your current method GET /api/market/ticker is not easily maintainable by clients, because it's supposed to be a JSON array but you're presenting it as a JSON object.
We can of course parse the JSON object, but every time you add a new symbol we'll be forced to amend the code. If instead you give us a JSON array, a new symbol will not break our code/logic.
The proposed API
I am proposing the following API addition, not changing the existing one. Adding a new API method will not break the existing implementation, but it will give your users an alternative (a list) to the current API:
GET /api/market/all-tickers
Description:
Get ticker information for all available symbols.
Query:
None
Response:
[
{
"id": 1,
"symbol": "THB_BTC",
"last": 216415.00,
"lowestAsk": 216678.00,
"highestBid": 215000.00,
"percentChange": 1.91,
"baseVolume": 71.02603946,
"quoteVolume": 15302897.99,
"isFrozen": 0,
"high24hr": 221396.00,
"low24hr": 206414.00
},
{
"id": 2,
"symbol":"THB_ETH",
"last": 11878.00,
"lowestAsk": 12077.00,
"highestBid": 11893.00,
"percentChange": -0.49,
"baseVolume": 455.17839270,
"quoteVolume": 5505664.42,
"isFrozen": 0,
"high24hr": 12396.00,
"low24hr": 11645.00
}
]