Rate
3 endpoints
GET
/assets/{assetId}/rates
List all rates
List all rates.
Parameters
assetId required
page
Page number of the records list
limit
Max number of records by page. limit=0 to return all records
sort
Sort the response PARAM or -PARAM
createdAfter
Created after date
createdBefore
Created before date
interval
Interval in days or hours 1-24h / 1-365d
assetSymbol
type
Responses
200
401
Unauthorized
GET https://api.qa.onyze.pro/v1/assets/{assetId}/rates
Response 200
[
{
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"asset": {
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"name": "Bitcoin",
"symbol": "BTC"
},
"fiatPrice": 10,
"fiatCurrency": 12,
"type": "coinmarketcap"
}
]
GET
/assets/{assetId}/rates/exchange
Find exchange rate
Obtain rate directly from the exchange provider.
Parameters
assetId required
side
Exchange rate side (buy | sell)
Responses
200
401
Unauthorized
404
Not found
GET https://api.qa.onyze.pro/v1/assets/{assetId}/rates/exchange
Response 200
[
{
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"asset": {
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"name": "Bitcoin",
"symbol": "BTC"
},
"fiatPrice": 10,
"fiatCurrency": 12,
"type": "coinmarketcap"
}
]
GET
/assets/{assetId}/rates/{rate}
Find the rate by id
Find an existing rate by its id.
Parameters
rate required
id parameter must be included in the URI
assetId required
Responses
200
401
Unauthorized
404
Not found
GET https://api.qa.onyze.pro/v1/assets/{assetId}/rates/{rate}
Response 200
{
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"asset": {
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"name": "Bitcoin",
"symbol": "BTC",
"rate": {},
"marketData": {}
},
"fiatPrice": 10,
"fiatCurrency": 12,
"type": "coinmarketcap"
}