List Trades

The method GET /trades/ enables you to retrieve a list of recent trades from the specified book.

HTTP Request

Query Parameters

You can use the following query parameters in your request:

ParameterDescriptionRequiredDefault Value
bookSpecifies which book to use.Yes
limitSpecifies the number of objects to return. Maximum is 100.No25
markerSpecifies to return older or newer objects (depending on the value of the sort parameter) than the object with the given ID.No
sortSpecifies the ordering direction of returned objects. Valid values: asc, desc.Nodesc

JSON Response Payload

The endpoint returns a descending JSON array of transactions. Every element in the array is a JSON object that contains the following fields:

Field NameDescriptionTypeUnits
amountThe major amount transacted.StringMajor
bookThe order book symbol.StringMajor_Minor
created_atThe date and time when the service executed the trade.StringISO 8601 timestamp
maker_sideAn indicator of the maker order side (maker order is the order that was opened in the order book).String
priceThe price per unit of major.StringMinor
tidThe trade's ID.Long

The following response object exemplifies the JSON array returned:

curl https://api-stage.bitso.com/api/v3/trades?book=btc_mxn

{
    "success": true,
    "payload": [{
        "book": "btc_mxn",
        "created_at": "2016-04-08T17:52:31.000+00:00",
        "amount": "0.02000000",
        "maker_side": "buy",
        "price": "5545.01",
        "tid": 55845
    }, {
        "book": "btc_mxn",
        "created_at": "2016-04-08T17:52:31.000+00:00",
        "amount": "0.33723939",
        "maker_side": "sell",
        "price": "5633.98",
        "tid": 55844
    }]
}