Instagram Post Comments
Instagram Post Comments
Overview
List the comments of an Instagram post, by post: a post URL (a /p/, /reel/ or /tv/ link, with or without the account handle in front), its shortcode or its numeric media id. Each comment carries its id, the text (whitespace collapsed, cut at 300 characters), the time it was written, its like counter and the commenting account as a short profile (pk, handle, display name, privacy and verification flags, profile URL). Replies to comments appear as their own entries on the page, as far as Instagram delivers them.
One call returns one page of comments (the data service usually delivers 15 per page). Repeat next_cursor back as cursor for the next page; null means the comments are fully read. A post given as a URL or a shortcode is resolved first (over the post cache shared with instagram_post); a numeric media id goes straight to the comments and needs no lookup.
Fetched pages are cached for 24 hours and shared across the platform. A second request for the same page within that window answers instantly and is charged the lower cached price.
When to use
- Find profiles that talk about a topic: commenters are more engaged than likers and their texts show what they care about.
- Read the reactions to a post without loading the post page.
[!NOTE]
A post that does not exist or was deleted completes with found: false, a post whose comments cannot be read (for example on a private account) with restricted: true, both not charged. A page without comments completes with count: 0, also at no charge. Genuine errors of the data service (auth, rate limit, 5xx) still fail the run and are refunded.
Endpoint
Output
Paging
Each call returns one page. To get the next page, pass the value of next_cursor back as cursor. A null cursor means the comments are fully read. Pages are priced individually, so page only as deep as you need.
Pricing
This enrichment costs 2 credits for a freshly fetched page. A page served from the cache (at most 24 hours old) is charged the lower cached tier. Pages without comments and runs ending with found: false or restricted: true are free.
Examples
Playground
States
| State |
Description |
queued |
Request accepted; waiting to be picked up by a worker. |
processing |
Worker is actively running the enrichment. |
completed |
Enrichment finished and results are available in output. |
failed |
Enrichment failed; reason is in error. Credits are refunded for failures unless otherwise noted. |
Errors
| Error |
When it happens |
What to do |
invalid_input |
post is missing or is not an Instagram post link, shortcode or media id, or cursor is malformed. |
Pass a post URL like https://www.instagram.com/p/DPxQ1AbCDeF/, its shortcode or its numeric media id; repeat next_cursor verbatim. |
not_found |
The lookup completed but the post does not exist or was deleted. |
No action needed, the run costs nothing. |
restricted |
The comments of the post cannot be read. |
No action needed, the run costs nothing. |
rate_limited |
The data service throttled the request. |
Retry with backoff. |
provider_error |
The data service returned an unexpected error. |
Retry; if persistent, contact support. |
503 endpoint_unavailable |
The endpoint is currently not configured or temporarily disabled. Nothing is reserved or charged. |
Retry later; if persistent, contact support. |