v1
latestOpenAPI 3.0.02026-07-26117342409.6 KBQuote Executions
Create Quote Execution
Execute on a quote for buying or selling an asset.
The side, market, and guaranteed price of the execution are specified by the quote with ID quote_id.
The amount to buy or sell must be specified in either fiat or crypto by setting exactly one of:
- base_amount to specify the amount of crypto to buy or sell.
- quote_amount to specify the amount of fiat to spend or acquire.
An otherwise-valid request to create a quote execution may fail with the following types of errors:
- Expired if the quote with ID quote_id has expired.
- Insufficient Funds if the profile with ID profile_id has insufficient available balance to fund the execution.
- Rejected if extreme market conditions (e.g. a very large price swing) have invalidated the quote.
- Already Exists if a Quote Execution with the same ref_id has already been created.
post/profiles/{profile_id}/quote-executions
Path parameters
profile_idstring required
The ID of the profile under which to execute this order.
Request body
Example request
{
"quote_id": "366a26d2-3098-4226-a520-4bb43ae4d922",
"quote_amount": "14102.82",
"metadata": {
"customer_id": "9b8c9cba-801e-4418-adc0-ede709df6339"
}
}Response
A successful response.
Example response
{
"id": "43a59965-be3a-45ab-841d-c55386e0ff90",
"profile_id": "b7b77d82-e6a7-4ae9-9904-36231aedf985",
"quote_id": "366a26d2-3098-4226-a520-4bb43ae4d922",
"status": "SETTLED",
"market": "BTCUSD",
"side": "BUY",
"price": "6001.2",
"base_amount": "2.35",
"base_asset": "BTC",
"quote_amount": "14102.82",
"quote_asset": "USD",
"created_at": "2020-01-17T18:36:31.345Z",
"settled_at": "2020-01-17T18:36:32.123Z",
"metadata": {
"customer_id": "9b8c9cba-801e-4418-adc0-ede709df6339"
}
}