Skip to main content
POST
Execute FX Quote
Executes a quote at the price it was issued with: the source currency is debited from the account and the target currency credited, less any platform_fee. The endpoint takes no request body, and requires write access on the fx scope. Execution requires that the quote exists on this account, has not expired, has not been executed, and that the account is active. Any other case, including an unknown quote_id, returns 422 FX_QUOTE_INVALID. Unlike other endpoints, an unknown id here returns 422, not 404. Branch on error.code. Execution is not replayable. A successful execute marks the quote executed, so retrying the same call returns FX_QUOTE_INVALID. Treat the first 2xx as authoritative, and request a new quote to trade again. When execution fails after the quote is accepted, the request still returns HTTP 200 with status: "failed" and the source funds released. No conversion happened. Always check status in the response body; a 2xx alone does not mean the trade completed.

Path Parameters

string
required
The account’s external ID (starts with acct_)
string
required
The FX quote’s external ID (starts with fxq_)

Response

string
FX trade identifier (starts with fxt_)
string
Always returns "fx_trade"
string
Account ID
string
The executed quote’s ID. On the trade object it is null for trades Hop books manually; an execute always returns the quote you executed.
string
Source currency code
string
Target currency code
string
Which side was fixed on the quote: source or target
string
Source currency amount debited (decimal)
string
Target currency amount (decimal), before any platform fee
object
Platform fee deducted from target_amount (currency, amount). Always present, and null when there is no fee.
string
All-in rate including spread, expressed as target_amount / source_amount: target units per one source unit, quantised to the pair’s rate precision (commonly 8 decimal places)
string
Trade status: processing, completed, failed, or voided. An execute returns completed or failed; voided only ever appears on a trade Hop has reversed.
string
market, manual, or reversal. An execute always returns market; the other two belong to trades Hop books on your behalf and show up in List FX Trades.
string
ISO 8601 timestamp when the trade was executed
string
ISO 8601 timestamp when the trade was voided, or null
string
Why the trade was voided, or null
string
Identifier of the reversal trade that voided this one (starts with fxt_), or null.
string
Internal note carried on the trade. Always null for trades executed through the API.
string
ISO 8601 timestamp when created
string
ISO 8601 timestamp when last updated
string
ID of the API key that executed the trade (starts with ak_)
string
Actor that last updated the trade, or null

Errors

Response Example