tx twitterxapi.com docs

API reference

Posts

Post details, direct replies, full threads, and retweeters.

GET

Post details

/v1/posts/{postId}

Get one post with its author, metrics, media, quoted post, and reposted post when present.

curl "https://twitterxapi.com/api/v1/posts/1897412345678901234?level=moderate" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET

Direct replies

/v1/posts/{postId}/replies?cursor={cursor}

Get one page of posts that reply directly to the requested post.

curl "https://twitterxapi.com/api/v1/posts/1897412345678901234/replies?level=moderate" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET

Conversation thread

/v1/posts/{postId}/thread?cursor={cursor}

Get one page from the conversation, including replies deeper than one level.

curl "https://twitterxapi.com/api/v1/posts/1897412345678901234/thread?level=moderate" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"
GET

Retweeters

/v1/posts/{postId}/retweeters?cursor={cursor}

Get one page of accounts that reposted the post.

curl "https://twitterxapi.com/api/v1/posts/1897412345678901234/retweeters?level=moderate" \
  -H "Authorization: Bearer $TWITTERXAPI_KEY"