Xianyu Search API
API health
- 24h health
- 100%
- 24h average time
- 14.59 s
- Healthy / normal
- Available
- Limited
- Mostly down
Last 24 hours
Last 30 days
Browse second-hand listings on Xianyu for a search phrase, up to 50 per call. Get price, city, want count, tags, auction flag and the seller's trust grade. Chinese terms and model numbers match seller titles best. A null want_count means the card did not show it, not zero.
Send POST https://api.everyinfra.com/api/v1/social with platform set to xianyu and action set to search. Price $5.56 per 1,000 requests ($0.005556 per call). Failed calls and empty results are not charged. Synchronous. For slow jobs add "mode": "async" to the body, take the job_id and poll.
Xianyu Search finds second-hand listings on Xianyu by keyword and returns each listing's title, price, the original price the seller entered, city or province, how many people want it, listing tags, free shipping, auction status and publish time, plus the seller's nickname and credit level. Use it to see what an item sells for second-hand and how quickly it might move: resale price research, trade-in pricing, or watching listings for an item.
Chinese words and model numbers that sellers put in titles match best. want_count is how many people tapped the want button, a fair signal of demand; it is null when the listing card does not show it, which is not zero. For auctions price is the current bid, so leave them out of price estimates, and treat original_price as the seller's own claim.
AI prompt
#Please help me write a data collection script with the EveryInfra Xianyu Search endpoint (xianyu/search).
How the endpoint works:
- Request: POST https://api.everyinfra.com/api/v1/social with the header Authorization: Bearer <API key>. Read the key from the EVERYINFRA_API_KEY environment variable and never hard-code it.
- In the request body, set platform to xianyu and action to search, and put the parameters inside params.
- Required parameters:
- keyword: The Xianyu search phrase for search, 1–100 characters. Chinese terms and model numbers match seller titles more often than English translations. It is not an item ID or a seller name.
- Optional parameters:
- limit: The most rows to return in this call, an integer from 1 to 50. The default applies when you leave it out, and a call can return fewer rows. Larger values return 422 before any charge. (default: 20)
- Returns a list of records. Main fields of each record: item_id (Numeric Xianyu listing ID (string)), url, title, price, original_price (Original price the seller entered, in y…), currency, city (Where the listing is, at city level as…), image_url, want_count (Number of users who tapped the want but…), tags (Every label on the listing card as writ…), category_id (Xianyu category ID (string)), free_shipping (Whether shipping is free); 19 fields in total, full list at https://api.everyinfra.com/api/v1/social/catalog?platform=xianyu.
- Example request body:
{
"platform": "xianyu",
"action": "search",
"params": {
"keyword": "iPhone 15"
}
}
- Price: $5.56 per 1,000 requests; failed and empty results are not charged.
- For dozens or hundreds of targets, add "mode": "async" to the body: you get a job_id at once and poll GET https://api.everyinfra.com/api/v1/jobs/{job_id} for the result.
- On 422, fix the request using the suggested parameter names and allowed values in the error; on 429 or 503, wait for Retry-After and try again.
Before writing code, ask me which targets I need, how many, which fields, and what output format I want; then confirm the plan and the rough cost with me.Request parameters
#| Name | In | Type | Required | Default | Description |
|---|---|---|---|---|---|
Authorization | header | string | Yes | - | Bearer followed by your API key. Create it in the console; never put it in a URL or a code repository. |
platform | body | string | Yes | xianyu | Platform identifier, fixed value. |
action | body | string | Yes | search | Capability identifier, fixed value. |
keyword | body.params | string | Yes | - | The Xianyu search phrase for search, 1–100 characters. Chinese terms and model numbers match seller titles more often than English translations. It is not an item ID or a seller name. |
limit | body.params | integer (1–50) | No | 20 | The most rows to return in this call, an integer from 1 to 50. The default applies when you leave it out, and a call can return fewer rows. Larger values return 422 before any charge. |
Code samples
#curl -X POST 'https://api.everyinfra.com/api/v1/social' \
-H "Authorization: Bearer $EVERYINFRA_API_KEY" \
-H 'Content-Type: application/json' \
--data-raw '{
"platform": "xianyu",
"action": "search",
"params": {
"keyword": "iPhone 15"
}
}'OpenAPI definition (JSON)Samples read the key from the EVERYINFRA_API_KEY environment variable; copied code never contains your key.
Response example
#{ "id": "req_…", "platform": "xianyu", "action": "search", "results": [ { "item_id": "1089122948858", "url": "https://www.goofish.com/item?id=1089122948858", "title": "滋滋【福利疯抢】iPhone 15 盲盒随机打包手机、平板、电脑,九九新几乎全新,不指定、不挑选,完美主义者请勿下单,要求较多的急单的勿扰勿拍! ✅ 评论区随心许愿,快递随机取件发货✅ 1人1单,邮费自理,请自觉下单✅ 客服回复不及时还请谅解!商品有在就都可以下单购买 宝宝", "price": 1.13, "currency": "CNY", "city": "重庆", "image_url": "https://img.alicdn.com/bao/uploaded/i1/2222991832241/O1CN01RndZ4wTqacI2Qw7p_!!4611686018427385009-0-xy_item.jpg", "want_count": 2, "tags": [ "13小时前发布", "freeShippingIcon" ], "category_id": "50023914", "free_shipping": true, "is_auction": false, "has_video": false, "posted_at": "2026-09-29T09:02:03+00:00", "seller_name": "•••", "platform": "xianyu" }, { "item_id": "1073624434319", "url": "https://www.goofish.com/item?id=1073624434319", "title": "出苹果15 iPhone15 国行256g 因为换手机了,太多了手机用不过来 随缘出,机况如图,电池77%这样 自己看哈", "price": 500, "currency": "CNY", "city": "上海", "image_url": "https://img.alicdn.com/bao/uploaded/i2/2222827391527/O1CN011onH6VJOZXL1jFqC_!!4611686018427382311-0-xy_item.jpg", "want_count": 270, "tags": [ "Apple/苹果", "256GB", "无任何维修" ], "category_id": "50025386", "free_shipping": true, "is_auction": false, "has_video": false, "posted_at": "2026-08-12T13:09:19+00:00", "seller_name": "•••", "platform": "xianyu" } ], "count": 20, "billing": { "charged": …, "charged_usd": …, "balance_after_usd": …, … }, "quota": { … }}
Response fields
#Business data is in results. The table lists the fields a record can contain; values the platform does not show are never made up.
| Field | Meaning |
|---|---|
item_id | Numeric Xianyu listing ID (string); pass it as is in urls of item_detail. |
url | Link to the record on the platform. |
title | Title. null when the platform has no titles (for example text-only posts). |
price | Price as a number without a currency symbol; see currency. |
original_price | Original price the seller entered, in yuan; null when not entered. |
currency | Currency code of the price (for example CNY, USD). If price is present but currency is null, do not assume a currency. |
city | Where the listing is, at city level as Xianyu shows it; some listings show only the province. Finer location, when the listing has it, is in district, lat, lng and poi_name. |
image_url | Image link. Capabilities with several images may return an image_urls array. |
want_count | Number of users who tapped the want button. In search it comes from the card's label and is null when the card does not show it; null is not zero. |
tags | Every label on the listing card as written, such as brand new, free shipping, brand or price drop, plus seller labels (credit, identity check, last seen, years on Xianyu); the want count is separate in want_count. Empty list when there are none. |
category_id | Xianyu category ID (string). |
free_shipping | Whether shipping is free. |
is_auction | Whether the listing is an auction; if so, price is the current bid. |
has_video | Whether the listing includes a video. |
posted_at | Publish time in ISO 8601, UTC (for example 2026-08-07T12:34:56+00:00). Non-standard strings from the platform are passed through as is, so parse defensively. null means the platform does not disclose it. |
seller_id | Numeric seller ID (string). |
seller_name | Seller nickname. Xianyu partly masks it for signed-out visitors, and it is returned as the page shows it. |
seller_avatar_url | Seller profile photo URL. |
seller_credit_label | Seller credit grade as shown on the search card, for example excellent. |
platform | Source platform identifier, the same as platform in the request (for example xiaohongshu, tiktok). |
FAQ
#How can I tell whether an item will sell quickly?
#Look at want_count, the number of people who tapped the want button, taken from the listing card. It is null when the card does not show it, which is not zero. Many wants soon after posted_at point to an item in demand.
What should I watch for when estimating resale prices?
#Leave out auctions, where is_auction is true and price is the current bid, and treat original_price as the seller's own figure. Grouping listings by model and condition keywords before reading the price spread gives a more reliable range.
What do I learn about the seller?
#The seller's ID, avatar and credit label as shown on the card, plus the seller tags in tags. Nicknames are partly masked exactly as Xianyu shows them. For a listing's full details, pass its item_id to the Xianyu Listing details capability.
Errors and billing
#- 401
- Missing or invalid key.
- 402
- Insufficient balance. Top up first.
- 422
- Invalid parameter name or value. Fix it using the suggestions in the error. No charge.
- 429
- Per-minute request limit reached. Wait for Retry-After, then try again.
- 503
- Could not complete. The held charge is returned to your balance. If the outcome is unknown, verify it before you retry.
- 200 empty
- No data. No charge.