Skip to main content

Place order

POST 

/v1/orders

Place a limit or market order. Either the buy amount or sell amount is required, but not both. If the order is not immediately filled or killed, but rather it is returned back with 'pending' status, then it may be necessary to try to retrieve the order again later for status updates.

Request

Body

    order_type OrderType (string)required

    Order type may be either limit order or market order.

    Possible values: [limit, market]

    Default value: limit
    client_order_id string

    Client's unique identifier for the order.

    buy_currency stringrequired

    The currency that you want to buy.

    Example: USD
    sell_currency stringrequired

    The currency that you want to sell.

    Example: BRL
    buy_amount double

    The amount that you want to buy.

    Example: 1000
    sell_amount double

    The amount that you want to sell.

    Example: 0
    tenor TenorREST (string)

    The tenor value for the quote e.g. SPOT, CASH (T+0), NEXT DAY (T+1)

    Possible values: [SPOT, TOD, TOM]

    Default value: SPOT
    Example: SPOT
    sources string[]

    Restrict quotes to specified sources.

    Example: ["CAB","Corpay"]
    limit_price double

    Limit price for the order using market conventions. Valid for limit orders only.

    Example: 3.141592
    instrument string

    Instrument for limit price. Valid for limit orders only.

    Possible values: >= 6 characters and <= 6 characters

    Example: USDBRL
    order_notes string

    Order notes.

    Possible values: <= 256 characters

    Example: My order notes

Responses

Order successfully placed.

Schema

    order

    object

    required

    An Order can placed and filled or klled (FoK). A fill may result in a Trade. Both limit and market order types are supported.

    id stringrequired

    Unique identifier for the order

    order_type OrderType (string)required

    Order type may be either limit order or market order.

    Possible values: [limit, market]

    Default value: limit
    order_state stringrequired

    Current fulfillment state of the order

    client_order_id stringrequired

    Client's unique identifier for the order.

    buy_currency stringrequired

    The currency that you want to buy.

    sell_currency stringrequired

    The currency that you want to sell.

    buy_amount double

    The amount that you want to buy.

    sell_amount double

    The amount that you want to sell.

    tenor TenorREST (string)required

    The tenor value for the quote e.g. SPOT, CASH (T+0), NEXT DAY (T+1)

    Possible values: [SPOT, TOD, TOM]

    Default value: SPOT
    Example: SPOT
    sources string[]

    Restrict quotes to specified sources.

    limit_price double

    limit price for the order using market conventions. Valid for limit orders only.

    order_notes string

    Order notes.

    Possible values: <= 256 characters

    status

    object

    Order status for the specified order id.

    status stringrequired

    Order status for given order id.

    Possible values: [pending, filled, killed]

    timestamp date-time

    Timestamp of last status update.

    quote

    object

    A Quote may result from a successful quotes request.

    id stringrequired

    The unique identifier for the quote.

    source_id stringrequired

    The source's unique identifier for the quote.

    client_id stringrequired

    The unique identifier fo the client.

    rate doublerequired

    The rate for the quote.

    source stringrequired

    The source of the quote.

    expires int64required

    The quote expiry in milliseconds.

    quote_date date-time

    Quote date.

    status stringrequired

    Rejection status.

    Possible values: [pending, accepted, rejected]

    Default value: pending

    trade

    object

    A Trade may result from a successfully executed order or quote.

    id stringrequired

    Id for the trade.

    source_order_id string

    Source order id for the trade.

    source_execution_id stringrequired

    Source execution id for the trade.

    source stringrequired

    Source for the exected trade.

    buy_currency stringrequired

    The currency that you bought.

    sell_currency stringrequired

    The currency that you sold.

    buy_amount doublerequired

    The amount that you bought.

    sell_amount doublerequired

    The anount that you sold.

    price doublerequired

    The rate for the trade.

    trade_date date-timerequired

    Trade date.

Loading...