herascrape
API reference

Comments

Threaded replies and comment likers.

Comment ids come from GET /posts/{id}/comments — each item's pk.

Replies

Instagram scopes replies to the parent media, so media_id and user_id are required alongside the comment id: the parent post's id (pk or shortcode) and its owner's numeric id.

GET /comments/18012345678901234/replies?media_id=2168384974851429640&user_id=25025320

Paginated on the standard cursor.

Path Parameters

comment_id*Comment Id

Query Parameters

media_id*Media Id

Parent post id: shortcode, bare or composite pk

user_id*User Id

Numeric id of the post's owner (the post's user.pk)

Match^\d+$
cursor?|

Opaque pagination cursor from a previous next_cursor

GET
/comments/{comment_id}/replies
curl -X GET "https://example.com/comments/string/replies?media_id=string&user_id=string"
{}
{}

What comes back

The standard list envelope. Items are comment objects in the same shape as a post's comments — pk, text, created_at, comment_like_count, user.

Likers

Keyed by comment id alone — no media_id. Returns one page; has_more is always false.

Path Parameters

comment_id*Comment Id
GET
/comments/{comment_id}/likers
curl -X GET "https://example.com/comments/string/likers"
{}
{}

What comes back

The standard list envelope, with compact user objects identical to followers.

Errors

CodeWhen
not_foundThe comment was deleted, or the id is wrong.
invalid_parametermedia_id is not a valid post id, or names a different owner than user_id.
unprocessable_entitymedia_id or user_id is missing, or user_id is not numeric.
invalid_cursorThe cursor was not one we issued.
upstream_errorTransient. Retry.

On this page