Composites

List every comment and reply under a post

List every comment under a TikTok, Instagram, YouTube, Reddit, X or Facebook post from its URL, with replies when includeReplies=true, in one shape, page by…

GET/v1/composites/comments
x-api-keystringheader

API key (`sfk_...`)

Parameters
6
urlstringrequiredquery

Link to the post, video or Reel whose comments to list: TikTok, Instagram, YouTube, Reddit, X or Facebook. Send the same `url` with every cursor.

min 1 chars · max 4096 chars

cursorstringoptionalquery

`page.nextCursor` from the previous call, to read on. Send it with the same `url` and `includeReplies`.

min 1 chars · max 16384 chars

includeRepliesbooleanoptionalquery

When true, also lists the replies to each comment, and replies to replies where the platform has them. Default false: top-level comments only.

dryRunbooleanoptionalquery

When true, returns the quote (the most this call can cost) and runs nothing, for 0 credits.

maxCreditsintegeroptionalquery

The most you approve this call to cost. When the quote is higher, nothing runs and nothing is charged. Send the quote a dry run returned to approve exactly that.

≥ 1 · ≤ 10000

labelsbooleanoptionalquery

Free AI labels on each row of the list, on by default. Each row gets `labels`: `question`, `complaint`, `purchaseIntent` and `sponsored` (true or false) and `sentiment` (`positive`, `neutral` or `negative`). Labels are model estimates and are never charged. Labels already made come back at once; the answer waits up to 0.7 seconds for new ones, and a row not labelled by then has `labels: null` and is labelled for your next call. Pass `true` to wait up to 2.5 seconds, or `false` to leave them out.

Response fields
59

Endpoint-specific response payload.

dataurl
string

The post URL, as sent.

dataplatform
string

one of: tiktok, instagram, youtube, reddit, x, facebook

dataincludeReplies
boolean
datadryRun
boolean

The price of this call, worked out before anything runs.

dataquotecredits
integer

The most this call can cost: every leg at its price. A run holds this much and charges only what its legs cost.

≥ 0

dataquotelegs[]key
string

The leg's name within this composite.

dataquotelegs[]endpoint
string

The Social Fetch endpoint the leg calls, by its id.

dataquotelegs[]credits
integer

The most this leg can cost: the endpoint's own price.

≥ 0

datalookupStatus
stringnullable

Whether the post was found, when this call read a page of its comments; null when it only read replies, or on a dry run.

one of: found, not_found, null

datatotalComments
integernullable

The comment count the platform reports for the post, where it reports one on this page (TikTok, and Reddit's first page). It can count comments the platform hides.

≥ 0

The comments and replies this call read: replies follow the comments they answer, in later calls when there are many. Null on a dry run.

datacomments[]id
string

The comment's id on the platform.

min 1 chars

datacomments[]platform
string

one of: tiktok, instagram, youtube, reddit, x, facebook

datacomments[]parentId
stringnullable

The id of the comment this replies to; null for a top-level comment.

datacomments[]text
string

Comment text. Empty on a sticker or GIF.

Who wrote the comment.

datacomments[]authorid
stringnullable

The author's account id on the platform, when known.

datacomments[]authorhandle
stringnullable

Username, without @. Null where the platform shows none.

datacomments[]authordisplayName
stringnullable

Display name, when the platform shows one.

datacomments[]authoravatarUrl
stringnullable

Profile picture URL, when known. It may expire.

datacomments[]likes
integernullable

Likes (reactions on Facebook, score on Reddit). Null when not reported.

datacomments[]replyCount
integernullable

Direct replies the platform reports. It can count replies it hides. Null when not reported.

≥ 0

datacomments[]createdAt
stringnullable

When it was posted (ISO-8601), when known.

datacomments[]url
stringnullable

Link to the comment, where the platform has one.

Free AI labels for this row, estimated by a model. `null` when the row couldn't be labelled in time (it's usually labelled by your next call); absent when labels are off.

datacomments[]labelsquestion
boolean

The author asks a question.

datacomments[]labelscomplaint
boolean

The author complains about a product, service, company, price or the content.

datacomments[]labelspurchaseIntent
boolean

The author wants or plans to buy, is choosing what to buy, or asks where or how to buy.

datacomments[]labelssponsored
boolean

The text promotes or sells something: an ad, a paid partnership, an affiliate or shop link, a discount code or promotional spam.

datacomments[]labelssentiment
string

The overall feeling the author expresses.

one of: positive, neutral, negative

Pages that couldn't be read this call. Usually empty.

dataerrors[]parentId
stringnullable

The comment whose replies couldn't be read; null for the post's own comments.

dataerrors[]code
string

The error code of the call that failed.

dataerrors[]message
string
dataerrors[]willRetry
boolean

True when the next call with `page.nextCursor` tries this page again; false when it was tried twice and is skipped.

Where this call got to. Null on a dry run.

datapagenextCursor
stringnullable

Pass as `cursor` to read on; null when everything has been read.

datapagehasMore
boolean

Whether there's more to read.

What ran and what it cost; null on a dry run.

datareceiptcreditsQuoted
integer

≥ 0

datareceiptcreditsCharged
integer

What the call cost: the same as `meta.creditsCharged`.

≥ 0

datareceiptcreditsRefunded
integer

The part of the quote given back: what failed legs, and legs that cost less than their price, didn't use.

≥ 0

datareceiptlegs[]key
string

The leg's name within this composite.

datareceiptlegs[]endpoint
string

The Social Fetch endpoint the leg called, by its id.

datareceiptlegs[]status
string

`ok` when the call answered, `failed` when it didn't.

one of: ok, failed

datareceiptlegs[]creditsQuoted
integer

≥ 0

datareceiptlegs[]creditsCharged
integer

What this leg cost. A failed leg costs nothing unless its endpoint charges that failure when called on its own.

≥ 0

datareceiptlegs[]errorCode
stringnullable

The endpoint's error code when the leg failed.

datareceiptlegs[]ms
integer

How long the leg took, in milliseconds.

≥ 0

Metadata describing the request and billing outcome.

metarequestId
string

Unique request identifier for tracing this API call.

min 1 chars

metacreditsCharged
integer

Credits charged for this request.

≥ 0

metaversion
string

Public API version that served the response.

one of: v1

metastale
booleanoptional

Present, and `true`, only when the source couldn't be reached and this is the last good answer for the same request instead, up to 24 hours old. Absent on every live answer.

one of: true

metafetchedAt
stringoptional

When a stale answer (`stale: true`) was originally fetched (ISO 8601, UTC). Absent on every live answer.

Code example

curl "https://api.socialfetch.dev/v1/composites/comments?url=https://www.example.com/social/content/example123" \
  -H "x-api-key: $SOCIALFETCH_API_KEY"

Responses

A page of comments (and replies, with `includeReplies=true`), the cursor for the next call, the quote and the receipt. With `dryRun=true`, the quote only, for 0 credits.