Fetch a post's comments
Fetch one page of an Instagram post or reel's comments, newest first — each with its author, text, timestamp, like count, and any preview replies.
GET /v1/instagram/post/{post_id}/comments
What's included
Each request returns one page of comments plus a next_cursor. Page through
a post's comments with the returned cursor, one page per request.
Path parameter
| Parameter | Description |
|---|---|
post_id | The post shortcode (e.g. DcghxSFtjRB) or a full post URL (/p/…, /reel/…, /tv/…). |
Query parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
cursor | string | — | Omit for the first page; pass the next_cursor from a previous response to fetch the next page. |
Examples
First page:
curl -G "$LISTENX_BASE/v1/instagram/post/DcghxSFtjRB/comments" \
-H "X-API-Key: $LISTENX_KEY"
Fetch the next page by passing the previous response's next_cursor:
curl -G "$LISTENX_BASE/v1/instagram/post/DcghxSFtjRB/comments" \
-H "X-API-Key: $LISTENX_KEY" \
--data-urlencode 'cursor=cmt1_eyJjYWNoZWRfY29tbWVudHNfY3Vyc29yIjoiMTgwNjg…'
Keep following next_cursor until has_next_page is false to walk every
comment, one page per request.
Response
{
"post_id": "DcghxSFtjRB",
"shortcode": "DcghxSFtjRB",
"url": "https://www.instagram.com/p/DcghxSFtjRB/",
"comment_count": 238,
"returned": 2,
"has_next_page": true,
"next_cursor": "cmt1_eyJjYWNoZWRfY29tbWVudHNfY3Vyc29yIjoiMTgwNjg…",
"comments": [
{
"id": "18068394785637492",
"text": "This is gorgeous 😍",
"created_at": "2025-06-12T16:02:41+00:00",
"like_count": 54,
"reply_count": 1,
"author": {
"id": "15904929129",
"username": "jane.doe",
"full_name": "Jane Doe",
"is_verified": false,
"profile_pic_url": "https://…"
},
"replies": [
{
"id": "18068394785637493",
"text": "Agreed!",
"created_at": "2025-06-12T16:10:03+00:00",
"like_count": 3,
"reply_count": null,
"author": {
"id": "15904929130",
"username": "another.user",
"full_name": "Another User",
"is_verified": false,
"profile_pic_url": "https://…"
},
"replies": []
}
]
},
{
"id": "18068394785637500",
"text": "Love this 🔥",
"created_at": "2025-06-12T16:05:12+00:00",
"like_count": 7,
"reply_count": 0,
"author": {
"id": "15904929131",
"username": "third.user",
"full_name": "Third User",
"is_verified": true,
"profile_pic_url": "https://…"
},
"replies": []
}
],
"billing": {
"endpoint": "instagram.comments",
"units": 1,
"unit_price": "0.010000",
"amount": "0.010000",
"balance_after": "97.210000",
"request_id": "…"
}
}
Fields
| Field | Description |
|---|---|
post_id / shortcode | Shortcode of the post these comments belong to. |
url | Canonical post permalink. |
comment_count | Total comments on the post (may exceed those returned on this page). |
returned | Number of top-level comments in comments on this page. |
has_next_page | true if more comment pages remain. |
next_cursor | Opaque cursor for the next page — pass it back as cursor; null when exhausted. |
comments[] | Comments with author, text, timestamp, like count, and preview replies. |
Comment
| Field | Description |
|---|---|
id | Comment id. |
text | Comment text. |
created_at | ISO 8601 UTC timestamp. |
like_count | Likes on the comment, when available. |
reply_count | Number of replies to the comment. |
author | Commenter details (id, username, full_name, is_verified, profile_pic_url). |
replies[] | Preview replies returned inline with the comment, when available. |
Billing
Billed per page — one unit per request (each request returns a single page). Paging through every comment costs one unit per page fetched. See Billing.
Errors
| HTTP | code | Meaning |
|---|---|---|
| 400 | invalid_post_id | Not a valid shortcode/URL. |
| 404 | post_not_found | Private, deleted, nonexistent, or comments disabled. |
| 429 | upstream_rate_limited | Transient block — retry with backoff. |