x.com APIx.com ↗
Fetch posts, engagement metrics, and profile data from any public X (Twitter) account. Two endpoints cover user timelines and profile details.
curl -X GET 'https://api.parse.bot/scraper/a5441c3e-48bc-4f1b-8b42-8fccc7e99d45/get_user_posts?limit=5&username=elonmusk' \ -H 'X-API-Key: $PARSE_API_KEY'
Get recent posts from a specific X/Twitter user's timeline. Returns post text, engagement metrics, media, quoted tweets, and pagination cursor. Supports filtering retweets.
| Param | Type | Description |
|---|---|---|
| limit | integer | Maximum number of posts to return |
| cursor | string | Pagination cursor from a previous response's next_cursor field |
| username | string | X/Twitter username (without @) |
| include_retweets | string | Whether to include retweets: "true" or "false" |
{
"type": "object",
"fields": {
"count": "integer - number of posts returned",
"posts": "array of post objects with id, text, created_at, engagement metrics, user, media, urls, quoted_tweet",
"username": "string - the requested username",
"next_cursor": "string or null - pagination cursor for the next page"
},
"sample": {
"data": {
"count": 1,
"posts": [
{
"id": "2053824997777457651",
"url": "https://x.com/OpenAI/status/2053824997777457651",
"text": "Today we’re launching the OpenAI Deployment Company to help businesses build and deploy AI.",
"urls": null,
"user": {
"id": "4398626122",
"name": "OpenAI",
"verified": false,
"screen_name": "OpenAI",
"followers_count": 4853752,
"is_blue_verified": true,
"profile_image_url": "https://pbs.twimg.com/profile_images/1885410181409820672/ztsaR0JW_normal.jpg"
},
"media": null,
"language": "en",
"is_pinned": true,
"created_at": "Mon May 11 13:10:12 +0000 2026",
"is_retweet": false,
"view_count": 7776021,
"quote_count": 1045,
"reply_count": 667,
"quoted_tweet": null,
"retweet_count": 1526,
"bookmark_count": 6119,
"favorite_count": 11366,
"conversation_id": "2053824997777457651",
"in_reply_to_status_id": null
}
],
"username": "OpenAI",
"next_cursor": "DAAHCgABHITAMVr___cLAAIAAAATMjA1MjQ4MDIwMzE3MjI3NDU5MwgAAwAAAAIAAA"
},
"status": "success"
}
}About the x.com API
The X.com API provides two endpoints — get_user_posts and get_user_profile — for pulling live data from any public X (Twitter) account. get_user_posts returns up to paginated batches of posts with 10+ fields including post text, engagement metrics, media attachments, quoted tweets, and a cursor for pagination. get_user_profile returns account-level data like follower counts, bio, verification status, and account creation date.
Endpoints
The API covers two resources: user timelines and user profiles. get_user_posts accepts a username (without the @ symbol), an optional limit, an optional include_retweets flag ("true" or "false"), and a cursor string for paginating through older posts. Each post object includes id, text, created_at, engagement metrics, media, urls, and a quoted_tweet object when applicable. The next_cursor field in each response can be passed back in subsequent requests to walk through a timeline.
Profile Data
get_user_profile accepts a username and returns a single object with the account's numeric id, display name, screen_name, description (bio), location, created_at date, media_count, verified boolean (legacy blue-check status), url (the user's linked website in t.co form), and a profile_url pointing to the account on x.com.
Scope and Limitations
Both endpoints operate on public accounts only. Search by keyword or hashtag is not available — you must supply a specific username. Retweet filtering through include_retweets lets you strip retweets from timeline results if you only want original posts. Engagement metrics are point-in-time snapshots reflecting the state at the moment of the request.
- Monitor a brand's posting frequency and engagement metrics from their X timeline
- Aggregate follower counts and bio data for a list of influencer accounts
- Filter a user's timeline to original posts only using include_retweets=false
- Build a competitor analysis feed by polling multiple public account timelines
- Track media attachments posted by a specific account over time
- Pull account creation date and verification status for identity research
- Paginate through a user's full post history using the next_cursor field
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does X (Twitter) have an official developer API?+
What does get_user_posts return for each post?+
id, text, created_at timestamp, engagement metrics (likes, reposts, replies, views), media attachments, resolved urls, a user sub-object, and a quoted_tweet object when the post quotes another. The next_cursor field at the response level lets you fetch the next page.Can I search posts by keyword or hashtag?+
username and does not support keyword or hashtag search. You can fork this API on Parse and revise it to add a search endpoint targeting public search results.Does the API return data from private or protected accounts?+
Is direct message or notification data available?+
get_user_posts) and public profile metadata (get_user_profile). DMs, notifications, and bookmarks require authenticated user-level access. You can fork this API on Parse and revise it to add endpoints that handle authenticated access if your use case requires it.