Skip to main content

Rate

3 endpoints

GET /assets/{assetId}/rates List all rates

List all rates.

Parameters

assetId required
string · path
page
number · query
Page number of the records list
limit
number · query
Max number of records by page. limit=0 to return all records
sort
string · query
Sort the response PARAM or -PARAM
createdAfter
string · query
Created after date
createdBefore
string · query
Created before date
interval
string · query
Interval in days or hours 1-24h / 1-365d
assetSymbol
string (enum) · query
type
string (enum) · query

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
string · path
side
string (enum) · query
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
string · path
id parameter must be included in the URI
assetId required
string · path

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"
}