You are viewing documentation for Polymarket US πΊπΈ
curl --request POST \
--url https://api.polymarket.us/v1/orders \
--header 'Content-Type: application/json' \
--header 'X-PM-Access-Key: <api-key>' \
--header 'X-PM-Signature: <api-key>' \
--header 'X-PM-Timestamp: <api-key>' \
--data '
{
"marketSlug": "<string>",
"type": "ORDER_TYPE_LIMIT",
"quantity": 123,
"tif": "TIME_IN_FORCE_DAY",
"participateDontInitiate": true,
"goodTillTime": "<string>",
"intent": "ORDER_INTENT_BUY_LONG",
"outcomeSide": "OUTCOME_SIDE_YES",
"action": "ORDER_ACTION_BUY",
"manualOrderIndicator": "MANUAL_ORDER_INDICATOR_MANUAL",
"synchronousExecution": true,
"maxBlockTime": "<string>",
"slippageTolerance": {
"bips": 123,
"ticks": 123
}
}
'{
"id": "<string>",
"executions": [
{
"id": "<string>",
"order": {
"id": "<string>",
"marketSlug": "<string>",
"side": "ORDER_SIDE_BUY",
"type": "ORDER_TYPE_LIMIT",
"price": {
"value": "0.55",
"currency": "USD"
},
"quantity": 123,
"cumQuantity": 123,
"leavesQuantity": 123,
"tif": "TIME_IN_FORCE_DAY",
"goodTillTime": "2023-11-07T05:31:56Z",
"intent": "ORDER_INTENT_BUY_LONG",
"marketMetadata": {
"slug": "<string>",
"icon": "<string>",
"title": "<string>",
"outcome": "<string>",
"eventSlug": "<string>",
"teamId": 123,
"team": {
"id": 123,
"name": "<string>",
"abbreviation": "<string>",
"league": "<string>",
"record": "<string>",
"logo": "<string>",
"alias": "<string>",
"safeName": "<string>",
"homeIcon": "<string>",
"awayIcon": "<string>",
"colorPrimary": "<string>",
"ordering": "<string>",
"ranking": "<string>",
"conference": "<string>"
}
},
"state": "ORDER_STATE_NEW",
"commissionNotionalTotalCollected": {
"value": "0.55",
"currency": "USD"
},
"commissionsBasisPoints": "<string>",
"makerCommissionsBasisPoints": "<string>",
"avgPx": {
"value": "0.55",
"currency": "USD"
},
"cashOrderQty": {
"value": "0.55",
"currency": "USD"
},
"insertTime": "2023-11-07T05:31:56Z",
"createTime": "2023-11-07T05:31:56Z",
"outcomeSide": "OUTCOME_SIDE_YES",
"action": "ORDER_ACTION_BUY"
},
"lastShares": "<string>",
"lastPx": {
"value": "0.55",
"currency": "USD"
},
"type": "EXECUTION_TYPE_NEW",
"text": "<string>",
"orderRejectReason": "ORD_REJECT_REASON_EXCHANGE_OPTION",
"transactTime": "2023-11-07T05:31:56Z",
"legPrices": [
{
"marketSlug": "<string>",
"anchor": true,
"px": {
"value": "0.55",
"currency": "USD"
},
"qty": "<string>",
"side": "ORDER_SIDE_BUY",
"referencePx": "<string>"
}
],
"tradeId": "<string>",
"aggressor": true,
"commissionNotionalCollected": {
"value": "0.55",
"currency": "USD"
},
"unsolicitedCancelReason": "UNSOLICITED_CXL_REASON_CONNECTION_LOSS",
"traceId": "<string>",
"commissionSpreadPx": {
"value": "0.55",
"currency": "USD"
},
"transactTradeDate": "2023-11-07T05:31:56Z"
}
]
}Create a new order to enter into a market
curl --request POST \
--url https://api.polymarket.us/v1/orders \
--header 'Content-Type: application/json' \
--header 'X-PM-Access-Key: <api-key>' \
--header 'X-PM-Signature: <api-key>' \
--header 'X-PM-Timestamp: <api-key>' \
--data '
{
"marketSlug": "<string>",
"type": "ORDER_TYPE_LIMIT",
"quantity": 123,
"tif": "TIME_IN_FORCE_DAY",
"participateDontInitiate": true,
"goodTillTime": "<string>",
"intent": "ORDER_INTENT_BUY_LONG",
"outcomeSide": "OUTCOME_SIDE_YES",
"action": "ORDER_ACTION_BUY",
"manualOrderIndicator": "MANUAL_ORDER_INDICATOR_MANUAL",
"synchronousExecution": true,
"maxBlockTime": "<string>",
"slippageTolerance": {
"bips": 123,
"ticks": 123
}
}
'{
"id": "<string>",
"executions": [
{
"id": "<string>",
"order": {
"id": "<string>",
"marketSlug": "<string>",
"side": "ORDER_SIDE_BUY",
"type": "ORDER_TYPE_LIMIT",
"price": {
"value": "0.55",
"currency": "USD"
},
"quantity": 123,
"cumQuantity": 123,
"leavesQuantity": 123,
"tif": "TIME_IN_FORCE_DAY",
"goodTillTime": "2023-11-07T05:31:56Z",
"intent": "ORDER_INTENT_BUY_LONG",
"marketMetadata": {
"slug": "<string>",
"icon": "<string>",
"title": "<string>",
"outcome": "<string>",
"eventSlug": "<string>",
"teamId": 123,
"team": {
"id": 123,
"name": "<string>",
"abbreviation": "<string>",
"league": "<string>",
"record": "<string>",
"logo": "<string>",
"alias": "<string>",
"safeName": "<string>",
"homeIcon": "<string>",
"awayIcon": "<string>",
"colorPrimary": "<string>",
"ordering": "<string>",
"ranking": "<string>",
"conference": "<string>"
}
},
"state": "ORDER_STATE_NEW",
"commissionNotionalTotalCollected": {
"value": "0.55",
"currency": "USD"
},
"commissionsBasisPoints": "<string>",
"makerCommissionsBasisPoints": "<string>",
"avgPx": {
"value": "0.55",
"currency": "USD"
},
"cashOrderQty": {
"value": "0.55",
"currency": "USD"
},
"insertTime": "2023-11-07T05:31:56Z",
"createTime": "2023-11-07T05:31:56Z",
"outcomeSide": "OUTCOME_SIDE_YES",
"action": "ORDER_ACTION_BUY"
},
"lastShares": "<string>",
"lastPx": {
"value": "0.55",
"currency": "USD"
},
"type": "EXECUTION_TYPE_NEW",
"text": "<string>",
"orderRejectReason": "ORD_REJECT_REASON_EXCHANGE_OPTION",
"transactTime": "2023-11-07T05:31:56Z",
"legPrices": [
{
"marketSlug": "<string>",
"anchor": true,
"px": {
"value": "0.55",
"currency": "USD"
},
"qty": "<string>",
"side": "ORDER_SIDE_BUY",
"referencePx": "<string>"
}
],
"tradeId": "<string>",
"aggressor": true,
"commissionNotionalCollected": {
"value": "0.55",
"currency": "USD"
},
"unsolicitedCancelReason": "UNSOLICITED_CXL_REASON_CONNECTION_LOSS",
"traceId": "<string>",
"commissionSpreadPx": {
"value": "0.55",
"currency": "USD"
},
"transactTradeDate": "2023-11-07T05:31:56Z"
}
]
}Documentation Index
Fetch the complete documentation index at: https://docs.polymarket.us/llms.txt
Use this file to discover all available pages before exploring further.
Your API key ID (UUID). Generate at polymarket.us/developer.
Unix timestamp in milliseconds. Must be within 30 seconds of server time.
Base64-encoded Ed25519 signature of timestamp + method + path. See Authentication for details.
Request to create a new order
Request to create a new order.
Unique market slug into which the order should be entered
Type of order (limit or market)
ORDER_TYPE_LIMIT, ORDER_TYPE_MARKET Order price and currency. Required for limit orders.
Show child attributes
Order quantity in shares
Order time in force policy
TIME_IN_FORCE_DAY, TIME_IN_FORCE_GOOD_TILL_CANCEL, TIME_IN_FORCE_GOOD_TILL_DATE, TIME_IN_FORCE_IMMEDIATE_OR_CANCEL, TIME_IN_FORCE_FILL_OR_KILL If true, order must rest on the book prior to matching (maker only). Order will be rejected if it would immediately match.
Expiration time for orders with TIME_IN_FORCE_GOOD_TILL_DATE
Order intent. Either intent or (outcomeSide + action) must be set.
ORDER_INTENT_BUY_LONG, ORDER_INTENT_SELL_LONG, ORDER_INTENT_BUY_SHORT, ORDER_INTENT_SELL_SHORT Outcome side. Set with action as an alternative to intent. Takes priority if both are set.
OUTCOME_SIDE_YES, OUTCOME_SIDE_NO Order action. Set with outcomeSide as an alternative to intent.
ORDER_ACTION_BUY, ORDER_ACTION_SELL Order quantity in cash and currency. Used for market orders instead of share quantity.
Show child attributes
Indicates whether the order was placed manually or automatically
MANUAL_ORDER_INDICATOR_MANUAL, MANUAL_ORDER_INDICATOR_AUTOMATIC If true, will block until the order is filled, rejected, canceled, or expired, up to maxBlockTime seconds
Maximum block time in seconds if synchronous execution is requested
Slippage tolerance configuration for the order
Show child attributes