Look Up Orders

The method GET /orders/ enables you to retrieve the details of one or more of your orders. The method only returns open or partially filled orders. When the service fully matches or cancels an order, it will not include it in the response. For further details on how to pull the list of trades for a given order, refer to the section, List Order Trades.

You can specify the order's identifier via:

  • A path parameter: Use the Bitso-supplied ID.
  • A query parameter: Use either one or several Bitso-supplied or user-supplied IDs.

HTTP Request

Path Parameters

Use the following path parameter to specify the order:

ParameterDescriptionRequired
oidSpecifies the Bitso-supplied identifier of the order to retrieve.No

Query Parameters

However, if you want to retrieve several orders' details, use either of the following query parameters to identify the orders. When specifying more than one order, use a comma to separate the IDs:

ParameterDescriptionRequired
oidsSpecifies the Bitso-supplied identifiers of the orders to retrieve.No
origin_idsSpecifies by origin ID (client-supplied ID) the orders to retrieve.No

JSON Response Payload

The endpoint returns a JSON array of open orders. Every element in the array is a JSON object that includes the following fields:

Field Name

Description

Type

Units

book

The order book symbol.

String

Major_Minor

created_at

The date and time when the service created the order.

String

ISO 8601 timestamp

oid

The order's ID.

String

original_amount

The order's initial major currency amount.

String

Major

origin_id

The order's client-supplied, unique ID (if any). Valid character set: a to z (lower and uppercase),  0 to 9, underscore, _, and dash, -. Maximum length = 40 characters.

String

original_value

The order's initial minor currency amount.

String

Minor

price

The order's price.

String

Minor

side

The order's side. Possible values: buy and sell.

String

status

The order's status. Possible values: queued, open, partially filled, cancelled, and completed.

  • *NOTE:** A lookup does not return completed or cancelled orders because the endpoint only retrieves open or partially filled orders. However, a one-hour window exists in which retrieval of orders with these status values is possible.

String

stop

The stop price for Stop Orders.

String

time_in_force

The time in force parameter for Limit Orders.

String

triggered_at

The date and time when the service triggered a Stop Order.

String

ISO 8601 timestamp

type

The order's type. Possible values: market and limit.

String

unfilled_amount

The order's unfilled major currency amount.

String

Major

updated_at

The date and time when the service updated the order. It might be "null".

String

ISO 8601 timestamp

cancellation_reason

This optional (nullable) string field is included in the response payload only when the status of an order is cancelled. It provides a specific reason for the cancellation.

Possible Values

  • Forlimit orders:
    -- TIF:post_only
    -- TIF:immediate_or_cancel
    -- TIF:fillorkill
  • Formarket orders:
    -- slippage_threshold
    -- unfilled_market
    -- unfilled_reverse_market

String

The following response object exemplifies the JSON array returned:`

curl https://stage.bitso.com/api/v3/orders?oids=543cr2v32a1h6844,qlbga6b600n3xta7a

{
    "success": true,
    "payload": [{
        "book": "btc_mxn",
        "original_amount": "0.01000000",
        "unfilled_amount": "0.00500000",
        "original_value": "56.0",
        "created_at": "2016-04-08T17:52:31.000+00:00",
        "updated_at": "2016-04-08T17:52:51.000+00:00",
        "price": "5600.00",
        "oid": "543cr2v32a1h6844",
        "side": "buy",
        "status": "partially filled",
        "type": "limit"
    }, {
        "book": "btc_mxn",
        "original_amount": "0.12680000",
        "unfilled_amount": "0.12680000",
        "original_value": "507.2",
        "created_at": "2016-04-08T17:52:31.000+00:00",
        "updated_at": "2016-04-08T17:52:41.000+00:00",
        "price": "4000.00",
        "oid": "qlbga6b600n3xta7a",
        "side": "sell",
        "status": "open",
        "type": "limit"
    }]
}