ReddGrowReddGrow Docs
Guides

Subreddit Research

Research a subreddit before posting

Before your agent posts to or engages with a subreddit, it should understand the community. This guide walks through a research sequence for r/typescript covering what is being posted right now, what performs best, how people talk in comments, and whether your topic has already been discussed.

Total cost for this sequence: 12 credits

Every call below is an async job: the API replies 202 Accepted with a jobId, and you fetch the result from GET /v1/reddit/jobs/{id} (free). The CLI waits for the result for you. See AI Agent Integration for the full flow.


Step 1: Read the current feed (2 credits)

Start with the hot feed to see what the community is talking about today.

curl -H "x-api-key: $REDDGROW_API_KEY" \
  "https://api.reddgrow.ai/agent/subreddits/typescript/posts?sort=hot&limit=25"
reddgrow reddit subreddits posts typescript --sort hot --limit 25
{
  "jobId": "job_01HXYZ...",
  "status": "queued"
}

Once the job completes, its result holds the posts:

{
  "posts": [
    {
      "id": "abc123",
      "title": "TypeScript 5.4 released",
      "score": 1842,
      "num_comments": 134,
      "url": "https://devblogs.microsoft.com/typescript/..."
    }
  ]
}

Titles show which topics and formats are active. Scores and comment counts show how much attention they get.


Step 2: Check top posts (2 credits)

Scan the top posts of the week to understand what content performs well and what tone the community expects.

curl -H "x-api-key: $REDDGROW_API_KEY" \
  "https://api.reddgrow.ai/agent/subreddits/typescript/posts?sort=top&t=week"
reddgrow reddit subreddits posts typescript --sort top --time week

Use the title and score fields to identify patterns. High-scoring posts give your agent a template for framing its own submission. Supported sorts are hot, new and top.


Step 3: Listen to the comment stream (4 credits)

The comment stream shows how people actually talk in the community, which is hard to infer from titles alone. It returns 25 comments per page at 2 credits per page, so limit=50 costs 4 credits (use the default for 2).

curl -H "x-api-key: $REDDGROW_API_KEY" \
  "https://api.reddgrow.ai/agent/subreddits/typescript/comments?limit=50"
reddgrow reddit subreddits comments typescript --limit 50

Each comment's parent_id is the post it belongs to. The parent comment is not available.


Step 4: Check if your topic was already discussed (4 credits)

Search for the exact phrase you plan to post about. Results are newest first and include titles and metadata only (selftext is empty). Search costs 1 credit per 7 results, so limit=25 costs 4 credits; limit=7 costs 1.

curl -H "x-api-key: $REDDGROW_API_KEY" \
  "https://api.reddgrow.ai/agent/posts/search?q=typescript+generics+explained&limit=25"
reddgrow reddit posts search "typescript generics explained" --limit 25

If a recent thread already covers your topic, your agent can join that thread with a comment instead of starting a duplicate post.


Full sequence summary

StepEndpointCredits
Current feedGET /agent/subreddits/{sub}/posts?sort=hot2
Top postsGET /agent/subreddits/{sub}/posts?sort=top2
Comment streamGET /agent/subreddits/{sub}/comments?limit=504
Topic searchGET /agent/posts/search?limit=254
Total12

To reduce cost, skip the comment stream unless your agent needs to match the community's tone. Steps 1 and 4 alone cost 6 credits and cover most posting decisions (2 credits if you search with limit=7).