SocialCrawl
Cookbooks

Find the communities and accounts behind a topic

Find the subreddits, groups and channels where a topic is discussed, then the accounts that post about it, with their latest posts

Send your topic words and get back two lists. The first holds the communities where people discuss the topic. The second holds the accounts that post about it. Then read the latest posts of the accounts you keep. The example maps the home sourdough baking world.

Measured on 18/11/2026: the communities run found 56 places and returned 10, for 15 credits. The accounts run returned 10 judged accounts and stopped at its cap of 40 credits. Two profiles with their latest posts cost 4.

Start in five minutes

Set your key once. Every block on this page reads it.

Terminal
export SOCIALCRAWL_API_KEY=YOUR_API_KEY

Paste this prompt into your coding agent:

Prompt
Read https://www.socialcrawl.dev/docs/recipes/communities-and-accounts.md and follow it to find the communities and accounts behind sourdough baking. Use the key in SOCIALCRAWL_API_KEY. Price each call with a dry run first (dry_run=true or dry_run=1), which is free. Send max_credits=30 for the communities and max_credits=40 for the accounts, and ask me before you raise either.

Or price the first call yourself. A dry run plans it for 0 credits:

cURL
curl -G "https://www.socialcrawl.dev/v1/prism/discover" \
  -H "x-api-key: $SOCIALCRAWL_API_KEY" \
  --data-urlencode "keywords=sourdough baking,sourdough starter" \
  --data-urlencode "view=communities" \
  --data-urlencode "platforms=reddit,facebook,youtube" \
  --data-urlencode "limit=10" \
  --data-urlencode "max_credits=30" \
  --data-urlencode "dry_run=true"

On 18/11/2026 it quoted at most 28 credits. The run itself cost 15.

How it works

  • The same topic words run twice: once to find communities, once to find accounts.
  • Communities are subreddits, Facebook groups and YouTube channels, each with its member count.
  • Accounts are the people and businesses whose posts matched, each looked up and judged.
  • The judgment says how well each account fits the topic and what kind of account it is.
  • You read the latest posts of the accounts you keep in one more call.

What you need

CallWhat it givesCredits
GET /v1/prism/discover with view=communitiesSubreddits, groups and channels about the topicEach search at its platform's price, up to max_credits
GET /v1/prism/discover with view=accountsAccounts that post about it, judgedEach search, plus looking up and judging each account, up to max_credits
POST /v1/prism/profiles with "include": "posts"Profiles and their latest posts1 a row, plus 1 for its posts page

Steps

Step 1: the communities

cURL
curl -G "https://www.socialcrawl.dev/v1/prism/discover" \
  -H "x-api-key: $SOCIALCRAWL_API_KEY" \
  --data-urlencode "keywords=sourdough baking,sourdough starter" \
  --data-urlencode "view=communities" \
  --data-urlencode "platforms=reddit,facebook,youtube" \
  --data-urlencode "limit=10" \
  --data-urlencode "max_credits=30"
Python
import json, os, urllib.parse, urllib.request

params = {"keywords": "sourdough baking,sourdough starter", "view": "communities",
          "platforms": "reddit,facebook,youtube", "limit": "10", "max_credits": "30"}
url = "https://www.socialcrawl.dev/v1/prism/discover?" + urllib.parse.urlencode(params)
req = urllib.request.Request(url, headers={"x-api-key": os.environ["SOCIALCRAWL_API_KEY"]})
data = json.load(urllib.request.urlopen(req, timeout=120))["data"]
for c in data["items"]:
    print(c["platform"], c["kind"], c["name"], c.get("members"), c["url"])
  • view=communities returns the places, not the posts.
  • limit=10 returns 10 communities. summary.communities.total says how many were found.
Response (trimmed)
{
  "data": {
    "items": [
      {
        "key": "reddit:subreddit:sourdough",
        "platform": "reddit",
        "kind": "subreddit",
        "name": "r/Sourdough",
        "url": "https://reddit.com/r/Sourdough",
        "members": 777152,
        "judgments": { "fit": { "p": 0.97, "basis": "community" } }
      }
    ],
    "summary": {
      "communities": {
        "total": 56,
        "by_kind": { "group": 5, "subreddit": 21, "channel": 30 }
      }
    }
  }
}

