API CodexAPI Codex
WebsiteDashboardGet API Key
  • Documentation
  • All APIs
  • Changelog
Resources
  • Docs Home
  • API Catalog
  • API Codex Website
Platform
  • Get a free API key
  • Dashboard
  • APIs & Pricing

© 2026 API Codex. All rights reserved.

Information
Other endpoints
    Scrape a Advanced X (Twitter) post by URLgetScrape an X (Twitter) profile by URL or usernamegetScrape recent posts of an X (Twitter) profile by URL or usernamegetFetch a pending scrape resultget
Schemas
powered by Zudoku
Advanced X (Twitter) API
Advanced X (Twitter) API

Other endpoints


Scrape a Advanced X (Twitter) post by URL

GET
https://api.apicodex.io/twitter
/v1/post

Returns structured JSON for a post URL. A fresh scrape usually returns in ~5-45s; if it exceeds the sync window you get a snapshot_id to fetch from /v1/result.

Scrape a Advanced X (Twitter) post by URL › query Parameters

url
​string · required

The post URL to scrape (x.com//status/...).

Example: https://x.com/elonmusk/status/1700000000000000000
fields
​string

Optional comma-separated list of top-level fields to keep in data.

Example: id,description,likes

Scrape a Advanced X (Twitter) post by URL › Responses

Scraped data.

type
​string
url
​string
​object
GET/v1/post
curl 'https://api.apicodex.io/twitter/v1/post?url=<string>&apikey=<api-key>'
Example Responses
{ "type": "post", "url": "url", "data": {} }
json
application/json

Scrape an X (Twitter) profile by URL or username

GET
https://api.apicodex.io/twitter
/v1/profile

Returns structured profile info (id, name, biography, followers, following, posts_count, is_verified, and more). Pass either url or username. A fresh scrape usually returns in ~5-45s; if it exceeds the sync window you get a snapshot_id to fetch from /v1/result.

Scrape an X (Twitter) profile by URL or username › query Parameters

url
​string

The profile URL to scrape (x.com/). Provide either url or username.

Example: https://x.com/jack
username
​string

Profile username as an alternative to url, with or without a leading @ (stripped automatically). The API builds https://x.com/.

Example: jack
fields
​string

Optional comma-separated list of top-level fields to keep in data.

Example: id,followers,biography

Scrape an X (Twitter) profile by URL or username › Responses

Scraped data.

type
​string
url
​string
​object
GET/v1/profile
curl 'https://api.apicodex.io/twitter/v1/profile?apikey=<api-key>'
Example Responses
{ "type": "profile", "url": "https://x.com/jack", "data": { "id": "12", "followers": 9803637, "biography": "no state is the best state" } }
json
application/json

Scrape recent posts of an X (Twitter) profile by URL or username

GET
https://api.apicodex.io/twitter
/v1/profile-posts

Returns the profile's most recent posts as a JSON array. Pass either url or username. A fresh scrape usually returns in ~5-45s; if it exceeds the sync window you get a snapshot_id to fetch from /v1/result.

Scrape recent posts of an X (Twitter) profile by URL or username › query Parameters

url
​string

The profile URL to scrape recent posts from (x.com/). Provide either url or username.

Example: https://x.com/elonmusk
username
​string

Profile username as an alternative to url, with or without a leading @ (stripped automatically). The API builds https://x.com/.

Example: elonmusk
limit
​integer · min: 1 · max: 50

Max number of recent posts to return (1-50).

Default: 10
fields
​string

Optional comma-separated list of top-level fields to keep on each item in data.

Example: id,description,likes

Scrape recent posts of an X (Twitter) profile by URL or username › Responses

Scraped data.

type
​string
url
​string
​object[]
GET/v1/profile-posts
curl 'https://api.apicodex.io/twitter/v1/profile-posts?apikey=<api-key>'
Example Responses
{ "type": "profile_posts", "url": "url", "data": [ {} ] }
json
application/json

Fetch a pending scrape result

GET
https://api.apicodex.io/twitter
/v1/result

Retrieve the result of a scrape that exceeded the sync window, using its snapshot_id.

Fetch a pending scrape result › query Parameters

snapshot_id
​string · required

Fetch a pending scrape result › Responses

Result ready.

status
​string
snapshot_id
​string
data
​

Scraped record. An array when the snapshot contains multiple records, otherwise a single object.

GET/v1/result
curl 'https://api.apicodex.io/twitter/v1/result?snapshot_id=<string>&apikey=<api-key>'
Example Responses
{ "status": "ready", "snapshot_id": "snapshot_id", "data": {} }
json
application/json