Skip to main content
GET
Get comments for a post using the Ayrshare post ID, Social Post ID, Ayrshare Comment ID, or Social Comment ID with the Comment API. Please see the Comments Overview for more information on the different ID types.
If using the Ayrshare Post ID no query parameters are required.

Additional Comment Details

  • Comment data is updated every 10 minutes for all platforms, with the exception of X. Due to restrictions imposed by the X API, the comment data for X is refreshed using an exponential backoff strategy, meaning the intervals between updates gradually increase over time.
  • In the Facebook response, comment replies to replies always have the same parent.id.
  • Retrieve LinkedIn replies to comments by setting the "commentId": true and "searchPlatformId": true query parameters and providing the Social Comment ID in the path parameter.
  • Facebook and Instagram return up to the most recent 1,000 comments on a post. Please contact us regarding higher limits on the Enterprise plan.
  • For a TikTok post still being processed (its id is "pending"), get-comments returns a clear “still processing” error (code: 288, HTTP 400) rather than a generic failure. Retry once the tikTokPublished webhook fires or /history shows the resolved video id.

Multiplatform Reads & Partial Success

When you request comments with the Ayrshare Post ID, the post may span several platforms. Ayrshare fans out one request (“leg”) per platform and returns a partial success if some legs succeed and others fail — the healthy platforms’ comment data is always returned, and each failed leg is enumerated in a top-level errors[] array.
  • Some platforms succeed, some fail: the response is HTTP 200 with status: “partial”. The healthy platform blocks are returned as usual, and a top-level errors[] array lists every failed leg with its platform, status, code, message, and id.
  • Every platform fails: the response has status: “error” and the full errors[] array. The HTTP status is mapped from the representative top-level error code. Code 485 maps to HTTP 404; other representative codes use their own mappings.
  • All platforms succeed: the response is unchanged — HTTP 200, status: “success”, and no errors[] key.
Behavior change — inspect errors[], don’t branch on HTTP status. Because a multiplatform read with a failing leg now returns HTTP 200 instead of collapsing the whole response to an error, integrators should always check for the presence of a top-level errors[] array to detect per-platform failures rather than relying on the HTTP status code alone.

Expired or Unavailable Instagram / Facebook Story Comments

An Instagram or Facebook Story comments leg that is expired or unavailable — so its comments cannot be retrieved — surfaces in errors[] with code 485. A representative Instagram message is “Instagram Story expired or unavailable — comments/insights cannot be retrieved.” If another platform succeeds, its comments are still returned and the overall response is HTTP 200. For an all-fail response, representative code 485 maps to HTTP 404; other representative codes use their own mappings. Match on the code (485), not the exact message text.

Example: Partial Success Response

200: Partial Success

Header Parameters

Path Parameters

Query Parameters

boolean
default:false
If getting comments on a post published via Ayrshare and using the Ayrshare Post ID, do not include this field - it defaults to false. If getting comments using the Social Post ID or Social Comment ID, which is the ID generated by the social networks, set to true.
boolean
default:false
If getting comments using the Social Comment ID, which is the comment ID generated by the social networks, set to true.If getting comment using the Ayrshare Post ID or Social Post ID, do not include this field - it defaults to false.
If using the commentId query parameter, you must also set searchPlatformId to true.
string
Required if searchPlatformId or commentId is true.When to use:
  • If using the Social Post ID and "searchPlatformId": true field. Supported platforms: bluesky, facebook, instagram, linkedin, threads, tiktok, twitter, youtube.
  • If using the Social Comment ID and "searchPlatformId": true and "commentId": true fields. Supported platforms: facebook, instagram, linkedin.
  • If using the Ayrshare Post ID, do not include this field - comments will be returned from all platforms where the original post was published.

Comment GET Request Examples