Weibo Search User Posts

2.07 credits/call
ae_weibo_search_user_posts

Search a specified Weibo user's posts by keyword, with optional pagination, time boundaries, and post-type filters. Inputs: - uid (required): The user's ID as a string. - q: Search keyword; defaults to "" for no keyword restriction. Other filters still apply. - page: Page number, starting at 1; defaults to 1. - starttime and endtime: Optional start and end Unix timestamps, accepting integers or null. Both have a schema default of 1772294400; omitting them should not be treated as requesting an unrestricted time range. - hasori, hasret, hastext, haspic, hasvideo, hasmusic: Include original posts, reposts, text, images, video, and music, respectively. Each uses 1 for include and 0 for exclude, and defaults to 1. Returns a response containing the search results, described as including post content, author information, and interaction data. The exact result-item structure is not specified, so available fields must be checked in the response. Results are affected by user privacy settings; this tool does not guarantee access to all of a user's posts.

Social
2.07 credits/call

Pricing

2.07 credits/call
ConditionCharge
Each call2.07 credits/call

2.07 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
qstringNo搜索关键词/Search keyword""
uidstringYes用户ID/User ID—
pageintegerNo页数/Page number1
hasoriintegerNo是否包含原创微博,1=包含,0=不包含/Include original posts, 1=include, 0=exclude1
haspicintegerNo是否包含图片微博,1=包含,0=不包含/Include image posts, 1=include, 0=exclude1
hasretintegerNo是否包含转发微博,1=包含,0=不包含/Include retweets, 1=include, 0=exclude1
endtimeinteger | nullNo结束时间戳/End timestamp1772294400
hastextintegerNo是否包含文字微博,1=包含,0=不包含/Include text posts, 1=include, 0=exclude1
hasmusicintegerNo是否包含音乐微博,1=包含,0=不包含/Include music posts, 1=include, 0=exclude1
hasvideointegerNo是否包含视频微博,1=包含,0=不包含/Include video posts, 1=include, 0=exclude1
starttimeinteger | nullNo开始时间戳/Start timestamp1772294400

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_weibo_search_user_posts' \
  --header "X-Api-Key: $AGENTEARTH_API_KEY" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "params": {
    "endtime": 1788192000,
    "hasmusic": 1,
    "hasori": 1,
    "haspic": 1,
    "hasret": 1,
    "hastext": 1,
    "hasvideo": 1,
    "page": 2,
    "q": "直播",
    "starttime": 1767196800,
    "uid": "2449560947"
  }
}'
Response exampleresponse.json
JSONPartial content
{
  "code": 200,
  "data": {
    "data": {
      "list": [],
      "total": 0
    },
    "ok": 1
  },
  "docs": "https://api.tikhub.io/#/Weibo-Web-V2-API/search_user_posts_api_v1_weibo_web_v2_search_user_posts_get",
  "message": "Request successful. This request will incur a charge.",
  "message_zh": "请求成功,本次请求将被计费。",
  "params": {
    "endtime": "1788192000",
    "hasmusic": "1",
    "hasori": "1",
    "haspic": "1",
    "hasret": "1",
    "hastext": "1"
  }
}

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