获取推文
按推文 ID 取单条详情(文本、作者、互动数据、引用/转推嵌套等)。
单条
GET /twitter/tweets/{id}
路径参数
| 参数 | 说明 |
|---|---|
id | 推文数字 ID;JS 请用字符串 |
请求示例
bash
curl "https://twidata.wvovw.com/twitter/tweets/1740192018918170738" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json"成功响应(节选)
json
{
"tweet_created_at": "2022-07-19T06:35:54+00:00",
"id_str": "1549281861687451648",
"full_text": "100 tips I learned growing an iOS app...",
"truncated": false,
"user": {
"id_str": "15118774",
"screen_name": "jakemor",
"name": "Jake Mor"
},
"is_quote_status": false,
"quoted_status": null,
"retweeted_status": null,
"quote_count": 73,
"reply_count": 105,
"retweet_count": 492,
"favorite_count": 9419,
"bookmark_count": 4614,
"views_count": null,
"lang": "en",
"entities": {
"user_mentions": [],
"urls": [],
"hashtags": []
}
}计费
成功返回 1 条 ≈ 1 点。
错误码
| HTTP | 含义 |
|---|---|
| 200 | 成功 |
| 402 | 余额不足 |
| 403 | 因作者隐私等不可用(如 Tweet not available) |
| 404 | 推文不存在 |
| 422 | 参数错误 |
| 500 | 上游失败 |
批量按 ID
POST /twitter/tweets-by-ids
单次最多约 100 个 ID。
bash
curl -X POST "https://twidata.wvovw.com/twitter/tweets-by-ids" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"ids":["1740192018918170738","1549281861687451648"]}'计费按成功返回条数。
评论 / 引用 / 转推用户 / 串帖
| 方法 | 路径 | 说明 | 计费 |
|---|---|---|---|
| GET | /twitter/tweets/{id}/comments | 评论列表,支持 cursor | 按返回评论数 |
| GET | /twitter/tweets/{id}/quotes | 引用推文列表 | 按返回条数 |
| GET | /twitter/tweets/{id}/retweeters | 转推用户列表 | 按返回用户数 |
| GET | /twitter/thread/{thread_id} | 同一作者串帖线程 | 按返回推文数 |
评论列表示例:
bash
curl "https://twidata.wvovw.com/twitter/tweets/1740192018918170738/comments" \
-H "Authorization: Bearer YOUR_API_KEY"列表类响应通常含 next_cursor + 数组字段,翻页方式与搜索一致。