LurkAPI
Docs · Search Reddit

Search Reddit

Search all of Reddit for posts matching a keyword.

1 credit per callFresh within 1 minuteMCP tool: reddit_search
GEThttps://api.lurkapi.com/v1/reddit/search

Example response

When to use this

Use it for brand monitoring and to find where a topic is discussed. It searches posts across all of Reddit, like reddit.com/search, and returns each post's title, author, subreddit, score, comment count and date. It doesn't search comments.

Results have no body text or link. For the full post, pass https://www.reddit.com + permalink as url to post comments (reddit_post_comments).

Pagination. Pass the response's after back as after for the next page; it's null at the end.

Example request

Copy one and replace YOUR_API_KEY with your API key (get one free). The code versions read the key from the LURKAPI_API_KEY environment variable instead.

Language

Parameters

Add them to the URL after a ?, as in ?query=claude+mcp. Join several with &.

ParameterDescription
query
stringrequired
Keywords, e.g. claude mcp.
Example
claude mcp
filter
stringoptional
What to search. Only posts for now; comment search isn't supported yet.
One of
posts
Default
posts
sort
stringoptional
Result order.
One of
relevancenewtopcomment_count
Default
relevance
timeframe
stringoptional
Only posts from the last hour, day, week, month, year, or all time.
One of
allhourdayweekmonthyear
Default
all
after
stringoptional
The after from the previous response, to get the next page.
trim
booleanoptional
Has no effect here: search results have no HTML body to drop.
One of
truefalse
Default
false

Example response

A real response, captured from the live API. Lists are trimmed to a couple of items, and long text such as media links is cut short with ….

Show the example response (2 KB)
{
  "success": true,
  "credits_remaining": 992,
  "credits_charged": 1,
  "posts": [
    {
      "id": "1v9n747",
      "name": "t3_1v9n747",
      "title": "Are people actually using MCP? For what?",
      "author": "ksyp21",
      "author_fullname": "t2_2rjo8r0b",
      "subreddit": "mcp",
      "subreddit_id": "t5_2s5cc",
      "subreddit_name_prefixed": "r/mcp",
      "quarantine": false,
      "permalink": "/r/mcp/comments/1v9n747/are_people_actually_using_mcp_for_what/",
      "score": 93,
      "ups": 93,
      "num_comments": 275,
      "created": 1785304145,
      "created_utc": 1785304145,
      "created_at_iso": "2026-07-29T05:49:05.000Z",
      "over_18": false,
      "spoiler": false,
      "thumbnail": null
    },
    {
      "id": "1w2grux",
      "name": "t3_1w2grux",
      "title": "What’s a good useful MCP you connected to that brings you real value?",
      "author": "Dense-Map-406",
      "author_fullname": "t2_zbqg0zcxt",
      "subreddit": "ClaudeAI",
      "subreddit_id": "t5_7t8hvt",
      "subreddit_name_prefixed": "r/ClaudeAI",
      "quarantine": false,
      "permalink": "/r/ClaudeAI/comments/1w2grux/whats_a_good_useful_mcp_you_connected_to_that/",
      "score": 412,
      "ups": 412,
      "num_comments": 249,
      "created": 1788094320,
      "created_utc": 1788094320,
      "created_at_iso": "2026-08-30T12:52:00.000Z",
      "over_18": false,
      "spoiler": false,
      "thumbnail": null
    }
  ],
  "after": "eyJjYW5kaWRhdGVzX3JldHVybmVkIjoie1wic2VjdGlvbl8xX3BpcGVsaW5lXzBfZ2xvYmFs…"
}

Response fields

Every field in a successful response, and what it means. A name with [] belongs to each item of a list: posts[].id is the id of every item in posts. null means there's no value.

