Reddit API

Reddit Subreddit search API

Search posts within a single subreddit by query, sort and timeframe. Paginate with the cursor field.

POST/v1/run/reddit.subreddit_search
Uptime
99.01%
30d · 3,322 calls
Requests
3,323
30d · weekly, last 12 wks
Response
1.3s
median · 30d

Try it

Make your first request

Open in
Get a free key
Sample response
Free runs return only the first 3 results. Fund a key to get the full response.
{
  "found": true,
  "data": {
    "posts": [
      {
        "id": "t3_1ghi890",
        "title": "Quietest silent switches you have tried?",
        "author": "lurkmoar",
        "score": 612,
        "numComments": 144,
        "url": "https://www.reddit.com/r/MechanicalKeyboards/comments/1ghi890/",
        "permalink": "/r/MechanicalKeyboards/comments/1ghi890/",
        "createdUtc": 1718160000,
        "subreddit": "MechanicalKeyboards",
        "nsfw": false
      }
    ],
    "nextCursor": "t3_1ghi890"
  }
}
Response interface
interface RedditSubredditSearchResponse {
  data: {
    nextCursor: string | null;
    posts: {
      author: string;
      createdUtc: number;
      id: string;
      nsfw: boolean;
      numComments: number;
      permalink: string;
      score: number;
      selftext?: string;
      subreddit: string;
      title: string;
      url: string;
    }[];
  } | null;
  found: boolean;
}

Full parameter and response reference - every field, type, and example for this endpoint.

Reference

Request, response, and price

Last verified 2026-09-12 · uptime and latency measured over 30d
POST /v1/run/reddit.subreddit_search
curl -X POST https://api.getanyapi.com/v1/run/reddit.subreddit_search \
  -H "Authorization: Bearer $ANYAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"subreddit":"MechanicalKeyboards","query":"silent switches"}'
FieldTypeExample value
Request body
subredditstring"MechanicalKeyboards"Subreddit name without the r/ prefix (e.g. 'Fitness').
cursorstringOptional pagination token from a previous response.
querystring"silent switches"Optional search query to match posts (e.g. 'push ups').
sortstringOptional sort order: relevance, hot, top, new, comments.
timeframestringOptional time filter: all, year, month, week, day, hour.
Response
foundbooleantrue
dataobject
data.postsarray
data.posts[].idstring"t3_1ghi890"
data.posts[].titlestring"Quietest silent switches you have tried?"
data.posts[].authorstring"lurkmoar"
data.posts[].scorenumber612
data.posts[].numCommentsnumber144
data.posts[].urlstring"https://www.reddit.com/r/MechanicalKeyboards/comments/1ghi890/"
data.posts[].permalinkstring"/r/MechanicalKeyboards/comments/1ghi890/"
data.posts[].createdUtcnumber1718160000
data.posts[].subredditstring"MechanicalKeyboards"
data.posts[].nsfwbooleanfalse
data.nextCursorstring"t3_1ghi890"
Price
Price per requestUSD$0.00045
Price /1k reqUSD$0.45

FAQ

About the Reddit Subreddit search API

The AnyAPI Reddit Subreddit search API returns Reddit subreddit search data as normalized JSON from one POST call to /v1/run/reddit.subreddit_search. Search posts within a single subreddit by query, sort and timeframe. Paginate with the cursor field. AnyAPI routes each request across 5 sources and falls back automatically when one fails. It costs from $0.45 per 1,000 requests, in US dollars with no subscription and no monthly minimum. Over the last 30 days, 99.0% of Reddit subreddit search calls through AnyAPI succeeded, with a median response time of 1.3 seconds across 3,322 measured calls.

It costs from $0.45 per 1,000 requests, in US dollars with no subscription and no monthly minimum. You fund one USD wallet, each call draws it down, and a failed request costs $0.

Search posts within a single subreddit by query, sort and timeframe. Paginate with the cursor field. The response is normalized JSON with the same envelope every AnyAPI endpoint returns, so parsing a second endpoint is a change of URL and nothing else.

Over the last 30 days, 99.0% of Reddit subreddit search calls through AnyAPI succeeded, with a median response time of 1.3 seconds across 3,322 measured calls. These are AnyAPI's own measurements of traffic through the gateway, recomputed continuously, not a published service-level target.