Social data (beta)

GET /v1/social/{platform}/{capability} returns public data from Douyin, Xiaohongshu, TikTok, YouTube and other social platforms, with the same API key and balance as your model calls. Each platform and capability is priced per successful call, and data is the platform's own response — fields are not normalized across platforms.

GET /v1/social/{platform}/{capability}
curl --get "https://api.chinaapi.ai/v1/social/tiktok/search" \
  -H "Authorization: Bearer $CHINAAPI_KEY" \
  --data-urlencode 'keyword=TikTok'

# HTTP 200
# {"object": "social.result", "platform": "tiktok", "capability": "search", "data": {...}}
Beta: paid accounts only Complete your first top-up before calling. Trial credit cannot be spent on these endpoints; an account that has never topped up gets HTTP 403 model_requires_topup. The beta has no SLA, and its platforms, endpoints and prices may change.

Authentication and billing

Send your ChinaAPI key as a bearer token to https://api.chinaapi.ai, as for any model call. A call is charged once, at the price listed for its endpoint, only when it returns HTTP 200 with data; an empty result, a rejected parameter or a failed upstream costs nothing. Every page you fetch is a separate call. Your usage log lists each call under the name shown with its endpoint, such as social-douyin-search.

Responses and errors

A successful response wraps the platform's data in a small envelope. Everything inside data — field names, pagination cursors, IDs — is the platform's own; pass cursors back exactly as you received them.

{
  "object": "social.result",
  "platform": "douyin",
  "capability": "search",
  "data": { "...": "the platform's own fields" }
}
  • 400 — a parameter is unknown, repeated, too long, of the wrong type or missing, including when no member of an "at least one of" group is given. The error code says which, such as unknown_parameter or missing_parameter.
  • 403 model_requires_topup — the account has not completed its first top-up.
  • 404 — the platform and capability pair does not exist, or the platform found nothing for these parameters (social_data_no_result).
  • 429 social_data_capacity_reached — the beta's capacity for the day is used up and resets at 00:00 UTC, or the platform is busy and a retry a few seconds later will do. Do not retry in a tight loop.
  • 502 — the data source did not answer, or answered without data.
  • 503 social_data_unavailable — this endpoint is paused right now; the live catalog lists it as paused.

None of these responses is charged.

Acceptable use

Follow each platform's terms and the data-protection rules that apply to you. Do not use this API to build profiles of individuals. Logging in, extracting contact details, manipulating engagement and reaching private or paid content are outside this beta.

Platforms and prices

USD per successful call. Each price links to its endpoint below, and a dash means the platform does not offer that capability. The live catalog — GET https://dash.chinaapi.ai/api/social/catalog, no key needed — is the authority on what is on sale right now, including any endpoint that is paused.

Endpoints

Parameters go in the query string under the platform's own names. Examples come from the catalog; replace identifiers with the content you want to retrieve.