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

Reddit comment by id API

One comment by its post and comment id, as a t1 Thing, without its replies.

GET /v1/reddit/posts/{id}/comments/{comment}1 credit per callRefunded on failure
import os, requests

res = requests.get(
    "https://api.groundsocial.dev/v1/reddit/posts/1y4iysc/comments/19t52rpfh106d",
    headers={"Authorization": f"Bearer {os.environ['GROUNDSOCIAL_API_KEY']}"},
)
res.raise_for_status()
data = res.json()
Response
200 · 1 credit
{
"kind": "t1",
"data": {
"id": "19t52rpfh106d",
"name": "t1_19t52rpfh106d",
"author": "drivingagermanwhip",
"author_fullname": null,
"body": "nice! I'll check it out",
"body_html": "<div class=\"md\"><p>\n nice! I'll check it out\n </p></div>",
"parent_id": "t1_19t52m56lkbhg",
"link_id": "t3_1y4iysc",
"subreddit": "Python",
"subreddit_id": "t5_2qh0y",
"permalink": "/r/Python/comments/1y4iysc/comment/19t52rpfh106d/",
"created_utc": 1795561146,
"score": 1,
"ups": 1,
"downs": 0,
"depth": 0,
"is_submitter": false,
"stickied": false,
"distinguished": null,
"edited": null,
"replies": ""
}
}

Parameters

NameTypeDescription
idpath · requiredstringA post id (1y1u285), fullname (t3_1y1u285) or post URL. Example: 1y1u285.
commentpath · requiredstringComment id or t1_ fullname. Example: 19t52rpfh106d.
Status codes
StatusMeaning
200The comment.
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.