Address
/openApi/entrust/historyList
Receiving parameter
Submit
Example
curl -d /openApi/entrust/historyList
Submit parameter
ParamName |
Y/N |
Type |
Example |
Description |
symbol |
No |
string |
|
Trading pair (current trading pair must submit, all trading pairs do not submit) |
from |
No |
int |
122 |
Query start order_sn |
direct |
No |
string |
prev |
Query direction (default prev), prev forward, time (or ID) reverse; next backward, time (or ID) positive order. (example: 1, 2, 3, 4, 5. From = 4, prev has 3, 2, 1; next only 5) |
limit |
No |
int |
20 |
Number result sets returned by paging, which defaults to 20 and Max to 100(see details at paging) |
Return example
ParamName |
Y/N |
Type |
Example |
Description |
errno |
Yes |
int |
0 |
Status code |
errmsg |
Yes |
success |
success |
Status information |
result |
Yes |
list |
See the example |
List |
RESULT Parameter Instructions
ParamName |
Y/N |
Type |
Example |
Description |
order_id |
Yes |
integer |
|
Order ID |
order_sn |
Yes |
string |
|
Order No |
symbol |
Yes |
string |
|
Trading pair |
ctime |
Yes |
string |
|
Entrusted time |
type |
Yes |
int |
1 |
Types:1=Market,2=Limit |
side |
Yes |
string |
buy |
Direction:buy/sell |
price |
Yes |
String |
|
Price: Market price (type=1) is 0 |
number |
Yes |
String |
3.12 |
Quantity: Market price is 0 when buying (type=1, side=buy) |
total_price |
Yes |
String |
|
Total: Market price is 0 when selling (type=1, side=sell) |
deal_number |
Yes |
String |
|
Orders |
deal_price |
Yes |
String |
|
Price |
status |
Yes |
int |
1 |
Status :1=Maker 2=Partial traded 3=Traded 4=Cancelled,5=Partial cancellation 6=Cancelled |
Return example
{
"errno": 0,
"errmsg": "success",
"result": [{
"order_id":121,
"order_sn":"BL123456789987523",
"symbol":"MCO-BTC",
"ctime":"2018-10-02 10:33:33",
"type":"2",
"side":"buy",
"price":"0.123456",
"number":"1.0000",
"total_price":"0.123456",
"deal_number":"0.00000",
"deal_price":"0.00000",
"status":1
},
{
"order_id":122,
"order_sn":"SL123456789987523",
"symbol":"MCO-BTC",
"ctime":"2018-10-02 10:33:33",
"type":"2",
"side":"sell",
"price":"0.123456",
"number":"1.0000",
"total_price":"0.123456",
"deal_number":"0.00000",
"deal_price":"0.00000",
"status":1
},
{
"order_id":123,
"order_sn":"BM123456789987523",
"symbol":"MCO-BTC",
"ctime":"2018-10-02 10:33:33",
"type":"1",
"side":"buy",
"price":"0",
"number":"0",
"total_price":"1",
"deal_number":"0.00000",
"deal_price":"0.00000",
"status":1
},
{
"order_id":124,
"order_sn":"SM123456789987523",
"symbol":"MCO-BTC",
"ctime":"2018-10-02 10:33:33",
"type":"1",
"side":"sell",
"price":"0",
"number":"1.0000",
"total_price":"0",
"deal_number":"0.00000",
"deal_price":"0.00000",
"status":1
}
]
}
Comments
0 comments
Article is closed for comments.