X scraping tutorials
How to get X data with code: 11 endpoints in Python, JavaScript, TypeScript, Go, PHP and cURL, each with a real sample response, parameters, pagination and pricing.
- X (Twitter) tweet
One post (tweet) with its author, metrics incl. views, media, quoted post and top replies.
- X (Twitter) user profile
A public X profile: bio, follower and post counts, verification, pinned post.
- X (Twitter) user tweets
The latest posts of an X account, newest first (about 20).
- X (Twitter) user tweets, next page (beta)
The next page of an X account’s posts, from a next_token (beta).
- X (Twitter) video transcript
The transcript of the video in an X post, from the captions X serves with it.
- X (Twitter) Communities
An X community: name, description, members, rules, creator.
- X (Twitter) Community posts
The top or media posts of an X community (one page).
- X (Twitter) user search
X accounts matching a name, handle or keyword, paginated.
- X (Twitter) profile analytics
An X profile with its latest posts and engagement stats computed from them.
- X (Twitter) highlights
The posts an X account highlights on its profile, paginated.
- X (Twitter) trending posts
The posts trending on X today.
X API: every endpoint and its price.