The 10 returned were 5 Facebook groups, 2 subreddits and 3 YouTube channels, with 165,000 to 2,329,280 members each. Each community also carries activity.posts_30d where the platform publishes it. The largest Facebook group showed 10,000 posts in 30 days.

Step 2: the accounts

cURL
curl -G "https://www.socialcrawl.dev/v1/prism/discover" \
  -H "x-api-key: $SOCIALCRAWL_API_KEY" \
  --data-urlencode "keywords=sourdough baking,sourdough starter" \
  --data-urlencode "view=accounts" \
  --data-urlencode "platforms=youtube,instagram,tiktok" \
  --data-urlencode "limit=10" \
  --data-urlencode "max_credits=40"
Python
import json, os, urllib.parse, urllib.request

params = {"keywords": "sourdough baking,sourdough starter", "view": "accounts",
          "platforms": "youtube,instagram,tiktok", "limit": "10", "max_credits": "40"}
url = "https://www.socialcrawl.dev/v1/prism/discover?" + urllib.parse.urlencode(params)
req = urllib.request.Request(url, headers={"x-api-key": os.environ["SOCIALCRAWL_API_KEY"]})
data = json.load(urllib.request.urlopen(req, timeout=120))["data"]
for row in data["items"]:
    acc, j = row["account"], row["judgments"]
    print(acc["key"], acc.get("followers"), j.get("account_kind"), (j.get("fit") or {}).get("p"))
  • Each account carries judgments.fit, a score from 0 to 1, and judgments.account_kind, such as individual_creator or brand_or_business.
  • evidence lists the posts that put the account on the list.
  • Judging each account is the largest part of the price. Price it with a dry run first.

Step 3: the latest posts of the accounts you keep

cURL
curl -X POST "https://www.socialcrawl.dev/v1/prism/profiles" \
  -H "x-api-key: $SOCIALCRAWL_API_KEY" \
  -H "content-type: application/json" \
  -d '{"items":[{"platform":"youtube","handle":"GrantBakes"},{"platform":"tiktok","handle":"wheatculture"}],"include":"posts"}'
Python
import json, os, urllib.request

body = {"items": [{"platform": "youtube", "handle": "GrantBakes"}, {"platform": "tiktok", "handle": "wheatculture"}],
        "include": "posts"}
req = urllib.request.Request("https://www.socialcrawl.dev/v1/prism/profiles", data=json.dumps(body).encode(),
                             headers={"x-api-key": os.environ["SOCIALCRAWL_API_KEY"], "content-type": "application/json"})
data = json.load(urllib.request.urlopen(req, timeout=120))["data"]
for row in data["results"]:
    if row["status"] == "ok":
        posts = (row.get("posts") or {}).get("items") or []
        print(row["platform"], row["data"]["author"]["username"], len(posts), "posts")
  • Send up to 25 accounts with "include": "posts", or up to 50 without.
  • A handle that is not found is refunded, and so is a posts page that comes back empty.

Store only what is new

Key communities and accounts on their key, such as reddit:subreddit:sourdough or tiktok:wheatculture. Keep one roster for the topic and add only keys you have not stored. To leave out accounts you already have on the next run, send their keys in exclude. To watch the roster's new posts each day, follow the Follow creators cookbook with the accounts as its list.

What it costs

PartCredits
A dry run0
Each search that returns rowsThat platform's search price
Looking up and judging an accountPriced by the dry run
A profile, and its posts page1 each, 5 on LinkedIn

What the example runs measured on 18/11/2026:

RunRowsCredits
The communities dry run00
The communities run10 of 5615
The accounts run, stopped at its cap10 of 170 candidates40
Two profiles with their posts24
The same two runs sent againthe same rows0

Sending a run again while it exists returns it, so the repeat cost nothing.

Tips, and what not to use

  • Run the communities first. They cost less here, and their names can suggest keywords for the accounts.
  • Raise max_credits only after a dry run. The accounts run here stopped at its cap of 40 with 10 accounts. Its next_step priced the remaining 168 candidates at a total cap of 194.
  • Add context to say what kind of community or account you want. It is judged on every row, so price it first.
  • Do not use GET /v1/prism/creators for this job. It builds creator shortlists. For communities, shops and businesses, use Discover as this page does.

Full program and agent brief

Next steps