# /xueqiu/quotes

`POST /api/xueqiu/quotes`

Price: 1 credit

Get live quotes for Shanghai, Shenzhen, Beijing, Hong Kong and US securities from Xueqiu: price, change, volume, turnover, valuation ratios, market capital, 52-week range and extended-hours prices, plus net asset value and premium for ETFs and funds and advancing/declining counts for indices

## How to use it

Symbols are Xueqiu's: SH/SZ/BJ plus six digits for mainland listings, five digits for Hong Kong, the ticker for US listings, a dot and the code for US indices (.DJI, .IXIC, .INX); the symbol of a ranked listing comes from xueqiu/quotes/search, which ranks a market and takes no name. A symbol Xueqiu does not know is left out of the result.

## Parameters

- `access-token` (string, required)

## Request body

- `timeout` (integer) — Max scrapping execution timeout (in seconds) (default: 300; min: 20; max: 1500)
- `symbols` (array, required) — Xueqiu security symbols or quote page URLs (examples: ["SH600519","00700","AAPL"]; minItems: 1; maxItems: 20)

## Response

### 200 — Successful Response

- `@type` (string) (default: "XueqiuQuote")
- `symbol` (string, required)
- `code` (string, nullable)
- `name` (string, nullable)
- `url` (string, nullable)
- `exchange` (string, nullable)
- `currency` (string, nullable)
- `security_type` (string, nullable)
- `sub_type` (string, nullable)
- `market_region` (string, nullable)
- `market_status` (string, nullable)
- `market_time_zone` (string, nullable)
- `price` (number, nullable)
- `previous_close` (number, nullable)
- `open` (number, nullable)
- `high` (number, nullable)
- `low` (number, nullable)
- `average_price` (number, nullable)
- `change` (number, nullable)
- `change_percent` (number, nullable)
- `amplitude` (number, nullable)
- `volume` (number, nullable)
- `amount` (number, nullable)
- `turnover_rate` (number, nullable)
- `volume_ratio` (number, nullable)
- `order_book_ratio` (number, nullable)
- `high_52w` (number, nullable)
- `low_52w` (number, nullable)
- `limit_up` (number, nullable)
- `limit_down` (number, nullable)
- `ytd_change_percent` (number, nullable)
- `market_capital` (number, nullable)
- `float_market_capital` (number, nullable)
- `total_shares` (number, nullable)
- `float_shares` (number, nullable)
- `eps` (number, nullable)
- `navps` (number, nullable)
- `pe_ttm` (number, nullable)
- `pe_lyr` (number, nullable)
- `pe_forecast` (number, nullable)
- `pb` (number, nullable)
- `ps` (number, nullable)
- `dividend` (number, nullable)
- `dividend_yield` (number, nullable)
- `profit` (number, nullable)
- `profit_ttm` (number, nullable)
- `profit_forecast` (number, nullable)
- `shareholder_funds` (number, nullable)
- `pledge_ratio` (number, nullable)
- `goodwill_in_net_assets` (number, nullable)
- `beta` (number, nullable)
- `short_ratio` (number, nullable)
- `institutional_holding` (number, nullable)
- `lot_size` (integer, nullable)
- `tick_size` (number, nullable)
- `variable_tick_size` (string, nullable)
- `contract_size` (integer, nullable)
- `is_registration` (string, nullable)
- `is_vie` (string, nullable)
- `has_weighted_voting_rights` (string, nullable)
- `has_no_profit` (string, nullable)
- `security_status` (string, nullable)
- `dual_counter_symbol` (string, nullable)
- `extended_price` (number, nullable)
- `extended_change` (number, nullable)
- `extended_change_percent` (number, nullable)
- `extended_volume` (number, nullable)
- `extended_amount` (number, nullable)
- `extended_at` (integer, nullable)
- `night_session_price` (number, nullable)
- `night_session_change` (number, nullable)
- `night_session_change_percent` (number, nullable)
- `night_session_at` (integer, nullable)
- `nav` (number, nullable)
- `accumulated_nav` (number, nullable)
- `nav_date` (integer, nullable)
- `iopv` (number, nullable)
- `premium_rate` (number, nullable)
- `inception_date` (integer, nullable)
- `rising_count` (integer, nullable)
- `falling_count` (integer, nullable)
- `unchanged_count` (integer, nullable)
- `max_order_quantity` (integer, nullable)
- `min_order_quantity` (integer, nullable)
- `market_maker_count` (integer, nullable)
- `listed_date` (integer, nullable)
- `updated_at` (integer, nullable)

## Errors

### 422 — Validation Error

The request body did not validate

What to do: Check the fields against this schema. A URN with the wrong prefix is the most common cause.

- `detail` (array)
  - `loc` (array, required)
  - `msg` (string, required)
  - `type` (string, required)
  - `input` (any)
  - `ctx` (object)

### 408

The request ran past its time limit

What to do: Raise `timeout` in the request body, up to the maximum this endpoint documents. Lowering `count` or turning off the `with_*` flags also helps, because less work finishes sooner.

### 412

None of the symbols is known to Xueqiu

What to do: Retrying will not help: either the entity does not exist, or the input points at a different one.

### 429

Too many requests: a rate limit or a usage window is exhausted

What to do: When the response carries an X-Retry-After header, wait that many seconds and retry: the same number is in the body as `detail.retry_after`, and the limit clears once that window passes. The message in the body names the limit that was hit.

### 500

Something broke on our side

What to do: Retrying will not help. If it keeps happening, send us the X-Request-ID from the response headers.

### 529

Rate limit reached, or the endpoint is overloaded

What to do: Wait at least 30 seconds, then retry.

## Response envelope

Success: Array of objects (may be empty if no results)

Error: Error may coexist with partial results if it occurs mid-execution. Check X-Error header and status code.

Every response carries these headers:

- `X-Error` — Error message text (present only on error)
- `X-Request-ID` — Unique request identifier
- `X-Execution-Time` — Execution time in seconds
- `X-Result-Count` — How many records the body carries. 0 means an empty result, which is a normal answer and not by itself an error. A non-zero count can come back together with X-Error when the failure happened partway through — read this header and X-Error independently.
- `X-Total-Available-Results` — How many records exist for this query, when the endpoint can say. On a `dry_run` request this is the answer and the body is empty. It saturates: the endpoint's documented maximum means 'at least that many', any smaller number is exact.
- `X-Warning` — Present when the request body carried keys this endpoint does not document. They were ignored, so any filter you meant to apply through them did not apply. Check the spelling against this schema and retry.
- `X-Retry-After` — Seconds to wait before retrying. Present only on 429.

