100 free credits. No credit card required. Get a key

Reddit batch subreddit lookup API

Up to 25 communities by name in one call, each as the t5 Thing the single lookup returns; names Reddit does not return are listed in missing.

POST /v1/reddit/subreddits/batch5 credits per callRefunded on failure
import os, requests

res = requests.post(
    "https://api.groundsocial.dev/v1/reddit/subreddits/batch",
    headers={"Authorization": f"Bearer {os.environ['GROUNDSOCIAL_API_KEY']}"},
    json={"names":["python","typescript","rust"]},
)
res.raise_for_status()
data = res.json()
Response
200 · 5 credits
{
"subreddits": [
{
"kind": "t5",
"data": {
"id": null,
"name": null,
"display_name": "typescript",
"display_name_prefixed": "r/typescript",
"title": "typescript",
"public_description": "About r/typescript",
"description": null,
"subscribers": 180000,
"active_user_count": null,
"created_utc": null,
"over18": false,
"subreddit_type": "public",
"url": "/r/typescript/",
"icon_img": null,
"banner_img": null
}
}
],
"requested": 3,
"returned": 1,
"missing": [
"python",
"rust"
]
}
Response fields

200 with a SubredditBatch, in Reddit’s own Things and Listings.

FieldTypeDescription
subredditsSubreddit[]
requestednumber
returnednumber
missingstring[]
Status codes
StatusMeaning
200The subreddits found and the names that were not.
400Invalid input. Nothing was charged.
401Missing or invalid API key.
402Not enough credits, a spend cap was reached, or payment is required.
403The target is private, or the account is suspended.
404The subreddit, post or user does not exist.
429Too many requests. Wait for Retry-After seconds.
503Reddit is temporarily unavailable. Retryable; nothing was charged.

Every error has code, message, hint and retryable. All error codes

Reddit is a trademark of Reddit, Inc. We are not affiliated with or endorsed by Reddit.