Search WeChat content
tikhub.x.wechat-search-v2-fetch-searchWechat search: fetch search (v2)
- Price
- $0.01/successPelo preço do provedor
- Success rate
- 100%Last 30 days · 44 calls
- Latency p50
- 2.3 sp95 3.1 s
- Last verified
- 28 de jul. de 2026Verified working
POSThttps://toolswitch.dev/v1/tools/tikhub.x.wechat-search-v2-fetch-searchPreview- Uses platform quota
- Synchronous response
- Reads public data
Parâmetros
| Parâmetro | Tipo | Obrigatório | Descrição | Exemplo |
|---|---|---|---|---|
| Corpo (JSON) | ||||
raw | booleano | Opcional | True=raw search response; False=simplified parsed structure | true |
sort | string | Opcional | Sort (result page 'sort' dropdown, common to all verticals): default/0 (relevance) / latest/1 (newest) / hot/2 (most liked); string key or integer | default |
cursor | string | Opcional | Pagination cursor: leave empty for the first page; for the next page pass back the cursor returned in the previous response | |
offset | inteiro | Opcional | Pass 0 for the first page; use cursor to paginate (offset alone does not work — it returns the first page every time) | 0 |
keyword | string | Obrigatório | Search keyword (1-100 chars) | 人民日报 |
publish_time | string | Opcional | Publish time (result page 'time' dropdown, common): all/0 / day/1 / week/2 / half_year/3; string key or integer | all |
business_type | string | Opcional | Vertical key: all / account / article / video / live_stream / moments / news / book / listen / image / encyclopedia / weixin_index, other values are rejected | all |
- Corpo (JSON)
rawbooleanoOpcionalTrue=raw search response; False=simplified parsed structure
Exemplo:
truesortstringOpcionalSort (result page 'sort' dropdown, common to all verticals): default/0 (relevance) / latest/1 (newest) / hot/2 (most liked); string key or integer
Exemplo:
defaultcursorstringOpcionalPagination cursor: leave empty for the first page; for the next page pass back the cursor returned in the previous response
offsetinteiroOpcionalPass 0 for the first page; use cursor to paginate (offset alone does not work — it returns the first page every time)
Exemplo:
0keywordstringObrigatórioSearch keyword (1-100 chars)
Exemplo:
人民日报publish_timestringOpcionalPublish time (result page 'time' dropdown, common): all/0 / day/1 / week/2 / half_year/3; string key or integer
Exemplo:
allbusiness_typestringOpcionalVertical key: all / account / article / video / live_stream / moments / news / book / listen / image / encyclopedia / weixin_index, other values are rejected
Exemplo:
all
Exemplos de código
Substitua $TOOLSWITCH_KEY pela chave criada no console.
curl -X POST 'https://toolswitch.dev/v1/tools/tikhub.x.wechat-search-v2-fetch-search' \
-H "X-Toolswitch-Key: $TOOLSWITCH_KEY" \
-H "Content-Type: application/json" \
--data-raw '{"raw":true,"sort":"default","offset":0,"keyword":"人民日报","publish_time":"all","business_type":"all"}'import os
import json
import requests
response = requests.request(
"POST",
"https://toolswitch.dev/v1/tools/tikhub.x.wechat-search-v2-fetch-search",
headers={"X-Toolswitch-Key": os.environ["TOOLSWITCH_KEY"]},
json=json.loads("{\"raw\":true,\"sort\":\"default\",\"offset\":0,\"keyword\":\"人民日报\",\"publish_time\":\"all\",\"business_type\":\"all\"}"),
)
response.raise_for_status()
print(response.text)const response = await fetch("https://toolswitch.dev/v1/tools/tikhub.x.wechat-search-v2-fetch-search", {
method: "POST",
headers: {
"X-Toolswitch-Key": process.env.TOOLSWITCH_KEY ?? "",
"Content-Type": "application/json",
},
body: JSON.stringify(JSON.parse("{\"raw\":true,\"sort\":\"default\",\"offset\":0,\"keyword\":\"人民日报\",\"publish_time\":\"all\",\"business_type\":\"all\"}")),
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
console.log(await response.text());Esta API de gateway está em prévia; a URL e a autenticação podem mudar. Os parâmetros do exemplo são dados de amostra. As chamadas são cobradas a $0.01/success, incluindo a taxa de serviço.