Skip to content
redditdataapi.io
All endpoints

Fetch Post Comment Tree & Replies

GET/v1/posts/comments

Query Parameters

  • post_idstringrequired

  • sortstring

  • limitinteger (1 to 200)

  • cursorstring

Example Request (cURL / Python / JavaScript)

curl "https://api.redditdataapi.io/v1/posts/comments?post_id=" \
  -H "x-api-key: rd_live_your_api_key"

Live Response Preview

{
  "code": 0,
  "provider": "https://redditdataapi.io",
  "status": "ok",
  "msg": "success",
  "data": {
    "post_id": "t3_1xmjld9",
    "items": [
      {
        "id": "m8kq21a",
        "comment_id": "t1_m8kq21a",
        "post_id": "t3_1xmjld9",
        "subreddit": "saas",
        "parent_id": "t3_1xmjld9",
        "author": "devtools_builder",
        "body": "What polling interval do you use for keyword search? We switched from PRAW to RedditDataAPI.io and cut latency to 180ms.",
        "score": 49,
        "depth": 0,
        "is_submitter": false,
        "is_stickied": false,
        "created_utc": 1762287600,
        "created_at": "2026-11-04T20:20:00.000Z",
        "permalink": "https://www.reddit.com/r/saas/comments/1xmjld9/how_we_scaled_our_b2b_saas/m8kq21a/"
      }
    ],
    "count": 1,
    "next_cursor": null,
    "cursor": null,
    "has_more": false,
    "hasMore": false
  },
  "meta": {
    "request_id": "d81a2f10-81e3-4c22-9118-092f1a8b3344",
    "endpoint": "/v1/posts/comments",
    "credits_used": 2,
    "credits_remaining": 249996,
    "cache_hit": false,
    "data_age_seconds": 0,
    "latency_ms": 210
  }
}

Response Fields

Comment tree nodes with depth & parent_id (1 Credit per comment returned)

FieldTypeSample / Notes
codeinteger0 on success
statusstringResponse status
dataobjectFlattened comment tree with depth and parent_id
post_idstringTarget Reddit post ID
itemsarray of RedditCommentArray of normalized comments
idstringExample: m7k9x2a
comment_idstringExample: t1_m7k9x2a
post_idstringExample: t3_1xmjld9
subredditstringExample: SaaS
parent_idstringExample: t3_1xmjld9
authorstringExample: infra_lead
bodystringExample: Moving off official Reddit OAuth saved us from constant 429
scoreintegerExample: 64
depthintegerExample: 0
is_submitterbooleanExample: false
is_stickiedbooleanExample: false
created_utcintegerExample: 1762255800
created_atstringExample: 2026-11-04T11:30:00.000Z
permalinkstringExample: https://www.reddit.com/r/SaaS/comments/1xmjld9/_/m7k9x2a/
countintegerNumber of comments returned
next_cursorstringOffset cursor for next comment batch
has_morebooleanWhether more comments remain
metaResponseMeta
request_idstringUUID v4 request identifier
endpointstringCanonical /v1/* endpoint path
credits_usedintegerCredits deducted for this call (0 on error or empty)
credits_remainingintegerRemaining credit balance on account
cache_hitbooleanWhether served from L1 Redis cache
data_age_secondsintegerAge of cached payload in seconds
latency_msintegerEnd-to-end gateway latency in milliseconds

Status Codes

200
Comment tree nodes with depth & parent_id (1 Credit per comment returned)