> ## Documentation Index
> Fetch the complete documentation index at: https://docs.spidra.io/llms.txt
> Use this file to discover all available pages before exploring further.

# X (Twitter)

> Get X profiles with their recent posts, single posts with replies and media, highlights and communities as structured data, for 1 credit per link.

Send an X (or Twitter) link to [Scrape](https://docs.spidra.io/scrape.md) or [Batch scrape](https://docs.spidra.io/batch-scrape.md) and you get the data X shows signed-out visitors, as JSON: a profile with its posts, or a single post with its metrics, media and replies. Each link costs 1 credit, and links that can't be read cost nothing.

## Example

```json theme={null}
{ "urls": ["https://x.com/NASA"], "output": "json", "wait": true }
```

The item's `result`, shortened:

```json theme={null}
{
  "type": "profile",
  "handle": "NASA",
  "name": "NASA",
  "location": "Pale Blue Dot",
  "website": "http://www.nasa.gov/",
  "joinedAt": "2007-12-19T20:20:32.000Z",
  "followers": 92311944,
  "following": 115,
  "postsCount": 74455,
  "verified": true,
  "postsOrder": "latest",
  "postCount": 39,
  "posts": [
    {
      "id": "2114130258912043194",
      "text": "RT @NASAAdmin: Roll Tide and full throttle! ...",
      "createdAt": "2026-10-24T23:01:47.000Z",
      "replyCount": 0,
      "repostCount": 161,
      "viewCount": 39045
    }
  ],
  "nextCursor": "DAAHCgABHVcmOoF__9gLAAIAAAATMjEwODYzNDk0NDI1NTc0MjE3MwgAAwAAAAIAAA"
}
```

## Links that work

| Link | Example | You get |
| - | - | - |
| Post | `x.com/<user>/status/<id>` (also `/photo/1`, `/video/1`, `/i/status/<id>`, `twitter.com`, `mobile.`, `fxtwitter`, `vxtwitter`) | The post, its metrics and media, the thread before it and the top replies X shows visitors |
| Profile | `x.com/<user>` | The profile and its posts (see below) |
| Highlights | `x.com/<user>/highlights` | The account's highlighted posts |
| Community | `x.com/i/communities/<id>` | The community and its top posts |

## Fields

**Profile:** `id`, `handle`, `name`, `description`, `bioEmail`, `bioLinks`, `location`, `website`, `joinedAt`, `birthdate`, `followers`, `following`, `postsCount`, `likesCount`, `mediaCount`, `listedCount`, `verified`, `isBlueVerified`, `verifiedType`, `affiliation`, `protected`, `avatar`, `banner`, `pinnedPost`, `posts`, `postCount`, `postsOrder`, `postsNote` and `nextCursor`.

**Post:** `id`, `url`, `text` (long posts in full), `lang`, `createdAt`, `author`, `replyCount`, `repostCount`, `quoteCount`, `likeCount`, `bookmarkCount`, `viewCount`, `isReply`, `replyTo`, `isQuote`, `quotedPost`, `isRepost`, `repostedPost`, `media` (full-size photos, and every video and GIF variant with its bitrate), `links`, `hashtags`, `mentions`, `card`, `poll`, `communityNote`, `article` (X Articles in full), `isEdited`, `possiblySensitive`. A single post also has `thread` (the earlier posts) and `replies`.

## A profile's posts

X shows signed-out visitors one of two things, and `postsOrder` says which:

* `"latest"`: the latest posts, newest first, about 40 at a time, with `nextCursor`. Add `?cursor=<nextCursor>` to the profile link for the next batch.
* X's own selection of about 100 popular posts, with no cursor. This happens for many well-known accounts.

## Limits

Only what X shows signed-out visitors. Search, hashtags, followers, following, likes, lists, and the media and replies tabs need a sign-in, so those links fail straight away and cost nothing. A deleted post or a wrong link fails with "X has no post at this link" and costs nothing. Your cookies are never sent to X.

## Templates

Ready-made [templates](https://docs.spidra.io/templates.md) for X: profile stats, recent posts and post metrics.

> [!NOTE]
>
> Check X's terms before you collect data from it. You're responsible for how you use what you collect.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.