curl --request POST \
--url https://api.enterprise.sandbox.uphold.com/trading/orders \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"clientOrderId": "3a9e1f7c-2d4b-4e6a-8c1f-5b7d9e2a4c61",
"side": "sell",
"type": "market",
"origin": {
"type": "account",
"id": "651ffcd3-a706-4c91-82ce-5a5eb9c1da62"
},
"destination": {
"type": "account",
"id": "9a3d7e4b-2c1f-4e8d-b7a6-5f4e3d2c1b0a"
},
"quantity": "0.5",
"timeInForce": "fok"
}
'{
"order": {
"id": "0192f3a1-7c2e-7d4b-9a1f-3e5c8b2d4f60",
"clientOrderId": "8d5f1c0e-1b2a-4c3d-9e8f-77a0b1c2d3e4",
"side": "sell",
"type": "limit",
"origin": {
"type": "account",
"id": "651ffcd3-a706-4c91-82ce-5a5eb9c1da62"
},
"destination": {
"type": "account",
"id": "9a3d7e4b-2c1f-4e8d-b7a6-5f4e3d2c1b0a"
},
"quantity": "0.5",
"price": "61500.00",
"timeInForce": "fok",
"status": "completed",
"execution": {
"quantity": "0.5",
"notional": "30959.57",
"averagePrice": "61919.14"
},
"timeline": [
{
"event": "created",
"timestamp": "2026-10-12T10:31:04.512Z"
},
{
"event": "filled",
"timestamp": "2026-10-12T10:31:05.104Z"
}
],
"createdAt": "2026-10-12T10:31:04.512Z",
"updatedAt": "2026-10-12T10:31:05.104Z",
"completedAt": "2026-10-12T10:31:05.104Z"
}
}Orders
Create order
Create an order to sell an asset.
POST
/
trading
/
orders
curl --request POST \
--url https://api.enterprise.sandbox.uphold.com/trading/orders \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"clientOrderId": "3a9e1f7c-2d4b-4e6a-8c1f-5b7d9e2a4c61",
"side": "sell",
"type": "market",
"origin": {
"type": "account",
"id": "651ffcd3-a706-4c91-82ce-5a5eb9c1da62"
},
"destination": {
"type": "account",
"id": "9a3d7e4b-2c1f-4e8d-b7a6-5f4e3d2c1b0a"
},
"quantity": "0.5",
"timeInForce": "fok"
}
'{
"order": {
"id": "0192f3a1-7c2e-7d4b-9a1f-3e5c8b2d4f60",
"clientOrderId": "8d5f1c0e-1b2a-4c3d-9e8f-77a0b1c2d3e4",
"side": "sell",
"type": "limit",
"origin": {
"type": "account",
"id": "651ffcd3-a706-4c91-82ce-5a5eb9c1da62"
},
"destination": {
"type": "account",
"id": "9a3d7e4b-2c1f-4e8d-b7a6-5f4e3d2c1b0a"
},
"quantity": "0.5",
"price": "61500.00",
"timeInForce": "fok",
"status": "completed",
"execution": {
"quantity": "0.5",
"notional": "30959.57",
"averagePrice": "61919.14"
},
"timeline": [
{
"event": "created",
"timestamp": "2026-10-12T10:31:04.512Z"
},
{
"event": "filled",
"timestamp": "2026-10-12T10:31:05.104Z"
}
],
"createdAt": "2026-10-12T10:31:04.512Z",
"updatedAt": "2026-10-12T10:31:05.104Z",
"completedAt": "2026-10-12T10:31:05.104Z"
}
}
Places a fill-or-kill order to sell an asset between two accounts of a user.
The
origin and destination accounts must belong to the same user. The origin holds the base asset and the destination the quote asset. The order is sized by its quantity of the base asset.
A 201 means the order was created, not that it traded: check its status and timeline. When you repeat a request, send the same clientOrderId, so the order is not placed twice. A 429 means too many orders were being placed at the same time: nothing was created, so send the order again after a moment. Read more about orders.Body
application/json
Was this page helpful?