This section give's control and information for all the orders performed by any user.
Order can be any Buy/Sell order (Market or Limit) with any currency.
Order must be created with a base amount,base currency,quote amount and quote currency,(and limit amount in case of limit orders).
Admin logged in - can see all the orders created by users.
User logged in - can see it's own orders data,create new orders (in case he has sufficent balance).
Returns a list of all orders (open and closed)
Success
Unauthorized
{- "api_message": "<string>",
- "api_data": {
- "orders": [
- {
- "username": "<string>",
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "null",
- "trade_status": "null",
- "trade_payload": "null",
- "settlement_id": "<string>",
- "ip": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
], - "last_at": "<datetime string>",
- "total_items": 1
}
}
Create new order - must given quote id for market orders
raw(json)
Success
Unauthorized
Internal Server Error
{- "quote_id": "b01vT1VyRC9XVGcrUk9nNnkzVlkybUZ2Ti93ZFdvdVhnUC8rTHd4ZGV1T2gvdDc0Z1J5eFlnPT0",
- "order_type": "MARKET",
- "order_amount": "10000",
- "order_price": "1",
- "spend_currency": "USD",
- "receive_currency": "TBTC",
- "side": "BUY"
}
{- "api_message": "<string>",
- "api_data": {
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "<string>",
- "trade_status": "<string>",
- "trade_payload": "<string>",
- "settlement_id": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
}
Return information about given order_id from orders table
Success
Unauthorized
Forbidden
{- "api_message": "<string>",
- "api_data": {
- "username": "<string>",
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "null",
- "trade_status": "null",
- "trade_payload": "null",
- "settlement_id": "<string>",
- "ip": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
}
Update specific order with given order_id. The order can be updated only if it a limit order
raw(json)
Success
Unauthorized
Internal Server Error
{- "order_type": "LIMIT",
- "order_amount": "1",
- "order_price": "1500",
- "base_currency": "USD",
- "quote_currency": "GTETH",
- "side": "BUY",
- "user_id": "Y0ZuTVFCNnl6S3pISDhMTXVYSHBwZz09"
}
{- "api_message": "<string>",
- "api_data": {
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "<string>",
- "trade_status": "<string>",
- "trade_payload": "<string>",
- "settlement_id": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
}
Returns a list of open orders
Success
Unauthorized
{- "api_message": "<string>",
- "api_data": {
- "orders": [
- {
- "username": "<string>",
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 20000,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "null",
- "trade_status": "null",
- "trade_payload": "null",
- "settlement_id": "<string>",
- "ip": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>",
- "userstatus": "ACTIVE",
- "user_created_at": "datetime string",
- "user_updated_at": "datetime string"
}
], - "last_at": "<datetime string>",
- "total_items": 1
}
}
Return frozen orders list information from orders table
Success
Unauthorized
{- "api_message": "<string>",
- "api_data": {
- "orders": [
- {
- "username": "<string>",
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "null",
- "trade_status": "null",
- "trade_payload": "null",
- "settlement_id": "<string>",
- "ip": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
], - "last_at": "<datetime string>",
- "total_items": 1
}
}
Returns information about LP's balances and available balances per liquidity provider
Success
Unauthorized
Forbidden
{- "api_message": "<string>",
- "api_data": {
- "balance": {
- "[liquidity provider name]": {
- "[currency name]": {
- "balance": 100,
- "availableBalance": 40
}
}
}
}
}
Returns list of closed orders
Success
Unauthorized
{- "api_message": "<string>",
- "api_data": {
- "orders": [
- {
- "username": "<string>",
- "id": "<string>",
- "user_id": "<string>",
- "ref_account_id": "<string>",
- "coid": "<string>",
- "base_currency": "<string>",
- "quote_currency": "<string>",
- "base_amount": 1,
- "quote_amount": 1,
- "lp_amount": 1,
- "limit_amount": 1,
- "discount_rate": 1,
- "side": "<string>",
- "type": "<string>",
- "time_in_force": "<string>",
- "liquidity_id": "<string>",
- "liquidity_rate": 1,
- "user_rate": 1,
- "feerule_id": "<string>",
- "feerule_rate": 1,
- "feerule_currency": "<string>",
- "status": "<string>",
- "payment_id": "<string>",
- "payment_status": "null",
- "trade_status": "null",
- "trade_payload": "null",
- "settlement_id": "<string>",
- "ip": "<string>",
- "created_by_id": "<string>",
- "created_at": "<datetime string>",
- "updated_at": "<datetime string>"
}
], - "last_at": "<datetime string>",
- "total_items": 1
}
}
Get a quote (price) for creating a new order.
raw(json)
Success
Unauthorized
Unprocessable Content
Internal Server Error
{- "quote_id": "K1hQOGs4U3hJS0U9",
- "spend_currency": "TBTC",
- "receive_currency": "USD",
- "order_price": 1,
- "spend_amount": 0.2,
- "side": "SELL"
}
{- "api_message": "<string>",
- "api_data": {
- "quote": {
- "quote_id": "<string>",
- "lp_id": "<string>",
- "lp_name": "<string>",
- "quote_rate": 1,
- "discount_rate": 1,
- "total_fee": 1,
- "feerule_id": "<string>",
- "quote_total_fee": 1,
- "base_amount": 1,
- "side": "BUY",
- "base_currency": "<string>",
- "user_id": "<string>",
- "quote_amount": 1,
- "quote_currency": "<string>",
- "valid": true
}
}
}
Get a quote/quotes for a single or batch spend_currency/receive_currency pairs to get a current prices.
Success
Unauthorized
[- {
- "spend_currency": "EUR",
- "receive_currency": "ETH",
- "spend_amount": "19782.77",
- "side": "SELL"
}
]
{- "api_message": "<string>",
- "api_data": {
- "quotes": [
- {
- "side": "SELL",
- "spend_amount": 100,
- "spend_currency": "BTC",
- "spend_currency_id": "WlBPdmtSY2hITGM9",
- "receive_currency": "USD",
- "receive_currency_id": "Nmw5bEUvMlhGaEE9",
- "rate_with_fee": 69477.567832421,
- "rate_without_fee": 69477.41782269,
- "valid": true
}
]
}
}
Refresh status of all existing orders that not in final status (PENDING orders)
Success
Unauthorized
Internal Server Error
{- "api_message": "<string>",
- "api_data": [ ]
}