Show all 24 fields
FieldTypeDescription
successtrueAlways true here; errors have success: false.
credits_remainingnumberYour balance after this call. On anonymous playground calls: free tries left today.
credits_chargednumberCredits this call cost; 0 on free endpoints. On anonymous playground calls: tries used (1).
postsobject[]Matching posts, in sort order.
posts[].idstringPost id. Pass the post's URL to post comments for the full post.
posts[].namestringFullname, t3_ + id.
posts[].titlestringPost title.
posts[].authorstringcan be nullUsername, without u/; null if unknown.
posts[].author_fullnamestringcan be nullAuthor's account fullname, t2_ + id.
posts[].subredditstringSubreddit name without r/.
posts[].subreddit_idstringcan be nullSubreddit fullname, t5_ + id.
posts[].subreddit_name_prefixedstringSubreddit name with the r/ prefix, e.g. r/ClaudeAI.
posts[].quarantinebooleanThe subreddit is quarantined.
posts[].permalinkstringcan be nullPath on reddit.com; prepend https://www.reddit.com.
posts[].scorenumberUpvotes minus downvotes.
posts[].upsnumberSame as score.
posts[].num_commentsnumberComment count when fetched.
posts[].creatednumberPosted at, Unix seconds.
posts[].created_utcnumberPosted at, Unix seconds.
posts[].created_at_isostringPosted at, ISO 8601.
posts[].over_18booleanMarked NSFW.
posts[].spoilerbooleanMarked as a spoiler.
posts[].thumbnailstringcan be nullPreview image URL; null for posts without media.
afterstringcan be nullPass as after for the next page. null on the last page.

Pagination

Results come in pages. For the next page, repeat the call with the same parameters and add the response's after as after. On the last page, after is null. Each page costs 1 credit.

The first five pages, in JavaScript
let after = null;for (let page = 1; page <= 5; page++) {const params = new URLSearchParams({ query: "claude mcp" });if (after) params.set("after", after);const res = await fetch(`https://api.lurkapi.com/v1/reddit/search?${params}`, {headers: { "x-api-key": process.env.LURKAPI_API_KEY },});const data = await res.json();if (!data.success) throw new Error(`${data.code}: ${data.error}`);console.log(data.posts);after = data.after;if (!after) break; // last page}

Cost and freshness

Each call costs 1 credit. Calls turned away before they reach the platform (invalid parameters, a key or balance problem, a rate limit) are free, and so are 5xx errors. A not_found is charged, since the platform was checked. How charging works.

Answers are cached for up to 1 minute. A repeat call within that time can return the same data, and costs the same.

Errors

A failed call returns success: false, an error message, a code your program can check, and a docs link. These are the errors this endpoint can return. All error codes.

StatusCodeMeaning
401missing_api_keyNo API key was sent. Put it in the x-api-key header.
401invalid_api_keyThis key doesn't exist or was revoked.
402insufficient_creditsNot enough credits for this call. Buy a pack, or wait for tomorrow's free top-up.
402over_max_creditsThis call would cost more than the max_credits you set. The error says what it needs; raise max_credits to allow it. Not charged.
403account_suspendedThis account is suspended. Email support@lurkapi.com. Not charged.
405method_not_allowedEndpoints only take GET, with parameters in the URL.
429rate_limitedToo many calls in a short time. Wait as many seconds as the retry-after header says, then retry.
500internal_errorSomething broke on our side. Retry. Not charged.
502upstream_errorThe platform didn't send a usable answer. Retry. Not charged.
503upstream_busyAll our connections to the platform are busy. Retry in a few seconds. Not charged.
504upstream_timeoutThe platform took over 30 seconds to answer (90 for web pages). Retry. Not charged.

Use it in Claude

Connect LurkAPI to Claude and ask in plain English. This endpoint is the reddit_search tool. For example:

Ask Claude
Use LurkAPI's reddit_search tool with query "claude mcp", then summarize what you find.

Claude calls reddit_search with arguments like these, and each call costs 1 credit:

Tool arguments
{"query": "claude mcp"}

To save tokens, tool results leave out empty fields, keep one URL per image or video, and give transcripts as plain text unless you pass timestamps=true. A result over 45,000 characters comes in parts. Its _note gives the offset for the next part, and later parts are free for 15 minutes. Pass trim=false for the full response.

From the blog

All posts