X / Twitter Твит API
Полные данные об одном твите по URL: текст, id автора и показатели вовлечённости (лайки, ретвиты, ответы, цитаты, закладки, просмотры).
0,21 USD/1 тыс. запросов, оплата за запрос, без подписки.
Post
NASA
@NASA
Liftoff! 🚀
1:45 PM · Jun 9, 2024 · 9.4M Views
{"id": "1800000000000000000","text": "Liftoff! 🚀","authorId": "11348282","likes": 142000,"retweets": 21400,"replies": 3900,"quotes": 1200,"bookmarks": 8600,... ещё полей: 10}
Цены и поставщики
Цена API X / Twitter Твит: один API, поставщиков 5, и любой может заменить другого
Первым обслуживает самый дешёвый поставщик. Если он не отвечает, его заменяет следующий в том же вызове.
Попробовать
Получите X / Twitter Твит одним запросом
В этом примере показано полей: 12 из 26. Все поля
{
"found": true,
"data": {
"id": "1800000000000000000",
"text": "Liftoff! 🚀",
"authorId": "11348282",
"likes": 142000,
"retweets": 21400,
"replies": 3900,
"quotes": 1200,
"bookmarks": 8600,
"views": 9400000,
"createdUtc": 1717940700
}
}Полный справочник по параметрам и ответу: каждое поле, тип и пример для этого эндпоинта.
Справочник
Один запрос, один формат ответа.
Каждое поле, которое вы отправляете, и каждое поле, которое получаете, с реальным примером.
Проверено 2026-11-21 · доступность и задержка измерены за 30d
Тело запроса
JSON, отправляется на этот эндпоинт.
- urlstring
https://x.com/NASA/status/1800000000000000000
Канонический URL статуса на x.com или twitter.com с числовым ID твита, включая варианты /i/web/status и ссылки на медиа.
- requireFieldsarray
Optional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example `videoUrl` or `width`, and it is served only by a source that returns every one of them. Fields you do not name are still returned whenever the serving source has them. This can raise your price: when the cheapest source cannot return a named field, a dearer source serves, and you are quoted and charged its price. A named field can still be absent on a tweet that genuinely lacks it. Naming a combination that no single source returns together is refused as invalid input, with no charge.
Ответ
JSON, по одному примеру значения на поле.
- authorHandlestring
Handle of the account that posted.
- authorIdstring
11348282
Populated whenever the provider has data for the entity.
- authorImagestring
Avatar image URL of the account that posted.
- authorNamestring
Display name of the account that posted.
- authorVerifiedboolean
Whether the posting account carries an X blue verification badge.
- bookmarksinteger
8600
- conversationIdstring
Id of the conversation the post belongs to, as a string.
- createdUtcnumber
1717940700
UTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds. Populated whenever the provider has data for the entity.
- idstring
1800000000000000000
Populated whenever the provider has data for the entity.
- inReplyToIdstring
Id of the post this post directly replies to, as a string, or null when the post is not a reply.
- langstring
Two-letter language code X detected for the post.
- likesinteger
142000
- quotesinteger
1200
- repliesinteger
3900
- retweetsinteger
21400
- textstring
Liftoff! 🚀
Populated whenever the provider has data for the entity.
- viewsinteger
9400000
View count, or null when X does not report one for this tweet. Distinct from 0, which means the tweet has no views.
Photo, video, and GIF attachments on the post. Empty when the post has none.
- heightintegerможет потребовать
Pixel height of the media item, when the lane reports it.
- typestring
One of photo, video, or gif.
- urlstring
Image URL. For a video or GIF this is the poster/thumbnail frame. X media URLs on pbs.twimg.com are publicly fetchable without authentication; append ?name=orig for the full-resolution original.
- videoUrlstringможет потребовать
Playable video file URL. Present only for video and gif items.
- widthintegerможет потребовать
Pixel width of the media item, when the lane reports it.
- foundboolean
true
- reason"not_found"
Present only when `found` is false, and says why there is no result. `not_found`: the source states the target does not exist, or returned nothing for it. A `found: false` answer is a successful call, not an error, and `costUsd` is what it actually cost.
Продаёте этот API? Полная схема, которую должен возвращать ваш эндпоинт.
Вопросы и ответы
Об API X / Twitter Твит
AnyAPI X / Twitter Твит API возвращает данные X / Twitter в виде нормализованного JSON одним вызовом POST к /v1/run/twitter.tweet. Полные данные об одном твите по URL: текст, id автора и показатели вовлечённости (лайки, ретвиты, ответы, цитаты, закладки, просмотры). AnyAPI направляет каждый запрос по источникам (их 5) и автоматически переключается, если один из них отказывает. Это стоит от 0,21 USD за 1000 запросов, в долларах США, без подписки и без ежемесячного минимума. За последние 30 дней 100,0% вызовов X / Twitter Твит через AnyAPI завершились успешно, медианное время ответа 1,3 с, измерено вызовов: 585 407.