error 字段的 JSON 对象:
全局错误
以下错误可能出现在任何需要身份验证的端点上。Unauthorized
Unauthorized/Invalid api key — API key
缺失、过期或无效。确保你发送了所有必需的身份验证
header。Service Unavailable
Trading is currently disabled. Check polymarket.com for updates —
交易所暂时停止运行。不接受任何订单(包括取消)。订单簿
订单簿端点的错误。GET book
Bad Request
Invalid token id — token_id 查询参数缺失或不是有效的 token ID。Not Found
No orderbook exists for the requested token idPOST books
Bad Request
Invalid payload — 请求体格式错误或缺少必填字段。Bad Request
Payload exceeds the limit — 单次请求中的 token ID 数量过多,请减少批量大小。价格查询
价格、中间价和价差端点的错误。GET price
Bad Request
Invalid token id — token_id 参数缺失或无效。Bad Request
Invalid side — side 参数必须为 BUY 或 SELL。Not Found
No orderbook exists for the requested token idPOST prices
Bad Request
Invalid payload — 请求体格式错误或缺少必填字段。Bad Request
Invalid side — side 字段必须为 BUY 或 SELL。Bad Request
Payload exceeds the limit — 单次请求中的 token ID 数量过多。GET midpoint
Bad Request
Invalid token id — token_id 参数缺失或无效。Not Found
No orderbook exists for the requested token idPOST midpoints
Bad Request
Invalid payload — 请求体格式错误或缺少必填字段。Bad Request
Payload exceeds the limit — 单次请求中的 token ID 数量过多。GET spread
Bad Request
Invalid token id — token_id 参数缺失或无效。Not Found
No orderbook exists for the requested token idPOST spreads
Bad Request
Invalid payload — 请求体格式错误或缺少必填字段。Bad Request
Payload exceeds the limit — 单次请求中的 token ID 数量过多。下单
下单端点的错误。POST order
Bad Request
Invalid order payload — 请求体格式错误、缺少必填字段或包含无效值。Bad Request
the order owner has to be the owner of the API KEY — 订单中的 maker
地址与你的 API key 关联的地址不匹配。Bad Request
the order signer address has to be the address of the API KEYBad Request
'{address}' address banned — 该地址已被禁止交易。Bad Request
'{address}' address in closed only modeService Unavailable
Trading is currently cancel-only. New orders are not accepted, but cancels are allowed. — 交易所处于仅取消模式。你可以取消现有订单,但不能下新单。Service Unavailable
post-only mode: only post-only orders and cancels are allowed — 交易所处于
post-only 模式。你可以取消订单,也可以提交设置了 postOnly: true 的订单;非
post-only 订单会被拒绝。响应包含 code: "post_only_mode" 和
retry_after_seconds,相同的重试延迟也会出现在 Retry-After HTTP header 中。Retry-After HTTP header 返回。
POST orders
包含POST /order 的端点级错误,以及:
Bad Request
Too many orders in payload: {N}, max allowed: {M} —
批量请求中的订单数量超过了每次请求的最大允许数量。200 响应数组中返回,每个失败的订单都有独立的错误信息。
在 post-only 模式下,批量请求中的非 post-only 订单会返回单独的错误:
订单处理错误
当订单通过初始验证但在处理过程中失败时,会返回这些错误。它们出现在POST /order 和 POST /orders 的响应体中。
Bad Request
invalid post-only order: order crosses book —
Post-only(maker)订单会立即成交。请调整价格使其挂在订单簿上。Bad Request
order {id} is invalid. Price ({price}) breaks minimum tick size rule: {tick}
— 订单价格不符合市场的最小价格精度。使用 GET /tick-size 查看有效的价格精度。Bad Request
order {id} is invalid. Size ({size}) lower than the minimum: {min} —
订单数量低于市场最小值。Bad Request
order {id} is invalid. Duplicated.Bad Request
order {id} crosses the bookBad Request
not enough balance / allowance — pUSD
余额不足或代币授权额度不够。请确保账户持有足够的
pUSD,并按照设置交易授权授予 Exchange
合约相应额度。Bad Request
invalid expiration — 订单过期时间已过或无效。Bad Request
order canceled in the CTF exchange contractBad Request
order match delayed due to market conditionsBad Request
order couldn't be fully filled. FOK orders are fully filled or killed. —
Fill-or-Kill 订单无法被现有流动性完全填充,整个订单被拒绝。Bad Request
no orders found to match with FAK order. FAK orders are partially filled or killed if no match is found. — Fill-and-Kill
订单未找到任何匹配订单。至少需要一个匹配。Bad Request
the market is not yet ready to process new ordersInternal Server Error
order timed out — Exchange
未能在请求截止时间前处理订单。这通常发生在同一账户并发提交大量订单时。订单在进入订单簿前已被拒绝,可以安全地重新提交。撮合引擎错误
订单执行过程中可能出现的内部撮合引擎错误。Internal Server Error
there are no matching ordersInternal Server Error
FOK orders are filled or killed — Fill-or-Kill 订单无法被完全满足。Internal Server Error
the trade contains rounding issuesInternal Server Error
the price of the taker's order has a discrepancy greater than allowed with the worst maker order取消订单
取消订单端点的错误。DELETE order
Bad Request
Invalid order payload — 请求体格式错误。Bad Request
Invalid orderID — 提供的订单 ID 格式无效。DELETE orders
Bad Request
Invalid order payload — 请求体格式错误。Bad Request
Too many orders in payload, max allowed: {N} — 单次取消请求中的订单 ID
数量过多。Bad Request
Invalid orderID — 一个或多个订单 ID 无效。DELETE cancel-market-orders
Bad Request
Invalid order payload — 请求体格式错误或包含无效的筛选参数。查询订单
查询订单端点的错误。GET order by ID
Bad Request
Invalid orderID — URL 路径中的订单 ID 无效。Internal Server Error
Internal server error — 获取订单时发生意外错误。GET orders
Bad Request
invalid order params payload — 查询参数格式错误或包含无效值。Internal Server Error
Internal server error — 获取订单时发生意外错误。交易记录
GET trades
Bad Request
Invalid trade params payload — 查询参数格式错误或包含无效值。Internal Server Error
Internal server error — 获取交易记录时发生意外错误。GET last-trade-price
Bad Request
Invalid token id — token_id 参数缺失或无效。Internal Server Error
Internal server error — 获取最近成交价时发生意外错误。POST last-trades-prices
Bad Request
Invalid payload — 请求体格式错误或缺少必填字段。Bad Request
Payload exceeds the limit — 单次请求中的 token ID 数量过多。市场信息
GET market by condition ID
Bad Request
Invalid market — condition ID 格式无效。Not Found
market not found — 不存在该 condition ID 对应的市场。GET tick-size
Bad Request
Invalid token id — token ID 无效。Not Found
market not found — 未找到该 token ID 对应的市场。GET neg-risk
Bad Request
Invalid token id — token ID 无效。Not Found
market not found — 未找到该 token ID 对应的市场。价格历史
GET prices-history
Bad Request
筛选条件验证错误 —
一个或多个查询参数(
market、startTs、endTs、fidelity)无效。GET ohlc
Bad Request
startTs is required — 缺少 startTs 查询参数。Bad Request
asset_id is required — 缺少 asset_id 查询参数。Bad Request
invalid fidelity: {val} — fidelity
参数必须为以下值之一:1m、5m、15m、30m、1h、4h、1d、1w。Bad Request
limit cannot exceed 1000 — 请将 limit 参数减少到 1000 或以下。GET orderbook-history
Bad Request
startTs is required — 缺少 startTs 查询参数。Bad Request
either market or asset_id must be provided — 你必须指定 market(condition
ID)或 asset_id(token ID)其中之一。Bad Request
limit cannot exceed 1000 — 请将 limit 参数减少到 1000 或以下。身份验证和 API Key
POST auth api-key
Unauthorized
Invalid L1 Request headers — L1 身份验证 header 缺失或无效。Bad Request
Could not create api keyGET auth api-keys
Internal Server Error
Could not retrieve API keys — 获取 API key 时发生意外错误。DELETE auth api-key
Internal Server Error
Could not delete API key — 删除 API key 时发生意外错误。GET auth derive-api-key
Unauthorized
Invalid L1 Request headers — L1 身份验证 header 缺失或无效。Bad Request
Could not derive api key!Builder API Key
POST auth builder-api-key
Internal Server Error
could not create builder api key — Builder API key 创建失败。GET auth builder-api-key
Internal Server Error
could not get builder api keys — 获取 Builder API key 时发生意外错误。DELETE auth builder-api-key
Bad Request
invalid revoke builder api key body — 请求体格式错误。Bad Request
invalid revoke builder api key headers — 缺少必要的身份验证 header。Internal Server Error
could not revoke the builder api key: {key} — 撤销 key 时发生意外错误。Builder 交易记录
GET builder trades
Bad Request
invalid builder trade params — 查询参数格式错误或包含无效值。Internal Server Error
could not fetch builder trades — 获取 Builder 交易记录时发生意外错误。余额和授权
GET balance-allowance
Bad Request
Invalid asset type — asset_type 参数不是可识别的资产类型。Bad Request
Invalid signature_type — signature_type 参数必须为 EOA、POLY_PROXY 或
GNOSIS_SAFE。状态码速查
CLOB API 内部存在状态码覆盖机制:任何包含
"not found" 的错误信息会返回
404,包含 "unauthorized" 的会返回 401,包含 "context canceled"
的会返回 400,无论原始状态码是什么。