API reference ยท Markets
GET
/v1/markets/{market}Get a market.
No key
Path parameters#
-
A market id.
Responses#
200OK
-
A market id: the asset and USD.
-
The market's name.
-
Whether the market trades now.
One of
openhaltedclosed -
Prices are multiples of this.
-
Sizes are multiples of this, in the base asset.
-
The smallest order size.
-
The highest leverage on this market.
-
The fee on each fill, in percent of its value.
-
The most you may hold on this market across your accounts on the same rule, in USD.
-
How far from the price a market order may fill, in percent.
404The market is not offered.
{
"error": {
"type": "not_found",
"code": "market_not_found",
"message": "No market with that id.",
"request_id": "req_0f9c2a7d8e1b4c6a9f3e5d7b1a2c4e6f",
"retryable": false,
"doc_url": "https://docs.phoenixperpsfunding.com/reference/errors#market_not_found"
}
}429A request budget is used up (details.scope says which).
{
"error": {
"type": "rate_limit",
"code": "rate_limited",
"message": "Too many requests: slow down.",
"request_id": "req_0f9c2a7d8e1b4c6a9f3e5d7b1a2c4e6f",
"retryable": true,
"doc_url": "https://docs.phoenixperpsfunding.com/reference/errors#rate_limited"
}
}500An error we did not expect.
{
"error": {
"type": "server",
"code": "internal_error",
"message": "Something went wrong on our side.",
"request_id": "req_0f9c2a7d8e1b4c6a9f3e5d7b1a2c4e6f",
"retryable": true,
"doc_url": "https://docs.phoenixperpsfunding.com/reference/errors#internal_error"
}
}503The API is starting and has not loaded your keys yet.
{
"error": {
"type": "engine",
"code": "not_ready",
"message": "The API is starting. Try again in a moment.",
"request_id": "req_0f9c2a7d8e1b4c6a9f3e5d7b1a2c4e6f",
"retryable": true,
"doc_url": "https://docs.phoenixperpsfunding.com/reference/errors#not_ready"
}
}Errors#
Codes this endpoint can return. Match on the code, never on the message.