X Twitter Searchpostsall

1.24 credits/call
ae_x_twitter_searchpostsall

Search public historical posts by keyword, time range or post ID range. Results may not be strictly chronological.

Social
1.24 credits/call

Pricing

1.24 credits/call
ConditionCharge
Each call1.24 credits/call

1.24 credits/call Charges are per query. A successful query is billed even if it returns no results.

Parameters

Optional parameters use the platform defaults when omitted.

ParameterTypeRequiredDescriptionDefault
querystringYes搜索表达式,例如from:NASA、filter:media、lang:en。 Search expression, such as from:NASA, filter:media or lang:en.—
end_timestringNo截止时间,不包含该时刻。使用带时区的RFC3339格式;与until_id二选一。 Exclusive end time in RFC3339 format with a timezone. Do not combine with until_id.—
since_idstringNo仅查询晚于该推文ID的帖子;与start_time二选一。 Return posts newer than this post ID; do not combine with start_time.—
until_idstringNo仅查询早于该推文ID的帖子;与end_time二选一。 Return posts older than this post ID; do not combine with end_time.—
sort_orderenum (recency | relevancy)No检索方式:recency优先近期结果,relevancy优先相关结果;返回顺序可能不严格按时间排列。 Search mode: recency favors recent results; relevancy favors relevant results. Results may not be strictly chronological.—
start_timestringNo起始时间,包含该时刻。使用带时区的RFC3339格式;与since_id二选一。 Inclusive start time in RFC3339 format with a timezone. Do not combine with since_id.—
pagination_tokenstringNo上一页返回的分页标记。首次查询不填;不能自行编造。 Pagination token returned by the previous page. Omit for the first page; do not invent a token.—

Invocation example

Copy the request and explore its response example.

POST/agent-api/v1/tool/executeX-Api-Key
Request coderequest.sh
curl --request POST \
  --url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_x_twitter_searchpostsall' \
  --header "X-Api-Key: $AGENTEARTH_API_KEY" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "params": {
    "end_time": "2026-11-12T03:03:26.565Z",
    "query": "conversation_id:2118029105451147478",
    "sort_order": "recency",
    "start_time": "2026-08-31T16:00:00Z"
  }
}'
Response exampleresponse.json
JSONPartial content
{
  "code": 200,
  "data": {
    "next_cursor": "DAACCgACHW5M9v0AJxAKAAMdbkz2_P_Y8AgABAAAAAILAAUAAAAoRW1QQzZ3QUFBZlEvZ0dKTjB2R3AvQUFBQUFFZFpNQS81bHFnMWc9PQgABgAAAAAIAAcAAAAADAAICgABHWTAP-ZaoNYAAAA",
    "prev_cursor": "DAACCgACHW5M9v0AJxAKAAMdbkz2_P_Y8AgABAAAAAELAAUAAAAoRW1QQzZ3QUFBZlEvZ0dKTjB2R3AvQUFBQUFFZFpNQS81bHFnMWc9PQgABgAAAAAIAAcAAAAADAAICgABHWTAP-ZaoNYAAAA",
    "status": "ok",
    "timeline": [
      {
        "bookmarks": 0,
        "conversation_id": "2118029105451147478",
        "created_at": "Wed Nov 04 17:14:24 +0000 2026",
        "display_text_range": [
          0
        ],
        "entities": {
          "hashtags": [],
          "symbols": [],
          "timestamps": [],
          "urls": [],
          "user_mentions": []
        },
        "type": "tweet"
      }
    ]
  },
  "docs": "https://api.tikhub.io/#/Twitter-Web-API/fetch_search_timeline_api_v1_twitter_web_fetch_search_timeline_get",
  "message": "Request successful. This request will incur a charge.",
  "message_zh": "请求成功,本次请求将被计费。",
  "params": {
    "cursor": "",
    "keyword": "conversation_id:2118029105451147478 since_time:1788192000 until_time:1794452606",
    "search_type": "Latest"
  }
}

This example shows part of the response. Copied content is valid JSON.

Guides using this tool

See how this tool fits into real workflows