Temporarily unavailable

We are restoring this capability. Until then calls usually fail or return no results; failed calls and empty results are not charged.

POST

API health

24h health
Temporarily unavailable
  • Healthy / normal
  • Available
  • Limited
  • Mostly down
Temporarily unavailable

Last 24 hours

Last 30 days

Work out a Threads account's engagement from its latest posts, from username. posts sets how many to use, 3 to 50 (default 20). Only posts the account wrote count: replies and reposts are left out, pinned posts are in. You get average and median likes and interactions, average replies, reposts, quotes and shares, engagement_rate in percent, posts_per_week, posts by UTC hour and weekday, the post-type mix and the top 3 posts. It returns one object, not a list.

Send POST https://api.everyinfra.com/api/v1/social with platform set to threads and action set to engagement. Price $0.56 per 1,000 requests ($0.000556 per call). Failed calls and empty results are not charged. Synchronous. For slow jobs add "mode": "async" to the body, take the job_id and poll.

AI prompt

#
Please help me write a data collection script with the EveryInfra Threads Engagement statistics endpoint (threads/engagement).

How the endpoint works:
- Request: POST https://api.everyinfra.com/api/v1/social with the header Authorization: Bearer <API key>. Read the key from the EVERYINFRA_API_KEY environment variable and never hard-code it.
- In the request body, set platform to threads and action to engagement, and put the parameters inside params.
- Required parameters:
  - username: Specifies the Threads handle (with or without @) for profile, user_posts, followers, user_replies, user_media, user_reposts, followers_list, following_list and engagement.
- Optional parameters:
  - posts: How many of the account's latest posts engagement uses: an integer from 3 to 50, default 20.
- Returns one object. Main fields: username, display_name, url, follower_count, is_verified, sample_size (engagement: how many posts went into th…), period_start (engagement: publish time (UTC) of the e…), period_end (engagement: publish time (UTC) of the l…), posts_per_week (engagement: average number of posts per…), avg_like_count (engagement: average likes per post), avg_comment_count (engagement: average replies per post), avg_repost_count (engagement: average reposts per post); 23 fields in total, full list at https://api.everyinfra.com/api/v1/social/catalog?platform=threads.
- Example request body:
{
  "platform": "threads",
  "action": "engagement",
  "params": {
    "username": "zuck"
  }
}
- Price: $0.56 per 1,000 requests; failed and empty results are not charged.
- For dozens or hundreds of targets, add "mode": "async" to the body: you get a job_id at once and poll GET https://api.everyinfra.com/api/v1/jobs/{job_id} for the result.
- On 422, fix the request using the suggested parameter names and allowed values in the error; on 429 or 503, wait for Retry-After and try again.

Before writing code, ask me which targets I need, how many, which fields, and what output format I want; then confirm the plan and the rough cost with me.

Request parameters

#
NameInTypeRequiredDefaultDescription
AuthorizationheaderstringYes-Bearer followed by your API key. Create it in the console; never put it in a URL or a code repository.
platformbodystringYesthreadsPlatform identifier, fixed value.
actionbodystringYesengagementCapability identifier, fixed value.
usernamebody.paramsstringYes-Specifies the Threads handle (with or without @) for profile, user_posts, followers, user_replies, user_media, user_reposts, followers_list, following_list and engagement. The profile and user_posts actions do not accept full profile URLs; user_replies, user_media, user_reposts, followers_list, following_list and engagement also accept a profile link such as https://www.threads.com/@mosseri. The followers action returns aggregate follower counts; use followers_list and following_list for the accounts themselves.
postsbody.paramsintegerNo-How many of the account's latest posts engagement uses: an integer from 3 to 50, default 20.

Code samples

#
bash
curl -X POST 'https://api.everyinfra.com/api/v1/social' \
  -H "Authorization: Bearer $EVERYINFRA_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "platform": "threads",
  "action": "engagement",
  "params": {
    "username": "zuck"
  }
}'

OpenAPI definition (JSON)Samples read the key from the EVERYINFRA_API_KEY environment variable; copied code never contains your key.

Response example

#
No sample response is available for these parameters yet. This preview shows the response shape and fields from the API definition, with … as placeholders; it is not the result of a live call.
json
{  "id": "req_…",  "platform": "threads",  "action": "engagement",  "results": {    "username": …,    "display_name": …,    "url": …,    "follower_count": …,    "is_verified": …,    "sample_size": …,    "period_start": …,    "period_end": …,    "posts_per_week": …,    "avg_like_count": …,    "avg_comment_count": …,    "avg_repost_count": …,    "avg_quote_count": …,    "avg_share_count": …,    "median_like_count": …,    "avg_interactions": …,    "median_interactions": …,    "engagement_rate": …,    "platform": …,    "posts_by_hour_utc": …,    "top_hours_utc": …,    "posts_by_weekday_utc": …,    "media_mix": …,    "top_posts": …  },  "billing": {    "charged": …,    "charged_usd": …,    "balance_after_usd": …,    …  },  "quota": { … }}

Response fields

#

Business data is in results. The table lists the fields a record can contain; values the platform does not show are never made up.

FieldMeaning
usernameUsername (@handle).
display_nameDisplay name; can differ from username.
urlLink to the record on the platform.
follower_countFollowers. null means not disclosed, not 0.
is_verifiedWhether the platform verified the account. null means it cannot be determined.
sample_sizeengagement: how many posts went into the calculation. Only posts the account wrote count: replies and reposts are left out, pinned posts are in.
period_startengagement: publish time (UTC) of the earliest post that went into the calculation.
period_endengagement: publish time (UTC) of the latest post that went into the calculation.
posts_per_weekengagement: average number of posts per week over this period.
avg_like_countengagement: average likes per post.
avg_comment_countengagement: average replies per post.
avg_repost_countengagement: average reposts per post.
avg_quote_countengagement: average quotes per post.
avg_share_countengagement: average shares per post.
median_like_countengagement: median likes per post.
avg_interactionsengagement: average interactions per post; interactions are likes, replies, reposts, quotes and shares added together.
median_interactionsengagement: median interactions per post.
engagement_rateengagement: engagement rate in percent: avg_interactions ÷ follower_count × 100. 0.17 means 0.17%.
platformSource platform identifier, the same as platform in the request (for example xiaohongshu, tiktok).
posts_by_hour_utcengagement: posts per UTC hour, 24 numbers; the first is hour 0.
top_hours_utcengagement: the hours (UTC, 0 to 23) with the most posts, most first.
posts_by_weekday_utcengagement: posts per weekday (UTC), 7 numbers, Sunday first.
media_mixengagement: how many posts of each kind: text (text only), image (one image), video, and carousel (several images, or images and videos mixed).
top_postsengagement: the posts with the most interactions (up to 3), each with url, text, posted_at, interactions, like_count, comment_count, repost_count, quote_count and share_count.

Errors and billing

#
401
Missing or invalid key.
402
Insufficient balance. Top up first.
422
Invalid parameter name or value. Fix it using the suggestions in the error. No charge.
429
Per-minute request limit reached. Wait for Retry-After, then try again.
503
Could not complete. The held charge is returned to your balance. If the outcome is unknown, verify it before you retry.
200 empty
No data. No charge.

Errors

Google Analytics needs consent. Privacy