# Xianyu Seller items API (xianyu.seller_items)

- Canonical page: [https://everyinfra.com/en/xianyu-api/seller_items](https://everyinfra.com/en/xianyu-api/seller_items?utm_medium=ai_doc&utm_campaign=page_md)
- Endpoint: POST https://api.everyinfra.com/api/v1/social with {"platform": "xianyu", "action": "seller_items", "params": {...}}
- Price: $0.001986 per call ($1.99 per 1,000 requests); failed calls and empty results are not charged
- Returns: list, default 10, max 10 per call
- Pagination: pass next_page_token back as page_token for the next page, other params unchanged; one call per page, tokens last 24 hours; up to 1000 rows; beyond 200 rows use mode=async
- Mode: sync; add "mode": "async" for slow tasks

## Health

- Live health (24h percent, hourly and daily trends): https://api.everyinfra.com/api/v1/social/availability?platform=xianyu&action=seller_items

## Parameters

| name | type | required | default | description |
|---|---|---|---|---|
| seller_id | not declared | yes | not declared | For `seller_items`, the Xianyu seller: a numeric seller ID (the `seller_id` returned by `item_detail`, also present on some `search` results) or a seller profile link `https://www.goofish.com/personal?userId=<digits>`. Returns the seller's items currently for sale; sold and delisted items are not returned. Any other format (nickname, item link, App share short link) is rejected with 422 and not billed. |
| page_token | not declared | no | not declared | Page token for `seller_items`. Leave it out for the first page; when the response has `next_page_token`, pass it back unchanged as `page_token`, with `seller_id` unchanged. Tokens last 24 hours and work only for the same seller and the same account; a different seller is rejected with 422 and not billed. Each page holds 10 items and is one call. You can page up to item 1,000 (page 100). Pages 1–20 (the first 200 items) can be read with synchronous requests; from page 21 on, use async: add `"mode": "async"` to the same request and poll `GET /api/v1/jobs/{job_id}`. A synchronous request for page 21 returns 422 `async_required` and is not billed. No `next_page_token` (`pagination.has_more` is false) means you cannot page further: `pagination.stop_reason` is `end_of_list` when the seller's items for sale are exhausted, or `depth_limit` if this run cannot go deeper; more items may remain. Page 1 is fetched fresh on every request. Pages 2–20 are cut in order from a saved copy of the list made the first time page 2 is requested, and page 21 onward from another saved copy made the first time page 21 is requested; within one copy, pages neither repeat nor skip items. If the seller lists or delists items in the meantime, an item already given on page 1 is never given again on a later page, whichever saved copy that page is cut from. Pages 20 and 21 meet at the seam between the two saved copies: a few items given on pages 2–20 may reappear from page 21 on, and a few items may be missed, so deduplicate by `item_id` when you merge. |
| limit | integer (1–10) | no | 10 | The most rows to return in this call, an integer from 1 to 10. The default applies when you leave it out, and a call can return fewer rows. Larger values return 422 before any charge. |

## Response fields (items in `results`)

| 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. |
| currency | Currency code of the price (for example CNY, USD). If price is present but currency is null, do not assume a currency. |
| image_url | Image link. Capabilities with several images may return an image_urls array. |
| images | Array of image links in the platform's display order; absent when there are no images. |
| 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. |
| seller_id | Numeric seller ID (string). Most `search` results do not return it. |
| seller_url | Link to the seller's page on Xianyu. |
| seller_item_count | Number of items for sale shown on the seller's profile. |
| platform | Source platform identifier, the same as platform in the request (for example xiaohongshu, tiktok). |

## Example

```bash
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": "seller_items",
  "params": {
    "seller_id": "<SELLER_ID>"
  }
}'
```

```python
import os
import requests

response = requests.post(
    "https://api.everyinfra.com/api/v1/social",
    headers={"Authorization": f"Bearer {os.environ['EVERYINFRA_API_KEY']}"},
    json={
        "platform": "xianyu",
        "action": "seller_items",
        "params": {
            "seller_id": "<SELLER_ID>",
        },
    },
    timeout=120,
)
print(response.status_code)
print(response.json())
```

## Response example

No real sample for these example parameters yet: structure only, every value is a placeholder (…).

```text
{
  "id": "req_…",
  "platform": "xianyu",
  "action": "seller_items",
  "results": [
    {
      "item_id": …,
      "url": …,
      "title": …,
      "price": …,
      "currency": …,
      "image_url": …,
      "images": …,
      "want_count": …,
      "tags": …,
      "category_id": …,
      "free_shipping": …,
      "is_auction": …,
      "has_video": …,
      "seller_id": …,
      "seller_url": …,
      "seller_item_count": …,
      "platform": …
    }
  ],
  "next_page_token": …,
  "pagination": { … },
  "count": …,
  "billing": {
    "charged": …,
    "charged_usd": …,
    "balance_after_usd": …,
    …
  },
  "quota": { … }
}
```

## Also

- Capability catalog (no key): https://api.everyinfra.com/api/v1/social/catalog?platform=xianyu
- OpenAPI: https://everyinfra.com/openapi.json · Agents guide: https://everyinfra.com/agents.md
