Skip to main content

Asset

5 endpoints

GET /assets List all assets

list all available assets.

Parameters

name
string · query
Asset name
symbol
string · query
Asset symbol
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

Responses

200
401 Unauthorized
GET https://api.qa.onyze.pro/v1/assets
Response 200
[
{
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"name": "Bitcoin",
"symbol": "BTC",
"rate": {
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"asset": "...",
"fiatPrice": 10
},
"marketData": {}
}
]
GET /assets/{asset} Find asset by id

Find asset by id

Parameters

asset required
string · path
id parameter must be included in the URI

Responses

200
401 Unauthorized
404 Not found
GET https://api.qa.onyze.pro/v1/assets/{asset}
Response 200
{
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"name": "Bitcoin",
"symbol": "BTC",
"rate": {
"id": "d8vJIh-H",
"createdAt": "2018-08-17T17:04:55.626Z",
"updatedAt": "2018-08-21T18:24:17.185Z",
"asset": "...",
"fiatPrice": 10
},
"marketData": {}
}
GET /assets/{asset}/available Get available to sell

Parameters

asset required
string · path
id parameter must be included in the URI
action
string (enum) · query
Order Action (BUY or SELL)

Responses

200
400 Bad request
401 Unauthorized
404 Not found
GET https://api.qa.onyze.pro/v1/assets/{asset}/available
Response
// Success
GET /assets/{asset}/market-data Get market data for the asset

Obtain market data associated to the asset (volume, supply, daily % change, etc).

Parameters

asset required
string · path
Asset id. Use * to get data for all assets
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
lastUpdatedAfter required
object · query
Last updated after date
lastUpdatedBefore required
object · query
Last updated before date
assetSymbol
string (enum) · query
createdAfter
string · query
Created after date
createdBefore
string · query
Created before date

Responses

200
400 Bad request
401 Unauthorized
GET https://api.qa.onyze.pro/v1/assets/{asset}/market-data
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"
},
"volume24h": "7155680000",
"percentChange1h": "-0.152774",
"percentChange24h": "0.518894",
"percentChange7d": "0.986573",
"circulatingSupply": "16950100",
"totalSupply": "16950100",
"maxSupply": "21000000",
"lastUpdated": "2019-08-21T18:24:17.185Z"
}
]
GET /assets/{asset}/market-data/{marketDataId} Get Market Data by id

Find asset market data by id.

Parameters

marketDataId required
string · path
id parameter must be included in the URI
asset required
object · path
id parameter must be included in the URI

Responses

200
401 Unauthorized
404 Not found
GET https://api.qa.onyze.pro/v1/assets/{asset}/market-data/{marketDataId}
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"
},
"volume24h": "7155680000",
"percentChange1h": "-0.152774",
"percentChange24h": "0.518894",
"percentChange7d": "0.986573",
"circulatingSupply": "16950100",
"totalSupply": "16950100",
"maxSupply": "21000000",
"lastUpdated": "2019-08-21T18:24:17.185Z"
}