POST /v1/get_quote
Request a spot quote
Returns a quote for the requested symbol, side and quantity. Requires ViewQuotes, SubmitRfq and access to the requested product and market. Supply market when the symbol is available in multiple eligible markets. Retries with the same Idempotency-Key and body return the original quote, including its original price and expires_at. Replay requires read access.
ApiKeyAuthorizationBearer <token>Send Authorization: Bearer over HTTPS. Each key is associated with an account and environment. Invalid, expired or revoked keys return 401.
Idempotency-Key*stringClient-generated UUID, scoped to account and operation. Use the same UUID and body for retries. Decimal strings are normalized and JSON property order is ignored when comparing requests. A changed request with the same UUID returns idempotency_conflict.
uuid36 <= length <= 36X-Request-ID?stringOptional request tracing UUID. The server generates one if omitted.
uuid36 <= length <= 36application/json- body
symbol*SymbolDistinct base/quote asset codes, such as BTC/USD.
market?|Required on market_required; omission and null are equivalent.
side*SideClient perspective. Buy acquires base and owes quote; sell delivers base and receives quote. Price is quote-asset units per one base unit.
"buy""sell"quantity*DecimalBase units; never resized by pricing.
1 <= length <= 39Quote with price, pay/receive amounts and expires_at.
application/json- response
Quoted price, final pay/receive amounts and expiry. Use pay and receive as the complete exchange amounts.
quote_id*QuoteIdCryptographically random server-generated UUIDv4. Nonselectable and immutably account-bound. Knowledge of an ID never grants access.
uuid36 <= length <= 36symbol*SymbolDistinct base/quote asset codes, such as BTC/USD.
market*Marketside*SideClient perspective. Buy acquires base and owes quote; sell delivers base and receives quote. Price is quote-asset units per one base unit.
"buy""sell"price*CanonicalDecimalQuote-asset units per base unit.
1 <= length <= 39pay*receive*issued_at*UtcTimestampExclusive expiry. Retry never refreshes the quote.
date-timeexpires_at*UtcTimestampExclusive expiry. Retry never refreshes the quote.
date-timecurl -X POST 'https://api.elkcrypto.com/sandbox/v1/get_quote' \ -H 'Idempotency-Key: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \ -H 'Content-Type: application/json' \ -d '{ "symbol": "BTC/USD", "side": "buy", "quantity": "0.25"}'{ "quote_id": "3c071a1d-db86-46a7-9dc8-72ba3fbca992", "symbol": "string", "market": "string", "side": "buy", "price": "string", "pay": { "asset": "string", "amount": "string" }, "receive": { "asset": "string", "amount": "string" }, "issued_at": "2019-08-24T14:15:22Z", "expires_at": "2019-08-24T14:15:22Z"}GET/v1/catalogueProducts and pricing availability
Lists products available to your account, including quantity rules and pricing availability. Requires ViewQuotes and an approved source IP. Use limit and after_id for pagination. No request body is required.
POST/v1/acceptAccept a quote
Accepts a quote by quote_id using its original terms. Requires ViewQuotes, AcceptTrade, product and market access, and sufficient funds or credit. The quote must be unexpired for a new acceptance. Use a distinct Idempotency-Key for acceptance; retries with that key and body return the existing order and its current status, including after quote expiry. Replay requires read access.