Get Repayment Order Detail
Covers: Margin trade (Classic Account)
HTTP Request
GET /v5/spot-cross-margin-trade/repay-history
Request Parameters
Parameter | Required | Type | Comments |
---|---|---|---|
startTime | false | long | The start timestamp (ms) |
endTime | false | long | The end timestamp (ms) |
coin | false | string | Coin name |
limit | false | integer | Limit for data size per page. [1 , 500 ], Default: 500 |
Response Parameters
Parameter | Type | Comments |
---|---|---|
list | array | Object |
> accountId | string | Account ID |
> coin | string | Coin name |
> repaidAmount | string | Repaid amount |
> repayId | string | Repay ID |
> repayMarginOrderId | string | Repay margin order ID |
> repayTime | string | Repay timestamp (ms) |
> transactIds | array | Object |
>> repaidInterest | string | Interest repaid |
>> repaidPrincipal | string | Principal repaid |
>> repaidSerialNumber | string | Repayment No. (Borrowing Order) |
>> transactId | string | Borrowing transaction ID |
Request Example
- HTTP
- Python
GET /v5/spot-cross-margin-trade/repay-history?coin=ETH&limit=1 HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-API-KEY: XXXXXXX
X-BAPI-TIMESTAMP: 1677755884678
X-BAPI-RECV-WINDOW: 5000
X-BAPI-SIGN: XXXXXXX
from pybit.unified_trading import HTTP
session = HTTP(
testnet=True,
api_key="XXXXX",
api_secret="XXXXX",
)
print(session.spot_margin_trade_normal_get_repayment_order_detail(
coin="ETH",
limit=1,
))
Response Example
{
"retCode": 0,
"retMsg": "success",
"result": {
"list": [
{
"accountId": "592335",
"coin": "ETH",
"repaidAmount": "10.0001",
"repayId": "19070",
"repayMarginOrderId": "1367476828218072576",
"repayTime": "1677751941000",
"transactIds": [
{
"repaidAmount": "10.0001",
"repaidInterest": "0.0001",
"repaidPrincipal": "10",
"repaidSerialNumber": "1367475973544746496",
"transactId": "21005"
}
]
}
]
},
"retExtInfo": {},
"time": 1677755885169
}