# TwitterViewer API: X Data for AI Agents

TwitterViewer API for public X data: convert post, thread and profile links and read replies as Markdown or JSON. No X developer account. 1 credit per post.

Page: https://twitterviewer.ai/twitterviewer-api

Your program sends a link and receives posts, threads, profiles or replies in JSON or Markdown. Nothing to request from X, and billing follows the post count.

TwitterViewer AI is an independent service. It is not X's official API and is not affiliated with X Corp. It reads public posts only: it cannot post, like, follow, send messages or read private accounts.

## Endpoints

| Method | Path | What it does |
| --- | --- | --- |
| POST | /api/v1/convert | A single post, the thread or recent posts from a profile as Markdown, Obsidian, text, JSON or PDF |
| GET | /api/v1/replies | Public replies to a post |
| GET | /{handle}/status/{id} | URL swap: the same link as on X, Markdown back when you send a key |
| GET | /api/v1/credits | Your balance by source: plan credits and purchased credits |
| MCP | /mcp | convert_x_url, get_x_replies, get_credits for Claude, Cursor and Codex |

## Example

```bash
curl https://twitterviewer.ai/api/v1/convert \
  -H "Authorization: Bearer $TWITTERVIEWER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://x.com/username/status/1234567890123456789",
    "scope": "thread",
    "format": "markdown"
  }'
```

```json
{
  "kind": "thread",
  "title": "How we shipped the new release:",
  "sourceUrl": "https://x.com/username/status/1234567890123456789",
  "author": { "handle": "username", "name": "Example", "followers": 1204 },
  "postsReturned": 31,
  "wordCount": 2214,
  "markdown": "# How we shipped…\n\nThread by @username…",
  "text": "…",
  "posts": [ { "id": "1234567890123456789", "text": "…" }, … ],
  "replies": [],
  "credits": { "charged": 31, "remaining": 2969 }
}
```

## Pricing

API, MCP and CLI come with Plus, from $5 a month billed yearly · 1 credit = 1 post.

- API, MCP and CLI access is part of Plus: 30 requests a minute and 2 API keys per account, 3,000 credits a month (yearly plans get 12 months of credits at once). The 50 sign-up credits of a free account work on website conversions only. A free account calling the API or MCP gets 402 LIMIT_REACHED with details.reason PLUS_REQUIRED.
- Plus: $10 monthly or $60 yearly, 3,000 credits a month.

## What can you build with the TwitterViewer API?

The TwitterViewer API lets programs and AI agents read public X content over HTTPS with a single Bearer key. Send it an address to convert, or request the answers to one post. Output arrives as JSON or Markdown. A Plus subscription here is the only requirement; X asks nothing of you.

TwitterViewer AI runs it independently of X Corp. It is a reading layer beside X's own products, so anything that writes to an account happens there.

## How to send your first request

1. **Subscribe** — Get Plus and make a key beginning tv_live_ on the account page. Copy it right away because it is displayed once.
2. **Convert a link** — Call `/api/v1/convert` with a url parameter, by GET or by POST with a JSON body.
3. **Choose the body** — Responses are JSON unless you set format. Send `Accept: text/markdown` to receive the document alone.
4. **Watch the meter** — Read x-credits-charged, x-credits-remaining and x-ratelimit-remaining from the response headers.

## Endpoints

- **/api/v1/convert**: A thread, one post, a conversation or up to 200 profile posts
- **/api/v1/replies**: Replies under one post, 20 by default and 100 at most
- **/api/v1/credits**: Total balance and its sources, at no cost
- **Domain swap**: A post or profile path on twitterviewer.ai, returned as Markdown

## How it works

- **Billing follows results** — A returned post costs one credit and a quoted post one more. Repeating a convert or reply call with unchanged parameters inside 10 minutes returns the same result for free. See [Pricing](https://twitterviewer.ai/pricing) for plan allowances.
- **Limits belong to accounts** — Plus gives each account 30 requests a minute and two keys. Excess calls receive status 429 with retryAfterSec. An empty balance returns status 402 before anything is requested from X.
- **Formats cover common needs** — Convert supports json, markdown, obsidian, text and pdf. Profile exports skip replies and reposts until you enable them. Browser printing is covered by [Twitter Thread to PDF](https://twitterviewer.ai/twitter-thread-to-pdf).

## API limits

- Create, like, repost or delete anything on X
- Expose locked accounts, private chats or removed posts
- Find posts by keyword, because each call starts from a link or handle

## FAQs

### Does X Corp run this API?

No, this API belongs to TwitterViewer AI, an independent service that is not affiliated with X Corp. Its calls never change anything and reach public material only.

### Which links can the TwitterViewer API read?

The TwitterViewer API accepts the address of a post or an account on either X domain, or a plain @handle. A post link can return that post alone, the author's thread or the thread with its first page of replies. Reply lists take a post link and stop at 100 entries.

### How does the domain swap work?

Keep the path, change the host to this site, and sign the request with your key. The Accept header must not ask for HTML. A browser opening that address sees an ordinary web page. The [Twitter Thread Reader](https://twitterviewer.ai/twitter-thread-reader) is the comfortable choice for people.

### What if my balance cannot cover a result?

A reply list is shortened to what your credits can pay for. A thread that costs more than the balance is refused with 402, and nothing is deducted.

### Can agents use it without writing HTTP code?

Yes, connect the [TwitterViewer MCP Server](https://twitterviewer.ai/twitterviewer-mcp-server) or run the command-line tool for conversions. For a manual look at the same output, try [X to Markdown](https://twitterviewer.ai/x-to-markdown). Full parameters are in the [API Docs](https://twitterviewer.ai/docs/api).

