Read Threads profiles, a user's posts and replies, a single post, its comment tree, and search Threads people as structured JSON. 6 endpoints, 2 credits by user_id and 4 by username. People search only, there is no content search.
---
name: threads-net-api
description: Read Threads profiles, a user's posts and replies, a single post, its comment tree, and search Threads people as structured JSON. 6 endpoints, 2 credits by user_id and 4 by username. People search only, there is no content search.
version: 1.0.0
tags: threads, meta-threads, social-media, creator-data, influencer-research, profiles, posts, replies, comments, people-search, brand-monitoring, sentiment, competitor-research, agents, langchain, crewai, autogen, structured-data, json, ai-agents
metadata:
openclaw:
requires:
env:
- SCAVIO_API_KEY
primaryEnv: SCAVIO_API_KEY
timeout: 120
throttle: 1
emoji: "\U0001F9F5"
homepage: https://scavio.dev/docs/threads-profile?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api
---
# Threads via Scavio
Read a Threads profile, page a user's posts and replies, fetch a single post by id or URL, walk its comment tree, and search Threads for people. All endpoints return structured JSON.
Two things to know before you start: **`user_id` costs half what a username costs**, and **Threads has no content search** — only people search.
## When to trigger
Use this skill when the user asks to:
- Look up a Threads profile and its follower/post counts
- Pull a Threads user's recent posts or their replies
- Read a single Threads post by id or by a threads.net URL
- Read the replies under a Threads post
- Find Threads accounts by name or handle
- Research a creator, brand or competitor's Threads presence
- Monitor what an account is posting on Threads
Do NOT reach for this skill to search Threads for a topic, keyword or hashtag. That capability does not exist. See Guardrails.
## Setup
Get a free API key at [scavio.dev](https://scavio.dev/?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api) (50 free credits to get started, no card required):
```bash
export SCAVIO_API_KEY=sk_live_your_key
```
### If you do not have a key yet
An agent running this skill without `SCAVIO_API_KEY` set will get `401` on every
call below. The whole path from nothing to a working key is self-serve:
1. Sign up at [dashboard.scavio.dev](https://dashboard.scavio.dev/sign-up?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api) - email or Google, no card required.
2. A key is created for the account automatically at signup. It is on the dashboard under API Keys, ready to copy.
3. A new account starts with 50 credits. Endpoints in this skill cost 1 credit each unless the table below says otherwise.
When the balance runs out the API answers `402` with a JSON body carrying
`billing_url`. Topping up needs no code change - the same key keeps working.
The smallest purchase is 2,500 credits for $25, and monthly plans work out
cheaper per credit if the usage is steady rather than one-off.
Every request is a `POST` with a JSON body and:
```
Authorization: Bearer $SCAVIO_API_KEY
```
## Endpoints
Base URL: `https://api.scavio.dev`.
| Endpoint | Credits | Description |
|---|---|---|
| `POST /api/v1/threads/profile` | 2 by `user_id`, 4 by `username` | Profile details for a Threads user |
| `POST /api/v1/threads/user/posts` | 2 by `user_id`, 4 by `username` | A user's posts, cursor-paginated |
| `POST /api/v1/threads/user/replies` | 2 by `user_id`, 4 by `username` | A user's replies, cursor-paginated |
| `POST /api/v1/threads/post` | 2 | A single post by id or threads.net URL |
| `POST /api/v1/threads/post/comments` | 2 | Replies to a post, cursor-paginated |
| `POST /api/v1/threads/search/users` | 2 | Threads profiles matching a name or handle |
### Cost rule: the handle surcharge
Cost is a function of the request body, not a constant.
- Addressed by **`user_id`: 2 credits.** This is the cheap path.
- Addressed by **`username`: 4 credits.** A handle costs double.
The reason: a handle has to be resolved to an id with a second lookup first. You pay for both.
Only `/profile`, `/user/posts` and `/user/replies` accept a username at all, so only those three can cost 4. `/post`, `/post/comments` and `/search/users` are always 2.
**Resolve once, reuse the id.** Call `/profile` or `/search/users` once with the handle, keep the `user_id`, and address everything after that by id. A 20-page crawl by handle costs 80 credits; by id it costs 40.
## Workflow
1. **Resolve the handle:** call `/threads/search/users` with the name or handle (2 credits), or `/threads/profile` with `username` (4 credits). Keep the `user_id` you get back.
2. **Profile:** call `/threads/profile` with `user_id` (2 credits).
3. **Posts and replies:** call `/threads/user/posts` and `/threads/user/replies` with `user_id`. Both return `next_cursor`; pass it back as `cursor` for the next page and stop when it is null.
4. **A single post:** call `/threads/post` with `post_id` or a threads.net `url`.
5. **Comments:** call `/threads/post/comments` with `post_id`. It is cursor-paginated the same way. Note this endpoint takes `post_id` only, never a username.
`profile`, `post` and `search/users` do not paginate. `user/posts`, `user/replies` and `post/comments` are cursor-paginated.
## Parameters
### Profile (`/profile`)
`username` or `user_id` is required.
| Parameter | Type | Default | Description |
|---|---|---|---|
| `user_id` | string | one of | Numeric id, e.g. `63625256886`. The 2-credit path |
| `username` | string | one of | Handle without the `@`, e.g. `natgeo` (1-60 chars). Costs 2 extra credits |
### User posts (`/user/posts`) and user replies (`/user/replies`)
`username` or `user_id` is required.
| Parameter | Type | Default | Description |
|---|---|---|---|
| `user_id` | string | one of | Numeric id. The 2-credit path |
| `username` | string | one of | Handle without the `@` (1-60 chars). Costs 2 extra credits |
| `cursor` | string | -- | Pagination cursor from a prior `next_cursor` |
### Post (`/post`)
`post_id` or `url` is required.
| Parameter | Type | Default | Description |
|---|---|---|---|
| `post_id` | string | one of | Post id, e.g. `3349029093483693129` |
| `url` | string | one of | A threads.net post URL |
### Post comments (`/post/comments`)
| Parameter | Type | Default | Description |
|---|---|---|---|
| `post_id` | string | required | Post id. This endpoint does NOT accept a username or a URL |
| `cursor` | string | -- | Pagination cursor from a prior `next_cursor` |
### User search (`/search/users`)
| Parameter | Type | Default | Description |
|---|---|---|---|
| `query` | string | required | Name or handle to match (1-200 chars) |
## Examples
```python
import requests
BASE = "https://api.scavio.dev"
# Your key from https://scavio.dev. Load it from your environment or secret
# store in real code - keep it out of source control.
API_KEY = "sk_your_key_here"
HEADERS = {"Authorization": f"Bearer {API_KEY}"}
# 1. Resolve the handle ONCE (2 credits), then work by id
found = requests.post(f"{BASE}/api/v1/threads/search/users", headers=HEADERS,
json={"query": "national geographic"}).json()
user_id = "63625256886" # taken from the search result, then reused
# 2. Profile by id: 2 credits. By username it would be 4.
profile = requests.post(f"{BASE}/api/v1/threads/profile", headers=HEADERS,
json={"user_id": user_id}).json()
# 3. Page their posts by id (2 credits per page)
page = requests.post(f"{BASE}/api/v1/threads/user/posts", headers=HEADERS,
json={"user_id": user_id}).json()
cursor = page["data"]["next_cursor"]
if cursor:
page2 = requests.post(f"{BASE}/api/v1/threads/user/posts", headers=HEADERS,
json={"user_id": user_id, "cursor": cursor}).json()
# 4. Their replies, same pattern
replies = requests.post(f"{BASE}/api/v1/threads/user/replies", headers=HEADERS,
json={"user_id": user_id}).json()
# 5. A single post, then its comment tree (post_id only, never a handle)
post = requests.post(f"{BASE}/api/v1/threads/post", headers=HEADERS,
json={"post_id": "3349029093483693129"}).json()
comments = requests.post(f"{BASE}/api/v1/threads/post/comments", headers=HEADERS,
json={"post_id": "3349029093483693129"}).json()
```
## Response
Every response uses the envelope `{ data, response_time, credits_used, credits_remaining }`.
- **profile** returns the user's profile details.
- **user/posts**, **user/replies** and **post/comments** return their rows plus `next_cursor`. A null `next_cursor` means there are no more pages.
- **post** returns the single post.
- **search/users** returns the matching profiles.
Read `credits_used` on the response rather than assuming a cost. It will read 4 whenever you addressed a user-keyed endpoint by handle.
## Guardrails
- **There is no Threads content search.** Searching Threads for a keyword, topic or hashtag is not possible through this API. `/search/users` is people search and nothing else. If the user asks to search Threads posts for a term, tell them plainly that Threads does not expose this, and offer the alternative of pulling a known account's posts with `/user/posts` and filtering client-side. Never imply a content search exists.
- **Prefer `user_id` over `username` everywhere.** A handle doubles the cost of `/profile`, `/user/posts` and `/user/replies`, from 2 credits to 4. Resolve the handle once and reuse the id for the rest of the session.
- Do not send `username` and `user_id` together on the same request. Conflicting identifiers are rejected with a `422`.
- `/post/comments` takes `post_id` only. It has no username form and no URL form.
- Never fabricate post text, handles, follower counts or engagement numbers. Only return data the API returned.
- Preserve author attribution when summarising a thread.
- Threads content is public posts only. Do not present it as anything more.
## Failure handling
Threads uses different error codes from the retail endpoints. **There is no `400` and no `503` here.**
- `422` means a missing or conflicting identifier: no `username` and no `user_id`, or both at once. Send exactly one.
- `404` means no matching user was found. Check the handle spelling, or resolve it through `/search/users` first.
- `401` means the API key is invalid or missing. Check `SCAVIO_API_KEY`.
- `429` means a rate or usage limit was exceeded. Wait before retrying. See [rate limits](https://scavio.dev/docs/rate-limits?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api).
- `502` means the upstream errored. Wait a few seconds and retry once.
- If a paginated call returns a null `next_cursor`, that is the end of the data, not a failure. Stop paging.
- If `SCAVIO_API_KEY` is not set, prompt the user to export it before continuing.
## Docs
- [Threads profile](https://scavio.dev/docs/threads-profile?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
- [Threads user posts](https://scavio.dev/docs/threads-user-posts?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
- [Threads user replies](https://scavio.dev/docs/threads-user-replies?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
- [Threads post](https://scavio.dev/docs/threads-post?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
- [Threads post comments](https://scavio.dev/docs/threads-post-comments?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
- [Threads user search](https://scavio.dev/docs/threads-user-search?utm_source=agent-skills&utm_medium=skill&utm_campaign=threads-net-api)
don't have the plugin yet? install it then click "run inline in claude" again.
added explicit decision points for each API error and user request type, expanded inputs section with credit billing details, broke procedure into 6 discrete numbered steps with clear input/output per step, documented edge cases like pagination termination and conflicting identifiers, and clarified output contract with JSON envelope structure and no-truncation policy.
read a Threads profile, page a user's posts and replies, fetch a single post by id or URL, walk its comment tree, and search Threads for people. all endpoints return structured JSON.
two things to know before you start: user_id costs half what a username costs, and Threads has no content search , only people search.
use this skill to look up Threads profiles, pull a user's recent posts or replies, read a single post and its reply tree, or find Threads accounts by name. the skill works best when researching creators, brands, or competitors on Threads, or monitoring what an account posts. do NOT use this to search Threads for topics, keywords, or hashtags , that capability doesn't exist. the API costs 2 credits per request if you use user_id, or 4 credits if you use a username (because the handle must be resolved to an id first). resolve once, reuse the id.
external connection: Scavio Threads API
https://api.scavio.devAuthorization headerSCAVIO_API_KEY (required, string). get a free API key at dashboard.scavio.dev, no card required. new accounts start with 50 credits. if SCAVIO_API_KEY is not set, all requests will return 401.credit costs by endpoint:
| endpoint | cost by id | cost by handle |
|---|---|---|
/profile |
2 | 4 |
/user/posts |
2 | 4 |
/user/replies |
2 | 4 |
/post |
2 | (no handle form) |
/post/comments |
2 | (no handle form) |
/search/users |
2 | (no handle form) |
account credit billing:
402 with a billing_url in the JSON body.input: a Threads username or handle provided by the user (e.g. "natgeo").
action: call POST /api/v1/threads/search/users with the query parameter, or call POST /api/v1/threads/profile with the username directly. either way costs 2 credits (search) or 4 credits (profile by handle).
output: extract user_id from the response. example: "63625256886". keep this id for all subsequent requests.
note on reuse: once you have the id, use it everywhere else. a 20-page crawl by username costs 80 credits; by id it costs 40.
input: user_id from step 1.
action: call POST /api/v1/threads/profile with {"user_id": "<id>"}.
output: structured JSON with profile details (follower count, post count, bio, verification status, etc.). returns { data, response_time, credits_used, credits_remaining }.
input: user_id from step 1, and optionally a cursor for pagination.
action: call POST /api/v1/threads/user/posts with {"user_id": "<id>"} for the first page. the response includes data.next_cursor. if next_cursor is not null, pass it back as {"user_id": "<id>", "cursor": "<next_cursor>"} to fetch the next page.
output: a page of posts (default 10-25 per page, server-determined). each post has id, text, timestamp, engagement counts, etc. when next_cursor is null, there are no more pages.
pagination stop: when next_cursor is null, stop paging. this is the end of the data, not a failure.
input: user_id from step 1, and optionally a cursor for pagination.
action: call POST /api/v1/threads/user/replies with {"user_id": "<id>"} for the first page. handle pagination the same way as step 3: check next_cursor, pass it back if present.
output: a page of posts where the user is replying to someone else. same structure as posts.
input: either a post_id (e.g. "3349029093483693129") or a threads.net URL (e.g. "https://www.threads.net/@natgeo/p/C123...").
action: call POST /api/v1/threads/post with {"post_id": "<id>"} or {"url": "<threads-url>"}. do not send both.
output: a single post object with text, author, timestamps, engagement, and reply count.
input: post_id only. this endpoint does NOT accept a username or a URL.
action: call POST /api/v1/threads/post/comments with {"post_id": "<id>"} for the first page. handle pagination with cursor the same way as steps 3 and 4.
output: a page of replies to the post. each reply is a post object. when next_cursor is null, there are no more replies.
if the user provides a username but not a user_id:
resolve it first with /search/users (2 credits) or /profile by username (4 credits). extract user_id and use it for all subsequent requests in that session. do not call endpoints with username on every request; that balloons the cost.
if the user asks to search Threads for a topic, keyword, or hashtag:
this is not supported. the API has no content search. tell the user plainly: "Threads doesn't expose content search through this API. you can pull a known account's posts with /user/posts and filter them client-side, or look up a specific post if you have a URL." never imply content search exists.
if the response includes both user_id and username in the request body:
this is a conflict. the API will reject it with 422. send exactly one identifier per request.
if /post/comments is called with a username or URL:
the endpoint does not accept them. it takes post_id only. if the user has a URL, resolve it to post_id with /post first, then pass the id to /post/comments.
if the API returns 401:
the API key is missing or invalid. check that SCAVIO_API_KEY is exported to the environment. if it is not set, prompt the user to run export SCAVIO_API_KEY=sk_your_key before continuing.
if the API returns 402:
the account has run out of credits. the response body includes a billing_url. direct the user there to top up. no code change is needed; the same key will work again once credits are added.
if the API returns 404:
no matching user was found. check the handle spelling. if unsure, use /search/users with a partial name to find the right handle.
if the API returns 422:
the request is missing an identifier (no user_id and no username), or it has both. send exactly one.
if the API returns 429:
a rate or usage limit was exceeded. wait a few seconds (or consult the rate limits docs) and retry. do not spam retries.
if the API returns 502:
the upstream service errored. wait 2-5 seconds and retry once. if it persists, the outage may be temporary; ask the user to try again later.
if a paginated endpoint returns next_cursor: null:
this is not an error. there is no more data to fetch. stop paging and return what you have.
if credits_used on the response is higher than expected:
this usually means you used a username instead of a user_id. read credits_used from the actual response rather than assuming the cost based on the endpoint name.
all responses follow the envelope:
{
"data": { /* endpoint-specific content */ },
"response_time": "123ms",
"credits_used": 2,
"credits_remaining": 48
}
profile (/profile): data contains the user's profile object (username, display name, follower count, following count, post count, bio, verification status, profile image URL, etc.).
user/posts and user/replies (/user/posts, /user/replies): data contains an array of post objects, plus next_cursor (string or null). each post has id, text, timestamp, author info, like count, reply count, etc. if next_cursor is not null, use it in the next request to get the next page.
post (/post): data contains a single post object (same structure as above).
post/comments (/post/comments): data contains an array of reply objects (posts) and a next_cursor, same as user/posts.
search/users (/search/users): data contains an array of matching user profiles (name, handle, follower count, verification status, etc.).
all JSON is valid UTF-8, structured, and machine-parseable. never truncate or summarise the JSON in the output. return the full response envelope as the API sent it.
file location: no files are written by this skill. all data is returned in memory as JSON.
the user knows the skill worked when:
credits_remaining is greater than zero and has decreased by the expected amount (credits_used matches the endpoint cost).next_cursor is either a non-empty string (more data available) or null (end of data).on failure, the user will see: