diff --git a/404.html b/404.html index 7bacbf54c7..5f25e02948 100644 --- a/404.html +++ b/404.html @@ -4,13 +4,13 @@ Page Not Found | Bybit API Documentation - +
Skip to main content

Page Not Found

We could not find what you were looking for.

Please contact the owner of the site that linked you to the original URL and let them know their link is broken.

- + \ No newline at end of file diff --git a/account-asset/all-balance.html b/account-asset/all-balance.html index 416b3f907b..8408875f6f 100644 --- a/account-asset/all-balance.html +++ b/account-asset/all-balance.html @@ -4,13 +4,13 @@ Get All Coins Balance | Bybit API Documentation - +
Skip to main content

Get All Coins Balance

You could get all coins balance of all account types under the master account, and sub account.

Important

It is not allowed to get master account coin balance via sub account api key.

HTTP Request

GET /asset/v3/private/transfer/account-coins/balance/query

Request Parameters

ParameterRequiredTypeComments
memberIdfalsestringUser Id. It is required when you use master api key to check sub account coin balance
accountTypetruestringAccount type
coinfalsestringCoin name
  • Query all coins if not passed
  • Can query multiple coins, separated by comma. USDT,USDC,ETH
withBonusfalsestringWhether query bonus or not. 0(default):false; 1:true

Response Parameters

ParameterTypeComments
accountTypestringAccount type
memberIdstringUserID
balancearrayObject
> coinstringCurrency type
> walletBalancestringWallet balance
> transferBalancestringTransferable balance
> bonusstringThe bonus

Request Example

GET /asset/v3/private/transfer/account-coins/balance/query?accountType=FUND&coin=USDT,USDC HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: XXXXX
X-BAPI-API-KEY: XXXXX
X-BAPI-TIMESTAMP: 1675865289817
X-BAPI-RECV-WINDOW: 50000

Response Example

{
"retCode": 0,
"retMsg": "success",
"result": {
"memberId": "533285",
"accountType": "FUND",
"balance": [
{
"coin": "USDT",
"transferBalance": "1010",
"walletBalance": "1010",
"bonus": ""
},
{
"coin": "USDC",
"transferBalance": "0",
"walletBalance": "0",
"bonus": ""
}
]
},
"retExtInfo": {},
"time": 1675865290069
}
- + \ No newline at end of file diff --git a/account-asset/apikey-info.html b/account-asset/apikey-info.html index 0b44cd11af..a99fd1ef26 100644 --- a/account-asset/apikey-info.html +++ b/account-asset/apikey-info.html @@ -4,13 +4,13 @@ Get API Key Information | Bybit API Documentation - +
Skip to main content

Get API Key Information

Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user's api key are applicable.

tip

Any permission can access this endpoint.

HTTP Request

GET /user/v3/private/query-api

Request Parameters

None

Response Parameters

ParameterTypeComments
idstringUnique id. Internal used
notestringThe remark
apiKeystringApi key
readOnlyinteger0:Read and Write. 1:Read only
secretstringAlways ""
permissionsObjectThe types of permission
> ContractTradearrayPermission of contract trade
> SpotarrayPermission of spot
> WalletarrayPermission of wallet
> OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
> DerivativesarrayPermission of derivatives
> CopyTradingarrayPermission of copytrade. Not applicable to sub account, always []
> BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
> ExchangearrayPermission of exchange
> NFTarrayPermission of NFT. Not applicable to sub account, always []
ipsarrayIP bound
typeintegerThe type of api key. 1:personal, 2:connected to the third-party app
deadlineDayintegerThe remaining valid days of api key. Only for those api key with no IP bound or the password has been changed
expiredAtdatetimeThe expiry day of the api key. Only for those api key with no IP bound or the password has been changed
createdAtdatetimeThe create day of the api key
unifiedintegerWhether the account to which the api key belongs is a unified account. 0:regular account; 1:unified margin account
utaintegerWhether the account to which the account upgrade to unified trade account. 0:regular account; 1:unified trade account
userIDintegerUser ID
inviterIDintegerInviter ID (the UID of the account which invited this account to the platform)
vipLevelstringVIP Level
mktMakerLevelstringMarket maker level
affiliateIDintegerAffiliate Id. 0 represents that there is no binding relationship.
rsaPublicKeystringRsa public key
isMasterbooleanIf this api key belongs to master account or not
parentUidstringThe main account uid. Returns "0" when the endpoint is called by main account

Request Example

GET /user/v3/private/query-api HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: xxxxxxxxxxxxx
X-BAPI-API-KEY: xxxxxxxxxxxxx
X-BAPI-TIMESTAMP: 1671177977555
X-BAPI-RECV-WINDOW: 50000

Response Example

{
"retCode": 0,
"retMsg": "",
"result": {
"id": "13770661",
"note": "XXXXXX",
"apiKey": "XXXXXX",
"readOnly": 0,
"secret": "",
"permissions": {
"ContractTrade": [
"Order",
"Position"
],
"Spot": [
"SpotTrade"
],
"Wallet": [
"AccountTransfer",
"SubMemberTransfer"
],
"Options": [
"OptionsTrade"
],
"Derivatives": [
"DerivativesTrade"
],
"CopyTrading": [
"CopyTrading"
],
"BlockTrade": [],
"Exchange": [
"ExchangeHistory"
],
"NFT": [
"NFTQueryProductList"
]
},
"ips": [
"*"
],
"type": 1,
"deadlineDay": 83,
"expiredAt": "2023-05-15T03:21:05Z",
"createdAt": "2022-10-16T02:24:40Z",
"unified": 0,
"uta": 0,
"userID": 24600000,
"inviterID": 0,
"vipLevel": "No VIP",
"mktMakerLevel": "0",
"affiliateID": 0,
"rsaPublicKey": "",
"isMaster": false,
"parentUid": "24617703"
},
"retExtInfo": {},
"time": 1676891757649
}
- + \ No newline at end of file diff --git a/account-asset/asset-info.html b/account-asset/asset-info.html index 176fc7e9ef..22fc3b6c80 100644 --- a/account-asset/asset-info.html +++ b/account-asset/asset-info.html @@ -4,13 +4,13 @@ Get Asset Info | Bybit API Documentation - +
Skip to main content

Get Asset Info

tip

Can query SPOT asset information only

HTTP Request

GET /asset/v3/private/transfer/asset-info/query

Request Parameters

ParameterRequiredTypeComments
accountTypefalsestringAccount type, SPOT in default
coinfalsestringCurrency type

Response Parameters

ParameterTypeComments
spotObject
> statusstring
  • ACCOUNT_STATUS_NORMAL -- NORMAL
  • ACCOUNT_STATUS_UNSPECIFIED -- ABNORMAL
> assetsarrayObject
>> coinstringCurrency type
>> frozenstringFreeze amount
>> freestringFree balance
>> withdrawstringAmount in withdrawing

Request Example

GET /asset/v3/private/transfer/asset-info/query?coin=USDT HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-API-KEY: XXXXXXXXXXX
X-BAPI-TIMESTAMP: 1670924059987
X-BAPI-RECV-WINDOW: 50000
X-BAPI-SIGN: XXXXXXXXXXX

Response Example

{
"retCode": 0,
"retMsg": "success",
"result": {
"spot": {
"status": "ACCOUNT_STATUS_NORMAL",
"assets": [
{
"coin": "USDT",
"frozen": "0",
"free": "61.1428",
"withdraw": ""
}
]
}
},
"retExtInfo": {},
"time": 1670924060108
}
- + \ No newline at end of file diff --git a/account-asset/cancel-withdraw.html b/account-asset/cancel-withdraw.html index 8d0f60f3a9..88ebb94d61 100644 --- a/account-asset/cancel-withdraw.html +++ b/account-asset/cancel-withdraw.html @@ -4,13 +4,13 @@ Cancel withdrawal | Bybit API Documentation - +
Skip to main content

Cancel withdrawal

Cancel withdrawal

HTTP Request

POST /asset/v3/private/withdraw/cancel

Request Parameters

ParameterRequiredTypeComments
idtrueintegerWithdrawal ID. (withdraw request ID in Response Parameters of Withdrawal endpoint)

Response Parameters

ParameterTypeComments
statusintegerCancel application result:
  • 1: SUCCESS
  • 0: FAIL

Request Example

POST /asset/v3/private/withdraw/cancel HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: xxxxxxxxxxx
X-BAPI-API-KEY: xxxxxxxxxxx
X-BAPI-TIMESTAMP: 1671173665186
X-BAPI-RECV-WINDOW: 50000
Content-Type: application/json
Content-Length: 24

{
"id": 1234567890
}

Response Example

{
"retCode": 0,
"retMsg": "success",
"result": {
"status": 1
},
"retExtInfo": {},
"time": 1671173665252
}
- + \ No newline at end of file diff --git a/account-asset/coin-balance.html b/account-asset/coin-balance.html index 3cd476d8f7..001252cd05 100644 --- a/account-asset/coin-balance.html +++ b/account-asset/coin-balance.html @@ -4,7 +4,7 @@ Get Single Coin Balance | Bybit API Documentation - + @@ -12,7 +12,7 @@
Skip to main content

Get Single Coin Balance

You could get a single coin balance under the master account, and sub account coin balance. Also, you can check the transferable amount from master to sub account, sub to master account or sub to sub account, especially for user who has INS loan.

Important

It is not allowed to get master account coin balance via sub account api key.

HTTP Request

GET /asset/v3/private/transfer/account-coin/balance/query

Request Parameters

ParameterRequiredTypeComments
memberIdfalsestringUser Id. It is required when you use master api key to check sub account coin balance
toMemberIdfalsestringUID. Required when querying the transferable balance between different uids
accountTypetruestringAccount type
toAccountTypefalsestringTo account type. Required when querying the transferable balance between different account types
cointruestringCoin name
withBonusfalseintegerWhether query bonus or not. 0(default):false; 1:true
withTransferSafeAmountfalseintegerWhether query delay withdraw/transfer safe amount
withLtvTransferSafeAmountfalseintegerFor OTC loan users in particular, you can check the transferable amount under risk level
  • 0(default):false, 1:true
  • toAccountType is mandatory

Response Parameters

ParameterTypeComments
accountTypestringAccount type
bizTypeintegerAccount business subtype
accountIdstringAccountID
memberIdstringUserID
balanceObject
> coinstringCurrency type
> walletBalancestringWallet balance
> transferBalancestringTransferable balance
> bonusstringThe bonus
> transferSafeAmountstringSafe amount to transfer. Keep "" if not query
> ltvTransferSafeAmountstringTransferable amount for ins loan account. Keep "" if not query

Request Example

GET /asset/v3/private/transfer/account-coin/balance/query?accountType=CONTRACT&coin=USDT&withTransferSafeAmount=1&withBonus=1 HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: XXXXXX
X-BAPI-API-KEY: XXXXXX
X-BAPI-TIMESTAMP: 1678794085278
X-BAPI-RECV-WINDOW: 50000

Response Example

{
"retCode": 0,
"retMsg": "success",
"result": {
"accountType": "CONTRACT",
"bizType": 1,
"accountId": "533285",
"memberId": "533285",
"balance": {
"coin": "USDT",
"walletBalance": "0",
"transferBalance": "-995.3506",
"bonus": "995.3506",
"transferSafeAmount": "-995.3506",
"ltvTransferSafeAmount": ""
}
},
"retExtInfo": {},
"time": 1678794085705
}
- + \ No newline at end of file diff --git a/account-asset/coin-info.html b/account-asset/coin-info.html index 4a9baf1870..c93e0e0ebb 100644 --- a/account-asset/coin-info.html +++ b/account-asset/coin-info.html @@ -4,13 +4,13 @@ Get Coin Information | Bybit API Documentation - +
Skip to main content

Get Coin Information

Query Coin Information

HTTP Request

GET /asset/v3/private/coin-info/query

Request Parameters

ParameterRequiredTypeComments
coinfalsestringcoin name

Response Parameters

ParameterTypeComments
rowsarrayObject
> namestringName
> coinstringCoin name
> remainAmountstringCurrent maximum withdrawal amount
> chainsarrayObject
>> chainTypestringchain type
>> confirmationstringdeposit confirmation number
>> withdrawFeestringwithdraw fee
  • If withdraw fee is empty, It means that this coin does not support withdrawal
  • If withdraw fee is zero, the fee might be calculated by percentage, we will add a new field later
>> depositMinstringminimum deposit amount
>> withdrawMinstringminimum withdrawal amount
>> chainstringchain name
>> chainDepositstringThe chain status of deposit. 0:suspend; 1:normal
>> chainWithdrawstringThe chain status of deposit. 0:suspend; 1:normal
>> minAccuracystringThe precision of withdraw or deposit
>> withdrawPercentageFeestringThe withdraw fee percentage. It is a real figure, e.g., 0.022 means 2.2%

Request Example

GET /asset/v3/private/coin-info/query?coin=ETH HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-API-KEY: xxxxxxxxxxx
X-BAPI-TIMESTAMP: 1671172180432
X-BAPI-RECV-WINDOW: 50000
X-BAPI-SIGN: xxxxxxxxxxx

Response Example

{
"retCode": 0,
"retMsg": "",
"result": {
"rows": [
{
"name": "ETH",
"coin": "ETH",
"remainAmount": "1020000",
"chains": [
{
"chainType": "ETH",
"confirmation": "10000",
"withdrawFee": "0.005",
"depositMin": "0.01",
"withdrawMin": "0.02",
"chain": "ETH",
"chainDeposit": "1",
"chainWithdraw": "1",
"minAccuracy": "8",
"withdrawPercentageFee": "0.022"
},
{
"chainType": "Arbitrum One",
"confirmation": "10",
"withdrawFee": "0.01",
"depositMin": "0.001",
"withdrawMin": "0.1",
"chain": "ARBI",
"chainDeposit": "1",
"chainWithdraw": "1",
"minAccuracy": "8",
"withdrawPercentageFee": "0"
}
]
}
]
},
"retExtInfo": {},
"time": 1677478088215
}
- + \ No newline at end of file diff --git a/account-asset/create-subuid-apikey.html b/account-asset/create-subuid-apikey.html index 09cdb0723b..f352e9d438 100644 --- a/account-asset/create-subuid-apikey.html +++ b/account-asset/create-subuid-apikey.html @@ -4,13 +4,13 @@ Create Sub UID API Key | Bybit API Documentation - +
Skip to main content

Create Sub UID API Key

To create new API key for those newly created sub UID. Use master user's api key only.

tip

The API key must have one of the below permissions in order to call this endpoint..

  • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

HTTP Request

POST /user/v3/private/create-sub-api

Request Parameters

ParameterRequiredTypeComments
subuidtrueintegerSub user Id
notefalsestringSet a remark
readOnlytrueinteger0:Read and Write. 1:Read only
ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
  • don't pass ips or pass with "*" means no bind
  • No ip bound api key will be invalid after 90 days
  • api key without IP bound will be invalid after 7 days once the account password is changed
permissionstrueObjectTick the types of permission.
  • one of below types must be passed, otherwise the error is thrown
> ContractTradefalsearrayContract Trade. ["Order","Position"]
> SpotfalsearraySpot Trade. ["SpotTrade"]
> WalletfalsearrayWallet. ["AccountTransfer","SubMemberTransferList"]
> OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
> DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
> ExchangefalsearrayExchange. ["ExchangeHistory"]
> CopyTradingfalsearrayCopytrade. ["CopyTrading"]

Response Parameters

ParameterTypeComments
idstringUnique id. Internal used
notestringThe remark
apiKeystringApi key
readOnlyinteger0:Read and Write. 1:Read only
secretstringThe secret paired with api key.
  • The secret can't be queried by GET api. Please keep it properly
permissionsObjectThe types of permission
> ContractTradearrayPermisson of contract trade
> SpotarrayPermisson of spot
> WalletarrayPermisson of wallet
> OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
> DerivativesarrayPermission of Unified account
> CopyTradingarrayPermission of copytrade
> BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
> ExchangearrayPermission of exchange
> NFTarrayPermission of NFT. Not applicable to sub account, always []

Request Example

POST /user/v3/private/create-sub-api HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: xxxxxxxxxxxxx
X-BAPI-API-KEY: xxxxxxxxxxxxx
X-BAPI-TIMESTAMP: 1671176685767
X-BAPI-RECV-WINDOW: 50000
Content-Type: application/json
Content-Length: 796

{
"subuid": 1111111111,
"note": "mytest",
"readOnly": 1,
"ips": "*",
"permissions": {
"ContractTrade": [
"Order",
"Position"
],
"Spot": [
"SpotTrade"
],
"Wallet": [
"AccountTransfer"
],
"Options": [
"OptionsTrade"
],
"CopyTrading": [],
"BlockTrade": [],
"Exchange": [],
"NFT": []
}
}

Response Example

{
"retCode": 0,
"retMsg": "OK",
"result": {
"id": "1111111111",
"note": "mytest",
"apiKey": "xxxxxxxxxxxxx",
"readOnly": 1,
"secret": "xxxxxxxxxxxxx",
"permissions": {
"ContractTrade": [
"Order",
"Position"
],
"Spot": [
"SpotTrade"
],
"Wallet": [
"AccountTransfer"
],
"Options": [
"OptionsTrade"
],
"Derivatives": [
"DerivativesTrade"
],
"CopyTrading": [],
"BlockTrade": [],
"Exchange": [
"ExchangeHistory"
],
"NFT": []
}
},
"retExtInfo": {},
"time": 1671176685954
}
- + \ No newline at end of file diff --git a/account-asset/create-subuid.html b/account-asset/create-subuid.html index 4a1d0cd72f..b31f4c6e39 100644 --- a/account-asset/create-subuid.html +++ b/account-asset/create-subuid.html @@ -4,13 +4,13 @@ Create Sub UID | Bybit API Documentation - +
Skip to main content

Create Sub UID

Create a new sub user id. Use master user's api key only.

tip

The API key must have one of the below permissions in order to call this endpoint..

  • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

HTTP Request

POST /user/v3/private/create-sub-member

Request Parameters

ParameterRequiredTypeComments
usernametruestringGive a username of the new sub user id.
  • 6-16 characters, must include both numbers and letters.
  • cannot be the same as the exist or deleted one.
passwordfalsestringSet the password for the new sub user id.
  • 8-30 characters, must include numbers, upper and lowercase letters.
memberTypetrueinteger1: normal sub account, 6: custodial sub account
switchfalseinteger
  • 0: turn off quick login (default)
  • 1: turn on quick login.
isUtafalseboolean
  • true: create UTA account
  • false(default): create classic account
notefalsestringSet a remark

Response Parameters

ParameterTypeComments
uidstringSub user Id
usernamestringGive a username of the new sub user id.
  • 6-16 characters, must include both numbers and letters.
  • cannot be the same as the exist or deleted one.
memberTypeinteger1: normal sub account, 6: custodial sub account
statusintegerThe status of the user account
  • 1: normal
  • 2: login banned
  • 4: frozen
remarkstringThe remark

Request Example

POST /user/v3/private/create-sub-member HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: xxxxxxxxxxxx
X-BAPI-API-KEY: xxxxxxxxxxxx
X-BAPI-TIMESTAMP: 1671174837503
X-BAPI-RECV-WINDOW: 50000
Content-Type: application/json
Content-Length: 109

{
"username": "testsubaccount",
"memberType": 1,
"switch": 1,
"note": "testnet subaccount"
}

Response Example

{
"retCode": 0,
"retMsg": "OK",
"result": {
"uid": "111111111",
"username": "testsubaccount",
"memberType": 1,
"status": 1,
"remark": "testnet subaccount"
},
"retExtInfo": {},
"time": 1671174837668
}
- + \ No newline at end of file diff --git a/account-asset/delay-amount.html b/account-asset/delay-amount.html index 181c6aa079..b9f10c20ae 100644 --- a/account-asset/delay-amount.html +++ b/account-asset/delay-amount.html @@ -4,13 +4,13 @@ Get Delay Withdraw Amount | Bybit API Documentation - +
Skip to main content

Get Delay Withdraw Amount

info

How can partial funds be subject to delayed withdrawal requests?

  • On-chain deposit: If the number of on-chain confirmations has not reached a risk-controlled level, a portion of the funds will be frozen for a period of time until they are unfrozen.
  • Buying crypto: If there is a risk, the funds will be frozen for a certain period of time and cannot be withdrawn.

HTTP Request

GET /asset/v3/private/withdraw/withdrawable-amount

Request Parameters

ParameterRequiredTypeComments
cointruestringCoin name

Response Parameters

ParameterTypeComments
limitAmountUsdstringThe frozen amount due to risk, in USD
withdrawableAmountarrayObject
> SPOTObjectSpot wallet, it is not returned if spot wallet is removed
>> coinstringCoin name
>> withdrawableAmountstringAmount that can be withdrawn
>> availableBalancestringAvailable balance
> FUNDObjectFunding wallet
>> coinstringCoin name
>> withdrawableAmountstringAmount that can be withdrawn
>> availableBalancestringAvailable balance

Request Example

GET /asset/v3/private/withdraw/withdrawable-amount?coin=USDT HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-API-KEY: XXXXXX
X-BAPI-TIMESTAMP: 1677565621998
X-BAPI-RECV-WINDOW: 50000
X-BAPI-SIGN: XXXXXX

Response Example

{
"retCode": 0,
"retMsg": "success",
"result": {
"limitAmountUsd": "52853.5551",
"withdrawableAmount": {
"FUND": {
"coin": "USDT",
"withdrawableAmount": "11135.0596",
"availableBalance": "11135.0596"
},
"SPOT": {
"coin": "USDT",
"withdrawableAmount": "0",
"availableBalance": "0"
}
}
},
"retExtInfo": {},
"time": 1677565632151
}
- + \ No newline at end of file diff --git a/account-asset/deposit-record.html b/account-asset/deposit-record.html index d0d3a80c4a..e2eec89ba1 100644 --- a/account-asset/deposit-record.html +++ b/account-asset/deposit-record.html @@ -4,13 +4,13 @@ Get Deposit Records (on chain) | Bybit API Documentation - +
Skip to main content

Get Deposit Records (on chain)

Query Deposit Records

Rules
  • The maximum difference between the start time and the end time is 30 days.
  • Support to get deposit records by Master or Sub Member Api Key
  • HTTP Request

    GET /asset/v3/private/deposit/record/query

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalseintegerStart time (ms). Default value: 30 days before the current time
    endTimefalseintegerEnd time (ms). Default value: current time
    coinfalsestringCoin name: for example, BTC. Default value: all
    cursorfalsestringCursor, used for pagination
    limitfalseintegerNumber of items per page, [1, 50]. Default value: 50

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > coinstringdeposit coin
    > chainstringchain name
    > amountstringdeposit amount
    > txIDstringtransaction ID. It is "" when deposit failed or deposit cancelled
    > statusinteger
    • 0=unknown
    • 1=ToBeConfirmed
    • 2=processing
    • 3=success
    • 4=deposit failed
    > toAddressstringdeposit target address
    > tagstringtag of deposit target address
    > depositFeestringdeposit fee
    > successAtstringlast updated time
    > confirmationsstringnumber of confirmation blocks
    > txIndexstringtransaction sequence number
    > blockHashstringhash number on the chain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit
    > depositTypeintegerThe deposit type. 0: normal deposit, 10: the deposit reaches daily deposit limit, 20: abnormal deposit
    nextPageCursorstringcursor information: used for pagination. Default value: ""

    Request Example

    GET /asset/v3/private/deposit/record/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671166430580
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "1234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "depositFee": "",
    "successAt": "1671018256000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    },
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "01234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "depositFee": "",
    "successAt": "1669197900000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTAwNTYwNiwibWF4SUQiOjEwMzE1MjN9"
    },
    "retExtInfo": {},
    "time": 1671166430718
    }
    - + \ No newline at end of file diff --git a/account-asset/deposit-spec.html b/account-asset/deposit-spec.html index fb7e9cc11d..465b9d1579 100644 --- a/account-asset/deposit-spec.html +++ b/account-asset/deposit-spec.html @@ -4,13 +4,13 @@ Get Deposit Spec | Bybit API Documentation - +
    Skip to main content

    Get Deposit Spec

    Query deposit spec.

    Information
    • It is a public endpoints, no authentication needed.
    • Coin and chain must be paired in the input parameter. Otherwise, it is regarded as an unconditional query.

    HTTP Request

    GET /asset/v3/public/deposit/allowed-deposit-list/query

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringDeposit Coin. Coin and chain must be paired. Otherwise, it is regarded as an unconditional query
    chainfalsestringDeposit Chain Name. Coin and chain must be paired. Otherwise, it is regarded as an unconditional query
    cursorfalsestringcursor information: used for pagination
    limitfalseintegerNumber of items per page, [1, 50]. Default value: 50

    Response Parameters

    ParameterTypeComments
    configListarrayObject
    > coinstringdeposit coin
    > chainstringchain name
    > coinShowNamestringCoin show name
    > chainTypestringchain type
    > blockConfirmNumberintegerdeposit confirmation number
    > minDepositAmountstringMinimum Deposit Amount
    nextPageCursorstringcursor information: used for pagination. Default value: ""

    Request Example

    GET /asset/v3/public/deposit/allowed-deposit-list/query?coin=BTC&chain=BTC HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "configList": [
    {
    "coin": "BTC",
    "chain": "BTC",
    "coinShowName": "BTC",
    "chainType": "BTC",
    "blockConfirmNumber": 10000,
    "minDepositAmount": "0.0005"
    }
    ],
    "nextPageCursor": "eyJwYWdlIjoyLCJsaW1pdCI6MTB9"
    },
    "retExtInfo": {},
    "time": 1671165256048
    }
    - + \ No newline at end of file diff --git a/account-asset/enable-unitransfer.html b/account-asset/enable-unitransfer.html index 3182ef462f..5db64fc413 100644 --- a/account-asset/enable-unitransfer.html +++ b/account-asset/enable-unitransfer.html @@ -4,13 +4,13 @@ Enable Universal Transfer (Depreciated) | Bybit API Documentation - +
    Skip to main content

    Enable Universal Transfer (Depreciated)

    Enable Universal Transfer

    info

    No need to configure transferable sub uids. Any sub uids can be transferred universally.

    tip

    A universal transfer enables you to transfer funds directly between two sub accounts, or master-sub account and any accountType (CONTRACT, SPOT, etc).

    Use this endpoint to enable subaccounts to take part in a universal transfer. It is a one-time switch which, once thrown, enables a subaccount permanently. If not set, your subaccounts cannot use universal tranfers.

    HTTP Request

    POST /asset/v3/private/transfer/transfer-sub-member-save

    Request Parameters

    ParameterRequiredTypeComments
    subMemberIdsfalsestringA comma-separated list of subaccount UIDs, for example "123,45,14,26,46"
    • If not passed, it means that remove the universal transfer ability of sub uid

    Response Parameters

    None

    Request Example

    POST /asset/v3/private/transfer/transfer-sub-member-save HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670928736473
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 43

    {
    "subMemberIds": ["1111111","2222222"]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {},
    "retExtInfo": {},
    "time": 1670928736727
    }
    - + \ No newline at end of file diff --git a/account-asset/enum.html b/account-asset/enum.html index 856a92bfab..c7c6f8d97e 100644 --- a/account-asset/enum.html +++ b/account-asset/enum.html @@ -4,13 +4,13 @@ Enums Definitions | Bybit API Documentation - +
    Skip to main content

    Enums Definitions

    accountType

    • CONTRACTDerivatives Account
    • SPOTSpot Account
    • INVESTMENTByFi Account (The service has been offline)
    • OPTIONUSDC Account
    • UNIFIEDUTA or UMA
    • FUNDFunding Account

    coin

    • BTC
    • ETH
    • USDT
    • XRP
    • ...

    chain

    • BTC
    • ETH
    • TRX
    • XLM
    • LTC
    • ...

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    withdrawStatus

    • SecurityCheck
    • Pending
    • success
    • CancelByUser
    • Reject
    • Fail
    • BlockchainConfirmed
    - + \ No newline at end of file diff --git a/account-asset/error.html b/account-asset/error.html index ced023b226..8610618866 100644 --- a/account-asset/error.html +++ b/account-asset/error.html @@ -4,13 +4,13 @@ Error Code | Bybit API Documentation - +
    Skip to main content

    Error Code

    CodeDescription
    0SUCCESS
    131084Withdraw failed because of Uta Upgrading
    131200Service error
    131201Internal error
    131202Invalid memberId
    131203Request parameter error
    131204Account info error
    131205Query transfer error
    131206Fail to transfer
    131207Account not exist
    131208Forbid transfer
    131209Get subMember relation error
    131210Amount accuracy error
    131211fromAccountType can't be the same as toAccountType
    131212Insufficient balance
    131213TransferLTV check error
    131214TransferId exist
    131215Amount error
    131216Query balance error
    131217Risk check error
    131001Service error
    131002Parameter error
    131003Interal error
    131004KYC needed
    131085Withdrawal amount is greater than your availale balance (the deplayed withdrawal is triggered)
    131086Withdrawal amount exceeds risk limit (the risk limit of margin trade is triggered)
    131088The withdrawal amount exceeds the remaining withdrawal limit of your identity verification level. The current available amount for withdrawal : %s
    131089User sensitive operation, withdrawal is prohibited within 24 hours
    131090User withdraw has been banned
    131091Blocked login status does not allow withdrawals
    131092User status is abnormal
    131093The withdrawal address is not in the whitelist
    131094UserId is not in the whitelist
    131095Withdrawl amount exceeds the 24 hour platform limit
    131096Withdraw amount does not satify the lower limit or upper limit
    131097Withdrawal of this currency has been closed
    131098Withdrawal currently is not availble from new address
    131099Hot wallet status can cancel the withdraw
    131227Sub-account do not have universal transfer permission
    131228your balance is not enough. Please check transfer safe amount
    131229Due to compliance requirements, the current currency is not allowed to transfer
    131087Do not input memo/tag,please
    - + \ No newline at end of file diff --git a/account-asset/froze-subuid.html b/account-asset/froze-subuid.html index e3d93f582d..4559c6e2c9 100644 --- a/account-asset/froze-subuid.html +++ b/account-asset/froze-subuid.html @@ -4,13 +4,13 @@ Froze Sub UID | Bybit API Documentation - +
    Skip to main content

    Froze Sub UID

    Froze sub uid. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    POST /user/v3/private/frozen-sub-member

    Request Parameters

    ParameterRequiredTypeComments
    subuidtrueintegerSub user Id
    frozentrueinteger0:unfreeze, 1:freeze

    Response Parameters

    None

    Request Example

    POST /user/v3/private/frozen-sub-member HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671177689823
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 42

    {
    "subuid": 111111111,
    "frozen": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671177689999
    }
    - + \ No newline at end of file diff --git a/account-asset/internal-deposit-record.html b/account-asset/internal-deposit-record.html index 482ddd473f..ff2afb5f31 100644 --- a/account-asset/internal-deposit-record.html +++ b/account-asset/internal-deposit-record.html @@ -4,13 +4,13 @@ Get Internal Deposit Records (across Bybit) | Bybit API Documentation - +
    Skip to main content

    Get Internal Deposit Records (across Bybit)

    Query deposit records through Bybit platform

    Rules
  • The maximum difference between the start time and the end time is 30 days.
  • Support to get deposit records by Master or Sub Member Api Key
  • HTTP Request

    GET /asset/v3/private/deposit/internal-deposit-record/query

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalseintegerStart time (ms). Default value: 30 days before the current time
    endTimefalseintegerEnd time (ms). Default value: current time
    coinfalsestringCoin name: for example, BTC. Default value: all
    cursorfalsestringCursor, used for pagination
    limitfalseintegerNumber of items per page, [1, 50]. Default value: 50

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > idstringID
    > typeinteger1: Internal deposit
    > coinstringDeposit coin
    > amountstringDeposit amount
    > statusinteger
    • 1=Processing
    • 2=Success
    • 3=deposit failed
    > addressstringEmail address or phone number
    > createdTimestringDeposit created timestamp
    nextPageCursorstringcursor information: used for pagination. Default value: ""

    Request Example


    Response Example


    - + \ No newline at end of file diff --git a/account-asset/internal-transfer-list.html b/account-asset/internal-transfer-list.html index d0d92813d5..0134b32bfa 100644 --- a/account-asset/internal-transfer-list.html +++ b/account-asset/internal-transfer-list.html @@ -4,13 +4,13 @@ Get Internal Transfer List | Bybit API Documentation - +
    Skip to main content

    Get Internal Transfer List

    Query Internal Transfer List

    HTTP Request

    GET /asset/v3/private/transfer/inter-transfer/list/query

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency
    statusfalsestringTransfer status
    startTimefalseintegerThe start timestamp (ms) Note: the query logic is actually effective based on second level
    endTimefalseintegerThe end timestamp (ms) Note: the query logic is actually effective based on second level
    limitfalseintegerLimit of data size
    cursorfalsestringCursor, used for pagination

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringUUID, which is unique across the platform
    > coinstringCurrency
    > amountstringTransfer amount
    > fromAccountTypestringFrom account type
    > toAccountTypestringTo account type
    > timestampstringCreated timestamp (ms)
    > statusstringTransfer status
    nextPageCursorstringCursor, used for pagination

    Request Example

    GET /asset/v3/private/transfer/inter-transfer/list/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670926842754
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: xxxxxxxxxxxxxxx

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "22b168ef-1917-4bbe-a8bd-4ea729ec5887",
    "coin": "USDT",
    "amount": "1",
    "fromAccountType": "SPOT",
    "toAccountType": "UNIFIED",
    "timestamp": "1668749670000",
    "status": "SUCCESS"
    },
    {
    "transferId": "selfTransfer_4420a136-5610-44d3-97bb-a3d0551869a9",
    "coin": "USDT",
    "amount": "1",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT",
    "timestamp": "1668570868000",
    "status": "SUCCESS"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6NTYxMzUxLCJtYXhJRCI6MTU2Mzg4OX0="
    },
    "retExtInfo": {},
    "time": 1670926842908
    }
    - + \ No newline at end of file diff --git a/account-asset/internal-transfer.html b/account-asset/internal-transfer.html index 8811bcd295..be069fd942 100644 --- a/account-asset/internal-transfer.html +++ b/account-asset/internal-transfer.html @@ -4,13 +4,13 @@ Create Internal Transfer | Bybit API Documentation - +
    Skip to main content

    Create Internal Transfer

    Transfers funds between the different sections of an individual's account (not between subaccounts). For example, between the spot and derivatives accounts.

    To send a transfer which is accountType & parent/sub agnostic, use the Create Universal Transfer endpoint.

    tip
    • The transferIn and transferOut account types cannot be the same.
    • You may transfer USDT from SPOT only after upgraded to Unified Margin Account.

    HTTP Request

    POST /asset/v3/private/transfer/inter-transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency type
    amounttruestringExchange to amount
    fromAccountTypetruestringAccount type
    toAccountTypetruestringAccount type

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID, which is unique across the platform

    Request Example

    POST /asset/v3/private/transfer/inter-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670925348932
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 164

    {
    "transferId": "42c0cfb0-6bca-c242-bc73-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "fromAccountType": "CONTRACT",
    "toAccountType": "SPOT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc73-4e6df6cbcb06"
    },
    "retExtInfo": {},
    "time": 1670925349100
    }
    - + \ No newline at end of file diff --git a/account-asset/master-deposit-addr.html b/account-asset/master-deposit-addr.html index f67a53d585..3fd8a4d21a 100644 --- a/account-asset/master-deposit-addr.html +++ b/account-asset/master-deposit-addr.html @@ -4,13 +4,13 @@ Get Master Acct Deposit Address Info | Bybit API Documentation - +
    Skip to main content

    Get Master Acct Deposit Address Info

    Query Master Acct Deposit Address Information

    HTTP Request

    GET /asset/v3/private/deposit/address/query

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringcoin name
    chainTypefalsestringChain name. Return all if not passed.
    • pass chain name, e.g. ETH instead of ERC20

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    chainsarrayObject
    > chainTypestringchain type
    > addressDepositstringdeposit address
    > tagDepositstringdeposit tag
    > chainstringchain name
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit

    Request Example

    GET /asset/v3/private/deposit/address/query?coin=USDT&chainType=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671174181320
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/x-www-form-urlencoded

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": [
    {
    "chainType": "ERC20",
    "addressDeposit": "xxxxxxxxxxx",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "-1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671174181514
    }
    - + \ No newline at end of file diff --git a/account-asset/modify-master-apikey.html b/account-asset/modify-master-apikey.html index bbf3776dac..29d83bbb59 100644 --- a/account-asset/modify-master-apikey.html +++ b/account-asset/modify-master-apikey.html @@ -4,13 +4,13 @@ Modify Master API Key | Bybit API Documentation - +
    Skip to main content

    Modify Master API Key

    Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"
    info

    Only the api key that calls this interface can be modified

    HTTP Request

    POST /user/v3/private/update-api

    Request Parameters

    ParameterRequiredTypeComments
    readOnlyfalseinteger0 (default):Read and Write. 1:Read only
    ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
    • don't pass ips or pass with "*" means no bind
    • No ip bound api key will be invalid after 90 days
    • api key without IP bound will be invalid after 7 days once the account password is changed
    permissionsfalseObjectTick the types of permission. Don't send this param if you don't want to change the permission
    > ContractTradefalsearrayContract Trade. ["Order","Position"]
    > SpotfalsearraySpot Trade. ["SpotTrade"]
    > WalletfalsearrayWallet. ["AccountTransfer","SubMemberTransfer"]
    > OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
    > DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
    > CopyTradingfalsearrayCopytrade. ["CopyTrading"]
    > BlockTradefalsearrayBlocktrade. ["BlockTrade"]
    > ExchangefalsearrayExchange. ["ExchangeHistory"]
    > NFTfalsearrayNFT. ["NFTQueryProductList"]

    Response Parameters

    ParameterTypeComments
    idstringUnique id. Internal used
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringAlways ""
    permissionsObjectThe types of permission
    > ContractTradearrayPermisson of contract trade
    > SpotarrayPermisson of spot
    > WalletarrayPermisson of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
    > DerivativesarrayPermission of Unified account
    > CopyTradingarrayPermission of copytrade. Not applicable to sub account, always []
    > BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []
    ipsarrayIP bound

    Request Example

    POST /user/v3/private/update-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671179084116
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 741

    {
    "readOnly": 0,
    "ips": "xxx.xxx.xxx.xx",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": ["BlockTrade"],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": ["NFTQueryProductList"]
    }
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "341509",
    "note": "TESTING12SEP",
    "apiKey": "xxxxxxxxxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [
    "BlockTrade"
    ],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    },
    "ips": [
    "xxx.xxx.xxx.xxx"
    ]
    },
    "retExtInfo": {},
    "time": 1671179084363
    }
    - + \ No newline at end of file diff --git a/account-asset/modify-sub-apikey.html b/account-asset/modify-sub-apikey.html index e618817b8d..7da8251e16 100644 --- a/account-asset/modify-sub-apikey.html +++ b/account-asset/modify-sub-apikey.html @@ -4,14 +4,14 @@ Modify Sub API Key | Bybit API Documentation - +
    Skip to main content

    Modify Sub API Key

    Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master account api key to manage its sub account api key.

    tip

    The API key must have one of the below permissions in order to call this endpoint

    • sub API key: "Account Transfer", "Sub Member Transfer"
    • master API Key: "Account Transfer", "Sub Member Transfer", "Withdrawal"

    HTTP Request

    POST /user/v3/private/update-sub-api

    Request Parameters

    ParameterRequiredTypeComments
    apikeyfalsestringSub account api key
    • You must pass this param when you use master account manage sub account api key settings
    • If you use corresponding sub uid api key call this endpoint, apikey param cannot be passed, otherwise throwing an error
    readOnlyfalseinteger0 (default):Read and Write. 1:Read only
    ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
    • don't pass ips or pass with "*" means no bind
    • No ip bound api key will be invalid after 90 days
    • api key will be invalid after 7 days once the account password is changed
    permissionsfalseObjectTick the types of permission. Don't send this param if you don't want to change the permission
    > ContractTradefalsearrayContract Trade. ["Order","Position"]
    > SpotfalsearraySpot Trade. ["SpotTrade"]
    > WalletfalsearrayWallet. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
    > DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
    > ExchangefalsearrayExchange. ["ExchangeHistory"]
    > CopyTradingfalsearrayCopytrade. ["CopyTrading"]

    Response Parameters

    ParameterTypeComments
    idstringUnique id. Internal used
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringAlways ""
    permissionsObjectThe types of permission
    > ContractTradearrayPermisson of contract trade
    > SpotarrayPermisson of spot
    > WalletarrayPermisson of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
    > DerivativesarrayPermission of Unified account
    > CopyTradingarrayPermission of copytrade
    > BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []
    ipsarrayIP bound

    Request Example

    POST /user/v3/private/update-sub-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180069231
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 531

    {
    "readOnly": 0,
    "ips": "*",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Exchange": [
    "ExchangeHistory"
    ]
    }
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "111111111",
    "note": "TESTNET subacc testing",
    "apiKey": "xxxxxxxxxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": []
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1671180069386
    }
    - + \ No newline at end of file diff --git a/account-asset/rate-limit.html b/account-asset/rate-limit.html index c1d2ce1878..eb71e34594 100644 --- a/account-asset/rate-limit.html +++ b/account-asset/rate-limit.html @@ -4,7 +4,7 @@ Rate Limit | Bybit API Documentation - + @@ -15,7 +15,7 @@ in an unexpected violation.

    note

    All traffic to api.bybit.com or api.bytick.com share this limit regardless of if it accesses Spot, Derivatives or Options.

    After violating the limit your IP will be banned for a set period of time (usually 30 minutes). Continually violating the limit will result in a permanent ban. We cannot undo permanent bans or shorten temporary bans.

    API Rate Limit

    caution

    If you receive "ret_msg": "Too many visits!" in the JSON response, you have hit the API rate limit.

    The API rate limit is based on the rolling time window per minute and UID. In other words, it is per minute per UID. Every request to the API returns response header shown in the code panel:

    Http Response Header Example

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    API Rate Limit Table

    Transfer

    PathLimit
    /asset/v3/private/transfer/inter-transfer20 req/min
    /asset/v3/private/transfer/sub-member-transfer
    /asset/v3/private/transfer/transfer-sub-member-save
    /asset/v3/private/transfer/universal-transfer5 req/sec
    /asset/v3/private/transfer/inter-transfer/list/query60 req/min
    /asset/v3/private/transfer/sub-member-transfer/list/query
    /asset/v3/private/transfer/transfer-coin/list/query
    /asset/v3/private/transfer/sub-member/list/query
    /asset/v3/private/transfer/account-coin/balance/query
    /asset/v3/private/transfer/asset-info/query
    /asset/v3/private/transfer/universal-transfer/list/query2 req/sec
    /asset/v3/private/transfer/account-coins/balance/query2 req/sec

    Withdraw and Deposit

    PathLimit
    /asset/v3/private/deposit/sub-member-record/query300 req/min
    /asset/v3/private/deposit/record/query
    /asset/v3/private/withdraw/record/query
    /asset/v3/private/deposit/address/query
    /asset/v3/private/deposit/sub-member-address/query
    /asset/v3/private/coin-info/query2 req/sec
    /asset/v3/private/withdraw/cancel60 req/min
    /asset/v3/private/withdraw/create10 req/min

    Master-Sub User

    PathLimit
    /user/v3/private/create-sub-member5 req/sec
    /user/v3/private/create-sub-api
    /user/v3/private/frozen-sub-member
    /user/v3/private/update-api
    /user/v3/private/delete-api
    /user/v3/private/update-sub-api
    /user/v3/private/delete-sub-api
    /user/v3/private/query-sub-members10 req/sec
    /user/v3/private/query-api
    - + \ No newline at end of file diff --git a/account-asset/rm-master-apikey.html b/account-asset/rm-master-apikey.html index 5cfead72b0..de6c4ebe40 100644 --- a/account-asset/rm-master-apikey.html +++ b/account-asset/rm-master-apikey.html @@ -4,13 +4,13 @@ Delete Master API Key | Bybit API Documentation - +
    Skip to main content

    Delete Master API Key

    Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"
    danger

    BE CAREFUL! The API key used to call this interface will be invalid immediately.

    HTTP Request

    POST /user/v3/private/delete-api

    Request Parameters

    None

    Response Parameters

    None

    Request Example

    POST /user/v3/private/delete-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180438117
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 4
    {
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671180438209
    }
    - + \ No newline at end of file diff --git a/account-asset/rm-sub-apikey.html b/account-asset/rm-sub-apikey.html index 1d17ff198d..6b266a0d7f 100644 --- a/account-asset/rm-sub-apikey.html +++ b/account-asset/rm-sub-apikey.html @@ -4,14 +4,14 @@ Delete Sub API Key | Bybit API Documentation - +
    Skip to main content

    Delete Sub API Key

    Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key to delete corresponding sub account api key

    tip

    The API key must have one of the below permissions in order to call this endpoint.

    • sub API key: "Account Transfer", "Sub Member Transfer"
    • master API Key: "Account Transfer", "Sub Member Transfer", "Withdrawal"
    danger

    BE CAREFUL! The Sub account API key will be invalid immediately after calling the endpoint.

    HTTP Request

    POST /user/v3/private/delete-sub-api

    Request Parameters

    ParameterRequiredTypeComments
    apikeyfalsestringSub account api key
    • You must pass this param when you use master account manage sub account api key settings
    • If you use corresponding sub uid api key call this endpoint, apikey param cannot be passed, otherwise throwing an error

    Response Parameters

    None

    Request Example

    POST /user/v3/private/delete-sub-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180557996
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    {}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671180558095
    }
    - + \ No newline at end of file diff --git a/account-asset/set-deposit-acct.html b/account-asset/set-deposit-acct.html index 01ab5eb59f..ffcbce5508 100644 --- a/account-asset/set-deposit-acct.html +++ b/account-asset/set-deposit-acct.html @@ -4,13 +4,13 @@ Set Deposit Account | Bybit API Documentation - +
    Skip to main content

    Set Deposit Account

    Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI.

    info
    • Your funds will be deposited into FUND wallet by default. You can set the wallet for auto-transfer after deposit by this API.
    • Only main UID can access.
    tip
    • Unified trading account has FUND, UNIFIED, CONTRACT(for inverse derivatives), SPOT(will be merged into UNIFIED by the end of Feb)
    • Unified margin account has FUND, UNIFIED, CONTRACT(for inverse derivatives), SPOT
    • Classic account has FUND, OPTION(USDC account), CONTRACT(for inverse derivatives and derivatives), SPOT

    HTTP Request

    POST /asset/v3/private/deposit/deposit-to-account

    Request Parameters

    ParameterRequiredTypeComments
    accountTypetruestringAccount type
    • UNIFIED
    • SPOT
    • OPTION
    • CONTRACT
    • FUND

    Response Parameters

    ParameterTypeComments
    statusintegerRequest result:
    • 1: SUCCESS
    • 0: FAIL

    Request Example

    POST /asset/v3/private/deposit/deposit-to-account HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676887913670
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "accountType": "CONTRACT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1676887914363
    }
    - + \ No newline at end of file diff --git a/account-asset/sub-deposit-addr.html b/account-asset/sub-deposit-addr.html index 13ce95dedd..2e465ec91f 100644 --- a/account-asset/sub-deposit-addr.html +++ b/account-asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ Get Sub Acct Deposit Address Info | Bybit API Documentation - +
    Skip to main content

    Get Sub Acct Deposit Address Info

    Query Sub Acct Deposit Address Information

    info

    Get the deposit address information of sub account. Use master user's api key only.

    HTTP Request

    GET /asset/v3/private/deposit/sub-member-address/query

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name
    chainTypefalsestringChain name. Return all if not passed.
    • pass chain name, e.g. ETH instead of ERC20
    subMemberIdtruestringSub UID

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    chainsarrayObject
    > chainTypestringChain type
    > addressDepositstringDeposit address
    > tagDepositstringDeposit tag
    > chainstringChain name
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit

    Request Example

    GET /asset/v3/private/deposit/sub-member-address/query?coin=USDT&chainType=ETH&subMemberId=407767 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671174486288
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": {
    "chainType": "ERC20",
    "addressDeposit": "xxxxxxxxxxx",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "-1"
    }
    },
    "retExtInfo": {},
    "time": 1671174486505
    }
    - + \ No newline at end of file diff --git a/account-asset/sub-deposit-record.html b/account-asset/sub-deposit-record.html index 73c821fec9..fc158a9ef1 100644 --- a/account-asset/sub-deposit-record.html +++ b/account-asset/sub-deposit-record.html @@ -4,13 +4,13 @@ Get Sub Deposit Records (on chain) | Bybit API Documentation - +
    Skip to main content

    Get Sub Deposit Records (on chain)

    Query Sub Deposit Records By Master Key

    Rules

    Rules: Query sub account deposit records by master account api key. If you want to use sub account api key to query, please use Query Deposit Records endpoint

    HTTP Request

    GET /asset/v3/private/deposit/sub-member-record/query

    Request Parameters

    ParameterRequiredTypeComments
    subMemberIdtrueintegerSub user Id
    startTimefalseintegerThe start time (ms). Default value: 30 days before the current time
    endTimefalseintegerTbe end time (ms). Default value: current time
    coinfalsestringCoin name: for example, BTC. Default value: all
    cursorfalsestringCursor, used for pagination
    limitfalseintegerNumber of items per page, [1, 50]. Default value: 50

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > coinstringdeposit coin
    > chainstringchain name
    > amountstringdeposit amount
    > txIDstringtransaction ID. It is "" when deposit failed or deposit cancelled
    > statusinteger
    • 0=unknown
    • 1=ToBeConfirmed
    • 2=processing
    • 3=success
    • 4=deposit failed
    > toAddressstringdeposit target address
    > tagstringtag of deposit target address
    > depositFeestringdeposit fee
    > successAtstringlast updated time
    > confirmationsstringnumber of confirmation blocks
    > txIndexstringtransaction sequence number
    > blockHashstringhash number on the chain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit
    > depositTypeintegerThe deposit type. 0: normal deposit, 10: the deposit reaches daily deposit limit, 20: abnormal deposit
    nextPageCursorstringcursor information: used for pagination. Default value: ""

    Request Example

    GET /asset/v3/private/deposit/sub-member-record/query?subMemberId=xxxxxxxxxxx HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671169682466
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "1234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "11234567890",
    "depositFee": "",
    "successAt": "1671018256000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTAwNTYwNiwibWF4SUQiOjEwMzE1MjN9"
    },
    "retExtInfo": {},
    "time": 1671166430718
    }
    - + \ No newline at end of file diff --git a/account-asset/sub-transfer-list.html b/account-asset/sub-transfer-list.html index 59a24cb370..13a065bae4 100644 --- a/account-asset/sub-transfer-list.html +++ b/account-asset/sub-transfer-list.html @@ -4,13 +4,13 @@ Get Master-Sub Transfer List | Bybit API Documentation - +
    Skip to main content

    Get Master-Sub Transfer List

    Query subaccount transfer list

    caution

    Can use master api key to query only

    HTTP Request

    GET /asset/v3/private/transfer/sub-member-transfer/list/query

    Request Parameters

    ParameterRequiredTypeComments
    transferIdfalsestringUUID, which is unique across the platform
    coinfalsestringCurrency type
    statusfalsestringTransfer status
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit of data size
    cursorfalsestringCursor, used for pagination

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringUUID, which is unique across the platform
    > coinstringCurrency
    > amountstringTransfer amount
    > memberIdintegerMaster account UID
    > subMemberIdintegerSubaccount UID
    > timestampstringCreated timestamp (ms)
    > statusstringTransfer status
    > typestringDetermines the direction of transfer.
    • IN transfer from main account to subaccount
    • OUT transfer from subaccount to main account
    nextPageCursorstringCursor, used for pagination

    Request Example

    GET /asset/v3/private/transfer/sub-member-transfer/list/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670927635525
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "memberId": xxxxxxx,
    "subMemberId": xxxxxxx,
    "timestamp": "1670925916000",
    "status": "SUCCESS",
    "type": "IN"
    },
    {
    "transferId": "11ff9144-2d5d-4233-913d-4595c9ad2170",
    "coin": "USDT",
    "amount": "100",
    "memberId": xxxxxxx,
    "subMemberId": xxxxxxx,
    "timestamp": "1658732947000",
    "status": "SUCCESS",
    "type": "OUT"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MzU2MTA0LCJtYXhJRCI6MTcyMDk2OH0="
    },
    "retExtInfo": {},
    "time": 1670927635641
    }
    - + \ No newline at end of file diff --git a/account-asset/sub-transfer.html b/account-asset/sub-transfer.html index 12d121bf75..7f4f95c1e5 100644 --- a/account-asset/sub-transfer.html +++ b/account-asset/sub-transfer.html @@ -4,13 +4,13 @@ Create Subaccount Transfer | Bybit API Documentation - +
    Skip to main content

    Create Subaccount Transfer

    Transfer funds between the parent and child (sub) accounts.

    To send a transfer which is accountType & parent/sub agnostic, use the Create Universal Transfer endpoint.

    tip
    • Please note that the transferId field in the incoming request data of this interface is UUID globally unique
    • This interface can only be used for transfer between parent and child accounts
    • A subaccount can only be attributed to a parent account.
    • If you encounter errorCode: 131228 and msg: your balance is not enough, please go to Get Single Coin Balance to check transfer safe amount.
    • It's mandatory to utilize the API key of the main account

    HTTP Request

    POST /asset/v3/private/transfer/sub-member-transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency type
    amounttruestringExchange to amount
    subMemberIdtrueintegerSubaccount userid
    typetruestringDetermines the direction of transfer.
    • IN transfer from main account to subaccount
    • OUT transfer from subaccount to main account

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID, which is unique across the platform

    Request Example

    POST /asset/v3/private/transfer/sub-member-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670925915816
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: xxxxxxxxxxxxx
    Content-Type: application/json
    Content-Length: 144

    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "subMemberId": 554137,
    "type": "IN"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f"
    },
    "retExtInfo": {},
    "time": 1670925915979
    }
    - + \ No newline at end of file diff --git a/account-asset/sub-uid-list.html b/account-asset/sub-uid-list.html index fda542e5b9..e0af36ec11 100644 --- a/account-asset/sub-uid-list.html +++ b/account-asset/sub-uid-list.html @@ -4,13 +4,13 @@ Get Subaccount UID List | Bybit API Documentation - +
    Skip to main content

    Get Subaccount UID List

    Query Subaccount List

    HTTP Request

    GET /asset/v3/private/transfer/sub-member/list/query

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    subMemberIdsarray<string>List of all subaccounts
    transferableSubMemberIdsarray<string>List of subaccounts that are universal transfer-enabled

    Request Example

    GET /asset/v3/private/transfer/sub-member/list/query HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670928351923
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "subMemberIds": [
    "111111",
    "2222222",
    "3333333"
    ],
    "transferableSubMemberIds": [
    "111111",
    "2222222",
    "3333333"
    ]
    },
    "retExtInfo": {},
    "time": 1670928352175
    }
    - + \ No newline at end of file diff --git a/account-asset/subuid-list.html b/account-asset/subuid-list.html index 16758cc566..4d146e94e4 100644 --- a/account-asset/subuid-list.html +++ b/account-asset/subuid-list.html @@ -4,13 +4,13 @@ Get Sub UID List | Bybit API Documentation - +
    Skip to main content

    Get Sub UID List

    Get all sub uid of master account. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    GET /user/v3/private/query-sub-members

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    subMembersarrayObject
    > uidstringSub user Id
    > usernamestringUsername
    > memberTypeinteger1: normal sub account, 6: custodial sub account
    > statusintegerThe status of the user account
    • 1: normal
    • 2: login banned
    • 4: frozen
    > remarkstringThe remark

    Request Example

    GET /user/v3/private/query-sub-members HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430318405
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "subMembers": [
    {
    "uid": "53888001",
    "username": "xxx001",
    "memberType": 1,
    "status": 1,
    "remark": "test"
    },
    {
    "uid": "53888002",
    "username": "xxx002",
    "memberType": 6,
    "status": 1,
    "remark": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676430319452
    }
    - + \ No newline at end of file diff --git a/account-asset/transferable-coin-list.html b/account-asset/transferable-coin-list.html index 1ffe3dc46a..b6ed64a454 100644 --- a/account-asset/transferable-coin-list.html +++ b/account-asset/transferable-coin-list.html @@ -4,13 +4,13 @@ Get Transferable Coin List | Bybit API Documentation - +
    Skip to main content

    Get Transferable Coin List

    Transferable coin list

    You can confirm transferable coins between different account types under the UID to which the current API key belongs

    HTTP Request

    GET /asset/v3/private/transfer/transfer-coin/list/query

    Request Parameters

    ParameterRequiredTypeComments
    fromAccountTypetruestringAccount type
    toAccountTypetruestringAccount type

    Response Parameters

    ParameterTypeComments
    listarrayThe coins are allowed to transfer between accounts

    Request Example

    GET /asset/v3/private/transfer/transfer-coin/list/query?fromAccountType=SPOT&toAccountType=CONTRACT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163888641
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    "ETH",
    "EOS",
    "USDT",
    "ADA",
    "BIT",
    "BTC",
    "DAI",
    "DOT",
    "LTC",
    "MANA",
    "XRP"
    ]
    },
    "retExtInfo": {},
    "time": 1671163888818
    }
    - + \ No newline at end of file diff --git a/account-asset/uni-transfer-list.html b/account-asset/uni-transfer-list.html index fc040905f7..c591738f7a 100644 --- a/account-asset/uni-transfer-list.html +++ b/account-asset/uni-transfer-list.html @@ -4,13 +4,13 @@ Get Universal Transfer List | Bybit API Documentation - +
    Skip to main content

    Get Universal Transfer List

    Query Universal Transfer List

    Only transfers made with the universal transfer API or web transfer will be returned by this endpoint. Transfers made by other endpoints will not be returned.

    tip
    • Main acct api key or Sub acct api key are both supported
    • Main acct api key needs "SubMemberTransfer" permission
    • Sub acct api key needs "SubMemberTransferList" permission

    HTTP Request

    GET /asset/v3/private/transfer/universal-transfer/list/query

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency type
    statusfalsestringTransfer status
    startTimefalseintegerThe start timestamp (ms) Note: the query logic is actually effective based on second level
    endTimefalseintegerThe end timestamp (ms) Note: the query logic is actually effective based on second level
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor, used for pagination

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringUUID, which is unique across the platform
    > coinstringCurrency type
    > amountstringTransfer amount
    > timestampstringCreated timestamp (ms)
    > statusstringstatus
    > fromAccountTypestringFrom account type
    > toAccountTypestringTo account type
    > fromMemberIdstringFrom UID
    > toMemberIdstringTo UID
    nextPageCursorstringCursor, used for pagination.

    Request Example

    GET /asset/v3/private/transfer/universal-transfer/list/query?coin=USDT&status=SUCCESS HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163509262
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "timestamp": "1671163374000",
    "status": "SUCCESS",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT",
    "fromMemberId": "11111111",
    "toMemberId": "22222222"
    },
    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "timestamp": "1670925916000",
    "status": "SUCCESS",
    "fromAccountType": "SPOT",
    "toAccountType": "SPOT",
    "fromMemberId": "111111111",
    "toMemberId": "33333333"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MzU2MTA0LCJtYXhJRCI6MTczNDQ5Mn0="
    },
    "retExtInfo": {},
    "time": 1671163509474
    }
    - + \ No newline at end of file diff --git a/account-asset/uni-transfer.html b/account-asset/uni-transfer.html index b867356bca..a75b78a83a 100644 --- a/account-asset/uni-transfer.html +++ b/account-asset/uni-transfer.html @@ -4,13 +4,13 @@ Create Universal Transfer | Bybit API Documentation - +
    Skip to main content

    Create Universal Transfer

    Create Universal Transfer

    It allows to transfer funds between sub accounts, or master-sub account.

    caution
    • Can use master or sub acct api key to request
      • To use sub acct api key, it must have "SubMemberTransferList" permission
      • When use sub acct api key, it can only transfer to main account
    • If you encounter errorCode: 131228 and msg: your balance is not enough, please go to Get Single Coin Balance to check transfer safe amount.

    HTTP Request

    POST /asset/v3/private/transfer/universal-transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency type
    amounttruestringExchange to amount
    fromMemberIdtruestringFrom UserID. fromMemberId cannot be the same as toMemberId
    toMemberIdtruestringTo UserID. fromMemberId cannot be the same as toMemberId
    fromAccountTypetruestringAccount type
    toAccountTypetruestringAccount type

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID, which is unique across the platform

    Request Example

    POST /asset/v3/private/transfer/universal-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163372208
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 219

    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "fromMemberId":"111111",
    "toMemberId":"222222",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06"
    },
    "retExtInfo": {},
    "time": 1671163373537
    }
    - + \ No newline at end of file diff --git a/account-asset/wallet-type.html b/account-asset/wallet-type.html index 91f961d068..d627168f62 100644 --- a/account-asset/wallet-type.html +++ b/account-asset/wallet-type.html @@ -4,13 +4,13 @@ Get UID Wallet Type | Bybit API Documentation - +
    Skip to main content

    Get UID Wallet Type

    Get available wallet types for the master account or sub account

    tip
    • Master api key: you can get master account and appointed sub account available wallet types, and support up to 200 sub uid in one request.
    • Sub api key: you can get its own available wallet types
    PRACTICE

    "FUND" - If you never deposit or transfer capital into it, this wallet type will not be shown in the array, but your account indeed has this wallet.

    • ["SPOT","OPTION","FUND","CONTRACT"] : Classic account and Funding wallet was operated before
    • ["SPOT","OPTION","CONTRACT"] : Classic account and Funding wallet is never operated
    • ["SPOT","UNIFIED","FUND","CONTRACT"] : UMA account and Funding wallet was operated before. (No UMA account after we forced upgrade to UTA)
    • ["SPOT","UNIFIED","CONTRACT"] : UMA account and Funding wallet is never operated. (No UMA account after we forced upgrade to UTA)
    • ["UNIFIED""FUND","CONTRACT"] : UTA account and Funding wallet was operated before.
    • ["UNIFIED","CONTRACT"] : UTA account and Funding wallet is never operated.

    HTTP Request

    GET /user/v3/private/get-member-type

    Request Parameters

    ParameterRequiredTypeComments
    memberIdsfalsestring
    • Query itself wallet types when not passed
    • When use master api key to query sub uid, master uid data is always returned in the top of the array
    • Multiple sub uid are supported, separated by commas, and up to 200 uids
    • This param is ignored when you use sub account api key

    Response Parameters

    ParameterTypeComments
    accountsarrayObject
    > uidstringMaster/Sub user Id
    > accountTypearrayWallets array. SPOT, CONTRACT, FUND, OPTION, UNIFIED. Please check above practice to understand the value

    Request Example

    GET /user/v3/private/get-member-type HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686882546210
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "accounts": [
    {
    "uid": "XXXXX",
    "accountType": [
    "SPOT",
    "OPTION",
    "FUND",
    "CONTRACT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686880658551
    }
    - + \ No newline at end of file diff --git a/account-asset/withdraw-record.html b/account-asset/withdraw-record.html index f5b2f12c72..5392f5c206 100644 --- a/account-asset/withdraw-record.html +++ b/account-asset/withdraw-record.html @@ -4,13 +4,13 @@ Get Withdraw Records | Bybit API Documentation - +
    Skip to main content

    Get Withdraw Records

    Query Withdraw Records

    Rules

    Rules: order by id in reverse order. The maximum difference between the start time and the end time is 30 days.

    HTTP Request

    GET /asset/v3/private/withdraw/record/query

    Request Parameters

    ParameterRequiredTypeComments
    withdrawIDfalseintegerwithdrawal id. (withdraw request ID in Response Parameters of Withdrawal endpoint)
    startTimefalseintegerThe start time (ms). Default value: 30 days before the current time
    endTimefalseintegerThe end time (ms). Default value: current time
    coinfalsestringcoin name: for example, BTC. Default value: all
    withdrawTypefalsestring
    • 0 (default):on chain.
    • 1:off chain.
    • 2:on and off chain
    cursorfalsestringCursor, used for pagination
    limitfalseintegerNumber of items per page. [1, 50] Default value: 50

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > coinstringwithdrawal coin
    > chainstringchain name
    > amountstringwithdrawal quantity
    > txIDstringtransaction ID. It returns "" when withdrawal failed, withdrawal cancelled or internal transfer
    > statusintstatus
    > toAddressstringwithdrawal target address. It shows email or mobile number for internal transfer
    > tagstringtag of withdrawal target address
    > withdrawFeestringwithdrawal fee
    > createTimestringwithdrawal create time
    > updateTimestringwithdrawal status updated time
    > withdrawIdstringwithdrawal id. (withdraw request ID in Response Parameters of Withdrawal endpoint)
    > withdrawTypeintegerWithdraw type.
    • 0:on chain;
    • 1:internal address transfer
    nextPageCursorstringcursor information, used for pagination

    Request Example

    GET /asset/v3/private/withdraw/record/query HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671171632559
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "TRX",
    "amount": "10",
    "txID": "",
    "status": "CancelByUser",
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "withdrawFee": "1",
    "createTime": "1670906044000",
    "updateTime": "1670906050000",
    "withdrawId": "9965",
    "withdrawType": 0
    },
    {
    "coin": "USDT",
    "chain": "TRX",
    "amount": "10",
    "txID": "",
    "status": "CancelByUser",
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "withdrawFee": "1",
    "createTime": "1670905993000",
    "updateTime": "1670906001000",
    "withdrawId": "9964",
    "withdrawType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6OTk2NCwibWF4SUQiOjk5NjV9"
    },
    "retExtInfo": {},
    "time": 1671171632649
    }
    - + \ No newline at end of file diff --git a/account-asset/withdraw.html b/account-asset/withdraw.html index e7f027e8d3..7070651786 100644 --- a/account-asset/withdraw.html +++ b/account-asset/withdraw.html @@ -4,14 +4,14 @@ Withdraw | Bybit API Documentation - +
    Skip to main content

    Withdraw

    Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.

    danger
    • For UTA users, please note that Bybit will merge SPOT account into UNIFIED account (est.end of Feb), so please adjust your withdrawal logic by transferring funds to FUND account first, then call withdraw API.
    • How do I know if my account is a UTA account? Call this endpoint, and if uta=1, then it is a UTA account.
    caution
    • Make sure you have whitelisted your wallet address here
    • Can query by the master UID's api key only
    formula

    feeType=0:

    • withdrawPercentageFee != 0: handlingFee = inputAmount / (1 - withdrawPercentageFee) * withdrawPercentageFee + withdrawFee
    • withdrawPercentageFee = 0: handlingFee = withdrawFee

    feeType=1:

    • withdrawPercentageFee != 0: handlingFee = withdrawFee + (inputAmount - withdrawFee) * withdrawPercentageFee
    • withdrawPercentageFee = 0: handlingFee = withdrawFee

    HTTP Request

    POST /asset/v3/private/withdraw/create

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringcoin name
    chaintruestringchain name
    addresstruestringWithdraw address. Please note that the address is case sensitive, so use the exact same address added in address book
    tagfalsestringNeed to fill in if there is a memo/tag when adding the wallet address. Note: please do not set a tag/memo in the address book if the chain does not support tag
    amounttruestringwithdraw amounts. The minimum withdrawal amount can be obtained from the Coin Info Query API
    timestamptrueintegerCurrent timestamp
    forceChainfalseintegerForce to withdraw on chain or not.
    • 0(default):If parsed as internal address, then internal transfer
    • 1:Force withdraw on chain
    accountTypefalsestringSelect the wallet to be withdrawn from
    • SPOT(default):spot wallet
    • FUND:Funding wallet
    feeTypefalseintegerHandling fee option
    • 0(default): input amount is the actual amount received, so you have to calculate handling fee manually
    • 1: input amount is not the actual amount you received, the system will help to deduct the handling fee automatically

    Response Parameters

    ParameterTypeComments
    idstringWithdrawal ID

    Request Example

    POST /asset/v3/private/withdraw/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671172758674
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 193

    {
    "coin": "USDT",
    "chain": "ETH",
    "address": "xxxxxxxxxxx",
    "tag": null,
    "amount": "10",
    "timestamp": 1670919612851,
    "forceChain": 1,
    "accountType": "FUND"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "xxxxxxxxxxx"
    },
    "retExtInfo": {},
    "time": 1671172180550
    }
    - + \ No newline at end of file diff --git a/account_asset.html b/account_asset.html index 48970e4e71..20b3088cf2 100644 --- a/account_asset.html +++ b/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@
    Skip to main content

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/account_asset/v1.html b/account_asset/v1.html index a553b930ff..2b273a2ea5 100644 --- a/account_asset/v1.html +++ b/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@
    Skip to main content

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/account_asset/v3.html b/account_asset/v3.html index 973bc9ed27..66e433cad2 100644 --- a/account_asset/v3.html +++ b/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@
    Skip to main content

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/api-explorer/derivatives/category.html b/api-explorer/derivatives/category.html index bbcb3cae49..c740ba9a90 100644 --- a/api-explorer/derivatives/category.html +++ b/api-explorer/derivatives/category.html @@ -4,13 +4,13 @@ Derivatives API | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/delivery-price.html b/api-explorer/derivatives/market/delivery-price.html index a00357b504..fada2e8d7c 100644 --- a/api-explorer/derivatives/market/delivery-price.html +++ b/api-explorer/derivatives/market/delivery-price.html @@ -4,13 +4,13 @@ Delivery price | Bybit API Documentation - +
    Skip to main content

    Delivery price

    Get delivery price of option

    Query Parameters
    • category string[]

      Possible values: [option]

      Products category. option only

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • direction string

      Possible values: [prev, next]

      The direction to pagination

    • limit string

      Default value: 50

      Maximum 200

    • cursor string

      The cursor, used to pagination

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/his-fund-rate.html b/api-explorer/derivatives/market/his-fund-rate.html index 0b4021658c..a5ff4074ad 100644 --- a/api-explorer/derivatives/market/his-fund-rate.html +++ b/api-explorer/derivatives/market/his-fund-rate.html @@ -4,13 +4,13 @@ Funding Rate History | Bybit API Documentation - +
    Skip to main content

    Funding Rate History

    Get historical funding rate

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • start string

      The start timstamp (ms)

    • end string

      The end timstamp (ms)

    • limit string

      Default value: 200

      Maximum 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/index-kline.html b/api-explorer/derivatives/market/index-kline.html index 0c82d4e4f2..8643612ecf 100644 --- a/api-explorer/derivatives/market/index-kline.html +++ b/api-explorer/derivatives/market/index-kline.html @@ -4,13 +4,13 @@ Index Price Kline | Bybit API Documentation - +
    Skip to main content

    Index Price Kline

    Get index price kline data

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms). e.g., 1671494400000 (20 DEC 2022 UTC 0:00)

    • end integer required

      end timestamp (ms). e.g., 1671926400000 (25 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/instrument.html b/api-explorer/derivatives/market/instrument.html index eda9645afe..ad2b81cef5 100644 --- a/api-explorer/derivatives/market/instrument.html +++ b/api-explorer/derivatives/market/instrument.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +
    Skip to main content

    Instrument Info

    Get launched instruments information. category=option is required for option.

    Query Parameters
    • category string[]

      Possible values: [linear, inverse, option]

      Products category

    • symbol string

      Symbol name

    • baseCoin string

      Default value: BTC

      for option ONLY

    • limit string

      Default value: 500

      Maximum 1000

    • cusor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • category string
    • list object[]
    • symbol string
    • contractType string
    • status string
    • baseCoin string
    • quoteCoin string
    • launchTime string
    • deliveryTime string
    • deliveryFeeRate string
    • priceScale string
    • leverageFilter object
    • minLeverage string
    • maxLeverage string
    • leverageStep string
    • priceFilter object
    • minPrice string
    • maxPrice string
    • tickSize string
    • lotSizeFilter object
    • maxTradingQty string
    • minTradingQty string
    • qtyStep string
    • nexPageCursor string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/kline.html b/api-explorer/derivatives/market/kline.html index f377bbb986..d0e7a2716c 100644 --- a/api-explorer/derivatives/market/kline.html +++ b/api-explorer/derivatives/market/kline.html @@ -4,13 +4,13 @@ Kline | Bybit API Documentation - +
    Skip to main content

    Kline

    Get kline data

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer required

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/mark-kline.html b/api-explorer/derivatives/market/mark-kline.html index ed39f2f554..02f6baed67 100644 --- a/api-explorer/derivatives/market/mark-kline.html +++ b/api-explorer/derivatives/market/mark-kline.html @@ -4,13 +4,13 @@ Mark Price Kline | Bybit API Documentation - +
    Skip to main content

    Mark Price Kline

    Get mark price kline data

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • end integer required

      end timestamp (ms). e.g., 1671494400000 (20 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/market.html b/api-explorer/derivatives/market/market.html index 6cd56e630e..3fccf943ce 100644 --- a/api-explorer/derivatives/market/market.html +++ b/api-explorer/derivatives/market/market.html @@ -4,13 +4,13 @@ Market data | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/open-interest.html b/api-explorer/derivatives/market/open-interest.html index ce0cc35834..662d9bd2df 100644 --- a/api-explorer/derivatives/market/open-interest.html +++ b/api-explorer/derivatives/market/open-interest.html @@ -4,13 +4,13 @@ Open Interest | Bybit API Documentation - +
    Skip to main content

    Open Interest

    Get open interest

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [5min, 15min, 30min, 1h, 4h, 1d]

      interval

    • startTime string

      The start timstamp (ms)

    • endTime string

      The end timstamp (ms)

    • limit string

      Default value: 50

      Maximum 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/orderbook.html b/api-explorer/derivatives/market/orderbook.html index b7043cdc7b..234cd01907 100644 --- a/api-explorer/derivatives/market/orderbook.html +++ b/api-explorer/derivatives/market/orderbook.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - +
    Skip to main content

    Order Book

    Get order book data

    Query Parameters
    • category string[]

      Possible values: [linear, inverse, option]

      Default value: linear

      Products category

    • symbol string required

      Symbol name

    • limit int

      Default value: 25

      Maximum 500

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • s string
    • b array[]
    • a array[]
    • ts timestamp
    • u sequence
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/premium-index-kline.html b/api-explorer/derivatives/market/premium-index-kline.html index c885b7951d..355339f7c1 100644 --- a/api-explorer/derivatives/market/premium-index-kline.html +++ b/api-explorer/derivatives/market/premium-index-kline.html @@ -4,13 +4,13 @@ Premium Index Price Kline | Bybit API Documentation - +
    Skip to main content

    Premium Index Price Kline

    Get premium index price kline data

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms). e.g., 1671926400000 (25 DEC 2022 UTC 0:00)

    • end integer required

      end timestamp (ms). e.g., 1672358400000 (30 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/public-trade.html b/api-explorer/derivatives/market/public-trade.html index ce5da60be4..a674e75987 100644 --- a/api-explorer/derivatives/market/public-trade.html +++ b/api-explorer/derivatives/market/public-trade.html @@ -4,13 +4,13 @@ Public trade | Bybit API Documentation - +
    Skip to main content

    Public trade

    Get public trade

    Query Parameters
    • category string[]

      Possible values: [linear, inverse, option]

      Products category

    • symbol string

      Symbol name. linear or inverse, required

    • baseCoin string

      Base coin. Valid for option.

    • optionType string

      Possible values: [Call, Put]

      Option type. Valid for option.

    • limit integer

      Default value: 500

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/risk-limit.html b/api-explorer/derivatives/market/risk-limit.html index a7aad449c7..68b4b9e06c 100644 --- a/api-explorer/derivatives/market/risk-limit.html +++ b/api-explorer/derivatives/market/risk-limit.html @@ -4,13 +4,13 @@ Risk limit | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/market/ticker.html b/api-explorer/derivatives/market/ticker.html index 1b3a00fe3d..cc1e7b6575 100644 --- a/api-explorer/derivatives/market/ticker.html +++ b/api-explorer/derivatives/market/ticker.html @@ -4,13 +4,13 @@ Ticker Info | Bybit API Documentation - +
    Skip to main content

    Ticker Info

    Get all latest information of symbols. All parameters are needed for OPTION

    Query Parameters
    • category string[]

      Possible values: [linear, inverse, option]

      Products category

    • symbol string

      Symbol name

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • category string
    • list object[]
    • symbol string
    • bidPrice string
    • askPrice string
    • lastPrice string
    • lastTickDirection string
    • prevPrice24h string
    • price24hPcnt string
    • highPrice24h string
    • lowPrice24h string
    • prevPrice1h string
    • markPrice string
    • indexPrice string
    • openInterest string
    • turnover24h string
    • volume24h string
    • fundingRate string
    • nextFundingTime string
    • predictedDeliveryPrice string
    • basisRate string
    • deliveryFeeRate string
    • deliveryTime string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/auto-margin.html b/api-explorer/derivatives/trade/contract/auto-margin.html index eef109a657..97a9efc9ab 100644 --- a/api-explorer/derivatives/trade/contract/auto-margin.html +++ b/api-explorer/derivatives/trade/contract/auto-margin.html @@ -4,13 +4,13 @@ Set Auto Add Margin | Bybit API Documentation - +
    Skip to main content

    Set Auto Add Margin

    Turn on/off auto add position margin.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

      Side

    • autoAddMargin integer required

      Possible values: [0, 1]

      Turn on / off. 0=off, 1=on

    • positionIdx integer

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/cancel-all.html b/api-explorer/derivatives/trade/contract/cancel-all.html index abb6446195..d5ea72c922 100644 --- a/api-explorer/derivatives/trade/contract/cancel-all.html +++ b/api-explorer/derivatives/trade/contract/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Order | Bybit API Documentation - +
    Skip to main content

    Cancel All Order

    Cancel all orders.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string

      Symbol name

    • baseCoin string

      Cancel by base coin

    • settleCoin string

      Cancel by settle coin

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/cancel-order.html b/api-explorer/derivatives/trade/contract/cancel-order.html index bacce43a8f..226a920fff 100644 --- a/api-explorer/derivatives/trade/contract/cancel-order.html +++ b/api-explorer/derivatives/trade/contract/cancel-order.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +
    Skip to main content

    Cancel Order

    Cancel a order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/close-pnl.html b/api-explorer/derivatives/trade/contract/close-pnl.html index f0ac3e959c..2e76ff855c 100644 --- a/api-explorer/derivatives/trade/contract/close-pnl.html +++ b/api-explorer/derivatives/trade/contract/close-pnl.html @@ -4,13 +4,13 @@ Get Closed PnL | Bybit API Documentation - +
    Skip to main content

    Get Closed PnL

    Get closed pnl.

    Query Parameters
    • symbol string

      Symbol name

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/contract.html b/api-explorer/derivatives/trade/contract/contract.html index b3d5152e4b..8472bf8c36 100644 --- a/api-explorer/derivatives/trade/contract/contract.html +++ b/api-explorer/derivatives/trade/contract/contract.html @@ -4,13 +4,13 @@ Contract | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/create-order.html b/api-explorer/derivatives/trade/contract/create-order.html index 6504956bd7..c34639f6b5 100644 --- a/api-explorer/derivatives/trade/contract/create-order.html +++ b/api-explorer/derivatives/trade/contract/create-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +
    Skip to main content

    Place Order

    Place a future or option order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required

      Order qty

    • price string

      ignore it if Market order

    • triggerPrice string

      param for StopOrder

    • triggerDirection integer

      param for StopOrder. 1=rise, 2=fall

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      param for StopOrder

    • timeInForce string required

      Possible values: [GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly]

      Time in force

    • positionIdx integer required

      Possible values: [0, 1, 2]

      0=one-way mode, 1=buy-hedge-mode, 2=sell-hedge-mode

    • orderLinkId string

      User customised order ID

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger stop loss price price type

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger string

      Possible values: [true, false]

      close on trigger

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/cross-isolated-margin.html b/api-explorer/derivatives/trade/contract/cross-isolated-margin.html index 4e516e4a26..9b93b19a84 100644 --- a/api-explorer/derivatives/trade/contract/cross-isolated-margin.html +++ b/api-explorer/derivatives/trade/contract/cross-isolated-margin.html @@ -4,13 +4,13 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +
    Skip to main content

    Switch Cross/Isolated Margin

    Switch cross/isolated margin mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • tradeMode integer required

      Possible values: [0, 1]

      Trade mode. 0=crossMargin, 1=isolatedMargin

    • buyLeverage string required

      Buy side leverage. Make sure buyLeverage equals to sellLeverage

    • sellLeverage string required

      Sell side leverage. Make sure buyLeverage equals to sellLeverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/execution.html b/api-explorer/derivatives/trade/contract/execution.html index 97594e2f9e..02e1a0decd 100644 --- a/api-explorer/derivatives/trade/contract/execution.html +++ b/api-explorer/derivatives/trade/contract/execution.html @@ -4,13 +4,13 @@ Get Execution List | Bybit API Documentation - +
    Skip to main content

    Get Execution List

    Get execution list.

    Query Parameters
    • symbol string required

      Symbol name

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • execType string

      Execution type

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/leverage.html b/api-explorer/derivatives/trade/contract/leverage.html index 028e9422a3..56d8b20048 100644 --- a/api-explorer/derivatives/trade/contract/leverage.html +++ b/api-explorer/derivatives/trade/contract/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +
    Skip to main content

    Set Leverage

    Set levearage.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/open-order.html b/api-explorer/derivatives/trade/contract/open-order.html index 46bb1e9c3a..5df3119b87 100644 --- a/api-explorer/derivatives/trade/contract/open-order.html +++ b/api-explorer/derivatives/trade/contract/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +
    Skip to main content

    Get Open Orders

    Get unfilled orders.

    Query Parameters
    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • settleCoin string
    • orderId string
    • orderLinkId string

      User customised order id

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor for pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/order-list.html b/api-explorer/derivatives/trade/contract/order-list.html index 9bb0935064..116bd1c59a 100644 --- a/api-explorer/derivatives/trade/contract/order-list.html +++ b/api-explorer/derivatives/trade/contract/order-list.html @@ -4,13 +4,13 @@ Get Order List | Bybit API Documentation - +
    Skip to main content

    Get Order List

    Get order history.

    Query Parameters
    • symbol string

      Symbol name

    • orderId string
    • orderLinkId string

      User customised order id

    • orderStatus string

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/position-info.html b/api-explorer/derivatives/trade/contract/position-info.html index f89e81bf63..1fdbfd9954 100644 --- a/api-explorer/derivatives/trade/contract/position-info.html +++ b/api-explorer/derivatives/trade/contract/position-info.html @@ -4,13 +4,13 @@ My Position | Bybit API Documentation - +
    Skip to main content

    My Position

    Get real-time position data.

    Query Parameters
    • symbol string

      Symbol name

    • settleCoin string

      symbol or settleCoin is required

    • limit string

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/position-mode.html b/api-explorer/derivatives/trade/contract/position-mode.html index 47b2ff91e9..9fe7e25118 100644 --- a/api-explorer/derivatives/trade/contract/position-mode.html +++ b/api-explorer/derivatives/trade/contract/position-mode.html @@ -4,13 +4,13 @@ Switch Position Mode | Bybit API Documentation - +
    Skip to main content

    Switch Position Mode

    Switch position mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string

      Symbol name. Either symbol or coin is required

    • coin string

      Coin. Either symbol or coin is required

    • mode string required

      Possible values: [0, 3]

      Position mode. 0=mergedSingle, 3=bothSide

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/replace-order.html b/api-explorer/derivatives/trade/contract/replace-order.html index 151c659743..bf393028fd 100644 --- a/api-explorer/derivatives/trade/contract/replace-order.html +++ b/api-explorer/derivatives/trade/contract/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +
    Skip to main content

    Replace Order

    Replace an order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/set-risk-limit.html b/api-explorer/derivatives/trade/contract/set-risk-limit.html index 256214ab34..c9caf69483 100644 --- a/api-explorer/derivatives/trade/contract/set-risk-limit.html +++ b/api-explorer/derivatives/trade/contract/set-risk-limit.html @@ -4,13 +4,13 @@ Set Risk Limit | Bybit API Documentation - +
    Skip to main content

    Set Risk Limit

    Set risk limit.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • riskId integer required

      Risk limit id

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/tpsl-mode.html b/api-explorer/derivatives/trade/contract/tpsl-mode.html index 136953503b..d5607e4a1c 100644 --- a/api-explorer/derivatives/trade/contract/tpsl-mode.html +++ b/api-explorer/derivatives/trade/contract/tpsl-mode.html @@ -4,13 +4,13 @@ Switch TP/SL Mode | Bybit API Documentation - +
    Skip to main content

    Switch TP/SL Mode

    Switch tp/sl mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • tpSlMode string required

      Possible values: [Full, Partial]

      Full=full position TP/SL, Partial=partial mode tp/sl

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/contract/trading-stop.html b/api-explorer/derivatives/trade/contract/trading-stop.html index c4ba92e1ef..145f798458 100644 --- a/api-explorer/derivatives/trade/contract/trading-stop.html +++ b/api-explorer/derivatives/trade/contract/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +
    Skip to main content

    Set Trading Stop

    Set trade stop.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpSize string

      Take profit size

    • slSize string

      Stop loss size

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Take profit trigger price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Stop loss trigger price type

    • trailingStop string

      Trailing stop

    • activePrice string

      Trailing stop trigger price

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/batch-cancel.html b/api-explorer/derivatives/trade/unified/batch-cancel.html index 1db1b67623..87c4a04164 100644 --- a/api-explorer/derivatives/trade/unified/batch-cancel.html +++ b/api-explorer/derivatives/trade/unified/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +
    Skip to main content

    Batch Cancel Order

    Batch cancel orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/batch-place.html b/api-explorer/derivatives/trade/unified/batch-place.html index 72934d9fed..9e7065088d 100644 --- a/api-explorer/derivatives/trade/unified/batch-place.html +++ b/api-explorer/derivatives/trade/unified/batch-place.html @@ -4,13 +4,13 @@ Batch Place Order | Bybit API Documentation - +
    Skip to main content

    Batch Place Order

    Batch place orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required
    • price string
    • iv string
    • timeInForce string required

      Possible values: [GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0]

      Position mode. one-way mode only for unified.

    • orderLinkId string

      REQUIRED param when place an option order

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger string

      Possible values: [true, false]

      close on trigger

    • mmp boolean

      Possible values: [true, false]

      market marker protection. for option order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/batch-replace-place.html b/api-explorer/derivatives/trade/unified/batch-replace-place.html index 9008cce909..a98ebb4f76 100644 --- a/api-explorer/derivatives/trade/unified/batch-replace-place.html +++ b/api-explorer/derivatives/trade/unified/batch-replace-place.html @@ -4,13 +4,13 @@ Batch Replace Order | Bybit API Documentation - +
    Skip to main content

    Batch Replace Order

    Batch replace orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • iv string

      Modify option order iv

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/cancel-all.html b/api-explorer/derivatives/trade/unified/cancel-all.html index 60d8635960..b272e66a89 100644 --- a/api-explorer/derivatives/trade/unified/cancel-all.html +++ b/api-explorer/derivatives/trade/unified/cancel-all.html @@ -4,13 +4,13 @@ Cancl All Orders | Bybit API Documentation - +
    Skip to main content

    Cancl All Orders

    Cancel all orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string

      Possible values: [linear, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin, e.g., BTC

    • settleCoin string

      Base coin, e.g., USDT

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/cancel-order.html b/api-explorer/derivatives/trade/unified/cancel-order.html index ec94f37ae6..57186145e9 100644 --- a/api-explorer/derivatives/trade/unified/cancel-order.html +++ b/api-explorer/derivatives/trade/unified/cancel-order.html @@ -4,13 +4,13 @@ Cancl Order | Bybit API Documentation - +
    Skip to main content

    Cancl Order

    Cancel a future or option order

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string

      Possible values: [linear, option]

      Product type

    • symbol string

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/create-order.html b/api-explorer/derivatives/trade/unified/create-order.html index 39b2958559..e25781599c 100644 --- a/api-explorer/derivatives/trade/unified/create-order.html +++ b/api-explorer/derivatives/trade/unified/create-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +
    Skip to main content

    Place Order

    Place a future or option order

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Sell]

      Order type

    • qty string required

      Order qty

    • price string

      Keep null for Market order

    • triggerPrice string

      param for StopOrder

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      param for StopOrder

    • iv string

      param for option order

    • timeInForce string required

      Possible values: [GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0]

      Position mode. one-way mode only for unified.

    • orderLinkId string

      REQUIRED param when place an option order

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger stop loss price price type

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger string

      Possible values: [true, false]

      close on trigger

    • mmp boolean

      Possible values: [true, false]

      market marker protection. for option order

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/myposition.html b/api-explorer/derivatives/trade/unified/myposition.html index f6eb135c9a..515ebbd4bc 100644 --- a/api-explorer/derivatives/trade/unified/myposition.html +++ b/api-explorer/derivatives/trade/unified/myposition.html @@ -4,13 +4,13 @@ Get position | Bybit API Documentation - +
    Skip to main content

    Get position

    Get your position info

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string
    • baseCoin string

      Default value: BTC

      for option only

    • direction string

      Possible values: [prev, next]

      Default value: next

      direction to page

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/open-order.html b/api-explorer/derivatives/trade/unified/open-order.html index c86e10450d..7b6ff188b1 100644 --- a/api-explorer/derivatives/trade/unified/open-order.html +++ b/api-explorer/derivatives/trade/unified/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +
    Skip to main content

    Get Open Orders

    Get unfilled orders

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string

      Symbol name

    • baseCoin string

      for option only

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/order-list.html b/api-explorer/derivatives/trade/unified/order-list.html index 88cd8a0798..d5cdf72c8b 100644 --- a/api-explorer/derivatives/trade/unified/order-list.html +++ b/api-explorer/derivatives/trade/unified/order-list.html @@ -4,13 +4,13 @@ Get Order List | Bybit API Documentation - +
    Skip to main content

    Get Order List

    Get order list

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string

      Symbol name

    • baseCoin string

      for option only

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderStatus string

      Possible values: [New, Filled, Cancelled, Rejected, PartiallyFilled, Untriggered, Deactivated, Triggered]

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/replace-order.html b/api-explorer/derivatives/trade/unified/replace-order.html index fcf272c71a..7d7ef5a8a6 100644 --- a/api-explorer/derivatives/trade/unified/replace-order.html +++ b/api-explorer/derivatives/trade/unified/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +
    Skip to main content

    Replace Order

    Replace an order

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • iv string

      Modify option order iv

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/derivatives/trade/unified/unified.html b/api-explorer/derivatives/trade/unified/unified.html index 2d7f977076..94802cc9a4 100644 --- a/api-explorer/derivatives/trade/unified/unified.html +++ b/api-explorer/derivatives/trade/unified/unified.html @@ -4,13 +4,13 @@ Unified Margin Account | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/category.html b/api-explorer/spot/category.html index a5d288d977..8f000da0be 100644 --- a/api-explorer/spot/category.html +++ b/api-explorer/spot/category.html @@ -4,13 +4,13 @@ Spot API | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/borrow-margin-loan.html b/api-explorer/spot/crossmargin/borrow-margin-loan.html index 733162b878..e940b194ef 100644 --- a/api-explorer/spot/crossmargin/borrow-margin-loan.html +++ b/api-explorer/spot/crossmargin/borrow-margin-loan.html @@ -4,13 +4,13 @@ Borrow Margin Loan | Bybit API Documentation - +
    Skip to main content

    Borrow Margin Loan

    Borrow Margin Loan

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • coin string required

      currency

    • qty string required

      Amount To Borrow

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/crossmargin.html b/api-explorer/spot/crossmargin/crossmargin.html index 3d066f0159..8186548a9a 100644 --- a/api-explorer/spot/crossmargin/crossmargin.html +++ b/api-explorer/spot/crossmargin/crossmargin.html @@ -4,13 +4,13 @@ Spot Margin Trade | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/query-account-info.html b/api-explorer/spot/crossmargin/query-account-info.html index 0913d78f02..128dd4b2b4 100644 --- a/api-explorer/spot/crossmargin/query-account-info.html +++ b/api-explorer/spot/crossmargin/query-account-info.html @@ -4,13 +4,13 @@ Query Account Info | Bybit API Documentation - +
    Skip to main content

    Query Account Info

    Query Account Info

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/query-borrowing-info.html b/api-explorer/spot/crossmargin/query-borrowing-info.html index 1d164c5156..9240748726 100644 --- a/api-explorer/spot/crossmargin/query-borrowing-info.html +++ b/api-explorer/spot/crossmargin/query-borrowing-info.html @@ -4,13 +4,13 @@ Query Borrowing Info | Bybit API Documentation - +
    Skip to main content

    Query Borrowing Info

    Query Borrowing Info

    Query Parameters
    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • coin string

      currency

    • status integer[]

      Possible values: [0, 1, 2]

      Status. 0 by default. 0:get all kinds of status; 1:uncleared; 2:cleared

    • limit string

      Default value: 500

      Default value is 500, max 500

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/query-interest-quota.html b/api-explorer/spot/crossmargin/query-interest-quota.html index ecb62a3aa4..d10bd90a0b 100644 --- a/api-explorer/spot/crossmargin/query-interest-quota.html +++ b/api-explorer/spot/crossmargin/query-interest-quota.html @@ -4,13 +4,13 @@ Query Interest and Quota | Bybit API Documentation - +
    Skip to main content

    Query Interest and Quota

    Query Interest and Quota

    Query Parameters
    • coin string

      currency

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/query-repayment-history.html b/api-explorer/spot/crossmargin/query-repayment-history.html index efe75bfbbf..9841f513f7 100644 --- a/api-explorer/spot/crossmargin/query-repayment-history.html +++ b/api-explorer/spot/crossmargin/query-repayment-history.html @@ -4,13 +4,13 @@ Query Repayment History | Bybit API Documentation - +
    Skip to main content

    Query Repayment History

    Query Repayment History

    Query Parameters
    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • coin string

      currency

    • limit string

      Default value: 500

      Default value is 500, max 500

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/crossmargin/redeem.html b/api-explorer/spot/crossmargin/redeem.html index 35d47b50bf..2100fb2e95 100644 --- a/api-explorer/spot/crossmargin/redeem.html +++ b/api-explorer/spot/crossmargin/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +
    Skip to main content

    Redeem

    Redeem

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • coin string required

      currency

    • qty string required

      Repayment Amount

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/all-asset-info.html b/api-explorer/spot/lttrade/all-asset-info.html index a81e2df5ce..eaecd6b14e 100644 --- a/api-explorer/spot/lttrade/all-asset-info.html +++ b/api-explorer/spot/lttrade/all-asset-info.html @@ -4,13 +4,13 @@ All Asset Infos | Bybit API Documentation - +
    Skip to main content

    All Asset Infos

    Get All Asset Infos

    Query Parameters
    • ltCode string

      Abbreviation of the LT.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/etp.html b/api-explorer/spot/lttrade/etp.html index 4d9a34054c..e461110895 100644 --- a/api-explorer/spot/lttrade/etp.html +++ b/api-explorer/spot/lttrade/etp.html @@ -4,13 +4,13 @@ Spot Leverage Token | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/market-info.html b/api-explorer/spot/lttrade/market-info.html index d515c6e085..e4c12a5bf5 100644 --- a/api-explorer/spot/lttrade/market-info.html +++ b/api-explorer/spot/lttrade/market-info.html @@ -4,13 +4,13 @@ Market Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/purchase-redemption-history.html b/api-explorer/spot/lttrade/purchase-redemption-history.html index b626f61aef..4f1d219363 100644 --- a/api-explorer/spot/lttrade/purchase-redemption-history.html +++ b/api-explorer/spot/lttrade/purchase-redemption-history.html @@ -4,13 +4,13 @@ Get Purchase or Redemption History | Bybit API Documentation - +
    Skip to main content

    Get Purchase or Redemption History

    Get Purchase or Redemption History

    Query Parameters
    • ltCode string

      Abbreviation of the LT.

    • orderId string

      Order ID

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • limit string

      Default value: 100

      Default value is 100, max 500

    • orderType integer[]

      Possible values: [1, 2]

      Order type; 1. Purchase; 2. Redemption

    • serialNo string

      Serial number

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/purchase.html b/api-explorer/spot/lttrade/purchase.html index 7147b6f842..a71d15d38d 100644 --- a/api-explorer/spot/lttrade/purchase.html +++ b/api-explorer/spot/lttrade/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +
    Skip to main content

    Purchase

    Purchase

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • ltCode string required

      Abbreviation of the LT.

    • ltAmount string required

      Market Buy order, it is amount to pay.

    • serialNo string

      Serial number

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/lttrade/redeem.html b/api-explorer/spot/lttrade/redeem.html index 6a9908ec3c..45d9ffed66 100644 --- a/api-explorer/spot/lttrade/redeem.html +++ b/api-explorer/spot/lttrade/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +
    Skip to main content

    Redeem

    Redeem

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • ltCode string required

      Abbreviation of the LT.

    • ltQuantity string required

      Market Buy order, it is amount to pay.

    • serialNo string

      Serial number

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/best-bidask-price.html b/api-explorer/spot/market/best-bidask-price.html index 84388b3f12..ea9f4cf66e 100644 --- a/api-explorer/spot/market/best-bidask-price.html +++ b/api-explorer/spot/market/best-bidask-price.html @@ -4,13 +4,13 @@ Best Bid/Ask Price | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/instrument-info.html b/api-explorer/spot/market/instrument-info.html index 47a68de7c2..9bb7214bbd 100644 --- a/api-explorer/spot/market/instrument-info.html +++ b/api-explorer/spot/market/instrument-info.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/last-traded-price.html b/api-explorer/spot/market/last-traded-price.html index 9084595769..25532203fd 100644 --- a/api-explorer/spot/market/last-traded-price.html +++ b/api-explorer/spot/market/last-traded-price.html @@ -4,13 +4,13 @@ Name of the trading pair | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/lastest-information-for-symbol.html b/api-explorer/spot/market/lastest-information-for-symbol.html index 92acbcc179..3d049cf2d8 100644 --- a/api-explorer/spot/market/lastest-information-for-symbol.html +++ b/api-explorer/spot/market/lastest-information-for-symbol.html @@ -4,13 +4,13 @@ Lastest Information for Symbol | Bybit API Documentation - +
    Skip to main content

    Lastest Information for Symbol

    Get Lastest Information for Symbol

    Query Parameters
    • symbol string

      Name of the trading pair

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/market.html b/api-explorer/spot/market/market.html index 5b4e10cefb..d4b37b3323 100644 --- a/api-explorer/spot/market/market.html +++ b/api-explorer/spot/market/market.html @@ -4,13 +4,13 @@ Market data | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/merged-order-book.html b/api-explorer/spot/market/merged-order-book.html index 77eae23ca2..f60617119e 100644 --- a/api-explorer/spot/market/merged-order-book.html +++ b/api-explorer/spot/market/merged-order-book.html @@ -4,13 +4,13 @@ Merged Order Book | Bybit API Documentation - +
    Skip to main content

    Merged Order Book

    Get Merged Order Book

    Query Parameters
    • symbol string required

      Name of the trading pair

    • scale integer

      Precision of the merged orderbook, 1 means 1 digit

    • limit integer

      Default value: 100

      Default value is 100. Max value is 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/order-book.html b/api-explorer/spot/market/order-book.html index 3e130f1a47..c78dc282c8 100644 --- a/api-explorer/spot/market/order-book.html +++ b/api-explorer/spot/market/order-book.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - +
    Skip to main content

    Order Book

    Get Order Book

    Query Parameters
    • symbol string required

      Name of the trading pair

    • limit integer

      Default value: 100

      Default value is 100. Max value is 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/public-trading-records.html b/api-explorer/spot/market/public-trading-records.html index b0cc6dade9..4967ebbc9a 100644 --- a/api-explorer/spot/market/public-trading-records.html +++ b/api-explorer/spot/market/public-trading-records.html @@ -4,13 +4,13 @@ Public Trading Records | Bybit API Documentation - +
    Skip to main content

    Public Trading Records

    Get Public Trading Records

    Query Parameters
    • symbol string required

      Name of the trading pair

    • limit integer

      Default value: 60

      Default value is 60, max 60

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/market/query-kline.html b/api-explorer/spot/market/query-kline.html index 3052e6ca50..45bf4789b1 100644 --- a/api-explorer/spot/market/query-kline.html +++ b/api-explorer/spot/market/query-kline.html @@ -4,13 +4,13 @@ Query Kline | Bybit API Documentation - +
    Skip to main content

    Query Kline

    Get Kline

    Query Parameters
    • symbol string required

      Name of the trading pair

    • interval string[] required

      Possible values: [1m, 3m, 5m, 15m, 30m, 1h, 2h, 4h, 6h, 12h, 1d, 1w, 1m]

      kline interval

    • limit integer

      Default value: 1000

      Default value is 1000, max 1000

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html b/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html index c2794dc039..5516e3e487 100644 --- a/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html +++ b/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html @@ -4,13 +4,13 @@ Batch Cancel Active Order By IDs | Bybit API Documentation - +
    Skip to main content

    Batch Cancel Active Order By IDs

    Batch Cancel Active Order By IDs

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • orderIds string required

      Order ID, use commas to indicate multiple orderIds. Maximum of 100 ids.

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/batch-cancel-active-order.html b/api-explorer/spot/trade/batch-cancel-active-order.html index dafa27f75f..31ec4b5c29 100644 --- a/api-explorer/spot/trade/batch-cancel-active-order.html +++ b/api-explorer/spot/trade/batch-cancel-active-order.html @@ -4,13 +4,13 @@ Batch Cancel Active Order | Bybit API Documentation - +
    Skip to main content

    Batch Cancel Active Order

    Batch Cancel Active Order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Name of the trading pair

    • side string

      Possible values: [Buy, Sell]

      Side

    • orderType string

      Order type. LIMIT in default. It allows multiple types, separated by comma, e.a LIMIT,LIMIT_MAKER

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/cancel-active-order.html b/api-explorer/spot/trade/cancel-active-order.html index 2ce83e7bc2..23f55d174e 100644 --- a/api-explorer/spot/trade/cancel-active-order.html +++ b/api-explorer/spot/trade/cancel-active-order.html @@ -4,13 +4,13 @@ Cancel Active Order | Bybit API Documentation - +
    Skip to main content

    Cancel Active Order

    Cancel Active Order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • orderId string

      Order ID. Required if not passing orderLinkId

    • orderLinkId string

      Unique user-set order ID. Required if not passing orderId

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/open-order.html b/api-explorer/spot/trade/open-order.html index 238732687c..d9b8d53a08 100644 --- a/api-explorer/spot/trade/open-order.html +++ b/api-explorer/spot/trade/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +
    Skip to main content

    Get Open Orders

    Get Open Orders.

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 500

      Default value is 500, max 500

    • orderCategory integer[]

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/order-history.html b/api-explorer/spot/trade/order-history.html index bb92773897..15d9b6749f 100644 --- a/api-explorer/spot/trade/order-history.html +++ b/api-explorer/spot/trade/order-history.html @@ -4,13 +4,13 @@ Get Order History | Bybit API Documentation - +
    Skip to main content

    Get Order History

    Get Order History

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 100

      Default value is 100, max 500

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • orderCategory integer[]

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/place-order.html b/api-explorer/spot/trade/place-order.html index 411f5492f7..0826b36b62 100644 --- a/api-explorer/spot/trade/place-order.html +++ b/api-explorer/spot/trade/place-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +
    Skip to main content

    Place Order

    Place a order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderQty string required

      Market Buy order, it is amount to pay.

    • side string required

      Possible values: [Buy, Sell]

      Side

    • orderType string required

      Possible values: [MARKET, LIMIT, LIMITMAKER]

      Order type

    • timeInForce string

      Possible values: [GTC, FOK, IOC]

      Time in force

    • orderPrice string

      Order price

    • orderLinkId string

      User customised order id

    • orderCategory integer

      Possible values: [0, 1]

      Order category. 0=normal order, 1=TP/SL order

    • triggerPrice string

      Tp/Sl order trigger price

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/spot-trade.html b/api-explorer/spot/trade/spot-trade.html index b75a4bc7bc..7fe7827537 100644 --- a/api-explorer/spot/trade/spot-trade.html +++ b/api-explorer/spot/trade/spot-trade.html @@ -4,13 +4,13 @@ Trade | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/trade-history.html b/api-explorer/spot/trade/trade-history.html index ac21835ac5..c5d08f3620 100644 --- a/api-explorer/spot/trade/trade-history.html +++ b/api-explorer/spot/trade/trade-history.html @@ -4,13 +4,13 @@ Get Trade History | Bybit API Documentation - +
    Skip to main content

    Get Trade History

    Get Trade History

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 100

      Default value is 100, max 500

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • fromTradeId string

      Query greater than the trade ID. (fromTicketId < trade ID)

    • toTradeId string

      Query smaller than the trade ID. (trade ID < toTicketId)

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/spot/trade/wallet-balance.html b/api-explorer/spot/trade/wallet-balance.html index 243fcab81d..dc6601319d 100644 --- a/api-explorer/spot/trade/wallet-balance.html +++ b/api-explorer/spot/trade/wallet-balance.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - +
    Skip to main content

    Get Wallet Balance

    Get Wallet Balance

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/account-info.html b/api-explorer/v5/account/account-info.html index 006ed90c95..9f845bce27 100644 --- a/api-explorer/v5/account/account-info.html +++ b/api-explorer/v5/account/account-info.html @@ -4,13 +4,13 @@ Get Account Info | Bybit API Documentation - +
    Skip to main content

    Get Account Info

    Get account info

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/account.html b/api-explorer/v5/account/account.html index d75d41b2e1..4b5e45c4b0 100644 --- a/api-explorer/v5/account/account.html +++ b/api-explorer/v5/account/account.html @@ -4,13 +4,13 @@ Account | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/borrow-history.html b/api-explorer/v5/account/borrow-history.html index f52c8d0390..50d31b1e8c 100644 --- a/api-explorer/v5/account/borrow-history.html +++ b/api-explorer/v5/account/borrow-history.html @@ -4,13 +4,13 @@ Get Borrow History | Bybit API Documentation - +
    Skip to main content

    Get Borrow History

    Get borrow history

    Query Parameters
    • currency string

      e.g., USDC, USDT, BTC, ETH

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit per page. 1-50

    • cursor string

      Cusor, used for pagiation

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/coin-greeks.html b/api-explorer/v5/account/coin-greeks.html index 77b6dc470f..531f996a61 100644 --- a/api-explorer/v5/account/coin-greeks.html +++ b/api-explorer/v5/account/coin-greeks.html @@ -4,13 +4,13 @@ Get Coin Greeks | Bybit API Documentation - +
    Skip to main content

    Get Coin Greeks

    Get coin greek info

    Query Parameters
    • baseCoin string

      Base coin

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/collateral-info.html b/api-explorer/v5/account/collateral-info.html index aff029dbec..1874c42783 100644 --- a/api-explorer/v5/account/collateral-info.html +++ b/api-explorer/v5/account/collateral-info.html @@ -4,13 +4,13 @@ Get Collateral Info | Bybit API Documentation - +
    Skip to main content

    Get Collateral Info

    Get collateral info

    Query Parameters
    • currency string

      Collateral asset

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/fee-rate.html b/api-explorer/v5/account/fee-rate.html index e5aec60992..f78bde62af 100644 --- a/api-explorer/v5/account/fee-rate.html +++ b/api-explorer/v5/account/fee-rate.html @@ -4,13 +4,13 @@ Get Fee Rate | Bybit API Documentation - +
    Skip to main content

    Get Fee Rate

    Get fee rate

    Query Parameters
    • category string required

      Possible values: [spot, linear, inverse, option]

      Product type. working for spot and option

    • symbol string

      Symbol name. valid for linear,inverse and spot

    • baseCoin string

      Possible values: [SOL, BTC, ETH]

      Base coin. Valid for option

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/set-margin-mode.html b/api-explorer/v5/account/set-margin-mode.html index ebe1c2c6fa..0fb74a70f1 100644 --- a/api-explorer/v5/account/set-margin-mode.html +++ b/api-explorer/v5/account/set-margin-mode.html @@ -4,13 +4,13 @@ Set Margin Mode | Bybit API Documentation - +
    Skip to main content

    Set Margin Mode

    Set margin mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • setMarginMode string required

      Possible values: [REGULAR_MARGIN, ISOLATED_MARGIN, PORTFOLIO_MARGIN]

      Margin mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/transaction-log.html b/api-explorer/v5/account/transaction-log.html index c97e7a80c2..abf46aa392 100644 --- a/api-explorer/v5/account/transaction-log.html +++ b/api-explorer/v5/account/transaction-log.html @@ -4,13 +4,13 @@ Get Transaction Log | Bybit API Documentation - +
    Skip to main content

    Get Transaction Log

    Get transaction log

    Query Parameters
    • accountType string

      Possible values: [UNIFIED]

      Support UNIFIED for now

    • category string

      Possible values: [spot, linear, option]

      Product category

    • currency string

      Currency

    • baseCoin string

      Base coin

    • type string

      Possible values: [TRANSFER_IN, TRANSFER_OUT, TRADE, SETTLEMENT, DELIVERY, LIQUIDATION, BONUS, FEE_REFUND, INTEREST, CURRENCY_BUY, CURRENCY_SELL]

      Transaction log type

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size for each page. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/upgrade-unified-account.html b/api-explorer/v5/account/upgrade-unified-account.html index be8d2b22b4..cba16ab1ac 100644 --- a/api-explorer/v5/account/upgrade-unified-account.html +++ b/api-explorer/v5/account/upgrade-unified-account.html @@ -4,13 +4,13 @@ Upgrade to Unified Account | Bybit API Documentation - +
    Skip to main content

    Upgrade to Unified Account

    Upgrade to UTA

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • object
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/account/wallet.html b/api-explorer/v5/account/wallet.html index ea31d6e155..999e5087a1 100644 --- a/api-explorer/v5/account/wallet.html +++ b/api-explorer/v5/account/wallet.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - +
    Skip to main content

    Get Wallet Balance

    Get wallet balance

    Query Parameters
    • accountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT]

      Account type

    • coin string

      Coin name. You can pass mutiple coins like USDT,USDC

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/account-coin-balance.html b/api-explorer/v5/asset/account-coin-balance.html index 6020c82357..b1496f356a 100644 --- a/api-explorer/v5/asset/account-coin-balance.html +++ b/api-explorer/v5/asset/account-coin-balance.html @@ -4,13 +4,13 @@ Get Single Coin Balance | Bybit API Documentation - +
    Skip to main content

    Get Single Coin Balance

    Get Single Coin Balance

    Query Parameters
    • memberId string

      If query sub user balance, please input sub uid

    • accountType string required

      Possible values: [SPOT, CONTRACT, UNIFIED, OPTION, INVESTMENT, FUND]

      Account type

    • coin string required

      Coin name

    • withBonus integer

      Possible values: [0, 1]

      Query bonus or not. 0=false, 1=true

    • withTransferSafeAmount integer

      Possible values: [0, 1]

      Whether query delay withdraw/transfer safe amount. 0:false, 1;true

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/all-balance.html b/api-explorer/v5/asset/all-balance.html index 6ae72a9b4d..8a3369f505 100644 --- a/api-explorer/v5/asset/all-balance.html +++ b/api-explorer/v5/asset/all-balance.html @@ -4,13 +4,13 @@ Get All Coins Balance | Bybit API Documentation - +
    Skip to main content

    Get All Coins Balance

    Get All Coins Balance

    Query Parameters
    • memberId string

      If query sub user balance, please input sub uid

    • accountType string required

      Possible values: [SPOT, CONTRACT, UNIFIED, OPTION, INVESTMENT, FUND]

      Account type

    • coin string

      Coin name

    • withBonus integer

      Possible values: [0, 1]

      Query bonus or not. 0=false, 1=true

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/asset-info.html b/api-explorer/v5/asset/asset-info.html index d6b368c6f7..87a862e977 100644 --- a/api-explorer/v5/asset/asset-info.html +++ b/api-explorer/v5/asset/asset-info.html @@ -4,13 +4,13 @@ Get Asset Info (Spot) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/asset.html b/api-explorer/v5/asset/asset.html index c2d1592c97..7feb41285d 100644 --- a/api-explorer/v5/asset/asset.html +++ b/api-explorer/v5/asset/asset.html @@ -4,13 +4,13 @@ Asset | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/coin-info.html b/api-explorer/v5/asset/coin-info.html index dad39160f8..a86e4434b6 100644 --- a/api-explorer/v5/asset/coin-info.html +++ b/api-explorer/v5/asset/coin-info.html @@ -4,13 +4,13 @@ Get Coin Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/create-inter-transfer.html b/api-explorer/v5/asset/create-inter-transfer.html index 6cfd17c9cd..091c6165da 100644 --- a/api-explorer/v5/asset/create-inter-transfer.html +++ b/api-explorer/v5/asset/create-inter-transfer.html @@ -4,13 +4,13 @@ Create Internal Transfer | Bybit API Documentation - +
    Skip to main content

    Create Internal Transfer

    Create internal transfer

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • transferId string required

      UUID

    • coin string required

      Coin

    • amount string required

      Amount

    • fromAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, OPTION, INVESTMENT, FUND]

      From account type

    • toAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, OPTION, INVESTMENT, FUND]

      To account type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/deposit-coin-spec.html b/api-explorer/v5/asset/deposit-coin-spec.html index cc5016dcfe..e342da2b5f 100644 --- a/api-explorer/v5/asset/deposit-coin-spec.html +++ b/api-explorer/v5/asset/deposit-coin-spec.html @@ -4,13 +4,13 @@ Get Allowed Deposit Coin Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/deposit-record.html b/api-explorer/v5/asset/deposit-record.html index f8625210b4..6edc0a51fa 100644 --- a/api-explorer/v5/asset/deposit-record.html +++ b/api-explorer/v5/asset/deposit-record.html @@ -4,13 +4,13 @@ Get Deposit Record (on-chain) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/enable-unitransfer-subuid.html b/api-explorer/v5/asset/enable-unitransfer-subuid.html index 45da7814cd..c60e8907a9 100644 --- a/api-explorer/v5/asset/enable-unitransfer-subuid.html +++ b/api-explorer/v5/asset/enable-unitransfer-subuid.html @@ -4,13 +4,13 @@ Enable Universal Transfer For Sub UID | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/exchange.html b/api-explorer/v5/asset/exchange.html index 9e4e2bd50c..85dd91e26f 100644 --- a/api-explorer/v5/asset/exchange.html +++ b/api-explorer/v5/asset/exchange.html @@ -4,13 +4,13 @@ Get Coin Exchange Records | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/inter-transfer-list.html b/api-explorer/v5/asset/inter-transfer-list.html index 5919266597..29d63f2976 100644 --- a/api-explorer/v5/asset/inter-transfer-list.html +++ b/api-explorer/v5/asset/inter-transfer-list.html @@ -4,13 +4,13 @@ Get Internal Transfer Records | Bybit API Documentation - +
    Skip to main content

    Get Internal Transfer Records

    Get internal transfer records

    Query Parameters
    • transferId string

      Transfer id

    • coin string

      Coin name

    • status string

      Possible values: [SUCCESS, PENDING, FAILED]

      Status

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/internal-deposit-record.html b/api-explorer/v5/asset/internal-deposit-record.html index a9b9cf7404..6d69672f17 100644 --- a/api-explorer/v5/asset/internal-deposit-record.html +++ b/api-explorer/v5/asset/internal-deposit-record.html @@ -4,13 +4,13 @@ Get Internal Deposit Records (across Bybit) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/master-deposit-addr.html b/api-explorer/v5/asset/master-deposit-addr.html index 21e52c781b..c28c681aef 100644 --- a/api-explorer/v5/asset/master-deposit-addr.html +++ b/api-explorer/v5/asset/master-deposit-addr.html @@ -4,13 +4,13 @@ Get Master Deposit Address | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/option-delivery.html b/api-explorer/v5/asset/option-delivery.html index 6813957426..b9e7e9debe 100644 --- a/api-explorer/v5/asset/option-delivery.html +++ b/api-explorer/v5/asset/option-delivery.html @@ -4,13 +4,13 @@ Get Option Delivery Record | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/set-deposit-acct.html b/api-explorer/v5/asset/set-deposit-acct.html index 10ca241733..55d6405b7e 100644 --- a/api-explorer/v5/asset/set-deposit-acct.html +++ b/api-explorer/v5/asset/set-deposit-acct.html @@ -4,13 +4,13 @@ Set Deposit Account | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/settlement.html b/api-explorer/v5/asset/settlement.html index f928dcae0d..c2bc39e179 100644 --- a/api-explorer/v5/asset/settlement.html +++ b/api-explorer/v5/asset/settlement.html @@ -4,13 +4,13 @@ Get USDC Perpetual Settlement | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/sub-deposit-addr.html b/api-explorer/v5/asset/sub-deposit-addr.html index cd90cbc47b..3e2a2d3ca1 100644 --- a/api-explorer/v5/asset/sub-deposit-addr.html +++ b/api-explorer/v5/asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ Get Sub Deposit Address | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/sub-deposit-record.html b/api-explorer/v5/asset/sub-deposit-record.html index 8740caace5..b2c02a0047 100644 --- a/api-explorer/v5/asset/sub-deposit-record.html +++ b/api-explorer/v5/asset/sub-deposit-record.html @@ -4,13 +4,13 @@ Get Sub Account Deposit Records (on-chain) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/sub-uid-list.html b/api-explorer/v5/asset/sub-uid-list.html index 6d3f929ec4..7d16f42fb7 100644 --- a/api-explorer/v5/asset/sub-uid-list.html +++ b/api-explorer/v5/asset/sub-uid-list.html @@ -4,13 +4,13 @@ Get Sub UID | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/transferable-coin.html b/api-explorer/v5/asset/transferable-coin.html index df98c1908a..e0d0114fe0 100644 --- a/api-explorer/v5/asset/transferable-coin.html +++ b/api-explorer/v5/asset/transferable-coin.html @@ -4,13 +4,13 @@ Get Transferable Coin | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/unitransfer-list.html b/api-explorer/v5/asset/unitransfer-list.html index e544629f31..29498d2a5d 100644 --- a/api-explorer/v5/asset/unitransfer-list.html +++ b/api-explorer/v5/asset/unitransfer-list.html @@ -4,13 +4,13 @@ Get Universal Transfer Records | Bybit API Documentation - +
    Skip to main content

    Get Universal Transfer Records

    Get universal transfer record

    Query Parameters
    • transferId string

      Transfer id

    • coin string

      Coin name

    • status string

      Possible values: [SUCCESS, FAILED, PENDING]

      Status

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/unitransfer.html b/api-explorer/v5/asset/unitransfer.html index ff088b8d09..320f87b474 100644 --- a/api-explorer/v5/asset/unitransfer.html +++ b/api-explorer/v5/asset/unitransfer.html @@ -4,13 +4,13 @@ Create Universal Transfer | Bybit API Documentation - +
    Skip to main content

    Create Universal Transfer

    Create universal transfer

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Request Body
    • transferId sting required

      Transfer id. UUID

    • coin sting required

      Coin name

    • amount sting required

      Amount

    • fromMemberId intger required

      From UID

    • toMemberId integer required

      To UID

    • fromAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, INVESTMENT, OPTION, FUND]

      From account type

    • toAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, INVESTMENT, OPTION, FUND]

      To account type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/asset/withdraw-record.html b/api-explorer/v5/asset/withdraw-record.html index 8f3f137a6b..9e05b1cc95 100644 --- a/api-explorer/v5/asset/withdraw-record.html +++ b/api-explorer/v5/asset/withdraw-record.html @@ -4,13 +4,13 @@ Get Withdraw Records | Bybit API Documentation - +
    Skip to main content

    Get Withdraw Records

    Get withdraw record

    Query Parameters
    • withdrawID string

      Withdraw ID

    • coin string

      Coin name

    • withdrawType integer

      Possible values: [0, 1, 2]

      Withdraw type. 0=on chain, 1=off chain, 2=all

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      Limit size. 1-50

    • cursor string

      Cursor, used to pagination

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/category.html b/api-explorer/v5/category.html index e2836b3204..8a0139c527 100644 --- a/api-explorer/v5/category.html +++ b/api-explorer/v5/category.html @@ -4,13 +4,13 @@ V5 API | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/etp.html b/api-explorer/v5/lt/etp.html index 25156f3ed4..9538009431 100644 --- a/api-explorer/v5/lt/etp.html +++ b/api-explorer/v5/lt/etp.html @@ -4,13 +4,13 @@ Spot Leverage Token | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/leverage-token-info.html b/api-explorer/v5/lt/leverage-token-info.html index 44e6d68d05..a6af7634d1 100644 --- a/api-explorer/v5/lt/leverage-token-info.html +++ b/api-explorer/v5/lt/leverage-token-info.html @@ -4,13 +4,13 @@ Get Leverage Token Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/leverage-token-reference.html b/api-explorer/v5/lt/leverage-token-reference.html index b50d706b32..a58eb63e93 100644 --- a/api-explorer/v5/lt/leverage-token-reference.html +++ b/api-explorer/v5/lt/leverage-token-reference.html @@ -4,13 +4,13 @@ Get Leverage Token Market | Bybit API Documentation - +
    Skip to main content

    Get Leverage Token Market

    Get lt market information

    Query Parameters
    • ltCoin string required

      Levearage coin name. e.g., BTC3L

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/order-record.html b/api-explorer/v5/lt/order-record.html index a5a4131404..d05e85137a 100644 --- a/api-explorer/v5/lt/order-record.html +++ b/api-explorer/v5/lt/order-record.html @@ -4,13 +4,13 @@ Get Purchase or Redeem Records | Bybit API Documentation - +
    Skip to main content

    Get Purchase or Redeem Records

    Get the order history of purchase or redeem

    Query Parameters
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • orderId string

      Order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 100

      Limit size of each page. 1-500

    • ltOrderType integer

      Possible values: [1, 2]

      LT order type. 1=purchase, 2=redeem

    • serialNo string

      Serial number

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/purchase.html b/api-explorer/v5/lt/purchase.html index f3129d51e8..2dc9fb4f99 100644 --- a/api-explorer/v5/lt/purchase.html +++ b/api-explorer/v5/lt/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +
    Skip to main content

    Purchase

    Purchase leverage token

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • ltAmount string

      Purchase amount

    • serialNo string

      Serial number, customised order id

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/lt/redeem.html b/api-explorer/v5/lt/redeem.html index 207f119f98..f9c927c110 100644 --- a/api-explorer/v5/lt/redeem.html +++ b/api-explorer/v5/lt/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +
    Skip to main content

    Redeem

    Redeem leverage token

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • quantity string

      Redeem quantity

    • serialNo string

      Serial number, customised order id

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/delivery-price.html b/api-explorer/v5/market/delivery-price.html index 68ef432e3a..44ce92d2cf 100644 --- a/api-explorer/v5/market/delivery-price.html +++ b/api-explorer/v5/market/delivery-price.html @@ -4,13 +4,13 @@ Get Option Delivery Price | Bybit API Documentation - +
    Skip to main content

    Get Option Delivery Price

    Get delivery price of option

    Query Parameters
    • category string[] required

      Possible values: [option]

      Product type. option only

    • symbol string

      Symbol name

    • baseCoin string

      Default value: BTC

      Base coin. Return BTC by default

    • limit string

      Default value: 50

      Maximum 200

    • cursor string

      The cursor, used for pagination

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/history-fund-rate.html b/api-explorer/v5/market/history-fund-rate.html index 09794f1347..40a2981439 100644 --- a/api-explorer/v5/market/history-fund-rate.html +++ b/api-explorer/v5/market/history-fund-rate.html @@ -4,13 +4,13 @@ Get Funding Rate History | Bybit API Documentation - +
    Skip to main content

    Get Funding Rate History

    Get historical funding rate

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • startTime integer

      The start timstamp (ms)

    • endTime integer

      The end timstamp (ms)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/index-kline.html b/api-explorer/v5/market/index-kline.html index 1c9fcf819b..77d23b0827 100644 --- a/api-explorer/v5/market/index-kline.html +++ b/api-explorer/v5/market/index-kline.html @@ -4,13 +4,13 @@ Get Index Price Kline | Bybit API Documentation - +
    Skip to main content

    Get Index Price Kline

    Get Index Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/instrument.html b/api-explorer/v5/market/instrument.html index ed57f48ed6..a4f787c390 100644 --- a/api-explorer/v5/market/instrument.html +++ b/api-explorer/v5/market/instrument.html @@ -4,13 +4,13 @@ Get Instrument Info | Bybit API Documentation - +
    Skip to main content

    Get Instrument Info

    Get launched instruments information.

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • status string

      Possible values: [PreLaunch, Trading, Settling, Delivering, Closed]

      Status filter

    • baseCoin string

      for linear, invere and option ONLY

    • limit integer

      Default value: 500

      Maximum 1000. spot does not have pagination

    • cursor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/insurance.html b/api-explorer/v5/market/insurance.html index 9562ac8aaf..070cb36c4d 100644 --- a/api-explorer/v5/market/insurance.html +++ b/api-explorer/v5/market/insurance.html @@ -4,13 +4,13 @@ Get Insurance | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/iv.html b/api-explorer/v5/market/iv.html index dff5ef5fb4..fb7cb96739 100644 --- a/api-explorer/v5/market/iv.html +++ b/api-explorer/v5/market/iv.html @@ -4,13 +4,13 @@ Get Historical Volatility | Bybit API Documentation - +
    Skip to main content

    Get Historical Volatility

    Get historical volatility

    Query Parameters
    • category string[] required

      Possible values: [option]

      Product type

    • baseCoin string

      Default value: BTC

      Base coin. If not passed, BTC returned by default

    • period integer[]

      Possible values: [7, 14, 21, 30, 60, 90, 180, 270]

      Period. If not passed, it returns 7 days by default. SOL does not have 180 and 270

    • startTime integer

      The start timstamp (ms)

    • endTime integer

      The end timstamp (ms)

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/kline.html b/api-explorer/v5/market/kline.html index ff2839fd14..d7bc9f6281 100644 --- a/api-explorer/v5/market/kline.html +++ b/api-explorer/v5/market/kline.html @@ -4,13 +4,13 @@ Get Kline | Bybit API Documentation - +
    Skip to main content

    Get Kline

    Get kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, spot]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/mark-kline.html b/api-explorer/v5/market/mark-kline.html index 73e9112813..347575d3ce 100644 --- a/api-explorer/v5/market/mark-kline.html +++ b/api-explorer/v5/market/mark-kline.html @@ -4,13 +4,13 @@ Get Mark Price Kline | Bybit API Documentation - +
    Skip to main content

    Get Mark Price Kline

    Get Mark Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, spot]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/market.html b/api-explorer/v5/market/market.html index 586fa63da6..f05a818a60 100644 --- a/api-explorer/v5/market/market.html +++ b/api-explorer/v5/market/market.html @@ -4,13 +4,13 @@ Market | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/open-interest.html b/api-explorer/v5/market/open-interest.html index 904ce60087..b9a0fdab28 100644 --- a/api-explorer/v5/market/open-interest.html +++ b/api-explorer/v5/market/open-interest.html @@ -4,13 +4,13 @@ Get Open Interest | Bybit API Documentation - +
    Skip to main content

    Get Open Interest

    Get open interest

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • intervalTime string[] required

      Possible values: [5min, 15min, 30min, 1h, 4h, 1d]

      interval time

    • startTime integer

      The start timstamp (ms)

    • endTime integer

      The end timstamp (ms)

    • limit integer

      Default value: 50

      Maximum 200

    • cursor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/orderbook.html b/api-explorer/v5/market/orderbook.html index f6957516dd..ec3dbc53a8 100644 --- a/api-explorer/v5/market/orderbook.html +++ b/api-explorer/v5/market/orderbook.html @@ -4,13 +4,13 @@ Get Orderbook | Bybit API Documentation - +
    Skip to main content

    Get Orderbook

    Get order book data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name

    • limit integer

      spot:1-50,default:1. linear&inverse:1-200,default:25. option:1-25,default:1

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/premium-index-kline.html b/api-explorer/v5/market/premium-index-kline.html index d87f0e5ff6..b6d288e71c 100644 --- a/api-explorer/v5/market/premium-index-kline.html +++ b/api-explorer/v5/market/premium-index-kline.html @@ -4,13 +4,13 @@ Get Premium Index Price Kline | Bybit API Documentation - +
    Skip to main content

    Get Premium Index Price Kline

    Get Premium Index Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/recent-trade.html b/api-explorer/v5/market/recent-trade.html index 85acb8bb1b..945678346f 100644 --- a/api-explorer/v5/market/recent-trade.html +++ b/api-explorer/v5/market/recent-trade.html @@ -4,13 +4,13 @@ Get Public Recent Trading History | Bybit API Documentation - +
    Skip to main content

    Get Public Recent Trading History

    Get public trade

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name.

    • baseCoin string

      Default value: BTC

      Base coin. Valid for option. Default is BTC

    • optionType string

      Possible values: [Call, Put]

      Option type. Valid for option.

    • limit integer

      Maximum 60 for spot. Maximum 1000 for others

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/risk-limit.html b/api-explorer/v5/market/risk-limit.html index db44d67e31..452b6956ec 100644 --- a/api-explorer/v5/market/risk-limit.html +++ b/api-explorer/v5/market/risk-limit.html @@ -4,13 +4,13 @@ Get Risk Limit | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/tickers.html b/api-explorer/v5/market/tickers.html index 64bac76311..f4a1baf3b6 100644 --- a/api-explorer/v5/market/tickers.html +++ b/api-explorer/v5/market/tickers.html @@ -4,13 +4,13 @@ Get Tickers | Bybit API Documentation - +
    Skip to main content

    Get Tickers

    Get all latest information of symbols. All parameters are needed for OPTION

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • baseCoin string

      for option ONLY, baseCoin or symbol must be passed when query option

    • expDate string

      Expiry date. For option only. Default is all, and the parameter format is 25MAR22.

    • symbol string

      Symbol name

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/market/time.html b/api-explorer/v5/market/time.html index 82510728f7..6819635b3f 100644 --- a/api-explorer/v5/market/time.html +++ b/api-explorer/v5/market/time.html @@ -4,13 +4,13 @@ Get Bybit Server Time | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/auto-add-margin.html b/api-explorer/v5/position/auto-add-margin.html index b711c980fa..8e682a2f36 100644 --- a/api-explorer/v5/position/auto-add-margin.html +++ b/api-explorer/v5/position/auto-add-margin.html @@ -4,13 +4,13 @@ Set Auto Add Margin | Bybit API Documentation - +
    Skip to main content

    Set Auto Add Margin

    Set Auto Add Margin

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • autoAddMargin integer required

      0 - turn off, 1 - turn on

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/close-pnl.html b/api-explorer/v5/position/close-pnl.html index 7dbbadc8e8..9898a9ce8f 100644 --- a/api-explorer/v5/position/close-pnl.html +++ b/api-explorer/v5/position/close-pnl.html @@ -4,13 +4,13 @@ Get Closed PnL | Bybit API Documentation - +
    Skip to main content

    Get Closed PnL

    Get closed pnl

    Query Parameters
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string

      Symbol name

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/cross-isolate.html b/api-explorer/v5/position/cross-isolate.html index 84df251417..6230abc32d 100644 --- a/api-explorer/v5/position/cross-isolate.html +++ b/api-explorer/v5/position/cross-isolate.html @@ -4,13 +4,13 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +
    Skip to main content

    Switch Cross/Isolated Margin

    Select cross margin mode or isolated margin mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • tradeMode integer required

      Possible values: [0, 1]

      0 - cross margin, 1 - isolated margin

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/execution.html b/api-explorer/v5/position/execution.html index d36c1cebe7..a464f51822 100644 --- a/api-explorer/v5/position/execution.html +++ b/api-explorer/v5/position/execution.html @@ -4,13 +4,13 @@ Get Execution (2 years) | Bybit API Documentation - +
    Skip to main content

    Get Execution (2 years)

    Get execution list

    Query Parameters
    • category string required

      Possible values: [linear, inverse, spot, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • execType string

      Execution type

    • limit integer

      Default value: 50

      1-100. max 100

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/leverage.html b/api-explorer/v5/position/leverage.html index de7328dc8e..78622ec14e 100644 --- a/api-explorer/v5/position/leverage.html +++ b/api-explorer/v5/position/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +
    Skip to main content

    Set Leverage

    Set levearage.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/manual-add-margin.html b/api-explorer/v5/position/manual-add-margin.html index f3e6bafce5..08e5d514d8 100644 --- a/api-explorer/v5/position/manual-add-margin.html +++ b/api-explorer/v5/position/manual-add-margin.html @@ -4,13 +4,13 @@ Add Or Reduce Margin | Bybit API Documentation - +
    Skip to main content

    Add Or Reduce Margin

    Manually add or reduce margin for isolated margin position

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • margin string required

      10 - add, -10 - reduce

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/position-info.html b/api-explorer/v5/position/position-info.html index 8e6d94aab5..8fd57d8b4c 100644 --- a/api-explorer/v5/position/position-info.html +++ b/api-explorer/v5/position/position-info.html @@ -4,13 +4,13 @@ Get Position Info | Bybit API Documentation - +
    Skip to main content

    Get Position Info

    Get Position Info

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin. For option only

    • settleCoin string

      Used for linear & inverse, symbol or settleCoin is required

    • limit integer

      Default value: 20

      1-200. max 200

    • cursor string

      cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/position-mode.html b/api-explorer/v5/position/position-mode.html index c118025392..2cda4d636e 100644 --- a/api-explorer/v5/position/position-mode.html +++ b/api-explorer/v5/position/position-mode.html @@ -4,13 +4,13 @@ Switch Position Mode | Bybit API Documentation - +
    Skip to main content

    Switch Position Mode

    Switch Position Mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string

      Symbol name

    • coin string

      Coin name

    • mode integer required

      Possible values: [0, 3]

      Position mode. 0 - Merged single, 3 - Both sides

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/position.html b/api-explorer/v5/position/position.html index 599cff248f..b8cbc5848d 100644 --- a/api-explorer/v5/position/position.html +++ b/api-explorer/v5/position/position.html @@ -4,13 +4,13 @@ Position | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/set-risk-limit.html b/api-explorer/v5/position/set-risk-limit.html index 8ed015736b..6049d93558 100644 --- a/api-explorer/v5/position/set-risk-limit.html +++ b/api-explorer/v5/position/set-risk-limit.html @@ -4,13 +4,13 @@ Set Risk Limit | Bybit API Documentation - +
    Skip to main content

    Set Risk Limit

    Set risk limit.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • riskId integer required

      Risk limit id

    • positionIdx integer

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/tpsl-mode.html b/api-explorer/v5/position/tpsl-mode.html index 9fa7d9675d..9df2d754c1 100644 --- a/api-explorer/v5/position/tpsl-mode.html +++ b/api-explorer/v5/position/tpsl-mode.html @@ -4,13 +4,13 @@ Set TP/SL Mode | Bybit API Documentation - +
    Skip to main content

    Set TP/SL Mode

    Set tp/sl mode.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • tpSlMode string required

      Possible values: [Full, Partial]

      Full = full position TP/SL, Partial = partial mode tp/sl

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/position/trading-stop.html b/api-explorer/v5/position/trading-stop.html index fdcf654ec3..df29200d9d 100644 --- a/api-explorer/v5/position/trading-stop.html +++ b/api-explorer/v5/position/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +
    Skip to main content

    Set Trading Stop

    Set trade stop.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpSize string

      Take profit size

    • slSize string

      Stop loss size

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Take profit trigger price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Stop loss trigger price type

    • trailingStop string

      Trailing stop

    • activePrice string

      Trailing stop trigger price

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    • tpOrderType string

      Possible values: [Market, Limit]

      The order type when take profit is triggered

    • slOrderType string

      Possible values: [Market, Limit]

      The order type when stop loss is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/account-info.html b/api-explorer/v5/spot-margin-normal/account-info.html index 7746dfc150..9860faf441 100644 --- a/api-explorer/v5/spot-margin-normal/account-info.html +++ b/api-explorer/v5/spot-margin-normal/account-info.html @@ -4,13 +4,13 @@ Get Loan Account Info | Bybit API Documentation - +
    Skip to main content

    Get Loan Account Info

    Get Loan Account Info

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/borrow-order.html b/api-explorer/v5/spot-margin-normal/borrow-order.html index 1fc0d647cb..5574cdb5f0 100644 --- a/api-explorer/v5/spot-margin-normal/borrow-order.html +++ b/api-explorer/v5/spot-margin-normal/borrow-order.html @@ -4,13 +4,13 @@ Get Borrow Order Detail | Bybit API Documentation - +
    Skip to main content

    Get Borrow Order Detail

    Get Borrow Order Detail

    Query Parameters
    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • coin string

      Coin name

    • status string

      Possible values: [0, 1, 2]

      Status filter. 0:get all kinds of status, 1:uncleared, 2:cleared

    • limit integer

      Limit for data size per page. 1 - 500. Default:500

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/borrow.html b/api-explorer/v5/spot-margin-normal/borrow.html index 0c7816071e..a441f109d2 100644 --- a/api-explorer/v5/spot-margin-normal/borrow.html +++ b/api-explorer/v5/spot-margin-normal/borrow.html @@ -4,13 +4,13 @@ Borrow | Bybit API Documentation - +
    Skip to main content

    Borrow

    Borrow

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Request Body
    • coin string

      Coin name

    • qty string

      Amount to borrow

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/borrowable-data.html b/api-explorer/v5/spot-margin-normal/borrowable-data.html index b10145e0ed..984f4d2299 100644 --- a/api-explorer/v5/spot-margin-normal/borrowable-data.html +++ b/api-explorer/v5/spot-margin-normal/borrowable-data.html @@ -4,13 +4,13 @@ Get Borrowable Coin Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/interest-quota.html b/api-explorer/v5/spot-margin-normal/interest-quota.html index a09e4aa665..39215559f8 100644 --- a/api-explorer/v5/spot-margin-normal/interest-quota.html +++ b/api-explorer/v5/spot-margin-normal/interest-quota.html @@ -4,13 +4,13 @@ Get Interest & Quota | Bybit API Documentation - +
    Skip to main content

    Get Interest & Quota

    Get Interest & Quota

    Query Parameters
    • coin string required

      Coin name

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/margin-data.html b/api-explorer/v5/spot-margin-normal/margin-data.html index b318ef2740..4a435d61c2 100644 --- a/api-explorer/v5/spot-margin-normal/margin-data.html +++ b/api-explorer/v5/spot-margin-normal/margin-data.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/normal-margin-trade.html b/api-explorer/v5/spot-margin-normal/normal-margin-trade.html index 8c99b9b2ab..8ef5086085 100644 --- a/api-explorer/v5/spot-margin-normal/normal-margin-trade.html +++ b/api-explorer/v5/spot-margin-normal/normal-margin-trade.html @@ -4,13 +4,13 @@ Spot Margin Trade (Normal) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/repay-order.html b/api-explorer/v5/spot-margin-normal/repay-order.html index 04671e33a7..945cafc774 100644 --- a/api-explorer/v5/spot-margin-normal/repay-order.html +++ b/api-explorer/v5/spot-margin-normal/repay-order.html @@ -4,13 +4,13 @@ Get Repayment Order Detail | Bybit API Documentation - +
    Skip to main content

    Get Repayment Order Detail

    Get Repayment Order Detail

    Query Parameters
    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • coin string

      Coin name

    • limit integer

      Limit for data size per page. 1 - 500. Default:500

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/repay.html b/api-explorer/v5/spot-margin-normal/repay.html index 31e3b112cb..11069edd0c 100644 --- a/api-explorer/v5/spot-margin-normal/repay.html +++ b/api-explorer/v5/spot-margin-normal/repay.html @@ -4,13 +4,13 @@ Repay | Bybit API Documentation - +
    Skip to main content

    Repay

    Repay

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Request Body
    • coin string

      Coin name

    • qty string

      Amount to repay

    • completeRepayment integer

      Possible values: [0, 1]

      Whether to pay off all debts. 0:false, 1:true

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-normal/switch-mode.html b/api-explorer/v5/spot-margin-normal/switch-mode.html index 3e04e30041..11534a332b 100644 --- a/api-explorer/v5/spot-margin-normal/switch-mode.html +++ b/api-explorer/v5/spot-margin-normal/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +
    Skip to main content

    Toggle Margin Trade

    Toggle Margin Trade

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Request Body
    • switch integer

      1:on, 0:off

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-uta/set-leverage.html b/api-explorer/v5/spot-margin-uta/set-leverage.html index 2694cde922..445ce68f60 100644 --- a/api-explorer/v5/spot-margin-uta/set-leverage.html +++ b/api-explorer/v5/spot-margin-uta/set-leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +
    Skip to main content

    Set Leverage

    Set leverage for margin trade

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • leverage integer

      Possible values: [2, 3, 4, 5, 6, 7, 8, 9, 10]

      Levearge, support 2-10

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-uta/switch-mode.html b/api-explorer/v5/spot-margin-uta/switch-mode.html index 5c3a68f12c..1979597d5e 100644 --- a/api-explorer/v5/spot-margin-uta/switch-mode.html +++ b/api-explorer/v5/spot-margin-uta/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +
    Skip to main content

    Toggle Margin Trade

    Toggle margin trade

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • spotMarginMode integer

      Possible values: [0, 1]

      Margin mode. 0=off, 1=on

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/spot-margin-uta/uta-margin-trade.html b/api-explorer/v5/spot-margin-uta/uta-margin-trade.html index a33179815f..4bc1c4da34 100644 --- a/api-explorer/v5/spot-margin-uta/uta-margin-trade.html +++ b/api-explorer/v5/spot-margin-uta/uta-margin-trade.html @@ -4,13 +4,13 @@ Spot Margin Trade (UTA) | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/amend-order.html b/api-explorer/v5/trade/amend-order.html index 20d3ebe746..babc96585c 100644 --- a/api-explorer/v5/trade/amend-order.html +++ b/api-explorer/v5/trade/amend-order.html @@ -4,13 +4,13 @@ Amend Order | Bybit API Documentation - +
    Skip to main content

    Amend Order

    Amend an order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • orderIv string

      Modify option order iv

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/batch-amend.html b/api-explorer/v5/trade/batch-amend.html index 9deb4c5dd4..f8fd269015 100644 --- a/api-explorer/v5/trade/batch-amend.html +++ b/api-explorer/v5/trade/batch-amend.html @@ -4,13 +4,13 @@ Batch Amend Order | Bybit API Documentation - +
    Skip to main content

    Batch Amend Order

    Batch amend orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • orderIv string

      Modify option order iv

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/batch-cancel.html b/api-explorer/v5/trade/batch-cancel.html index 39ffabb416..b85f30403f 100644 --- a/api-explorer/v5/trade/batch-cancel.html +++ b/api-explorer/v5/trade/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +
    Skip to main content

    Batch Cancel Order

    Batch cancel orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/batch-place.html b/api-explorer/v5/trade/batch-place.html index ba26f33df9..b57d420f37 100644 --- a/api-explorer/v5/trade/batch-place.html +++ b/api-explorer/v5/trade/batch-place.html @@ -4,13 +4,13 @@ Batch Place Order | Bybit API Documentation - +
    Skip to main content

    Batch Place Order

    Batch place orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type. option ONLY

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required
    • price string
    • orderIv string
    • timeInForce string

      Possible values: [GTC, IOC, FOK, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0]

      Position mode. one-way mode only for unified.

    • orderLinkId string required

      REQUIRED param when place an option order

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • mmp boolean

      Possible values: [true, false]

      enable market marker protection

    • smpType string

      Possible values: [None, CancelMaker, CancelTaker, CancelBoth]

      Smp execution type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/cancel-all.html b/api-explorer/v5/trade/cancel-all.html index 65052984ae..f01018502d 100644 --- a/api-explorer/v5/trade/cancel-all.html +++ b/api-explorer/v5/trade/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Orders | Bybit API Documentation - +
    Skip to main content

    Cancel All Orders

    Cancel all orders.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name. Required if not passing baseCoin or settleCoin

    • baseCoin string

      Cancel by base coin. Required if not passing symbol or settleCoin

    • settleCoin string

      Cancel by settle coin. Does not support spot. Required if not passing symbol or baseCoin

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/cancel-order.html b/api-explorer/v5/trade/cancel-order.html index 8108358e2e..98949fdc43 100644 --- a/api-explorer/v5/trade/cancel-order.html +++ b/api-explorer/v5/trade/cancel-order.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +
    Skip to main content

    Cancel Order

    Cancel a single order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, tpslOrder]

      Default value: Order

      Take profit stop loss or ordinary order. Only valid for spot.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/create-order.html b/api-explorer/v5/trade/create-order.html index 093fb6bc07..515733f9c8 100644 --- a/api-explorer/v5/trade/create-order.html +++ b/api-explorer/v5/trade/create-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +
    Skip to main content

    Place Order

    Place an order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name

    • isLeverage integer

      Possible values: [0, 1]

      Whether to loan, only for spot. 0:No;1:Yes.

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required

      Order qty

    • price string

      ignore it if Market order

    • triggerPrice string

      param for StopOrder

    • triggerDirection integer

      param for StopOrder. 1=rise, 2=fall

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      param for StopOrder

    • orderFilter string

      Possible values: [Order, tpslOrder]

      Default value: Order

      Take profit stop loss or ordinary order. Only valid for spot.

    • orderIv string

      Implied volatility. param for option order

    • timeInForce string

      Possible values: [GTC, IOC, FOK, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0, 1, 2]

      0=one-way mode, 1=buy-hedge-mode, 2=sell-hedge-mode

    • orderLinkId string

      required param for option order

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger stop loss price price type

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger boolean

      Possible values: [true, false]

      close on trigger

    • smpType string

      Possible values: [None, CancelMaker, CancelTaker, CancelBoth]

      Smp execution type

    • mmp boolean

      Possible values: [true, false]

      market marker protection. for option order

    • tpslMode string

      Possible values: [Full, Partial]

      TP/SL mode

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    • tpOrderType string

      Possible values: [Market, Limit]

      The order type when take profit is triggered

    • slOrderType string

      Possible values: [Market, Limit]

      The order type when stop loss is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/open-order.html b/api-explorer/v5/trade/open-order.html index cbe7fbacf6..3bda968921 100644 --- a/api-explorer/v5/trade/open-order.html +++ b/api-explorer/v5/trade/open-order.html @@ -4,13 +4,13 @@ Get Open Orders (real-time) | Bybit API Documentation - +
    Skip to main content

    Get Open Orders (real-time)

    Get unfilled orders or partially filled orders

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin. For option only

    • settleCoin string

      Settle coin. Spot is not available

    • orderId string
    • orderLinkId string

      User customised order id

    • orderFilter string

      Possible values: [Order, StopOrder, tpslOrder]

      Order filter. Default:all kinds of orders

    • openOnly integer

      Possible values: [0, 1, 2]

      Whether to only query active orders, if openOnly = 0, only get active orders. If it is 1, return only the order data of the final status (cancelled/rejected/completely filled, etc.) in the last 10 minutes

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/order-list.html b/api-explorer/v5/trade/order-list.html index 9c4e5b0627..c4ab91e15e 100644 --- a/api-explorer/v5/trade/order-list.html +++ b/api-explorer/v5/trade/order-list.html @@ -4,13 +4,13 @@ Get Order History (2 years) | Bybit API Documentation - +
    Skip to main content

    Get Order History (2 years)

    Get order history.

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • orderStatus string

      Possible values: [Created, New, Rejected, PartiallyFilled, PartillyFilledCancelled, Filled, PendingCancel, Cancelled, Untriggered, Triggered, Deactivated, Active]

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder, tpslOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/query-spot-quota.html b/api-explorer/v5/trade/query-spot-quota.html index 30d55382ae..cc1bd0f6a1 100644 --- a/api-explorer/v5/trade/query-spot-quota.html +++ b/api-explorer/v5/trade/query-spot-quota.html @@ -4,13 +4,13 @@ Get Borrow Quota (Spot) | Bybit API Documentation - +
    Skip to main content

    Get Borrow Quota (Spot)

    Query user's spot available quota

    Query Parameters
    • category string required

      Possible values: [spot]

      Product type

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

      Buy or Sell

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/trade/trade.html b/api-explorer/v5/trade/trade.html index dfeacf0e09..199e209b59 100644 --- a/api-explorer/v5/trade/trade.html +++ b/api-explorer/v5/trade/trade.html @@ -4,13 +4,13 @@ Trade | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/api-explorer/v5/user/apikey-info.html b/api-explorer/v5/user/apikey-info.html index 59acfcec94..7e3e479dd3 100644 --- a/api-explorer/v5/user/apikey-info.html +++ b/api-explorer/v5/user/apikey-info.html @@ -4,13 +4,13 @@ Get API Key Information | Bybit API Documentation - +
    Skip to main content

    Get API Key Information

    Get API Key Information

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/api-explorer/v5/user/user.html b/api-explorer/v5/user/user.html index 7017f5a944..c1ee84e8f7 100644 --- a/api-explorer/v5/user/user.html +++ b/api-explorer/v5/user/user.html @@ -4,13 +4,13 @@ User | Bybit API Documentation - +
    Skip to main content
    - + \ No newline at end of file diff --git a/assets/js/47f09a6b.bef3f80c.js b/assets/js/47f09a6b.7788896d.js similarity index 52% rename from assets/js/47f09a6b.bef3f80c.js rename to assets/js/47f09a6b.7788896d.js index d98b64bfd4..25f5fc1191 100644 --- a/assets/js/47f09a6b.bef3f80c.js +++ b/assets/js/47f09a6b.7788896d.js @@ -1 +1 @@ -"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[47137],{3905:(e,t,n)=>{n.d(t,{Zo:()=>s,kt:()=>c});var r=n(67294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var p=r.createContext({}),d=function(e){var t=r.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},s=function(e){var t=d(e.components);return r.createElement(p.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,i=e.originalType,p=e.parentName,s=l(e,["components","mdxType","originalType","parentName"]),m=d(n),c=a,b=m["".concat(p,".").concat(c)]||m[c]||u[c]||i;return n?r.createElement(b,o(o({ref:t},s),{},{components:n})):r.createElement(b,o({ref:t},s))}));function c(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var i=n.length,o=new Array(i);o[0]=m;var l={};for(var p in t)hasOwnProperty.call(t,p)&&(l[p]=t[p]);l.originalType=e,l.mdxType="string"==typeof e?e:a,o[1]=l;for(var d=2;d{n.r(t),n.d(t,{assets:()=>p,contentTitle:()=>o,default:()=>u,frontMatter:()=>i,metadata:()=>l,toc:()=>d});var r=n(87462),a=(n(67294),n(3905));const i={title:"Bind Or Unbind UID",sidebar_label:"Bind Or Unbind UID",sidebar_position:7},o=void 0,l={unversionedId:"v5/otc/bind-uid",id:"v5/otc/bind-uid",title:"Bind Or Unbind UID",description:"For the OTC loan product, you can bind new UID to risk unit or unbind UID out from risk unit.",source:"@site/docs/v5/otc/bind-uid.mdx",sourceDirName:"v5/otc",slug:"/v5/otc/bind-uid",permalink:"/docs/v5/otc/bind-uid",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"Bind Or Unbind UID",sidebar_label:"Bind Or Unbind UID",sidebar_position:7},sidebar:"v5SideBar",previous:{title:"Get LTV",permalink:"/docs/v5/otc/ltv-convert"},next:{title:"Get Lending Coin Info",permalink:"/docs/v5/c2c-lend/coin-info"}},p={},d=[{value:"HTTP Request",id:"http-request",level:3},{value:"Request Parameters",id:"request-parameters",level:3},{value:"Response Parameters",id:"response-parameters",level:3},{value:"Request Example",id:"request-example",level:3},{value:"Response Example",id:"response-example",level:3}],s={toc:d};function u(e){let{components:t,...n}=e;return(0,a.kt)("wrapper",(0,r.Z)({},s,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"For the OTC loan product, you can bind new UID to risk unit or unbind UID out from risk unit."),(0,a.kt)("admonition",{type:"info"},(0,a.kt)("ul",{parentName:"admonition"},(0,a.kt)("li",{parentName:"ul"},"Risk unit main UID cannot be unbound"),(0,a.kt)("li",{parentName:"ul"},"This endpoint can only be called by uids in the risk unit list"),(0,a.kt)("li",{parentName:"ul"},"The UID must be upgraded to UTA if you try to bind it."))),(0,a.kt)("h3",{id:"http-request"},"HTTP Request"),(0,a.kt)("p",null,"POST ",(0,a.kt)("inlineCode",{parentName:"p"},"/v5/ins-loan/association-uid")),(0,a.kt)("h3",{id:"request-parameters"},"Request Parameters"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"Parameter"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Required"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Type"),(0,a.kt)("th",{parentName:"tr",align:null},"Comments"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": bind, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": unbind")))),(0,a.kt)("h3",{id:"response-parameters"},"Response Parameters"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"Parameter"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Type"),(0,a.kt)("th",{parentName:"tr",align:null},"Comments"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": bind, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": unbind")))),(0,a.kt)("h3",{id:"request-example"},"Request Example"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-http"},'POST /v5/ins-loan/association-uid HTTP/1.1\nHost: api-testnet.bybit.com\nX-BAPI-API-KEY: XXXXX\nX-BAPI-TIMESTAMP: 1699257853101\nX-BAPI-RECV-WINDOW: 5000\nX-BAPI-SIGN: XXXXX\nContent-Type: application/json\nContent-Length: 43\n\n{\n "uid": "592324",\n "operate": "0"\n}\n')),(0,a.kt)("h3",{id:"response-example"},"Response Example"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-json"},'{\n "retCode": 0,\n "retMsg": "OK",\n "result": {\n "uid": "592324",\n "operate": "0"\n },\n "retExtInfo": {},\n "time": 1699257746135\n}\n')))}u.isMDXComponent=!0}}]); \ No newline at end of file +"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[47137],{3905:(e,t,n)=>{n.d(t,{Zo:()=>s,kt:()=>c});var r=n(67294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var p=r.createContext({}),d=function(e){var t=r.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},s=function(e){var t=d(e.components);return r.createElement(p.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,i=e.originalType,p=e.parentName,s=l(e,["components","mdxType","originalType","parentName"]),m=d(n),c=a,b=m["".concat(p,".").concat(c)]||m[c]||u[c]||i;return n?r.createElement(b,o(o({ref:t},s),{},{components:n})):r.createElement(b,o({ref:t},s))}));function c(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var i=n.length,o=new Array(i);o[0]=m;var l={};for(var p in t)hasOwnProperty.call(t,p)&&(l[p]=t[p]);l.originalType=e,l.mdxType="string"==typeof e?e:a,o[1]=l;for(var d=2;d{n.r(t),n.d(t,{assets:()=>p,contentTitle:()=>o,default:()=>u,frontMatter:()=>i,metadata:()=>l,toc:()=>d});var r=n(87462),a=(n(67294),n(3905));const i={title:"Bind Or Unbind UID",sidebar_label:"Bind Or Unbind UID",sidebar_position:7},o=void 0,l={unversionedId:"v5/otc/bind-uid",id:"v5/otc/bind-uid",title:"Bind Or Unbind UID",description:"For the INS loan product, you can bind new UID to risk unit or unbind UID out from risk unit.",source:"@site/docs/v5/otc/bind-uid.mdx",sourceDirName:"v5/otc",slug:"/v5/otc/bind-uid",permalink:"/docs/v5/otc/bind-uid",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"Bind Or Unbind UID",sidebar_label:"Bind Or Unbind UID",sidebar_position:7},sidebar:"v5SideBar",previous:{title:"Get LTV",permalink:"/docs/v5/otc/ltv-convert"},next:{title:"Get Lending Coin Info",permalink:"/docs/v5/c2c-lend/coin-info"}},p={},d=[{value:"HTTP Request",id:"http-request",level:3},{value:"Request Parameters",id:"request-parameters",level:3},{value:"Response Parameters",id:"response-parameters",level:3},{value:"Request Example",id:"request-example",level:3},{value:"Response Example",id:"response-example",level:3}],s={toc:d};function u(e){let{components:t,...n}=e;return(0,a.kt)("wrapper",(0,r.Z)({},s,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"For the INS loan product, you can bind new UID to risk unit or unbind UID out from risk unit."),(0,a.kt)("admonition",{type:"info"},(0,a.kt)("ul",{parentName:"admonition"},(0,a.kt)("li",{parentName:"ul"},"Risk unit designated UID cannot be unbound"),(0,a.kt)("li",{parentName:"ul"},"This endpoint can only be called by uids in the risk unit list"),(0,a.kt)("li",{parentName:"ul"},"The UID must be upgraded to UTA Pro if you try to bind it."))),(0,a.kt)("h3",{id:"http-request"},"HTTP Request"),(0,a.kt)("p",null,"POST ",(0,a.kt)("inlineCode",{parentName:"p"},"/v5/ins-loan/association-uid")),(0,a.kt)("h3",{id:"request-parameters"},"Request Parameters"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"Parameter"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Required"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Type"),(0,a.kt)("th",{parentName:"tr",align:null},"Comments"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": bind, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": unbind")))),(0,a.kt)("h3",{id:"response-parameters"},"Response Parameters"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"Parameter"),(0,a.kt)("th",{parentName:"tr",align:"left"},"Type"),(0,a.kt)("th",{parentName:"tr",align:null},"Comments"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": bind, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": unbind")))),(0,a.kt)("h3",{id:"request-example"},"Request Example"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-http"},'POST /v5/ins-loan/association-uid HTTP/1.1\nHost: api-testnet.bybit.com\nX-BAPI-API-KEY: XXXXX\nX-BAPI-TIMESTAMP: 1699257853101\nX-BAPI-RECV-WINDOW: 5000\nX-BAPI-SIGN: XXXXX\nContent-Type: application/json\nContent-Length: 43\n\n{\n "uid": "592324",\n "operate": "0"\n}\n')),(0,a.kt)("h3",{id:"response-example"},"Response Example"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-json"},'{\n "retCode": 0,\n "retMsg": "OK",\n "result": {\n "uid": "592324",\n "operate": "0"\n },\n "retExtInfo": {},\n "time": 1699257746135\n}\n')))}u.isMDXComponent=!0}}]); \ No newline at end of file diff --git a/assets/js/935f2afb.09a35993.js b/assets/js/935f2afb.f69e0d20.js similarity index 99% rename from assets/js/935f2afb.09a35993.js rename to assets/js/935f2afb.f69e0d20.js index 97d6984132..0c35eb5a6e 100644 --- a/assets/js/935f2afb.09a35993.js +++ b/assets/js/935f2afb.f69e0d20.js @@ -1 +1 @@ -"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[80053],{1109:e=>{e.exports=JSON.parse('{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"noIndex":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"v3SideBar":[{"type":"link","label":"Introduction","href":"/docs/v3/intro","docId":"v3/intro"},{"type":"link","label":"Bybit Server Time","href":"/docs/v3/server-time","docId":"v3/server-time"},{"type":"link","label":"Self Match Prevention","href":"/docs/v3/smp","docId":"v3/smp"},{"type":"category","label":"Derivatives","items":[{"type":"category","label":"REST API","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Kline","href":"/docs/derivatives/public/kline","docId":"v3/derivatives/rest-public/kline"},{"type":"link","label":"Mark Price Kline","href":"/docs/derivatives/public/mark-kline","docId":"v3/derivatives/rest-public/mark-kline"},{"type":"link","label":"Index Price Kline","href":"/docs/derivatives/public/index-kline","docId":"v3/derivatives/rest-public/index-kline"},{"type":"link","label":"Premium Index Price Kline","href":"/docs/derivatives/public/premium-index-kline","docId":"v3/derivatives/rest-public/premium-index-kline"},{"type":"link","label":"Order Book","href":"/docs/derivatives/public/orderbook","docId":"v3/derivatives/rest-public/orderbook"},{"type":"link","label":"Ticker Info","href":"/docs/derivatives/public/ticker","docId":"v3/derivatives/rest-public/ticker-info"},{"type":"link","label":"Instrument Info","href":"/docs/derivatives/public/instrument-info","docId":"v3/derivatives/rest-public/instrument-info"},{"type":"link","label":"Public Trading History","href":"/docs/derivatives/public/trade","docId":"v3/derivatives/rest-public/public-trade"},{"type":"link","label":"Risk Limit","href":"/docs/derivatives/public/risk-limit","docId":"v3/derivatives/rest-public/risk-limit"},{"type":"link","label":"Funding Rate History","href":"/docs/derivatives/public/funding-rate","docId":"v3/derivatives/rest-public/fund-rate-history"},{"type":"link","label":"Open Interest","href":"/docs/derivatives/public/open-interest","docId":"v3/derivatives/rest-public/open-interest"},{"type":"link","label":"Option Delivery Price","href":"/docs/derivatives/public/option-delivery","docId":"v3/derivatives/rest-public/delivery-price"},{"type":"link","label":"Get Long Short Ratio","href":"/docs/derivatives/public/long-short-ratio","docId":"v3/derivatives/rest-public/long-short-ratio"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contract","items":[{"type":"category","label":"Order","items":[{"type":"link","label":"Place Order","href":"/docs/derivatives/contract/place-order","docId":"v3/derivatives/rest-contract/order/place-order"},{"type":"link","label":"Get Open Orders","href":"/docs/derivatives/contract/open-order","docId":"v3/derivatives/rest-contract/order/open-order"},{"type":"link","label":"Replace Order","href":"/docs/derivatives/contract/replace-order","docId":"v3/derivatives/rest-contract/order/replace-order"},{"type":"link","label":"Cancel Order","href":"/docs/derivatives/contract/cancel","docId":"v3/derivatives/rest-contract/order/cancel-order"},{"type":"link","label":"Cancel All Order","href":"/docs/derivatives/contract/cancel-all","docId":"v3/derivatives/rest-contract/order/cancel-all"},{"type":"link","label":"Get Order List","href":"/docs/derivatives/contract/order-list","docId":"v3/derivatives/rest-contract/order/order-list"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Position","items":[{"type":"link","label":"My Position","href":"/docs/derivatives/contract/position-list","docId":"v3/derivatives/rest-contract/position/position-info"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/derivatives/contract/auto-margin","docId":"v3/derivatives/rest-contract/position/auto-margin"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/derivatives/contract/cross-isolated","docId":"v3/derivatives/rest-contract/position/cross-isolated-margin"},{"type":"link","label":"Switch Position Mode","href":"/docs/derivatives/contract/position-mode","docId":"v3/derivatives/rest-contract/position/position-mode"},{"type":"link","label":"Switch TP/SL Mode","href":"/docs/derivatives/contract/tpsl-mode","docId":"v3/derivatives/rest-contract/position/tpsl-mode"},{"type":"link","label":"Set Leverage","href":"/docs/derivatives/contract/leverage","docId":"v3/derivatives/rest-contract/position/leverage"},{"type":"link","label":"Set Trading Stop","href":"/docs/derivatives/contract/trading-stop","docId":"v3/derivatives/rest-contract/position/trading-stop"},{"type":"link","label":"Set Risk Limit","href":"/docs/derivatives/contract/set-risk-limit","docId":"v3/derivatives/rest-contract/position/set-risk-limit"},{"type":"link","label":"Get Execution List","href":"/docs/derivatives/contract/execution-list","docId":"v3/derivatives/rest-contract/position/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/derivatives/contract/closepnl","docId":"v3/derivatives/rest-contract/position/close-pnl"},{"type":"link","label":"Confirm New Risk Limit","href":"/docs/derivatives/contract/confirm-mmr","docId":"v3/derivatives/rest-contract/position/confirm-mmr"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Account","items":[{"type":"link","label":"Wallet Balance","href":"/docs/derivatives/contract/wallet","docId":"v3/derivatives/rest-contract/account/wallet-balance"},{"type":"link","label":"Get Trading Fee Rate","href":"/docs/derivatives/contract/fee-rate","docId":"v3/derivatives/rest-contract/account/trading-fee"},{"type":"link","label":"Get Wallet Fund Records","href":"/docs/derivatives/contract/wallet-fund","docId":"v3/derivatives/rest-contract/account/wallet-fund-record"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/derivatives/ws/connect","docId":"v3/derivatives/wss-authentication"},{"type":"category","label":"Public Channel","items":[{"type":"link","label":"Orderbook","href":"/docs/derivatives/ws-public/orderbook","docId":"v3/derivatives/wss-public/orderbook"},{"type":"link","label":"Public Trade","href":"/docs/derivatives/ws-public/trade","docId":"v3/derivatives/wss-public/trade"},{"type":"link","label":"Tickers","href":"/docs/derivatives/ws-public/ticker","docId":"v3/derivatives/wss-public/tickers"},{"type":"link","label":"Kline","href":"/docs/derivatives/ws-public/kline","docId":"v3/derivatives/wss-public/kline"},{"type":"link","label":"Liquidation","href":"/docs/derivatives/ws-public/liquidation","docId":"v3/derivatives/wss-public/liquidation"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private Channel (contract)","items":[{"type":"link","label":"Position","href":"/docs/derivatives/ws-contract/position","docId":"v3/derivatives/wss-contract/position"},{"type":"link","label":"Execution","href":"/docs/derivatives/ws-contract/execution","docId":"v3/derivatives/wss-contract/execution"},{"type":"link","label":"Order","href":"/docs/derivatives/ws-contract/order","docId":"v3/derivatives/wss-contract/order"},{"type":"link","label":"Wallet","href":"/docs/derivatives/ws-contract/wallet","docId":"v3/derivatives/wss-contract/wallet"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/derivatives/rate-limit","docId":"v3/derivatives/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/derivatives/enum","docId":"v3/derivatives/enum"},{"type":"link","label":"Error Code","href":"/docs/derivatives/error","docId":"v3/derivatives/error"}],"collapsed":true,"collapsible":true,"href":"/docs/category/derivatives"},{"type":"category","label":"Spot","items":[{"type":"category","label":"REST API","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Instrument Info","href":"/docs/spot/public/instrument","docId":"v3/spot/rest-public/instrument-info"},{"type":"link","label":"Order Book","href":"/docs/spot/public/depth","docId":"v3/spot/rest-public/orderbook"},{"type":"link","label":"Merged Order Book","href":"/docs/spot/public/merge-depth","docId":"v3/spot/rest-public/merge-orderbook"},{"type":"link","label":"Kline","href":"/docs/spot/public/kline","docId":"v3/spot/rest-public/kline"},{"type":"link","label":"Public Trading Records","href":"/docs/spot/public/recent-trade","docId":"v3/spot/rest-public/public-trade"},{"type":"link","label":"Best Bid/Ask Price","href":"/docs/spot/public/bid-ask","docId":"v3/spot/rest-public/best-bid-ask"},{"type":"link","label":"Last Traded Price","href":"/docs/spot/public/last-price","docId":"v3/spot/rest-public/last-trade-price"},{"type":"link","label":"Tickers","href":"/docs/spot/public/tickers","docId":"v3/spot/rest-public/ticker-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/spot/trade/place-order","docId":"v3/spot/rest-spot/place-order"},{"type":"link","label":"Get Order","href":"/docs/spot/trade/get-order","docId":"v3/spot/rest-spot/get-order"},{"type":"link","label":"Cancel Order","href":"/docs/spot/trade/cancel","docId":"v3/spot/rest-spot/cancel-order"},{"type":"link","label":"Open Orders","href":"/docs/spot/trade/open-order","docId":"v3/spot/rest-spot/open-order"},{"type":"link","label":"Batch Cancel Order","href":"/docs/spot/trade/batch-cancel","docId":"v3/spot/rest-spot/batch-cancel"},{"type":"link","label":"Batch Cancel Order By Id","href":"/docs/spot/trade/cancel-by-id","docId":"v3/spot/rest-spot/batch-cancel-by-id"},{"type":"link","label":"Order History","href":"/docs/spot/trade/order-history","docId":"v3/spot/rest-spot/order-history"},{"type":"link","label":"Trade History","href":"/docs/spot/trade/my-trades","docId":"v3/spot/rest-spot/trade-history"}],"collapsed":true,"collapsible":true},{"type":"link","label":"Get Wallet Balance","href":"/docs/spot/wallet","docId":"v3/spot/wallet"},{"type":"category","label":"Leveraged Token","items":[{"type":"link","label":"All Asset Info","href":"/docs/spot/etp/asset-info","docId":"v3/spot/rest-etp/asset-info"},{"type":"link","label":"Market Info","href":"/docs/spot/etp/market-info","docId":"v3/spot/rest-etp/market-info"},{"type":"link","label":"Purchase & Redeem History","href":"/docs/spot/etp/order-history","docId":"v3/spot/rest-etp/purchase-redeem-history"},{"type":"link","label":"Purchase","href":"/docs/spot/etp/purchase","docId":"v3/spot/rest-etp/purchase"},{"type":"link","label":"Redeem","href":"/docs/spot/etp/redeem","docId":"v3/spot/rest-etp/redeem"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Cross Margin Trade","items":[{"type":"link","label":"Get Loan Account Info","href":"/docs/spot/margin/account","docId":"v3/spot/rest-spot-margin/account-info"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/spot/margin/borrow-history","docId":"v3/spot/rest-spot-margin/borrow-info"},{"type":"link","label":"Borrow","href":"/docs/spot/margin/borrow","docId":"v3/spot/rest-spot-margin/borrow"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/spot/margin/borrowable-coin","docId":"v3/spot/rest-spot-margin/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/spot/margin/interest","docId":"v3/spot/rest-spot-margin/interest-quota"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/spot/margin/margin-data","docId":"v3/spot/rest-spot-margin/margin-data"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/spot/margin/repay-history","docId":"v3/spot/rest-spot-margin/repay-history"},{"type":"link","label":"Repay","href":"/docs/spot/margin/repay","docId":"v3/spot/rest-spot-margin/repay"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/spot/margin/toggle","docId":"v3/spot/rest-spot-margin/switch-mode"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Institution Loan","items":[{"type":"link","label":"Get Margin Product Info","href":"/docs/spot/otc/product-info","docId":"v3/spot/rest-institution-loan/margin-product-info"},{"type":"link","label":"Margin Coin Info","href":"/docs/spot/otc/coin-info","docId":"v3/spot/rest-institution-loan/margin-coin-info"},{"type":"link","label":"Get Loan Info","href":"/docs/spot/otc/loan-info","docId":"v3/spot/rest-institution-loan/loan-info"},{"type":"link","label":"Get Repay Info","href":"/docs/spot/otc/repay-info","docId":"v3/spot/rest-institution-loan/repay-info"},{"type":"link","label":"Get LTV","href":"/docs/spot/otc/ltv","docId":"v3/spot/rest-institution-loan/ltv"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/spot/ws/connect","docId":"v3/spot/wss-authentication"},{"type":"category","label":"Public Channel","items":[{"type":"link","label":"Orderbook","href":"/docs/spot/ws-public/orderbook","docId":"v3/spot/wss-public/orderbook"},{"type":"link","label":"Kline","href":"/docs/spot/ws-public/kline","docId":"v3/spot/wss-public/kline"},{"type":"link","label":"Tickers","href":"/docs/spot/ws-public/ticker","docId":"v3/spot/wss-public/tickers"},{"type":"link","label":"Bookticker","href":"/docs/spot/ws-public/bookticker","docId":"v3/spot/wss-public/bookticker"},{"type":"link","label":"Public trade","href":"/docs/spot/ws-public/public-trade","docId":"v3/spot/wss-public/trade"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private Channel","items":[{"type":"link","label":"Order","href":"/docs/spot/ws-private/order","docId":"v3/spot/wss-private/order"},{"type":"link","label":"Stop Order","href":"/docs/spot/ws-private/stop-order","docId":"v3/spot/wss-private/stop-order"},{"type":"link","label":"Execution","href":"/docs/spot/ws-private/execution","docId":"v3/spot/wss-private/ticket-info"},{"type":"link","label":"Wallet","href":"/docs/spot/ws-private/wallet","docId":"v3/spot/wss-private/outbound-account-info"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/spot/rate-limit","docId":"v3/spot/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/spot/enum","docId":"v3/spot/enum"},{"type":"link","label":"Error Code","href":"/docs/spot/error","docId":"v3/spot/error"}],"collapsed":true,"collapsible":true,"href":"/docs/category/spot"},{"type":"category","label":"Account Asset","collapsed":true,"items":[{"type":"category","label":"Transfer Endpoint","collapsed":true,"items":[{"type":"link","label":"Create Internal Transfer","href":"/docs/account-asset/internal-transfer","docId":"v3/account-asset/transfer/internal-transfer"},{"type":"link","label":"Get Internal Transfer List","href":"/docs/account-asset/internal-transfer-list","docId":"v3/account-asset/transfer/internal-transfer-list"},{"type":"link","label":"Create Subaccount Transfer","href":"/docs/account-asset/sub-transfer","docId":"v3/account-asset/transfer/subacct-transfer"},{"type":"link","label":"Get Master-Sub Transfer List","href":"/docs/account-asset/sub-transfer-list","docId":"v3/account-asset/transfer/subacct-transfer-list"},{"type":"link","label":"Get Subaccount UID List","href":"/docs/account-asset/sub-uid-list","docId":"v3/account-asset/transfer/subacct-list"},{"type":"link","label":"Enable Universal Transfer (Depreciated)","href":"/docs/account-asset/enable-unitransfer","docId":"v3/account-asset/transfer/enable-uni-transfer"},{"type":"link","label":"Create Universal Transfer","href":"/docs/account-asset/uni-transfer","docId":"v3/account-asset/transfer/uni-transfer"},{"type":"link","label":"Get Universal Transfer List","href":"/docs/account-asset/uni-transfer-list","docId":"v3/account-asset/transfer/uni-transfer-list"},{"type":"link","label":"Get Transferable Coin List","href":"/docs/account-asset/transferable-coin-list","docId":"v3/account-asset/transfer/transferable-coin-list"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/account-asset/coin-balance","docId":"v3/account-asset/transfer/coin-balance"},{"type":"link","label":"Get All Coins Balance","href":"/docs/account-asset/all-balance","docId":"v3/account-asset/transfer/all-balance"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/account-asset/asset-info","docId":"v3/account-asset/transfer/asset-info"}],"collapsible":true},{"type":"category","label":"Withdraw and Deposit endpoint","collapsed":true,"items":[{"type":"link","label":"Get Deposit Spec","href":"/docs/account-asset/deposit-spec","docId":"v3/account-asset/withdraw-deposit/deposit-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/account-asset/set-deposit-acct","docId":"v3/account-asset/withdraw-deposit/set-deposit-acct"},{"type":"link","label":"Get Deposit Records (on chain)","href":"/docs/account-asset/deposit-record","docId":"v3/account-asset/withdraw-deposit/master-deposit-record"},{"type":"link","label":"Get Sub Deposit Records (on chain)","href":"/docs/account-asset/sub-deposit-record","docId":"v3/account-asset/withdraw-deposit/sub-deposit-record"},{"type":"link","label":"Get Bybit Internal Deposit Records (across Bybit)","href":"/docs/account-asset/internal-deposit-record","docId":"v3/account-asset/withdraw-deposit/internal-deposit-record"},{"type":"link","label":"Get Withdraw Records","href":"/docs/account-asset/withdraw-record","docId":"v3/account-asset/withdraw-deposit/withdraw-record"},{"type":"link","label":"Get Coin Information","href":"/docs/account-asset/coin-info","docId":"v3/account-asset/withdraw-deposit/coin-info"},{"type":"link","label":"Get Delay Withdraw Amount","href":"/docs/account-asset/delay-amount","docId":"v3/account-asset/withdraw-deposit/deplay-amount"},{"type":"link","label":"Withdraw","href":"/docs/account-asset/withdraw","docId":"v3/account-asset/withdraw-deposit/withdraw"},{"type":"link","label":"Cancel withdrawal","href":"/docs/account-asset/cancel-withdraw","docId":"v3/account-asset/withdraw-deposit/cancel-withdraw"},{"type":"link","label":"Get Master Acct Deposit Address Info","href":"/docs/account-asset/master-deposit-addr","docId":"v3/account-asset/withdraw-deposit/master-deposit-addr"},{"type":"link","label":"Get Sub Acct Deposit Address Info","href":"/docs/account-asset/sub-deposit-addr","docId":"v3/account-asset/withdraw-deposit/sub-deposit-addr"}],"collapsible":true},{"type":"category","label":"Master-Sub User Endpoint","collapsed":true,"items":[{"type":"link","label":"Create Sub UID","href":"/docs/account-asset/create-subuid","docId":"v3/account-asset/user/create-subuid"},{"type":"link","label":"Create Sub UID API Key","href":"/docs/account-asset/create-subuid-apikey","docId":"v3/account-asset/user/create-subuid-apikey"},{"type":"link","label":"Get Sub UID List","href":"/docs/account-asset/subuid-list","docId":"v3/account-asset/user/subuid-list"},{"type":"link","label":"Froze Sub UID","href":"/docs/account-asset/froze-subuid","docId":"v3/account-asset/user/froze-subuid"},{"type":"link","label":"Get API Key Information","href":"/docs/account-asset/apikey-info","docId":"v3/account-asset/user/apikey-info"},{"type":"link","label":"Get UID Wallet Type","href":"/docs/account-asset/wallet-type","docId":"v3/account-asset/user/wallet-type"},{"type":"link","label":"Modify Master API Key","href":"/docs/account-asset/modify-master-apikey","docId":"v3/account-asset/user/modify-master-apikey"},{"type":"link","label":"Modify Sub API Key","href":"/docs/account-asset/modify-sub-apikey","docId":"v3/account-asset/user/modify-sub-apikey"},{"type":"link","label":"Delete Master API Key","href":"/docs/account-asset/rm-master-apikey","docId":"v3/account-asset/user/rm-master-apikey"},{"type":"link","label":"Delete Sub API Key","href":"/docs/account-asset/rm-sub-apikey","docId":"v3/account-asset/user/rm-sub-apikey"}],"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/account-asset/rate-limit","docId":"v3/account-asset/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/account-asset/enum","docId":"v3/account-asset/enum"},{"type":"link","label":"Error Code","href":"/docs/account-asset/error","docId":"v3/account-asset/error"}],"collapsible":true},{"type":"category","label":"Tax","items":[{"type":"link","label":"Get User Register Date","href":"/docs/tax/time","docId":"v3/tax/register-time"},{"type":"link","label":"Request Export Report","href":"/docs/tax/report","docId":"v3/tax/request-report"},{"type":"link","label":"Get Export Report Status","href":"/docs/tax/status","docId":"v3/tax/report-status"},{"type":"link","label":"Retrieve Data Export","href":"/docs/tax/data-export","docId":"v3/tax/data-export"},{"type":"link","label":"Data Explanation","href":"/docs/tax/explain","docId":"v3/tax/data-explain"},{"type":"link","label":"Enums Definitions","href":"/docs/tax/enum","docId":"v3/tax/enum"}],"collapsed":true,"collapsible":true}],"v5SideBar":[{"type":"link","label":"Introduction","href":"/docs/v5/intro","docId":"v5/intro"},{"type":"link","label":"Integration Guidance","href":"/docs/v5/guide","docId":"v5/guide"},{"type":"link","label":"Get Announcement","href":"/docs/v5/announcement","docId":"v5/announcement"},{"type":"link","label":"Self Match Prevention","href":"/docs/v5/smp","docId":"v5/smp"},{"type":"link","label":"How To Start Copy Trading","href":"/docs/v5/copytrade","docId":"v5/copytrade"},{"type":"category","label":"Market","items":[{"type":"link","label":"Get Bybit Server Time","href":"/docs/v5/market/time","docId":"v5/market/time"},{"type":"link","label":"Get Kline","href":"/docs/v5/market/kline","docId":"v5/market/kline"},{"type":"link","label":"Get Mark Price Kline","href":"/docs/v5/market/mark-kline","docId":"v5/market/mark-kline"},{"type":"link","label":"Get Index Price Kline","href":"/docs/v5/market/index-kline","docId":"v5/market/index-kline"},{"type":"link","label":"Get Premium Index Price Kline","href":"/docs/v5/market/preimum-index-kline","docId":"v5/market/preimum-index-kline"},{"type":"link","label":"Get Instruments Info","href":"/docs/v5/market/instrument","docId":"v5/market/instrument"},{"type":"link","label":"Get Orderbook","href":"/docs/v5/market/orderbook","docId":"v5/market/orderbook"},{"type":"link","label":"Get Tickers","href":"/docs/v5/market/tickers","docId":"v5/market/tickers"},{"type":"link","label":"Get Funding Rate History","href":"/docs/v5/market/history-fund-rate","docId":"v5/market/history-fund-rate"},{"type":"link","label":"Get Public Recent Trading History","href":"/docs/v5/market/recent-trade","docId":"v5/market/recent-trade"},{"type":"link","label":"Get Open Interest","href":"/docs/v5/market/open-interest","docId":"v5/market/open-interest"},{"type":"link","label":"Get Historical Volatility","href":"/docs/v5/market/iv","docId":"v5/market/iv"},{"type":"link","label":"Get Insurance","href":"/docs/v5/market/insurance","docId":"v5/market/insurance"},{"type":"link","label":"Get Risk Limit","href":"/docs/v5/market/risk-limit","docId":"v5/market/risk-limit"},{"type":"link","label":"Get Delivery Price","href":"/docs/v5/market/delivery-price","docId":"v5/market/delivery-price"},{"type":"link","label":"Get Long Short Ratio","href":"/docs/v5/market/long-short-ratio","docId":"v5/market/long-short-ratio"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/v5/order/create-order","docId":"v5/order/create-order"},{"type":"link","label":"Amend Order","href":"/docs/v5/order/amend-order","docId":"v5/order/amend-order"},{"type":"link","label":"Cancel Order","href":"/docs/v5/order/cancel-order","docId":"v5/order/cancel-order"},{"type":"link","label":"Get Open Orders (real-time)","href":"/docs/v5/order/open-order","docId":"v5/order/open-order"},{"type":"link","label":"Cancel All Orders","href":"/docs/v5/order/cancel-all","docId":"v5/order/cancel-all"},{"type":"link","label":"Get Order History (2 years)","href":"/docs/v5/order/order-list","docId":"v5/order/order-list"},{"type":"link","label":"Batch Place Order","href":"/docs/v5/order/batch-place","docId":"v5/order/batch-place"},{"type":"link","label":"Batch Amend Order","href":"/docs/v5/order/batch-amend","docId":"v5/order/batch-amend"},{"type":"link","label":"Batch Cancel Order","href":"/docs/v5/order/batch-cancel","docId":"v5/order/batch-cancel"},{"type":"link","label":"Get Borrow Quota (Spot)","href":"/docs/v5/order/spot-borrow-quota","docId":"v5/order/spot-borrow-quota"},{"type":"link","label":"Set DCP (Options)","href":"/docs/v5/order/dcp","docId":"v5/order/dcp"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Position","items":[{"type":"link","label":"Get Position Info","href":"/docs/v5/position/","docId":"v5/position/position"},{"type":"link","label":"Set Leverage","href":"/docs/v5/position/leverage","docId":"v5/position/leverage"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/v5/position/cross-isolate","docId":"v5/position/cross-isolate"},{"type":"link","label":"Set TP/SL Mode","href":"/docs/v5/position/tpsl-mode","docId":"v5/position/tpsl-mode"},{"type":"link","label":"Switch Position Mode","href":"/docs/v5/position/position-mode","docId":"v5/position/position-mode"},{"type":"link","label":"Set Risk Limit","href":"/docs/v5/position/set-risk-limit","docId":"v5/position/set-risk-limit"},{"type":"link","label":"Set Trading Stop","href":"/docs/v5/position/trading-stop","docId":"v5/position/trading-stop"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/v5/position/auto-add-margin","docId":"v5/position/auto-add-margin"},{"type":"link","label":"Add Or Reduce Margin","href":"/docs/v5/position/manual-add-margin","docId":"v5/position/manual-add-margin"},{"type":"link","label":"Get Execution (2 years)","href":"/docs/v5/position/execution","docId":"v5/position/execution"},{"type":"link","label":"Get Closed PnL (2 years)","href":"/docs/v5/position/close-pnl","docId":"v5/position/close-pnl"},{"type":"link","label":"Confirm New Risk Limit","href":"/docs/v5/position/confirm-mmr","docId":"v5/position/confirm-mmr"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Pre-upgrade","items":[{"type":"link","label":"Get Pre-upgrade Order History","href":"/docs/v5/pre-upgrade/order-list","docId":"v5/pre-upgrade/order-list"},{"type":"link","label":"Get Pre-upgrade Trade History","href":"/docs/v5/pre-upgrade/execution","docId":"v5/pre-upgrade/execution"},{"type":"link","label":"Get Pre-upgrade Closed PnL","href":"/docs/v5/pre-upgrade/close-pnl","docId":"v5/pre-upgrade/close-pnl"},{"type":"link","label":"Get Pre-upgrade Transaction Log","href":"/docs/v5/pre-upgrade/transaction-log","docId":"v5/pre-upgrade/transaction-log"},{"type":"link","label":"Get Pre-upgrade Option Delivery Record","href":"/docs/v5/pre-upgrade/delivery","docId":"v5/pre-upgrade/delivery"},{"type":"link","label":"Get Pre-upgrade USDC Session Settlement","href":"/docs/v5/pre-upgrade/settlement","docId":"v5/pre-upgrade/settlement"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Account","items":[{"type":"link","label":"Get Wallet Balance","href":"/docs/v5/account/wallet-balance","docId":"v5/account/wallet-balance"},{"type":"link","label":"Upgrade to Unified Account","href":"/docs/v5/account/upgrade-unified-account","docId":"v5/account/upgrade-unified-account"},{"type":"link","label":"Get Borrow History","href":"/docs/v5/account/borrow-history","docId":"v5/account/borrow-history"},{"type":"link","label":"Set Collateral Coin","href":"/docs/v5/account/set-collateral","docId":"v5/account/set-collateral"},{"type":"link","label":"Get Collateral Info","href":"/docs/v5/account/collateral-info","docId":"v5/account/collateral-info"},{"type":"link","label":"Get Coin Greeks","href":"/docs/v5/account/coin-greeks","docId":"v5/account/coin-greeks"},{"type":"link","label":"Get Fee Rate","href":"/docs/v5/account/fee-rate","docId":"v5/account/fee-rate"},{"type":"link","label":"Get Account Info","href":"/docs/v5/account/account-info","docId":"v5/account/account-info"},{"type":"link","label":"Get Transaction Log","href":"/docs/v5/account/transaction-log","docId":"v5/account/transaction-log"},{"type":"link","label":"Set Margin Mode","href":"/docs/v5/account/set-margin-mode","docId":"v5/account/set-margin-mode"},{"type":"link","label":"Set MMP","href":"/docs/v5/account/set-mmp","docId":"v5/account/set-mmp"},{"type":"link","label":"Reset MMP","href":"/docs/v5/account/reset-mmp","docId":"v5/account/reset-mmp"},{"type":"link","label":"Get MMP State","href":"/docs/v5/account/get-mmp-state","docId":"v5/account/get-mmp-state"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Asset","items":[{"type":"link","label":"Get Coin Exchange Records","href":"/docs/v5/asset/exchange","docId":"v5/asset/exchange"},{"type":"link","label":"Get Delivery Record","href":"/docs/v5/asset/delivery","docId":"v5/asset/delivery"},{"type":"link","label":"Get USDC Session Settlement","href":"/docs/v5/asset/settlement","docId":"v5/asset/settlement"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/v5/asset/asset-info","docId":"v5/asset/asset-info"},{"type":"link","label":"Get All Coins Balance","href":"/docs/v5/asset/all-balance","docId":"v5/asset/all-balance"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/v5/asset/account-coin-balance","docId":"v5/asset/account-coin-balance"},{"type":"link","label":"Get Transferable Coin","href":"/docs/v5/asset/transferable-coin","docId":"v5/asset/transferable-coin"},{"type":"link","label":"Create Internal Transfer","href":"/docs/v5/asset/create-inter-transfer","docId":"v5/asset/create-inter-transfer"},{"type":"link","label":"Get Internal Transfer Records","href":"/docs/v5/asset/inter-transfer-list","docId":"v5/asset/inter-transfer-list"},{"type":"link","label":"Get Sub UID","href":"/docs/v5/asset/sub-uid-list","docId":"v5/asset/sub-uid-list"},{"type":"link","label":"Create Universal Transfer","href":"/docs/v5/asset/unitransfer","docId":"v5/asset/unitransfer"},{"type":"link","label":"Get Universal Transfer Records","href":"/docs/v5/asset/unitransfer-list","docId":"v5/asset/unitransfer-list"},{"type":"link","label":"Get Allowed Deposit Coin Info","href":"/docs/v5/asset/deposit-coin-spec","docId":"v5/asset/deposit-coin-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/v5/asset/set-deposit-acct","docId":"v5/asset/set-deposit-acct"},{"type":"link","label":"Get Deposit Records (on-chain)","href":"/docs/v5/asset/deposit-record","docId":"v5/asset/deposit-record"},{"type":"link","label":"Get Sub Deposit Records (on-chain)","href":"/docs/v5/asset/sub-deposit-record","docId":"v5/asset/sub-deposit-record"},{"type":"link","label":"Get Internal Deposit Records (off-chain)","href":"/docs/v5/asset/internal-deposit-record","docId":"v5/asset/internal-deposit-record"},{"type":"link","label":"Get Master Deposit Address","href":"/docs/v5/asset/master-deposit-addr","docId":"v5/asset/master-deposit-addr"},{"type":"link","label":"Get Sub Deposit Address","href":"/docs/v5/asset/sub-deposit-addr","docId":"v5/asset/sub-deposit-addr"},{"type":"link","label":"Get Coin Info","href":"/docs/v5/asset/coin-info","docId":"v5/asset/coin-info"},{"type":"link","label":"Get Withdrawal Records","href":"/docs/v5/asset/withdraw-record","docId":"v5/asset/withdraw-record"},{"type":"link","label":"Get Withdrawable Amount","href":"/docs/v5/asset/delay-amount","docId":"v5/asset/delay-amount"},{"type":"link","label":"Withdraw","href":"/docs/v5/asset/withdraw","docId":"v5/asset/withdraw"},{"type":"link","label":"Cancel Withdrawal","href":"/docs/v5/asset/cancel-withdraw","docId":"v5/asset/cancel-withdraw"}],"collapsed":true,"collapsible":true},{"type":"category","label":"User","items":[{"type":"link","label":"Create Sub UID","href":"/docs/v5/user/create-subuid","docId":"v5/user/create-subuid"},{"type":"link","label":"Create Sub UID API Key","href":"/docs/v5/user/create-subuid-apikey","docId":"v5/user/create-subuid-apikey"},{"type":"link","label":"Get Sub UID List","href":"/docs/v5/user/subuid-list","docId":"v5/user/subuid-list"},{"type":"link","label":"Freeze Sub UID","href":"/docs/v5/user/froze-subuid","docId":"v5/user/froze-subuid"},{"type":"link","label":"Get API Key Information","href":"/docs/v5/user/apikey-info","docId":"v5/user/apikey-info"},{"type":"link","label":"Get UID Wallet Type","href":"/docs/v5/user/wallet-type","docId":"v5/user/wallet-type"},{"type":"link","label":"Modify Master API Key","href":"/docs/v5/user/modify-master-apikey","docId":"v5/user/modify-master-apikey"},{"type":"link","label":"Modify Sub API Key","href":"/docs/v5/user/modify-sub-apikey","docId":"v5/user/modify-sub-apikey"},{"type":"link","label":"Delete Sub UID","href":"/docs/v5/user/rm-subuid","docId":"v5/user/rm-subuid"},{"type":"link","label":"Delete Master API Key","href":"/docs/v5/user/rm-master-apikey","docId":"v5/user/rm-master-apikey"},{"type":"link","label":"Delete Sub API Key","href":"/docs/v5/user/rm-sub-apikey","docId":"v5/user/rm-sub-apikey"},{"type":"link","label":"Get Affiliate User Info","href":"/docs/v5/user/affiliate-info","docId":"v5/user/affiliate-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"Get Leverage Token Info","href":"/docs/v5/lt/leverage-token-info","docId":"v5/lt/leverage-token-info"},{"type":"link","label":"Get Leveraged Token Market","href":"/docs/v5/lt/leverage-token-reference","docId":"v5/lt/leverage-token-reference"},{"type":"link","label":"Purchase","href":"/docs/v5/lt/purchase","docId":"v5/lt/purchase"},{"type":"link","label":"Redeem","href":"/docs/v5/lt/redeem","docId":"v5/lt/redeem"},{"type":"link","label":"Get Purchase/Redemption Records","href":"/docs/v5/lt/order-record","docId":"v5/lt/order-record"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Margin Trade (UTA)","items":[{"type":"link","label":"Get VIP Margin Data","href":"/docs/v5/spot-margin-uta/vip-margin","docId":"v5/spot-margin-uta/vip-margin"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/v5/spot-margin-uta/switch-mode","docId":"v5/spot-margin-uta/switch-mode"},{"type":"link","label":"Set Leverage","href":"/docs/v5/spot-margin-uta/set-leverage","docId":"v5/spot-margin-uta/set-leverage"},{"type":"link","label":"Get Status And Leverage","href":"/docs/v5/spot-margin-uta/status","docId":"v5/spot-margin-uta/status"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Margin Trade (Classic)","items":[{"type":"link","label":"Get VIP Margin Data","href":"/docs/v5/spot-margin-normal/vip-margin","docId":"v5/spot-margin-normal/vip-margin"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/spot-margin-normal/margin-data","docId":"v5/spot-margin-normal/margin-data"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/v5/spot-margin-normal/borrowable-data","docId":"v5/spot-margin-normal/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/v5/spot-margin-normal/interest-quota","docId":"v5/spot-margin-normal/interest-quota"},{"type":"link","label":"Get Loan Account Info","href":"/docs/v5/spot-margin-normal/account-info","docId":"v5/spot-margin-normal/account-info"},{"type":"link","label":"Borrow","href":"/docs/v5/spot-margin-normal/borrow","docId":"v5/spot-margin-normal/borrow"},{"type":"link","label":"Repay","href":"/docs/v5/spot-margin-normal/repay","docId":"v5/spot-margin-normal/repay"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/v5/spot-margin-normal/borrow-order","docId":"v5/spot-margin-normal/borrow-order"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/v5/spot-margin-normal/repay-order","docId":"v5/spot-margin-normal/repay-order"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/v5/spot-margin-normal/switch-mode","docId":"v5/spot-margin-normal/switch-mode"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Institutional Loan","items":[{"type":"link","label":"Get Product Info","href":"/docs/v5/otc/margin-product-info","docId":"v5/otc/margin-product-info"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/otc/margin-coin-convert-info","docId":"v5/otc/margin-coin-convert-info"},{"type":"link","label":"Get Loan Orders","href":"/docs/v5/otc/loan-info","docId":"v5/otc/loan-info"},{"type":"link","label":"Get Repay Orders","href":"/docs/v5/otc/repay-info","docId":"v5/otc/repay-info"},{"type":"link","label":"Get LTV","href":"/docs/v5/otc/ltv-convert","docId":"v5/otc/ltv-convert"},{"type":"link","label":"Bind Or Unbind UID","href":"/docs/v5/otc/bind-uid","docId":"v5/otc/bind-uid"}],"collapsed":true,"collapsible":true},{"type":"category","label":"C2C Lending","items":[{"type":"link","label":"Get Lending Coin Info","href":"/docs/v5/c2c-lend/coin-info","docId":"v5/c2c-lend/coin-info"},{"type":"link","label":"Deposit Funds","href":"/docs/v5/c2c-lend/deposit","docId":"v5/c2c-lend/deposit"},{"type":"link","label":"Redeem Funds","href":"/docs/v5/c2c-lend/redeem","docId":"v5/c2c-lend/redeem"},{"type":"link","label":"Cancel Redeem","href":"/docs/v5/c2c-lend/cancel-redeem","docId":"v5/c2c-lend/cancel-redeem"},{"type":"link","label":"Get Order Records","href":"/docs/v5/c2c-lend/order-record","docId":"v5/c2c-lend/order-record"},{"type":"link","label":"Get Lending Account Info","href":"/docs/v5/c2c-lend/account-info","docId":"v5/c2c-lend/account-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Broker","items":[{"type":"link","label":"Get Broker Earning","href":"/docs/v5/broker/earning","docId":"v5/broker/earning"}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/v5/ws/connect","docId":"v5/websocket/wss-authentication"},{"type":"category","label":"Public","items":[{"type":"link","label":"Orderbook","href":"/docs/v5/websocket/public/orderbook","docId":"v5/websocket/public/orderbook"},{"type":"link","label":"Trade","href":"/docs/v5/websocket/public/trade","docId":"v5/websocket/public/trade"},{"type":"link","label":"Ticker","href":"/docs/v5/websocket/public/ticker","docId":"v5/websocket/public/ticker"},{"type":"link","label":"Kline","href":"/docs/v5/websocket/public/kline","docId":"v5/websocket/public/kline"},{"type":"link","label":"Liquidation","href":"/docs/v5/websocket/public/liquidation","docId":"v5/websocket/public/liquidation"},{"type":"link","label":"LT Kline","href":"/docs/v5/websocket/public/etp-kline","docId":"v5/websocket/public/etp-kline"},{"type":"link","label":"LT Ticker","href":"/docs/v5/websocket/public/etp-ticker","docId":"v5/websocket/public/etp-ticker"},{"type":"link","label":"LT Nav","href":"/docs/v5/websocket/public/etp-nav","docId":"v5/websocket/public/etp-nav"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private","items":[{"type":"link","label":"Position","href":"/docs/v5/websocket/private/position","docId":"v5/websocket/private/position"},{"type":"link","label":"Execution","href":"/docs/v5/websocket/private/execution","docId":"v5/websocket/private/execution"},{"type":"link","label":"Order","href":"/docs/v5/websocket/private/order","docId":"v5/websocket/private/order"},{"type":"link","label":"Wallet","href":"/docs/v5/websocket/private/wallet","docId":"v5/websocket/private/wallet"},{"type":"link","label":"Greek","href":"/docs/v5/websocket/private/greek","docId":"v5/websocket/private/greek"},{"type":"link","label":"Dcp","href":"/docs/v5/websocket/private/dcp","docId":"v5/websocket/private/dcp"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/v5/rate-limit","docId":"v5/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/v5/enum","docId":"v5/enum"},{"type":"link","label":"Error Codes","href":"/docs/v5/error","docId":"v5/error"},{"type":"category","label":"Abandoned Endpoints","items":[{"type":"link","label":"Get LTV","href":"/docs/v5/abandon/ltv","docId":"v5/abandon/ltv"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/abandon/margin-coin-info","docId":"v5/abandon/margin-coin-info"},{"type":"link","label":"Enable Universal Transfer for Sub UID","href":"/docs/v5/abandon/enable-unitransfer-subuid","docId":"v5/abandon/enable-unitransfer-subuid"}],"collapsed":true,"collapsible":true}],"apiExplorerSideBar":[{"type":"category","label":"V5","items":[{"type":"category","label":"Market","items":[{"type":"link","label":"Get Bybit Server Time","href":"/docs/api-explorer/v5/market/time","className":"api-method get","docId":"api-explorer/v5/market/time"},{"type":"link","label":"Get Kline","href":"/docs/api-explorer/v5/market/kline","className":"api-method get","docId":"api-explorer/v5/market/kline"},{"type":"link","label":"Get Mark Price Kline","href":"/docs/api-explorer/v5/market/mark-kline","className":"api-method get","docId":"api-explorer/v5/market/mark-kline"},{"type":"link","label":"Get Index Price Kline","href":"/docs/api-explorer/v5/market/index-kline","className":"api-method get","docId":"api-explorer/v5/market/index-kline"},{"type":"link","label":"Get Premium Index Price Kline","href":"/docs/api-explorer/v5/market/premium-index-kline","className":"api-method get","docId":"api-explorer/v5/market/premium-index-kline"},{"type":"link","label":"Get Instrument Info","href":"/docs/api-explorer/v5/market/instrument","className":"api-method get","docId":"api-explorer/v5/market/instrument"},{"type":"link","label":"Get Orderbook","href":"/docs/api-explorer/v5/market/orderbook","className":"api-method get","docId":"api-explorer/v5/market/orderbook"},{"type":"link","label":"Get Tickers","href":"/docs/api-explorer/v5/market/tickers","className":"api-method get","docId":"api-explorer/v5/market/tickers"},{"type":"link","label":"Get Funding Rate History","href":"/docs/api-explorer/v5/market/history-fund-rate","className":"api-method get","docId":"api-explorer/v5/market/history-fund-rate"},{"type":"link","label":"Get Public Recent Trading History","href":"/docs/api-explorer/v5/market/recent-trade","className":"api-method get","docId":"api-explorer/v5/market/recent-trade"},{"type":"link","label":"Get Open Interest","href":"/docs/api-explorer/v5/market/open-interest","className":"api-method get","docId":"api-explorer/v5/market/open-interest"},{"type":"link","label":"Get Historical Volatility","href":"/docs/api-explorer/v5/market/iv","className":"api-method get","docId":"api-explorer/v5/market/iv"},{"type":"link","label":"Get Insurance","href":"/docs/api-explorer/v5/market/insurance","className":"api-method get","docId":"api-explorer/v5/market/insurance"},{"type":"link","label":"Get Risk Limit","href":"/docs/api-explorer/v5/market/risk-limit","className":"api-method get","docId":"api-explorer/v5/market/risk-limit"},{"type":"link","label":"Get Option Delivery Price","href":"/docs/api-explorer/v5/market/delivery-price","className":"api-method get","docId":"api-explorer/v5/market/delivery-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/market/market"},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/v5/trade/create-order","className":"api-method post","docId":"api-explorer/v5/trade/create-order"},{"type":"link","label":"Amend Order","href":"/docs/api-explorer/v5/trade/amend-order","className":"api-method post","docId":"api-explorer/v5/trade/amend-order"},{"type":"link","label":"Cancel Order","href":"/docs/api-explorer/v5/trade/cancel-order","className":"api-method post","docId":"api-explorer/v5/trade/cancel-order"},{"type":"link","label":"Get Open Orders (real-time)","href":"/docs/api-explorer/v5/trade/open-order","className":"api-method get","docId":"api-explorer/v5/trade/open-order"},{"type":"link","label":"Cancel All Orders","href":"/docs/api-explorer/v5/trade/cancel-all","className":"api-method post","docId":"api-explorer/v5/trade/cancel-all"},{"type":"link","label":"Get Order History (2 years)","href":"/docs/api-explorer/v5/trade/order-list","className":"api-method get","docId":"api-explorer/v5/trade/order-list"},{"type":"link","label":"Batch Place Order","href":"/docs/api-explorer/v5/trade/batch-place","className":"api-method post","docId":"api-explorer/v5/trade/batch-place"},{"type":"link","label":"Batch Amend Order","href":"/docs/api-explorer/v5/trade/batch-amend","className":"api-method post","docId":"api-explorer/v5/trade/batch-amend"},{"type":"link","label":"Batch Cancel Order","href":"/docs/api-explorer/v5/trade/batch-cancel","className":"api-method post","docId":"api-explorer/v5/trade/batch-cancel"},{"type":"link","label":"Get Borrow Quota (Spot)","href":"/docs/api-explorer/v5/trade/query-spot-quota","className":"api-method get","docId":"api-explorer/v5/trade/query-spot-quota"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/trade/trade"},{"type":"category","label":"Position","items":[{"type":"link","label":"Get Position Info","href":"/docs/api-explorer/v5/position/position-info","className":"api-method get","docId":"api-explorer/v5/position/position-info"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/v5/position/leverage","className":"api-method post","docId":"api-explorer/v5/position/leverage"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/api-explorer/v5/position/cross-isolate","className":"api-method post","docId":"api-explorer/v5/position/cross-isolate"},{"type":"link","label":"Set TP/SL Mode","href":"/docs/api-explorer/v5/position/tpsl-mode","className":"api-method post","docId":"api-explorer/v5/position/tpsl-mode"},{"type":"link","label":"Switch Position Mode","href":"/docs/api-explorer/v5/position/position-mode","className":"api-method post","docId":"api-explorer/v5/position/position-mode"},{"type":"link","label":"Set Risk Limit","href":"/docs/api-explorer/v5/position/set-risk-limit","className":"api-method post","docId":"api-explorer/v5/position/set-risk-limit"},{"type":"link","label":"Set Trading Stop","href":"/docs/api-explorer/v5/position/trading-stop","className":"api-method post","docId":"api-explorer/v5/position/trading-stop"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/api-explorer/v5/position/auto-add-margin","className":"api-method post","docId":"api-explorer/v5/position/auto-add-margin"},{"type":"link","label":"Add Or Reduce Margin","href":"/docs/api-explorer/v5/position/manual-add-margin","className":"api-method post","docId":"api-explorer/v5/position/manual-add-margin"},{"type":"link","label":"Get Execution (2 years)","href":"/docs/api-explorer/v5/position/execution","className":"api-method get","docId":"api-explorer/v5/position/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/api-explorer/v5/position/close-pnl","className":"api-method get","docId":"api-explorer/v5/position/close-pnl"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/position/position"},{"type":"category","label":"Account","items":[{"type":"link","label":"Get Wallet Balance","href":"/docs/api-explorer/v5/account/wallet","className":"api-method get","docId":"api-explorer/v5/account/wallet"},{"type":"link","label":"Upgrade to Unified Account","href":"/docs/api-explorer/v5/account/upgrade-unified-account","className":"api-method post","docId":"api-explorer/v5/account/upgrade-unified-account"},{"type":"link","label":"Get Borrow History","href":"/docs/api-explorer/v5/account/borrow-history","className":"api-method get","docId":"api-explorer/v5/account/borrow-history"},{"type":"link","label":"Get Collateral Info","href":"/docs/api-explorer/v5/account/collateral-info","className":"api-method get","docId":"api-explorer/v5/account/collateral-info"},{"type":"link","label":"Get Coin Greeks","href":"/docs/api-explorer/v5/account/coin-greeks","className":"api-method get","docId":"api-explorer/v5/account/coin-greeks"},{"type":"link","label":"Get Fee Rate","href":"/docs/api-explorer/v5/account/fee-rate","className":"api-method get","docId":"api-explorer/v5/account/fee-rate"},{"type":"link","label":"Get Account Info","href":"/docs/api-explorer/v5/account/account-info","className":"api-method get","docId":"api-explorer/v5/account/account-info"},{"type":"link","label":"Get Transaction Log","href":"/docs/api-explorer/v5/account/transaction-log","className":"api-method get","docId":"api-explorer/v5/account/transaction-log"},{"type":"link","label":"Set Margin Mode","href":"/docs/api-explorer/v5/account/set-margin-mode","className":"api-method post","docId":"api-explorer/v5/account/set-margin-mode"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/account/account"},{"type":"category","label":"Asset","items":[{"type":"link","label":"Get Coin Exchange Records","href":"/docs/api-explorer/v5/asset/exchange","className":"api-method get","docId":"api-explorer/v5/asset/exchange"},{"type":"link","label":"Get Option Delivery Record","href":"/docs/api-explorer/v5/asset/option-delivery","className":"api-method get","docId":"api-explorer/v5/asset/option-delivery"},{"type":"link","label":"Get USDC Perpetual Settlement","href":"/docs/api-explorer/v5/asset/settlement","className":"api-method get","docId":"api-explorer/v5/asset/settlement"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/api-explorer/v5/asset/asset-info","className":"api-method get","docId":"api-explorer/v5/asset/asset-info"},{"type":"link","label":"Get All Coins Balance","href":"/docs/api-explorer/v5/asset/all-balance","className":"api-method get","docId":"api-explorer/v5/asset/all-balance"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/api-explorer/v5/asset/account-coin-balance","className":"api-method get","docId":"api-explorer/v5/asset/account-coin-balance"},{"type":"link","label":"Get Transferable Coin","href":"/docs/api-explorer/v5/asset/transferable-coin","className":"api-method get","docId":"api-explorer/v5/asset/transferable-coin"},{"type":"link","label":"Create Internal Transfer","href":"/docs/api-explorer/v5/asset/create-inter-transfer","className":"api-method post","docId":"api-explorer/v5/asset/create-inter-transfer"},{"type":"link","label":"Get Internal Transfer Records","href":"/docs/api-explorer/v5/asset/inter-transfer-list","className":"api-method get","docId":"api-explorer/v5/asset/inter-transfer-list"},{"type":"link","label":"Get Sub UID","href":"/docs/api-explorer/v5/asset/sub-uid-list","className":"api-method get","docId":"api-explorer/v5/asset/sub-uid-list"},{"type":"link","label":"Enable Universal Transfer For Sub UID","href":"/docs/api-explorer/v5/asset/enable-unitransfer-subuid","className":"api-method post","docId":"api-explorer/v5/asset/enable-unitransfer-subuid"},{"type":"link","label":"Create Universal Transfer","href":"/docs/api-explorer/v5/asset/unitransfer","className":"api-method post","docId":"api-explorer/v5/asset/unitransfer"},{"type":"link","label":"Get Universal Transfer Records","href":"/docs/api-explorer/v5/asset/unitransfer-list","className":"api-method get","docId":"api-explorer/v5/asset/unitransfer-list"},{"type":"link","label":"Get Allowed Deposit Coin Info","href":"/docs/api-explorer/v5/asset/deposit-coin-spec","className":"api-method get","docId":"api-explorer/v5/asset/deposit-coin-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/api-explorer/v5/asset/set-deposit-acct","className":"api-method post","docId":"api-explorer/v5/asset/set-deposit-acct"},{"type":"link","label":"Get Deposit Record (on-chain)","href":"/docs/api-explorer/v5/asset/deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/deposit-record"},{"type":"link","label":"Get Sub Account Deposit Records (on-chain)","href":"/docs/api-explorer/v5/asset/sub-deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/sub-deposit-record"},{"type":"link","label":"Get Internal Deposit Records (across Bybit)","href":"/docs/api-explorer/v5/asset/internal-deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/internal-deposit-record"},{"type":"link","label":"Get Master Deposit Address","href":"/docs/api-explorer/v5/asset/master-deposit-addr","className":"api-method get","docId":"api-explorer/v5/asset/master-deposit-addr"},{"type":"link","label":"Get Sub Deposit Address","href":"/docs/api-explorer/v5/asset/sub-deposit-addr","className":"api-method get","docId":"api-explorer/v5/asset/sub-deposit-addr"},{"type":"link","label":"Get Coin Info","href":"/docs/api-explorer/v5/asset/coin-info","className":"api-method get","docId":"api-explorer/v5/asset/coin-info"},{"type":"link","label":"Get Withdraw Records","href":"/docs/api-explorer/v5/asset/withdraw-record","className":"api-method get","docId":"api-explorer/v5/asset/withdraw-record"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/asset/asset"},{"type":"category","label":"User","items":[{"type":"link","label":"Get API Key Information","href":"/docs/api-explorer/v5/user/apikey-info","className":"api-method get","docId":"api-explorer/v5/user/apikey-info"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/user/user"},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"Get Leverage Token Info","href":"/docs/api-explorer/v5/lt/leverage-token-info","className":"api-method get","docId":"api-explorer/v5/lt/leverage-token-info"},{"type":"link","label":"Get Leverage Token Market","href":"/docs/api-explorer/v5/lt/leverage-token-reference","className":"api-method get","docId":"api-explorer/v5/lt/leverage-token-reference"},{"type":"link","label":"Purchase","href":"/docs/api-explorer/v5/lt/purchase","className":"api-method post","docId":"api-explorer/v5/lt/purchase"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/v5/lt/redeem","className":"api-method post","docId":"api-explorer/v5/lt/redeem"},{"type":"link","label":"Get Purchase or Redeem Records","href":"/docs/api-explorer/v5/lt/order-record","className":"api-method get","docId":"api-explorer/v5/lt/order-record"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/lt/etp"},{"type":"category","label":"Spot Margin Trade (UTA)","items":[{"type":"link","label":"Toggle Margin Trade","href":"/docs/api-explorer/v5/spot-margin-uta/switch-mode","className":"api-method post","docId":"api-explorer/v5/spot-margin-uta/switch-mode"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/v5/spot-margin-uta/set-leverage","className":"api-method post","docId":"api-explorer/v5/spot-margin-uta/set-leverage"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/spot-margin-uta/uta-margin-trade"},{"type":"category","label":"Spot Margin Trade (Normal)","items":[{"type":"link","label":"Get Margin Coin Info","href":"/docs/api-explorer/v5/spot-margin-normal/margin-data","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/margin-data"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/api-explorer/v5/spot-margin-normal/borrowable-data","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/api-explorer/v5/spot-margin-normal/interest-quota","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/interest-quota"},{"type":"link","label":"Get Loan Account Info","href":"/docs/api-explorer/v5/spot-margin-normal/account-info","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/account-info"},{"type":"link","label":"Borrow","href":"/docs/api-explorer/v5/spot-margin-normal/borrow","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/borrow"},{"type":"link","label":"Repay","href":"/docs/api-explorer/v5/spot-margin-normal/repay","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/repay"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/api-explorer/v5/spot-margin-normal/borrow-order","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/borrow-order"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/api-explorer/v5/spot-margin-normal/repay-order","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/repay-order"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/api-explorer/v5/spot-margin-normal/switch-mode","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/switch-mode"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/spot-margin-normal/normal-margin-trade"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/category/"},{"type":"category","label":"V3","items":[{"type":"category","label":"Derivatives","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Order Book","href":"/docs/api-explorer/derivatives/market/orderbook","className":"api-method get","docId":"api-explorer/derivatives/market/orderbook"},{"type":"link","label":"Kline","href":"/docs/api-explorer/derivatives/market/kline","className":"api-method get","docId":"api-explorer/derivatives/market/kline"},{"type":"link","label":"Ticker Info","href":"/docs/api-explorer/derivatives/market/ticker","className":"api-method get","docId":"api-explorer/derivatives/market/ticker"},{"type":"link","label":"Instrument Info","href":"/docs/api-explorer/derivatives/market/instrument","className":"api-method get","docId":"api-explorer/derivatives/market/instrument"},{"type":"link","label":"Mark Price Kline","href":"/docs/api-explorer/derivatives/market/mark-kline","className":"api-method get","docId":"api-explorer/derivatives/market/mark-kline"},{"type":"link","label":"Index Price Kline","href":"/docs/api-explorer/derivatives/market/index-kline","className":"api-method get","docId":"api-explorer/derivatives/market/index-kline"},{"type":"link","label":"Premium Index Price Kline","href":"/docs/api-explorer/derivatives/market/premium-index-kline","className":"api-method get","docId":"api-explorer/derivatives/market/premium-index-kline"},{"type":"link","label":"Public trade","href":"/docs/api-explorer/derivatives/market/public-trade","className":"api-method get","docId":"api-explorer/derivatives/market/public-trade"},{"type":"link","label":"Risk limit","href":"/docs/api-explorer/derivatives/market/risk-limit","className":"api-method get","docId":"api-explorer/derivatives/market/risk-limit"},{"type":"link","label":"Funding Rate History","href":"/docs/api-explorer/derivatives/market/his-fund-rate","className":"api-method get","docId":"api-explorer/derivatives/market/his-fund-rate"},{"type":"link","label":"Open Interest","href":"/docs/api-explorer/derivatives/market/open-interest","className":"api-method get","docId":"api-explorer/derivatives/market/open-interest"},{"type":"link","label":"Delivery price","href":"/docs/api-explorer/derivatives/market/delivery-price","className":"api-method get","docId":"api-explorer/derivatives/market/delivery-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/market/market"},{"type":"category","label":"Unified Margin Account","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/derivatives/trade/unified/create-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/create-order"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/derivatives/trade/unified/open-order","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/open-order"},{"type":"link","label":"Replace Order","href":"/docs/api-explorer/derivatives/trade/unified/replace-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/replace-order"},{"type":"link","label":"Cancl Order","href":"/docs/api-explorer/derivatives/trade/unified/cancel-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/cancel-order"},{"type":"link","label":"Cancl All Orders","href":"/docs/api-explorer/derivatives/trade/unified/cancel-all","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/cancel-all"},{"type":"link","label":"Batch Place Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-place","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-place"},{"type":"link","label":"Batch Replace Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-replace-place","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-replace-place"},{"type":"link","label":"Batch Cancel Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-cancel","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-cancel"},{"type":"link","label":"Get Order List","href":"/docs/api-explorer/derivatives/trade/unified/order-list","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/order-list"},{"type":"link","label":"Get position","href":"/docs/api-explorer/derivatives/trade/unified/myposition","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/myposition"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/trade/unified/unified"},{"type":"category","label":"Contract","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/derivatives/trade/contract/create-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/create-order"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/derivatives/trade/contract/open-order","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/open-order"},{"type":"link","label":"Replace Order","href":"/docs/api-explorer/derivatives/trade/contract/replace-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/replace-order"},{"type":"link","label":"Cancel Order","href":"/docs/api-explorer/derivatives/trade/contract/cancel-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cancel-order"},{"type":"link","label":"Cancel All Order","href":"/docs/api-explorer/derivatives/trade/contract/cancel-all","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cancel-all"},{"type":"link","label":"Get Order List","href":"/docs/api-explorer/derivatives/trade/contract/order-list","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/order-list"},{"type":"link","label":"My Position","href":"/docs/api-explorer/derivatives/trade/contract/position-info","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/position-info"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/api-explorer/derivatives/trade/contract/auto-margin","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/auto-margin"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/api-explorer/derivatives/trade/contract/cross-isolated-margin","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cross-isolated-margin"},{"type":"link","label":"Switch Position Mode","href":"/docs/api-explorer/derivatives/trade/contract/position-mode","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/position-mode"},{"type":"link","label":"Switch TP/SL Mode","href":"/docs/api-explorer/derivatives/trade/contract/tpsl-mode","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/tpsl-mode"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/derivatives/trade/contract/leverage","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/leverage"},{"type":"link","label":"Set Trading Stop","href":"/docs/api-explorer/derivatives/trade/contract/trading-stop","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/trading-stop"},{"type":"link","label":"Set Risk Limit","href":"/docs/api-explorer/derivatives/trade/contract/set-risk-limit","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/set-risk-limit"},{"type":"link","label":"Get Execution List","href":"/docs/api-explorer/derivatives/trade/contract/execution","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/api-explorer/derivatives/trade/contract/close-pnl","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/close-pnl"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/trade/contract/contract"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/category/"},{"type":"category","label":"Spot","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Instrument Info","href":"/docs/api-explorer/spot/market/instrument-info","className":"api-method get","docId":"api-explorer/spot/market/instrument-info"},{"type":"link","label":"Order Book","href":"/docs/api-explorer/spot/market/order-book","className":"api-method get","docId":"api-explorer/spot/market/order-book"},{"type":"link","label":"Merged Order Book","href":"/docs/api-explorer/spot/market/merged-order-book","className":"api-method get","docId":"api-explorer/spot/market/merged-order-book"},{"type":"link","label":"Public Trading Records","href":"/docs/api-explorer/spot/market/public-trading-records","className":"api-method get","docId":"api-explorer/spot/market/public-trading-records"},{"type":"link","label":"Query Kline","href":"/docs/api-explorer/spot/market/query-kline","className":"api-method get","docId":"api-explorer/spot/market/query-kline"},{"type":"link","label":"Lastest Information for Symbol","href":"/docs/api-explorer/spot/market/lastest-information-for-symbol","className":"api-method get","docId":"api-explorer/spot/market/lastest-information-for-symbol"},{"type":"link","label":"Name of the trading pair","href":"/docs/api-explorer/spot/market/last-traded-price","className":"api-method get","docId":"api-explorer/spot/market/last-traded-price"},{"type":"link","label":"Best Bid/Ask Price","href":"/docs/api-explorer/spot/market/best-bidask-price","className":"api-method get","docId":"api-explorer/spot/market/best-bidask-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/market/market"},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/spot/trade/place-order","className":"api-method post","docId":"api-explorer/spot/trade/place-order"},{"type":"link","label":"Cancel Active Order","href":"/docs/api-explorer/spot/trade/cancel-active-order","className":"api-method post","docId":"api-explorer/spot/trade/cancel-active-order"},{"type":"link","label":"Batch Cancel Active Order","href":"/docs/api-explorer/spot/trade/batch-cancel-active-order","className":"api-method post","docId":"api-explorer/spot/trade/batch-cancel-active-order"},{"type":"link","label":"Batch Cancel Active Order By IDs","href":"/docs/api-explorer/spot/trade/batch-cancel-active-order-by-ids","className":"api-method post","docId":"api-explorer/spot/trade/batch-cancel-active-order-by-ids"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/spot/trade/open-order","className":"api-method get","docId":"api-explorer/spot/trade/open-order"},{"type":"link","label":"Get Order History","href":"/docs/api-explorer/spot/trade/order-history","className":"api-method get","docId":"api-explorer/spot/trade/order-history"},{"type":"link","label":"Get Trade History","href":"/docs/api-explorer/spot/trade/trade-history","className":"api-method get","docId":"api-explorer/spot/trade/trade-history"},{"type":"link","label":"Get Wallet Balance","href":"/docs/api-explorer/spot/trade/wallet-balance","className":"api-method get","docId":"api-explorer/spot/trade/wallet-balance"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/trade/spot-trade"},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"All Asset Infos","href":"/docs/api-explorer/spot/lttrade/all-asset-info","className":"api-method get","docId":"api-explorer/spot/lttrade/all-asset-info"},{"type":"link","label":"Market Info","href":"/docs/api-explorer/spot/lttrade/market-info","className":"api-method get","docId":"api-explorer/spot/lttrade/market-info"},{"type":"link","label":"Purchase","href":"/docs/api-explorer/spot/lttrade/purchase","className":"api-method post","docId":"api-explorer/spot/lttrade/purchase"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/spot/lttrade/redeem","className":"api-method post","docId":"api-explorer/spot/lttrade/redeem"},{"type":"link","label":"Get Purchase or Redemption History","href":"/docs/api-explorer/spot/lttrade/purchase-redemption-history","className":"api-method get","docId":"api-explorer/spot/lttrade/purchase-redemption-history"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/lttrade/etp"},{"type":"category","label":"Spot Margin Trade","items":[{"type":"link","label":"Borrow Margin Loan","href":"/docs/api-explorer/spot/crossmargin/borrow-margin-loan","className":"api-method post","docId":"api-explorer/spot/crossmargin/borrow-margin-loan"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/spot/crossmargin/redeem","className":"api-method post","docId":"api-explorer/spot/crossmargin/redeem"},{"type":"link","label":"Query Borrowing Info","href":"/docs/api-explorer/spot/crossmargin/query-borrowing-info","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-borrowing-info"},{"type":"link","label":"Query Account Info","href":"/docs/api-explorer/spot/crossmargin/query-account-info","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-account-info"},{"type":"link","label":"Query Interest and Quota","href":"/docs/api-explorer/spot/crossmargin/query-interest-quota","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-interest-quota"},{"type":"link","label":"Query Repayment History","href":"/docs/api-explorer/spot/crossmargin/query-repayment-history","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-repayment-history"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/crossmargin/crossmargin"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/category/"}],"collapsed":true,"collapsible":true}],"changelogSidebar":[{"type":"link","label":"V5","href":"/docs/changelog/v5","docId":"changelog/v5"},{"type":"link","label":"Derivatives V3","href":"/docs/changelog/derivatives-v3","docId":"changelog/derivatives-v3"},{"type":"link","label":"Spot V3","href":"/docs/changelog/spot-v3","docId":"changelog/spot-v3"},{"type":"link","label":"Account Asset V3","href":"/docs/changelog/asset-v3","docId":"changelog/asset-v3"},{"type":"link","label":"Copy Trading","href":"/docs/changelog/copytrade","docId":"changelog/copytrade"}]},"docs":{"account_asset":{"id":"account_asset","title":"account_asset","description":"const Home = () => {"},"account_asset/v1":{"id":"account_asset/v1","title":"v1","description":"const Home = () => {"},"account_asset/v3":{"id":"account_asset/v3","title":"v3","description":"const Home = () => {"},"api-explorer/derivatives/market/delivery-price":{"id":"api-explorer/derivatives/market/delivery-price","title":"Delivery price","description":"Get delivery price of option","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/his-fund-rate":{"id":"api-explorer/derivatives/market/his-fund-rate","title":"Funding Rate History","description":"Get historical funding rate","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/index-kline":{"id":"api-explorer/derivatives/market/index-kline","title":"Index Price Kline","description":"Get index price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/instrument":{"id":"api-explorer/derivatives/market/instrument","title":"Instrument Info","description":"Get launched instruments information. `category`=option is required for option.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/kline":{"id":"api-explorer/derivatives/market/kline","title":"Kline","description":"Get kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/mark-kline":{"id":"api-explorer/derivatives/market/mark-kline","title":"Mark Price Kline","description":"Get mark price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/market":{"id":"api-explorer/derivatives/market/market","title":"Market data","description":"Market data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/open-interest":{"id":"api-explorer/derivatives/market/open-interest","title":"Open Interest","description":"Get open interest","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/orderbook":{"id":"api-explorer/derivatives/market/orderbook","title":"Order Book","description":"Get order book data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/premium-index-kline":{"id":"api-explorer/derivatives/market/premium-index-kline","title":"Premium Index Price Kline","description":"Get premium index price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/public-trade":{"id":"api-explorer/derivatives/market/public-trade","title":"Public trade","description":"Get public trade","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/risk-limit":{"id":"api-explorer/derivatives/market/risk-limit","title":"Risk limit","description":"Get risk limit","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/ticker":{"id":"api-explorer/derivatives/market/ticker","title":"Ticker Info","description":"Get all latest information of symbols. All parameters are needed for OPTION","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/auto-margin":{"id":"api-explorer/derivatives/trade/contract/auto-margin","title":"Set Auto Add Margin","description":"Turn on/off auto add position margin.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cancel-all":{"id":"api-explorer/derivatives/trade/contract/cancel-all","title":"Cancel All Order","description":"Cancel all orders.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cancel-order":{"id":"api-explorer/derivatives/trade/contract/cancel-order","title":"Cancel Order","description":"Cancel a order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/close-pnl":{"id":"api-explorer/derivatives/trade/contract/close-pnl","title":"Get Closed PnL","description":"Get closed pnl.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/contract":{"id":"api-explorer/derivatives/trade/contract/contract","title":"Contract","description":"Contract","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/create-order":{"id":"api-explorer/derivatives/trade/contract/create-order","title":"Place Order","description":"Place a future or option order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cross-isolated-margin":{"id":"api-explorer/derivatives/trade/contract/cross-isolated-margin","title":"Switch Cross/Isolated Margin","description":"Switch cross/isolated margin mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/execution":{"id":"api-explorer/derivatives/trade/contract/execution","title":"Get Execution List","description":"Get execution list.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/leverage":{"id":"api-explorer/derivatives/trade/contract/leverage","title":"Set Leverage","description":"Set levearage.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/open-order":{"id":"api-explorer/derivatives/trade/contract/open-order","title":"Get Open Orders","description":"Get unfilled orders.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/order-list":{"id":"api-explorer/derivatives/trade/contract/order-list","title":"Get Order List","description":"Get order history.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/position-info":{"id":"api-explorer/derivatives/trade/contract/position-info","title":"My Position","description":"Get real-time position data.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/position-mode":{"id":"api-explorer/derivatives/trade/contract/position-mode","title":"Switch Position Mode","description":"Switch position mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/replace-order":{"id":"api-explorer/derivatives/trade/contract/replace-order","title":"Replace Order","description":"Replace an order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/set-risk-limit":{"id":"api-explorer/derivatives/trade/contract/set-risk-limit","title":"Set Risk Limit","description":"Set risk limit.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/tpsl-mode":{"id":"api-explorer/derivatives/trade/contract/tpsl-mode","title":"Switch TP/SL Mode","description":"Switch tp/sl mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/trading-stop":{"id":"api-explorer/derivatives/trade/contract/trading-stop","title":"Set Trading Stop","description":"Set trade stop.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-cancel":{"id":"api-explorer/derivatives/trade/unified/batch-cancel","title":"Batch Cancel Order","description":"Batch cancel orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-place":{"id":"api-explorer/derivatives/trade/unified/batch-place","title":"Batch Place Order","description":"Batch place orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-replace-place":{"id":"api-explorer/derivatives/trade/unified/batch-replace-place","title":"Batch Replace Order","description":"Batch replace orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/cancel-all":{"id":"api-explorer/derivatives/trade/unified/cancel-all","title":"Cancl All Orders","description":"Cancel all orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/cancel-order":{"id":"api-explorer/derivatives/trade/unified/cancel-order","title":"Cancl Order","description":"Cancel a future or option order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/create-order":{"id":"api-explorer/derivatives/trade/unified/create-order","title":"Place Order","description":"Place a future or option order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/myposition":{"id":"api-explorer/derivatives/trade/unified/myposition","title":"Get position","description":"Get your position info","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/open-order":{"id":"api-explorer/derivatives/trade/unified/open-order","title":"Get Open Orders","description":"Get unfilled orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/order-list":{"id":"api-explorer/derivatives/trade/unified/order-list","title":"Get Order List","description":"Get order list","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/replace-order":{"id":"api-explorer/derivatives/trade/unified/replace-order","title":"Replace Order","description":"Replace an order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/unified":{"id":"api-explorer/derivatives/trade/unified/unified","title":"Unified Margin Account","description":"Unified Margin Account","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/borrow-margin-loan":{"id":"api-explorer/spot/crossmargin/borrow-margin-loan","title":"Borrow Margin Loan","description":"Borrow Margin Loan","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/crossmargin":{"id":"api-explorer/spot/crossmargin/crossmargin","title":"Spot Margin Trade","description":"Spot Margin Trade","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-account-info":{"id":"api-explorer/spot/crossmargin/query-account-info","title":"Query Account Info","description":"Query Account Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-borrowing-info":{"id":"api-explorer/spot/crossmargin/query-borrowing-info","title":"Query Borrowing Info","description":"Query Borrowing Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-interest-quota":{"id":"api-explorer/spot/crossmargin/query-interest-quota","title":"Query Interest and Quota","description":"Query Interest and Quota","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-repayment-history":{"id":"api-explorer/spot/crossmargin/query-repayment-history","title":"Query Repayment History","description":"Query Repayment History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/redeem":{"id":"api-explorer/spot/crossmargin/redeem","title":"Redeem","description":"Redeem","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/all-asset-info":{"id":"api-explorer/spot/lttrade/all-asset-info","title":"All Asset Infos","description":"Get All Asset Infos","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/etp":{"id":"api-explorer/spot/lttrade/etp","title":"Spot Leverage Token","description":"Spot Leverage Token","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/market-info":{"id":"api-explorer/spot/lttrade/market-info","title":"Market Info","description":"Get Market Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/purchase":{"id":"api-explorer/spot/lttrade/purchase","title":"Purchase","description":"Purchase","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/purchase-redemption-history":{"id":"api-explorer/spot/lttrade/purchase-redemption-history","title":"Get Purchase or Redemption History","description":"Get Purchase or Redemption History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/redeem":{"id":"api-explorer/spot/lttrade/redeem","title":"Redeem","description":"Redeem","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/best-bidask-price":{"id":"api-explorer/spot/market/best-bidask-price","title":"Best Bid/Ask Price","description":"Get Best Bid/Ask Price","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/instrument-info":{"id":"api-explorer/spot/market/instrument-info","title":"Instrument Info","description":"Get the spec of spot symbols","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/last-traded-price":{"id":"api-explorer/spot/market/last-traded-price","title":"Name of the trading pair","description":"Get Last Traded Price","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/lastest-information-for-symbol":{"id":"api-explorer/spot/market/lastest-information-for-symbol","title":"Lastest Information for Symbol","description":"Get Lastest Information for Symbol","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/market":{"id":"api-explorer/spot/market/market","title":"Market data","description":"Market data","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/merged-order-book":{"id":"api-explorer/spot/market/merged-order-book","title":"Merged Order Book","description":"Get Merged Order Book","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/order-book":{"id":"api-explorer/spot/market/order-book","title":"Order Book","description":"Get Order Book","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/public-trading-records":{"id":"api-explorer/spot/market/public-trading-records","title":"Public Trading Records","description":"Get Public Trading Records","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/query-kline":{"id":"api-explorer/spot/market/query-kline","title":"Query Kline","description":"Get Kline","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/batch-cancel-active-order":{"id":"api-explorer/spot/trade/batch-cancel-active-order","title":"Batch Cancel Active Order","description":"Batch Cancel Active Order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/batch-cancel-active-order-by-ids":{"id":"api-explorer/spot/trade/batch-cancel-active-order-by-ids","title":"Batch Cancel Active Order By IDs","description":"Batch Cancel Active Order By IDs","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/cancel-active-order":{"id":"api-explorer/spot/trade/cancel-active-order","title":"Cancel Active Order","description":"Cancel Active Order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/open-order":{"id":"api-explorer/spot/trade/open-order","title":"Get Open Orders","description":"Get Open Orders.","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/order-history":{"id":"api-explorer/spot/trade/order-history","title":"Get Order History","description":"Get Order History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/place-order":{"id":"api-explorer/spot/trade/place-order","title":"Place Order","description":"Place a order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/spot-trade":{"id":"api-explorer/spot/trade/spot-trade","title":"Trade","description":"Trade","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/trade-history":{"id":"api-explorer/spot/trade/trade-history","title":"Get Trade History","description":"Get Trade History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/wallet-balance":{"id":"api-explorer/spot/trade/wallet-balance","title":"Get Wallet Balance","description":"Get Wallet Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/account":{"id":"api-explorer/v5/account/account","title":"Account","description":"Account","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/account-info":{"id":"api-explorer/v5/account/account-info","title":"Get Account Info","description":"Get account info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/borrow-history":{"id":"api-explorer/v5/account/borrow-history","title":"Get Borrow History","description":"Get borrow history","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/coin-greeks":{"id":"api-explorer/v5/account/coin-greeks","title":"Get Coin Greeks","description":"Get coin greek info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/collateral-info":{"id":"api-explorer/v5/account/collateral-info","title":"Get Collateral Info","description":"Get collateral info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/fee-rate":{"id":"api-explorer/v5/account/fee-rate","title":"Get Fee Rate","description":"Get fee rate","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/set-margin-mode":{"id":"api-explorer/v5/account/set-margin-mode","title":"Set Margin Mode","description":"Set margin mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/transaction-log":{"id":"api-explorer/v5/account/transaction-log","title":"Get Transaction Log","description":"Get transaction log","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/upgrade-unified-account":{"id":"api-explorer/v5/account/upgrade-unified-account","title":"Upgrade to Unified Account","description":"Upgrade to UTA","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/wallet":{"id":"api-explorer/v5/account/wallet","title":"Get Wallet Balance","description":"Get wallet balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/account-coin-balance":{"id":"api-explorer/v5/asset/account-coin-balance","title":"Get Single Coin Balance","description":"Get Single Coin Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/all-balance":{"id":"api-explorer/v5/asset/all-balance","title":"Get All Coins Balance","description":"Get All Coins Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/asset":{"id":"api-explorer/v5/asset/asset","title":"Asset","description":"Asset","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/asset-info":{"id":"api-explorer/v5/asset/asset-info","title":"Get Asset Info (Spot)","description":"Get spot asset","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/coin-info":{"id":"api-explorer/v5/asset/coin-info","title":"Get Coin Info","description":"Get coin info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/create-inter-transfer":{"id":"api-explorer/v5/asset/create-inter-transfer","title":"Create Internal Transfer","description":"Create internal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/deposit-coin-spec":{"id":"api-explorer/v5/asset/deposit-coin-spec","title":"Get Allowed Deposit Coin Info","description":"Get allowed deposit coin info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/deposit-record":{"id":"api-explorer/v5/asset/deposit-record","title":"Get Deposit Record (on-chain)","description":"Get deposit record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/enable-unitransfer-subuid":{"id":"api-explorer/v5/asset/enable-unitransfer-subuid","title":"Enable Universal Transfer For Sub UID","description":"Enable sub uid for universal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/exchange":{"id":"api-explorer/v5/asset/exchange","title":"Get Coin Exchange Records","description":"Get exchange records","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/inter-transfer-list":{"id":"api-explorer/v5/asset/inter-transfer-list","title":"Get Internal Transfer Records","description":"Get internal transfer records","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/internal-deposit-record":{"id":"api-explorer/v5/asset/internal-deposit-record","title":"Get Internal Deposit Records (across Bybit)","description":"Get deposit records through Bybit platform","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/master-deposit-addr":{"id":"api-explorer/v5/asset/master-deposit-addr","title":"Get Master Deposit Address","description":"Get master deposit address","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/option-delivery":{"id":"api-explorer/v5/asset/option-delivery","title":"Get Option Delivery Record","description":"Get delivery record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/set-deposit-acct":{"id":"api-explorer/v5/asset/set-deposit-acct","title":"Set Deposit Account","description":"Set Deposit Account","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/settlement":{"id":"api-explorer/v5/asset/settlement","title":"Get USDC Perpetual Settlement","description":"Get Settlement Record.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-deposit-addr":{"id":"api-explorer/v5/asset/sub-deposit-addr","title":"Get Sub Deposit Address","description":"Get sub deposit address","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-deposit-record":{"id":"api-explorer/v5/asset/sub-deposit-record","title":"Get Sub Account Deposit Records (on-chain)","description":"Get sub account deposit record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-uid-list":{"id":"api-explorer/v5/asset/sub-uid-list","title":"Get Sub UID","description":"Get sub uid","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/transferable-coin":{"id":"api-explorer/v5/asset/transferable-coin","title":"Get Transferable Coin","description":"Get transferable coins","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/unitransfer":{"id":"api-explorer/v5/asset/unitransfer","title":"Create Universal Transfer","description":"Create universal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/unitransfer-list":{"id":"api-explorer/v5/asset/unitransfer-list","title":"Get Universal Transfer Records","description":"Get universal transfer record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/withdraw-record":{"id":"api-explorer/v5/asset/withdraw-record","title":"Get Withdraw Records","description":"Get withdraw record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/etp":{"id":"api-explorer/v5/lt/etp","title":"Spot Leverage Token","description":"Spot Leverage Token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/leverage-token-info":{"id":"api-explorer/v5/lt/leverage-token-info","title":"Get Leverage Token Info","description":"Get lt information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/leverage-token-reference":{"id":"api-explorer/v5/lt/leverage-token-reference","title":"Get Leverage Token Market","description":"Get lt market information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/order-record":{"id":"api-explorer/v5/lt/order-record","title":"Get Purchase or Redeem Records","description":"Get the order history of purchase or redeem","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/purchase":{"id":"api-explorer/v5/lt/purchase","title":"Purchase","description":"Purchase leverage token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/redeem":{"id":"api-explorer/v5/lt/redeem","title":"Redeem","description":"Redeem leverage token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/delivery-price":{"id":"api-explorer/v5/market/delivery-price","title":"Get Option Delivery Price","description":"Get delivery price of option","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/history-fund-rate":{"id":"api-explorer/v5/market/history-fund-rate","title":"Get Funding Rate History","description":"Get historical funding rate","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/index-kline":{"id":"api-explorer/v5/market/index-kline","title":"Get Index Price Kline","description":"Get Index Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/instrument":{"id":"api-explorer/v5/market/instrument","title":"Get Instrument Info","description":"Get launched instruments information.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/insurance":{"id":"api-explorer/v5/market/insurance","title":"Get Insurance","description":"Get Insurance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/iv":{"id":"api-explorer/v5/market/iv","title":"Get Historical Volatility","description":"Get historical volatility","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/kline":{"id":"api-explorer/v5/market/kline","title":"Get Kline","description":"Get kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/mark-kline":{"id":"api-explorer/v5/market/mark-kline","title":"Get Mark Price Kline","description":"Get Mark Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/market":{"id":"api-explorer/v5/market/market","title":"Market","description":"Market","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/open-interest":{"id":"api-explorer/v5/market/open-interest","title":"Get Open Interest","description":"Get open interest","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/orderbook":{"id":"api-explorer/v5/market/orderbook","title":"Get Orderbook","description":"Get order book data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/premium-index-kline":{"id":"api-explorer/v5/market/premium-index-kline","title":"Get Premium Index Price Kline","description":"Get Premium Index Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/recent-trade":{"id":"api-explorer/v5/market/recent-trade","title":"Get Public Recent Trading History","description":"Get public trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/risk-limit":{"id":"api-explorer/v5/market/risk-limit","title":"Get Risk Limit","description":"Get risk limit","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/tickers":{"id":"api-explorer/v5/market/tickers","title":"Get Tickers","description":"Get all latest information of symbols. All parameters are needed for OPTION","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/time":{"id":"api-explorer/v5/market/time","title":"Get Bybit Server Time","description":"Get server time","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/auto-add-margin":{"id":"api-explorer/v5/position/auto-add-margin","title":"Set Auto Add Margin","description":"Set Auto Add Margin","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/close-pnl":{"id":"api-explorer/v5/position/close-pnl","title":"Get Closed PnL","description":"Get closed pnl","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/cross-isolate":{"id":"api-explorer/v5/position/cross-isolate","title":"Switch Cross/Isolated Margin","description":"Select cross margin mode or isolated margin mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/execution":{"id":"api-explorer/v5/position/execution","title":"Get Execution (2 years)","description":"Get execution list","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/leverage":{"id":"api-explorer/v5/position/leverage","title":"Set Leverage","description":"Set levearage.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/manual-add-margin":{"id":"api-explorer/v5/position/manual-add-margin","title":"Add Or Reduce Margin","description":"Manually add or reduce margin for isolated margin position","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position":{"id":"api-explorer/v5/position/position","title":"Position","description":"Position","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position-info":{"id":"api-explorer/v5/position/position-info","title":"Get Position Info","description":"Get Position Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position-mode":{"id":"api-explorer/v5/position/position-mode","title":"Switch Position Mode","description":"Switch Position Mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/set-risk-limit":{"id":"api-explorer/v5/position/set-risk-limit","title":"Set Risk Limit","description":"Set risk limit.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/tpsl-mode":{"id":"api-explorer/v5/position/tpsl-mode","title":"Set TP/SL Mode","description":"Set tp/sl mode.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/trading-stop":{"id":"api-explorer/v5/position/trading-stop","title":"Set Trading Stop","description":"Set trade stop.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/account-info":{"id":"api-explorer/v5/spot-margin-normal/account-info","title":"Get Loan Account Info","description":"Get Loan Account Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrow":{"id":"api-explorer/v5/spot-margin-normal/borrow","title":"Borrow","description":"Borrow","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrow-order":{"id":"api-explorer/v5/spot-margin-normal/borrow-order","title":"Get Borrow Order Detail","description":"Get Borrow Order Detail","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrowable-data":{"id":"api-explorer/v5/spot-margin-normal/borrowable-data","title":"Get Borrowable Coin Info","description":"Get Borrowable Coin Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/interest-quota":{"id":"api-explorer/v5/spot-margin-normal/interest-quota","title":"Get Interest & Quota","description":"Get Interest & Quota","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/margin-data":{"id":"api-explorer/v5/spot-margin-normal/margin-data","title":"Get Margin Coin Info","description":"Get Margin Coin Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/normal-margin-trade":{"id":"api-explorer/v5/spot-margin-normal/normal-margin-trade","title":"Spot Margin Trade (Normal)","description":"Spot Margin Trade (Normal)","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/repay":{"id":"api-explorer/v5/spot-margin-normal/repay","title":"Repay","description":"Repay","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/repay-order":{"id":"api-explorer/v5/spot-margin-normal/repay-order","title":"Get Repayment Order Detail","description":"Get Repayment Order Detail","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/switch-mode":{"id":"api-explorer/v5/spot-margin-normal/switch-mode","title":"Toggle Margin Trade","description":"Toggle Margin Trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/set-leverage":{"id":"api-explorer/v5/spot-margin-uta/set-leverage","title":"Set Leverage","description":"Set leverage for margin trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/switch-mode":{"id":"api-explorer/v5/spot-margin-uta/switch-mode","title":"Toggle Margin Trade","description":"Toggle margin trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/uta-margin-trade":{"id":"api-explorer/v5/spot-margin-uta/uta-margin-trade","title":"Spot Margin Trade (UTA)","description":"Spot Margin Trade (UTA)","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/amend-order":{"id":"api-explorer/v5/trade/amend-order","title":"Amend Order","description":"Amend an order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-amend":{"id":"api-explorer/v5/trade/batch-amend","title":"Batch Amend Order","description":"Batch amend orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-cancel":{"id":"api-explorer/v5/trade/batch-cancel","title":"Batch Cancel Order","description":"Batch cancel orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-place":{"id":"api-explorer/v5/trade/batch-place","title":"Batch Place Order","description":"Batch place orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/cancel-all":{"id":"api-explorer/v5/trade/cancel-all","title":"Cancel All Orders","description":"Cancel all orders.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/cancel-order":{"id":"api-explorer/v5/trade/cancel-order","title":"Cancel Order","description":"Cancel a single order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/create-order":{"id":"api-explorer/v5/trade/create-order","title":"Place Order","description":"Place an order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/open-order":{"id":"api-explorer/v5/trade/open-order","title":"Get Open Orders (real-time)","description":"Get unfilled orders or partially filled orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/order-list":{"id":"api-explorer/v5/trade/order-list","title":"Get Order History (2 years)","description":"Get order history.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/query-spot-quota":{"id":"api-explorer/v5/trade/query-spot-quota","title":"Get Borrow Quota (Spot)","description":"Query user\'s spot available quota","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/trade":{"id":"api-explorer/v5/trade/trade","title":"Trade","description":"Trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/user/apikey-info":{"id":"api-explorer/v5/user/apikey-info","title":"Get API Key Information","description":"Get API Key Information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/user/user":{"id":"api-explorer/v5/user/user","title":"User","description":"User","sidebar":"apiExplorerSideBar"},"changelog/asset-v3":{"id":"changelog/asset-v3","title":"Account Asset V3","description":"2023-09-18","sidebar":"changelogSidebar"},"changelog/copytrade":{"id":"changelog/copytrade","title":"Copy Trading","description":"2023-06-24","sidebar":"changelogSidebar"},"changelog/derivatives-v3":{"id":"changelog/derivatives-v3","title":"Derivatives V3","description":"2023-10-25","sidebar":"changelogSidebar"},"changelog/spot-v3":{"id":"changelog/spot-v3","title":"Spot V3","description":"2023-04-20","sidebar":"changelogSidebar"},"changelog/v5":{"id":"changelog/v5","title":"V5","description":"2023-11-08","sidebar":"changelogSidebar"},"copy_trading":{"id":"copy_trading","title":"copy_trading","description":"const Home = () => {"},"derivativesV3/contract":{"id":"derivativesV3/contract","title":"contract","description":"const Home = () => {"},"derivativesV3/unified_margin":{"id":"derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"faq":{"id":"faq","title":"Frequently Asked Questions","description":"Where are Bybit\'s servers located?"},"futuresV2/inverse":{"id":"futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"futuresV2/inverse_futures":{"id":"futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"futuresV2/linear":{"id":"futuresV2/linear","title":"linear","description":"const Home = () => {"},"inverse":{"id":"inverse","title":"inverse","description":"const Home = () => {"},"inverse_futures":{"id":"inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"linear":{"id":"linear","title":"linear","description":"const Home = () => {"},"pilot-feature/pilot":{"id":"pilot-feature/pilot","title":"Pilot Features","description":"Spot Supports Amend Order"},"spot":{"id":"spot","title":"spot","description":"const Home = () => {"},"spot/v1":{"id":"spot/v1","title":"v1","description":"const Home = () => {"},"spot/v3":{"id":"spot/v3","title":"v3","description":"const Home = () => {"},"tax":{"id":"tax","title":"tax","description":"const Home = () => {"},"testnet/account_asset":{"id":"testnet/account_asset","title":"account_asset","description":"const Home = () => {"},"testnet/account_asset/v1":{"id":"testnet/account_asset/v1","title":"v1","description":"const Home = () => {"},"testnet/account_asset/v3":{"id":"testnet/account_asset/v3","title":"v3","description":"const Home = () => {"},"testnet/copy_trading":{"id":"testnet/copy_trading","title":"copy_trading","description":"const Home = () => {"},"testnet/derivativesV3/contract":{"id":"testnet/derivativesV3/contract","title":"contract","description":"const Home = () => {"},"testnet/derivativesV3/unified_margin":{"id":"testnet/derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"testnet/futuresV2/inverse":{"id":"testnet/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"testnet/futuresV2/inverse_futures":{"id":"testnet/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"testnet/futuresV2/linear":{"id":"testnet/futuresV2/linear","title":"linear","description":"const Home = () => {"},"testnet/inverse":{"id":"testnet/inverse","title":"inverse","description":"const Home = () => {"},"testnet/inverse_futures":{"id":"testnet/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"testnet/linear":{"id":"testnet/linear","title":"linear","description":"const Home = () => {"},"testnet/spot":{"id":"testnet/spot","title":"spot","description":"const Home = () => {"},"testnet/spot/v1":{"id":"testnet/spot/v1","title":"v1","description":"const Home = () => {"},"testnet/spot/v3":{"id":"testnet/spot/v3","title":"v3","description":"const Home = () => {"},"testnet/tax":{"id":"testnet/tax","title":"tax","description":"const Home = () => {"},"testnet/usdc/option":{"id":"testnet/usdc/option","title":"option","description":"const Home = () => {"},"testnet/usdc/perpetual":{"id":"testnet/usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"usdc/option":{"id":"usdc/option","title":"option","description":"const Home = () => {"},"usdc/perpetual":{"id":"usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"v3/account-asset/enum":{"id":"v3/account-asset/enum","title":"Enums Definitions","description":"accountType","sidebar":"v3SideBar"},"v3/account-asset/error":{"id":"v3/account-asset/error","title":"Error Code","description":"|Code |Description |","sidebar":"v3SideBar"},"v3/account-asset/rate-limit":{"id":"v3/account-asset/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/account-asset/transfer/all-balance":{"id":"v3/account-asset/transfer/all-balance","title":"Get All Coins Balance","description":"You could get all coins balance of all account types under the master account, and sub account.","sidebar":"v3SideBar"},"v3/account-asset/transfer/asset-info":{"id":"v3/account-asset/transfer/asset-info","title":"Get Asset Info","description":"Can query SPOT asset information only","sidebar":"v3SideBar"},"v3/account-asset/transfer/coin-balance":{"id":"v3/account-asset/transfer/coin-balance","title":"Get Single Coin Balance","description":"You could get a single coin balance under the master account, and sub account coin balance.","sidebar":"v3SideBar"},"v3/account-asset/transfer/enable-uni-transfer":{"id":"v3/account-asset/transfer/enable-uni-transfer","title":"Enable Universal Transfer (Depreciated)","description":"Enable Universal Transfer","sidebar":"v3SideBar"},"v3/account-asset/transfer/internal-transfer":{"id":"v3/account-asset/transfer/internal-transfer","title":"Create Internal Transfer","description":"Transfers funds between the different sections of an individual\'s account (not between subaccounts). For example, between the spot and derivatives accounts.","sidebar":"v3SideBar"},"v3/account-asset/transfer/internal-transfer-list":{"id":"v3/account-asset/transfer/internal-transfer-list","title":"Get Internal Transfer List","description":"Query Internal Transfer List","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-list":{"id":"v3/account-asset/transfer/subacct-list","title":"Get Subaccount UID List","description":"Query Subaccount List","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-transfer":{"id":"v3/account-asset/transfer/subacct-transfer","title":"Create Subaccount Transfer","description":"Transfer funds between the parent and child (sub) accounts.","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-transfer-list":{"id":"v3/account-asset/transfer/subacct-transfer-list","title":"Get Master-Sub Transfer List","description":"Query subaccount transfer list","sidebar":"v3SideBar"},"v3/account-asset/transfer/transferable-coin-list":{"id":"v3/account-asset/transfer/transferable-coin-list","title":"Get Transferable Coin List","description":"Transferable coin list","sidebar":"v3SideBar"},"v3/account-asset/transfer/uni-transfer":{"id":"v3/account-asset/transfer/uni-transfer","title":"Create Universal Transfer","description":"Create Universal Transfer","sidebar":"v3SideBar"},"v3/account-asset/transfer/uni-transfer-list":{"id":"v3/account-asset/transfer/uni-transfer-list","title":"Get Universal Transfer List","description":"Query Universal Transfer List","sidebar":"v3SideBar"},"v3/account-asset/user/apikey-info":{"id":"v3/account-asset/user/apikey-info","title":"Get API Key Information","description":"Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user\'s api key are applicable.","sidebar":"v3SideBar"},"v3/account-asset/user/create-subuid":{"id":"v3/account-asset/user/create-subuid","title":"Create Sub UID","description":"Create a new sub user id. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/create-subuid-apikey":{"id":"v3/account-asset/user/create-subuid-apikey","title":"Create Sub UID API Key","description":"To create new API key for those newly created sub UID. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/froze-subuid":{"id":"v3/account-asset/user/froze-subuid","title":"Froze Sub UID","description":"Froze sub uid. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/modify-master-apikey":{"id":"v3/account-asset/user/modify-master-apikey","title":"Modify Master API Key","description":"Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/modify-sub-apikey":{"id":"v3/account-asset/user/modify-sub-apikey","title":"Modify Sub API Key","description":"Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master","sidebar":"v3SideBar"},"v3/account-asset/user/rm-master-apikey":{"id":"v3/account-asset/user/rm-master-apikey","title":"Delete Master API Key","description":"Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/rm-sub-apikey":{"id":"v3/account-asset/user/rm-sub-apikey","title":"Delete Sub API Key","description":"Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key","sidebar":"v3SideBar"},"v3/account-asset/user/subuid-list":{"id":"v3/account-asset/user/subuid-list","title":"Get Sub UID List","description":"Get all sub uid of master account. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/wallet-type":{"id":"v3/account-asset/user/wallet-type","title":"Get UID Wallet Type","description":"Get available wallet types for the master account or sub account","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/cancel-withdraw":{"id":"v3/account-asset/withdraw-deposit/cancel-withdraw","title":"Cancel withdrawal","description":"Cancel withdrawal","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/coin-info":{"id":"v3/account-asset/withdraw-deposit/coin-info","title":"Get Coin Information","description":"Query Coin Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/deplay-amount":{"id":"v3/account-asset/withdraw-deposit/deplay-amount","title":"Get Delay Withdraw Amount","description":"How can partial funds be subject to delayed withdrawal requests?","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/deposit-spec":{"id":"v3/account-asset/withdraw-deposit/deposit-spec","title":"Get Deposit Spec","description":"Query deposit spec.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/internal-deposit-record":{"id":"v3/account-asset/withdraw-deposit/internal-deposit-record","title":"Get Internal Deposit Records (across Bybit)","description":"Query deposit records through Bybit platform","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/master-deposit-addr":{"id":"v3/account-asset/withdraw-deposit/master-deposit-addr","title":"Get Master Acct Deposit Address Info","description":"Query Master Acct Deposit Address Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/master-deposit-record":{"id":"v3/account-asset/withdraw-deposit/master-deposit-record","title":"Get Deposit Records (on chain)","description":"Query Deposit Records","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/set-deposit-acct":{"id":"v3/account-asset/withdraw-deposit/set-deposit-acct","title":"Set Deposit Account","description":"Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/sub-deposit-addr":{"id":"v3/account-asset/withdraw-deposit/sub-deposit-addr","title":"Get Sub Acct Deposit Address Info","description":"Query Sub Acct Deposit Address Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/sub-deposit-record":{"id":"v3/account-asset/withdraw-deposit/sub-deposit-record","title":"Get Sub Deposit Records (on chain)","description":"Query Sub Deposit Records By Master Key","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/withdraw":{"id":"v3/account-asset/withdraw-deposit/withdraw","title":"Withdraw","description":"Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/withdraw-record":{"id":"v3/account-asset/withdraw-deposit/withdraw-record","title":"Get Withdraw Records","description":"Query Withdraw Records","sidebar":"v3SideBar"},"v3/copy-trade/enum":{"id":"v3/copy-trade/enum","title":"Enums Definitions","description":"accountType"},"v3/copy-trade/error":{"id":"v3/copy-trade/error","title":"Error Code","description":"|Code |Description |"},"v3/copy-trade/rate-limit":{"id":"v3/copy-trade/rate-limit","title":"Rate Limit","description":"IP Rate Limit"},"v3/copy-trade/rest-public/symbol-info":{"id":"v3/copy-trade/rest-public/symbol-info","title":"Instrument Info","description":"Get the spec of trading symbols"},"v3/copy-trade/rest-trade/account/transfer":{"id":"v3/copy-trade/rest-trade/account/transfer","title":"Transfer","description":"Transfer"},"v3/copy-trade/rest-trade/account/transfer-list":{"id":"v3/copy-trade/rest-trade/account/transfer-list","title":"Get Transfer History","description":"Get the transfer history of Copy-trade wallet"},"v3/copy-trade/rest-trade/account/wallet":{"id":"v3/copy-trade/rest-trade/account/wallet","title":"Get Wallet Balance","description":"Get CopyTrading Wallet Balance"},"v3/copy-trade/rest-trade/order/cancel-order":{"id":"v3/copy-trade/rest-trade/order/cancel-order","title":"Cancel Order","description":"Cancel Order"},"v3/copy-trade/rest-trade/order/close-order":{"id":"v3/copy-trade/rest-trade/order/close-order","title":"Create Close Position Order","description":"Create a specific close order"},"v3/copy-trade/rest-trade/order/order-list":{"id":"v3/copy-trade/rest-trade/order/order-list","title":"Get Orders","description":"Query orders"},"v3/copy-trade/rest-trade/order/place-order":{"id":"v3/copy-trade/rest-trade/order/place-order","title":"Create Order","description":"Create Order"},"v3/copy-trade/rest-trade/order/set-trading-stop":{"id":"v3/copy-trade/rest-trade/order/set-trading-stop","title":"Set Trading Stop","description":"Set Trading Stop"},"v3/copy-trade/rest-trade/position/close-position":{"id":"v3/copy-trade/rest-trade/position/close-position","title":"Close All Positions","description":"Close Position"},"v3/copy-trade/rest-trade/position/execution":{"id":"v3/copy-trade/rest-trade/position/execution","title":"Get Execution List (2 years)","description":"Query users\' execution list, sort by execTime in descending order"},"v3/copy-trade/rest-trade/position/position-info":{"id":"v3/copy-trade/rest-trade/position/position-info","title":"Position List","description":"Position List"},"v3/copy-trade/rest-trade/position/set-leverage":{"id":"v3/copy-trade/rest-trade/position/set-leverage","title":"Set Leverage","description":"Set Leverage"},"v3/copy-trade/wss-authentication":{"id":"v3/copy-trade/wss-authentication","title":"Connect","description":"Note that currently Copy Trading only supports USDT perpetual and the following endpoints only apply to USDT Perpetual"},"v3/copy-trade/wss-private/execution":{"id":"v3/copy-trade/wss-private/execution","title":"Execution","description":"Topic:"},"v3/copy-trade/wss-private/order":{"id":"v3/copy-trade/wss-private/order","title":"Order","description":"Topic:"},"v3/copy-trade/wss-private/position":{"id":"v3/copy-trade/wss-private/position","title":"Position","description":"Topic:"},"v3/copy-trade/wss-private/wallet":{"id":"v3/copy-trade/wss-private/wallet","title":"Wallet","description":"Topic:"},"v3/copy-trade/wss-public/kline":{"id":"v3/copy-trade/wss-public/kline","title":"Kline","description":"Interval supported:"},"v3/copy-trade/wss-public/liquidation":{"id":"v3/copy-trade/wss-public/liquidation","title":"Liquidation","description":"Get recent liquidation orders in Bybit."},"v3/copy-trade/wss-public/orderbook":{"id":"v3/copy-trade/wss-public/orderbook","title":"Orderbook","description":"Get different depth"},"v3/copy-trade/wss-public/tickers":{"id":"v3/copy-trade/wss-public/tickers","title":"Tickers","description":"Get latest information of the symbol"},"v3/copy-trade/wss-public/trade":{"id":"v3/copy-trade/wss-public/trade","title":"Public Trade","description":"Get recent public trades data in Bybit."},"v3/derivatives/enum":{"id":"v3/derivatives/enum","title":"Enums Definitions","description":"category","sidebar":"v3SideBar"},"v3/derivatives/error":{"id":"v3/derivatives/error","title":"Error Code","description":"Unified Margin","sidebar":"v3SideBar"},"v3/derivatives/rate-limit":{"id":"v3/derivatives/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/trading-fee":{"id":"v3/derivatives/rest-contract/account/trading-fee","title":"Get Trading Fee Rate","description":"Get user trading fee rate.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/wallet-balance":{"id":"v3/derivatives/rest-contract/account/wallet-balance","title":"Wallet Balance","description":"Get wallet balance, including Derivatives account and USDC account.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/wallet-fund-record":{"id":"v3/derivatives/rest-contract/account/wallet-fund-record","title":"Get Wallet Fund Records","description":"Get wallet fund records. This endpoint also shows exchanges from the Asset Exchange, where the types for the exchange are ExchangeOrderWithdraw and ExchangeOrderDeposit.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/cancel-all":{"id":"v3/derivatives/rest-contract/order/cancel-all","title":"Cancel All Order","description":"This endpoint enables to cancel all open orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/cancel-order":{"id":"v3/derivatives/rest-contract/order/cancel-order","title":"Cancel Order","description":"You could cancel those unfilled or partially filled orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/open-order":{"id":"v3/derivatives/rest-contract/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/order-list":{"id":"v3/derivatives/rest-contract/order/order-list","title":"Get Order List","description":"Query order list.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/place-order":{"id":"v3/derivatives/rest-contract/order/place-order","title":"Place Order","description":"- Market order: A traditional market order, which will be filled at the current optimal price. Only when the market","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/replace-order":{"id":"v3/derivatives/rest-contract/order/replace-order","title":"Replace Order","description":"You could modify those unfilled or partially filled orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/auto-margin":{"id":"v3/derivatives/rest-contract/position/auto-margin","title":"Set Auto Add Margin","description":"Turn on/off auto add position margin. To understand more, please read here","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/close-pnl":{"id":"v3/derivatives/rest-contract/position/close-pnl","title":"Get Closed PnL","description":"Query user\'s closed profit and loss records. The results are sorted by createdAt in descending order.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/confirm-mmr":{"id":"v3/derivatives/rest-contract/position/confirm-mmr","title":"Confirm New Risk Limit","description":"It is only applicable when the user is marked as only reducing positions (please see the isReduceOnly field in","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/cross-isolated-margin":{"id":"v3/derivatives/rest-contract/position/cross-isolated-margin","title":"Switch Cross/Isolated Margin","description":"Switch cross margin mode / isolated margin mode. To understand more, please read here","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/execution":{"id":"v3/derivatives/rest-contract/position/execution","title":"Get Execution List","description":"Query users\' execution list, sort by execTime in descending order. Support USDT Perpetual, Inverse Perpetual, Inverse Future, USDC Perpetual and USDC Option.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/leverage":{"id":"v3/derivatives/rest-contract/position/leverage","title":"Set Leverage","description":"Set the leverage.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/position-info":{"id":"v3/derivatives/rest-contract/position/position-info","title":"My Position","description":"Get real-time position data","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/position-mode":{"id":"v3/derivatives/rest-contract/position/position-mode","title":"Switch Position Mode","description":"It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/set-risk-limit":{"id":"v3/derivatives/rest-contract/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/tpsl-mode":{"id":"v3/derivatives/rest-contract/position/tpsl-mode","title":"Switch TP/SL Mode","description":"_To some extent, this endpoint is depreciated because now tpsl is based on order level. This API was used for position level","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/trading-stop":{"id":"v3/derivatives/rest-contract/position/trading-stop","title":"Set Trading Stop","description":"Set the take profit, stop loss or trailing stop for the position.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/delivery-price":{"id":"v3/derivatives/rest-public/delivery-price","title":"Option Delivery Price","description":"Get the delivery price for option","sidebar":"v3SideBar"},"v3/derivatives/rest-public/fund-rate-history":{"id":"v3/derivatives/rest-public/fund-rate-history","title":"Funding Rate History","description":"Get historical funding rate","sidebar":"v3SideBar"},"v3/derivatives/rest-public/index-kline":{"id":"v3/derivatives/rest-public/index-kline","title":"Index Price Kline","description":"Get index price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/instrument-info":{"id":"v3/derivatives/rest-public/instrument-info","title":"Instrument Info","description":"Get launched instruments information.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/kline":{"id":"v3/derivatives/rest-public/kline","title":"Kline","description":"Get kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/long-short-ratio":{"id":"v3/derivatives/rest-public/long-short-ratio","title":"Get Long Short Ratio","description":"HTTP Request","sidebar":"v3SideBar"},"v3/derivatives/rest-public/mark-kline":{"id":"v3/derivatives/rest-public/mark-kline","title":"Mark Price Kline","description":"Get mark price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/open-interest":{"id":"v3/derivatives/rest-public/open-interest","title":"Open Interest","description":"Get open interest of each symbol in Bybit","sidebar":"v3SideBar"},"v3/derivatives/rest-public/orderbook":{"id":"v3/derivatives/rest-public/orderbook","title":"Order Book","description":"Get order book data.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/premium-index-kline":{"id":"v3/derivatives/rest-public/premium-index-kline","title":"Premium Index Price Kline","description":"Get premium index price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/public-trade":{"id":"v3/derivatives/rest-public/public-trade","title":"Public Trading History","description":"Get recent public trading records in Bybit. You could download archived USDT contract trade records here.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/risk-limit":{"id":"v3/derivatives/rest-public/risk-limit","title":"Risk Limit","description":"Get risk limit","sidebar":"v3SideBar"},"v3/derivatives/rest-public/ticker-info":{"id":"v3/derivatives/rest-public/ticker-info","title":"Ticker Info","description":"Get all latest information of symbols.","sidebar":"v3SideBar"},"v3/derivatives/rest-unified/account/account-info":{"id":"v3/derivatives/rest-unified/account/account-info","title":"Account Info","description":"Query the configuration under the account."},"v3/derivatives/rest-unified/account/borrow-history":{"id":"v3/derivatives/rest-unified/account/borrow-history","title":"Borrow History","description":"HTTP Request"},"v3/derivatives/rest-unified/account/borrow-rate":{"id":"v3/derivatives/rest-unified/account/borrow-rate","title":"Get Borrow Rate","description":"HTTP Request"},"v3/derivatives/rest-unified/account/dcp":{"id":"v3/derivatives/rest-unified/account/dcp","title":"Set Disconnect Cancel All","description":"What is Disconnection Protect (DCP)?"},"v3/derivatives/rest-unified/account/exchange":{"id":"v3/derivatives/rest-unified/account/exchange","title":"Get Exchange Records","description":"Query the coin exchange records."},"v3/derivatives/rest-unified/account/get-dcp":{"id":"v3/derivatives/rest-unified/account/get-dcp","title":"Get DCP Info","description":"HTTP Request"},"v3/derivatives/rest-unified/account/get-mmp-state":{"id":"v3/derivatives/rest-unified/account/get-mmp-state","title":"Get MMP State","description":"HTTP Request"},"v3/derivatives/rest-unified/account/reset-mmp":{"id":"v3/derivatives/rest-unified/account/reset-mmp","title":"Reset MMP","description":"Once the mmp triggered, you can unfreeze the account by this endpoint"},"v3/derivatives/rest-unified/account/set-margin-mode":{"id":"v3/derivatives/rest-unified/account/set-margin-mode","title":"Set Margin Mode","description":"Default is the regular margin mode. This mode is valid for USDT Perp, USDC Perp and Option."},"v3/derivatives/rest-unified/account/set-mmp":{"id":"v3/derivatives/rest-unified/account/set-mmp","title":"Set MMP","description":"What is MMP?"},"v3/derivatives/rest-unified/account/transaction-log":{"id":"v3/derivatives/rest-unified/account/transaction-log","title":"Transaction Log","description":"Query transaction logs in Unified account."},"v3/derivatives/rest-unified/account/upgrade-unified-account":{"id":"v3/derivatives/rest-unified/account/upgrade-unified-account","title":"Upgrade To Unified Margin Account","description":"Upgrade to unified margin account (UMA)"},"v3/derivatives/rest-unified/account/wallet-balance":{"id":"v3/derivatives/rest-unified/account/wallet-balance","title":"Wallet Balance","description":"Get wallet balance"},"v3/derivatives/rest-unified/order/batch-cancel":{"id":"v3/derivatives/rest-unified/order/batch-cancel","title":"Batch Cancel Order","description":"This endpoint provides the batch order mode to cancel a bunch of open orders."},"v3/derivatives/rest-unified/order/batch-place":{"id":"v3/derivatives/rest-unified/order/batch-place","title":"Batch Place Order","description":"This endpoint provides the batch order mode to place a bunch of orders."},"v3/derivatives/rest-unified/order/batch-replace":{"id":"v3/derivatives/rest-unified/order/batch-replace","title":"Batch Replace Order","description":"This endpoint provides the batch order mode to replace a bunch of open orders."},"v3/derivatives/rest-unified/order/cancel-all":{"id":"v3/derivatives/rest-unified/order/cancel-all","title":"Cancel All Orders","description":"This endpoint enables to cancel all open orders."},"v3/derivatives/rest-unified/order/cancel-order":{"id":"v3/derivatives/rest-unified/order/cancel-order","title":"Cancel Order","description":"You could cancel those unfilled or partially filled orders."},"v3/derivatives/rest-unified/order/open-order":{"id":"v3/derivatives/rest-unified/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time."},"v3/derivatives/rest-unified/order/order-list":{"id":"v3/derivatives/rest-unified/order/order-list","title":"Get Order List","description":"Query order list."},"v3/derivatives/rest-unified/order/place-order":{"id":"v3/derivatives/rest-unified/order/place-order","title":"Place Order","description":"- Market order: A traditional market order, which will be filled at the current optimal price. Only when the market"},"v3/derivatives/rest-unified/order/replace-order":{"id":"v3/derivatives/rest-unified/order/replace-order","title":"Replace Order","description":"You could modify those unfilled or partially filled orders."},"v3/derivatives/rest-unified/position/execution-list":{"id":"v3/derivatives/rest-unified/position/execution-list","title":"Get Execution Record","description":"Query users\' execution records, sort by execTime in descending order"},"v3/derivatives/rest-unified/position/full-partial-tpsl":{"id":"v3/derivatives/rest-unified/position/full-partial-tpsl","title":"Switch TP/SL Mode","description":"Set take profit / stop loss mode of the position, such as FULL TP/SL mode or PARTIAL TP/SL mode"},"v3/derivatives/rest-unified/position/leverage":{"id":"v3/derivatives/rest-unified/position/leverage","title":"Set Leverage","description":"Set the leverage."},"v3/derivatives/rest-unified/position/option-delivery":{"id":"v3/derivatives/rest-unified/position/option-delivery","title":"Get Option Delivery Record","description":"Query option delivery records, sort by deliveryTime in descending order"},"v3/derivatives/rest-unified/position/position-info":{"id":"v3/derivatives/rest-unified/position/position-info","title":"My Position","description":"Get real-time position data"},"v3/derivatives/rest-unified/position/set-risk-limit":{"id":"v3/derivatives/rest-unified/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements."},"v3/derivatives/rest-unified/position/trading-stop":{"id":"v3/derivatives/rest-unified/position/trading-stop","title":"Set Trading Stop","description":"Pass the following parameters, then the system will create conditional orders. If the position is closed, the system will cancel these orders, and adjust the position size."},"v3/derivatives/rest-unified/position/usdc-settlement":{"id":"v3/derivatives/rest-unified/position/usdc-settlement","title":"Get USDC Perpetual Settlement","description":"Query session settlement records of USDC perpetual"},"v3/derivatives/wss-authentication":{"id":"v3/derivatives/wss-authentication","title":"Connect","description":"Base endpoints:","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/execution":{"id":"v3/derivatives/wss-contract/execution","title":"Execution","description":"Subscribe to the execution stream to see when an open order gets filled or partially filled.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/order":{"id":"v3/derivatives/wss-contract/order","title":"Order","description":"Subscribe to the order stream to see new orders, when an order\'s order status changes, etc.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/position":{"id":"v3/derivatives/wss-contract/position","title":"Position","description":"Subscribe to the position stream to see changes to your position size, position setting changes, etc.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/wallet":{"id":"v3/derivatives/wss-contract/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time.","sidebar":"v3SideBar"},"v3/derivatives/wss-public/kline":{"id":"v3/derivatives/wss-public/kline","title":"Kline","description":"Covers: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future","sidebar":"v3SideBar"},"v3/derivatives/wss-public/liquidation":{"id":"v3/derivatives/wss-public/liquidation","title":"Liquidation","description":"Get recent liquidation orders in Bybit.","sidebar":"v3SideBar"},"v3/derivatives/wss-public/orderbook":{"id":"v3/derivatives/wss-public/orderbook","title":"Orderbook","description":"Get different depth","sidebar":"v3SideBar"},"v3/derivatives/wss-public/tickers":{"id":"v3/derivatives/wss-public/tickers","title":"Tickers","description":"Cover: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future, Option","sidebar":"v3SideBar"},"v3/derivatives/wss-public/trade":{"id":"v3/derivatives/wss-public/trade","title":"Public Trade","description":"Get recent public trades data in Bybit.","sidebar":"v3SideBar"},"v3/derivatives/wss-unified/execution":{"id":"v3/derivatives/wss-unified/execution","title":"Execution","description":"Subscribe to the execution stream. Will not push funding payments unless they occur on a USDT perpetual, eg BTCUSDT."},"v3/derivatives/wss-unified/greek":{"id":"v3/derivatives/wss-unified/greek","title":"Greek","description":"Subscribe to the user greeks stream, option only."},"v3/derivatives/wss-unified/order":{"id":"v3/derivatives/wss-unified/order","title":"Order","description":"Subscribe to the order stream to see new orders, when an order\'s order status changes, etc."},"v3/derivatives/wss-unified/position":{"id":"v3/derivatives/wss-unified/position","title":"Position","description":"Subscribe to the position stream to see changes to your position size, position setting changes, etc."},"v3/derivatives/wss-unified/wallet":{"id":"v3/derivatives/wss-unified/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time."},"v3/intro":{"id":"v3/intro","title":"Introduction","description":"Bybit V3 API allow users to select different collections to build their API model.","sidebar":"v3SideBar"},"v3/server-time":{"id":"v3/server-time","title":"Bybit Server Time","description":"Get the Bybit server timestamp","sidebar":"v3SideBar"},"v3/smp":{"id":"v3/smp","title":"Self Match Prevention","description":"What is SMP?","sidebar":"v3SideBar"},"v3/spot/enum":{"id":"v3/spot/enum","title":"Enums Definitions","description":"side","sidebar":"v3SideBar"},"v3/spot/error":{"id":"v3/spot/error","title":"Error Code","description":"|Code |Description |","sidebar":"v3SideBar"},"v3/spot/rate-limit":{"id":"v3/spot/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/spot/rest-etp/asset-info":{"id":"v3/spot/rest-etp/asset-info","title":"All Asset Info","description":"It is a public endpoint, and no need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-etp/market-info":{"id":"v3/spot/rest-etp/market-info","title":"Market Info","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/purchase":{"id":"v3/spot/rest-etp/purchase","title":"Purchase","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/purchase-redeem-history":{"id":"v3/spot/rest-etp/purchase-redeem-history","title":"Purchase & Redeem History","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/redeem":{"id":"v3/spot/rest-etp/redeem","title":"Redeem","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/loan-info":{"id":"v3/spot/rest-institution-loan/loan-info","title":"Get Loan Info","description":"Get loan orders information","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/ltv":{"id":"v3/spot/rest-institution-loan/ltv","title":"Get LTV","description":"Get LTV. Please head here to get LTV if this API returns empty data.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/margin-coin-info":{"id":"v3/spot/rest-institution-loan/margin-coin-info","title":"Margin Coin Info","description":"This is a public endpoint, so it does not need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/margin-product-info":{"id":"v3/spot/rest-institution-loan/margin-product-info","title":"Get Margin Product Info","description":"This is a public endpoint, so it does not need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/repay-info":{"id":"v3/spot/rest-institution-loan/repay-info","title":"Get Repay Info","description":"Get repaid order information. Authentication needed.","sidebar":"v3SideBar"},"v3/spot/rest-public/best-bid-ask":{"id":"v3/spot/rest-public/best-bid-ask","title":"Best Bid/Ask Price","description":"If symbol is not specified, the best order price from all symbols will be returned","sidebar":"v3SideBar"},"v3/spot/rest-public/instrument-info":{"id":"v3/spot/rest-public/instrument-info","title":"Instrument Info","description":"Get the spec of symbol information","sidebar":"v3SideBar"},"v3/spot/rest-public/kline":{"id":"v3/spot/rest-public/kline","title":"Kline","description":"It only returns the results from latest 1000 candles regardless of what interval is specified","sidebar":"v3SideBar"},"v3/spot/rest-public/last-trade-price":{"id":"v3/spot/rest-public/last-trade-price","title":"Last Traded Price","description":"If symbol is not specified, the price from all symbols will be returned","sidebar":"v3SideBar"},"v3/spot/rest-public/merge-orderbook":{"id":"v3/spot/rest-public/merge-orderbook","title":"Merged Order Book","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/orderbook":{"id":"v3/spot/rest-public/orderbook","title":"Order Book","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/public-trade":{"id":"v3/spot/rest-public/public-trade","title":"Public Trading Records","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/ticker-info":{"id":"v3/spot/rest-public/ticker-info","title":"Tickers","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/account-info":{"id":"v3/spot/rest-spot-margin/account-info","title":"Get Loan Account Info","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrow":{"id":"v3/spot/rest-spot-margin/borrow","title":"Borrow","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrow-info":{"id":"v3/spot/rest-spot-margin/borrow-info","title":"Get Borrow Order Detail","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrowable-data":{"id":"v3/spot/rest-spot-margin/borrowable-data","title":"Get Borrowable Coin Info","description":"This is public endpoint, so do not need an authentication","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/interest-quota":{"id":"v3/spot/rest-spot-margin/interest-quota","title":"Get Interest & Quota","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/margin-data":{"id":"v3/spot/rest-spot-margin/margin-data","title":"Get Margin Coin Info","description":"This is public endpoint, so do not need an authentication","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/repay":{"id":"v3/spot/rest-spot-margin/repay","title":"Repay","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/repay-history":{"id":"v3/spot/rest-spot-margin/repay-history","title":"Get Repayment Order Detail","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/switch-mode":{"id":"v3/spot/rest-spot-margin/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v3SideBar"},"v3/spot/rest-spot/batch-cancel":{"id":"v3/spot/rest-spot/batch-cancel","title":"Batch Cancel Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/batch-cancel-by-id":{"id":"v3/spot/rest-spot/batch-cancel-by-id","title":"Batch Cancel Order By Id","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/cancel-order":{"id":"v3/spot/rest-spot/cancel-order","title":"Cancel Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/get-order":{"id":"v3/spot/rest-spot/get-order","title":"Get Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/open-order":{"id":"v3/spot/rest-spot/open-order","title":"Open Orders","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/order-history":{"id":"v3/spot/rest-spot/order-history","title":"Order History","description":"- If startTime and endTime are both not specified, it returns last 7 days records by default. 3 days records for institutional clients.","sidebar":"v3SideBar"},"v3/spot/rest-spot/place-order":{"id":"v3/spot/rest-spot/place-order","title":"Place Order","description":"Do not use the duplicate orderLinkId in normal order & TP/SL order","sidebar":"v3SideBar"},"v3/spot/rest-spot/trade-history":{"id":"v3/spot/rest-spot/trade-history","title":"Trade History","description":"* If startTime is not specified, you can only query for records in the last 7 days.","sidebar":"v3SideBar"},"v3/spot/wallet":{"id":"v3/spot/wallet","title":"Get Wallet Balance","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/wss-authentication":{"id":"v3/spot/wss-authentication","title":"Connect","description":"Note that the following endpoints only apply to Spot. To listen to other websockets, go to:","sidebar":"v3SideBar"},"v3/spot/wss-private/order":{"id":"v3/spot/wss-private/order","title":"Order","description":"This topic pushes order information\uff0cavg.filledPrice = Z / z","sidebar":"v3SideBar"},"v3/spot/wss-private/outbound-account-info":{"id":"v3/spot/wss-private/outbound-account-info","title":"Wallet","description":"This topic pushes spot wallet information","sidebar":"v3SideBar"},"v3/spot/wss-private/stop-order":{"id":"v3/spot/wss-private/stop-order","title":"Stop Order","description":"This topic pushes conditional order, TP/SL order information placed by web/app channel, and TP/SL order information placed by open api channel. It\'ll be triggered as long as order status is changed","sidebar":"v3SideBar"},"v3/spot/wss-private/ticket-info":{"id":"v3/spot/wss-private/ticket-info","title":"Execution","description":"This topic pushes filled trades information. When an order is filled, you will receive two messages: one from ticketInfo, and one from order / stopOrder","sidebar":"v3SideBar"},"v3/spot/wss-public/bookticker":{"id":"v3/spot/wss-public/bookticker","title":"Bookticker","description":"Best bid price and best ask price","sidebar":"v3SideBar"},"v3/spot/wss-public/kline":{"id":"v3/spot/wss-public/kline","title":"Kline","description":"Subscribe the kline stream. Please find desired kline interval here.","sidebar":"v3SideBar"},"v3/spot/wss-public/orderbook":{"id":"v3/spot/wss-public/orderbook","title":"Orderbook","description":"Market depth data for a trading pair:","sidebar":"v3SideBar"},"v3/spot/wss-public/tickers":{"id":"v3/spot/wss-public/tickers","title":"Tickers","description":"The 24-hr statistics of a trading pair.","sidebar":"v3SideBar"},"v3/spot/wss-public/trade":{"id":"v3/spot/wss-public/trade","title":"Public trade","description":"This topic pushes raw trade information; each trade has a unique buyer and seller.","sidebar":"v3SideBar"},"v3/tax/data-explain":{"id":"v3/tax/data-explain","title":"Data Explanation","description":"Trade History","sidebar":"v3SideBar"},"v3/tax/data-export":{"id":"v3/tax/data-export","title":"Retrieve Data Export","description":"Retrieve data export","sidebar":"v3SideBar"},"v3/tax/enum":{"id":"v3/tax/enum","title":"Enums Definitions","description":"ReportType","sidebar":"v3SideBar"},"v3/tax/register-time":{"id":"v3/tax/register-time","title":"Get User Register Date","description":"Get User Register Date","sidebar":"v3SideBar"},"v3/tax/report-status":{"id":"v3/tax/report-status","title":"Get Export Report Status","description":"Get Export Report Status","sidebar":"v3SideBar"},"v3/tax/request-report":{"id":"v3/tax/request-report","title":"Request Export Report","description":"Request to export report","sidebar":"v3SideBar"},"v5/abandon/enable-unitransfer-subuid":{"id":"v5/abandon/enable-unitransfer-subuid","title":"Enable Universal Transfer for Sub UID","description":"You no longer need to configure transferable sub UIDs. Now, all sub UIDs are automatically enabled for universal transfer.","sidebar":"v5SideBar"},"v5/abandon/ltv":{"id":"v5/abandon/ltv","title":"Get LTV","description":"HTTP Request","sidebar":"v5SideBar"},"v5/abandon/margin-coin-info":{"id":"v5/abandon/margin-coin-info","title":"Get Margin Coin Info","description":"HTTP Request","sidebar":"v5SideBar"},"v5/account/account-info":{"id":"v5/account/account-info","title":"Get Account Info","description":"Query the margin mode configuration of the account.","sidebar":"v5SideBar"},"v5/account/borrow-history":{"id":"v5/account/borrow-history","title":"Get Borrow History","description":"Get interest records, sorted in reverse order of creation time.","sidebar":"v5SideBar"},"v5/account/coin-greeks":{"id":"v5/account/coin-greeks","title":"Get Coin Greeks","description":"Get current account Greeks information","sidebar":"v5SideBar"},"v5/account/collateral-info":{"id":"v5/account/collateral-info","title":"Get Collateral Info","description":"Get the collateral information of the current unified margin account, including loan interest rate, loanable amount, collateral conversion rate, whether it can be mortgaged as margin, etc.","sidebar":"v5SideBar"},"v5/account/fee-rate":{"id":"v5/account/fee-rate","title":"Get Fee Rate","description":"Get the trading fee rate.","sidebar":"v5SideBar"},"v5/account/get-mmp-state":{"id":"v5/account/get-mmp-state","title":"Get MMP State","description":"HTTP Request","sidebar":"v5SideBar"},"v5/account/reset-mmp":{"id":"v5/account/reset-mmp","title":"Reset MMP","description":"* Once the mmp triggered, you can unfreeze the account by this endpoint, then qtyLimit and deltaLimit will be reset to 0.","sidebar":"v5SideBar"},"v5/account/set-collateral":{"id":"v5/account/set-collateral","title":"Set Collateral Coin","description":"You can decide whether the assets in the Unified account needs to be collateral coins.","sidebar":"v5SideBar"},"v5/account/set-margin-mode":{"id":"v5/account/set-margin-mode","title":"Set Margin Mode","description":"Default is regular margin mode","sidebar":"v5SideBar"},"v5/account/set-mmp":{"id":"v5/account/set-mmp","title":"Set MMP","description":"What is MMP?","sidebar":"v5SideBar"},"v5/account/transaction-log":{"id":"v5/account/transaction-log","title":"Get Transaction Log","description":"Query transaction logs in Unified account.","sidebar":"v5SideBar"},"v5/account/upgrade-unified-account":{"id":"v5/account/upgrade-unified-account","title":"Upgrade to Unified Account","description":"Upgrade Unified Account","sidebar":"v5SideBar"},"v5/account/wallet-balance":{"id":"v5/account/wallet-balance","title":"Get Wallet Balance","description":"Obtain wallet balance, query asset information of each currency, and account risk rate information. By default, currency","sidebar":"v5SideBar"},"v5/announcement":{"id":"v5/announcement","title":"Get Announcement","description":"HTTP Request","sidebar":"v5SideBar"},"v5/asset/account-coin-balance":{"id":"v5/asset/account-coin-balance","title":"Get Single Coin Balance","description":"Query the balance of a specific coin in a specific account type. Supports querying sub UID\'s balance.","sidebar":"v5SideBar"},"v5/asset/all-balance":{"id":"v5/asset/all-balance","title":"Get All Coins Balance","description":"You could get all coin balance of all account types under the master account, and sub account.","sidebar":"v5SideBar"},"v5/asset/asset-info":{"id":"v5/asset/asset-info","title":"Get Asset Info","description":"Query asset information","sidebar":"v5SideBar"},"v5/asset/cancel-withdraw":{"id":"v5/asset/cancel-withdraw","title":"Cancel Withdrawal","description":"Cancel the withdrawal","sidebar":"v5SideBar"},"v5/asset/coin-info":{"id":"v5/asset/coin-info","title":"Get Coin Info","description":"Query coin information, including chain information, withdraw and deposit status.","sidebar":"v5SideBar"},"v5/asset/create-inter-transfer":{"id":"v5/asset/create-inter-transfer","title":"Create Internal Transfer","description":"Create the internal transfer between different account types under the same UID.","sidebar":"v5SideBar"},"v5/asset/delay-amount":{"id":"v5/asset/delay-amount","title":"Get Withdrawable Amount","description":"How can partial funds be subject to delayed withdrawal requests?","sidebar":"v5SideBar"},"v5/asset/delivery":{"id":"v5/asset/delivery","title":"Get Delivery Record","description":"Query delivery records of USDC futures and Options, sorted by deliveryTime in descending order","sidebar":"v5SideBar"},"v5/asset/deposit-coin-spec":{"id":"v5/asset/deposit-coin-spec","title":"Get Allowed Deposit Coin Info","description":"Query allowed deposit coin information. To find out paired chain of coin, please refer coin info api.","sidebar":"v5SideBar"},"v5/asset/deposit-record":{"id":"v5/asset/deposit-record","title":"Get Deposit Records (on-chain)","description":"Query deposit records.","sidebar":"v5SideBar"},"v5/asset/exchange":{"id":"v5/asset/exchange","title":"Get Coin Exchange Records","description":"Query the coin exchange records.","sidebar":"v5SideBar"},"v5/asset/inter-transfer-list":{"id":"v5/asset/inter-transfer-list","title":"Get Internal Transfer Records","description":"Query the internal transfer records between different account types under the same UID.","sidebar":"v5SideBar"},"v5/asset/internal-deposit-record":{"id":"v5/asset/internal-deposit-record","title":"Get Internal Deposit Records (off-chain)","description":"Query deposit records within the Bybit platform. These transactions are not on the blockchain.","sidebar":"v5SideBar"},"v5/asset/master-deposit-addr":{"id":"v5/asset/master-deposit-addr","title":"Get Master Deposit Address","description":"Query the deposit address information of MASTER account.","sidebar":"v5SideBar"},"v5/asset/set-deposit-acct":{"id":"v5/asset/set-deposit-acct","title":"Set Deposit Account","description":"Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI","sidebar":"v5SideBar"},"v5/asset/settlement":{"id":"v5/asset/settlement","title":"Get USDC Session Settlement","description":"Query session settlement records of USDC perpetual and futures","sidebar":"v5SideBar"},"v5/asset/sub-deposit-addr":{"id":"v5/asset/sub-deposit-addr","title":"Get Sub Deposit Address","description":"Query the deposit address information of SUB account.","sidebar":"v5SideBar"},"v5/asset/sub-deposit-record":{"id":"v5/asset/sub-deposit-record","title":"Get Sub Deposit Records (on-chain)","description":"Query subaccount\'s deposit records by main UID\'s API key.","sidebar":"v5SideBar"},"v5/asset/sub-uid-list":{"id":"v5/asset/sub-uid-list","title":"Get Sub UID","description":"Query the sub UIDs under a main UID","sidebar":"v5SideBar"},"v5/asset/transferable-coin":{"id":"v5/asset/transferable-coin","title":"Get Transferable Coin","description":"Query the transferable coin list between each account type","sidebar":"v5SideBar"},"v5/asset/unitransfer":{"id":"v5/asset/unitransfer","title":"Create Universal Transfer","description":"Transfer between sub-sub or main-sub.","sidebar":"v5SideBar"},"v5/asset/unitransfer-list":{"id":"v5/asset/unitransfer-list","title":"Get Universal Transfer Records","description":"Query universal transfer records","sidebar":"v5SideBar"},"v5/asset/withdraw":{"id":"v5/asset/withdraw","title":"Withdraw","description":"Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.","sidebar":"v5SideBar"},"v5/asset/withdraw-record":{"id":"v5/asset/withdraw-record","title":"Get Withdrawal Records","description":"Query withdrawal records.","sidebar":"v5SideBar"},"v5/backup/set-pledge-token":{"id":"v5/backup/set-pledge-token","title":"Set Pledge Token","description":"Set Pledge Token in cross margin"},"v5/broker/earning":{"id":"v5/broker/earning","title":"Get Broker Earning","description":"* Use exchange broker master account to query","sidebar":"v5SideBar"},"v5/c2c-lend/account-info":{"id":"v5/c2c-lend/account-info","title":"Get Lending Account Info","description":"HTTP Request","sidebar":"v5SideBar"},"v5/c2c-lend/cancel-redeem":{"id":"v5/c2c-lend/cancel-redeem","title":"Cancel Redeem","description":"Cancel the withdrawal operation.","sidebar":"v5SideBar"},"v5/c2c-lend/coin-info":{"id":"v5/c2c-lend/coin-info","title":"Get Lending Coin Info","description":"Get the basic information of lending coins","sidebar":"v5SideBar"},"v5/c2c-lend/deposit":{"id":"v5/c2c-lend/deposit","title":"Deposit Funds","description":"Lending funds to Bybit asset pool","sidebar":"v5SideBar"},"v5/c2c-lend/order-record":{"id":"v5/c2c-lend/order-record","title":"Get Order Records","description":"Get lending or redeem history","sidebar":"v5SideBar"},"v5/c2c-lend/redeem":{"id":"v5/c2c-lend/redeem","title":"Redeem Funds","description":"Withdraw funds from the Bybit asset pool.","sidebar":"v5SideBar"},"v5/copytrade":{"id":"v5/copytrade","title":"How To Start Copy Trading","description":"Become A Master Trader","sidebar":"v5SideBar"},"v5/enum":{"id":"v5/enum","title":"Enums Definitions","description":"locale","sidebar":"v5SideBar"},"v5/error":{"id":"v5/error","title":"Error Codes","description":"HTTP Code","sidebar":"v5SideBar"},"v5/guide":{"id":"v5/guide","title":"Integration Guidance","description":"To learn more about the V5 API, please read the Introduction.","sidebar":"v5SideBar"},"v5/intro":{"id":"v5/intro","title":"Introduction","description":"Overview","sidebar":"v5SideBar"},"v5/lt/leverage-token-info":{"id":"v5/lt/leverage-token-info","title":"Get Leverage Token Info","description":"Query leverage token information","sidebar":"v5SideBar"},"v5/lt/leverage-token-reference":{"id":"v5/lt/leverage-token-reference","title":"Get Leveraged Token Market","description":"Get leverage token market information","sidebar":"v5SideBar"},"v5/lt/order-record":{"id":"v5/lt/order-record","title":"Get Purchase/Redemption Records","description":"Get purchase or redeem history","sidebar":"v5SideBar"},"v5/lt/purchase":{"id":"v5/lt/purchase","title":"Purchase","description":"Purchase levearge token","sidebar":"v5SideBar"},"v5/lt/redeem":{"id":"v5/lt/redeem","title":"Redeem","description":"Redeem leverage token","sidebar":"v5SideBar"},"v5/market/delivery-price":{"id":"v5/market/delivery-price","title":"Get Delivery Price","description":"Get the delivery price.","sidebar":"v5SideBar"},"v5/market/history-fund-rate":{"id":"v5/market/history-fund-rate","title":"Get Funding Rate History","description":"Query for historical funding rates. Each symbol has a different funding interval. For example, if the interval is 8 hours and the current time is UTC 12, then it returns the last funding rate, which settled at UTC 8.","sidebar":"v5SideBar"},"v5/market/index-kline":{"id":"v5/market/index-kline","title":"Get Index Price Kline","description":"Query for historical index price klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/instrument":{"id":"v5/market/instrument","title":"Get Instruments Info","description":"Query for the instrument specification of online trading pairs.","sidebar":"v5SideBar"},"v5/market/insurance":{"id":"v5/market/insurance","title":"Get Insurance","description":"Query for Bybit insurance pool data (BTC/USDT/USDC etc). The data is updated every 24 hours.","sidebar":"v5SideBar"},"v5/market/iv":{"id":"v5/market/iv","title":"Get Historical Volatility","description":"Query option historical volatility","sidebar":"v5SideBar"},"v5/market/kline":{"id":"v5/market/kline","title":"Get Kline","description":"Query for historical klines (also known as candles/candlesticks). Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/long-short-ratio":{"id":"v5/market/long-short-ratio","title":"Get Long Short Ratio","description":"HTTP Request","sidebar":"v5SideBar"},"v5/market/mark-kline":{"id":"v5/market/mark-kline","title":"Get Mark Price Kline","description":"Query for historical mark price klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/open-interest":{"id":"v5/market/open-interest","title":"Get Open Interest","description":"Get the open interest of each symbol.","sidebar":"v5SideBar"},"v5/market/orderbook":{"id":"v5/market/orderbook","title":"Get Orderbook","description":"Query for orderbook depth data.","sidebar":"v5SideBar"},"v5/market/preimum-index-kline":{"id":"v5/market/preimum-index-kline","title":"Get Premium Index Price Kline","description":"Query for historical premium index klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/recent-trade":{"id":"v5/market/recent-trade","title":"Get Public Recent Trading History","description":"Query recent public trading data in Bybit.","sidebar":"v5SideBar"},"v5/market/risk-limit":{"id":"v5/market/risk-limit","title":"Get Risk Limit","description":"Query for the risk limit.","sidebar":"v5SideBar"},"v5/market/tickers":{"id":"v5/market/tickers","title":"Get Tickers","description":"Query for the latest price snapshot, best bid/ask price, and trading volume in the last 24 hours.","sidebar":"v5SideBar"},"v5/market/time":{"id":"v5/market/time","title":"Get Bybit Server Time","description":"HTTP Request","sidebar":"v5SideBar"},"v5/order/amend-order":{"id":"v5/order/amend-order","title":"Amend Order","description":"Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option","sidebar":"v5SideBar"},"v5/order/batch-amend":{"id":"v5/order/batch-amend","title":"Batch Amend Order","description":"Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)","sidebar":"v5SideBar"},"v5/order/batch-cancel":{"id":"v5/order/batch-cancel","title":"Batch Cancel Order","description":"This endpoint allows you to cancel more than one open order in a single request.","sidebar":"v5SideBar"},"v5/order/batch-place":{"id":"v5/order/batch-place","title":"Batch Place Order","description":"Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)","sidebar":"v5SideBar"},"v5/order/cancel-all":{"id":"v5/order/cancel-all","title":"Cancel All Orders","description":"Cancel all open orders","sidebar":"v5SideBar"},"v5/order/cancel-order":{"id":"v5/order/cancel-order","title":"Cancel Order","description":"Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options","sidebar":"v5SideBar"},"v5/order/create-order":{"id":"v5/order/create-order","title":"Place Order","description":"This endpoint supports to create the order for spot, spot margin, USDT perpetual, USDC perpetual, USDC futures, inverse futures and options.","sidebar":"v5SideBar"},"v5/order/dcp":{"id":"v5/order/dcp","title":"Set Disconnect Cancel All","description":"Covers: Option (Unified Account)","sidebar":"v5SideBar"},"v5/order/open-order":{"id":"v5/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time. To query older order records, please use the order history interface.","sidebar":"v5SideBar"},"v5/order/order-list":{"id":"v5/order/order-list","title":"Get Order History","description":"Query order history. As order creation/cancellation is asynchronous, the data returned from this endpoint may delay. If you want to get","sidebar":"v5SideBar"},"v5/order/spot-borrow-quota":{"id":"v5/order/spot-borrow-quota","title":"Get Borrow Quota (Spot)","description":"Query the available balance for Spot trading and Margin trading","sidebar":"v5SideBar"},"v5/otc/bind-uid":{"id":"v5/otc/bind-uid","title":"Bind Or Unbind UID","description":"For the OTC loan product, you can bind new UID to risk unit or unbind UID out from risk unit.","sidebar":"v5SideBar"},"v5/otc/loan-info":{"id":"v5/otc/loan-info","title":"Get Loan Orders","description":"Get loan orders information","sidebar":"v5SideBar"},"v5/otc/ltv-convert":{"id":"v5/otc/ltv-convert","title":"Get LTV","description":"Get LTV","sidebar":"v5SideBar"},"v5/otc/margin-coin-convert-info":{"id":"v5/otc/margin-coin-convert-info","title":"Get Margin Coin Info","description":"* This endpoint can be queried without api key and secret, then it returns public margin data","sidebar":"v5SideBar"},"v5/otc/margin-product-info":{"id":"v5/otc/margin-product-info","title":"Get Product Info","description":"* This endpoint can be queried without api key and secret, then it returns public product data","sidebar":"v5SideBar"},"v5/otc/repay-info":{"id":"v5/otc/repay-info","title":"Get Repay Orders","description":"Get repaid order information","sidebar":"v5SideBar"},"v5/position/auto-add-margin":{"id":"v5/position/auto-add-margin","title":"Set Auto Add Margin","description":"Turn on/off auto-add-margin for isolated margin position","sidebar":"v5SideBar"},"v5/position/close-pnl":{"id":"v5/position/close-pnl","title":"Get Closed PnL","description":"Query user\'s closed profit and loss records. The results are sorted by createdTime in descending order.","sidebar":"v5SideBar"},"v5/position/confirm-mmr":{"id":"v5/position/confirm-mmr","title":"Confirm New Risk Limit","description":"It is only applicable when the user is marked as only reducing positions (please see the isReduceOnly field in","sidebar":"v5SideBar"},"v5/position/cross-isolate":{"id":"v5/position/cross-isolate","title":"Switch Cross/Isolated Margin","description":"Select cross margin mode or isolated margin mode per symbol level","sidebar":"v5SideBar"},"v5/position/execution":{"id":"v5/position/execution","title":"Get Execution","description":"Query users\' execution records, sorted by execTime in descending order. However, for Classic spot, they are sorted by execId in descending order.","sidebar":"v5SideBar"},"v5/position/leverage":{"id":"v5/position/leverage","title":"Set Leverage","description":"Set the leverage","sidebar":"v5SideBar"},"v5/position/manual-add-margin":{"id":"v5/position/manual-add-margin","title":"Add Or Reduce Margin","description":"Manually add or reduce margin for isolated margin position","sidebar":"v5SideBar"},"v5/position/position":{"id":"v5/position/position","title":"Get Position Info","description":"Query real-time position data, such as position size, cumulative realizedPNL.","sidebar":"v5SideBar"},"v5/position/position-mode":{"id":"v5/position/position-mode","title":"Switch Position Mode","description":"It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.","sidebar":"v5SideBar"},"v5/position/set-risk-limit":{"id":"v5/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements. If you want to hold a bigger position size, you need more margin. This interface can set the risk limit of a single position. If the order exceeds the current risk limit when placing an order, it will be rejected. Click here to learn more about risk limit.","sidebar":"v5SideBar"},"v5/position/tpsl-mode":{"id":"v5/position/tpsl-mode","title":"Set TP/SL Mode","description":"_To some extent, this endpoint is depreciated because now tpsl is based on order level. This API was used for position level","sidebar":"v5SideBar"},"v5/position/trading-stop":{"id":"v5/position/trading-stop","title":"Set Trading Stop","description":"Set the take profit, stop loss or trailing stop for the position.","sidebar":"v5SideBar"},"v5/pre-upgrade/close-pnl":{"id":"v5/pre-upgrade/close-pnl","title":"Get Pre-upgrade Closed PnL","description":"Query user\'s closed profit and loss records from before you upgraded the account to a Unified account. The results are sorted by createdTime in descending order.","sidebar":"v5SideBar"},"v5/pre-upgrade/delivery":{"id":"v5/pre-upgrade/delivery","title":"Get Pre-upgrade Option Delivery Record","description":"Query delivery records of Option before you upgraded the account to a Unified account, sorted by deliveryTime in descending order","sidebar":"v5SideBar"},"v5/pre-upgrade/execution":{"id":"v5/pre-upgrade/execution","title":"Get Pre-upgrade Trade History","description":"Get users\' execution records which occurred before you upgraded the account to a Unified account, sorted by execTime in descending order","sidebar":"v5SideBar"},"v5/pre-upgrade/order-list":{"id":"v5/pre-upgrade/order-list","title":"Get Pre-upgrade Order History","description":"After the account is upgraded to a Unified account, you can get the orders which occurred before the upgrade.","sidebar":"v5SideBar"},"v5/pre-upgrade/settlement":{"id":"v5/pre-upgrade/settlement","title":"Get Pre-upgrade USDC Session Settlement","description":"Query session settlement records of USDC perpetual before you upgrade the account to Unified account.","sidebar":"v5SideBar"},"v5/pre-upgrade/transaction-log":{"id":"v5/pre-upgrade/transaction-log","title":"Get Pre-upgrade Transaction Log","description":"Query transaction logs which occurred in the USDC Derivatives wallet before the account was upgraded to a Unified account.","sidebar":"v5SideBar"},"v5/rate-limit":{"id":"v5/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v5SideBar"},"v5/smp":{"id":"v5/smp","title":"Self Match Prevention","description":"What is SMP?","sidebar":"v5SideBar"},"v5/spot-margin-normal/account-info":{"id":"v5/spot-margin-normal/account-info","title":"Get Loan Account Info","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrow":{"id":"v5/spot-margin-normal/borrow","title":"Borrow","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrow-order":{"id":"v5/spot-margin-normal/borrow-order","title":"Get Borrow Order Detail","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrowable-data":{"id":"v5/spot-margin-normal/borrowable-data","title":"Get Borrowable Coin Info","description":"Do not need authentication","sidebar":"v5SideBar"},"v5/spot-margin-normal/interest-quota":{"id":"v5/spot-margin-normal/interest-quota","title":"Get Interest & Quota","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/margin-data":{"id":"v5/spot-margin-normal/margin-data","title":"Get Margin Coin Info","description":"Do not need authentication","sidebar":"v5SideBar"},"v5/spot-margin-normal/repay":{"id":"v5/spot-margin-normal/repay","title":"Repay","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/repay-order":{"id":"v5/spot-margin-normal/repay-order","title":"Get Repayment Order Detail","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/switch-mode":{"id":"v5/spot-margin-normal/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v5SideBar"},"v5/spot-margin-normal/vip-margin":{"id":"v5/spot-margin-normal/vip-margin","title":"Get VIP Margin Data","description":"This margin data is for Classic account in particular.","sidebar":"v5SideBar"},"v5/spot-margin-uta/set-leverage":{"id":"v5/spot-margin-uta/set-leverage","title":"Set Leverage","description":"Set the user\'s maximum leverage in spot cross margin","sidebar":"v5SideBar"},"v5/spot-margin-uta/status":{"id":"v5/spot-margin-uta/status","title":"Get Status And Leverage","description":"Query the Spot margin status and leverage of Unified account","sidebar":"v5SideBar"},"v5/spot-margin-uta/switch-mode":{"id":"v5/spot-margin-uta/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v5SideBar"},"v5/spot-margin-uta/vip-margin":{"id":"v5/spot-margin-uta/vip-margin","title":"Get VIP Margin Data","description":"This margin data is for Unified account in particular.","sidebar":"v5SideBar"},"v5/user/affiliate-info":{"id":"v5/user/affiliate-info","title":"Get Affiliate User Info","description":"This API is used for affiliate to get their users information","sidebar":"v5SideBar"},"v5/user/apikey-info":{"id":"v5/user/apikey-info","title":"Get API Key Information","description":"Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user\'s api key are applicable.","sidebar":"v5SideBar"},"v5/user/create-subuid":{"id":"v5/user/create-subuid","title":"Create Sub UID","description":"Create a new sub user id. Use master account\'s api key.","sidebar":"v5SideBar"},"v5/user/create-subuid-apikey":{"id":"v5/user/create-subuid-apikey","title":"Create Sub UID API Key","description":"To create new API key for those newly created sub UID. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/froze-subuid":{"id":"v5/user/froze-subuid","title":"Freeze Sub UID","description":"Freeze Sub UID. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/modify-master-apikey":{"id":"v5/user/modify-master-apikey","title":"Modify Master API Key","description":"Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/modify-sub-apikey":{"id":"v5/user/modify-sub-apikey","title":"Modify Sub API Key","description":"Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master","sidebar":"v5SideBar"},"v5/user/rm-master-apikey":{"id":"v5/user/rm-master-apikey","title":"Delete Master API Key","description":"Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/rm-sub-apikey":{"id":"v5/user/rm-sub-apikey","title":"Delete Sub API Key","description":"Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key","sidebar":"v5SideBar"},"v5/user/rm-subuid":{"id":"v5/user/rm-subuid","title":"Delete Sub UID","description":"Delete a sub UID. Before deleting the UID, please make sure there is no asset.","sidebar":"v5SideBar"},"v5/user/subuid-list":{"id":"v5/user/subuid-list","title":"Get Sub UID List","description":"Get all sub UID of master account. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/wallet-type":{"id":"v5/user/wallet-type","title":"Get UID Wallet Type","description":"Get available wallet types for the master account or sub account","sidebar":"v5SideBar"},"v5/websocket/private/dcp":{"id":"v5/websocket/private/dcp","title":"Dcp","description":"Subscribe to the dcp stream to trigger DCP function.","sidebar":"v5SideBar"},"v5/websocket/private/execution":{"id":"v5/websocket/private/execution","title":"Execution","description":"Subscribe to the execution stream to see your executions in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/greek":{"id":"v5/websocket/private/greek","title":"Greek","description":"Subscribe to the greeks stream to see changes to your greeks data in real-time. option only.","sidebar":"v5SideBar"},"v5/websocket/private/order":{"id":"v5/websocket/private/order","title":"Order","description":"Subscribe to the order stream to see changes to your orders in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/position":{"id":"v5/websocket/private/position","title":"Position","description":"Subscribe to the position stream to see changes to your position data in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/wallet":{"id":"v5/websocket/private/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time.","sidebar":"v5SideBar"},"v5/websocket/public/etp-kline":{"id":"v5/websocket/public/etp-kline","title":"LT Kline","description":"Subscribe to the leveraged token kline stream.","sidebar":"v5SideBar"},"v5/websocket/public/etp-nav":{"id":"v5/websocket/public/etp-nav","title":"LT Nav","description":"Subscribe to the leveraged token nav stream.","sidebar":"v5SideBar"},"v5/websocket/public/etp-ticker":{"id":"v5/websocket/public/etp-ticker","title":"LT Ticker","description":"Subscribe to the leveraged token ticker stream.","sidebar":"v5SideBar"},"v5/websocket/public/kline":{"id":"v5/websocket/public/kline","title":"Kline","description":"Subscribe to the klines stream.","sidebar":"v5SideBar"},"v5/websocket/public/liquidation":{"id":"v5/websocket/public/liquidation","title":"Liquidation","description":"Subscribe to the liquidation stream","sidebar":"v5SideBar"},"v5/websocket/public/orderbook":{"id":"v5/websocket/public/orderbook","title":"Orderbook","description":"Subscribe to the orderbook stream. Supports different depths.","sidebar":"v5SideBar"},"v5/websocket/public/ticker":{"id":"v5/websocket/public/ticker","title":"Ticker","description":"Subscribe to the ticker stream.","sidebar":"v5SideBar"},"v5/websocket/public/trade":{"id":"v5/websocket/public/trade","title":"Trade","description":"Subscribe to the recent trades stream.","sidebar":"v5SideBar"},"v5/websocket/wss-authentication":{"id":"v5/websocket/wss-authentication","title":"Connect","description":"WebSocket public channel:","sidebar":"v5SideBar"},"zh-my/account_asset":{"id":"zh-my/account_asset","title":"account_asset","description":"const Home = () => {"},"zh-my/account_asset/v1":{"id":"zh-my/account_asset/v1","title":"v1","description":"const Home = () => {"},"zh-my/account_asset/v3":{"id":"zh-my/account_asset/v3","title":"v3","description":"const Home = () => {"},"zh-my/copy_trading":{"id":"zh-my/copy_trading","title":"copy_trading","description":"const Home = () => {"},"zh-my/derivativesV3/contract":{"id":"zh-my/derivativesV3/contract","title":"contract","description":"const Home = () => {"},"zh-my/derivativesV3/unified_margin":{"id":"zh-my/derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"zh-my/futuresV2/inverse":{"id":"zh-my/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/futuresV2/inverse_futures":{"id":"zh-my/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/futuresV2/linear":{"id":"zh-my/futuresV2/linear","title":"linear","description":"const Home = () => {"},"zh-my/inverse":{"id":"zh-my/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/inverse_futures":{"id":"zh-my/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/linear":{"id":"zh-my/linear","title":"linear","description":"const Home = () => {"},"zh-my/spot":{"id":"zh-my/spot","title":"spot","description":"const Home = () => {"},"zh-my/spot/v1":{"id":"zh-my/spot/v1","title":"v1","description":"const Home = () => {"},"zh-my/spot/v3":{"id":"zh-my/spot/v3","title":"v3","description":"const Home = () => {"},"zh-my/tax":{"id":"zh-my/tax","title":"tax","description":"const Home = () => {"},"zh-my/testnet/account_asset/v1":{"id":"zh-my/testnet/account_asset/v1","title":"v1","description":"const Home = () => {"},"zh-my/testnet/account_asset/v3":{"id":"zh-my/testnet/account_asset/v3","title":"v3","description":"const Home = () => {"},"zh-my/testnet/copy_trading":{"id":"zh-my/testnet/copy_trading","title":"copy_trading","description":"const Home = () => {"},"zh-my/testnet/futuresV2/inverse":{"id":"zh-my/testnet/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/testnet/futuresV2/inverse_futures":{"id":"zh-my/testnet/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/testnet/futuresV2/linear":{"id":"zh-my/testnet/futuresV2/linear","title":"linear","description":"const Home = () => {"},"zh-my/testnet/inverse":{"id":"zh-my/testnet/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/testnet/inverse_futures":{"id":"zh-my/testnet/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/testnet/linear":{"id":"zh-my/testnet/linear","title":"linear","description":"const Home = () => {"},"zh-my/testnet/spot":{"id":"zh-my/testnet/spot","title":"spot","description":"const Home = () => {"},"zh-my/testnet/spot/v1":{"id":"zh-my/testnet/spot/v1","title":"v1","description":"const Home = () => {"},"zh-my/testnet/spot/v3":{"id":"zh-my/testnet/spot/v3","title":"v3","description":"const Home = () => {"},"zh-my/testnet/usdc/option":{"id":"zh-my/testnet/usdc/option","title":"option","description":"const Home = () => {"},"zh-my/testnet/usdc/perpetual":{"id":"zh-my/testnet/usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"zh-my/usdc/option":{"id":"zh-my/usdc/option","title":"option","description":"const Home = () => {"},"zh-my/usdc/perpetual":{"id":"zh-my/usdc/perpetual","title":"perpetual","description":"const Home = () => {"}}}')}}]); \ No newline at end of file +"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[80053],{1109:e=>{e.exports=JSON.parse('{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"noIndex":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"v3SideBar":[{"type":"link","label":"Introduction","href":"/docs/v3/intro","docId":"v3/intro"},{"type":"link","label":"Bybit Server Time","href":"/docs/v3/server-time","docId":"v3/server-time"},{"type":"link","label":"Self Match Prevention","href":"/docs/v3/smp","docId":"v3/smp"},{"type":"category","label":"Derivatives","items":[{"type":"category","label":"REST API","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Kline","href":"/docs/derivatives/public/kline","docId":"v3/derivatives/rest-public/kline"},{"type":"link","label":"Mark Price Kline","href":"/docs/derivatives/public/mark-kline","docId":"v3/derivatives/rest-public/mark-kline"},{"type":"link","label":"Index Price Kline","href":"/docs/derivatives/public/index-kline","docId":"v3/derivatives/rest-public/index-kline"},{"type":"link","label":"Premium Index Price Kline","href":"/docs/derivatives/public/premium-index-kline","docId":"v3/derivatives/rest-public/premium-index-kline"},{"type":"link","label":"Order Book","href":"/docs/derivatives/public/orderbook","docId":"v3/derivatives/rest-public/orderbook"},{"type":"link","label":"Ticker Info","href":"/docs/derivatives/public/ticker","docId":"v3/derivatives/rest-public/ticker-info"},{"type":"link","label":"Instrument Info","href":"/docs/derivatives/public/instrument-info","docId":"v3/derivatives/rest-public/instrument-info"},{"type":"link","label":"Public Trading History","href":"/docs/derivatives/public/trade","docId":"v3/derivatives/rest-public/public-trade"},{"type":"link","label":"Risk Limit","href":"/docs/derivatives/public/risk-limit","docId":"v3/derivatives/rest-public/risk-limit"},{"type":"link","label":"Funding Rate History","href":"/docs/derivatives/public/funding-rate","docId":"v3/derivatives/rest-public/fund-rate-history"},{"type":"link","label":"Open Interest","href":"/docs/derivatives/public/open-interest","docId":"v3/derivatives/rest-public/open-interest"},{"type":"link","label":"Option Delivery Price","href":"/docs/derivatives/public/option-delivery","docId":"v3/derivatives/rest-public/delivery-price"},{"type":"link","label":"Get Long Short Ratio","href":"/docs/derivatives/public/long-short-ratio","docId":"v3/derivatives/rest-public/long-short-ratio"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contract","items":[{"type":"category","label":"Order","items":[{"type":"link","label":"Place Order","href":"/docs/derivatives/contract/place-order","docId":"v3/derivatives/rest-contract/order/place-order"},{"type":"link","label":"Get Open Orders","href":"/docs/derivatives/contract/open-order","docId":"v3/derivatives/rest-contract/order/open-order"},{"type":"link","label":"Replace Order","href":"/docs/derivatives/contract/replace-order","docId":"v3/derivatives/rest-contract/order/replace-order"},{"type":"link","label":"Cancel Order","href":"/docs/derivatives/contract/cancel","docId":"v3/derivatives/rest-contract/order/cancel-order"},{"type":"link","label":"Cancel All Order","href":"/docs/derivatives/contract/cancel-all","docId":"v3/derivatives/rest-contract/order/cancel-all"},{"type":"link","label":"Get Order List","href":"/docs/derivatives/contract/order-list","docId":"v3/derivatives/rest-contract/order/order-list"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Position","items":[{"type":"link","label":"My Position","href":"/docs/derivatives/contract/position-list","docId":"v3/derivatives/rest-contract/position/position-info"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/derivatives/contract/auto-margin","docId":"v3/derivatives/rest-contract/position/auto-margin"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/derivatives/contract/cross-isolated","docId":"v3/derivatives/rest-contract/position/cross-isolated-margin"},{"type":"link","label":"Switch Position Mode","href":"/docs/derivatives/contract/position-mode","docId":"v3/derivatives/rest-contract/position/position-mode"},{"type":"link","label":"Switch TP/SL Mode","href":"/docs/derivatives/contract/tpsl-mode","docId":"v3/derivatives/rest-contract/position/tpsl-mode"},{"type":"link","label":"Set Leverage","href":"/docs/derivatives/contract/leverage","docId":"v3/derivatives/rest-contract/position/leverage"},{"type":"link","label":"Set Trading Stop","href":"/docs/derivatives/contract/trading-stop","docId":"v3/derivatives/rest-contract/position/trading-stop"},{"type":"link","label":"Set Risk Limit","href":"/docs/derivatives/contract/set-risk-limit","docId":"v3/derivatives/rest-contract/position/set-risk-limit"},{"type":"link","label":"Get Execution List","href":"/docs/derivatives/contract/execution-list","docId":"v3/derivatives/rest-contract/position/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/derivatives/contract/closepnl","docId":"v3/derivatives/rest-contract/position/close-pnl"},{"type":"link","label":"Confirm New Risk Limit","href":"/docs/derivatives/contract/confirm-mmr","docId":"v3/derivatives/rest-contract/position/confirm-mmr"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Account","items":[{"type":"link","label":"Wallet Balance","href":"/docs/derivatives/contract/wallet","docId":"v3/derivatives/rest-contract/account/wallet-balance"},{"type":"link","label":"Get Trading Fee Rate","href":"/docs/derivatives/contract/fee-rate","docId":"v3/derivatives/rest-contract/account/trading-fee"},{"type":"link","label":"Get Wallet Fund Records","href":"/docs/derivatives/contract/wallet-fund","docId":"v3/derivatives/rest-contract/account/wallet-fund-record"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/derivatives/ws/connect","docId":"v3/derivatives/wss-authentication"},{"type":"category","label":"Public Channel","items":[{"type":"link","label":"Orderbook","href":"/docs/derivatives/ws-public/orderbook","docId":"v3/derivatives/wss-public/orderbook"},{"type":"link","label":"Public Trade","href":"/docs/derivatives/ws-public/trade","docId":"v3/derivatives/wss-public/trade"},{"type":"link","label":"Tickers","href":"/docs/derivatives/ws-public/ticker","docId":"v3/derivatives/wss-public/tickers"},{"type":"link","label":"Kline","href":"/docs/derivatives/ws-public/kline","docId":"v3/derivatives/wss-public/kline"},{"type":"link","label":"Liquidation","href":"/docs/derivatives/ws-public/liquidation","docId":"v3/derivatives/wss-public/liquidation"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private Channel (contract)","items":[{"type":"link","label":"Position","href":"/docs/derivatives/ws-contract/position","docId":"v3/derivatives/wss-contract/position"},{"type":"link","label":"Execution","href":"/docs/derivatives/ws-contract/execution","docId":"v3/derivatives/wss-contract/execution"},{"type":"link","label":"Order","href":"/docs/derivatives/ws-contract/order","docId":"v3/derivatives/wss-contract/order"},{"type":"link","label":"Wallet","href":"/docs/derivatives/ws-contract/wallet","docId":"v3/derivatives/wss-contract/wallet"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/derivatives/rate-limit","docId":"v3/derivatives/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/derivatives/enum","docId":"v3/derivatives/enum"},{"type":"link","label":"Error Code","href":"/docs/derivatives/error","docId":"v3/derivatives/error"}],"collapsed":true,"collapsible":true,"href":"/docs/category/derivatives"},{"type":"category","label":"Spot","items":[{"type":"category","label":"REST API","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Instrument Info","href":"/docs/spot/public/instrument","docId":"v3/spot/rest-public/instrument-info"},{"type":"link","label":"Order Book","href":"/docs/spot/public/depth","docId":"v3/spot/rest-public/orderbook"},{"type":"link","label":"Merged Order Book","href":"/docs/spot/public/merge-depth","docId":"v3/spot/rest-public/merge-orderbook"},{"type":"link","label":"Kline","href":"/docs/spot/public/kline","docId":"v3/spot/rest-public/kline"},{"type":"link","label":"Public Trading Records","href":"/docs/spot/public/recent-trade","docId":"v3/spot/rest-public/public-trade"},{"type":"link","label":"Best Bid/Ask Price","href":"/docs/spot/public/bid-ask","docId":"v3/spot/rest-public/best-bid-ask"},{"type":"link","label":"Last Traded Price","href":"/docs/spot/public/last-price","docId":"v3/spot/rest-public/last-trade-price"},{"type":"link","label":"Tickers","href":"/docs/spot/public/tickers","docId":"v3/spot/rest-public/ticker-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/spot/trade/place-order","docId":"v3/spot/rest-spot/place-order"},{"type":"link","label":"Get Order","href":"/docs/spot/trade/get-order","docId":"v3/spot/rest-spot/get-order"},{"type":"link","label":"Cancel Order","href":"/docs/spot/trade/cancel","docId":"v3/spot/rest-spot/cancel-order"},{"type":"link","label":"Open Orders","href":"/docs/spot/trade/open-order","docId":"v3/spot/rest-spot/open-order"},{"type":"link","label":"Batch Cancel Order","href":"/docs/spot/trade/batch-cancel","docId":"v3/spot/rest-spot/batch-cancel"},{"type":"link","label":"Batch Cancel Order By Id","href":"/docs/spot/trade/cancel-by-id","docId":"v3/spot/rest-spot/batch-cancel-by-id"},{"type":"link","label":"Order History","href":"/docs/spot/trade/order-history","docId":"v3/spot/rest-spot/order-history"},{"type":"link","label":"Trade History","href":"/docs/spot/trade/my-trades","docId":"v3/spot/rest-spot/trade-history"}],"collapsed":true,"collapsible":true},{"type":"link","label":"Get Wallet Balance","href":"/docs/spot/wallet","docId":"v3/spot/wallet"},{"type":"category","label":"Leveraged Token","items":[{"type":"link","label":"All Asset Info","href":"/docs/spot/etp/asset-info","docId":"v3/spot/rest-etp/asset-info"},{"type":"link","label":"Market Info","href":"/docs/spot/etp/market-info","docId":"v3/spot/rest-etp/market-info"},{"type":"link","label":"Purchase & Redeem History","href":"/docs/spot/etp/order-history","docId":"v3/spot/rest-etp/purchase-redeem-history"},{"type":"link","label":"Purchase","href":"/docs/spot/etp/purchase","docId":"v3/spot/rest-etp/purchase"},{"type":"link","label":"Redeem","href":"/docs/spot/etp/redeem","docId":"v3/spot/rest-etp/redeem"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Cross Margin Trade","items":[{"type":"link","label":"Get Loan Account Info","href":"/docs/spot/margin/account","docId":"v3/spot/rest-spot-margin/account-info"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/spot/margin/borrow-history","docId":"v3/spot/rest-spot-margin/borrow-info"},{"type":"link","label":"Borrow","href":"/docs/spot/margin/borrow","docId":"v3/spot/rest-spot-margin/borrow"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/spot/margin/borrowable-coin","docId":"v3/spot/rest-spot-margin/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/spot/margin/interest","docId":"v3/spot/rest-spot-margin/interest-quota"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/spot/margin/margin-data","docId":"v3/spot/rest-spot-margin/margin-data"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/spot/margin/repay-history","docId":"v3/spot/rest-spot-margin/repay-history"},{"type":"link","label":"Repay","href":"/docs/spot/margin/repay","docId":"v3/spot/rest-spot-margin/repay"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/spot/margin/toggle","docId":"v3/spot/rest-spot-margin/switch-mode"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Institution Loan","items":[{"type":"link","label":"Get Margin Product Info","href":"/docs/spot/otc/product-info","docId":"v3/spot/rest-institution-loan/margin-product-info"},{"type":"link","label":"Margin Coin Info","href":"/docs/spot/otc/coin-info","docId":"v3/spot/rest-institution-loan/margin-coin-info"},{"type":"link","label":"Get Loan Info","href":"/docs/spot/otc/loan-info","docId":"v3/spot/rest-institution-loan/loan-info"},{"type":"link","label":"Get Repay Info","href":"/docs/spot/otc/repay-info","docId":"v3/spot/rest-institution-loan/repay-info"},{"type":"link","label":"Get LTV","href":"/docs/spot/otc/ltv","docId":"v3/spot/rest-institution-loan/ltv"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/spot/ws/connect","docId":"v3/spot/wss-authentication"},{"type":"category","label":"Public Channel","items":[{"type":"link","label":"Orderbook","href":"/docs/spot/ws-public/orderbook","docId":"v3/spot/wss-public/orderbook"},{"type":"link","label":"Kline","href":"/docs/spot/ws-public/kline","docId":"v3/spot/wss-public/kline"},{"type":"link","label":"Tickers","href":"/docs/spot/ws-public/ticker","docId":"v3/spot/wss-public/tickers"},{"type":"link","label":"Bookticker","href":"/docs/spot/ws-public/bookticker","docId":"v3/spot/wss-public/bookticker"},{"type":"link","label":"Public trade","href":"/docs/spot/ws-public/public-trade","docId":"v3/spot/wss-public/trade"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private Channel","items":[{"type":"link","label":"Order","href":"/docs/spot/ws-private/order","docId":"v3/spot/wss-private/order"},{"type":"link","label":"Stop Order","href":"/docs/spot/ws-private/stop-order","docId":"v3/spot/wss-private/stop-order"},{"type":"link","label":"Execution","href":"/docs/spot/ws-private/execution","docId":"v3/spot/wss-private/ticket-info"},{"type":"link","label":"Wallet","href":"/docs/spot/ws-private/wallet","docId":"v3/spot/wss-private/outbound-account-info"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/spot/rate-limit","docId":"v3/spot/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/spot/enum","docId":"v3/spot/enum"},{"type":"link","label":"Error Code","href":"/docs/spot/error","docId":"v3/spot/error"}],"collapsed":true,"collapsible":true,"href":"/docs/category/spot"},{"type":"category","label":"Account Asset","collapsed":true,"items":[{"type":"category","label":"Transfer Endpoint","collapsed":true,"items":[{"type":"link","label":"Create Internal Transfer","href":"/docs/account-asset/internal-transfer","docId":"v3/account-asset/transfer/internal-transfer"},{"type":"link","label":"Get Internal Transfer List","href":"/docs/account-asset/internal-transfer-list","docId":"v3/account-asset/transfer/internal-transfer-list"},{"type":"link","label":"Create Subaccount Transfer","href":"/docs/account-asset/sub-transfer","docId":"v3/account-asset/transfer/subacct-transfer"},{"type":"link","label":"Get Master-Sub Transfer List","href":"/docs/account-asset/sub-transfer-list","docId":"v3/account-asset/transfer/subacct-transfer-list"},{"type":"link","label":"Get Subaccount UID List","href":"/docs/account-asset/sub-uid-list","docId":"v3/account-asset/transfer/subacct-list"},{"type":"link","label":"Enable Universal Transfer (Depreciated)","href":"/docs/account-asset/enable-unitransfer","docId":"v3/account-asset/transfer/enable-uni-transfer"},{"type":"link","label":"Create Universal Transfer","href":"/docs/account-asset/uni-transfer","docId":"v3/account-asset/transfer/uni-transfer"},{"type":"link","label":"Get Universal Transfer List","href":"/docs/account-asset/uni-transfer-list","docId":"v3/account-asset/transfer/uni-transfer-list"},{"type":"link","label":"Get Transferable Coin List","href":"/docs/account-asset/transferable-coin-list","docId":"v3/account-asset/transfer/transferable-coin-list"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/account-asset/coin-balance","docId":"v3/account-asset/transfer/coin-balance"},{"type":"link","label":"Get All Coins Balance","href":"/docs/account-asset/all-balance","docId":"v3/account-asset/transfer/all-balance"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/account-asset/asset-info","docId":"v3/account-asset/transfer/asset-info"}],"collapsible":true},{"type":"category","label":"Withdraw and Deposit endpoint","collapsed":true,"items":[{"type":"link","label":"Get Deposit Spec","href":"/docs/account-asset/deposit-spec","docId":"v3/account-asset/withdraw-deposit/deposit-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/account-asset/set-deposit-acct","docId":"v3/account-asset/withdraw-deposit/set-deposit-acct"},{"type":"link","label":"Get Deposit Records (on chain)","href":"/docs/account-asset/deposit-record","docId":"v3/account-asset/withdraw-deposit/master-deposit-record"},{"type":"link","label":"Get Sub Deposit Records (on chain)","href":"/docs/account-asset/sub-deposit-record","docId":"v3/account-asset/withdraw-deposit/sub-deposit-record"},{"type":"link","label":"Get Bybit Internal Deposit Records (across Bybit)","href":"/docs/account-asset/internal-deposit-record","docId":"v3/account-asset/withdraw-deposit/internal-deposit-record"},{"type":"link","label":"Get Withdraw Records","href":"/docs/account-asset/withdraw-record","docId":"v3/account-asset/withdraw-deposit/withdraw-record"},{"type":"link","label":"Get Coin Information","href":"/docs/account-asset/coin-info","docId":"v3/account-asset/withdraw-deposit/coin-info"},{"type":"link","label":"Get Delay Withdraw Amount","href":"/docs/account-asset/delay-amount","docId":"v3/account-asset/withdraw-deposit/deplay-amount"},{"type":"link","label":"Withdraw","href":"/docs/account-asset/withdraw","docId":"v3/account-asset/withdraw-deposit/withdraw"},{"type":"link","label":"Cancel withdrawal","href":"/docs/account-asset/cancel-withdraw","docId":"v3/account-asset/withdraw-deposit/cancel-withdraw"},{"type":"link","label":"Get Master Acct Deposit Address Info","href":"/docs/account-asset/master-deposit-addr","docId":"v3/account-asset/withdraw-deposit/master-deposit-addr"},{"type":"link","label":"Get Sub Acct Deposit Address Info","href":"/docs/account-asset/sub-deposit-addr","docId":"v3/account-asset/withdraw-deposit/sub-deposit-addr"}],"collapsible":true},{"type":"category","label":"Master-Sub User Endpoint","collapsed":true,"items":[{"type":"link","label":"Create Sub UID","href":"/docs/account-asset/create-subuid","docId":"v3/account-asset/user/create-subuid"},{"type":"link","label":"Create Sub UID API Key","href":"/docs/account-asset/create-subuid-apikey","docId":"v3/account-asset/user/create-subuid-apikey"},{"type":"link","label":"Get Sub UID List","href":"/docs/account-asset/subuid-list","docId":"v3/account-asset/user/subuid-list"},{"type":"link","label":"Froze Sub UID","href":"/docs/account-asset/froze-subuid","docId":"v3/account-asset/user/froze-subuid"},{"type":"link","label":"Get API Key Information","href":"/docs/account-asset/apikey-info","docId":"v3/account-asset/user/apikey-info"},{"type":"link","label":"Get UID Wallet Type","href":"/docs/account-asset/wallet-type","docId":"v3/account-asset/user/wallet-type"},{"type":"link","label":"Modify Master API Key","href":"/docs/account-asset/modify-master-apikey","docId":"v3/account-asset/user/modify-master-apikey"},{"type":"link","label":"Modify Sub API Key","href":"/docs/account-asset/modify-sub-apikey","docId":"v3/account-asset/user/modify-sub-apikey"},{"type":"link","label":"Delete Master API Key","href":"/docs/account-asset/rm-master-apikey","docId":"v3/account-asset/user/rm-master-apikey"},{"type":"link","label":"Delete Sub API Key","href":"/docs/account-asset/rm-sub-apikey","docId":"v3/account-asset/user/rm-sub-apikey"}],"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/account-asset/rate-limit","docId":"v3/account-asset/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/account-asset/enum","docId":"v3/account-asset/enum"},{"type":"link","label":"Error Code","href":"/docs/account-asset/error","docId":"v3/account-asset/error"}],"collapsible":true},{"type":"category","label":"Tax","items":[{"type":"link","label":"Get User Register Date","href":"/docs/tax/time","docId":"v3/tax/register-time"},{"type":"link","label":"Request Export Report","href":"/docs/tax/report","docId":"v3/tax/request-report"},{"type":"link","label":"Get Export Report Status","href":"/docs/tax/status","docId":"v3/tax/report-status"},{"type":"link","label":"Retrieve Data Export","href":"/docs/tax/data-export","docId":"v3/tax/data-export"},{"type":"link","label":"Data Explanation","href":"/docs/tax/explain","docId":"v3/tax/data-explain"},{"type":"link","label":"Enums Definitions","href":"/docs/tax/enum","docId":"v3/tax/enum"}],"collapsed":true,"collapsible":true}],"v5SideBar":[{"type":"link","label":"Introduction","href":"/docs/v5/intro","docId":"v5/intro"},{"type":"link","label":"Integration Guidance","href":"/docs/v5/guide","docId":"v5/guide"},{"type":"link","label":"Get Announcement","href":"/docs/v5/announcement","docId":"v5/announcement"},{"type":"link","label":"Self Match Prevention","href":"/docs/v5/smp","docId":"v5/smp"},{"type":"link","label":"How To Start Copy Trading","href":"/docs/v5/copytrade","docId":"v5/copytrade"},{"type":"category","label":"Market","items":[{"type":"link","label":"Get Bybit Server Time","href":"/docs/v5/market/time","docId":"v5/market/time"},{"type":"link","label":"Get Kline","href":"/docs/v5/market/kline","docId":"v5/market/kline"},{"type":"link","label":"Get Mark Price Kline","href":"/docs/v5/market/mark-kline","docId":"v5/market/mark-kline"},{"type":"link","label":"Get Index Price Kline","href":"/docs/v5/market/index-kline","docId":"v5/market/index-kline"},{"type":"link","label":"Get Premium Index Price Kline","href":"/docs/v5/market/preimum-index-kline","docId":"v5/market/preimum-index-kline"},{"type":"link","label":"Get Instruments Info","href":"/docs/v5/market/instrument","docId":"v5/market/instrument"},{"type":"link","label":"Get Orderbook","href":"/docs/v5/market/orderbook","docId":"v5/market/orderbook"},{"type":"link","label":"Get Tickers","href":"/docs/v5/market/tickers","docId":"v5/market/tickers"},{"type":"link","label":"Get Funding Rate History","href":"/docs/v5/market/history-fund-rate","docId":"v5/market/history-fund-rate"},{"type":"link","label":"Get Public Recent Trading History","href":"/docs/v5/market/recent-trade","docId":"v5/market/recent-trade"},{"type":"link","label":"Get Open Interest","href":"/docs/v5/market/open-interest","docId":"v5/market/open-interest"},{"type":"link","label":"Get Historical Volatility","href":"/docs/v5/market/iv","docId":"v5/market/iv"},{"type":"link","label":"Get Insurance","href":"/docs/v5/market/insurance","docId":"v5/market/insurance"},{"type":"link","label":"Get Risk Limit","href":"/docs/v5/market/risk-limit","docId":"v5/market/risk-limit"},{"type":"link","label":"Get Delivery Price","href":"/docs/v5/market/delivery-price","docId":"v5/market/delivery-price"},{"type":"link","label":"Get Long Short Ratio","href":"/docs/v5/market/long-short-ratio","docId":"v5/market/long-short-ratio"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/v5/order/create-order","docId":"v5/order/create-order"},{"type":"link","label":"Amend Order","href":"/docs/v5/order/amend-order","docId":"v5/order/amend-order"},{"type":"link","label":"Cancel Order","href":"/docs/v5/order/cancel-order","docId":"v5/order/cancel-order"},{"type":"link","label":"Get Open Orders (real-time)","href":"/docs/v5/order/open-order","docId":"v5/order/open-order"},{"type":"link","label":"Cancel All Orders","href":"/docs/v5/order/cancel-all","docId":"v5/order/cancel-all"},{"type":"link","label":"Get Order History (2 years)","href":"/docs/v5/order/order-list","docId":"v5/order/order-list"},{"type":"link","label":"Batch Place Order","href":"/docs/v5/order/batch-place","docId":"v5/order/batch-place"},{"type":"link","label":"Batch Amend Order","href":"/docs/v5/order/batch-amend","docId":"v5/order/batch-amend"},{"type":"link","label":"Batch Cancel Order","href":"/docs/v5/order/batch-cancel","docId":"v5/order/batch-cancel"},{"type":"link","label":"Get Borrow Quota (Spot)","href":"/docs/v5/order/spot-borrow-quota","docId":"v5/order/spot-borrow-quota"},{"type":"link","label":"Set DCP (Options)","href":"/docs/v5/order/dcp","docId":"v5/order/dcp"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Position","items":[{"type":"link","label":"Get Position Info","href":"/docs/v5/position/","docId":"v5/position/position"},{"type":"link","label":"Set Leverage","href":"/docs/v5/position/leverage","docId":"v5/position/leverage"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/v5/position/cross-isolate","docId":"v5/position/cross-isolate"},{"type":"link","label":"Set TP/SL Mode","href":"/docs/v5/position/tpsl-mode","docId":"v5/position/tpsl-mode"},{"type":"link","label":"Switch Position Mode","href":"/docs/v5/position/position-mode","docId":"v5/position/position-mode"},{"type":"link","label":"Set Risk Limit","href":"/docs/v5/position/set-risk-limit","docId":"v5/position/set-risk-limit"},{"type":"link","label":"Set Trading Stop","href":"/docs/v5/position/trading-stop","docId":"v5/position/trading-stop"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/v5/position/auto-add-margin","docId":"v5/position/auto-add-margin"},{"type":"link","label":"Add Or Reduce Margin","href":"/docs/v5/position/manual-add-margin","docId":"v5/position/manual-add-margin"},{"type":"link","label":"Get Execution (2 years)","href":"/docs/v5/position/execution","docId":"v5/position/execution"},{"type":"link","label":"Get Closed PnL (2 years)","href":"/docs/v5/position/close-pnl","docId":"v5/position/close-pnl"},{"type":"link","label":"Confirm New Risk Limit","href":"/docs/v5/position/confirm-mmr","docId":"v5/position/confirm-mmr"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Pre-upgrade","items":[{"type":"link","label":"Get Pre-upgrade Order History","href":"/docs/v5/pre-upgrade/order-list","docId":"v5/pre-upgrade/order-list"},{"type":"link","label":"Get Pre-upgrade Trade History","href":"/docs/v5/pre-upgrade/execution","docId":"v5/pre-upgrade/execution"},{"type":"link","label":"Get Pre-upgrade Closed PnL","href":"/docs/v5/pre-upgrade/close-pnl","docId":"v5/pre-upgrade/close-pnl"},{"type":"link","label":"Get Pre-upgrade Transaction Log","href":"/docs/v5/pre-upgrade/transaction-log","docId":"v5/pre-upgrade/transaction-log"},{"type":"link","label":"Get Pre-upgrade Option Delivery Record","href":"/docs/v5/pre-upgrade/delivery","docId":"v5/pre-upgrade/delivery"},{"type":"link","label":"Get Pre-upgrade USDC Session Settlement","href":"/docs/v5/pre-upgrade/settlement","docId":"v5/pre-upgrade/settlement"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Account","items":[{"type":"link","label":"Get Wallet Balance","href":"/docs/v5/account/wallet-balance","docId":"v5/account/wallet-balance"},{"type":"link","label":"Upgrade to Unified Account","href":"/docs/v5/account/upgrade-unified-account","docId":"v5/account/upgrade-unified-account"},{"type":"link","label":"Get Borrow History","href":"/docs/v5/account/borrow-history","docId":"v5/account/borrow-history"},{"type":"link","label":"Set Collateral Coin","href":"/docs/v5/account/set-collateral","docId":"v5/account/set-collateral"},{"type":"link","label":"Get Collateral Info","href":"/docs/v5/account/collateral-info","docId":"v5/account/collateral-info"},{"type":"link","label":"Get Coin Greeks","href":"/docs/v5/account/coin-greeks","docId":"v5/account/coin-greeks"},{"type":"link","label":"Get Fee Rate","href":"/docs/v5/account/fee-rate","docId":"v5/account/fee-rate"},{"type":"link","label":"Get Account Info","href":"/docs/v5/account/account-info","docId":"v5/account/account-info"},{"type":"link","label":"Get Transaction Log","href":"/docs/v5/account/transaction-log","docId":"v5/account/transaction-log"},{"type":"link","label":"Set Margin Mode","href":"/docs/v5/account/set-margin-mode","docId":"v5/account/set-margin-mode"},{"type":"link","label":"Set MMP","href":"/docs/v5/account/set-mmp","docId":"v5/account/set-mmp"},{"type":"link","label":"Reset MMP","href":"/docs/v5/account/reset-mmp","docId":"v5/account/reset-mmp"},{"type":"link","label":"Get MMP State","href":"/docs/v5/account/get-mmp-state","docId":"v5/account/get-mmp-state"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Asset","items":[{"type":"link","label":"Get Coin Exchange Records","href":"/docs/v5/asset/exchange","docId":"v5/asset/exchange"},{"type":"link","label":"Get Delivery Record","href":"/docs/v5/asset/delivery","docId":"v5/asset/delivery"},{"type":"link","label":"Get USDC Session Settlement","href":"/docs/v5/asset/settlement","docId":"v5/asset/settlement"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/v5/asset/asset-info","docId":"v5/asset/asset-info"},{"type":"link","label":"Get All Coins Balance","href":"/docs/v5/asset/all-balance","docId":"v5/asset/all-balance"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/v5/asset/account-coin-balance","docId":"v5/asset/account-coin-balance"},{"type":"link","label":"Get Transferable Coin","href":"/docs/v5/asset/transferable-coin","docId":"v5/asset/transferable-coin"},{"type":"link","label":"Create Internal Transfer","href":"/docs/v5/asset/create-inter-transfer","docId":"v5/asset/create-inter-transfer"},{"type":"link","label":"Get Internal Transfer Records","href":"/docs/v5/asset/inter-transfer-list","docId":"v5/asset/inter-transfer-list"},{"type":"link","label":"Get Sub UID","href":"/docs/v5/asset/sub-uid-list","docId":"v5/asset/sub-uid-list"},{"type":"link","label":"Create Universal Transfer","href":"/docs/v5/asset/unitransfer","docId":"v5/asset/unitransfer"},{"type":"link","label":"Get Universal Transfer Records","href":"/docs/v5/asset/unitransfer-list","docId":"v5/asset/unitransfer-list"},{"type":"link","label":"Get Allowed Deposit Coin Info","href":"/docs/v5/asset/deposit-coin-spec","docId":"v5/asset/deposit-coin-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/v5/asset/set-deposit-acct","docId":"v5/asset/set-deposit-acct"},{"type":"link","label":"Get Deposit Records (on-chain)","href":"/docs/v5/asset/deposit-record","docId":"v5/asset/deposit-record"},{"type":"link","label":"Get Sub Deposit Records (on-chain)","href":"/docs/v5/asset/sub-deposit-record","docId":"v5/asset/sub-deposit-record"},{"type":"link","label":"Get Internal Deposit Records (off-chain)","href":"/docs/v5/asset/internal-deposit-record","docId":"v5/asset/internal-deposit-record"},{"type":"link","label":"Get Master Deposit Address","href":"/docs/v5/asset/master-deposit-addr","docId":"v5/asset/master-deposit-addr"},{"type":"link","label":"Get Sub Deposit Address","href":"/docs/v5/asset/sub-deposit-addr","docId":"v5/asset/sub-deposit-addr"},{"type":"link","label":"Get Coin Info","href":"/docs/v5/asset/coin-info","docId":"v5/asset/coin-info"},{"type":"link","label":"Get Withdrawal Records","href":"/docs/v5/asset/withdraw-record","docId":"v5/asset/withdraw-record"},{"type":"link","label":"Get Withdrawable Amount","href":"/docs/v5/asset/delay-amount","docId":"v5/asset/delay-amount"},{"type":"link","label":"Withdraw","href":"/docs/v5/asset/withdraw","docId":"v5/asset/withdraw"},{"type":"link","label":"Cancel Withdrawal","href":"/docs/v5/asset/cancel-withdraw","docId":"v5/asset/cancel-withdraw"}],"collapsed":true,"collapsible":true},{"type":"category","label":"User","items":[{"type":"link","label":"Create Sub UID","href":"/docs/v5/user/create-subuid","docId":"v5/user/create-subuid"},{"type":"link","label":"Create Sub UID API Key","href":"/docs/v5/user/create-subuid-apikey","docId":"v5/user/create-subuid-apikey"},{"type":"link","label":"Get Sub UID List","href":"/docs/v5/user/subuid-list","docId":"v5/user/subuid-list"},{"type":"link","label":"Freeze Sub UID","href":"/docs/v5/user/froze-subuid","docId":"v5/user/froze-subuid"},{"type":"link","label":"Get API Key Information","href":"/docs/v5/user/apikey-info","docId":"v5/user/apikey-info"},{"type":"link","label":"Get UID Wallet Type","href":"/docs/v5/user/wallet-type","docId":"v5/user/wallet-type"},{"type":"link","label":"Modify Master API Key","href":"/docs/v5/user/modify-master-apikey","docId":"v5/user/modify-master-apikey"},{"type":"link","label":"Modify Sub API Key","href":"/docs/v5/user/modify-sub-apikey","docId":"v5/user/modify-sub-apikey"},{"type":"link","label":"Delete Sub UID","href":"/docs/v5/user/rm-subuid","docId":"v5/user/rm-subuid"},{"type":"link","label":"Delete Master API Key","href":"/docs/v5/user/rm-master-apikey","docId":"v5/user/rm-master-apikey"},{"type":"link","label":"Delete Sub API Key","href":"/docs/v5/user/rm-sub-apikey","docId":"v5/user/rm-sub-apikey"},{"type":"link","label":"Get Affiliate User Info","href":"/docs/v5/user/affiliate-info","docId":"v5/user/affiliate-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"Get Leverage Token Info","href":"/docs/v5/lt/leverage-token-info","docId":"v5/lt/leverage-token-info"},{"type":"link","label":"Get Leveraged Token Market","href":"/docs/v5/lt/leverage-token-reference","docId":"v5/lt/leverage-token-reference"},{"type":"link","label":"Purchase","href":"/docs/v5/lt/purchase","docId":"v5/lt/purchase"},{"type":"link","label":"Redeem","href":"/docs/v5/lt/redeem","docId":"v5/lt/redeem"},{"type":"link","label":"Get Purchase/Redemption Records","href":"/docs/v5/lt/order-record","docId":"v5/lt/order-record"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Margin Trade (UTA)","items":[{"type":"link","label":"Get VIP Margin Data","href":"/docs/v5/spot-margin-uta/vip-margin","docId":"v5/spot-margin-uta/vip-margin"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/v5/spot-margin-uta/switch-mode","docId":"v5/spot-margin-uta/switch-mode"},{"type":"link","label":"Set Leverage","href":"/docs/v5/spot-margin-uta/set-leverage","docId":"v5/spot-margin-uta/set-leverage"},{"type":"link","label":"Get Status And Leverage","href":"/docs/v5/spot-margin-uta/status","docId":"v5/spot-margin-uta/status"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Spot Margin Trade (Classic)","items":[{"type":"link","label":"Get VIP Margin Data","href":"/docs/v5/spot-margin-normal/vip-margin","docId":"v5/spot-margin-normal/vip-margin"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/spot-margin-normal/margin-data","docId":"v5/spot-margin-normal/margin-data"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/v5/spot-margin-normal/borrowable-data","docId":"v5/spot-margin-normal/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/v5/spot-margin-normal/interest-quota","docId":"v5/spot-margin-normal/interest-quota"},{"type":"link","label":"Get Loan Account Info","href":"/docs/v5/spot-margin-normal/account-info","docId":"v5/spot-margin-normal/account-info"},{"type":"link","label":"Borrow","href":"/docs/v5/spot-margin-normal/borrow","docId":"v5/spot-margin-normal/borrow"},{"type":"link","label":"Repay","href":"/docs/v5/spot-margin-normal/repay","docId":"v5/spot-margin-normal/repay"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/v5/spot-margin-normal/borrow-order","docId":"v5/spot-margin-normal/borrow-order"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/v5/spot-margin-normal/repay-order","docId":"v5/spot-margin-normal/repay-order"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/v5/spot-margin-normal/switch-mode","docId":"v5/spot-margin-normal/switch-mode"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Institutional Loan","items":[{"type":"link","label":"Get Product Info","href":"/docs/v5/otc/margin-product-info","docId":"v5/otc/margin-product-info"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/otc/margin-coin-convert-info","docId":"v5/otc/margin-coin-convert-info"},{"type":"link","label":"Get Loan Orders","href":"/docs/v5/otc/loan-info","docId":"v5/otc/loan-info"},{"type":"link","label":"Get Repay Orders","href":"/docs/v5/otc/repay-info","docId":"v5/otc/repay-info"},{"type":"link","label":"Get LTV","href":"/docs/v5/otc/ltv-convert","docId":"v5/otc/ltv-convert"},{"type":"link","label":"Bind Or Unbind UID","href":"/docs/v5/otc/bind-uid","docId":"v5/otc/bind-uid"}],"collapsed":true,"collapsible":true},{"type":"category","label":"C2C Lending","items":[{"type":"link","label":"Get Lending Coin Info","href":"/docs/v5/c2c-lend/coin-info","docId":"v5/c2c-lend/coin-info"},{"type":"link","label":"Deposit Funds","href":"/docs/v5/c2c-lend/deposit","docId":"v5/c2c-lend/deposit"},{"type":"link","label":"Redeem Funds","href":"/docs/v5/c2c-lend/redeem","docId":"v5/c2c-lend/redeem"},{"type":"link","label":"Cancel Redeem","href":"/docs/v5/c2c-lend/cancel-redeem","docId":"v5/c2c-lend/cancel-redeem"},{"type":"link","label":"Get Order Records","href":"/docs/v5/c2c-lend/order-record","docId":"v5/c2c-lend/order-record"},{"type":"link","label":"Get Lending Account Info","href":"/docs/v5/c2c-lend/account-info","docId":"v5/c2c-lend/account-info"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Broker","items":[{"type":"link","label":"Get Broker Earning","href":"/docs/v5/broker/earning","docId":"v5/broker/earning"}],"collapsed":true,"collapsible":true},{"type":"category","label":"WebSocket Stream","items":[{"type":"link","label":"Connect","href":"/docs/v5/ws/connect","docId":"v5/websocket/wss-authentication"},{"type":"category","label":"Public","items":[{"type":"link","label":"Orderbook","href":"/docs/v5/websocket/public/orderbook","docId":"v5/websocket/public/orderbook"},{"type":"link","label":"Trade","href":"/docs/v5/websocket/public/trade","docId":"v5/websocket/public/trade"},{"type":"link","label":"Ticker","href":"/docs/v5/websocket/public/ticker","docId":"v5/websocket/public/ticker"},{"type":"link","label":"Kline","href":"/docs/v5/websocket/public/kline","docId":"v5/websocket/public/kline"},{"type":"link","label":"Liquidation","href":"/docs/v5/websocket/public/liquidation","docId":"v5/websocket/public/liquidation"},{"type":"link","label":"LT Kline","href":"/docs/v5/websocket/public/etp-kline","docId":"v5/websocket/public/etp-kline"},{"type":"link","label":"LT Ticker","href":"/docs/v5/websocket/public/etp-ticker","docId":"v5/websocket/public/etp-ticker"},{"type":"link","label":"LT Nav","href":"/docs/v5/websocket/public/etp-nav","docId":"v5/websocket/public/etp-nav"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Private","items":[{"type":"link","label":"Position","href":"/docs/v5/websocket/private/position","docId":"v5/websocket/private/position"},{"type":"link","label":"Execution","href":"/docs/v5/websocket/private/execution","docId":"v5/websocket/private/execution"},{"type":"link","label":"Order","href":"/docs/v5/websocket/private/order","docId":"v5/websocket/private/order"},{"type":"link","label":"Wallet","href":"/docs/v5/websocket/private/wallet","docId":"v5/websocket/private/wallet"},{"type":"link","label":"Greek","href":"/docs/v5/websocket/private/greek","docId":"v5/websocket/private/greek"},{"type":"link","label":"Dcp","href":"/docs/v5/websocket/private/dcp","docId":"v5/websocket/private/dcp"}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"link","label":"Rate Limit","href":"/docs/v5/rate-limit","docId":"v5/rate-limit"},{"type":"link","label":"Enums Definitions","href":"/docs/v5/enum","docId":"v5/enum"},{"type":"link","label":"Error Codes","href":"/docs/v5/error","docId":"v5/error"},{"type":"category","label":"Abandoned Endpoints","items":[{"type":"link","label":"Get LTV","href":"/docs/v5/abandon/ltv","docId":"v5/abandon/ltv"},{"type":"link","label":"Get Margin Coin Info","href":"/docs/v5/abandon/margin-coin-info","docId":"v5/abandon/margin-coin-info"},{"type":"link","label":"Enable Universal Transfer for Sub UID","href":"/docs/v5/abandon/enable-unitransfer-subuid","docId":"v5/abandon/enable-unitransfer-subuid"}],"collapsed":true,"collapsible":true}],"apiExplorerSideBar":[{"type":"category","label":"V5","items":[{"type":"category","label":"Market","items":[{"type":"link","label":"Get Bybit Server Time","href":"/docs/api-explorer/v5/market/time","className":"api-method get","docId":"api-explorer/v5/market/time"},{"type":"link","label":"Get Kline","href":"/docs/api-explorer/v5/market/kline","className":"api-method get","docId":"api-explorer/v5/market/kline"},{"type":"link","label":"Get Mark Price Kline","href":"/docs/api-explorer/v5/market/mark-kline","className":"api-method get","docId":"api-explorer/v5/market/mark-kline"},{"type":"link","label":"Get Index Price Kline","href":"/docs/api-explorer/v5/market/index-kline","className":"api-method get","docId":"api-explorer/v5/market/index-kline"},{"type":"link","label":"Get Premium Index Price Kline","href":"/docs/api-explorer/v5/market/premium-index-kline","className":"api-method get","docId":"api-explorer/v5/market/premium-index-kline"},{"type":"link","label":"Get Instrument Info","href":"/docs/api-explorer/v5/market/instrument","className":"api-method get","docId":"api-explorer/v5/market/instrument"},{"type":"link","label":"Get Orderbook","href":"/docs/api-explorer/v5/market/orderbook","className":"api-method get","docId":"api-explorer/v5/market/orderbook"},{"type":"link","label":"Get Tickers","href":"/docs/api-explorer/v5/market/tickers","className":"api-method get","docId":"api-explorer/v5/market/tickers"},{"type":"link","label":"Get Funding Rate History","href":"/docs/api-explorer/v5/market/history-fund-rate","className":"api-method get","docId":"api-explorer/v5/market/history-fund-rate"},{"type":"link","label":"Get Public Recent Trading History","href":"/docs/api-explorer/v5/market/recent-trade","className":"api-method get","docId":"api-explorer/v5/market/recent-trade"},{"type":"link","label":"Get Open Interest","href":"/docs/api-explorer/v5/market/open-interest","className":"api-method get","docId":"api-explorer/v5/market/open-interest"},{"type":"link","label":"Get Historical Volatility","href":"/docs/api-explorer/v5/market/iv","className":"api-method get","docId":"api-explorer/v5/market/iv"},{"type":"link","label":"Get Insurance","href":"/docs/api-explorer/v5/market/insurance","className":"api-method get","docId":"api-explorer/v5/market/insurance"},{"type":"link","label":"Get Risk Limit","href":"/docs/api-explorer/v5/market/risk-limit","className":"api-method get","docId":"api-explorer/v5/market/risk-limit"},{"type":"link","label":"Get Option Delivery Price","href":"/docs/api-explorer/v5/market/delivery-price","className":"api-method get","docId":"api-explorer/v5/market/delivery-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/market/market"},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/v5/trade/create-order","className":"api-method post","docId":"api-explorer/v5/trade/create-order"},{"type":"link","label":"Amend Order","href":"/docs/api-explorer/v5/trade/amend-order","className":"api-method post","docId":"api-explorer/v5/trade/amend-order"},{"type":"link","label":"Cancel Order","href":"/docs/api-explorer/v5/trade/cancel-order","className":"api-method post","docId":"api-explorer/v5/trade/cancel-order"},{"type":"link","label":"Get Open Orders (real-time)","href":"/docs/api-explorer/v5/trade/open-order","className":"api-method get","docId":"api-explorer/v5/trade/open-order"},{"type":"link","label":"Cancel All Orders","href":"/docs/api-explorer/v5/trade/cancel-all","className":"api-method post","docId":"api-explorer/v5/trade/cancel-all"},{"type":"link","label":"Get Order History (2 years)","href":"/docs/api-explorer/v5/trade/order-list","className":"api-method get","docId":"api-explorer/v5/trade/order-list"},{"type":"link","label":"Batch Place Order","href":"/docs/api-explorer/v5/trade/batch-place","className":"api-method post","docId":"api-explorer/v5/trade/batch-place"},{"type":"link","label":"Batch Amend Order","href":"/docs/api-explorer/v5/trade/batch-amend","className":"api-method post","docId":"api-explorer/v5/trade/batch-amend"},{"type":"link","label":"Batch Cancel Order","href":"/docs/api-explorer/v5/trade/batch-cancel","className":"api-method post","docId":"api-explorer/v5/trade/batch-cancel"},{"type":"link","label":"Get Borrow Quota (Spot)","href":"/docs/api-explorer/v5/trade/query-spot-quota","className":"api-method get","docId":"api-explorer/v5/trade/query-spot-quota"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/trade/trade"},{"type":"category","label":"Position","items":[{"type":"link","label":"Get Position Info","href":"/docs/api-explorer/v5/position/position-info","className":"api-method get","docId":"api-explorer/v5/position/position-info"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/v5/position/leverage","className":"api-method post","docId":"api-explorer/v5/position/leverage"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/api-explorer/v5/position/cross-isolate","className":"api-method post","docId":"api-explorer/v5/position/cross-isolate"},{"type":"link","label":"Set TP/SL Mode","href":"/docs/api-explorer/v5/position/tpsl-mode","className":"api-method post","docId":"api-explorer/v5/position/tpsl-mode"},{"type":"link","label":"Switch Position Mode","href":"/docs/api-explorer/v5/position/position-mode","className":"api-method post","docId":"api-explorer/v5/position/position-mode"},{"type":"link","label":"Set Risk Limit","href":"/docs/api-explorer/v5/position/set-risk-limit","className":"api-method post","docId":"api-explorer/v5/position/set-risk-limit"},{"type":"link","label":"Set Trading Stop","href":"/docs/api-explorer/v5/position/trading-stop","className":"api-method post","docId":"api-explorer/v5/position/trading-stop"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/api-explorer/v5/position/auto-add-margin","className":"api-method post","docId":"api-explorer/v5/position/auto-add-margin"},{"type":"link","label":"Add Or Reduce Margin","href":"/docs/api-explorer/v5/position/manual-add-margin","className":"api-method post","docId":"api-explorer/v5/position/manual-add-margin"},{"type":"link","label":"Get Execution (2 years)","href":"/docs/api-explorer/v5/position/execution","className":"api-method get","docId":"api-explorer/v5/position/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/api-explorer/v5/position/close-pnl","className":"api-method get","docId":"api-explorer/v5/position/close-pnl"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/position/position"},{"type":"category","label":"Account","items":[{"type":"link","label":"Get Wallet Balance","href":"/docs/api-explorer/v5/account/wallet","className":"api-method get","docId":"api-explorer/v5/account/wallet"},{"type":"link","label":"Upgrade to Unified Account","href":"/docs/api-explorer/v5/account/upgrade-unified-account","className":"api-method post","docId":"api-explorer/v5/account/upgrade-unified-account"},{"type":"link","label":"Get Borrow History","href":"/docs/api-explorer/v5/account/borrow-history","className":"api-method get","docId":"api-explorer/v5/account/borrow-history"},{"type":"link","label":"Get Collateral Info","href":"/docs/api-explorer/v5/account/collateral-info","className":"api-method get","docId":"api-explorer/v5/account/collateral-info"},{"type":"link","label":"Get Coin Greeks","href":"/docs/api-explorer/v5/account/coin-greeks","className":"api-method get","docId":"api-explorer/v5/account/coin-greeks"},{"type":"link","label":"Get Fee Rate","href":"/docs/api-explorer/v5/account/fee-rate","className":"api-method get","docId":"api-explorer/v5/account/fee-rate"},{"type":"link","label":"Get Account Info","href":"/docs/api-explorer/v5/account/account-info","className":"api-method get","docId":"api-explorer/v5/account/account-info"},{"type":"link","label":"Get Transaction Log","href":"/docs/api-explorer/v5/account/transaction-log","className":"api-method get","docId":"api-explorer/v5/account/transaction-log"},{"type":"link","label":"Set Margin Mode","href":"/docs/api-explorer/v5/account/set-margin-mode","className":"api-method post","docId":"api-explorer/v5/account/set-margin-mode"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/account/account"},{"type":"category","label":"Asset","items":[{"type":"link","label":"Get Coin Exchange Records","href":"/docs/api-explorer/v5/asset/exchange","className":"api-method get","docId":"api-explorer/v5/asset/exchange"},{"type":"link","label":"Get Option Delivery Record","href":"/docs/api-explorer/v5/asset/option-delivery","className":"api-method get","docId":"api-explorer/v5/asset/option-delivery"},{"type":"link","label":"Get USDC Perpetual Settlement","href":"/docs/api-explorer/v5/asset/settlement","className":"api-method get","docId":"api-explorer/v5/asset/settlement"},{"type":"link","label":"Get Asset Info (Spot)","href":"/docs/api-explorer/v5/asset/asset-info","className":"api-method get","docId":"api-explorer/v5/asset/asset-info"},{"type":"link","label":"Get All Coins Balance","href":"/docs/api-explorer/v5/asset/all-balance","className":"api-method get","docId":"api-explorer/v5/asset/all-balance"},{"type":"link","label":"Get Single Coin Balance","href":"/docs/api-explorer/v5/asset/account-coin-balance","className":"api-method get","docId":"api-explorer/v5/asset/account-coin-balance"},{"type":"link","label":"Get Transferable Coin","href":"/docs/api-explorer/v5/asset/transferable-coin","className":"api-method get","docId":"api-explorer/v5/asset/transferable-coin"},{"type":"link","label":"Create Internal Transfer","href":"/docs/api-explorer/v5/asset/create-inter-transfer","className":"api-method post","docId":"api-explorer/v5/asset/create-inter-transfer"},{"type":"link","label":"Get Internal Transfer Records","href":"/docs/api-explorer/v5/asset/inter-transfer-list","className":"api-method get","docId":"api-explorer/v5/asset/inter-transfer-list"},{"type":"link","label":"Get Sub UID","href":"/docs/api-explorer/v5/asset/sub-uid-list","className":"api-method get","docId":"api-explorer/v5/asset/sub-uid-list"},{"type":"link","label":"Enable Universal Transfer For Sub UID","href":"/docs/api-explorer/v5/asset/enable-unitransfer-subuid","className":"api-method post","docId":"api-explorer/v5/asset/enable-unitransfer-subuid"},{"type":"link","label":"Create Universal Transfer","href":"/docs/api-explorer/v5/asset/unitransfer","className":"api-method post","docId":"api-explorer/v5/asset/unitransfer"},{"type":"link","label":"Get Universal Transfer Records","href":"/docs/api-explorer/v5/asset/unitransfer-list","className":"api-method get","docId":"api-explorer/v5/asset/unitransfer-list"},{"type":"link","label":"Get Allowed Deposit Coin Info","href":"/docs/api-explorer/v5/asset/deposit-coin-spec","className":"api-method get","docId":"api-explorer/v5/asset/deposit-coin-spec"},{"type":"link","label":"Set Deposit Account","href":"/docs/api-explorer/v5/asset/set-deposit-acct","className":"api-method post","docId":"api-explorer/v5/asset/set-deposit-acct"},{"type":"link","label":"Get Deposit Record (on-chain)","href":"/docs/api-explorer/v5/asset/deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/deposit-record"},{"type":"link","label":"Get Sub Account Deposit Records (on-chain)","href":"/docs/api-explorer/v5/asset/sub-deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/sub-deposit-record"},{"type":"link","label":"Get Internal Deposit Records (across Bybit)","href":"/docs/api-explorer/v5/asset/internal-deposit-record","className":"api-method get","docId":"api-explorer/v5/asset/internal-deposit-record"},{"type":"link","label":"Get Master Deposit Address","href":"/docs/api-explorer/v5/asset/master-deposit-addr","className":"api-method get","docId":"api-explorer/v5/asset/master-deposit-addr"},{"type":"link","label":"Get Sub Deposit Address","href":"/docs/api-explorer/v5/asset/sub-deposit-addr","className":"api-method get","docId":"api-explorer/v5/asset/sub-deposit-addr"},{"type":"link","label":"Get Coin Info","href":"/docs/api-explorer/v5/asset/coin-info","className":"api-method get","docId":"api-explorer/v5/asset/coin-info"},{"type":"link","label":"Get Withdraw Records","href":"/docs/api-explorer/v5/asset/withdraw-record","className":"api-method get","docId":"api-explorer/v5/asset/withdraw-record"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/asset/asset"},{"type":"category","label":"User","items":[{"type":"link","label":"Get API Key Information","href":"/docs/api-explorer/v5/user/apikey-info","className":"api-method get","docId":"api-explorer/v5/user/apikey-info"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/user/user"},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"Get Leverage Token Info","href":"/docs/api-explorer/v5/lt/leverage-token-info","className":"api-method get","docId":"api-explorer/v5/lt/leverage-token-info"},{"type":"link","label":"Get Leverage Token Market","href":"/docs/api-explorer/v5/lt/leverage-token-reference","className":"api-method get","docId":"api-explorer/v5/lt/leverage-token-reference"},{"type":"link","label":"Purchase","href":"/docs/api-explorer/v5/lt/purchase","className":"api-method post","docId":"api-explorer/v5/lt/purchase"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/v5/lt/redeem","className":"api-method post","docId":"api-explorer/v5/lt/redeem"},{"type":"link","label":"Get Purchase or Redeem Records","href":"/docs/api-explorer/v5/lt/order-record","className":"api-method get","docId":"api-explorer/v5/lt/order-record"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/lt/etp"},{"type":"category","label":"Spot Margin Trade (UTA)","items":[{"type":"link","label":"Toggle Margin Trade","href":"/docs/api-explorer/v5/spot-margin-uta/switch-mode","className":"api-method post","docId":"api-explorer/v5/spot-margin-uta/switch-mode"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/v5/spot-margin-uta/set-leverage","className":"api-method post","docId":"api-explorer/v5/spot-margin-uta/set-leverage"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/spot-margin-uta/uta-margin-trade"},{"type":"category","label":"Spot Margin Trade (Normal)","items":[{"type":"link","label":"Get Margin Coin Info","href":"/docs/api-explorer/v5/spot-margin-normal/margin-data","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/margin-data"},{"type":"link","label":"Get Borrowable Coin Info","href":"/docs/api-explorer/v5/spot-margin-normal/borrowable-data","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/borrowable-data"},{"type":"link","label":"Get Interest & Quota","href":"/docs/api-explorer/v5/spot-margin-normal/interest-quota","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/interest-quota"},{"type":"link","label":"Get Loan Account Info","href":"/docs/api-explorer/v5/spot-margin-normal/account-info","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/account-info"},{"type":"link","label":"Borrow","href":"/docs/api-explorer/v5/spot-margin-normal/borrow","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/borrow"},{"type":"link","label":"Repay","href":"/docs/api-explorer/v5/spot-margin-normal/repay","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/repay"},{"type":"link","label":"Get Borrow Order Detail","href":"/docs/api-explorer/v5/spot-margin-normal/borrow-order","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/borrow-order"},{"type":"link","label":"Get Repayment Order Detail","href":"/docs/api-explorer/v5/spot-margin-normal/repay-order","className":"api-method get","docId":"api-explorer/v5/spot-margin-normal/repay-order"},{"type":"link","label":"Toggle Margin Trade","href":"/docs/api-explorer/v5/spot-margin-normal/switch-mode","className":"api-method post","docId":"api-explorer/v5/spot-margin-normal/switch-mode"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/spot-margin-normal/normal-margin-trade"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/v5/category/"},{"type":"category","label":"V3","items":[{"type":"category","label":"Derivatives","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Order Book","href":"/docs/api-explorer/derivatives/market/orderbook","className":"api-method get","docId":"api-explorer/derivatives/market/orderbook"},{"type":"link","label":"Kline","href":"/docs/api-explorer/derivatives/market/kline","className":"api-method get","docId":"api-explorer/derivatives/market/kline"},{"type":"link","label":"Ticker Info","href":"/docs/api-explorer/derivatives/market/ticker","className":"api-method get","docId":"api-explorer/derivatives/market/ticker"},{"type":"link","label":"Instrument Info","href":"/docs/api-explorer/derivatives/market/instrument","className":"api-method get","docId":"api-explorer/derivatives/market/instrument"},{"type":"link","label":"Mark Price Kline","href":"/docs/api-explorer/derivatives/market/mark-kline","className":"api-method get","docId":"api-explorer/derivatives/market/mark-kline"},{"type":"link","label":"Index Price Kline","href":"/docs/api-explorer/derivatives/market/index-kline","className":"api-method get","docId":"api-explorer/derivatives/market/index-kline"},{"type":"link","label":"Premium Index Price Kline","href":"/docs/api-explorer/derivatives/market/premium-index-kline","className":"api-method get","docId":"api-explorer/derivatives/market/premium-index-kline"},{"type":"link","label":"Public trade","href":"/docs/api-explorer/derivatives/market/public-trade","className":"api-method get","docId":"api-explorer/derivatives/market/public-trade"},{"type":"link","label":"Risk limit","href":"/docs/api-explorer/derivatives/market/risk-limit","className":"api-method get","docId":"api-explorer/derivatives/market/risk-limit"},{"type":"link","label":"Funding Rate History","href":"/docs/api-explorer/derivatives/market/his-fund-rate","className":"api-method get","docId":"api-explorer/derivatives/market/his-fund-rate"},{"type":"link","label":"Open Interest","href":"/docs/api-explorer/derivatives/market/open-interest","className":"api-method get","docId":"api-explorer/derivatives/market/open-interest"},{"type":"link","label":"Delivery price","href":"/docs/api-explorer/derivatives/market/delivery-price","className":"api-method get","docId":"api-explorer/derivatives/market/delivery-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/market/market"},{"type":"category","label":"Unified Margin Account","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/derivatives/trade/unified/create-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/create-order"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/derivatives/trade/unified/open-order","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/open-order"},{"type":"link","label":"Replace Order","href":"/docs/api-explorer/derivatives/trade/unified/replace-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/replace-order"},{"type":"link","label":"Cancl Order","href":"/docs/api-explorer/derivatives/trade/unified/cancel-order","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/cancel-order"},{"type":"link","label":"Cancl All Orders","href":"/docs/api-explorer/derivatives/trade/unified/cancel-all","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/cancel-all"},{"type":"link","label":"Batch Place Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-place","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-place"},{"type":"link","label":"Batch Replace Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-replace-place","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-replace-place"},{"type":"link","label":"Batch Cancel Order","href":"/docs/api-explorer/derivatives/trade/unified/batch-cancel","className":"api-method post","docId":"api-explorer/derivatives/trade/unified/batch-cancel"},{"type":"link","label":"Get Order List","href":"/docs/api-explorer/derivatives/trade/unified/order-list","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/order-list"},{"type":"link","label":"Get position","href":"/docs/api-explorer/derivatives/trade/unified/myposition","className":"api-method get","docId":"api-explorer/derivatives/trade/unified/myposition"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/trade/unified/unified"},{"type":"category","label":"Contract","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/derivatives/trade/contract/create-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/create-order"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/derivatives/trade/contract/open-order","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/open-order"},{"type":"link","label":"Replace Order","href":"/docs/api-explorer/derivatives/trade/contract/replace-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/replace-order"},{"type":"link","label":"Cancel Order","href":"/docs/api-explorer/derivatives/trade/contract/cancel-order","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cancel-order"},{"type":"link","label":"Cancel All Order","href":"/docs/api-explorer/derivatives/trade/contract/cancel-all","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cancel-all"},{"type":"link","label":"Get Order List","href":"/docs/api-explorer/derivatives/trade/contract/order-list","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/order-list"},{"type":"link","label":"My Position","href":"/docs/api-explorer/derivatives/trade/contract/position-info","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/position-info"},{"type":"link","label":"Set Auto Add Margin","href":"/docs/api-explorer/derivatives/trade/contract/auto-margin","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/auto-margin"},{"type":"link","label":"Switch Cross/Isolated Margin","href":"/docs/api-explorer/derivatives/trade/contract/cross-isolated-margin","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/cross-isolated-margin"},{"type":"link","label":"Switch Position Mode","href":"/docs/api-explorer/derivatives/trade/contract/position-mode","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/position-mode"},{"type":"link","label":"Switch TP/SL Mode","href":"/docs/api-explorer/derivatives/trade/contract/tpsl-mode","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/tpsl-mode"},{"type":"link","label":"Set Leverage","href":"/docs/api-explorer/derivatives/trade/contract/leverage","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/leverage"},{"type":"link","label":"Set Trading Stop","href":"/docs/api-explorer/derivatives/trade/contract/trading-stop","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/trading-stop"},{"type":"link","label":"Set Risk Limit","href":"/docs/api-explorer/derivatives/trade/contract/set-risk-limit","className":"api-method post","docId":"api-explorer/derivatives/trade/contract/set-risk-limit"},{"type":"link","label":"Get Execution List","href":"/docs/api-explorer/derivatives/trade/contract/execution","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/execution"},{"type":"link","label":"Get Closed PnL","href":"/docs/api-explorer/derivatives/trade/contract/close-pnl","className":"api-method get","docId":"api-explorer/derivatives/trade/contract/close-pnl"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/trade/contract/contract"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/derivatives/category/"},{"type":"category","label":"Spot","items":[{"type":"category","label":"Market data","items":[{"type":"link","label":"Instrument Info","href":"/docs/api-explorer/spot/market/instrument-info","className":"api-method get","docId":"api-explorer/spot/market/instrument-info"},{"type":"link","label":"Order Book","href":"/docs/api-explorer/spot/market/order-book","className":"api-method get","docId":"api-explorer/spot/market/order-book"},{"type":"link","label":"Merged Order Book","href":"/docs/api-explorer/spot/market/merged-order-book","className":"api-method get","docId":"api-explorer/spot/market/merged-order-book"},{"type":"link","label":"Public Trading Records","href":"/docs/api-explorer/spot/market/public-trading-records","className":"api-method get","docId":"api-explorer/spot/market/public-trading-records"},{"type":"link","label":"Query Kline","href":"/docs/api-explorer/spot/market/query-kline","className":"api-method get","docId":"api-explorer/spot/market/query-kline"},{"type":"link","label":"Lastest Information for Symbol","href":"/docs/api-explorer/spot/market/lastest-information-for-symbol","className":"api-method get","docId":"api-explorer/spot/market/lastest-information-for-symbol"},{"type":"link","label":"Name of the trading pair","href":"/docs/api-explorer/spot/market/last-traded-price","className":"api-method get","docId":"api-explorer/spot/market/last-traded-price"},{"type":"link","label":"Best Bid/Ask Price","href":"/docs/api-explorer/spot/market/best-bidask-price","className":"api-method get","docId":"api-explorer/spot/market/best-bidask-price"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/market/market"},{"type":"category","label":"Trade","items":[{"type":"link","label":"Place Order","href":"/docs/api-explorer/spot/trade/place-order","className":"api-method post","docId":"api-explorer/spot/trade/place-order"},{"type":"link","label":"Cancel Active Order","href":"/docs/api-explorer/spot/trade/cancel-active-order","className":"api-method post","docId":"api-explorer/spot/trade/cancel-active-order"},{"type":"link","label":"Batch Cancel Active Order","href":"/docs/api-explorer/spot/trade/batch-cancel-active-order","className":"api-method post","docId":"api-explorer/spot/trade/batch-cancel-active-order"},{"type":"link","label":"Batch Cancel Active Order By IDs","href":"/docs/api-explorer/spot/trade/batch-cancel-active-order-by-ids","className":"api-method post","docId":"api-explorer/spot/trade/batch-cancel-active-order-by-ids"},{"type":"link","label":"Get Open Orders","href":"/docs/api-explorer/spot/trade/open-order","className":"api-method get","docId":"api-explorer/spot/trade/open-order"},{"type":"link","label":"Get Order History","href":"/docs/api-explorer/spot/trade/order-history","className":"api-method get","docId":"api-explorer/spot/trade/order-history"},{"type":"link","label":"Get Trade History","href":"/docs/api-explorer/spot/trade/trade-history","className":"api-method get","docId":"api-explorer/spot/trade/trade-history"},{"type":"link","label":"Get Wallet Balance","href":"/docs/api-explorer/spot/trade/wallet-balance","className":"api-method get","docId":"api-explorer/spot/trade/wallet-balance"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/trade/spot-trade"},{"type":"category","label":"Spot Leverage Token","items":[{"type":"link","label":"All Asset Infos","href":"/docs/api-explorer/spot/lttrade/all-asset-info","className":"api-method get","docId":"api-explorer/spot/lttrade/all-asset-info"},{"type":"link","label":"Market Info","href":"/docs/api-explorer/spot/lttrade/market-info","className":"api-method get","docId":"api-explorer/spot/lttrade/market-info"},{"type":"link","label":"Purchase","href":"/docs/api-explorer/spot/lttrade/purchase","className":"api-method post","docId":"api-explorer/spot/lttrade/purchase"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/spot/lttrade/redeem","className":"api-method post","docId":"api-explorer/spot/lttrade/redeem"},{"type":"link","label":"Get Purchase or Redemption History","href":"/docs/api-explorer/spot/lttrade/purchase-redemption-history","className":"api-method get","docId":"api-explorer/spot/lttrade/purchase-redemption-history"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/lttrade/etp"},{"type":"category","label":"Spot Margin Trade","items":[{"type":"link","label":"Borrow Margin Loan","href":"/docs/api-explorer/spot/crossmargin/borrow-margin-loan","className":"api-method post","docId":"api-explorer/spot/crossmargin/borrow-margin-loan"},{"type":"link","label":"Redeem","href":"/docs/api-explorer/spot/crossmargin/redeem","className":"api-method post","docId":"api-explorer/spot/crossmargin/redeem"},{"type":"link","label":"Query Borrowing Info","href":"/docs/api-explorer/spot/crossmargin/query-borrowing-info","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-borrowing-info"},{"type":"link","label":"Query Account Info","href":"/docs/api-explorer/spot/crossmargin/query-account-info","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-account-info"},{"type":"link","label":"Query Interest and Quota","href":"/docs/api-explorer/spot/crossmargin/query-interest-quota","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-interest-quota"},{"type":"link","label":"Query Repayment History","href":"/docs/api-explorer/spot/crossmargin/query-repayment-history","className":"api-method get","docId":"api-explorer/spot/crossmargin/query-repayment-history"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/crossmargin/crossmargin"}],"collapsed":true,"collapsible":true,"href":"/docs/api-explorer/spot/category/"}],"collapsed":true,"collapsible":true}],"changelogSidebar":[{"type":"link","label":"V5","href":"/docs/changelog/v5","docId":"changelog/v5"},{"type":"link","label":"Derivatives V3","href":"/docs/changelog/derivatives-v3","docId":"changelog/derivatives-v3"},{"type":"link","label":"Spot V3","href":"/docs/changelog/spot-v3","docId":"changelog/spot-v3"},{"type":"link","label":"Account Asset V3","href":"/docs/changelog/asset-v3","docId":"changelog/asset-v3"},{"type":"link","label":"Copy Trading","href":"/docs/changelog/copytrade","docId":"changelog/copytrade"}]},"docs":{"account_asset":{"id":"account_asset","title":"account_asset","description":"const Home = () => {"},"account_asset/v1":{"id":"account_asset/v1","title":"v1","description":"const Home = () => {"},"account_asset/v3":{"id":"account_asset/v3","title":"v3","description":"const Home = () => {"},"api-explorer/derivatives/market/delivery-price":{"id":"api-explorer/derivatives/market/delivery-price","title":"Delivery price","description":"Get delivery price of option","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/his-fund-rate":{"id":"api-explorer/derivatives/market/his-fund-rate","title":"Funding Rate History","description":"Get historical funding rate","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/index-kline":{"id":"api-explorer/derivatives/market/index-kline","title":"Index Price Kline","description":"Get index price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/instrument":{"id":"api-explorer/derivatives/market/instrument","title":"Instrument Info","description":"Get launched instruments information. `category`=option is required for option.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/kline":{"id":"api-explorer/derivatives/market/kline","title":"Kline","description":"Get kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/mark-kline":{"id":"api-explorer/derivatives/market/mark-kline","title":"Mark Price Kline","description":"Get mark price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/market":{"id":"api-explorer/derivatives/market/market","title":"Market data","description":"Market data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/open-interest":{"id":"api-explorer/derivatives/market/open-interest","title":"Open Interest","description":"Get open interest","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/orderbook":{"id":"api-explorer/derivatives/market/orderbook","title":"Order Book","description":"Get order book data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/premium-index-kline":{"id":"api-explorer/derivatives/market/premium-index-kline","title":"Premium Index Price Kline","description":"Get premium index price kline data","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/public-trade":{"id":"api-explorer/derivatives/market/public-trade","title":"Public trade","description":"Get public trade","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/risk-limit":{"id":"api-explorer/derivatives/market/risk-limit","title":"Risk limit","description":"Get risk limit","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/market/ticker":{"id":"api-explorer/derivatives/market/ticker","title":"Ticker Info","description":"Get all latest information of symbols. All parameters are needed for OPTION","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/auto-margin":{"id":"api-explorer/derivatives/trade/contract/auto-margin","title":"Set Auto Add Margin","description":"Turn on/off auto add position margin.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cancel-all":{"id":"api-explorer/derivatives/trade/contract/cancel-all","title":"Cancel All Order","description":"Cancel all orders.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cancel-order":{"id":"api-explorer/derivatives/trade/contract/cancel-order","title":"Cancel Order","description":"Cancel a order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/close-pnl":{"id":"api-explorer/derivatives/trade/contract/close-pnl","title":"Get Closed PnL","description":"Get closed pnl.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/contract":{"id":"api-explorer/derivatives/trade/contract/contract","title":"Contract","description":"Contract","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/create-order":{"id":"api-explorer/derivatives/trade/contract/create-order","title":"Place Order","description":"Place a future or option order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/cross-isolated-margin":{"id":"api-explorer/derivatives/trade/contract/cross-isolated-margin","title":"Switch Cross/Isolated Margin","description":"Switch cross/isolated margin mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/execution":{"id":"api-explorer/derivatives/trade/contract/execution","title":"Get Execution List","description":"Get execution list.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/leverage":{"id":"api-explorer/derivatives/trade/contract/leverage","title":"Set Leverage","description":"Set levearage.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/open-order":{"id":"api-explorer/derivatives/trade/contract/open-order","title":"Get Open Orders","description":"Get unfilled orders.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/order-list":{"id":"api-explorer/derivatives/trade/contract/order-list","title":"Get Order List","description":"Get order history.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/position-info":{"id":"api-explorer/derivatives/trade/contract/position-info","title":"My Position","description":"Get real-time position data.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/position-mode":{"id":"api-explorer/derivatives/trade/contract/position-mode","title":"Switch Position Mode","description":"Switch position mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/replace-order":{"id":"api-explorer/derivatives/trade/contract/replace-order","title":"Replace Order","description":"Replace an order.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/set-risk-limit":{"id":"api-explorer/derivatives/trade/contract/set-risk-limit","title":"Set Risk Limit","description":"Set risk limit.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/tpsl-mode":{"id":"api-explorer/derivatives/trade/contract/tpsl-mode","title":"Switch TP/SL Mode","description":"Switch tp/sl mode.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/contract/trading-stop":{"id":"api-explorer/derivatives/trade/contract/trading-stop","title":"Set Trading Stop","description":"Set trade stop.","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-cancel":{"id":"api-explorer/derivatives/trade/unified/batch-cancel","title":"Batch Cancel Order","description":"Batch cancel orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-place":{"id":"api-explorer/derivatives/trade/unified/batch-place","title":"Batch Place Order","description":"Batch place orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/batch-replace-place":{"id":"api-explorer/derivatives/trade/unified/batch-replace-place","title":"Batch Replace Order","description":"Batch replace orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/cancel-all":{"id":"api-explorer/derivatives/trade/unified/cancel-all","title":"Cancl All Orders","description":"Cancel all orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/cancel-order":{"id":"api-explorer/derivatives/trade/unified/cancel-order","title":"Cancl Order","description":"Cancel a future or option order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/create-order":{"id":"api-explorer/derivatives/trade/unified/create-order","title":"Place Order","description":"Place a future or option order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/myposition":{"id":"api-explorer/derivatives/trade/unified/myposition","title":"Get position","description":"Get your position info","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/open-order":{"id":"api-explorer/derivatives/trade/unified/open-order","title":"Get Open Orders","description":"Get unfilled orders","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/order-list":{"id":"api-explorer/derivatives/trade/unified/order-list","title":"Get Order List","description":"Get order list","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/replace-order":{"id":"api-explorer/derivatives/trade/unified/replace-order","title":"Replace Order","description":"Replace an order","sidebar":"apiExplorerSideBar"},"api-explorer/derivatives/trade/unified/unified":{"id":"api-explorer/derivatives/trade/unified/unified","title":"Unified Margin Account","description":"Unified Margin Account","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/borrow-margin-loan":{"id":"api-explorer/spot/crossmargin/borrow-margin-loan","title":"Borrow Margin Loan","description":"Borrow Margin Loan","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/crossmargin":{"id":"api-explorer/spot/crossmargin/crossmargin","title":"Spot Margin Trade","description":"Spot Margin Trade","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-account-info":{"id":"api-explorer/spot/crossmargin/query-account-info","title":"Query Account Info","description":"Query Account Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-borrowing-info":{"id":"api-explorer/spot/crossmargin/query-borrowing-info","title":"Query Borrowing Info","description":"Query Borrowing Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-interest-quota":{"id":"api-explorer/spot/crossmargin/query-interest-quota","title":"Query Interest and Quota","description":"Query Interest and Quota","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/query-repayment-history":{"id":"api-explorer/spot/crossmargin/query-repayment-history","title":"Query Repayment History","description":"Query Repayment History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/crossmargin/redeem":{"id":"api-explorer/spot/crossmargin/redeem","title":"Redeem","description":"Redeem","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/all-asset-info":{"id":"api-explorer/spot/lttrade/all-asset-info","title":"All Asset Infos","description":"Get All Asset Infos","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/etp":{"id":"api-explorer/spot/lttrade/etp","title":"Spot Leverage Token","description":"Spot Leverage Token","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/market-info":{"id":"api-explorer/spot/lttrade/market-info","title":"Market Info","description":"Get Market Info","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/purchase":{"id":"api-explorer/spot/lttrade/purchase","title":"Purchase","description":"Purchase","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/purchase-redemption-history":{"id":"api-explorer/spot/lttrade/purchase-redemption-history","title":"Get Purchase or Redemption History","description":"Get Purchase or Redemption History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/lttrade/redeem":{"id":"api-explorer/spot/lttrade/redeem","title":"Redeem","description":"Redeem","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/best-bidask-price":{"id":"api-explorer/spot/market/best-bidask-price","title":"Best Bid/Ask Price","description":"Get Best Bid/Ask Price","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/instrument-info":{"id":"api-explorer/spot/market/instrument-info","title":"Instrument Info","description":"Get the spec of spot symbols","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/last-traded-price":{"id":"api-explorer/spot/market/last-traded-price","title":"Name of the trading pair","description":"Get Last Traded Price","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/lastest-information-for-symbol":{"id":"api-explorer/spot/market/lastest-information-for-symbol","title":"Lastest Information for Symbol","description":"Get Lastest Information for Symbol","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/market":{"id":"api-explorer/spot/market/market","title":"Market data","description":"Market data","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/merged-order-book":{"id":"api-explorer/spot/market/merged-order-book","title":"Merged Order Book","description":"Get Merged Order Book","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/order-book":{"id":"api-explorer/spot/market/order-book","title":"Order Book","description":"Get Order Book","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/public-trading-records":{"id":"api-explorer/spot/market/public-trading-records","title":"Public Trading Records","description":"Get Public Trading Records","sidebar":"apiExplorerSideBar"},"api-explorer/spot/market/query-kline":{"id":"api-explorer/spot/market/query-kline","title":"Query Kline","description":"Get Kline","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/batch-cancel-active-order":{"id":"api-explorer/spot/trade/batch-cancel-active-order","title":"Batch Cancel Active Order","description":"Batch Cancel Active Order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/batch-cancel-active-order-by-ids":{"id":"api-explorer/spot/trade/batch-cancel-active-order-by-ids","title":"Batch Cancel Active Order By IDs","description":"Batch Cancel Active Order By IDs","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/cancel-active-order":{"id":"api-explorer/spot/trade/cancel-active-order","title":"Cancel Active Order","description":"Cancel Active Order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/open-order":{"id":"api-explorer/spot/trade/open-order","title":"Get Open Orders","description":"Get Open Orders.","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/order-history":{"id":"api-explorer/spot/trade/order-history","title":"Get Order History","description":"Get Order History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/place-order":{"id":"api-explorer/spot/trade/place-order","title":"Place Order","description":"Place a order","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/spot-trade":{"id":"api-explorer/spot/trade/spot-trade","title":"Trade","description":"Trade","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/trade-history":{"id":"api-explorer/spot/trade/trade-history","title":"Get Trade History","description":"Get Trade History","sidebar":"apiExplorerSideBar"},"api-explorer/spot/trade/wallet-balance":{"id":"api-explorer/spot/trade/wallet-balance","title":"Get Wallet Balance","description":"Get Wallet Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/account":{"id":"api-explorer/v5/account/account","title":"Account","description":"Account","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/account-info":{"id":"api-explorer/v5/account/account-info","title":"Get Account Info","description":"Get account info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/borrow-history":{"id":"api-explorer/v5/account/borrow-history","title":"Get Borrow History","description":"Get borrow history","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/coin-greeks":{"id":"api-explorer/v5/account/coin-greeks","title":"Get Coin Greeks","description":"Get coin greek info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/collateral-info":{"id":"api-explorer/v5/account/collateral-info","title":"Get Collateral Info","description":"Get collateral info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/fee-rate":{"id":"api-explorer/v5/account/fee-rate","title":"Get Fee Rate","description":"Get fee rate","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/set-margin-mode":{"id":"api-explorer/v5/account/set-margin-mode","title":"Set Margin Mode","description":"Set margin mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/transaction-log":{"id":"api-explorer/v5/account/transaction-log","title":"Get Transaction Log","description":"Get transaction log","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/upgrade-unified-account":{"id":"api-explorer/v5/account/upgrade-unified-account","title":"Upgrade to Unified Account","description":"Upgrade to UTA","sidebar":"apiExplorerSideBar"},"api-explorer/v5/account/wallet":{"id":"api-explorer/v5/account/wallet","title":"Get Wallet Balance","description":"Get wallet balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/account-coin-balance":{"id":"api-explorer/v5/asset/account-coin-balance","title":"Get Single Coin Balance","description":"Get Single Coin Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/all-balance":{"id":"api-explorer/v5/asset/all-balance","title":"Get All Coins Balance","description":"Get All Coins Balance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/asset":{"id":"api-explorer/v5/asset/asset","title":"Asset","description":"Asset","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/asset-info":{"id":"api-explorer/v5/asset/asset-info","title":"Get Asset Info (Spot)","description":"Get spot asset","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/coin-info":{"id":"api-explorer/v5/asset/coin-info","title":"Get Coin Info","description":"Get coin info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/create-inter-transfer":{"id":"api-explorer/v5/asset/create-inter-transfer","title":"Create Internal Transfer","description":"Create internal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/deposit-coin-spec":{"id":"api-explorer/v5/asset/deposit-coin-spec","title":"Get Allowed Deposit Coin Info","description":"Get allowed deposit coin info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/deposit-record":{"id":"api-explorer/v5/asset/deposit-record","title":"Get Deposit Record (on-chain)","description":"Get deposit record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/enable-unitransfer-subuid":{"id":"api-explorer/v5/asset/enable-unitransfer-subuid","title":"Enable Universal Transfer For Sub UID","description":"Enable sub uid for universal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/exchange":{"id":"api-explorer/v5/asset/exchange","title":"Get Coin Exchange Records","description":"Get exchange records","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/inter-transfer-list":{"id":"api-explorer/v5/asset/inter-transfer-list","title":"Get Internal Transfer Records","description":"Get internal transfer records","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/internal-deposit-record":{"id":"api-explorer/v5/asset/internal-deposit-record","title":"Get Internal Deposit Records (across Bybit)","description":"Get deposit records through Bybit platform","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/master-deposit-addr":{"id":"api-explorer/v5/asset/master-deposit-addr","title":"Get Master Deposit Address","description":"Get master deposit address","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/option-delivery":{"id":"api-explorer/v5/asset/option-delivery","title":"Get Option Delivery Record","description":"Get delivery record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/set-deposit-acct":{"id":"api-explorer/v5/asset/set-deposit-acct","title":"Set Deposit Account","description":"Set Deposit Account","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/settlement":{"id":"api-explorer/v5/asset/settlement","title":"Get USDC Perpetual Settlement","description":"Get Settlement Record.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-deposit-addr":{"id":"api-explorer/v5/asset/sub-deposit-addr","title":"Get Sub Deposit Address","description":"Get sub deposit address","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-deposit-record":{"id":"api-explorer/v5/asset/sub-deposit-record","title":"Get Sub Account Deposit Records (on-chain)","description":"Get sub account deposit record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/sub-uid-list":{"id":"api-explorer/v5/asset/sub-uid-list","title":"Get Sub UID","description":"Get sub uid","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/transferable-coin":{"id":"api-explorer/v5/asset/transferable-coin","title":"Get Transferable Coin","description":"Get transferable coins","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/unitransfer":{"id":"api-explorer/v5/asset/unitransfer","title":"Create Universal Transfer","description":"Create universal transfer","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/unitransfer-list":{"id":"api-explorer/v5/asset/unitransfer-list","title":"Get Universal Transfer Records","description":"Get universal transfer record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/asset/withdraw-record":{"id":"api-explorer/v5/asset/withdraw-record","title":"Get Withdraw Records","description":"Get withdraw record","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/etp":{"id":"api-explorer/v5/lt/etp","title":"Spot Leverage Token","description":"Spot Leverage Token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/leverage-token-info":{"id":"api-explorer/v5/lt/leverage-token-info","title":"Get Leverage Token Info","description":"Get lt information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/leverage-token-reference":{"id":"api-explorer/v5/lt/leverage-token-reference","title":"Get Leverage Token Market","description":"Get lt market information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/order-record":{"id":"api-explorer/v5/lt/order-record","title":"Get Purchase or Redeem Records","description":"Get the order history of purchase or redeem","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/purchase":{"id":"api-explorer/v5/lt/purchase","title":"Purchase","description":"Purchase leverage token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/lt/redeem":{"id":"api-explorer/v5/lt/redeem","title":"Redeem","description":"Redeem leverage token","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/delivery-price":{"id":"api-explorer/v5/market/delivery-price","title":"Get Option Delivery Price","description":"Get delivery price of option","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/history-fund-rate":{"id":"api-explorer/v5/market/history-fund-rate","title":"Get Funding Rate History","description":"Get historical funding rate","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/index-kline":{"id":"api-explorer/v5/market/index-kline","title":"Get Index Price Kline","description":"Get Index Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/instrument":{"id":"api-explorer/v5/market/instrument","title":"Get Instrument Info","description":"Get launched instruments information.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/insurance":{"id":"api-explorer/v5/market/insurance","title":"Get Insurance","description":"Get Insurance","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/iv":{"id":"api-explorer/v5/market/iv","title":"Get Historical Volatility","description":"Get historical volatility","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/kline":{"id":"api-explorer/v5/market/kline","title":"Get Kline","description":"Get kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/mark-kline":{"id":"api-explorer/v5/market/mark-kline","title":"Get Mark Price Kline","description":"Get Mark Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/market":{"id":"api-explorer/v5/market/market","title":"Market","description":"Market","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/open-interest":{"id":"api-explorer/v5/market/open-interest","title":"Get Open Interest","description":"Get open interest","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/orderbook":{"id":"api-explorer/v5/market/orderbook","title":"Get Orderbook","description":"Get order book data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/premium-index-kline":{"id":"api-explorer/v5/market/premium-index-kline","title":"Get Premium Index Price Kline","description":"Get Premium Index Price Kline data","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/recent-trade":{"id":"api-explorer/v5/market/recent-trade","title":"Get Public Recent Trading History","description":"Get public trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/risk-limit":{"id":"api-explorer/v5/market/risk-limit","title":"Get Risk Limit","description":"Get risk limit","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/tickers":{"id":"api-explorer/v5/market/tickers","title":"Get Tickers","description":"Get all latest information of symbols. All parameters are needed for OPTION","sidebar":"apiExplorerSideBar"},"api-explorer/v5/market/time":{"id":"api-explorer/v5/market/time","title":"Get Bybit Server Time","description":"Get server time","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/auto-add-margin":{"id":"api-explorer/v5/position/auto-add-margin","title":"Set Auto Add Margin","description":"Set Auto Add Margin","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/close-pnl":{"id":"api-explorer/v5/position/close-pnl","title":"Get Closed PnL","description":"Get closed pnl","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/cross-isolate":{"id":"api-explorer/v5/position/cross-isolate","title":"Switch Cross/Isolated Margin","description":"Select cross margin mode or isolated margin mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/execution":{"id":"api-explorer/v5/position/execution","title":"Get Execution (2 years)","description":"Get execution list","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/leverage":{"id":"api-explorer/v5/position/leverage","title":"Set Leverage","description":"Set levearage.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/manual-add-margin":{"id":"api-explorer/v5/position/manual-add-margin","title":"Add Or Reduce Margin","description":"Manually add or reduce margin for isolated margin position","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position":{"id":"api-explorer/v5/position/position","title":"Position","description":"Position","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position-info":{"id":"api-explorer/v5/position/position-info","title":"Get Position Info","description":"Get Position Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/position-mode":{"id":"api-explorer/v5/position/position-mode","title":"Switch Position Mode","description":"Switch Position Mode","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/set-risk-limit":{"id":"api-explorer/v5/position/set-risk-limit","title":"Set Risk Limit","description":"Set risk limit.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/tpsl-mode":{"id":"api-explorer/v5/position/tpsl-mode","title":"Set TP/SL Mode","description":"Set tp/sl mode.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/position/trading-stop":{"id":"api-explorer/v5/position/trading-stop","title":"Set Trading Stop","description":"Set trade stop.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/account-info":{"id":"api-explorer/v5/spot-margin-normal/account-info","title":"Get Loan Account Info","description":"Get Loan Account Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrow":{"id":"api-explorer/v5/spot-margin-normal/borrow","title":"Borrow","description":"Borrow","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrow-order":{"id":"api-explorer/v5/spot-margin-normal/borrow-order","title":"Get Borrow Order Detail","description":"Get Borrow Order Detail","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/borrowable-data":{"id":"api-explorer/v5/spot-margin-normal/borrowable-data","title":"Get Borrowable Coin Info","description":"Get Borrowable Coin Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/interest-quota":{"id":"api-explorer/v5/spot-margin-normal/interest-quota","title":"Get Interest & Quota","description":"Get Interest & Quota","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/margin-data":{"id":"api-explorer/v5/spot-margin-normal/margin-data","title":"Get Margin Coin Info","description":"Get Margin Coin Info","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/normal-margin-trade":{"id":"api-explorer/v5/spot-margin-normal/normal-margin-trade","title":"Spot Margin Trade (Normal)","description":"Spot Margin Trade (Normal)","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/repay":{"id":"api-explorer/v5/spot-margin-normal/repay","title":"Repay","description":"Repay","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/repay-order":{"id":"api-explorer/v5/spot-margin-normal/repay-order","title":"Get Repayment Order Detail","description":"Get Repayment Order Detail","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-normal/switch-mode":{"id":"api-explorer/v5/spot-margin-normal/switch-mode","title":"Toggle Margin Trade","description":"Toggle Margin Trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/set-leverage":{"id":"api-explorer/v5/spot-margin-uta/set-leverage","title":"Set Leverage","description":"Set leverage for margin trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/switch-mode":{"id":"api-explorer/v5/spot-margin-uta/switch-mode","title":"Toggle Margin Trade","description":"Toggle margin trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/spot-margin-uta/uta-margin-trade":{"id":"api-explorer/v5/spot-margin-uta/uta-margin-trade","title":"Spot Margin Trade (UTA)","description":"Spot Margin Trade (UTA)","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/amend-order":{"id":"api-explorer/v5/trade/amend-order","title":"Amend Order","description":"Amend an order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-amend":{"id":"api-explorer/v5/trade/batch-amend","title":"Batch Amend Order","description":"Batch amend orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-cancel":{"id":"api-explorer/v5/trade/batch-cancel","title":"Batch Cancel Order","description":"Batch cancel orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/batch-place":{"id":"api-explorer/v5/trade/batch-place","title":"Batch Place Order","description":"Batch place orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/cancel-all":{"id":"api-explorer/v5/trade/cancel-all","title":"Cancel All Orders","description":"Cancel all orders.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/cancel-order":{"id":"api-explorer/v5/trade/cancel-order","title":"Cancel Order","description":"Cancel a single order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/create-order":{"id":"api-explorer/v5/trade/create-order","title":"Place Order","description":"Place an order.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/open-order":{"id":"api-explorer/v5/trade/open-order","title":"Get Open Orders (real-time)","description":"Get unfilled orders or partially filled orders","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/order-list":{"id":"api-explorer/v5/trade/order-list","title":"Get Order History (2 years)","description":"Get order history.","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/query-spot-quota":{"id":"api-explorer/v5/trade/query-spot-quota","title":"Get Borrow Quota (Spot)","description":"Query user\'s spot available quota","sidebar":"apiExplorerSideBar"},"api-explorer/v5/trade/trade":{"id":"api-explorer/v5/trade/trade","title":"Trade","description":"Trade","sidebar":"apiExplorerSideBar"},"api-explorer/v5/user/apikey-info":{"id":"api-explorer/v5/user/apikey-info","title":"Get API Key Information","description":"Get API Key Information","sidebar":"apiExplorerSideBar"},"api-explorer/v5/user/user":{"id":"api-explorer/v5/user/user","title":"User","description":"User","sidebar":"apiExplorerSideBar"},"changelog/asset-v3":{"id":"changelog/asset-v3","title":"Account Asset V3","description":"2023-09-18","sidebar":"changelogSidebar"},"changelog/copytrade":{"id":"changelog/copytrade","title":"Copy Trading","description":"2023-06-24","sidebar":"changelogSidebar"},"changelog/derivatives-v3":{"id":"changelog/derivatives-v3","title":"Derivatives V3","description":"2023-10-25","sidebar":"changelogSidebar"},"changelog/spot-v3":{"id":"changelog/spot-v3","title":"Spot V3","description":"2023-04-20","sidebar":"changelogSidebar"},"changelog/v5":{"id":"changelog/v5","title":"V5","description":"2023-11-08","sidebar":"changelogSidebar"},"copy_trading":{"id":"copy_trading","title":"copy_trading","description":"const Home = () => {"},"derivativesV3/contract":{"id":"derivativesV3/contract","title":"contract","description":"const Home = () => {"},"derivativesV3/unified_margin":{"id":"derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"faq":{"id":"faq","title":"Frequently Asked Questions","description":"Where are Bybit\'s servers located?"},"futuresV2/inverse":{"id":"futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"futuresV2/inverse_futures":{"id":"futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"futuresV2/linear":{"id":"futuresV2/linear","title":"linear","description":"const Home = () => {"},"inverse":{"id":"inverse","title":"inverse","description":"const Home = () => {"},"inverse_futures":{"id":"inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"linear":{"id":"linear","title":"linear","description":"const Home = () => {"},"pilot-feature/pilot":{"id":"pilot-feature/pilot","title":"Pilot Features","description":"Spot Supports Amend Order"},"spot":{"id":"spot","title":"spot","description":"const Home = () => {"},"spot/v1":{"id":"spot/v1","title":"v1","description":"const Home = () => {"},"spot/v3":{"id":"spot/v3","title":"v3","description":"const Home = () => {"},"tax":{"id":"tax","title":"tax","description":"const Home = () => {"},"testnet/account_asset":{"id":"testnet/account_asset","title":"account_asset","description":"const Home = () => {"},"testnet/account_asset/v1":{"id":"testnet/account_asset/v1","title":"v1","description":"const Home = () => {"},"testnet/account_asset/v3":{"id":"testnet/account_asset/v3","title":"v3","description":"const Home = () => {"},"testnet/copy_trading":{"id":"testnet/copy_trading","title":"copy_trading","description":"const Home = () => {"},"testnet/derivativesV3/contract":{"id":"testnet/derivativesV3/contract","title":"contract","description":"const Home = () => {"},"testnet/derivativesV3/unified_margin":{"id":"testnet/derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"testnet/futuresV2/inverse":{"id":"testnet/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"testnet/futuresV2/inverse_futures":{"id":"testnet/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"testnet/futuresV2/linear":{"id":"testnet/futuresV2/linear","title":"linear","description":"const Home = () => {"},"testnet/inverse":{"id":"testnet/inverse","title":"inverse","description":"const Home = () => {"},"testnet/inverse_futures":{"id":"testnet/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"testnet/linear":{"id":"testnet/linear","title":"linear","description":"const Home = () => {"},"testnet/spot":{"id":"testnet/spot","title":"spot","description":"const Home = () => {"},"testnet/spot/v1":{"id":"testnet/spot/v1","title":"v1","description":"const Home = () => {"},"testnet/spot/v3":{"id":"testnet/spot/v3","title":"v3","description":"const Home = () => {"},"testnet/tax":{"id":"testnet/tax","title":"tax","description":"const Home = () => {"},"testnet/usdc/option":{"id":"testnet/usdc/option","title":"option","description":"const Home = () => {"},"testnet/usdc/perpetual":{"id":"testnet/usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"usdc/option":{"id":"usdc/option","title":"option","description":"const Home = () => {"},"usdc/perpetual":{"id":"usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"v3/account-asset/enum":{"id":"v3/account-asset/enum","title":"Enums Definitions","description":"accountType","sidebar":"v3SideBar"},"v3/account-asset/error":{"id":"v3/account-asset/error","title":"Error Code","description":"|Code |Description |","sidebar":"v3SideBar"},"v3/account-asset/rate-limit":{"id":"v3/account-asset/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/account-asset/transfer/all-balance":{"id":"v3/account-asset/transfer/all-balance","title":"Get All Coins Balance","description":"You could get all coins balance of all account types under the master account, and sub account.","sidebar":"v3SideBar"},"v3/account-asset/transfer/asset-info":{"id":"v3/account-asset/transfer/asset-info","title":"Get Asset Info","description":"Can query SPOT asset information only","sidebar":"v3SideBar"},"v3/account-asset/transfer/coin-balance":{"id":"v3/account-asset/transfer/coin-balance","title":"Get Single Coin Balance","description":"You could get a single coin balance under the master account, and sub account coin balance.","sidebar":"v3SideBar"},"v3/account-asset/transfer/enable-uni-transfer":{"id":"v3/account-asset/transfer/enable-uni-transfer","title":"Enable Universal Transfer (Depreciated)","description":"Enable Universal Transfer","sidebar":"v3SideBar"},"v3/account-asset/transfer/internal-transfer":{"id":"v3/account-asset/transfer/internal-transfer","title":"Create Internal Transfer","description":"Transfers funds between the different sections of an individual\'s account (not between subaccounts). For example, between the spot and derivatives accounts.","sidebar":"v3SideBar"},"v3/account-asset/transfer/internal-transfer-list":{"id":"v3/account-asset/transfer/internal-transfer-list","title":"Get Internal Transfer List","description":"Query Internal Transfer List","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-list":{"id":"v3/account-asset/transfer/subacct-list","title":"Get Subaccount UID List","description":"Query Subaccount List","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-transfer":{"id":"v3/account-asset/transfer/subacct-transfer","title":"Create Subaccount Transfer","description":"Transfer funds between the parent and child (sub) accounts.","sidebar":"v3SideBar"},"v3/account-asset/transfer/subacct-transfer-list":{"id":"v3/account-asset/transfer/subacct-transfer-list","title":"Get Master-Sub Transfer List","description":"Query subaccount transfer list","sidebar":"v3SideBar"},"v3/account-asset/transfer/transferable-coin-list":{"id":"v3/account-asset/transfer/transferable-coin-list","title":"Get Transferable Coin List","description":"Transferable coin list","sidebar":"v3SideBar"},"v3/account-asset/transfer/uni-transfer":{"id":"v3/account-asset/transfer/uni-transfer","title":"Create Universal Transfer","description":"Create Universal Transfer","sidebar":"v3SideBar"},"v3/account-asset/transfer/uni-transfer-list":{"id":"v3/account-asset/transfer/uni-transfer-list","title":"Get Universal Transfer List","description":"Query Universal Transfer List","sidebar":"v3SideBar"},"v3/account-asset/user/apikey-info":{"id":"v3/account-asset/user/apikey-info","title":"Get API Key Information","description":"Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user\'s api key are applicable.","sidebar":"v3SideBar"},"v3/account-asset/user/create-subuid":{"id":"v3/account-asset/user/create-subuid","title":"Create Sub UID","description":"Create a new sub user id. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/create-subuid-apikey":{"id":"v3/account-asset/user/create-subuid-apikey","title":"Create Sub UID API Key","description":"To create new API key for those newly created sub UID. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/froze-subuid":{"id":"v3/account-asset/user/froze-subuid","title":"Froze Sub UID","description":"Froze sub uid. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/modify-master-apikey":{"id":"v3/account-asset/user/modify-master-apikey","title":"Modify Master API Key","description":"Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/modify-sub-apikey":{"id":"v3/account-asset/user/modify-sub-apikey","title":"Modify Sub API Key","description":"Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master","sidebar":"v3SideBar"},"v3/account-asset/user/rm-master-apikey":{"id":"v3/account-asset/user/rm-master-apikey","title":"Delete Master API Key","description":"Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/rm-sub-apikey":{"id":"v3/account-asset/user/rm-sub-apikey","title":"Delete Sub API Key","description":"Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key","sidebar":"v3SideBar"},"v3/account-asset/user/subuid-list":{"id":"v3/account-asset/user/subuid-list","title":"Get Sub UID List","description":"Get all sub uid of master account. Use master user\'s api key only.","sidebar":"v3SideBar"},"v3/account-asset/user/wallet-type":{"id":"v3/account-asset/user/wallet-type","title":"Get UID Wallet Type","description":"Get available wallet types for the master account or sub account","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/cancel-withdraw":{"id":"v3/account-asset/withdraw-deposit/cancel-withdraw","title":"Cancel withdrawal","description":"Cancel withdrawal","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/coin-info":{"id":"v3/account-asset/withdraw-deposit/coin-info","title":"Get Coin Information","description":"Query Coin Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/deplay-amount":{"id":"v3/account-asset/withdraw-deposit/deplay-amount","title":"Get Delay Withdraw Amount","description":"How can partial funds be subject to delayed withdrawal requests?","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/deposit-spec":{"id":"v3/account-asset/withdraw-deposit/deposit-spec","title":"Get Deposit Spec","description":"Query deposit spec.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/internal-deposit-record":{"id":"v3/account-asset/withdraw-deposit/internal-deposit-record","title":"Get Internal Deposit Records (across Bybit)","description":"Query deposit records through Bybit platform","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/master-deposit-addr":{"id":"v3/account-asset/withdraw-deposit/master-deposit-addr","title":"Get Master Acct Deposit Address Info","description":"Query Master Acct Deposit Address Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/master-deposit-record":{"id":"v3/account-asset/withdraw-deposit/master-deposit-record","title":"Get Deposit Records (on chain)","description":"Query Deposit Records","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/set-deposit-acct":{"id":"v3/account-asset/withdraw-deposit/set-deposit-acct","title":"Set Deposit Account","description":"Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/sub-deposit-addr":{"id":"v3/account-asset/withdraw-deposit/sub-deposit-addr","title":"Get Sub Acct Deposit Address Info","description":"Query Sub Acct Deposit Address Information","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/sub-deposit-record":{"id":"v3/account-asset/withdraw-deposit/sub-deposit-record","title":"Get Sub Deposit Records (on chain)","description":"Query Sub Deposit Records By Master Key","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/withdraw":{"id":"v3/account-asset/withdraw-deposit/withdraw","title":"Withdraw","description":"Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.","sidebar":"v3SideBar"},"v3/account-asset/withdraw-deposit/withdraw-record":{"id":"v3/account-asset/withdraw-deposit/withdraw-record","title":"Get Withdraw Records","description":"Query Withdraw Records","sidebar":"v3SideBar"},"v3/copy-trade/enum":{"id":"v3/copy-trade/enum","title":"Enums Definitions","description":"accountType"},"v3/copy-trade/error":{"id":"v3/copy-trade/error","title":"Error Code","description":"|Code |Description |"},"v3/copy-trade/rate-limit":{"id":"v3/copy-trade/rate-limit","title":"Rate Limit","description":"IP Rate Limit"},"v3/copy-trade/rest-public/symbol-info":{"id":"v3/copy-trade/rest-public/symbol-info","title":"Instrument Info","description":"Get the spec of trading symbols"},"v3/copy-trade/rest-trade/account/transfer":{"id":"v3/copy-trade/rest-trade/account/transfer","title":"Transfer","description":"Transfer"},"v3/copy-trade/rest-trade/account/transfer-list":{"id":"v3/copy-trade/rest-trade/account/transfer-list","title":"Get Transfer History","description":"Get the transfer history of Copy-trade wallet"},"v3/copy-trade/rest-trade/account/wallet":{"id":"v3/copy-trade/rest-trade/account/wallet","title":"Get Wallet Balance","description":"Get CopyTrading Wallet Balance"},"v3/copy-trade/rest-trade/order/cancel-order":{"id":"v3/copy-trade/rest-trade/order/cancel-order","title":"Cancel Order","description":"Cancel Order"},"v3/copy-trade/rest-trade/order/close-order":{"id":"v3/copy-trade/rest-trade/order/close-order","title":"Create Close Position Order","description":"Create a specific close order"},"v3/copy-trade/rest-trade/order/order-list":{"id":"v3/copy-trade/rest-trade/order/order-list","title":"Get Orders","description":"Query orders"},"v3/copy-trade/rest-trade/order/place-order":{"id":"v3/copy-trade/rest-trade/order/place-order","title":"Create Order","description":"Create Order"},"v3/copy-trade/rest-trade/order/set-trading-stop":{"id":"v3/copy-trade/rest-trade/order/set-trading-stop","title":"Set Trading Stop","description":"Set Trading Stop"},"v3/copy-trade/rest-trade/position/close-position":{"id":"v3/copy-trade/rest-trade/position/close-position","title":"Close All Positions","description":"Close Position"},"v3/copy-trade/rest-trade/position/execution":{"id":"v3/copy-trade/rest-trade/position/execution","title":"Get Execution List (2 years)","description":"Query users\' execution list, sort by execTime in descending order"},"v3/copy-trade/rest-trade/position/position-info":{"id":"v3/copy-trade/rest-trade/position/position-info","title":"Position List","description":"Position List"},"v3/copy-trade/rest-trade/position/set-leverage":{"id":"v3/copy-trade/rest-trade/position/set-leverage","title":"Set Leverage","description":"Set Leverage"},"v3/copy-trade/wss-authentication":{"id":"v3/copy-trade/wss-authentication","title":"Connect","description":"Note that currently Copy Trading only supports USDT perpetual and the following endpoints only apply to USDT Perpetual"},"v3/copy-trade/wss-private/execution":{"id":"v3/copy-trade/wss-private/execution","title":"Execution","description":"Topic:"},"v3/copy-trade/wss-private/order":{"id":"v3/copy-trade/wss-private/order","title":"Order","description":"Topic:"},"v3/copy-trade/wss-private/position":{"id":"v3/copy-trade/wss-private/position","title":"Position","description":"Topic:"},"v3/copy-trade/wss-private/wallet":{"id":"v3/copy-trade/wss-private/wallet","title":"Wallet","description":"Topic:"},"v3/copy-trade/wss-public/kline":{"id":"v3/copy-trade/wss-public/kline","title":"Kline","description":"Interval supported:"},"v3/copy-trade/wss-public/liquidation":{"id":"v3/copy-trade/wss-public/liquidation","title":"Liquidation","description":"Get recent liquidation orders in Bybit."},"v3/copy-trade/wss-public/orderbook":{"id":"v3/copy-trade/wss-public/orderbook","title":"Orderbook","description":"Get different depth"},"v3/copy-trade/wss-public/tickers":{"id":"v3/copy-trade/wss-public/tickers","title":"Tickers","description":"Get latest information of the symbol"},"v3/copy-trade/wss-public/trade":{"id":"v3/copy-trade/wss-public/trade","title":"Public Trade","description":"Get recent public trades data in Bybit."},"v3/derivatives/enum":{"id":"v3/derivatives/enum","title":"Enums Definitions","description":"category","sidebar":"v3SideBar"},"v3/derivatives/error":{"id":"v3/derivatives/error","title":"Error Code","description":"Unified Margin","sidebar":"v3SideBar"},"v3/derivatives/rate-limit":{"id":"v3/derivatives/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/trading-fee":{"id":"v3/derivatives/rest-contract/account/trading-fee","title":"Get Trading Fee Rate","description":"Get user trading fee rate.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/wallet-balance":{"id":"v3/derivatives/rest-contract/account/wallet-balance","title":"Wallet Balance","description":"Get wallet balance, including Derivatives account and USDC account.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/account/wallet-fund-record":{"id":"v3/derivatives/rest-contract/account/wallet-fund-record","title":"Get Wallet Fund Records","description":"Get wallet fund records. This endpoint also shows exchanges from the Asset Exchange, where the types for the exchange are ExchangeOrderWithdraw and ExchangeOrderDeposit.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/cancel-all":{"id":"v3/derivatives/rest-contract/order/cancel-all","title":"Cancel All Order","description":"This endpoint enables to cancel all open orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/cancel-order":{"id":"v3/derivatives/rest-contract/order/cancel-order","title":"Cancel Order","description":"You could cancel those unfilled or partially filled orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/open-order":{"id":"v3/derivatives/rest-contract/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/order-list":{"id":"v3/derivatives/rest-contract/order/order-list","title":"Get Order List","description":"Query order list.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/place-order":{"id":"v3/derivatives/rest-contract/order/place-order","title":"Place Order","description":"- Market order: A traditional market order, which will be filled at the current optimal price. Only when the market","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/order/replace-order":{"id":"v3/derivatives/rest-contract/order/replace-order","title":"Replace Order","description":"You could modify those unfilled or partially filled orders.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/auto-margin":{"id":"v3/derivatives/rest-contract/position/auto-margin","title":"Set Auto Add Margin","description":"Turn on/off auto add position margin. To understand more, please read here","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/close-pnl":{"id":"v3/derivatives/rest-contract/position/close-pnl","title":"Get Closed PnL","description":"Query user\'s closed profit and loss records. The results are sorted by createdAt in descending order.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/confirm-mmr":{"id":"v3/derivatives/rest-contract/position/confirm-mmr","title":"Confirm New Risk Limit","description":"It is only applicable when the user is marked as only reducing positions (please see the isReduceOnly field in","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/cross-isolated-margin":{"id":"v3/derivatives/rest-contract/position/cross-isolated-margin","title":"Switch Cross/Isolated Margin","description":"Switch cross margin mode / isolated margin mode. To understand more, please read here","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/execution":{"id":"v3/derivatives/rest-contract/position/execution","title":"Get Execution List","description":"Query users\' execution list, sort by execTime in descending order. Support USDT Perpetual, Inverse Perpetual, Inverse Future, USDC Perpetual and USDC Option.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/leverage":{"id":"v3/derivatives/rest-contract/position/leverage","title":"Set Leverage","description":"Set the leverage.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/position-info":{"id":"v3/derivatives/rest-contract/position/position-info","title":"My Position","description":"Get real-time position data","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/position-mode":{"id":"v3/derivatives/rest-contract/position/position-mode","title":"Switch Position Mode","description":"It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/set-risk-limit":{"id":"v3/derivatives/rest-contract/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements.","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/tpsl-mode":{"id":"v3/derivatives/rest-contract/position/tpsl-mode","title":"Switch TP/SL Mode","description":"_To some extent, this endpoint is depreciated because now tpsl is based on order level. This API was used for position level","sidebar":"v3SideBar"},"v3/derivatives/rest-contract/position/trading-stop":{"id":"v3/derivatives/rest-contract/position/trading-stop","title":"Set Trading Stop","description":"Set the take profit, stop loss or trailing stop for the position.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/delivery-price":{"id":"v3/derivatives/rest-public/delivery-price","title":"Option Delivery Price","description":"Get the delivery price for option","sidebar":"v3SideBar"},"v3/derivatives/rest-public/fund-rate-history":{"id":"v3/derivatives/rest-public/fund-rate-history","title":"Funding Rate History","description":"Get historical funding rate","sidebar":"v3SideBar"},"v3/derivatives/rest-public/index-kline":{"id":"v3/derivatives/rest-public/index-kline","title":"Index Price Kline","description":"Get index price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/instrument-info":{"id":"v3/derivatives/rest-public/instrument-info","title":"Instrument Info","description":"Get launched instruments information.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/kline":{"id":"v3/derivatives/rest-public/kline","title":"Kline","description":"Get kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/long-short-ratio":{"id":"v3/derivatives/rest-public/long-short-ratio","title":"Get Long Short Ratio","description":"HTTP Request","sidebar":"v3SideBar"},"v3/derivatives/rest-public/mark-kline":{"id":"v3/derivatives/rest-public/mark-kline","title":"Mark Price Kline","description":"Get mark price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/open-interest":{"id":"v3/derivatives/rest-public/open-interest","title":"Open Interest","description":"Get open interest of each symbol in Bybit","sidebar":"v3SideBar"},"v3/derivatives/rest-public/orderbook":{"id":"v3/derivatives/rest-public/orderbook","title":"Order Book","description":"Get order book data.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/premium-index-kline":{"id":"v3/derivatives/rest-public/premium-index-kline","title":"Premium Index Price Kline","description":"Get premium index price kline data","sidebar":"v3SideBar"},"v3/derivatives/rest-public/public-trade":{"id":"v3/derivatives/rest-public/public-trade","title":"Public Trading History","description":"Get recent public trading records in Bybit. You could download archived USDT contract trade records here.","sidebar":"v3SideBar"},"v3/derivatives/rest-public/risk-limit":{"id":"v3/derivatives/rest-public/risk-limit","title":"Risk Limit","description":"Get risk limit","sidebar":"v3SideBar"},"v3/derivatives/rest-public/ticker-info":{"id":"v3/derivatives/rest-public/ticker-info","title":"Ticker Info","description":"Get all latest information of symbols.","sidebar":"v3SideBar"},"v3/derivatives/rest-unified/account/account-info":{"id":"v3/derivatives/rest-unified/account/account-info","title":"Account Info","description":"Query the configuration under the account."},"v3/derivatives/rest-unified/account/borrow-history":{"id":"v3/derivatives/rest-unified/account/borrow-history","title":"Borrow History","description":"HTTP Request"},"v3/derivatives/rest-unified/account/borrow-rate":{"id":"v3/derivatives/rest-unified/account/borrow-rate","title":"Get Borrow Rate","description":"HTTP Request"},"v3/derivatives/rest-unified/account/dcp":{"id":"v3/derivatives/rest-unified/account/dcp","title":"Set Disconnect Cancel All","description":"What is Disconnection Protect (DCP)?"},"v3/derivatives/rest-unified/account/exchange":{"id":"v3/derivatives/rest-unified/account/exchange","title":"Get Exchange Records","description":"Query the coin exchange records."},"v3/derivatives/rest-unified/account/get-dcp":{"id":"v3/derivatives/rest-unified/account/get-dcp","title":"Get DCP Info","description":"HTTP Request"},"v3/derivatives/rest-unified/account/get-mmp-state":{"id":"v3/derivatives/rest-unified/account/get-mmp-state","title":"Get MMP State","description":"HTTP Request"},"v3/derivatives/rest-unified/account/reset-mmp":{"id":"v3/derivatives/rest-unified/account/reset-mmp","title":"Reset MMP","description":"Once the mmp triggered, you can unfreeze the account by this endpoint"},"v3/derivatives/rest-unified/account/set-margin-mode":{"id":"v3/derivatives/rest-unified/account/set-margin-mode","title":"Set Margin Mode","description":"Default is the regular margin mode. This mode is valid for USDT Perp, USDC Perp and Option."},"v3/derivatives/rest-unified/account/set-mmp":{"id":"v3/derivatives/rest-unified/account/set-mmp","title":"Set MMP","description":"What is MMP?"},"v3/derivatives/rest-unified/account/transaction-log":{"id":"v3/derivatives/rest-unified/account/transaction-log","title":"Transaction Log","description":"Query transaction logs in Unified account."},"v3/derivatives/rest-unified/account/upgrade-unified-account":{"id":"v3/derivatives/rest-unified/account/upgrade-unified-account","title":"Upgrade To Unified Margin Account","description":"Upgrade to unified margin account (UMA)"},"v3/derivatives/rest-unified/account/wallet-balance":{"id":"v3/derivatives/rest-unified/account/wallet-balance","title":"Wallet Balance","description":"Get wallet balance"},"v3/derivatives/rest-unified/order/batch-cancel":{"id":"v3/derivatives/rest-unified/order/batch-cancel","title":"Batch Cancel Order","description":"This endpoint provides the batch order mode to cancel a bunch of open orders."},"v3/derivatives/rest-unified/order/batch-place":{"id":"v3/derivatives/rest-unified/order/batch-place","title":"Batch Place Order","description":"This endpoint provides the batch order mode to place a bunch of orders."},"v3/derivatives/rest-unified/order/batch-replace":{"id":"v3/derivatives/rest-unified/order/batch-replace","title":"Batch Replace Order","description":"This endpoint provides the batch order mode to replace a bunch of open orders."},"v3/derivatives/rest-unified/order/cancel-all":{"id":"v3/derivatives/rest-unified/order/cancel-all","title":"Cancel All Orders","description":"This endpoint enables to cancel all open orders."},"v3/derivatives/rest-unified/order/cancel-order":{"id":"v3/derivatives/rest-unified/order/cancel-order","title":"Cancel Order","description":"You could cancel those unfilled or partially filled orders."},"v3/derivatives/rest-unified/order/open-order":{"id":"v3/derivatives/rest-unified/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time."},"v3/derivatives/rest-unified/order/order-list":{"id":"v3/derivatives/rest-unified/order/order-list","title":"Get Order List","description":"Query order list."},"v3/derivatives/rest-unified/order/place-order":{"id":"v3/derivatives/rest-unified/order/place-order","title":"Place Order","description":"- Market order: A traditional market order, which will be filled at the current optimal price. Only when the market"},"v3/derivatives/rest-unified/order/replace-order":{"id":"v3/derivatives/rest-unified/order/replace-order","title":"Replace Order","description":"You could modify those unfilled or partially filled orders."},"v3/derivatives/rest-unified/position/execution-list":{"id":"v3/derivatives/rest-unified/position/execution-list","title":"Get Execution Record","description":"Query users\' execution records, sort by execTime in descending order"},"v3/derivatives/rest-unified/position/full-partial-tpsl":{"id":"v3/derivatives/rest-unified/position/full-partial-tpsl","title":"Switch TP/SL Mode","description":"Set take profit / stop loss mode of the position, such as FULL TP/SL mode or PARTIAL TP/SL mode"},"v3/derivatives/rest-unified/position/leverage":{"id":"v3/derivatives/rest-unified/position/leverage","title":"Set Leverage","description":"Set the leverage."},"v3/derivatives/rest-unified/position/option-delivery":{"id":"v3/derivatives/rest-unified/position/option-delivery","title":"Get Option Delivery Record","description":"Query option delivery records, sort by deliveryTime in descending order"},"v3/derivatives/rest-unified/position/position-info":{"id":"v3/derivatives/rest-unified/position/position-info","title":"My Position","description":"Get real-time position data"},"v3/derivatives/rest-unified/position/set-risk-limit":{"id":"v3/derivatives/rest-unified/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements."},"v3/derivatives/rest-unified/position/trading-stop":{"id":"v3/derivatives/rest-unified/position/trading-stop","title":"Set Trading Stop","description":"Pass the following parameters, then the system will create conditional orders. If the position is closed, the system will cancel these orders, and adjust the position size."},"v3/derivatives/rest-unified/position/usdc-settlement":{"id":"v3/derivatives/rest-unified/position/usdc-settlement","title":"Get USDC Perpetual Settlement","description":"Query session settlement records of USDC perpetual"},"v3/derivatives/wss-authentication":{"id":"v3/derivatives/wss-authentication","title":"Connect","description":"Base endpoints:","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/execution":{"id":"v3/derivatives/wss-contract/execution","title":"Execution","description":"Subscribe to the execution stream to see when an open order gets filled or partially filled.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/order":{"id":"v3/derivatives/wss-contract/order","title":"Order","description":"Subscribe to the order stream to see new orders, when an order\'s order status changes, etc.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/position":{"id":"v3/derivatives/wss-contract/position","title":"Position","description":"Subscribe to the position stream to see changes to your position size, position setting changes, etc.","sidebar":"v3SideBar"},"v3/derivatives/wss-contract/wallet":{"id":"v3/derivatives/wss-contract/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time.","sidebar":"v3SideBar"},"v3/derivatives/wss-public/kline":{"id":"v3/derivatives/wss-public/kline","title":"Kline","description":"Covers: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future","sidebar":"v3SideBar"},"v3/derivatives/wss-public/liquidation":{"id":"v3/derivatives/wss-public/liquidation","title":"Liquidation","description":"Get recent liquidation orders in Bybit.","sidebar":"v3SideBar"},"v3/derivatives/wss-public/orderbook":{"id":"v3/derivatives/wss-public/orderbook","title":"Orderbook","description":"Get different depth","sidebar":"v3SideBar"},"v3/derivatives/wss-public/tickers":{"id":"v3/derivatives/wss-public/tickers","title":"Tickers","description":"Cover: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future, Option","sidebar":"v3SideBar"},"v3/derivatives/wss-public/trade":{"id":"v3/derivatives/wss-public/trade","title":"Public Trade","description":"Get recent public trades data in Bybit.","sidebar":"v3SideBar"},"v3/derivatives/wss-unified/execution":{"id":"v3/derivatives/wss-unified/execution","title":"Execution","description":"Subscribe to the execution stream. Will not push funding payments unless they occur on a USDT perpetual, eg BTCUSDT."},"v3/derivatives/wss-unified/greek":{"id":"v3/derivatives/wss-unified/greek","title":"Greek","description":"Subscribe to the user greeks stream, option only."},"v3/derivatives/wss-unified/order":{"id":"v3/derivatives/wss-unified/order","title":"Order","description":"Subscribe to the order stream to see new orders, when an order\'s order status changes, etc."},"v3/derivatives/wss-unified/position":{"id":"v3/derivatives/wss-unified/position","title":"Position","description":"Subscribe to the position stream to see changes to your position size, position setting changes, etc."},"v3/derivatives/wss-unified/wallet":{"id":"v3/derivatives/wss-unified/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time."},"v3/intro":{"id":"v3/intro","title":"Introduction","description":"Bybit V3 API allow users to select different collections to build their API model.","sidebar":"v3SideBar"},"v3/server-time":{"id":"v3/server-time","title":"Bybit Server Time","description":"Get the Bybit server timestamp","sidebar":"v3SideBar"},"v3/smp":{"id":"v3/smp","title":"Self Match Prevention","description":"What is SMP?","sidebar":"v3SideBar"},"v3/spot/enum":{"id":"v3/spot/enum","title":"Enums Definitions","description":"side","sidebar":"v3SideBar"},"v3/spot/error":{"id":"v3/spot/error","title":"Error Code","description":"|Code |Description |","sidebar":"v3SideBar"},"v3/spot/rate-limit":{"id":"v3/spot/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v3SideBar"},"v3/spot/rest-etp/asset-info":{"id":"v3/spot/rest-etp/asset-info","title":"All Asset Info","description":"It is a public endpoint, and no need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-etp/market-info":{"id":"v3/spot/rest-etp/market-info","title":"Market Info","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/purchase":{"id":"v3/spot/rest-etp/purchase","title":"Purchase","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/purchase-redeem-history":{"id":"v3/spot/rest-etp/purchase-redeem-history","title":"Purchase & Redeem History","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-etp/redeem":{"id":"v3/spot/rest-etp/redeem","title":"Redeem","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/loan-info":{"id":"v3/spot/rest-institution-loan/loan-info","title":"Get Loan Info","description":"Get loan orders information","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/ltv":{"id":"v3/spot/rest-institution-loan/ltv","title":"Get LTV","description":"Get LTV. Please head here to get LTV if this API returns empty data.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/margin-coin-info":{"id":"v3/spot/rest-institution-loan/margin-coin-info","title":"Margin Coin Info","description":"This is a public endpoint, so it does not need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/margin-product-info":{"id":"v3/spot/rest-institution-loan/margin-product-info","title":"Get Margin Product Info","description":"This is a public endpoint, so it does not need to authenticate.","sidebar":"v3SideBar"},"v3/spot/rest-institution-loan/repay-info":{"id":"v3/spot/rest-institution-loan/repay-info","title":"Get Repay Info","description":"Get repaid order information. Authentication needed.","sidebar":"v3SideBar"},"v3/spot/rest-public/best-bid-ask":{"id":"v3/spot/rest-public/best-bid-ask","title":"Best Bid/Ask Price","description":"If symbol is not specified, the best order price from all symbols will be returned","sidebar":"v3SideBar"},"v3/spot/rest-public/instrument-info":{"id":"v3/spot/rest-public/instrument-info","title":"Instrument Info","description":"Get the spec of symbol information","sidebar":"v3SideBar"},"v3/spot/rest-public/kline":{"id":"v3/spot/rest-public/kline","title":"Kline","description":"It only returns the results from latest 1000 candles regardless of what interval is specified","sidebar":"v3SideBar"},"v3/spot/rest-public/last-trade-price":{"id":"v3/spot/rest-public/last-trade-price","title":"Last Traded Price","description":"If symbol is not specified, the price from all symbols will be returned","sidebar":"v3SideBar"},"v3/spot/rest-public/merge-orderbook":{"id":"v3/spot/rest-public/merge-orderbook","title":"Merged Order Book","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/orderbook":{"id":"v3/spot/rest-public/orderbook","title":"Order Book","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/public-trade":{"id":"v3/spot/rest-public/public-trade","title":"Public Trading Records","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-public/ticker-info":{"id":"v3/spot/rest-public/ticker-info","title":"Tickers","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/account-info":{"id":"v3/spot/rest-spot-margin/account-info","title":"Get Loan Account Info","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrow":{"id":"v3/spot/rest-spot-margin/borrow","title":"Borrow","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrow-info":{"id":"v3/spot/rest-spot-margin/borrow-info","title":"Get Borrow Order Detail","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/borrowable-data":{"id":"v3/spot/rest-spot-margin/borrowable-data","title":"Get Borrowable Coin Info","description":"This is public endpoint, so do not need an authentication","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/interest-quota":{"id":"v3/spot/rest-spot-margin/interest-quota","title":"Get Interest & Quota","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/margin-data":{"id":"v3/spot/rest-spot-margin/margin-data","title":"Get Margin Coin Info","description":"This is public endpoint, so do not need an authentication","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/repay":{"id":"v3/spot/rest-spot-margin/repay","title":"Repay","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/repay-history":{"id":"v3/spot/rest-spot-margin/repay-history","title":"Get Repayment Order Detail","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot-margin/switch-mode":{"id":"v3/spot/rest-spot-margin/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v3SideBar"},"v3/spot/rest-spot/batch-cancel":{"id":"v3/spot/rest-spot/batch-cancel","title":"Batch Cancel Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/batch-cancel-by-id":{"id":"v3/spot/rest-spot/batch-cancel-by-id","title":"Batch Cancel Order By Id","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/cancel-order":{"id":"v3/spot/rest-spot/cancel-order","title":"Cancel Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/get-order":{"id":"v3/spot/rest-spot/get-order","title":"Get Order","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/open-order":{"id":"v3/spot/rest-spot/open-order","title":"Open Orders","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/rest-spot/order-history":{"id":"v3/spot/rest-spot/order-history","title":"Order History","description":"- If startTime and endTime are both not specified, it returns last 7 days records by default. 3 days records for institutional clients.","sidebar":"v3SideBar"},"v3/spot/rest-spot/place-order":{"id":"v3/spot/rest-spot/place-order","title":"Place Order","description":"Do not use the duplicate orderLinkId in normal order & TP/SL order","sidebar":"v3SideBar"},"v3/spot/rest-spot/trade-history":{"id":"v3/spot/rest-spot/trade-history","title":"Trade History","description":"* If startTime is not specified, you can only query for records in the last 7 days.","sidebar":"v3SideBar"},"v3/spot/wallet":{"id":"v3/spot/wallet","title":"Get Wallet Balance","description":"HTTP Request","sidebar":"v3SideBar"},"v3/spot/wss-authentication":{"id":"v3/spot/wss-authentication","title":"Connect","description":"Note that the following endpoints only apply to Spot. To listen to other websockets, go to:","sidebar":"v3SideBar"},"v3/spot/wss-private/order":{"id":"v3/spot/wss-private/order","title":"Order","description":"This topic pushes order information\uff0cavg.filledPrice = Z / z","sidebar":"v3SideBar"},"v3/spot/wss-private/outbound-account-info":{"id":"v3/spot/wss-private/outbound-account-info","title":"Wallet","description":"This topic pushes spot wallet information","sidebar":"v3SideBar"},"v3/spot/wss-private/stop-order":{"id":"v3/spot/wss-private/stop-order","title":"Stop Order","description":"This topic pushes conditional order, TP/SL order information placed by web/app channel, and TP/SL order information placed by open api channel. It\'ll be triggered as long as order status is changed","sidebar":"v3SideBar"},"v3/spot/wss-private/ticket-info":{"id":"v3/spot/wss-private/ticket-info","title":"Execution","description":"This topic pushes filled trades information. When an order is filled, you will receive two messages: one from ticketInfo, and one from order / stopOrder","sidebar":"v3SideBar"},"v3/spot/wss-public/bookticker":{"id":"v3/spot/wss-public/bookticker","title":"Bookticker","description":"Best bid price and best ask price","sidebar":"v3SideBar"},"v3/spot/wss-public/kline":{"id":"v3/spot/wss-public/kline","title":"Kline","description":"Subscribe the kline stream. Please find desired kline interval here.","sidebar":"v3SideBar"},"v3/spot/wss-public/orderbook":{"id":"v3/spot/wss-public/orderbook","title":"Orderbook","description":"Market depth data for a trading pair:","sidebar":"v3SideBar"},"v3/spot/wss-public/tickers":{"id":"v3/spot/wss-public/tickers","title":"Tickers","description":"The 24-hr statistics of a trading pair.","sidebar":"v3SideBar"},"v3/spot/wss-public/trade":{"id":"v3/spot/wss-public/trade","title":"Public trade","description":"This topic pushes raw trade information; each trade has a unique buyer and seller.","sidebar":"v3SideBar"},"v3/tax/data-explain":{"id":"v3/tax/data-explain","title":"Data Explanation","description":"Trade History","sidebar":"v3SideBar"},"v3/tax/data-export":{"id":"v3/tax/data-export","title":"Retrieve Data Export","description":"Retrieve data export","sidebar":"v3SideBar"},"v3/tax/enum":{"id":"v3/tax/enum","title":"Enums Definitions","description":"ReportType","sidebar":"v3SideBar"},"v3/tax/register-time":{"id":"v3/tax/register-time","title":"Get User Register Date","description":"Get User Register Date","sidebar":"v3SideBar"},"v3/tax/report-status":{"id":"v3/tax/report-status","title":"Get Export Report Status","description":"Get Export Report Status","sidebar":"v3SideBar"},"v3/tax/request-report":{"id":"v3/tax/request-report","title":"Request Export Report","description":"Request to export report","sidebar":"v3SideBar"},"v5/abandon/enable-unitransfer-subuid":{"id":"v5/abandon/enable-unitransfer-subuid","title":"Enable Universal Transfer for Sub UID","description":"You no longer need to configure transferable sub UIDs. Now, all sub UIDs are automatically enabled for universal transfer.","sidebar":"v5SideBar"},"v5/abandon/ltv":{"id":"v5/abandon/ltv","title":"Get LTV","description":"HTTP Request","sidebar":"v5SideBar"},"v5/abandon/margin-coin-info":{"id":"v5/abandon/margin-coin-info","title":"Get Margin Coin Info","description":"HTTP Request","sidebar":"v5SideBar"},"v5/account/account-info":{"id":"v5/account/account-info","title":"Get Account Info","description":"Query the margin mode configuration of the account.","sidebar":"v5SideBar"},"v5/account/borrow-history":{"id":"v5/account/borrow-history","title":"Get Borrow History","description":"Get interest records, sorted in reverse order of creation time.","sidebar":"v5SideBar"},"v5/account/coin-greeks":{"id":"v5/account/coin-greeks","title":"Get Coin Greeks","description":"Get current account Greeks information","sidebar":"v5SideBar"},"v5/account/collateral-info":{"id":"v5/account/collateral-info","title":"Get Collateral Info","description":"Get the collateral information of the current unified margin account, including loan interest rate, loanable amount, collateral conversion rate, whether it can be mortgaged as margin, etc.","sidebar":"v5SideBar"},"v5/account/fee-rate":{"id":"v5/account/fee-rate","title":"Get Fee Rate","description":"Get the trading fee rate.","sidebar":"v5SideBar"},"v5/account/get-mmp-state":{"id":"v5/account/get-mmp-state","title":"Get MMP State","description":"HTTP Request","sidebar":"v5SideBar"},"v5/account/reset-mmp":{"id":"v5/account/reset-mmp","title":"Reset MMP","description":"* Once the mmp triggered, you can unfreeze the account by this endpoint, then qtyLimit and deltaLimit will be reset to 0.","sidebar":"v5SideBar"},"v5/account/set-collateral":{"id":"v5/account/set-collateral","title":"Set Collateral Coin","description":"You can decide whether the assets in the Unified account needs to be collateral coins.","sidebar":"v5SideBar"},"v5/account/set-margin-mode":{"id":"v5/account/set-margin-mode","title":"Set Margin Mode","description":"Default is regular margin mode","sidebar":"v5SideBar"},"v5/account/set-mmp":{"id":"v5/account/set-mmp","title":"Set MMP","description":"What is MMP?","sidebar":"v5SideBar"},"v5/account/transaction-log":{"id":"v5/account/transaction-log","title":"Get Transaction Log","description":"Query transaction logs in Unified account.","sidebar":"v5SideBar"},"v5/account/upgrade-unified-account":{"id":"v5/account/upgrade-unified-account","title":"Upgrade to Unified Account","description":"Upgrade Unified Account","sidebar":"v5SideBar"},"v5/account/wallet-balance":{"id":"v5/account/wallet-balance","title":"Get Wallet Balance","description":"Obtain wallet balance, query asset information of each currency, and account risk rate information. By default, currency","sidebar":"v5SideBar"},"v5/announcement":{"id":"v5/announcement","title":"Get Announcement","description":"HTTP Request","sidebar":"v5SideBar"},"v5/asset/account-coin-balance":{"id":"v5/asset/account-coin-balance","title":"Get Single Coin Balance","description":"Query the balance of a specific coin in a specific account type. Supports querying sub UID\'s balance.","sidebar":"v5SideBar"},"v5/asset/all-balance":{"id":"v5/asset/all-balance","title":"Get All Coins Balance","description":"You could get all coin balance of all account types under the master account, and sub account.","sidebar":"v5SideBar"},"v5/asset/asset-info":{"id":"v5/asset/asset-info","title":"Get Asset Info","description":"Query asset information","sidebar":"v5SideBar"},"v5/asset/cancel-withdraw":{"id":"v5/asset/cancel-withdraw","title":"Cancel Withdrawal","description":"Cancel the withdrawal","sidebar":"v5SideBar"},"v5/asset/coin-info":{"id":"v5/asset/coin-info","title":"Get Coin Info","description":"Query coin information, including chain information, withdraw and deposit status.","sidebar":"v5SideBar"},"v5/asset/create-inter-transfer":{"id":"v5/asset/create-inter-transfer","title":"Create Internal Transfer","description":"Create the internal transfer between different account types under the same UID.","sidebar":"v5SideBar"},"v5/asset/delay-amount":{"id":"v5/asset/delay-amount","title":"Get Withdrawable Amount","description":"How can partial funds be subject to delayed withdrawal requests?","sidebar":"v5SideBar"},"v5/asset/delivery":{"id":"v5/asset/delivery","title":"Get Delivery Record","description":"Query delivery records of USDC futures and Options, sorted by deliveryTime in descending order","sidebar":"v5SideBar"},"v5/asset/deposit-coin-spec":{"id":"v5/asset/deposit-coin-spec","title":"Get Allowed Deposit Coin Info","description":"Query allowed deposit coin information. To find out paired chain of coin, please refer coin info api.","sidebar":"v5SideBar"},"v5/asset/deposit-record":{"id":"v5/asset/deposit-record","title":"Get Deposit Records (on-chain)","description":"Query deposit records.","sidebar":"v5SideBar"},"v5/asset/exchange":{"id":"v5/asset/exchange","title":"Get Coin Exchange Records","description":"Query the coin exchange records.","sidebar":"v5SideBar"},"v5/asset/inter-transfer-list":{"id":"v5/asset/inter-transfer-list","title":"Get Internal Transfer Records","description":"Query the internal transfer records between different account types under the same UID.","sidebar":"v5SideBar"},"v5/asset/internal-deposit-record":{"id":"v5/asset/internal-deposit-record","title":"Get Internal Deposit Records (off-chain)","description":"Query deposit records within the Bybit platform. These transactions are not on the blockchain.","sidebar":"v5SideBar"},"v5/asset/master-deposit-addr":{"id":"v5/asset/master-deposit-addr","title":"Get Master Deposit Address","description":"Query the deposit address information of MASTER account.","sidebar":"v5SideBar"},"v5/asset/set-deposit-acct":{"id":"v5/asset/set-deposit-acct","title":"Set Deposit Account","description":"Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI","sidebar":"v5SideBar"},"v5/asset/settlement":{"id":"v5/asset/settlement","title":"Get USDC Session Settlement","description":"Query session settlement records of USDC perpetual and futures","sidebar":"v5SideBar"},"v5/asset/sub-deposit-addr":{"id":"v5/asset/sub-deposit-addr","title":"Get Sub Deposit Address","description":"Query the deposit address information of SUB account.","sidebar":"v5SideBar"},"v5/asset/sub-deposit-record":{"id":"v5/asset/sub-deposit-record","title":"Get Sub Deposit Records (on-chain)","description":"Query subaccount\'s deposit records by main UID\'s API key.","sidebar":"v5SideBar"},"v5/asset/sub-uid-list":{"id":"v5/asset/sub-uid-list","title":"Get Sub UID","description":"Query the sub UIDs under a main UID","sidebar":"v5SideBar"},"v5/asset/transferable-coin":{"id":"v5/asset/transferable-coin","title":"Get Transferable Coin","description":"Query the transferable coin list between each account type","sidebar":"v5SideBar"},"v5/asset/unitransfer":{"id":"v5/asset/unitransfer","title":"Create Universal Transfer","description":"Transfer between sub-sub or main-sub.","sidebar":"v5SideBar"},"v5/asset/unitransfer-list":{"id":"v5/asset/unitransfer-list","title":"Get Universal Transfer Records","description":"Query universal transfer records","sidebar":"v5SideBar"},"v5/asset/withdraw":{"id":"v5/asset/withdraw","title":"Withdraw","description":"Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.","sidebar":"v5SideBar"},"v5/asset/withdraw-record":{"id":"v5/asset/withdraw-record","title":"Get Withdrawal Records","description":"Query withdrawal records.","sidebar":"v5SideBar"},"v5/backup/set-pledge-token":{"id":"v5/backup/set-pledge-token","title":"Set Pledge Token","description":"Set Pledge Token in cross margin"},"v5/broker/earning":{"id":"v5/broker/earning","title":"Get Broker Earning","description":"* Use exchange broker master account to query","sidebar":"v5SideBar"},"v5/c2c-lend/account-info":{"id":"v5/c2c-lend/account-info","title":"Get Lending Account Info","description":"HTTP Request","sidebar":"v5SideBar"},"v5/c2c-lend/cancel-redeem":{"id":"v5/c2c-lend/cancel-redeem","title":"Cancel Redeem","description":"Cancel the withdrawal operation.","sidebar":"v5SideBar"},"v5/c2c-lend/coin-info":{"id":"v5/c2c-lend/coin-info","title":"Get Lending Coin Info","description":"Get the basic information of lending coins","sidebar":"v5SideBar"},"v5/c2c-lend/deposit":{"id":"v5/c2c-lend/deposit","title":"Deposit Funds","description":"Lending funds to Bybit asset pool","sidebar":"v5SideBar"},"v5/c2c-lend/order-record":{"id":"v5/c2c-lend/order-record","title":"Get Order Records","description":"Get lending or redeem history","sidebar":"v5SideBar"},"v5/c2c-lend/redeem":{"id":"v5/c2c-lend/redeem","title":"Redeem Funds","description":"Withdraw funds from the Bybit asset pool.","sidebar":"v5SideBar"},"v5/copytrade":{"id":"v5/copytrade","title":"How To Start Copy Trading","description":"Become A Master Trader","sidebar":"v5SideBar"},"v5/enum":{"id":"v5/enum","title":"Enums Definitions","description":"locale","sidebar":"v5SideBar"},"v5/error":{"id":"v5/error","title":"Error Codes","description":"HTTP Code","sidebar":"v5SideBar"},"v5/guide":{"id":"v5/guide","title":"Integration Guidance","description":"To learn more about the V5 API, please read the Introduction.","sidebar":"v5SideBar"},"v5/intro":{"id":"v5/intro","title":"Introduction","description":"Overview","sidebar":"v5SideBar"},"v5/lt/leverage-token-info":{"id":"v5/lt/leverage-token-info","title":"Get Leverage Token Info","description":"Query leverage token information","sidebar":"v5SideBar"},"v5/lt/leverage-token-reference":{"id":"v5/lt/leverage-token-reference","title":"Get Leveraged Token Market","description":"Get leverage token market information","sidebar":"v5SideBar"},"v5/lt/order-record":{"id":"v5/lt/order-record","title":"Get Purchase/Redemption Records","description":"Get purchase or redeem history","sidebar":"v5SideBar"},"v5/lt/purchase":{"id":"v5/lt/purchase","title":"Purchase","description":"Purchase levearge token","sidebar":"v5SideBar"},"v5/lt/redeem":{"id":"v5/lt/redeem","title":"Redeem","description":"Redeem leverage token","sidebar":"v5SideBar"},"v5/market/delivery-price":{"id":"v5/market/delivery-price","title":"Get Delivery Price","description":"Get the delivery price.","sidebar":"v5SideBar"},"v5/market/history-fund-rate":{"id":"v5/market/history-fund-rate","title":"Get Funding Rate History","description":"Query for historical funding rates. Each symbol has a different funding interval. For example, if the interval is 8 hours and the current time is UTC 12, then it returns the last funding rate, which settled at UTC 8.","sidebar":"v5SideBar"},"v5/market/index-kline":{"id":"v5/market/index-kline","title":"Get Index Price Kline","description":"Query for historical index price klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/instrument":{"id":"v5/market/instrument","title":"Get Instruments Info","description":"Query for the instrument specification of online trading pairs.","sidebar":"v5SideBar"},"v5/market/insurance":{"id":"v5/market/insurance","title":"Get Insurance","description":"Query for Bybit insurance pool data (BTC/USDT/USDC etc). The data is updated every 24 hours.","sidebar":"v5SideBar"},"v5/market/iv":{"id":"v5/market/iv","title":"Get Historical Volatility","description":"Query option historical volatility","sidebar":"v5SideBar"},"v5/market/kline":{"id":"v5/market/kline","title":"Get Kline","description":"Query for historical klines (also known as candles/candlesticks). Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/long-short-ratio":{"id":"v5/market/long-short-ratio","title":"Get Long Short Ratio","description":"HTTP Request","sidebar":"v5SideBar"},"v5/market/mark-kline":{"id":"v5/market/mark-kline","title":"Get Mark Price Kline","description":"Query for historical mark price klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/open-interest":{"id":"v5/market/open-interest","title":"Get Open Interest","description":"Get the open interest of each symbol.","sidebar":"v5SideBar"},"v5/market/orderbook":{"id":"v5/market/orderbook","title":"Get Orderbook","description":"Query for orderbook depth data.","sidebar":"v5SideBar"},"v5/market/preimum-index-kline":{"id":"v5/market/preimum-index-kline","title":"Get Premium Index Price Kline","description":"Query for historical premium index klines. Charts are returned in groups based on the requested interval.","sidebar":"v5SideBar"},"v5/market/recent-trade":{"id":"v5/market/recent-trade","title":"Get Public Recent Trading History","description":"Query recent public trading data in Bybit.","sidebar":"v5SideBar"},"v5/market/risk-limit":{"id":"v5/market/risk-limit","title":"Get Risk Limit","description":"Query for the risk limit.","sidebar":"v5SideBar"},"v5/market/tickers":{"id":"v5/market/tickers","title":"Get Tickers","description":"Query for the latest price snapshot, best bid/ask price, and trading volume in the last 24 hours.","sidebar":"v5SideBar"},"v5/market/time":{"id":"v5/market/time","title":"Get Bybit Server Time","description":"HTTP Request","sidebar":"v5SideBar"},"v5/order/amend-order":{"id":"v5/order/amend-order","title":"Amend Order","description":"Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option","sidebar":"v5SideBar"},"v5/order/batch-amend":{"id":"v5/order/batch-amend","title":"Batch Amend Order","description":"Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)","sidebar":"v5SideBar"},"v5/order/batch-cancel":{"id":"v5/order/batch-cancel","title":"Batch Cancel Order","description":"This endpoint allows you to cancel more than one open order in a single request.","sidebar":"v5SideBar"},"v5/order/batch-place":{"id":"v5/order/batch-place","title":"Batch Place Order","description":"Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)","sidebar":"v5SideBar"},"v5/order/cancel-all":{"id":"v5/order/cancel-all","title":"Cancel All Orders","description":"Cancel all open orders","sidebar":"v5SideBar"},"v5/order/cancel-order":{"id":"v5/order/cancel-order","title":"Cancel Order","description":"Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options","sidebar":"v5SideBar"},"v5/order/create-order":{"id":"v5/order/create-order","title":"Place Order","description":"This endpoint supports to create the order for spot, spot margin, USDT perpetual, USDC perpetual, USDC futures, inverse futures and options.","sidebar":"v5SideBar"},"v5/order/dcp":{"id":"v5/order/dcp","title":"Set Disconnect Cancel All","description":"Covers: Option (Unified Account)","sidebar":"v5SideBar"},"v5/order/open-order":{"id":"v5/order/open-order","title":"Get Open Orders","description":"Query unfilled or partially filled orders in real-time. To query older order records, please use the order history interface.","sidebar":"v5SideBar"},"v5/order/order-list":{"id":"v5/order/order-list","title":"Get Order History","description":"Query order history. As order creation/cancellation is asynchronous, the data returned from this endpoint may delay. If you want to get","sidebar":"v5SideBar"},"v5/order/spot-borrow-quota":{"id":"v5/order/spot-borrow-quota","title":"Get Borrow Quota (Spot)","description":"Query the available balance for Spot trading and Margin trading","sidebar":"v5SideBar"},"v5/otc/bind-uid":{"id":"v5/otc/bind-uid","title":"Bind Or Unbind UID","description":"For the INS loan product, you can bind new UID to risk unit or unbind UID out from risk unit.","sidebar":"v5SideBar"},"v5/otc/loan-info":{"id":"v5/otc/loan-info","title":"Get Loan Orders","description":"Get loan orders information","sidebar":"v5SideBar"},"v5/otc/ltv-convert":{"id":"v5/otc/ltv-convert","title":"Get LTV","description":"Get LTV","sidebar":"v5SideBar"},"v5/otc/margin-coin-convert-info":{"id":"v5/otc/margin-coin-convert-info","title":"Get Margin Coin Info","description":"* This endpoint can be queried without api key and secret, then it returns public margin data","sidebar":"v5SideBar"},"v5/otc/margin-product-info":{"id":"v5/otc/margin-product-info","title":"Get Product Info","description":"* This endpoint can be queried without api key and secret, then it returns public product data","sidebar":"v5SideBar"},"v5/otc/repay-info":{"id":"v5/otc/repay-info","title":"Get Repay Orders","description":"Get repaid order information","sidebar":"v5SideBar"},"v5/position/auto-add-margin":{"id":"v5/position/auto-add-margin","title":"Set Auto Add Margin","description":"Turn on/off auto-add-margin for isolated margin position","sidebar":"v5SideBar"},"v5/position/close-pnl":{"id":"v5/position/close-pnl","title":"Get Closed PnL","description":"Query user\'s closed profit and loss records. The results are sorted by createdTime in descending order.","sidebar":"v5SideBar"},"v5/position/confirm-mmr":{"id":"v5/position/confirm-mmr","title":"Confirm New Risk Limit","description":"It is only applicable when the user is marked as only reducing positions (please see the isReduceOnly field in","sidebar":"v5SideBar"},"v5/position/cross-isolate":{"id":"v5/position/cross-isolate","title":"Switch Cross/Isolated Margin","description":"Select cross margin mode or isolated margin mode per symbol level","sidebar":"v5SideBar"},"v5/position/execution":{"id":"v5/position/execution","title":"Get Execution","description":"Query users\' execution records, sorted by execTime in descending order. However, for Classic spot, they are sorted by execId in descending order.","sidebar":"v5SideBar"},"v5/position/leverage":{"id":"v5/position/leverage","title":"Set Leverage","description":"Set the leverage","sidebar":"v5SideBar"},"v5/position/manual-add-margin":{"id":"v5/position/manual-add-margin","title":"Add Or Reduce Margin","description":"Manually add or reduce margin for isolated margin position","sidebar":"v5SideBar"},"v5/position/position":{"id":"v5/position/position","title":"Get Position Info","description":"Query real-time position data, such as position size, cumulative realizedPNL.","sidebar":"v5SideBar"},"v5/position/position-mode":{"id":"v5/position/position-mode","title":"Switch Position Mode","description":"It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.","sidebar":"v5SideBar"},"v5/position/set-risk-limit":{"id":"v5/position/set-risk-limit","title":"Set Risk Limit","description":"The risk limit will limit the maximum position value you can hold under different margin requirements. If you want to hold a bigger position size, you need more margin. This interface can set the risk limit of a single position. If the order exceeds the current risk limit when placing an order, it will be rejected. Click here to learn more about risk limit.","sidebar":"v5SideBar"},"v5/position/tpsl-mode":{"id":"v5/position/tpsl-mode","title":"Set TP/SL Mode","description":"_To some extent, this endpoint is depreciated because now tpsl is based on order level. This API was used for position level","sidebar":"v5SideBar"},"v5/position/trading-stop":{"id":"v5/position/trading-stop","title":"Set Trading Stop","description":"Set the take profit, stop loss or trailing stop for the position.","sidebar":"v5SideBar"},"v5/pre-upgrade/close-pnl":{"id":"v5/pre-upgrade/close-pnl","title":"Get Pre-upgrade Closed PnL","description":"Query user\'s closed profit and loss records from before you upgraded the account to a Unified account. The results are sorted by createdTime in descending order.","sidebar":"v5SideBar"},"v5/pre-upgrade/delivery":{"id":"v5/pre-upgrade/delivery","title":"Get Pre-upgrade Option Delivery Record","description":"Query delivery records of Option before you upgraded the account to a Unified account, sorted by deliveryTime in descending order","sidebar":"v5SideBar"},"v5/pre-upgrade/execution":{"id":"v5/pre-upgrade/execution","title":"Get Pre-upgrade Trade History","description":"Get users\' execution records which occurred before you upgraded the account to a Unified account, sorted by execTime in descending order","sidebar":"v5SideBar"},"v5/pre-upgrade/order-list":{"id":"v5/pre-upgrade/order-list","title":"Get Pre-upgrade Order History","description":"After the account is upgraded to a Unified account, you can get the orders which occurred before the upgrade.","sidebar":"v5SideBar"},"v5/pre-upgrade/settlement":{"id":"v5/pre-upgrade/settlement","title":"Get Pre-upgrade USDC Session Settlement","description":"Query session settlement records of USDC perpetual before you upgrade the account to Unified account.","sidebar":"v5SideBar"},"v5/pre-upgrade/transaction-log":{"id":"v5/pre-upgrade/transaction-log","title":"Get Pre-upgrade Transaction Log","description":"Query transaction logs which occurred in the USDC Derivatives wallet before the account was upgraded to a Unified account.","sidebar":"v5SideBar"},"v5/rate-limit":{"id":"v5/rate-limit","title":"Rate Limit","description":"IP Rate Limit","sidebar":"v5SideBar"},"v5/smp":{"id":"v5/smp","title":"Self Match Prevention","description":"What is SMP?","sidebar":"v5SideBar"},"v5/spot-margin-normal/account-info":{"id":"v5/spot-margin-normal/account-info","title":"Get Loan Account Info","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrow":{"id":"v5/spot-margin-normal/borrow","title":"Borrow","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrow-order":{"id":"v5/spot-margin-normal/borrow-order","title":"Get Borrow Order Detail","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/borrowable-data":{"id":"v5/spot-margin-normal/borrowable-data","title":"Get Borrowable Coin Info","description":"Do not need authentication","sidebar":"v5SideBar"},"v5/spot-margin-normal/interest-quota":{"id":"v5/spot-margin-normal/interest-quota","title":"Get Interest & Quota","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/margin-data":{"id":"v5/spot-margin-normal/margin-data","title":"Get Margin Coin Info","description":"Do not need authentication","sidebar":"v5SideBar"},"v5/spot-margin-normal/repay":{"id":"v5/spot-margin-normal/repay","title":"Repay","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/repay-order":{"id":"v5/spot-margin-normal/repay-order","title":"Get Repayment Order Detail","description":"Covers: Margin trade (Classic Account)","sidebar":"v5SideBar"},"v5/spot-margin-normal/switch-mode":{"id":"v5/spot-margin-normal/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v5SideBar"},"v5/spot-margin-normal/vip-margin":{"id":"v5/spot-margin-normal/vip-margin","title":"Get VIP Margin Data","description":"This margin data is for Classic account in particular.","sidebar":"v5SideBar"},"v5/spot-margin-uta/set-leverage":{"id":"v5/spot-margin-uta/set-leverage","title":"Set Leverage","description":"Set the user\'s maximum leverage in spot cross margin","sidebar":"v5SideBar"},"v5/spot-margin-uta/status":{"id":"v5/spot-margin-uta/status","title":"Get Status And Leverage","description":"Query the Spot margin status and leverage of Unified account","sidebar":"v5SideBar"},"v5/spot-margin-uta/switch-mode":{"id":"v5/spot-margin-uta/switch-mode","title":"Toggle Margin Trade","description":"Turn on / off spot margin trade","sidebar":"v5SideBar"},"v5/spot-margin-uta/vip-margin":{"id":"v5/spot-margin-uta/vip-margin","title":"Get VIP Margin Data","description":"This margin data is for Unified account in particular.","sidebar":"v5SideBar"},"v5/user/affiliate-info":{"id":"v5/user/affiliate-info","title":"Get Affiliate User Info","description":"This API is used for affiliate to get their users information","sidebar":"v5SideBar"},"v5/user/apikey-info":{"id":"v5/user/apikey-info","title":"Get API Key Information","description":"Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user\'s api key are applicable.","sidebar":"v5SideBar"},"v5/user/create-subuid":{"id":"v5/user/create-subuid","title":"Create Sub UID","description":"Create a new sub user id. Use master account\'s api key.","sidebar":"v5SideBar"},"v5/user/create-subuid-apikey":{"id":"v5/user/create-subuid-apikey","title":"Create Sub UID API Key","description":"To create new API key for those newly created sub UID. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/froze-subuid":{"id":"v5/user/froze-subuid","title":"Freeze Sub UID","description":"Freeze Sub UID. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/modify-master-apikey":{"id":"v5/user/modify-master-apikey","title":"Modify Master API Key","description":"Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/modify-sub-apikey":{"id":"v5/user/modify-sub-apikey","title":"Modify Sub API Key","description":"Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master","sidebar":"v5SideBar"},"v5/user/rm-master-apikey":{"id":"v5/user/rm-master-apikey","title":"Delete Master API Key","description":"Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/rm-sub-apikey":{"id":"v5/user/rm-sub-apikey","title":"Delete Sub API Key","description":"Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key","sidebar":"v5SideBar"},"v5/user/rm-subuid":{"id":"v5/user/rm-subuid","title":"Delete Sub UID","description":"Delete a sub UID. Before deleting the UID, please make sure there is no asset.","sidebar":"v5SideBar"},"v5/user/subuid-list":{"id":"v5/user/subuid-list","title":"Get Sub UID List","description":"Get all sub UID of master account. Use master user\'s api key only.","sidebar":"v5SideBar"},"v5/user/wallet-type":{"id":"v5/user/wallet-type","title":"Get UID Wallet Type","description":"Get available wallet types for the master account or sub account","sidebar":"v5SideBar"},"v5/websocket/private/dcp":{"id":"v5/websocket/private/dcp","title":"Dcp","description":"Subscribe to the dcp stream to trigger DCP function.","sidebar":"v5SideBar"},"v5/websocket/private/execution":{"id":"v5/websocket/private/execution","title":"Execution","description":"Subscribe to the execution stream to see your executions in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/greek":{"id":"v5/websocket/private/greek","title":"Greek","description":"Subscribe to the greeks stream to see changes to your greeks data in real-time. option only.","sidebar":"v5SideBar"},"v5/websocket/private/order":{"id":"v5/websocket/private/order","title":"Order","description":"Subscribe to the order stream to see changes to your orders in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/position":{"id":"v5/websocket/private/position","title":"Position","description":"Subscribe to the position stream to see changes to your position data in real-time.","sidebar":"v5SideBar"},"v5/websocket/private/wallet":{"id":"v5/websocket/private/wallet","title":"Wallet","description":"Subscribe to the wallet stream to see changes to your wallet in real-time.","sidebar":"v5SideBar"},"v5/websocket/public/etp-kline":{"id":"v5/websocket/public/etp-kline","title":"LT Kline","description":"Subscribe to the leveraged token kline stream.","sidebar":"v5SideBar"},"v5/websocket/public/etp-nav":{"id":"v5/websocket/public/etp-nav","title":"LT Nav","description":"Subscribe to the leveraged token nav stream.","sidebar":"v5SideBar"},"v5/websocket/public/etp-ticker":{"id":"v5/websocket/public/etp-ticker","title":"LT Ticker","description":"Subscribe to the leveraged token ticker stream.","sidebar":"v5SideBar"},"v5/websocket/public/kline":{"id":"v5/websocket/public/kline","title":"Kline","description":"Subscribe to the klines stream.","sidebar":"v5SideBar"},"v5/websocket/public/liquidation":{"id":"v5/websocket/public/liquidation","title":"Liquidation","description":"Subscribe to the liquidation stream","sidebar":"v5SideBar"},"v5/websocket/public/orderbook":{"id":"v5/websocket/public/orderbook","title":"Orderbook","description":"Subscribe to the orderbook stream. Supports different depths.","sidebar":"v5SideBar"},"v5/websocket/public/ticker":{"id":"v5/websocket/public/ticker","title":"Ticker","description":"Subscribe to the ticker stream.","sidebar":"v5SideBar"},"v5/websocket/public/trade":{"id":"v5/websocket/public/trade","title":"Trade","description":"Subscribe to the recent trades stream.","sidebar":"v5SideBar"},"v5/websocket/wss-authentication":{"id":"v5/websocket/wss-authentication","title":"Connect","description":"WebSocket public channel:","sidebar":"v5SideBar"},"zh-my/account_asset":{"id":"zh-my/account_asset","title":"account_asset","description":"const Home = () => {"},"zh-my/account_asset/v1":{"id":"zh-my/account_asset/v1","title":"v1","description":"const Home = () => {"},"zh-my/account_asset/v3":{"id":"zh-my/account_asset/v3","title":"v3","description":"const Home = () => {"},"zh-my/copy_trading":{"id":"zh-my/copy_trading","title":"copy_trading","description":"const Home = () => {"},"zh-my/derivativesV3/contract":{"id":"zh-my/derivativesV3/contract","title":"contract","description":"const Home = () => {"},"zh-my/derivativesV3/unified_margin":{"id":"zh-my/derivativesV3/unified_margin","title":"unified_margin","description":"const Home = () => {"},"zh-my/futuresV2/inverse":{"id":"zh-my/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/futuresV2/inverse_futures":{"id":"zh-my/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/futuresV2/linear":{"id":"zh-my/futuresV2/linear","title":"linear","description":"const Home = () => {"},"zh-my/inverse":{"id":"zh-my/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/inverse_futures":{"id":"zh-my/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/linear":{"id":"zh-my/linear","title":"linear","description":"const Home = () => {"},"zh-my/spot":{"id":"zh-my/spot","title":"spot","description":"const Home = () => {"},"zh-my/spot/v1":{"id":"zh-my/spot/v1","title":"v1","description":"const Home = () => {"},"zh-my/spot/v3":{"id":"zh-my/spot/v3","title":"v3","description":"const Home = () => {"},"zh-my/tax":{"id":"zh-my/tax","title":"tax","description":"const Home = () => {"},"zh-my/testnet/account_asset/v1":{"id":"zh-my/testnet/account_asset/v1","title":"v1","description":"const Home = () => {"},"zh-my/testnet/account_asset/v3":{"id":"zh-my/testnet/account_asset/v3","title":"v3","description":"const Home = () => {"},"zh-my/testnet/copy_trading":{"id":"zh-my/testnet/copy_trading","title":"copy_trading","description":"const Home = () => {"},"zh-my/testnet/futuresV2/inverse":{"id":"zh-my/testnet/futuresV2/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/testnet/futuresV2/inverse_futures":{"id":"zh-my/testnet/futuresV2/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/testnet/futuresV2/linear":{"id":"zh-my/testnet/futuresV2/linear","title":"linear","description":"const Home = () => {"},"zh-my/testnet/inverse":{"id":"zh-my/testnet/inverse","title":"inverse","description":"const Home = () => {"},"zh-my/testnet/inverse_futures":{"id":"zh-my/testnet/inverse_futures","title":"inverse_futures","description":"const Home = () => {"},"zh-my/testnet/linear":{"id":"zh-my/testnet/linear","title":"linear","description":"const Home = () => {"},"zh-my/testnet/spot":{"id":"zh-my/testnet/spot","title":"spot","description":"const Home = () => {"},"zh-my/testnet/spot/v1":{"id":"zh-my/testnet/spot/v1","title":"v1","description":"const Home = () => {"},"zh-my/testnet/spot/v3":{"id":"zh-my/testnet/spot/v3","title":"v3","description":"const Home = () => {"},"zh-my/testnet/usdc/option":{"id":"zh-my/testnet/usdc/option","title":"option","description":"const Home = () => {"},"zh-my/testnet/usdc/perpetual":{"id":"zh-my/testnet/usdc/perpetual","title":"perpetual","description":"const Home = () => {"},"zh-my/usdc/option":{"id":"zh-my/usdc/option","title":"option","description":"const Home = () => {"},"zh-my/usdc/perpetual":{"id":"zh-my/usdc/perpetual","title":"perpetual","description":"const Home = () => {"}}}')}}]); \ No newline at end of file diff --git a/assets/js/runtime~main.7d6c1861.js b/assets/js/runtime~main.de6c4d09.js similarity index 99% rename from assets/js/runtime~main.7d6c1861.js rename to assets/js/runtime~main.de6c4d09.js index 7b54b22d8b..0083f7df0e 100644 --- a/assets/js/runtime~main.7d6c1861.js +++ b/assets/js/runtime~main.de6c4d09.js @@ -1 +1 @@ -(()=>{"use strict";var e,b,a,f,d,c={},r={};function t(e){var b=r[e];if(void 0!==b)return b.exports;var a=r[e]={id:e,loaded:!1,exports:{}};return c[e].call(a.exports,a,a.exports,t),a.loaded=!0,a.exports}t.m=c,e=[],t.O=(b,a,f,d)=>{if(!a){var c=1/0;for(i=0;i=d)&&Object.keys(t.O).every((e=>t.O[e](a[o])))?a.splice(o--,1):(r=!1,d0&&e[i-1][2]>d;i--)e[i]=e[i-1];e[i]=[a,f,d]},t.n=e=>{var b=e&&e.__esModule?()=>e.default:()=>e;return t.d(b,{a:b}),b},a=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,t.t=function(e,f){if(1&f&&(e=this(e)),8&f)return e;if("object"==typeof e&&e){if(4&f&&e.__esModule)return e;if(16&f&&"function"==typeof e.then)return e}var d=Object.create(null);t.r(d);var c={};b=b||[null,a({}),a([]),a(a)];for(var r=2&f&&e;"object"==typeof r&&!~b.indexOf(r);r=a(r))Object.getOwnPropertyNames(r).forEach((b=>c[b]=()=>e[b]));return c.default=()=>e,t.d(d,c),d},t.d=(e,b)=>{for(var a in b)t.o(b,a)&&!t.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:b[a]})},t.f={},t.e=e=>Promise.all(Object.keys(t.f).reduce(((b,a)=>(t.f[a](e,b),b)),[])),t.u=e=>"assets/js/"+({42:"2518c83b",520:"fb1a77b4",783:"84002310",1046:"ee503142",1269:"9e31950e",1286:"f5bce583",1669:"f58086e5",1739:"510acf22",1770:"e6847b95",1802:"96368f4f",1893:"4c5e977b",1972:"ed99de2c",2050:"f54e89d1",2112:"5e4fe134",2143:"64e17396",2375:"1c94925b",2449:"3e99551e",2528:"5b292b69",2666:"09c26509",2951:"9bb13d2e",3299:"7e3ea763",3300:"655c39d2",3507:"7190026f",3522:"abf6ee25",4147:"345d96d3",4159:"b9acd066",4193:"95ce3c59",4387:"78950515",4694:"98dc0d0e",4696:"9569bc2f",4993:"7cfe228b",5209:"bcd351e4",5295:"5bcf38c1",5665:"7bb9f034",5872:"587e3d47",5886:"31d96af4",6282:"cd8b4f9a",6473:"a83fc124",6576:"fc169afb",6597:"44177285",6620:"8399f467",6675:"036e14f3",6768:"4eb9b8ff",6874:"8b221193",6907:"0393be11",7267:"c9713a6d",7338:"833a1fde",7828:"f72af8b9",7841:"179c9190",7954:"b90c57a3",8025:"b42f8477",8179:"136658e4",8347:"8b988d57",8966:"16ef1cd9",9022:"29b0efd4",9113:"84ab2fd1",9300:"903944d2",9532:"68079445",9609:"8e84b0d9",9624:"3042b185",9800:"9ff509e1",9817:"14eb3368",10225:"883bb60a",10235:"a7d19085",10293:"fa570740",11005:"c127b609",11013:"e8acd80e",11053:"7205acf7",11119:"988d8e24",11265:"f6106990",11389:"a005ddbc",11396:"e3e28d8f",11792:"855341b1",11908:"f9fe6464",12319:"e6b47cdb",12333:"650716b7",12717:"0b0bc04d",12933:"b6036b82",13085:"1f391b9e",13364:"74e68634",13408:"fdf22a50",13467:"08cdb8be",13994:"b2ae77a0",14030:"c5d3bb95",14132:"b6eadb9e",14243:"0744e06b",14281:"30bb4662",14491:"1fefa037",14582:"fed448c0",14731:"64e1104a",14760:"4863838d",14796:"a41d5bc2",14945:"b9fef5ef",15068:"e4440f9d",15114:"ee7f03d8",15262:"664d32ba",15272:"bed401a1",15309:"57f8207f",15365:"b82d00b2",15408:"2435c844",15609:"060b1584",15903:"f4c85b32",16071:"094a53a9",16377:"07ffdee5",16401:"1a7a3335",16667:"f81ec24e",16677:"3d4af990",16720:"4ac45b89",16771:"028b7f22",16825:"5621bfd0",17210:"daa5df1a",17445:"1a299676",17638:"e165cecb",18085:"f56ba7e1",18104:"7ab943be",18287:"82405689",18772:"c83cf481",19063:"0004065d",19122:"c1adbe0b",19178:"3956460a",19270:"cba951d8",19389:"2a8d8e88",19715:"2cfd0fc8",19831:"4e7e2ca5",20048:"441ee7d2",20367:"05a3c259",20844:"4e1901bc",20926:"05bb3e6b",21004:"bc0c7228",21390:"a6905832",21493:"79022373",21945:"ccaa939a",22162:"31593e16",22399:"0d34b62b",22477:"2b25df32",22982:"f041af6f",23003:"34fadc99",23022:"e0a5c1d2",23389:"9041aea1",23747:"bedf2929",23750:"c77ce8fa",24069:"41ce3377",24114:"170bc0f5",24180:"83b28724",24215:"13696f7b",24804:"440f78e7",24851:"a592f1e4",24989:"0f2dc4ca",25329:"4eca193c",25374:"980085d9",25785:"20f55e05",25968:"156751cf",25969:"07ca0209",26192:"e3bf20e0",26295:"67f94a41",26467:"302d24dc",26648:"0157939d",26668:"b9fa1d17",26912:"197a4930",27044:"89e5bdec",27133:"92e99bf6",27188:"5036ec9d",27212:"e6cbd2ed",27238:"e298e99e",28135:"89179ad6",28155:"094ce30e",28364:"069e89fb",28460:"dd3ced3a",28492:"9931c5c6",28608:"0cadbdb9",28772:"d5f94c50",28781:"7e458d36",28801:"6dfc2f3d",28848:"99d44459",29010:"8c2621f5",29217:"547b19b8",29514:"1be78505",29538:"4c950052",29770:"06b60cb4",29976:"f512b2b1",30051:"6dd54b46",30499:"24774f91",30561:"bc670d5c",30601:"e5d84bc0",30701:"21fa7ce5",30797:"80238aff",30882:"aedc496a",31094:"8675103a",31218:"eeea228c",31404:"3e301362",32111:"74db685e",32252:"eef51a73",32490:"1eaa7a2a",32755:"7e04e77d",33201:"18d0ad0f",33240:"0ab53148",33312:"8cd2105d",33404:"afdda5b6",33410:"8ed5753e",33509:"786f71e5",33527:"a5e760bc",33659:"0e5cbc44",33869:"e457634d",33949:"1e577d6c",34288:"af1ac92b",34548:"1a8c488b",35167:"6c74a4d7",35416:"cc68b255",35708:"41eb0037",35832:"b745f339",35898:"eb050011",35943:"bc53881b",36106:"c2ebbb3e",36137:"fcda79ce",36553:"18a5e8d6",36554:"9d979a6d",36648:"a6b8b35b",37018:"01464744",37034:"14f73ed3",37146:"86320adf",37193:"49541ebb",37222:"d1498869",37486:"dcc6b54d",37487:"a9bf2227",37570:"ab214d24",37896:"83cc66ac",38101:"1a004de9",38270:"5393ce94",38460:"c2d32f88",38818:"7e40020f",38890:"c084c2e9",38959:"1eb543d3",39127:"a230a772",39580:"75ecb4f9",39626:"fd867f7c",39675:"62547fbf",39796:"3e9399ec",40073:"359a0a8d",40081:"39f63e6a",40114:"8740ec05",40211:"eb907bb2",40219:"49e3720f",40542:"41790d5d",40614:"716600a7",40683:"0abae2e0",40701:"1ce0a301",40830:"c343ef35",40916:"e4459066",41003:"d0d62bb5",41276:"a6c72656",41804:"ee640683",41847:"82a30884",41877:"717e7ee6",42069:"9a6be05d",42885:"acdbee8e",43726:"6b85e2ea",44120:"a61ed651",44209:"278665dc",44850:"1bde5858",44880:"e7d2e6f0",44916:"95d5a544",45111:"cb819e9b",45167:"da88d543",45208:"034a556b",45293:"2f7c7419",45919:"8070429a",46039:"778f38dc",46215:"784585a8",46566:"763e4dec",46976:"70b01d77",47137:"47f09a6b",47328:"6daf901a",47563:"146da2b4",47615:"84ebbbbf",47769:"196fab6d",47969:"7f281903",48026:"a120aaca",48081:"5dce62fd",48124:"553f321c",48169:"e4492fa7",48244:"41f003c0",48890:"d5603669",48954:"b0bdb7f3",49486:"e72cf26a",49717:"a5962d55",49755:"c123803f",50030:"fd3dbbb4",50067:"246367e0",50430:"867911a0",50730:"4b1cba20",50893:"965dbb95",50932:"485af29a",51106:"dd813bf5",51410:"bd1a9377",51523:"a3761f7f",52474:"4507e508",52486:"de127d6b",52574:"e2668db3",52603:"a4b6f3a5",52654:"f024ddd5",52831:"5ec88f12",53111:"203d8c37",53309:"63ee150d",53408:"4694df8d",53482:"a718913e",53501:"7795e3fe",53559:"ebe9f683",53630:"dd02e78e",53778:"2fa02bf3",54013:"2f5fda3e",54053:"24e3585b",54235:"695f8b9b",54601:"c552c222",54636:"760e3208",54801:"3ec68450",54820:"05a18904",55038:"100f3054",55229:"2fcfad90",55328:"74c40fe4",55381:"cfc9c16e",55480:"006095b2",56025:"c3aed80f",56319:"879063fc",56370:"36f93d19",56382:"9ffa1a6c",56886:"4b7a6889",56955:"51ca6efd",56963:"1b80e345",56979:"d005934a",57060:"4be15b13",57067:"eece046c",57152:"e09bff2e",57251:"eb1718b4",57287:"bde9fb45",57480:"c86abbf7",57756:"6ab4408e",57979:"c5059afe",58e3:"fbf4432e",58188:"e73e328f",58235:"3bdeaa89",58353:"162f137e",58634:"e6a2b2bf",58663:"c7dcc258",59082:"6a9a7317",59131:"3b0223df",59135:"e27b8251",59319:"35379327",59469:"68648e27",59485:"edfdb191",59607:"25f376d4",59728:"aa5bd2a7",59738:"d68e7e95",59856:"e5c88a3e",59865:"e8ee0390",59910:"16142a34",59953:"2041170f",60298:"d4e7ac8a",60310:"5913a508",60377:"2d4599ae",60679:"353f52a3",61166:"2fcd316c",61304:"8d5fe6f9",61528:"2b6f680f",62062:"988ba51e",62353:"35d50d77",62746:"00468222",62860:"3d49fc0e",63447:"1c5b9066",63497:"b8541bfd",63851:"51b69e86",64166:"c54a5582",64195:"c4f5d8e4",64209:"d7a48e98",64214:"575f1b1b",64280:"95a35da8",64364:"4bec54d5",64497:"099f8a1f",64549:"788d9fe0",64557:"63c7b841",64814:"8ade285d",64925:"7ee339c8",65149:"53e78238",65154:"af35203c",65349:"796ce4fb",65368:"cc468388",65573:"291c8f9c",65687:"2f2f8f8f",65957:"e4627c87",66068:"e8bf0c3e",66345:"42a8d727",66546:"e938eb25",66880:"f32d8490",67098:"6df78374",67112:"7196ee6c",67328:"137314dd",67365:"18f77871",67374:"6279c8a9",67746:"df7ec86c",67813:"8894256f",67821:"bcd02ebb",67861:"0f9cda3e",68005:"73ce7b01",68207:"7622c6de",68253:"363ba2d8",68349:"3d3a07f6",68503:"f8c92f63",68809:"4090f62b",68970:"eaafcd74",69043:"9ad8637e",69125:"c80ee60a",69184:"30b61715",69572:"8000380e",69753:"7e31db45",69905:"e23eefc0",70022:"41abf40a",70147:"b9535f14",70332:"39fee459",70509:"3b768736",70633:"b50c9021",70670:"e62aa786",70743:"c7399101",70838:"22bdf908",71347:"e93ff9aa",71568:"43cca846",71600:"397d4a7e",71723:"0328b0c9",71871:"ce32ce4d",71910:"2a3724f5",72069:"57494db5",72145:"a5c74766",72379:"9dba6800",72809:"540cb455",72841:"bb0e99df",72978:"5bf9b44a",73091:"04849bf5",73375:"94fe2afe",73464:"3c6391c1",73695:"bdb43652",73894:"9b6eea2c",73905:"94b87f57",73918:"4294ceba",74190:"84cf2087",74298:"48db5030",74428:"53d82fc0",74531:"b25d4024",74971:"0ed89c29",75063:"cf69f832",75066:"466daf09",75288:"77de130e",75474:"4e6cf383",75600:"30fdf4bf",75791:"0667cc8f",76152:"b180b1b1",76255:"94a29094",76428:"418c923e",76434:"40878283",76541:"d67ae496",76549:"7a65c859",77184:"11b4dd89",77535:"eb746456",77665:"97d979ce",77811:"18a382cc",77937:"ea313555",77944:"6bc64de5",77999:"3af651bf",78023:"2b20c80a",78315:"9218c1fd",78340:"5f10f6e3",78541:"0abbbb35",78638:"1fa35ec3",78776:"f46c4408",79014:"e77a5489",79046:"904cfab0",79054:"722ec584",79239:"b27348e5",79315:"378b1b2a",79376:"6249c7de",79475:"1db45fbc",79480:"7c767e9e",79923:"77622da5",80032:"8c139ad0",80053:"935f2afb",80103:"500ab5e8",80369:"a7c6c228",80536:"17c91901",80567:"df36d98d",80808:"b85fa405",81030:"d312cf7c",81135:"6c43de6e",81188:"476a319a",81447:"df330cef",81451:"563d7403",81500:"bffae127",81747:"f1e3befe",81981:"c8450cf2",82294:"555d583b",82381:"16127d6f",82672:"71c1d7a6",82708:"d5e6c777",82718:"471f7fbd",82803:"aea5d0af",82921:"12f49e0c",83100:"da6ad706",83154:"67009ff2",83302:"9622a62d",83398:"9f602629",83416:"d8f590ab",83616:"0d16b667",83701:"ef308d07",83771:"8c02dfd8",83773:"39c791a9",84052:"1dc390ba",84099:"38f61187",84249:"8dca2180",84386:"121b1090",84840:"2e4eadd3",84857:"b4eef555",84878:"2e8d4eda",84959:"c75d7ff6",84987:"d94bb6b6",85056:"730110a3",85188:"c0e80954",85313:"06848362",85534:"e593aec6",85621:"87b2412c",85660:"6dd1645f",85836:"bf0b75c4",85897:"6b3775fc",85953:"b700f6c8",86072:"26183636",86139:"9267eb77",86390:"c4cf1261",86451:"f2a10594",86529:"cb4175f3",87173:"87a13df2",87414:"393be207",87493:"d46f8e51",87655:"40230f21",87658:"6dde3b76",87677:"750960ca",87824:"4c4c3de8",88042:"5daee80f",88258:"8204d27d",88831:"3c8da607",88935:"99494472",89047:"856bceac",89083:"db4f0c5e",89167:"faee50e1",89415:"3f0d1ba4",89776:"b7c7e74a",89786:"c1d23c47",89912:"75a6ad06",89964:"b82b3205",90357:"e0751957",90951:"76e9b4e1",91538:"0248575c",91569:"5a7e7a34",91759:"ec202e26",92097:"9a072ddf",92416:"726fea1f",92560:"0c337ca4",93006:"5be4f4f7",93056:"73bfea73",93065:"812cb8ed",93348:"eb2927ba",93387:"007a6c32",93418:"49dbb45e",93507:"4a6f24a9",93543:"510addcb",94089:"d9ffe17e",94194:"4b3e38af",94201:"d6b0fe44",94215:"189eacae",94276:"d108a77f",94319:"d0816b53",94506:"fd03cc72",94907:"29f28a73",95190:"f8dc48d9",95496:"994f6abf",95557:"6f9bf5a7",95662:"caaad1b0",95690:"f4bc196f",95974:"710d4e4e",96247:"6ab4df05",96276:"8aadacf1",96361:"3aecebcc",96551:"120d9fdd",96826:"68f43c04",97170:"03e0b503",97421:"c8a855a5",97482:"4a3e680b",97500:"d63a00cf",97719:"51c3befa",97879:"e9d56634",97900:"954fe569",97920:"1a4e3797",98016:"ffb2e417",98105:"acc38ec3",98220:"4b25ddc7",98591:"a61cb094",98604:"d0931cd6",98630:"68e9a632",98692:"67044a7a",98792:"0d6f57e0",98948:"65e0cd55",98960:"4ade5613",99070:"02574e0f",99438:"b5511831",99533:"a6f4eced",99822:"595b2ce9",99889:"f56b8973"}[e]||e)+"."+{42:"c43f8910",520:"5c2a267b",783:"d4f745cf",1046:"f421e3c0",1269:"7bc4f975",1286:"28d0b3fc",1669:"4752392e",1739:"3d437425",1770:"d15d6c60",1802:"043f0de8",1893:"4a98b5fe",1972:"7594392d",2050:"823155de",2112:"82477c40",2143:"78f20385",2375:"34eb2114",2449:"c8c4a269",2528:"17f369fc",2666:"1a51e707",2951:"21706190",3299:"c104220f",3300:"2dc42cf3",3507:"019a9fa5",3522:"25589105",4147:"9a01466a",4159:"6d060ce6",4193:"d8c5fb64",4387:"c65dc917",4694:"e4aa9c43",4696:"261d15e2",4972:"c1e0c51c",4993:"acc5f429",5209:"be5a092c",5295:"8ff802c6",5665:"c17ab8c9",5872:"20b27d16",5886:"d9475a2e",6282:"de39aa72",6338:"359271aa",6473:"7ab3f71d",6576:"492e2951",6597:"73fc4cdd",6620:"2944efd1",6675:"d953ea15",6768:"e650080a",6874:"26bd809c",6907:"6cefc11d",7267:"b891b533",7338:"9fcd22c8",7828:"7614eb22",7841:"eaacaa11",7954:"2b01d23c",8025:"739425f2",8179:"d929c0f4",8347:"a04343be",8966:"336bd1a1",9022:"9e4d05b5",9113:"ecabc4d6",9300:"261c6639",9532:"5ec3ca5b",9609:"288677fa",9624:"cab240a8",9799:"cdb5b12a",9800:"8135d36c",9817:"f9d79ca6",10225:"3d3596d5",10235:"7e46f062",10293:"dacaf0b5",11005:"58d5b73e",11013:"aece890c",11053:"2c6dd170",11119:"a7f302b9",11265:"0c81fd6e",11389:"21b97b61",11396:"e0a86f74",11792:"4655b6c9",11908:"9641f6e6",12319:"25bcf0cf",12333:"893aa641",12717:"c448b7f5",12933:"f5ea1ee2",13085:"74c4de50",13364:"b9101d9f",13408:"e6044319",13467:"54cc787a",13994:"f6412254",14030:"57c1e1f4",14132:"618c5934",14243:"561b594f",14281:"cf8be476",14491:"23ccaa23",14582:"f07ccdf2",14731:"6e6937e7",14760:"c4ab7b63",14796:"67b6859e",14945:"ceaa448c",15068:"a911fd6e",15114:"a0cce757",15262:"18d69e6c",15272:"c902eb2f",15309:"8230c2ac",15365:"4759fbe7",15408:"5835c415",15609:"536132e5",15903:"649cb0cf",16071:"2dc6ee69",16377:"bcac3475",16401:"9c798132",16667:"4487755d",16677:"6dfb38be",16720:"2d17fe6d",16771:"ea90e09c",16825:"9319d7a3",17210:"045fe953",17445:"18a650a4",17638:"ca541869",18085:"554b52c4",18104:"80a63f08",18287:"e6a54e4f",18772:"f22facf0",18894:"2da9821d",19063:"d6dbfb6c",19122:"9af15b7c",19178:"96987a51",19270:"25a94c9f",19389:"feb155f7",19715:"ee5f3704",19831:"5f90158e",20048:"c475b360",20367:"0bb13b15",20844:"0c3e4097",20926:"53588a4c",21004:"036b2b1f",21390:"93917d02",21493:"c26a7538",21945:"72e3587f",22162:"5ebbe176",22399:"80f66527",22477:"c8fd2aa5",22761:"365a347a",22982:"fdca227d",23003:"a77f6c46",23022:"0bd66a28",23389:"8c8835a8",23747:"d3c92649",23750:"6130cc67",24069:"17aacc5f",24114:"54ee1cf0",24180:"baa2cde2",24215:"85fbc604",24804:"e3b992a0",24851:"c8502192",24989:"6dac20a5",25329:"0936a0bf",25374:"6d32276c",25785:"97d36de8",25968:"fab4e438",25969:"c51b573e",26192:"4212dfaf",26295:"4f220773",26467:"b303e60b",26648:"acbaf873",26668:"2e7c5e86",26912:"b3a88e29",27044:"0ff557a9",27133:"97370dd1",27188:"3624fcda",27212:"d30661f5",27238:"9afcec49",28135:"5b1476ac",28155:"317306dd",28364:"7f11b9bc",28460:"6e8b9fee",28492:"c9059ac6",28608:"315c7081",28772:"817ac08d",28781:"22102bff",28801:"54787bb9",28848:"761000fa",29010:"10df03ac",29217:"38f19102",29514:"e4bcc747",29538:"0518905a",29770:"17b7b24c",29976:"63adaa26",30051:"b8aa46bc",30499:"339d001a",30561:"1fc90304",30601:"2a5579b9",30701:"8b5b0eb7",30797:"85de9f7a",30882:"3c5ac118",31094:"f685f08e",31218:"d8725830",31404:"008d83aa",32111:"e4935bce",32252:"816c7d32",32490:"d0adf848",32755:"eead5037",33201:"446a5f5c",33240:"726c4a87",33312:"9907b91c",33404:"0efbfadd",33410:"76ac8dd8",33509:"f924244a",33527:"c0ee1aeb",33659:"f6432c75",33869:"0034ae7a",33949:"2d9b37a7",34288:"89e2c37b",34548:"510a448d",35167:"b49fab92",35416:"5322fc44",35708:"0fe8f81f",35832:"89b33974",35898:"9c2b236b",35943:"0cbd318b",36106:"035575ac",36137:"9bc3d126",36553:"0fc8fe84",36554:"f0d4c23c",36648:"e1106aa5",37018:"c6e5914d",37034:"75fec4c8",37146:"e6e9886a",37193:"40af0f54",37222:"b3275e97",37486:"c2082024",37487:"0b43fb28",37570:"44b39cf5",37896:"aa3c7b74",38101:"4d059d0a",38270:"c1ef53c6",38460:"e88eec46",38818:"2035cc81",38890:"afa6ad85",38959:"12c42e0b",39127:"8b4cf1c4",39580:"c324ee5d",39626:"db9dd9ea",39675:"21645207",39796:"0f844535",40073:"1c4aa29e",40081:"eff10365",40114:"354298b2",40211:"3df45470",40219:"7603b1f6",40542:"627141b9",40614:"1611c893",40683:"4c6d71f0",40701:"d5e8f1c1",40830:"53ae3566",40916:"729db7d8",41003:"36e31dce",41276:"8dadc84f",41804:"d1aca82e",41847:"e8cd87e2",41877:"1814cb04",42069:"069e635b",42885:"bfa95af9",43726:"990e8b22",44120:"8f4578a0",44209:"28c163b6",44850:"c3eecc99",44880:"8942da16",44916:"1bc7c335",45111:"0a16adcc",45167:"3abc174e",45208:"0e603945",45293:"c5e7682e",45919:"0d56535a",46039:"de587cdd",46215:"08417467",46566:"a5077acb",46945:"11021670",46976:"5e04970b",47137:"bef3f80c",47328:"6bf4dc53",47563:"dddd758f",47615:"835b1cc6",47769:"8ef7c2e0",47969:"9ef94159",48026:"8cad975d",48081:"23fd8a90",48124:"636e6e24",48169:"d5d88ba9",48244:"f9a2d353",48890:"32c5ddf3",48954:"cdfc2c65",49486:"b4557cfa",49717:"1d6ff5e3",49755:"a388e846",50030:"6bec3ed2",50067:"0bdf2d2a",50430:"7910e348",50730:"c8c75462",50893:"36df98f6",50932:"5af46298",51106:"98875bed",51410:"c9fc3c07",51523:"8598a7f5",52474:"de8bba8d",52486:"635a774e",52574:"472cf42f",52603:"9d89ea47",52654:"92b816af",52831:"c3227a77",53111:"0d6852e5",53309:"8ae306cc",53408:"c8dc96a4",53482:"df103e38",53501:"7cf5c335",53559:"bd21e86d",53630:"c92dce0e",53778:"367f311a",54013:"961b0355",54053:"9e602739",54235:"6a08614d",54601:"c7802446",54636:"56e055f1",54801:"433ccde3",54820:"d82b721a",55038:"0efb12f2",55229:"ebcdbf21",55328:"bc82ad85",55381:"0f7ce3c0",55480:"d528d018",56025:"16398596",56319:"74302ebf",56370:"b8478850",56382:"3def563d",56886:"ca6f13c8",56955:"78038386",56963:"0c50b8a7",56979:"0ba2abc6",57060:"b1c30f6b",57067:"94292e0b",57152:"af1ad35a",57251:"ed7488a0",57287:"e26ec7d5",57480:"0866edfb",57756:"f5aeb441",57979:"1ff7221e",58e3:"5ec47679",58188:"1fe0b3e6",58235:"ca76d8fc",58353:"622fffee",58634:"12458c96",58663:"57e0701e",59082:"6c8b93f7",59131:"441f24ce",59135:"6f73f94f",59319:"cd719bc0",59469:"6976aee8",59485:"bd33ab11",59607:"1e04d082",59728:"a4c378d0",59738:"f2030e38",59856:"0b84f70e",59865:"deb8694a",59910:"95e1e5e2",59953:"4166ce32",60298:"5f669764",60310:"a77f85b7",60377:"0c71fdb8",60679:"b9b7c276",61166:"61a621a5",61304:"009bd8ba",61528:"de68d6ec",62062:"d3b53104",62353:"3b2b9e41",62746:"c9463b36",62860:"8684fd86",63447:"3d31efcb",63497:"f4d660ad",63851:"c999ace8",64166:"b71eccd0",64195:"07350901",64209:"f5ad69ae",64214:"2cc8e777",64280:"5efc0cff",64364:"5316964a",64497:"2395298f",64549:"1a1add38",64557:"007ee6f1",64814:"67f95d80",64925:"2f99fa91",65149:"5abf9135",65154:"fb3eceb4",65349:"7ee9aa91",65368:"5b1c1d58",65573:"2c6331be",65687:"c6809b64",65957:"95afcdf9",66068:"3b887511",66345:"8c235ba0",66546:"2106ffbc",66880:"fa4535e7",67098:"245147a0",67112:"ea592d9a",67328:"40b70453",67365:"ff7af498",67374:"a4a3557e",67746:"73579300",67813:"169c3ef2",67821:"f59a1771",67861:"feded733",68005:"c1051622",68207:"2543c5de",68253:"87f711c9",68349:"3df1974e",68503:"89385e31",68724:"bd00f8e9",68809:"ae6235ee",68970:"6227e9a9",69043:"b88c085a",69125:"c6e399ca",69184:"e8a26324",69572:"0037e2de",69753:"8344f96a",69905:"5390d20c",70022:"b7c72e72",70147:"7e1836d5",70332:"e4214ba7",70509:"634f930a",70633:"2676ed95",70670:"4647b158",70743:"1bc17e63",70838:"8445a962",71347:"b8233b2a",71568:"6166d0da",71600:"387e240c",71723:"aa61b8c8",71814:"56dd82a2",71871:"1654e72b",71910:"b220fcde",72069:"a92d7715",72145:"64ff0e7f",72379:"8cb7d62c",72809:"cf9cae29",72841:"8ecfd9ac",72978:"787c9bcd",73091:"2234b421",73375:"177280a8",73464:"5f9bce6c",73695:"e2b4cac6",73894:"713fdd3d",73905:"8bd67e5c",73918:"a40b3907",74190:"76cd087b",74298:"d717c136",74428:"d722afe9",74531:"67a3f108",74971:"e4dabd31",75063:"80ef3c52",75066:"54042ed9",75288:"f71e9af9",75474:"a3c68a2c",75600:"fe5ce8c7",75791:"22c15814",76152:"d2f3715c",76255:"15271f83",76428:"a691b41f",76434:"5d75b4fd",76541:"bf22c3cc",76549:"54c764b8",76780:"a2521cf6",77184:"5344e158",77535:"668fadda",77665:"0bb895e1",77811:"806940f9",77937:"264a7976",77944:"eb111f96",77999:"074e4008",78023:"8f7b2b62",78315:"fddd6e0b",78340:"fd8f0a19",78541:"1875c215",78638:"cbff6869",78776:"0c62f023",79014:"6378fbc5",79046:"438a917c",79054:"bb10d360",79239:"c5e9eef2",79315:"c9864331",79376:"772aa1f2",79475:"4341bb63",79480:"1cabc8e8",79923:"24e9dfb4",80032:"b63ca947",80053:"09a35993",80103:"adb45701",80369:"823951a8",80536:"1fc24eda",80567:"6a9d0b26",80808:"d89117d5",81030:"f8ac3f2c",81135:"4c893d97",81188:"23452a7d",81447:"6435e97d",81451:"df661c64",81500:"86e20713",81747:"712b5a86",81981:"aca1e4a5",82294:"fa192674",82381:"faeefc76",82672:"b1911849",82708:"cab3b61f",82718:"52d0bf25",82803:"792692fe",82921:"917648f0",83100:"ff43253e",83154:"b0af7501",83302:"05d57b7e",83398:"61763665",83416:"7b819fe1",83616:"8ebf4756",83701:"760e705a",83771:"076b6e5d",83773:"2909b551",84052:"78b5196f",84099:"3e664253",84249:"89ad564d",84386:"3cdac849",84840:"c9ae913e",84857:"a2328bb0",84878:"5edf6cbd",84959:"77f53787",84987:"3a555e6d",85056:"e929ee43",85188:"103821dc",85313:"49c56bb7",85534:"9bf0046e",85621:"b14f6a91",85660:"d41a7652",85836:"e76ef639",85897:"31ab244d",85953:"474bfc80",86072:"b2386542",86139:"6b79a1a5",86390:"98cacb7c",86451:"bcb991c4",86529:"ec82adac",87173:"e22cd17a",87414:"e74de51a",87493:"0072bd90",87655:"664033ae",87658:"0b016f35",87677:"baaf40c3",87824:"7eddecc7",88042:"70c3c1f9",88258:"8ed27800",88831:"e3546d5f",88935:"73e4d93a",89047:"15309827",89083:"591c8943",89167:"b785a832",89415:"33ee9ac5",89776:"04406d29",89786:"975a5550",89912:"45d78fc7",89964:"1950abd7",90357:"35110dae",90951:"e5e599eb",91538:"5bee4d8c",91569:"ce93dfb7",91759:"63117712",92097:"85d2fd38",92416:"07ce2e4c",92560:"9b3787fc",93006:"2d30d12a",93056:"b5c58925",93065:"b033e6cb",93348:"27f4c48c",93387:"64b4440b",93418:"3ee42084",93507:"a657a544",93543:"cf45b1b9",94089:"adfc8b09",94194:"e23dd625",94201:"15a7b665",94215:"aacdca39",94276:"6afc6a42",94319:"2bf1ddcc",94506:"3a8a0c30",94907:"29225ebf",95190:"813a5c8a",95496:"603eb1ee",95557:"ff4a681a",95662:"848f1286",95690:"ebf24935",95974:"46a39b17",96247:"ae1d6419",96276:"74c119ca",96361:"e24f4c03",96551:"807583b8",96826:"dbd45390",97170:"30294cd2",97421:"2e7bbb6e",97482:"beb13a9b",97500:"7e68e3a7",97719:"5defa7bb",97879:"03182d91",97900:"a14e34b2",97920:"d5457aa2",98016:"d08720e9",98105:"48938e56",98220:"933b63ce",98591:"98be4f3a",98604:"5372b027",98630:"7607f8c9",98692:"f146280e",98792:"9f8cc5eb",98948:"75dc840b",98960:"79202773",99070:"6d90e6e1",99438:"6c99546d",99533:"d4e17677",99822:"5b9bd95e",99889:"d667b6bf"}[e]+".js",t.miniCssF=e=>{},t.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),t.o=(e,b)=>Object.prototype.hasOwnProperty.call(e,b),f={},d="docusaurus-docs:",t.l=(e,b,a,c)=>{if(f[e])f[e].push(b);else{var r,o;if(void 0!==a)for(var n=document.getElementsByTagName("script"),i=0;i{r.onerror=r.onload=null,clearTimeout(l);var d=f[e];if(delete f[e],r.parentNode&&r.parentNode.removeChild(r),d&&d.forEach((e=>e(a))),b)return b(a)},l=setTimeout(s.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=s.bind(null,r.onerror),r.onload=s.bind(null,r.onload),o&&document.head.appendChild(r)}},t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),t.p="/docs/",t.gca=function(e){return e={26183636:"86072",35379327:"59319",40878283:"76434",44177285:"6597",68079445:"9532",78950515:"4387",79022373:"21493",82405689:"18287",84002310:"783",99494472:"88935","2518c83b":"42",fb1a77b4:"520",ee503142:"1046","9e31950e":"1269",f5bce583:"1286",f58086e5:"1669","510acf22":"1739",e6847b95:"1770","96368f4f":"1802","4c5e977b":"1893",ed99de2c:"1972",f54e89d1:"2050","5e4fe134":"2112","64e17396":"2143","1c94925b":"2375","3e99551e":"2449","5b292b69":"2528","09c26509":"2666","9bb13d2e":"2951","7e3ea763":"3299","655c39d2":"3300","7190026f":"3507",abf6ee25:"3522","345d96d3":"4147",b9acd066:"4159","95ce3c59":"4193","98dc0d0e":"4694","9569bc2f":"4696","7cfe228b":"4993",bcd351e4:"5209","5bcf38c1":"5295","7bb9f034":"5665","587e3d47":"5872","31d96af4":"5886",cd8b4f9a:"6282",a83fc124:"6473",fc169afb:"6576","8399f467":"6620","036e14f3":"6675","4eb9b8ff":"6768","8b221193":"6874","0393be11":"6907",c9713a6d:"7267","833a1fde":"7338",f72af8b9:"7828","179c9190":"7841",b90c57a3:"7954",b42f8477:"8025","136658e4":"8179","8b988d57":"8347","16ef1cd9":"8966","29b0efd4":"9022","84ab2fd1":"9113","903944d2":"9300","8e84b0d9":"9609","3042b185":"9624","9ff509e1":"9800","14eb3368":"9817","883bb60a":"10225",a7d19085:"10235",fa570740:"10293",c127b609:"11005",e8acd80e:"11013","7205acf7":"11053","988d8e24":"11119",f6106990:"11265",a005ddbc:"11389",e3e28d8f:"11396","855341b1":"11792",f9fe6464:"11908",e6b47cdb:"12319","650716b7":"12333","0b0bc04d":"12717",b6036b82:"12933","1f391b9e":"13085","74e68634":"13364",fdf22a50:"13408","08cdb8be":"13467",b2ae77a0:"13994",c5d3bb95:"14030",b6eadb9e:"14132","0744e06b":"14243","30bb4662":"14281","1fefa037":"14491",fed448c0:"14582","64e1104a":"14731","4863838d":"14760",a41d5bc2:"14796",b9fef5ef:"14945",e4440f9d:"15068",ee7f03d8:"15114","664d32ba":"15262",bed401a1:"15272","57f8207f":"15309",b82d00b2:"15365","2435c844":"15408","060b1584":"15609",f4c85b32:"15903","094a53a9":"16071","07ffdee5":"16377","1a7a3335":"16401",f81ec24e:"16667","3d4af990":"16677","4ac45b89":"16720","028b7f22":"16771","5621bfd0":"16825",daa5df1a:"17210","1a299676":"17445",e165cecb:"17638",f56ba7e1:"18085","7ab943be":"18104",c83cf481:"18772","0004065d":"19063",c1adbe0b:"19122","3956460a":"19178",cba951d8:"19270","2a8d8e88":"19389","2cfd0fc8":"19715","4e7e2ca5":"19831","441ee7d2":"20048","05a3c259":"20367","4e1901bc":"20844","05bb3e6b":"20926",bc0c7228:"21004",a6905832:"21390",ccaa939a:"21945","31593e16":"22162","0d34b62b":"22399","2b25df32":"22477",f041af6f:"22982","34fadc99":"23003",e0a5c1d2:"23022","9041aea1":"23389",bedf2929:"23747",c77ce8fa:"23750","41ce3377":"24069","170bc0f5":"24114","83b28724":"24180","13696f7b":"24215","440f78e7":"24804",a592f1e4:"24851","0f2dc4ca":"24989","4eca193c":"25329","980085d9":"25374","20f55e05":"25785","156751cf":"25968","07ca0209":"25969",e3bf20e0:"26192","67f94a41":"26295","302d24dc":"26467","0157939d":"26648",b9fa1d17:"26668","197a4930":"26912","89e5bdec":"27044","92e99bf6":"27133","5036ec9d":"27188",e6cbd2ed:"27212",e298e99e:"27238","89179ad6":"28135","094ce30e":"28155","069e89fb":"28364",dd3ced3a:"28460","9931c5c6":"28492","0cadbdb9":"28608",d5f94c50:"28772","7e458d36":"28781","6dfc2f3d":"28801","99d44459":"28848","8c2621f5":"29010","547b19b8":"29217","1be78505":"29514","4c950052":"29538","06b60cb4":"29770",f512b2b1:"29976","6dd54b46":"30051","24774f91":"30499",bc670d5c:"30561",e5d84bc0:"30601","21fa7ce5":"30701","80238aff":"30797",aedc496a:"30882","8675103a":"31094",eeea228c:"31218","3e301362":"31404","74db685e":"32111",eef51a73:"32252","1eaa7a2a":"32490","7e04e77d":"32755","18d0ad0f":"33201","0ab53148":"33240","8cd2105d":"33312",afdda5b6:"33404","8ed5753e":"33410","786f71e5":"33509",a5e760bc:"33527","0e5cbc44":"33659",e457634d:"33869","1e577d6c":"33949",af1ac92b:"34288","1a8c488b":"34548","6c74a4d7":"35167",cc68b255:"35416","41eb0037":"35708",b745f339:"35832",eb050011:"35898",bc53881b:"35943",c2ebbb3e:"36106",fcda79ce:"36137","18a5e8d6":"36553","9d979a6d":"36554",a6b8b35b:"36648","01464744":"37018","14f73ed3":"37034","86320adf":"37146","49541ebb":"37193",d1498869:"37222",dcc6b54d:"37486",a9bf2227:"37487",ab214d24:"37570","83cc66ac":"37896","1a004de9":"38101","5393ce94":"38270",c2d32f88:"38460","7e40020f":"38818",c084c2e9:"38890","1eb543d3":"38959",a230a772:"39127","75ecb4f9":"39580",fd867f7c:"39626","62547fbf":"39675","3e9399ec":"39796","359a0a8d":"40073","39f63e6a":"40081","8740ec05":"40114",eb907bb2:"40211","49e3720f":"40219","41790d5d":"40542","716600a7":"40614","0abae2e0":"40683","1ce0a301":"40701",c343ef35:"40830",e4459066:"40916",d0d62bb5:"41003",a6c72656:"41276",ee640683:"41804","82a30884":"41847","717e7ee6":"41877","9a6be05d":"42069",acdbee8e:"42885","6b85e2ea":"43726",a61ed651:"44120","278665dc":"44209","1bde5858":"44850",e7d2e6f0:"44880","95d5a544":"44916",cb819e9b:"45111",da88d543:"45167","034a556b":"45208","2f7c7419":"45293","8070429a":"45919","778f38dc":"46039","784585a8":"46215","763e4dec":"46566","70b01d77":"46976","47f09a6b":"47137","6daf901a":"47328","146da2b4":"47563","84ebbbbf":"47615","196fab6d":"47769","7f281903":"47969",a120aaca:"48026","5dce62fd":"48081","553f321c":"48124",e4492fa7:"48169","41f003c0":"48244",d5603669:"48890",b0bdb7f3:"48954",e72cf26a:"49486",a5962d55:"49717",c123803f:"49755",fd3dbbb4:"50030","246367e0":"50067","867911a0":"50430","4b1cba20":"50730","965dbb95":"50893","485af29a":"50932",dd813bf5:"51106",bd1a9377:"51410",a3761f7f:"51523","4507e508":"52474",de127d6b:"52486",e2668db3:"52574",a4b6f3a5:"52603",f024ddd5:"52654","5ec88f12":"52831","203d8c37":"53111","63ee150d":"53309","4694df8d":"53408",a718913e:"53482","7795e3fe":"53501",ebe9f683:"53559",dd02e78e:"53630","2fa02bf3":"53778","2f5fda3e":"54013","24e3585b":"54053","695f8b9b":"54235",c552c222:"54601","760e3208":"54636","3ec68450":"54801","05a18904":"54820","100f3054":"55038","2fcfad90":"55229","74c40fe4":"55328",cfc9c16e:"55381","006095b2":"55480",c3aed80f:"56025","879063fc":"56319","36f93d19":"56370","9ffa1a6c":"56382","4b7a6889":"56886","51ca6efd":"56955","1b80e345":"56963",d005934a:"56979","4be15b13":"57060",eece046c:"57067",e09bff2e:"57152",eb1718b4:"57251",bde9fb45:"57287",c86abbf7:"57480","6ab4408e":"57756",c5059afe:"57979",fbf4432e:"58000",e73e328f:"58188","3bdeaa89":"58235","162f137e":"58353",e6a2b2bf:"58634",c7dcc258:"58663","6a9a7317":"59082","3b0223df":"59131",e27b8251:"59135","68648e27":"59469",edfdb191:"59485","25f376d4":"59607",aa5bd2a7:"59728",d68e7e95:"59738",e5c88a3e:"59856",e8ee0390:"59865","16142a34":"59910","2041170f":"59953",d4e7ac8a:"60298","5913a508":"60310","2d4599ae":"60377","353f52a3":"60679","2fcd316c":"61166","8d5fe6f9":"61304","2b6f680f":"61528","988ba51e":"62062","35d50d77":"62353","00468222":"62746","3d49fc0e":"62860","1c5b9066":"63447",b8541bfd:"63497","51b69e86":"63851",c54a5582:"64166",c4f5d8e4:"64195",d7a48e98:"64209","575f1b1b":"64214","95a35da8":"64280","4bec54d5":"64364","099f8a1f":"64497","788d9fe0":"64549","63c7b841":"64557","8ade285d":"64814","7ee339c8":"64925","53e78238":"65149",af35203c:"65154","796ce4fb":"65349",cc468388:"65368","291c8f9c":"65573","2f2f8f8f":"65687",e4627c87:"65957",e8bf0c3e:"66068","42a8d727":"66345",e938eb25:"66546",f32d8490:"66880","6df78374":"67098","7196ee6c":"67112","137314dd":"67328","18f77871":"67365","6279c8a9":"67374",df7ec86c:"67746","8894256f":"67813",bcd02ebb:"67821","0f9cda3e":"67861","73ce7b01":"68005","7622c6de":"68207","363ba2d8":"68253","3d3a07f6":"68349",f8c92f63:"68503","4090f62b":"68809",eaafcd74:"68970","9ad8637e":"69043",c80ee60a:"69125","30b61715":"69184","8000380e":"69572","7e31db45":"69753",e23eefc0:"69905","41abf40a":"70022",b9535f14:"70147","39fee459":"70332","3b768736":"70509",b50c9021:"70633",e62aa786:"70670",c7399101:"70743","22bdf908":"70838",e93ff9aa:"71347","43cca846":"71568","397d4a7e":"71600","0328b0c9":"71723",ce32ce4d:"71871","2a3724f5":"71910","57494db5":"72069",a5c74766:"72145","9dba6800":"72379","540cb455":"72809",bb0e99df:"72841","5bf9b44a":"72978","04849bf5":"73091","94fe2afe":"73375","3c6391c1":"73464",bdb43652:"73695","9b6eea2c":"73894","94b87f57":"73905","4294ceba":"73918","84cf2087":"74190","48db5030":"74298","53d82fc0":"74428",b25d4024:"74531","0ed89c29":"74971",cf69f832:"75063","466daf09":"75066","77de130e":"75288","4e6cf383":"75474","30fdf4bf":"75600","0667cc8f":"75791",b180b1b1:"76152","94a29094":"76255","418c923e":"76428",d67ae496:"76541","7a65c859":"76549","11b4dd89":"77184",eb746456:"77535","97d979ce":"77665","18a382cc":"77811",ea313555:"77937","6bc64de5":"77944","3af651bf":"77999","2b20c80a":"78023","9218c1fd":"78315","5f10f6e3":"78340","0abbbb35":"78541","1fa35ec3":"78638",f46c4408:"78776",e77a5489:"79014","904cfab0":"79046","722ec584":"79054",b27348e5:"79239","378b1b2a":"79315","6249c7de":"79376","1db45fbc":"79475","7c767e9e":"79480","77622da5":"79923","8c139ad0":"80032","935f2afb":"80053","500ab5e8":"80103",a7c6c228:"80369","17c91901":"80536",df36d98d:"80567",b85fa405:"80808",d312cf7c:"81030","6c43de6e":"81135","476a319a":"81188",df330cef:"81447","563d7403":"81451",bffae127:"81500",f1e3befe:"81747",c8450cf2:"81981","555d583b":"82294","16127d6f":"82381","71c1d7a6":"82672",d5e6c777:"82708","471f7fbd":"82718",aea5d0af:"82803","12f49e0c":"82921",da6ad706:"83100","67009ff2":"83154","9622a62d":"83302","9f602629":"83398",d8f590ab:"83416","0d16b667":"83616",ef308d07:"83701","8c02dfd8":"83771","39c791a9":"83773","1dc390ba":"84052","38f61187":"84099","8dca2180":"84249","121b1090":"84386","2e4eadd3":"84840",b4eef555:"84857","2e8d4eda":"84878",c75d7ff6:"84959",d94bb6b6:"84987","730110a3":"85056",c0e80954:"85188","06848362":"85313",e593aec6:"85534","87b2412c":"85621","6dd1645f":"85660",bf0b75c4:"85836","6b3775fc":"85897",b700f6c8:"85953","9267eb77":"86139",c4cf1261:"86390",f2a10594:"86451",cb4175f3:"86529","87a13df2":"87173","393be207":"87414",d46f8e51:"87493","40230f21":"87655","6dde3b76":"87658","750960ca":"87677","4c4c3de8":"87824","5daee80f":"88042","8204d27d":"88258","3c8da607":"88831","856bceac":"89047",db4f0c5e:"89083",faee50e1:"89167","3f0d1ba4":"89415",b7c7e74a:"89776",c1d23c47:"89786","75a6ad06":"89912",b82b3205:"89964",e0751957:"90357","76e9b4e1":"90951","0248575c":"91538","5a7e7a34":"91569",ec202e26:"91759","9a072ddf":"92097","726fea1f":"92416","0c337ca4":"92560","5be4f4f7":"93006","73bfea73":"93056","812cb8ed":"93065",eb2927ba:"93348","007a6c32":"93387","49dbb45e":"93418","4a6f24a9":"93507","510addcb":"93543",d9ffe17e:"94089","4b3e38af":"94194",d6b0fe44:"94201","189eacae":"94215",d108a77f:"94276",d0816b53:"94319",fd03cc72:"94506","29f28a73":"94907",f8dc48d9:"95190","994f6abf":"95496","6f9bf5a7":"95557",caaad1b0:"95662",f4bc196f:"95690","710d4e4e":"95974","6ab4df05":"96247","8aadacf1":"96276","3aecebcc":"96361","120d9fdd":"96551","68f43c04":"96826","03e0b503":"97170",c8a855a5:"97421","4a3e680b":"97482",d63a00cf:"97500","51c3befa":"97719",e9d56634:"97879","954fe569":"97900","1a4e3797":"97920",ffb2e417:"98016",acc38ec3:"98105","4b25ddc7":"98220",a61cb094:"98591",d0931cd6:"98604","68e9a632":"98630","67044a7a":"98692","0d6f57e0":"98792","65e0cd55":"98948","4ade5613":"98960","02574e0f":"99070",b5511831:"99438",a6f4eced:"99533","595b2ce9":"99822",f56b8973:"99889"}[e]||e,t.p+t.u(e)},(()=>{var e={51303:0,40532:0};t.f.j=(b,a)=>{var f=t.o(e,b)?e[b]:void 0;if(0!==f)if(f)a.push(f[2]);else if(/^(40532|51303)$/.test(b))e[b]=0;else{var d=new Promise(((a,d)=>f=e[b]=[a,d]));a.push(f[2]=d);var c=t.p+t.u(b),r=new Error;t.l(c,(a=>{if(t.o(e,b)&&(0!==(f=e[b])&&(e[b]=void 0),f)){var d=a&&("load"===a.type?"missing":a.type),c=a&&a.target&&a.target.src;r.message="Loading chunk "+b+" failed.\n("+d+": "+c+")",r.name="ChunkLoadError",r.type=d,r.request=c,f[1](r)}}),"chunk-"+b,b)}},t.O.j=b=>0===e[b];var b=(b,a)=>{var f,d,c=a[0],r=a[1],o=a[2],n=0;if(c.some((b=>0!==e[b]))){for(f in r)t.o(r,f)&&(t.m[f]=r[f]);if(o)var i=o(t)}for(b&&b(a);n{"use strict";var e,b,a,f,d,c={},r={};function t(e){var b=r[e];if(void 0!==b)return b.exports;var a=r[e]={id:e,loaded:!1,exports:{}};return c[e].call(a.exports,a,a.exports,t),a.loaded=!0,a.exports}t.m=c,e=[],t.O=(b,a,f,d)=>{if(!a){var c=1/0;for(i=0;i=d)&&Object.keys(t.O).every((e=>t.O[e](a[o])))?a.splice(o--,1):(r=!1,d0&&e[i-1][2]>d;i--)e[i]=e[i-1];e[i]=[a,f,d]},t.n=e=>{var b=e&&e.__esModule?()=>e.default:()=>e;return t.d(b,{a:b}),b},a=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,t.t=function(e,f){if(1&f&&(e=this(e)),8&f)return e;if("object"==typeof e&&e){if(4&f&&e.__esModule)return e;if(16&f&&"function"==typeof e.then)return e}var d=Object.create(null);t.r(d);var c={};b=b||[null,a({}),a([]),a(a)];for(var r=2&f&&e;"object"==typeof r&&!~b.indexOf(r);r=a(r))Object.getOwnPropertyNames(r).forEach((b=>c[b]=()=>e[b]));return c.default=()=>e,t.d(d,c),d},t.d=(e,b)=>{for(var a in b)t.o(b,a)&&!t.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:b[a]})},t.f={},t.e=e=>Promise.all(Object.keys(t.f).reduce(((b,a)=>(t.f[a](e,b),b)),[])),t.u=e=>"assets/js/"+({42:"2518c83b",520:"fb1a77b4",783:"84002310",1046:"ee503142",1269:"9e31950e",1286:"f5bce583",1669:"f58086e5",1739:"510acf22",1770:"e6847b95",1802:"96368f4f",1893:"4c5e977b",1972:"ed99de2c",2050:"f54e89d1",2112:"5e4fe134",2143:"64e17396",2375:"1c94925b",2449:"3e99551e",2528:"5b292b69",2666:"09c26509",2951:"9bb13d2e",3299:"7e3ea763",3300:"655c39d2",3507:"7190026f",3522:"abf6ee25",4147:"345d96d3",4159:"b9acd066",4193:"95ce3c59",4387:"78950515",4694:"98dc0d0e",4696:"9569bc2f",4993:"7cfe228b",5209:"bcd351e4",5295:"5bcf38c1",5665:"7bb9f034",5872:"587e3d47",5886:"31d96af4",6282:"cd8b4f9a",6473:"a83fc124",6576:"fc169afb",6597:"44177285",6620:"8399f467",6675:"036e14f3",6768:"4eb9b8ff",6874:"8b221193",6907:"0393be11",7267:"c9713a6d",7338:"833a1fde",7828:"f72af8b9",7841:"179c9190",7954:"b90c57a3",8025:"b42f8477",8179:"136658e4",8347:"8b988d57",8966:"16ef1cd9",9022:"29b0efd4",9113:"84ab2fd1",9300:"903944d2",9532:"68079445",9609:"8e84b0d9",9624:"3042b185",9800:"9ff509e1",9817:"14eb3368",10225:"883bb60a",10235:"a7d19085",10293:"fa570740",11005:"c127b609",11013:"e8acd80e",11053:"7205acf7",11119:"988d8e24",11265:"f6106990",11389:"a005ddbc",11396:"e3e28d8f",11792:"855341b1",11908:"f9fe6464",12319:"e6b47cdb",12333:"650716b7",12717:"0b0bc04d",12933:"b6036b82",13085:"1f391b9e",13364:"74e68634",13408:"fdf22a50",13467:"08cdb8be",13994:"b2ae77a0",14030:"c5d3bb95",14132:"b6eadb9e",14243:"0744e06b",14281:"30bb4662",14491:"1fefa037",14582:"fed448c0",14731:"64e1104a",14760:"4863838d",14796:"a41d5bc2",14945:"b9fef5ef",15068:"e4440f9d",15114:"ee7f03d8",15262:"664d32ba",15272:"bed401a1",15309:"57f8207f",15365:"b82d00b2",15408:"2435c844",15609:"060b1584",15903:"f4c85b32",16071:"094a53a9",16377:"07ffdee5",16401:"1a7a3335",16667:"f81ec24e",16677:"3d4af990",16720:"4ac45b89",16771:"028b7f22",16825:"5621bfd0",17210:"daa5df1a",17445:"1a299676",17638:"e165cecb",18085:"f56ba7e1",18104:"7ab943be",18287:"82405689",18772:"c83cf481",19063:"0004065d",19122:"c1adbe0b",19178:"3956460a",19270:"cba951d8",19389:"2a8d8e88",19715:"2cfd0fc8",19831:"4e7e2ca5",20048:"441ee7d2",20367:"05a3c259",20844:"4e1901bc",20926:"05bb3e6b",21004:"bc0c7228",21390:"a6905832",21493:"79022373",21945:"ccaa939a",22162:"31593e16",22399:"0d34b62b",22477:"2b25df32",22982:"f041af6f",23003:"34fadc99",23022:"e0a5c1d2",23389:"9041aea1",23747:"bedf2929",23750:"c77ce8fa",24069:"41ce3377",24114:"170bc0f5",24180:"83b28724",24215:"13696f7b",24804:"440f78e7",24851:"a592f1e4",24989:"0f2dc4ca",25329:"4eca193c",25374:"980085d9",25785:"20f55e05",25968:"156751cf",25969:"07ca0209",26192:"e3bf20e0",26295:"67f94a41",26467:"302d24dc",26648:"0157939d",26668:"b9fa1d17",26912:"197a4930",27044:"89e5bdec",27133:"92e99bf6",27188:"5036ec9d",27212:"e6cbd2ed",27238:"e298e99e",28135:"89179ad6",28155:"094ce30e",28364:"069e89fb",28460:"dd3ced3a",28492:"9931c5c6",28608:"0cadbdb9",28772:"d5f94c50",28781:"7e458d36",28801:"6dfc2f3d",28848:"99d44459",29010:"8c2621f5",29217:"547b19b8",29514:"1be78505",29538:"4c950052",29770:"06b60cb4",29976:"f512b2b1",30051:"6dd54b46",30499:"24774f91",30561:"bc670d5c",30601:"e5d84bc0",30701:"21fa7ce5",30797:"80238aff",30882:"aedc496a",31094:"8675103a",31218:"eeea228c",31404:"3e301362",32111:"74db685e",32252:"eef51a73",32490:"1eaa7a2a",32755:"7e04e77d",33201:"18d0ad0f",33240:"0ab53148",33312:"8cd2105d",33404:"afdda5b6",33410:"8ed5753e",33509:"786f71e5",33527:"a5e760bc",33659:"0e5cbc44",33869:"e457634d",33949:"1e577d6c",34288:"af1ac92b",34548:"1a8c488b",35167:"6c74a4d7",35416:"cc68b255",35708:"41eb0037",35832:"b745f339",35898:"eb050011",35943:"bc53881b",36106:"c2ebbb3e",36137:"fcda79ce",36553:"18a5e8d6",36554:"9d979a6d",36648:"a6b8b35b",37018:"01464744",37034:"14f73ed3",37146:"86320adf",37193:"49541ebb",37222:"d1498869",37486:"dcc6b54d",37487:"a9bf2227",37570:"ab214d24",37896:"83cc66ac",38101:"1a004de9",38270:"5393ce94",38460:"c2d32f88",38818:"7e40020f",38890:"c084c2e9",38959:"1eb543d3",39127:"a230a772",39580:"75ecb4f9",39626:"fd867f7c",39675:"62547fbf",39796:"3e9399ec",40073:"359a0a8d",40081:"39f63e6a",40114:"8740ec05",40211:"eb907bb2",40219:"49e3720f",40542:"41790d5d",40614:"716600a7",40683:"0abae2e0",40701:"1ce0a301",40830:"c343ef35",40916:"e4459066",41003:"d0d62bb5",41276:"a6c72656",41804:"ee640683",41847:"82a30884",41877:"717e7ee6",42069:"9a6be05d",42885:"acdbee8e",43726:"6b85e2ea",44120:"a61ed651",44209:"278665dc",44850:"1bde5858",44880:"e7d2e6f0",44916:"95d5a544",45111:"cb819e9b",45167:"da88d543",45208:"034a556b",45293:"2f7c7419",45919:"8070429a",46039:"778f38dc",46215:"784585a8",46566:"763e4dec",46976:"70b01d77",47137:"47f09a6b",47328:"6daf901a",47563:"146da2b4",47615:"84ebbbbf",47769:"196fab6d",47969:"7f281903",48026:"a120aaca",48081:"5dce62fd",48124:"553f321c",48169:"e4492fa7",48244:"41f003c0",48890:"d5603669",48954:"b0bdb7f3",49486:"e72cf26a",49717:"a5962d55",49755:"c123803f",50030:"fd3dbbb4",50067:"246367e0",50430:"867911a0",50730:"4b1cba20",50893:"965dbb95",50932:"485af29a",51106:"dd813bf5",51410:"bd1a9377",51523:"a3761f7f",52474:"4507e508",52486:"de127d6b",52574:"e2668db3",52603:"a4b6f3a5",52654:"f024ddd5",52831:"5ec88f12",53111:"203d8c37",53309:"63ee150d",53408:"4694df8d",53482:"a718913e",53501:"7795e3fe",53559:"ebe9f683",53630:"dd02e78e",53778:"2fa02bf3",54013:"2f5fda3e",54053:"24e3585b",54235:"695f8b9b",54601:"c552c222",54636:"760e3208",54801:"3ec68450",54820:"05a18904",55038:"100f3054",55229:"2fcfad90",55328:"74c40fe4",55381:"cfc9c16e",55480:"006095b2",56025:"c3aed80f",56319:"879063fc",56370:"36f93d19",56382:"9ffa1a6c",56886:"4b7a6889",56955:"51ca6efd",56963:"1b80e345",56979:"d005934a",57060:"4be15b13",57067:"eece046c",57152:"e09bff2e",57251:"eb1718b4",57287:"bde9fb45",57480:"c86abbf7",57756:"6ab4408e",57979:"c5059afe",58e3:"fbf4432e",58188:"e73e328f",58235:"3bdeaa89",58353:"162f137e",58634:"e6a2b2bf",58663:"c7dcc258",59082:"6a9a7317",59131:"3b0223df",59135:"e27b8251",59319:"35379327",59469:"68648e27",59485:"edfdb191",59607:"25f376d4",59728:"aa5bd2a7",59738:"d68e7e95",59856:"e5c88a3e",59865:"e8ee0390",59910:"16142a34",59953:"2041170f",60298:"d4e7ac8a",60310:"5913a508",60377:"2d4599ae",60679:"353f52a3",61166:"2fcd316c",61304:"8d5fe6f9",61528:"2b6f680f",62062:"988ba51e",62353:"35d50d77",62746:"00468222",62860:"3d49fc0e",63447:"1c5b9066",63497:"b8541bfd",63851:"51b69e86",64166:"c54a5582",64195:"c4f5d8e4",64209:"d7a48e98",64214:"575f1b1b",64280:"95a35da8",64364:"4bec54d5",64497:"099f8a1f",64549:"788d9fe0",64557:"63c7b841",64814:"8ade285d",64925:"7ee339c8",65149:"53e78238",65154:"af35203c",65349:"796ce4fb",65368:"cc468388",65573:"291c8f9c",65687:"2f2f8f8f",65957:"e4627c87",66068:"e8bf0c3e",66345:"42a8d727",66546:"e938eb25",66880:"f32d8490",67098:"6df78374",67112:"7196ee6c",67328:"137314dd",67365:"18f77871",67374:"6279c8a9",67746:"df7ec86c",67813:"8894256f",67821:"bcd02ebb",67861:"0f9cda3e",68005:"73ce7b01",68207:"7622c6de",68253:"363ba2d8",68349:"3d3a07f6",68503:"f8c92f63",68809:"4090f62b",68970:"eaafcd74",69043:"9ad8637e",69125:"c80ee60a",69184:"30b61715",69572:"8000380e",69753:"7e31db45",69905:"e23eefc0",70022:"41abf40a",70147:"b9535f14",70332:"39fee459",70509:"3b768736",70633:"b50c9021",70670:"e62aa786",70743:"c7399101",70838:"22bdf908",71347:"e93ff9aa",71568:"43cca846",71600:"397d4a7e",71723:"0328b0c9",71871:"ce32ce4d",71910:"2a3724f5",72069:"57494db5",72145:"a5c74766",72379:"9dba6800",72809:"540cb455",72841:"bb0e99df",72978:"5bf9b44a",73091:"04849bf5",73375:"94fe2afe",73464:"3c6391c1",73695:"bdb43652",73894:"9b6eea2c",73905:"94b87f57",73918:"4294ceba",74190:"84cf2087",74298:"48db5030",74428:"53d82fc0",74531:"b25d4024",74971:"0ed89c29",75063:"cf69f832",75066:"466daf09",75288:"77de130e",75474:"4e6cf383",75600:"30fdf4bf",75791:"0667cc8f",76152:"b180b1b1",76255:"94a29094",76428:"418c923e",76434:"40878283",76541:"d67ae496",76549:"7a65c859",77184:"11b4dd89",77535:"eb746456",77665:"97d979ce",77811:"18a382cc",77937:"ea313555",77944:"6bc64de5",77999:"3af651bf",78023:"2b20c80a",78315:"9218c1fd",78340:"5f10f6e3",78541:"0abbbb35",78638:"1fa35ec3",78776:"f46c4408",79014:"e77a5489",79046:"904cfab0",79054:"722ec584",79239:"b27348e5",79315:"378b1b2a",79376:"6249c7de",79475:"1db45fbc",79480:"7c767e9e",79923:"77622da5",80032:"8c139ad0",80053:"935f2afb",80103:"500ab5e8",80369:"a7c6c228",80536:"17c91901",80567:"df36d98d",80808:"b85fa405",81030:"d312cf7c",81135:"6c43de6e",81188:"476a319a",81447:"df330cef",81451:"563d7403",81500:"bffae127",81747:"f1e3befe",81981:"c8450cf2",82294:"555d583b",82381:"16127d6f",82672:"71c1d7a6",82708:"d5e6c777",82718:"471f7fbd",82803:"aea5d0af",82921:"12f49e0c",83100:"da6ad706",83154:"67009ff2",83302:"9622a62d",83398:"9f602629",83416:"d8f590ab",83616:"0d16b667",83701:"ef308d07",83771:"8c02dfd8",83773:"39c791a9",84052:"1dc390ba",84099:"38f61187",84249:"8dca2180",84386:"121b1090",84840:"2e4eadd3",84857:"b4eef555",84878:"2e8d4eda",84959:"c75d7ff6",84987:"d94bb6b6",85056:"730110a3",85188:"c0e80954",85313:"06848362",85534:"e593aec6",85621:"87b2412c",85660:"6dd1645f",85836:"bf0b75c4",85897:"6b3775fc",85953:"b700f6c8",86072:"26183636",86139:"9267eb77",86390:"c4cf1261",86451:"f2a10594",86529:"cb4175f3",87173:"87a13df2",87414:"393be207",87493:"d46f8e51",87655:"40230f21",87658:"6dde3b76",87677:"750960ca",87824:"4c4c3de8",88042:"5daee80f",88258:"8204d27d",88831:"3c8da607",88935:"99494472",89047:"856bceac",89083:"db4f0c5e",89167:"faee50e1",89415:"3f0d1ba4",89776:"b7c7e74a",89786:"c1d23c47",89912:"75a6ad06",89964:"b82b3205",90357:"e0751957",90951:"76e9b4e1",91538:"0248575c",91569:"5a7e7a34",91759:"ec202e26",92097:"9a072ddf",92416:"726fea1f",92560:"0c337ca4",93006:"5be4f4f7",93056:"73bfea73",93065:"812cb8ed",93348:"eb2927ba",93387:"007a6c32",93418:"49dbb45e",93507:"4a6f24a9",93543:"510addcb",94089:"d9ffe17e",94194:"4b3e38af",94201:"d6b0fe44",94215:"189eacae",94276:"d108a77f",94319:"d0816b53",94506:"fd03cc72",94907:"29f28a73",95190:"f8dc48d9",95496:"994f6abf",95557:"6f9bf5a7",95662:"caaad1b0",95690:"f4bc196f",95974:"710d4e4e",96247:"6ab4df05",96276:"8aadacf1",96361:"3aecebcc",96551:"120d9fdd",96826:"68f43c04",97170:"03e0b503",97421:"c8a855a5",97482:"4a3e680b",97500:"d63a00cf",97719:"51c3befa",97879:"e9d56634",97900:"954fe569",97920:"1a4e3797",98016:"ffb2e417",98105:"acc38ec3",98220:"4b25ddc7",98591:"a61cb094",98604:"d0931cd6",98630:"68e9a632",98692:"67044a7a",98792:"0d6f57e0",98948:"65e0cd55",98960:"4ade5613",99070:"02574e0f",99438:"b5511831",99533:"a6f4eced",99822:"595b2ce9",99889:"f56b8973"}[e]||e)+"."+{42:"c43f8910",520:"5c2a267b",783:"d4f745cf",1046:"f421e3c0",1269:"7bc4f975",1286:"28d0b3fc",1669:"4752392e",1739:"3d437425",1770:"d15d6c60",1802:"043f0de8",1893:"4a98b5fe",1972:"7594392d",2050:"823155de",2112:"82477c40",2143:"78f20385",2375:"34eb2114",2449:"c8c4a269",2528:"17f369fc",2666:"1a51e707",2951:"21706190",3299:"c104220f",3300:"2dc42cf3",3507:"019a9fa5",3522:"25589105",4147:"9a01466a",4159:"6d060ce6",4193:"d8c5fb64",4387:"c65dc917",4694:"e4aa9c43",4696:"261d15e2",4972:"c1e0c51c",4993:"acc5f429",5209:"be5a092c",5295:"8ff802c6",5665:"c17ab8c9",5872:"20b27d16",5886:"d9475a2e",6282:"de39aa72",6338:"359271aa",6473:"7ab3f71d",6576:"492e2951",6597:"73fc4cdd",6620:"2944efd1",6675:"d953ea15",6768:"e650080a",6874:"26bd809c",6907:"6cefc11d",7267:"b891b533",7338:"9fcd22c8",7828:"7614eb22",7841:"eaacaa11",7954:"2b01d23c",8025:"739425f2",8179:"d929c0f4",8347:"a04343be",8966:"336bd1a1",9022:"9e4d05b5",9113:"ecabc4d6",9300:"261c6639",9532:"5ec3ca5b",9609:"288677fa",9624:"cab240a8",9799:"cdb5b12a",9800:"8135d36c",9817:"f9d79ca6",10225:"3d3596d5",10235:"7e46f062",10293:"dacaf0b5",11005:"58d5b73e",11013:"aece890c",11053:"2c6dd170",11119:"a7f302b9",11265:"0c81fd6e",11389:"21b97b61",11396:"e0a86f74",11792:"4655b6c9",11908:"9641f6e6",12319:"25bcf0cf",12333:"893aa641",12717:"c448b7f5",12933:"f5ea1ee2",13085:"74c4de50",13364:"b9101d9f",13408:"e6044319",13467:"54cc787a",13994:"f6412254",14030:"57c1e1f4",14132:"618c5934",14243:"561b594f",14281:"cf8be476",14491:"23ccaa23",14582:"f07ccdf2",14731:"6e6937e7",14760:"c4ab7b63",14796:"67b6859e",14945:"ceaa448c",15068:"a911fd6e",15114:"a0cce757",15262:"18d69e6c",15272:"c902eb2f",15309:"8230c2ac",15365:"4759fbe7",15408:"5835c415",15609:"536132e5",15903:"649cb0cf",16071:"2dc6ee69",16377:"bcac3475",16401:"9c798132",16667:"4487755d",16677:"6dfb38be",16720:"2d17fe6d",16771:"ea90e09c",16825:"9319d7a3",17210:"045fe953",17445:"18a650a4",17638:"ca541869",18085:"554b52c4",18104:"80a63f08",18287:"e6a54e4f",18772:"f22facf0",18894:"2da9821d",19063:"d6dbfb6c",19122:"9af15b7c",19178:"96987a51",19270:"25a94c9f",19389:"feb155f7",19715:"ee5f3704",19831:"5f90158e",20048:"c475b360",20367:"0bb13b15",20844:"0c3e4097",20926:"53588a4c",21004:"036b2b1f",21390:"93917d02",21493:"c26a7538",21945:"72e3587f",22162:"5ebbe176",22399:"80f66527",22477:"c8fd2aa5",22761:"365a347a",22982:"fdca227d",23003:"a77f6c46",23022:"0bd66a28",23389:"8c8835a8",23747:"d3c92649",23750:"6130cc67",24069:"17aacc5f",24114:"54ee1cf0",24180:"baa2cde2",24215:"85fbc604",24804:"e3b992a0",24851:"c8502192",24989:"6dac20a5",25329:"0936a0bf",25374:"6d32276c",25785:"97d36de8",25968:"fab4e438",25969:"c51b573e",26192:"4212dfaf",26295:"4f220773",26467:"b303e60b",26648:"acbaf873",26668:"2e7c5e86",26912:"b3a88e29",27044:"0ff557a9",27133:"97370dd1",27188:"3624fcda",27212:"d30661f5",27238:"9afcec49",28135:"5b1476ac",28155:"317306dd",28364:"7f11b9bc",28460:"6e8b9fee",28492:"c9059ac6",28608:"315c7081",28772:"817ac08d",28781:"22102bff",28801:"54787bb9",28848:"761000fa",29010:"10df03ac",29217:"38f19102",29514:"e4bcc747",29538:"0518905a",29770:"17b7b24c",29976:"63adaa26",30051:"b8aa46bc",30499:"339d001a",30561:"1fc90304",30601:"2a5579b9",30701:"8b5b0eb7",30797:"85de9f7a",30882:"3c5ac118",31094:"f685f08e",31218:"d8725830",31404:"008d83aa",32111:"e4935bce",32252:"816c7d32",32490:"d0adf848",32755:"eead5037",33201:"446a5f5c",33240:"726c4a87",33312:"9907b91c",33404:"0efbfadd",33410:"76ac8dd8",33509:"f924244a",33527:"c0ee1aeb",33659:"f6432c75",33869:"0034ae7a",33949:"2d9b37a7",34288:"89e2c37b",34548:"510a448d",35167:"b49fab92",35416:"5322fc44",35708:"0fe8f81f",35832:"89b33974",35898:"9c2b236b",35943:"0cbd318b",36106:"035575ac",36137:"9bc3d126",36553:"0fc8fe84",36554:"f0d4c23c",36648:"e1106aa5",37018:"c6e5914d",37034:"75fec4c8",37146:"e6e9886a",37193:"40af0f54",37222:"b3275e97",37486:"c2082024",37487:"0b43fb28",37570:"44b39cf5",37896:"aa3c7b74",38101:"4d059d0a",38270:"c1ef53c6",38460:"e88eec46",38818:"2035cc81",38890:"afa6ad85",38959:"12c42e0b",39127:"8b4cf1c4",39580:"c324ee5d",39626:"db9dd9ea",39675:"21645207",39796:"0f844535",40073:"1c4aa29e",40081:"eff10365",40114:"354298b2",40211:"3df45470",40219:"7603b1f6",40542:"627141b9",40614:"1611c893",40683:"4c6d71f0",40701:"d5e8f1c1",40830:"53ae3566",40916:"729db7d8",41003:"36e31dce",41276:"8dadc84f",41804:"d1aca82e",41847:"e8cd87e2",41877:"1814cb04",42069:"069e635b",42885:"bfa95af9",43726:"990e8b22",44120:"8f4578a0",44209:"28c163b6",44850:"c3eecc99",44880:"8942da16",44916:"1bc7c335",45111:"0a16adcc",45167:"3abc174e",45208:"0e603945",45293:"c5e7682e",45919:"0d56535a",46039:"de587cdd",46215:"08417467",46566:"a5077acb",46945:"11021670",46976:"5e04970b",47137:"7788896d",47328:"6bf4dc53",47563:"dddd758f",47615:"835b1cc6",47769:"8ef7c2e0",47969:"9ef94159",48026:"8cad975d",48081:"23fd8a90",48124:"636e6e24",48169:"d5d88ba9",48244:"f9a2d353",48890:"32c5ddf3",48954:"cdfc2c65",49486:"b4557cfa",49717:"1d6ff5e3",49755:"a388e846",50030:"6bec3ed2",50067:"0bdf2d2a",50430:"7910e348",50730:"c8c75462",50893:"36df98f6",50932:"5af46298",51106:"98875bed",51410:"c9fc3c07",51523:"8598a7f5",52474:"de8bba8d",52486:"635a774e",52574:"472cf42f",52603:"9d89ea47",52654:"92b816af",52831:"c3227a77",53111:"0d6852e5",53309:"8ae306cc",53408:"c8dc96a4",53482:"df103e38",53501:"7cf5c335",53559:"bd21e86d",53630:"c92dce0e",53778:"367f311a",54013:"961b0355",54053:"9e602739",54235:"6a08614d",54601:"c7802446",54636:"56e055f1",54801:"433ccde3",54820:"d82b721a",55038:"0efb12f2",55229:"ebcdbf21",55328:"bc82ad85",55381:"0f7ce3c0",55480:"d528d018",56025:"16398596",56319:"74302ebf",56370:"b8478850",56382:"3def563d",56886:"ca6f13c8",56955:"78038386",56963:"0c50b8a7",56979:"0ba2abc6",57060:"b1c30f6b",57067:"94292e0b",57152:"af1ad35a",57251:"ed7488a0",57287:"e26ec7d5",57480:"0866edfb",57756:"f5aeb441",57979:"1ff7221e",58e3:"5ec47679",58188:"1fe0b3e6",58235:"ca76d8fc",58353:"622fffee",58634:"12458c96",58663:"57e0701e",59082:"6c8b93f7",59131:"441f24ce",59135:"6f73f94f",59319:"cd719bc0",59469:"6976aee8",59485:"bd33ab11",59607:"1e04d082",59728:"a4c378d0",59738:"f2030e38",59856:"0b84f70e",59865:"deb8694a",59910:"95e1e5e2",59953:"4166ce32",60298:"5f669764",60310:"a77f85b7",60377:"0c71fdb8",60679:"b9b7c276",61166:"61a621a5",61304:"009bd8ba",61528:"de68d6ec",62062:"d3b53104",62353:"3b2b9e41",62746:"c9463b36",62860:"8684fd86",63447:"3d31efcb",63497:"f4d660ad",63851:"c999ace8",64166:"b71eccd0",64195:"07350901",64209:"f5ad69ae",64214:"2cc8e777",64280:"5efc0cff",64364:"5316964a",64497:"2395298f",64549:"1a1add38",64557:"007ee6f1",64814:"67f95d80",64925:"2f99fa91",65149:"5abf9135",65154:"fb3eceb4",65349:"7ee9aa91",65368:"5b1c1d58",65573:"2c6331be",65687:"c6809b64",65957:"95afcdf9",66068:"3b887511",66345:"8c235ba0",66546:"2106ffbc",66880:"fa4535e7",67098:"245147a0",67112:"ea592d9a",67328:"40b70453",67365:"ff7af498",67374:"a4a3557e",67746:"73579300",67813:"169c3ef2",67821:"f59a1771",67861:"feded733",68005:"c1051622",68207:"2543c5de",68253:"87f711c9",68349:"3df1974e",68503:"89385e31",68724:"bd00f8e9",68809:"ae6235ee",68970:"6227e9a9",69043:"b88c085a",69125:"c6e399ca",69184:"e8a26324",69572:"0037e2de",69753:"8344f96a",69905:"5390d20c",70022:"b7c72e72",70147:"7e1836d5",70332:"e4214ba7",70509:"634f930a",70633:"2676ed95",70670:"4647b158",70743:"1bc17e63",70838:"8445a962",71347:"b8233b2a",71568:"6166d0da",71600:"387e240c",71723:"aa61b8c8",71814:"56dd82a2",71871:"1654e72b",71910:"b220fcde",72069:"a92d7715",72145:"64ff0e7f",72379:"8cb7d62c",72809:"cf9cae29",72841:"8ecfd9ac",72978:"787c9bcd",73091:"2234b421",73375:"177280a8",73464:"5f9bce6c",73695:"e2b4cac6",73894:"713fdd3d",73905:"8bd67e5c",73918:"a40b3907",74190:"76cd087b",74298:"d717c136",74428:"d722afe9",74531:"67a3f108",74971:"e4dabd31",75063:"80ef3c52",75066:"54042ed9",75288:"f71e9af9",75474:"a3c68a2c",75600:"fe5ce8c7",75791:"22c15814",76152:"d2f3715c",76255:"15271f83",76428:"a691b41f",76434:"5d75b4fd",76541:"bf22c3cc",76549:"54c764b8",76780:"a2521cf6",77184:"5344e158",77535:"668fadda",77665:"0bb895e1",77811:"806940f9",77937:"264a7976",77944:"eb111f96",77999:"074e4008",78023:"8f7b2b62",78315:"fddd6e0b",78340:"fd8f0a19",78541:"1875c215",78638:"cbff6869",78776:"0c62f023",79014:"6378fbc5",79046:"438a917c",79054:"bb10d360",79239:"c5e9eef2",79315:"c9864331",79376:"772aa1f2",79475:"4341bb63",79480:"1cabc8e8",79923:"24e9dfb4",80032:"b63ca947",80053:"f69e0d20",80103:"adb45701",80369:"823951a8",80536:"1fc24eda",80567:"6a9d0b26",80808:"d89117d5",81030:"f8ac3f2c",81135:"4c893d97",81188:"23452a7d",81447:"6435e97d",81451:"df661c64",81500:"86e20713",81747:"712b5a86",81981:"aca1e4a5",82294:"fa192674",82381:"faeefc76",82672:"b1911849",82708:"cab3b61f",82718:"52d0bf25",82803:"792692fe",82921:"917648f0",83100:"ff43253e",83154:"b0af7501",83302:"05d57b7e",83398:"61763665",83416:"7b819fe1",83616:"8ebf4756",83701:"760e705a",83771:"076b6e5d",83773:"2909b551",84052:"78b5196f",84099:"3e664253",84249:"89ad564d",84386:"3cdac849",84840:"c9ae913e",84857:"a2328bb0",84878:"5edf6cbd",84959:"77f53787",84987:"3a555e6d",85056:"e929ee43",85188:"103821dc",85313:"49c56bb7",85534:"9bf0046e",85621:"b14f6a91",85660:"d41a7652",85836:"e76ef639",85897:"31ab244d",85953:"474bfc80",86072:"b2386542",86139:"6b79a1a5",86390:"98cacb7c",86451:"bcb991c4",86529:"ec82adac",87173:"e22cd17a",87414:"e74de51a",87493:"0072bd90",87655:"664033ae",87658:"0b016f35",87677:"baaf40c3",87824:"7eddecc7",88042:"70c3c1f9",88258:"8ed27800",88831:"e3546d5f",88935:"73e4d93a",89047:"15309827",89083:"591c8943",89167:"b785a832",89415:"33ee9ac5",89776:"04406d29",89786:"975a5550",89912:"45d78fc7",89964:"1950abd7",90357:"35110dae",90951:"e5e599eb",91538:"5bee4d8c",91569:"ce93dfb7",91759:"63117712",92097:"85d2fd38",92416:"07ce2e4c",92560:"9b3787fc",93006:"2d30d12a",93056:"b5c58925",93065:"b033e6cb",93348:"27f4c48c",93387:"64b4440b",93418:"3ee42084",93507:"a657a544",93543:"cf45b1b9",94089:"adfc8b09",94194:"e23dd625",94201:"15a7b665",94215:"aacdca39",94276:"6afc6a42",94319:"2bf1ddcc",94506:"3a8a0c30",94907:"29225ebf",95190:"813a5c8a",95496:"603eb1ee",95557:"ff4a681a",95662:"848f1286",95690:"ebf24935",95974:"46a39b17",96247:"ae1d6419",96276:"74c119ca",96361:"e24f4c03",96551:"807583b8",96826:"dbd45390",97170:"30294cd2",97421:"2e7bbb6e",97482:"beb13a9b",97500:"7e68e3a7",97719:"5defa7bb",97879:"03182d91",97900:"a14e34b2",97920:"d5457aa2",98016:"d08720e9",98105:"48938e56",98220:"933b63ce",98591:"98be4f3a",98604:"5372b027",98630:"7607f8c9",98692:"f146280e",98792:"9f8cc5eb",98948:"75dc840b",98960:"79202773",99070:"6d90e6e1",99438:"6c99546d",99533:"d4e17677",99822:"5b9bd95e",99889:"d667b6bf"}[e]+".js",t.miniCssF=e=>{},t.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),t.o=(e,b)=>Object.prototype.hasOwnProperty.call(e,b),f={},d="docusaurus-docs:",t.l=(e,b,a,c)=>{if(f[e])f[e].push(b);else{var r,o;if(void 0!==a)for(var n=document.getElementsByTagName("script"),i=0;i{r.onerror=r.onload=null,clearTimeout(l);var d=f[e];if(delete f[e],r.parentNode&&r.parentNode.removeChild(r),d&&d.forEach((e=>e(a))),b)return b(a)},l=setTimeout(s.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=s.bind(null,r.onerror),r.onload=s.bind(null,r.onload),o&&document.head.appendChild(r)}},t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),t.p="/docs/",t.gca=function(e){return e={26183636:"86072",35379327:"59319",40878283:"76434",44177285:"6597",68079445:"9532",78950515:"4387",79022373:"21493",82405689:"18287",84002310:"783",99494472:"88935","2518c83b":"42",fb1a77b4:"520",ee503142:"1046","9e31950e":"1269",f5bce583:"1286",f58086e5:"1669","510acf22":"1739",e6847b95:"1770","96368f4f":"1802","4c5e977b":"1893",ed99de2c:"1972",f54e89d1:"2050","5e4fe134":"2112","64e17396":"2143","1c94925b":"2375","3e99551e":"2449","5b292b69":"2528","09c26509":"2666","9bb13d2e":"2951","7e3ea763":"3299","655c39d2":"3300","7190026f":"3507",abf6ee25:"3522","345d96d3":"4147",b9acd066:"4159","95ce3c59":"4193","98dc0d0e":"4694","9569bc2f":"4696","7cfe228b":"4993",bcd351e4:"5209","5bcf38c1":"5295","7bb9f034":"5665","587e3d47":"5872","31d96af4":"5886",cd8b4f9a:"6282",a83fc124:"6473",fc169afb:"6576","8399f467":"6620","036e14f3":"6675","4eb9b8ff":"6768","8b221193":"6874","0393be11":"6907",c9713a6d:"7267","833a1fde":"7338",f72af8b9:"7828","179c9190":"7841",b90c57a3:"7954",b42f8477:"8025","136658e4":"8179","8b988d57":"8347","16ef1cd9":"8966","29b0efd4":"9022","84ab2fd1":"9113","903944d2":"9300","8e84b0d9":"9609","3042b185":"9624","9ff509e1":"9800","14eb3368":"9817","883bb60a":"10225",a7d19085:"10235",fa570740:"10293",c127b609:"11005",e8acd80e:"11013","7205acf7":"11053","988d8e24":"11119",f6106990:"11265",a005ddbc:"11389",e3e28d8f:"11396","855341b1":"11792",f9fe6464:"11908",e6b47cdb:"12319","650716b7":"12333","0b0bc04d":"12717",b6036b82:"12933","1f391b9e":"13085","74e68634":"13364",fdf22a50:"13408","08cdb8be":"13467",b2ae77a0:"13994",c5d3bb95:"14030",b6eadb9e:"14132","0744e06b":"14243","30bb4662":"14281","1fefa037":"14491",fed448c0:"14582","64e1104a":"14731","4863838d":"14760",a41d5bc2:"14796",b9fef5ef:"14945",e4440f9d:"15068",ee7f03d8:"15114","664d32ba":"15262",bed401a1:"15272","57f8207f":"15309",b82d00b2:"15365","2435c844":"15408","060b1584":"15609",f4c85b32:"15903","094a53a9":"16071","07ffdee5":"16377","1a7a3335":"16401",f81ec24e:"16667","3d4af990":"16677","4ac45b89":"16720","028b7f22":"16771","5621bfd0":"16825",daa5df1a:"17210","1a299676":"17445",e165cecb:"17638",f56ba7e1:"18085","7ab943be":"18104",c83cf481:"18772","0004065d":"19063",c1adbe0b:"19122","3956460a":"19178",cba951d8:"19270","2a8d8e88":"19389","2cfd0fc8":"19715","4e7e2ca5":"19831","441ee7d2":"20048","05a3c259":"20367","4e1901bc":"20844","05bb3e6b":"20926",bc0c7228:"21004",a6905832:"21390",ccaa939a:"21945","31593e16":"22162","0d34b62b":"22399","2b25df32":"22477",f041af6f:"22982","34fadc99":"23003",e0a5c1d2:"23022","9041aea1":"23389",bedf2929:"23747",c77ce8fa:"23750","41ce3377":"24069","170bc0f5":"24114","83b28724":"24180","13696f7b":"24215","440f78e7":"24804",a592f1e4:"24851","0f2dc4ca":"24989","4eca193c":"25329","980085d9":"25374","20f55e05":"25785","156751cf":"25968","07ca0209":"25969",e3bf20e0:"26192","67f94a41":"26295","302d24dc":"26467","0157939d":"26648",b9fa1d17:"26668","197a4930":"26912","89e5bdec":"27044","92e99bf6":"27133","5036ec9d":"27188",e6cbd2ed:"27212",e298e99e:"27238","89179ad6":"28135","094ce30e":"28155","069e89fb":"28364",dd3ced3a:"28460","9931c5c6":"28492","0cadbdb9":"28608",d5f94c50:"28772","7e458d36":"28781","6dfc2f3d":"28801","99d44459":"28848","8c2621f5":"29010","547b19b8":"29217","1be78505":"29514","4c950052":"29538","06b60cb4":"29770",f512b2b1:"29976","6dd54b46":"30051","24774f91":"30499",bc670d5c:"30561",e5d84bc0:"30601","21fa7ce5":"30701","80238aff":"30797",aedc496a:"30882","8675103a":"31094",eeea228c:"31218","3e301362":"31404","74db685e":"32111",eef51a73:"32252","1eaa7a2a":"32490","7e04e77d":"32755","18d0ad0f":"33201","0ab53148":"33240","8cd2105d":"33312",afdda5b6:"33404","8ed5753e":"33410","786f71e5":"33509",a5e760bc:"33527","0e5cbc44":"33659",e457634d:"33869","1e577d6c":"33949",af1ac92b:"34288","1a8c488b":"34548","6c74a4d7":"35167",cc68b255:"35416","41eb0037":"35708",b745f339:"35832",eb050011:"35898",bc53881b:"35943",c2ebbb3e:"36106",fcda79ce:"36137","18a5e8d6":"36553","9d979a6d":"36554",a6b8b35b:"36648","01464744":"37018","14f73ed3":"37034","86320adf":"37146","49541ebb":"37193",d1498869:"37222",dcc6b54d:"37486",a9bf2227:"37487",ab214d24:"37570","83cc66ac":"37896","1a004de9":"38101","5393ce94":"38270",c2d32f88:"38460","7e40020f":"38818",c084c2e9:"38890","1eb543d3":"38959",a230a772:"39127","75ecb4f9":"39580",fd867f7c:"39626","62547fbf":"39675","3e9399ec":"39796","359a0a8d":"40073","39f63e6a":"40081","8740ec05":"40114",eb907bb2:"40211","49e3720f":"40219","41790d5d":"40542","716600a7":"40614","0abae2e0":"40683","1ce0a301":"40701",c343ef35:"40830",e4459066:"40916",d0d62bb5:"41003",a6c72656:"41276",ee640683:"41804","82a30884":"41847","717e7ee6":"41877","9a6be05d":"42069",acdbee8e:"42885","6b85e2ea":"43726",a61ed651:"44120","278665dc":"44209","1bde5858":"44850",e7d2e6f0:"44880","95d5a544":"44916",cb819e9b:"45111",da88d543:"45167","034a556b":"45208","2f7c7419":"45293","8070429a":"45919","778f38dc":"46039","784585a8":"46215","763e4dec":"46566","70b01d77":"46976","47f09a6b":"47137","6daf901a":"47328","146da2b4":"47563","84ebbbbf":"47615","196fab6d":"47769","7f281903":"47969",a120aaca:"48026","5dce62fd":"48081","553f321c":"48124",e4492fa7:"48169","41f003c0":"48244",d5603669:"48890",b0bdb7f3:"48954",e72cf26a:"49486",a5962d55:"49717",c123803f:"49755",fd3dbbb4:"50030","246367e0":"50067","867911a0":"50430","4b1cba20":"50730","965dbb95":"50893","485af29a":"50932",dd813bf5:"51106",bd1a9377:"51410",a3761f7f:"51523","4507e508":"52474",de127d6b:"52486",e2668db3:"52574",a4b6f3a5:"52603",f024ddd5:"52654","5ec88f12":"52831","203d8c37":"53111","63ee150d":"53309","4694df8d":"53408",a718913e:"53482","7795e3fe":"53501",ebe9f683:"53559",dd02e78e:"53630","2fa02bf3":"53778","2f5fda3e":"54013","24e3585b":"54053","695f8b9b":"54235",c552c222:"54601","760e3208":"54636","3ec68450":"54801","05a18904":"54820","100f3054":"55038","2fcfad90":"55229","74c40fe4":"55328",cfc9c16e:"55381","006095b2":"55480",c3aed80f:"56025","879063fc":"56319","36f93d19":"56370","9ffa1a6c":"56382","4b7a6889":"56886","51ca6efd":"56955","1b80e345":"56963",d005934a:"56979","4be15b13":"57060",eece046c:"57067",e09bff2e:"57152",eb1718b4:"57251",bde9fb45:"57287",c86abbf7:"57480","6ab4408e":"57756",c5059afe:"57979",fbf4432e:"58000",e73e328f:"58188","3bdeaa89":"58235","162f137e":"58353",e6a2b2bf:"58634",c7dcc258:"58663","6a9a7317":"59082","3b0223df":"59131",e27b8251:"59135","68648e27":"59469",edfdb191:"59485","25f376d4":"59607",aa5bd2a7:"59728",d68e7e95:"59738",e5c88a3e:"59856",e8ee0390:"59865","16142a34":"59910","2041170f":"59953",d4e7ac8a:"60298","5913a508":"60310","2d4599ae":"60377","353f52a3":"60679","2fcd316c":"61166","8d5fe6f9":"61304","2b6f680f":"61528","988ba51e":"62062","35d50d77":"62353","00468222":"62746","3d49fc0e":"62860","1c5b9066":"63447",b8541bfd:"63497","51b69e86":"63851",c54a5582:"64166",c4f5d8e4:"64195",d7a48e98:"64209","575f1b1b":"64214","95a35da8":"64280","4bec54d5":"64364","099f8a1f":"64497","788d9fe0":"64549","63c7b841":"64557","8ade285d":"64814","7ee339c8":"64925","53e78238":"65149",af35203c:"65154","796ce4fb":"65349",cc468388:"65368","291c8f9c":"65573","2f2f8f8f":"65687",e4627c87:"65957",e8bf0c3e:"66068","42a8d727":"66345",e938eb25:"66546",f32d8490:"66880","6df78374":"67098","7196ee6c":"67112","137314dd":"67328","18f77871":"67365","6279c8a9":"67374",df7ec86c:"67746","8894256f":"67813",bcd02ebb:"67821","0f9cda3e":"67861","73ce7b01":"68005","7622c6de":"68207","363ba2d8":"68253","3d3a07f6":"68349",f8c92f63:"68503","4090f62b":"68809",eaafcd74:"68970","9ad8637e":"69043",c80ee60a:"69125","30b61715":"69184","8000380e":"69572","7e31db45":"69753",e23eefc0:"69905","41abf40a":"70022",b9535f14:"70147","39fee459":"70332","3b768736":"70509",b50c9021:"70633",e62aa786:"70670",c7399101:"70743","22bdf908":"70838",e93ff9aa:"71347","43cca846":"71568","397d4a7e":"71600","0328b0c9":"71723",ce32ce4d:"71871","2a3724f5":"71910","57494db5":"72069",a5c74766:"72145","9dba6800":"72379","540cb455":"72809",bb0e99df:"72841","5bf9b44a":"72978","04849bf5":"73091","94fe2afe":"73375","3c6391c1":"73464",bdb43652:"73695","9b6eea2c":"73894","94b87f57":"73905","4294ceba":"73918","84cf2087":"74190","48db5030":"74298","53d82fc0":"74428",b25d4024:"74531","0ed89c29":"74971",cf69f832:"75063","466daf09":"75066","77de130e":"75288","4e6cf383":"75474","30fdf4bf":"75600","0667cc8f":"75791",b180b1b1:"76152","94a29094":"76255","418c923e":"76428",d67ae496:"76541","7a65c859":"76549","11b4dd89":"77184",eb746456:"77535","97d979ce":"77665","18a382cc":"77811",ea313555:"77937","6bc64de5":"77944","3af651bf":"77999","2b20c80a":"78023","9218c1fd":"78315","5f10f6e3":"78340","0abbbb35":"78541","1fa35ec3":"78638",f46c4408:"78776",e77a5489:"79014","904cfab0":"79046","722ec584":"79054",b27348e5:"79239","378b1b2a":"79315","6249c7de":"79376","1db45fbc":"79475","7c767e9e":"79480","77622da5":"79923","8c139ad0":"80032","935f2afb":"80053","500ab5e8":"80103",a7c6c228:"80369","17c91901":"80536",df36d98d:"80567",b85fa405:"80808",d312cf7c:"81030","6c43de6e":"81135","476a319a":"81188",df330cef:"81447","563d7403":"81451",bffae127:"81500",f1e3befe:"81747",c8450cf2:"81981","555d583b":"82294","16127d6f":"82381","71c1d7a6":"82672",d5e6c777:"82708","471f7fbd":"82718",aea5d0af:"82803","12f49e0c":"82921",da6ad706:"83100","67009ff2":"83154","9622a62d":"83302","9f602629":"83398",d8f590ab:"83416","0d16b667":"83616",ef308d07:"83701","8c02dfd8":"83771","39c791a9":"83773","1dc390ba":"84052","38f61187":"84099","8dca2180":"84249","121b1090":"84386","2e4eadd3":"84840",b4eef555:"84857","2e8d4eda":"84878",c75d7ff6:"84959",d94bb6b6:"84987","730110a3":"85056",c0e80954:"85188","06848362":"85313",e593aec6:"85534","87b2412c":"85621","6dd1645f":"85660",bf0b75c4:"85836","6b3775fc":"85897",b700f6c8:"85953","9267eb77":"86139",c4cf1261:"86390",f2a10594:"86451",cb4175f3:"86529","87a13df2":"87173","393be207":"87414",d46f8e51:"87493","40230f21":"87655","6dde3b76":"87658","750960ca":"87677","4c4c3de8":"87824","5daee80f":"88042","8204d27d":"88258","3c8da607":"88831","856bceac":"89047",db4f0c5e:"89083",faee50e1:"89167","3f0d1ba4":"89415",b7c7e74a:"89776",c1d23c47:"89786","75a6ad06":"89912",b82b3205:"89964",e0751957:"90357","76e9b4e1":"90951","0248575c":"91538","5a7e7a34":"91569",ec202e26:"91759","9a072ddf":"92097","726fea1f":"92416","0c337ca4":"92560","5be4f4f7":"93006","73bfea73":"93056","812cb8ed":"93065",eb2927ba:"93348","007a6c32":"93387","49dbb45e":"93418","4a6f24a9":"93507","510addcb":"93543",d9ffe17e:"94089","4b3e38af":"94194",d6b0fe44:"94201","189eacae":"94215",d108a77f:"94276",d0816b53:"94319",fd03cc72:"94506","29f28a73":"94907",f8dc48d9:"95190","994f6abf":"95496","6f9bf5a7":"95557",caaad1b0:"95662",f4bc196f:"95690","710d4e4e":"95974","6ab4df05":"96247","8aadacf1":"96276","3aecebcc":"96361","120d9fdd":"96551","68f43c04":"96826","03e0b503":"97170",c8a855a5:"97421","4a3e680b":"97482",d63a00cf:"97500","51c3befa":"97719",e9d56634:"97879","954fe569":"97900","1a4e3797":"97920",ffb2e417:"98016",acc38ec3:"98105","4b25ddc7":"98220",a61cb094:"98591",d0931cd6:"98604","68e9a632":"98630","67044a7a":"98692","0d6f57e0":"98792","65e0cd55":"98948","4ade5613":"98960","02574e0f":"99070",b5511831:"99438",a6f4eced:"99533","595b2ce9":"99822",f56b8973:"99889"}[e]||e,t.p+t.u(e)},(()=>{var e={51303:0,40532:0};t.f.j=(b,a)=>{var f=t.o(e,b)?e[b]:void 0;if(0!==f)if(f)a.push(f[2]);else if(/^(40532|51303)$/.test(b))e[b]=0;else{var d=new Promise(((a,d)=>f=e[b]=[a,d]));a.push(f[2]=d);var c=t.p+t.u(b),r=new Error;t.l(c,(a=>{if(t.o(e,b)&&(0!==(f=e[b])&&(e[b]=void 0),f)){var d=a&&("load"===a.type?"missing":a.type),c=a&&a.target&&a.target.src;r.message="Loading chunk "+b+" failed.\n("+d+": "+c+")",r.name="ChunkLoadError",r.type=d,r.request=c,f[1](r)}}),"chunk-"+b,b)}},t.O.j=b=>0===e[b];var b=(b,a)=>{var f,d,c=a[0],r=a[1],o=a[2],n=0;if(c.some((b=>0!==e[b]))){for(f in r)t.o(r,f)&&(t.m[f]=r[f]);if(o)var i=o(t)}for(b&&b(a);n Derivatives Guides | Bybit API Documentation - + - + \ No newline at end of file diff --git a/category/spot.html b/category/spot.html index 2acfe9e99d..a7124593a2 100644 --- a/category/spot.html +++ b/category/spot.html @@ -4,13 +4,13 @@ Spot Guides | Bybit API Documentation - + - + \ No newline at end of file diff --git a/changelog/asset-v3.html b/changelog/asset-v3.html index 588c0dd5e6..2c8e5b686f 100644 --- a/changelog/asset-v3.html +++ b/changelog/asset-v3.html @@ -4,13 +4,13 @@ Account Asset V3 | Bybit API Documentation - +

    Account Asset V3

    2023-09-18

    REST API

    • Create Sub UID API Key [UPDATE]
      • Request parameter ips is actually string type. array can be used, but string is more explicit
      • Request parameter Derivatives has been depreciated due to auto identification by system
    • Modify Master API Key [UPDATE]
      • Request parameter ips is actually string type. array can be used, but string is more explicit
      • Request parameter Derivatives has been depreciated due to auto identification by system
    • Modify Sub API Key [UPDATE]
      • Add a new request param apikey, which can be used for Master account to manage sub account api key
      • Request parameter ips is actually string type. array can be used, but string is more explicit
      • Request parameter Derivatives has been depreciated due to auto identification by system
    • Delete Sub API Key [UPDATE]
      • Add a new request param apikey, which can be used for Master account to delete sub account api key

    2023-08-31

    REST API

    • Get Deposit Records (on chain) [UPDATE]
      • Add a new response field depositType. You can process deposit assets in the web when the deposit has daily deposit limit or abnormal deposit issue.
    • Get Sub Deposit Records (on chain) [UPDATE]
      • Add a new response field depositType. You can process deposit assets in the web when the deposit has daily deposit limit or abnormal deposit issue.

    2023-08-30

    REST API

    2023-08-17

    REST API

    2023-08-07

    REST API

    • Enable Universal Transfer [DEPRECIATE]
      • Depreciated endpoint. No need to configure this, all sub uids support universal transfer by default

    2023-07-24

    REST API

    • Get Single Coin Balance [UPDATE]
      • Add new request param: toAccountType, toMemberId, withLtvTransferSafeAmount
      • Add new response field: ltvTransferSafeAmount

    2023-06-15

    REST API

    2023-06-06

    REST API

    • Withdraw [UPDATE]
      • Add new request param feeType, which is used to select the withdrawal fee operation type when withdraw

    2023-03-23

    REST API

    2023-03-15

    REST API

    • Get Single Coin Balance [UPDATE]
      • Add a new request param withTransferSafeAmount and a new response field transferSafeAmount

    2023-02-28

    REST API

    2023-02-20

    REST API

    2023-02-14

    REST API

    • Withdraw [UPDATE]
      • Select the wallet to be withdrawn from
      • The default withdrawn wallet is Spot wallet
    Req paramRequiredTypeComments
    accountTypefalsestringSelect the wallet to be withdrawn from
    • SPOT:spot wallet (default)
    • FUND:Funding wallet

    2023-02-09

    REST API

    2023-02-06

    REST API

    - + \ No newline at end of file diff --git a/changelog/copytrade.html b/changelog/copytrade.html index 605d2dc2fa..ad06c87e78 100644 --- a/changelog/copytrade.html +++ b/changelog/copytrade.html @@ -4,13 +4,13 @@ Copy Trading | Bybit API Documentation - +

    Copy Trading

    2023-06-24

    REST API

    • Bybit starts to release a fully new copy trading on 24th June 2023. It is released gradually by end digit of uid. You can select to upgrade to new copy trading when you are applicable. Once upgraded, please note below points:
      • You will be allocated a new sub account, which has USDT Perpetual copy trading ability
      • Create a new api key for that sub account, and grant it "Contract" permissions.
      • You are no longer permitted to use Copy Trade V3 API. Alternatively, you can go to Contract V3 or V5 to trade, and V5 API is recommended.

    2023-03-23

    REST API

    2023-03-15

    REST API

    - + \ No newline at end of file diff --git a/changelog/derivatives-v3.html b/changelog/derivatives-v3.html index 993006d0d3..8793a48a83 100644 --- a/changelog/derivatives-v3.html +++ b/changelog/derivatives-v3.html @@ -4,13 +4,13 @@ Derivatives V3 | Bybit API Documentation - +

    Derivatives V3

    2023-10-25

    REST API

    Websocket API

    • Position [UPDATE]
      • Add response field isReduceOnly, mmrSysUpdatedTime, leverageSysUpdatedTime

    2023-09-28

    REST API

    2023-08-11

    REST API

    • Wallet Balance
      • availableToBorrow always returns "" because main-sub uids share borrow quota

    WebSocket API

    • Wallet
      • availableToBorrow always returns "" because main-sub uids share borrow quota

    2023-07-31

    REST API

    WebSocket API

    2023-07-13

    REST API

    2023-05-23

    REST API

    • Place Order [UPDATE]
      • Add new request params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType
    • Replace Order [UPDATE]
      • Add new request params for new TP/SL tpLimitPrice, slLimitPrice
    • Get Open Orders [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice
    • Get Order List [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice
    • My Position [UPDATE]
      • tpSlMode in the position is depreciated
    • Set Trading Stop [UPDATE]
      • Add new request params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType

    WebSocket API

    • Position
      • tpSlMode in the position is depreciated
    • Order [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice

    2023-05-10

    REST API

    Old error codeNew error codeMsg
    10001140071RiskId is not modified

    2023-04-20

    REST API

    • Account Info [UPDATE]
      • add new response fields dcpStatus, timeWindow, smpGroup
    • Place Order [UPDATE]
      • add new request param smpType used to select SMP execution type
    • Get Open Orders [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType
    • Get Order List [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType

    WebSocket API

    • Order [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType

    2023-04-12

    REST API

    • My Position [UPDATE]
      • add response param adlRankIndicator

    WebSocket API

    • Position [UPDATE]
      • add response param adlRankIndicator

    2023-03-08

    REST API

    • Risk Limit [UPDATE]
      • remove useless response field section

    2023-03-03

    REST API

    • Ticker Info [UPDATE]
      • A new response field openInterestValue is added for Futures
    • Open Interest [UPDATE]
      • cursor & nextPageCursor are added to support pagination

    2023-02-28

    REST API

    • IP Rate Limit [UPDATE]
      • Due to the switch to CloudFront, the IP limit rules have been adjusted appropriately

    2023-02-20

    WebSocket API

    • Execution [UPDATE]
      • Add new fields: blockTradeId, markPrice

    2023-02-09

    REST API

    WebSocket API

    • Order [UPDATE]
      • Add new fields: avgPrice, blockTradeId, cancelType, cumExecFee, leavesValue, positionIdx, rejectReason

    2023-01-19

    REST API

    • Set Margin Mode
      • Portfolio margin mode supports USDT Perpetual
    • Get Open Orders
      • For portfolio margin mode, orderIM returns ""
    • Get Order List
      • For portfolio margin mode, orderIM returns ""
    • My Position
      • For portfolio margin mode, positionIM, positionMM, leverage returns "", riskId returns 0
    • Wallet Balance
      • For portfolio margin mode, totalOrderIM, totalPositionIM, totoalPositionMM returns ""

    WebSocket API

    • Position
      • For portfolio margin mode, positionIM, positionMM, leverage returns "", riskId returns 0
    • Order
      • For portfolio margin mode, orderIM returns ""
    • Wallet
      • For portfolio margin mode, totalOrderIM, totalPositionIM, totoalPositionMM returns ""

    2023-01-16

    WebSocket API

    • Orderbook
      • Add 500 level depth, push frequency is 100ms

    2023-01-09

    WebSocket API

    • Tickers
      • nextFundingTime has been changed from dataTime 2023-01-05T08:00:00Z to timestamp (ms) 1672905600000
      • predicatedFundingRate has been removed from stream
    - + \ No newline at end of file diff --git a/changelog/spot-v3.html b/changelog/spot-v3.html index a99b5fa766..b3bd5a7fe2 100644 --- a/changelog/spot-v3.html +++ b/changelog/spot-v3.html @@ -4,13 +4,13 @@ Spot V3 | Bybit API Documentation - +

    Spot V3

    2023-04-20

    REST API

    • Place Order [UPDATE]
      • add new request param smpType used to select SMP execution type
      • add new response param smpType
    • Open Orders [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new response field cancelType, the enum value is CancelBySmp and UNKNOWN
    • Get Order [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new response field cancelType, the enum value is CancelBySmp and UNKNOWN
    • Order History [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new response field cancelType, the enum value is CancelBySmp and UNKNOWN

    WebSocket API

    • Order [UPDATE]
      • add new response fields st, sg, so
      • add new response field ct, the enum value is CancelBySmp and UNKNOWN

    2023-04-12

    REST API

    WebSocket API

    • Order [UPDATE]
      • add response field b, which indicates "blockTradeId"
    • Execution [UPDATE]
      • add response field b, which indicates "blockTradeId"

    2023-03-13

    WebSocket API

    • Stop Order [UPDATE]
      • add new response field triggerPrice tp

    2023-03-09

    REST API

    2023-02-28

    REST API

    • IP Rate Limit
      • due to the switch to CloudFront, the IP limit rules have been adjusted appropriately
    • Public Trading Records
      • type field in the response to tell if it is a paradigm trade

    2023-01-16

    WebSocket API

    • Tickers
      • xp has been added to stream. It means USD index price, which can be empty.
    - + \ No newline at end of file diff --git a/changelog/v5.html b/changelog/v5.html index 91d24b1dce..f0a445d413 100644 --- a/changelog/v5.html +++ b/changelog/v5.html @@ -4,7 +4,7 @@ V5 | Bybit API Documentation - + @@ -14,7 +14,7 @@ USDTPerpetualLeverage, symbol, leverage, USDCContractLeverage
  • Get Loan Orders
    • Add new Response fields: USDTPerpetualOpenLine, USDCContractOpenLine, USDCOptionsOpenLine, USDTPerpetualCloseLine, USDCContractCloseLine, USDCOptionsCloseLine, USDCContractSymbols, USDCOptionsSymbols, marginLeverage, USDTPerpetualLeverage, symbol, leverage, USDCContractLeverage
  • Get Single Coin Balance
    • Add new request param: toAccountType, toMemberId, withLtvTransferSafeAmount
    • Add new response field: ltvTransferSafeAmount
  • Add error codes for UTA with OTC loan when trade Spot, Futures and Option
  • New error codeDescription
    30133USDT Perp: When the trading pair is not in the whitelist
    30134USDC Contract: When the trading pair is not in the whitelist
    30135USDT Perp: When you try to change a leverage higher than the maximum leverage in OTC loan
    30136USDC Contract: When you try to change a leverage higher than the maximum leverage in OTC loan
    3200316Option: restrict to trade
    3200317Option: restrict to buy
    170709Spot: When the trading pair is not in the whitelist
    170215Spot: restrict to buy
    170216Spot: margin leverage exceeded
    170220Spot: restrict to trade

    2023-07-13

    REST API

    2023-07-04

    REST API

    2023-06-26

    WebSocket API

    • Orderbook [Spot]
      • Improve the push frequency from 100ms to 20ms of level 50

    2023-06-24

    REST API

    • Get Instruments Info [UPDATE]
      • When category=linear, add a new response params copyTrading to indicate this trading pair supporting copy trade or not for UTA and normal account

    2023-06-15

    REST API

    2023-06-14

    REST API

    2023-06-08

    REST API

    • Get Fee Rate [UPDATE]
      • Support to get USDC perp & USDC futures trading fee rate

    2023-06-07

    REST API

    • Withdraw [UPDATE]
      • Add new request param feeType, which is used to select the withdrawal fee operation type when withdraw

    2023-06-06

    REST API

    2023-06-02

    REST API

    • Get Affiliate User Info [New]
      • A brand new endpoint, which is used for affiliate to check the basic information of their users

    2023-06-01

    REST API

    • Set Margin Mode [UPDATE]
      • UTA account supports isolated margin, a new enum ISOLATED_MARGIN for request param "setMarginMode"
    • Switch Position Mode [UPDATE]
      • UTA account supports Hedge mode for USDT Perp when it is isolated margin or cross margin mode
    • Get Position Info [UPDATE]
      • Add new response field positionBalance
    • Get Account Info [UPDATE]
      • "marginTrade" field has a new enum value - ISOLATED_MARGIN
    • Set Auto Add Margin [UPDATE]
      • add category enum linear for UTA
    • Add Or Reduce Margin [UPDATE]
      • A brand new endpoint is used to add or reduce specific margin you want

    WebSocket API

    • Position [UPDATE]
      • Add new response param positionBalance

    2023-05-30

    REST API

    • Get Instruments Info [UPDATE]
      • When category=spot, add a new response params marginTrading to indicate this trading pair supporting margin trade or not for UTA and normal account

    2023-05-23

    REST API

    • Place Order [UPDATE]
      • Add new request params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType
    • Amend Order [UPDATE]
      • Add new request params for new TP/SL tpLimitPrice, slLimitPrice
    • Get Open Orders [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice
    • Get Order History [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice
    • Get Position Info [UPDATE]
      • tpslMode in the position is depreciated
    • Set Trading Stop [UPDATE]
      • Add new request params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType

    WebSocket API

    • Position [UPDATE]
      • tpslMode in the position is depreciated
    • Order [UPDATE]
      • Add new response params for new TP/SL tpslMode, tpLimitPrice, slLimitPrice

    2023-05-10

    REST API

    Old error codeNew error codeMsg
    10001110075RiskId is not modified

    2023-05-05

    REST API

    2023-05-04

    REST API

    • Get Execution [UPDATE]
      • symbol is no longer mandatory for normal account when get derivatives
    • Get Closed PnL [UPDATE]
      • symbol is no longer mandatory for normal account when get derivatives

    2023-04-20

    REST API

    • Place Order [UPDATE]
      • add new request param smpType used to select SMP execution type
    • Get Open Orders [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType
    • Get Order History [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType
    • Get Account Info [UPDATE]
      • add new response fields dcpStatus, timeWindow, smpGroup

    WebSocket API

    • Order [UPDATE]
      • add new response fields smpType, smpOrderId, smpGroup
      • add new enum cancelBySmp of cancelType

    2023-04-06

    REST API

    2023-04-04

    REST API

    • Get Instruments Info [UPDATE]
      • add request param startTime endTime, effective for UTA mode
      • add response param placeType, used for option

    2023-04-04

    REST API

    • Get Order History [UPDATE]
      • add request param startTime endTime, effective for UTA mode
      • add response param placeType, used for option
    • Get Execution [UPDATE]
      • add response param closedSize
    • Get Position Info [UPDATE]
      • add response param adlRankIndicator

    WebSocket API

    • Position [UPDATE]
      • add response param adlRankIndicator
      • category field is added to UTA stream
    • Order [UPDATE]
      • add response param placeType, used for option
    • Execution [UPDATE]
      • add response param closedSize

    2023-03-24

    REST API

    2023-03-23

    REST API

    WebSocket API

    • Wallet [UPDATE]
      • Add a new response field accountLTV

    2023-03-22

    REST API

    2023-03-15

    REST API

    • Get Single Coin Balance [UPDATE]
      • Add a new request param withTransferSafeAmount and a new response field transferSafeAmount

    2023-03-10

    REST API

    • Get Instruments Info [UPDATE]
      • Unify the enums of status for Spot, Derivatives and Options. Use Trading, Closed, Settling, PreLaunch, Deliverying
      • Remove duplicate category field in the Options response
    • Get Fee Rate [UPDATE]
      • Support to get Options trading fee rate

    2023-03-09

    REST API

    • Set Leverage [UPDATE]
      • UTA user can set up to 10X for margin trade
    • Get Wallet Balance [UPDATE]
      • Before adjustment: normal account gets error code and message when call accountType=UNIFIED.
        After adjustment: normal account gets http code 400 when call accountType=UNIFIED

    2023-02-28

    REST API

    WebSocket API

    • Wallet [UPDATE]
      • Add a new field bonus

    2023-02-20

    REST API

    2023-02-15

    REST API

    • User [NEW]
      • Add a set of user & api key related endpoints for V5

    2023-02-14

    REST API

    • Get Fee Rate (Derivatives) [NEW]
      • Get the trading fee rate for derivatives
    • Withdraw [UPDATE]
      • Select the wallet to be withdrawn from
      • The default withdrawn wallet is Spot wallet
    Req paramRequiredTypeComments
    accountTypefalsestringSelect the wallet to be withdrawn from
    • SPOT:spot wallet (default)
    • FUND:Funding wallet

    2023-02-09

    REST API

    2023-01-19

    REST API

    • Set Margin Mode [UPDATE]
      • Portfolio margin mode supports USDT Perpetual
    • Get Position Info [UPDATE]
      • For portfolio margin mode, positionIM, positionMM, leverage, riskLimitValue returns "", riskId returns 0
    • Get Wallet Balance [UPDATE]
      • For portfolio margin mode, totalOrderIM, totalPositionIM, totoalPositionMM returns ""

    WebSocket API

    • Position [UPDATE]
      • For portfolio margin mode, positionIM, positionMM, leverage, riskLimitValue returns "", riskId returns 0
    • Wallet [UPDATE]
      • For portfolio margin mode, totalOrderIM, totalPositionIM, totoalPositionMM returns ""

    2023-01-16

    REST API

    • Get Tickers [spot]
      • usdIndexPrice has been added to response. It means USD index price, which can be empty.

    WebSocket API

    • Tickers [spot]
      • usdIndexPrice has been added to stream. It means USD index price, which can be empty.
    • Orderbook [linear contract & inverse contract]
      • Add 500 level depth, push frequency is 100ms

    2023-01-09

    WebSocket API

    • Tickers [linear contract & inverse contract]
      • nextFundingTime has been changed from dataTime 2023-01-05T08:00:00Z to timestamp (ms) 1672905600000
      • predicatedFundingRate has been removed from stream
    - + \ No newline at end of file diff --git a/copy-trade/account/transfer-list.html b/copy-trade/account/transfer-list.html index f5117e90d1..564798ec83 100644 --- a/copy-trade/account/transfer-list.html +++ b/copy-trade/account/transfer-list.html @@ -4,13 +4,13 @@ Get Transfer History | Bybit API Documentation - +

    Get Transfer History

    Get the transfer history of Copy-trade wallet

    tip

    Need Wallet - "Account Transfer" permission

    HTTP Request

    GET /asset/v3/private/transfer/copy-trading/list/query

    Request Parameters

    ParameterRequiredTypeComments
    transferIdfalsestringUUID, which is unique across the platform
    coinfalsestringCoin name
    statusfalsestringStatus. Query all by default
    copyTradeTypefalseintegerThe copy-trade type. 0: all, 1: Contract copy trade, 2 (not available): Spot copy trade
    startTimefalseintegerThe start timestamp (ms). Query the past 30 days by default when not passed
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringThe transfer ID
    > coinstringCoin name
    > amountstringAmount
    > fromAccountTypestringFrom account type
    > toAccountTypestringTo account type
    > timestampstringTransfer timestamp
    > statusstringTransfer status
    > copyTradeTypeintegerCopy-trade type. 1: Contract copy trade, 2 (not available): Spot copy trade
    nextPageCursorstringCursor

    Request Example

    GET /asset/v3/private/transfer/copy-trading/list/query?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1679560892359
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "cb86de08-b10f-4abe-9746-7b95c4a37d307",
    "coin": "USDT",
    "amount": "100",
    "fromAccountType": "UNIFIED",
    "toAccountType": "COPYTRADE",
    "timestamp": "1678861757000",
    "status": "SUCCESS",
    "copyTradeType": 1
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MjY4MTAzNSwibWF4SUQiOjI2ODEwMzV9"
    },
    "retExtInfo": {},
    "time": 1679560892812
    }
    - + \ No newline at end of file diff --git a/copy-trade/account/transfer.html b/copy-trade/account/transfer.html index a098ce4250..9e498cbb00 100644 --- a/copy-trade/account/transfer.html +++ b/copy-trade/account/transfer.html @@ -4,13 +4,13 @@ Transfer | Bybit API Documentation - +

    Transfer

    Transfer

    HTTP Request

    POST /contract/v3/private/copytrading/wallet/transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID, which is unique across the platform
    cointruestringCurrency. USDT only
    amounttruestringExchange to amount
    fromAccountTypetruestringAccount type
    toAccountTypetruestringAccount type

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID, which is unique across the platform

    Request Example

    POST /contract/v3/private/copytrading/wallet/transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673257786588
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 173

    {
    "transferId": "5f95de08-b10f-43be-9746-7b95c4a37d307",
    "coin": "USDT",
    "amount": "500",
    "fromAccountType": "UNIFIED",
    "toAccountType": "COPYTRADING"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "transferId": "5f95de08-b10f-43be-9746-7b95c4a37d307"
    },
    "retExtInfo": {},
    "time": 1673258002526
    }
    - + \ No newline at end of file diff --git a/copy-trade/account/wallet.html b/copy-trade/account/wallet.html index 17418eebee..7ba15f0c97 100644 --- a/copy-trade/account/wallet.html +++ b/copy-trade/account/wallet.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - +

    Get Wallet Balance

    Get CopyTrading Wallet Balance

    HTTP Request

    GET /contract/v3/private/copytrading/wallet/balance

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    coinstringCoin
    equitystringUser equity (wallet_balance + unrealised_pnl)
    availableBalancestringAvailable balance = wallet balance - used margin
    usedMarginstringUsed margin
    orderMarginstringPre-occupied order margin
    positionMarginstringPosition margin
    walletBalancestringWallet balance
    realisedPnlstringToday's realised pnl
    unrealisedPnlstringunrealised pnl
    cumRealisedPnlstringAccumulated realised pnl (all-time total)

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/contract/v3/private/copytrading/wallet/balance' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841373442' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "availableBalance": "985.4988359",
    "usedMargin": "0",
    "orderMargin": "0",
    "positionMargin": "0",
    "walletBalance": "985.4988359",
    "realisedPnl": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "-14.5011641",
    "coin": "USDT",
    "equity": "985.4988359"
    },
    "retExtInfo": {},
    "time": 1673257786956
    }
    - + \ No newline at end of file diff --git a/copy-trade/enum.html b/copy-trade/enum.html index 5056459daa..0f3d6edfe1 100644 --- a/copy-trade/enum.html +++ b/copy-trade/enum.html @@ -4,13 +4,13 @@ Enums Definitions | Bybit API Documentation - +

    Enums Definitions

    accountType

    • UNIFIEDUnified account
    • CONTRACTFuture account
    • COPYTRADINGCopyTrading account

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    symbol

    CopyTrading supports USDT Perpetual only

    • BTCUSDT
    • ETHUSDT
    • SOLUSDT
    • ...

    orderType

    • Market
    • Limit

    triggerBy

    • LastPrice
    • IndexPrice
    • MarkPrice

    copyTradeOrderStatus

    • UNKNOWN
    • PendingNew
    • New
    • OpenOrderPartiallyFilled
    • OpenOrderFilled
    • OpenOrderClosing
    • OpenOrderClosedFilled
    • CloseOrderPartiallyFilled
    • CloseOrderFilled
    • Cancelled
    • Untriggered
    • Triggered

    timeInForce

    • GoodTillCancel
    • ImmediateOrCancel
    • FillOrKill
    • PostOnly

    positionIdx

    • 0one-way mode
    • 1Buy side hedge mode
    • 2Sell side hedge mode

    interval

    • 1 3 5 15 30 60 120 240 360 720minute
    • Dday
    • Wweek
    • Mmonth

    tickDirection

    It indicates price fluctuation relative to the last trade.

    • PlusTickprice rise
    • ZeroPlusTicktrade occurs at the same price as the previous trade, which occurred at a price higher than that for the trade preceding it
    • MinusTickprice drop
    • ZeroMinusTicktrade occurs at the same price as the previous trade, which occurred at a price lower than that for the trade preceding it

    execType

    lastLiquidityInd

    • AddedLiquidityadd liquidity
    • RemovedLiquiditytake liquidity
    • LiquidityIndNALiquidity not applicable
    - + \ No newline at end of file diff --git a/copy-trade/error.html b/copy-trade/error.html index c4aad557dc..31eeef0ab8 100644 --- a/copy-trade/error.html +++ b/copy-trade/error.html @@ -4,13 +4,13 @@ Error Code | Bybit API Documentation - +

    Error Code

    CodeDescription
    10000An unknown error occurred while processing the request.
    10001There was a problem with the value passed to the API
    10002Request not authorized - an API key is required and should be included in all requests.
    10003Invalid api key
    10004Invalid sign
    10005Permission denied for current apikey. API key was created without the correct permissions (e.g. doesn´t have Order permission, or it's set to read-only)
    10006Too many visits. Refer to the API rate limit. Please use WebSocket for live updates. Current limit is %s requests per minute.
    10007Response timeout from backend server. Delivery and request status unknown.
    10010Request IP mismatch.
    10012DB error
    10014Trading pairs not supported.
    10015Too many new orders. Please lower request frequency.
    10016Service not available.
    10017Request path not found or request method is invalid
    10018Exceeded IP rate limit.
    10020Request not supported.
    10021Timestamp for the request is outside of the recvWindow. The timestamp of this request is 1000 milliseconds ahead of the server time. Please check local time and server time.
    10022Invalid request signature.
    11000Parameter characters not supported.
    11001Too many parameters sent for this endpoint.
    11002Required parameter not sent. Parameter was empty/null or format was incorrect.
    11003Unknown parameter sent.
    11004Not all parameters sent were read.
    11005Empty parameter.
    11006Parameter was sent when no longer required.
    11011Order price exceeded upper limit.
    11012Trading pair does not exist.
    11014TimeInForce parameter sent when not required.
    11015Invalid timeInForce.
    11016Invalid orderType.
    11017Invalid direction.
    11018User-generated order ID was empty.
    11019User-generated order ID was empty.
    11020Invalid interval.
    11021Invalid symbol.
    11025listenKey does not exist.
    11027Query intervals too large.
    11028Invalid parameter combination.
    11030Invalid parameter sent.
    11031Insufficient balance.
    11032Order price exceeded upper limit.
    11033Order price exceeded lower limit.
    11034Order price has too many decimals.
    11035Order quantity exceeded upper limit.
    11036Order quantity exceeded lower limit.
    11037Order quantity has too many decimals.
    11038Order price exceeded limits.
    11039Order has been filled.
    11040Order value exceeded lower limit.
    11041Duplicate clientOrderId.
    11042Order has been canceled.
    11043Order not found.
    11044Order being cancelled. Operation not supported.
    11045Order cannot be canceled.
    11046Order creation timeout.
    11047Order cancellation timeout.
    11090Cancel order has been finished.
    11091Can not cancel order, please try again later.
    20001Order does not exist.
    20003Missing parameter side
    20004Invalid parameter side
    20005Missing parameter symbol
    20006Invalid parameter symbol
    20007Missing parameter order_type
    20008Invalid parameter order_type
    20009Missing parameter qty
    20010New order rejected.
    20011Cancelation rejected.
    20012qty must be greater than zero and less than 1 million
    20013Order does not exist.
    20014Invalid API key format.
    20015Invalid API key or IP.
    20016Trading window not open yet for current pair.
    20017Missing parameter order_id
    20018Invalid date format
    20019Missing parameter stop_px
    20020Missing parameter base_price
    20021Missing parameter stop_order_id
    20022Missing parameter leverage
    20023Leverage must be a number
    20031Leverage must be greater than zero
    20070Missing parameter margin
    20071margin must be greater than zero
    20084order_id or order_link_id is required
    20094order_link_id is not unique.
    30002Exit order already exists.
    30003qty must be higher than the minimum allowed.
    30004qty must be higher than the minimum allowed. The number of contracts exceeds maximum limit allowed. Order qty should be less than 1 million per order.
    30005Order price is out of permissible range.
    30006No last_price.
    30007Order price is out of permissible range.
    30008Invalid order_type.
    30009No position found.
    30010Insufficient wallet balance.
    30011Operation not allowed as position is undergoing liquidation
    30012Operation not allowed as position is undergoing ADL
    30013Position is in liq or adl status
    30014Invalid closing order, qty should not be greater than size.
    30015Invalid closing order, side should be the opposite.
    30016TP and SL must be cancelled before closing the position.
    30017Estimated fill price cannot be lower than current Buy liq_price.
    30018Estimated fill price cannot be higher than current Sell liq_price.
    30019Cannot attach TP/SL params for non-zero position when placing non-opening position order.
    30020Position already has TP/SL params.
    30021Cannot afford estimated position_margin.
    30022Estimated buy liq_price cannot be higher than current mark_price.
    30023Estimated sell liq_price cannot be lower than current mark_price.
    30024Cannot set TP/SL/TS for zero-position
    30025Trigger price should bigger than 10% of last price.
    30026Price is too high.
    30027Price set for Take profit should be higher than Last Traded Price.
    30028Price set for Stop Loss should be between Liquidation price and Last Traded Price.
    30029Price set for Stop Loss should be between Last Traded Price and Liquidation Price.
    30030Price set for Take Profit should be lower than Last Traded Price.
    30031Insufficient available balance for order cost.
    30032Order has been filled or cancelled.
    30033The number of stop orders exceeds maximum limit allowed.
    30034No stop order found.
    30035Too fast to cancel, try it later.
    30036The expected position value after order execution exceeds the current risk limit
    30037Order already cancelled
    30038No mark_price.
    30039Applied leverage has exceeded the permitted range.
    30040Any adjustments made will trigger immediate liquidation.
    30041No position found.
    30042Insufficient wallet balance.
    30043Operation not allowed as position is undergoing liquidation.
    30044Operation not allowed as position is undergoing ADL.
    30045Operation not allowed as position is not in normal status.
    30046There are multiple untriggered stop orders.
    30047Inconsistent p:o.
    30048Applied leverage has exceeded the permitted range.
    30049Insufficient available balance.
    30050Any adjustments made will trigger immediate liquidation!
    30051Due to risk limit, cannot adjust leverage.
    30052Leverage cannot be less than 1x.
    30053max_affordable_position_margin <= 0, position:%s
    30054fixed_new_position_margin is invalid.
    30055Available Balance is not enough to add margin.
    30056The position is in cross_margin.
    30057Requested quantity of contracts exceeds risk limit, please adjust your risk limit level before trying again.
    30063Reduce-only rule not satisfied
    30066Set auto add margin fail.
    30067Insufficient available balance.
    30068Exit value must be positive.
    30073Number of active orders is greater than 500.
    30074Can't create the stop order, because you expect the order will be triggered when the LastPrice(or IndexPrice, MarkPrice, determined by trigger_by) is raising to stop_px, but the LastPrice(or IndexPrice, MarkPrice) is already equal to or greater than stop_px, please adjust base_price or stop_px
    30075Can't create the stop order, because you expect the order will be triggered when the LastPrice(or IndexPrice, MarkPrice, determined by trigger_by) is falling to stop_px, but the LastPrice(or IndexPrice, MarkPrice) is already equal to or less than stop_px, please adjust base_price or stop_px
    30076Replace params invalid. Order not modified.
    30077Submission of order will result in the breach of user's limit according to open interest.
    30078Contracts not in trading status
    30079The position is about to trigger a liquidation
    30080Price cannot be lower than current Buy liq_price
    30081Price cannot be greater than current sell liq_price
    30082Position exists No switching of position mode allowed
    30083No change in position pattern
    30084No changes to the full position-by-position model
    30085Margin unchanged
    30086With a commissioned order, switching position mode is not allowed
    30087Symbol does not support two-way open positions
    30088Symbol does not exist
    30089Duplicate order number
    30090Risk limit info does not exist
    30091Illegal orders (meaning that the order os
    30092No position is not allowed to set margin
    30093No net position
    30094Withdrawal of an order before a liquidation is not concluded
    30095Full positions are not allowed to modify leverage
    31003User account banned
    32006The available balance is not sufficient to cover the handling fee.
    32008Insufficient available margin.
    32009Any adjustments made will trigger immediate liquidation.
    32010Risk limit cannot be adjusted due to insufficient available margin.
    32011Risk limit cannot be adjusted as the current/expected position value held exceeds the revised risk limit.
    33004apikey already expired
    34010Wallet Balance is less than zero.
    34015Cannot set new leverage as it is equal to the previous leverage.
    34017Current leverage is less than 1X
    34018Cannot set leverage lower than 1X
    34019Cannot set leverage greater than maxLeverage.
    34020Cannot set leverage which is same to the previous leverage.
    34021Cannot cancel occ_calc_data, the data is wrong.
    34022Cannot set leverage which will cause available balance less than 0.
    34023The request was canceled because the origin request has been handled.
    34024The request does not include add margin data.
    34025Increase in leverage has failed.
    34026The new limit is equal to the old limit (no change).
    34027Cannot adjust leverage.
    34028ReCalc Funding Fee Failed.
    34030positionInfo not sync with current exec_rpt.
    34032PositionSeq not match on Withdraw.
    34033Realized PNL already rotated.
    34035Add margin not modified.
    34036Set leverage not modified.
    34037Set custom fee rate not modified.
    34038Update deleverage indicator not modified.
    34039Update position status not modified.
    34040Set TP/SL/TS not modified.
    35014Open interest exceeded.
    37001Both side positions tp_sl_mode is equal.
    37002Same tp_sl_mode.
    37003This position has at least one stop-link order and cannot switch between stop-loss and take-profit modes.
    37004This position has at least one stop-loss link order and cannot switch between stop-loss and take-profit modes.
    37005This position has at least one trailing stop or trailing stop link order and cannot be switched to take profit and stop loss mode.
    37006Conditional or limit orders carry a take profit and stop loss parameter
    37007Insufficient number of positions left to set Stop Loss and Take Profit
    37008Active orders are not allowed to modify the price and quantity when they also modify the trigger price
    37009Activity orders are not allowed to modify the stop-loss and take-profit settings if the order is partially filled
    37010In Full Take Profit Stop Loss mode, it is not allowed to modify the Stop Profit Stop Loss size
    37011In partial SL mode, SL is set to more than 20. Set SL/TP exceeds the limit oldTpNum+oldStNum+newNum=(2 the num is tp+sl)
    37012Stop loss price needs to be greater than base price.
    37013Stop loss price needs to be less than base price.
    38101Replacement of order will result in the breach of user's limit according to open interest.
    90015Insufficient balance
    90016Rejected by risk control. It may cause liquidation after the transfer.
    90063In the progress of liquidation
    90066In the reconciliation
    90067Reconciliation failed
    131200server err
    131201biz err
    131212user insufficient balance
    131217risk check err
    131203request parameter err
    131204account info err
    131206cannot be transfer
    131214transferId exist
    131215amount err
    131216query balance error
    131218unify transfer out risk,user's positions are currently under forced liquidation
    131219unify transfer out risk,transfer out waring
    131220unify transfer out risk,transfer out interest-free-load-limit waring
    131221unify transfer out risk,transfer out waring
    131222unify transfer out risk,reconciliation check fail
    131223unify transfer out risk,refused
    131224unify transfer out risk,balance not enough
    131225unsupported unify state
    - + \ No newline at end of file diff --git a/copy-trade/position/close-position.html b/copy-trade/position/close-position.html index 0610fc2c6d..9f6c02a575 100644 --- a/copy-trade/position/close-position.html +++ b/copy-trade/position/close-position.html @@ -4,13 +4,13 @@ Close All Positions | Bybit API Documentation - +

    Close All Positions

    Close Position

    HTTP Request

    GET /contract/v3/private/copytrading/position/close

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol
    positionIdxtruestringPosition idx, used to identify positions in different position modes: 0-Single side; 1-Buy side of both side mode; 2-Sell side of both side mode

    Response Parameters

    None

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/close' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841189767' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","positionIdx":"1"}'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/copy-trade/position/execution-list.html b/copy-trade/position/execution-list.html index 5949d313f9..119c86a26d 100644 --- a/copy-trade/position/execution-list.html +++ b/copy-trade/position/execution-list.html @@ -4,13 +4,13 @@ Get Execution List (2 years) | Bybit API Documentation - +

    Get Execution List (2 years)

    Query users' execution list, sort by execTime in descending order

    tip

    You may have multiple executions in a single order.

    HTTP Request

    GET /contract/v3/private/copytrading/execution/list

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    orderIdfalsestringOrder ID. Return all records if not passed
    orderLinkIdfalsestringUser customised order ID
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    execTypefalsestringExecution type
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringCursor. Used to pagination
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > orderIdstringOrder id
    > orderLinkIdstringUser customised order id
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > orderTypestringMarket,Limit
    > execIdstringTrade Id
    > execPricestringExecution price
    > execQtystringExecution qty
    > execFeestringExecution fee
    > execTypestringExecution type
    > execValuestringExecution position value
    > feeRatestringTrading fee rate
    > lastLiquidityIndstringAddedLiquidity, RemovedLiquidity, LiquidityIndNA
    > isMakerbooleanIs maker
    > leavesQtystringRemaining qty waiting for execution
    > closedSizestringClose size
    > markPricestringMark price
    > execTimestringExecution timestamp (ms)

    Request Example

    GET /contract/v3/private/copytrading/execution/list?symbol=XRPUSDT&execType=Funding HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1678788154878
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "nextPageCursor": "0o+MpbbRsIrLhRXdulAiDPRZFkidzCCKmEOQR4TzFIYyq1tofpJ/bOX92Vn8uwRBSEUuSxC/9jnLZs7oFLgcMQ==",
    "list": [
    {
    "symbol": "XRPUSDT",
    "side": "Buy",
    "orderId": "1678780800-XRPUSDT-1019213-Buy",
    "orderLinkId": "",
    "orderPrice": "0.0000",
    "orderQty": "0",
    "orderType": "UNKNOWN",
    "execFee": "0.003679",
    "execId": "73729a92-caf5-4911-8e85-5194dd2ee1c5",
    "execPrice": "0.3679",
    "execQty": "100",
    "execType": "Funding",
    "execValue": "36.79",
    "feeRate": "0.0001",
    "lastLiquidityInd": "LiquidityIndNA",
    "isMaker": false,
    "leavesQty": "0",
    "closedSize": "0",
    "markPrice": "0.3679",
    "execTime": "1678780800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1678788155282
    }
    - + \ No newline at end of file diff --git a/copy-trade/position/leverage.html b/copy-trade/position/leverage.html index 4fdc7653b9..3df0b1eba4 100644 --- a/copy-trade/position/leverage.html +++ b/copy-trade/position/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set Leverage

    HTTP Request

    GET /contract/v3/private/copytrading/position/set-leverage

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol
    buyLeveragetruestringThe value of buy_leverage must be equal to sell_leverage.
    sellLeveragetruestringThe value of buy_leverage must be equal to sell_leverage.

    Response Parameters

    None

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/set-leverage' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841373442' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","buyLeverage":"4","sellLeverage":"4"}'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/copy-trade/position/position-info.html b/copy-trade/position/position-info.html index f78ed8912f..adb6031c2d 100644 --- a/copy-trade/position/position-info.html +++ b/copy-trade/position/position-info.html @@ -4,13 +4,13 @@ Position List | Bybit API Documentation - +

    Position List

    Position List

    HTTP Request

    GET /contract/v3/private/copytrading/position/list

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol
    > sidestringSide
    > sizestringPosition qty
    > positionValuestringPosition value
    > entryPricestringAverage entry price
    > liqPricestringLiquidation price
    > bustPricestringBankruptcy price
    > markPricestringMark price
    > leveragestringIn Isolated Margin mode, the value is set by the user. In Cross Margin mode, the value is the max leverage at current risk level
    > isIsolatedbooleantrue means isolated margin mode; false means cross margin mode
    > positionMarginstringPosition margin
    > occClosingFeestringPosition closing fee occupied (your opening fee + expected maximum closing fee)
    > occFundingFeestringPre-occupied funding fee: calculated from position qty and current funding fee
    > cumRealisedPnlstringAccumulated realised pnl (all-time total)
    > freeQtystringQty which can be closed. (If you have a long position, free_qty is negative. vice versa)
    > unrealisedPnlstringunrealised pnl
    > positionIdxstringPosition idx, used to identify positions in different position modes:0-Single side; 1-Buy side of both side mode; 2-Sell side of both side mode
    > createdTimestringCreation time (when the order_status was Created)
    > updatedTimestringUpdate time

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/list' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "side": "Sell",
    "size": "0.02",
    "positionValue": "25.2665",
    "entryPrice": "1263.325",
    "liqPrice": "1383.30",
    "bustPrice": "1389.65",
    "markPrice": "1254.60",
    "leverage": "10",
    "isIsolated": true,
    "positionMargin": "2.52665009",
    "occClosingFee": "0.0166758",
    "occFundingFee": "0",
    "cumRealisedPnl": "132.46751301",
    "freeQty": "0.02",
    "unrealisedPnl": "0.1745",
    "positionIdx": "2",
    "createdTime": "1652324549816",
    "updatedTime": "1670841190027"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/copy-trade/rate-limit.html b/copy-trade/rate-limit.html index f4d3d4cfed..e3a99fa16b 100644 --- a/copy-trade/rate-limit.html +++ b/copy-trade/rate-limit.html @@ -4,7 +4,7 @@ Rate Limit | Bybit API Documentation - + @@ -15,7 +15,7 @@ in an unexpected violation.

    • GET/POST method (shared):
      • 120 requests per second for 5 consecutive seconds
    note

    All traffic to api.bybit.com or api.bytick.com share this limit regardless of if it accesses Spot, Derivatives or Options.

    After violating the limit your IP will be banned for a set period of time (usually 30 minutes). Continually violating the limit will result in a permanent ban. We cannot undo permanent bans or shorten temporary bans.

    API Rate Limit

    caution

    If you receive "ret_msg": "Too many visits!" in the JSON response, you have hit the API rate limit.

    The API rate limit is based on the rolling time window per minute and UID. In other words, it is per minute per UID. Every request to the API returns response header shown in the code panel:

    • X-Bapi-Limit-Status - your remaining requests for current endpoint
    • X-Bapi-Limit - your current limit for current endpoint
    • X-Bapi-Limit-Reset-Timestamp - the timestamp indicating when your request limit resets if you have exceeded your rate_limit. Otherwise, this is just the current timestamp.

    Http Response Header Example

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    API Rate Limit Table

    PathLimitConsume
    /contract/v3/private/copytrading/position/set-leverage75 req/min1/request
    /contract/v3/private/copytrading/position/close1/request
    /contract/v3/private/copytrading/position/list1/request
    /contract/v3/private/copytrading/order/create100 req/min1/request
    /contract/v3/private/copytrading/order/close1/request
    /contract/v3/private/copytrading/order/cancel1/request
    /contract/v3/private/copytrading/order/list 1/request
    /contract/v3/private/copytrading/wallet/balance120 req/min1/request
    /contract/v3/private/copytrading/wallet/transfer1/request

    How to increase API Limit

    Please email api@bybit.com with the following information. We will reply within 1-4 working days:

    1. Your name and your company details
    2. Your Bybit UID or registered email, and the assets you are trading
    3. General description of your trading strategy and reasons for higher rate limits
    4. Screenshot of previous monthly trading volume (maker/taker) on other platforms
    5. Optional: your order history in CSV format
    - + \ No newline at end of file diff --git a/copy-trade/trade/cancel.html b/copy-trade/trade/cancel.html index 85e98db9a7..f91b91b3b3 100644 --- a/copy-trade/trade/cancel.html +++ b/copy-trade/trade/cancel.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    Cancel Order

    HTTP Request

    POST /contract/v3/private/copytrading/order/cancel

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringsymbol
    orderIdfalsestringOrder ID. Either passing orderId or orderLinkId
    orderLinkIdfalsestringUnique user-set order ID. Maximum length of 36 characters. Either passing orderId or orderLinkId

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/cancel' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"orderId": "a4f60d8d-2957-46cb-9fff-126367e7fdc6"}'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": ""
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/trade/close-order.html b/copy-trade/trade/close-order.html index f971eece51..1bfe12e99f 100644 --- a/copy-trade/trade/close-order.html +++ b/copy-trade/trade/close-order.html @@ -4,13 +4,13 @@ Create Close Position Order | Bybit API Documentation - +

    Create Close Position Order

    Create a specific close order

    HTTP Request

    POST /contract/v3/private/copytrading/order/close

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol
    orderLinkIdfalsestringUnique user-set order ID. Maximum length of 36 characters
    parentOrderIdfalsestringRequired if not passing parentOrderLinkId
    parentOrderLinkIdfalsestringRequired if not passing parentOrderId

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/close' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","parentOrderId":"cf252fd5-f25f-4623-9080-c60201b22575"}'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": ""
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/trade/create-order.html b/copy-trade/trade/create-order.html index 692fe1ca9b..4acfdfa420 100644 --- a/copy-trade/trade/create-order.html +++ b/copy-trade/trade/create-order.html @@ -4,13 +4,13 @@ Create Order | Bybit API Documentation - +

    Create Order

    Create Order

    HTTP Request

    POST /contract/v3/private/copytrading/order/create

    Request Parameters

    ParameterRequiredTypeComments
    sidetruestringSide
    symboltruestringSymbol
    orderTypetruestringActive order type
    qtytruestringOrder quantity
    pricefalsestringOrder price
    takeProfitfalsestringTake profit price
    stopLossfalsestringStop loss price
    tpTriggerByfalsestringType of take-profit activation price, LastPrice by default
    slTriggerByfalsestringType of stop-loss activation price, LastPrice by default
    orderLinkIdfalsestringUnique user-set order ID. Maximum length of 36 characters

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/create' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json; charset=utf-8' \
    --data-raw '{"side":"Sell","symbol":"BTCUSDT","orderType":"Limit","qty":"0.001","price":"20000","takeProfit":"0","stopLoss":"0","tpTriggerBy":"LastPrice","slTriggerBy":"LastPrice"}'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": "234590fe-016c-44f6-fg78"
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/trade/get-order.html b/copy-trade/trade/get-order.html index cfba119978..0c7ba16b57 100644 --- a/copy-trade/trade/get-order.html +++ b/copy-trade/trade/get-order.html @@ -4,13 +4,13 @@ Get Orders | Bybit API Documentation - +

    Get Orders

    Query orders

    HTTP Request

    GET /contract/v3/private/copytrading/order/list

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol
    orderIdfalsestringOrder Id
    orderLinkIdfalsestringUnique user-set order ID. Maximum length of 36 characters
    copyTradeOrderTypefalsestringCopyTrading order type

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder Id
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters
    symbolstringSymbol
    sidestringSide
    pricestringOrder price
    qtystringOrder quantity in USD
    timeInForcestringTime in force
    isIsolatedbooleantrue means isolated margin mode; false means cross margin mode
    leveragestringIn Isolated Margin mode, the value is set by the user. In Cross Margin mode, the value is the max leverage at current risk level
    copyTradeOrderStatusstringCopy trade order type
    leavesQtystringNumber of unfilled contracts from the order's size
    leavesValuestringThe estimated value corresponding to the number of remaining orders
    cumExecValuestringCumulative value of trading
    cumExecFeestringCumulative trading fees
    takeProfitstringTake profit price
    stopLossstringStop loss price
    tpTriggerBystringType of take-profit activation price, LastPrice by default.
    slTriggerBystringType of stop-loss activation price, LastPrice by default.
    createdTimestringCreation time (when the order_status was Created)
    updatedTimestringUpdate time

    Request Example

    curl "https://api-testnet.bybit.com/contract/v3/private/copytrading/order/list?api_key={api_key}&timestamp={timestamp}&sign={sign}&symbol=ETHUSDT"

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "orderId": "ae0700f6-c990-4de5-9d6e-0fdf8d5aabea",
    "symbol": "ETHUSDT",
    "orderLinkId": "234500f6-c45f-4de5-9d6e",
    "side": "Sell",
    "copyTradeOrderStatus": "New",
    "price": "4000.00",
    "qty": "5.55",
    "timeInForce": "GoodTillCancel",
    "leavesQty": "5.55",
    "isIsolated": true,
    "leavesValue": "22200",
    "leverage": "44",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "createdTime": "1652216213331",
    "updatedTime": "1652216213365"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/trade/trading-stop.html b/copy-trade/trade/trading-stop.html index f1c3499ae5..a13477a349 100644 --- a/copy-trade/trade/trading-stop.html +++ b/copy-trade/trade/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +

    Set Trading Stop

    Set Trading Stop

    HTTP Request

    POST /contract/v3/private/copytrading/order/trading-stop

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol
    parentOrderIdtruestringparentOrderId
    takeProfitfalsestringTake profit price
    stopLossfalsestringStop loss price
    tpTriggerByfalsestringType of take-profit activation price
    slTriggerByfalsestringType of stop-loss activation price
    parentOrderLinkIdfalsestringparentOrderLinkID

    Response Parameters

    None

    Request Example

    curl --location --request POST 'https://api.bybit.com/contract/v3/private/copytrading/order/trading-stop' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662026807816' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "parentOrderId": "XXXXXXXX",
    "takeProfit": "0",
    "stopLoss": "0",
    "tpTriggerBy": "MarkPrice",
    "slTriggerBy": "LastPrice",
    "parentOrderLinkId": "XXXXXXXX"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {}
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-private/execution.html b/copy-trade/ws-private/execution.html index dfa1c80bac..774c72fd7b 100644 --- a/copy-trade/ws-private/execution.html +++ b/copy-trade/ws-private/execution.html @@ -4,14 +4,14 @@ Execution | Bybit API Documentation - +

    Execution

    Topic:
    copyTradeExecution

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder Id
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters
    symbolstringSymbol
    sidestringSide
    execIdstringTransaction ID
    execQtystringTransaction qty
    execTypestringExecution type (cannot be Funding)
    execFeestringTransaction fee
    pricestringTransaction price
    orderQtystringOrder qty
    tradeTimenumberTransaction timestamp

    Request Example

    ws.send('{"op": "subscribe", "args": ["copyTradeExecution"]}')

    Response Example

    {
    "topic": "copyTradeExecution",
    "data": [
    {
    "orderId": "6d667921-3cf4-4efd-b93f-727bd10a3b62",
    "orderLinkId": "w11a313223ddd132111",
    "symbol": "ETHUSDT",
    "side": "Sell",
    "execId": "0182b08b-a3ce-5038-a8be-5e1e9f862e90",
    "execQty": "0.010000",
    "execType": "Trade",
    "execFee": "0.01175970",
    "price": "1863.250000",
    "orderQty": "0.010000",
    "tradeTime": 1652932133873
    }
    ]
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-private/order.html b/copy-trade/ws-private/order.html index 2444012b37..f9132bc24c 100644 --- a/copy-trade/ws-private/order.html +++ b/copy-trade/ws-private/order.html @@ -4,14 +4,14 @@ Order | Bybit API Documentation - +

    Order

    Topic:
    copyTradeOrder

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder Id
    orderLinkIdstringUnique user-set order ID. Maximum length of 36 characters
    symbolstringSymbol
    orderTypestringConditional order type
    pricestringOrder price
    qtystringTransaction qty
    sidestringSide
    positionIdxstringPosition idx, used to identify positions in different position modes: 1-Buy side of both side mode; 2-Sell side of both side mode
    cumExecFeestringCumulative trading fees
    cumExecValuestringCumulative value of trading
    lastExecPricestringLast execution price
    cumExecQtystringCumulative qty of trading
    takeProfitstringTake profit price
    stopLossstringStop loss price
    tpTriggerBystringType of take-profit activation price, LastPrice by default.
    slTriggerBystringType of stop-loss activation price, LastPrice by default.
    createTimenumberCommission time
    updateTimenumberUpdate time
    copyTradeOrderStatusstringCopy trade order status

    Request Example

    ws.send('{"op": "subscribe", "args": ["copyTradeOrder"]}')

    Response Example

    {
    "topic": "copyTradeOrder",
    "data": [
    {
    "orderId": "6d667921-3cf4-4efd-b93f-727bd10a3b62",
    "orderLinkId": "w11a313223ddd132111",
    "symbol": "ETHUSDT",
    "orderType": "Market",
    "price": "1863.250000",
    "qty": "0.010000",
    "side": "Sell",
    "positionIdx": "2",
    "cumExecFee": "0.01175970",
    "cumExecValue": "19.59950000",
    "lastExecPrice": "1959.949951",
    "cumExecQty": "0.010000",
    "takeProfit": "1750",
    "stopLoss": "2000",
    "tpTriggerBy": "LastPrice",
    "slTriggerBy": "LastPrice",
    "createTime": 1652932133873,
    "updateTime": 1652932133892,
    "copyTradeOrderStatus": "OpenOrderFilled"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-private/position.html b/copy-trade/ws-private/position.html index d75687ad69..66cef60b38 100644 --- a/copy-trade/ws-private/position.html +++ b/copy-trade/ws-private/position.html @@ -4,14 +4,14 @@ Position | Bybit API Documentation - +

    Position

    Topic:
    copyTradePosition

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol
    positionIdxstringPosition idx, used to identify positions in different position modes: 1-Buy side of both side mode; 2-Sell side of both side mode
    positionValuestringPosition value
    riskIdintegerRisk ID
    leveragestringIn Isolated Margin mode, the value is set by the user.
    isolatedbooleantrue means isolated margin mode; false means cross margin mode
    sidestringSide
    sizestringPosition qty
    unrealisedPnlstringunrealised pnl
    liqPricestringLiquidation price
    bustPricestringBankruptcy price
    entryPricestringAverage entry price
    positionMarginstringPosition margin
    orderMarginstringPre-occupied order margin
    occClosingFeestringPosition closing fee occupied (your opening fee + expected maximum closing fee)
    cumRealisedPnlstringAccumulated realised pnl (all-time total)
    positionStatusstringPosition status: Normal, Liq, Adl
    positionSeqnumberPosition sequence

    Request Example

    ws.send('{"op": "subscribe", "args": ["copyTradePosition"]}')

    Response Example

    {
    "topic": "copyTradePosition",
    "data": [
    {
    "symbol": "ETHUSDT",
    "positionIdx": "2",
    "positionValue": "80.05065626",
    "riskId": 11,
    "leverage": "10.000000",
    "isIsolated": true,
    "side": "Sell",
    "size": "0.040000",
    "unrealisedPnl": "1.62665626",
    "liqPrice": "2191.350098",
    "bustPrice": "2201.350098",
    "entryPrice": "2001.26640650",
    "positionMargin": "8.00506666",
    "orderMargin": "0.00000000",
    "occClosingFee": "0.05283240",
    "cumRealisedPnl": "0.55284374",
    "positionStatus": "Normal",
    "positionSeq": 0
    }
    ]
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-private/wallet.html b/copy-trade/ws-private/wallet.html index 59701bf0fb..53cb76a75c 100644 --- a/copy-trade/ws-private/wallet.html +++ b/copy-trade/ws-private/wallet.html @@ -4,14 +4,14 @@ Wallet | Bybit API Documentation - +

    Wallet

    Topic:
    copyTradeWallet

    Response Parameters

    ParameterTypeComments
    walletBalancenumberWallet balance
    availableBalancenumberAvailable balance = wallet balance - used margin

    Request Example

    ws.send('{"op": "subscribe", "args": ["copyTradeWallet"]}')

    Response Example

    {
    "topic": "copyTradeWallet",
    "data": {
    "walletBalance": "14009.12164704",
    "availableBalance": "13998.97749271"
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-public/kline.html b/copy-trade/ws-public/kline.html index 5013026e83..e3d895f207 100644 --- a/copy-trade/ws-public/kline.html +++ b/copy-trade/ws-public/kline.html @@ -4,14 +4,14 @@ Kline | Bybit API Documentation - +

    Kline

    Interval supported:

    • 1 3 5 15 30 60 120 240 360 720minute
    • Dday
    • Wweek
    • Mmonth
    info

    If confirm is true, then the data is a final tick for this interval. Otherwise, it is a snapshot.

    Push frequency: 1-60s

    Topic: kline.{interval}.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject
    > startnumberCandle start timestamp (ms)
    > endnumberCandle end timestamp (ms)
    > intervalstringInterval
    > openstringOpen price
    > closestringClose price. If not closed, it is last price
    > highstringHighest price
    > lowstringLowest price
    > volumestringTrading volume
    > turnoverstringTrading turnover
    > confirmbooleantrue: last tick. false: this is snapshot data
    > timestampnumberThe timestamp (ms) of the last matched order in the candle

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "kline.5.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "kline.5.BTCUSDT",
    "data": [
    {
    "start": 1671187800000,
    "end": 1671188099999,
    "interval": "5",
    "open": "16991",
    "close": "16980.5",
    "high": "16991",
    "low": "16980.5",
    "volume": "2.501",
    "turnover": "42493.2305",
    "confirm": false,
    "timestamp": 1671187815755
    }
    ],
    "ts": 1671187815755,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-public/liquidation.html b/copy-trade/ws-public/liquidation.html index 403cc19f05..f54e31bb98 100644 --- a/copy-trade/ws-public/liquidation.html +++ b/copy-trade/ws-public/liquidation.html @@ -4,14 +4,14 @@ Liquidation | Bybit API Documentation - +

    Liquidation

    Get recent liquidation orders in Bybit.

    Push frequency: real-time

    Topic: liquidation.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject
    > updatedTimenumberData updated timestamp (ms)
    > symbolstringSymbol name
    > sizestringFilled size
    > pricestringFilled price
    > sidestringSide

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "liquidation.GALAUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-public/orderbook.html b/copy-trade/ws-public/orderbook.html index 08014845f5..5268a6bee2 100644 --- a/copy-trade/ws-public/orderbook.html +++ b/copy-trade/ws-public/orderbook.html @@ -4,14 +4,14 @@ Orderbook | Bybit API Documentation - +

    Orderbook

    Get different depth

    info
    • Once subscribe successfully, you will receive a snapshot first.
    • The data is sort by order price, which bids is from highest to lowest and asks is from lowest to highest
    • Websocket will keep pushing delta message when orderbook is changed.
    • If you receive a new snapshot data, it is necessary to reset your local orderbook.
    • If there is a problem in bybit end, it will re-send a snapshot, which is promised the latest and accurate.
    tip

    Level 1 data: if 3 seconds have elapsed without a change in the orderbook, a snapshot message will be pushed again.

    • Level 1 data, push frequency: 10ms
    • Level 50 data, push frequency: 20ms
    • Level 200 data, push frequency: 100ms

    Topic:
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot,delta
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > sStringSymbol name
    > barray<array>Bid array
    >> b[0][0]stringBid price
    >> b[0][1]stringBid size
    > sarray<array>Ask array
    >> s[0][0]stringAsk price
    >> s[0][1]stringAsk size
    > unumberUpdate id, is always in sequence. Occasionally, you'll receive "u"=1, which is a snapshot data due to the restart of the service. So please overwrite the locally saved orderbook
    > seqnumberCross sequence (internal value)

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "orderbook.50.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1671179923028,
    "data": {
    "s": "BTCUSDT",
    "b": [
    [
    "17440.00",
    "40.833"
    ],
    [
    "17439.50",
    "0.513"
    ],
    ...
    [
    "17416.00",
    "6.156"
    ],
    [
    "17415.50",
    "32.268"
    ]
    ],
    "a": [
    [
    "17440.50",
    "78.815"
    ],
    [
    "17441.00",
    "8.858"
    ],
    ...
    [
    "17464.50",
    "4.901"
    ],
    [
    "17465.00",
    "5.744"
    ]
    ],
    "u": 13079592,
    "seq": 22520573250
    }
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-public/ticker.html b/copy-trade/ws-public/ticker.html index 455547c5d4..9bde7d7427 100644 --- a/copy-trade/ws-public/ticker.html +++ b/copy-trade/ws-public/ticker.html @@ -4,14 +4,14 @@ Tickers | Bybit API Documentation - +

    Tickers

    Get latest information of the symbol

    important

    Have snapshot and delta types. If a key does not exist in the field, it means the value is not changed.

    Push frequency: real-time

    Topic: tickers.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot,delta
    csintegerCross sequence
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > symbolstringSymbol name
    > tickDirectionstringTick direction
    > price24hPcntstringPercentage change of market price in the last 24 hours
    > lastPricestringLast price
    > prevPrice24hstringMarket price 24 hours ago
    > highPrice24hstringThe highest price in the last 24 hours
    > lowPrice24hstringThe lowest price in the last 24 hours
    > prevPrice1hstringMarket price an hour ago
    > markPricestringMark price
    > indexPricestringIndex price
    > openIntereststringOpen interest size
    > openInterestValuestringOpen interest value
    > turnover24hstringTurnover for 24h
    > volume24hstringVolume for 24h
    > nextFundingTimestringNext funding timestamp (ms)
    > fundingRatestringFunding rate
    > bid1PricestringBest bid price
    > bid1SizestringBest bid size
    > ask1PricestringBest ask price
    > ask1SizestringBest ask size

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "tickers.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "MinusTick",
    "price24hPcnt": "0.017367",
    "lastPrice": "17222.00",
    "prevPrice24h": "16928.00",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17224.40",
    "indexPrice": "17234.84",
    "openInterest": "68795.534",
    "openInterestValue": "1184961795.83",
    "turnover24h": "1572429119.324499",
    "volume24h": "91823.449",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000211",
    "bid1Price": "17222.00",
    "bid1Size": "220.358",
    "ask1Price": "17222.50",
    "ask1Size": "3.902"
    },
    "cs": 24988405605,
    "ts": 1673273043686
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws-public/trade.html b/copy-trade/ws-public/trade.html index 0731374afc..07105a2c6a 100644 --- a/copy-trade/ws-public/trade.html +++ b/copy-trade/ws-public/trade.html @@ -4,14 +4,14 @@ Public Trade | Bybit API Documentation - +

    Public Trade

    Get recent public trades data in Bybit.

    info

    After subscription, you will be pushed delta trade message in real-time once there is an order filled.

    Push frequency: real-time

    Topic: publicTrade.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject
    > TnumberThe timestamp (ms) that the order is filled
    > sstringSymbol name
    > SstringDirection of taker. Buy,Sell
    > vstringqty
    > pstringExecuted price
    > LstringDirection of price change
    > istringTrade id
    > BTbooleanBlock trade or not

    Request Example

    {
    "op": "subscribe",
    "args": [
    "publicTrade.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Response Example

    {
    "topic": "publicTrade.BTCUSDT",
    "type": "snapshot",
    "ts": 1671181689023,
    "data": [
    {
    "T": 1671181689021,
    "s": "BTCUSDT",
    "S": "Buy",
    "v": "0.002",
    "p": "17032.50",
    "L": "MinusTick",
    "i": "d9cd8295-40dc-5dce-8deb-42882580a7ab",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/copy-trade/ws/connect.html b/copy-trade/ws/connect.html index 5ae17399bf..99d4b7e1b0 100644 --- a/copy-trade/ws/connect.html +++ b/copy-trade/ws/connect.html @@ -4,13 +4,13 @@ Connect | Bybit API Documentation - +

    Connect

    caution

    Note that currently Copy Trading only supports USDT perpetual and the following endpoints only apply to USDT Perpetual

    Base endpoints:

    • Testnet:
      • Public Channel: wss://stream-testnet.bybit.com/contract/usdt/public/v3
      • Private Channel: wss://stream-testnet.bybit.com/realtime_private
    • Mainnet:
      • Public Channel: wss://stream.bybit.com/contract/usdt/public/v3
      • Private Channel: wss://stream.bybit.com/realtime_private
    info
    Public channel do not require authentication. The following section applies to private channel only.

    Apply for authentication when establishing a connection.

    Note: if you're using pybit, bybit-api, or another high-level library, you can ignore this code - as authentication is handled for you.

    {
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //expires; is greater than your current timestamp
    "singature"
    ]
    }
    # based on: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    The response sample of authentication success

    {
    "success": true,
    "ret_msg": "",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "auth",
    "args": [
    "OZUDHROKUZZNVZWHKN",
    "1673261297304",
    "63ae5f1064130d8e931b5d937500461b87c00b2a939284e455fe8ea1e27387f6"
    ]
    }
    }
    info

    Example signature algorithms can be found here.

    caution

    Due to network complexity, your may get disconnected at any time. Please follow the instructions below to ensure that you receive WebSocket messages on time:

    1. Keep connection alive by sending heartbeat packet
    2. Reconnect as soon as possible if disconnected

    IP Limits

    • Do not frequently connect and disconnect the connection.
    • Do not build over 500 connections in 5 minutes. This is counted separately per WebSocket endpoint.

    How to Send Heartbeat Packet

    How to Send

    ws.send('{"op":"ping"}');

    Pong response Example

    // Pong example of public channel
    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "13271fcb-53ed-4e80-948e-2bdbe3a6587d",
    "req_id": "",
    "op": "ping"
    }
    // Pong example of private channel
    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "ping",
    "args": null
    }
    }
    caution

    To avoid networks or program issues, we recommend that you send the ping heartbeat packet every 20 seconds to maintain the WebSocket connection.

    How to Subscribe to Topics

    Understanding Websocket Filters

    How to subscribe with a filter

    // Subscribing level 1 orderbook
    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    Support subscribe multiple symbols and topics, separate with ','.

    // Example: Subscribing to the trade data for BTCUSDT and ETHUSDT
    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "publicTrade.BTCUSDT",
    "publicTrade.ETHUSDT"
    ]
    }

    After establishing the connection, you can subscribe to a new topic by sending a JSON request. The request formats are as follows:

    ws.send('{"op": "subscribe", "args": ["orderbook.1.BTCUSDT","publicTrade.BTCUSDT","orderbook.1.ETHUSDT]}')

    Understanding Websocket Filters unsubscription

    After successful subscription, you can unsubscribe by sending a JSON request. The request formats are as follows:

    ws.send('{"op": "unsubscribe", "args": ["publicTrade.BTCUSDT"]}');
    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.BTCUSDT"
    ]
    }

    Understanding Subscription Response

    Subscription Response

    // Subscription response of public channel
    {
    "success": true,
    "ret_msg": "",
    "conn_id": "322b49ce-d6a5-494a-9019-f1d51cd541ae",
    "req_id": "",
    "op": "subscribe"
    }
    // Subscription response of private channel
    {
    "success": true,
    "ret_msg": "",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "subscribe",
    "args": [
    "copyTradePosition",
    "copyTradeOrder",
    "copyTradeExecution"
    ]
    }
    }

    Once you subscribe successfully, you'd receive result information. You can determine whether the subscription is successful based on the response.

    - + \ No newline at end of file diff --git a/copy_trading.html b/copy_trading.html index c6dea4a907..5c197886b2 100644 --- a/copy_trading.html +++ b/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/copytrade/public/instrument-info.html b/copytrade/public/instrument-info.html index 70ca9f96e5..1e8bcff122 100644 --- a/copytrade/public/instrument-info.html +++ b/copytrade/public/instrument-info.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +

    Instrument Info

    Get the spec of trading symbols

    tip

    This is public endpoint, so it does not need authentication

    HTTP Request

    GET /contract/v3/public/copytrading/symbol/list

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringsymbol
    > baseCurrencystringBase currency
    > quoteCurrencystringQuote currency
    > priceScalestringPrice scale (the number of decimal places to which a price can be submitted, although the final price may be rounded to conform to the tick_size)
    > takerFeestringTaker fee
    > makerFeestringMaker fee
    > fundingIntervalstringFunding fee interval
    > leverageFilterObjectLeverage attributes
    >> maxLeveragestringMax leverage (indicates the max leverage, assuming the lowest risk limit setting)
    >> minLeveragestringMin leverage
    > priceFilterObjectPrice attributes
    >> minPricestringMin price
    >> maxPricestringMax price
    >> tickSizestringTick size
    > lotSizeFilterObjectOrder attributes
    >> qtyStepstringQty step
    >> maxOrderQtystringMax trading quantity
    >> minOrderQtystringMin trading quantity

    Request Example

    curl https://api-testnet.bybit.com/contract/v3/public/copytrading/symbol/list

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "baseCurrency": "BTC",
    "quoteCurrency": "USDT",
    "priceScale": "1",
    "takerFee": "0.00075",
    "makerFee": "-0.00025",
    "fundingInterval": "480",
    "leverageFilter": {
    "maxLeverage": "100",
    "minLeverage": "1"
    },
    "priceFilter": {
    "minPrice": "0.5",
    "maxPrice": "999999.0",
    "tickSize": "0.5"
    },
    "lotSizeFilter": {
    "qtyStep": "0.001",
    "maxOrderQty": "100.000",
    "minOrderQty": "0.001"
    }
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/auto-margin.html b/derivatives/contract/auto-margin.html index 71c9792ea6..a6b861b72d 100644 --- a/derivatives/contract/auto-margin.html +++ b/derivatives/contract/auto-margin.html @@ -4,13 +4,13 @@ Set Auto Add Margin | Bybit API Documentation - +

    Set Auto Add Margin

    Turn on/off auto add position margin. To understand more, please read here

    tip

    This functionality only supports USDT Perpetual.

    HTTP Request

    POST /contract/v3/private/position/set-auto-add-margin

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    sidetruestringSide. Buy,Sell
    autoAddMargintrueintegerTurn on/off auto add margin. 0: off. 1: on
    positionIdxtrueintegerPosition index

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/set-auto-add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670826151188
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "ETHUSDT",
    "side": "Buy",
    "autoAddMargin": 1,
    "positionIdx": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670826151500
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/cancel-all.html b/derivatives/contract/cancel-all.html index 3d7b388404..c09ec49b24 100644 --- a/derivatives/contract/cancel-all.html +++ b/derivatives/contract/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Order | Bybit API Documentation - +

    Cancel All Order

    This endpoint enables to cancel all open orders.

    tip

    One of param baseCoin, settleCoin, symbol must be passed.

    HTTP Request

    POST /contract/v3/private/order/cancel-all

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name
    baseCoinfalsestringCancel all open orders by base coin
    settleCoinfalsestringCancel all open orders by settle coin

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id

    Request Example

    POST /contract/v3/private/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670571959925
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "settleCoin": "USDT",
    "symbol": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "4545cab5-0f98-45c4-b137-6c42f3b33d4a",
    "orderLinkId": ""
    },
    {
    "orderId": "66c1beaf-aadd-4b36-be37-7f80ec315422",
    "orderLinkId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670571961179
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/cancel.html b/derivatives/contract/cancel.html index d353722c65..93da822970 100644 --- a/derivatives/contract/cancel.html +++ b/derivatives/contract/cancel.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    note

    You could cancel those unfilled or partially filled orders.

    HTTP Request

    POST /contract/v3/private/order/cancel

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    POST /contract/v3/private/order/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670570871662
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "BTCUSDT",
    "orderLinkId": null,
    "orderId": "a0c76874-1777-48dd-9f99-b4120ec71cc0"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "a0c76874-1777-48dd-9f99-b4120ec71cc0",
    "orderLinkId": "xrp_12"
    },
    "retExtInfo": {},
    "time": 1670570872075
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/closepnl.html b/derivatives/contract/closepnl.html index 9621fe3f8a..8b3d0e3284 100644 --- a/derivatives/contract/closepnl.html +++ b/derivatives/contract/closepnl.html @@ -4,13 +4,13 @@ Get Closed PnL | Bybit API Documentation - +

    Get Closed PnL

    Query user's closed profit and loss records. The results are sorted by createdAt in descending order.

    info

    Support USDT Perpetual, Inverse Perpetual and Inverse Future

    Query time range:

    • Specify startTime and endTime, you can query up to 2 years records
    • Without startTime and endTime, it returns past 6 months records by default

    HTTP Request

    GET /contract/v3/private/position/closed-pnl

    Request Parameters

    ParameterRequiredTypeComments
    symboltruetrueSymbol name
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder Id
    > sidestringBuy, Side
    > qtystringOrder qty
    > leveragestringleverage
    > orderPricestringOrder price
    > orderTypestringOrder type. Market,Limit
    > execTypestringExec type
    > closedSizestringClosed size
    > cumEntryValuestringCumulated entry position value
    > avgEntryPricestringAverage entry price
    > cumExitValuestringCumulated exit position value
    > avgExitPricestringAverage exit price
    > closedPnlstringClosed PnL
    > fillCountstringThe number of fills in a single order
    > createdAtstringThe created time (ms), same as createdTime
    > createdTimestringThe created time (ms), same as createdAt
    > updatedTimestringThe updated time (ms)
    nextPageCursorstringCursor. Used to pagination

    Request Example

    GET /contract/v3/private/position/closed-pnl?symbol=ETHUSDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670855140626
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "orderId": "ee650123-74bf-4094-aadb-efa139d99c50",
    "side": "Buy",
    "qty": "0.30",
    "orderPrice": "1314.75",
    "orderType": "Market",
    "execType": "Trade",
    "closedSize": "0.30",
    "cumEntryValue": "373.71078947",
    "avgEntryPrice": "1245.7026",
    "cumExitValue": "375.532",
    "avgExitPrice": "1251.7734",
    "closedPnl": "-2.27050237",
    "fillCount": "2",
    "leverage": "50",
    "createdAt": "1670838034412",
    "createdTime": "1670838034412",
    "updatedTime": "1670838034450"
    }
    ],
    "nextPageCursor": "eyJza2lwX2xvY2FsX3N5bWJvbCI6ZmFsc2UsInBhZ2VfdG9rZW4iOiJleUpOSWpwN0lsOTFjM2N4WHlJNmV5SkNJam9pUVRnMlZFcEJSVWRCVVVVOUluMHNJbkJySWpwN0lrSWlPaUpLUjFac1RtcFZkMDFVU1hwTVZHTXdXVzFaZEU1RVFUVk9RekZvV1ZkU2FVeFhWbTFaVkVWNlQxZFJOVTlYVFRGTlFUMDlJbjBzSWw5emExOGlPbnNpUWlJNklrWjZRVU5XZGpWcVkyTXlSblJoTTJSQlp6MDlJbjE5ZlE9PSJ9"
    },
    "retExtInfo": {},
    "time": 1670855140831
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/confirm-mmr.html b/derivatives/contract/confirm-mmr.html index 65e8654721..3010893104 100644 --- a/derivatives/contract/confirm-mmr.html +++ b/derivatives/contract/confirm-mmr.html @@ -4,7 +4,7 @@ Confirm New Risk Limit | Bybit API Documentation - + @@ -13,7 +13,7 @@ the Get Position Info interface). After the user actively adjusts the risk level, this interface is called to try to calculate the adjusted risk level, and if it passes (retCode=0), the system will remove the position reduceOnly mark. You are recommended to call Get Position Info to check isReduceOnly field.

    HTTP Request

    POST /contract/v3/private/position/confirm-pending-mmr

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/confirm-pending-mmr HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698051546759
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 32

    {

    "symbol": "BTCUSDT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698051124588
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/cross-isolated.html b/derivatives/contract/cross-isolated.html index f3e1060c1a..7dd1d2283a 100644 --- a/derivatives/contract/cross-isolated.html +++ b/derivatives/contract/cross-isolated.html @@ -4,13 +4,13 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +

    Switch Cross/Isolated Margin

    Switch cross margin mode / isolated margin mode. To understand more, please read here

    info

    Support USDT Perpetual, Inverse Perpetual and Inverse Future.

    HTTP Request

    POST /contract/v3/private/position/switch-isolated

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    tradeModetrueinteger0: cross margin. 1: isolated margin
    buyLeveragetruestringBuy side leverage. Make sure buyLeverage equals to sellLeverage
    sellLeveragetruestringSell side leverage. Make sure buyLeverage equals to sellLeverage

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/switch-isolated HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670848559156
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSDT",
    "tradeMode": 1,
    "buyLeverage": "8",
    "sellLeverage": "8"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670848559569
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/execution-list.html b/derivatives/contract/execution-list.html index 8a7f4c541e..f680758189 100644 --- a/derivatives/contract/execution-list.html +++ b/derivatives/contract/execution-list.html @@ -4,13 +4,13 @@ Get Execution List | Bybit API Documentation - +

    Get Execution List

    Query users' execution list, sort by execTime in descending order. Support USDT Perpetual, Inverse Perpetual, Inverse Future, USDC Perpetual and USDC Option.

    Query time range:

    • USDT perp, Inverse perp, Inverse future: up to 2 years
    tip

    You may have multiple executions in a single order.

    HTTP Request

    GET /contract/v3/private/execution/list

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    orderIdfalsestringOrder ID. Return all records if not passed
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    execTypefalsestringExecution type
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringCursor. Used to pagination
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > orderIdstringOrder id
    > orderLinkIdstringUser customised order id
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > orderTypestringMarket,Limit
    > stopOrderTypestringStop order type
    > execIdstringTrade Id
    > execPricestringExecution price
    > execQtystringExecution qty
    > execFeestringExecution fee
    > execTypestringExecution type
    > execValuestringExecution position value
    > feeRatestringTrading fee rate
    > lastLiquidityIndstringAddedLiquidity, RemovedLiquidity
    > isMakerbooleanIs maker
    > leavesQtystringRemaining qty waiting for execution
    > closedSizestringClose size
    > ivstringImplied volatility
    > blockTradeIdstringBlock trade id
    > markPricestringMark price
    > indexPricestringIndex price
    > markIvstringMark iv
    > underlyingPricestringUnderlying price
    > execTimestringExecution timestamp (ms)

    Request Example

    GET /contract/v3/private/execution/list?symbol=ETHUSDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670853954362
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "execFee": "-0.08720013",
    "execId": "208751d8-f70e-4570-a5fd-d208c82af99d",
    "execPrice": "1263.77",
    "execQty": "0.69",
    "execType": "Funding",
    "execValue": "872.0013",
    "feeRate": "-0.0001",
    "lastLiquidityInd": "UNKNOWN",
    "leavesQty": "0.00",
    "orderId": "1673136000-ETHUSDT-592334-Sell",
    "orderLinkId": "",
    "orderPrice": "0.00",
    "orderQty": "0.00",
    "orderType": "UNKNOWN",
    "stopOrderType": "UNKNOWN",
    "side": "Sell",
    "execTime": "1673136000000",
    "closedSize": "0.00",
    "iv": "",
    "blockTradeId": "",
    "markPrice": "",
    "markIv": "",
    "underlyingPrice": "",
    "indexPrice": "",
    "isMaker": false
    }
    ],
    "nextPageCursor": "ZzU3NlU4M1JlLzhFTWkzeW9hemRVcitqUk4wVW9LL21KVTRWV3JPR0tYTG9uTENWSkFvUDJuWk44OVBlNnB0ZjJHTTFwdlJRV0tpZFM0Z0RzUlQ0d2FSbzVRN2lpZ0ZrZmt2UTZuRlJVSHdQSHdoYXUvdDN6aExzOEpmcDNFY2NLc2dYTnRvOXhmTmY3NVNreVgzQ2RKUFZtekptU0NQNU1rOWd5YzZRV1ZDejVFM0t0MGdlMENNc04ybzQvc2JQQ3BVRkQycHU3MFdBK3RqdFlWaVRkMTNGQmZRUUZpaVc4MkE1SnRCT09iZDRNL2FlNDVSMithdU96NTROWGFxcTFucW1MSnJSaTluM29pZm85dHVkNzJMSVQwODk4UTJLbHEybDJ0Uk9UYmtCcU5ScU9zZWRCa2Znc0dwbmNEOWJoaCtnZkRkWjlrMEl6elRmWnljeHZpYXBPWVdzZSs0UEtvdnZ4cTJHQ2JZcm1UQkU3TXFKS01yU1dmaloyT3pVS1psbmVaamh3N3Ntc0hFbEgwckxtQT09",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1673150404910
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/fee-rate.html b/derivatives/contract/fee-rate.html index e154eaf589..5054a0733d 100644 --- a/derivatives/contract/fee-rate.html +++ b/derivatives/contract/fee-rate.html @@ -4,13 +4,13 @@ Get Trading Fee Rate | Bybit API Documentation - +

    Get Trading Fee Rate

    Get user trading fee rate.

    HTTP Request

    GET /contract/v3/private/account/fee-rate

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol name
    > takerFeeRatestringTaker fee rate
    > makerFeeRatestringMaker fee rate

    Request Example

    GET /contract/v3/private/account/fee-rate?symbol=SOLUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670924049902
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "SOLUSDT",
    "takerFeeRate": "0.0006",
    "makerFeeRate": "0.0001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670924050413
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/leverage.html b/derivatives/contract/leverage.html index 28c4bb46ce..b7c380d3b5 100644 --- a/derivatives/contract/leverage.html +++ b/derivatives/contract/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set the leverage.

    HTTP Request

    POST /contract/v3/private/position/set-leverage

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    buyLeveragetruestring(0, max leverage of corresponding risk limit]. For one-way mode, make sure buyLeverage=sellLeverage
    sellLeveragetruestring(0, max leverage of corresponding risk limit]. For one-way mode, make sure buyLeverage=sellLeverage

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/set-leverage HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670849911829
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSD",
    "buyLeverage":"20",
    "sellLeverage":"20"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670849912024
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/open-order.html b/derivatives/contract/open-order.html index 1f3152d1c8..9e36bc6e28 100644 --- a/derivatives/contract/open-order.html +++ b/derivatives/contract/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    Query unfilled or partially filled orders in real-time.

    tip
    • At most 500 unfilled or partially filled orders will be returned if neither orderId nor orderLinkId is passed.
    • The records are sort by the createdTime from newest to oldest.

    HTTP Request

    GET /contract/v3/private/order/unfilled-orders

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin
    settleCoinfalsestringSettle coin. One of symbol,baseCoin and settleCoin is required. Priority: symbol > baseCoin > settleCoin
    orderIdfalsestringOrder id
    orderLinkIdfalsestringUser customised order id
    orderFilterfalsestringOrder: active order, StopOrder: conditional order
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringCursor. Used to pagination
    listarraystring
    > symbolstringSymbol name
    > orderIdstringOrder id
    > orderLinkIdstringUser customised order id
    > sidestringSide. Buy,Sell
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
    > pricestringOrder price
    > ivstringImplied volatility. Not applicable for future
    > qtystringOrder qty
    > timeInForcestringTime in force
    > orderStatusstringOrder status
    > lastPriceOnCreatedstringLast price when create the order
    > createdTimestringCreated timestamp (ms)
    > updatedTimestringUpdated timestamp (ms)
    > cancelTypestringCancel type
    > stopOrderTypestringStop order type
    > triggerDirectionstring1: rise, 2: fall
    > triggerBystringThe trigger type of trigger price
    > triggerPricestringTrigger price
    > cumExecValuestringCumulative executed position value
    > cumExecFeestringCumulative trading fee
    > cumExecQtystringCumulative executed qty
    > leavesValuestringThe remaining value waiting to be traded
    > leavesQtystringThe remaining quantity waiting to be traded
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringTrigger type of take profit
    > slTriggerBystringTrigger type of stop loss
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution

    Request Example

    GET /contract/v3/private/order/unfilled-orders?symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670564324211
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "806f5fc6-d487-46d1-9a57-4b4964126c90",
    "side": "Buy",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "price": "26864.40",
    "qty": "0.003",
    "timeInForce": "PostOnly",
    "orderStatus": "New",
    "triggerPrice": "0.00",
    "orderLinkId": "YLxaWKMiHU",
    "createdTime": "1684810640078",
    "updatedTime": "1684810640080",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "reduceOnly": false,
    "leavesQty": "0.003",
    "leavesValue": "80.5932",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "triggerDirection": 0,
    "cancelType": "UNKNOWN",
    "lastPriceOnCreated": "",
    "iv": "",
    "closeOnTrigger": false,
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ],
    "nextPageCursor": "",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1684810643363
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/order-list.html b/derivatives/contract/order-list.html index 2e73350e1a..766db3bd08 100644 --- a/derivatives/contract/order-list.html +++ b/derivatives/contract/order-list.html @@ -4,14 +4,14 @@ Get Order List | Bybit API Documentation - +

    Get Order List

    tip

    Query order list.
    As order creation/cancellation is asynchronous, the data returned from this endpoint may delay.

    HTTP Request

    GET /contract/v3/private/order/list

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name
    orderIdfalsestringOrder id
    orderLinkIdfalsestringUser customised order id
    orderStatusfalsestringOrder status. Return all status orders if not passed
    orderFilterfalsestringOrder,StopOrder
    limitfalsestringLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringCursor. Used to pagination
    listlistObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID.
    > sidestringBuy,Sell
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
    > pricestringOrder price
    > ivstringImplied volatility
    > qtystringOrder quantity
    > timeInForcestringTime in force
    > orderStatusstringOrder status
    > positionIdxintegerPosition index. 0: one-way mode, 1: buy side hedge mode, 2: sell side hedge mode
    > lastPriceOnCreatedstringLast price when place the order
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)
    > cancelTypestringCancel type
    > rejectReasonstringReject reason
    > stopOrderTypestringStop order type
    > triggerDirectionstringTrigger direction. 1: rise, 2: fall
    > triggerBystringThe trigger type of trigger price
    > triggerPricestringTrigger price
    > cumExecValuestringCumulative executed order value
    > cumExecFeestringCumulative executed trading fee
    > cumExecQtystringCumulative executed order qty
    > leavesValuestringThe estimated value not executed
    > leavesQtystringThe remaining qty not executed
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringThe price type to trigger take profit
    > slTriggerBystringThe price type to trigger stop loss
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?. Keeps "" for option
    > blockTradeIdstringParadigm block trade ID
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution

    Request Example

    GET /contract/v3/private/order/list?symbol=BTCUSDT&orderId=806f5fc6-d487-46d1-9a57-4b4964126c90 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673420679798
    X-BAPI-RECV-WINDOW: 5000
    cdn-request-id: test-10

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "price": "26864.40",
    "qty": "0.003",
    "reduceOnly": false,
    "timeInForce": "PostOnly",
    "orderStatus": "Cancelled",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "lastPriceOnCreated": "0.00",
    "rejectReason": "EC_PerCancelRequest",
    "orderLinkId": "YLxaWKMiHU",
    "createdTime": "1684810640078",
    "updatedTime": "1684810770380",
    "orderId": "806f5fc6-d487-46d1-9a57-4b4964126c90",
    "stopOrderType": "UNKNOWN",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerPrice": "0.00",
    "closeOnTrigger": false,
    "triggerDirection": 0,
    "positionIdx": 1,
    "cancelType": "CancelByUser",
    "iv": "",
    "triggerBy": "UNKNOWN",
    "blockTradeId": "",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ],
    "nextPageCursor": "eyJza2lwX2xvY2FsX3N5bWJvbCI6ZmFsc2UsInBhZ2VfdG9rZW4iOiIzOTQ3NCJ9",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1684810802126
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/place-order.html b/derivatives/contract/place-order.html index cdf5241728..25166a7bce 100644 --- a/derivatives/contract/place-order.html +++ b/derivatives/contract/place-order.html @@ -4,7 +4,7 @@ Place Order | Bybit API Documentation - + @@ -20,7 +20,7 @@ ID to cancel active orders. Meanwhile, your customized order ID should be no longer than 36 characters and should be unique.

  • Each account can hold a maximum of 500 active orders simultaneously. This is contract-specific, so the following situation is allowed: The same account can hold 300 BTCUSD active orders and 280 ETHUSD active orders at the same time. When the upper limit of orders is reached, you can still place orders with parameters of reduceOnly or closeOnTrigger.

  • HTTP Request

    POST /contract/v3/private/order/create

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    sidetruestringBuy,Sell
    orderTypetruestringMarket, Limit
    qtytruestringOrder quantity
    timeInForcetruestringRead more about Time in force.
    pricefalsestringOrder price. Invalid if orderType=Market
    triggerDirectionfalseintegerConditional order param. Used to identify the expected direction of the conditional order.
    • 1: triggered when market price rises to triggerPrice
    • 2: triggered when market price falls to triggerPrice
    triggerPricefalsestringConditional order param. If you expect the price to rise to trigger your conditional order, make sure:
    triggerPrice > market price
    Else, triggerPrice < market price
    triggerByfalsestringTrigger price type. default:LastPrice.
    positionIdxfalseintegerPosition index. It is required for hedge position mode
    orderLinkIdfalsestringUser customised order id. A max of 36 characters. Combinations of numbers, letters (upper and lower cases), dashes, and underscores are supported.
    rule of future:
    • optional param
    • The same orderLinkId can be used for both USDC PERP and USDT PERP.
    • An orderLinkId can be reused once the original order is either Filled or Cancelled
    • rule of option:
    • This param is required
    • always unique
    takeProfitfalsestringTake profit price
    stopLossfalsestringStop loss price
    tpTriggerByfalsestringThe price type to trigger take profit. default:LastPrice
    slTriggerByfalsestringThe price type to trigger stop loss. default:LastPrice
    reduceOnlyfalsebooleanWhat is a reduce-only order? true means your position can only reduce in size if this order is triggered. When reduce_only is true, take profit/stop loss cannot be set
    smpTypefalsestringSmp execution type. What is SMP?
    closeOnTriggerfalsebooleanWhat is a close on trigger order? For a closing order. It can only reduce your position, not increase it. If the account has insufficient available balance when the closing order is triggered, then other active orders of similar contracts will be cancelled or reduced. It can be used to ensure your stop loss reduces your position regardless of current available margin.
    tpslModefalsestringTP/SL mode
    • Full: entire position for TP/SL. Then, tpOrderType or slOrderType must be Market
    • Partial: partial position tp/sl. Limit TP/SL order are supported. Note: When create limit tp/sl, tpslMode is required and it must be Partial
    tpLimitPricefalsestringThe limit order price when take profit price is triggered. Only works when tpslMode=Partial and tpOrderType=Limit
    slLimitPricefalsestringThe limit order price when stop loss price is triggered. Only works when tpslMode=Partial and slOrderType=Limit
    tpOrderTypefalsestringThe order type when take profit is triggered. Market(default), Limit. For tpslMode=Full, it only supports tpOrderType=Market
    slOrderTypefalsestringThe order type when stop loss is triggered. Market(default), Limit. For tpslMode=Full, it only supports slOrderType=Market

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    POST /contract/v3/private/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670487164902
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json; charset=utf-8
    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "qty": "0.05",
    "price": "18500",
    "timeInForce": "GoodTillCancel",
    "positionIdx": null,
    "triggerDirection": 1,
    "triggerPrice": "19000"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "0cf62262-7dc2-4503-9566-8835c841509b",
    "orderLinkId": ""
    },
    "retExtInfo": {},
    "time": 1670486764551
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/position-list.html b/derivatives/contract/position-list.html index e1d4b5f31c..3fec332ff5 100644 --- a/derivatives/contract/position-list.html +++ b/derivatives/contract/position-list.html @@ -4,13 +4,13 @@ My Position | Bybit API Documentation - +

    My Position

    Get real-time position data

    HTTP Request

    GET /contract/v3/private/position/list

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name
    settleCoinfalsestringSettle coin. Either symbol or settleCoin is required. symbol has a higher priority

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringCursor. Used to pagination
    listarrayObject
    > symbolstringSymbol name
    > sidestringSide. Buy, Sell. Return None when zero position of one-way mode
    > sizestringPosition size
    > entryPricestringEntry price
    > leveragestringleverage
    > positionValuestringPosition value
    > positionIdxintegerPosition index
    > riskIdintegerRisk limit id
    > riskLimitValuestringPosition limit value corresponding to the risk id
    > tradeModeinteger0: cross margin mode. 1: isolated margin mode
    > autoAddMargininteger0: false. 1: true
    > positionBalancestringPosition margin
    > liqPricestringEstimated liquidation price. It returns value only when minPrice < liqPrice < maxPrice
    > bustPricestringEstimated bankruptcy price
    > tpSlModestringDepreciated, meaningless here, always "Full"
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > createdTimestringPosition created timestamp (ms)
    > updatedTimestringPosition data updated timestamp (ms)
    > trailingStopstringTrailing stop
    > activePricestringActivate price of trailing stop
    > markPricestringReal-time mark price
    > unrealisedPnlstringunrealised PNL
    > cumRealisedPnlstringcumulative realised PNL
    > positionMMstringPosition maintenance margin
    > positionIMstringPosition initial margin
    > positionStatusstringPosition status
    > sessionAvgPricestringSettlement price
    > occClosingFeestringPre-occupancy closing fee
    > adlRankIndicatorintegerAuto-deleverage rank indicator. What is Auto-Deleveraging?
    > isReduceOnlybooleanUseful when Bybit lower the risk limit
    • true: Only allowed to reduce the position. You can consider a series of measures, e.g., lower the risk limit, decrease leverage or reduce the position, add margin, or cancel orders, after these operations, you can call confirm new risk limit endpoint to check if your position can be removed the reduceOnly mark
    • false: There is no restriction, and it means your position is under the risk when the risk limit is systematically adjusted
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > mmrSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the MMR will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the MMR had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > leverageSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the leverage will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the leverage had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others

    Request Example

    GET /contract/v3/private/position/list?symbol=ETCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673421074950
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "positionIdx": 0,
    "riskId": 236,
    "symbol": "ETCUSDT",
    "side": "None",
    "size": "0.0",
    "positionValue": "0",
    "entryPrice": "0",
    "tradeMode": 0,
    "autoAddMargin": 0,
    "leverage": "10",
    "positionBalance": "0",
    "liqPrice": "",
    "bustPrice": "0.000",
    "takeProfit": "0.000",
    "stopLoss": "0.000",
    "trailingStop": "0.000",
    "unrealisedPnl": "0",
    "createdTime": "1672986751942",
    "updatedTime": "1675382400091",
    "tpSlMode": "Full",
    "riskLimitValue": "200000",
    "activePrice": "0.000",
    "markPrice": "15.126",
    "cumRealisedPnl": "-10.69094915",
    "positionMM": "0",
    "positionIM": "0",
    "positionStatus": "Normal",
    "sessionAvgPrice": "0.000",
    "occClosingFee": "0",
    "avgPrice": "0",
    "adlRankIndicator": 0,
    "isReduceOnly": false,
    "mmrSysUpdatedTime": "",
    "leverageSysUpdatedTime": ""
    }
    ],
    "category": "",
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1697685149803
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/position-mode.html b/derivatives/contract/position-mode.html index 6b6ea8d61c..cf561026a5 100644 --- a/derivatives/contract/position-mode.html +++ b/derivatives/contract/position-mode.html @@ -4,13 +4,13 @@ Switch Position Mode | Bybit API Documentation - +

    Switch Position Mode

    It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.

    tip
    • Priority for configuration to take effect: symbol > coin > system default
    • System default: one-way mode
    • If the request is by coin (settleCoin), then all symbols based on this setteCoin that do not have position and open order will be batch switched, and new listed symbol based on this settleCoin will be the same mode you set.

    Example

    System defaultcoinsymbol
    Initial settingone-waynever configurednever configured
    ResultAll USDT perpetual trading pairs are one-way mode
    Change 1--Set BTCUSDT to hedge-mode
    ResultBTCUSDT becomes hedge-mode, and all other symbols keep one-way mode
    list new symbol ETHUSDTETHUSDT is one-way mode (inherit default rules)
    Change 2-Set USDT to hedge-mode-
    ResultAll current trading pairs with no positions or orders are hedge-mode, and no adjustments will be made for trading pairs with positions and orders
    list new symbol SOLUSDTSOLUSDT is hedge-mode (Inherit coin rule)
    Change 3--Set ASXUSDT to one-mode
    Take effect resultAXSUSDT is one-way mode, other trading pairs have no change
    list new symbol BITUSDTBITUSDT is hedge-mode (Inherit coin rule)

    The position-switch ability for each contract

    Regular accountUnified margin account
    USDT perpetualSupport one-way & hedge-modeSupport one-way **only**
    USDC perpetualSupport one-way **only**Support one-way **only**
    Inverse perpetualSupport one-way **only**N/A
    Inverse future Support one-way & hedge-modeN/A

    HTTP Request

    POST /contract/v3/private/position/switch-mode

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringSymbol name. Either symbol or coin is required. symbol has a higher priority
    coinfalsestringCoin
    modetrueintegerPosition mode. 0: Merged Single. 3: Both Side

    Response Parameters

    ParameterTypeComments
    retCodeintegerSuccess/Error code
    retMsgstringSuccess/Error message
    resultObject
    retExtInfoObject
    timeintegerTimestamp

    Request Example

    POST /contract/v3/private/position/switch-mode HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670848915553
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"CHZUSDT",
    "coin": null,
    "mode": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670848915768
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/replace-order.html b/derivatives/contract/replace-order.html index 1207b7f150..99c7b6a3fa 100644 --- a/derivatives/contract/replace-order.html +++ b/derivatives/contract/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +

    Replace Order

    note

    You could modify those unfilled or partially filled orders.

    HTTP Request

    POST /contract/v3/private/order/replace

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required
    pricefalsestringOrder price after modification. Don't pass it if not modify the price
    qtyfalsestringOrder quantity after modification. Don't pass it if not modify the qty
    triggerPricefalsestringTrigger price. Don't pass it if not modify the qty
    takeProfitfalsestringTake profit price after modification. Don't pass it if not modify the take profit
    stopLossfalsestringStop loss price after modification. Don't pass it if not modify the Stop loss
    tpTriggerByfalsestringThe price type to trigger take profit. When set a take profit, this param is required if no initial value for the order
    slTriggerByfalsestringThe price type to trigger stop loss. When set a stop loss, this param is required if no initial value for the order
    triggerByfalsestringTrigger price type. LastPrice, IndexPrice, MarkPrice, LastPrice
    tpLimitPricefalsestringLimit order price when take profit is triggered. Only working when original order sets partial limit tp/sl
    slLimitPricefalsestringLimit order price when stop loss is triggered. Only working when original order sets partial limit tp/sl

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    POST /contract/v3/private/order/replace HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670554903846
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "XRPUSDT",
    "orderId": "5ba57394-0ff0-4cb8-8000-59085d2c3aba",
    "orderLinkId": null,
    "price": "14.5"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "5ba57394-0ff0-4cb8-8000-59085d2c3aba",
    "orderLinkId": ""
    },
    "retExtInfo": {},
    "time": 1670554904609
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/set-risk-limit.html b/derivatives/contract/set-risk-limit.html index f8490e7c30..093a9f28f1 100644 --- a/derivatives/contract/set-risk-limit.html +++ b/derivatives/contract/set-risk-limit.html @@ -4,7 +4,7 @@ Set Risk Limit | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Set Risk Limit

    The risk limit will limit the maximum position value you can hold under different margin requirements. If you want to hold a bigger position size, you need more margin. This interface can set the risk limit of a single position. If the order exceeds the current risk limit when placing an order, it will be rejected. Click here to learn more about risk limit.

    tip

    Set the risk limit of the position. You could get risk limit information of each symbol here.

    HTTP Request

    POST /contract/v3/private/position/set-risk-limit

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    riskIdtrueintegerRisk limit id
    positionIdxfalseintegerUsed to identify positions in different position modes. For hedge-mode, this param is required
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670853142896
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"ETHUSDT",
    "riskId": 12,
    "positionIdx": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670853143027
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/tpsl-mode.html b/derivatives/contract/tpsl-mode.html index f33789b310..716e260449 100644 --- a/derivatives/contract/tpsl-mode.html +++ b/derivatives/contract/tpsl-mode.html @@ -4,7 +4,7 @@ Switch TP/SL Mode | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Switch TP/SL Mode

    tip

    To some extent, this endpoint is depreciated because now tpsl is based on order level. This API was used for position level change before.

    However, you still can use it to set an implicit tpsl mode for a certain symbol because when you don't pass "tpslMode" in the place order or trading stop request, system will get the tpslMode by the default setting.

    Adjust the take profit / stop loss mode. Full position or Partial position TP/SL.

    note

    Support USDT Perpetual, Inverse Perpetual and Inverse Future.

    HTTP Request

    POST /contract/v3/private/position/switch-tpsl-mode

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    tpSlModetruestringFull: set TP/SL to full position. Partial: set TP/SL to partial mode

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/switch-tpsl-mode HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670849702461
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSDT",
    "tpSlMode":"Full"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670849702655
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/trading-stop.html b/derivatives/contract/trading-stop.html index 9b15da8810..e6b2a3285e 100644 --- a/derivatives/contract/trading-stop.html +++ b/derivatives/contract/trading-stop.html @@ -4,7 +4,7 @@ Set Trading Stop | Bybit API Documentation - + @@ -13,7 +13,7 @@ on existing TP/SL orders on the holding position, it will cause the paired tp/sl orders to lose binding relationship. This means that when calling the cancel API through the tp/sl order ID, it will only cancel the corresponding one-sided take profit or stop loss order ID.

    HTTP Request

    POST /contract/v3/private/position/trading-stop

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringSymbol name
    takeProfitfalsestringCannot be less than 0, 0 means cancel TP. Partial TP/SL cannot be cancelled by set it 0
    stopLossfalsestringCannot be less than 0, 0 means cancel SL. Partial TP/SL cannot be cancelled by set it 0
    tpslModefalsestringTP/SL mode. Full: entire position TP/SL, Partial: partial position TP/SL. As each contract has an initial full TP/SL mode, if it has been modified before, it may be partial. Therefore, if not provided, the system will automatically retrieve the current TP/SL mode configuration for the contract.
    tpSizefalsestringTake profit size. Valid in TP/SL partial mode only. Note: the value of tpSize and slSize must equal
    slSizefalsestringStop loss size. Valid in TP/SL partial mode only. Note: the value of tpSize and slSize must equal
    tpTriggerByfalsestringTake profit trigger price type. default: LastPrice
    slTriggerByfalsestringStop loss trigger price type. default: LastPrice
    trailingStopfalsestringCannot be less than 0, 0 means cancel TS
    activePricefalsestringTrailing stop trigger price. Trailing stop will be triggered when this price is reached only
    tpLimitPricefalsestringThe limit order price when take profit price is triggered. Only works when tpslMode=Partial and tpOrderType=Limit
    slLimitPricefalsestringThe limit order price when stop loss price is triggered. Only works when tpslMode=Partial and slOrderType=Limit
    tpOrderTypefalsestringThe order type when take profit is triggered. Market(default), Limit. For tpslMode=Full, it only supports tpOrderType=Market
    slOrderTypefalsestringThe order type when stop loss is triggered. Market(default), Limit. For tpslMode=Full, it only supports slOrderType=Market
    positionIdxfalsestringUsed to identify positions in different position modes. For hedge-mode, this param is required
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    None

    Request Example

    POST /contract/v3/private/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670852788387
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "SOLPERP",
    "takeProfit": "19",
    "stopLoss": "10",
    "activePrice": null,
    "trailingStop": null,
    "tpTriggerBy": null,
    "slTriggerBy": null,
    "tpslMode": "Partial",
    "tpOrderType": "Limit"
    "slOrderType": "Limit"
    "tpSize": "50",
    "slSize": "50",
    "tpLimitPrice": "18",
    "slLimitPrice": "11",
    "positionIdx": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670852788558
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/wallet-fund.html b/derivatives/contract/wallet-fund.html index 2d66ee0c00..cf5a17bd80 100644 --- a/derivatives/contract/wallet-fund.html +++ b/derivatives/contract/wallet-fund.html @@ -4,13 +4,13 @@ Get Wallet Fund Records | Bybit API Documentation - +

    Get Wallet Fund Records

    Get wallet fund records. This endpoint also shows exchanges from the Asset Exchange, where the types for the exchange are ExchangeOrderWithdraw and ExchangeOrderDeposit.

    tip
    • This endpoint returns incomplete information for transfers involving the derivatives wallet. Use the account asset API for creating and querying internal transfers.
    • Find more detail for types Withdraw and Refund in the Withdraw Records endpoint.
    • Deposit or withdrawal records which occurred after 2021-07-15 will not be shown by this endpoint. To fetch records after this date you should call the Query Deposit Recordsand Query Withdraw Records endpoint. This is due to the introduction of the spot wallet at this time.

    HTTP Request

    GET /contract/v3/private/account/wallet/fund-records

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin
    walletFundTypefalsestringFund type
    startTimefalseintegerStart timestamp (ms)
    endTimefalseintegerEnd timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin
    > typestringType
    > amountstringAmount
    > walletBalancestringWallet balance
    > execTimestringExecuted timestamp (ms)
    nextPageCursorstringCursor. Used to pagination

    Request Example

    GET /contract/v3/private/account/wallet/fund-records?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670931970500
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "BTC",
    "type": "RealisedPNL",
    "amount": "-0.00003034",
    "walletBalance": "0.68146653",
    "execTime": "1665792000030"
    }
    ],
    "nextPageCursor": "K2tqR0xUQ1B1Tyt1a0ZFeVZRa1I2R2ZOT2pVekNKeGZPOTEyWFNpeXd1ejRmRTFoUkhabnVKVlRBNnFtZGk0dlBhRThLdFNHTGxFdWJGQVFMdXBnZ29Bb3JmSDlkczZHV1p1V1JoZmc2dnlRc1VMZ1ZVYlRXeW51ZUVBT3QycjlYSml3alNZampKTHdrdDJzSzFWdnlWK0djRklqczB1M0JYN04wVXltV0ljPQ=="
    },
    "retExtInfo": {},
    "time": 1670931971341
    }
    - + \ No newline at end of file diff --git a/derivatives/contract/wallet.html b/derivatives/contract/wallet.html index c91092d2b1..dfa708eb25 100644 --- a/derivatives/contract/wallet.html +++ b/derivatives/contract/wallet.html @@ -4,13 +4,13 @@ Wallet Balance | Bybit API Documentation - +

    Wallet Balance

    Get wallet balance, including Derivatives account and USDC account.

    HTTP Request

    GET /contract/v3/private/account/wallet/balance

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin
    • Return all wallet info if not passed
    • Multiple coins are allowed, separated by comma, like USDT,USDC

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin
    > equitystringTotal equity
    > walletBalancestringWallet balance
    > positionMarginstringPosition margin
    > availableBalancestringAvailable balance
    > orderMarginstringPre-occupied order margin
    > occClosingFeestringPosition closing fee occupied. formula: opening fee + expected maximum closing fee
    > occFundingFeestringPre-occupied funding fee
    > unrealisedPnlstringUnrealised pnl
    > cumRealisedPnlstringCumulative realised pnl (all-time)
    > givenCashstringTrial fund. Find out more here
    > serviceCashstringCoupon. Find out more here
    > accountIMstringUSDC account initial margin
    > accountMMstringUSDC account maintenance margin

    Request Example

    GET /contract/v3/private/account/wallet/balance?coin=USDC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670923630734
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "USDC",
    "equity": "1259.7788251",
    "walletBalance": "1259.7488251",
    "positionMargin": "1259.7788251",
    "availableBalance": "1246.7387871",
    "orderMargin": "0",
    "occClosingFee": "0",
    "occFundingFee": "0",
    "unrealisedPnl": "0.03",
    "cumRealisedPnl": "26.6561752",
    "givenCash": "0",
    "serviceCash": "0",
    "accountIM": "13.040038",
    "accountMM": "1.367038"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670923631261
    }
    - + \ No newline at end of file diff --git a/derivatives/enum.html b/derivatives/enum.html index 7900d9794b..35f9135b12 100644 --- a/derivatives/enum.html +++ b/derivatives/enum.html @@ -4,13 +4,13 @@ Enums Definitions | Bybit API Documentation - +

    Enums Definitions

    category

    Contract

    • linearLinear Contract, including USDT Perpetual
    • inverseInverse Contract, including Inverse Perpetual, Inverse Futures

    Unified Margin

    • linearLinear Contract, including USDT Perpetual, USDC Perpetual
    • option

    symbol

    USDT Perpetual:

    • BTCUSDT
    • ETHUSDT

    USDC Perpetual:

    • BTCPERP
    • ETHPERP

    Inverse Perpetual:

    • BTCUSD
    • ETHUSD

    Inverse Futures:

    • BTCUSDH23H: First quarter; 23: 2023
    • BTCUSDM23M: Second quarter; 23: 2023
    • BTCUSDU23U: Third quarter; 23: 2023
    • BTCUSDZ23Z: Fourth quarter; 23: 2023

    positionIdx

    • 0one-way mode
    • 1Buy side of hedge-mode
    • 2Sell side of hedge-mode

    positionStatus

    • Normal
    • Liqin the liquidation progress
    • Adlin the auto-deleverage progress

    interval

    • 1 3 5 15 30 60 120 240 360 720minute
    • Dday
    • Wweek
    • Mmonth

    triggerBy

    • LastPrice
    • MarkPrice
    • IndexPrice

    timeInForce

    • GoodTillCancel
    • ImmediateOrCancel
    • FillOrKlii
    • PostOnly

    orderFilter

    • Orderactive order
    • StopOrderconditional order

    orderStatus

    • Created
    • New
    • Rejected
    • PartiallyFilled
    • Filled
    • PendingCancel
    • Cancelled
    • Untriggered
    • Triggered
    • Deactivated
    • Active

    cancelType

    • CancelByUser
    • CancelByReduceOnly
    • CancelByPrepareLiq CancelAllBeforeLiq
    • CancelByPrepareAdl CancelAllBeforeAdl
    • CancelByAdmin
    • CancelByTpSlTsClear
    • CancelByPzSideCh
    • CancelBySmp

    Options:

    • CancelByUser
    • CancelByReduceOnly
    • CancelAllBeforeLiqCancelled due to liquidation
    • CancelAllBeforeAdlCancelled due to ADL
    • CancelBySettle
    • CancelByCannotAffordOrderCost
    • CancelByPmTrialMmOverEquity
    • CancelByAccountBlocking
    • CancelByDelivery
    • CancelByMmpTriggered
    • CancelByCrossSelfMuch
    • CancelByCrossReachMaxTradeNum
    • CancelByDCP

    stopOrderType

    • TakeProfit
    • StopLoss
    • TrailingStop
    • Stop
    • PartialTakeProfit
    • PartialStopLoss

    rejectReason

    • EC_NoError
    • EC_Others
    • EC_UnknownMessageType
    • EC_MissingClOrdID
    • EC_MissingOrigClOrdID
    • EC_ClOrdIDOrigClOrdIDAreTheSame
    • EC_DuplicatedClOrdID
    • EC_OrigClOrdIDDoesNotExist
    • EC_TooLateToCancel
    • EC_UnknownOrderType
    • EC_UnknownSide
    • EC_UnknownTimeInForce
    • EC_WronglyRouted
    • EC_MarketOrderPriceIsNotZero
    • EC_LimitOrderInvalidPrice
    • EC_NoEnoughQtyToFill
    • EC_NoImmediateQtyToFill
    • EC_PerCancelRequest
    • EC_MarketOrderCannotBePostOnly
    • EC_PostOnlyWillTakeLiquidity
    • EC_CancelReplaceOrder
    • EC_InvalidSymbolStatus

    positionMode

    • 0One-Way Mode
    • 3Hedge Mode

    execType

    lastLiquidityInd

    Unified Margin

    • TAKER
    • MAKER

    Contract

    • AddedLiquidityadd liquidity
    • RemovedLiquiditytake liquidity

    walletFundType

    • Deposit
    • Withdraw
    • RealisedPNL
    • Commission
    • Refund
    • Prize
    • ExchangeOrderWithdraw
    • ExchangeOrderDeposit
    • ReturnServiceCashRefund of handling fee bonus
    • InsuranceInsurance account transfer
    • SubMemberMain-Sub account transfer
    • CouponCoupon interest
    • AccountTransferAccount transfer
    • CashBackCash back

    type

    • TRANSFER_IN
    • TRANSFER_OUT
    • TRADE
    • SETTLEMENT
    • DELIVERY
    • LIQUIDATION
    • BONUS
    • FEE_REFUND
    • INTEREST
    • CURRENCY_BUY
    • CURRENCY_SELL

    adlRankIndicator

    • 0default value of empty position
    • 1
    • 2
    • 3
    • 4
    • 5

    tickDirection

    It indicates price fluctuation relative to the last trade.

    • PlusTickprice rise
    • ZeroPlusTicktrade occurs at the same price as the previous trade, which occurred at a price higher than that for the trade preceding it
    • MinusTickprice drop
    • ZeroMinusTicktrade occurs at the same price as the previous trade, which occurred at a price lower than that for the trade preceding it

    smpType

    • default: None
    • CancelMaker
    • CancelTaker
    • CancelBoth

    unifiedMarginStatus

    • 1Regular account
    • 2Unified margin account, it only trades linear perpetual and options.
    • 3Unified trade account, it can trade linear perpetual, options and spot
    - + \ No newline at end of file diff --git a/derivatives/error.html b/derivatives/error.html index 42915f8db4..cee2a79b5c 100644 --- a/derivatives/error.html +++ b/derivatives/error.html @@ -4,13 +4,13 @@ Error Code | Bybit API Documentation - +

    Error Code

    Unified Margin

    CodeDescription
    10000Server Timeout
    10001params error
    10002Invalid request, please check your timestamp and recv_window param
    10003Invalid api_key
    10004Error sign
    10005Permission denied
    10006Too many visits
    10008User had been banned. Please check your account mode
    10009IP had been banned
    10010unmatched IP
    10014Request is duplicate
    10016Server Error
    10018Out of frequency limit of IP
    10024Compliance rules triggered
    10027Trading Banned
    110001Order does not exist
    110003Order price is out of permissible range
    110004Insufficient wallet balance
    110005position status
    110006cannot afford estimated position_margin
    110007Insufficient available balance
    110008Order has been finished or canceled
    110009The number of stop orders exceeds maximum limit allowed
    110010Order already cancelled
    110011Any adjustments made will trigger immediate liquidation
    110012Available balance not enough
    110013Due to risk limit, cannot set leverage
    110014Available balance not enough to add margin
    110015the position is in cross_margin
    110016Requested quantity of contracts exceeds risk limit, please adjust your risk limit level before trying again
    110017Reduce-only rule not satisfied
    110018userId illegal
    110019orderId illegal
    110020number of active orders greater than 500
    110021Open Interest exceeded
    110022qty has been limited, cannot modify the order to add qty
    110023This contract only supports position reduction operation, please contact customer service for details
    110024You have an existing position, so position mode cannot be switched
    110025Position mode is not modified
    110026Cross/isolated margin mode is not modified
    110027Margin is not modified
    110028Open orders exist, so you cannot change position mode
    110029Hedge mode is not available for this symbol
    110030Duplicate orderId
    110031risk limit info does not exists
    110032Illegal order
    110033Margin cannot be set without open position
    110034There is no net position
    110035Cancel order is not completed before liquidation
    110036Cross margin mode is not allowed to change leverage
    110037User setting list does not have this symbol
    110038Portfolio margin mode is not allowed to change leverage
    110039Maintain margin rate is too high, which may trigger liquidation
    110040Order will trigger forced liquidation, please resubmit the order
    110041Skip liquidation is not allowed when a position or maker order exists
    110042Pre-delivery status can only reduce positions
    110043Set leverage not modified
    110044Insufficient available margin
    110045Insufficient wallet balance
    110046Any adjustments made will trigger immediate liquidation
    110047Risk limit cannot be adjusted due to insufficient available margin
    110048Risk limit cannot be adjusted as the current/expected position value held exceeds the revised risk limit
    110049Tick notes can only be numbers
    110050Coin is not in the range of selected
    110051The user's available balance cannot cover the lowest price of the current market
    110052User's available balance is insufficient to set a price
    110053The user's available balance cannot cover the current market price and upper limit price
    110054This position has at least one take profit link order, so the take profit and stop loss mode cannot be switched
    110055This position has at least one stop loss link order, so the take profit and stop loss mode cannot be switched
    110056This position has at least one trailing stop link order, so the take profit and stop loss mode cannot be switched
    110057Conditional order or limit order contains TP/SL related params
    110058Insufficient number of remaining position size to set take profit and stop loss
    110059In the case of partial filled of the open order, it is not allowed to modify the take profit and stop loss settings of the open order
    110060Under full TP/SL mode, it is not allowed to modify TP/SL
    110061Under partial TP/SL mode, TP/SL set more than 20
    110062Institution MMP profile not found.
    110063Settlement in progress! {{key0}} not available for trades.
    110064The number of contracts modified cannot be less than or equal to the filled quantity
    110065MMP hasn't yet been enabled for your account. Please contact your BD manager.
    110066No trading is allowed at the current time
    110067unified account is not support
    110068Leveraged user trading is not allowed
    110069Do not allow OTC lending users to trade
    110070ETP symbols are not allowed to be traded

    Contract

    CodeDescription
    10000Server Timeout
    10001params error
    10002Invalid request, please check your timestamp and recv_window param
    10003Invalid api_key
    10004Error sign
    10005Permission denied
    10006Too many visits
    10008User had been banned. Please check your account mode
    10009IP had been banned
    10010unmatched IP
    10014Request is duplicate
    10016Server Error
    10018Out of frequency limit of IP
    10027Trading Banned
    140001Order does not exist
    140003Order price is out of permissible range
    140004Insufficient wallet balance
    140005position status
    140006cannot afford estimated position_margin
    140007Insufficient available balance
    140008Order has been finished or canceled
    140009The number of stop orders exceeds maximum limit allowed
    140010Order already cancelled
    140011Any adjustments made will trigger immediate liquidation
    140012Available balance not enough
    140013Due to risk limit, cannot set leverage
    140014Available balance not enough to add margin
    140015the position is in cross_margin
    140016Requested quantity of contracts exceeds risk limit, please adjust your risk limit level before trying again
    140017Reduce-only rule not satisfied
    140018userId illegal
    140019orderId illegal
    140020number of active orders greater than 500
    140021Open Interest exceeded
    140022qty has been limited, cannot modify the order to add qty
    140023This contract only supports position reduction operation, please contact customer service for details
    140024You have an existing position, so position mode cannot be switched
    140025Position mode is not modified
    140026Cross/isolated margin mode is not modified
    140027Margin is not modified
    140028Open orders exist, so you cannot change position mode
    140029Hedge mode is not available for this symbol
    140030Duplicate orderId
    140031risk limit info does not exists
    140032Illegal order
    140033Margin cannot be set without open position
    140034There is no net position
    140035Cancel order is not completed before liquidation
    140036Cross margin mode is not allowed to change leverage
    140037User setting list does not have this symbol
    140038Portfolio margin mode is not allowed to change leverage
    140039Maintain margin rate is too high, which may trigger liquidation
    140040Order will trigger forced liquidation, please resubmit the order
    140041Skip liquidation is not allowed when a position or maker order exists
    140042Pre-delivery status can only reduce positions
    140043Set leverage not modified
    140044Insufficient available margin
    140045Insufficient wallet balance
    140046Any adjustments made will trigger immediate liquidation
    140047Risk limit cannot be adjusted due to insufficient available margin
    140048Risk limit cannot be adjusted as the current/expected position value held exceeds the revised risk limit
    140049Tick notes can only be numbers
    140050Coin is not in the range of selected
    140051The user's available balance cannot cover the lowest price of the current market
    140052User's available balance is insufficient to set a price
    140053The user's available balance cannot cover the current market price and upper limit price
    140054This position has at least one take profit link order, so the take profit and stop loss mode cannot be switched
    140055This position has at least one stop loss link order, so the take profit and stop loss mode cannot be switched
    140056This position has at least one trailing stop link order, so the take profit and stop loss mode cannot be switched
    140057Conditional order or limit order contains TP/SL related params
    140058Insufficient number of remaining position size to set take profit and stop loss
    140059In the case of partial filled of the open order, it is not allowed to modify the take profit and stop loss settings of the open order
    140060Under full TP/SL mode, it is not allowed to modify TP/SL
    140061Under partial TP/SL mode, TP/SL set more than 20
    140062Institution MMP profile not found.
    140063Settlement in progress! {{key0}} not available for trades.
    140064The number of contracts modified cannot be less than or equal to the filled quantity
    140065MMP hasn't yet been enabled for your account. Please contact your BD manager.
    140066No trading is allowed at the current time
    140067unified account is not support
    140068Leveraged user trading is not allowed
    140069Do not allow OTC lending users to trade
    140070ETP symbols are not allowed to be traded
    140071RiskId not modified
    3400045Set margin mode failed
    340099Server error
    - + \ No newline at end of file diff --git a/derivatives/public/funding-rate.html b/derivatives/public/funding-rate.html index 9ca548cc5f..09b6240d74 100644 --- a/derivatives/public/funding-rate.html +++ b/derivatives/public/funding-rate.html @@ -4,13 +4,13 @@ Funding Rate History | Bybit API Documentation - +

    Funding Rate History

    Get historical funding rate

    tip
    • Passing startTime only, it returns error.
    • Passing endTime only, it returns 200 records till endTime.
    • Both are not passed, it returns 200 records till current time.

    HTTP Request

    GET /derivatives/v3/public/funding/history-funding-rate

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    startfalseintegerThe start timestamp (ms)
    endfalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarrayObject
    > symbolstringSymbol name
    > fundingRatestringFunding rate
    > fundingRateTimestampstringFunding rate timestamp(ms)

    Request Example

    GET /derivatives/v3/public/funding/history-funding-rate?symbol=BTCPERP&limit=2 HTTP/1.1
    Host: api.bybit.com​​

    Response Example

        {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "",
    "list": [
    {
    "symbol": "BTCPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1671955200000"
    },
    {
    "symbol": "BTCPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1671926400000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671970750651
    }
    - + \ No newline at end of file diff --git a/derivatives/public/index-kline.html b/derivatives/public/index-kline.html index 92a41fcc87..93ea51389d 100644 --- a/derivatives/public/index-kline.html +++ b/derivatives/public/index-kline.html @@ -4,13 +4,13 @@ Index Price Kline | Bybit API Documentation - +

    Index Price Kline

    Get index price kline data

    HTTP Request

    GET /derivatives/v3/public/index-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    intervaltruestringKline interval. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueintegerThe start timestamp (ms)
    endtrueintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarray
    • An string array of individual candle
    • Sort in reverse by start
    • The default collation within the array is start, open, high, low, close

    Request Example

    GET /derivatives/v3/public/index-price-kline?category=linear&symbol=BTCUSDT&interval=60&start=1668441600000&end=1668528000000&limit=2 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "linear",
    "list": [
    [
    "1668445200000",
    "16471.28",
    "16619.57",
    "16445.28",
    "16584.01"
    ],
    [
    "1668441600000",
    "16594.06",
    "16624.76",
    "16358",
    "16471.28"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968874797
    }
    - + \ No newline at end of file diff --git a/derivatives/public/instrument-info.html b/derivatives/public/instrument-info.html index 5c8c5ce1ba..d0ac525b78 100644 --- a/derivatives/public/instrument-info.html +++ b/derivatives/public/instrument-info.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +

    Instrument Info

    Get launched instruments information.

    HTTP Request

    GET /derivatives/v3/public/instruments-info

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse,option. Default: returns futures
    symbolfalsestringSymbol name.
    • query an option symbol, category is required
    baseCoinfalsestringBase coin.
    • Valid when category=option
    • BTC by default if not passed
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 500
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringDerivatives products category. Keeps empty string `""` when `category` is not passed
    listarrayObject
    > symbolstringSymbol name
    > contractTypestringContract type. `LinearPerpetual`, `InversePerpetual`, `InverseFutures`
    > statusstringSymbol status
    > baseCoinstringBase coin. e.g BTCUSDT, BTC is base coin
    > quoteCoinstringQuote coin. e.g BTCPERP, USDC is quote coin
    > settleCoinstringSettle coin. e.g BTCUSD, BTC is settle coin
    > launchTimestringThe launch timestamp (ms)
    > deliveryTimestringThe delivery timestamp (ms). "0" for perpetual
    > deliveryFeeRatestringThe delivery fee rate
    > priceScalestringPrice scale
    > leverageFilterObject
    >> minLeveragestringMin. leverage
    >> maxLeveragestringMax. leverage
    >> leverageStepstringThe min step to modify leverage
    > priceFilterObject
    >> minPricestringMin. order price
    >> maxPricestringMax. order price
    >> tickSizestringTick size
    > lotSizeFilterObject
    >> maxOrderQtystringMax. trade quantity per order
    >> minOrderQtystringMin. trade quantity per order
    >> qtyStepstringMin. order quantity increment
    > unifiedMarginTradebooleanSupport unified margin trade or not
    > fundingIntervalintegerFunding interval (minute)
    nextPageCursorstringThe cursor used to pagination

    Request Example

    GET /derivatives/v3/public/instruments-info?symbol=BTCPERP&category=linear HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "BTCPERP",
    "contractType": "LinearPerpetual",
    "status": "Trading",
    "baseCoin": "BTC",
    "quoteCoin": "USD",
    "launchTime": "1610604231000",
    "deliveryTime": "0",
    "deliveryFeeRate": "",
    "priceScale": "2",
    "leverageFilter": {
    "minLeverage": "1",
    "maxLeverage": "125.00",
    "leverageStep": "0.01"
    },
    "priceFilter": {
    "minPrice": "0.50",
    "maxPrice": "999999.00",
    "tickSize": "0.50"
    },
    "lotSizeFilter": {
    "maxTradingQty": "20.000",
    "minTradingQty": "0.001",
    "qtyStep": "0.001",
    "postOnlyMaxOrderQty": "100.000",
    "maxOrderQty": "20.000",
    "minOrderQty": "0.001"
    },
    "unifiedMarginTrade": true,
    "fundingInterval": 480,
    "settleCoin": "USDC"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1671969788515
    }
    - + \ No newline at end of file diff --git a/derivatives/public/kline.html b/derivatives/public/kline.html index a021074cc4..e8ac8b1ee9 100644 --- a/derivatives/public/kline.html +++ b/derivatives/public/kline.html @@ -4,13 +4,13 @@ Kline | Bybit API Documentation - +

    Kline

    Get kline data

    HTTP Request

    GET /derivatives/v3/public/kline

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    intervaltruestringKline interval. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueintegerThe start timestamp (ms)
    endtrueintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarray
    • An string array of individual candle
    • Sort in reverse by start
    • The default collation within the array is start, open, high, low, close, volume, turnover

    Request Example

    GET /derivatives/v3/public/kline?category=linear&symbol=BTCPERP&interval=1&start=1670371140000&end=1670371200000 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCPERP",
    "category": "linear",
    "list": [
    [
    "1670371200000",
    "17077",
    "17084",
    "17077",
    "17084",
    "0.017",
    "290.412"
    ],
    [
    "1670371140000",
    "17074",
    "17077.5",
    "17074",
    "17077",
    "0.006",
    "102.457"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968612436
    }
    - + \ No newline at end of file diff --git a/derivatives/public/long-short-ratio.html b/derivatives/public/long-short-ratio.html index a960cac759..e5f6a00989 100644 --- a/derivatives/public/long-short-ratio.html +++ b/derivatives/public/long-short-ratio.html @@ -4,13 +4,13 @@ Get Long Short Ratio | Bybit API Documentation - +

    Get Long Short Ratio

    HTTP Request

    GET /derivatives/v3/public/account-ratio

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear(USDT Perpetual only),inverse
    symboltruestringSymbol name
    periodtruestringData recording period. 5min, 15min, 30min, 1h, 4h, 4d
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 50

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol name
    > buyRatiostringThe ratio of users with net long position
    > sellRatiostringThe ratio of users with net short position
    > timestampstringTimestamp (ms)

    Request Example

    GET /derivatives/v3/public/account-ratio?category=linear&symbol=BTCUSDT&period=1d&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "buyRatio": "0.5777",
    "sellRatio": "0.4223",
    "timestamp": "1695772800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1695785131028
    }
    - + \ No newline at end of file diff --git a/derivatives/public/mark-kline.html b/derivatives/public/mark-kline.html index d2bd303a13..4cd36305ec 100644 --- a/derivatives/public/mark-kline.html +++ b/derivatives/public/mark-kline.html @@ -4,13 +4,13 @@ Mark Price Kline | Bybit API Documentation - +

    Mark Price Kline

    Get mark price kline data

    HTTP Request

    GET /derivatives/v3/public/mark-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    intervaltruestringKline interval. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueintegerThe start timestamp (ms)
    endtrueintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarray
    • An string array of individual candle
    • Sort in reverse by start
    • The default collation within the array is start, open, high, low, close

    Request Example

    GET /derivatives/v3/public/mark-price-kline?symbol=BTCUSD&interval=1&start=1670261100000&end=1670261280000&category=inverse HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    [
    "1670261280000",
    "17064.76",
    "17068.45",
    "17063.5",
    "17067"
    ],
    [
    "1670261220000",
    "17062.5",
    "17064.88",
    "17062.5",
    "17064.76"
    ],
    [
    "1670261160000",
    "17064",
    "17064",
    "17062.5",
    "17062.5"
    ],
    [
    "1670261100000",
    "17072",
    "17072",
    "17064",
    "17064"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968706092
    }
    - + \ No newline at end of file diff --git a/derivatives/public/open-interest.html b/derivatives/public/open-interest.html index bf8749cd36..6452dc18de 100644 --- a/derivatives/public/open-interest.html +++ b/derivatives/public/open-interest.html @@ -4,13 +4,13 @@ Open Interest | Bybit API Documentation - +

    Open Interest

    Get open interest of each symbol in Bybit

    info
    • Returns single side data
    • The upper limit time you can query is the launch time of the symbol.

    HTTP Request

    GET /derivatives/v3/public/open-interest

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    intervaltruestringInterval. 5min 15min 30min 1h 4h 1d
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarrayObject
    > openIntereststringOpen interest
    > timestampstringThe timestamp (ms)
    nextPageCursorstringThe cursor used to pagination

    Request Example

    GET /derivatives/v3/public/open-interest?category=linear&symbol=ETHUSDT&interval=5min&limit=2 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "ETHUSDT",
    "category": "linear",
    "list": [
    {
    "openInterest": "411496.22000000",
    "timestamp": "1677832800000"
    },
    {
    "openInterest": "411484.61000000",
    "timestamp": "1677832500000"
    }
    ],
    "nextPageCursor": "lastid%3D44487872"
    },
    "retExtInfo": {},
    "time": 1677832955976
    }
    - + \ No newline at end of file diff --git a/derivatives/public/option-delivery.html b/derivatives/public/option-delivery.html index 938a2d6b22..12c1aae75a 100644 --- a/derivatives/public/option-delivery.html +++ b/derivatives/public/option-delivery.html @@ -4,13 +4,13 @@ Option Delivery Price | Bybit API Documentation - +

    Option Delivery Price

    Get the delivery price for option

    HTTP Request

    GET /derivatives/v3/public/delivery-price

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. For option only
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Default: BTC
    directionfalsestringPage direction. prev, next. Default: next
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    resultTotalSizeintegerThe number of records in dataList
    cursorstringCursor. Used to pagination
    dataListarrayObject
    > categorystringProducts category
    > symbolstringSymbol name
    > deliveryPricestringDelivery price
    > deliveryTimestringDelivery timestamp(ms)

    Request Example

    GET /derivatives/v3/public/delivery-price?limit=1&baseCoin=ETH HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "resultTotalSize": 4830,
    "cursor": "0%2C1",
    "dataList": [
    {
    "category": "option",
    "symbol": "ETH-25DEC22-1450-C",
    "deliveryPrice": "1218.856238890",
    "deliveryTime": "1671955200000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671971138308
    }
    - + \ No newline at end of file diff --git a/derivatives/public/orderbook.html b/derivatives/public/orderbook.html index 4108b46647..688914461d 100644 --- a/derivatives/public/orderbook.html +++ b/derivatives/public/orderbook.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - +

    Order Book

    Get order book data.

    info

    The response is in the snapshot format.

    HTTP Request

    GET /derivatives/v3/public/order-book/L2

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse,option. Default: linear, but in the response category shows ""
    symboltruestringSymbol name. category is required when query an option symbol
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 25. option has 25 only

    Response Parameters

    ParameterTypeComments
    sstringSymbol name
    bstringBid. Order by price asc
    astringAsk. Order by price asc
    tsintegerThe timestamp(ms) that system generates the data
    uintegerUpdate id, is always in sequence

    Request Example

    GET /derivatives/v3/public/order-book/L2?category=linear&symbol=BTCPERP&limit=2 HTTP/1.1
    Host: api.bybit.com​

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "s": "BTCPERP",
    "b": [
    [
    "16818", // price
    "0.156" // qty
    ],
    [
    "16818.5",
    "0.183"
    ]
    ],
    "a": [
    [
    "16819",
    "0.454"
    ],
    [
    "16819.5",
    "0.054"
    ]
    ],
    "ts": 1671969122791,
    "u": 6404345
    },
    "retExtInfo": {},
    "time": 1671969122869
    }
    - + \ No newline at end of file diff --git a/derivatives/public/premium-index-kline.html b/derivatives/public/premium-index-kline.html index 4644be47a4..e7c5b360b7 100644 --- a/derivatives/public/premium-index-kline.html +++ b/derivatives/public/premium-index-kline.html @@ -4,13 +4,13 @@ Premium Index Price Kline | Bybit API Documentation - +

    Premium Index Price Kline

    Get premium index price kline data

    HTTP Request

    GET /derivatives/v3/public/premium-index-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symboltruestringSymbol name
    intervaltruestringKline interval. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueintegerThe start timestamp (ms)
    endtrueintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarray
    • An string array of individual candle
    • Sort in reverse by start
    • The default collation within the array is start, open, high, low, close

    Request Example

    GET /derivatives/v3/public/premium-index-price-kline?symbol=BTCUSDT&interval=D&start=1668441600000&end=1668528000000 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "",
    "list": [
    [
    "1668470400000",
    "-0.000754",
    "-0.001071",
    "-0.001072",
    "-0.001072"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671969006930
    }
    - + \ No newline at end of file diff --git a/derivatives/public/risk-limit.html b/derivatives/public/risk-limit.html index 56c4b2a5d1..7c821839df 100644 --- a/derivatives/public/risk-limit.html +++ b/derivatives/public/risk-limit.html @@ -4,13 +4,13 @@ Risk Limit | Bybit API Documentation - +

    Risk Limit

    Get risk limit

    tip

    What is risk limit? Risk Limit (USDT Contract)

    HTTP Request

    GET /derivatives/v3/public/risk-limit/list

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse. Default: linear, but in the response category shows ""
    symbolfalsestringSymbol name

    Response Parameters

    ParameterTypeComments
    categorystringProduct type. Keeps empty string "" when category is not passed
    listarrayObject
    > idstringRisk id
    > symbolstringSymbol name
    > limitstringPosition limit
    > maintainMarginstringMaintain margin rate
    > initialMarginstringInitial margin rate
    > isLowerRiskinteger1: true, 0: false
    > maxLeveragestringAllowed max leverage

    Request Example

    GET /derivatives/v3/public/risk-limit/list?symbol=ETHPERP HTTP/1.1
    Host: api.bybit.com

    Response Example

        {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "",
    "list": [
    {
    "id": 1,
    "symbol": "ETHPERP",
    "limit": "500000",
    "maintainMargin": "0.01",
    "initialMargin": "0.015",
    "isLowestRisk": 1,
    "maxLeverage": "66.67"
    },
    ...,

    ]
    },
    "retExtInfo": {},
    "time": 1671970615467
    }
    - + \ No newline at end of file diff --git a/derivatives/public/ticker.html b/derivatives/public/ticker.html index ff76c44750..3bbf7d0d9a 100644 --- a/derivatives/public/ticker.html +++ b/derivatives/public/ticker.html @@ -4,13 +4,13 @@ Ticker Info | Bybit API Documentation - +

    Ticker Info

    Get all latest information of symbols.

    HTTP Request

    GET /derivatives/v3/public/tickers

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,inverse,option. Default: linear, but in the response category shows ""
    symbolfalsestringSymbol name.
    • category=option, symbol is required
    • an option symbol, category is required

    Response Parameters

    ParameterTypeComments
    categorystringDerivatives products category. Keeps empty string `""` when `category` is not passed
    listarrayObject
    > symbolstringSymbol name
    > bidPricestringBest bid price
    > askPricestringBest ask price
    > lastPricestringLast transaction price
    > lastTickDirectionstringDirection of price change
    > prevPrice24hstringPrice of 24 hours ago
    > price24hPcntstringPercentage change of market price relative to 24h
    > highPrice24hstringThe highest price in the last 24 hours
    > lowPrice24hstringLowest price in the last 24 hours
    > prevPrice1hstringHourly market price an hour ago
    > markPricestringMark price
    > indexPricestringIndex price
    > openIntereststringOpen interest
    > turnover24hstringTurnover in the last 24 hours
    > volume24hstringTrading volume in the last 24 hours
    > fundingRatestringFunding rate
    > nextFundingTimestringNext timestamp for funding to settle
    > predictedDeliveryPricestringPredicted delivery price. It has value when 30 min before delivery
    > basisRatestringBasis rate for futures
    > deliveryFeeRatestringDelivery fee rate
    > deliveryTimestringDelivery timestamp (ms)
    > openInterestValuestringOpen interest value

    Request Example

    GET /derivatives/v3/public/tickers?category=linear&symbol=BTCUSDZ22 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "symbol": "BTCUSDZ22",
    "bidPrice": "16825",
    "askPrice": "16825.5",
    "lastPrice": "16825.00",
    "lastTickDirection": "ZeroPlusTick",
    "prevPrice24h": "16830.50",
    "price24hPcnt": "-0.000326",
    "highPrice24h": "16859.50",
    "lowPrice24h": "16798.50",
    "prevPrice1h": "16824.50",
    "markPrice": "16824.02",
    "indexPrice": "16825.28",
    "openInterest": "7653441",
    "turnover24h": "30.80109312",
    "volume24h": "518542",
    "fundingRate": "",
    "nextFundingTime": "0",
    "predictedDeliveryPrice": "0.00",
    "basisRate": "-0.00009093",
    "deliveryFeeRate": "0.0005",
    "deliveryTime": "1672387200000",
    "openInterestValue": "21887.06"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671969377669
    }
    - + \ No newline at end of file diff --git a/derivatives/public/trade.html b/derivatives/public/trade.html index 70674337b8..1e9198d0df 100644 --- a/derivatives/public/trade.html +++ b/derivatives/public/trade.html @@ -4,13 +4,13 @@ Public Trading History | Bybit API Documentation - +

    Public Trading History

    Get recent public trading records in Bybit. You could download archived USDT contract trade records here.

    HTTP Request

    GET /derivatives/v3/public/recent-trade

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type.linear,inverse,option
    • category not passed or =linerar,inverse, then symbol is required
    • category=option, then symbol is optional
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Default: BTC. Valid only when category=option
    optionTypefalsestringOption type. Call or Put. Valid only when category=option
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 500

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > execIdstringExecution id
    > symbolstringSymbol name
    > pricestringTrade price
    > sizestringTrade size
    > sidestringSide of taker Buy, Sell
    > timestringTrade time
    > isBlockTradebooleanIs block trade

    Request Example

    GET /derivatives/v3/public/recent-trade?category=linear&symbol=BTCUSDT&limit=1 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "execId": "5706445b-8543-59bc-8988-93e0f4a3f0f9",
    "symbol": "BTCUSDT",
    "price": "16814.50",
    "size": "0.001",
    "side": "Buy",
    "time": "1671970297430",
    "isBlockTrade": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671970297723
    }
    - + \ No newline at end of file diff --git a/derivatives/rate-limit.html b/derivatives/rate-limit.html index bba0070f1a..68bcdd1dd2 100644 --- a/derivatives/rate-limit.html +++ b/derivatives/rate-limit.html @@ -4,7 +4,7 @@ Rate Limit | Bybit API Documentation - + @@ -14,7 +14,7 @@ If you are still banned after 30 minutes, you likely have a permanent ban.

    We do not recommend running your application at the very edge of these limits in case abnormal network activity results in an unexpected violation.

    • GET/POST method (shared):
      • 120 requests per second for 5 consecutive seconds
    note

    All traffic to api.bybit.com or api.bytick.com share this limit regardless of if it accesses Spot, Derivatives or Options.

    After violating the limit your IP will be banned for a set period of time (usually 30 minutes). Continually violating the limit will result in a permanent ban. We cannot undo permanent bans or shorten temporary bans.

    API Rate Limit

    caution

    If you receive "ret_msg": "Too many visits!" in the JSON response, you have hit the API rate limit.

    tip

    For now, api rate limit for Unified margin is a bit different.

    • linear: rate limit is count by minute
    • option: rate limit is count by second

    The API rate limit is based on the rolling time window per second and UID. In other words, it is per second per UID. Every request to the API returns response header shown in the code panel:

    • X-Bapi-Limit-Status - your remaining requests for current endpoint
    • X-Bapi-Limit - your current limit for current endpoint
    • X-Bapi-Limit-Reset-Timestamp - the timestamp indicating when your request limit resets if you have exceeded your rate_limit. Otherwise, this is just the current timestamp.

    Http Response Header Example

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    API Rate Limit Table

    Unified Margin

    Pathlinearoption
    /unified/v3/private/order/create100 req/min (shared)5 req/s
    /unified/v3/private/order/replace5 req/s
    /unified/v3/private/order/cancel5 req/s
    /unified/v3/private/order/create-batch100 req/min (shared)
    5 req/s
    /unified/v3/private/order/replace-batch5 req/s
    /unified/v3/private/order/cancel-batch5 req/s
    /unified/v3/private/order/cancel-all1 req/s
    /unified/v3/private/order/list50 req/s50 req/s
    /unified/v3/private/order/unfilled-orders50 req/s50 req/s
    /unified/v3/private/position/list50 req/s50 req/s
    /unified/v3/private/execution/list50 req/s50 req/s
    /unified/v3/private/account/wallet/balance50 req/s50 req/s
    /unified/v3/private/delivery-record50 req/s50 req/s
    /unified/v3/private/account/transaction-log50 req/s50 req/s
    /unified/v3/private/settlement-record50 req/s50 req/s
    /unified/v3/private/account/assets50 req/s50 req/s
    /unified/v3/private/position/usdc-marginmode-info50 req/s50 req/s
    /unified/v3/private/account/borrow-history50 req/s50 req/s
    /unified/v3/private/account/borrow-rate50 req/s50 req/s

    Contract

    PathLimit
    All private endpoints10 req/s

    How to increase API Limit

    Please email api@bybit.com with the following information. We will reply within 1-4 working days:

    1. Your name and your company details
    2. Your Bybit UID or registered email, and the assets you are trading
    3. General description of your trading strategy and reasons for higher rate limits
    4. Screenshot of previous monthly trading volume (maker/taker) on other platforms
    5. Optional: your order history in CSV format
    - + \ No newline at end of file diff --git a/derivatives/unified/batch-cancel.html b/derivatives/unified/batch-cancel.html index 3b58587c68..c7aab60a9d 100644 --- a/derivatives/unified/batch-cancel.html +++ b/derivatives/unified/batch-cancel.html @@ -4,14 +4,14 @@ Batch Cancel Order | Bybit API Documentation - +

    Batch Cancel Order

    tip

    This endpoint provides the batch order mode to cancel a bunch of open orders.

    • Order cancellation of future and option cannot be cancelled in one request.
    • If both future and option orders are in one request, then by given the category type, only the orders whose symbol matches the category will be operated.

    HTTP Request

    POST /unified/v3/private/order/cancel-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,option
    requesttruearrayObject
    > symboltruestringSymbol name
    > orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    > orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProducts category
    >> symbolstringSymbol name
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id
    retExtInfoObject
    > listarrayObject
    >> codeintegerSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /unified/v3/private/order/cancel-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672818987475
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderLinkId": "test-002"
    },
    {
    "symbol": "XRPUSDT",
    "orderLinkId": "test-003"
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "",
    "orderLinkId": "test-002"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "",
    "orderLinkId": "test-003"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 110001,
    "msg": "order not exists or too late to cancel"
    }
    ]
    },
    "time": 1672818989928
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/batch-place.html b/derivatives/unified/batch-place.html index 600c40b074..d88b4858f2 100644 --- a/derivatives/unified/batch-place.html +++ b/derivatives/unified/batch-place.html @@ -4,7 +4,7 @@ Batch Place Order | Bybit API Documentation - + @@ -15,7 +15,7 @@ time. Only Limit / Market active order is supported, the conditional order is not supported.
  • If both future and option orders are in one request, then by given the category type, only the orders whose symbol matches the category will be operated.
  • The maximum number of orders included in each request is 10 orders. The returned data list is divided into two lists. The list created by the order and the created information are returned. The structure of the two lists are completely consistent.
  • HTTP Request

    POST /unified/v3/private/order/create-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    requesttruearrayObject
    > symboltruestringSymbol name
    > sidetruestringBuy, Sell
    > orderTypetruestringMarket, Limit
    > qtytruestringOrder quantity
    > pricefalsestringOrder price. Invalid if orderType=Market
    > orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed
    > timeInForcetruestringTime in force. GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly
    > positionIdxfalseintegerPosition index. 0: one-way mode. Unified margin supports one-way mode only
    > orderLinkIdfalsestringUser customised order id. A max of 36 characters. Combinations of numbers, letters (upper and lower cases), dashes, and underscores are supported.
    rule of linear:
    • optional param
    • The same orderLinkId can be used for both USDC PERP and USDT PERP.
    • An orderLinkId can be reused once the original order is either Filled or Cancelled
    • rule of option:
    • required param
    • always unique
    > reduceOnlyfalsebooleanWhat is a reduce-only order? true means your position can only reduce in size if this order is triggered. When reduce_only is true, take profit/stop loss cannot be set
    > closeOnTriggerfalsebooleanWhat is a close on trigger order? For a closing order. It can only reduce your position, not increase it. If the account has insufficient available balance when the closing order is triggered, then other active orders of similar contracts will be cancelled or reduced. It can be used to ensure your stop loss reduces your position regardless of current available margin.
    > mmpfalsebooleanMarket maker protection. true means this order is a market maker protection order

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProducts category
    >> symbolstringSymbol name
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id
    >> createAtstringOrder created time (ms)
    retExtInfoObject
    > listarrayObject
    >> codeintegerSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /unified/v3/private/order/create-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672817108675
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.05",
    "price": "1000",
    "timeInForce": "GoodTillCancel",
    "orderLinkId": "test-002",
    "reduceOnly": false,
    "closeOntrigger": false
    },
    {
    "symbol": "XRPUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "100",
    "price": "0.3",
    "timeInForce": "GoodTillCancel",
    "orderLinkId": "test-003",
    "reduceOnly": false,
    "closeOntrigger": false
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "ce295fcb-8c8a-4f12-89f4-4ab23d38ccd8",
    "orderLinkId": "test-002",
    "createAt": "1672817109797"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "e97f0355-6586-49a4-965f-feb7253cef14",
    "orderLinkId": "test-003",
    "createAt": "1672817109796"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672817109804
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/batch-replace.html b/derivatives/unified/batch-replace.html index 131332f378..ab011c26bd 100644 --- a/derivatives/unified/batch-replace.html +++ b/derivatives/unified/batch-replace.html @@ -4,14 +4,14 @@ Batch Replace Order | Bybit API Documentation - +

    Batch Replace Order

    tip

    This endpoint provides the batch order mode to replace a bunch of open orders.

    • You could modify those unfilled or partially filled orders. Conditional order is not supported.
    • If both future and option orders are in one request, then by given the category type, only the orders whose symbol matches the category will be operated.

    HTTP Request

    POST /unified/v3/private/order/replace-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    requesttruearrayObject
    > symboltruestringSymbol name
    > orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    > orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required
    > qtyfalsestringOrder quantity after modification. Don't pass it if not modify the qty
    > pricefalsestringOrder price after modification. Don't pass it if not modify the price
    > orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProducts category
    >> symbolstringSymbol name
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id
    retExtInfoObject
    > listarrayObject
    >> codeintegerSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /unified/v3/private/order/replace-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672818010133
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderId": null,
    "price": null,
    "qty": "0.1",
    "orderLinkId": "test-002"
    },
    {
    "symbol": "XRPUSDT",
    "orderId": null,
    "price": "120",
    "qty": null,
    "orderLinkId": "test-003"
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "",
    "orderLinkId": "test-002"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "",
    "orderLinkId": "test-003"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672818011076
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/borrow-history.html b/derivatives/unified/borrow-history.html index 44f8318457..6d408894a2 100644 --- a/derivatives/unified/borrow-history.html +++ b/derivatives/unified/borrow-history.html @@ -4,13 +4,13 @@ Borrow History | Bybit API Documentation - +

    Borrow History

    HTTP Request

    GET /unified/v3/private/account/borrow-history

    Request Parameters

    ParameterRequiredTypeComments
    currencyfalsestringUSDC、USDT、BTC、ETH
    startTimeintegerintegerThe start timestamp (ms)
    endTimeintegerintegerThe end time. timestamp (ms)
    directionfalsestringDirection: prev: previous page, next: next page, Default is next
    limitintegerintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringCursor. Used to pagination
    currencystringnull
    listarrayObject
    > currencystringUSDC、USDT、BTC、ETH
    > createTimeintegerCreated timestamp (ms)
    > borrowCoststringInterest
    > hourlyBorrowRatestringHourly Borrow Rate
    > InterestBearingBorrowSizestringInterest Bearing Borrow Size
    > costExemptionstringCost exemption

    Request Example

    GET /unified/v3/private/account/borrow-history?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673078071099
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "1625%3A0%2C1625%3A0",
    "currency": null,
    "list": [
    {
    "createTime": 1667282700269,
    "costExemption": "0.00063175360150218",
    "InterestBearingBorrowSize": "0",
    "currency": "USDT",
    "hourlyBorrowRate": "0.000001142",
    "borrowCost": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673078071991
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/borrow-rate.html b/derivatives/unified/borrow-rate.html index e270ded123..aa6a069fa7 100644 --- a/derivatives/unified/borrow-rate.html +++ b/derivatives/unified/borrow-rate.html @@ -4,13 +4,13 @@ Get Borrow Rate | Bybit API Documentation - +

    Get Borrow Rate

    HTTP Request

    GET /unified/v3/private/account/borrow-rate

    Request Parameters

    ParameterRequiredTypeComments
    currencyfalsestringUSDC, USDT Only

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > currencystringCurrency of all current collateral
    > hourlyBorrowRatestringHourly borrow rate
    > maxBorrowAmountstringMax borrow amount
    > freeBorrowAmountstringThe free interest of loan amount

    Request Example

    GET /unified/v3/private/account/borrow-rate HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673078229194
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "list": [
    {
    "freeBorrowingAmount": "30000",
    "currency": "USDT",
    "maxBorrowingAmount": "2500000",
    "hourlyBorrowRate": "0.0000055139"
    },
    {
    "freeBorrowingAmount": "15000",
    "currency": "USDC",
    "maxBorrowingAmount": "1500000",
    "hourlyBorrowRate": "0.00000342460000000000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672023307465
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/cancel-all.html b/derivatives/unified/cancel-all.html index 2dfaabe190..9c22e3c500 100644 --- a/derivatives/unified/cancel-all.html +++ b/derivatives/unified/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Orders | Bybit API Documentation - +

    Cancel All Orders

    tip

    This endpoint enables to cancel all open orders.

    • If category=linear, one of param baseCoin, settleCoin, symbol must be passed.

    HTTP Request

    POST /unified/v3/private/order/cancel-all

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symbolfalsestringSymbol name
    baseCoinfalsestringCancel all open orders by base coin
    settleCoinfalsestringCancel all open orders by settle coin. linear only
    orderFilterfalsestringOrder: active order, StopOrder: conditional order

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProducts category
    >> symbolstringSymbol name
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id
    retExtInfoObject
    > listarrayObject
    >> codeintegerSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /unified/v3/private/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672810386137
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "baseCoin": "ETH",
    "settleCoin": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "6cba55ea-6996-44f5-bd0f-ac09ffda4ab1",
    "orderLinkId": "liang-001"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672810388787
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/cancel.html b/derivatives/unified/cancel.html index b7e6788410..7226689fdb 100644 --- a/derivatives/unified/cancel.html +++ b/derivatives/unified/cancel.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    caution

    You could cancel those unfilled or partially filled orders.

    HTTP Request

    POST /unified/v3/private/order/cancel

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symboltruestringSymbol name
    orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required
    orderFilterfalsestringOrder: active order, StopOrder: conditional order

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/cancel' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "category": "linear",
    "orderId": "4c51a45f-7795-4b38-9b66-3c306b73f112",
    "symbol": "BTCUSDT"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "4c51a45f-7795-4b38-9b66-3c306b73f112",
    "orderLinkId": "e80d558e-ed"
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/dcp.html b/derivatives/unified/dcp.html index 854f67ce05..8a6503a253 100644 --- a/derivatives/unified/dcp.html +++ b/derivatives/unified/dcp.html @@ -4,7 +4,7 @@ Set Disconnect Cancel All | Bybit API Documentation - + @@ -15,7 +15,7 @@ all active option orders of the client will be cancelled automatically. If within 10 seconds, the client reconnects and resumes the heartbeat "ping", the timing will be reset and restarted at the next disconnection.

    How to enable DCP

    If you need to turn it on/off, you can contact your client manager for consultation and application. The default time window is 10 seconds.

    Applicable

    Effective for options only.

    tip

    After the request is successfully sent, the system needs a certain time to take effect. It is recommended to query or set again after 10 seconds

    HTTP Request

    POST /derivatives/v3/private/dcp-set-timewindow

    Request Parameters

    ParameterRequiredTypeComments
    timeWindowtrueintegerDisconnection timing window time. [3, 300], unit: second

    Response Parameters

    None

    Request Example

    POST /derivatives/v3/private/dcp-set-timewindow HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675852742375
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "timeWindow": 40
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/delivery.html b/derivatives/unified/delivery.html index 0c46a3df9c..4756555635 100644 --- a/derivatives/unified/delivery.html +++ b/derivatives/unified/delivery.html @@ -4,13 +4,13 @@ Get Option Delivery Record | Bybit API Documentation - +

    Get Option Delivery Record

    Query option delivery records, sort by deliveryTime in descending order

    HTTP Request

    GET /unified/v3/private/delivery-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. option
    symbolfalsestringSymbol name
    expDatefalsestringExpiry date. 25MAR22. Default: return all
    directionfalsestringprev: previous page, next: next page. Default: next
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringCursor. Used to pagination
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > strikestringExercise price
    > feestringTrading fee
    > positionstringExecuted size
    > deliveryTimenumberDelivery time (ms)
    > deliveryPricestringDelivery price
    > deliveryRplstringRealized PnL of the delivery

    Request Example

    GET /unified/v3/private/delivery-record?category=option&limit=5 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020598623
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "45%3A0%2C45%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "BTC-29JUL22-27000-C",
    "side": "Sell",
    "deliveryTime": 1659081601928,
    "strike": "27000",
    "fee": "0.00000000",
    "position": "0.0300",
    "deliveryPrice": "23927.85304688",
    "deliveryRpl": "0.00000000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672020600013
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/exchange.html b/derivatives/unified/exchange.html index baf1521641..61eb3aeb3a 100644 --- a/derivatives/unified/exchange.html +++ b/derivatives/unified/exchange.html @@ -4,13 +4,13 @@ Get Exchange Records | Bybit API Documentation - +

    Get Exchange Records

    Query the coin exchange records.

    HTTP Request

    GET /asset/v2/private/exchange/exchange-order-all

    Request Parameters

    ParameterRequiredTypeComments
    fromCoinfalsestringThe currency to convert from. e.g,BTC
    toCoinfalsestringThe currency to convert to. e.g,USDT

    Response Parameters

    ParameterTypeComments
    totalCountstringRecords size
    orderarrayObject
    > fromCoinstringThe currency to convert from
    > fromAmountstringThe amount to convert from
    > toCoinstringThe currency to convert to
    > toAmountstringThe amount to convert to
    > exchangeRatestringExchange rate
    > createdTimestringExchange created timestamp (ms)
    > exchangeTxIdstringExchange transaction id

    Request Example

    GET /asset/v2/private/exchange/exchange-order-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673079087093
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "order": [
    {
    "fromCoin": "ETH",
    "fromAmount": "0.10000000",
    "toCoin": "XRP",
    "toAmount": "372.37487085",
    "exchangeRate": "3723.74870857",
    "createdTime": "1672989418000",
    "exchangeTxId": "251239533285211865273079980032"
    },
    {
    "fromCoin": "BTC",
    "fromAmount": "0.10000000",
    "toCoin": "ETH",
    "toAmount": "1.38586623",
    "exchangeRate": "13.85866238",
    "createdTime": "1672197760000",
    "exchangeTxId": "145102533285208544812654440448"
    }
    ],
    "totalCount": "2"
    },
    "retExtInfo": {},
    "time": 1673079089361
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/execution-list.html b/derivatives/unified/execution-list.html index e0d955ca21..c64108879b 100644 --- a/derivatives/unified/execution-list.html +++ b/derivatives/unified/execution-list.html @@ -4,13 +4,13 @@ Get Execution Record | Bybit API Documentation - +

    Get Execution Record

    Query users' execution records, sort by execTime in descending order

    tip
    • You may have multiple executions in a single order.
    • This endpoint can query half-year data.

    HTTP Request

    POST /unified/v3/private/execution/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,option
    symbolfalsestringSymbol name
    orderIdfalsestringOrder id
    orderLinkIdfalsestringUser customised order id
    baseCoinfalsestringBase coin. For option only. Return all base coin data if not passed
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    execTypefalsestringExecution type
    directionfalsestringprev: previous page, next: next page. Default: next
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type. linear,option
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder id
    > orderLinkIdstringUser customized order id
    > sidestringSide. Buy,Sell
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > leavesQtystringThe remaining qty not executed
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. If the order is not stop order, any type is not returned
    > execFeestringExecuted trading fee
    > execIdstringExecution id
    > execPricestringExecution price
    > execQtystringExecution qty
    > execTypestringExecuted type
    > execValuestringExecuted order value
    > execTimenumberExecuted timestamp(ms)
    > feeRatestringTrading fee rate
    > blockTradeIdstringParadigm block trade id
    nextPageCursorstringCursor. Used to pagination

    Request Example

    GET /unified/v3/private/execution/list?category=option&symbol=ETH-30DEC22-700-C HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020216382
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "2203%3A0%2C2203%3A0",
    "category": "option",
    "list": [
    {
    "orderType": "Market",
    "symbol": "ETH-30DEC22-700-C",
    "orderLinkId": "",
    "side": "Sell",
    "orderId": "cc8012bc-ddc1-443c-8dd9-88cfb946d3b0",
    "leavesQty": "0.0000",
    "execTime": 1672018465365,
    "execFee": "0.03656010",
    "feeRate": "0.000300",
    "execId": "f4309658-62be-5f2b-b262-852909c45bba",
    "blockTradeId": "",
    "execPrice": "498.00000000",
    "lastLiquidityInd": "TAKER",
    "orderQty": "0.1000",
    "orderPrice": "496.50000000",
    "execValue": "49.80000000",
    "execType": "Trade",
    "execQty": "0.1000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672019908409
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/get-dcp.html b/derivatives/unified/get-dcp.html index cb5544a4fd..5358d1d0d8 100644 --- a/derivatives/unified/get-dcp.html +++ b/derivatives/unified/get-dcp.html @@ -4,13 +4,13 @@ Get DCP Info | Bybit API Documentation - +

    Get DCP Info

    HTTP Request

    GET /derivatives/v3/private/query-dcp-info

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    retCodeintegerResult code
    retMsgstringResult message
    dcpStatusstringDCP status. ON, OFF
    timeWindowstringDCP time window (second)

    請求示例

    GET /derivatives/v3/private/query-dcp-info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675861979020
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "dcpStatus": "ON",
    "timeWindow": "40"
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/get-mmp-state.html b/derivatives/unified/get-mmp-state.html index 786ac276df..cc28661b02 100644 --- a/derivatives/unified/get-mmp-state.html +++ b/derivatives/unified/get-mmp-state.html @@ -4,13 +4,13 @@ Get MMP State | Bybit API Documentation - +

    Get MMP State

    HTTP Request

    GET /unified/v3/private/account/mmp-state

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin

    Response Parameters

    ParameterTypeComments
    resultarrayObject
    > baseCoinstringBase coin
    > mmpEnabledbooleanWhether the account is enabled mmp
    > windowstringTime window (ms)
    > frozenPeriodstringFrozen period (ms)
    > qtyLimitstringTrade qty limit
    > deltaLimitstringDelta limit
    > mmpFrozenUntilstringUnfreeze timestamp (ms)
    > mmpFrozenbooleanWhether the mmp is triggered.
    • true: mmpFrozenUntil is meaningful
    • false: please ignore the value of mmpFrozenUntil

    Request Example

    POST /unified/v3/private/account/mmp-state HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "result": [
    {
    "baseCoin": "BTC",
    "mmpEnabled": true,
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "0.01",
    "deltaLimit": "0.01",
    "mmpFrozenUntil": "1675760625519",
    "mmpFrozen": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675843188984
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/leverage.html b/derivatives/unified/leverage.html index 98edf78c46..c5976bd455 100644 --- a/derivatives/unified/leverage.html +++ b/derivatives/unified/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set the leverage.

    HTTP Request

    POST /unified/v3/private/position/set-leverage

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear only
    symboltruestringSymbol name
    buyLeveragetruestring(0, allowed max leverage of corresponding risk limit]
    sellLeveragetruestring(0, allowed max leverage of corresponding risk limit]

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/position/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016383313
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "ARUSDT",
    "buyLeverage": "11",
    "sellLeverage": "11"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016384347
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/open-order.html b/derivatives/unified/open-order.html index 8ed8031603..002c4f00fa 100644 --- a/derivatives/unified/open-order.html +++ b/derivatives/unified/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    tip

    Query unfilled or partially filled orders in real-time.

    • At most 500 unfilled or partially filled orders will be returned if neither orderId nor orderLinkId is passed.
    • The records are sort by the createdTime from newest to oldest.

    HTTP Request

    GET /unified/v3/private/order/unfilled-orders

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Ifcategory=option,then it returns BTC data when this field is not passed
    orderIdfalsestringOrder id
    orderLinkIdfalsestringUser customised order id
    orderFilterfalsestringOrder: active order, StopOrder: conditional order
    directionfalsestringPage direction. prev, next. Default: next
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringRefer to the cursor request parameter
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > blockTradeIdstringParadigm block trade ID
    > symbolstringSymbol name
    > ivstringImplied volatility. linear does not have this field
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > orderStatusstringOrder status
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. option does not have this field
    > cumExecValuestringCumulative executed order value
    > cumExecFeestringCumulative executed trading fee
    > cumExecQtystringCumulative executed order qty
    > tpTriggerBystringThe price type to trigger take profit. option does not have this field
    > slTriggerBystringStop loss price. option does not have this field
    > timeInForcestringTime in force
    > basePricestringBase price
    > triggerBystringThe price type of trigger price. option does not have this field
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price. option does not have this field
    > leavesQtystringThe remaining qty not executed
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. option does not have this field
    > takeProfitstringTake profit price. option does not have this field
    > stopLossstringStop loss price. option does not have this field
    > orderIMstringOrder initial margin. For portfolio margin mode, it returns ""
    > createdTimenumberOrder created timestamp (ms)
    > updatedTimenumberOrder updated timestamp (ms)

    Request Example

    GET /unified/v3/private/order/unfilled-orders?category=option&baseCoin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673079658059
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "d00b5b7b-4e05-4a12-a81c-8afb6ddf76bc%3A1673079539417%2Cd00b5b7b-4e05-4a12-a81c-8afb6ddf76bc%3A1673079539417",
    "category": "linear",
    "list": [
    {
    "symbol": "MATICUSDT",
    "orderType": "Limit",
    "orderLinkId": "",
    "orderId": "d00b5b7b-4e05-4a12-a81c-8afb6ddf76bc",
    "stopOrderType": "UNKNOWN",
    "orderStatus": "New",
    "takeProfit": "",
    "cumExecValue": "0.00000000",
    "blockTradeId": "",
    "price": "1.00000000",
    "createdTime": 1673079539417,
    "tpTriggerBy": "UNKNOWN",
    "timeInForce": "PostOnly",
    "basePrice": "",
    "updatedTime": 1673079539426,
    "side": "Sell",
    "triggerPrice": "",
    "cumExecFee": "0.00000000",
    "slTriggerBy": "UNKNOWN",
    "leavesQty": "500.0000",
    "closeOnTrigger": true,
    "cumExecQty": "0.00000000",
    "reduceOnly": true,
    "qty": "500.0000",
    "stopLoss": "",
    "triggerBy": "UNKNOWN",
    "orderIM": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673079551691
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/order-list.html b/derivatives/unified/order-list.html index 5e0e8ce291..121190248a 100644 --- a/derivatives/unified/order-list.html +++ b/derivatives/unified/order-list.html @@ -4,14 +4,14 @@ Get Order List | Bybit API Documentation - +

    Get Order List

    tip

    Query order list.
    As order creation/cancellation is asynchronous, the data returned from this endpoint may delay.

    HTTP Request

    GET /unified/v3/private/order/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Ifcategory=option,then it returns BTC data when this field is not passed
    orderIdfalsestringOrder id
    orderLinkIdfalsestringUser customised order id
    orderStatusfalsestringReturn all status orders if not passed. You could pass multiple status, separated by comma
    orderFilterfalsestringOrder: active order, StopOrder: conditional order
    directionfalsestringPage direction. prev, next. Default: next
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringRefer to the cursor request parameter
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > blockTradeIdstringParadigm block trade ID
    > symbolstringSymbol name
    > ivstringImplied volatility. linear does not have this field
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > orderStatusstringOrder status
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. option does not have this field
    > rejectReasonstringThe reason of rejection
    > cumExecValuestringCumulative executed order value
    > cumExecFeestringCumulative executed trading fee
    > cumExecQtystringCumulative executed order qty
    > tpTriggerBystringThe price type to trigger take profit. option does not have this field
    > slTriggerBystringStop loss price. option does not have this field
    > timeInForcestringTime in force
    > basePricestringBase price
    > triggerBystringThe price type of trigger price. option does not have this field
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price. option does not have this field
    > leavesQtystringThe remaining qty not executed
    > leavesValuestringThe remaining value not executed. option does not have this field
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. option does not have this field
    > takeProfitstringTake profit price. option does not have this field
    > stopLossstringStop loss price. option does not have this field
    > orderIMstringOrder initial margin. For portfolio margin mode, it returns ""
    > createdTimenumberOrder created timestamp (ms)
    > updatedTimenumberOrder updated timestamp (ms)

    Request Example

    GET /unified/v3/private/order/list?category=linear&orderFilter=StopOrder&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672811957817
    X-BAPI-RECV-WINDOW: 5000
    cdn-request-id: test-002

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "c6f055d9-7f21-4079-913d-e6523a9cfffa%3A1672216686849%2Cc6f055d9-7f21-4079-913d-e6523a9cfffa%3A1672216686849",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Limit",
    "orderLinkId": "linear-004",
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "stopOrderType": "Stop",
    "orderStatus": "Deactivated",
    "takeProfit": "",
    "cumExecValue": "0",
    "blockTradeId": "",
    "rejectReason": "EC_NoError",
    "price": "1050",
    "createdTime": 1672216686849,
    "tpTriggerBy": "UNKNOWN",
    "timeInForce": "GoodTillCancel",
    "basePrice": "1188",
    "leavesValue": "0",
    "updatedTime": 1672217377166,
    "side": "Sell",
    "triggerPrice": "1145.00000000",
    "cumExecFee": "0",
    "slTriggerBy": "UNKNOWN",
    "leavesQty": "0",
    "closeOnTrigger": false,
    "cumExecQty": "0",
    "reduceOnly": false,
    "qty": "0.15",
    "stopLoss": "",
    "triggerBy": "MarkPrice",
    "orderIM": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672811958171
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/place-order.html b/derivatives/unified/place-order.html index a579178eb4..24164b97f7 100644 --- a/derivatives/unified/place-order.html +++ b/derivatives/unified/place-order.html @@ -4,7 +4,7 @@ Place Order | Bybit API Documentation - + @@ -20,7 +20,7 @@ ID to cancel active orders. Meanwhile, your customized order ID should be no longer than 36 characters and should be unique.

  • Each account can hold a maximum of 500 active orders simultaneously. This is contract-specific, so the following situation is allowed: The same account can hold 300 BTCUSD active orders and 280 ETHUSD active orders at the same time. When the upper limit of orders is reached, you can still place orders with parameters of reduceOnly or closeOnTrigger.

  • HTTP Request

    POST /unified/v3/private/order/create

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symboltruestringSymbol name
    sidetruestringBuy, Sell
    orderTypetruestringMarket, Limit
    qtytruestringOrder quantity
    pricefalsestringOrder price. Invalid if orderType=Market
    basePricefalsestring
    • Used to compare with triggerPrice, to decide whether your conditional order will be triggered by crossing trigger price from upper side or lower side.
    • Mainly used to identify the expected direction of the current conditional order.
    triggerPricefalsestringIf you expect the price to rise to trigger your conditional order, make sure:
    triggerPrice > max(market price, basePrice)
    Else, triggerPrice < min(market price, basePrice)
    triggerByfalsestringTrigger price type. LastPrice, IndexPrice, MarkPrice
    orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed
    timeInForcetruestringTime in force. GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly
    positionIdxfalseintegerPosition mode. 0: one-way mode.
    orderLinkIdfalsestringUser customised order id. A max of 36 characters. Combinations of numbers, letters (upper and lower cases), dashes, and underscores are supported.
    rule of future:
    • optional param
    • The same orderLinkId can be used for both USDC PERP and USDT PERP.
    • An orderLinkId can be reused once the original order is either Filled or Cancelled
    • rule of option:
    • required param
    • always unique
    takeProfitfalsestringTake profit price
    stopLossfalsestringStop loss price
    tpTriggerByfalsestringThe price type to trigger take profit. MarkPrice, IndexPrice, default:LastPrice
    slTriggerByfalsestringThe price type to trigger stop loss. MarkPrice, IndexPrice, default:LastPrice
    reduceOnlyfalsebooleanWhat is a reduce-only order? true means your position can only reduce in size if this order is triggered. When reduce_only is true, take profit/stop loss cannot be set
    closeOnTriggerfalsebooleanWhat is a close on trigger order? For a closing order. It can only reduce your position, not increase it. If the account has insufficient available balance when the closing order is triggered, then other active orders of similar contracts will be cancelled or reduced. It can be used to ensure your stop loss reduces your position regardless of current available margin.
    mmpfalsebooleanMarket maker protection. true means this order is a market maker protection order

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/create' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.01",
    "price": "20002",
    "timeInForce": "GoodTillCancel",
    "category": "linear"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "e10b0716-7c91-4091-b98a-1fa0f401c7d5",
    "orderLinkId": "test0000003"
    },
    "retExtInfo": {},
    "time": 1664441344238
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/position-info.html b/derivatives/unified/position-info.html index ad9ca72e75..d9bb62e910 100644 --- a/derivatives/unified/position-info.html +++ b/derivatives/unified/position-info.html @@ -4,13 +4,13 @@ My Position | Bybit API Documentation - +

    My Position

    Get real-time position data

    HTTP Request

    GET /unified/v3/private/position/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin.
    • category=option, then BTC records returned by default
    settleCoinfalsestringSettle coin
    directionfalsestringPage direction. prev, next. default: next
    limitfalseintegerLimit for data size per page. [1, 200]. default: 20
    cursorfalsestringCursor. Used to pagination

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringCursor. Used to pagination
    categorystringProducts category
    listarrayObject
    > symbolstringSymbol name
    > leveragestringLeverage value. For portfolio margin mode, it returns "", which the leverage rule is invalid
    > updatedTimeintegerUpdate time of position (ms)
    > sidestring`Buy`, `Sell`
    > positionValuestringTotal value of position
    > takeProfitstringTake profit price
    > tpslModestringTp/SL mode. `Partial`, `Full`
    > riskIdintegerRisk limit ID. For portfolio margin mode, it returns 0, which the risk limit rule is invalid
    > trailingStopstringTrailing stop (the distance from the current price)
    > entryPricestringAverage entry price
    > unrealisedPnlstringUnrealised pnl
    > markPricestringMark price
    > sizestringPosition size
    > stopLossstringStop loss price
    > cumRealisedPnlstringCumulative realised profit and loss
    > positionMMstringPosition maintenance margin. For portfolio margin mode, it returns ""
    > createdTimeintegerCreated time (ms)
    > positionIdxintegerPosition idx, used to identify positions in different position modes
  • `0`: One-Way Mode
  • > positionIMstringPosition initial margin. For portfolio margin mode, it returns ""

    Request Example

    GET /unified/v3/private/position/list?category=linear&symbol=XRPUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672820718517
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "updateAt%3D1672819200214",
    "category": "linear",
    "list": [
    {
    "symbol": "XRPUSDT",
    "updatedTime": 1672819200214,
    "leverage": "10",
    "side": "Buy",
    "positionValue": "34.91000000",
    "takeProfit": "",
    "tpslMode": "Partial",
    "riskId": 41,
    "trailingStop": "0",
    "entryPrice": "0.34910000",
    "unrealisedPnl": "0.00000000",
    "markPrice": "0.34910000",
    "size": "100.0000",
    "cumRealisedPnl": "-0.02444200",
    "stopLoss": "",
    "positionMM": "0.36795140",
    "createdTime": 1672016298024,
    "positionIdx": 0,
    "positionIM": "3.50985140"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672820720159
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/replace-order.html b/derivatives/unified/replace-order.html index 2ef990ee0d..47f9a55cc5 100644 --- a/derivatives/unified/replace-order.html +++ b/derivatives/unified/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +

    Replace Order

    caution

    You could modify those unfilled or partially filled orders.

    HTTP Request

    POST /unified/v3/private/order/replace

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    symboltruestringSymbol name
    orderIdfalsestringOrder id. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order id. Either orderId or orderLinkId is required
    orderFilterfalsestringOrder: active order, StopOrder: conditional order
    orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed
    triggerPricefalsestringIf you expect the price to rise to trigger your conditional order, make sure:
    triggerPrice > max(market price, basePrice) Else,
    triggerPrice < min(market price, basePrice)
    qtyfalsestringOrder quantity after modification. Don't pass it if not modify the qty
    pricefalsestringOrder price after modification. Don't pass it if not modify the price
    takeProfitfalsestringTake profit price after modification. Don't pass it if not modify the take profit
    stopLossfalsestringStop loss price after modification. Don't pass it if not modify the Stop loss
    tpTriggerByfalsestringThe price type to trigger take profit. When set a take profit, this param is required if no initial value for the order
    slTriggerByfalsestringThe price type to trigger stop loss. When set a stop loss, this param is required if no initial value for the order
    triggerByfalsestringTrigger price type

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order id

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/replace' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "category": "linear",
    "symbol":"BTCUSDT",
    "orderId":"1a1ae001-2034-4a6b-8b25-45aa9100b1ec",
    "price":"35000"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1a1ae001-2034-4a6b-8b25-45aa9100b1ec",
    "orderLinkId": "e80d558e-ed"
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/reset-mmp.html b/derivatives/unified/reset-mmp.html index ea9a0ab9fe..dc54f87e32 100644 --- a/derivatives/unified/reset-mmp.html +++ b/derivatives/unified/reset-mmp.html @@ -4,13 +4,13 @@ Reset MMP | Bybit API Documentation - +

    Reset MMP

    info

    Once the mmp triggered, you can unfreeze the account by this endpoint

    HTTP Request

    POST /unified/v3/private/account/mmp-reset

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/risk-limit.html b/derivatives/unified/risk-limit.html index 06154e1804..6eff7516f2 100644 --- a/derivatives/unified/risk-limit.html +++ b/derivatives/unified/risk-limit.html @@ -4,7 +4,7 @@ Set Risk Limit | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Set Risk Limit

    The risk limit will limit the maximum position value you can hold under different margin requirements. If you want to hold a bigger position size, you need more margin. This interface can set the risk limit of a single position. If the order exceeds the current risk limit when placing an order, it will be rejected. Click here to learn more about risk limit.

    tip

    Set the risk limit of the position. You could get risk limit information of each symbol here.

    HTTP Request

    POST /unified/v3/private/position/set-risk-limit

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear only
    symboltruestringSymbol name
    riskIdtrueintegerRisk id
    positionIdxfalseintegerPosition index. 0: one-way mode

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016123862
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "riskId": 2,
    "positionIdx": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016125676
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/set-mmp.html b/derivatives/unified/set-mmp.html index 9dc1d0c87e..36ad903bbd 100644 --- a/derivatives/unified/set-mmp.html +++ b/derivatives/unified/set-mmp.html @@ -4,7 +4,7 @@ Set MMP | Bybit API Documentation - + @@ -16,7 +16,7 @@ and new orders tagged as MMP will be rejected for a specific duration — known as the frozen period — so that MM can reassess the market and modify the quotes.

    How to enable MMP

    Send an email to Bybit (financial.inst@bybit.com) or contact your business development (BD) manager to apply for MMP. After processed, the default settings are as below table:

    ParameterTypeCommentsDefault value
    baseCoinstringBase coinBTC
    windowstringTime window (millisecond)5000
    frozenPeriodstringFrozen period (millisecond)100
    qtyLimitstringQuantity limit100
    deltaLimitstringDelta limit100

    Applicable

    Effective for options only. When you place an option order, set mmp=true, which means you mark this order as a mmp order.

    HTTP Request

    POST /unified/v3/private/account/mmp-modify

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin
    windowtruestringTime window (ms)
    frozenPeriodtruestringFrozen period (ms). "0" means the trade will remain frozen until manually reset
    qtyLimittruestringTrade qty limit (positive and up to 2 decimal places)
    deltaLimittruestringDelta limit (positive and up to 2 decimal places)

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/account/mmp-modify HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675833524616
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "baseCoin": "ETH",
    "window":"5000",
    "frozenPeriod":"100000",
    "qtyLimit":"50",
    "deltaLimit":"20"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/settlement.html b/derivatives/unified/settlement.html index 8413a44c39..8df31bda4c 100644 --- a/derivatives/unified/settlement.html +++ b/derivatives/unified/settlement.html @@ -4,13 +4,13 @@ Get USDC Perpetual Settlement | Bybit API Documentation - +

    Get USDC Perpetual Settlement

    Query session settlement records of USDC perpetual

    HTTP Request

    GET /unified/v3/private/settlement-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear
    symbolfalsestringSymbol name
    directionfalsestringprev: previous page, next: next page. Default: next
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringCursor. Used to pagination
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > sizestringPosition size
    > sessionAvgPricestringSettlement price
    > markPricestringMark price
    > realisedPnlstringRealised PnL
    > timestringSettlement timestamp (ms)

    Request Example

    GET /unified/v3/private/settlement-record?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020804664
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "1516%3A0%2C1516%3A0",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "0.72230000",
    "symbol": "BTCPERP",
    "side": "Buy",
    "markPrice": "19769.82000000",
    "size": "0.0100",
    "time": "1666828800000",
    "sessionAvgPrice": "19769.82000000"
    },
    ]
    },
    "retExtInfo": {},
    "time": 1672020805170
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/tp-sl-mode.html b/derivatives/unified/tp-sl-mode.html index 8facacb5f1..d3288c38db 100644 --- a/derivatives/unified/tp-sl-mode.html +++ b/derivatives/unified/tp-sl-mode.html @@ -4,13 +4,13 @@ Switch TP/SL Mode | Bybit API Documentation - +

    Switch TP/SL Mode

    Set take profit / stop loss mode of the position, such as FULL TP/SL mode or PARTIAL TP/SL mode

    HTTP Request

    POST /unified/v3/private/position/tpsl/switch-mode

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear only
    symboltruestringSymbol name
    tpSlModetruestringFull, Partial

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/position/tpsl/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016302990
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol":"XRPUSDT",
    "tpSlMode":"Partial"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016303452
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/trading-stop.html b/derivatives/unified/trading-stop.html index 40dc525590..970af9535b 100644 --- a/derivatives/unified/trading-stop.html +++ b/derivatives/unified/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +

    Set Trading Stop

    tip

    Pass the following parameters, then the system will create conditional orders. If the position is closed, the system will cancel these orders, and adjust the position size.

    HTTP Request

    POST /unified/v3/private/position/trading-stop

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear
    symboltruestringSymbol name
    takeProfitfalsestringCannot be less than 0, 0 means cancel TP
    stopLossfalsestringCannot be less than 0, 0 means cancel SL
    trailingStopfalsestringCannot be less than 0, 0 means cancel TS. note: valid for USDT Perpetual only
    tpTriggerByfalsestringTake profit trigger price type. default: LastPrice
    slTriggerByfalsestringStop loss trigger price type. default: LastPrice
    activePricefalsestringTrailing stop trigger price. Trailing stop will be triggered when this price is reached only
    tpSizefalsestringTake profit size. Valid in TP/SL partial mode
    slSizefalsestringStop loss size. Valid in TP/SL partial mode
    positionIdxtrueintegerUsed to identify positions in different position modes. 0: one-way mode for unified margin only

    Response Parameters

    None

    Request Example

    POST /unified/v3/private/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXX
    X-BAPI-API-KEY: XXXX
    X-BAPI-TIMESTAMP: 1672017116301
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol":"BTCUSDT",
    "takeProfit":"18000",
    "stopLoss":"15500",
    "tpTriggerBy":"MarkPrice",
    "slTriggerBy":"MarkPrice",
    "trailingStop": null,
    "activePrice": null,
    "slSize": "0.05",
    "tpSize": "0.1",
    "positionIdx": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672017116958
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/transaction-log.html b/derivatives/unified/transaction-log.html index 6f99adad0a..0e9637bb3b 100644 --- a/derivatives/unified/transaction-log.html +++ b/derivatives/unified/transaction-log.html @@ -4,13 +4,13 @@ Transaction Log | Bybit API Documentation - +

    Transaction Log

    Query transaction logs in Unified account.

    HTTP Request

    GET /unified/v3/private/account/transaction-log

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,option
    currencytruestringUSDC、USDT、BTC、ETH
    baseCoinfalsestringbaseCoin
    typefalsestringAll transaction logs under this category are returned (except transfer/exchange/given cash). Note: To query transfer-in and transfer-out logs, type=TRANSFER_IN, type=TRANSFER_OUT must be passed, otherwise the transfer log cannot be found.
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    directionfalsestringDirection: prev: previous page, next: next page, Default: next
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    currencystringUSDC、USDT、BTC、ETH
    listarrayObject
    > transactionTimenumberTransaction timestamp (ms)
    > typestringType
    > symbolstringSymbol name
    > sidestringSide. Buy,Sell,None
    > qtystringQuantity
    > sizeintegerSize
    > tradePricestringTrade price
    > fundingstringFunding fee
    > feestringTrading fee,fees are positive and rebates are negative
    > cashFlowstringCash flow
    > changestringChange
    > cashBalancestringCash balance
    > feeRatestringTrading fee rate
    > tradeIdstringTrade id
    > orderIdstringOrder id
    > orderLinkIdstringUser customised order id
    nextPageCursorstringCursor. Used to pagination

    Request Example

    GET /unified/v3/private/account/transaction-log?category=linear&currency=USDC&limit=1&type=SETTLEMENT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023156071
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "1516%3A0%2C1516%3A0",
    "currency": "USDC",
    "category": "linear",
    "list": [
    {
    "symbol": "BTCPERP",
    "side": "None",
    "funding": "0.00000000",
    "orderLinkId": "",
    "orderId": "",
    "fee": "",
    "change": "0.00000000",
    "cashFlow": "0.00000000",
    "transactionTime": 1666857600000,
    "type": "SETTLEMENT",
    "feeRate": "",
    "size": "0.0000",
    "qty": "",
    "cashBalance": "22.96780168",
    "tradePrice": "",
    "tradeId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672023157776
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/upgrade.html b/derivatives/unified/upgrade.html index d9933ae226..43324dfe67 100644 --- a/derivatives/unified/upgrade.html +++ b/derivatives/unified/upgrade.html @@ -4,13 +4,13 @@ Upgrade To Unified Margin Account | Bybit API Documentation - +

    Upgrade To Unified Margin Account

    Upgrade to unified margin account (UMA)

    HTTP Request

    POST /unified/v3/private/account/upgrade-unified-account

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    statusstringUpgrade status
    > relieveLimitBizResponsearrayempty array if request success
    >> relieveLimitCodestringFail code
    >> relieveLimitMsgstringFail message
    >> relieveLimitMobileUrlstring""
    >> relieveLimitWebUrlstring""
    >> passbooleanwhether to pass the requirement

    Request Example

    POST /unified/v3/private/account/upgrade-unified-account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672022838777
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {}

    Response Example

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "result": {
    "status": "FAIL",
    "relieveLimitBizResponse": [
    {
    "relieveLimitCode": "3400071",
    "relieveLimitMsg": "unable to upgrade as you haven’t met the minimum asset requirement.",
    "relieveLimitMobileUrl": "",
    "relieveLimitWebUrl": "",
    "pass": false
    },
    {
    "relieveLimitCode": "3400051",
    "relieveLimitMsg": "unable to upgrade, please close the usdt perpetual positions in USDT account.",
    "relieveLimitMobileUrl": "",
    "relieveLimitWebUrl": "",
    "pass": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672022840011
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/usc-account-info.html b/derivatives/unified/usc-account-info.html index d39750be51..d7f5c6ef97 100644 --- a/derivatives/unified/usc-account-info.html +++ b/derivatives/unified/usc-account-info.html @@ -4,13 +4,13 @@ Account Info | Bybit API Documentation - +

    Account Info

    Query the configuration under the account.

    HTTP Request

    GET /unified/v3/private/account/info

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    unifiedMarginStatusintegerAccount status
    marginModestringREGULAR_MARGIN, PORTFOLIO_MARGIN
    dcpStatusstringDisconnected-CancelAll-Prevention status: ON, OFF
    timeWindowintegerDCP trigger time window which user pre-set. Between [10, 300] seconds, default: 10 sec
    smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    updatedTimestringAccount data updated timestamp (ms)

    Request Example

    GET /unified/v3/private/account/info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023630281
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginMode": "REGULAR_MARGIN",
    "updatedTime": "1672918286000",
    "unifiedMarginStatus": 3,
    "dcpStatus": "ON",
    "timeWindow": 30,
    "smpGroup": 0
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/usc-margin-mode.html b/derivatives/unified/usc-margin-mode.html index d2b32aab04..55cba30944 100644 --- a/derivatives/unified/usc-margin-mode.html +++ b/derivatives/unified/usc-margin-mode.html @@ -4,13 +4,13 @@ Set Margin Mode | Bybit API Documentation - +

    Set Margin Mode

    Default is the regular margin mode. This mode is valid for USDT Perp, USDC Perp and Option.

    HTTP Request

    POST /unified/v3/private/account/setMarginMode

    Request Parameters

    ParameterRequiredTypeComments
    setMarginModetruestringREGULAR_MARGIN, PORTFOLIO_MARGIN

    Response Parameters

    ParameterTypeComments
    reasonsarrayEmpty array if the request is submitted successfully. Otherwise, there are failure Object
    > reasonCodestringFail reason code
    > reasonMsgstringFail reason msg

    Request Example

    POST /unified/v3/private/account/setMarginMode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023475526
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "setMarginMode": "REGULAR_MARGIN"
    }

    Response Example

    {
    "retCode": 3400045,
    "retMsg": "Set margin mode failed",
    "result": {
    "reasons": [
    {
    "reasonCode": "3400102",
    "reasonMsg": "Please ensure that there are no active orders in your USDC account, including Limit, Market and Conditional orders"
    },
    {
    "reasonCode": "3400101",
    "reasonMsg": "Please ensure that there are no positions in your USDC account, including USDC perpetual and options"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/unified/wallet.html b/derivatives/unified/wallet.html index 8a04371295..adb082830a 100644 --- a/derivatives/unified/wallet.html +++ b/derivatives/unified/wallet.html @@ -4,13 +4,13 @@ Wallet Balance | Bybit API Documentation - +

    Wallet Balance

    Get wallet balance

    HTTP Request

    GET /unified/v3/private/account/wallet/balance

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    accountIMRatestringInitial Margin Rate: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    accountMMRatestringMaintenance Margin Rate: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalEquitystringEquity of account converted to usd:Account Margin Balance Base Coin + Account Option Value Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalWalletBalancestringWallet Balance of account converted to usd:∑ Asset Wallet Balance Base Coin。In non-uniform margin mode, the field will be returned as an empty string.
    totalMarginBalancestringMargin Balance of account converted to usd:Account Wallet Balance Base Coin + Account Perp UPL Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalAvailableBalancestringAvailable Balance of account converted to usd:RM:Account Margin Balance Base Coin - Account Initial Margin Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalPerpUPLstringUnrealised P&L of perpetuals of account converted to usd:∑ Asset Perp UPL Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalInitialMarginstringInitial Margin of account converted to usd:∑ Asset Total Initial Margin Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    totalMaintenanceMarginstringMaintenance Margin of account converted to usd: ∑ Asset Total Maintenance Margin Base Coin. In non-uniform margin mode, the field will be returned as an empty string.
    coinarrayObject
    > currencyCoinstringCoin name, such as BTC, ETH, USDT, USDC
    > availableToBorrowstringDepreciated field, always return "" due to feature of main-sub uid sharing borrow quota
    > borrowSizestringLending amount used. For USDC and USDT only. For BTC and ETH, return 0
    > bonusstringTrial fund
    > accruedIntereststringAccrued interest of an asset
    > availableBalanceWithoutConvertstringAvailable balance, Margin Balance - Total Initial Margin
    > totalOrderIMstringOrder margin pre-occupied. For portfolio margin mode, it returns ""
    > equitystringEquity
    > totalPositionMMstringSum of maintenance margin for all positions. For portfolio margin mode, it returns ""
    > usdValuestringusd value
    > availableBalancestringAB from other assets + the actual AB balance from the current assets (cannot be negative)
    > unrealisedPnlstringUnrealised P&L
    > totalPositionIMstringSum of initial margin of all positions + Pre-occupied liquidation fee. For portfolio margin mode, it returns ""
    > marginBalanceWithoutConvertstringMargin balance
    > walletBalancestringWallet balance
    > cumRealisedPnlstringCumulative Realised P&L
    > marginBalancestringMB from other assets + the actual MB balance from the current assets

    Request Example

    GET /unified/v3/private/account/wallet/balance?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672021457498
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "totalEquity": "5952.13539158",
    "accountIMRate": "0.1037",
    "totalMarginBalance": "6003.96034690",
    "totalInitialMargin": "622.37237856",
    "totalAvailableBalance": "5381.58796835",
    "accountMMRate": "0.0361",
    "totalPerpUPL": "-733.16272882",
    "totalWalletBalance": "6733.45726207",
    "totalMaintenanceMargin": "216.49590186",
    "coin": [
    {
    "currencyCoin": "ETH",
    "availableToBorrow": "0.00000000",
    "borrowSize": "0.00000000",
    "bonus": "0.00000000",
    "accruedInterest": "0.00000000",
    "availableBalanceWithoutConvert": "0.00000000",
    "totalOrderIM": "",
    "equity": "0.00000000",
    "totalPositionMM": "",
    "usdValue": "0.00000000",
    "availableBalance": "4.41128415",
    "unrealisedPnl": "",
    "totalPositionIM": "",
    "marginBalanceWithoutConvert": "0.00000000",
    "walletBalance": "0.00000000",
    "cumRealisedPnl": "",
    "marginBalance": "4.92144238"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672021457963
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-contract/execution.html b/derivatives/ws-contract/execution.html index 074ab0e73a..864b8702ee 100644 --- a/derivatives/ws-contract/execution.html +++ b/derivatives/ws-contract/execution.html @@ -4,14 +4,14 @@ Execution | Bybit API Documentation - +

    Execution

    Subscribe to the execution stream to see when an open order gets filled or partially filled.

    Covers: USDT Perpetual, Inverse Perpetual, Inverse Future

    Push frequency: real-time

    Topic: user.execution.contractAccount

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    dataarrayObject
    > symbolstringSymbol name
    > sidestringSide. Buy,Sell
    > execIdstringtransaction ID
    > feeRatestringTrading fee rate
    > execFeestringExecuted fee
    > execPricestringExecuted price
    > execQtystringExecuted qty
    > leavesQtystringRemaining order qty waiting to be executed
    > execTypestringExecuted type
    > execValuestringExecuted value
    > lastLiquidityIndstringLiquidity index. AddLiquidity,RemovedLiquidity
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. No stop order type if the order is not stop order
    > execTimestringTransaction timestamp (ms)
    > closedSizestringPosition size to be closed
    > blockTradeIdstringParadigm block trade ID
    > markPricestringMark price

    Stream Example

    {
    "topic": "user.execution.contractAccount",
    "data": [
    {
    "symbol": "ETHUSDT",
    "execFee": "0.1017888",
    "execId": "8b4b2e8c-caa1-5fde-be59-d483166885e7",
    "execPrice": "1696.48",
    "execQty": "0.1",
    "execType": "Trade",
    "execValue": "169.648",
    "feeRate": "0.0006",
    "lastLiquidityInd": "RemovedLiquidity",
    "leavesQty": "0",
    "orderId": "cd2f6f95-8031-4272-9339-e7054ff56567",
    "orderLinkId": "",
    "orderPrice": "1781.09",
    "orderQty": "0.1",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "side": "Buy",
    "execTime": "1676885237382",
    "closedSize": "0",
    "blockTradeId": "",
    "markPrice": "1696.25"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-contract/order.html b/derivatives/ws-contract/order.html index 0bbb0e7803..116f77a7e7 100644 --- a/derivatives/ws-contract/order.html +++ b/derivatives/ws-contract/order.html @@ -4,14 +4,14 @@ Order | Bybit API Documentation - +

    Order

    Subscribe to the order stream to see new orders, when an order's order status changes, etc.

    Covers: USDT Perpetual, Inverse Perpetual, Inverse Future

    Push frequency: real-time

    Topic: user.order.contractAccount

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    dataarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > sidestringSide. Buy,Sell
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
    > stopOrderTypestringStop order type
    > pricestringOrder price
    > qtystringOrder qty
    > blockTradeIdstringBlock trade ID
    > timeInForcestringTime in force
    > orderStatusstringOrder status
    > positionIdxintegerPosition index. Used to identify positions in different position modes
    > cancelTypestringCancel type
    > rejectReasonstringReject reason
    > avgPricestringAverage filled price. If unfilled, it is ""
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringTake profit price trigger by
    > slTriggerBystringStop loss price trigger by
    > triggerPricestringTrigger price
    > triggerDirectioninteger0: rise, 1: fall
    > triggerBystringTrigger by
    > reduceOnlybooleanReduce only. true means reduce the position
    > closeOnTriggerbooleanClose on trigger
    > leavesQtystringRemaining order qty waiting to be executed
    > leavesValuestringThe remaining value not executed
    > lastExecQtystringLast executed qty
    • If order status is Filled or Partially Filled, then this field means Executed qty
    • If the orders status is Cancelled, then this field means leaves qty
    > lastExecPricestringLast executed price
    > cumExecFeestringCumulative executed trading fee
    > cumExecQtystringCumulative executed qty
    > cumExecValuestringCumulative executed value
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)

    Stream Example

    {
    "topic": "user.order.contractAccount",
    "data": [
    {
    "symbol": "ETHUSDT",
    "orderId": "e62a3099-eced-499f-bd81-185e8747187f",
    "side": "Buy",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "price": "1622.55",
    "qty": "0.2",
    "timeInForce": "ImmediateOrCancel",
    "orderStatus": "Filled",
    "triggerPrice": "0.00",
    "orderLinkId": "",
    "createdTime": "1675999655229",
    "updatedTime": "1675999655232",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "triggerDirection": 0,
    "leavesQty": "0",
    "lastExecQty": "0.2",
    "lastExecPrice": "1545.30",
    "cumExecQty": "0.2",
    "cumExecValue": "309.06",
    "avgPrice": "1545.30",
    "blockTradeId": "",
    "cancelType": "UNKNOWN",
    "cumExecFee": "0.185436",
    "leavesValue": "0",
    "positionIdx": 1,
    "rejectReason": "EC_NoError",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-contract/position.html b/derivatives/ws-contract/position.html index 16a21266d9..58f8a53356 100644 --- a/derivatives/ws-contract/position.html +++ b/derivatives/ws-contract/position.html @@ -4,14 +4,14 @@ Position | Bybit API Documentation - +

    Position

    Subscribe to the position stream to see changes to your position size, position setting changes, etc.

    Covers: USDT Perpetual, Inverse Perpetual, Inverse Future

    Topic: user.position.contractAccount

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    dataarrayObject
    > symbolstringSymbol name
    > riskIdintegerRisk limit id
    > riskLimitValuestringRisk limit value
    > sidestringSide. Buy,Sell
    > sizestringPosition size
    > entryPricestringAverage entry price
    > positionValuestringEntry position value
    > positionIdxintegerPosition idx, used to identify positions in different position modes
    • 0: One-Way Mode
    • 1: Buy side of both side mode
    • 2: Sell side of both side mode
    > tradeModeintegerTrade mode. 0: cross margin, 1: isolated margin
    > autoAddMarginintegerAuto add margin. 0: false, 1: true
    > leveragestringPosition leverage
    > positionBalancestringPosition margin
    > markPricestringMark price
    > liqPricestringLiquidation price. It returns value only when minPrice < liqPrice < maxPrice
    > bustPricestringBankruptcy price
    > tpSlModestringDepreciated, meaningless here, always "Full"
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > trailingStopstringTrailing stop
    > activePricestringTrailing stop trigger price
    > unrealisedPnlstringUnrealised PnL
    > cumRealisedPnlstringCumulative realized P&L
    > occClosingFeestringPosition closing fee occupied
    > sessionAvgPricestringSettlement price
    > positionStatusstringPosition status
    > positionMMstringPosition Initial margin
    > positionIMstringPosition Maintenance margin
    > createdTimestringPosition created timestamp (ms)
    > updatedTimestringPosition data updated timestamp (ms)
    > adlRankIndicatorintegerAuto-deleverage rank indicator. What is Auto-Deleveraging?
    > isReduceOnlybooleanUseful when Bybit lower the risk limit
    • true: Only allowed to reduce the position. You can consider a series of measures, e.g., lower the risk limit, decrease leverage or reduce the position, add margin, or cancel orders, after these operations, you can call confirm new risk limit endpoint to check if your position can be removed the reduceOnly mark
    • false: There is no restriction, and it means your position is under the risk when the risk limit is systematically adjusted
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > mmrSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the MMR will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the MMR had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > leverageSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the leverage will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the leverage had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others

    Stream Example

    {
    "topic": "user.position.contractAccount",
    "data": [
    {
    "positionIdx": 0,
    "riskId": 1,
    "symbol": "ARBUSDT",
    "side": "None",
    "size": "0",
    "positionValue": "0",
    "entryPrice": "0",
    "tradeMode": 0,
    "autoAddMargin": 0,
    "leverage": "10",
    "positionBalance": "0",
    "liqPrice": "",
    "bustPrice": "0.0000",
    "takeProfit": "0.0000",
    "stopLoss": "0.0000",
    "trailingStop": "0.0000",
    "unrealisedPnl": "0",
    "createdTime": "1695115891722",
    "updatedTime": "1697686565866",
    "tpSlMode": "Full",
    "sessionAvgPrice": "0.0000",
    "positionStatus": "Normal",
    "occClosingFee": "0",
    "markPrice": "0.7747",
    "cumRealisedPnl": "21.84890946",
    "activePrice": "0.0000",
    "riskLimitValue": "200000",
    "positionMM": "0",
    "positionIM": "0",
    "adlRankIndicator": 0,
    "isReduceOnly": false,
    "mmrSysUpdateTime": "",
    "leverageSysUpdatedTime": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-contract/wallet.html b/derivatives/ws-contract/wallet.html index 7667f58a41..909d79e815 100644 --- a/derivatives/ws-contract/wallet.html +++ b/derivatives/ws-contract/wallet.html @@ -4,14 +4,14 @@ Wallet | Bybit API Documentation - +

    Wallet

    Subscribe to the wallet stream to see changes to your wallet in real-time.

    Covers: USDT Perpetual, Inverse Perpetual, Inverse Future

    Push frequency: real-time

    Topic: user.wallet.contractAccount

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    dataarrayObject
    > coinstringCoin
    > equitystringEquity
    > walletBalancestringWallet balance
    > positionMarginstringPosition margin
    > availableBalancestringAvailable balance
    > orderMarginstringOrder margin. Margin is occupied by open orders
    > unrealisedPnlstringUnrealised pnl
    > cumRealisedPnlstringCumulative realised pnl

    Stream Example

    {
    "topic": "user.wallet.contractAccount",
    "data": [
    {
    "coin": "USDT",
    "equity": "8538.34927711",
    "walletBalance": "8505.77505604",
    "positionMargin": "58.93257631",
    "availableBalance": "8436.20247873",
    "orderMargin": "10.640001",
    "unrealisedPnl": "32.57422107",
    "cumRealisedPnl": "-195.05231821"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-public/kline.html b/derivatives/ws-public/kline.html index 5a5315feed..a878056190 100644 --- a/derivatives/ws-public/kline.html +++ b/derivatives/ws-public/kline.html @@ -4,14 +4,14 @@ Kline | Bybit API Documentation - +

    Kline

    Covers: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future

    Interval supported:

    • 1 3 5 15 30 60 120 240 360 720minute
    • Dday
    • Wweek
    • Mmonth
    info

    If confirm is true, then the data is a final tick for this interval. Otherwise, it is a snapshot.

    Push frequency: 1-60s

    Topic: kline.{interval}.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject
    > startnumberCandle start timestamp (ms)
    > endnumberCandle end timestamp (ms)
    > intervalstringInterval
    > openstringOpen price
    > closestringClose price. If not closed, it is last price
    > highstringHighest price
    > lowstringLowest price
    > volumestringTrading volume
    > turnoverstringTrading turnover
    > confirmbooleantrue: last tick. false: this is snapshot data
    > timestampnumberThe timestamp (ms) of the last matched order in the candle

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "kline.5.BTCPERP"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "kline.5.BTCPERP",
    "data": [
    {
    "start": 1671187800000,
    "end": 1671188099999,
    "interval": "5",
    "open": "16991",
    "close": "16980.5",
    "high": "16991",
    "low": "16980.5",
    "volume": "2.501",
    "turnover": "42493.2305",
    "confirm": false,
    "timestamp": 1671187815755
    }
    ],
    "ts": 1671187815755,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-public/liquidation.html b/derivatives/ws-public/liquidation.html index 234779304e..ab31139c8e 100644 --- a/derivatives/ws-public/liquidation.html +++ b/derivatives/ws-public/liquidation.html @@ -4,14 +4,14 @@ Liquidation | Bybit API Documentation - +

    Liquidation

    Get recent liquidation orders in Bybit.

    Covers: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future

    Push frequency: real-time

    Topic: liquidation.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject
    > updatedTimenumberData updated timestamp (ms)
    > symbolstringSymbol name
    > sizestringFilled size
    > pricestringFilled price
    > sidestringSide

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "liquidation.GALAUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-public/orderbook.html b/derivatives/ws-public/orderbook.html index e2360465c0..331c656bdf 100644 --- a/derivatives/ws-public/orderbook.html +++ b/derivatives/ws-public/orderbook.html @@ -4,14 +4,14 @@ Orderbook | Bybit API Documentation - +

    Orderbook

    Get different depth

    Covers: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future, Option

    info
    • Once subscribe successfully, you will receive a snapshot first.
    • For snapshot stream, it is sort by order price, which bids is from highest to lowest and asks is from lowest to highest
    • Websocket will keep pushing delta message when orderbook is changed.
    • If you receive a new snapshot data, it is necessary to reset your local orderbook.
    • If there is a problem in bybit end, it will re-send a snapshot, which is promised the latest and accurate.
    tip

    Linear & inverse level 1 data: if 3 seconds have elapsed without a change in the orderbook, a snapshot message will be pushed again.

    Linear & Inverse:

    • Level 1 data, push frequency: 10ms
    • Level 50 data, push frequency: 20ms
    • Level 200 data, push frequency: 100ms
    • Level 500 data, push frequency: 100ms

    Option:

    • Level 25 data, push frequency: 20ms
    • Level 100 data, push frequency: 100ms

    Topic: (note: option has 25 & 100 level only)
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringMessage type. snapshot,delta
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > sStringSymbol name
    > barray<array>Bid array
    >> b[0][0]stringBid price
    >> b[0][1]stringBid size
    > sarray<array>Ask array
    >> s[0][0]stringAsk price
    >> s[0][1]stringAsk size
    > unumberUpdate id, is always in sequence. Occasionally, you'll receive "u"=1, which is a snapshot data due to the restart of the service. So please overwrite the locally saved orderbook
    > seqnumberCross sequence (internal value)

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "orderbook.50.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1671179923028,
    "data": {
    "s": "BTCUSDT",
    "b": [
    [
    "17440.00",
    "40.833"
    ],
    [
    "17439.50",
    "0.513"
    ],
    ...
    [
    "17416.00",
    "6.156"
    ],
    [
    "17415.50",
    "32.268"
    ]
    ],
    "a": [
    [
    "17440.50",
    "78.815"
    ],
    [
    "17441.00",
    "8.858"
    ],
    ...
    [
    "17464.50",
    "4.901"
    ],
    [
    "17465.00",
    "5.744"
    ]
    ],
    "u": 13079592,
    "seq": 22520573250
    }
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-public/ticker.html b/derivatives/ws-public/ticker.html index 51bf660790..b1a40b7344 100644 --- a/derivatives/ws-public/ticker.html +++ b/derivatives/ws-public/ticker.html @@ -4,14 +4,14 @@ Tickers | Bybit API Documentation - +

    Tickers

    Cover: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future, Option

    Get latest information of the symbol

    important
    • Future has snapshot and delta types. If a key does not exist in the field, it means the value is not changed.
    • Option has snapshot data only.

    Push frequency: 100ms

    Topic: tickers.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot,delta
    csintegerCross sequence
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > symbolstringSymbol name
    > tickDirectionstringTick direction
    > price24hPcntstringPercentage change of market price in the last 24 hours
    > lastPricestringLast price
    > prevPrice24hstringMarket price 24 hours ago
    > highPrice24hstringThe highest price in the last 24 hours
    > lowPrice24hstringThe lowest price in the last 24 hours
    > prevPrice1hstringMarket price an hour ago
    > markPricestringMark price
    > indexPricestringIndex price
    > openIntereststringOpen interest size
    > openInterestValuestringOpen interest value
    > turnover24hstringTurnover for 24h
    > volume24hstringVolume for 24h
    > nextFundingTimestringNext funding timestamp (ms)
    > fundingRatestringFunding rate
    > bid1PricestringBest bid price
    > bid1SizestringBest bid size
    > ask1PricestringBest ask price
    > ask1SizestringBest ask size

    Subscription Example

    {
    "op": "subscribe",
    "args": [
    "tickers.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    Stream Example

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "MinusTick",
    "price24hPcnt": "0.017367",
    "lastPrice": "17222.00",
    "prevPrice24h": "16928.00",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17224.40",
    "indexPrice": "17234.84",
    "openInterest": "68795.534",
    "openInterestValue": "1184961795.83",
    "turnover24h": "1572429119.324499",
    "volume24h": "91823.449",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000211",
    "bid1Price": "17222.00",
    "bid1Size": "220.358",
    "ask1Price": "17222.50",
    "ask1Size": "3.902"
    },
    "cs": 24988405605,
    "ts": 1673273043686
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-public/trade.html b/derivatives/ws-public/trade.html index 8bfd210027..07846a2418 100644 --- a/derivatives/ws-public/trade.html +++ b/derivatives/ws-public/trade.html @@ -4,14 +4,14 @@ Public Trade | Bybit API Documentation - +

    Public Trade

    Get recent public trades data in Bybit.

    Cover: USDT Perpetual, USDC Perpetual, Inverse Perpetual, Inverse Future, Option

    info

    After subscription, you will be pushed delta trade message in real-time once there is an order filled.

    Push frequency: real-time

    Topic: publicTrade.{symbol}

    For option, it should use base coin, e.g., publicTrade.BTC

    Response Parameters

    ParameterTypeComments
    idstringMessage id. Unique field for option
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataarrayObject. The element in the array is sort by matching time in ascending order
    > TnumberThe timestamp (ms) that the order is filled
    > sstringSymbol name
    > SstringSide of taker. Buy,Sell
    > vstringqty
    > pstringExecuted price
    > LstringDirection of price change. Unique field for future
    > istringTrade id
    > BTbooleanBlock trade or not

    Request Example

    {
    "op": "subscribe",
    "args": [
    "publicTrade.BTCPERP"
    ],
    "req_id": "test" // optional
    }

    Response Example

    {
    "topic": "publicTrade.BTCPERP",
    "type": "snapshot",
    "ts": 1671181689023,
    "data": [
    {
    "T": 1671181689021,
    "s": "BTCPERP",
    "S": "Buy",
    "v": "0.002",
    "p": "17032.50",
    "L": "MinusTick",
    "i": "d9cd8295-40dc-5dce-8deb-42882580a7ab",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-unified/execution.html b/derivatives/ws-unified/execution.html index 4e49cbc557..a6437825f6 100644 --- a/derivatives/ws-unified/execution.html +++ b/derivatives/ws-unified/execution.html @@ -4,14 +4,14 @@ Execution | Bybit API Documentation - +

    Execution

    Subscribe to the execution stream. Will not push funding payments unless they occur on a USDT perpetual, eg BTCUSDT.

    tip

    You may have multiple pushes for one order.

    Topic:
    user.execution.unifiedAccount

    Response Parameters

    ParameterTypeComments
    idstringMessage id
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > versionintegerVersion
    > resultarrayObject
    >> symbolstringSymbol name
    >> orderIdstringOrder id
    >> sidestringSide. Buy,Sell
    >> orderLinkIdstringUser customized order id
    >> orderPricestringOrder price
    >> orderQtystringOrder qty
    >> orderTypestringOrder type
    >> execIdstringExecution id
    >> execPricestringExecution price
    >> execQtystringExecution qty
    >> execValuestringExecuted order value
    >> feeRatestringTrading fee rate
    >> execFeestringExecuted trading fee
    >> execTimestringExecuted timestamp (ms)
    >> execTypestringExecuted type. TRADE,ADLTRADE,FUNDING,BUSTTRADE,SETTLE
    >> lastLiquidityIndstringLiquidity index. TAKER, MAKER
    >> leavesQtystringThe remaining qty not executed
    >> stopOrderTypestringStop order type. If the order is not stop order, any type is not returned
    >> blockTradeIdstringParadigm block trade ID

    Stream Example

    {
    "id": "533285750bcd0d-6878-4db4-bc15-71207e39acda",
    "topic": "user.execution.unifiedAccount",
    "ts": 1672824334832,
    "data": {
    "result": [
    {
    "symbol": "ARUSDT",
    "execFee": "1.399224",
    "execId": "b90dc5f2-0a01-53e7-b1c5-aa7dfbe774da",
    "execPrice": "6.92",
    "execQty": "337",
    "execType": "TRADE",
    "execValue": "2332.04",
    "feeRate": "0.0006",
    "lastLiquidityInd": "TAKER",
    "leavesQty": "0",
    "orderId": "496929da-6243-4f40-b621-267f9611e565",
    "orderLinkId": "",
    "orderPrice": "6.58",
    "orderQty": "337",
    "orderType": "Market",
    "stopOrderType": "",
    "side": "Sell",
    "execTime": 1672824334817,
    "blockTradeId": ""
    }
    ],
    "version": 177285
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-unified/greek.html b/derivatives/ws-unified/greek.html index 16a3f94f42..22b321ffe6 100644 --- a/derivatives/ws-unified/greek.html +++ b/derivatives/ws-unified/greek.html @@ -4,14 +4,14 @@ Greek | Bybit API Documentation - +

    Greek

    Subscribe to the user greeks stream, option only.

    Topic:
    user.greeks.unifiedAccount

    Response Parameters

    ParameterTypeComments
    idstringMessage id
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > versionintegerVersion
    > resultObject
    >> baseCoinstringBase coin
    >> totalDeltastringDelta value
    >> totalGammastringGamma value
    >> totalVegastringVega value
    >> totalThetastringTheta value

    Stream Example

    {
    "id": "53328593eddf20-ebe8-47d9-8a2b-62e4e2681eaa",
    "topic": "user.greeks.unifiedAccount",
    "ts": 1672107550646,
    "data": {
    "result": [
    {
    "baseCoin": "BTC",
    "totalDelta": "-0.02077347",
    "totalGamma": "-0.00004675",
    "totalVega": "-0.52558304",
    "totalTheta": "3.48921259"
    },
    {
    "baseCoin": "ETH",
    "totalDelta": "0.05003533",
    "totalGamma": "-0.00000063",
    "totalVega": "-0.00014849",
    "totalTheta": "0.0041225"
    }
    ],
    "version": 62056
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-unified/order.html b/derivatives/ws-unified/order.html index 1ba5280db9..c70c8ce09b 100644 --- a/derivatives/ws-unified/order.html +++ b/derivatives/ws-unified/order.html @@ -4,14 +4,14 @@ Order | Bybit API Documentation - +

    Order

    Subscribe to the order stream to see new orders, when an order's order status changes, etc.

    Topic:
    user.order.unifiedAccount

    Response Parameters

    ParameterTypeComments
    idstringMessage id
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > versionintegerVersion
    > resultarrayObject
    >> symbolstringSymbol name
    >> sidestringSide. Buy,Sell
    >> orderIdstringOrder id
    >> orderLinkIdstringUser customised order id
    >> orderTypestringOrder type. Market,Limit
    >> stopOrderTypestringStop order type
    >> orderStatusstringOrder status
    >> pricestringOrder price
    >> qtystringOrder qty
    >> timeInForcestringTime in force
    >> cumExecQtystringCumulative executed order qty
    >> cumExecValuestringCumulative executed order value
    >> cumExecFeestringCumulative executed trading fee
    >> leavesQtystringThe remaining qty not executed
    >> triggerBystringThe price type of trigger price
    >> triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price
    >> reduceOnlybooleanReduce only. true means reduce position size
    >> closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    >> ivstringImplied volatility
    >> orderIMstringOrder initial margin. For portfolio margin mode, it returns ""
    >> takeProfitstringTake profit price
    >> stopLossstringStop loss price
    >> tpTriggerBystringThe price type to trigger take profit
    >> slTriggerBystringThe price type to trigger stop loss
    >> basePricestringBase price
    >> blockTradeIdstringBlock trade ID
    >> createdTimenumberOrder created timestamp (ms)
    >> updatedTimenumberOrder updated timestamp (ms)

    Stream Example

    {
    "id": "533285293a44e9-7925-445c-a62c-01d7726c6543",
    "topic": "user.order.unifiedAccount",
    "ts": 1672063477614,
    "data": {
    "result": [
    {
    "orderId": "38554b22-e4fa-4327-9250-3fc81aa4e30a",
    "orderLinkId": "",
    "symbol": "SCUSDT",
    "side": "Sell",
    "orderType": "Market",
    "price": "0.00224",
    "qty": "100",
    "timeInForce": "ImmediateOrCancel",
    "orderStatus": "Filled",
    "cumExecQty": "100",
    "cumExecValue": "0.234",
    "cumExecFee": "0.0001404",
    "stopOrderType": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "triggerPrice": "0",
    "reduceOnly": true,
    "closeOnTrigger": true,
    "createdTime": 1672063477568,
    "updatedTime": 1672063477578,
    "iv": "",
    "orderIM": "",
    "takeProfit": "0",
    "stopLoss": "0",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "basePrice": "0.00235",
    "blockTradeId": "",
    "leavesQty": "0"
    }
    ],
    "version": 17965
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-unified/position.html b/derivatives/ws-unified/position.html index 103a28d072..61c58617d4 100644 --- a/derivatives/ws-unified/position.html +++ b/derivatives/ws-unified/position.html @@ -4,14 +4,14 @@ Position | Bybit API Documentation - +

    Position

    Subscribe to the position stream to see changes to your position size, position setting changes, etc.

    Topic:
    user.position.unifiedAccount

    Response Parameters

    ParameterTypeComments
    idstringMessage id
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > versionintegerVersion
    > resultarrayObject
    >> symbolstringSymbol name
    >> sidestringPosition side. Buy,Sell
    >> sizestringPosition size
    >> positionIdxintegerUsed to identify positions in different position modes
    >> riskIdintegerRisk limit id. Note: for portfolio margin mode, it returns 0, which the risk limit rule is invalid
    >> leveragestringLeverage. Note: for portfolio margin mode, it returns "", which the leverage rule is invalid
    >> entryPricestringAverage entry price
    >> markPricestringCurrent mark price
    >> positionValuestringPosition value
    >> positionIMstringPosition initial margin. Note: for portfolio margin mode, it returns ""
    >> positionMMstringPosition maintenance margin. Note: for portfolio margin mode, it returns ""
    >> tpslModestringTP/SL mode. Full,Partial
    >> takeProfitstringTake profit price
    >> stopLossstringStop loss price
    >> trailingStopstringTrailing stop
    >> unrealisedPnlstringUnrealised PnL
    >> cumRealisedPnlstringCumulative realised PnL
    >> sessionAvgPricestringSession avg price. option does not have this field
    >> createdTimenumberCreated timestamp (ms)
    >> updatedTimenumberUpdated timestamp (ms)

    Stream Example

    {
    "id": "533285d3534ad0-0cab-477b-95fa-d8efa92e3a00",
    "topic": "user.position.unifiedAccount",
    "ts": 1672103585576,
    "data": {
    "result": [
    {
    "positionIdx": 0,
    "riskId": 11,
    "symbol": "ETHUSDT",
    "side": "Buy",
    "size": "0.15",
    "entryPrice": "1072.54285714",
    "leverage": "11",
    "markPrice": "1215.38",
    "positionIM": "14.71334027",
    "positionMM": "0.89216153",
    "takeProfit": "0",
    "stopLoss": "0",
    "trailingStop": "0",
    "positionValue": "160.88142858",
    "unrealisedPnl": "21.42557142",
    "cumRealisedPnl": "80.35333206",
    "createdTime": 0,
    "updatedTime": 1672103585565,
    "tpslMode": "Partial"
    }
    ],
    "version": 58085
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws-unified/wallet.html b/derivatives/ws-unified/wallet.html index b6079ce706..07c92cecb6 100644 --- a/derivatives/ws-unified/wallet.html +++ b/derivatives/ws-unified/wallet.html @@ -4,14 +4,14 @@ Wallet | Bybit API Documentation - +

    Wallet

    Subscribe to the wallet stream to see changes to your wallet in real-time.

    Topic:
    user.wallet.unifiedAccount

    Response Parameters

    ParameterTypeComments
    idstringMessage id
    topicstringTopic name
    typestringMessage type. snapshot
    tsnumberThe timestamp (ms) that system generates the data.
    dataObject
    > versionintegerVersion
    > resultObject
    >> accountIMRatestringInitial Margin Rate: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin.
    >> accountMMRatestringMaintenance Margin Rate: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin.
    >> totalEquitystringEquity of account converted to usd:Account Margin Balance Base Coin + Account Option Value Base Coin.
    >> totalWalletBalancestringWallet Balance of account converted to usd:∑ Asset Wallet Balance Base Coin
    >> totalMarginBalancestringMargin Balance of account converted to usd:Account Wallet Balance Base Coin + Account Perp UPL Base Coin.
    >> totalAvailableBalancestringAvailable Balance of account converted to usd:RM:Account Margin Balance Base Coin - Account Initial Margin Base Coin.
    >> totalPerpUPLstringUnrealised P&L of perpetuals of account converted to usd:∑ Asset Perp UPL Base Coin.
    >> totalInitialMarginstringInitial Margin of account converted to usd:∑ Asset Total Initial Margin Base Coin.
    >> totalMaintenanceMarginstringMaintenance Margin of account converted to usd: ∑ Asset Total Maintenance Margin Base Coin.
    >> coinarrayObject
    >>> currencyCoinstringCoin name, such as BTC, ETH, USDT, USDC
    >>> equitystringEquity
    >>> usdValuestringusd value
    >>> walletBalancestringWallet balance
    >>> marginBalancestringMB from other assets + the actual MB balance from the current assets
    >>> availableBalancestringAB from other assets + the actual AB balance from the current assets (cannot be negative)
    >>> marginBalanceWithoutConvertstringMargin balance
    >>> availableBalanceWithoutConvertstringAvailable balance, Margin Balance - Total Initial Margin
    >>> borrowSizestringLending amount used. For USDC and USDT only. For BTC and ETH, return 0
    >>> availableToBorrowstringDepreciated field, always return "" due to feature of main-sub uid sharing borrow quota
    >>> accruedIntereststringAccrued interest of an asset
    >>> totalOrderIMstringOrder margin pre-occupied. For portfolio margin mode, it returns ""
    >>> totalPositionIMstringSum of initial margin of all positions + Pre-occupied liquidation fee. For portfolio margin mode, it returns ""
    >>> totalPositionMMstringSum of maintenance margin for all positions. For portfolio margin mode, it returns ""
    >>> unrealisedPnlstringUnrealised P&L
    >>> cumRealisedPnlstringCumulative Realised P&L

    Stream Example

    {
    "id": "5332858071ac1a-adcf-4c22-9967-4bdb763d993d",
    "topic": "user.wallet.unifiedAccount",
    "ts": 1673246212184,
    "data": {
    "result": {
    "accountIMRate": "0.1062",
    "accountMMRate": "0.0126",
    "totalEquity": "5306.99168766",
    "totalWalletBalance": "5015.81303189",
    "totalMarginBalance": "5315.50124767",
    "totalAvailableBalance": "4750.87543737",
    "totalPerpUPL": "299.68821577",
    "totalInitialMargin": "564.62581029",
    "totalMaintenanceMargin": "67.39562585",
    "coin": [
    {
    "currencyCoin": "USDC",
    "equity": "696.90520008",
    "usdValue": "696.90520008",
    "walletBalance": "702.87476009",
    "marginBalance": "5315.50124767",
    "availableBalance": "4750.87543737",
    "marginBalanceWithoutConvert": "705.41476009",
    "availableBalanceWithoutConvert": "472.43375944",
    "borrowSize": "0",
    "availableToBorrow": "1500000",
    "accruedInterest": "0",
    "totalOrderIM": "172.47750096",
    "totalPositionIM": "60.50349967",
    "totalPositionMM": "16.09254346",
    "unrealisedPnl": "-2.07956",
    "cumRealisedPnl": "153.26214849"
    },
    {
    "currencyCoin": "USDT",
    "equity": "2989.97442076",
    "usdValue": "2975.11272839",
    "walletBalance": "2691.34184935",
    "marginBalance": "5330.29357298",
    "availableBalance": "4750.7346256",
    "marginBalanceWithoutConvert": "2989.97442076",
    "availableBalanceWithoutConvert": "2658.33944077",
    "borrowSize": "0",
    "availableToBorrow": "2500000",
    "accruedInterest": "0",
    "totalOrderIM": "0.9205456",
    "totalPositionIM": "330.71443439",
    "totalPositionMM": "51.24010721",
    "unrealisedPnl": "298.63257142",
    "cumRealisedPnl": "-3418.29414098"
    }
    ]
    },
    "version": 177440
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/derivatives/ws/connect.html b/derivatives/ws/connect.html index a68e979015..f2e2a3cdde 100644 --- a/derivatives/ws/connect.html +++ b/derivatives/ws/connect.html @@ -4,7 +4,7 @@ Connect | Bybit API Documentation - + @@ -23,7 +23,7 @@ Contract: wss://stream.bybit.com/contract/private/v3

  • Testnet:
    Unified margin: wss://stream-testnet.bybit.com/unified/private/v3
    Contract: wss://stream-testnet.bybit.com/contract/private/v3

  • Authentication

    info
    Public topics do not require authentication. The following section applies to private topics only.

    Apply for authentication when establishing a connection.

    Note: if you're using pybit, bybit-api or another high-level library, you can ignore this code - as authentication is handled for you.

    {
    "req_id": "10001", // optional
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //expires; is greater than your current timestamp
    "singature"
    ]
    }
    # based on: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    Authentication success sample response

    {
    "success": true,
    "ret_msg": "",
    "op": "auth",
    "conn_id": "ced97gevha793pjs1t30-ob"
    }
    note

    Example signature algorithms can be found here.

    caution

    Due to network complexity, your may get disconnected at any time. Please follow the instructions below to ensure that you receive WebSocket messages on time:

    1. Keep connection alive by sending heartbeat packet
    2. Reconnect as soon as possible if disconnected

    IP Limits

    • Do not frequently connect and disconnect the connection.
    • Do not build over 500 connections in 5 minutes. This is counted separately per WebSocket endpoint.

    How to Send Heartbeat Packet

    How to Send

    // req_id is a customised id, which is optional
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    Pong message example

    {
    "req_id": "test",
    "op": "pong",
    "args": [
    "1671163042443"
    ],
    "conn_id": "ce3e06kfnonvuu2e3j4g-2t5w"
    }
    caution

    To avoid networks or program issues, we recommend that you send the ping heartbeat packet every 20 seconds to maintain the WebSocket connection.

    How to Subscribe to Topics

    Understanding Websocket Filters

    How to subscribe with a filter

    // Subscribing level 1 orderbook
    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    Support subscribe multiple symbols and topics, separate with ','.

    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT",
    "publicTrade.BTCUSDT",
    "orderbook.1.ETHUSDT",
    ]
    }

    Understanding Websocket Filters unsubscription

    You can dynamically subscribe and unsubscribe from topics without websocket disconnection as follows:

    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.ETHUSD"
    ],
    "req_id": "customised_id"
    }

    Understanding Subscription Response

    Topic subscription response message example

    {
    "success": true,
    "ret_msg": "",
    "op": "subscribe",
    "conn_id": "ced97gevha793pjs1t30-ob"
    }

    Once you subscribe successfully, you'd receive result information. You can determine whether the subscription is successful based on the response.

    - + \ No newline at end of file diff --git a/derivativesV3/contract.html b/derivativesV3/contract.html index 01bbbd3524..8404d18ecd 100644 --- a/derivativesV3/contract.html +++ b/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/derivativesV3/unified_margin.html b/derivativesV3/unified_margin.html index e3b77d39db..aa9f294f3f 100644 --- a/derivativesV3/unified_margin.html +++ b/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/faq.html b/faq.html index 478baa169e..3b4c365ae1 100644 --- a/faq.html +++ b/faq.html @@ -4,14 +4,14 @@ Frequently Asked Questions | Bybit API Documentation - +

    Frequently Asked Questions

    Where are Bybit's servers located?

    AWS Singapore, Availability Zone ID apse1-az3.

    reduceOnly and closeOnTrigger - what's the difference?

    • To close your position, submit an order and specify reduceOnly to true. closeOnTrigger is not strictly applicable here, but you can also set it to true if it's required.
    • reduceOnly is the one that really matters for closing position, and we will improve the interface in the future.
    • Be careful when you specify closeOnTrigger to true as it could cause conflict when reduceOnly is false.

    Why aren't all my orders showing on the website?

    • Users who have bots which place large numbers of laddered orders will be restricted by the frontend interface, which only shows a maximum of 50 orders on-screen.
    • Don't worry, your orders are still in the system and can be queried by the API, but the frontend cannot show more than 50.

    Calculating order size based on available wallet balance

    • price * availableBalance * leverage * perc * (1 - (0.0006 * 2))
    • Unfortunately this is not a perfectly accurate formula; the real calculation is complex and may be published in the docs at a later date.
      • price - last price (or your entry price) - can be found with the Tickers.
      • availableBalance - can be found with the Position Info endpoint.
      • leverage - up to the respective maximum leverage for the market and your risk limit (eg 2, 10, 50).
      • perc - 0.1 for 10%, 0.25 for 25%, etc.
      • 1 - (0.0006 * 2) - used to calculate the maximum order cost (always assumes entry & exit orders use taker fee regardless actual fee).

    Can I exchange assets with the API?

    How do I get funds for testnet?

    To get testnet funds, just go to master account asset page to request.

    Why are my Closed PNL prices inaccurate?

    • The entryPrice and exitPrice returned by Closed PNL endpoints are not the actual execution prices of the orders.
    • It is based on the total costs of the order (whether or not the position was only opened/closed by one order executed at one price - it is more complicated if multiple orders opened/closed a position.)
    • For instance, the entry_price and exit_price reported by this endpoint are influenced by the fee paid/received on the orders.

    How can I ensure I am using up-to-date data?

    • It is possible, although unlikely, that the REST API or (even less likely) the websocket could return/push old data.
    • For the greatest level of data resilience, we recommend clients to:
      • firstly, rely on the websocket, which will not only ensure you get the latest data as fast as possible, but will also ensure you get complete data
      • secondly, query the REST API to fill in any discrepencies in data - or between websocket disconnections.
    • The best practice is to save all of this data locally in your own database or cache.
    • This frees up your rate limits for other requests and also ensures a level of redundancy against the exchange in case of data delays.

    What is the difference between turnover and volume?

    • Turnover: is in the opposite currency to the quantity's currency
    • Volume: is in the same currency as the quantity's currency

    Why is the price returned in the place market order response wrong?

    Market orders are (in the backend) just limit orders submitted at a worse price. This is to reduce the chance of a flash crash or a similar event, where a trader might submit a market order which executes at a significantly worse price than they expected it to. The price returned here is that internal limit order price. This "inaccurate" price is returned because the place order endpoint is asynchronous, meaning the response is returned to you before the order is actually executed.

    If you want the true execution price (execPrice) you should subscribe to the execution websocket.

    - + \ No newline at end of file diff --git a/futuresV2/inverse.html b/futuresV2/inverse.html index 0398fd83e4..2bde3e6dfd 100644 --- a/futuresV2/inverse.html +++ b/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/futuresV2/inverse_futures.html b/futuresV2/inverse_futures.html index a9826f0832..935cd2d964 100644 --- a/futuresV2/inverse_futures.html +++ b/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/futuresV2/linear.html b/futuresV2/linear.html index 0c72317143..2b664d6057 100644 --- a/futuresV2/linear.html +++ b/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/index.html b/index.html index a03c0c3702..fbbbb7cb84 100644 --- a/index.html +++ b/index.html @@ -4,13 +4,13 @@ Hello from Bybit API Documentation | Bybit API Documentation - +

    Unified APIs

    Bybit's latest v5 suite of APIs allow for a smooth and easy integration.

    Learn Exchange Mechanisms

    Learn the intricate details of Bybit's market rules to fully maximise your API usage.

    Historical Market Data

    Get comprehensive public market data in CSV format to speedily backtest and build strategies.

    - + \ No newline at end of file diff --git a/inverse.html b/inverse.html index eab1505f62..8c9486077b 100644 --- a/inverse.html +++ b/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/inverse_futures.html b/inverse_futures.html index d2ecad3905..66870b2470 100644 --- a/inverse_futures.html +++ b/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/linear.html b/linear.html index 3fb845d266..3eb8603d49 100644 --- a/linear.html +++ b/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/markdown-page.html b/markdown-page.html index 1050436d61..4ca4719616 100644 --- a/markdown-page.html +++ b/markdown-page.html @@ -4,13 +4,13 @@ Markdown page example | Bybit API Documentation - +

    Markdown page example

    You don't need React to write simple standalone pages.

    - + \ No newline at end of file diff --git a/pilot-feature.html b/pilot-feature.html index 062b52438e..14210a73e5 100644 --- a/pilot-feature.html +++ b/pilot-feature.html @@ -4,7 +4,7 @@ Pilot Features | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Pilot Features

    Spot Supports Amend Order

    • Available date: Testnet - alive, Mainnet - 1 Nov 2023
    • Cover: Classic & Unified account Spot
    • Details: You can amend your spot orders via Amend Order

    Unified Account Spot Stop Orders logic is changed

    • Available date: Testnet - alive, Mainnet - 26 Oct 2023 (grey scale period, all are effective est. 2th Nov 2023)
    • Cover: Unified account Spot Stop Orders
    • Details: Once the TP/SL order or Conditional order is triggered, the order ID will be kept the same

    UTA Pro Batch Feature

    • Available date: Testnet - alive, Mainnet - 31 Aug 2023
    • Cover: UTA Pro, USDT Perpetual, USDC Perpetual & USDC Futures (linear)
    • Details: UTA Pro user can batch create/amend/cancel linear orders
    Sample code
    POST https://api-testnet.bybit.com/v5/order/create-batch

    > Request Body
    {
    "category": "linear",
    "request": [
    {

    "symbol": "BTCUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.1",
    "price": "25500",
    "timeInForce": "GTC",
    "orderLinkId": "test-03",
    "reduceOnly": false,
    "tpslMode": "Full",
    "takeProfit": "26300",
    "stopLoss": "24800",
    "triggerDirection": null,
    "triggerPrice": null,
    "triggerBy": null,
    "positioIdx": 0,
    "smpType": null,
    "tpLimitPrice": null,
    "slLimitPrice": null,
    "slOrderType": null,
    "tpOrderType": null

    },
    {

    "symbol": "ETHUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.1",
    "price": "1550",
    "timeInForce": "GTC",
    "orderLinkId": "test-04",
    "reduceOnly": false,
    "tpslMode": "Full",
    "takeProfit": "1680",
    "stopLoss": "1490",
    "triggerDirection": null,
    "triggerPrice": null,
    "triggerBy": null,
    "positioIdx": 0,
    "smpType": null,
    "tpLimitPrice": null,
    "slLimitPrice": null,
    "slOrderType": null,
    "tpOrderType": null
    }
    ]
    }
    > Response
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "orderId": "6afd7e83-7176-4f73-93e0-44a8f2babd14",
    "orderLinkId": "test-03",
    "createAt": "1693212677410"
    },
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "9eeef30c-c682-42b2-a4a7-7e403db8506c",
    "orderLinkId": "test-04",
    "createAt": "1693212677410"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1693212677411
    }

    Add Customised Disconnection Configuration

    • Available date: Testnet - alive, Mainnet - 16 Aug 2023
    • Cover: All kinds of accounts - V5 Websocket Private Connection
    • Details: Set /v5/private?max_active_time=, supported range is from 30s to 600s. For more info, please check here

    Adjust error code

    Old error codeNew error codeMsg
    34001283200320Operations Restriction: The current LTV ratio of your Institutional Loan has hit the liquidation threshold. Assets in your account are being liquidated.
    1760363200320Operations Restriction: The current LTV ratio of your Institutional Loan has hit the liquidation threshold. Assets in your account are being liquidated.

    UTA borrow quota is shared across main-sub uids

    • Available date: Testnet - alive, Mainnet - 11 Aug 2023
    • Cover: UTA account
    • Details: Before each uid has an independent borrow quota, but now, main-sub uids share the same borrow quota

    UTA user can set collateral coin

    • Available date: Testnet - alive, Mainnet - 10 Aug 2023
    • Cover: UTA account
    • Details: User can set collateral coin via API

    User can upgrade account to UTA Pro manually

    • Available date: Testnet - alive, Mainnet - 08 Aug 2023
    • Cover: Normal account, UTA account
    • Details: User can upgrade account to UTA Pro via API

    OpenAPI supports Spot Conditional Order

    • Available date: Testnet - alive, Mainnet - 07 Aug 2023
    • Cover: Normal account, UTA account
    • Details: User can place Spot conditional order

    UTA Supports Institutional Lending

    • Available date: Testnet - alive, Mainnet - 24 July 2023
    • Cover: UTA
    • Details: UTA can have OTC loan

    Support Funding For USDC Perp

    • Available date: Testnet - alive, Mainnet - 13 July 2023
    • Cover: UTA USDC Perpetual
    • Details: There was no execType=Funding in Get Execution and websocket execution stream update. Now you will it.

    New Copy Trading

    • Available date: Testnet - alive, Mainnet - 24 June 2023
    • Cover: Copy trading
    • Details: Bybit will release uids that allow upgrades in batches starting from 23 June, and if you select to upgrade it, you can only use Contract V3 or V5 to copy trade

    Unified Account Supports Isolated Margin And Hedge Mode

    • Available date: Testnet - alive, Mainnet - 1 June 2023
    • Cover: Unified trading account only
    • Details: Isolated margin mode for UTA is account level. Hedge mode supports USDT perpetual only

    New TP/SL

    • Available date: Testnet - alive, Mainnet - 23 May 2023
    • Cover: V5 API and Contract V3 API
    • Details: UTA account: USDT Perpetual, USDC Perpetual and Futures, Inverse contract, Inverse contract
      Normal account: USDT Perpetual, Inverse contract

    Query Pre-upgrade Records

    • Available date: Testnet - alive, Mainnet - 27 Apr 2023
    • Cover: UTA account
    • Details: After upgraded to UTA, you can get those order information before upgraded.

    C2C Lending

    • Available date: Testnet - alive, Mainnet - 22 Apr 2023
    • Cover: All users (grey scale in the progress right now)
    • Details: You can lend your available assets to platform to earn yield

    Self Match Prevention

    • Available date: Testnet - alive, Mainnet - 20 Apr 2023
    • Cover: read here
    • Details: Support spot, futures and options

    Upgrade to UTA without closing positions

    • Available date: Testnet - alive, Mainnet - 04 Apr 2023
    • Cover: Normal account is upgraded to Unified account
    • Details: Do not need to close positions when upgrade. For more details. please refer to upgrade API information

    UTA can trade USDC Futures via V5

    • Available date: Testnet - alive, Mainnet - 20 Mar 2023
    • Cover: Unified trading account users only
    • Details: Add USDC Futures trading pair

    Institutional Lending V5 API

    • Available date: Testnet - alive, Mainnet - 13 Mar 2023
    • Cover: Institutional clients who applied OTC
    • Details: Clients can get LTV, lends and repayment information

    Normal account can trade Spot via V5

    • Available date: Testnet - alive, Mainnet - 10 Mar 2023
    • Cover: Normal account
    • Details: Use V5 API to trade Spot for normal account

    Unify symbol status enums

    • Available date: Testnet - alive, Mainnet - 10 Mar 2023
    • Cover: /v5/market/instruments-info status field
    • Details: Use Trading, Closed, Settling, PreLaunch, Deliverying

    Release V5 Margin trade (normal account) API

    • Available date: Testnet - alive, Mainnet - 3 Mar 2023
    • Cover: Normal account can operate margin trade via V5
    • Details: able to loan, repay margins with V5

    UTA can trade Inverse Contract

    • Available date: Testnet - alive, Mainnet - 21 Feb 2023
    • Cover: UTA has ability to trade inverse contract via V5 API
    • Details: Please note that inverse contract trade is conducted though the CONTRACT wallet

    Merge SPOT account into UNIFIED account(IMPORTANT)

    • Available date: est. March 3rd, 2023
    • Cover: UTA users only
    • Details: You need to adjust withdrawal logic by transfer funds to FUND account first, then call withdraw API

    Use RSA keys to authenticate

    • Available date: Testnet - alive, Mainnet - 21 Feb 2023
    • Cover: All V3 & V5 the endpoints need authentication
    • Details: Please refer to this guideline to have a quick start

    Add a new enum type for execType

    • Available date: Testnet - alive, Mainnet - 20 Feb 2023
    • Cover: Contract V3 - Websocket private channel - execution topic
    • Details: Funding execution stream will be pushed depending on the funding interval of the symbol.

    Normal account is supported by V5 API

    • Available date: Testnet - alive, Mainnet - 9 Feb 2023
    • Cover: non-unified account can trade USDT perpetual and Inverse contract
    • Details: After this release, you may get some 401 errors or 404 errors if you have following actions:

    401: You are using v1/v2 way to pass authentication params:

    GET https://api.bybit.com/v5/position/list?api_key=xxx&category=linear&recv_window=5000&symbol=ETHUSDT&timestamp=1675929695887&sign=xxx

    You should pass them in the request header:

    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'

    404: For below APIs, if you use unsuitable category, i.e., you use Normal account to access category=option/spot


    Adjust error code

    Old error codeNew error codeMsg
    3400045110073Set margin mode failed
    34009910016Server error

    Add level 500 depth

    • Available date: Testnet - 13 JAN 2023, Mainnet - 16 JAN 2023
    • Cover: V5 orderbook and V3 orderbook
    • Details: Linear contract and inverse contract supports 500 depth, and the push frequency is 100ms.
    - + \ No newline at end of file diff --git a/search.html b/search.html index 89d87b5e3f..5f18dc3c7a 100644 --- a/search.html +++ b/search.html @@ -4,13 +4,13 @@ Search the documentation | Bybit API Documentation - + - + \ No newline at end of file diff --git a/spot.html b/spot.html index ba47209ef4..6ff0b14568 100644 --- a/spot.html +++ b/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/spot/enum.html b/spot/enum.html index 60689365b1..9b266f55bd 100644 --- a/spot/enum.html +++ b/spot/enum.html @@ -4,7 +4,7 @@ Enums Definitions | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Enums Definitions

    side

    • BUY
    • SELL

    timeInForce

    • GTCGood Till Cancel
    • FOKFill or Kill
    • IOCImmediate or Cancel

    symbol

    • BTCUSDT
    • ETHUSDT
    • BTCUSDC
    • ...
      You can get all symbols with the instrument endpoint.

    orderType

    • MARKET
    • LIMIT
    • LIMIT_MAKER

    currency/coin

    • BTC
    • ETH
    • USDT
    • ...

    Cross Margin Trading Endpoints support below currency:

    • BTC
    • ETH
    • XRP
    • SOL
    • LTC
    • EOS
    • LINK
    • XLM
    • USDC
    • USDT You could find all supported coins of margin trade here.

    orderStatus

    • NEWnormal order is placed
    • ORDER_NEWTP/SL order is placed
    • PARTIALLY_FILLED
    • FILLED
    • ORDER_FILLEDTP/SL order is filled
    • CANCELEDnormal order is cancelled
    • ORDER_CANCELEDTP/SL order is cancelled
    • REJECTED
    • ORDER_REJECTEDTP/SL order is cancelled
    • PARTIALLY_FILLED_CANCELED
    • ORDER_FAILEDTP/SL order is failed

    interval

    • 1m1 minute
    • 3m3 minutes
    • 5m5 minutes
    • 15m15 minutes
    • 30m30 minutes
    • 1h1 hour
    • 2h2 hours
    • 4h4 hours
    • 6h6 hours
    • 12h12 hours
    • 1d1 day
    • 1w1 week
    • 1M1 month

    ltStatus

    • 1ETP can be purchased and redeemed
    • 2ETP can be purchased, but not redeemed
    • 3ETP can be redeemed, but not purchased
    • 4ETP cannot be purchased nor redeemed

    ltOrderStatus

    • 1Completed
    • 2In progress
    • 3Failed

    ltOrderType

    • 1Purchase
    • 2Redemption

    smpType

    • default: None
    • CancelMaker
    • CancelTaker
    • CancelBoth
    - + \ No newline at end of file diff --git a/spot/error.html b/spot/error.html index 0172a96dfe..4282847efa 100644 --- a/spot/error.html +++ b/spot/error.html @@ -4,13 +4,13 @@ Error Code | Bybit API Documentation - +

    Error Code

    CodeDescription
    5019User-service error
    5004Upstream server timeout
    7001Grpc request filed type error
    10003Invalid api_key
    10006Too many visits
    10001Params error
    10002Invalid request, please check your timestamp and recv_window param
    10004Error sign
    10005Permission denied
    10008uta banned. You cannot access to this endpoint with current account mode, please check your account mode
    10024Compliance rules triggered
    10029The requested symbol is invalid, please check symbol whitelist
    33004api_key expire
    12940Connection reset
    12999Server Error
    12800Invalid request
    12801Invalid JSON
    12802Invalid event
    12803Event required
    12804Invalid topic
    12805Topic required
    12806Params required
    12807Period required
    12808Invalid period
    12809Invalid Symbols
    12810Not supported symbols
    12811There is no such broker.
    12812DumpScale required
    12813Invalid exchangeId
    12814Param %s should be %s.
    12815Symbol required
    12816Timeout. Retry later.
    12817No business with any exchange.
    12818Client disconnected.
    12819OrgId required.
    12820OrgId must be a number.
    12821DumpScale error.
    12822Index name error.
    12823Parameter error
    12824Parameter %s [%s]
    12825The number of each symbol request cannot exceed 300
    12001Request failed to be processed. Please try again.
    12007Response timeout from backend server. Delivery and request status unknown.
    12014Trading pairs not supported.
    12005Too many new orders. Please lower request frequency.
    12016Service not available.
    12032Fusing error
    12114NETWORK_BUSY
    12015UID_NOT_EXIST
    12011INNOVATION_BUY_FAILED_BY_QUOTA
    12010ETP_BUY_FAILED_BY_QUOTA
    12012ETP_NAV_IS_ABNORMAL
    12017CROSS_MARGIN_PRE_BUY_QUOTA_FAILED
    10020CROSS_MARGIN_PRE_SELL_QUOTA_FAILED
    12019Your account has been restricted for trades. If you have any questions, please email us at support@bybit.com
    12124Order amount is too big
    12031The feature has been suspended
    12105Empty parameter.
    12115Invalid timeInForce.
    12116Invalid orderType.
    12117Invalid direction.
    12121Invalid symbol.
    12130Invalid parameter sent.
    12131Insufficient balance
    12132Order price exceeded upper limit.
    12133Order price exceeded lower limit.
    12134Order price has too many decimals.
    12135Order quantity exceeded upper limit.
    12136Order quantity exceeded lower limit.
    12137Order quantity has too many decimals.
    12138Order price exceeded limits.
    12139Order has been filled.
    12140Order value exceeded lower limit.
    12141Duplicate clientOrderId.
    12142Order has been canceled.
    12143Order not found.
    12144Order being cancelled. Operation not supported.
    12145Order cannot be canceled.
    12146Order creation timeout.
    12147Order cancellation timeout.
    12148Market order amount decimal too long
    12149Create order failed
    12150Cancel order failed
    12151The trading pair is not open yet
    12156Order quantity invalid
    12157The trading pair is not available for api trading
    12158create limit maker order failed
    12159Market Order is not supported within the first %s minutes of newly launched pairs due to risk control.
    12190Cancel order has been finished.
    12191Can not cancel order, please try again later.
    12192Order price cannot be higher than %s .
    12193Buy order price cannot be higher than %s.
    12194Sell order price cannot be lower than %s.
    12195Please note that your order may not be filled
    12196Please note that your order may not be filled
    12197Your order quantity to buy is too large. The filled price may deviate significantly from the market price. Please try again
    12198Your order quantity to sell is too large. The filled price may deviate significantly from the market price. Please try again
    12199Your order quantity to buy is too large. The filled price may deviate significantly from the nav. Please try again.
    12200Your order quantity to sell is too large. The filled price may deviate significantly from the nav. Please try again.
    12201Invalid orderCategory parameter
    12202Please enter the TP/SL price
    12203trigger price cannot be higher than 110% price
    12204trigger price cannot be lower than 90% of qty
    12205CROSS_MARGIN_USER_NOT_ALLOW
    12206Stop_limit Order is not supported within the first 5 minutes of newly launched pairs
    12210New order rejected.
    12211Cancelation rejected.
    12212Cancel order request processing
    12213Order does not exist.
    12214This trading pair currently does not support trading
    12217Only LIMIT-MAKER order is supported for the current pair.
    12218The LIMIT-MAKER order is rejected due to invalid price.
    12219UID {{xxx}} is not available to this feature
    12221This coin does not exist
    12222Too many requests in this time frame
    12223Your Spot Account with Institutional Lending triggers an alert or liquidation
    12224You're not a user of the Innovation Zone
    12225You've failed to check the Risk Alert for Leveraged Tokens
    12226Your Spot Account for Margin Trading is being liquidated
    12227This feature is not supported
    12228The purchase amount of each order exceeds the estimated maximum purchase amount
    12229The sell quantity per order exceeds the estimated maximum sell quantity
    12230The reserved quota for Spot Margin Trading does not meet the LTV ratio requirement
    12231Users with Spot Margin Trading are not allowed to perform Block Trades
    12232Users with Institutional Lending are not allowed to perform Block Trades
    12233Users with Leverage Tokens are not allowed to perform Block Trades
    12234System Error
    12400The serialNum is already in use.
    12401Daily purchase limit has been exceeded. Please try again later.
    12402There's a large number of purchase orders. Please try again later.
    12403Insufficient available balance. Please make a deposit and try again.
    12404Daily redemption limit has been exceeded. Please try again later.
    12405There's a large number of redemption orders. Please try again later.
    12406Insufficient available balance. Please make a deposit and try again.
    12407Order not found.
    12408Purchase period hasn't started yet.
    12409Purchase amount has exceeded the upper limit.
    12410You haven't passed the quiz yet! To purchase and/or redeem an LT, please complete the quiz first.
    12412Redemption period hasn't started yet.
    12413Redemption amount has exceeded the upper limit.
    12414Purchase of the LT has been temporarily suspended.
    12415Redemption of the LT has been temporarily suspended.
    12416Invalid format. Please check the length and numeric precision.
    12417Failed to place order:Exceed the maximum position limit of leveraged tokens
    12601Query user repay history error
    12602Query user account info error
    12603Query user loan history error
    12604Query order history start time exceeds end time
    12605Failed to borrow
    12606Repayment Failed
    12607User not found
    12608You haven't enabled Cross Margin Trading yet. To do so
    12609You haven't enabled Cross Margin Trading yet. To do so
    12610Failed to locate the coins to borrow
    12611Cross Margin Trading not yet supported by the selected coin
    12612Pair not available
    12613Cross Margin Trading not yet supported by the selected pair
    12614Repeated repayment requests
    12615Insufficient available balance
    12616No repayment required
    12617Repayment amount has exceeded the total liability
    12618Settlement in progress
    12619Liquidation in progress
    12620Failed to locate repayment history
    12621Repeated borrowing requests
    12622Coins to borrow not generally available yet
    12623Pair to borrow not generally available yet
    12624Invalid user status
    12625Amount to borrow cannot be lower than the min. amount to borrow (per transaction)
    12626Amount to borrow cannot be larger than the max. amount to borrow (per transaction)
    12627Amount to borrow cannot be higher than the max. amount to borrow per user
    12628Amount to borrow has exceeded Bybit's max. amount to borrow
    12629Amount to borrow has exceeded the user's estimated max. amount to borrow
    12630Query user loan info error
    12631Number of decimals has exceeded the maximum precision of borrow
    12631Number of decimals has exceeded the maximum precision of repay
    - + \ No newline at end of file diff --git a/spot/etp/asset-info.html b/spot/etp/asset-info.html index f2c15e4b7e..e2dcb35689 100644 --- a/spot/etp/asset-info.html +++ b/spot/etp/asset-info.html @@ -4,13 +4,13 @@ All Asset Info | Bybit API Documentation - +

    All Asset Info

    info

    It is a public endpoint, and no need to authenticate.

    HTTP Request

    GET /spot/v3/public/infos

    Request Parameters

    ParameterRequiredTypeComments
    ltCodefalsestringAbbreviation of the LT.

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > ltCodestringAbbreviation of the LT
    > ltNamestringFull name of the LT
    > maxPurchasestringMax. purchase amount per transaction
    > minPurchasestringMin. purchase amount per transaction
    > maxPurchaseDailystringMax. purchase amount per day
    > maxRedeemstringMax. redemption amount per transaction
    > minRedeemstringMin. redemption amount per transaction
    > maxRedeemDailystringMax. redemption amount per day
    > purchaseFeeRatestringPurchase fees
    > redeemFeeRatestringRedemption fees
    > statusstringWhether the LT can be purchased or redeemed
    > fundFeestringFunding fees charged daily to users who hold LT
    > fundFeeTimenumberTimestamps when funding fees are charged
    > manageFeeRatestringManagement fees
    > manageFeeTimenumberTimestamps when management fees are charged
    > valuestringInternal used parameter, please ignore
    > totalstringApplication upper limit
    > netValuestringNet asset value

    Request Example

    https://api-testnet.bybit.com/spot/v3/public/infos?ltCode=EOS2LUSDT

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "fundFee": "21.79800315",
    "fundFeeTime": 1673366400000,
    "ltCode": "EOS2LUSDT",
    "ltName": "Long EOS (2x Leverage)",
    "manageFeeRate": "0.00005",
    "manageFeeTime": 1673398800000,
    "maxPurchase": "5000",
    "maxPurchaseDaily": "200000",
    "maxRedeem": "861",
    "maxRedeemDaily": "20000",
    "minPurchase": "100",
    "minRedeem": "17",
    "netValue": "3.781571076822412032",
    "purchaseFeeRate": "0.0005",
    "redeemFeeRate": "0.0005",
    "status": "1",
    "total": "5000000",
    "value": "23624.848996419293002588635"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673345413125
    }
    - + \ No newline at end of file diff --git a/spot/etp/market-info.html b/spot/etp/market-info.html index 215bf60a2b..2a69815941 100644 --- a/spot/etp/market-info.html +++ b/spot/etp/market-info.html @@ -4,13 +4,13 @@ Market Info | Bybit API Documentation - +

    Market Info

    HTTP Request

    GET /spot/v3/private/reference

    Request Parameters

    ParameterRequiredTypeComments
    ltCodetruestringAbbreviation of the LT. Get ltCode from asset info api

    Response Parameters

    ParameterTypeComments
    basketstringTotal position value = basket value * total circulation
    circulationstringCirculating supply in the secondary market
    leveragestringReal Leverage calculated by last traded price.
    ltCodestringAbbreviation of the LT
    navstringNet asset value
    navTimenumberUpdate time for net asset value (ms)

    Request Example

    curl --location --request GET 'https://api.bybit.com/spot/v3/private/reference?ltCode=EOS2LUSDT' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662549197919' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "basket": "230666.700009559600667216",
    "circulation": "24999.840207851103706443",
    "leverage": "2.302545313639639446",
    "ltCode": "EOS2L",
    "nav": "3.790797803797135639",
    "navTime": 1673346095226
    },
    "retExtInfo": {},
    "time": 1673346095239
    }
    - + \ No newline at end of file diff --git a/spot/etp/order-history.html b/spot/etp/order-history.html index a7d7263e00..64e845b3e1 100644 --- a/spot/etp/order-history.html +++ b/spot/etp/order-history.html @@ -4,13 +4,13 @@ Purchase & Redeem History | Bybit API Documentation - +

    Purchase & Redeem History

    HTTP Request

    GET /spot/v3/private/record

    Request Parameters

    ParameterRequiredTypeComments
    ltCodefalsestringAbbreviation of the LT.
    orderIdfalsestringOrder ID
    startTimefalseintegerStart timestamp (ms)
    endTimefalseintegerEnd timestamp (ms)
    limitfalseintegerLimit for data size. [1, 500]. Default: 100
    orderTypefalseintegerOrder type; 1: Purchase; 2: Redeem
    serialNofalsestringSerial number

    Response Parameters

    ParameterTypeComments
    amountstringActual purchase quantity of the ETP
    excTimenumberLast update time of the order status
    feestringTrading fees
    ltCodestringAbbreviation of the LT
    orderIdstringOrder ID
    orderStatusstringOrder status. 1: Completed; 2: In progress; 3: Failed
    orderTimenumberOrder time
    orderTypeintegerOrder type; 1. Purchase; 2. Redemption
    serialNostringSerial number
    valuestringFilled value
    valueCoinstringQuote asset

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/record?ltCode=DOT3L&startTime=1662548400000&endTime=1662549840000' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662608374151' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "amount": "",
    "excTime": 1662549752000,
    "fee": "",
    "ltCode": "DOT3L",
    "orderId": "2083",
    "orderStatus": "3",
    "orderTime": 1662549752000,
    "orderType": 1,
    "serialNo": "x003",
    "value": "",
    "valueCoin": "USDT"
    },
    {
    "amount": "",
    "excTime": 1662549702000,
    "fee": "",
    "ltCode": "DOT3L",
    "orderId": "2082",
    "orderStatus": "3",
    "orderTime": 1662549702000,
    "orderType": 1,
    "serialNo": "x002",
    "value": "",
    "valueCoin": "USDT"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1662608374640
    }
    - + \ No newline at end of file diff --git a/spot/etp/purchase.html b/spot/etp/purchase.html index 234c0895c0..21b2dc22bf 100644 --- a/spot/etp/purchase.html +++ b/spot/etp/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +

    Purchase

    HTTP Request

    POST /spot/v3/private/purchase

    Request Parameters

    ParameterRequiredTypeComments
    ltCodetruestringAbbreviation of the LT.
    ltAmounttruestringPurchase amount
    serialNofalsestringSerial number. A kind of unique customised ID

    Response Parameters

    ParameterTypeComments
    amountstringActual purchase value of the LT
    idstringTransaction ID
    ltCodestringAbbreviation of the LT
    orderAmountstringOrder value of the LT
    orderQuantitystringOrder quantity of the LT
    orderStatusstringOrder status. 1: Completed; 2: In progress; 3: Failed
    serialNostringSerial number
    timestampnumberTimestamp
    valueCoinstringQuote asset

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/purchase' \
    --header 'Content-Type: application/json' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662549845240' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --data-raw '{
    "ltCode": "DOT3LUSDT",
    "ltAmount": "100",
    "serialNo": "x005"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "amount": "100",
    "id": "2085",
    "ltCode": "DOT3LUSDT",
    "orderAmount": "",
    "orderQuantity": "",
    "orderStatus": "2",
    "serialNo": "x005",
    "timestamp": 1662549845373,
    "valueCoin": "USDT"
    },
    "retExtInfo": {},
    "time": 1662549845453
    }
    - + \ No newline at end of file diff --git a/spot/etp/redeem.html b/spot/etp/redeem.html index 07034f7eb3..6a333a619a 100644 --- a/spot/etp/redeem.html +++ b/spot/etp/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +

    Redeem

    HTTP Request

    POST /spot/v3/private/redeem

    Request Parameters

    ParameterRequiredTypeComments
    ltCodetruestringAbbreviation of the LT.
    ltQuantitytruestringRedeem quantity
    serialNofalsestringSerial number. A kind of unique customised ID

    Response Parameters

    ParameterTypeComments
    idstringTransaction ID
    ltCodestringAbbreviation of the LT
    orderAmountstringOrder value of the LT. Normally returns ""
    orderQuantitystringOrder quantity of the LT
    orderStatusstringOrder status; 1. Completed; 2. In progress; 3. Failed
    quantitystringQuantity. Normally returns ""
    serialNostringSerial number
    timestampnumberTimestamp
    valueCoinstringQuote asset

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/redeem' \
    --header 'Content-Type: application/json' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662605726010' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --data-raw '{
    "ltCode": "DOT3LUSDT",
    "ltQuantity": "50",
    "serialNo": "r001"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "2087",
    "ltCode": "DOT3LUSDT",
    "orderAmount": "",
    "orderQuantity": "50",
    "orderStatus": "2",
    "quantity": "",
    "serialNo": "r001",
    "timestamp": 1662605726326,
    "valueCoin": "DOT3L"
    },
    "retExtInfo": {},
    "time": 1662605727987
    }
    - + \ No newline at end of file diff --git a/spot/margin/account.html b/spot/margin/account.html index 6d5f62e1d0..5678ae46b7 100644 --- a/spot/margin/account.html +++ b/spot/margin/account.html @@ -4,13 +4,13 @@ Get Loan Account Info | Bybit API Documentation - +

    Get Loan Account Info

    HTTP Request

    GET /spot/v3/private/cross-margin-account

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    acctBalanceSumstringTotal equity (BTC)
    debtBalanceSumstringTotal liability (BTC)
    loanAccountListarrayObject
    > freestringAvailable balance
    > intereststringOutstanding interest
    > loanstringOutstanding principle
    > remainAmountstringRemaining debt = interest + loan
    > lockedstringLocked amount
    > tokenIdstringCoin name
    > totalstringTotal
    riskRatestringRisk rate
    statusintegerLoan account status
    • 1: normal
    • 2: withdrawal/transfer restricted
    • 3: liquidation alert triggered
    • 4: liquidated
    switchStatusinteger0: margin trade off, 1: margin trade on

    Request Example

    GET /spot/v3/private/cross-margin-account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751305868
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "acctBalanceSum": "0.455189592150138021",
    "debtBalanceSum": "0",
    "loanAccountList": [
    {
    "free": "0.01444",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "BTC",
    "total": "0.01444"
    },
    {
    "free": "0.21147048",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "ETH",
    "total": "0.21147048"
    },
    {
    "free": "7963.58978991849",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDT",
    "total": "7963.58978991849"
    },
    {
    "free": "1380.28832",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDC",
    "total": "1380.28832"
    }
    ],
    "riskRate": "0",
    "status": 1,
    "switchStatus": 1
    },
    "retExtInfo": {},
    "time": 1677751306287
    }
    - + \ No newline at end of file diff --git a/spot/margin/borrow-history.html b/spot/margin/borrow-history.html index c9eb716ad2..c735a792cb 100644 --- a/spot/margin/borrow-history.html +++ b/spot/margin/borrow-history.html @@ -4,13 +4,13 @@ Get Borrow Order Detail | Bybit API Documentation - +

    Get Borrow Order Detail

    HTTP Request

    GET /spot/v3/private/cross-margin-orders

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalselongThe start timestamp (ms)
    endTimefalselongThe end timestamp (ms)
    coinfalsestringCoin name
    statusfalseintegerStatus
    • 0(default):get all kinds of status
    • 1:uncleared
    • 2:cleared
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 500

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > accountIdstringAccount ID
    > coinstringCoin name
    > createdTimenumberBorrow order created timestamp (ms)
    > idstringBorrow order ID
    > interestAmountstringTotal interest
    > interestBalancestringOutstanding interest
    > loanAmountstringPrincipal amount
    > loanBalancestringOutstanding principal
    > remainAmountstringRemaining debt = interestBalance + loanBalance
    > statusintegerStatus 1:uncleared, 2:cleared
    > typeintegerOrder Type 1: manual loan, 2: auto loan

    Request Example

    GET /spot/v3/private/cross-margin-orders?coin=ETH&limit=1&status=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677754328650
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "accountId": "592335",
    "coin": "ETH",
    "createdTime": 1677751839000,
    "id": "21005",
    "interestAmount": "0.0001",
    "interestBalance": "0",
    "loanAmount": "10",
    "loanBalance": "0",
    "remainAmount": "0",
    "status": 2,
    "type": 1
    }
    ]
    },
    "retExtInfo": {},
    "time": 1662618592344
    }
    - + \ No newline at end of file diff --git a/spot/margin/borrow.html b/spot/margin/borrow.html index 0a208c4f1f..46240f5574 100644 --- a/spot/margin/borrow.html +++ b/spot/margin/borrow.html @@ -4,13 +4,13 @@ Borrow | Bybit API Documentation - +

    Borrow

    HTTP Request

    POST /spot/v3/private/cross-margin-loan

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    qtytruestringAmount to borrow

    Response Parameters

    ParameterTypeComments
    transactIdstringBorrow transaction ID

    Request Example

    POST /spot/v3/private/cross-margin-loan HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751838628
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 38

    {
    "coin": "ETH",
    "qty": "10"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transactId": "14143"
    },
    "retExtInfo": {},
    "time": 1662617848970
    }
    - + \ No newline at end of file diff --git a/spot/margin/borrowable-coin.html b/spot/margin/borrowable-coin.html index ce7ae47b9f..692f982288 100644 --- a/spot/margin/borrowable-coin.html +++ b/spot/margin/borrowable-coin.html @@ -4,13 +4,13 @@ Get Borrowable Coin Info | Bybit API Documentation - +

    Get Borrowable Coin Info

    info

    This is public endpoint, so do not need an authentication

    HTTP Request

    GET /spot/v3/public/cross-margin-borrow-data

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > borrowingPrecisionintegerAccuracy of loan amount
    > repaymentPrecisionintegerAccuracy of repayment amount

    Request Example

    GET /spot/v3/public/cross-margin-borrow-data?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750684772
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "borrowingPrecision": 5,
    "coin": "ETH",
    "repaymentPrecision": 4
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750685331
    }
    - + \ No newline at end of file diff --git a/spot/margin/interest.html b/spot/margin/interest.html index b92da3fec9..7fd8c8a0ad 100644 --- a/spot/margin/interest.html +++ b/spot/margin/interest.html @@ -4,13 +4,13 @@ Get Interest & Quota | Bybit API Documentation - +

    Get Interest & Quota

    HTTP Request

    GET /spot/v3/private/cross-margin-loan-info

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    interestRatestringDaily interest rate
    loanAbleAmountstringThe estimated amount can be loaned
    maxLoanAmountstringThe fixed loanable amount per user on platform

    Request Example

    GET /spot/v3/private/cross-margin-loan-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750928871
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "ETH",
    "interestRate": "0.000054835",
    "loanAbleAmount": "19.220442066850037795",
    "maxLoanAmount": "300"
    },
    "retExtInfo": {},
    "time": 1677750929290
    }
    - + \ No newline at end of file diff --git a/spot/margin/margin-data.html b/spot/margin/margin-data.html index e0657d0694..54162ede7d 100644 --- a/spot/margin/margin-data.html +++ b/spot/margin/margin-data.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - +

    Get Margin Coin Info

    info

    This is public endpoint, so do not need an authentication

    HTTP Request

    GET /spot/v3/public/cross-margin-bond-data

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > conversionRatestringConvert ratio
    > liquidationOrderintegerLiquidation order

    Request Example

    GET /spot/v3/public/cross-margin-bond-data?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750396890
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "coin": "ETH",
    "conversionRate": "0.95",
    "liquidationOrder": 2
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750397414
    }
    - + \ No newline at end of file diff --git a/spot/margin/repay-history.html b/spot/margin/repay-history.html index 97cfe86fef..7da2349311 100644 --- a/spot/margin/repay-history.html +++ b/spot/margin/repay-history.html @@ -4,13 +4,13 @@ Get Repayment Order Detail | Bybit API Documentation - +

    Get Repayment Order Detail

    HTTP Request

    GET /spot/v3/private/cross-margin-repay-history

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalselongThe start timestamp (ms)
    endTimefalselongThe end timestamp (ms)
    coinfalsestringCoin name
    limitfalseintegerLimit for data size per page. [1, 500], Default: 500

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > accountIdstringAccount ID
    > coinstringCoin name
    > repaidAmountstringRepaid amount
    > repayIdstringRepay ID
    > repayMarginOrderIdstringRepay margin order ID
    > repayTimestringRepay timestamp (ms)
    > transactIdsarrayObject
    >> repaidIntereststringInterest repaid
    >> repaidPrincipalstringPrincipal repaid
    >> repaidSerialNumberstringRepayment No. (Borrowing Order)
    >> transactIdstringBorrowing transaction ID

    Request Example

    GET /spot/v3/private/cross-margin-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

    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": 1662622151872
    }
    - + \ No newline at end of file diff --git a/spot/margin/repay.html b/spot/margin/repay.html index d46b425405..f63c5b9676 100644 --- a/spot/margin/repay.html +++ b/spot/margin/repay.html @@ -4,13 +4,13 @@ Repay | Bybit API Documentation - +

    Repay

    HTTP Request

    POST /spot/v3/private/cross-margin-repay

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    qtyfalsestringAmount to repay
    • qty is required when completeRepayment=0
    • qty is invalid when completeRepayment=1
    completeRepaymentfalseintegerWhether to pay off all debts. 0(default): false, 1: true

    Response Parameters

    ParameterTypeComments
    repayIdstringRepayment transaction ID

    Request Example

    POST /spot/v3/private/cross-margin-repay HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751944347
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 66

    {
    "coin": "ETH",
    "qty": null,
    "completeRepayment": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "repayId": "12128"
    },
    "retExtInfo": {},
    "time": 1662618298452
    }
    - + \ No newline at end of file diff --git a/spot/margin/toggle.html b/spot/margin/toggle.html index c6ea8491a0..76836bd283 100644 --- a/spot/margin/toggle.html +++ b/spot/margin/toggle.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +

    Toggle Margin Trade

    Turn on / off spot margin trade

    HTTP Request

    POST /spot/v3/private/cross-margin-switch

    Request Parameters

    ParameterRequiredTypeComments
    switchtrueinteger1: on, 0: off

    Response Parameters

    ParameterTypeComments
    switchStatusintegerMargin trade status. 1: on, 0: off

    Request Example

    POST /spot/v3/private/cross-margin-switch HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677747804512
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 19

    {
    "switch": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "switchStatus": 0
    },
    "retExtInfo": {},
    "time": 1677747804974
    }
    - + \ No newline at end of file diff --git a/spot/otc/coin-info.html b/spot/otc/coin-info.html index db037d1d8d..8a49501e20 100644 --- a/spot/otc/coin-info.html +++ b/spot/otc/coin-info.html @@ -4,13 +4,13 @@ Margin Coin Info | Bybit API Documentation - +

    Margin Coin Info

    tip

    This is a public endpoint, so it does not need to authenticate.

    HTTP Request

    GET /spot/v3/public/margin-ensure-tokens

    Request Parameters

    ParameterRequiredTypeComments
    productIdfalsestringProductId. If not passed, then return all product margin coin. For spot, it returns coin that convertRation greater than 0.

    Response Parameters

    ParameterTypeComments
    marginTokenarrayObject
    > productIdstringProduct Id
    > spotTokenarraySpot margin coin
    >> tokenstringMargin coin
    >> convertRatiostringMargin coin convert ratio
    > contractTokenarrayContract margin coin
    >> tokenstringMargin coin
    >> convertRatiostringMargin coin convert ratio

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/public/margin-ensure-tokens?productId=70'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginToken": [
    {
    "productId": "70",
    "spotToken": [
    {
    "token": "BTC",
    "convertRatio": "1.00000000"
    },
    {
    "token": "ETH",
    "convertRatio": "1.00000000"
    },
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ],
    "contractToken": [
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669363954802
    }
    - + \ No newline at end of file diff --git a/spot/otc/loan-info.html b/spot/otc/loan-info.html index d8e3d5d5d8..746372fc93 100644 --- a/spot/otc/loan-info.html +++ b/spot/otc/loan-info.html @@ -4,13 +4,13 @@ Get Loan Info | Bybit API Documentation - +

    Get Loan Info

    Get loan orders information

    HTTP Request

    GET /spot/v3/private/margin-loan-infos

    Request Parameters

    ParameterRequiredTypeComments
    orderIdfalsestringLoan order id. If not passed, then return all orders, sort by loanTime in descend
    startTimefalseintegerStart timestamp (ms)
    endTimefalseintegerEnd timestamp (ms)
    limitfalseintegerLimit for data size. [1, 100], Default: 10

    Response Parameters

    ParameterTypeComments
    loanInfoarrayObject
    > orderIdstringLoan order ID
    > orderProductIdstringProduct ID
    > parentUidstringUser parent UID
    > loanTimestringLoan timestamp, in milliseconds
    > loanCoinstringLoan coin
    > loanAmountstringLoan amount
    > unpaidAmountstringUnpaid principal
    > unpaidIntereststringUnpaid interest
    > repaidAmountstringRepaid principal
    > repaidIntereststringRepaid interest
    > interestRatestringDaily interest rate
    > statusinteger1:outstanding; 2:paid off
    > leveragestringleverage
    > supportSpotintegerWhether to support spot. 0:false; 1:true
    > supportContractintegerWhether to support contract . 0:false; 1:true
    > withdrawLinestringRestrict line for withdrawal
    > transferLinestringRestrict line for transfer
    > spotBuyLinestringRestrict line for SPOT buy
    > spotSellLinestringRestrict line for SPOT sell
    > contractOpenLinestringRestrict line for CONTRACT open position
    > liquidationLinestringLine for liquidation
    > stopLiquidationLinestringLine for stop liquidation
    > contractLeveragestringAllowed max leverage of opening contract position
    > transferRatiostringAvailable transfer ratio of loan funds
    > spotSymbolsarrayThe whitelist of spot trading pairs
    > contractSymbolsarrayThe whitelist of contract trading pairs

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-loan-infos' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669364798602' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "loanInfo": [
    {
    "orderId": "1244781478207029504",
    "orderProductId": "34",
    "parentUid": "999805",
    "loanTime": "1663126149000",
    "loanCoin": "USDT",
    "loanAmount": "500000",
    "unpaidAmount": "6351.49614274",
    "unpaidInterest": "264.0137162",
    "repaidAmount": "493648.50385726",
    "repaidInterest": "0",
    "interestRate": "0.00027397",
    "status": 1,
    "leverage": "20",
    "supportSpot": 1,
    "supportContract": 1,
    "withdrawLine": "0.5",
    "transferLine": "0.6",
    "spotBuyLine": "0.7",
    "spotSellLine": "0.8",
    "contractOpenLine": "0.9",
    "liquidationLine": "0.95",
    "stopLiquidationLine": "0.20000000",
    "contractLeverage": "3",
    "transferRatio": "0.1",
    "spotSymbols": [
    "DYDXQQTEST001",
    "DYDXNEO",
    "PMTEST16USDT"
    ],
    "contractSymbols": [
    "RAYUSDT",
    "API3USDT",
    "SUSHIUSDT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669364798924
    }
    - + \ No newline at end of file diff --git a/spot/otc/ltv.html b/spot/otc/ltv.html index 47fc5f0697..2ea4f9a6a6 100644 --- a/spot/otc/ltv.html +++ b/spot/otc/ltv.html @@ -4,13 +4,13 @@ Get LTV | Bybit API Documentation - +

    Get LTV

    Get LTV. Please head here to get LTV if this API returns empty data.

    HTTP Request

    GET /spot/v3/private/margin-ltv

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    ltvInfoarrayObject
    > ltvstringRisk rate
    > parentUidstringUser id
    > subAccountUidsarrayBound user id
    > unpaidAmountstringTotal debt(USDT)
    > unpaidInfoarrayDebt details
    >> tokenstringcoin
    >> unpaidQtystringUnpaid principle
    >> unpaidIntereststringUnpaid interest
    > balancestringTotal asset. (margin coins converted to USDT). Please read here to understand the calculation
    > spotBalanceInfoarraySpot asset details
    >> tokenstringSpot margin coin
    >> pricestringSpot margin coin price
    >> qtystringSpot margin coin quantity
    > contractInfoarrayContract asset details
    >> tokenstringContract margin coin
    >> pricestringContract margin coin index price
    >> qtystringContract margin coin quantity (available balance of Contract account, and it is not involved with LTV calculation)

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-ltv' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669367335035' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.1147",
    "parentUid": "999805",
    "subAccountUids": [
    "999805"
    ],
    "unpaidAmount": "",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "6351.49614274",
    "unpaidInterest": "264.0137162"
    }
    ],
    "balance": "57626.875915433333333332400000000",
    "spotBalanceInfo": [
    {
    "token": "BTC",
    "price": "16375.621333333333333332",
    "qty": "0.2"
    },
    ....
    {
    "token": "XRP",
    "price": "0.409517",
    "qty": "10000"
    }
    ],
    "contractInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669367335608
    }
    - + \ No newline at end of file diff --git a/spot/otc/product-info.html b/spot/otc/product-info.html index efeac28a8b..779989209d 100644 --- a/spot/otc/product-info.html +++ b/spot/otc/product-info.html @@ -4,13 +4,13 @@ Get Margin Product Info | Bybit API Documentation - +

    Get Margin Product Info

    tip

    This is a public endpoint, so it does not need to authenticate.

    HTTP Request

    GET /spot/v3/public/margin-product-infos

    Request Parameters

    ParameterRequiredTypeComments
    productIdfalsestringProduct Id. If not passed, then return all products info

    Response Parameters

    ParameterTypeComments
    marginProductInfoarrayObject
    > productIdstringProduct Id
    > leveragestringleverage
    > supportSpotintegerWhether to support spot. 0:false; 1:true
    > supportContractintegerWhether to support contract. 0:false; 1:true
    > withdrawLinestringRestrict line for withdrawal
    > transferLinestringRestrict line for transfer
    > spotBuyLinestringRestrict line for SPOT buy
    > spotSellLinestringRestrict line for SPOT sell
    > contractOpenLinestringRestrict line for CONTRACT open position
    > liquidationLinestringLine for liquidation
    > stopLiquidationLinestringLine for stop liquidation
    > contractLeveragestringAllowed max leverage of opening contract position
    > transferRatiostringAvailable transfer ratio of loan funds
    > spotSymbolsarrayThe whitelist of spot trading pairs
    > contractSymbolsarrayThe whitelist of contract trading pairs

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/margin-product-infos?productId=70'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginProductInfo": [
    {
    "productId": "70",
    "leverage": "5.00000000",
    "supportSpot": 1,
    "supportContract": 1,
    "withdrawLine": "0.5",
    "transferLine": "0.6",
    "spotBuyLine": "0.7",
    "spotSellLine": "0.8",
    "contractOpenLine": "0.9",
    "liquidationLine": "0.95",
    "stopLiquidationLine": "0.40000000",
    "contractLeverage": "",
    "transferRatio": "",
    "spotSymbols": [
    "DYDXQQTEST001"
    ],
    "contractSymbols": [
    "RAYUSDT",
    "API3USDT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669362961705
    }
    - + \ No newline at end of file diff --git a/spot/otc/repay-info.html b/spot/otc/repay-info.html index d9f2dc8aba..ab272796ab 100644 --- a/spot/otc/repay-info.html +++ b/spot/otc/repay-info.html @@ -4,13 +4,13 @@ Get Repay Info | Bybit API Documentation - +

    Get Repay Info

    Get repaid order information. Authentication needed.

    HTTP Request

    GET /spot/v3/private/margin-repaid-infos

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size. [1, 100]. Default: 100

    Response Parameters

    ParameterTypeComments
    repayInfoarrayObject
    > repayOrderIdstringRepaid order ID
    > repaidTimestringRepaid timestamp (ms)
    > tokenstringRepaid coin
    > quantitystringRepaid principle
    > intereststringRepaid interest
    > businessTypestringRepaid type. 1:normal repayment; 2:repaid by liquidation
    > statusstring1:outstanding; 2:paid off

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-repaid-infos?startTime=1663126392000&endTime=1663126394000' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669366647851' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "repayInfo": [
    {
    "repayOrderId": "8189",
    "repaidTime": "1663126393000",
    "token": "USDT",
    "quantity": "30000",
    "interest": "0",
    "businessType": "1",
    "status": "1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669366648366
    }
    - + \ No newline at end of file diff --git a/spot/public/bid-ask.html b/spot/public/bid-ask.html index ed7b65314f..924ae731c3 100644 --- a/spot/public/bid-ask.html +++ b/spot/public/bid-ask.html @@ -4,13 +4,13 @@ Best Bid/Ask Price | Bybit API Documentation - +

    Best Bid/Ask Price

    info

    If symbol is not specified, the best order price from all symbols will be returned

    HTTP Request

    GET /spot/v3/public/quote/ticker/bookTicker

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair

    Response Parameters

    ParameterTypeComments
    symbolstringName of the trading pair
    bidPricestringBest bid price
    bidQtystringBid quantity
    askPricestringBest ask price
    askQtystringAsk quantity
    timenumberMillisecond timestamp

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/bookTicker?symbol=BTCUSDT'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "bidPrice": "21170.14",
    "bidQty": "0.908276",
    "askPrice": "21250",
    "askQty": "0.009264",
    "time": 1659431461695
    },
    "retExtInfo": {},
    "time": 1659431462103
    }
    - + \ No newline at end of file diff --git a/spot/public/depth.html b/spot/public/depth.html index 3fed9f9a05..c8b4503afb 100644 --- a/spot/public/depth.html +++ b/spot/public/depth.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - +

    Order Book

    HTTP Request

    GET /spot/v3/public/quote/depth

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringsymbol
    limitfalseintegerLimit for data size. [1, 200]. Default: 100

    Response Parameters

    ParameterTypeComments
    timenumberCurrent time, unit in millisecond
    bidsarrayBid price and quantity, with best bid prices ranked from top to bottom
    asksarrayAsk price and quantity, with best ask prices ranked from top to bottom

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/depth?symbol=BTCUSDT&limit=1'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "time": 1659429083820,
    "bids": [
    [
    "21170.14",
    "0.050096"
    ]
    ],
    "asks": [
    [
    "21250",
    "0.00211"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1659429083979
    }
    - + \ No newline at end of file diff --git a/spot/public/instrument.html b/spot/public/instrument.html index 1fc9859fce..5923d806f9 100644 --- a/spot/public/instrument.html +++ b/spot/public/instrument.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +

    Instrument Info

    Get the spec of symbol information

    HTTP Request

    GET /spot/v3/public/symbols

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > namestringName of the trading pair
    > aliasstringAlias
    > baseCoinstringBase currency
    > quoteCoinstringQuote currency
    > basePrecisionstringDecimal precision (base currency)
    > quotePrecisionstringDecimal precision (quote currency)
    > minTradeQtystringMin. order qty (Not valid for market buy orders)
    > minTradeAmtstringMin. order value (Only valid for market buy orders)
    > minPricePrecisionstringMin. number of decimal places
    > maxTradeQtystringMax. order qty (It is ignored when you place an order with order type LIMIT_MAKER)
    > maxTradeAmtstringMax. order value (It is ignored when you place an order with order type LIMIT_MAKER)
    > categorystringCategory
    > innovationstring1 indicates that the price of this currency is relatively volatile
    > showStatusstring1 indicates that the symbol open for trading

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/symbols'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "name": "BTCUSDT",
    "alias": "BTCUSDT",
    "baseCoin": "BTC",
    "quoteCoin": "USDT",
    "basePrecision": "0.000001",
    "quotePrecision": "0.00000001",
    "minTradeQty": "0.000001",
    "minTradeAmt": "10",
    "maxTradeQty": "63.01197227",
    "maxTradeAmt": "1000000",
    "minPricePrecision": "0.01",
    "category": "1",
    "showStatus": "1",
    "innovation": "0"
    },
    {
    "name": "ETHUSDT",
    "alias": "ETHUSDT",
    "baseCoin": "ETH",
    "quoteCoin": "USDT",
    "basePrecision": "0.00001",
    "quotePrecision": "0.0000001",
    "minTradeQty": "0.00224",
    "minTradeAmt": "10",
    "maxTradeQty": "100000000",
    "maxTradeAmt": "100000000",
    "minPricePrecision": "0.01",
    "category": "1",
    "showStatus": "1",
    "innovation": "0"
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659067662931
    }
    - + \ No newline at end of file diff --git a/spot/public/kline.html b/spot/public/kline.html index b27e4503e7..e1f385d2d0 100644 --- a/spot/public/kline.html +++ b/spot/public/kline.html @@ -4,13 +4,13 @@ Kline | Bybit API Documentation - +

    Kline

    info

    It only returns the results from latest 1000 candles regardless of what interval is specified

    info

    If startTime and endTime are not specified, only the latest candles will be sent

    HTTP Request

    GET /spot/v3/public/quote/kline

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair
    intervaltruestringChart interval
    limitfalseintegerLimit for data size. [1, 1000]. Default: 1000
    startTimefalseintegerStart time (ms)
    endTimefalseintegerEnd time (ms)

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > tnumberTimestamp(ms)
    > sstringName of the trading pair
    > snstringAlias
    > cstringClose price
    > hstringHigh price
    > lstringLow price
    > ostringOpen price
    > vstringTrading volume

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/kline?symbol=BTCUSDT&interval=1m&limit=1'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "t": 1659430380000,
    "s": "BTCUSDT",
    "sn": "BTCUSDT",
    "c": "21170.14",
    "h": "21170.14",
    "l": "21127.86",
    "o": "21127.86",
    "v": "0.907276"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659430400353
    }
    - + \ No newline at end of file diff --git a/spot/public/last-price.html b/spot/public/last-price.html index 6d71a16e2f..a4424af0d9 100644 --- a/spot/public/last-price.html +++ b/spot/public/last-price.html @@ -4,13 +4,13 @@ Last Traded Price | Bybit API Documentation - +

    Last Traded Price

    info

    If symbol is not specified, the price from all symbols will be returned

    HTTP Request

    GET /spot/v3/public/quote/ticker/price

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringName of the trading pair

    Response Parameters

    ParameterTypeComments
    symbolstringName of the trading pair
    pricestringLast traded price

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/price?symbol=BTCUSDT'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "price": "21127.86"
    },
    "retExtInfo": {},
    "time": 1659431315936
    }
    - + \ No newline at end of file diff --git a/spot/public/merge-depth.html b/spot/public/merge-depth.html index f4c2182c9f..cd9aa22e91 100644 --- a/spot/public/merge-depth.html +++ b/spot/public/merge-depth.html @@ -4,13 +4,13 @@ Merged Order Book | Bybit API Documentation - +

    Merged Order Book

    HTTP Request

    GET /spot/v3/public/quote/depth/merged

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair
    scalefalseintegerPrecision of the merged orderbook, 1 means 1 digit
    limitfalseintegerLimit for data size. [1, 200]. Default: 100

    Response Parameters

    ParameterTypeComments
    timenumberCurrent time, unit in millisecond
    bidsarrayBid price and quantity, with best bid prices ranked from top to bottom
    asksarrayAsk price and quantity, with best ask prices ranked from top to bottom

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/depth/merged?symbol=BTCUSDT&scale=1&limit=1'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "time": 1659429646349,
    "bids": [
    [
    "21170.1",
    "0.049096"
    ]
    ],
    "asks": [
    [
    "21250",
    "0.00211"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1659429646652
    }
    - + \ No newline at end of file diff --git a/spot/public/recent-trade.html b/spot/public/recent-trade.html index 16f8065ba7..62cb347a61 100644 --- a/spot/public/recent-trade.html +++ b/spot/public/recent-trade.html @@ -4,13 +4,13 @@ Public Trading Records | Bybit API Documentation - +

    Public Trading Records

    HTTP Request

    GET /spot/v3/public/quote/trades

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair
    limitfalseintegerLimit for data size. [1, 60]. Default: 60

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > pricestringOrder price
    > timenumberCurrent timestamp (ms)
    > qtystringOrder quantity
    > isBuyerMakerinteger0:Sell or taker order, 1:Buy maker order
    > typestring0:normal trade, 1:Paradigm block trade

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/trades?symbol=BTCUSDT&limit=1'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "price": "21170.14",
    "time": 1659429793926,
    "qty": "0.907276",
    "isBuyerMaker": 0,
    "type": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659429835311
    }
    - + \ No newline at end of file diff --git a/spot/public/tickers.html b/spot/public/tickers.html index 48806a3f53..578839491d 100644 --- a/spot/public/tickers.html +++ b/spot/public/tickers.html @@ -4,13 +4,13 @@ Tickers | Bybit API Documentation - +

    Tickers

    HTTP Request

    GET /spot/v3/public/quote/ticker/24hr

    info

    If symbol is not specified, the data from all symbols will be returned

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringName of the trading pair

    Response Parameters

    ParameterTypeComments
    tnumberCurrent timestamp (ms)
    sstringName of the trading pair
    lpstringLast traded price
    hstringHigh price
    lstringLow price
    ostringOpen price
    bpstringBest bid price
    apstringBest ask price
    vstringTrading volume
    qvstringTrading quote volume

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/24hr?symbol=BTCUSDT'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "t": 1659430933736,
    "s": "BTCUSDT",
    "lp": "21127.86",
    "h": "22000",
    "l": "19779.14",
    "o": "19935.19",
    "bp": "21170.14",
    "ap": "21250",
    "v": "211.378621",
    "qv": "4460854.96730398"
    },
    "retExtInfo": {},
    "time": 1659430975794
    }
    - + \ No newline at end of file diff --git a/spot/rate-limit.html b/spot/rate-limit.html index 0fa8cda7a9..cdf7c9ac1a 100644 --- a/spot/rate-limit.html +++ b/spot/rate-limit.html @@ -4,7 +4,7 @@ Rate Limit | Bybit API Documentation - + @@ -15,7 +15,7 @@ in an unexpected violation.

    • GET/POST method (shared):
      • 120 requests per second for 5 consecutive seconds
    note

    All traffic to api.bybit.com or api.bytick.com share this limit regardless of if it accesses Spot, Derivatives or Options.

    After violating the limit your IP will be banned for a set period of time (usually 30 minutes). Continually violating the limit will result in a permanent ban. We cannot undo permanent bans or shorten temporary bans.

    API Rate Limit

    caution

    If you receive "ret_msg": "Too many visits!" in the JSON response, you have hit the API rate limit.

    The API rate limit is based on the rolling time window per second and UID. In other words, it is per second per UID. Every request to the API returns response header shown in the code panel:

    • X-Bapi-Limit-Status - your remaining requests for current endpoint
    • X-Bapi-Limit - your current limit for current endpoint
    • X-Bapi-Limit-Reset-Timestamp - the timestamp indicating when your request limit resets if you have exceeded your rate_limit. Otherwise, this is just the current timestamp.

    Http Response Header Example

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    API Rate Limit Table

    PathLimit
    Cross margin trade5 req/s
    All other private endpoints20 req/s

    How to increase API Limit

    Please email api@bybit.com with the following information. We will reply within 1-4 working days:

    1. Your name and your company details
    2. Your Bybit UID or registered email, and the assets you are trading
    3. General description of your trading strategy and reasons for higher rate limits
    4. Screenshot of previous monthly trading volume (maker/taker) on other platforms
    5. Optional: your order history in CSV format
    - + \ No newline at end of file diff --git a/spot/trade/batch-cancel.html b/spot/trade/batch-cancel.html index 70df148a24..d5493566df 100644 --- a/spot/trade/batch-cancel.html +++ b/spot/trade/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +

    Batch Cancel Order

    HTTP Request

    POST /spot/v3/private/cancel-orders

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair
    sidefalsestringSide. BUY, SELL
    orderTypesfalsestringOrder type. LIMIT in default. It allows multiple types, separated by comma, e.a LIMIT,LIMIT_MAKER
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    successstringBatch cancel successfully or not. 0:fail, 1:success

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-orders' \
    --header 'X-BAPI-SIGN: XXXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659078150737' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderTypes": "LIMIT,LIMIT_MAKER"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "success": "1"
    },
    "retExtInfo": {},
    "time": 1659080154042
    }
    - + \ No newline at end of file diff --git a/spot/trade/cancel-by-id.html b/spot/trade/cancel-by-id.html index 56050fc345..13433b2341 100644 --- a/spot/trade/cancel-by-id.html +++ b/spot/trade/cancel-by-id.html @@ -4,13 +4,13 @@ Batch Cancel Order By Id | Bybit API Documentation - +

    Batch Cancel Order By Id

    HTTP Request

    POST /spot/v3/private/cancel-orders-by-ids

    Request Parameters

    ParameterRequiredTypeComments
    orderIdstruestringOrder ID, use commas to indicate multiple orderIds. Maximum of 100 ids.
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    listarrayObject. If all success, it returns empty array []
    > orderIdstringOrder ID
    > codestringErrors

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-orders-by-ids' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659080877551' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "orderIds": "1210851823244553984,1210852013162639104"
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": []
    },
    "retExtInfo": {},
    "time": 1659080815222
    }
    - + \ No newline at end of file diff --git a/spot/trade/cancel.html b/spot/trade/cancel.html index a016d43b9d..7d2eda1255 100644 --- a/spot/trade/cancel.html +++ b/spot/trade/cancel.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    HTTP Request

    POST /spot/v3/private/cancel-order

    Request Parameters

    ParameterRequiredTypeComments
    orderIdfalsestringOrder ID. Required if not passing orderLinkId
    orderLinkIdfalsestringUnique user-set order ID. Required if not passing orderId
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser-generated order ID
    symbolstringName of the trading pair
    statusstringOrder status
    accountIdstringAccount ID
    orderPricestringOrder price
    createTimestringOrder Creation Time
    orderQtystringOrder quantity
    execQtystringExecuted quantity
    timeInForcestringTime in force
    orderTypestringOrder type
    sidestringSide. BUY, SELL

    Request Example

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-order' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659078017415' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "orderId": "1210810256551063296",
    "orderLinkId": null
    }'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1210810256551063296",
    "orderLinkId": "spotA0010",
    "symbol": "BTCUSDT",
    "status": "NEW",
    "accountId": "533287",
    "createTime": "1659075830464",
    "orderPrice": "23500",
    "orderQty": "0.01",
    "execQty": "0",
    "timeInForce": "GTC",
    "orderType": "LIMIT",
    "side": "SELL"
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659078151226
    }
    - + \ No newline at end of file diff --git a/spot/trade/get-order.html b/spot/trade/get-order.html index 2e6ec180e0..df7d48de89 100644 --- a/spot/trade/get-order.html +++ b/spot/trade/get-order.html @@ -4,13 +4,13 @@ Get Order | Bybit API Documentation - +

    Get Order

    HTTP Request

    GET /spot/v3/private/order

    Request Parameters

    ParameterRequiredTypeComments
    orderIdfalsestringOrder ID. Required if not passing orderLinkId
    orderLinkIdfalsestringUnique user-set order ID. Required if not passing orderId
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    accountIdstringAccount ID
    symbolstringName of the trading pair
    orderLinkIdstringUser-generated order ID
    orderIdstringOrder ID
    orderPricestringOrder price
    orderQtystringOrder quantity
    execQtystringExecuted quantity
    cummulativeQuoteQtystringTotal order quantity. For some historical data, it might less than 0, and that means it is not applicable
    avgPricestringAverage filled price
    statusstringOrder status
    timeInForcestringTime in force
    orderTypestringOrder type
    sidestringOrder direction
    stopPricestringStop price
    icebergQtystringPlease ignore
    createTimestringOrder created time in the match engine
    updateTimestringLast time order was updated
    isWorkingstringIs working. 0:valid, 1:invalid
    lockedstringReserved for order (if it's 0, it means that the funds corresponding to the order have been settled)
    blockTradeIdstringParadigm block trade ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP execution type
    smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    smpOrderIdstringThe counterparty's orderID which triggers this SMP execution

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/order?orderLinkId=spotA0010' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659076396894' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotA0010",
    "orderId": "1210810256551063296",
    "orderPrice": "23500",
    "orderQty": "0.01",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "NEW",
    "timeInForce": "GTC",
    "orderType": "LIMIT",
    "side": "SELL",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": "1659075830464",
    "updateTime": "1659075830497",
    "isWorking": "1",
    "locked": "0.01",
    "blockTradeId": "",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659076397365
    }
    - + \ No newline at end of file diff --git a/spot/trade/my-trades.html b/spot/trade/my-trades.html index 032eaf9918..c33a7afa1e 100644 --- a/spot/trade/my-trades.html +++ b/spot/trade/my-trades.html @@ -4,13 +4,13 @@ Trade History | Bybit API Documentation - +

    Trade History

    info
    • If startTime is not specified, you can only query for records in the last 7 days.
    • If you want to query for records older than 7 days, startTime is required.
    • It supports to query records up to 180 days.
    info

    If the orderId is null, fromTicketId is passed, and toTicketId is null, then the result is sorted by ticketId in ascend. Otherwise, the result is sorted by ticketId in descend.

    HTTP Request

    GET /spot/v3/private/my-trades

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringName of the trading pair
    orderIdfalsestringOrder ID
    limitfalsestringDefault value is 50, max 50
    startTimefalseintegerStart timestamp (ms)
    endTimefalseintegerEnd time timestamp (ms)
    fromTradeIdfalsestringQuery greater than the trade ID
    toTradeIdfalsestringQuery smaller than the trade ID

    Response Parameters

    ParameterTypeComments
    symbolstringName of the trading pair
    idstringIrrelevant for API usage. This field reflects the "Transaction ID" from the Trade History section of the website
    orderIdstringOrder ID
    tradeIdstringThe ID for the trade
    orderPricestringLast traded price
    orderQtystringOrder quantity
    execFeestringTrading fee (for a single fill)
    feeTokenIdstringFee Token ID
    creatTimestringOrder created time in the match engine
    isBuyerstring0:Buyer, 1:Seller
    isMakerstring0:Maker, 1:Taker
    matchOrderIdstringOrder ID of the opponent trader
    makerRebatestringMaker rebate
    executionTimestringOrder execution time
    blockTradeIdstringParadigm block trade ID

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/my-trades?symbol=BTCUSDT' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659084253772' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "id": "1210346127973428992",
    "orderId": "1210073515485572864",
    "tradeId": "2100000000001769786",
    "orderPrice": "20500",
    "orderQty": "0.02",
    "execFee": "0.00002",
    "feeTokenId": "BTC",
    "creatTime": "1659020488738",
    "isBuyer": "0",
    "isMaker": "0",
    "matchOrderId": "1210346015893229312",
    "makerRebate": "0",
    "executionTime": "1659020502026"
    "blockTradeId": ""
    },
    {
    "symbol": "BTCUSDT",
    "id": "1208702504949264128",
    "orderId": "1208702504731160320",
    "tradeId": "2100000000001753197",
    "orderPrice": "20240",
    "orderQty": "0.009881",
    "execFee": "0.000009881",
    "feeTokenId": "BTC",
    "creatTime": "1658824566874",
    "isBuyer": "0",
    "isMaker": "1",
    "matchOrderId": "1208677465155702529",
    "makerRebate": "0",
    "executionTime": "1658824566893"
    "blockTradeId": ""
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659084254366
    }
    - + \ No newline at end of file diff --git a/spot/trade/open-order.html b/spot/trade/open-order.html index 74806b2e3a..baaea5331f 100644 --- a/spot/trade/open-order.html +++ b/spot/trade/open-order.html @@ -4,13 +4,13 @@ Open Orders | Bybit API Documentation - +

    Open Orders

    HTTP Request

    GET /spot/v3/private/open-orders

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringName of the trading pair
    orderIdfalsestringSpecify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose
    limitfalseintegerLimit for data size. [1, 500]. Default: 500
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    accountIdstringAccount ID
    symbolstringName of the trading pair
    orderLinkIdstringUser-generated order ID
    orderIdstringOrder ID
    orderPricestringOrder price
    orderQtystringOrder quantity
    execQtystringExecuted quantity
    cummulativeQuoteQtystringTotal order quantity. For some historical data, it might less than 0, and that means it is not applicable
    avgPricestringAverage filled price
    statusstringOrder status
    timeInForcestringTime in force
    orderTypestringOrder type
    sidestringSide. BUY, SELL
    stopPricestringStop price
    icebergQtystringPlease ignore
    createTimeintegerOrder created time in the match engine
    updateTimeintegerLast time order was updated
    isWorkingstringIs working. 0:valid, 1:invalid
    orderCategoryintegerOrder category. 0:normal order; 1:TP/SL order. TP/SL order has this field
    triggerPricestringTrigger price. TP/SL order has this field
    blockTradeIdstringParadigm block trade ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP execution type
    smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    smpOrderIdstringThe counterparty's orderID which triggers this SMP execution

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/open-orders?symbol=BTCUSDT' \
    --header 'X-BAPI-SIGN: e28768ea749013bbd0eb38edf78e1cac187d3018e4807859a84a37cf52feb5c0' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659081676022' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotx004",
    "orderId": "1210858291884732160",
    "orderPrice": "23500",
    "orderQty": "0.02",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "NEW",
    "timeInForce": "GTC",
    "orderType": "LIMIT_MAKER",
    "side": "SELL",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": 1659081556722,
    "updateTime": 1659081556740,
    "isWorking": "1",
    "blockTradeId": "",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659081570356
    }
    - + \ No newline at end of file diff --git a/spot/trade/order-history.html b/spot/trade/order-history.html index 0dac59d7cb..0fea7e0678 100644 --- a/spot/trade/order-history.html +++ b/spot/trade/order-history.html @@ -4,13 +4,13 @@ Order History | Bybit API Documentation - +

    Order History

    info
    • If startTime and endTime are both not specified, it returns last 7 days records by default. 3 days records for institutional clients.
    • Supports fetching 3 months worth of data per request. Returns data up to 6 months old.

    HTTP Request

    GET /spot/v3/private/history-orders

    Request Parameters

    ParameterRequiredTypeComments
    symbolfalsestringName of the trading pair
    orderIdfalsestringSpecify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose
    limitfalseintegerLimit for data size. [1, 500]. Default: 100
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.

    Response Parameters

    ParameterTypeComments
    accountIdstringAccount ID
    symbolstringName of the trading pair
    orderLinkIdstringUser-generated order ID
    orderIdstringOrder ID
    orderPricestringLast traded price
    orderQtystringOrder quantity
    execQtystringExecuted quantity
    cummulativeQuoteQtystringTotal order quantity
    avgPricestringAverage filled price
    statusstringOrder status
    timeInForcestringTime in force
    orderTypestringOrder type
    sidestringSide. BUY, SELL
    stopPricestringStop price
    icebergQtystringPlease ignore
    createTimenumberOrder created time in the match engine
    updateTimenumberLast time order was updated
    isWorkingstringIs working. 0:valid, 1:invalid
    orderCategoryintegerOrder category. 0:normal order; 1:TP/SL order. TP/SL order has this field
    triggerPricestringTrigger price. TP/SL order has this field
    blockTradeIdstringParadigm block trade ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP execution type
    smpGroupintegerSmp group ID. If the uid has no group, it is 0 by default
    smpOrderIdstringThe counterparty's orderID which triggers this SMP execution

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/history-orders?symbol=BTCUSDT&limit=2&startTime=1658246400000&endTime=1659110400000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659082629976' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotx003",
    "orderId": "1210856408331857664",
    "orderPrice": "23800",
    "orderQty": "0.02",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "REJECTED",
    "timeInForce": "GTC",
    "orderType": "LIMIT_MAKER",
    "side": "BUY",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": 1659081332185,
    "updateTime": 1659081332225,
    "isWorking": "1",
    "blockTradeId": "",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659082630638
    }
    - + \ No newline at end of file diff --git a/spot/trade/place-order.html b/spot/trade/place-order.html index b23a3b4910..c2979b1c96 100644 --- a/spot/trade/place-order.html +++ b/spot/trade/place-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +

    Place Order

    info

    Do not use the duplicate orderLinkId in normal order & TP/SL order

    HTTP Request

    POST /spot/v3/private/order

    Request Parameters

    ParameterRequiredTypeComments
    symboltruestringName of the trading pair
    orderQtytruestringOrder qty. When you place a MARKET BUY order, this param means quote amount. e.g., MARKET BUY BTCUSDT, orderQty should be 200 USDT
    sidetruestringSide. BUY, SELL
    orderTypetruestringOrder type
    timeInForcefalsestringTime in force
    orderPricefalsestringOrder price. When the type field is MARKET, the price field is optional. When the type field is LIMIT or LIMIT_MAKER, the price field is required
    orderLinkIdfalsestringUser-generated order ID
    orderCategoryfalseintegerOrder category. 0:normal order by default; 1TP/SL order, Required for TP/SL order.
    triggerPricefalsestringTrigger price. Used for TP/SL order
    smpTypefalsestringSmp execution type. What is SMP?

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser-generated order ID
    symbolstringName of the trading pair
    createTimestringOrder Creation Time
    orderPricestringLast traded price
    orderQtystringOrder quantity
    orderTypestringOrder type
    sidestringSide. BUY, SELL
    statusstringOrder status
    timeInForcestringTime in force
    accountIdstringAccount ID
    execQtystringPlease ignore
    orderCategoryintegerOrder category. 0:normal order by default; 1TP/SL order
    triggerPricestringTrigger price. TP/SL order has this field
    smpTypestringSmp execution type

    Request Example

    POST /spot/v3/private/order HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673333450317
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 146

    {
    "symbol": "ETHUSDT",
    "orderPrice": "1220",
    "side": "SELL",
    "orderQty": "1",
    "orderType": "LIMIT",
    "timeInForce": "GTC"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1330411843270754304",
    "orderLinkId": "1673333450634810",
    "symbol": "ETHUSDT",
    "createTime": "1673333450646",
    "orderPrice": "1220",
    "orderQty": "1",
    "orderType": "LIMIT",
    "side": "SELL",
    "status": "NEW",
    "timeInForce": "GTC",
    "accountId": "592335",
    "execQty": "0",
    "orderCategory": 0,
    "smpType": "None"
    },
    "retExtInfo": {},
    "time": 1673333450660
    }
    - + \ No newline at end of file diff --git a/spot/v1.html b/spot/v1.html index 774a79bfd8..7a8d49d359 100644 --- a/spot/v1.html +++ b/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/spot/v3.html b/spot/v3.html index 4f5036ff44..f4740bdc0d 100644 --- a/spot/v3.html +++ b/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/spot/wallet.html b/spot/wallet.html index 628d9cde14..5f74ac8327 100644 --- a/spot/wallet.html +++ b/spot/wallet.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - +

    Get Wallet Balance

    HTTP Request

    GET /spot/v3/private/account

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    balancesarrayObject
    > coinstringCoin
    > coinIdstringCoin ID
    > totalstringTotal equity
    > freestringAvailable balance
    > lockedstringReserved for orders

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/account' \
    --header 'X-BAPI-SIGN: XXXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659346886605' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "balances": [
    {
    "coin": "BTC",
    "coinId": "BTC",
    "total": "0.20378018343",
    "free": "0.20378018343",
    "locked": "0"
    },
    {
    "coin": "BTC3L",
    "coinId": "BTC3L",
    "total": "743.03560386",
    "free": "743.03560386",
    "locked": "0"
    },
    {
    "coin": "BTC3S",
    "coinId": "BTC3S",
    "total": "0.999",
    "free": "0.999",
    "locked": "0"
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659346887407
    }
    - + \ No newline at end of file diff --git a/spot/ws-private/execution.html b/spot/ws-private/execution.html index 6e5fe9cd58..49010a7560 100644 --- a/spot/ws-private/execution.html +++ b/spot/ws-private/execution.html @@ -4,13 +4,13 @@ Execution | Bybit API Documentation - +

    Execution

    This topic pushes filled trades information. When an order is filled, you will receive two messages: one from ticketInfo, and one from order / stopOrder

    Push frequency: real-time

    Topic: ticketInfo

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > estringEvent type
    > EstringEvent time
    > sstringTrading pair
    > qstringFilled quantity
    > tstringFilled timestamp (ms)
    > pstringFilled price
    > TstringTrade ID
    > ostringOrder ID
    > cstringUser-generated order ID
    > OstringOrder ID of the opponent trader
    > astringAccount ID
    > AstringAccount ID of the opponent trader
    > mbooleanIs MAKER. true: maker, false: taker
    > SstringSide. BUY, SELL
    > bstringParadigm block trade ID

    Subscribe Example

    {
    "req_id": "ticketInfo_1", //optional
    "op": "subscribe",
    "args": [
    "ticketInfo"
    ]
    }

    Stream Example

    {
    "type": "snapshot",
    "topic": "ticketInfo",
    "ts": "1662348310388",
    "data": [
    {
    "e": "ticketInfo",
    "E": "1662348310386",
    "s": "BTCUSDT",
    "q": "0.001007",
    "t": "1662348310373",
    "p": "19842.02",
    "T": "2100000000002220938",
    "o": "1238261807653647872",
    "c": "spotx008",
    "O": "1238225004531834368",
    "a": "533287",
    "A": "642908",
    "m": false,
    "S": "BUY",
    "b": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/spot/ws-private/order.html b/spot/ws-private/order.html index 3edb9a0088..f2bc4125da 100644 --- a/spot/ws-private/order.html +++ b/spot/ws-private/order.html @@ -4,13 +4,13 @@ Order | Bybit API Documentation - +

    Order

    This topic pushes order information,avg.filledPrice = Z / z

    Push frequency: real-time

    Topic: order

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > estringEvent type
    > EstringEvent time
    > sstringTrading pair
    > cstringUser-generated order ID
    > SstringBUY: buy order, SELL: sell order
    > ostringOrder type. LIMIT, MARKET_OF_QUOTE(Market Buy), MARKET_OF_BASE(Market Sell)
    > fstringTime in force
    > qstringOrder quantity
    > pstringOrder price
    > XstringOrder status
    > istringOrder ID
    > MstringOrder ID of the opponent trader
    > lstringLast filled quantity
    > zstringTotal filled quantity
    > LstringLast traded price
    > nstringTrading fee (for a single fill)
    > NstringAsset type in which fee is paid
    > ubooleanIs normal trade. False if self-trade.
    > wbooleanIs working. false:invalid; true:valid
    > mbooleanIs LIMIT_MAKER
    > OstringOrder creation timestamp (ms)
    > ZstringTotal filled value
    > AstringAccount ID of the opponent trader
    > CbooleanIs closed
    > vstringleverage
    > dstringNO_LIQ: it is not a liquidation order. IOC: it is a liquidation order
    > tstringTrade ID
    > bstringParadigm block trade ID
    > ctstringCancel type. CancelBySmp
    > ststringSMP execution type
    > sgintegerSmp group ID. If the uid has no group, it is 0 by default
    > sostringThe counterparty's orderID which triggers this SMP execution

    Subscribe Example

    {
    "req_id": "order_1", //optional
    "op": "subscribe",
    "args": [
    "order"
    ]
    }

    Stream Example

    {
    "type": "snapshot",
    "topic": "order",
    "ts": "1681698833381",
    "data": [
    {
    "e": "order",
    "E": "1681698833381",
    "s": "UNIUSDT",
    "c": "test-error-liangwuuu-02",
    "S": "BUY",
    "o": "MARKET_OF_QUOTE",
    "f": "GTC",
    "q": "15",
    "p": "0",
    "X": "CANCELED",
    "i": "1400585759234258176",
    "M": "0",
    "l": "0",
    "z": "0",
    "L": "0",
    "n": "0",
    "N": "",
    "u": true,
    "w": true,
    "m": false,
    "O": "1681698833313",
    "Z": "0",
    "A": "0",
    "C": false,
    "v": "0",
    "d": "NO_LIQ",
    "sg": 1005,
    "st": "CancelTaker",
    "ct": "CancelBySmp",
    "so": "1400584538658193920",
    "b": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/spot/ws-private/stop-order.html b/spot/ws-private/stop-order.html index f337122f2e..18a8cf1280 100644 --- a/spot/ws-private/stop-order.html +++ b/spot/ws-private/stop-order.html @@ -4,13 +4,13 @@ Stop Order | Bybit API Documentation - +

    Stop Order

    This topic pushes conditional order, TP/SL order information placed by web/app channel, and TP/SL order information placed by open api channel. It'll be triggered as long as order status is changed

    Push frequency: real-time

    Topic: stopOrder

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > estringEvent type
    > EstringEvent time
    > sstringTrading pair
    > cstringUser-generated order ID
    > SstringBUY: buy order, SELL: sell order
    > ostringOrder type. LIMIT, MARKET_OF_QUOTE(Market Buy), MARKET_OF_BASE(Market Sell)
    > fstringTime in force
    > qstringOrder quantity
    > pstringOrder price
    > XstringOrder status
    > istringOrder ID
    > TstringOrder created timestamp (ms)
    > tstringTP/SL order triggered timestamp (ms). The field has value only when order status is ORDER_FILLED and ORDER_FAILED
    > CstringOrder updated time. It is updated when order status is changed
    > qpstringThe market price when place the order
    > eostringThe new order ID after the TP/SL order is triggered
    > tistringPlease ignore
    > sistringPlease ignore
    > tpstringTrigger price

    Subscribe Example

    {
    "req_id": "stopOrder_1", //optional
    "op": "subscribe",
    "args": [
    "stopOrder"
    ]
    }

    Stream Example

    {
    "type": "snapshot",
    "topic": "stopOrder",
    "ts": "1678689442476",
    "data": [
    {
    "e": "stopOrder",
    "E": "1678689442476",
    "s": "XRPUSDT",
    "c": "1678689442086",
    "S": "BUY",
    "o": "LIMIT",
    "f": "GTC",
    "q": "100",
    "p": "0.335",
    "X": "ORDER_NEW",
    "i": "1375341158856660992",
    "T": "1678689442437",
    "t": "0",
    "C": "1678689442437",
    "qp": "0.3666",
    "eo": "1375341158856660993",
    "ti": "209a1cc923e1322315805fea6ed6fcbf",
    "si": "d980d5212ea83c87",
    "tp": "0.33"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/spot/ws-private/wallet.html b/spot/ws-private/wallet.html index 8de176d69d..7f155357ce 100644 --- a/spot/ws-private/wallet.html +++ b/spot/ws-private/wallet.html @@ -4,13 +4,13 @@ Wallet | Bybit API Documentation - +

    Wallet

    This topic pushes spot wallet information

    Push frequency: real-time

    Topic: outboundAccountInfo

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > estringEvent type
    > EstringTimestamp
    > TbooleanAllow trade
    > WbooleanAllow withdraw
    > DbooleanAllow deposit
    > BarrayWallet balance change
    >> astringcoin name
    >> fstringAvailable balance
    >> lstringReserved for orders

    Subscribe Example

    {
    "req_id": "acctInfo_1", //optional
    "op": "subscribe",
    "args": [
    "outboundAccountInfo"
    ]
    }

    Stream Example

    {
    "type": "snapshot",
    "topic": "outboundAccountInfo",
    "ts": "1662107217641",
    "data": [
    {
    "e": "outboundAccountInfo",
    "E": "1662107217640",
    "T": true,
    "W": true,
    "D": true,
    "B": [
    {
    "a": "USDT",
    "f": "176.81254174",
    "l": "201.575"
    }
    ]
    }
    ]
    }
    - + \ No newline at end of file diff --git a/spot/ws-public/bookticker.html b/spot/ws-public/bookticker.html index 69b49e4591..12201837cd 100644 --- a/spot/ws-public/bookticker.html +++ b/spot/ws-public/bookticker.html @@ -4,13 +4,13 @@ Bookticker | Bybit API Documentation - +

    Bookticker

    Best bid price and best ask price

    Push frequency: 100ms

    Topic: bookticker.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > sstringTrading pair
    > bpstringBest bid price
    > bqstringBid quantity
    > apstringBest ask price
    > aqstringAsk quantity
    > tnumberThe timestamp (ms) that system generates the data

    Subscribe Example

    {
    "req_id": "bookticker00001", //optional
    "op": "subscribe",
    "args": [
    "bookticker.BTCUSDT"
    ]
    }

    Stream Example

    {
    "topic": "bookticker.BTCUSDT",
    "ts": 1673437259336,
    "type": "snapshot",
    "data": {
    "s": "BTCUSDT",
    "bp": "17440",
    "bq": "0.0002",
    "ap": "17440.01",
    "aq": "0.21302",
    "t": 1673437259336
    }
    }
    - + \ No newline at end of file diff --git a/spot/ws-public/kline.html b/spot/ws-public/kline.html index c7e31b23a1..b9088e3be9 100644 --- a/spot/ws-public/kline.html +++ b/spot/ws-public/kline.html @@ -4,13 +4,13 @@ Kline | Bybit API Documentation - +

    Kline

    Subscribe the kline stream. Please find desired kline interval here.

    Topic: kline.{interval}.{symbol} e.g., kline.30m.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > tnumberThe start timestamp (ms) of the bar
    > sstringTrading pair
    > cstringClose price
    > hstringHigh price
    > lstringLow price
    > ostringOpen price
    > vstringTrading volume

    Subscribe Example

    {
    "req_id": "kline00001", //optional
    "op": "subscribe",
    "args": [
    "kline.30m.BTCUSDT"
    ]
    }

    Stream Example

    {
    "type": "snapshot",
    "topic": "kline.30m.BTCUSDT",
    "data": {
    "s": "BTCUSDT",
    "t": 1673436600000,
    "o": "17439.16",
    "c": "17437.82",
    "h": "17450.45",
    "l": "17433.5",
    "v": "34.059614"
    },
    "ts": 1673438143609
    }
    - + \ No newline at end of file diff --git a/spot/ws-public/orderbook.html b/spot/ws-public/orderbook.html index 9d2dea942d..355595dba3 100644 --- a/spot/ws-public/orderbook.html +++ b/spot/ws-public/orderbook.html @@ -4,13 +4,13 @@ Orderbook | Bybit API Documentation - +

    Orderbook

    Market depth data for a trading pair:

    • Snapshot depth: 40 each for asks and bids.
    • Events trigger order book version change:
      • order enters order book
      • order leaves order book
      • order quantity changes
      • order filled

    Pushes snapshot data only

    Push frequency: 100ms

    Topic: orderbook.40.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > sstringTrading pair
    > tnumberThe timestamp (ms) that system generates the data.
    > barrayBids. The element is sorted by price in descending order
    >> b[0]stringBid price
    >> b[1]stringBid size
    > aarrayAsks. The element is sorted by price in ascending order
    >> a[0]stringAsk price
    >> a[1]stringAsk size

    Subscribe Example

    {
    "req_id": "depth00001", //optional
    "op": "subscribe",
    "args": [
    "orderbook.40.BTCUSDT"
    ]
    }

    Stream Example

    {
    "topic": "orderbook.40.BTCUSDT",
    "ts": 1673439424737,
    "type": "snapshot",
    "data": {
    "s": "BTCUSDT",
    "t": 1673439424737,
    "b": [
    [
    "17423",
    "0.809534"
    ],
    [
    "17422.86",
    "0.043596"
    ],
    ...
    ],
    "a": [
    ...
    [
    "17428.28",
    "0.004811"
    ],
    [
    "17428.62",
    "0.23"
    ]
    ]
    }
    }
    - + \ No newline at end of file diff --git a/spot/ws-public/public-trade.html b/spot/ws-public/public-trade.html index 9d0a5709a6..56584b8ff2 100644 --- a/spot/ws-public/public-trade.html +++ b/spot/ws-public/public-trade.html @@ -4,13 +4,13 @@ Public trade | Bybit API Documentation - +

    Public trade

    This topic pushes raw trade information; each trade has a unique buyer and seller.

    Variable "v" acts as a tradeId. This variable is shared across different symbols; however, each ID is unique. For example, suppose in the last 5 seconds 3 trades happened in ETHUSDT, BTCUSDT, and BHTBTC. Their tradeId (which is "v") will be consecutive: 112, 113, 114.

    Push frequency: real-time

    Topic: trade.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > vstringTrade ID
    > tnumberTimestamp (trading time in the match box)
    > pstringPrice
    > qstringQuantity
    > mbooleanTrue indicates buy side is taker, false indicates sell side is taker
    > typestringTrade type. 0:Spot trade. 1:Paradigm block trade

    Subscribe Example

    {
    "req_id": "trade0001", //optional
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT"
    ]
    }

    Stream Example

    {
    "topic": "trade.BTCUSDT",
    "ts": 1673437259397,
    "type": "snapshot",
    "data": {
    "v": "2290000000036455162",
    "t": 1673437259395,
    "p": "17440",
    "q": "0.0002",
    "m": false,
    "type": "0"
    }
    }
    - + \ No newline at end of file diff --git a/spot/ws-public/ticker.html b/spot/ws-public/ticker.html index 4baeaa310b..007c3c41c3 100644 --- a/spot/ws-public/ticker.html +++ b/spot/ws-public/ticker.html @@ -4,13 +4,13 @@ Tickers | Bybit API Documentation - +

    Tickers

    The 24-hr statistics of a trading pair.

    Push frequency: real-time

    Topic: tickers.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    tsnumberThe timestamp (ms) that message is sent out
    typestringData type. snapshot
    dataarrayObject
    > tlongTimestamp (trading time in the match box)
    > sstringTrading pair
    > ostringOpen price
    > hstringHigh price
    > lstringLow price
    > cstringClose price
    > vstringTrading volume
    > qvstringTrading quote volume
    > mstringChange
    > xpstringUSD index price. It can be empty

    Request Example

    {
    "req_id": "ticker00001", //optional
    "op": "subscribe",
    "args": [
    "tickers.BTCUSDT"
    ]
    }

    Response Example

    {
    "topic": "tickers.BTCUSDT",
    "ts": 1673853966002,
    "type": "snapshot",
    "data": {
    "t": 1673853957769,
    "s": "BTCUSDT",
    "c": "21097.53",
    "h": "21426.99",
    "l": "20575",
    "o": "20705.31",
    "v": "6786.96571",
    "qv": "142076886.7193882",
    "m": "0.0189",
    "xp": "21109.48012482"
    }
    }
    - + \ No newline at end of file diff --git a/spot/ws/connect.html b/spot/ws/connect.html index dc672e6bad..83abe3ce20 100644 --- a/spot/ws/connect.html +++ b/spot/ws/connect.html @@ -4,13 +4,13 @@ Connect | Bybit API Documentation - +

    Connect

    info

    Note that the following endpoints only apply to Spot. To listen to other websockets, go to:

    Base endpoints:

    • Testnet:
      • Public Topics: wss://stream-testnet.bybit.com/spot/public/v3
      • Private Topics: wss://stream-testnet.bybit.com/spot/private/v3
    • Mainnet:
      • Public Topics: wss://stream.bybit.com/spot/public/v3
      • Private Topics: wss://stream.bybit.com/spot/private/v3
    info
    Public topics do not require authentication. The following section applies to private topics only.

    Apply for authentication when establishing a connection.

    Note: if you're using pybit, bybit-api or another high-level library, you can ignore this code - as authentication is handled for you.

    {
    "req_id": "10001", // optional
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //expires; is greater than your current timestamp
    "singature"
    ]
    }
    # based on: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )
    info

    Example signature algorithms can be found here.

    caution

    Due to network complexity, your may get disconnected at any time. Please follow the instructions below to ensure that you receive WebSocket messages on time:

    1. Keep connection alive by sending heartbeat packet
    2. Reconnect as soon as possible if disconnected

    How to Send Heartbeat Packet

    How to Send

    // req_id is a customised id, which is optional
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    The response sample of Pong

    // with req_id
    {"op":"pong","args":[1661741630642],"req_id":"100001","conn_id":"706b870c"}

    // without req_id
    {"op":"pong","args":[1661741654529],"conn_id":"706b870c"}
    caution

    To avoid networks or program issues, we recommend that you send the ping heartbeat packet every 20 seconds to maintain the WebSocket connection.

    IP Limits

    • Do not frequently connect and disconnect the connection.
    • Do not build over 500 connections in 5 minutes. This is counted separately per WebSocket endpoint.

    Rate Limits

    Private channel only:

    • Each API key may have a maximum of 100 private WebSocket connections. The 101st connection will be rejected.
    • An IP can connect to a maximum of 50 private spot websocket connections simultaneously.

    How to Subscribe to Topics

    Understanding Websocket Filters

    How to subscribe with a filter

    // Subscribing to the trade data for BTCUSDT
    {
    "req_id": "10001", // optional
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT"
    ]
    }

    support many symbol, separate with ','.

    // Example: Subscribing to the trade data for BTCUSDT and ETHUSDT
    {
    "req_id": "10001", // optional
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT",
    "trade.ETHUSDT"
    ]
    }

    After establishing the connection, you can subscribe to a new topic by sending a JSON request. The request formats are as follows:

    ws.send('{"req_id": "10001", "op": "subscribe", "args": ["trade.BTCUSDT", "trade.ETHUSDT", "tickers.BTCUSDT", "bookticker.BTCUSDT"]}')
    tip

    You can input up to 10 args for each subscription request sent to one connection

    Understanding Websocket Filters unsubscription

    After successful subscription, you can unsubscribe by sending a JSON request. The request formats are as follows:

    ws.send('{"req_id": "10002", "op": "unsubscribe", "args": ["trade.BTCUSDT"]}');
    // Example: unsubscribing to the trade data for BTCUSDT and ETHUSDT
    {
    "req_id": "10002", // optional
    "op": "unsubscribe",
    "args": [
    "trade.BTCUSDT",
    "trade.ETHUSDT"
    ]
    }
    // unsubscribe response sample
    {
    "op": "unsubscribe",
    "success": true,
    "req_id": "10002",
    "ret_msg": "unsubscribe",
    "conn_id": "46f097b7"
    }

    Understanding Subscription Response

    Subscription Response

    {
    "op": "subscribe",
    "success": true,
    "req_id": "10001",
    "ret_msg": "subscribe",
    "conn_id": "46f097b7"
    }

    Once you subscribe successfully, you'd receive result information. You can determine whether the subscription is successful based on the response.

    - + \ No newline at end of file diff --git a/tax.html b/tax.html index d88d678afc..a934651024 100644 --- a/tax.html +++ b/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/tax/data-export.html b/tax/data-export.html index 9864829e72..36b0e1ffd8 100644 --- a/tax/data-export.html +++ b/tax/data-export.html @@ -4,13 +4,13 @@ Retrieve Data Export | Bybit API Documentation - +

    Retrieve Data Export

    Retrieve data export

    HTTP Request

    POST /fht/compliance/tax/v3/private/url

    Request Parameters

    ParameterRequiredTypeComments
    queryIdtruestringReport Request ID

    Response Parameters

    ParameterTypeComments
    urlstringURL of files (Basepath + Files). To shorten the time it takes to generate the report, it could generate multiple files. Do take note of this and combine the several files using the same base path when requesting the data export
    info

    Convert S3 Files To CSV using python script

    Sample Python Script


    import pandas as pd
    import os

    class Bases(object):
    @staticmethod
    def path_list(path):
    """
    :param path:
    :return: list of file paths
    """
    file_list = []
    if os.path.isdir(path):
    print("it's a directory")
    for root, dirs, files in os.walk(path):
    for f in files:
    file = os.path.join(root, f)
    file_list.append(file)
    return file_list
    elif os.path.isfile(path):
    print("it's a normal file")
    return [path]

    class pd_service(Bases):
    def get_data(self, file_path):
    """
    Read s3 files, merge forms
    :param file_path:
    :return:
    """
    df_all = pd.DataFrame()
    for paths in self.path_list(path=file_path):
    df_all = pd.concat([df_all, pd.read_orc(paths)], axis=0)
    print('Row number of tables:', df_all[df_all.columns[1]].count())
    print(df_all.columns.values)
    df_all.sort_values("TradeTime", inplace=True)
    df_all.to_csv("test_data_s3.csv", header=True, index=False)
    print(df_all)
    return df_all

    if __name__ == '__main__':
    # file path
    path = 'XXXX'
    test = pd_service()
    test.get_data(file_path=path)

    Request Example

    POST /fht/compliance/tax/v3/private/url HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671184057480
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"queryId":"12312312415325325"}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "url": "{\"Files\":[\"20221216/adfsf34234-8e87-4c72-bc70-dsa234234daf/_SUCCESS\",\"20221216/dafasdf34243-8e87-4c72-bc70-dafsd34234/part-00000-adfsd34-00bd-4fe9-9591-adfasr343-c000\"],\"Basepath\":\"https://prod-bybit-tax-api-1705-rz.s3.ap-southeast-1.amazonaws.com/\"}"
    },
    "retExtInfo": {},
    "time": 1671184057646
    }
    - + \ No newline at end of file diff --git a/tax/enum.html b/tax/enum.html index 8fbfdbad09..5ab9536173 100644 --- a/tax/enum.html +++ b/tax/enum.html @@ -4,13 +4,13 @@ Enums Definitions | Bybit API Documentation - +

    Enums Definitions

    ReportType

    • TRADE - TradeHistory
    • P&L - P&L History
    • EARN - Earn History
    • DEPOSIT&WITHDRAWAL - Deposit and Withdrawal History
    • BONUS - Bonus History
    • AIRDROP - Airdrop History

    ReportNumber

    ReportType = "TRADE"

    • 1 - Get Spot Trade History
    • 2 - Get Contract Trade History
    • 3 - Get USDC Options Trade History
    • 4 - Get NFT Trade History

    ReportType = "P&L"

    • 1 - Get Contract Closed P&L History

    ReportType = "EARN"

    • 1 - Get BybitSavings Yield History
    • 2 - Get LiquidityMining Liquidity History
    • 3 - Get LiquidityMining Yield History
    • 4 - Get LiquidityMining Swap History
    • 5 - Get DualAsset Swap History
    • 6 - Get DeFiMining Yield History
    • 7 - Get Launchpool Yield History
    • 8 - Get Sharkfin Yield History

    ReportType = "DEPOSIT&WITHDRAWAL"

    • 1 - Get Crypto Deposit History
    • 2 - Get P2P Deposit History
    • 3 - Get Fiat Deposit and Withdraw History
    • 4 - Get Express Order Deposit History
    • 5 - Get Third Party Deposit History
    • 6 - Get Crypto Withdraw History
    • 7 - Get NFT Deposit and Withdrawal History

    ReportType = "BONUS"

    • 1 - Get Coupon History
    • 2 - Get Bonus History

    ReportType = "AIRDROP"

    • 1 - Get Airdrop History
    - + \ No newline at end of file diff --git a/tax/explain.html b/tax/explain.html index f3292fbb60..9c7420667f 100644 --- a/tax/explain.html +++ b/tax/explain.html @@ -4,13 +4,13 @@ Data Explanation | Bybit API Documentation - +

    Data Explanation

    Trade History

    1. Spot Trade History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order
    TradeIDstringTrade ID of the closing order
    SymbolstringName of the trading pair in the form of
    SidestringSide. Either Buy or Sell direction
    QuoteCoinstringSymbol of the Quote Coin
    BaseCoinstringSymbol of the Executed Coin
    ExecPricestringExecution Price
    ExecValuestringTransacted volume
    TradingFeestringTrading fee for a single fill
    FeeTokenstringToken of the Trading Fee
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    2. Contract Trade History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order.
    TradeIDstringTrade ID of the closing order.
    ContractTypestringTypes of Contract. Inverse Contracts, Linear Contracts, Future Contracts
    SymbolstringName of the trading pair in the form of
    SidestringSide. Either Buy or Sell direction
    QuoteCoinstringSymbol of the Quote Coin
    BaseCoinstringSymbol of the Executed Coin
    ExecPricestringExecution Price
    ExecQtystringTransaction Quantity
    ExecTypestringExecution Types. Trade, ADL, BustTrade
    ExecValuestringTransacted volume
    FeeRatestringRates for Maker or taker fee
    FeeTokenstringToken of the Trading Fee
    TradingFeestringTrading fee for a single fill
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed
    ClosedSizestringClosed postion size
    OrderTypestringOrder type

    3. USDC Options Trade History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order.
    TradeIDstringTrade ID of the closing order.
    ContractTypestringTypes of Contract. Inverse Contracts, Linear Contracts, Future Contracts
    SymbolstringName of the trading pair in the form of
    SidestringSide. Either Buy or Sell direction
    QuoteCoinstringSymbol of the Quote Coin
    BaseCoinstringSymbol of the Executed Coin
    ExecPricestringExecution Price
    ExecQtystringTransaction Quantity
    ExecTypestringExecution Types. Trade, ADL, BustTrade
    ExecValuestringTransacted volume
    FeeRatestringRates for Maker or taker fee
    FeeTokenstringToken of the Trading Fee
    TradingFeestringTrading fee for a single fill
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    4. NFT Trade History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order.
    NetworkstringName of Network.
    SidestringSide. Either Buy or Sell direction
    NftIdstringID of the NFT collection
    ExecValuestringTransacted volume
    BaseCoinstringSymbol of the Executed Coin
    PlatformFeestringFees for Platform, Fee is as per Base coin
    ShareFeestringFees for Sharing, Fee is as per Base coin
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    P&L History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order.
    ContractTypestringTypes of Contract. Inverse Contracts, Linear Contracts, Future Contracts
    SymbolstringName of the trading pair in the form of
    SidestringSide. Either Buy or Sell direction
    ClosedSizestringClosed Size
    CumEntryValuestringCumulative entry value
    AvgEntryPricestringAverage entry price
    CumExitValuestringCumulative exit value
    AvgExitPricestringAverage exit price
    SettleCoinstringSettle Coin. Coin for Profit and Loss
    ClosedPNLstringClosed Profit and Loss
    FillCountstringThe number of fills in a single order
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    Earn History

    1. BybitSavings Yield History

    Response Parameters

    ParameterTypeComments
    AssetStakedCoinstringCoin that was used to staked in the Bybit Savings Product
    StakingTypestringType of Staking. Flexible and Fixed Term
    AssetEarnedCoinstringCoin that the Interest is given out in
    EffectiveStakingAmountstringTotal amount staked with the Asset Staked coin
    YieldstringAmount of the Interest coin that was given out based on
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    2. LiquidityMining Liquidity History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID of the closing order.
    SymbolstringName of the trading pair in the form of
    OrderTypestringIncludes the different types of liquidity mining. Add, Remove, Reduce Leverage, Reinvest
    EntryPricestringEntry price of principal coin pair at time of order
    LeveragestringLeverage Multiples
    SlippagestringDifference between price of an order and the price when the order actually executes
    LiquiditystringLiquidity = Principal Change multiplied by Leverage
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    3. LiquidityMining Yield History

    Response Parameters

    ParameterTypeComments
    AssetEarnedCoinstringCoin that the Interest is given out in
    YieldstringAmount of the Interest coin that was given out based on
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    4. LiquidityMining Swap History

    Response Parameters

    ParameterTypeComments
    OrderIdstringtranslation missing: en.taxOrderID
    InitialCoinstringThe coin in the pair that you are trying to swap from.
    DepositAmountstringQuantity of the selected coin in the pair that you are trying to swap from
    SwapCoinstringThe coin in the pair that you are trying to swap into.
    SwapAmountstringQuantity of the selected coin in the pair that you are trying to swap to
    SwapFeeTokenstringFee will be in the swap coin.
    SwapFeestringFee incurred after the swap was successfully performed. Fee will be in the swap coin
    SlippagestringDifference between price of an order and the price when the order actually executes
    TradeTimestringUNIX Time. This is in milliseconds. Time when the trade was executed

    5. DualAsset Swap History

    Response Parameters

    ParameterTypeComments
    OrderIdstringOrder ID
    InitialCoinstringThe coin in the pair that you are trying to swap from.
    DepositAmountstringQuantity of the selected coin in the pair that you are trying to swap from
    SwapCoinstringThe coin in the pair that you are trying to swap into.
    SwapAmountstringQuantity of the selected coin in the pair that you are trying to swap to
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    TradeTimenumberUNIX Time. This is in milliseconds. Time when the trade was executed

    6. DeFiMining Yield History

    Response Parameters

    ParameterTypeComments
    OrderIdstringtranslation missing: en.taxOrderID
    AssetStakedCoinstringCoin that was used to staked in the Bybit Savings Product
    YieldstringAmount of the Interest coin that was given out based on
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    TradeTimenumberUNIX Time. This is in milliseconds. Time when the trade was executed

    7. Launchpool Yield History

    Response Parameters

    ParameterTypeComments
    AssetEarnedCoinstringCoin that the Interest is given out in
    EffectiveStakingAmountstringTotal amount staked with the Asset Staked coin
    YieldstringAmount of the Interest coin that was given out based on
    TradeTimenumberUNIX Time. This is in milliseconds. Time when the trade was executed

    8. Sharkfin Yield History

    Response Parameters

    ParameterTypeComments
    AssetEarnedCoinstringCoin that the Interest is given out in
    YieldstringAmount of the Interest coin that was given out based on
    TradeTimenumberUNIX Time. This is in milliseconds. Time when the trade was executed

    Deposit And Withdraw History

    1. Crypto Deposit History

    Response Parameters

    ParameterTypeComments
    TxidstringTransactionID
    DepositTypestringType of Deposit. On-chain Deposit
    ChainTypestringChain name
    SymbolstringName of the trading pair in the form of
    FinalAmountstringQuantity of Crypto
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    2. P2P Deposit History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID
    OrderTypestringIncludes the different types of liquidity mining. Add, Remove, Reduce Leverage, Reinvest
    P2pSidestringFor P2P Buyer, this represents the buyer bought the respective Coin and using Fiat currency. For P2P Seller, this represents the buyer sold the respective Coin and receive Fiat currency in return.
    FiatstringFiat type
    FiatAmountstringFiat deposited
    CoinstringSymbol of coin purchased
    CoinPricestringPrice of coin purchased
    CoinAmountstringQuantity of coin that is purchased
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    3. Fiat Deposit and Withdraw History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID
    TypestringType. DEPOSIT, WITHDRAW
    FiatstringFiat type
    DepositAmountstringQuantity of the selected coin in the pair that you are trying to swap from
    FinalAmountstringQuantity of Crypto
    FeestringFee for Fiat Deposit
    PaymentMethodsstringDifferent payment methods
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    4. Express Order Deposit History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID
    SidestringType of Order. Buy
    FiatstringFiat type
    DepositAmountstringFiat deposited via Credit card.
    DestinationCoinstringSymbol of coin purchased
    CoinPricestringPrice of coin purchased
    FinalAmountstringQuantity of Crypto
    FeestringAny fees in fiat involved when depositing via Credit card
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    5. Third Party Deposit History

    Response Parameters

    ParameterTypeComments
    OrderIDstringOrder ID
    TxidstringTransactionID
    PlatformstringPayment Platform methods
    FiatstringFiat type
    DepositAmountstringQuantity of the selected coin in the pair that you are trying to swap from
    DestinationCoinstringSymbol of coin purchased
    CoinPricestringPrice of coin purchased
    FinalAmountstringQuantity of Crypto
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    6. Crypto Withdraw History

    Response Parameters

    ParameterTypeComments
    TxidstringTransactionID
    ChainTypestringChain name
    CoinstringSymbol of coin purchased
    FinalAmountstringQuantity of Crypto
    FeestringWithdrawal fee as per the withdrawal coin
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    7. NFT Deposit and Withdrawal History

    Response Parameters

    ParameterTypeComments
    OrderIdstringtranslation missing: en.taxOrderID
    TxHashstringUnique IDs recording each NFT transaction
    TokenIdstringAll NFTs have a uint256 variable that identifies different NFT
    TransferTypestringType. Deposit, Withdrawal
    NetworkstringName of Network.
    FeeTokenstringToken of the Trading Fee
    FeestringAny fee incurred using the transaction of the NFT
    OrderTimenumberUNIX Time. This is in milliseconds. Time which the order was ordered
    CompletedTimenumberComplete timestamp (ms)

    Bonus History

    tip
  • Bonus - The experience bonus can be used to open a position and deduct the handling fee and the funding rate fee because it is paid directly to the user's asset account. All bonuses shown are already applied by the users.
  • Coupon - Money from coupons are deductible will only be used to offset the handling fee. It will not be added to the user's asset account. It will be refunded to the user's asset account following the deduction. All coupons shown are already applied by the users.
  • 1. Coupon History

    Response Parameters

    ParameterTypeComments
    CoinstringCoin that is given to user as coupon
    FinalAmountstringAmount of the coin given to user
    CompletedTimenumberComplete timestamp (ms)

    2. Bonus History

    Response Parameters

    ParameterTypeComments
    CoinstringCoin that is given to user as coupon
    FinalAmountstringAmount of the coin given to user
    CompletedTimenumberComplete timestamp (ms)

    Airdrop History

    Response Parameters

    ParameterTypeComments
    CoinstringCoin that is airdropped to user
    FinalAmountstringAmount of the airdrop given to user
    TransferTypestringType of Airdrop. Airdrop Deposit, Airdrop Withdrawal
    TransferDescriptionstringDescription of the Transfer
    CompletedTimenumberComplete timestamp (ms)
    - + \ No newline at end of file diff --git a/tax/report.html b/tax/report.html index bab5f78be1..dcbd6bc8eb 100644 --- a/tax/report.html +++ b/tax/report.html @@ -4,13 +4,13 @@ Request Export Report | Bybit API Documentation - +

    Request Export Report

    Request to export report

    HTTP Request

    POST /fht/compliance/tax/v3/private/create

    Request Parameters

    ParameterRequiredTypeComments
    typetruestringReport Type
    numbertruestringReport Number
    startTimetruestringUNIX Time. This is in seconds. Timestamp for report start time. The StartTime is included in the Time range for the Data Export.
    endTimetruestringUNIX Time. This is in seconds. Timestamp for report end time. The EndTime is not included in the Time range for the Data Export. Do note that for each request, we will only allow up to 2 months time range search from the StartTime

    Response Parameters

    ParameterTypeComments
    queryIdstringReport Request ID

    Request Example

    POST /fht/compliance/tax/v3/private/create HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183681683
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"startTime":"1667264621","endTime":"1669261057","type":"TRADE","number":"2"}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "queryId": "12312312415325325"
    },
    "retExtInfo": {},
    "time": 1671183681990
    }
    - + \ No newline at end of file diff --git a/tax/status.html b/tax/status.html index b07f22b3e4..740b588c8d 100644 --- a/tax/status.html +++ b/tax/status.html @@ -4,13 +4,13 @@ Get Export Report Status | Bybit API Documentation - +

    Get Export Report Status

    Get Export Report Status

    HTTP Request

    POST /fht/compliance/tax/v3/private/status

    Request Parameters

    ParameterRequiredTypeComments
    queryIdtruestringReport Request ID

    Response Parameters

    ParameterTypeComments
    statusstring
    • -1: Failed
    • 0: Queued
    • 1: Processing
    • 2: Processed
    • 3: Expired

    Request Example

    POST /fht/compliance/tax/v3/private/status HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183923110
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"queryId":"12312312415325325"}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "status": "2"
    },
    "retExtInfo": {},
    "time": 1671183923244
    }
    - + \ No newline at end of file diff --git a/tax/time.html b/tax/time.html index e98aed3f4f..7a2078cf88 100644 --- a/tax/time.html +++ b/tax/time.html @@ -4,13 +4,13 @@ Get User Register Date | Bybit API Documentation - +

    Get User Register Date

    Get User Register Date

    HTTP Request

    POST /fht/compliance/tax/v3/private/registertime

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    registerTimestringUNIX Time. This is in seconds. Date that the specific user registers on the platform

    Request Example

    POST /fht/compliance/tax/v3/private/registertime HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183584043
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "registerTime": "1634515200"
    },
    "retExtInfo": {},
    "time": 1671183584270
    }
    - + \ No newline at end of file diff --git a/testnet/account_asset.html b/testnet/account_asset.html index 13470da853..f286131d47 100644 --- a/testnet/account_asset.html +++ b/testnet/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/account_asset/v1.html b/testnet/account_asset/v1.html index 73b8e7af82..6c7f0d9df0 100644 --- a/testnet/account_asset/v1.html +++ b/testnet/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/account_asset/v3.html b/testnet/account_asset/v3.html index f4a252c113..634ba0860c 100644 --- a/testnet/account_asset/v3.html +++ b/testnet/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/copy_trading.html b/testnet/copy_trading.html index 691da562e8..90be49f716 100644 --- a/testnet/copy_trading.html +++ b/testnet/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/derivativesV3/contract.html b/testnet/derivativesV3/contract.html index f0bb75227b..1323af27e2 100644 --- a/testnet/derivativesV3/contract.html +++ b/testnet/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/derivativesV3/unified_margin.html b/testnet/derivativesV3/unified_margin.html index 3f7ea811fd..ff2548c942 100644 --- a/testnet/derivativesV3/unified_margin.html +++ b/testnet/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/futuresV2/inverse.html b/testnet/futuresV2/inverse.html index 1a2ce3d1b9..df54a4333f 100644 --- a/testnet/futuresV2/inverse.html +++ b/testnet/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/futuresV2/inverse_futures.html b/testnet/futuresV2/inverse_futures.html index ce00bc57fb..51962040ff 100644 --- a/testnet/futuresV2/inverse_futures.html +++ b/testnet/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/futuresV2/linear.html b/testnet/futuresV2/linear.html index 10d1c9f4bb..c6b3e2abdd 100644 --- a/testnet/futuresV2/linear.html +++ b/testnet/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/inverse.html b/testnet/inverse.html index 71aac1c59e..c7cac7e65e 100644 --- a/testnet/inverse.html +++ b/testnet/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/inverse_futures.html b/testnet/inverse_futures.html index 2c984d7f6e..8efea2fd4b 100644 --- a/testnet/inverse_futures.html +++ b/testnet/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/linear.html b/testnet/linear.html index 8fa1c9747f..819fb598b4 100644 --- a/testnet/linear.html +++ b/testnet/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/spot.html b/testnet/spot.html index 331fd2d214..f7901378ce 100644 --- a/testnet/spot.html +++ b/testnet/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/spot/v1.html b/testnet/spot/v1.html index 3136d1c680..679b35b703 100644 --- a/testnet/spot/v1.html +++ b/testnet/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/spot/v3.html b/testnet/spot/v3.html index ad48236b24..cc0c553929 100644 --- a/testnet/spot/v3.html +++ b/testnet/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/tax.html b/testnet/tax.html index 5dfbbe4a3e..7d4f782884 100644 --- a/testnet/tax.html +++ b/testnet/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/usdc/option.html b/testnet/usdc/option.html index d70d811cd5..2c90a66973 100644 --- a/testnet/usdc/option.html +++ b/testnet/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/testnet/usdc/perpetual.html b/testnet/usdc/perpetual.html index 9464867a99..d19d99920c 100644 --- a/testnet/usdc/perpetual.html +++ b/testnet/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/usdc/option.html b/usdc/option.html index 55feac7bc9..07344e558d 100644 --- a/usdc/option.html +++ b/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/usdc/perpetual.html b/usdc/perpetual.html index ecf5b907f9..3019f7936d 100644 --- a/usdc/perpetual.html +++ b/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/v3/intro.html b/v3/intro.html index b401b5737c..54098c4c67 100644 --- a/v3/intro.html +++ b/v3/intro.html @@ -4,7 +4,7 @@ Introduction | Bybit API Documentation - + @@ -15,7 +15,7 @@ server_time - recv_window <= timestamp < server_time + 1000
    server_time stands for Bybit server time, which can be queried via the Server Time endpoint.

    Create A Request

    tip

    To assist in diagnosing advanced network problems, you may consider adding cdn-request-id to your request headers. Its value should be unique for each request.

    info

    Example signature algorithms can be found here

    Basic steps:

    1. timestamp + api-key + (recv_window) + (queryString | jsonBodyString)
    2. Use the HMAC_SHA256 or RSA_SHA256 algorithm to sign the string in step 1, and convert it to a hex string (HMAC_SHA256) / base64 (RSA_SHA256) to obtain the sign parameter.
    3. Append the sign parameter to request header, and send the HTTP request. Note: the plain text for GET and POST requests is different. Please refer to blew examples.

    An example for how to generate plain text to encrypt

    # rule:
    timestamp+api_key+recv_window+queryString

    # param_str
    "1658384314791XXXXXXXXXX5000category=option&symbol=BTC-29JUL22-25000-C"

    # parse
    timestamp = "1658384314791"
    api_key = "XXXXXXXXXX"
    recv_window = "5000"
    queryString = "category=option&symbol=BTC-29JUL22-25000-C"

    http request examples

    GET /unified/v3/private/order/list?category=option&symbol=BTC-29JUL22-25000-C HTTP/1.1
    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'
    -H 'cdn-request-id: test-001'

    Common response parameters

    Derivatives

    ParameterTypeComments
    retCodenumberSuccess/Error code
    retMsgstringSuccess/Error msg. Can be OK,success,Success for Success message
    resultObjectBusiness data result
    retExtInfoObjectExtend info. Most of time, it is {}
    timenumberCurrent timestamp (ms)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }

    Spot

    ParameterTypeComments
    retCodenumberSuccess/Error code
    retMsgstringSuccess/Error msg. Can be OK,success,Success for Success message
    resultObjectBusiness data result
    retExtInfoObjectExtend info. Most of time, it is {}
    timenumberCurrent timestamp (ms)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }

    Account Asset

    ParameterTypeComments
    retCodenumberSuccess/Error code
    retMsgstringSuccess/Error msg. Can be OK,success,Success for Success message
    resultObjectBusiness data result
    retExtInfoObjectExtend info. Most of time, it is {}
    timenumberCurrent timestamp (ms)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }
    - + \ No newline at end of file diff --git a/v3/server-time.html b/v3/server-time.html index fc9b8559ec..280d6d45a7 100644 --- a/v3/server-time.html +++ b/v3/server-time.html @@ -4,13 +4,13 @@ Bybit Server Time | Bybit API Documentation - +

    Bybit Server Time

    Get the Bybit server timestamp

    HTTP Request

    GET /v3/public/time

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    timeSecondstringBybit server timestamp (sec)
    timeNanostringBybit server timestamp (nano)

    Request Example

    curl https://api-testnet.bybit.com/v3/public/time

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "timeSecond": "1674026082",
    "timeNano": "1674026082947745743"
    },
    "retExtInfo": {},
    "time": 1674026082947
    }
    - + \ No newline at end of file diff --git a/v3/smp.html b/v3/smp.html index c900e1f93e..daad2f4ff1 100644 --- a/v3/smp.html +++ b/v3/smp.html @@ -4,7 +4,7 @@ Self Match Prevention | Bybit API Documentation - + @@ -19,7 +19,7 @@ the pre-existing orders to avoid the unexpected execution.

    1. SMP Trade Group has a higher priority on SMP execution, and UID will only take effect when there is no group on any side.

    Examples:
    1st of Jan: UID1 joined SMP Trade Group A, and placed Order1;
    2nd of Jan: UID1 was removed from SMP Trade Group A, but Order1 is still active and "New"

    • case1: If UID1 joined SMP Trade Group B, and placed Order2, if Order2 meets Order1, it will be executed since they belong to two different groups.
    • case2: If UID1 did not join any other groups after being removed from SMP Trade Group A, and placed Order2, if Order2 meets Order1, the SMP will be triggered because UID1 did not have a group when placed Order2, so SMP was triggered at the UID level (the same UID1).

    How to manage my UIDs & SMP Trade Group?

    You can contact your institutional business manager or email Bybit via: institutional_services@bybit.com

    Supported OpenAPI Versions and Product Lines

    Product linesOpenAPI version supportedComments
    SpotV3 (normal account)
    V5 (unified & normal account)
    ContractContract V3 (normal account): USDT perpetual / Inverse perpetual & futures
    V5 (unified account): USDT perpetual / Inverse perpetual & futures / USDC perpetual & futures
    V5 (normal account): USDT perpetual / Inverse perpetual & futures
    OptionV5 (unified account)V1 has a default SMP at UID level
    - + \ No newline at end of file diff --git a/v5/abandon/enable-unitransfer-subuid.html b/v5/abandon/enable-unitransfer-subuid.html index f9a2e3ffb7..5de99fbcae 100644 --- a/v5/abandon/enable-unitransfer-subuid.html +++ b/v5/abandon/enable-unitransfer-subuid.html @@ -4,13 +4,13 @@ Enable Universal Transfer for Sub UID | Bybit API Documentation - +

    Enable Universal Transfer for Sub UID

    info

    You no longer need to configure transferable sub UIDs. Now, all sub UIDs are automatically enabled for universal transfer.

    Transfer between sub-sub or main-sub

    Use this endpoint to enable a subaccount to take part in a universal transfer. It is a one-time switch which, once thrown, enables a subaccount permanently. If not set, your subaccount cannot use universal transfers.

    caution

    Can query by the master UID's api key only

    HTTP Request

    POST /v5/asset/transfer/save-transfer-sub-member

    Request Parameters

    ParameterRequiredTypeComments
    subMemberIdstruearrayThis list has a single item. Separate multiple UIDs by comma, e.g., "uid1,uid2,uid3"

    Response Parameters

    None


    Request Example

    POST /v5/asset/transfer/save-transfer-sub-member HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672147595971
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subMemberIds": ["554117,592324,592334"]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {},
    "retExtInfo": {},
    "time": 1672147593188
    }
    - + \ No newline at end of file diff --git a/v5/abandon/ltv.html b/v5/abandon/ltv.html index 851def1648..2a084ee6c5 100644 --- a/v5/abandon/ltv.html +++ b/v5/abandon/ltv.html @@ -4,13 +4,13 @@ Get LTV | Bybit API Documentation - +

    Get LTV

    HTTP Request

    GET /v5/ins-loan/ltv

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    ltvInfoarrayObject
    > ltvstringRisk rate
    > parentUidstringUser id
    > subAccountUidsarrayBound user id
    > unpaidAmountstringTotal debt(USDT)
    > unpaidInfoarrayDebt details
    >> tokenstringcoin
    >> unpaidQtystringUnpaid principle
    >> unpaidIntereststringUnpaid interest
    > balancestringTotal asset. (margin coins converted to USDT). Please read here to understand the calculation
    > spotBalanceInfoarraySpot asset details
    >> tokenstringSpot margin coin
    >> pricestringSpot margin coin price
    >> qtystringSpot margin coin quantity
    > contractInfoarrayContract asset details
    >> tokenstringContract margin coin
    >> pricestringContract margin coin index price
    >> qtystringContract margin coin quantity (available balance of Contract account, and it is not involved with LTV calculation)

    Request Example

    GET /v5/ins-loan/ltv HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1678688069538
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.1147",
    "parentUid": "999805",
    "subAccountUids": [
    "999805"
    ],
    "unpaidAmount": "",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "6351.49614274",
    "unpaidInterest": "264.0137162"
    }
    ],
    "balance": "57626.875915433333333332400000000",
    "spotBalanceInfo": [
    {
    "token": "BTC",
    "price": "16375.621333333333333332",
    "qty": "0.2"
    },
    ....
    {
    "token": "XRP",
    "price": "0.409517",
    "qty": "10000"
    }
    ],
    "contractInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669367335608
    }
    - + \ No newline at end of file diff --git a/v5/abandon/margin-coin-info.html b/v5/abandon/margin-coin-info.html index 3af7e9d9f2..31e7284aea 100644 --- a/v5/abandon/margin-coin-info.html +++ b/v5/abandon/margin-coin-info.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - +

    Get Margin Coin Info

    HTTP Request

    GET /v5/ins-loan/ensure-tokens

    Request Parameters

    ParameterRequiredTypeComments
    productIdfalsestringProductId. If not passed, then return all product margin coin. For spot, it returns coin that convertRation greater than 0.

    Response Parameters

    ParameterTypeComments
    marginTokenarrayObject
    > productIdstringProduct Id
    > spotTokenarraySpot margin coin
    >> tokenstringMargin coin
    >> convertRatiostringMargin coin convert ratio
    > contractTokenarrayContract margin coin
    >> tokenstringMargin coin
    >> convertRatiostringMargin coin convert ratio

    Request Example

    GET /v5/ins-loan/ensure-tokens?productId=70 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginToken": [
    {
    "productId": "70",
    "spotToken": [
    {
    "token": "BTC",
    "convertRatio": "1.00000000"
    },
    {
    "token": "ETH",
    "convertRatio": "1.00000000"
    },
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ],
    "contractToken": [
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669363954802
    }
    - + \ No newline at end of file diff --git a/v5/account/account-info.html b/v5/account/account-info.html index d915bc1d90..3295ea756a 100644 --- a/v5/account/account-info.html +++ b/v5/account/account-info.html @@ -4,13 +4,13 @@ Get Account Info | Bybit API Documentation - +

    Get Account Info

    Query the margin mode configuration of the account.

    note

    Query the margin mode and the upgraded status of account

    HTTP Request

    GET /v5/account/info

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    unifiedMarginStatusintegerAccount status
    marginModestringISOLATED_MARGIN, REGULAR_MARGIN, PORTFOLIO_MARGIN
    dcpStatusstringDisconnected-CancelAll-Prevention status: ON, OFF
    timeWindowintegerDCP trigger time window which user pre-set. Between [3, 300] seconds, default: 10 sec
    smpGroupintegerSmp group ID. If the UID has no group, it is 0 by default
    isMasterTraderbooleanWhether the account is a master trader (copytrading). true, false
    updatedTimestringAccount data updated timestamp (ms)

    Request Example

    GET /v5/account/info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672129307221
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginMode": "REGULAR_MARGIN",
    "updatedTime": "1665645428000",
    "unifiedMarginStatus": 1,
    "dcpStatus": "ON",
    "timeWindow": 15,
    "smpGroup": 0,
    "isMasterTrader": false
    }
    }
    - + \ No newline at end of file diff --git a/v5/account/borrow-history.html b/v5/account/borrow-history.html index fdf7e5a2ff..0615e4035c 100644 --- a/v5/account/borrow-history.html +++ b/v5/account/borrow-history.html @@ -4,13 +4,13 @@ Get Borrow History | Bybit API Documentation - +

    Get Borrow History

    Get interest records, sorted in reverse order of creation time.

    Unified account

    HTTP Request

    GET /v5/account/borrow-history

    Request Parameters

    ParameterRequiredTypeComments
    currencyfalsestringUSDC,USDT,BTC,ETH
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end time. timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > currencystringUSDC,USDT,BTC,ETH
    > createdTimeintegerCreated timestamp (ms)
    > borrowCoststringInterest
    > hourlyBorrowRatestringHourly Borrow Rate
    > InterestBearingBorrowSizestringInterest Bearing Borrow Size
    > costExemptionstringCost exemption
    > borrowAmountstringTotal borrow amount
    > unrealisedLossstringUnrealised loss
    > freeBorrowedAmountstringThe borrowed amount for interest free
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/account/borrow-history?currency=BTC&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672277745427
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "2671153%3A1%2C2671153%3A1",
    "list": [
    {
    "borrowAmount": "1.06333265702840778",
    "costExemption": "0",
    "freeBorrowedAmount": "0",
    "createdTime": 1697439900204,
    "InterestBearingBorrowSize": "1.06333265702840778",
    "currency": "BTC",
    "unrealisedLoss": "0",
    "hourlyBorrowRate": "0.000001216904",
    "borrowCost": "0.00000129"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1697442206478
    }
    - + \ No newline at end of file diff --git a/v5/account/coin-greeks.html b/v5/account/coin-greeks.html index 104ae5fa13..4c3f7dd0b6 100644 --- a/v5/account/coin-greeks.html +++ b/v5/account/coin-greeks.html @@ -4,13 +4,13 @@ Get Coin Greeks | Bybit API Documentation - +

    Get Coin Greeks

    Get current account Greeks information

    HTTP Request

    GET /v5/asset/coin-greeks

    Request Parameters

    ParameterRequiredTypeComments
    baseCoinfalsestringBase coin. If not passed, all supported base coin greeks will be returned by default

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > baseCoinstringBase coin. e.g.,BTC,ETH,SOL
    > totalDeltastringDelta value
    > totalGammastringGamma value
    > totalVegastringVega value
    > totalThetastringTheta value

    Request Example

    GET /v5/asset/coin-greeks?baseCoin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672287887610
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "baseCoin": "BTC",
    "totalDelta": "0.00004001",
    "totalGamma": "-0.00000009",
    "totalVega": "-0.00039689",
    "totalTheta": "0.01243824"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672287887942
    }
    - + \ No newline at end of file diff --git a/v5/account/collateral-info.html b/v5/account/collateral-info.html index d0ffab0022..b9f8144a8d 100644 --- a/v5/account/collateral-info.html +++ b/v5/account/collateral-info.html @@ -4,13 +4,13 @@ Get Collateral Info | Bybit API Documentation - +

    Get Collateral Info

    Get the collateral information of the current unified margin account, including loan interest rate, loanable amount, collateral conversion rate, whether it can be mortgaged as margin, etc.

    HTTP Request

    GET /v5/account/collateral-info

    Request Parameters

    ParameterRequiredTypeComments
    currencyfalsestringAsset currency of all current collateral

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > currencystringCurrency of all current collateral
    > hourlyBorrowRatestringHourly borrow rate
    > maxBorrowingAmountstringMax borrow amount. This value is shared across main-sub UIDs
    > freeBorrowingAmountstringDepreciated field, always return "", please refer to freeBorrowingLimit
    > freeBorrowingLimitstringThe maximum limit for interest-free borrowing
    > freeBorrowAmountstringThe amount of borrowing within your total borrowing amount that is exempt from interest charges
    > borrowAmountstringBorrow amount
    > availableToBorrowstringAvailable amount to borrow. This value is shared across main-sub UIDs
    > borrowablebooleanWhether currency can be borrowed
    > borrowUsageRatestringBorrow usage rate: borrowAmount/maxBorrowingAmount. It is an actual value between 0 and 1
    > marginCollateralbooleanWhether it can be used as a margin collateral currency (platform)
  • When marginCollateral=false, then collateralSwitch is meaningless
  • > collateralSwitchbooleanWhether the collateral is turned on by user (user)
  • When marginCollateral=true, then collateralSwitch is meaningful
  • > collateralRatiostringCollateral ratio

    Request Example

    GET /v5/account/collateral-info?currency=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672127952719
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "availableToBorrow": "3",
    "freeBorrowingAmount": "",
    "freeBorrowAmount": "0",
    "maxBorrowingAmount": "3",
    "hourlyBorrowRate": "0.00000147",
    "borrowUsageRate": "0",
    "collateralSwitch": true,
    "borrowAmount": "0",
    "borrowable": true,
    "currency": "BTC",
    "marginCollateral": true,
    "freeBorrowingLimit": "0",
    "collateralRatio": "0.95"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1691565901952
    }
    - + \ No newline at end of file diff --git a/v5/account/fee-rate.html b/v5/account/fee-rate.html index fe62abeaa4..e3ff1429a7 100644 --- a/v5/account/fee-rate.html +++ b/v5/account/fee-rate.html @@ -4,13 +4,13 @@ Get Fee Rate | Bybit API Documentation - +

    Get Fee Rate

    Get the trading fee rate.

    Covers: Spot / USDT perpetual / USDC perpetual / USDC futures / Inverse perpetual / Inverse futures / Options

    HTTP Request

    GET /v5/account/fee-rate

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot, linear, inverse, option
    symbolfalsestringSymbol name. Valid for linear, inverse, spot
    baseCoinfalsestringBase coin. SOL, BTC, ETH. Valid for option

    Response Parameters

    ParameterTypeComments
    categorystringProduct type. spot, option. Derivatives does not have this field
    listarrayObject
    > symbolstringSymbol name. Keeps "" for Options
    > baseCoinstringBase coin. SOL, BTC, ETH
    • Derivatives does not have this field
    • Keeps "" for Spot
    > takerFeeRatestringTaker fee rate
    > makerFeeRatestringMaker fee rate

    Request Example

    GET /v5/account/fee-rate?symbol=ETHUSDT HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXXX
    X-BAPI-API-KEY: XXXXXXX
    X-BAPI-TIMESTAMP: 1676360412362
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "takerFeeRate": "0.0006",
    "makerFeeRate": "0.0001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676360412576
    }
    - + \ No newline at end of file diff --git a/v5/account/get-mmp-state.html b/v5/account/get-mmp-state.html index 275e318411..51b24a8fa2 100644 --- a/v5/account/get-mmp-state.html +++ b/v5/account/get-mmp-state.html @@ -4,13 +4,13 @@ Get MMP State | Bybit API Documentation - +

    Get MMP State

    HTTP Request

    GET /v5/account/mmp-state

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin

    Response Parameters

    ParameterTypeComments
    resultarrayObject
    > baseCoinstringBase coin
    > mmpEnabledbooleanWhether the account is enabled mmp
    > windowstringTime window (ms)
    > frozenPeriodstringFrozen period (ms)
    > qtyLimitstringTrade qty limit
    > deltaLimitstringDelta limit
    > mmpFrozenUntilstringUnfreeze timestamp (ms)
    > mmpFrozenbooleanWhether the mmp is triggered.
    • true: mmpFrozenUntil is meaningful
    • false: please ignore the value of mmpFrozenUntil

    Request Example

    POST /v5/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "result": [
    {
    "baseCoin": "BTC",
    "mmpEnabled": true,
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "0.01",
    "deltaLimit": "0.01",
    "mmpFrozenUntil": "1675760625519",
    "mmpFrozen": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675843188984
    }
    - + \ No newline at end of file diff --git a/v5/account/reset-mmp.html b/v5/account/reset-mmp.html index 11fc9a8cd6..f230f5c562 100644 --- a/v5/account/reset-mmp.html +++ b/v5/account/reset-mmp.html @@ -4,13 +4,13 @@ Reset MMP | Bybit API Documentation - +

    Reset MMP

    info
    • Once the mmp triggered, you can unfreeze the account by this endpoint, then qtyLimit and deltaLimit will be reset to 0.
    • If the account is not frozen, reset action can also remove previous accumulation, i.e., qtyLimit and deltaLimit will be reset to 0.

    HTTP Request

    POST /v5/account/mmp-reset

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin

    Response Parameters

    None

    Request Example

    POST /v5/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/v5/account/set-collateral.html b/v5/account/set-collateral.html index cddb547330..61000561e6 100644 --- a/v5/account/set-collateral.html +++ b/v5/account/set-collateral.html @@ -4,13 +4,13 @@ Set Collateral Coin | Bybit API Documentation - +

    Set Collateral Coin

    You can decide whether the assets in the Unified account needs to be collateral coins.

    HTTP Request

    POST /v5/account/set-collateral-switch

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    • You can get collateral coin from here
    • USDT, USDC cannot be switched off
    collateralSwitchtruestringON: switch on collateral, OFF: switch off collateral

    Response Parameters

    None

    Request Example

    POST /v5/account/set-collateral-switch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1690513916181
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 55

    {
    "coin": "BTC",
    "collateralSwitch": "ON"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "result": {},
    "retExtInfo": {},
    "time": 1690515818656
    }
    - + \ No newline at end of file diff --git a/v5/account/set-margin-mode.html b/v5/account/set-margin-mode.html index 5a2edb1c85..5469ce4380 100644 --- a/v5/account/set-margin-mode.html +++ b/v5/account/set-margin-mode.html @@ -4,13 +4,13 @@ Set Margin Mode | Bybit API Documentation - +

    Set Margin Mode

    Default is regular margin mode

    info
    • UTA account can be switched between these 3 kinds of margin modes, which is across UID level, working for USDT Perp, USDC Perp, USDC Futures and Options (Option does not support ISOLATED_MARGIN)
    • Classic account can be switched between REGULAR_MARGIN and PORTFOLIO_MARGIN, only work for USDC Perp and Options trading.

    HTTP Request

    POST /v5/account/set-margin-mode

    Request Parameters

    ParameterRequiredTypeComments
    setMarginModetruestringISOLATED_MARGIN, REGULAR_MARGIN(i.e. Cross margin), PORTFOLIO_MARGIN

    Response Parameters

    ParameterTypeComments
    reasonsarrayObject. If requested successfully, it is an empty array
    > reasonCodestringFail reason code
    > reasonMsgstringFail reason msg

    Request Example

    POST /v5/account/set-margin-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672134396332
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "setMarginMode": "PORTFOLIO_MARGIN"
    }

    Response Example

    {
    "retCode": 3400045,
    "retMsg": "Set margin mode failed",
    "result": {
    "reasons": [
    {
    "reasonCode": "3400000",
    "reasonMsg": "Equity needs to be equal to or greater than 1000 USDC"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/v5/account/set-mmp.html b/v5/account/set-mmp.html index 3e246c0cab..cc96d4a927 100644 --- a/v5/account/set-mmp.html +++ b/v5/account/set-mmp.html @@ -4,7 +4,7 @@ Set MMP | Bybit API Documentation - + @@ -16,7 +16,7 @@ and new orders tagged as MMP will be rejected for a specific duration — known as the frozen period — so that MM can reassess the market and modify the quotes.

    How to enable MMP

    Send an email to Bybit (financial.inst@bybit.com) or contact your business development (BD) manager to apply for MMP. After processed, the default settings are as below table:

    ParameterTypeCommentsDefault value
    baseCoinstringBase coinBTC
    windowstringTime window (millisecond)5000
    frozenPeriodstringFrozen period (millisecond)100
    qtyLimitstringQuantity limit100
    deltaLimitstringDelta limit100

    Applicable

    Effective for options only. When you place an option order, set mmp=true, which means you mark this order as a mmp order.

    HTTP Request

    POST /v5/account/mmp-modify

    Request Parameters

    ParameterRequiredTypeComments
    baseCointruestringBase coin
    windowtruestringTime window (ms)
    frozenPeriodtruestringFrozen period (ms). "0" means the trade will remain frozen until manually reset
    qtyLimittruestringTrade qty limit (positive and up to 2 decimal places)
    deltaLimittruestringDelta limit (positive and up to 2 decimal places)

    Response Parameters

    None

    Request Example

    POST /v5/account/mmp-modify HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675833524616
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "baseCoin": "ETH",
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "50",
    "deltaLimit": "20"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/v5/account/transaction-log.html b/v5/account/transaction-log.html index ca09382523..64e04078c0 100644 --- a/v5/account/transaction-log.html +++ b/v5/account/transaction-log.html @@ -4,13 +4,13 @@ Get Transaction Log | Bybit API Documentation - +

    Get Transaction Log

    Query transaction logs in Unified account.

    HTTP Request

    GET /v5/account/transaction-log

    Request Parameters

    ParameterRequiredTypeComments
    accountTypefalsestringAccount Type. UNIFIED
    categoryfalsestringProduct type. spot,linear,option
    currencyfalsestringCurrency
    baseCoinfalsestringBaseCoin. e.g., BTC of BTCPERP
    typefalsestringTypes of transaction logs
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > idstringUnique id
    > symbolstringSymbol name
    > categorystringProduct type
    > sidestringSide. Buy,Sell,None
    > transactionTimestringTransaction timestamp (ms)
    > typestringType
    > qtystringQuantity. It is the quantity for each trade entry and it does not have direction
    > sizestringSize. The rest position size after the trade is executed, and it has direction, i.e., short with "-"
    > currencystringUSDC、USDT、BTC、ETH
    > tradePricestringTrade price
    > fundingstringFunding fee
    • Positive value means receiving funding fee
    • Negative value means deducting funding fee
    > feestringTrading fee
    • Positive fee value means expense
    • Negative fee value means rebates
    > cashFlowstringCash flow, e.g., (1) close the position, and unRPL converts to RPL, (2) 8-hour session settlement for USDC Perp and Futures, (3) transfer in or transfer out. This does not include trading fee, funding fee
    > changestringChange = cashFlow + funding - fee
    > cashBalancestringCash balance. This is the wallet balance after a cash change
    > feeRatestring
    • When type=TRADE, then it is trading fee rate
    • When type=SETTLEMENT, it means funding fee rate. For side=Buy, feeRate=market fee rate; For side=Sell, feeRate= - market fee rate
    > bonusChangestringThe change of bonus
    > tradeIdstringTrade ID
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/account/transaction-log?accountType=UNIFIED&category=linear&currency=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672132480085
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21963%3A1%2C14954%3A1",
    "list": [
    {
    "id": "592324_XRPUSDT_161440249321",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "-0.003676",
    "orderLinkId": "",
    "orderId": "1672128000-8-592324-1-2",
    "fee": "0.00000000",
    "change": "-0.003676",
    "cashFlow": "0",
    "transactionTime": "1672128000000",
    "type": "SETTLEMENT",
    "feeRate": "0.0001",
    "bonusChange": "",
    "size": "100",
    "qty": "100",
    "cashBalance": "5086.55825002",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3676",
    "tradeId": "534c0003-4bf7-486f-aa02-78cee36825e4"
    },
    {
    "id": "592324_XRPUSDT_161440249321",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "linear-order",
    "orderId": "592b7e41-78fd-42e2-9aa3-91e1835ef3e1",
    "fee": "0.01908720",
    "change": "-0.0190872",
    "cashFlow": "0",
    "transactionTime": "1672121182224",
    "type": "TRADE",
    "feeRate": "0.0006",
    "bonusChange": "-0.1430544",
    "size": "100",
    "qty": "88",
    "cashBalance": "5086.56192602",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3615",
    "tradeId": "5184f079-88ec-54c7-8774-5173cafd2b4e"
    },
    {
    "id": "592324_XRPUSDT_161407743011",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "linear-order",
    "orderId": "592b7e41-78fd-42e2-9aa3-91e1835ef3e1",
    "fee": "0.00260280",
    "change": "-0.0026028",
    "cashFlow": "0",
    "transactionTime": "1672121182224",
    "type": "TRADE",
    "feeRate": "0.0006",
    "bonusChange": "",
    "size": "12",
    "qty": "12",
    "cashBalance": "5086.58101322",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3615",
    "tradeId": "8569c10f-5061-5891-81c4-a54929847eb3"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672132481405
    }
    - + \ No newline at end of file diff --git a/v5/account/upgrade-unified-account.html b/v5/account/upgrade-unified-account.html index dde0adca50..9a2ade91b3 100644 --- a/v5/account/upgrade-unified-account.html +++ b/v5/account/upgrade-unified-account.html @@ -4,7 +4,7 @@ Upgrade to Unified Account | Bybit API Documentation - + @@ -17,7 +17,7 @@ result cannot be returned in real time. You can check API Get Account Info after 3-5 minutes, check whether the upgrade is successful according to the "unifiedMarginStatus" field in the return.

  • During the account upgrade process, the data of Rest API/Websocket stream may be inaccurate due to the fact that the account-related asset data is in the processing state. It is recommended to query and use it after the upgrade is completed.

  • HTTP Request

    POST /v5/account/upgrade-to-uta

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    unifiedUpdateStatusstringUpgrade status. FAIL,PROCESS,SUCCESS
    unifiedUpdateMsgObjectIf PROCESS,SUCCESS, it returns null
    > msgarrayError message array. Only FAIL will have this field

    Request Example

    POST /v5/account/upgrade-to-uta HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672125123533
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {}

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "unifiedUpdateStatus": "FAIL",
    "unifiedUpdateMsg": {
    "msg": [
    "Update account failed. You have outstanding liabilities in your Spot account.",
    "Update account failed. Please close the usdc perpetual positions in USDC Account.",
    "unable to upgrade, please cancel the usdt perpetual open orders in USDT account.",
    "unable to upgrade, please close the usdt perpetual positions in USDT account."
    ]
    }
    },
    "retExtInfo": {},
    "time": 1672125124195
    }
    - + \ No newline at end of file diff --git a/v5/account/wallet-balance.html b/v5/account/wallet-balance.html index fa89683b57..e0f32731c5 100644 --- a/v5/account/wallet-balance.html +++ b/v5/account/wallet-balance.html @@ -4,14 +4,14 @@ Get Wallet Balance | Bybit API Documentation - +

    Get Wallet Balance

    Obtain wallet balance, query asset information of each currency, and account risk rate information. By default, currency information with assets or liabilities of 0 is not returned.

    tip
    • The trading of UTA inverse contracts is conducted through the CONTRACT wallet.
    • To get Funding wallet balance, please go to this endpoint

    HTTP Request

    GET /v5/account/wallet-balance

    Request Parameters

    ParameterRequiredTypeComments
    accountTypetruestringAccount type
    • Unified account: UNIFIED (trade spot/linear/options), CONTRACT(trade inverse)
    • Classic account: CONTRACT, SPOT
    coinfalsestringCoin name
    • If not passed, it returns non-zero asset info
    • You can pass multiple coins to query, separated by comma. USDT,USDC

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > accountTypestringAccount type
    > accountLTVstringAccount LTV: account total borrowed size / (account total equity + account total borrowed size). In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > accountIMRatestringInitial Margin Rate: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > accountMMRatestringMaintenance Margin Rate: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalEquitystringTotal Equity is calculated by adding the fiat currency valuation of the equity of each coin in your account. In non-unified mode & unified (inverse), the field will be returned as an empty string.
    > totalWalletBalancestringWallet Balance of account converted to usd:∑ Asset Wallet Balance By USD value of each asset。In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalMarginBalancestringMargin Balance of account converted to usd:totalWalletBalance + totalPerpUPL. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalAvailableBalancestringAvailable Balance of account converted to usd:Regular mode:totalMarginBalance - totalInitialMargin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalPerpUPLstringUnrealised P&L of Perpetuals and USDC Futures of account converted to usd:∑ Each Perp and USDC Futures upl by base coin. In non-unified mode & unified (inverse), the field will be returned as an empty string.
    > totalInitialMarginstringInitial Margin of account converted to usd:∑ Asset Total Initial Margin Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalMaintenanceMarginstringMaintenance Margin of account converted to usd: ∑ Asset Total Maintenance Margin Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > coinarrayObject
    >> coinstringCoin name, such as BTC, ETH, USDT, USDC
    >> equitystringEquity of current coin
    >> usdValuestringUSD value of current coin. If this coin cannot be collateral, then it is 0
    >> walletBalancestringWallet balance of current coin
    >> freestringAvailable balance for Spot wallet. This is a unique field for Classic SPOT
    >> lockedstringLocked balance due to the Spot open order
    >> borrowAmountstringBorrow amount of current coin
    >> availableToBorrowstringDepreciated field, always return "" due to feature of main-sub UID sharing borrow quota. Please refer to availableToBorrow in the Get Collateral Info
    >> availableToWithdrawstringAvailable amount to withdraw of current coin
    >> accruedIntereststringAccrued interest
    >> totalOrderIMstringPre-occupied margin for order. For portfolio margin mode, it returns ""
    >> totalPositionIMstringSum of initial margin of all positions + Pre-occupied liquidation fee. For portfolio margin mode, it returns ""
    >> totalPositionMMstringSum of maintenance margin for all positions. For portfolio margin mode, it returns ""
    >> unrealisedPnlstringUnrealised P&L
    >> cumRealisedPnlstringCumulative Realised P&L
    >> bonusstringBonus. This is a unique field for UNIFIED account
    >> collateralSwitchbooleanWhether it can be used as a margin collateral currency (platform)
    • When marginCollateral=false, then collateralSwitch is meaningless
    • This is a unique field for UNIFIED account
    >> marginCollateralbooleanWhether the collateral is turned on by user (user)
    • When marginCollateral=true, then collateralSwitch is meaningful
    • This is a unique field for UNIFIED account

    Request Example

    GET /v5/account/wallet-balance?accountType=UNIFIED&coin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672125440406
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "totalEquity": "3.31216591",
    "accountIMRate": "0",
    "totalMarginBalance": "3.00326056",
    "totalInitialMargin": "0",
    "accountType": "UNIFIED",
    "totalAvailableBalance": "3.00326056",
    "accountMMRate": "0",
    "totalPerpUPL": "0",
    "totalWalletBalance": "3.00326056",
    "accountLTV": "0",
    "totalMaintenanceMargin": "0",
    "coin": [
    {
    "availableToBorrow": "3",
    "bonus": "0",
    "accruedInterest": "0",
    "availableToWithdraw": "0",
    "totalOrderIM": "0",
    "equity": "0",
    "totalPositionMM": "0",
    "usdValue": "0",
    "unrealisedPnl": "0",
    "collateralSwitch": true,
    "borrowAmount": "0.0",
    "totalPositionIM": "0",
    "walletBalance": "0",
    "cumRealisedPnl": "0",
    "locked": "0",
    "marginCollateral": true,
    "coin": "BTC"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1690872862481
    }
    - + \ No newline at end of file diff --git a/v5/announcement.html b/v5/announcement.html index 0f89ca7afa..517fd24989 100644 --- a/v5/announcement.html +++ b/v5/announcement.html @@ -4,13 +4,13 @@ Get Announcement | Bybit API Documentation - +

    Get Announcement

    HTTP Request

    GET /v5/announcements/index

    Request Parameters

    ParameterRequiredTypeComments
    localetruestringLanguage symbol
    typefalsestringAnnouncement type
    tagfalsestringAnnouncement tag
    pagefalseintegerPage number. Default: 1
    limitfalseintegerLimit for data size per page. Default: 20

    Response Parameters

    ParameterTypeComments
    totalintegerTotal records
    listarrayObject
    > titlestringAnnouncement title
    > descriptionstringAnnouncement description
    > typeObject
    >> titlestringThe title of announcement type
    >> keystringThe key of announcement type
    > tagsarray<string>The tag of announcement
    > urlstringAnnouncement url
    > dateTimestampnumberPublish timestamp (ms) of announcement
    > startDataTimestampnumberThe start timestamp (ms) of the event, only valid when list.type.key == "latest_activities"
    > endDataTimestampnumberThe end timestamp (ms) of the event, only valid when list.type.key == "latest_activities"

    Request Example

    GET /v5/announcements/index?locale=en-US&limit=1 HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "total": 735,
    "list": [
    {
    "title": "New Listing: Arbitrum (ARB) — Deposit, Trade and Stake ARB to Share a 400,000 USDT Prize Pool!",
    "description": "Bybit is excited to announce the listing of ARB on our trading platform!",
    "type": {
    "title": "New Listings",
    "key": "new_crypto"
    },
    "tags": [
    "Spot",
    "Spot Listings"
    ],
    "url": "https://announcements.bybit.com/en-US/article/new-listing-arbitrum-arb-deposit-trade-and-stake-arb-to-share-a-400-000-usdt-prize-pool--bltf662314c211a8616/",
    "dateTimestamp": 1679045608000,
    "startDateTimestamp": 1679045608000,
    "endDateTimestamp": 1679045608000
    }
    ]
    },
    "retExtInfo": {},
    "time": 1679415136117
    }
    - + \ No newline at end of file diff --git a/v5/asset/account-coin-balance.html b/v5/asset/account-coin-balance.html index b41946f368..d7767ea28f 100644 --- a/v5/asset/account-coin-balance.html +++ b/v5/asset/account-coin-balance.html @@ -4,7 +4,7 @@ Get Single Coin Balance | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Get Single Coin Balance

    Query the balance of a specific coin in a specific account type. Supports querying sub UID's balance. Also, you can check the transferable amount from master to sub account, sub to master account or sub to sub account, especially for user who has INS loan.

    info
    • Sub account cannot query master account balance
    • Sub account can only check its own balance
    • Master account can check its own and its sub UIDs balance

    HTTP Request

    GET /v5/asset/transfer/query-account-coin-balance

    Request Parameters

    ParameterRequiredTypeComments
    memberIdfalsestringUID. Required when querying sub UID balance with master api key
    toMemberIdfalsestringUID. Required when querying the transferable balance between different UIDs
    accountTypetruestringAccount type
    toAccountTypefalsestringTo account type. Required when querying the transferable balance between different account types
    cointruestringCoin
    withBonusfalseinteger0(default): not query bonus. 1: query bonus
    withTransferSafeAmountfalseintegerWhether query delay withdraw/transfer safe amount
    withLtvTransferSafeAmountfalseintegerFor OTC loan users in particular, you can check the transferable amount under risk level
    • 0(default):false, 1:true
    • toAccountType is mandatory

    Response Parameters

    ParameterTypeComments
    accountTypestringAccount type
    bizTypeintegerBiz type
    accountIdstringAccount ID
    memberIdstringUid
    balanceObject
    > coinstringCoin
    > walletBalancestringWallet balance
    > transferBalancestringTransferable balance
    > bonusstringbonus
    > transferSafeAmountstringSafe amount to transfer. Keep "" if not query
    > ltvTransferSafeAmountstringTransferable amount for ins loan account. Keep "" if not query

    Request Example

    GET /v5/asset/transfer/query-account-coin-balance?accountType=UNIFIED&coin=USDT&toAccountType=FUND&withLtvTransferSafeAmount=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxx
    X-BAPI-API-KEY: xxxxx
    X-BAPI-TIMESTAMP: 1690254520644
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "accountType": "UNIFIED",
    "bizType": 1,
    "accountId": "1631385",
    "memberId": "1631373",
    "balance": {
    "coin": "USDT",
    "walletBalance": "11999",
    "transferBalance": "11999",
    "bonus": "0",
    "transferSafeAmount": "",
    "ltvTransferSafeAmount": "7602.4861"
    }
    },
    "retExtInfo": {},
    "time": 1690254521256
    }
    - + \ No newline at end of file diff --git a/v5/asset/all-balance.html b/v5/asset/all-balance.html index bfabddc953..f01ae176b5 100644 --- a/v5/asset/all-balance.html +++ b/v5/asset/all-balance.html @@ -4,13 +4,13 @@ Get All Coins Balance | Bybit API Documentation - +

    Get All Coins Balance

    You could get all coin balance of all account types under the master account, and sub account.

    Important

    It is not allowed to get master account coin balance via sub account api key.

    HTTP Request

    GET /v5/asset/transfer/query-account-coins-balance

    Request Parameters

    ParameterRequiredTypeComments
    memberIdfalsestringUser Id. It is required when you use master api key to check sub account coin balance
    accountTypetruestringAccount type
    coinfalsestringCoin name
    • Query all coins if not passed
    • Can query multiple coins, separated by comma. USDT,USDC,ETH
    withBonusfalseinteger0(default): not query bonus. 1: query bonus

    Response Parameters

    ParameterTypeComments
    accountTypestringAccount type
    memberIdstringUserID
    balancearrayObject
    > coinstringCurrency type
    > walletBalancestringWallet balance
    > transferBalancestringTransferable balance
    > bonusstringThe bonus

    Request Example

    GET /v5/asset/transfer/query-account-coins-balance?accountType=FUND&coin=USDC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675866354698
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "memberId": "XXXX",
    "accountType": "FUND",
    "balance": [
    {
    "coin": "USDC",
    "transferBalance": "0",
    "walletBalance": "0",
    "bonus": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675866354913
    }
    - + \ No newline at end of file diff --git a/v5/asset/asset-info.html b/v5/asset/asset-info.html index 0e15d30a5a..caeb1f827c 100644 --- a/v5/asset/asset-info.html +++ b/v5/asset/asset-info.html @@ -4,13 +4,13 @@ Get Asset Info | Bybit API Documentation - +

    Get Asset Info

    Query asset information

    info

    For now, it can query SPOT only.

    HTTP Request

    GET /v5/asset/transfer/query-asset-info

    Request Parameters

    ParameterRequiredTypeComments
    accountTypetruestringAccount type. SPOT
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    spotObject
    > statusstringaccount status. ACCOUNT_STATUS_NORMAL: normal, ACCOUNT_STATUS_UNSPECIFIED: banned
    > assetsarrayObject
    >> coinstringCoin
    >> frozenstringFreeze amount
    >> freestringFree balance
    >> withdrawstringAmount in withdrawing

    Request Example

    GET /v5/asset/transfer/query-asset-info?accountType=SPOT&coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672136538042
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "spot": {
    "status": "ACCOUNT_STATUS_NORMAL",
    "assets": [
    {
    "coin": "ETH",
    "frozen": "0",
    "free": "11.53485",
    "withdraw": ""
    }
    ]
    }
    },
    "retExtInfo": {},
    "time": 1672136539127
    }
    - + \ No newline at end of file diff --git a/v5/asset/cancel-withdraw.html b/v5/asset/cancel-withdraw.html index 9d925e4e2b..5601963cc0 100644 --- a/v5/asset/cancel-withdraw.html +++ b/v5/asset/cancel-withdraw.html @@ -4,13 +4,13 @@ Cancel Withdrawal | Bybit API Documentation - +

    Cancel Withdrawal

    Cancel the withdrawal

    caution

    Can query by the master UID's api key only

    HTTP Request

    POST /v5/asset/withdraw/cancel

    Request Parameters

    ParameterRequiredTypeComments
    idtruestringWithdrawal ID

    Response Parameters

    ParameterTypeComments
    statusinteger0: fail. 1: success

    Request Example

    POST /v5/asset/withdraw/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672197227732
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "id": "10197"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1672197228408
    }
    - + \ No newline at end of file diff --git a/v5/asset/coin-info.html b/v5/asset/coin-info.html index 476ca6686e..a50ed8de98 100644 --- a/v5/asset/coin-info.html +++ b/v5/asset/coin-info.html @@ -4,13 +4,13 @@ Get Coin Info | Bybit API Documentation - +

    Get Coin Info

    Query coin information, including chain information, withdraw and deposit status.

    HTTP Request

    GET /v5/asset/coin/query-info

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > nameintegerCoin name
    > coinstringCoin
    > remainAmountstringRemaining amount
    > chainsarrayObject
    >> chainstringChain
    >> chainTypestringChain type
    >> confirmationstringThe number of confirmation for deposit
    >> withdrawFeestringwithdraw fee. If withdraw fee is empty, It means that this coin does not support withdrawal
    >> depositMinstringMin. deposit
    >> withdrawMinstringMin. withdraw
    >> minAccuracystringThe precision of withdraw or deposit
    >> chainDepositstringThe chain status of deposit. 0: suspend. 1: normal
    >> chainWithdrawstringThe chain status of withdraw. 0: suspend. 1: normal
    >> withdrawPercentageFeestringThe withdraw fee percentage. It is a real figure, e.g., 0.022 means 2.2%

    Request Example

    GET /v5/asset/coin/query-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194580887
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "rows": [
    {
    "name": "ETH",
    "coin": "ETH",
    "remainAmount": "1020000",
    "chains": [
    {
    "chainType": "ETH",
    "confirmation": "10000",
    "withdrawFee": "0.005",
    "depositMin": "0.01",
    "withdrawMin": "0.02",
    "chain": "ETH",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0.022"
    },
    {
    "chainType": "Arbitrum One",
    "confirmation": "10",
    "withdrawFee": "0.01",
    "depositMin": "0.001",
    "withdrawMin": "0.1",
    "chain": "ARBI",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677478088215
    }
    - + \ No newline at end of file diff --git a/v5/asset/create-inter-transfer.html b/v5/asset/create-inter-transfer.html index c740a11d35..fccd9d27a9 100644 --- a/v5/asset/create-inter-transfer.html +++ b/v5/asset/create-inter-transfer.html @@ -4,14 +4,14 @@ Create Internal Transfer | Bybit API Documentation - +

    Create Internal Transfer

    Create the internal transfer between different account types under the same UID.

    tip

    Each account type has its own acceptable coins, e.g, you cannot transfer USDC from SPOT to CONTRACT. Please refer to transferable coin list API to find out more.

    HTTP Request

    POST /v5/asset/transfer/inter-transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID. Please manually generate a UUID
    cointruestringCoin
    amounttruestringAmount
    fromAccountTypetruestringFrom account type
    toAccountTypetruestringTo account type

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID

    Request Example

    POST v5/asset/transfer/inter-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670986690556
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb16",
    "coin": "BTC",
    "amount": "0.05",
    "fromAccountType": "UNIFIED",
    "toAccountType": "CONTRACT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbab16"
    },
    "retExtInfo": {},
    "time": 1670986962783
    }
    - + \ No newline at end of file diff --git a/v5/asset/delay-amount.html b/v5/asset/delay-amount.html index 46575d8266..6f415ab3ba 100644 --- a/v5/asset/delay-amount.html +++ b/v5/asset/delay-amount.html @@ -4,13 +4,13 @@ Get Withdrawable Amount | Bybit API Documentation - +

    Get Withdrawable Amount

    info

    How can partial funds be subject to delayed withdrawal requests?

    • On-chain deposit: If the number of on-chain confirmations has not reached a risk-controlled level, a portion of the funds will be frozen for a period of time until they are unfrozen.
    • Buying crypto: If there is a risk, the funds will be frozen for a certain period of time and cannot be withdrawn.

    HTTP Request

    GET /v5/asset/withdraw/withdrawable-amount

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name

    Response Parameters

    ParameterTypeComments
    limitAmountUsdstringThe frozen amount due to risk, in USD
    withdrawableAmountarrayObject
    > SPOTObjectSpot wallet, it is not returned if spot wallet is removed
    >> coinstringCoin name
    >> withdrawableAmountstringAmount that can be withdrawn
    >> availableBalancestringAvailable balance
    > FUNDObjectFunding wallet
    >> coinstringCoin name
    >> withdrawableAmountstringAmount that can be withdrawn
    >> availableBalancestringAvailable balance

    Request Example

    GET /v5/asset/withdraw/withdrawable-amount?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677565621998
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "limitAmountUsd": "52853.5551",
    "withdrawableAmount": {
    "FUND": {
    "coin": "USDT",
    "withdrawableAmount": "11135.0596",
    "availableBalance": "11135.0596"
    },
    "SPOT": {
    "coin": "USDT",
    "withdrawableAmount": "0",
    "availableBalance": "0"
    }
    }
    },
    "retExtInfo": {},
    "time": 1677565632151
    }
    - + \ No newline at end of file diff --git a/v5/asset/delivery.html b/v5/asset/delivery.html index 776e4204b4..f811bef8bd 100644 --- a/v5/asset/delivery.html +++ b/v5/asset/delivery.html @@ -4,13 +4,13 @@ Get Delivery Record | Bybit API Documentation - +

    Get Delivery Record

    Query delivery records of USDC futures and Options, sorted by deliveryTime in descending order

    Unified account covers: USDC futures / Option

    HTTP Request

    GET /v5/asset/delivery-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. option, linear
    symbolfalsestringSymbol name
    expDatefalsestringExpiry date. 25MAR22. Default: return all
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > deliveryTimenumberDelivery time (ms)
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > positionstringExecuted size
    > deliveryPricestringDelivery price
    > strikestringExercise price
    > feestringTrading fee
    > deliveryRplstringRealized PnL of the delivery
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/delivery-record?expDate=29DEC22&category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672362112944
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "132791%3A0%2C132791%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "BTC-29DEC22-16000-P",
    "side": "Buy",
    "deliveryTime": 1672300800860,
    "strike": "16000",
    "fee": "0.00000000",
    "position": "0.01",
    "deliveryPrice": "16541.86369547",
    "deliveryRpl": "3.5"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672362116184
    }
    - + \ No newline at end of file diff --git a/v5/asset/deposit-coin-spec.html b/v5/asset/deposit-coin-spec.html index 52362ad1ee..710b409851 100644 --- a/v5/asset/deposit-coin-spec.html +++ b/v5/asset/deposit-coin-spec.html @@ -4,13 +4,13 @@ Get Allowed Deposit Coin Info | Bybit API Documentation - +

    Get Allowed Deposit Coin Info

    Query allowed deposit coin information. To find out paired chain of coin, please refer coin info api.

    tip

    This is an endpoint that does not need authentication

    HTTP Request

    GET /v5/asset/deposit/query-allowed-list

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin. coin and chain must be paired if passed
    chainfalsestringChain. coin and chain must be paired if passed
    limitfalseintegerLimit for data size per page. [1, 35]. Default: 10
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    configListarrayObject
    > coinstringCoin
    > chainstringChain
    > coinShowNamestringCoin name
    > chainTypestringChain type
    > blockConfirmNumberintegerDeposit confirmation number
    > minDepositAmountstringMinimum deposit amount
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/deposit/query-allowed-list?coin=ETH&chain=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672191495968
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "configList": [
    {
    "coin": "ETH",
    "chain": "ETH",
    "coinShowName": "ETH",
    "chainType": "ETH",
    "blockConfirmNumber": 10000,
    "minDepositAmount": "0.01"
    }
    ],
    "nextPageCursor": "eyJwYWdlIjoyLCJsaW1pdCI6MTB9"
    },
    "retExtInfo": {},
    "time": 1672191496219
    }
    - + \ No newline at end of file diff --git a/v5/asset/deposit-record.html b/v5/asset/deposit-record.html index 9a3dd29e16..260d364f07 100644 --- a/v5/asset/deposit-record.html +++ b/v5/asset/deposit-record.html @@ -4,13 +4,13 @@ Get Deposit Records (on-chain) | Bybit API Documentation - +

    Get Deposit Records (on-chain)

    Query deposit records.

    tip
    • endTime - startTime should be less than 30 days. Query last 30 days records by default.
    • Can use main or sub UID api key to query deposit records respectively.

    HTTP Request

    GET /v5/asset/deposit/query-record

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > coinstringCoin
    > chainstringChain
    > amountstringAmount
    > txIDstringTransaction ID
    > statusintegerDeposit status
    > toAddressstringDeposit target address
    > tagstringTag of deposit target address
    > depositFeestringDeposit fee
    > successAtstringLast updated time
    > confirmationsstringNumber of confirmation blocks
    > txIndexstringTransaction sequence number
    > blockHashstringHash number on the chain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit
    > depositTypeintegerThe deposit type. 0: normal deposit, 10: the deposit reaches daily deposit limit, 20: abnormal deposit
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/deposit/query-record?coin=USDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672191991544
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "skip-notification-scene-test-amount-202212270944-533285-USDT",
    "status": 3,
    "toAddress": "test-amount-address",
    "tag": "",
    "depositFee": "",
    "successAt": "1672134274000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTA0NjA0MywibWF4SUQiOjEwNDYwNDN9"
    },
    "retExtInfo": {},
    "time": 1672191992512
    }
    - + \ No newline at end of file diff --git a/v5/asset/exchange.html b/v5/asset/exchange.html index 7f77a4c09d..1d4b0716a3 100644 --- a/v5/asset/exchange.html +++ b/v5/asset/exchange.html @@ -4,13 +4,13 @@ Get Coin Exchange Records | Bybit API Documentation - +

    Get Coin Exchange Records

    Query the coin exchange records.

    info

    This endpoint currently is not available to get data after 12 Mar 2023. We will make it fully available later.

    caution

    You may have a long delay of this endpoint.

    HTTP Request

    GET /v5/asset/exchange/order-record

    Request Parameters

    ParameterRequiredTypeComments
    fromCoinfalsestringThe currency to convert from. e.g,BTC
    toCoinfalsestringThe currency to convert to. e.g,USDT
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 10
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    nextPageCursorstringRefer to the cursor request parameter
    orderBodyarrayObject
    > fromCoinstringThe currency to convert from
    > fromAmountstringThe amount to convert from
    > toCoinstringThe currency to convert to
    > toAmountstringThe amount to convert to
    > exchangeRatestringExchange rate
    > createdTimestringExchange created timestamp (sec)
    > exchangeTxIdstringExchange transaction ID

    Request Example

    GET /v5/asset/exchange/order-record?limit=10 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672990462492
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderBody": [
    {
    "fromCoin": "BTC",
    "fromAmount": "0.100000000000000000",
    "toCoin": "ETH",
    "toAmount": "1.385866230000000000",
    "exchangeRate": "13.858662380000000000",
    "createdTime": "1672197760",
    "exchangeTxId": "145102533285208544812654440448"
    }
    ],
    "nextPageCursor": "173341:1672197760"
    },
    "retExtInfo": {},
    "time": 1672990464021
    }
    - + \ No newline at end of file diff --git a/v5/asset/inter-transfer-list.html b/v5/asset/inter-transfer-list.html index fa632fef85..6ea3523add 100644 --- a/v5/asset/inter-transfer-list.html +++ b/v5/asset/inter-transfer-list.html @@ -4,13 +4,13 @@ Get Internal Transfer Records | Bybit API Documentation - +

    Get Internal Transfer Records

    Query the internal transfer records between different account types under the same UID.

    HTTP Request

    GET /v5/asset/transfer/query-inter-transfer-list

    Request Parameters

    ParameterRequiredTypeComments
    transferIdfalsestringUUID. Use the one you generated in createTransfer
    coinfalsestringCoin
    statusfalsestringTransfer status
    startTimefalseintegerThe start timestamp (ms) Note: the query logic is actually effective based on second level
    endTimefalseintegerThe end timestamp (ms) Note: the query logic is actually effective based on second level
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringTransfer ID
    > coinstringTransferred coin
    > amountstringTransferred amount
    > fromAccountTypestringFrom account type
    > toAccountTypestringTo account type
    > timestampstringTransfer created timestamp (ms)
    > statusstringTransfer status
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/transfer/inter-transfer-list-query?coin=USDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670988271299
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "selfTransfer_a1091cc7-9364-4b74-8de1-18f02c6f2d5c",
    "coin": "USDT",
    "amount": "5000",
    "fromAccountType": "SPOT",
    "toAccountType": "UNIFIED",
    "timestamp": "1667283263000",
    "status": "SUCCESS"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTM1ODQ2OCwibWF4SUQiOjEzNTg0Njh9"
    },
    "retExtInfo": {},
    "time": 1670988271677
    }
    - + \ No newline at end of file diff --git a/v5/asset/internal-deposit-record.html b/v5/asset/internal-deposit-record.html index 02143a97d7..8002cf34af 100644 --- a/v5/asset/internal-deposit-record.html +++ b/v5/asset/internal-deposit-record.html @@ -4,13 +4,13 @@ Get Internal Deposit Records (off-chain) | Bybit API Documentation - +

    Get Internal Deposit Records (off-chain)

    Query deposit records within the Bybit platform. These transactions are not on the blockchain.

    Rules
    • The maximum difference between the start time and the end time is 30 days.
    • Support to get deposit records by Master or Sub Member Api Key

    HTTP Request

    GET /v5/asset/deposit/query-internal-record

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalseintegerStart time (ms). Default value: 30 days before the current time
    endTimefalseintegerEnd time (ms). Default value: current time
    coinfalsestringCoin name: for example, BTC. Default value: all
    cursorfalsestringCursor, used for pagination
    limitfalseintegerNumber of items per page, [1, 50]. Default value: 50

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > idstringID
    > typeinteger1: Internal deposit
    > coinstringDeposit coin
    > amountstringDeposit amount
    > statusinteger
    • 1=Processing
    • 2=Success
    • 3=deposit failed
    > addressstringEmail address or phone number
    > createdTimestringDeposit created timestamp
    nextPageCursorstringcursor information: used for pagination. Default value: ""

    Request Example

    GET /v5/asset/deposit/query-internal-record?startTime=1667260800000&endTime=1667347200000 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682099024473
    X-BAPI-RECV-WINDOW: 50000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "id": "19097",
    "amount": "0.001",
    "type": 1,
    "coin": "BTC",
    "address": "gas***gmail.com",
    "status": 2,
    "createdTime": "1667319101"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTkwOTcsIm1heElEIjoxOTA5N30="
    },
    "retExtInfo": {},
    "time": 1682099394381
    }
    - + \ No newline at end of file diff --git a/v5/asset/master-deposit-addr.html b/v5/asset/master-deposit-addr.html index 5a51004a1e..8dfa1aa219 100644 --- a/v5/asset/master-deposit-addr.html +++ b/v5/asset/master-deposit-addr.html @@ -4,13 +4,13 @@ Get Master Deposit Address | Bybit API Documentation - +

    Get Master Deposit Address

    Query the deposit address information of MASTER account.

    HTTP Request

    GET /v5/asset/deposit/query-address

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin
    chainTypefalsestringChain, e.g.,ETH

    Response Parameters

    ParameterTypeComments
    coinstringCoin
    chainsarrayObject
    > chainTypestringChain type
    > addressDepositstringThe address for deposit
    > tagDepositstringTag of deposit
    > chainstringChain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit

    Request Example

    GET /v5/asset/deposit/query-address?coin=USDT&chainType=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672192792371
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": [
    {
    "chainType": "ERC20",
    "addressDeposit": "0xd9e1cd77afa0e50b452a62fbb68a3340602286c3",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "-1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672192792860
    }
    - + \ No newline at end of file diff --git a/v5/asset/set-deposit-acct.html b/v5/asset/set-deposit-acct.html index 2fd6cba239..1961e8c432 100644 --- a/v5/asset/set-deposit-acct.html +++ b/v5/asset/set-deposit-acct.html @@ -4,13 +4,13 @@ Set Deposit Account | Bybit API Documentation - +

    Set Deposit Account

    Set auto transfer account after deposit. The same function as the setting for Deposit on web GUI

    info
    • Your funds will be deposited into FUND wallet by default. You can set the wallet for auto-transfer after deposit by this API.
    • Only main UID can access.
    tip
    • Unified trading account has FUND, UNIFIED, CONTRACT(for inverse derivatives)
    • Unified margin account has FUND, UNIFIED, CONTRACT(for inverse derivatives), SPOT
    • Classic account has FUND, OPTION(USDC account), CONTRACT(for inverse derivatives and derivatives), SPOT

    HTTP Request

    POST /v5/asset/deposit/deposit-to-account

    Request Parameters

    ParameterRequiredTypeComments
    accountTypetruestringAccount type
    • UNIFIED
    • SPOT
    • OPTION
    • CONTRACT
    • FUND

    Response Parameters

    ParameterTypeComments
    statusintegerRequest result:
    • 1: SUCCESS
    • 0: FAIL

    Request Example

    POST /v5/asset/deposit/deposit-to-account HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676887913670
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "accountType": "CONTRACT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1676887914363
    }
    - + \ No newline at end of file diff --git a/v5/asset/settlement.html b/v5/asset/settlement.html index cc9621ea49..43aa5bd6c9 100644 --- a/v5/asset/settlement.html +++ b/v5/asset/settlement.html @@ -4,13 +4,13 @@ Get USDC Session Settlement | Bybit API Documentation - +

    Get USDC Session Settlement

    Query session settlement records of USDC perpetual and futures

    Unified account covers: USDC perpetual / USDC futures

    HTTP Request

    GET /v5/asset/settlement-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear
    symbolfalsestringSymbol name
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > sizestringPosition size
    > sessionAvgPricestringSettlement price
    > markPricestringMark price
    > realisedPnlstringRealised PnL
    > createdTimestringCreated time (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/settlement-record?category=linear HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672284883483
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "116952%3A1%2C116952%3A1",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "-71.28",
    "symbol": "BTCPERP",
    "side": "Buy",
    "markPrice": "16620",
    "size": "1.5",
    "createdTime": "1672214400000",
    "sessionAvgPrice": "16620"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672284884285
    }
    - + \ No newline at end of file diff --git a/v5/asset/sub-deposit-addr.html b/v5/asset/sub-deposit-addr.html index d0b84f037e..648389d50d 100644 --- a/v5/asset/sub-deposit-addr.html +++ b/v5/asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ Get Sub Deposit Address | Bybit API Documentation - +

    Get Sub Deposit Address

    Query the deposit address information of SUB account.

    caution

    Can use master UID's api key only

    HTTP Request

    GET /v5/asset/deposit/query-sub-member-address

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin
    chainTypetruestringChain, e.g.,ETH
    subMemberIdtruestringSub user ID

    Response Parameters

    ParameterTypeComments
    coinstringCoin
    chainsarrayObject
    > chainTypestringChain type
    > addressDepositstringThe address for deposit
    > tagDepositstringTag of deposit
    > chainstringChain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit

    Request Example

    GET /v5/asset/deposit/query-sub-member-address?coin=USDT&chainType=TRX&subMemberId=592334 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194349421
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": {
    "chainType": "TRC20",
    "addressDeposit": "TCB6NmwGXjn8eJYDuPxLvs4aM8Jn7gvJ1f",
    "tagDeposit": "",
    "chain": "TRX",
    "batchReleaseLimit": "-1"
    }
    },
    "retExtInfo": {},
    "time": 1672194350819
    }
    - + \ No newline at end of file diff --git a/v5/asset/sub-deposit-record.html b/v5/asset/sub-deposit-record.html index 57b10ad8ee..9ab0a7cf90 100644 --- a/v5/asset/sub-deposit-record.html +++ b/v5/asset/sub-deposit-record.html @@ -4,13 +4,13 @@ Get Sub Deposit Records (on-chain) | Bybit API Documentation - +

    Get Sub Deposit Records (on-chain)

    Query subaccount's deposit records by main UID's API key.

    tip

    endTime - startTime should be less than 30 days. Queries for the last 30 days worth of records by default.

    HTTP Request

    GET /v5/asset/deposit/query-sub-member-record

    Request Parameters

    ParameterRequiredTypeComments
    subMemberIdtruestringSub UID
    coinfalsestringCoin
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > coinstringCoin
    > chainstringChain
    > amountstringAmount
    > txIDstringTransaction ID
    > statusintegerDeposit status
    > toAddressstringDeposit target address
    > tagstringTag of deposit target address
    > depositFeestringDeposit fee
    > successAtstringLast updated time
    > confirmationsstringNumber of confirmation blocks
    > txIndexstringTransaction sequence number
    > blockHashstringHash number on the chain
    > batchReleaseLimitstringThe deposit limit for this coin in this chain. "-1" means no limit
    > depositTypeintegerThe deposit type. 0: normal deposit, 10: the deposit reaches daily deposit limit, 20: abnormal deposit
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/deposit/query-sub-member-record?coin=USDT&limit=1&subMemberId=592334 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672192441294
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672192441742
    }
    - + \ No newline at end of file diff --git a/v5/asset/sub-uid-list.html b/v5/asset/sub-uid-list.html index af67950e78..753116e40f 100644 --- a/v5/asset/sub-uid-list.html +++ b/v5/asset/sub-uid-list.html @@ -4,13 +4,13 @@ Get Sub UID | Bybit API Documentation - +

    Get Sub UID

    Query the sub UIDs under a main UID

    caution

    Can query by the master UID's api key only

    HTTP Request

    GET /v5/asset/transfer/query-sub-member-list

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    subMemberIdsarray<string>All sub UIDs under the main UID
    transferableSubMemberIdsarray<string>All sub UIDs that have universal transfer enabled

    Request Example

    GET /v5/asset/transfer/query-sub-member-list HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672147239931
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "subMemberIds": [
    "554117",
    "592324",
    "592334",
    "1055262",
    "1072055",
    "1119352"
    ],
    "transferableSubMemberIds": [
    "554117",
    "592324"
    ]
    },
    "retExtInfo": {},
    "time": 1672147241320
    }
    - + \ No newline at end of file diff --git a/v5/asset/transferable-coin.html b/v5/asset/transferable-coin.html index 896d01b5ab..7cec484588 100644 --- a/v5/asset/transferable-coin.html +++ b/v5/asset/transferable-coin.html @@ -4,13 +4,13 @@ Get Transferable Coin | Bybit API Documentation - +

    Get Transferable Coin

    Query the transferable coin list between each account type

    HTTP Request

    GET /v5/asset/transfer/query-transfer-coin-list

    Request Parameters

    ParameterRequiredTypeComments
    fromAccountTypetruestringFrom account type
    toAccountTypetruestringTo account type

    Response Parameters

    ParameterTypeComments
    listarrayA list of coins (as strings)

    Request Example

    GET /v5/asset/transfer/query-transfer-coin-list?fromAccountType=UNIFIED&toAccountType=CONTRACT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672144322595
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    "BTC",
    "ETH"
    ]
    },
    "retExtInfo": {},
    "time": 1672144322954
    }
    - + \ No newline at end of file diff --git a/v5/asset/unitransfer-list.html b/v5/asset/unitransfer-list.html index 19f610860b..3071539175 100644 --- a/v5/asset/unitransfer-list.html +++ b/v5/asset/unitransfer-list.html @@ -4,13 +4,13 @@ Get Universal Transfer Records | Bybit API Documentation - +

    Get Universal Transfer Records

    Query universal transfer records

    tip
    • Main acct api key or Sub acct api key are both supported
    • Main acct api key needs "SubMemberTransfer" permission
    • Sub acct api key needs "SubMemberTransferList" permission

    HTTP Request

    GET /v5/asset/transfer/query-universal-transfer-list

    Request Parameters

    ParameterRequiredTypeComments
    transferIdfalsestringUUID. Use the one you generated in createTransfer
    coinfalsestringCoin
    statusfalsestringTransfer status. SUCCESS,FAILED,PENDING
    startTimefalseintegerThe start timestamp (ms) Note: the query logic is actually effective based on second level
    endTimefalseintegerThe end timestamp (ms) Note: the query logic is actually effective based on second level
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > transferIdstringTransfer ID
    > coinstringTransferred coin
    > amountstringTransferred amount
    > fromMemberIdstringFrom UID
    > toMemberIdstringTO UID
    > fromAccountTypestringFrom account type
    > toAccountTypestringTo account type
    > timestampstringTransfer created timestamp (ms)
    > statusstringTransfer status
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/asset/transfer/query-universal-transfer-list?limit=1&cursor=eyJtaW5JRCI6MTc5NjU3OCwibWF4SUQiOjE3OTY1Nzh9 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672190762800
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "universalTransfer_4c3cfe2f-85cb-11ed-ac09-9e37823c81cd_533285",
    "coin": "USDC",
    "amount": "1000",
    "timestamp": "1672134373000",
    "status": "SUCCESS",
    "fromAccountType": "UNIFIED",
    "toAccountType": "UNIFIED",
    "fromMemberId": "533285",
    "toMemberId": "592324"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTc4OTYwNSwibWF4SUQiOjE3ODk2MDV9"
    },
    "retExtInfo": {},
    "time": 1672190763079
    }
    - + \ No newline at end of file diff --git a/v5/asset/unitransfer.html b/v5/asset/unitransfer.html index 31e2a90a51..f0b8c648c8 100644 --- a/v5/asset/unitransfer.html +++ b/v5/asset/unitransfer.html @@ -4,13 +4,13 @@ Create Universal Transfer | Bybit API Documentation - +

    Create Universal Transfer

    Transfer between sub-sub or main-sub.

    caution
    • Can use master or sub acct api key to request
      • To use sub acct api key, it must have "SubMemberTransferList" permission
      • When use sub acct api key, it can only transfer to main account
    • If you encounter errorCode: 131228 and msg: your balance is not enough, please go to Get Single Coin Balance to check transfer safe amount.
    • You can not transfer between the same UID

    HTTP Request

    POST /v5/asset/transfer/universal-transfer

    Request Parameters

    ParameterRequiredTypeComments
    transferIdtruestringUUID. Please manually generate a UUID
    cointruestringCoin
    amounttruestringAmount
    fromMemberIdtrueintegerFrom UID
    toMemberIdtrueintegerTo UID
    fromAccountTypetruestringFrom account type
    toAccountTypetruestringTo account type

    Response Parameters

    ParameterTypeComments
    transferIdstringUUID

    Request Example

    POST /v5/asset/transfer/universal-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672189449697
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "transferId": "be7a2462-1138-4e27-80b1-62653f24925e",
    "coin": "ETH",
    "amount": "0.5",
    "fromMemberId": 592334,
    "toMemberId": 691355,
    "fromAccountType": "CONTRACT",
    "toAccountType": "UNIFIED"

    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "be7a2462-1138-4e27-80b1-62653f24925e"
    },
    "retExtInfo": {},
    "time": 1672189450195
    }
    - + \ No newline at end of file diff --git a/v5/asset/withdraw-record.html b/v5/asset/withdraw-record.html index 05bec7d11e..4166a169df 100644 --- a/v5/asset/withdraw-record.html +++ b/v5/asset/withdraw-record.html @@ -4,13 +4,13 @@ Get Withdrawal Records | Bybit API Documentation - +

    Get Withdrawal Records

    Query withdrawal records.

    tip
    • endTime - startTime should be less than 30 days. Query last 30 days records by default.
    • Can query by the master UID's api key only

    HTTP Request

    GET /v5/asset/withdraw/query-record

    Request Parameters

    ParameterRequiredTypeComments
    withdrawIDfalsestringWithdraw ID
    coinfalsestringCoin
    withdrawTypefalseintegerWithdraw type. 0(default): on chain. 1: off chain. 2: all.
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    rowsarrayObject
    > withdrawIdstringWithdraw ID
    > txIDstringTransaction ID. It returns "" when withdrawal failed, withdrawal cancelled or internal transfer
    > withdrawTypestringWithdraw type. 0: on chain. 1: off chain
    > coinstringCoin
    > chainstringChain
    > amountstringAmount
    > withdrawFeestringWithdraw fee
    > statusstringWithdraw status
    > toAddressstringTo withdrawal address. Shows the Bybit UID for internal transfers
    > tagstringTag
    > createTimestringWithdraw created timestamp (ms)
    > updateTimestringWithdraw updated timestamp (ms)
    nextPageCursorstringCursor. Used for pagination

    Request Example

    GET /v5/asset/withdraw/query-record?coin=USDT&withdrawType=2&limit=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194949557
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "77",
    "txID": "",
    "status": "SecurityCheck",
    "toAddress": "0x99ced129603abc771c0dabe935c326ff6c86645d",
    "tag": "",
    "withdrawFee": "10",
    "createTime": "1670922217000",
    "updateTime": "1670922217000",
    "withdrawId": "9976",
    "withdrawType": 0
    },
    {
    "coin": "USDT",
    "chain": "internalAddressChain",
    "amount": "20.1234",
    "txID": "",
    "status": "success",
    "toAddress": "999805",
    "tag": "",
    "withdrawFee": "0",
    "createTime": "1698889833000",
    "updateTime": "1698889846000",
    "withdrawId": "13310",
    "withdrawType": 1
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6OTgwMSwibWF4SUQiOjk5NzZ9"
    },
    "retExtInfo": {},
    "time": 1672194949928
    }
    - + \ No newline at end of file diff --git a/v5/asset/withdraw.html b/v5/asset/withdraw.html index d08e8ec480..82966145ca 100644 --- a/v5/asset/withdraw.html +++ b/v5/asset/withdraw.html @@ -4,13 +4,13 @@ Withdraw | Bybit API Documentation - +

    Withdraw

    Withdraw assets from your Bybit account. You can make an off-chain transfer if the target wallet address is from Bybit. This means that no blockchain fee will be charged.

    danger
    • UTA does not have SPOT account
    • How do I know if my account is a UTA account? Call this endpoint, and if uta=1, then it is a UTA account.
    caution
    • Make sure you have whitelisted your wallet address here
    • Can query by the master UID's api key only
    formula

    feeType=0:

    • withdrawPercentageFee != 0: handlingFee = inputAmount / (1 - withdrawPercentageFee) * withdrawPercentageFee + withdrawFee
    • withdrawPercentageFee = 0: handlingFee = withdrawFee

    feeType=1:

    • withdrawPercentageFee != 0: handlingFee = withdrawFee + (inputAmount - withdrawFee) * withdrawPercentageFee
    • withdrawPercentageFee = 0: handlingFee = withdrawFee

    HTTP Request

    POST /v5/asset/withdraw/create

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin
    chainfalsestringChain
    • forceChain=0 or 1: this field is required
    • forceChain=2: this field can be null
    addresstruestring
    • forceChain=0 or 1: fill wallet address, and make sure you add address in the address book first. Please note that the address is case sensitive, so use the exact same address added in address book
    • forceChain=2: fill Bybit UID, and it can only be another Bybit main account UID. Make sure you add UID in the address book first
    tagfalsestringTag
    • Required if tag exists in the wallet address list.
    • Note: please do not set a tag/memo in the address book if the chain does not support tag
    amounttruestringWithdraw amount
    timestamptrueintegerCurrent timestamp (ms). Used for preventing from withdraw replay
    forceChainfalseintegerWhether or not to force an on-chain withdrawal
    • 0(default): If the address is parsed out to be an internal address, then internal transfer
    • 1: Force the withdrawal to occur on-chain
    • 2: Use UID to withdraw
    accountTypefalsestringSelect the wallet to be withdrawn from
    • SPOT:spot wallet (default)
    • FUND:Funding wallet
    feeTypefalseintegerHandling fee option
    • 0(default): input amount is the actual amount received, so you have to calculate handling fee manually
    • 1: input amount is not the actual amount you received, the system will help to deduct the handling fee automatically

    Response Parameters

    ParameterTypeComments
    idstringWithdrawal ID

    Request Example

    POST /v5/asset/withdraw/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672196570254
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "coin": "USDT",
    "chain": "ETH",
    "address": "0x99ced129603abc771c0dabe935c326ff6c86645d",
    "tag": null,
    "amount": "24",
    "timestamp": 1672196561407,
    "forceChain": 0,
    "accountType": "FUND"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "10195"
    },
    "retExtInfo": {},
    "time": 1672196571239
    }
    - + \ No newline at end of file diff --git a/v5/backup/set-pledge-token.html b/v5/backup/set-pledge-token.html index c521e78f57..6eea31e233 100644 --- a/v5/backup/set-pledge-token.html +++ b/v5/backup/set-pledge-token.html @@ -4,13 +4,13 @@ Set Pledge Token | Bybit API Documentation - +

    Set Pledge Token

    Set Pledge Token in cross margin

    HTTP Request

    POST /v5/spot-margin-trade/set-pledge-token

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringcoin
    pledgeStatustureintpledge status. 1: on, 0: off

    Response Parameters

    ParameterTypeComments
    pledgeStatusstringpledge status:1: on,0: off
    - + \ No newline at end of file diff --git a/v5/broker/earning.html b/v5/broker/earning.html index 463ba5c595..a39da8cdbf 100644 --- a/v5/broker/earning.html +++ b/v5/broker/earning.html @@ -4,13 +4,13 @@ Get Broker Earning | Bybit API Documentation - +

    Get Broker Earning

    info
    • Use exchange broker master account to query
    • The data can support up to past 6 months until T-1
    • startTime & endTime are either entered at the same time or not entered

    HTTP Request

    GET /v5/broker/earning-record

    Request Parameters

    ParameterRequiredTypeComments
    bizTypefalsestringBusiness type. SPOT, DERIVATIVES, OPTIONS
    startTimefalseintegerThe start timestamp(ms)
    endTimefalseintegerThe end timestamp(ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 1000
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > userIdstringUID
    > bizTypestringBusiness type
    > symbolstringSymbol name
    > coinstringCoin name. The currency of earning
    > earningstringCommission
    > orderIdstringOrder ID
    > execTimestringExecution timestamp (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/broker/earning-record?bizType=SPOT&startTime=1686240000000&endTime=1686326400000&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686708862669
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "userId": "xxxx",
    "bizType": "SPOT",
    "symbol": "BTCUSDT",
    "coin": "BTC",
    "earning": "0.000015",
    "orderId": "1531607271849858304",
    "execTime": "1686306035957"
    }
    ],
    "nextPageCursor": "0%2C1"
    },
    "retExtInfo": {},
    "time": 1686708863283
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/account-info.html b/v5/c2c-lend/account-info.html index dffaa7ee93..b49685219e 100644 --- a/v5/c2c-lend/account-info.html +++ b/v5/c2c-lend/account-info.html @@ -4,13 +4,13 @@ Get Lending Account Info | Bybit API Documentation - +

    Get Lending Account Info

    HTTP Request

    GET /v5/lending/account

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    principalIntereststringUser Redeemable interest
    principalQtystringLeftover quantity you can redeem for today (measured from 0 - 24 UTC), formula: min(the rest amount of principle, the amount that the user can redeem on the day)
    principalTotalstringTotal amount redeemable by user
    quantitystringCurrent deposit quantity

    Request Example

    GET /v5/lending/account?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682049556563
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "BTC",
    "principalInterest": "0",
    "principalQty": "1",
    "principalTotal": "1",
    "quantity": "1"
    },
    "retExtInfo": {},
    "time": 1682049706988
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/cancel-redeem.html b/v5/c2c-lend/cancel-redeem.html index d7b25f52d3..3ad1cd3d45 100644 --- a/v5/c2c-lend/cancel-redeem.html +++ b/v5/c2c-lend/cancel-redeem.html @@ -4,13 +4,13 @@ Cancel Redeem | Bybit API Documentation - +

    Cancel Redeem

    Cancel the withdrawal operation.

    HTTP Request

    POST /v5/lending/redeem-cancel

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name
    orderIdfalsestringThe order ID of redemption
    serialNofalsestringSerial no. The customised ID of redemption

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    serialNostringSerial No
    updatedTimestringUpdated timestamp (ms)

    Request Example

    POST /v5/lending/redeem-cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682048277724
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "BTC",
    "orderId": "1403517113428086272",
    "serialNo": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1403517113428086272",
    "serialNo": "linear004",
    "updatedTime": "1682048277963"
    },
    "retExtInfo": {},
    "time": 1682048278001
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/coin-info.html b/v5/c2c-lend/coin-info.html index 73c043863b..3e349392d2 100644 --- a/v5/c2c-lend/coin-info.html +++ b/v5/c2c-lend/coin-info.html @@ -4,13 +4,13 @@ Get Lending Coin Info | Bybit API Documentation - +

    Get Lending Coin Info

    Get the basic information of lending coins

    info

    All v5/lending APIs need SPOT permission.

    HTTP Request

    GET /v5/lending/info

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name. Return all currencies by default

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > maxRedeemQtystringThe maximum redeemable qty per day (measured from 0 - 24 UTC)
    > minPurchaseQtystringThe minimum qty that can be deposited per request
    > precisionstringDeposit quantity accuracy
    > ratestringAnnualized interest rate. e.g. 0.0002 means 0.02%
    > loanToPoolRatiostringCapital utilization rate. e.g. 0.0004 means 0.04%
    > actualApystringThe actual annualized interest rate

    Request Example

    GET /v5/lending/info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682045949295
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "actualApy": "0.003688421873941958",
    "coin": "ETH",
    "loanToPoolRatio": "0.16855491872747133044",
    "maxRedeemQty": "161",
    "minPurchaseQty": "0.03",
    "precision": "8",
    "rate": "0.003411300771389848"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1682045942972
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/deposit.html b/v5/c2c-lend/deposit.html index b574ef4fb4..f9a6c8013d 100644 --- a/v5/c2c-lend/deposit.html +++ b/v5/c2c-lend/deposit.html @@ -4,13 +4,13 @@ Deposit Funds | Bybit API Documentation - +

    Deposit Funds

    Lending funds to Bybit asset pool

    info
    • normal & UMA account: deduct funds from Spot wallet
    • UTA account: deduct funds from Unified wallet

    HTTP Request

    POST /v5/lending/purchase

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    quantitytruestringDeposit quantity
    serialNofalsestringCustomised ID. If not passed, system will create one by default

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    createdTimestringCreated timestamp (ms)
    orderIdstringOrder ID
    quantitystringDeposit quantity
    serialNostringSerial No
    statusstringOrder status. 0: Initial, 1: Processing, 2: Success, 10: Failed
    updatedTimestringUpdated timestamp (ms)

    Request Example

    POST /v5/lending/purchase HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682046368938
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "USDC",
    "quantity": "20.00005",
    "serialNo": "test-00007"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "USDC",
    "createdTime": "1682046369112",
    "orderId": "1403501100816928256",
    "quantity": "20.00005",
    "serialNo": "test-00007",
    "status": "0",
    "updatedTime": "1682046369112"
    },
    "retExtInfo": {},
    "time": 1682046369120
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/order-record.html b/v5/c2c-lend/order-record.html index ebf6db6b2b..b37244332e 100644 --- a/v5/c2c-lend/order-record.html +++ b/v5/c2c-lend/order-record.html @@ -4,13 +4,13 @@ Get Order Records | Bybit API Documentation - +

    Get Order Records

    Get lending or redeem history

    HTTP Request

    GET /v5/lending/history-order

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name
    orderIdfalsestringOrder ID
    startTimefalselongThe start timestamp (ms)
    endTimefalselongThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 50
    orderTypefalsestringOrder type. 1: deposit, 2: redemption, 3: Payment of proceeds

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > createdTimestringCreated timestamp (ms)
    > orderIdstringOrder ID
    > quantitystringquantity
    > serialNostringSerial No
    > statusstringOrder status. 0: Initial, 1: Processing, 2: Success, 10: Failed, 11: Cancelled
    > updatedTimestringUpdated timestamp (ms)

    Request Example

    GET /v5/lending/history-order?orderNo=1403517113428086272 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: 9pXyrhxTlXXXXXaVQGSaP3n
    X-BAPI-TIMESTAMP: 1682049395799
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "BTC",
    "createdTime": "1682048277963",
    "orderId": "1403517113428086272",
    "orderType": "2",
    "quantity": "0.1",
    "serialNo": "14035171132183710722373",
    "status": "2",
    "updatedTime": "1682048278245"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1682049395967
    }
    - + \ No newline at end of file diff --git a/v5/c2c-lend/redeem.html b/v5/c2c-lend/redeem.html index 2d9f014ce4..0466ca1c71 100644 --- a/v5/c2c-lend/redeem.html +++ b/v5/c2c-lend/redeem.html @@ -4,13 +4,13 @@ Redeem Funds | Bybit API Documentation - +

    Redeem Funds

    Withdraw funds from the Bybit asset pool.

    tip

    There will be two redemption records: one for the redeemed quantity, and the other one is for the total interest occurred.

    HTTP Request

    POST /v5/lending/redeem

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    quantityturestringRedemption quantity
    serialNofalsestringSerial no. A customised ID, and it will automatically generated if not passed

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    createdTimestringCreated timestamp (ms)
    orderIdstringOrder ID
    principalQtystringRedemption quantity
    serialNostringSerial No
    statusstringOrder status. 0: Initial, 1: Processing, 2: Success, 10: Failed
    updatedTimestringUpdated timestamp (ms)

    Request Example

    POST /v5/lending/redeem HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682048277724
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "BTC",
    "quantity": "0.1",
    "serialNo": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "BTC",
    "createdTime": "1682048277963",
    "orderId": "1403517113428086272",
    "principalQty": "0.1",
    "serialNo": "14035171132183710722373",
    "status": "0",
    "updatedTime": "1682048277963"
    },
    "retExtInfo": {},
    "time": 1682048278001
    }
    - + \ No newline at end of file diff --git a/v5/copytrade.html b/v5/copytrade.html index 6cdd56eefb..ef38d9d590 100644 --- a/v5/copytrade.html +++ b/v5/copytrade.html @@ -4,14 +4,14 @@ How To Start Copy Trading | Bybit API Documentation - +

    How To Start Copy Trading

    Become A Master Trader

    Please go here to apply to become a Master Trader

    Create The API KEY

    "Contract - Orders & Positions" are mandatory permissions for Copy Trading orders

    Understand The Scope

    From time being, classic account and unified account both support Copy Trading, but can only trade USDT Perpetual symbols. Please check the field copytrading from Get Instruments Info

    Place The Copy Trading Order

    Use V5 Place Order endpoint to place a Copy Trading order

    POST /v5/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698376189371
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 207

    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "category": "linear",
    "qty": "0.1",
    "price": "29000",
    "timeInForce": "GTC",
    "positionIdx": 1
    }
    - + \ No newline at end of file diff --git a/v5/enum.html b/v5/enum.html index af5ed22a54..d756def444 100644 --- a/v5/enum.html +++ b/v5/enum.html @@ -4,13 +4,13 @@ Enums Definitions | Bybit API Documentation - +

    Enums Definitions

    locale

    • de-DE
    • en-US
    • es-AR
    • es-ES
    • es-MX
    • fr-FR
    • kk-KZ
    • id-ID
    • uk-UA
    • ja-JP
    • ru-RU
    • th-TH
    • pt-BR
    • tr-TR
    • vi-VN
    • zh-TW
    • ar-SA
    • hi-IN
    • fil-PH

    announcementType

    • new_crypto
    • latest_bybit_news
    • delistings
    • latest_activities
    • product_updates
    • maintenance_updates
    • new_fiat_listings
    • other

    announcementTag

    • Spot
    • Derivatives
    • Spot Listings
    • BTC
    • ETH
    • Trading Bots
    • USDC
    • Leveraged Tokens
    • USDT
    • Margin Trading
    • Partnerships
    • Launchpad
    • Upgrades
    • ByVotes
    • Delistings
    • VIP
    • Futures
    • Institutions
    • Options
    • WEB3
    • Copy Trading
    • Earn
    • Bybit Savings
    • Dual Asset
    • Liquidity Mining
    • Shark Fin
    • Launchpool
    • NFT GrabPic
    • Buy Crypto
    • P2P Trading
    • Fiat Deposit
    • Crypto Deposit
    • Спот
    • Спот лістинги
    • Торгові боти
    • Токени з кредитним плечем
    • Маржинальна торгівля
    • Партнерство
    • Оновлення
    • Делістинги
    • Ф'ючерси
    • Опціони
    • Копітрейдинг
    • Bybit Накопичення
    • Бівалютні інвестиції
    • Майнінг ліквідності
    • Купівля криптовалюти
    • P2P торгівля
    • Фіатні депозити
    • Криптодепозити
    • Копитрейдинг
    • Торговые боты
    • Деривативы
    • P2P
    • Спот листинги
    • Деривативи
    • MT4
    • Lucky Draw
    • Unified Trading Account
    • Єдиний торговий акаунт
    • Единый торговый аккаунт
    • Институциональный трейдинг
    • Інституціональний трейдинг
    • Делистинг

    category

    Unified Account

    • spot
    • linearUSDT perpetual, and USDC contract, including USDC perp, USDC futures
    • inverseInverse contract, including Inverse perp, Inverse futures
    • option

    Classic Account

    • linearUSDT perp
    • inverseInverse contract, including Inverse perp, Inverse futures
    • spot

    orderStatus

    • Createdorder has been accepted by the system but not yet put through the matching engine
    • Neworder has been placed successfully
    • Rejected
    • PartiallyFilled
    • PartiallyFilledCanceledOnly spot has this order status
    • Filled
    • CancelledIn derivatives, orders with this status may have an executed qty
    • Untriggered
    • Triggered
    • DeactivatedUTA: Spot tp/sl order, conditional order, OCO order are cancelled before they are triggered
    • Activeorder has been triggered and the new active order has been successfully placed. Is the final state of a successful conditional order

    timeInForce

    • GTCGoodTillCancel
    • IOCImmediateOrCancel
    • FOKFillOrKill
    • PostOnly

    execType

    • Trade
    • AdlTradeAuto-Deleveraging
    • FundingFunding fee
    • BustTradeLiquidation
    • DeliveryUSDC futures delivery
    • BlockTrade
    • UNKNOWNMay be returned by a classic account. Cannot query by this type

    orderType

    • Market
    • Limit
    • UNKNOWNis not a valid request parameter value. Is only used in some responses. Mainly, it is used when execType is Funding.

    stopOrderType

    • TakeProfit
    • StopLoss
    • TrailingStop
    • Stop
    • PartialTakeProfit
    • PartialStopLoss
    • tpslOrderspot TP/SL order
    • OcoOrderspot OCO order
    • MmRateCloseOn web or app can set MMR to close position

    tickDirection

    • PlusTickprice rise
    • ZeroPlusTicktrade occurs at the same price as the previous trade, which occurred at a price higher than that for the trade preceding it
    • MinusTickprice drop
    • ZeroMinusTicktrade occurs at the same price as the previous trade, which occurred at a price lower than that for the trade preceding it

    interval

    • 1 3 5 15 30 60 120 240 360 720minute
    • Dday
    • Wweek
    • Mmonth

    intervalTime

    • 5min 15min 30minminute
    • 1h 4hhour
    • 1dday

    positionIdx

    • 0one-way mode position
    • 1Buy side of hedge-mode position
    • 2Sell side of hedge-mode position

    positionStatus

    • Normal
    • Liqin the liquidation progress
    • Adlin the auto-deleverage progress

    rejectReason

    • EC_NoError
    • EC_Others
    • EC_UnknownMessageType
    • EC_MissingClOrdID
    • EC_MissingOrigClOrdID
    • EC_ClOrdIDOrigClOrdIDAreTheSame
    • EC_DuplicatedClOrdID
    • EC_OrigClOrdIDDoesNotExist
    • EC_TooLateToCancel
    • EC_UnknownOrderType
    • EC_UnknownSide
    • EC_UnknownTimeInForce
    • EC_WronglyRouted
    • EC_MarketOrderPriceIsNotZero
    • EC_LimitOrderInvalidPrice
    • EC_NoEnoughQtyToFill
    • EC_NoImmediateQtyToFill
    • EC_PerCancelRequest
    • EC_MarketOrderCannotBePostOnly
    • EC_PostOnlyWillTakeLiquidity
    • EC_CancelReplaceOrder
    • EC_InvalidSymbolStatus

    accountType

    Check the value of unifiedMarginStatus to see if you're on the Unified Trading Account or the classic account.

    Unified Trading Account (UTA)

    • CONTRACTInverse Derivatives Account
    • UNIFIEDUnified Trading Account
    • FUNDFunding Account

    Classic account

    Also known as the "standard account".

    • SPOTSpot Account
    • CONTRACTDerivatives Account
    • OPTIONUSDC Derivatives
    • FUNDFunding Account
    • INVESTMENTByFi Account (this service is now offline)

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    depositStatus

    • 0unknown
    • 1toBeConfirmed
    • 2processing
    • 3success (finalised status of a success deposit)
    • 4deposit failed
    • 10011pending to be credited to funding pool
    • 10012Credited to funding pool successfully

    withdrawStatus

    • SecurityCheck
    • Pending
    • success
    • CancelByUser
    • Reject
    • Fail
    • BlockchainConfirmed
    • Unknowna rare status

    triggerBy

    • LastPrice
    • IndexPrice
    • MarkPrice

    cancelType

    • CancelByUser
    • CancelByReduceOnly
    • CancelByPrepareLiq CancelAllBeforeLiqCancelled due to liquidation
    • CancelByPrepareAdl CancelAllBeforeAdlCancelled due to ADL
    • CancelByAdmin
    • CancelByTpSlTsClear
    • CancelByPzSideCh
    • CancelBySmp

    Options:

    • CancelByUser
    • CancelByReduceOnly
    • CancelAllBeforeLiqCancelled due to liquidation
    • CancelAllBeforeAdlCancelled due to ADL
    • CancelBySettle
    • CancelByCannotAffordOrderCost
    • CancelByPmTrialMmOverEquity
    • CancelByAccountBlocking
    • CancelByDelivery
    • CancelByMmpTriggered
    • CancelByCrossSelfMuch
    • CancelByCrossReachMaxTradeNum
    • CancelByDCP
    • CancelBySmp

    optionPeriod

    • BTC: 7,14,21,30,60,90,180,270days
    • ETH: 7,14,21,30,60,90,180,270days
    • SOL: 7,14,21,30,60,90days

    dataRecordingPeriod

    • 5min 15min 30minminute
    • 1h 4hhour
    • 4dday

    contractType

    • InversePerpetual
    • LinearPerpetual
    • LinearFuturesUSDC Futures
    • InverseFutures

    status

    • PreLaunch
    • Trading
    • SettlingThe unique status for USDC Perpetual 8-hour settlement
    • Delivering
    • Closed

    marginTrading

    • noneRegardless of normal account or UTA account, this trading pair does not support margin trading
    • bothFor both normal account and UTA account, this trading pair supports margin trading
    • utaOnlyOnly for UTA account,this trading pair supports margin trading
    • normalSpotOnlyOnly for normal account, this trading pair supports margin trading

    copyTrading

    • noneRegardless of normal account or UTA account, this trading pair does not support copy trading
    • bothFor both normal account and UTA account, this trading pair supports copy trading
    • utaOnlyOnly for UTA account,this trading pair supports copy trading
    • normalOnlyOnly for normal account, this trading pair supports copy trading

    type

    • TRANSFER_IN
    • TRANSFER_OUT
    • TRADE
    • SETTLEMENT
    • DELIVERY
    • LIQUIDATION
    • BONUS
    • FEE_REFUND
    • INTEREST
    • CURRENCY_BUY
    • CURRENCY_SELL
    • BORROWED_AMOUNT_INS_LOAN
    • PRINCIPLE_REPAYMENT_INS_LOAN
    • INTEREST_REPAYMENT_INS_LOAN
    • AUTO_SOLD_COLLATERAL_INS_LOAN
    • AUTO_BUY_LIABILITY_INS_LOAN
    • AUTO_PRINCIPLE_REPAYMENT_INS_LOAN
    • AUTO_INTEREST_REPAYMENT_INS_LOAN
    • TRANSFER_IN_INS_LOANTransfer In when in the liquidation of OTC loan
    • TRANSFER_OUT_INS_LOANTransfer Out when in the liquidation of OTC loan
    • SPOT_REPAYMENT_SELLOne-click repayment currency sell
    • SPOT_REPAYMENT_BUYOne-click repayment currency buy

    unifiedMarginStatus

    • 1Regular account
    • 2Unified margin account, it only trades linear perpetual and options.
    • 3Unified trade account, it can trade linear perpetual, options and spot
    • 4UTA Pro, the pro version of Unified trade account

    ltStatus

    • 1LT can be purchased and redeemed
    • 2LT can be purchased, but not redeemed
    • 3LT can be redeemed, but not purchased
    • 4LT cannot be purchased nor redeemed
    • 5Adjusting position

    symbol

    USDT Perpetual:

    • BTCUSDT
    • ETHUSDT

    USDC Perpetual:

    • BTCPERP
    • ETHPERP

    USDC Futures:

    • BTC-24MAR23

    Inverse Perpetual:

    • BTCUSD
    • ETHUSD

    Inverse Futures:

    • BTCUSDH23H: First quarter; 23: 2023
    • BTCUSDM23M: Second quarter; 23: 2023
    • BTCUSDU23U: Third quarter; 23: 2023
    • BTCUSDZ23Z: Fourth quarter; 23: 2023

    Spot:

    • BTCUSDT
    • ETHUSDC

    vipLevel

    • No VIP
    • VIP-1
    • VIP-2
    • VIP-3
    • VIP-4
    • VIP-5
    • VIP-Supreme
    • PRO-1
    • PRO-2
    • PRO-3
    • PRO-4
    • PRO-5

    adlRankIndicator

    • 0default value of empty position
    • 1
    • 2
    • 3
    • 4
    • 5

    smpType

    • default: None
    • CancelMaker
    • CancelTaker
    • CancelBoth

    Spot Fee Currency Instruction

    with the example of BTCUSDT:

    • Is makerFeeRate positive?
      • TRUE
        • Side = Buy -> base currency (BTC)
        • Side = Sell -> quote currency (USDT)
      • FALSE
        • IsMakerOrder = TRUE
          • Side = Buy -> quote currency (USDT)
          • Side = Sell -> base currency (BTC)
        • IsMakerOrder = FALSE
          • Side = Buy -> base currency (BTC)
          • Side = Sell -> quote currency (USDT)
    - + \ No newline at end of file diff --git a/v5/error.html b/v5/error.html index 88f594155d..dc17647b95 100644 --- a/v5/error.html +++ b/v5/error.html @@ -4,13 +4,13 @@ Error Codes | Bybit API Documentation - +

    Error Codes

    HTTP Code

    CodeDescription
    400Bad request. Need to send the request with GET / POST (must be capitalized)
    401Invalid request. 1. Need to use the correct key to access; 2. Need to put authentication params in the request header
    403Forbidden request. Possible causes: 1. IP rate limit breached; 2. You send GET request with an empty json body
    404Cannot find path. Possible causes: 1. Wrong path; 2. Category value does not match account mode

    UMA & UTA & Futures of Classic Account

    CodeDescription
    0OK
    10000Server Timeout
    10001Request parameter error
    10002The request time exceeds the time window range.
    10003API key is invalid.
    10004Error sign, please check your signature generation algorithm.
    10005Permission denied, please check your API key permissions.
    10006Too many visits. Exceeded the API Rate Limit.
    10007User authentication failed.
    10008Common banned, please check your account mode
    10009IP has been banned.
    10010Unmatched IP, please check your API key's bound IP addresses.
    10014Invalid duplicate request.
    10016Server error.
    10017Route not found.
    10018Exceeded the IP Rate Limit.
    10024Compliance rules triggered
    10027Transactions are banned.
    10029The requested symbol is invalid, please check symbol whitelist
    10028The API can only be accessed by unified account users.
    30133OTC loan: The symbol you select for USDT Perpetual is not allowed by Institutional Lending
    30134OTC loan: The symbol you select for USDC Contract is not allowed by Institutional Lending
    30135The leverage you select for USDT Perpetual trading cannot exceed the maximum leverage allowed by Institutional Lending.
    30136The leverage you select for USDC Perpetual or Futures trading cannot exceed the maximum leverage allowed by Institutional Lending.
    40004the order is modified during the process of replacing , please check the order status again
    100028The API cannot be accessed by unified account users.
    110001Order does not exist
    110003Order price exceeds the allowable range.
    110004Wallet balance is insufficient
    110005position status
    110006The assets are estimated to be unable to cover the position margin
    110007Available balance is insufficient
    110008The order has been completed or cancelled.
    110009The number of stop orders exceeds the maximum allowable limit. You can find references in our API doc.
    110010The order has been cancelled
    110011Liquidation will be triggered immediately by this adjustment
    110012Insufficient available balance.
    110013Cannot set leverage due to risk limit level.
    110014Insufficient available balance to add additional margin.
    110015The position is in cross margin mode.
    110016The quantity of contracts requested exceeds the risk limit, please adjust your risk limit level before trying again
    110017Reduce-only rule not satisfied
    110018User ID is illegal.
    110019Order ID is illegal.
    110020Not allowed to have more than 500 active orders.
    110021Not allowed to exceeded position limits due to Open Interest.
    110022Quantity has been restricted and orders cannot be modified to increase the quantity.
    110023Currently you can only reduce your position on this contract. please check our announcement or contact customer service for details.
    110024You have an existing position, so the position mode cannot be switched.
    110025Position mode has not been modified.
    110026Cross/isolated margin mode has not been modified.
    110027Margin has not been modified.
    110028You have existing open orders, so the position mode cannot be switched.
    110029Hedge mode is not supported for this symbol.
    110030Duplicate orderId
    110031Non-existing risk limit info, please check the risk limit rules.
    110032Order is illegal
    110033You can't set margin without an open position
    110034There is no net position
    110035Cancellation of orders was not completed before liquidation
    110036You are not allowed to change leverage due to cross margin mode.
    110037User setting list does not have this symbol
    110038You are not allowed to change leverage due to portfolio margin mode.
    110039Maintenance margin rate is too high. This may trigger liquidation.
    110040The order will trigger a forced liquidation, please re-submit the order.
    110041Skip liquidation is not allowed when a position or maker order exists
    110042Currently,due to pre-delivery status, you can only reduce your position on this contract.
    110043Set leverage has not been modified.
    110044Available margin is insufficient.
    110045Wallet balance is insufficient.
    110046Liquidation will be triggered immediately by this adjustment.
    110047Risk limit cannot be adjusted due to insufficient available margin.
    110048Risk limit cannot be adjusted as the current/expected position value exceeds the revised risk limit.
    110049Tick notes can only be numbers
    110050Invalid coin
    110051The user's available balance cannot cover the lowest price of the current market
    110052Your available balance is insufficient to set the price
    110053The user's available balance cannot cover the current market price and upper limit price
    110054This position has at least one take profit link order, so the take profit and stop loss mode cannot be switched
    110055This position has at least one stop loss link order, so the take profit and stop loss mode cannot be switched
    110056This position has at least one trailing stop link order, so the take profit and stop loss mode cannot be switched
    110057Conditional order or limit order contains TP/SL related params
    110058You can't set take profit and stop loss due to insufficient size of remaining position size.
    110059Not allowed to modify the TP/SL of a partially filled open order
    110060Under full TP/SL mode, it is not allowed to modify TP/SL
    110061Not allowed to have more than 20 TP/SLs under Partial tpSlMode
    110062There is no MMP information of the institution found.
    110063Settlement in progress! {{key0}} not available for trading.
    110064The modified contract quantity cannot be less than or equal to the filled quantity.
    110065MMP hasn't yet been enabled for your account. Please contact your BD manager.
    110066Trading is currently not allowed.
    110067Unified account is not supported.
    110068Leveraged trading is not allowed.
    110069Ins lending customer is not allowed to trade.
    110070ETP symbols cannot be traded.
    110071Sorry, we're revamping the Unified Margin Account! Currently, new upgrades are not supported. If you have any questions, please contact our 24/7 customer support.
    110072OrderLinkedID is duplicate
    110073Set margin mode failed
    110075RiskId not modified
    110075 182021Cannot enable spot margin while in isolated margin mode. Please switch to cross margin mode or portfolio margin mode to trade spot with margin.
    110076Only isolated mode can set auto-add-margin
    110077Pm mode cannot support
    110078Added margin more than max can reduce margin
    110079The order is processing and can not be operated, please try again later
    110080Operations Restriction: The current LTV ratio of your Institutional Lending has hit the liquidation threshold. Assets in your account are being liquidated (trade/risk limit/leverage)
    110082You cannot lift Reduce-Only restrictions, as no Reduce-Only restrictions are applied to your position
    110083Reduce-Only restrictions must be lifted for both Long and Short positions at the same time
    110085The risk limit and margin ratio for this contract has been updated, please select a supported risk limit and place your order again
    110086Current order leverage exceeds the maximum available for your current Risk Limit tier. Please lower leverage before placing an order
    110087Leverage for Perpetual or Futures contracts cannot exceed the maximum allowed for your Institutional loan
    3100181UID can not be null
    3100197Temporary banned due to the upgrade to UTA
    3200316USDC Options Trading Restriction: The current LTV ratio for your Institutional Lending has reached the maximum allowable amount for USDC Options trading.
    3200317USDC Options Open Position Restriction: The current LTV ratio for your Institutional Lending has reached the maximum allowable amount for opening USDC Options positions.
    3100326BaseCoin is required
    3200403isolated margin can not create order
    3200320Operations Restriction: The current LTV ratio of your Institutional Lending has hit the liquidation threshold. Assets in your account are being liquidated. (margin mode or spot leverage)
    3400208You have unclosed hedge mode or isolated mode USDT perpetual positions
    3400209You have USDT perpetual positions, so upgrading is prohibited for 10 minutes before and after the hour every hour
    3400210The risk rate of your Derivatives account is too high
    3400211Once upgraded, the estimated risk rate will be too high
    3400212You have USDC perpetual positions or Options positions, so upgrading is prohibited for 10 minutes before and after the hour every hour
    3400213The risk rate of your USDC Derivatives account is too high
    3400052You have uncancelled USDC perpetual orders
    3400053You have uncancelled Options orders
    3400054You have uncancelled USDT perpetual orders
    3400214Server error, please try again later
    3400071The net asset is not satisfied
    3401010Cannot switch to PM mode (for copy trading master trader)
    3400139The total value of your positions and orders has exceeded the risk limit for a Perpetual or Futures contract

    Spot Trade

    CodeDescription
    170001Internal error.
    170005Too many new orders; current limit is %s orders per %s.
    170007Timeout waiting for response from backend server.
    170010Purchase failed: Exceed the maximum position limit of leveraged tokens, the current available limit is %s USDT
    170011"Purchase failed: Exceed the maximum position limit of innovation tokens,
    170019the current available limit is ''{{.replaceKey0}}'' USDT"
    170031The feature has been suspended
    170032Network error. Please try again later
    170033margin Insufficient account balance
    170034Liability over flow in spot leverage trade!
    170035Submitted to the system for processing!
    170036You haven't enabled Cross Margin Trading yet. To do so, please head to the PC trading site or the Bybit app
    170037Cross Margin Trading not yet supported by the selected coin
    170105Parameter '%s' was empty.
    170115Invalid timeInForce.
    170116Invalid orderType.
    170117Invalid side.
    170121Invalid symbol.
    170124Order amount too large.
    170130Data sent for paramter '%s' is not valid.
    170131Balance insufficient
    170132Order price too high.
    170133Order price lower than the minimum.
    170134Order price decimal too long.
    170135Order quantity too large.
    170136Order quantity lower than the minimum.
    170137Order volume decimal too long
    170139Order has been filled.
    170140Transaction amount lower than the minimum.
    170141Duplicate clientOrderId
    170142Order has been canceled
    170143Cannot be found on order book
    170144Order has been locked
    170145This order type does not support cancellation
    170146Order creation timeout
    170147Order cancellation timeout
    170148Market order amount decimal too long
    170149Create order failed
    170150Cancel order failed
    170151The trading pair is not open yet
    170157The trading pair is not available for api trading
    170159Market Order is not supported within the first %s minutes of newly launched pairs due to risk control.
    170190Cancel order has been finished
    170191Can not cancel order, please try again later
    170192Order price cannot be higher than %s .
    170193Buy order price cannot be higher than %s.
    170194Sell order price cannot be lower than %s.
    170195Please note that your order may not be filled
    170196Please note that your order may not be filled
    170197Your order quantity to buy is too large. The filled price may deviate significantly from the market price. Please try again
    170198Your order quantity to sell is too large. The filled price may deviate significantly from the market price. Please try again
    170199Your order quantity to buy is too large. The filled price may deviate significantly from the nav. Please try again.
    170200Your order quantity to sell is too large. The filled price may deviate significantly from the nav. Please try again.
    170201Your account has been restricted for trades. If you have any questions, please email us at support@bybit.com
    170202Invalid orderFilter parameter.
    170203Please enter the TP/SL price.
    170204trigger price cannot be higher than 110% price.
    170206trigger price cannot be lower than 90% of qty.
    170207The loan amount of the platform is not enough.
    170210New order rejected.
    170212Cancel order request processing
    170213Order does not exist.
    170215Spot Trading (Buy) Restriction: The current LTV ratio of your institutional lending has reached the maximum allowable amount for buy orders
    170216The leverage you select for Spot Trading cannot exceed the maximum leverage allowed by Institutional Lending
    170217Only LIMIT-MAKER order is supported for the current pair.
    170218The LIMIT-MAKER order is rejected due to invalid price.
    170219UID {{xxx}} is not available to this feature
    170220Spot Trading Restriction: The current LTV ratio of your institutional lending has reached the maximum allowable amount for Spot trading
    170221This coin does not exist.
    170222Too many requests in this time frame.
    170223Your Spot Account with Institutional Lending triggers an alert or liquidation.
    170224You're not a user of the Innovation Zone.
    170226Your Spot Account for Margin Trading is being liquidated.
    170227This feature is not supported.
    170228The purchase amount of each order exceeds the estimated maximum purchase amount.
    170229The sell quantity per order exceeds the estimated maximum sell quantity.
    170230Operations Restriction: Due to the deactivation of Margin Trading for institutional loan
    170234System Error
    170310Order modification timeout
    170311Order modification failed
    170312The current order does not support modification
    170313The modified contract quantity cannot be less than to the filled quantity
    170709OTC loan: The select trading pair is not in the whitelist pair

    Spot Leverage Token

    CodeDescription
    175000The serialNum is already in use.
    175001Daily purchase limit has been exceeded. Please try again later.
    175002There's a large number of purchase orders. Please try again later.
    175003Insufficient available balance. Please make a deposit and try again.
    175004Daily redemption limit has been exceeded. Please try again later.
    175005There's a large number of redemption orders. Please try again later.
    175006Insufficient available balance. Please make a deposit and try again.
    175007Order not found.
    175008Purchase period hasn't started yet.
    175009Purchase amount has exceeded the upper limit.
    175010You haven't passed the quiz yet! To purchase and/or redeem an LT, please complete the quiz first.
    175012Redemption period hasn't started yet.
    175013Redemption amount has exceeded the upper limit.
    175014Purchase of the LT has been temporarily suspended.
    175015Redemption of the LT has been temporarily suspended.
    175016Invalid format. Please check the length and numeric precision.
    175017Failed to place order:Exceed the maximum position limit of leveraged tokens, the current available limit is XXXX USDT
    175027Subscriptions and redemptions are temporarily unavailable while account upgrade is in progress

    Spot Margin Trade

    CodeDescription
    176002Query user account info error. Confirm that if you have completed quiz in GUI
    176003Query user loan history error
    176004Query order history start time exceeds end time
    176005Failed to borrow
    176006Repayment Failed
    176007User not found
    176008You haven't enabled Cross Margin Trading yet. To do so, please head to the PC trading site
    176009You haven't enabled Cross Margin Trading yet. Confirm that if you have turned on margin trade
    176010Failed to locate the coins to borrow
    176011Cross Margin Trading not yet supported by the selected coin
    176012Pair not available
    176013Cross Margin Trading not yet supported by the selected pair
    176014Repeated repayment requests
    176015Insufficient available balance
    176016No repayment required
    176017Repayment amount has exceeded the total liability
    176018Settlement in progress
    176019Liquidation in progress
    176020Failed to locate repayment history
    176021Repeated borrowing requests
    176022Coins to borrow not generally available yet
    176023Pair to borrow not generally available yet
    176024Invalid user status
    176025Amount to borrow cannot be lower than the min. amount to borrow (per transaction)
    176026Amount to borrow cannot be larger than the max. amount to borrow (per transaction)
    176027Amount to borrow cannot be higher than the max. amount to borrow per user
    176028Amount to borrow has exceeded Bybit's max. amount to borrow
    176029Amount to borrow has exceeded the user's estimated max. amount to borrow
    176030Query user loan info error
    176031Number of decimals for borrow amount has exceeded the maximum precision
    176034The leverage ratio is out of range
    176035Failed to close the leverage switch during liquidation
    176036Failed to adjust leverage switch during forced liquidation
    176037For non-unified transaction users, the operation failed
    176038The spot leverage is closed and the current operation is not allowed
    176039Borrowing, current operation is not allowed
    176040There is a spot leverage order, and the adjustment of the leverage switch failed!
    176132Number of decimals for repay amount has exceeded the maximum precision
    176133Liquidation may be triggered! Please adjust your transaction amount and try again
    176134Account has been upgraded (upgrading) to UTA
    176135Failed to get bond data
    176136Failed to get borrow data
    176137Failed to switch user status
    176138You need to repay all your debts before closing your disabling cross margin account
    176139Sorry, you are not eligible to enable cross margin, as you have already enabled OTC lending
    176201Account exception. Check if the UID is bound to INS loan

    Asset

    CodeDescription
    131001Service error
    131002Parameter error
    131002Withdraw address chain or destination tag are not equal
    131003Internal error
    131004KYC needed
    131075InternalAddressCannotBeYourself
    131076internal transfer not support sub-accounts
    131077receive user not exist
    131078receive user deposit has been banned
    131079receive user need kyc
    131080User left retry times is zero
    131081Do not input memo/tag,please.
    131082Do not repeat the request
    131083Withdraw only allowed from address book
    131084Withdraw failed because of Uta Upgrading
    131085Withdrawal amount is greater than your availale balance (the deplayed withdrawal is triggered)
    131086Withdrawal amount exceeds risk limit (the risk limit of margin trade is triggered)
    131087your current account spot risk level is too high, withdrawal is prohibited, please adjust and try again
    131088The withdrawal amount exceeds the remaining withdrawal limit of your identity verification level. The current available amount for withdrawal : %s
    131089User sensitive operation, withdrawal is prohibited within 24 hours
    131090User withdraw has been banned
    131091Blocked login status does not allow withdrawals
    131092User status is abnormal
    131093The withdrawal address is not in the whitelist
    131094UserId is not in the whitelist
    131095Withdrawl amount exceeds the 24 hour platform limit
    131096Withdraw amount does not satify the lower limit or upper limit
    131097Withdrawal of this currency has been closed
    131098Withdrawal currently is not availble from new address
    131099Hot wallet status can cancel the withdraw
    131200Service error
    131201Internal error
    131202Invalid memberId
    131203Request parameter error
    131204Account info error
    131205Query transfer error
    131206cannot be transfer
    131207Account not exist
    131208Forbid transfer
    131209Get subMember relation error
    131210Amount accuracy error
    131211fromAccountType can't be the same as toAccountType
    131212Insufficient balance
    131213TransferLTV check error
    131214TransferId exist
    131215Amount error
    131216Query balance error
    131217Risk check error
    131227Sub-account do not have universal transfer permission
    131228your balance is not enough. Please check transfer safe amount
    131229Due to compliance requirements, the current currency is not allowed to transfer
    131230The system is busy, please try again later
    141004sub member is not normal
    141025This sub-account has assets and cannot be deleted
    181000category is null
    181001category only support linear or option or spot.
    181002symbol is null.
    181003side is null.
    181004side only support Buy or Sell.
    181005orderStatus is wrong
    181006startTime is not number
    181007endTime is not number
    181008Parameter startTime and endTime are both needed
    181009Parameter startTime needs to be smaller than endTime
    181010The time range between startTime and endTime cannot exceed 7 days
    181011limit is not a number
    181012symbol not exist
    181013Only support settleCoin: usdc
    181014Classic account is not supported
    182000symbol related quote price is null

    Institutional Lending

    CodeDescription
    3777002UID cannot be bound repeatedly.
    3777003UID cannot be unbound because the UID has not been bound to a risk unit.
    3777004The main UID of the risk unit cannot be unbound.
    3777006UID cannot be bound, please try again with a different UID."
    3777007UID cannot be bound, please upgrade to UTA Pro."
    3777027UID cannot be bound, leveraged trading closure failed.

    C2C Lending

    CodeDescription
    177000Unknown error
    177001System internal error
    177002Timeout
    177003System is busy, please try again later
    177004Parameter error
    177005Unable to find lending currency
    177006Request frequency limit
    177007The unified account is being upgraded, and redemption is not supported for the time being
    177008Deposit quantity too small
    177009Quantity accuracy exceeds limit
    177010User balance not enough
    177011Platform limit exceeded
    177012Maximum redeemable amount exceeded
    177013Duplicate serial number
    177014There are orders in process, please try again later
    177015Exceeded the user's one-day platform limit
    177019Cannot continue lending because reached this crypto lending limit

    Broker

    CodeDescription
    3500402Parameter verification failed for 'limit'.
    3500403Only available to exchange broker main-account
    3500404Invalid Cursor
    3500405Parameter "startTime" and "endTime" need to be input in pairs.
    - + \ No newline at end of file diff --git a/v5/guide.html b/v5/guide.html index 413ab4a83d..734494b0c9 100644 --- a/v5/guide.html +++ b/v5/guide.html @@ -4,7 +4,7 @@ Integration Guidance | Bybit API Documentation - + @@ -15,7 +15,7 @@ server_time - recv_window <= timestamp < server_time + 1000
    server_time stands for Bybit server time, which can be queried via the Server Time endpoint.

    Create A Request

    tip

    To assist in diagnosing advanced network problems, you may consider adding cdn-request-id to your request headers. Its value should be unique for each request.

    Basic steps:

    1. timestamp + API key + (recv_window) + (queryString | jsonBodyString)
    2. Use the HMAC_SHA256 or RSA_SHA256 algorithm to sign the string in step 1, and convert it to a hex string (HMAC_SHA256) / base64 (RSA_SHA256) to obtain the sign parameter.
    3. Append the sign parameter to request header, and send the HTTP request. Note: the plain text for GET and POST requests is different. Please refer to blew examples.
    info
    Example signature algorithms can be found here.

    An example for how to generate plain text to encrypt

    # rule:
    timestamp+api_key+recv_window+queryString

    # param_str
    "1658384314791XXXXXXXXXX5000category=option&symbol=BTC-29JUL22-25000-C"

    # parse
    timestamp = "1658384314791"
    api_key = "XXXXXXXXXX"
    recv_window = "5000"
    queryString = "category=option&symbol=BTC-29JUL22-25000-C"

    HTTP request examples

    GET /v5/order/realtime?category=option&symbol=BTC-29JUL22-25000-C HTTP/1.1
    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'

    Common response parameters

    ParameterTypeComments
    retCodenumberSuccess/Error code
    retMsgstringSuccess/Error msg. OK, success, SUCCESS indicate a successful response
    resultObjectBusiness data result
    retExtInfoObjectExtend info. Most of the time, it is {}
    timenumberCurrent timestamp (ms)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }
    - + \ No newline at end of file diff --git a/v5/intro.html b/v5/intro.html index 83341daaf9..ea31921983 100644 --- a/v5/intro.html +++ b/v5/intro.html @@ -4,7 +4,7 @@ Introduction | Bybit API Documentation - + @@ -44,7 +44,7 @@ orders that can be traded for each symbol.

    Uniform and Precise Data

    Previous APIs returned data as E2 and E8. API V3 and V5 return data as actual values, eliminating the need for users to implement conversion logic.

    Readability Improvements to API Documentation

    The API documentation has been revised and proofread to improve clarity and reduce confusion. Any parts of the previous documentation that were not clear have been revised to provide better explanations.

    V5 and V3 Interface Mapping List

    ModuleV5 EndpointV3 Endpoint
    Market/v5/market/kline/derivatives/v3/public/kline
    /spot/v3/public/quote/kline
    /v5/market/mark-price-kline/derivatives/v3/public/mark-price-kline
    /v5/market/index-price-kline/derivatives/v3/public/index-price-kline
    /v5/market/premium-index-price-kline/derivatives/v3/public/premium-index-price-kline
    /v5/market/orderbook/derivatives/v3/public/order-book/L2
    /spot/v3/public/quote/depth
    /v5/market/tickers/derivatives/v3/public/tickers
    /spot/v3/public/quote/ticker/24hr
    /spot/v3/public/quote/ticker/price
    /spot/v3/public/quote/ticker/bookTicker
    /v5/market/funding/history/derivatives/v3/public/funding/history-funding-rate
    /v5/market/recent-trade/derivatives/v3/public/recent-trade
    /spot/v3/public/quote/trades
    /v5/market/open-interest/derivatives/v3/public/open-interest
    /v5/market/historical-volatility/derivatives/v3/public/historical-volatility
    /v5/market/insurance/derivatives/v3/public/insurance
    /v5/market/instruments-info/derivatives/v3/public/instruments-info
    /spot/v3/public/infos
    /spot/v3/public/symbols
    /v5/market/risk-limit/derivatives/v3/public/risk-limit/list
    /v5/market/delivery-price/derivatives/v3/public/delivery-price
    Order/v5/order/create/unified/v3/private/order/create
    /contract/v3/private/order/create
    /v5/order/amend/unified/v3/private/order/replace
    /contract/v3/private/order/replace
    /v5/order/cancel/unified/v3/private/order/cancel
    /contract/v3/private/order/cancel
    /v5/order/realtime/unified/v3/private/order/unfilled-orders
    /contract/v3/private/order/unfilled-orders
    /v5/order/cancel-all/unified/v3/private/order/cancel-all
    /contract/v3/private/order/cancel-all
    /v5/order/history/unified/v3/private/order/list
    /contract/v3/private/order/list
    /v5/order/create-batch/unified/v3/private/order/create-batch
    /v5/order/amend-batch/unified/v3/private/order/replace-batch
    /v5/order/cancel-batch/unified/v3/private/order/cancel-batch
    /v5/order/spot-borrow-checkNone
    Position/v5/position/list/unified/v3/private/position/list
    /contract/v3/private/position/list
    /v5/position/set-leverage/unified/v3/private/position/set-leverage
    /contract/v3/private/position/set-leverage
    /v5/position/set-risk-limit/unified/v3/private/position/set-risk-limit
    /contract/v3/private/position/set-risk-limit
    /v5/position/trading-stop/unified/v3/private/position/trading-stop
    /contract/v3/private/position/trading-stop
    /v5/position/switch-isolated/contract/v3/private/position/switch-isolated
    /v5/position/switch-mode/contract/v3/private/position/switch-mode
    /v5/position/set-auto-add-margin/contract/v3/private/position/set-auto-add-margin
    /v5/position/closed-pnl/contract/v3/position/closed-pnl
    /v5/execution/list/unified/v3/private/execution/list
    /contract/v3/private/execution/list
    Account/v5/account/wallet-balance/unified/v3/private/account/wallet/balance
    /contract/v3/private/account/wallet/balance
    /v5/account/upgrade-to-uta/unified/v3/private/account/upgrade-unified-account
    /v5/account/borrow-history/unified/v3/private/account/borrow-history
    /v5/account/collateral-info/unified/v3/private/account/borrow-rate
    /v5/asset/coin-greeksNone
    /v5/account/infoNone
    /v5/account/transaction-log/unified/v3/private/account/transaction-log
    /v5/account/set-margin-mode/contract/v3/private/account/setMarginMode
    Spot Leverage Token/v5/spot-lever-token/info/spot/v3/public/infos
    /v5/spot-lever-token/reference/spot/v3/private/order/reference
    /v5/spot-lever-token/purchase/spot/v3/private/order/purchase
    /v5/spot-lever-token/redeem/spot/v3/private/order/redeem
    /v5/spot-lever-token/order-record/spot/v3/private/order/record
    Spot Margin Trade/v5/spot-margin-trade/switch-mode/spot/v3/private/cross-margin-switch
    /v5/spot-margin-trade/set-leverageNone
    /v5/spot-margin-trade/set-pledge-tokenNone
    Asset/v5/asset/delivery-record/unified/v3/private/delivery-record
    /v5/asset/settlement-record/unified/v3/private/settlement-record
    /v5/asset/transfer/inter-transfer/asset/v3/private/transfer/inter-transfer
    v5/asset/transfer/query-inter-transfer-list/asset/v3/private/transfer/inter-transfer/list/query
    v5/asset/transfer/save-transfer-sub-member/asset/v3/private/transfer/transfer-sub-member-save
    /v5/asset/transfer/universal-transfer/asset/v3/private/transfer/universal-transfer
    /v5/asset/transfer/query-universal-transfer-list/asset/v3/private/transfer/universal-transfer/list/query
    /v5/asset/transfer/query-transfer-coin-list/asset/v3/private/transfer/transfer-coin/list/query
    /v5/asset/transfer/query-sub-member-list/asset/v3/private/transfer/sub-member/list/quer
    /v5/asset/transfer/query-account-coin-balance/asset/v3/private/transfer/account-coin/balance/query
    /v5/asset/transfer/query-asset-info/asset/v3/private/transfer/asset-info/query
    /v5/asset/deposit/query-allowed-list/asset/v3/public/deposit/allowed-deposit-list/query
    /v5/asset/deposit/query-record/asset/v3/private/deposit/record/query
    /v5/asset/deposit/query-sub-member-record/asset/v3/private/deposit/sub-member-record/query
    /v5/asset/withdraw/query-record/asset/v3/private/withdraw/record/query
    /v5/asset/coin/query-info/asset/v3/private/coin-info/query
    /v5/asset/withdraw/create/asset/v3/private/withdraw/create
    /v5/asset/withdraw/cancel/asset/v3/private/withdraw/cancel
    /v5/asset/deposit/query-address/asset/v3/private/deposit/address/query
    /v5/asset/deposit/query-sub-member-address/asset/v3/private/deposit/sub-member-address/query
    /v5/asset/exchange/order-record/asset/v2/private/exchange/query-exchange-order
    WebSocket Publicwss://stream.bybit.com/v5/public/spotwss://stream.bybit.com/spot/public/v3
    wss://stream.bybit.com/v5/public/linearwss://stream.bybit.com/contract/usdt/public/v3
    wss://stream.bybit.com/contract/usdc/public/v3
    wss://stream.bybit.com/v5/public/inversewss://stream.bybit.com/contract/inverse/public/v3
    wss://stream.bybit.com/v5/public/optionwss://stream.bybit.com/option/usdc/public/v3
    WebSocket Privatewss://stream.bybit.com/v5/privatewss://stream.bybit.com/spot/private/v3
    wss://stream.bybit.com/unified/private/v3
    wss://stream.bybit.com/contract/private/v3
    - + \ No newline at end of file diff --git a/v5/lt/leverage-token-info.html b/v5/lt/leverage-token-info.html index 40df9fae3f..b7ab25febc 100644 --- a/v5/lt/leverage-token-info.html +++ b/v5/lt/leverage-token-info.html @@ -4,13 +4,13 @@ Get Leverage Token Info | Bybit API Documentation - +

    Get Leverage Token Info

    Query leverage token information

    HTTP Request

    GET /v5/spot-lever-token/info

    Request Parameters

    ParameterRequiredTypeComments
    ltCoinfalsestringAbbreviation of the LT, such as BTC3L

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > ltCoinstringAbbreviation
    > ltNamestringFull name of leveraged token
    > maxPurchasestringSingle maximum purchase amount
    > minPurchasestringSingle minimum purchase amount
    > maxPurchaseDailystringMaximum purchase amount in a single day
    > maxRedeemstringSingle Maximum redemption quantity
    > minRedeemstringSingle Minimum redemption quantity
    > maxRedeemDailystringMaximum redemption quantity in a single day
    > purchaseFeeRatestringPurchase fee rate
    > redeemFeeRatestringRedeem fee rate
    > ltStatusstringWhether the leverage token can be purchased or redeemed
    > fundFeestringFunding fee charged daily for users holding leveraged token
    > fundFeeTimestringThe time to charge funding fee
    > manageFeeRatestringManagement fee rate
    > manageFeeTimestringThe time to charge management fee
    > valuestringNominal asset value
    > netValuestringNet value
    > totalstringTotal purchase upper limit

    Request Example

    GET /v5/spot-lever-token/info?ltCoin=BTC3L HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "fundFee": "299.70622821",
    "fundFeeTime": "1672992000000",
    "ltCoin": "BTC3L",
    "ltName": "3X Long",
    "ltStatus": "1",
    "manageFeeRate": "0.00005",
    "manageFeeTime": "1673053200000",
    "maxPurchase": "10000",
    "maxPurchaseDaily": "200000",
    "maxRedeem": "14434",
    "maxRedeemDaily": "2100000",
    "minPurchase": "100",
    "minRedeem": "144",
    "netValue": "0.376482201140738147",
    "purchaseFeeRate": "0.0005",
    "redeemFeeRate": "0.0005",
    "total": "5000000",
    "value": "49464463114.022994974075443169"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672991427073
    }
    - + \ No newline at end of file diff --git a/v5/lt/leverage-token-reference.html b/v5/lt/leverage-token-reference.html index f48d631fee..7ceca862b9 100644 --- a/v5/lt/leverage-token-reference.html +++ b/v5/lt/leverage-token-reference.html @@ -4,13 +4,13 @@ Get Leveraged Token Market | Bybit API Documentation - +

    Get Leveraged Token Market

    Get leverage token market information

    HTTP Request

    GET /v5/spot-lever-token/reference

    Request Parameters

    ParameterRequiredTypeComments
    ltCointruestringAbbreviation of the LT, such as BTC3L

    Response Parameters

    ParameterTypeComments
    ltCoinstringAbbreviation of the LT, such as BTC3L
    navstringnet value
    navTimestringUpdate time for net asset value (in milliseconds and UTC time zone)
    circulationstringCirculating supply in the secondary market
    basketstringbasket
    leveragestringReal leverage calculated by last traded price

    Request Example

    GET /v5/spot-lever-token/reference?ltCoin=BTC3S HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "basket": "-132.460000082171973364",
    "circulation": "30097.901900052619091704",
    "leverage": "-2.666924651755770729",
    "ltCoin": "BTC3S",
    "nav": "27.692082719770373048",
    "navTime": "1672991679858"
    },
    "retExtInfo": {},
    "time": 1672991679937
    }
    - + \ No newline at end of file diff --git a/v5/lt/order-record.html b/v5/lt/order-record.html index cdc0808bd2..5c977be374 100644 --- a/v5/lt/order-record.html +++ b/v5/lt/order-record.html @@ -4,13 +4,13 @@ Get Purchase/Redemption Records | Bybit API Documentation - +

    Get Purchase/Redemption Records

    Get purchase or redeem history

    HTTP Request

    GET /v5/spot-lever-token/order-record

    Request Parameters

    ParameterRequiredTypeComments
    ltCoinfalsestringAbbreviation of the LT, such as BTC3L
    orderIdfalsestringOrder ID
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 100
    ltOrderTypefalseintegerLT order type. 1: purchase, 2: redemption
    serialNofalsestringSerial number

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > ltCoinstringAbbreviation of the LT, such as BTC3L
    > orderIdstringOrder ID
    > ltOrderTypeintegerLT order type. 1: purchase, 2: redeem
    > orderTimenumberOrder time
    > updateTimenumberLast update time of the order status
    > ltOrderStatusstringOrder status. 1: completed, 2: in progress, 3: failed
    > feestringTrading fees
    > amountstringOrder quantity of the LT
    > valuestringFilled value
    > valueCoinstringQuote coin
    > serialNostringSerial number

    Request Example

    GET /v5/spot-lever-token/order-record?orderId=2611 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672294422027
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "amount": "222.90757477",
    "fee": "0",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "1",
    "ltOrderType": "1",
    "orderId": "2611",
    "orderTime": "1672737465000",
    "serialNo": "pruchase-002",
    "updateTime": "1672737478000",
    "value": "95.13860435",
    "valueCoin": "USDT"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672294446137
    }
    - + \ No newline at end of file diff --git a/v5/lt/purchase.html b/v5/lt/purchase.html index 921d3173e9..9358641c93 100644 --- a/v5/lt/purchase.html +++ b/v5/lt/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +

    Purchase

    Purchase levearge token

    HTTP Request

    POST /v5/spot-lever-token/purchase

    Request Parameters

    ParameterRequiredTypeComments
    ltCointruestringAbbreviation of the LT, such as BTC3L
    ltAmounttruestringPurchase amount
    serialNofalsestringSerial number

    Response Parameters

    ParameterTypeComments
    ltCoinstringAbbreviation of the LT, such as BTC3L
    ltOrderStatusstringOrder status. 1: completed, 2: in progress, 3: failed
    execQtystringExecuted qty of LT
    execAmtstringExecuted amount of LT
    amountstringPurchase amount
    purchaseIdstringOrder ID
    serialNostringSerial number, customised order ID
    valueCoinstringQuote coin

    Request Example

    POST /v5/spot-lever-token/purchase HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672294730346
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "ltCoin": "EOS3L",
    "amount": "200",
    "serialNo": "purchase-001"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "amount": "200",
    "execAmt": "",
    "execQty": "",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "2",
    "purchaseId": "2611",
    "serialNo": "purchase-001",
    "valueCoin": "USDT"
    },
    "retExtInfo": {},
    "time": 1672293867729
    }
    - + \ No newline at end of file diff --git a/v5/lt/redeem.html b/v5/lt/redeem.html index b42138d1e7..b52b18aa2b 100644 --- a/v5/lt/redeem.html +++ b/v5/lt/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +

    Redeem

    Redeem leverage token

    HTTP Request

    POST /v5/spot-lever-token/redeem

    Request Parameters

    ParameterRequiredTypeComments
    ltCointruestringAbbreviation of the LT, such as BTC3L
    quantityturestringRedeem quantity of LT
    serialNofalsestringSerial number

    Response Parameters

    ParameterTypeComments
    ltCoinstringAbbreviation of the LT
    ltOrderStatusstringOrder status. 1: completed, 2: in progress, 3: failed
    quantitystringQuantity
    execQtystringLT quantity
    execAmtstringExecuted amount of LT
    redeemIdstringOrder ID
    serialNostringSerial number
    valueCoinstringQuote coin

    Request Example

    POST /v5/spot-lever-token/redeem HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672296416024
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "ltCoin": "EOS3L",
    "quantity": "150",
    "serialNo": "redeem-001"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "execAmt": "",
    "execQty": "150",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "2",
    "quantity": "",
    "redeemId": "2619",
    "serialNo": "redeem-001",
    "valueCoin": "EOS3L"
    },
    "retExtInfo": {},
    "time": 1672296417363
    }
    - + \ No newline at end of file diff --git a/v5/market/delivery-price.html b/v5/market/delivery-price.html index 8bcc4e1e2b..62b1c2f83c 100644 --- a/v5/market/delivery-price.html +++ b/v5/market/delivery-price.html @@ -4,13 +4,13 @@ Get Delivery Price | Bybit API Documentation - +

    Get Delivery Price

    Get the delivery price.

    Covers: USDC futures / Inverse futures / Option

    HTTP Request

    GET /v5/market/delivery-price

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, inverse, option
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Default: BTC. valid for option only
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > deliveryPricestringDelivery price
    > deliveryTimestringDelivery timestamp (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/market/delivery-price?category=option&symbol=ETH-26DEC22-1400-C HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "category": "option",
    "nextPageCursor": "",
    "list": [
    {
    "symbol": "ETH-26DEC22-1400-C",
    "deliveryPrice": "1220.728594450",
    "deliveryTime": "1672041600000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672055336993
    }
    - + \ No newline at end of file diff --git a/v5/market/history-fund-rate.html b/v5/market/history-fund-rate.html index ade34afa75..3699ee8e8d 100644 --- a/v5/market/history-fund-rate.html +++ b/v5/market/history-fund-rate.html @@ -4,13 +4,13 @@ Get Funding Rate History | Bybit API Documentation - +

    Get Funding Rate History

    Query for historical funding rates. Each symbol has a different funding interval. For example, if the interval is 8 hours and the current time is UTC 12, then it returns the last funding rate, which settled at UTC 8.

    To query the funding rate interval, please refer to the instruments-info endpoint.

    Covers: USDT and USDC perpetual / Inverse perpetual

    tip
    • Passing only startTime returns an error.
    • Passing only endTime returns 200 records up till endTime.
    • Passing neither returns 200 records up till the current time.

    HTTP Request

    GET /v5/market/funding/history

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,inverse
    symboltruestringSymbol name
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > fundingRatestringFunding rate
    > fundingRateTimestampstringFunding rate timestamp (ms)

    Request Example

    GET /v5/market/funding/history?category=linear&symbol=ETHPERP&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1672041600000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672051897447
    }
    - + \ No newline at end of file diff --git a/v5/market/index-kline.html b/v5/market/index-kline.html index 7f57a04236..c4bd303f47 100644 --- a/v5/market/index-kline.html +++ b/v5/market/index-kline.html @@ -4,13 +4,13 @@ Get Index Price Kline | Bybit API Documentation - +

    Get Index Price Kline

    Query for historical index price klines. Charts are returned in groups based on the requested interval.

    Covers: USDT perpetual / USDC contract / Inverse contract

    HTTP Request

    GET /v5/market/index-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,inverse
    symboltruestringSymbol name
    intervaltruestringKline interval. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseintegerThe start timestamp (ms)
    endfalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    listarray
    • An string array of individual candle
    • Sort in reverse by startTime
    > list[0]: startTimestringStart time of the candle (ms)
    > list[1]: openPricestringOpen price
    > list[2]: highPricestringHighest price
    > list[3]: lowPricestringLowest price
    > list[4]: closePricestringClose price. Is the last traded price when the candle is not closed

    Request Example

    GET /v5/market/index-price-kline?category=inverse&symbol=BTCUSDZ22&interval=1&start=1670601600000&end=1670608800000&limit=2 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDZ22",
    "category": "inverse",
    "list": [
    [
    "1670608800000",
    "17167.00",
    "17167.00",
    "17161.90",
    "17163.07"
    ],
    [
    "1670608740000",
    "17166.54",
    "17167.69",
    "17165.42",
    "17167.00"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672026471128
    }
    - + \ No newline at end of file diff --git a/v5/market/instrument.html b/v5/market/instrument.html index 839f02e98a..33ec881fe8 100644 --- a/v5/market/instrument.html +++ b/v5/market/instrument.html @@ -4,13 +4,13 @@ Get Instruments Info | Bybit API Documentation - +

    Get Instruments Info

    Query for the instrument specification of online trading pairs.

    Covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option

    caution
    • Spot does not support pagination, so limit, cursor are invalid.
    • When query by baseCoin, regardless of category=linear or inverse, the result will have USDT perpetual, USDC contract and Inverse contract symbols.

    HTTP Request

    GET /v5/market/instruments-info

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot,linear,inverse,option
    symbolfalsestringSymbol name
    statusfalsestringSymbol status filter
    • spot/linear/inverse has Trading only
    baseCoinfalsestringBase coin. linear,inverse,option only
  • For option, it returns BTC by default
  • limitfalseintegerLimit for data size per page. [1, 1000]. Default: 500
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringCursor. Used to pagination
    listarrayObject
    > symbolstringSymbol name
    > contractTypestringContract type
    > statusstringInstrument status
    > baseCoinstringBase coin
    > quoteCoinstringQuote coin
    > launchTimestringLaunch timestamp (ms)
    > deliveryTimestringDelivery timestamp (ms)
    > deliveryFeeRatestringDelivery fee rate
    > priceScalestringPrice scale
    > leverageFilterObjectLeverage attributes
    >> minLeveragestringMinimum leverage
    >> maxLeveragestringMaximum leverage
    >> leverageStepstringThe step to increase/reduce leverage
    > priceFilterObjectPrice attributes
    >> minPricestringMinimum order price
    >> maxPricestringMaximum order price
    >> tickSizestringThe step to increase/reduce order price
    > lotSizeFilterObjectSize attributes
    >> maxOrderQtystringMaximum order quantity
    >> minOrderQtystringMinimum order quantity
    >> qtyStepstringThe step to increase/reduce order quantity
    >> postOnlyMaxOrderQtystringMaximum order qty for PostOnly order
    > unifiedMarginTradebooleanWhether to support unified margin trade
    > fundingIntervalintegerFunding interval (minute)
    > settleCoinstringSettle coin
    > copyTradingstringCopy trade symbol or not

    Request Example

    GET /v5/market/instruments-info?category=linear&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "BTCUSDT",
    "contractType": "LinearPerpetual",
    "status": "Trading",
    "baseCoin": "BTC",
    "quoteCoin": "USDT",
    "launchTime": "1585526400000",
    "deliveryTime": "0",
    "deliveryFeeRate": "",
    "priceScale": "2",
    "leverageFilter": {
    "minLeverage": "1",
    "maxLeverage": "100.00",
    "leverageStep": "0.01"
    },
    "priceFilter": {
    "minPrice": "0.50",
    "maxPrice": "999999.00",
    "tickSize": "0.50"
    },
    "lotSizeFilter": {
    "maxOrderQty": "100.000",
    "minOrderQty": "0.001",
    "qtyStep": "0.001",
    "postOnlyMaxOrderQty": "1000.000"
    },
    "unifiedMarginTrade": true,
    "fundingInterval": 480,
    "settleCoin": "USDT"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672712495660
    }
    - + \ No newline at end of file diff --git a/v5/market/insurance.html b/v5/market/insurance.html index defdc55590..bed1fe8d40 100644 --- a/v5/market/insurance.html +++ b/v5/market/insurance.html @@ -4,13 +4,13 @@ Get Insurance | Bybit API Documentation - +

    Get Insurance

    Query for Bybit insurance pool data (BTC/USDT/USDC etc). The data is updated every 24 hours.

    HTTP Request

    GET /v5/market/insurance

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringcoin. Default: return all insurance coins

    Response Parameters

    ParameterTypeComments
    updatedTimestringData updated time (ms)
    listarrayObject
    > coinstringCoin
    > balancestringBalance
    > valuestringUSD value

    Request Example

    GET /v5/market/insurance?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "updatedTime": "1672012800000",
    "list": [
    {
    "coin": "ETH",
    "balance": "0.00187332",
    "value": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672053931991
    }
    - + \ No newline at end of file diff --git a/v5/market/iv.html b/v5/market/iv.html index 980d18ae67..7f53cf8819 100644 --- a/v5/market/iv.html +++ b/v5/market/iv.html @@ -4,13 +4,13 @@ Get Historical Volatility | Bybit API Documentation - +

    Get Historical Volatility

    Query option historical volatility

    Covers: Option

    info
    • The data is hourly.
    • If both startTime and endTime are not specified, it will return the most recent 1 hours worth of data.
    • startTime and endTime are a pair of params. Either both are passed or they are not passed at all.
    • This endpoint can query the last 2 years worth of data, but make sure [endTime - startTime] <= 30 days.

    HTTP Request

    GET /v5/market/historical-volatility

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. option
    baseCoinfalsestringBase coin. Default: return BTC data
    periodfalseintegerPeriod. If not specified, it will return data with a 7-day average by default
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > periodintegerPeriod
    > valuestringVolatility
    > timestringTimestamp (ms)

    Request Example

    GET /v5/market/historical-volatility?category=option&baseCoin=ETH&period=30 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "category": "option",
    "result": [
    {
    "period": 30,
    "value": "0.45024716",
    "time": "1672052400000"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/market/kline.html b/v5/market/kline.html index ccbf3b324a..faf111b1f7 100644 --- a/v5/market/kline.html +++ b/v5/market/kline.html @@ -4,13 +4,13 @@ Get Kline | Bybit API Documentation - +

    Get Kline

    Query for historical klines (also known as candles/candlesticks). Charts are returned in groups based on the requested interval.

    Covers: Spot / USDT perpetual / USDC contract / Inverse contract

    HTTP Request

    GET /v5/market/kline

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot,linear,inverse
    symboltruestringSymbol name
    intervaltruestringKline interval. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseintegerThe start timestamp (ms)
    endfalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    listarray
    • An string array of individual candle
    • Sort in reverse by startTime
    > list[0]: startTimestringStart time of the candle (ms)
    > list[1]: openPricestringOpen price
    > list[2]: highPricestringHighest price
    > list[3]: lowPricestringLowest price
    > list[4]: closePricestringClose price. Is the last traded price when the candle is not closed
    > list[5]: volumestringTrade volume. Unit of contract: pieces of contract. Unit of spot: quantity of coins
    > list[6]: turnoverstringTurnover. Unit of figure: quantity of quota coin

    Request Example

    GET /v5/market/kline?category=inverse&symbol=BTCUSD&interval=60&start=1670601600000&end=1670608800000 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    [
    "1670608800000",
    "17071",
    "17073",
    "17027",
    "17055.5",
    "268611",
    "15.74462667"
    ],
    [
    "1670605200000",
    "17071.5",
    "17071.5",
    "17061",
    "17071",
    "4177",
    "0.24469757"
    ],
    [
    "1670601600000",
    "17086.5",
    "17088",
    "16978",
    "17071.5",
    "6356",
    "0.37288112"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672025956592
    }
    - + \ No newline at end of file diff --git a/v5/market/long-short-ratio.html b/v5/market/long-short-ratio.html index 903ceba718..ba90a186fa 100644 --- a/v5/market/long-short-ratio.html +++ b/v5/market/long-short-ratio.html @@ -4,13 +4,13 @@ Get Long Short Ratio | Bybit API Documentation - +

    Get Long Short Ratio

    HTTP Request

    GET /v5/market/account-ratio

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear(USDT Perpetual only),inverse
    symboltruestringSymbol name
    periodtruestringData recording period. 5min, 15min, 30min, 1h, 4h, 1d
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 50

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol name
    > buyRatiostringThe ratio of users with net long position
    > sellRatiostringThe ratio of users with net short position
    > timestampstringTimestamp (ms)

    Request Example

    GET /v5/market/account-ratio?category=linear&symbol=BTCUSDT&period=1d&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "buyRatio": "0.5777",
    "sellRatio": "0.4223",
    "timestamp": "1695772800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1695785131028
    }
    - + \ No newline at end of file diff --git a/v5/market/mark-kline.html b/v5/market/mark-kline.html index b001b7a538..bea87e8cc1 100644 --- a/v5/market/mark-kline.html +++ b/v5/market/mark-kline.html @@ -4,13 +4,13 @@ Get Mark Price Kline | Bybit API Documentation - +

    Get Mark Price Kline

    Query for historical mark price klines. Charts are returned in groups based on the requested interval.

    Covers: USDT perpetual / USDC contract / Inverse contract

    HTTP Request

    GET /v5/market/mark-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,inverse
    symboltruestringSymbol name
    intervaltruestringKline interval. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseintegerThe start timestamp (ms)
    endfalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    listarray
    • An string array of individual candle
    • Sort in reverse by startTime
    > list[0]: startTimestringStart time of the candle (ms)
    > list[1]: openPricestringOpen price
    > list[2]: highPricestringHighest price
    > list[3]: lowPricestringLowest price
    > list[4]: closePricestringClose price. Is the last traded price when the candle is not closed

    Request Example

    GET /v5/market/mark-price-kline?category=linear&symbol=BTCUSDT&interval=15&start=1670601600000&end=1670608800000&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "linear",
    "list": [
    [
    "1670608800000",
    "17164.16",
    "17164.16",
    "17121.5",
    "17131.64"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672026361839
    }
    - + \ No newline at end of file diff --git a/v5/market/open-interest.html b/v5/market/open-interest.html index e03a64d26a..325a991d03 100644 --- a/v5/market/open-interest.html +++ b/v5/market/open-interest.html @@ -4,13 +4,13 @@ Get Open Interest | Bybit API Documentation - +

    Get Open Interest

    Get the open interest of each symbol.

    Covers: USDT perpetual / USDC contract / Inverse contract

    info
    • Returns single side data
    • The upper limit time you can query is the launch time of the symbol.

    HTTP Request

    GET /v5/market/open-interest

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,inverse
    symboltruestringSymbol name
    intervalTimetruestringInterval time. 5min,15min,30min,1h,4h,1d
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 50
    cursorfalsestringCursor. Used to paginate

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    listarrayObject
    > openIntereststringOpen interest
    > timestampstringThe timestamp (ms)
    nextPageCursorstringUsed to paginate

    Request Example

    GET /v5/market/open-interest?category=inverse&symbol=BTCUSD&intervalTime=5min&startTime=1669571100000&endTime=1669571400000 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    {
    "openInterest": "461134384.00000000",
    "timestamp": "1669571400000"
    },
    {
    "openInterest": "461134292.00000000",
    "timestamp": "1669571100000"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672053548579
    }
    - + \ No newline at end of file diff --git a/v5/market/orderbook.html b/v5/market/orderbook.html index af06e39945..8aa216ed43 100644 --- a/v5/market/orderbook.html +++ b/v5/market/orderbook.html @@ -4,13 +4,13 @@ Get Orderbook | Bybit API Documentation - +

    Get Orderbook

    Query for orderbook depth data.

    Covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option

    • future: 200-level of orderbook data
    • spot: 50-level of orderbook data
    • option: 25-level of orderbook data
    tip

    The response is in the snapshot format.

    HTTP Request

    GET /v5/market/orderbook

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot, linear, inverse, option
    symboltruestringSymbol name
    limitfalseintegerLimit size for each bid and ask
    • spot: [1, 200]. Default: 1.
    • linear&inverse: [1, 200]. Default: 25.
    • option: [1, 25]. Default: 1.

    Response Parameters

    ParameterTypeComments
    sstringSymbol name
    barrayBid, buyer. Sort by price desc
    > b[0]stringBid price
    > b[1]stringBid size
    aarrayAsk, seller. Order by price asc
    > a[0]stringAsk price
    > a[1]stringAsk size
    tsintegerThe timestamp (ms) that the system generates the data
    uintegerUpdate ID, is always in sequence
    • For future, it is corresponding to u in the wss 200-level orderbook
    • For spot, it is corresponding to u in the wss 50-level orderbook

    Request Example

    GET /v5/market/orderbook?category=spot&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "s": "BTCUSDT",
    "a": [
    [
    "16638.64",
    "0.008479"
    ]
    ],
    "b": [
    [
    "16638.27",
    "0.305749"
    ]
    ],
    "ts": 1672765737733,
    "u": 5277055
    },
    "retExtInfo": {},
    "time": 1672765737734
    }
    - + \ No newline at end of file diff --git a/v5/market/preimum-index-kline.html b/v5/market/preimum-index-kline.html index 3dd76076f6..9bc3340e14 100644 --- a/v5/market/preimum-index-kline.html +++ b/v5/market/preimum-index-kline.html @@ -4,13 +4,13 @@ Get Premium Index Price Kline | Bybit API Documentation - +

    Get Premium Index Price Kline

    Query for historical premium index klines. Charts are returned in groups based on the requested interval.

    Covers: USDT and USDC perpetual

    HTTP Request

    GET /v5/market/premium-index-price-kline

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear
    symboltruestringSymbol name
    intervaltruestringKline interval
    startfalseintegerThe start timestamp (ms)
    endfalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 1000]. Default: 200

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    listarray
    • An string array of individual candle
    • Sort in reverse by start
    > list[0]stringStart time of the candle (ms)
    > list[1]stringOpen price
    > list[2]stringHighest price
    > list[3]stringLowest price
    > list[4]stringClose price. Is the last traded price when the candle is not closed

    Request Example

    GET /v5/market/premium-index-price-kline?category=linear&symbol=BTCUSDT&interval=D&start=1652112000000&end=1652544000000 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "linear",
    "list": [
    [
    "1652486400000",
    "-0.000587",
    "-0.000344",
    "-0.000480",
    "-0.000344"
    ],
    [
    "1652400000000",
    "-0.000989",
    "-0.000561",
    "-0.000587",
    "-0.000587"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672765216291
    }
    - + \ No newline at end of file diff --git a/v5/market/recent-trade.html b/v5/market/recent-trade.html index beccbcb8fd..7559efd3fd 100644 --- a/v5/market/recent-trade.html +++ b/v5/market/recent-trade.html @@ -4,13 +4,13 @@ Get Public Recent Trading History | Bybit API Documentation - +

    Get Public Recent Trading History

    Query recent public trading data in Bybit.

    Covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option

    You can download archived historical trades here:

    HTTP Request

    GET /v5/market/recent-trade

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot,linear,inverse,option
    symbolfalsestringSymbol name
    • required for spot/linear/inverse
    • optional for option
    baseCoinfalsestringBase coin. For option only. If not passed, return BTC data by default
    optionTypefalsestringOption type. Call or Put. For option only
    limitfalseintegerLimit for data size per page.
    • spot: [1,60], default: 60.
    • others: [1,1000], default: 500

    Response Parameters

    ParameterTypeComments
    categorystringProducts category
    listarrayObject
    > execIdstringExecution ID
    > symbolstringSymbol name
    > pricestringTrade price
    > sizestringTrade size
    > sidestringSide of taker Buy, Sell
    > timestringTrade time (ms)
    > isBlockTradebooleanWhether the trade is block trade

    Request Example

    GET /v5/market/recent-trade?category=spot&symbol=BTCUSDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "spot",
    "list": [
    {
    "execId": "2100000000007764263",
    "symbol": "BTCUSDT",
    "price": "16618.49",
    "size": "0.00012",
    "side": "Buy",
    "time": "1672052955758",
    "isBlockTrade": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672053054358
    }
    - + \ No newline at end of file diff --git a/v5/market/risk-limit.html b/v5/market/risk-limit.html index 2a588b3c96..9869ee3f50 100644 --- a/v5/market/risk-limit.html +++ b/v5/market/risk-limit.html @@ -4,13 +4,13 @@ Get Risk Limit | Bybit API Documentation - +

    Get Risk Limit

    Query for the risk limit.

    Covers: USDT perpetual / USDC contract / Inverse contract

    HTTP Request

    GET /v5/market/risk-limit

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear,inverse
    symbolfalsestringSymbol name

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > idintegerRisk ID
    > symbolstringSymbol name
    > riskLimitValuestringPosition limit
    > maintenanceMarginnumberMaintain margin rate
    > initialMarginnumberInitial margin rate
    > isLowestRiskinteger1: true, 0: false
    > maxLeveragestringAllowed max leverage

    Request Example

    GET /v5/market/risk-limit?category=inverse&symbol=BTCUSD HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "id": 1,
    "symbol": "BTCUSD",
    "riskLimitValue": "150",
    "maintenanceMargin": "0.5",
    "initialMargin": "1",
    "isLowestRisk": 1,
    "maxLeverage": "100.00"
    },
    ....
    ]
    },
    "retExtInfo": {},
    "time": 1672054488010
    }
    - + \ No newline at end of file diff --git a/v5/market/tickers.html b/v5/market/tickers.html index 0e20622e26..32dac2ca81 100644 --- a/v5/market/tickers.html +++ b/v5/market/tickers.html @@ -4,13 +4,13 @@ Get Tickers | Bybit API Documentation - +

    Get Tickers

    Query for the latest price snapshot, best bid/ask price, and trading volume in the last 24 hours.

    Covers: Spot / USDT perpetual / USDC contract / Inverse contract / Option

    tip

    If category=option, symbol or baseCoin must be passed.

    HTTP Request

    GET /v5/market/tickers

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot,linear,inverse,option
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. For option only
    expDatefalsestringExpiry date. e.g., 25DEC22. For option only

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > lastPricestringLast price
    > indexPricestringIndex price
    > markPricestringMark price
    > prevPrice24hstringMarket price 24 hours ago
    > price24hPcntstringPercentage change of market price relative to 24h
    > highPrice24hstringThe highest price in the last 24 hours
    > lowPrice24hstringThe lowest price in the last 24 hours
    > prevPrice1hstringMarket price an hour ago
    > openIntereststringOpen interest size
    > openInterestValuestringOpen interest value
    > turnover24hstringTurnover for 24h
    > volume24hstringVolume for 24h
    > fundingRatestringFunding rate
    > nextFundingTimestringNext funding time (ms)
    > predictedDeliveryPricestringPredicated delivery price. It has value when 30 min before delivery
    > basisRatestringBasis rate
    > basisstringBasis
    > deliveryFeeRatestringDelivery fee rate
    > deliveryTimestringDelivery timestamp (ms)
    > ask1SizestringBest ask size
    > bid1PricestringBest bid price
    > ask1PricestringBest ask price
    > bid1SizestringBest bid size

    Request Example

    GET /v5/market/tickers?category=inverse&symbol=BTCUSD HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "symbol": "BTCUSD",
    "lastPrice": "16597.00",
    "indexPrice": "16598.54",
    "markPrice": "16596.00",
    "prevPrice24h": "16464.50",
    "price24hPcnt": "0.008047",
    "highPrice24h": "30912.50",
    "lowPrice24h": "15700.00",
    "prevPrice1h": "16595.50",
    "openInterest": "373504107",
    "openInterestValue": "22505.67",
    "turnover24h": "2352.94950046",
    "volume24h": "49337318",
    "fundingRate": "-0.001034",
    "nextFundingTime": "1672387200000",
    "predictedDeliveryPrice": "",
    "basisRate": "",
    "deliveryFeeRate": "",
    "deliveryTime": "0",
    "ask1Size": "1",
    "bid1Price": "16596.00",
    "ask1Price": "16597.50",
    "bid1Size": "1",
    "basis": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672376496682
    }
    - + \ No newline at end of file diff --git a/v5/market/time.html b/v5/market/time.html index 6c35c50298..36787e87f4 100644 --- a/v5/market/time.html +++ b/v5/market/time.html @@ -4,13 +4,13 @@ Get Bybit Server Time | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/v5/order/amend-order.html b/v5/order/amend-order.html index b9848677b4..5bb08bc471 100644 --- a/v5/order/amend-order.html +++ b/v5/order/amend-order.html @@ -4,7 +4,7 @@ Amend Order | Bybit API Documentation - + @@ -13,7 +13,7 @@ Classic account covers: Spot / USDT perpetual / Inverse contract

    important

    You can only modify unfilled or partially filled orders.

    Websocket logic for Spot

    Classic account: if the original Spot order is a PostOnly order, and after the modification, the order becomes a taker order, then you will receive orderStatus="New" ws message first, followed by orderStatus="Rejected" ws message.

    Unified account: if the original Spot order is a PostOnly order, and after the modification, the order becomes a taker order, then you will directly receive orderStatus="Rejected" ws message.

    HTTP Request

    POST /v5/order/amend

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse, spot, option
    • Classic account: linear, inverse, spot
    symboltruestringSymbol name
    orderIdfalsestringOrder ID. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order ID. Either orderId or orderLinkId is required
    orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed
    triggerPricefalsestring
    • For Perps & Futures, it is the conditional order trigger price. If you expect the price to rise to trigger your conditional order, make sure:
      triggerPrice > market price
      Else, triggerPrice < market price
    • For spot, it is the TP/SL and Conditional order trigger price
    qtyfalsestringOrder quantity after modification. Do not pass it if not modify the qty
    pricefalsestringOrder price after modification. Do not pass it if not modify the price
    tpslModefalsestringTP/SL mode
    • Full: entire position for TP/SL. Then, tpOrderType or slOrderType must be Market
    • Partial: partial position tp/sl. Limit TP/SL order are supported. Note: When create limit tp/sl, tpslMode is required and it must be Partial
    Valid for linear & inverse
    takeProfitfalsestringTake profit price after modification. If pass "0", it means cancel the existing take profit of the order. Do not pass it if you do not want to modify the take profit
    stopLossfalsestringStop loss price after modification. If pass "0", it means cancel the existing stop loss of the order. Do not pass it if you do not want to modify the stop loss
    tpTriggerByfalsestringThe price type to trigger take profit. When set a take profit, this param is required if no initial value for the order
    slTriggerByfalsestringThe price type to trigger stop loss. When set a take profit, this param is required if no initial value for the order
    triggerByfalsestringTrigger price type
    tpLimitPricefalsestringLimit order price when take profit is triggered. Only working when original order sets partial limit tp/sl
    slLimitPricefalsestringLimit order price when stop loss is triggered. Only working when original order sets partial limit tp/sl

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order ID

    Request Example

    POST /v5/order/amend HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672217108106
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "ETHPERP",
    "orderLinkId": "linear-004",
    "triggerPrice": "1145",
    "qty": "0.15",
    "price": "1050",
    "takeProfit": "0",
    "stopLoss": "0"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "orderLinkId": "linear-004"
    },
    "retExtInfo": {},
    "time": 1672217093461
    }
    - + \ No newline at end of file diff --git a/v5/order/batch-amend.html b/v5/order/batch-amend.html index 5a0c100d37..e59d49431b 100644 --- a/v5/order/batch-amend.html +++ b/v5/order/batch-amend.html @@ -4,13 +4,13 @@ Batch Amend Order | Bybit API Documentation - +

    Batch Amend Order

    Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)

    tip

    This endpoint allows you to amend more than one open order in a single request.

    • You can modify unfilled or partially filled orders. Conditional orders are not supported.
    • A maximum of 20 orders (option) & 10 orders (linear) can be amended per request.

    HTTP Request

    POST /v5/order/amend-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    requesttruearrayObject
    > symboltruestringSymbol name
    > orderIdfalsestringOrder ID. Either orderId or orderLinkId is required
    > orderLinkIdfalsestringUser customised order ID. Either orderId or orderLinkId is required
    > orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed
    > triggerPricefalsestringIf you expect the price to rise to trigger your conditional order, make sure:
    triggerPrice > market price
    Else, triggerPrice < market price
    > qtyfalsestringOrder quantity after modification. Do not pass it if not modify the qty
    > pricefalsestringOrder price after modification. Do not pass it if not modify the price
    > tpslModefalsestringTP/SL mode
    • Full: entire position for TP/SL. Then, tpOrderType or slOrderType must be Market
    • Partial: partial position tp/sl. Limit TP/SL order are supported. Note: When create limit tp/sl, tpslMode is required and it must be Partial
    Valid for linear
    > takeProfitfalsestringTake profit price after modification. If pass "0", it means cancel the existing take profit of the order. Do not pass it if you do not want to modify the take profit
    > stopLossfalsestringStop loss price after modification. If pass "0", it means cancel the existing stop loss of the order. Do not pass it if you do not want to modify the stop loss
    > tpTriggerByfalsestringThe price type to trigger take profit. When set a take profit, this param is required if no initial value for the order
    > slTriggerByfalsestringThe price type to trigger stop loss. When set a take profit, this param is required if no initial value for the order
    > triggerByfalsestringTrigger price type
    > tpLimitPricefalsestringLimit order price when take profit is triggered. Only working when original order sets partial limit tp/sl
    > slLimitPricefalsestringLimit order price when stop loss is triggered. Only working when original order sets partial limit tp/sl

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProduct type
    >> symbolstringSymbol name
    >> orderIdstringOrder ID
    >> orderLinkIdstringUser customised order ID
    retExtInfoObject
    > listarrayObject
    >> codenumberSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /v5/order/amend-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672222935987
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "qty": null,
    "price": null,
    "orderIv": "6.8",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2"
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "qty": null,
    "price": "650",
    "orderIv": null,
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52"
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": ""
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": ""
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672222808060
    }
    - + \ No newline at end of file diff --git a/v5/order/batch-cancel.html b/v5/order/batch-cancel.html index c07c151905..29069319ee 100644 --- a/v5/order/batch-cancel.html +++ b/v5/order/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +

    Batch Cancel Order

    This endpoint allows you to cancel more than one open order in a single request.

    Covers: Option (UTA, UTA Pro) / USDT Perpetual, UDSC Perpetual, USDC Futures (UTA Pro)

    important
    • You must specify orderId or orderLinkId.
    • If orderId and orderLinkId is not matched, the system will process orderId first.
    • You can cancel unfilled or partially filled orders.
    • A maximum of 20 orders (option) & 10 orders (linear) can be cancelled per request.

    HTTP Request

    POST /v5/order/cancel-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    requesttruearrayObject
    > symboltruestringSymbol name
    > orderIdfalsestringOrder ID. Either orderId or orderLinkId is required
    > orderLinkIdfalsestringUser customised order ID. Either orderId or orderLinkId is required

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProduct type
    >> symbolstringSymbol name
    >> orderIdstringOrder ID
    >> orderLinkIdstringUser customised order ID
    retExtInfoObject
    > listarrayObject
    >> codenumberSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /v5/order/cancel-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672223356634
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2"
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52"
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": "option-test-001"
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": "option-test-001"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672223357252
    }
    - + \ No newline at end of file diff --git a/v5/order/batch-place.html b/v5/order/batch-place.html index 39f75fc1fc..0178501484 100644 --- a/v5/order/batch-place.html +++ b/v5/order/batch-place.html @@ -4,7 +4,7 @@ Batch Place Order | Bybit API Documentation - + @@ -15,7 +15,7 @@ The first list indicates whether or not the order creation was successful and the second list details the created order information. The structure of the two lists are completely consistent.
    info
    • Check the rate limit instruction when category=linear here

    • Risk control limit notice:
      Bybit will monitor on your API requests. When the total number of orders of a single user (aggregated the number of orders across main account and sub-accounts) within a day (UTC 0 - UTC 24) exceeds a certain upper limit, the platform will reserve the right to remind, warn, and impose necessary restrictions. Customers who use API default to acceptance of these terms and have the obligation to cooperate with adjustments.

    HTTP Request

    POST /v5/order/create-batch

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, option
    requesttruearrayObject
    > symboltruestringSymbol name
    > sidetruestringBuy, Sell
    > orderTypetruestringMarket, Limit
    > qtytruestringOrder quantity
  • In particular, for linear, if you pass qty="0", you can close the whole position of current symbol
  • > pricefalsestringOrder price
    • Market order will ignore this field
    • Please check the min price and price precision from instrument info endpoint
    • If you have position, price needs to be better than liquidation price
    > triggerDirectionfalseintegerConditional order param. Used to identify the expected direction of the conditional order.
    • 1: triggered when market price rises to triggerPrice
    • 2: triggered when market price falls to triggerPrice
    Valid for linear
    > triggerPricefalsestring
    • For futures, it is the conditional order trigger price. If you expect the price to rise to trigger your conditional order, make sure:
      triggerPrice > market price
      Else, triggerPrice < market price
    > triggerByfalsestringConditional order param. Trigger price type. LastPrice, IndexPrice, MarkPrice
    > orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed. orderIv has a higher priority when price is passed as well
    > timeInForcefalsestringTime in force
    • Market order will use IOC directly
    • If not passed, GTC is used by default
    > positionIdxfalseintegerUsed to identify positions in different position modes. Under hedge-mode, this param is required (USDT perps have hedge mode)
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side
    > orderLinkIdfalsestringUser customised order ID. A max of 36 characters. Combinations of numbers, letters (upper and lower cases), dashes, and underscores are supported.
    Futures & Perps: orderLinkId rules:
    • optional param
    • always unique
    • option orderLinkId rules:
    • required param
    • always unique
    > takeProfitfalsestringTake profit price, valid for linear
    > stopLossfalsestringStop loss price, valid for linear
    > tpTriggerByfalsestringThe price type to trigger take profit. MarkPrice, IndexPrice, default: LastPrice.
    Valid for linear
    > slTriggerByfalsestringThe price type to trigger stop loss. MarkPrice, IndexPrice, default: LastPrice
    Valid for linear
    > reduceOnlyfalsebooleanWhat is a reduce-only order? true means your position can only reduce in size if this order is triggered.
    • You must specify it as true when you are about to close/reduce the position
    • When reduceOnly is true, take profit/stop loss cannot be set
    Valid for linear, & option
    > closeOnTriggerfalsebooleanWhat is a close on trigger order? For a closing order. It can only reduce your position, not increase it. If the account has insufficient available balance when the closing order is triggered, then other active orders of similar contracts will be cancelled or reduced. It can be used to ensure your stop loss reduces your position regardless of current available margin.
    Valid for linear
    > smpTypefalsestringSmp execution type. What is SMP?
    > mmpfalsebooleanMarket maker protection. option only. true means set the order as a market maker protection order. What is mmp?
    > tpslModefalsestringTP/SL mode
    • Full: entire position for TP/SL. Then, tpOrderType or slOrderType must be Market
    • Partial: partial position tp/sl. Limit TP/SL order are supported. Note: When create limit tp/sl, tpslMode is required and it must be Partial
    Valid for linear
    > tpLimitPricefalsestringThe limit order price when take profit price is triggered. Only works when tpslMode=Partial and tpOrderType=Limit
    Valid for linear
    > slLimitPricefalsestringThe limit order price when stop loss price is triggered. Only works when tpslMode=Partial and slOrderType=Limit
    Valid for linear
    > tpOrderTypefalsestringThe order type when take profit is triggered. Market(default), Limit. For tpslMode=Full, it only supports tpOrderType=Market
    Valid for linear
    > slOrderTypefalsestringThe order type when stop loss is triggered. Market(default), Limit. For tpslMode=Full, it only supports slOrderType=Market
    Valid for linear

    Response Parameters

    ParameterTypeComments
    resultObject
    > listarrayObject
    >> categorystringProduct type
    >> symbolstringSymbol name
    >> orderIdstringOrder ID
    >> orderLinkIdstringUser customised order ID
    >> createAtstringOrder created time (ms)
    retExtInfoObject
    > listarrayObject
    >> codenumberSuccess/error code
    >> msgstringSuccess/error message

    Request Example

    POST /v5/order/create-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672222064519
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "1",
    "price": null,
    "orderIv": "6",
    "timeInForce": "GTC",
    "orderLinkId": "option-test-001",
    "mmp": false,
    "reduceOnly": false
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "orderType": "Limit",
    "side": "Sell",
    "qty": "2",
    "price": "700",
    "iv": null,
    "timeInForce": "GTC",
    "orderLinkId": "option-test-001",
    "mmp": false,
    "reduceOnly": false
    }
    ]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": "option-test-001",
    "createAt": "1672222047683"
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": "option-test-001",
    "createAt": "1672222047683"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672222047684
    }
    - + \ No newline at end of file diff --git a/v5/order/cancel-all.html b/v5/order/cancel-all.html index 8e280f1171..bd07d2d93f 100644 --- a/v5/order/cancel-all.html +++ b/v5/order/cancel-all.html @@ -4,7 +4,7 @@ Cancel All Orders | Bybit API Documentation - + @@ -13,7 +13,7 @@ Classic account covers: Spot / USDT perpetual / Inverse contract

    info
    • Support cancel orders by symbol/baseCoin/settleCoin. If you pass multiple of these params, the system will process one of param, which priority is symbol > baseCoin > settleCoin.
    • NOTE: category=option, you can cancel all option open orders without passing any of those three params. However, for linear and inverse, you must specify one of those three params.
    • NOTE: category=spot, you can cancel all spot open orders (normal order by default) without passing other params.
    info

    Spot: Classic account - cancel up to 500 orders; Unified account - no limit
    Futures: Classic account - cancel up to 500 orders; Unified account - cancel up to 500 orders
    Options: Unified account - no limit

    HTTP Request

    POST /v5/order/cancel-all

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symbolfalsestringSymbol name. linear & inverse: Required if not passing baseCoin or settleCoin
    baseCoinfalsestringBase coin
    • linear & inverse(Classic account): If cancel all by baseCoin, it will cancel all linear & inverse orders. Required if not passing symbol or settleCoin
    • linear & inverse(Unified account): If cancel all by baseCoin, it will cancel all corresponding category orders. Required if not passing symbol or settleCoin
    • Classic spot: invalid
    settleCoinfalsestringSettle coin
    • linear & inverse: Required if not passing symbol or baseCoin
    • Does not support spot
    orderFilterfalsestring
    • category=spot, you can pass Order, tpslOrder, StopOrder. If not passed, Order by default
    • category=linear or inverse, you can pass Order, StopOrder. If not passed, all kinds of orders will be cancelled, like active order, conditional order, TP/SL order and trailing stop order
    • category=option, you can pass Order. No matter it is passed or not, always cancel all orders
    stopOrderTypefalsestringStop order type, Stop
  • Only used for category=linear or inverse and orderFilter=StopOrder,you can cancel conditional orders except TP/SL order and Trailing stop orders with this param

  • Response Parameters

    ParameterTypeComments
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID

    Request Example

    POST /v5/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672219779140
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": null,
    "settleCoin": "USDT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "f6a73e1f-39b5-4dee-af21-1460b2e3b27c",
    "orderLinkId": "a001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672219780463
    }
    - + \ No newline at end of file diff --git a/v5/order/cancel-order.html b/v5/order/cancel-order.html index b2cf6cf987..3058c099af 100644 --- a/v5/order/cancel-order.html +++ b/v5/order/cancel-order.html @@ -4,14 +4,14 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options
    Classic account covers: Spot / USDT perpetual / Inverse contract

    important
    • You must specify orderId or orderLinkId to cancel the order.
    • If orderId and orderLinkId do not match, the system will process orderId first.
    • You can only cancel unfilled or partially filled orders.

    HTTP Request

    POST /v5/order/cancel

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symboltruestringSymbol name
    orderIdfalsestringOrder ID. Either orderId or orderLinkId is required
    orderLinkIdfalsestringUser customised order ID. Either orderId or orderLinkId is required
    orderFilterfalsestringValid for spot only. Order,tpslOrder,StopOrder. If not passed, Order by default

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order ID

    Request Example

    POST /v5/order/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672217376681
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCPERP",
    "orderLinkId": null,
    "orderId":"c6f055d9-7f21-4079-913d-e6523a9cfffa"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "orderLinkId": "linear-004"
    },
    "retExtInfo": {},
    "time": 1672217377164
    }
    - + \ No newline at end of file diff --git a/v5/order/create-order.html b/v5/order/create-order.html index ac869e8aa8..e90f89f24e 100644 --- a/v5/order/create-order.html +++ b/v5/order/create-order.html @@ -4,7 +4,7 @@ Place Order | Bybit API Documentation - + @@ -28,7 +28,7 @@ Customers who use API default to acceptance of these terms and have the obligation to cooperate with adjustments.

    tip

    To margin trade on spot on a normal account, you need to go here to borrow margin first.

    Spot Stop Order

    Spot supports TP/SL order, Conditional order, however, the system logic is different between Classic account and Unified account
    Classic account: When the stop order is created, you will get an order ID. After it is triggered, you will get a new order ID
    Unified account: When the stop order is created, you will get an order ID. After it is triggered, the order ID will not be changed

    HTTP Request

    POST /v5/order/create

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symboltruestringSymbol name
    isLeveragefalseintegerWhether to borrow. Valid for Unified spot only. 0(default): false then spot trading, 1: true then margin trading
    sidetruestringBuy, Sell
    orderTypetruestringMarket, Limit
    qtytruestringOrder quantity.
    • For Spot Market Buy order, please note that qty should be quote curreny amount, and make sure it satisfies quotePrecision in Spot instrument spec
    • For other cases, please make sure the input qty is the multiples of minOrderQty from instrument info endpoint
    • In particular, for Futures & Perps, if you pass qty="0", you can close the whole position of current symbol
    pricefalsestringOrder price
    • Market order will ignore this field
    • Please check the min price and price precision from instrument info endpoint
    • If you have position, price needs to be better than liquidation price
    triggerDirectionfalseintegerConditional order param. Used to identify the expected direction of the conditional order.
    • 1: triggered when market price rises to triggerPrice
    • 2: triggered when market price falls to triggerPrice
    Valid for linear & inverse
    orderFilterfalsestringIf it is not passed, Order by default.
    • Order
    • tpslOrder: Spot TP/SL order, the assets are occupied even before the order is triggered
    • StopOrder: Spot conditional order, the assets will not be occupied until the price of the underlying asset reaches the trigger price, and the required assets will be occupied after the Conditional order is triggered
    Valid for spot only
    triggerPricefalsestring
    • For Perps & Futures, it is the conditional order trigger price. If you expect the price to rise to trigger your conditional order, make sure:
      triggerPrice > market price
      Else, triggerPrice < market price
    • For spot, it is the TP/SL and Conditional order trigger price
    triggerByfalsestringTrigger price type, Conditional order param for Perps & Futures. LastPrice, IndexPrice, MarkPrice
    Valid for linear & inverse
    orderIvfalsestringImplied volatility. option only. Pass the real value, e.g for 10%, 0.1 should be passed. orderIv has a higher priority when price is passed as well
    timeInForcefalsestringTime in force
    • Market order will use IOC directly
    • If not passed, GTC is used by default
    positionIdxfalseintegerUsed to identify positions in different position modes. Under hedge-mode, this param is required (USDT perps & Inverse contracts have hedge mode)
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side
    orderLinkIdfalsestringUser customised order ID. A max of 36 characters. Combinations of numbers, letters (upper and lower cases), dashes, and underscores are supported.
    Futures & Perps: orderLinkId rules:
    • optional param
    • always unique
    • option orderLinkId rules:
    • required param
    • always unique
    takeProfitfalsestringTake profit price, valid for linear & inverse
    stopLossfalsestringStop loss price, valid for linear & inverse
    tpTriggerByfalsestringThe price type to trigger take profit. MarkPrice, IndexPrice, default: LastPrice. Valid for linear & inverse
    slTriggerByfalsestringThe price type to trigger stop loss. MarkPrice, IndexPrice, default: LastPrice. Valid for linear & inverse
    reduceOnlyfalsebooleanWhat is a reduce-only order? true means your position can only reduce in size if this order is triggered.
    • You must specify it as true when you are about to close/reduce the position
    • When reduceOnly is true, take profit/stop loss cannot be set
    Valid for linear, inverse & option
    closeOnTriggerfalsebooleanWhat is a close on trigger order? For a closing order. It can only reduce your position, not increase it. If the account has insufficient available balance when the closing order is triggered, then other active orders of similar contracts will be cancelled or reduced. It can be used to ensure your stop loss reduces your position regardless of current available margin.
    Valid for linear & inverse
    smpTypefalsestringSmp execution type. What is SMP?
    mmpfalsebooleanMarket maker protection. option only. true means set the order as a market maker protection order. What is mmp?
    tpslModefalsestringTP/SL mode
    • Full: entire position for TP/SL. Then, tpOrderType or slOrderType must be Market
    • Partial: partial position tp/sl. Limit TP/SL order are supported. Note: When create limit tp/sl, tpslMode is required and it must be Partial
    Valid for linear & inverse
    tpLimitPricefalsestringThe limit order price when take profit price is triggered. Only works when tpslMode=Partial and tpOrderType=Limit.
    Valid for linear & inverse
    slLimitPricefalsestringThe limit order price when stop loss price is triggered. Only works when tpslMode=Partial and slOrderType=Limit.
    Valid for linear & inverse
    tpOrderTypefalsestringThe order type when take profit is triggered. Market(default), Limit. For tpslMode=Full, it only supports tpOrderType=Market.
    Valid for linear & inverse
    slOrderTypefalsestringThe order type when stop loss is triggered. Market(default), Limit. For tpslMode=Full, it only supports slOrderType=Market.
    Valid for linear & inverse

    Response Parameters

    ParameterTypeComments
    orderIdstringOrder ID
    orderLinkIdstringUser customised order ID

    Request Example

    POST /v5/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672211928338
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    // Spot PostOnly normal order
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","timeInForce":"PostOnly","orderLinkId":"spot-test-01","isLeverage":0,"orderFilter":"Order"}

    // Spot TP/SL order
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","triggerPrice": "15000", "timeInForce":"Limit","orderLinkId":"spot-test-02","isLeverage":0,"orderFilter":"tpslOrder"}

    // Spot margin normal order (UTA)
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","timeInForce":"Limit","orderLinkId":"spot-test-limit","isLeverage":1,"orderFilter":"Order"}

    // Spot Market Buy order, qty is quote currency
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Market","qty":"200","timeInForce":"IOC","orderLinkId":"spot-test-04","isLeverage":0,"orderFilter":"Order"}


    // USDT Perp open long position (one-way mode)
    {"category":"linear","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"1","price":"25000","timeInForce":"GTC","positionIdx":0,"orderLinkId":"usdt-test-01","reduceOnly":false,"takeProfit":"28000","stopLoss":"20000","tpslMode":"Partial","tpOrderType":"Limit","slOrderType":"Limit","tpLimitPrice":"27500","slLimitPrice":"20500"}

    // USDT Perp close long position (one-way mode)
    {"category": "linear", "symbol": "BTCUSDT", "side": "Sell", "orderType": "Limit", "qty": "1", "price": "30000", "timeInForce": "GTC", "positionIdx": 0, "orderLinkId": "usdt-test-02", "reduceOnly": true}

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1321003749386327552",
    "orderLinkId": "spot-test-postonly"
    },
    "retExtInfo": {},
    "time": 1672211918471
    }
    - + \ No newline at end of file diff --git a/v5/order/dcp.html b/v5/order/dcp.html index b0e4e918ba..4fd8684255 100644 --- a/v5/order/dcp.html +++ b/v5/order/dcp.html @@ -4,7 +4,7 @@ Set Disconnect Cancel All | Bybit API Documentation - + @@ -14,7 +14,7 @@ more than 10 (default) seconds and resumes the heartbeat "ping", then the client is in the state of "disconnection protect", all active option orders of the client will be cancelled automatically. If within 10 seconds, the client reconnects and resumes the heartbeat "ping", the timing will be reset and restarted at the next disconnection.

    How to enable DCP

    If you need to turn it on/off, you can contact your client manager for consultation and application. The default time window is 10 seconds.

    Applicable

    Effective for options only.

    tip

    After the request is successfully sent, the system needs a certain time to take effect. It is recommended to query or set again after 10 seconds

    • You can use this endpoint to get your current DCP configuration.
    • Your private websocket connection must subscribe "dcp" topic in order to trigger DCP successfully

    HTTP Request

    POST /v5/order/disconnected-cancel-all

    Request Parameters

    ParameterRequiredTypeComments
    timeWindowtrueintegerDisconnection timing window time. [3, 300], unit: second

    Response Parameters

    None

    Request Example

    POST v5/order/disconnected-cancel-all HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675852742375
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "timeWindow": 40
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/v5/order/open-order.html b/v5/order/open-order.html index ef0673931f..aa68119d69 100644 --- a/v5/order/open-order.html +++ b/v5/order/open-order.html @@ -4,14 +4,14 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    Query unfilled or partially filled orders in real-time. To query older order records, please use the order history interface.

    Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options
    Classic account covers: Spot / USDT perpetual / Inverse contract

    tip
    • It also supports querying filled, cancelled, and rejected orders which occurred in last 10 minutes (check the openOnly param). At most, 500 orders will be returned.
    • You can query by symbol, baseCoin, orderId and orderLinkId, and if you pass multiple params, the system will process them according to this priority: orderId > orderLinkId > symbol > baseCoin.
    • The records are sorted by the createdTime from newest to oldest.
    info

    Classic account spot trade can return open orders only

    HTTP Request

    GET /v5/order/realtime

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symbolfalsestringSymbol name. For linear, either symbol, baseCoin, settleCoin is required
    baseCoinfalsestringBase coin. Supports linear, inverse & option. For option. Return all option open orders if not passed
    settleCoinfalsestringSettle coin
    • linear: either symbol, baseCoin or settleCoin is required
    • spot: invalid
    orderIdfalsestringOrder ID
    orderLinkIdfalsestringUser customised order ID
    openOnlyfalseinteger
    • Unified account & Classic account: 0(default) - query open orders only
    • Unified account - spot / linear / option: 1
      Unified account - inverse & Classic account - linear / inverse: 2
      return cancelled, rejected or totally filled orders by last 10 minutes, A maximum of 500 records are kept under each account. If the Bybit service is restarted due to an update, this part of the data will be cleared and accumulated again, but the order records will still be queried in order history
    • Classic spot: not supported, return open orders only
    orderFilterfalsestringOrder: active order, StopOrder: conditional order for Futures and Spot, tpslOrder: spot TP/SL order, OcoOrder: UTA spot OCO orders only
    • Classic spot: return Order active order by default
    • Others: all kinds of orders by default
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    nextPageCursorstringRefer to the cursor request parameter
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > blockTradeIdstringParadigm block trade ID
    > symbolstringSymbol name
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > isLeveragestringWhether to borrow. Unified spot only. 0: false, 1: true. . Classic spot is not supported, always 0
    > positionIdxintegerPosition index. Used to identify positions in different position modes.
    > orderStatusstringOrder status
    > cancelTypestringCancel type
    > rejectReasonstringReject reason. Classic spot is not supported
    > avgPricestringAverage filled price. If unfilled, it is "0"
    > leavesQtystringThe remaining qty not executed. Classic spot is not supported
    > leavesValuestringThe estimated value not executed. Classic spot is not supported
    > cumExecQtystringCumulative executed order qty
    > cumExecValuestringCumulative executed order value. Classic spot is not supported
    > cumExecFeestringCumulative executed trading fee. Classic spot is not supported
    > timeInForcestringTime in force
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
    > stopOrderTypestringStop order type
    > orderIvstringImplied volatility
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl. Spot does not have this field, and Option returns always ""
    > ocoTriggerTypestringThe trigger type of Spot OCO order.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. Classic spot is not supported
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringThe price type to trigger take profit
    > slTriggerBystringThe price type to trigger stop loss
    > triggerDirectionintegerTrigger direction. 1: rise, 2: fall
    > triggerBystringThe price type of trigger price
    > lastPriceOnCreatedstringLast price when place the order
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    > placeTypestringPlace type, option used. iv, price
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the UID has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)

    Request Example

    GET /v5/order/realtime?symbol=ETHUSDT&category=linear&openOnly=0&limit=1  HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672219525810
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "fd4300ae-7847-404e-b947-b46980a4d140",
    "orderLinkId": "test-000005",
    "blockTradeId": "",
    "symbol": "ETHUSDT",
    "price": "1600.00",
    "qty": "0.10",
    "side": "Buy",
    "isLeverage": "",
    "positionIdx": 1,
    "orderStatus": "New",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_NoError",
    "avgPrice": "0",
    "leavesQty": "0.10",
    "leavesValue": "160",
    "cumExecQty": "0.00",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "timeInForce": "GTC",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "2500.00",
    "stopLoss": "1500.00",
    "tpTriggerBy": "LastPrice",
    "slTriggerBy": "LastPrice",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "placeType": "",
    "createdTime": "1684738540559",
    "updatedTime": "1684738540561"
    }
    ],
    "nextPageCursor": "page_args%3Dfd4300ae-7847-404e-b947-b46980a4d140%26symbol%3D6%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1684765770483
    }
    - + \ No newline at end of file diff --git a/v5/order/order-list.html b/v5/order/order-list.html index 149523bbb1..ceb2690114 100644 --- a/v5/order/order-list.html +++ b/v5/order/order-list.html @@ -4,7 +4,7 @@ Get Order History | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Get Order History

    Query order history. As order creation/cancellation is asynchronous, the data returned from this endpoint may delay. If you want to get real-time order information, you could query this endpoint or rely on the websocket stream (recommended).

    Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options
    Classic account covers: Spot / USDT perpetual / Inverse contract

    info
    • The orders in the last 7 days: supports querying all statuses
    • The orders beyond 7 days: supports querying filled orders
    • You can query by symbol, baseCoin, orderId and orderLinkId, and if you pass multiple params, the system will process them according to this priority: orderId > orderLinkId > symbol > baseCoin.
    tip

    Classic account spot can get final status orders only

    HTTP Request

    GET /v5/order/history

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symbolfalsestringSymbol name
    baseCoinfalsestringBase coin. Unified account - inverse & Classic account does not support this param
    settleCoinfalsestringSettle coin. Unified account - inverse & Classic account does not support this param
    orderIdfalsestringOrder ID
    orderLinkIdfalsestringUser customised order ID
    orderFilterfalsestringOrder: active order, StopOrder: conditional order for Futures and Spot, tpslOrder: spot TP/SL order, OcoOrder: UTA spot OCO orders only
    • Classic spot: return Order active order by default
    • Others: all kinds of orders by default
    orderStatusfalsestring
    • Classic spot: invalid
    • Others: return all status orders if not passed
    startTimefalseintegerThe start timestamp (ms)
    • Classic spot is not supported temporarily
    • startTime and endTime must be passed together
    • If not passed, query the past 7 days data by default
    • For each request, startTime and endTime interval should be less then 7 days
    endTimefalseintegerThe end timestamp (ms)
    • For each request, startTime and endTime interval should be less then 7 days
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > blockTradeIdstringBlock trade ID
    > symbolstringSymbol name
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > isLeveragestringWhether to borrow. Unified spot only. 0: false, 1: true. . Classic spot is not supported, always 0
    > positionIdxintegerPosition index. Used to identify positions in different position modes
    > orderStatusstringOrder status
    > cancelTypestringCancel type
    > rejectReasonstringReject reason. Classic spot is not supported
    > avgPricestringAverage filled price. If unfilled, it is ""
    > leavesQtystringThe remaining qty not executed. Classic spot is not supported
    > leavesValuestringThe estimated value not executed. Classic spot is not supported
    > cumExecQtystringCumulative executed order qty
    > cumExecValuestringCumulative executed order value. Classic spot is not supported
    > cumExecFeestringCumulative executed trading fee. Classic spot is not supported
    > timeInForcestringTime in force
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
  • Block trade Roll Back, Block trade-Limit: Unique enum values for Unified account block trades
  • > stopOrderTypestringStop order type
    > orderIvstringImplied volatility
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl. Spot does not have this field, and Option returns always ""
    > ocoTriggerTypestringThe trigger type of Spot OCO order.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. Classic spot is not supported
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringThe price type to trigger take profit
    > slTriggerBystringThe price type to trigger stop loss
    > triggerDirectionintegerTrigger direction. 1: rise, 2: fall
    > triggerBystringThe price type of trigger price
    > lastPriceOnCreatedstringLast price when place the order
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    > placeTypestringPlace type, option used. iv, price
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the UID has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/order/history?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672221263407
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "14bad3a1-6454-43d8-bcf2-5345896cf74d",
    "orderLinkId": "YLxaWKMiHU",
    "blockTradeId": "",
    "symbol": "BTCUSDT",
    "price": "26864.40",
    "qty": "0.003",
    "side": "Buy",
    "isLeverage": "",
    "positionIdx": 1,
    "orderStatus": "Cancelled",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_PostOnlyWillTakeLiquidity",
    "avgPrice": "0",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "timeInForce": "PostOnly",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "0.00",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "tpslMode": "",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "placeType": "",
    "createdTime": "1684476068369",
    "updatedTime": "1684476068372"
    }
    ],
    "nextPageCursor": "page_token%3D39380%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1684766282976
    }
    - + \ No newline at end of file diff --git a/v5/order/spot-borrow-quota.html b/v5/order/spot-borrow-quota.html index b4e7206352..aac66401aa 100644 --- a/v5/order/spot-borrow-quota.html +++ b/v5/order/spot-borrow-quota.html @@ -4,13 +4,13 @@ Get Borrow Quota (Spot) | Bybit API Documentation - +

    Get Borrow Quota (Spot)

    Query the available balance for Spot trading and Margin trading

    Covers: Spot (Unified Account)

    HTTP Request

    GET /v5/order/spot-borrow-check

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. spot
    symboltruestringSymbol name
    sidetruestringTransaction side. Buy,Sell

    Response Parameters

    ParameterTypeComments
    symbolstringSymbol name
    sidestringSide
    maxTradeQtystringThe maximum base coin qty can be traded
    • If spot margin trade on and symbol is margin trading pair, it returns available balance + max.borrowable amount
    • Otherwise, it returns actual balance
    • up to 4 decimals
    maxTradeAmountstringThe maximum quote coin amount can be traded
    • If spot margin trade on and symbol is margin trading pair, it returns available balance + max.borrowable amount
    • Otherwise, it returns actual balance
    • up to 8 decimals
    spotMaxTradeQtystringNo matter your Spot margin switch on or not, it always returns actual qty of base coin you can trade or you have, up to 4 decimals
    spotMaxTradeAmountstringNo matter your Spot margin switch on or not, it always returns actual amount of quote coin you can trade or you have, up to 8 decimals
    borrowCoinstringBorrow coin

    Request Example

    GET /v5/order/spot-borrow-check?category=spot&symbol=BTCUSDT&side=Buy HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672228522214
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "maxTradeQty": "6.6065",
    "side": "Buy",
    "spotMaxTradeAmount": "9004.75628594",
    "maxTradeAmount": "218014.01330797",
    "borrowCoin": "USDT",
    "spotMaxTradeQty": "0.2728"
    },
    "retExtInfo": {},
    "time": 1698895841534
    }
    - + \ No newline at end of file diff --git a/v5/otc/bind-uid.html b/v5/otc/bind-uid.html index ff7bdce534..495082cf7a 100644 --- a/v5/otc/bind-uid.html +++ b/v5/otc/bind-uid.html @@ -3,14 +3,14 @@ -Bind Or Unbind UID | Bybit API Documentation - +Bind Or Unbind UID | Bybit API Documentation +
    -

    Bind Or Unbind UID

    For the OTC loan product, you can bind new UID to risk unit or unbind UID out from risk unit.

    info
    • Risk unit main UID cannot be unbound
    • This endpoint can only be called by uids in the risk unit list
    • The UID must be upgraded to UTA if you try to bind it.

    HTTP Request

    POST /v5/ins-loan/association-uid

    Request Parameters

    ParameterRequiredTypeComments
    uidtruestringUID
    operatetruestring0: bind, 1: unbind

    Response Parameters

    ParameterTypeComments
    uidstringUID
    operatestring0: bind, 1: unbind

    Request Example

    POST /v5/ins-loan/association-uid HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1699257853101
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    Content-Length: 43

    {
    "uid": "592324",
    "operate": "0"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "uid": "592324",
    "operate": "0"
    },
    "retExtInfo": {},
    "time": 1699257746135
    }
    - +

    Bind Or Unbind UID

    For the INS loan product, you can bind new UID to risk unit or unbind UID out from risk unit.

    info
    • Risk unit designated UID cannot be unbound
    • This endpoint can only be called by uids in the risk unit list
    • The UID must be upgraded to UTA Pro if you try to bind it.

    HTTP Request

    POST /v5/ins-loan/association-uid

    Request Parameters

    ParameterRequiredTypeComments
    uidtruestringUID
    operatetruestring0: bind, 1: unbind

    Response Parameters

    ParameterTypeComments
    uidstringUID
    operatestring0: bind, 1: unbind

    Request Example

    POST /v5/ins-loan/association-uid HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1699257853101
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    Content-Length: 43

    {
    "uid": "592324",
    "operate": "0"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "uid": "592324",
    "operate": "0"
    },
    "retExtInfo": {},
    "time": 1699257746135
    }
    + \ No newline at end of file diff --git a/v5/otc/loan-info.html b/v5/otc/loan-info.html index 2cb88f727a..06c2a5cfb1 100644 --- a/v5/otc/loan-info.html +++ b/v5/otc/loan-info.html @@ -4,13 +4,13 @@ Get Loan Orders | Bybit API Documentation - +

    Get Loan Orders

    Get loan orders information

    tip
    • Get the past 2 years data by default
    • Get up to the past 2 years of data

    HTTP Request

    GET /v5/ins-loan/loan-order

    Request Parameters

    ParameterRequiredTypeComments
    orderIdfalsestringLoan order id. If not passed, then return all orders, sort by loanTime in descend
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size. [1, 100], Default: 10

    Response Parameters

    ParameterTypeComments
    loanInfoarrayObject
    > orderIdstringLoan order ID
    > orderProductIdstringProduct ID
    > parentUidstringThe uid that used to bind OTC loan product
    > loanTimestringLoan timestamp, in milliseconds
    > loanCoinstringLoan coin
    > loanAmountstringLoan amount
    > unpaidAmountstringUnpaid principal
    > unpaidIntereststringUnpaid interest
    > repaidAmountstringRepaid principal
    > repaidIntereststringRepaid interest
    > interestRatestringDaily interest rate
    > statusstring1:outstanding; 2:paid off
    > leveragestringThe maximum leverage for this loan product
    > supportSpotstringWhether to support spot. 0:false; 1:true
    > supportContractstringWhether to support contract . 0:false; 1:true
    > withdrawLinestringRestrict line for withdrawal
    > transferLinestringRestrict line for transfer
    > spotBuyLinestringRestrict line for SPOT buy
    > spotSellLinestringRestrict line for SPOT sell
    > contractOpenLinestringRestrict line for USDT Perpetual open position
    > liquidationLinestringLine for liquidation
    > stopLiquidationLinestringLine for stop liquidation
    > contractLeveragestringThe allowed default leverage for USDT Perpetual
    > transferRatiostringThe transfer ratio for loan funds to transfer from Spot wallet to Contract wallet
    > spotSymbolsarrayThe whitelist of spot trading pairs. If there is no whitelist, then "[]"
    > contractSymbolsarrayThe whitelist of contract trading pairs
    • If supportContract="0", then this is "[]"
    • If there is no whitelist, this is "[]"
    > supportUSDCContractstringWhether to support USDC contract. "0":false; "1":true
    > supportUSDCOptionsstringWhether to support Option. "0":false; "1":true
    > supportMarginTradingstringWhether to support Spot margin trading. "0":false; "1":true
    > USDTPerpetualOpenLinestringRestrict line to open USDT Perpetual position
    > USDCContractOpenLinestringRestrict line to open USDC Contract position
    > USDCOptionsOpenLinestringRestrict line to open Option position
    > USDTPerpetualCloseLinestringRestrict line to trade USDT Perpetual position
    > USDCContractCloseLinestringRestrict line to trade USDC Contract position
    > USDCOptionsCloseLinestringRestrict line to trade Option position
    > USDCContractSymbolsarrayThe whitelist of USDC contract trading pairs
    • If no whitelist symbols, it is [], and you can trade any
    • If supportUSDCContract="0", it is []
    > USDCOptionsSymbolsarrayThe whitelist of Option symbols
    • If no whitelisted, it is [], and you can trade any
    • If supportUSDCOptions="0", it is []
    > marginLeveragestringThe allowable maximum leverage for Spot margin
    > USDTPerpetualLeveragearrayObject
    • If supportContract="0", it is []
    • If no whitelist USDT perp symbols, it returns all trading symbols and leverage by default
    • If there are whitelist symbols, it return those whitelist data
    >> symbolstringSymbol name
    >> leveragestringMaximum leverage
    > USDCContractLeveragearrayObject
    • If supportUSDCContract="0", it is []
    • If no whitelist USDC contract symbols, it returns all trading symbols and leverage by default
    • If there are whitelist symbols, it return those whitelist data
    >> symbolstringSymbol name
    >> leveragestringMaximum leverage

    Request Example

    GET /v5/ins-loan/loan-order HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1678687874060
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "loanInfo": [
    {
    "orderId": "1468005106166530304",
    "orderProductId": "96",
    "parentUid": "1631521",
    "loanTime": "1689735916000",
    "loanCoin": "USDT",
    "loanAmount": "204",
    "unpaidAmount": "52.07924201",
    "unpaidInterest": "0",
    "repaidAmount": "151.92075799",
    "repaidInterest": "0",
    "interestRate": "0.00019178",
    "status": "1",
    "leverage": "4",
    "supportSpot": "1",
    "supportContract": "1",
    "withdrawLine": "",
    "transferLine": "",
    "spotBuyLine": "0.71",
    "spotSellLine": "0.71",
    "contractOpenLine": "0.71",
    "liquidationLine": "0.75",
    "stopLiquidationLine": "0.35000000",
    "contractLeverage": "7",
    "transferRatio": "1",
    "spotSymbols": [],
    "contractSymbols": [],
    "supportUSDCContract": "1",
    "supportUSDCOptions": "1",
    "USDTPerpetualOpenLine": "0.71",
    "USDCContractOpenLine": "0.71",
    "USDCOptionsOpenLine": "0.71",
    "USDTPerpetualCloseLine": "0.71",
    "USDCContractCloseLine": "0.71",
    "USDCOptionsCloseLine": "0.71",
    "USDCContractSymbols": [],
    "USDCOptionsSymbols": [],
    "marginLeverage": "4",
    "USDTPerpetualLeverage": [
    {
    "symbol": "SUSHIUSDT",
    "leverage": "7"
    },
    {
    "symbol": "INJUSDT",
    "leverage": "7"
    },
    {
    "symbol": "RDNTUSDT",
    "leverage": "7"
    },
    {
    "symbol": "ZRXUSDT",
    "leverage": "7"
    },
    {
    "symbol": "HIGHUSDT",
    "leverage": "7"
    },
    {
    "symbol": "WAVESUSDT",
    "leverage": "7"
    },
    ...
    {
    "symbol": "ACHUSDT",
    "leverage": "7"
    },
    {
    "symbol": "SUNUSDT",
    "leverage": "7"
    }
    ],
    "USDCContractLeverage": [
    {
    "symbol": "BTCPERP",
    "leverage": "8"
    },
    {
    "symbol": "BTC-Futures",
    "leverage": "8"
    },
    ...
    {
    "symbol": "ETH-Futures",
    "leverage": "8"
    },
    {
    "symbol": "SOLPERP",
    "leverage": "8"
    },
    {
    "symbol": "ETHPERP",
    "leverage": "8"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1689745773187
    }
    - + \ No newline at end of file diff --git a/v5/otc/ltv-convert.html b/v5/otc/ltv-convert.html index d63fb64313..6c1c74c17b 100644 --- a/v5/otc/ltv-convert.html +++ b/v5/otc/ltv-convert.html @@ -4,13 +4,13 @@ Get LTV | Bybit API Documentation - +

    Get LTV

    Get LTV

    HTTP Request

    GET /v5/ins-loan/ltv-convert

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    ltvInfoarrayObject
    > ltvstringRisk rate
    > parentUidstringThe uid that used to bind OTC loan product
    > subAccountUidsarrayBound user id
    > unpaidAmountstringTotal debt(USDT)
    > unpaidInfoarrayDebt details
    >> tokenstringcoin
    >> unpaidQtystringUnpaid principle
    >> unpaidIntereststringUseless field, please ignore this for now
    > balancestringTotal asset. (margin coins converted to USDT). Please read here to understand the calculation
    > balanceInfoarrayAsset details
    >> tokenstringMargin coin
    >> pricestringMargin coin price
    >> qtystringMargin coin quantity
    >> convertedAmountstringMargin conversion amount

    Request Example

    GET /v5/ins-loan/ltv-convert HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686638165351
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.75",
    "parentUid": "xxxxx",
    "subAccountUids": [
    "60568258"
    ],
    "unpaidAmount": "30",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "30",
    "unpaidInterest": "0"
    }
    ],
    "balance": "40",
    "balanceInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "40",
    "convertedAmount": "40"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686638166323
    }
    - + \ No newline at end of file diff --git a/v5/otc/margin-coin-convert-info.html b/v5/otc/margin-coin-convert-info.html index 87837c7cfe..a467c36c97 100644 --- a/v5/otc/margin-coin-convert-info.html +++ b/v5/otc/margin-coin-convert-info.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - +

    Get Margin Coin Info

    tip
    • This endpoint can be queried without api key and secret, then it returns public margin data
    • If your uid is bound with OTC loan product, then you can get your private margin data by calling the endpoint with api key and secret
    • If your uid is not bound with OTC loan product but api key and secret are also passed, it will return public data only

    HTTP Request

    GET /v5/ins-loan/ensure-tokens-convert

    Request Parameters

    ParameterRequiredTypeComments
    productIdfalsestringProductId. If not passed, then return all product margin coin. For spot, it returns coin that convertRation greater than 0.

    Response Parameters

    ParameterTypeComments
    marginTokenarrayObject
    > productIdstringProduct Id
    > tokenInfoarraySpot margin coin
    >> tokenstringMargin coin
    >> convertRatioListarrayMargin coin convert ratio List
    >>> ladderstringladder
    >>> convertRatiostringMargin coin convert ratio

    Request Example

    GET /v5/ins-loan/ensure-tokens HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginToken": [
    {
    "productId": "81",
    "tokenInfo": [
    {
    "token": "USDT",
    "convertRatioList": [
    {
    "ladder": "0-500",
    "convertRatio": "0.95"
    },
    {
    "ladder": "500-1000",
    "convertRatio": "0.9"
    },
    {
    "ladder": "1000-2000",
    "convertRatio": "0.8"
    },
    {
    "ladder": "2000-4000",
    "convertRatio": "0.7"
    },
    {
    "ladder": "4000-99999999999",
    "convertRatio": "0.6"
    }
    ]
    }
    ...
    ]
    },
    {
    "productId": "82",
    "tokenInfo": [
    ...
    {
    "token": "USDT",
    "convertRatioList": [
    {
    "ladder": "0-1000",
    "convertRatio": "0.7"
    },
    {
    "ladder": "1000-2000",
    "convertRatio": "0.65"
    },
    {
    "ladder": "2000-99999999999",
    "convertRatio": "0.6"
    }
    ]
    }
    ]
    },
    {
    "productId": "84",
    "tokenInfo": [
    ...
    {
    "token": "BTC",
    "convertRatioList": [
    {
    "ladder": "0-1000",
    "convertRatio": "1"
    },
    {
    "ladder": "1000-5000",
    "convertRatio": "0.9"
    },
    {
    "ladder": "5000-99999999999",
    "convertRatio": "0.55"
    }
    ]
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1683276016497
    }
    - + \ No newline at end of file diff --git a/v5/otc/margin-product-info.html b/v5/otc/margin-product-info.html index 0e682bcc33..fb7d377b35 100644 --- a/v5/otc/margin-product-info.html +++ b/v5/otc/margin-product-info.html @@ -4,13 +4,13 @@ Get Product Info | Bybit API Documentation - +

    Get Product Info

    tip
    • This endpoint can be queried without api key and secret, then it returns public product data
    • If your uid is bound with OTC loan product, then you can get your private product data by calling the endpoint with api key and secret
    • If your uid is not bound with OTC loan product but api key and secret are also passed, it will return public data only

    HTTP Request

    GET /v5/ins-loan/product-infos

    Request Parameters

    ParameterRequiredTypeComments
    productIdfalsestringProduct Id. If not passed, then return all products info

    Response Parameters

    ParameterTypeComments
    marginProductInfoarrayObject
    > productIdstringProduct Id
    > leveragestringThe maximum leverage for this loan product
    > supportSpotintegerWhether to support Spot. 0:false; 1:true
    > supportContractintegerWhether to support USDT Perpetual. 0:false; 1:true
    > supportMarginTradingintegerWhether to support Spot margin trading. 0:false; 1:true
    > withdrawLinestringRestrict line for withdrawal
    > transferLinestringRestrict line for transfer
    > spotBuyLinestringRestrict line for Spot buy
    > spotSellLinestringRestrict line for Spot trading
    > contractOpenLinestringRestrict line for USDT Perpetual open position
    > liquidationLinestringLine for liquidation
    > stopLiquidationLinestringLine for stop liquidation
    > contractLeveragestringThe allowed default leverage for USDT Perpetual
    > transferRatiostringThe transfer ratio for loan funds to transfer from Spot wallet to Contract wallet
    > spotSymbolsarrayThe whitelist of spot trading pairs
    • If supportSpot="0", then it returns "[]"
    • If empty array, then you can trade any symbols
    • If not empty, then you can only trade listed symbols
    > contractSymbolsarrayThe whitelist of contract trading pairs
    • If supportContract="0", then it returns "[]"
    • If empty array, then you can trade any symbols
    • If not empty, then you can only trade listed symbols
    > supportUSDCContractintegerWhether to support USDC contract. '0':false; '1':true
    > supportUSDCOptionsintegerWhether to support Option. '0':false; '1':true
    > USDTPerpetualOpenLinestringRestrict line to open USDT Perpetual position
    > USDCContractOpenLinestringRestrict line to open USDC Contract position
    > USDCOptionsOpenLinestringRestrict line to open Option position
    > USDTPerpetualCloseLinestringRestrict line to trade USDT Perpetual
    > USDCContractCloseLinestringRestrict line to trade USDC Contract
    > USDCOptionsCloseLinestringRestrict line to trade Option
    > USDCContractSymbolsarrayThe whitelist of USDC contract trading pairs
    • If supportContract="0", then it returns "[]"
    • If no whitelist symbols, it is [], and you can trade any
    • If supportUSDCContract="0", it is []
    > USDCOptionsSymbolsarrayThe whitelist of Option symbols
    • If supportContract="0", then it returns "[]"
    • If no whitelisted, it is [], and you can trade any
    • If supportUSDCOptions="0", it is []
    > marginLeveragestringThe allowable maximum leverage for Spot margin trading. If supportMarginTrading=0, then it returns ""
    > USDTPerpetualLeveragearrayObject
    • If supportContract="0", it is []
    • If no whitelist USDT perp symbols, it returns all trading symbols and leverage by default
    • If there are whitelist symbols, it return those whitelist data
    >> symbolstringSymbol name
    >> leveragestringMaximum leverage
    > USDCContractLeveragearrayObject
    • If supportUSDCContract="0", it is []
    • If no whitelist USDC contract symbols, it returns all trading symbols and leverage by default
    • If there are whitelist symbols, it return those whitelist data
    >> symbolstringSymbol name
    >> leveragestringMaximum leverage

    Request Example

    GET /v5/ins-loan/product-infos?productId=91 HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginProductInfo": [
    {
    "productId": "91",
    "leverage": "4.00000000",
    "supportSpot": 1,
    "supportContract": 0,
    "withdrawLine": "",
    "transferLine": "",
    "spotBuyLine": "",
    "spotSellLine": "",
    "contractOpenLine": "",
    "liquidationLine": "0.75",
    "stopLiquidationLine": "0.35000000",
    "contractLeverage": "0",
    "transferRatio": "0",
    "spotSymbols": [],
    "contractSymbols": [],
    "supportUSDCContract": 0,
    "supportUSDCOptions": 0,
    "USDTPerpetualOpenLine": "",
    "USDCContractOpenLine": "",
    "USDCOptionsOpenLine": "",
    "USDTPerpetualCloseLine": "",
    "USDCContractCloseLine": "",
    "USDCOptionsCloseLine": "",
    "USDCContractSymbols": [],
    "USDCOptionsSymbols": [],
    "marginLeverage": "0",
    "USDTPerpetualLeverage": [],
    "USDCContractLeverage": []
    }
    ]
    },
    "retExtInfo": {},
    "time": 1689747746332
    }
    - + \ No newline at end of file diff --git a/v5/otc/repay-info.html b/v5/otc/repay-info.html index 11ce36a005..2e5314b6bc 100644 --- a/v5/otc/repay-info.html +++ b/v5/otc/repay-info.html @@ -4,13 +4,13 @@ Get Repay Orders | Bybit API Documentation - +

    Get Repay Orders

    Get repaid order information

    tip
    • Get the past 2 years data by default
    • Get up to the past 2 years of data

    HTTP Request

    GET /v5/ins-loan/repaid-history

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size. [1, 100]. Default: 100

    Response Parameters

    ParameterTypeComments
    repayInfoarrayObject
    > repayOrderIdstringRepaid order ID
    > repaidTimestringRepaid timestamp (ms)
    > tokenstringRepaid coin
    > quantitystringRepaid principle
    > intereststringRepaid interest
    > businessTypestringRepaid type. 1:normal repayment; 2:repaid by liquidation
    > statusstring1:outstanding; 2:paid off

    Request Example

    GET /v5/ins-loan/repaid-history HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1678687944725
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "repayInfo": [
    {
    "repayOrderId": "8189",
    "repaidTime": "1663126393000",
    "token": "USDT",
    "quantity": "30000",
    "interest": "0",
    "businessType": "1",
    "status": "1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669366648366
    }
    - + \ No newline at end of file diff --git a/v5/position.html b/v5/position.html index c2982ddd58..1c90236ddb 100644 --- a/v5/position.html +++ b/v5/position.html @@ -4,14 +4,14 @@ Get Position Info | Bybit API Documentation - +

    Get Position Info

    Query real-time position data, such as position size, cumulative realizedPNL.

    Unified account covers: USDT perpetual / USDC contract / Inverse contract / Options
    Classic account covers: USDT perpetual / Inverse contract

    info

    Regarding inverse contracts,

    1. you can query all holding positions with "/v5/position/list?category=inverse";
    2. symbol parameter is supported to be passed with multiple symbols up to 10

    HTTP Request

    GET /v5/position/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse, option
    • Classic account: linear, inverse
    symbolfalsestringSymbol name
    • If symbol passed, it returns data regardless of having position or not.
    • If symbol=null and settleCoin specified, it returns position size greater than zero.
    baseCoinfalsestringBase coin. option only. Return all option positions if not passed
    settleCoinfalsestringSettle coin. For linear, either symbol or settleCoin is required. symbol has a higher priority
    limitfalseintegerLimit for data size per page. [1, 200]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > positionIdxintegerPosition idx, used to identify positions in different position modes
    • 0: One-Way Mode
    • 1: Buy side of both side mode
    • 2: Sell side of both side mode
    > riskIdintegerRisk limit ID. Note: for portfolio margin mode, this field returns 0, which means risk limit rules are invalid
    > riskLimitValuestringRisk limit value. Note: for portfolio margin mode, this field returns 0, which means risk limit rules are invalid
    > symbolstringSymbol name
    > sidestringPosition side. Buy: long, Sell: short
    • Classic account in one-way mode & Unified account (inverse), an empty position returns None.
    • UTA account(linear contracts), either one-way or hedge mode returns an empty string for an empty position.
    > sizestringPosition size
    > avgPricestringAverage entry price
  • For USDC Perp & Futures, it indicates average entry price, and it will not be changed with 8-hour session settlement
  • > positionValuestringPosition value
    > tradeModeintegerTrade mode
    • Classic & UTA (inverse): 0: cross-margin, 1: isolated margin
    • UTA: depreciated, always 0
    > autoAddMarginintegerWhether to add margin automatically. 0: false, 1: true. For UTA, it is meaningful only when UTA enables ISOLATED_MARGIN
    > positionStatusStringPosition status. Normal, Liq, Adl
    > leveragestringPosition leverage. Valid for contract. Note: for portfolio margin mode, this field returns "", which means leverage rules are invalid
    > markPricestringLast mark price
    > liqPricestringPosition liquidation price
    • UTA (inverse) & UTA (isolated margin enabled) & Classic account: it is the real price for isolated and cross positions, and keeps "" when liqPrice <= minPrice or liqPrice >= maxPrice
    • UTA (Cross margin mode): it is an estimated price for cross positions(because the unified mode controls the risk rate according to the account), and keeps "" when liqPrice <= minPrice or liqPrice >= maxPrice
    However, this field is empty for Portfolio Margin Mode, and no liquidation price will be provided
    > bustPricestringBankruptcy price. Note: Unified mode returns "", no position bankruptcy price (exclude inverse trade under UTA)
    > positionIMstringInitial margin. For portfolio margin mode, it returns ""
    > positionMMstringMaintenance margin. For portfolio margin mode, it returns ""
    > positionBalancestringPosition margin. For portfolio margin mode, it returns ""
    > tpslModestringDepreciated, meaningless here, always "Full". Spot does not return this field. Option returns ""
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > trailingStopstringTrailing stop (The distance from market price)
    > unrealisedPnlstringUnrealised PnL
    > cumRealisedPnlstringCumulative realised pnl
    • Futures & Perp: it is the all time cumulative realised P&L
    • Option: it is the realised P&L when you hold that position
    > adlRankIndicatorintegerAuto-deleverage rank indicator. What is Auto-Deleveraging?
    > isReduceOnlybooleanUseful when Bybit lower the risk limit
    • true: Only allowed to reduce the position. You can consider a series of measures, e.g., lower the risk limit, decrease leverage or reduce the position, add margin, or cancel orders, after these operations, you can call confirm new risk limit endpoint to check if your position can be removed the reduceOnly mark
    • false: There is no restriction, and it means your position is under the risk when the risk limit is systematically adjusted
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > mmrSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the MMR will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the MMR had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > leverageSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the leverage will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the leverage had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > createdTimestringPosition created timestamp (ms)
    > updatedTimestringPosition updated timestamp (ms)
    > seqlongCross sequence, used to associate each fill and each position update
    • Different symbols may have the same seq, please use seq + symbol to check unique
    • Returns "-1" if the symbol has never been traded
    • Returns the seq updated by the last transaction when there are settings like leverage, risk limit
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/position/list?category=inverse&symbol=BTCUSD HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672280218882
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "positionIdx": 0,
    "riskId": 1,
    "riskLimitValue": "150",
    "symbol": "BTCUSD",
    "side": "Sell",
    "size": "300",
    "avgPrice": "27464.50441675",
    "positionValue": "0.01092319",
    "tradeMode": 0,
    "positionStatus": "Normal",
    "autoAddMargin": 1,
    "adlRankIndicator": 2,
    "leverage": "10",
    "positionBalance": "0.00139186",
    "markPrice": "28224.50",
    "liqPrice": "",
    "bustPrice": "999999.00",
    "positionMM": "0.0000015",
    "positionIM": "0.00010923",
    "tpslMode": "Full",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "trailingStop": "0.00",
    "unrealisedPnl": "-0.00029413",
    "cumRealisedPnl": "-0.00096902",
    "seq": 5723621632,
    "isReduceOnly": false,
    "mmrSysUpdateTime": "",
    "leverageSysUpdatedTime": "",
    "createdTime": "1676538056258",
    "updatedTime": "1697673600012"
    }
    ],
    "nextPageCursor": "",
    "category": "inverse"
    },
    "retExtInfo": {},
    "time": 1697684980172
    }
    - + \ No newline at end of file diff --git a/v5/position/auto-add-margin.html b/v5/position/auto-add-margin.html index e4ec738ff7..11b3a04b71 100644 --- a/v5/position/auto-add-margin.html +++ b/v5/position/auto-add-margin.html @@ -4,14 +4,14 @@ Set Auto Add Margin | Bybit API Documentation - +

    Set Auto Add Margin

    Turn on/off auto-add-margin for isolated margin position

    Unified account covers: USDT perpetual / USDC perpetual / USDC futures / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    POST /v5/position/set-auto-add-margin

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse
    symboltruestringSymbol name
    autoAddMargintrueintegerTurn on/off. 0: off. 1: on
    positionIdxfalseintegerUsed to identify positions in different position modes. For hedge mode position, this param is required
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    None


    Request Example

    POST /v5/position/set-auto-add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675255134857
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "autoAddmargin": 1,
    "positionIdx": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675255135069
    }
    - + \ No newline at end of file diff --git a/v5/position/close-pnl.html b/v5/position/close-pnl.html index 76beadc36a..8759531743 100644 --- a/v5/position/close-pnl.html +++ b/v5/position/close-pnl.html @@ -4,14 +4,14 @@ Get Closed PnL | Bybit API Documentation - +

    Get Closed PnL

    Query user's closed profit and loss records. The results are sorted by createdTime in descending order.

    Unified account covers: USDT perpetual / USDC contract / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    GET /v5/position/closed-pnl

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symbolfalsestringSymbol name
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > sidestringBuy, Sell
    > qtystringOrder qty
    > orderPricestringOrder price
    > orderTypestringOrder type. Market,Limit
    > execTypestringExec type. Trade, BustTrade, SessionSettlePnL, Settle
    > closedSizestringClosed size
    > cumEntryValuestringCumulated Position value
    > avgEntryPricestringAverage entry price
    > cumExitValuestringCumulated exit position value
    > avgExitPricestringAverage exit price
    > closedPnlstringClosed PnL
    > fillCountstringThe number of fills in a single order
    > leveragestringleverage
    > createdTimestringThe created time (ms)
    > updatedTimestringThe updated time (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/position/closed-pnl?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672284128523
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "5a373bfe-188d-4913-9c81-d57ab5be8068%3A1672214887231423699%2C5a373bfe-188d-4913-9c81-d57ab5be8068%3A1672214887231423699",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Market",
    "leverage": "3",
    "updatedTime": "1672214887236",
    "side": "Sell",
    "orderId": "5a373bfe-188d-4913-9c81-d57ab5be8068",
    "closedPnl": "-47.4065323",
    "avgEntryPrice": "1194.97516667",
    "qty": "3",
    "cumEntryValue": "3584.9255",
    "createdTime": "1672214887231423699",
    "orderPrice": "1122.95",
    "closedSize": "3",
    "avgExitPrice": "1180.59833333",
    "execType": "Trade",
    "fillCount": "4",
    "cumExitValue": "3541.795"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672284129153
    }
    - + \ No newline at end of file diff --git a/v5/position/confirm-mmr.html b/v5/position/confirm-mmr.html index 56b4d766cd..043175ab41 100644 --- a/v5/position/confirm-mmr.html +++ b/v5/position/confirm-mmr.html @@ -4,7 +4,7 @@ Confirm New Risk Limit | Bybit API Documentation - + @@ -14,7 +14,7 @@ is called to try to calculate the adjusted risk level, and if it passes (retCode=0), the system will remove the position reduceOnly mark. You are recommended to call Get Position Info to check isReduceOnly field.

    Unified account covers: USDT perpetual / USDC contract / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    POST /v5/position/confirm-pending-mmr

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse
    symboltruestringSymbol name

    Response Parameters

    None

    Request Example

    POST /v5/position/confirm-pending-mmr HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698051123673
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 53

    {
    "category": "linear",
    "symbol": "BTCUSDT"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698051124588
    }
    - + \ No newline at end of file diff --git a/v5/position/cross-isolate.html b/v5/position/cross-isolate.html index 7e46af1aa2..c57447c92f 100644 --- a/v5/position/cross-isolate.html +++ b/v5/position/cross-isolate.html @@ -4,14 +4,14 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +

    Switch Cross/Isolated Margin

    Select cross margin mode or isolated margin mode per symbol level

    Unified account covers: Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    POST /v5/position/switch-isolated

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symboltruestringSymbol name
    tradeModetrueinteger0: cross margin. 1: isolated margin
    buyLeveragetruestringThe value must be equal to sellLeverage value
    sellLeveragetruestringThe value must be equal to buyLeverage value

    Response Parameters

    None

    Request Example

    POST /v5/position/switch-isolated HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675248447965
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 121

    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "tradeMode": 1,
    "buyLeverage": "10",
    "sellLeverage": "10"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675248433635
    }
    - + \ No newline at end of file diff --git a/v5/position/execution.html b/v5/position/execution.html index 65d92433bf..9d5dbe3d03 100644 --- a/v5/position/execution.html +++ b/v5/position/execution.html @@ -4,7 +4,7 @@ Get Execution | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Get Execution

    Query users' execution records, sorted by execTime in descending order. However, for Classic spot, they are sorted by execId in descending order.

    Unified account covers: Spot / USDT perpetual / USDC contract / Inverse contract / Options
    Classic account covers: Spot / USDT perpetual / Inverse contract

    tip
    • Response items will have sorting issues When 'execTime' is the same. This issue is currently being optimized and will be released at the end of October. If you want to receive real-time execution information, Use the websocket stream (recommended).
    • You may have multiple executions in a single order.
    • You can query by symbol, baseCoin, orderId and orderLinkId, and if you pass multiple params, the system will process them according to this priority: orderId > orderLinkId > symbol > baseCoin.

    HTTP Request

    GET /v5/execution/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse
    symbolfalsestringSymbol name
    orderIdfalsestringOrder ID
    orderLinkIdfalsestringUser customised order ID. Classic account does not support this param
    baseCoinfalsestringBase coin. Unified account - inverse and Classic account do not support this param
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    execTypefalsestringExecution type. Classic spot is not supported
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > orderLinkIdstringUser customized order ID. Classic spot is not supported
    > sidestringSide. Buy,Sell
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > leavesQtystringThe remaining qty not executed. Classic spot is not supported
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. If the order is not stop order, it either returns UNKNOWN or "". Classic spot is not supported
    > execFeestringExecuted trading fee. You can get spot fee currency instruction here
    > execIdstringExecution ID
    > execPricestringExecution price
    > execQtystringExecution qty
    > execTypestringExecuted type. Classic spot is not supported
    > execValuestringExecuted order value. Classic spot is not supported
    > execTimestringExecuted timestamp(ms)
    > isMakerbooleanIs maker order. true: maker, false: taker
    > feeRatestringTrading fee rate. Classic spot is not supported
    > tradeIvstringImplied volatility. Valid for option
    > markIvstringImplied volatility of mark price. Valid for option
    > markPricestringThe mark price of the symbol when executing. Classic spot is not supported
    > indexPricestringThe index price of the symbol when executing. Valid for option only
    > underlyingPricestringThe underlying price of the symbol when executing. Valid for option
    > blockTradeIdstringParadigm block trade ID
    > closedSizestringClosed position size
    > seqlongCross sequence, used to associate each fill and each position update
    • The seq will be the same when conclude multiple transactions at the same time
    • Different symbols may have the same seq, please use seq + symbol to check unique
    • Classic account Spot trade does not have this field
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/execution/list?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672283754132
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "132766%3A2%2C132766%3A2",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Market",
    "underlyingPrice": "",
    "orderLinkId": "",
    "side": "Buy",
    "indexPrice": "",
    "orderId": "8c065341-7b52-4ca9-ac2c-37e31ac55c94",
    "stopOrderType": "UNKNOWN",
    "leavesQty": "0",
    "execTime": "1672282722429",
    "isMaker": false,
    "execFee": "0.071409",
    "feeRate": "0.0006",
    "execId": "e0cbe81d-0f18-5866-9415-cf319b5dab3b",
    "tradeIv": "",
    "blockTradeId": "",
    "markPrice": "1183.54",
    "execPrice": "1190.15",
    "markIv": "",
    "orderQty": "0.1",
    "orderPrice": "1236.9",
    "execValue": "119.015",
    "execType": "Trade",
    "execQty": "0.1",
    "closedSize": "",
    "seq": 4688002127
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672283754510
    }
    - + \ No newline at end of file diff --git a/v5/position/leverage.html b/v5/position/leverage.html index eaf1878485..b126346b19 100644 --- a/v5/position/leverage.html +++ b/v5/position/leverage.html @@ -4,14 +4,14 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set the leverage

    Unified account covers: USDT perpetual / USDC contract / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    POST /v5/position/set-leverage

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symboltruestringSymbol name
    buyLeveragetruestring[1, max leverage of corresponding risk limit]
    • Classic account: under one-way mode, buyLeverage must be the same as sellLeverage
    • Unified account: buyLeverage must be the same as sellLeverage all the time
    sellLeveragetruestring[1, max leverage of corresponding risk limit]
    • Classic account: under one-way mode, buyLeverage must be the same as sellLeverage
    • Unified account: buyLeverage must be the same as sellLeverage all the time

    Response Parameters

    None

    Request Example

    POST /v5/position/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672281605082
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "buyLeverage": "6",
    "sellLeverage": "6"

    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672281607343
    }
    - + \ No newline at end of file diff --git a/v5/position/manual-add-margin.html b/v5/position/manual-add-margin.html index d6e967804d..d974b14a1f 100644 --- a/v5/position/manual-add-margin.html +++ b/v5/position/manual-add-margin.html @@ -4,14 +4,14 @@ Add Or Reduce Margin | Bybit API Documentation - +

    Add Or Reduce Margin

    Manually add or reduce margin for isolated margin position

    Unified account covers: USDT perpetual / USDC perpetual / USDC futures / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    HTTP Request

    POST /v5/position/add-margin

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse
    symboltruestringSymbol name
    margintruestringAdd or reduce. To add, then 10; To reduce, then -10. Support up to 4 decimal
    positionIdxfalseintegerUsed to identify positions in different position modes. For hedge mode position, this param is required
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    symbolstringSymbol name
    positionIdxintegerPosition idx, used to identify positions in different position modes
    • 0: One-Way Mode
    • 1: Buy side of both side mode
    • 2: Sell side of both side mode
    riskIdintegerRisk limit ID
    riskLimitValuestringRisk limit value
    sizestringPosition size
    avgPricestringAverage entry price
    liqPricestringLiquidation price
    bustPricestringBankruptcy price
    markPricestringLast mark price
    positionValuestringPosition value
    leveragestringPosition leverage
    autoAddMarginintegerWhether to add margin automatically. 0: false, 1: true
    positionStatusStringPosition status. Normal, Liq, Adl
    positionIMstringInitial margin
    positionMMstringMaintenance margin
    takeProfitstringTake profit price
    stopLossstringStop loss price
    trailingStopstringTrailing stop (The distance from market price)
    unrealisedPnlstringUnrealised PnL
    cumRealisedPnlstringCumulative realised pnl
    createdTimestringPosition created timestamp (ms)
    updatedTimestringPosition updated timestamp (ms)

    Request Example

    POST /v5/position/add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1684234363665
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 97

    {
    "category": "inverse",
    "symbol": "ETHUSD",
    "margin": "0.01",
    "positionIdx": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "symbol": "ETHUSD",
    "positionIdx": 0,
    "riskId": 11,
    "riskLimitValue": "500",
    "size": "200",
    "positionValue": "0.11033265",
    "avgPrice": "1812.70004844",
    "liqPrice": "1550.80",
    "bustPrice": "1544.20",
    "markPrice": "1812.90",
    "leverage": "12",
    "autoAddMargin": 0,
    "positionStatus": "Normal",
    "positionIM": "0.01926611",
    "positionMM": "0",
    "unrealisedPnl": "0.00001217",
    "cumRealisedPnl": "-0.04618929",
    "stopLoss": "0.00",
    "takeProfit": "0.00",
    "trailingStop": "0.00",
    "createdTime": "1672737740039",
    "updatedTime": "1684234363788"
    },
    "retExtInfo": {},
    "time": 1684234363789
    }
    - + \ No newline at end of file diff --git a/v5/position/position-mode.html b/v5/position/position-mode.html index a0e6a30431..a0fe750f43 100644 --- a/v5/position/position-mode.html +++ b/v5/position/position-mode.html @@ -4,14 +4,14 @@ Switch Position Mode | Bybit API Documentation - +

    Switch Position Mode

    It supports to switch the position mode for USDT perpetual and Inverse futures. If you are in one-way Mode, you can only open one position on Buy or Sell side. If you are in hedge mode, you can open both Buy and Sell side positions simultaneously.

    Unified account covers: USDT perpetual / Inverse Futures
    Classic account covers: USDT perpetual / Inverse Futures

    tip
    • Priority for configuration to take effect: symbol > coin > system default
    • System default: one-way mode
    • If the request is by coin (settleCoin), then all symbols based on this setteCoin that do not have position and open order will be batch switched, and new listed symbol based on this settleCoin will be the same mode you set.

    Example

    System defaultcoinsymbol
    Initial settingone-waynever configurednever configured
    ResultAll USDT perpetual trading pairs are one-way mode
    Change 1--Set BTCUSDT to hedge-mode
    ResultBTCUSDT becomes hedge-mode, and all other symbols keep one-way mode
    list new symbol ETHUSDTETHUSDT is one-way mode (inherit default rules)
    Change 2-Set USDT to hedge-mode-
    ResultAll current trading pairs with no positions or orders are hedge-mode, and no adjustments will be made for trading pairs with positions and orders
    list new symbol SOLUSDTSOLUSDT is hedge-mode (Inherit coin rule)
    Change 3--Set ASXUSDT to one-mode
    Take effect resultAXSUSDT is one-way mode, other trading pairs have no change
    list new symbol BITUSDTBITUSDT is hedge-mode (Inherit coin rule)

    The position-switch ability for each contract

    Classic accountUnified account
    USDT perpetualSupport one-way & hedge-modeSupport one-way & hedge-mode
    USDC perpetualSupport one-way onlySupport one-way only
    Inverse perpetualSupport one-way onlySupport one-way only
    Inverse futureSupport one-way & hedge-modeSupport one-way & hedge-mode

    HTTP Request

    POST /v5/position/switch-mode

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, USDT Perp; inverse, Inverse Futures
    • Classic account: linear, USDT Perp; inverse, Inverse Futures. Please note that category is not involved with business logic
    symbolfalsestringSymbol name. Either symbol or coin is required. symbol has a higher priority
    coinfalsestringCoin
    modetrueintegerPosition mode. 0: Merged Single. 3: Both Sides

    Response Parameters

    None

    Request Example

    POST /v5/position/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675249072041
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 87

    {
    "category":"inverse",
    "symbol":"BTCUSDH23",
    "coin": null,
    "mode": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675249072814
    }
    - + \ No newline at end of file diff --git a/v5/position/set-risk-limit.html b/v5/position/set-risk-limit.html index 89dbaf4145..18bcf28bca 100644 --- a/v5/position/set-risk-limit.html +++ b/v5/position/set-risk-limit.html @@ -4,14 +4,14 @@ Set Risk Limit | Bybit API Documentation - +

    Set Risk Limit

    The risk limit will limit the maximum position value you can hold under different margin requirements. If you want to hold a bigger position size, you need more margin. This interface can set the risk limit of a single position. If the order exceeds the current risk limit when placing an order, it will be rejected. Click here to learn more about risk limit.

    Unified account covers: USDT perpetual / USDC contract / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    tip

    Set the risk limit of the position. You can get risk limit information for each symbol here.

    HTTP Request

    POST /v5/position/set-risk-limit

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symboltruestringSymbol name
    riskIdtrueintegerRisk limit ID
    positionIdxfalseintegerUsed to identify positions in different position modes. For hedge mode, it is required
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    riskIdintegerRisk limit ID
    riskLimitValuestringThe position limit value corresponding to this risk ID

    Request Example

    POST /v5/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672282269774
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "riskId": 4,
    "positionIdx": null
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "riskId": 4,
    "riskLimitValue": "8000000",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1672282270571
    }
    - + \ No newline at end of file diff --git a/v5/position/tpsl-mode.html b/v5/position/tpsl-mode.html index de2e615013..ce8646a2e6 100644 --- a/v5/position/tpsl-mode.html +++ b/v5/position/tpsl-mode.html @@ -4,7 +4,7 @@ Set TP/SL Mode | Bybit API Documentation - + @@ -13,7 +13,7 @@ change before.

    However, you still can use it to set an implicit tpsl mode for a certain symbol because when you don't pass "tpslMode" in the place order or trading stop request, system will get the tpslMode by the default setting.

    Set TP/SL mode to Full or Partial

    Unified account covers: USDT perpetual / Inverse contract
    Classic account covers: USDT perpetual / Inverse contract

    info

    For partial TP/SL mode, you can set the TP/SL size smaller than position size.

    HTTP Request

    POST /v5/position/set-tpsl-mode

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symboltruestringSymbol name
    tpSlModetruestringTP/SL mode. Full,Partial

    Response Parameters

    ParameterTypeComments
    tpSlModestringFull,Partial

    Request Example

    POST /v5/position/set-tpsl-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672279325035
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "symbol": "XRPUSDT",
    "category": "linear",
    "tpSlMode": "Full"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "tpSlMode": "Full"
    },
    "retExtInfo": {},
    "time": 1672279322666
    }
    - + \ No newline at end of file diff --git a/v5/position/trading-stop.html b/v5/position/trading-stop.html index 0e7c8ba12b..dee3387ff3 100644 --- a/v5/position/trading-stop.html +++ b/v5/position/trading-stop.html @@ -4,7 +4,7 @@ Set Trading Stop | Bybit API Documentation - + @@ -14,7 +14,7 @@ on existing TP/SL orders on the holding position, it will cause the paired tp/sl orders to lose binding relationship. This means that when calling the cancel API through the tp/sl order ID, it will only cancel the corresponding one-sided take profit or stop loss order ID.

    HTTP Request

    POST /v5/position/trading-stop

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type
    • Unified account: linear, inverse
    • Classic account: linear, inverse. Please note that category is not involved with business logic
    symboltruestringSymbol name
    takeProfitfalsestringCannot be less than 0, 0 means cancel TP
    stopLossfalsestringCannot be less than 0, 0 means cancel SL
    trailingStopfalsestringTrailing stop by price distance. Cannot be less than 0, 0 means cancel TS
    tpTriggerByfalsestringTake profit trigger price type
    slTriggerByfalsestringStop loss trigger price type
    activePricefalsestringTrailing stop trigger price. Trailing stop will be triggered when this price is reached only
    tpslModefalsestringTP/SL mode. Full: entire position TP/SL, Partial: partial position TP/SL. As each contract has an initial full TP/SL mode, if it has been modified before, it may be partial. Therefore, if not provided, the system will automatically retrieve the current TP/SL mode configuration for the contract.
    tpSizefalsestringTake profit size. Valid in TP/SL partial mode. Note: the value of tpSize and slSize must equal
    slSizefalsestringStop loss size. Valid in TP/SL partial mode. Note: the value of tpSize and slSize must equal
    tpLimitPricefalsestringThe limit order price when take profit price is triggered. Only works when tpslMode=Partial and tpOrderType=Limit
    slLimitPricefalsestringThe limit order price when stop loss price is triggered. Only works when tpslMode=Partial and slOrderType=Limit
    tpOrderTypefalsestringThe order type when take profit is triggered. Market(default), Limit. For tpslMode=Full, it only supports tpOrderType=Market
    slOrderTypefalsestringThe order type when stop loss is triggered. Market(default), Limit. For tpslMode=Full, it only supports slOrderType=Market
    positionIdxtrueintegerUsed to identify positions in different position modes.
    • 0: one-way mode
    • 1: hedge-mode Buy side
    • 2: hedge-mode Sell side

    Response Parameters

    None


    Request Example

    POST /v5/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672283124270
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category":"linear",
    "symbol": "XRPUSDT",
    "takeProfit": "0.6",
    "stopLoss": "0.2",
    "tpTriggerBy": "MarkPrice",
    "slTriggerBy": "IndexPrice",
    "tpslMode": "Partial",
    "tpOrderType": "Limit",
    "slOrderType": "Limit",
    "tpSize": "50",
    "slSize": "50",
    "tpLimitPrice": "0.57",
    "slLimitPrice": "0.21",
    "positionIdx": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672283125359
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/close-pnl.html b/v5/pre-upgrade/close-pnl.html index a8120fc481..7bdbb1e1aa 100644 --- a/v5/pre-upgrade/close-pnl.html +++ b/v5/pre-upgrade/close-pnl.html @@ -4,13 +4,13 @@ Get Pre-upgrade Closed PnL | Bybit API Documentation - +

    Get Pre-upgrade Closed PnL

    Query user's closed profit and loss records from before you upgraded the account to a Unified account. The results are sorted by createdTime in descending order.

    For now, it only supports to query USDT perpetual, Inverse perpetual and futures.

    HTTP Request

    GET /v5/pre-upgrade/position/closed-pnl

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type linear, inverse
    symboltruestringSymbol name
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > sidestringBuy, Side
    > qtystringOrder qty
    > orderPricestringOrder price
    > orderTypestringOrder type. Market,Limit
    > execTypestringExec type. Trade, BustTrade, SessionSettlePnL, Settle
    > closedSizestringClosed size
    > cumEntryValuestringCumulated Position value
    > avgEntryPricestringAverage entry price
    > cumExitValuestringCumulated exit position value
    > avgExitPricestringAverage exit price
    > closedPnlstringClosed PnL
    > fillCountstringThe number of fills in a single order
    > leveragestringleverage
    > createdTimestringThe created time (ms)
    > updatedTimestringThe updated time (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/pre-upgrade/position/closed-pnl?category=linear&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682580911998
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "67836246-460e-4c52-a009-af0c3e1d12bc",
    "side": "Sell",
    "qty": "0.200",
    "orderPrice": "27203.40",
    "orderType": "Market",
    "execType": "Trade",
    "closedSize": "0.200",
    "cumEntryValue": "5588.88",
    "avgEntryPrice": "27944.40",
    "cumExitValue": "5726.4252",
    "avgExitPrice": "28632.13",
    "closedPnl": "204.25510011",
    "fillCount": "22",
    "leverage": "10",
    "createdTime": "1682487465732",
    "updatedTime": "1682487465732"
    }
    ],
    "category": "linear",
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1682580912259
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/delivery.html b/v5/pre-upgrade/delivery.html index e777d9b3b8..7bca99311a 100644 --- a/v5/pre-upgrade/delivery.html +++ b/v5/pre-upgrade/delivery.html @@ -4,13 +4,13 @@ Get Pre-upgrade Option Delivery Record | Bybit API Documentation - +

    Get Pre-upgrade Option Delivery Record

    Query delivery records of Option before you upgraded the account to a Unified account, sorted by deliveryTime in descending order

    HTTP Request

    GET /v5/pre-upgrade/asset/delivery-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. option
    symbolfalsestringSymbol name
    expDatefalsestringExpiry date. 25MAR22. Default: return all
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Used for pagination

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > deliveryTimenumberDelivery time (ms)
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > positionstringExecuted size
    > deliveryPricestringDelivery price
    > strikestringExercise price
    > feestringTrading fee
    > deliveryRplstringRealized PnL of the delivery
    nextPageCursorstringCursor. Used for pagination

    Request Example

    GET /v5/pre-upgrade/asset/delivery-record?category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686809005774
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21%3A0%2C21%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "ETH-14JUN23-1750-C",
    "side": "Buy",
    "deliveryTime": 1686729604507,
    "strike": "1750",
    "fee": "0",
    "position": "0.5",
    "deliveryPrice": "1740.25036667",
    "deliveryRpl": "0.175"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686796328492
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/execution.html b/v5/pre-upgrade/execution.html index 286af5f271..c45c47c3ca 100644 --- a/v5/pre-upgrade/execution.html +++ b/v5/pre-upgrade/execution.html @@ -4,14 +4,14 @@ Get Pre-upgrade Trade History | Bybit API Documentation - +

    Get Pre-upgrade Trade History

    Get users' execution records which occurred before you upgraded the account to a Unified account, sorted by execTime in descending order

    For now, it supports to query USDT perpetual, USDC perpetual, Inverse perpetual and futures, Option.

    tip
    • Response items will have sorting issues When 'execTime' is the same. This issue is currently being optimized and will be released at the end of October. If you want to receive real-time execution information, Use the websocket stream (recommended).
    • You may have multiple executions in a single order.
    • You can query by symbol, baseCoin, orderId and orderLinkId, and if you pass multiple params, the system will process them according to this priority: orderId > orderLinkId > symbol > baseCoin.

    HTTP Request

    GET /v5/pre-upgrade/execution/list

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type linear, inverse, option
    symbolfalsestringSymbol name
    orderIdfalsestringOrder ID
    orderLinkIdfalsestringUser customised order ID
    baseCoinfalsestringBase coin. Used for option
    startTimefalseintegerThe start timestamp (ms)
    endTimefalseintegerThe end timestamp (ms)
    execTypefalsestringExecution type
    limitfalseintegerLimit for data size per page. [1, 100]. Default: 50
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > orderIdstringOrder ID
    > orderLinkIdstringUser customized order ID
    > sidestringSide. Buy,Sell
    > orderPricestringOrder price
    > orderQtystringOrder qty
    > leavesQtystringThe remaining qty not executed
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type. If the order is not stop order, any type is not returned
    > execFeestringExecuted trading fee
    > execIdstringExecution ID
    > execPricestringExecution price
    > execQtystringExecution qty
    > execTypestringExecuted type
    > execValuestringExecuted order value
    > execTimestringExecuted timestamp(ms)
    > isMakerbooleanIs maker order. true: maker, false: taker
    > feeRatestringTrading fee rate
    > tradeIvstringImplied volatility
    > markIvstringImplied volatility of mark price
    > markPricestringThe mark price of the symbol when executing
    > indexPricestringThe index price of the symbol when executing
    > underlyingPricestringThe underlying price of the symbol when executing
    > blockTradeIdstringParadigm block trade ID
    > closedSizestringClosed position size
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/pre-upgrade/execution/list?category=linear&limit=1&execType=Funding&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682580752432
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "1682553600-BTCUSDT-592334-Sell",
    "orderLinkId": "",
    "side": "Sell",
    "orderPrice": "0.00",
    "orderQty": "0.000",
    "leavesQty": "0.000",
    "orderType": "UNKNOWN",
    "stopOrderType": "UNKNOWN",
    "execFee": "0.6364003",
    "execId": "11f1c4ed-ff20-4d73-acb7-96e43a917f25",
    "execPrice": "28399.90",
    "execQty": "0.011",
    "execType": "Funding",
    "execValue": "312.3989",
    "execTime": "1682553600000",
    "isMaker": false,
    "feeRate": "0.00203714",
    "tradeIv": "",
    "markIv": "",
    "markPrice": "28399.90",
    "indexPrice": "",
    "underlyingPrice": "",
    "blockTradeId": "",
    "closedSize": "0.000"
    }
    ],
    "nextPageCursor": "page_token%3D96184191%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1682580752717
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/order-list.html b/v5/pre-upgrade/order-list.html index 5a34d301c1..a8a2aed70f 100644 --- a/v5/pre-upgrade/order-list.html +++ b/v5/pre-upgrade/order-list.html @@ -4,13 +4,13 @@ Get Pre-upgrade Order History | Bybit API Documentation - +

    Get Pre-upgrade Order History

    After the account is upgraded to a Unified account, you can get the orders which occurred before the upgrade.

    info
    • can get all status in 7 days
    • can only get filled orders beyond 7 days

    HTTP Request

    GET /v5/pre-upgrade/order/history

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear, inverse, option
    symbolfalsestringSymbol name.
    • If not passed, return settleCoin=USDT by default
    • To get USDC perp, please pass symbol
    baseCoinfalsestringBase coin. Used for option query
    orderIdfalsestringOrder ID
    orderLinkIdfalsestringUser customised order ID
    orderFilterfalsestringOrder: active order, StopOrder: conditional order
    orderStatusfalsestringOrder status. Not supported for spot category
    startTimefalseintegerThe start timestamp (ms)
    • startTime and endTime must be passed together
    • If not passed, query the past 7 days data by default
    endTimefalseintegerThe end timestamp (ms)
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Use the nextPageCursor token from the response to retrieve the next page of the result set

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > blockTradeIdstringBlock trade ID
    > symbolstringSymbol name
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > isLeveragestringUseless field for those orders before upgraded
    > positionIdxintegerPosition index. Used to identify positions in different position modes
    > orderStatusstringOrder status
    > cancelTypestringCancel type
    > rejectReasonstringReject reason
    > avgPricestringAverage filled price. If unfilled, it is ""
    > leavesQtystringThe remaining qty not executed
    > leavesValuestringThe estimated value not executed
    > cumExecQtystringCumulative executed order qty
    > cumExecValuestringCumulative executed order value
    > cumExecFeestringCumulative executed trading fee
    > timeInForcestringTime in force
    > orderTypestringOrder type. Market,Limit
    > stopOrderTypestringStop order type
    > orderIvstringImplied volatility
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpTriggerBystringThe price type to trigger take profit
    > slTriggerBystringThe price type to trigger stop loss
    > triggerDirectionintegerTrigger direction. 1: rise, 2: fall
    > triggerBystringThe price type of trigger price
    > lastPriceOnCreatedstringLast price when place the order
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    > placeTypestringPlace type, option used. iv, price
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the UID has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)
    nextPageCursorstringRefer to the cursor request parameter

    Request Example

    GET /v5/pre-upgrade/order/history?category=linear&limit=1&orderStatus=Filled HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682576940304
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "67836246-460e-4c52-a009-af0c3e1d12bc",
    "orderLinkId": "",
    "blockTradeId": "",
    "symbol": "BTCUSDT",
    "price": "27203.40",
    "qty": "0.200",
    "side": "Sell",
    "isLeverage": "",
    "positionIdx": 0,
    "orderStatus": "Filled",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_NoError",
    "avgPrice": "28632.126000",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.200",
    "cumExecValue": "5726.4252",
    "cumExecFee": "3.43585512",
    "timeInForce": "IOC",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "0.00",
    "reduceOnly": true,
    "closeOnTrigger": true,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "createdTime": "1682487465732",
    "updatedTime": "1682487465735",
    "placeType": ""
    }
    ],
    "nextPageCursor": "page_token%3D69406%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1682576940540
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/settlement.html b/v5/pre-upgrade/settlement.html index bb1fbeacb4..b536bf4281 100644 --- a/v5/pre-upgrade/settlement.html +++ b/v5/pre-upgrade/settlement.html @@ -4,13 +4,13 @@ Get Pre-upgrade USDC Session Settlement | Bybit API Documentation - +

    Get Pre-upgrade USDC Session Settlement

    Query session settlement records of USDC perpetual before you upgrade the account to Unified account.

    HTTP Request

    GET /v5/pre-upgrade/asset/settlement-record

    Request Parameters

    ParameterRequiredTypeComments
    categorytruestringProduct type. linear
    symbolfalsestringSymbol name
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Used for pagination

    Response Parameters

    ParameterTypeComments
    categorystringProduct type
    listarrayObject
    > symbolstringSymbol name
    > sidestringBuy,Sell
    > sizestringPosition size
    > sessionAvgPricestringSettlement price
    > markPricestringMark price
    > realisedPnlstringRealised PnL
    > createdTimestringCreated time (ms)
    nextPageCursorstringCursor. Used for pagination

    Request Example

    GET /v5/pre-upgrade/asset/settlement-record?category=linear&symbol=ETHPERP&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686809850982
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "25%3A0%2C25%3A0",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "45.76",
    "symbol": "ETHPERP",
    "side": "Sell",
    "markPrice": "1668.44",
    "size": "-0.5",
    "createdTime": "1686787200000",
    "sessionAvgPrice": "1668.41"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686809851749
    }
    - + \ No newline at end of file diff --git a/v5/pre-upgrade/transaction-log.html b/v5/pre-upgrade/transaction-log.html index fbc4fbd04b..9e5cb9e18d 100644 --- a/v5/pre-upgrade/transaction-log.html +++ b/v5/pre-upgrade/transaction-log.html @@ -4,13 +4,13 @@ Get Pre-upgrade Transaction Log | Bybit API Documentation - +

    Get Pre-upgrade Transaction Log

    Query transaction logs which occurred in the USDC Derivatives wallet before the account was upgraded to a Unified account.

    You can get USDC Perpetual, Option records.

    HTTP Request

    GET /v5/pre-upgrade/account/transaction-log

    Request Parameters

    ParameterRequiredTypeComments
    categoryfalsestringProduct type. linear,option
    baseCoinfalsestringBaseCoin. e.g., BTC of BTCPERP
    typefalsestringTypes of transaction logs
    startTimefalseintegerThe start timestamp (ms) of creation
    endTimefalseintegerThe end timestamp (ms) of creation
    limitfalseintegerLimit for data size per page. [1, 50]. Default: 20
    cursorfalsestringCursor. Used for pagination

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > symbolstringSymbol name
    > categorystringProduct type
    > sidestringSide. Buy,Sell,None
    > transactionTimestringTransaction timestamp (ms)
    > typestringType
    > qtystringQuantity
    > sizestringSize
    > currencystringUSDC、USDT、BTC、ETH
    > tradePricestringTrade price
    > fundingstringFunding fee
    • Positive value means receiving funding fee
    • Negative value means deducting funding fee
    > feestringTrading fee
    • Positive fee value means expense
    • Negative fee value means rebates
    > cashFlowstringCash flow
    > changestringChange
    > cashBalancestringCash balance
    > feeRatestring
    • When type=TRADE, then it is trading fee rate
    • When type=SETTLEMENT, it means funding fee rate. For side=Buy, feeRate=market fee rate; For side=Sell, feeRate= - market fee rate
    > bonusChangestringThe change of bonus
    > tradeIdstringTrade ID
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    nextPageCursorstringCursor. Used for pagination

    Request Example

    GET /v5/pre-upgrade/account/transaction-log?category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686808288265
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21%3A0%2C21%3A0",
    "list": [
    {
    "symbol": "ETH-14JUN23-1750-C",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "",
    "orderId": "",
    "fee": "0",
    "change": "0",
    "cashFlow": "0",
    "transactionTime": "1686729604507",
    "type": "DELIVERY",
    "feeRate": "0",
    "bonusChange": "",
    "size": "0",
    "qty": "0.5",
    "cashBalance": "1001.1438885",
    "currency": "USDC",
    "category": "option",
    "tradePrice": "1740.25036667",
    "tradeId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686809006792
    }
    - + \ No newline at end of file diff --git a/v5/rate-limit.html b/v5/rate-limit.html index d4f60dfdd3..464fa6e70b 100644 --- a/v5/rate-limit.html +++ b/v5/rate-limit.html @@ -4,7 +4,7 @@ Rate Limit | Bybit API Documentation - + @@ -24,7 +24,7 @@ the part that does not exceed the limit will succeed. For example, in the 1 second, the remaining limit is 5, but a batch request containing 8 orders is placed at this time, then the first 5 orders will be successfully placed, and the 6-8th orders will report an error exceeding the limit, and these orders will fail.

    Classic account & UTAUTA Pro
    Level\ProductFuturesOptionSpotFuturesOptionSpot
    Default10/s10/s20/s10/s10/s20/s
    VIP 120/s20/s25/s20/s20/s25/s
    VIP 240/s40/s30/s40/s40/s30/s
    VIP 360/s60/s40/s60/s60/s40/s
    VIP 460/s60/s40/s60/s60/s40/s
    VIP 560/s60/s40/s60/s60/s40/s
    VIP Supreme60/s60/s40/s60/s60/s40/s
    PRO1100/s100/s50/s150/s150/s150/s
    PRO2150/s150/s75/s200/s200/s200/s
    PRO3200/s200/s100/s250/s250/s250/s
    PRO4200/s200/s100/s300/s300/s300/s
    PRO5200/s200/s100/s300/s300/s300/s

    How to increase API Limit

    Please contact your client manager or email to institutional_services@bybit.com with the following information. We will reply within 1-4 working days:

    1. Your name and your company details
    2. Your Bybit UID or registered email, and the assets you are trading
    3. General description of your trading strategy and reasons for higher rate limits
    4. Screenshot of previous monthly trading volume (maker/taker) on other platforms
    5. Optional: your order history in CSV format
    - + \ No newline at end of file diff --git a/v5/smp.html b/v5/smp.html index 2c23530178..690a3e83af 100644 --- a/v5/smp.html +++ b/v5/smp.html @@ -4,7 +4,7 @@ Self Match Prevention | Bybit API Documentation - + @@ -19,7 +19,7 @@ pre-existing orders to avoid an unexpected execution.

    1. The SMP Trade Group has a higher priority on SMP execution, so an individual UID is only taken into account when there is no SMP Trade Group on either side.

    2. Once the order is standing in the orderbook, its SMP flag doesn't matter any more. The system always follows the tag on the latter order.

    Examples:
    1st of Jan: UID1 joins SMP Trade Group A, and places Order1;
    2nd of Jan: UID1 is removed from SMP Trade Group A, but Order1 is still active and "New"

    • case1: If UID1 joined SMP Trade Group B, and placed Order2, if Order2 meets Order1, it will be executed since they belong to two different groups.
    • case2: If UID1 did not join any other groups after being removed from SMP Trade Group A, and placed Order2, if Order2 meets Order1, the SMP will be triggered because UID1 did not have a group when it placed Order2, so SMP was triggered at the UID level (the same UID1).

    How to manage my UIDs & SMP Trade Group?

    You can contact your institutional business manager or email Bybit via: institutional_services@bybit.com

    Supported OpenAPI Versions and Product Lines

    Product linesOpenAPI version supportedComments
    SpotV3 (normal account)
    V5 (unified & normal account)
    ContractContract V3 (normal account): USDT perpetual / Inverse perpetual & futures
    V5 (unified account): USDT perpetual / Inverse perpetual & futures / USDC perpetual & futures
    V5 (normal account): USDT perpetual / Inverse perpetual & futures
    OptionV5 (unified account)V1 has a default SMP at UID level
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/account-info.html b/v5/spot-margin-normal/account-info.html index 1e210da462..8ef0667624 100644 --- a/v5/spot-margin-normal/account-info.html +++ b/v5/spot-margin-normal/account-info.html @@ -4,13 +4,13 @@ Get Loan Account Info | Bybit API Documentation - +

    Get Loan Account Info

    Covers: Margin trade (Classic Account)

    HTTP Request

    GET /v5/spot-cross-margin-trade/account

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    acctBalanceSumstringTotal equity (BTC)
    debtBalanceSumstringTotal liability (BTC)
    loanAccountListarrayObject
    > freestringAvailable balance
    > intereststringOutstanding interest
    > loanstringOutstanding principle
    > remainAmountstringRemaining debt = interest + loan
    > lockedstringLocked amount
    > tokenIdstringCoin name
    > totalstringTotal
    riskRatestringRisk rate
    statusintegerLoan account status
    • 1: normal
    • 2: withdrawal/transfer restricted
    • 3: liquidation alert triggered
    • 4: liquidated
    switchStatusinteger0: margin trade off, 1: margin trade on

    Request Example

    GET /v5/spot-cross-margin-trade/account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751305868
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "acctBalanceSum": "0.455189592150138021",
    "debtBalanceSum": "0",
    "loanAccountList": [
    {
    "free": "0.01444",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "BTC",
    "total": "0.01444"
    },
    {
    "free": "0.21147048",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "ETH",
    "total": "0.21147048"
    },
    {
    "free": "7963.58978991849",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDT",
    "total": "7963.58978991849"
    },
    {
    "free": "1380.28832",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDC",
    "total": "1380.28832"
    }
    ],
    "riskRate": "0",
    "status": 1,
    "switchStatus": 1
    },
    "retExtInfo": {},
    "time": 1677751306287
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/borrow-order.html b/v5/spot-margin-normal/borrow-order.html index 9af784959a..334b01ab40 100644 --- a/v5/spot-margin-normal/borrow-order.html +++ b/v5/spot-margin-normal/borrow-order.html @@ -4,13 +4,13 @@ Get Borrow Order Detail | Bybit API Documentation - +

    Get Borrow Order Detail

    Covers: Margin trade (Classic Account)

    HTTP Request

    GET /v5/spot-cross-margin-trade/orders

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalselongThe start timestamp (ms)
    endTimefalselongThe end timestamp (ms)
    coinfalsestringCoin name
    statusfalseintegerStatus
    • 0(default):get all kinds of status
    • 1:uncleared
    • 2:cleared
    limitfalseintegerLimit for data size per page. [1, 500]. Default: 500

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > accountIdstringAccount ID
    > coinstringCoin name
    > createdTimenumberBorrow order created timestamp (ms)
    > idstringBorrow order ID
    > interestAmountstringTotal interest
    > interestBalancestringOutstanding interest
    > loanAmountstringPrincipal amount
    > loanBalancestringOutstanding principal
    > remainAmountstringRemaining debt = interestBalance + loanBalance
    > statusintegerStatus 1:uncleared, 2:cleared
    > typeintegerOrder Type 1: manual loan, 2: auto loan

    Request Example

    GET /v5/spot-cross-margin-trade/orders?coin=ETH&limit=1&status=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677754328650
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "accountId": "592335",
    "coin": "ETH",
    "createdTime": 1677751839000,
    "id": "21005",
    "interestAmount": "0.0001",
    "interestBalance": "0",
    "loanAmount": "10",
    "loanBalance": "0",
    "remainAmount": "0",
    "status": 2,
    "type": 1
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677754329096
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/borrow.html b/v5/spot-margin-normal/borrow.html index 1d9b58d161..45a44132b3 100644 --- a/v5/spot-margin-normal/borrow.html +++ b/v5/spot-margin-normal/borrow.html @@ -4,13 +4,13 @@ Borrow | Bybit API Documentation - +

    Borrow

    Covers: Margin trade (Classic Account)

    HTTP Request

    POST /v5/spot-cross-margin-trade/loan

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    qtytruestringAmount to borrow

    Response Parameters

    ParameterTypeComments
    transactIdstringBorrow transaction ID

    Request Example

    POST /v5/spot-cross-margin-trade/loan HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751838628
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 38

    {
    "coin": "ETH",
    "qty": "10"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transactId": "21005"
    },
    "retExtInfo": {},
    "time": 1677751839688
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/borrowable-data.html b/v5/spot-margin-normal/borrowable-data.html index 873c77ef89..3b531342fa 100644 --- a/v5/spot-margin-normal/borrowable-data.html +++ b/v5/spot-margin-normal/borrowable-data.html @@ -4,13 +4,13 @@ Get Borrowable Coin Info | Bybit API Documentation - +

    Get Borrowable Coin Info

    info

    Do not need authentication

    HTTP Request

    GET /v5/spot-cross-margin-trade/borrow-token

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > borrowingPrecisionintegerAccuracy of loan amount
    > repaymentPrecisionintegerAccuracy of repayment amount

    Request Example

    GET /v5/spot-cross-margin-trade/borrow-token?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "borrowingPrecision": 5,
    "coin": "ETH",
    "repaymentPrecision": 4
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750685331
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/interest-quota.html b/v5/spot-margin-normal/interest-quota.html index 0805e32635..7a585c1d89 100644 --- a/v5/spot-margin-normal/interest-quota.html +++ b/v5/spot-margin-normal/interest-quota.html @@ -4,13 +4,13 @@ Get Interest & Quota | Bybit API Documentation - +

    Get Interest & Quota

    Covers: Margin trade (Classic Account)

    HTTP Request

    GET /v5/spot-cross-margin-trade/loan-info

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name

    Response Parameters

    ParameterTypeComments
    coinstringCoin name
    interestRatestringDaily interest rate
    loanAbleAmountstringThe estimated amount can be loaned
    maxLoanAmountstringThe fixed loanable amount per user on platform

    Request Example

    GET /v5/spot-cross-margin-trade/loan-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750928871
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "ETH",
    "interestRate": "0.000054835",
    "loanAbleAmount": "19.220442066850037795",
    "maxLoanAmount": "300"
    },
    "retExtInfo": {},
    "time": 1677750929290
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/margin-data.html b/v5/spot-margin-normal/margin-data.html index b30914aca0..1187e52b1d 100644 --- a/v5/spot-margin-normal/margin-data.html +++ b/v5/spot-margin-normal/margin-data.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - +

    Get Margin Coin Info

    info

    Do not need authentication

    HTTP Request

    GET /v5/spot-cross-margin-trade/pledge-token

    Request Parameters

    ParameterRequiredTypeComments
    coinfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > coinstringCoin name
    > conversionRatestringConvert ratio
    > liquidationOrderintegerLiquidation order

    Request Example

    GET /v5/spot-cross-margin-trade/pledge-token?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "coin": "ETH",
    "conversionRate": "0.95",
    "liquidationOrder": 2
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750397414
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/repay-order.html b/v5/spot-margin-normal/repay-order.html index 0885ef2d9b..bf55460d77 100644 --- a/v5/spot-margin-normal/repay-order.html +++ b/v5/spot-margin-normal/repay-order.html @@ -4,13 +4,13 @@ Get Repayment Order Detail | Bybit API Documentation - +

    Get Repayment Order Detail

    Covers: Margin trade (Classic Account)

    HTTP Request

    GET /v5/spot-cross-margin-trade/repay-history

    Request Parameters

    ParameterRequiredTypeComments
    startTimefalselongThe start timestamp (ms)
    endTimefalselongThe end timestamp (ms)
    coinfalsestringCoin name
    limitfalseintegerLimit for data size per page. [1, 500], Default: 500

    Response Parameters

    ParameterTypeComments
    listarrayObject
    > accountIdstringAccount ID
    > coinstringCoin name
    > repaidAmountstringRepaid amount
    > repayIdstringRepay ID
    > repayMarginOrderIdstringRepay margin order ID
    > repayTimestringRepay timestamp (ms)
    > transactIdsarrayObject
    >> repaidIntereststringInterest repaid
    >> repaidPrincipalstringPrincipal repaid
    >> repaidSerialNumberstringRepayment No. (Borrowing Order)
    >> transactIdstringBorrowing transaction ID

    Request Example

    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

    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
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/repay.html b/v5/spot-margin-normal/repay.html index ae2af6a6e6..0c670470c0 100644 --- a/v5/spot-margin-normal/repay.html +++ b/v5/spot-margin-normal/repay.html @@ -4,13 +4,13 @@ Repay | Bybit API Documentation - +

    Repay

    Covers: Margin trade (Classic Account)

    HTTP Request

    POST /v5/spot-cross-margin-trade/repay

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringCoin name
    qtyfalsestringAmount to repay
    • qty is required when completeRepayment=0
    • qty is invalid when completeRepayment=1
    completeRepaymentfalseintegerWhether to pay off all debts. 0(default): false, 1: true

    Response Parameters

    ParameterTypeComments
    repayIdstringRepayment transaction ID

    Request Example

    POST /v5/spot-cross-margin-trade/repay HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751944347
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 66

    {
    "coin": "ETH",
    "qty": null,
    "completeRepayment": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "repayId": "19070"
    },
    "retExtInfo": {},
    "time": 1677751941219
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/switch-mode.html b/v5/spot-margin-normal/switch-mode.html index e9c986997b..f568b0e0ca 100644 --- a/v5/spot-margin-normal/switch-mode.html +++ b/v5/spot-margin-normal/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +

    Toggle Margin Trade

    Turn on / off spot margin trade

    Covers: Margin trade (Classic Account)

    HTTP Request

    POST /v5/spot-cross-margin-trade/switch

    Request Parameters

    ParameterRequiredTypeComments
    switchtrueinteger1: on, 0: off

    Response Parameters

    ParameterTypeComments
    switchStatusintegerMargin trade status. 1: on, 0: off

    Request Example

    POST /v5/spot-cross-margin-trade/switch HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677747804512
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 19

    {
    "switch": 0
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "switchStatus": 0
    },
    "retExtInfo": {},
    "time": 1677747804974
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-normal/vip-margin.html b/v5/spot-margin-normal/vip-margin.html index fdb8ac2588..6305029768 100644 --- a/v5/spot-margin-normal/vip-margin.html +++ b/v5/spot-margin-normal/vip-margin.html @@ -4,13 +4,13 @@ Get VIP Margin Data | Bybit API Documentation - +

    Get VIP Margin Data

    This margin data is for Classic account in particular.

    info

    Do not need authentication

    HTTP Request

    GET /v5/spot-cross-margin-trade/data

    Request Parameters

    ParameterRequiredTypeComments
    vipLevelfalsestringVip level
    currencyfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    vipCoinListarrayObject
    > listarrayObject
    >> borrowablebooleanWhether it is allowed to be borrowed
    >> collateralRatiostringCollateral ratio
    >> currencystringCoin name
    >> hourlyBorrowRatestringBorrow interest rate per hour
    >> liquidationOrderstringLiquidation order
    >> marginCollateralbooleanWhether it can be used as a margin collateral currency
    >> maxBorrowingAmountstringMax borrow amount
    > vipLevelstringVip level

    Request Example

    GET /v5/spot-cross-margin-trade/data?vipLevel=No VIP&currency=BTC HTTP/1.1
    Host: api.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "vipCoinList": [
    {
    "list": [
    {
    "borrowable": true,
    "collateralRatio": "0.95",
    "currency": "BTC",
    "hourlyBorrowRate": "0.000003964522",
    "liquidationOrder": "2",
    "marginCollateral": true,
    "maxBorrowingAmount": "5"
    }
    ],
    "vipLevel": "No VIP"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1692071381663
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-uta/set-leverage.html b/v5/spot-margin-uta/set-leverage.html index 5c4d34cce2..e8d3888fac 100644 --- a/v5/spot-margin-uta/set-leverage.html +++ b/v5/spot-margin-uta/set-leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set the user's maximum leverage in spot cross margin

    Covers: Margin trade (Unified Account)

    caution

    Your account needs to activate spot margin first; i.e., you must have finished the quiz on web / app.

    HTTP Request

    POST /v5/spot-margin-trade/set-leverage

    Request Parameters

    ParameterRequiredTypeComments
    leveragetruestringLeverage. [2, 10].

    Response Parameters

    None

    Request Example

    POST /v5/spot-margin-trade/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672299806626
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "leverage": "4"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672710944282
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-uta/status.html b/v5/spot-margin-uta/status.html index efdd1dae16..703b64eec9 100644 --- a/v5/spot-margin-uta/status.html +++ b/v5/spot-margin-uta/status.html @@ -4,13 +4,13 @@ Get Status And Leverage | Bybit API Documentation - +

    Get Status And Leverage

    Query the Spot margin status and leverage of Unified account

    Covers: Margin trade (Unified Account)

    HTTP Request

    GET /v5/spot-margin-trade/state

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    spotLeveragestringSpot margin leverage. Returns "" if the margin trade is turned off
    spotMarginModestringSpot margin status. 1: on, 0: off

    Request Example

    GET /v5/spot-margin-trade/state HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1692696840996
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "spotLeverage": "10",
    "spotMarginMode": "1"
    },
    "retExtInfo": {},
    "time": 1692696841231
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-uta/switch-mode.html b/v5/spot-margin-uta/switch-mode.html index ff5a892c36..1c2956e993 100644 --- a/v5/spot-margin-uta/switch-mode.html +++ b/v5/spot-margin-uta/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +

    Toggle Margin Trade

    Turn on / off spot margin trade

    Covers: Margin trade (Unified Account)

    caution

    Your account needs to activate spot margin first; i.e., you must have finished the quiz on web / app.

    HTTP Request

    POST /v5/spot-margin-trade/switch-mode

    Request Parameters

    ParameterRequiredTypeComments
    spotMarginModetruestring1: on, 0: off

    Response Parameters

    ParameterTypeComments
    spotMarginModestringSpot margin status. 1: on, 0: off

    Request Example

    POST /v5/spot-margin-trade/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672297794480
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "spotMarginMode": "0"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "spotMarginMode": "0"
    },
    "retExtInfo": {},
    "time": 1672297795542
    }
    - + \ No newline at end of file diff --git a/v5/spot-margin-uta/vip-margin.html b/v5/spot-margin-uta/vip-margin.html index d6e616489b..2906305342 100644 --- a/v5/spot-margin-uta/vip-margin.html +++ b/v5/spot-margin-uta/vip-margin.html @@ -4,13 +4,13 @@ Get VIP Margin Data | Bybit API Documentation - +

    Get VIP Margin Data

    This margin data is for Unified account in particular.

    info

    Do not need authentication

    HTTP Request

    GET /v5/spot-margin-trade/data

    Request Parameters

    ParameterRequiredTypeComments
    vipLevelfalsestringVip level
    currencyfalsestringCoin name

    Response Parameters

    ParameterTypeComments
    vipCoinListarrayObject
    > listarrayObject
    >> borrowablebooleanWhether it is allowed to be borrowed
    >> collateralRatiostringCollateral ratio
    >> currencystringCoin name
    >> hourlyBorrowRatestringBorrow interest rate per hour
    >> liquidationOrderstringLiquidation order
    >> marginCollateralbooleanWhether it can be used as a margin collateral currency
    >> maxBorrowingAmountstringMax borrow amount
    > vipLevelstringVip level

    Request Example

    GET /v5/spot-margin-trade/data?vipLevel=No VIP&currency=BTC HTTP/1.1
    Host: api-testnet.bybit.com

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "vipCoinList": [
    {
    "list": [
    {
    "borrowable": true,
    "collateralRatio": "0.95",
    "currency": "BTC",
    "hourlyBorrowRate": "0.0000015021220000",
    "liquidationOrder": "11",
    "marginCollateral": true,
    "maxBorrowingAmount": "3"
    }
    ],
    "vipLevel": "No VIP"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/v5/user/affiliate-info.html b/v5/user/affiliate-info.html index a5d706ee1c..b907451665 100644 --- a/v5/user/affiliate-info.html +++ b/v5/user/affiliate-info.html @@ -4,13 +4,13 @@ Get Affiliate User Info | Bybit API Documentation - +

    Get Affiliate User Info

    This API is used for affiliate to get their users information

    tip
    • Use master UID only
    • The api key can only have "Affiliate" permission
    • The transaction volume and deposit amount are the total amount of the user done on Bybit, and have nothing to do with commission settlement. Any transaction volume data related to commission settlement is subject to the Affiliate Portal.

    HTTP Request

    GET /v5/user/aff-customer-info

    Request Parameters

    ParameterRequiredTypeComments
    uidtruestringThe master account UID of affiliate's client

    Response Parameters

    ParameterTypeComments
    uidstringUID
    vipLevelstringVIP level
    takerVol30DaystringTaker volume in last 30 days (USDT). All volume related attributes below includes Derivatives, Option, Spot volume
    makerVol30DaystringMaker volume in last 30 days (USDT)
    tradeVol30DaystringTotal trading volume in last 30 days (USDT)
    depositAmount30DaystringDeposit amount in last 30 days (USDT)
    takerVol365DaystringTaker volume in the past year (USDT)
    makerVol365DaystringMaker volume in the past year (USDT)
    tradeVol365DaystringTotal trading volume in the past year (USDT)
    depositAmount365DaystringTotal deposit amount in the past year (USDT)
    totalWalletBalancestringWallet balance range
    • 1: less than 100 USDT value
    • 2: [100, 250) USDT value
    • 3: [250, 500) USDT value
    • 4: greater than 500 USDT value
    depositUpdateTimestringThe update date time (UTC) of deposit data
    volUpdateTimestringThe update date of volume data time (UTC)

    Request Example

    GET /v5/user/aff-customer-info?uid=1513500 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: uQ61dcX0lSe7ygD2EA
    X-BAPI-TIMESTAMP: 1685596324209
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: xxxxxx
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "uid": "1513500",
    "takerVol30Day": "10",
    "makerVol30Day": "20",
    "tradeVol30Day": "30",
    "depositAmount30Day": "90",
    "takerVol365Day": "100",
    "makerVol365Day": "500",
    "tradeVol365Day": "600",
    "depositAmount365Day": "1300",
    "totalWalletBalance": "4",
    "depositUpdateTime": "2023-06-01 05:12:04",
    "vipLevel": "99",
    "volUpdateTime": "2023-06-02 00:00:00"
    },
    "retExtInfo": {},
    "time": 1685596324508
    }
    - + \ No newline at end of file diff --git a/v5/user/apikey-info.html b/v5/user/apikey-info.html index a344713627..f33053377b 100644 --- a/v5/user/apikey-info.html +++ b/v5/user/apikey-info.html @@ -4,13 +4,13 @@ Get API Key Information | Bybit API Documentation - +

    Get API Key Information

    Get the information of the api key. Use the api key pending to be checked to call the endpoint. Both master and sub user's api key are applicable.

    tip

    Any permission can access this endpoint.

    HTTP Request

    GET /v5/user/query-api

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    idstringUnique ID. Internal use
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringAlways ""
    permissionsObjectThe types of permission
    > ContractTradearrayPermission of contract trade
    > SpotarrayPermission of spot
    > WalletarrayPermission of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and USDC perpetual.
    > DerivativesarrayPermission of derivatives
    > CopyTradingarrayPermission of copytrade. Not applicable to subaccount, always []
    > BlockTradearrayPermission of blocktrade. Not applicable to subaccount, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []
    ipsarrayIP bound
    typeintegerThe type of api key. 1:personal, 2:connected to the third-party app
    deadlineDayintegerThe remaining valid days of api key. Only for those api key with no IP bound or the password has been changed
    expiredAtdatetimeThe expiry day of the api key. Only for those api key with no IP bound or the password has been changed
    createdAtdatetimeThe create day of the api key
    unifiedintegerWhether the account to which the api key belongs is a unified margin account. 0:regular account; 1:unified margin account
    utaintegerWhether the account to which the account upgrade to unified trade account. 0:regular account; 1:unified trade account
    userIDintegerUser ID
    inviterIDintegerInviter ID (the UID of the account which invited this account to the platform)
    vipLevelstringVIP Level
    mktMakerLevelstringMarket maker level
    affiliateIDintegerAffiliate Id. 0 represents that there is no binding relationship.
    rsaPublicKeystringRsa public key
    isMasterbooleanIf this api key belongs to master account or not
    parentUidstringThe main account uid. Returns "0" when the endpoint is called by main account
    kycLevelstringPersonal account kyc level. LEVEL_DEFAULT, LEVEL_1LEVEL_2
    kycRegionstringPersonal account kyc region

    Request Example

    GET /v5/user/query-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676430842094
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "13770661",
    "note": "readwrite api key",
    "apiKey": "XXXXXX",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": [],
    "Affiliate": []
    },
    "ips": [
    "*"
    ],
    "type": 1,
    "deadlineDay": 66,
    "expiredAt": "2023-12-22T07:20:25Z",
    "createdAt": "2022-10-16T02:24:40Z",
    "unified": 0,
    "uta": 0,
    "userID": 24617703,
    "inviterID": 0,
    "vipLevel": "No VIP",
    "mktMakerLevel": "0",
    "affiliateID": 0,
    "rsaPublicKey": "",
    "isMaster": true,
    "parentUid": "0",
    "kycLevel": "LEVEL_DEFAULT",
    "kycRegion": ""
    },
    "retExtInfo": {},
    "time": 1697525990798
    }
    - + \ No newline at end of file diff --git a/v5/user/create-subuid-apikey.html b/v5/user/create-subuid-apikey.html index 1822a19b04..4a82707eef 100644 --- a/v5/user/create-subuid-apikey.html +++ b/v5/user/create-subuid-apikey.html @@ -4,13 +4,13 @@ Create Sub UID API Key | Bybit API Documentation - +

    Create Sub UID API Key

    To create new API key for those newly created sub UID. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    POST /v5/user/create-sub-api

    Request Parameters

    ParameterRequiredTypeComments
    subuidtrueintegerSub user Id
    notefalsestringSet a remark
    readOnlytrueinteger0:Read and Write. 1:Read only
    ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
    • don't pass ips or pass with "*" means no bind
    • No ip bound api key will be invalid after 90 days
    • api key without IP bound will be invalid after 7 days once the account password is changed
    permissionstrueObjectTick the types of permission.
    • one of below types must be passed, otherwise the error is thrown
    > ContractTradefalsearrayContract Trade. ["Order","Position"]
    > SpotfalsearraySpot Trade. ["SpotTrade"]
    > WalletfalsearrayWallet. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
    > DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
    > ExchangefalsearrayExchange. ["ExchangeHistory"]
    > CopyTradingfalsearrayCopytrade. ["CopyTrading"]

    Response Parameters

    ParameterTypeComments
    idstringUnique id. Internal used
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringThe secret paired with api key.
    • The secret can't be queried by GET api. Please keep it properly
    permissionsObjectThe types of permission
    > ContractTradearrayPermisson of contract trade
    > SpotarrayPermisson of spot
    > WalletarrayPermisson of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
    > DerivativesarrayPermission of Unified account
    > CopyTradingarrayPermission of copytrade
    > BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []

    Request Example

    POST /v5/user/create-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430005459
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subuid": 53888000,
    "note": "testxxx",
    "readOnly": 0,
    "permissions": {
    "Wallet": [
    "AccountTransfer"
    ]
    }
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "16651283",
    "note": "testxxx",
    "apiKey": "xxxxx",
    "readOnly": 0,
    "secret": "xxxxxxxx",
    "permissions": {
    "ContractTrade": [],
    "Spot": [],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    }
    },
    "retExtInfo": {},
    "time": 1676430007643
    }
    - + \ No newline at end of file diff --git a/v5/user/create-subuid.html b/v5/user/create-subuid.html index 50e0c3ae88..f014f9123b 100644 --- a/v5/user/create-subuid.html +++ b/v5/user/create-subuid.html @@ -4,13 +4,13 @@ Create Sub UID | Bybit API Documentation - +

    Create Sub UID

    Create a new sub user id. Use master account's api key.

    tip

    The API key must have one of the below permissions in order to call this endpoint

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    POST /v5/user/create-sub-member

    Request Parameters

    ParameterRequiredTypeComments
    usernametruestringGive a username of the new sub user id.
    • 6-16 characters, must include both numbers and letters.
    • cannot be the same as the exist or deleted one.
    passwordfalsestringSet the password for the new sub user id.
    • 8-30 characters, must include numbers, upper and lowercase letters.
    memberTypetrueinteger1: normal sub account, 6: custodial sub account
    switchfalseinteger
    • 0: turn off quick login (default)
    • 1: turn on quick login.
    isUtafalseboolean
    • true: create UTA account
    • false(default): create classic account
    notefalsestringSet a remark

    Response Parameters

    ParameterTypeComments
    uidstringSub user Id
    usernamestringGive a username of the new sub user id.
    • 6-16 characters, must include both numbers and letters.
    • cannot be the same as the exist or deleted one.
    memberTypeinteger1: normal sub account, 6: custodial sub account
    statusintegerThe status of the user account
    • 1: normal
    • 2: login banned
    • 4: frozen
    remarkstringThe remark

    Request Example

    POST /v5/user/create-sub-member HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXXX
    X-BAPI-API-KEY: XXXXXXX
    X-BAPI-TIMESTAMP: 1676429344202
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "username": "xxxxx",
    "memberType": 1,
    "switch": 1,
    "note": "test"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "uid": "53888000",
    "username": "xxxxx",
    "memberType": 1,
    "status": 1,
    "remark": "test"
    },
    "retExtInfo": {},
    "time": 1676429344734
    }
    - + \ No newline at end of file diff --git a/v5/user/froze-subuid.html b/v5/user/froze-subuid.html index a2b6123b6f..3404e8b156 100644 --- a/v5/user/froze-subuid.html +++ b/v5/user/froze-subuid.html @@ -4,13 +4,13 @@ Freeze Sub UID | Bybit API Documentation - +

    Freeze Sub UID

    Freeze Sub UID. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    POST /v5/user/frozen-sub-member

    Request Parameters

    ParameterRequiredTypeComments
    subuidtrueintegerSub user Id
    frozentrueinteger0:unfreeze, 1:freeze

    Response Parameters

    None

    Request Example

    POST /v5/user/frozen-sub-member HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430842094
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subuid": 53888001,
    "frozen": 1
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676430697553
    }
    - + \ No newline at end of file diff --git a/v5/user/modify-master-apikey.html b/v5/user/modify-master-apikey.html index 9b13a09e92..58e777369a 100644 --- a/v5/user/modify-master-apikey.html +++ b/v5/user/modify-master-apikey.html @@ -4,13 +4,13 @@ Modify Master API Key | Bybit API Documentation - +

    Modify Master API Key

    Modify the settings of master api key. Use the api key pending to be modified to call the endpoint. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"
    info

    Only the api key that calls this interface can be modified

    HTTP Request

    POST /v5/user/update-api

    Request Parameters

    ParameterRequiredTypeComments
    readOnlyfalseinteger0 (default):Read and Write. 1:Read only
    ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
    • don't pass ips or pass with "*" means no bind
    • No ip bound api key will be invalid after 90 days
    • api key will be invalid after 7 days once the account password is changed
    permissionsfalseObjectTick the types of permission. Don't send this param if you don't want to change the permission
    > ContractTradefalsearrayContract Trade. ["Order","Position"]
    > SpotfalsearraySpot Trade. ["SpotTrade"]
    > WalletfalsearrayWallet. ["AccountTransfer","SubMemberTransfer"]
    > OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
    > DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
    > CopyTradingfalsearrayCopytrade. ["CopyTrading"]
    > BlockTradefalsearrayBlocktrade. ["BlockTrade"]
    > ExchangefalsearrayExchange. ["ExchangeHistory"]
    > NFTfalsearrayNFT. ["NFTQueryProductList"]
    > AffiliatefalsearrayAffiliate. ["Affiliate"]
    • This permission is only useful for affiliate
    • If you need this permission, make sure you remove all other permissions

    Response Parameters

    ParameterTypeComments
    idstringUnique id. Internal used
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringAlways ""
    permissionsObjectThe types of permission
    > ContractTradearrayPermisson of contract trade
    > SpotarrayPermisson of spot
    > WalletarrayPermisson of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
    > DerivativesarrayPermission of Unified account
    > CopyTradingarrayPermission of copytrade. Not applicable to sub account, always []
    > BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []
    ipsarrayIP bound

    Request Example

    POST /v5/user/update-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431264739
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {
    "readOnly": null,
    "ips": "*",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    }
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "13770661",
    "note": "xxxxx",
    "apiKey": "xxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1676431265427
    }
    - + \ No newline at end of file diff --git a/v5/user/modify-sub-apikey.html b/v5/user/modify-sub-apikey.html index 40e3a5c8df..6a6da530d6 100644 --- a/v5/user/modify-sub-apikey.html +++ b/v5/user/modify-sub-apikey.html @@ -4,14 +4,14 @@ Modify Sub API Key | Bybit API Documentation - +

    Modify Sub API Key

    Modify the settings of sub api key. Use the sub account api key pending to be modified to call the endpoint or use master account api key to manage its sub account api key.

    tip

    The API key must have one of the below permissions in order to call this endpoint

    • sub API key: "Account Transfer", "Sub Member Transfer"
    • master API Key: "Account Transfer", "Sub Member Transfer", "Withdrawal"

    HTTP Request

    POST /v5/user/update-sub-api

    Request Parameters

    ParameterRequiredTypeComments
    apikeyfalsestringSub account api key
    • You must pass this param when you use master account manage sub account api key settings
    • If you use corresponding sub uid api key call this endpoint, apikey param cannot be passed, otherwise throwing an error
    readOnlyfalseinteger0 (default):Read and Write. 1:Read only
    ipsfalsestringSet the IP bind. example: "192.168.0.1,192.168.0.2"note:
    • don't pass ips or pass with "*" means no bind
    • No ip bound api key will be invalid after 90 days
    • api key will be invalid after 7 days once the account password is changed
    permissionsfalseObjectTick the types of permission. Don't send this param if you don't want to change the permission
    > ContractTradefalsearrayContract Trade. ["Order","Position"]
    > SpotfalsearraySpot Trade. ["SpotTrade"]
    > WalletfalsearrayWallet. ["AccountTransfer", "SubMemberTransferList"]
    > OptionsfalsearrayUSDC Contract. ["OptionsTrade"]
    > DerivativesfalsearrayThis param is depreciated because system will automatically add this permission according to your account is UTA or Classic
    > ExchangefalsearrayExchange. ["ExchangeHistory"]
    > CopyTradingfalsearrayCopytrade. ["CopyTrading"]

    Response Parameters

    ParameterTypeComments
    idstringUnique id. Internal used
    notestringThe remark
    apiKeystringApi key
    readOnlyinteger0:Read and Write. 1:Read only
    secretstringAlways ""
    permissionsObjectThe types of permission
    > ContractTradearrayPermisson of contract trade
    > SpotarrayPermisson of spot
    > WalletarrayPermisson of wallet
    > OptionsarrayPermission of USDC Contract. It supports trade option and usdc perpetual.
    > DerivativesarrayPermission of Unified account
    > CopyTradingarrayPermission of copytrade
    > BlockTradearrayPermission of blocktrade. Not applicable to sub account, always []
    > ExchangearrayPermission of exchange
    > NFTarrayPermission of NFT. Not applicable to sub account, always []
    ipsarrayIP bound

    Request Example

    POST /v5/user/update-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431795752
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "readOnly": 0,
    "ips": "*",
    "permissions": {
    "ContractTrade": [],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    }
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "16651472",
    "note": "testxxx",
    "apiKey": "xxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "Derivatives": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1676431796263
    }
    - + \ No newline at end of file diff --git a/v5/user/rm-master-apikey.html b/v5/user/rm-master-apikey.html index 792b5c99b1..26ba7bee4f 100644 --- a/v5/user/rm-master-apikey.html +++ b/v5/user/rm-master-apikey.html @@ -4,13 +4,13 @@ Delete Master API Key | Bybit API Documentation - +

    Delete Master API Key

    Delete the api key of master account. Use the api key pending to be delete to call the endpoint. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"
    danger

    BE CAREFUL! The API key used to call this interface will be invalid immediately.

    HTTP Request

    POST /v5/user/delete-api

    Request Parameters

    None

    Response Parameters

    None

    Request Example

    POST /v5/user/delete-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431576621
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {

    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676431577675
    }
    - + \ No newline at end of file diff --git a/v5/user/rm-sub-apikey.html b/v5/user/rm-sub-apikey.html index f34db9a11c..9016ec953f 100644 --- a/v5/user/rm-sub-apikey.html +++ b/v5/user/rm-sub-apikey.html @@ -4,14 +4,14 @@ Delete Sub API Key | Bybit API Documentation - +

    Delete Sub API Key

    Delete the api key of sub account. Use the sub api key pending to be delete to call the endpoint or use the master api key to delete corresponding sub account api key

    tip

    The API key must have one of the below permissions in order to call this endpoint.

    • sub API key: "Account Transfer", "Sub Member Transfer"
    • master API Key: "Account Transfer", "Sub Member Transfer", "Withdrawal"
    danger

    BE CAREFUL! The Sub account API key will be invalid immediately after calling the endpoint.

    HTTP Request

    POST /v5/user/delete-sub-api

    Request Parameters

    ParameterRequiredTypeComments
    apikeyfalsestringSub account api key
    • You must pass this param when you use master account manage sub account api key settings
    • If you use corresponding sub uid api key call this endpoint, apikey param cannot be passed, otherwise throwing an error

    Response Parameters

    None

    Request Example

    POST /v5/user/delete-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431922953
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {

    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676431924719
    }
    - + \ No newline at end of file diff --git a/v5/user/rm-subuid.html b/v5/user/rm-subuid.html index 84e9607cb4..bec4f5fa04 100644 --- a/v5/user/rm-subuid.html +++ b/v5/user/rm-subuid.html @@ -4,14 +4,14 @@ Delete Sub UID | Bybit API Documentation - +

    Delete Sub UID

    Delete a sub UID. Before deleting the UID, please make sure there is no asset.
    Use master user's api key**.

    tip

    The API key must have one of the below permissions in order to call this endpoint

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    POST /v5/user/del-submember

    Request Parameters

    ParameterRequiredTypeComments
    subMemberIdtruestringSub UID

    Response Parameters

    None

    Request Example

    POST /v5/user/del-submember HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698907012755
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json
    Content-Length: 34

    {
    "subMemberId": "112725187"
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698907012962
    }
    - + \ No newline at end of file diff --git a/v5/user/subuid-list.html b/v5/user/subuid-list.html index 8227bfd2fc..51a6864cb7 100644 --- a/v5/user/subuid-list.html +++ b/v5/user/subuid-list.html @@ -4,13 +4,13 @@ Get Sub UID List | Bybit API Documentation - +

    Get Sub UID List

    Get all sub UID of master account. Use master user's api key only.

    tip

    The API key must have one of the below permissions in order to call this endpoint..

    • master API key: "Account Transfer", "Subaccount Transfer", "Withdrawal"

    HTTP Request

    GET /v5/user/query-sub-members

    Request Parameters

    None

    Response Parameters

    ParameterTypeComments
    subMembersarrayObject
    > uidstringSub user Id
    > usernamestringUsername
    > memberTypeinteger1: normal sub account, 6: custodial sub account
    > statusintegerThe status of the user account
    • 1: normal
    • 2: login banned
    • 4: frozen
    > accountModeintegerThe account mode of the user account
    • 1: classic account
    • 2: UMA
    • 3: UTA
    > remarkstringThe remark

    Request Example

    GET /v5/user/query-sub-members HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430318405
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "subMembers": [
    {
    "uid": "53888001",
    "username": "xxx001",
    "memberType": 1,
    "status": 1,
    "remark": "test",
    "accountMode": 3
    },
    {
    "uid": "53888002",
    "username": "xxx002",
    "memberType": 6,
    "status": 1,
    "remark": "",
    "accountMode": 1
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676430319452
    }
    - + \ No newline at end of file diff --git a/v5/user/wallet-type.html b/v5/user/wallet-type.html index 56930ee3ca..5aff7188eb 100644 --- a/v5/user/wallet-type.html +++ b/v5/user/wallet-type.html @@ -4,13 +4,13 @@ Get UID Wallet Type | Bybit API Documentation - +

    Get UID Wallet Type

    Get available wallet types for the master account or sub account

    tip
    • Master api key: you can get master account and appointed sub account available wallet types, and support up to 200 sub UID in one request.
    • Sub api key: you can get its own available wallet types
    PRACTICE

    "FUND" - If you never deposit or transfer capital into it, this wallet type will not be shown in the array, but your account indeed has this wallet.

    • ["SPOT","OPTION","FUND","CONTRACT"] : Classic account and Funding wallet was operated before
    • ["SPOT","OPTION","CONTRACT"] : Classic account and Funding wallet is never operated
    • ["SPOT","UNIFIED","FUND","CONTRACT"] : UMA account and Funding wallet was operated before. (No UMA account after we forced upgrade to UTA)
    • ["SPOT","UNIFIED","CONTRACT"] : UMA account and Funding wallet is never operated. (No UMA account after we forced upgrade to UTA)
    • ["UNIFIED""FUND","CONTRACT"] : UTA account and Funding wallet was operated before.
    • ["UNIFIED","CONTRACT"] : UTA account and Funding wallet is never operated.

    HTTP Request

    GET /v5/user/get-member-type

    Request Parameters

    ParameterRequiredTypeComments
    memberIdsfalsestring
    • Query itself wallet types when not passed
    • When use master api key to query sub UID, master UID data is always returned in the top of the array
    • Multiple sub UID are supported, separated by commas
    • This param is ignored when you use sub account api key

    Response Parameters

    ParameterTypeComments
    accountsarrayObject
    > uidstringMaster/Sub user Id
    > accountTypearrayWallets array. SPOT, CONTRACT, FUND, OPTION, UNIFIED. Please check above practice to understand the value

    Request Example

    GET /v5/user/get-member-type HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686884973961
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "accounts": [
    {
    "uid": "533285",
    "accountType": [
    "SPOT",
    "UNIFIED",
    "FUND",
    "CONTRACT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686884974151
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/dcp.html b/v5/websocket/private/dcp.html index ef3d3d58e8..c6eedcff08 100644 --- a/v5/websocket/private/dcp.html +++ b/v5/websocket/private/dcp.html @@ -4,13 +4,13 @@ Dcp | Bybit API Documentation - +

    Dcp

    Subscribe to the dcp stream to trigger DCP function.

    For example, connection A subscribes "dcp", connection B does not and connection C subscribes "dcp".

    1. If A is alive, B is dead, C is alive, then this case will not trigger DCP.
    2. If A is alive, B is dead, C is dead, then this case will not trigger DCP.
    3. If A is dead, B is alive, C is dead, then DCP is triggered when reach the timeWindow threshold

    To sum up, for those private connections subscribing "dcp" topic are all dead, then DCP will be triggered.

    Topic: dcp

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "dcp"
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/execution.html b/v5/websocket/private/execution.html index 5e72155f57..fbb3c83787 100644 --- a/v5/websocket/private/execution.html +++ b/v5/websocket/private/execution.html @@ -4,14 +4,14 @@ Execution | Bybit API Documentation - +

    Execution

    Subscribe to the execution stream to see your executions in real-time.

    tip

    You may have multiple executions for one order in a single message.

    All-In-One Topic: execution
    Categorised Topic: execution.spot, execution.linear, execution.inverse, execution.option

    info
    • All-In-One topic and Categorised topic cannot be in the same subscription request
    • All-In-One topic: Allow you to listen to all categories (spot, linear, inverse, option) websocket updates
    • Categorised Topic: Allow you to listen only to specific category websocket updates

    Response Parameters

    ParameterTypeComments
    idstringMessage ID
    topicstringTopic name
    creationTimenumberData created timestamp (ms)
    dataarrayObject
    > categorystringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse.
    > symbolstringSymbol name
    > isLeveragestringWhether to borrow. Unified spot only. 0: false, 1: true. . Classic spot is not supported, always 0
    > orderIdstringOrder ID
    > orderLinkIdstringUser customized order ID
    > sidestringSide. Buy,Sell
    > orderPricestringOrder price. Classic spot is not supported
    > orderQtystringOrder qty. Classic spot is not supported
    > leavesQtystringThe remaining qty not executed. Classic spot is not supported
    > orderTypestringOrder type. Market,Limit. Classic spot is not supported
    > stopOrderTypestringStop order type. If the order is not stop order, any type is not returned. Classic spot is not supported
    > execFeestringExecuted trading fee. You can get spot fee currency instruction here Classic spot is not supported
    > execIdstringExecution ID
    > execPricestringExecution price
    > execQtystringExecution qty
    > execTypestringExecuted type. Classic spot is not supported
    > execValuestringExecuted order value. Classic spot is not supported
    > execTimestringExecuted timestamp(ms)
    > isMakerbooleanIs maker order. true: maker, false: taker
    > feeRatestringTrading fee rate. Classic spot is not supported
    > tradeIvstringImplied volatility. Valid for option
    > markIvstringImplied volatility of mark price. Valid for option
    > markPricestringThe mark price of the symbol when executing. Valid for option
    > indexPricestringThe index price of the symbol when executing. Valid for option
    > underlyingPricestringThe underlying price of the symbol when executing. Valid for option
    > blockTradeIdstringParadigm block trade ID
    > closedSizestringClosed position size
    > seqlongCross sequence, used to associate each fill and each position update
    • The seq will be the same when conclude multiple transactions at the same time
    • Different symbols may have the same seq, please use seq + symbol to check unique

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "execution"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.execution_stream(callback=handle_message)
    while True:
    sleep(1)

    Stream Example

    {
    "id": "592324803b2785-26fa-4214-9963-bdd4727f07be",
    "topic": "execution",
    "creationTime": 1672364174455,
    "data": [
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "execFee": "0.005061",
    "execId": "7e2ae69c-4edf-5800-a352-893d52b446aa",
    "execPrice": "0.3374",
    "execQty": "25",
    "execType": "Trade",
    "execValue": "8.435",
    "isMaker": false,
    "feeRate": "0.0006",
    "tradeIv": "",
    "markIv": "",
    "blockTradeId": "",
    "markPrice": "0.3391",
    "indexPrice": "",
    "underlyingPrice": "",
    "leavesQty": "0",
    "orderId": "f6e324ff-99c2-4e89-9739-3086e47f9381",
    "orderLinkId": "",
    "orderPrice": "0.3207",
    "orderQty": "25",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "side": "Sell",
    "execTime": "1672364174443",
    "isLeverage": "0",
    "closedSize": "",
    "seq": 4688002127
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/greek.html b/v5/websocket/private/greek.html index 4b4aad7b50..e6166263a7 100644 --- a/v5/websocket/private/greek.html +++ b/v5/websocket/private/greek.html @@ -4,13 +4,13 @@ Greek | Bybit API Documentation - +

    Greek

    Subscribe to the greeks stream to see changes to your greeks data in real-time. option only.

    Topic: greeks

    Response Parameters

    ParameterTypeComments
    idstringMessage ID
    topicstringTopic name
    creationTimenumberData created timestamp (ms)
    dataarrayObject
    > baseCoinstringBase coin
    > totalDeltastringDelta value
    > totalGammastringGamma value
    > totalVegastringVega value
    > totalThetastringTheta value

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "greeks"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.greek_stream(callback=handle_message)
    while True:
    sleep(1)

    Stream Example

    {
    "id": "592324fa945a30-2603-49a5-b865-21668c29f2a6",
    "topic": "greeks",
    "creationTime": 1672364262482,
    "data": [
    {
    "baseCoin": "ETH",
    "totalDelta": "0.06999986",
    "totalGamma": "-0.00000001",
    "totalVega": "-0.00000024",
    "totalTheta": "0.00001314"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/order.html b/v5/websocket/private/order.html index 12001cfb7c..7105b0d252 100644 --- a/v5/websocket/private/order.html +++ b/v5/websocket/private/order.html @@ -4,14 +4,14 @@ Order | Bybit API Documentation - +

    Order

    Subscribe to the order stream to see changes to your orders in real-time.

    All-In-One Topic: order
    Categorised Topic: order.spot, order.linear, order.inverse, order.option

    info
    • All-In-One topic and Categorised topic cannot be in the same subscription request
    • All-In-One topic: Allow you to listen to all categories (spot, linear, inverse, option) websocket updates
    • Categorised Topic: Allow you to listen only to specific category websocket updates

    Response Parameters

    ParameterTypeComments
    idstringMessage ID
    topicstringTopic name
    creationTimenumberData created timestamp (ms)
    dataarrayObject
    > categorystringProduct type
    • Unified account: spot, linear, inverse, option
    • Classic account: spot, linear, inverse.
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID
    > isLeveragestringWhether to borrow. Unified spot only. 0: false, 1: true. . Classic spot is not supported, always 0
    > blockTradeIdstringBlock trade ID
    > symbolstringSymbol name
    > pricestringOrder price
    > qtystringOrder qty
    > sidestringSide. Buy,Sell
    > positionIdxintegerPosition index. Used to identify positions in different position modes
    > orderStatusstringOrder status
    > cancelTypestringCancel type
    > rejectReasonstringReject reason. Classic spot is not supported
    > avgPricestringAverage filled price. If unfilled, it is ""
    • For normal account USDT Perp and Inverse derivatives trades, if a partially filled order, and the final orderStatus is Cancelled, then avgPrice is "0"
    • For Classic spot is not supported, it is always ""
    > leavesQtystringThe remaining qty not executed. Classic spot is not supported
    > leavesValuestringThe remaining value not executed. Classic spot is not supported
    > cumExecQtystringCumulative executed order qty
    > cumExecValuestringCumulative executed order value
    > cumExecFeestringCumulative executed trading fee. For normal spot, it is the execution fee per single fill
    > feeCurrencystringTrading fee currency for Spot only. Please understand Spot trading fee currency here
    > timeInForcestringTime in force
    > orderTypestringOrder type. Market,Limit. For TP/SL order, it means the order type after triggered
    > stopOrderTypestringStop order type
    > ocoTriggerTypestringThe trigger type of Spot OCO order.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. Classic spot is not supported
    > orderIvstringImplied volatility
    > triggerPricestringTrigger price. If stopOrderType=TrailingStop, it is activate price. Otherwise, it is trigger price
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > tpslModestringTP/SL mode, Full: entire position for TP/SL. Partial: partial position tp/sl. Spot does not have this field, and Option returns always ""
    > tpLimitPricestringThe limit order price when take profit price is triggered
    > slLimitPricestringThe limit order price when stop loss price is triggered
    > tpTriggerBystringThe price type to trigger take profit
    > slTriggerBystringThe price type to trigger stop loss
    > triggerDirectionintegerTrigger direction. 1: rise, 2: fall
    > triggerBystringThe price type of trigger price
    > lastPriceOnCreatedstringLast price when place the order
    > reduceOnlybooleanReduce only. true means reduce position size
    > closeOnTriggerbooleanClose on trigger. What is a close on trigger order?
    > placeTypestringPlace type, option used. iv, price
    > smpTypestringSMP execution type
    > smpGroupintegerSmp group ID. If the UID has no group, it is 0 by default
    > smpOrderIdstringThe counterparty's orderID which triggers this SMP execution
    > createdTimestringOrder created timestamp (ms)
    > updatedTimestringOrder updated timestamp (ms)

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "order"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.order_stream(callback=handle_message)
    while True:
    sleep(1)

    Stream Example

    {
    "id": "5923240c6880ab-c59f-420b-9adb-3639adc9dd90",
    "topic": "order",
    "creationTime": 1672364262474,
    "data": [
    {
    "symbol": "ETH-30DEC22-1400-C",
    "orderId": "5cf98598-39a7-459e-97bf-76ca765ee020",
    "side": "Sell",
    "orderType": "Market",
    "cancelType": "UNKNOWN",
    "price": "72.5",
    "qty": "1",
    "orderIv": "",
    "timeInForce": "IOC",
    "orderStatus": "Filled",
    "orderLinkId": "",
    "lastPriceOnCreated": "",
    "reduceOnly": false,
    "leavesQty": "",
    "leavesValue": "",
    "cumExecQty": "1",
    "cumExecValue": "75",
    "avgPrice": "75",
    "blockTradeId": "",
    "positionIdx": 0,
    "cumExecFee": "0.358635",
    "createdTime": "1672364262444",
    "updatedTime": "1672364262457",
    "rejectReason": "EC_NoError",
    "stopOrderType": "",
    "tpslMode": "",
    "triggerPrice": "",
    "takeProfit": "",
    "stopLoss": "",
    "tpTriggerBy": "",
    "slTriggerBy": "",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "triggerDirection": 0,
    "triggerBy": "",
    "closeOnTrigger": false,
    "category": "option",
    "placeType": "price",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "feeCurrency": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/position.html b/v5/websocket/private/position.html index 9aee2cbd9c..e2cb4158b0 100644 --- a/v5/websocket/private/position.html +++ b/v5/websocket/private/position.html @@ -4,14 +4,14 @@ Position | Bybit API Documentation - +

    Position

    Subscribe to the position stream to see changes to your position data in real-time.

    All-In-One Topic: position
    Categorised Topic: position.linear, position.inverse, position.option

    info
    • All-In-One topic and Categorised topic cannot be in the same subscription request
    • All-In-One topic: Allow you to listen to all categories (linear, inverse, option) websocket updates
    • Categorised Topic: Allow you to listen only to specific category websocket updates

    Response Parameters

    ParameterTypeComments
    idstringMessage ID
    topicstringTopic name
    creationTimenumberData created timestamp (ms)
    dataarrayObject
    > categorystringProduct type
    > symbolstringSymbol name
    > sidestringPosition side. Buy,Sell
    > sizestringPosition size
    > positionIdxintegerUsed to identify positions in different position modes
    > tradeModeintegerTrade mode
    • Classic & UTA (inverse): 0: cross-margin, 1: isolated margin
    • UTA: depreciated, always 0
    > positionValuestringPosition value
    > riskIdintegerRisk limit ID. Note: for portfolio margin mode, it returns 0, which the risk limit value is invalid
    > riskLimitValuestringRisk limit value corresponding to riskId. Note: for portfolio margin mode, it returns "", which the risk limit value is invalid
    > entryPricestringEntry price
    > markPricestringMark price
    > leveragestringLeverage. Note: for portfolio margin mode, it returns "", which the leverage value is invalid
    > positionBalancestringPosition margin. For portfolio margin mode, it returns ""
    > autoAddMarginintegerWhether to add margin automatically. 0: false, 1: true. For UTA, it is meaningful only when UTA enables ISOLATED_MARGIN
    > positionMMstringPosition maintenance margin. Note: for portfolio margin mode, it returns ""
    > positionIMstringPosition initial margin. Note: for portfolio margin mode, it returns ""
    > liqPricestringPosition liquidation price
    • UTA (inverse) & UTA (isolated margin enabled) & Classic account: it is the real price for isolated and cross positions, and keeps "" when liqPrice <= minPrice or liqPrice >= maxPrice
    • UTA (Cross margin mode): it is an estimated price for cross positions(because the unified mode controls the risk rate according to the account), and keeps "" when liqPrice <= minPrice or liqPrice >= maxPrice
    However, this field is empty for Portfolio Margin Mode, and no liquidation price will be provided
    > bustPricestringEst.bankruptcy price. "" for Unified trade(spot/linear/options)
    > tpslModestringDepreciated, meaningless here, always "Full". Spot does not return this field. Option returns ""
    > takeProfitstringTake profit price
    > stopLossstringStop loss price
    > trailingStopstringTrailing stop
    > unrealisedPnlstringUnrealised profit and loss
    > cumRealisedPnlstringCumulative realised pnl
    • Futures & Perp: it is the all time cumulative realised P&L
    • Option: it is the realised P&L when you hold that position
    > positionStatusstringPosition status. Normal, Liq, Adl
    > adlRankIndicatorintegerAuto-deleverage rank indicator. What is Auto-Deleveraging?
    > isReduceOnlybooleanUseful when Bybit lower the risk limit
    • true: Only allowed to reduce the position. You can consider a series of measures, e.g., lower the risk limit, decrease leverage or reduce the position, add margin, or cancel orders, after these operations, you can call confirm new risk limit endpoint to check if your position can be removed the reduceOnly mark
    • false: There is no restriction, and it means your position is under the risk when the risk limit is systematically adjusted
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > mmrSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the MMR will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the MMR had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > leverageSysUpdatedTimestringUseful when Bybit lower the risk limit
    • When isReduceOnly=true: the timestamp (ms) when the leverage will be forcibly adjusted by the system
    • When isReduceOnly=false: the timestamp when the leverage had been adjusted by system
    • It returns the timestamp when the system operates, and if you manually operate, there is no timestamp
    • Keeps "" by default, if there was a lower risk limit system adjustment previously, it shows that system operation timestamp
    • Only meaningful for isolated margin & cross margin of USDT Perp, USDC Perp, USDC Futures, Inverse Perp and Inverse Futures, meaningless for others
    > createdTimestringPosition created timestamp (ms)
    > updatedTimestringPosition data updated timestamp (ms)
    > seqlongCross sequence, used to associate each fill and each position update
    • Different symbols may have the same seq, please use seq + symbol to check unique
    • Returns "-1" if the symbol has never been traded
    • Returns the seq updated by the last transaction when there are setting like leverage, risk limit

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "position"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.position_stream(callback=handle_message)
    while True:
    sleep(1)

    Stream Example

    {
    "id": "1003076014fb7eedb-c7e6-45d6-a8c1-270f0169171a",
    "topic": "position",
    "creationTime": 1697682317044,
    "data": [
    {
    "positionIdx": 2,
    "tradeMode": 0,
    "riskId": 1,
    "riskLimitValue": "2000000",
    "symbol": "BTCUSDT",
    "side": "",
    "size": "0",
    "entryPrice": "0",
    "leverage": "10",
    "positionValue": "0",
    "positionBalance": "0",
    "markPrice": "28184.5",
    "positionIM": "0",
    "positionMM": "0",
    "takeProfit": "0",
    "stopLoss": "0",
    "trailingStop": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "-25.06579337",
    "createdTime": "1694402496913",
    "updatedTime": "1697682317038",
    "tpslMode": "Full",
    "liqPrice": "0",
    "bustPrice": "",
    "category": "linear",
    "positionStatus": "Normal",
    "adlRankIndicator": 0,
    "autoAddMargin": 0,
    "leverageSysUpdatedTime": "",
    "mmrSysUpdatedTime": "",
    "seq": 8327597863,
    "isReduceOnly": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/private/wallet.html b/v5/websocket/private/wallet.html index d5aa3e18dd..d14ece83a3 100644 --- a/v5/websocket/private/wallet.html +++ b/v5/websocket/private/wallet.html @@ -4,13 +4,13 @@ Wallet | Bybit API Documentation - +

    Wallet

    Subscribe to the wallet stream to see changes to your wallet in real-time.

    Topic: wallet

    Response Parameters

    ParameterTypeComments
    idstringMessage ID
    topicstringTopic name
    creationTimenumberData created timestamp (ms)
    dataarrayObject
    > accountTypestringAccount type.
    • Unified account: UNIFIED (spot/linear/options), CONTRACT(inverse)
    • Classic account: CONTRACT, SPOT
    > accountLTVstringAccount LTV: account total borrowed size / (account total equity + account total borrowed size). In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > accountIMRatestringInitial Margin Rate: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > accountMMRatestringMaintenance Margin Rate: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalEquitystringEquity of account converted to usd:Account Margin Balance Base Coin + Account Option Value Base Coin. In non-unified mode & unified (inverse), the field will be returned as an empty string.
    > totalWalletBalancestringWallet Balance of account converted to usd:∑ Asset Wallet Balance By USD value of each asset。In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalMarginBalancestringMargin Balance of account converted to usd:totalWalletBalance + totalPerpUPL. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalAvailableBalancestringAvailable Balance of account converted to usd:Regular mode:totalMarginBalance - totalInitialMargin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalPerpUPLstringUnrealised P&L of Perpetuals and USDC Futures of account converted to usd:∑ Each Perp and USDC Futures upl by base coin. In non-unified mode & unified (inverse), the field will be returned as an empty string.
    > totalInitialMarginstringInitial Margin of account converted to usd:∑ Asset Total Initial Margin Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > totalMaintenanceMarginstringMaintenance Margin of account converted to usd: ∑ Asset Total Maintenance Margin Base Coin. In non-unified mode & unified (inverse) & unified (isolated_margin), the field will be returned as an empty string.
    > coinarrayObject
    >> coinstringCoin name, such as BTC, ETH, USDT, USDC
    >> equitystringEquity of current coin
    >> usdValuestringUSD value of current coin. If this coin cannot be collateral, then it is 0
    >> walletBalancestringWallet balance of current coin
    >> freestringAvailable balance for Spot wallet. This is a unique field for Classic SPOT
    >> lockedstringLocked balance due to the Spot open order
    >> borrowAmountstringBorrow amount of current coin
    >> availableToBorrowstringDepreciated field, always return "" due to feature of main-sub UID sharing borrow quota. Please refer to availableToBorrow in the Get Collateral Info
    >> availableToWithdrawstringAvailable amount to withdraw of current coin
    >> accruedIntereststringAccrued interest
    >> totalOrderIMstringPre-occupied margin for order. For portfolio margin mode, it returns ""
    >> totalPositionIMstringSum of initial margin of all positions + Pre-occupied liquidation fee. For portfolio margin mode, it returns ""
    >> totalPositionMMstringSum of maintenance margin for all positions. For portfolio margin mode, it returns ""
    >> unrealisedPnlstringUnrealised P&L
    >> cumRealisedPnlstringCumulative Realised P&L
    >> bonusstringBonus. This is a unique field for UNIFIED account
    >> collateralSwitchbooleanWhether it can be used as a margin collateral currency (platform)
    • When marginCollateral=false, then collateralSwitch is meaningless
    • This is a unique field for UNIFIED account
    >> marginCollateralbooleanWhether the collateral is turned on by user (user)
    • When marginCollateral=true, then collateralSwitch is meaningful
    • This is a unique field for UNIFIED account

    Subscribe Example

    {
    "op": "subscribe",
    "args": [
    "wallet"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.wallet_stream(callback=handle_message)
    while True:
    sleep(1)

    Stream Example

    {
    "id": "5923248e5d0ee3-faeb-4864-87e4-9cd63f785c1b",
    "topic": "wallet",
    "creationTime": 1690873065683,
    "data": [
    {
    "accountIMRate": "0.4782",
    "accountMMRate": "0.0151",
    "totalEquity": "19620.93864593",
    "totalWalletBalance": "18331.93856433",
    "totalMarginBalance": "18230.83251552",
    "totalAvailableBalance": "9511.52641225",
    "totalPerpUPL": "-101.10604881",
    "totalInitialMargin": "8719.30610327",
    "totalMaintenanceMargin": "277.05763376",
    "coin": [
    {
    "coin": "USDC",
    "equity": "0",
    "usdValue": "0",
    "walletBalance": "0",
    "availableToWithdraw": "0",
    "availableToBorrow": "1500000",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "-1100.6552094",
    "bonus": "0",
    "collateralSwitch": true,
    "marginCollateral": true,
    "locked": "0"
    },
    {
    "coin": "BTC",
    "equity": "0",
    "usdValue": "0",
    "walletBalance": "0",
    "availableToWithdraw": "0",
    "availableToBorrow": "3",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "0",
    "bonus": "0",
    "collateralSwitch": false,
    "marginCollateral": true,
    "locked": "0"
    },
    {
    "coin": "USDT",
    "equity": "4.93036732",
    "usdValue": "4.9306623",
    "walletBalance": "106.03036732",
    "availableToWithdraw": "0",
    "availableToBorrow": "2500000",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "7539.624",
    "totalPositionIM": "1179.1604584",
    "totalPositionMM": "61.4170584",
    "unrealisedPnl": "-101.1",
    "cumRealisedPnl": "-55295.06268939",
    "bonus": "0",
    "collateralSwitch": true,
    "marginCollateral": true,
    "locked": "0"
    }
    ],
    "accountLTV": "0",
    "accountType": "UNIFIED"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/etp-kline.html b/v5/websocket/public/etp-kline.html index fd014977f5..b480a27e06 100644 --- a/v5/websocket/public/etp-kline.html +++ b/v5/websocket/public/etp-kline.html @@ -4,14 +4,14 @@ LT Kline | Bybit API Documentation - +

    LT Kline

    Subscribe to the leveraged token kline stream.

    tip

    If confirm=true, this means that the candle has closed. Otherwise, the candle is still open and updating.

    Available intervals:

    • 1 3 5 15 30 (min)
    • 60 120 240 360 720 (min)
    • D (day)
    • W (week)
    • M (month)

    Push frequency: 1-60s

    Topic:
    kline_lt.{interval}.{symbol} e.g., kline_lt.30.BTC3SUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > startnumberThe start timestamp (ms)
    > endnumberThe end timestamp (ms). It is current timestamp if it does not reach to the end time of candle
    > intervalstringKline interval
    > openstringOpen price
    > closestringClose price
    > highstringHighest price
    > lowstringLowest price
    > confirmbooleanWeather the tick is ended or not
    > timestampnumberThe timestamp (ms) of the last matched order in the candle

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_kline_stream(
    interval=30,
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "type": "snapshot",
    "topic": "kline_lt.5.EOS3LUSDT",
    "data": [
    {
    "start": 1672325100000,
    "end": 1672325399999,
    "interval": "5",
    "open": "0.416039541212402799",
    "close": "0.41477848043290448",
    "high": "0.416039541212402799",
    "low": "0.409734237314911206",
    "confirm": false,
    "timestamp": 1672325322393
    }
    ],
    "ts": 1672325322393
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/etp-nav.html b/v5/websocket/public/etp-nav.html index c72e7071ee..24f881cd02 100644 --- a/v5/websocket/public/etp-nav.html +++ b/v5/websocket/public/etp-nav.html @@ -4,14 +4,14 @@ LT Nav | Bybit API Documentation - +

    LT Nav

    Subscribe to the leveraged token nav stream.

    Push frequency: 300ms

    Topic:
    lt.{symbol} e.g.,lt.BTC3SUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > timenumberThe generated timestamp of nav
    > symbolstringSymbol name
    > navstringNet asset value
    > basketPositionstringTotal position value = basket value * total circulation
    > leveragestringLeverage
    > basketLoanstringBasket loan
    > circulationstringCirculation
    > basketstringBasket

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_nav_stream(
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "lt.EOS3LUSDT",
    "ts": 1672325564669,
    "type": "snapshot",
    "data": {
    "symbol": "EOS3LUSDT",
    "time": 1672325564554,
    "nav": "0.413517419653406162",
    "basketPosition": "1.261060779498318641",
    "leverage": "2.656197506416192150",
    "basketLoan": "-0.684866519289629374",
    "circulation": "72767.309468460367138199",
    "basket": "91764.000000292013277472"
    }
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/etp-ticker.html b/v5/websocket/public/etp-ticker.html index 9e4ab09ad2..44ed90c1ec 100644 --- a/v5/websocket/public/etp-ticker.html +++ b/v5/websocket/public/etp-ticker.html @@ -4,14 +4,14 @@ LT Ticker | Bybit API Documentation - +

    LT Ticker

    Subscribe to the leveraged token ticker stream.

    Push frequency: 300ms

    Topic:
    tickers_lt.{symbol} e.g.,tickers_lt.BTC3SUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > symbolstringSymbol name
    > price24hPcntstringMarket price change percentage in the past 24 hours
    > lastPricestringThe last price
    > prevPrice24hstringMarket price 24 hours ago
    > highPrice24hstringHighest price in the past 24 hours
    > lowPrice24hstringLowest price in the past 24 hours

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_ticker_stream(
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "tickers_lt.EOS3LUSDT",
    "ts": 1672325446847,
    "type": "snapshot",
    "data": {
    "symbol": "EOS3LUSDT",
    "lastPrice": "0.41477848043290448",
    "highPrice24h": "0.435285472510871305",
    "lowPrice24h": "0.394601507960931382",
    "prevPrice24h": "0.431502290172376349",
    "price24hPcnt": "-0.0388"
    }
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/kline.html b/v5/websocket/public/kline.html index 2bad1822ed..495ebbb3a0 100644 --- a/v5/websocket/public/kline.html +++ b/v5/websocket/public/kline.html @@ -4,14 +4,14 @@ Kline | Bybit API Documentation - +

    Kline

    Subscribe to the klines stream.

    tip

    If confirm=true, this means that the candle has closed. Otherwise, the candle is still open and updating.

    Available intervals:

    • 1 3 5 15 30 (min)
    • 60 120 240 360 720 (min)
    • D (day)
    • W (week)
    • M (month)

    Push frequency: 1-60s

    Topic:
    kline.{interval}.{symbol} e.g., kline.30.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > startnumberThe start timestamp (ms)
    > endnumberThe end timestamp (ms)
    > intervalstringKline interval
    > openstringOpen price
    > closestringClose price
    > highstringHighest price
    > lowstringLowest price
    > volumestringTrade volume
    > turnoverstringTurnover
    > confirmbooleanWeather the tick is ended or not
    > timestampnumberThe timestamp (ms) of the last matched order in the candle

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.kline_stream(
    interval=5,
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "kline.5.BTCUSDT",
    "data": [
    {
    "start": 1672324800000,
    "end": 1672325099999,
    "interval": "5",
    "open": "16649.5",
    "close": "16677",
    "high": "16677",
    "low": "16608",
    "volume": "2.081",
    "turnover": "34666.4005",
    "confirm": false,
    "timestamp": 1672324988882
    }
    ],
    "ts": 1672324988882,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/liquidation.html b/v5/websocket/public/liquidation.html index 647ab21dfc..79d934fe94 100644 --- a/v5/websocket/public/liquidation.html +++ b/v5/websocket/public/liquidation.html @@ -4,14 +4,14 @@ Liquidation | Bybit API Documentation - +

    Liquidation

    Subscribe to the liquidation stream

    Push frequency: real-time

    Topic:
    liquidation.{symbol} e.g., liquidation.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > updateTimenumberThe updated timestamp (ms)
    > symbolstringSymbol name
    > sidestringPosition side. Buy,Sell. When you receive a Buy update, this means that a long position has been liquidated
    > sizestringExecuted size
    > pricestringBankruptcy price

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.liquidation_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/orderbook.html b/v5/websocket/public/orderbook.html index e2605b61d8..5fb97b276c 100644 --- a/v5/websocket/public/orderbook.html +++ b/v5/websocket/public/orderbook.html @@ -4,7 +4,7 @@ Orderbook | Bybit API Documentation - + @@ -20,7 +20,7 @@ Level 25 data, push frequency: 20ms
    Level 100 data, push frequency: 100ms

    Topic:
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot,delta
    tsnumberThe timestamp (ms) that the system generates the data
    datamapObject
    > sstringSymbol name
    > barrayBids. For snapshot stream, the element is sorted by price in descending order
    >> b[0]stringBid price
    >> b[1]stringBid size
  • The delta data has size=0, which means that all quotations for this price have been filled or cancelled
  • > aarrayAsks. For snapshot stream, the element is sorted by price in ascending order
    >> a[0]stringAsk price
    >> a[1]stringAsk size
  • The delta data has size=0, which means that all quotations for this price have been filled or cancelled
  • > uintegerUpdate ID. Is a sequence. Occasionally, you'll receive "u"=1, which is a snapshot data due to the restart of the service. So please overwrite your local orderbook
    > seqintegerCross sequence
  • You can use this field to compare different levels orderbook data, and for the smaller seq, then it means the data is generated earlier.
  • Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.orderbook_stream(
    depth=50,
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1672304484978,
    "data": {
    "s": "BTCUSDT",
    "b": [
    ...,
    [
    "16493.50",
    "0.006"
    ],
    [
    "16493.00",
    "0.100"
    ]
    ],
    "a": [
    [
    "16611.00",
    "0.029"
    ],
    [
    "16612.00",
    "0.213"
    ],
    ...,
    ],
    "u": 18521288,
    "seq": 7961638724
    }
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/ticker.html b/v5/websocket/public/ticker.html index 1d59a5e0d7..045d3799bf 100644 --- a/v5/websocket/public/ticker.html +++ b/v5/websocket/public/ticker.html @@ -4,14 +4,14 @@ Ticker | Bybit API Documentation - +

    Ticker

    Subscribe to the ticker stream.

    note
    • This topic utilises the snapshot field and delta field. If a response param is not found in the message, then its value has not changed.
    • Spot & Option tickers message are snapshot only

    Push frequency: Derivatives & Options - 100ms, Spot - real-time

    Topic:
    tickers.{symbol}

    Response Parameters

    ParameterTypeComments
    topicstringTopic name
    typestringData type. snapshot,delta
    csintegerCross sequence
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject
    > symbolstringSymbol name
    > tickDirectionstringTick direction
    > price24hPcntstringPercentage change of market price in the last 24 hours
    > lastPricestringLast price
    > prevPrice24hstringMarket price 24 hours ago
    > highPrice24hstringThe highest price in the last 24 hours
    > lowPrice24hstringThe lowest price in the last 24 hours
    > prevPrice1hstringMarket price an hour ago
    > markPricestringMark price
    > indexPricestringIndex price
    > openIntereststringOpen interest size
    > openInterestValuestringOpen interest value
    > turnover24hstringTurnover for 24h
    > volume24hstringVolume for 24h
    > nextFundingTimestringNext funding timestamp (ms)
    > fundingRatestringFunding rate
    > bid1PricestringBest bid price
    > bid1SizestringBest bid size
    > ask1PricestringBest ask price
    > ask1SizestringBest ask size
    > deliveryTimedatetimeDelivery date time (UTC+0). Unique field for inverse futures & USDC futures
    > basisRatestringBasis rate. Unique field for inverse futures & USDC futures
    > deliveryFeeRatestringDelivery fee rate. Unique field for inverse futures & USDC futures
    > predictedDeliveryPricestringPredicated delivery price. Unique field for inverse futures & USDC futures

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.ticker_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "PlusTick",
    "price24hPcnt": "0.017103",
    "lastPrice": "17216.00",
    "prevPrice24h": "16926.50",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17217.33",
    "indexPrice": "17227.36",
    "openInterest": "68744.761",
    "openInterestValue": "1183601235.91",
    "turnover24h": "1570383121.943499",
    "volume24h": "91705.276",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000212",
    "bid1Price": "17215.50",
    "bid1Size": "84.489",
    "ask1Price": "17216.00",
    "ask1Size": "83.020"
    },
    "cs": 24987956059,
    "ts": 1673272861686
    }
    - + \ No newline at end of file diff --git a/v5/websocket/public/trade.html b/v5/websocket/public/trade.html index bc81641689..f401edb522 100644 --- a/v5/websocket/public/trade.html +++ b/v5/websocket/public/trade.html @@ -4,7 +4,7 @@ Trade | Bybit API Documentation - + @@ -12,7 +12,7 @@

    Trade

    Subscribe to the recent trades stream.

    After subscription, you will be pushed trade messages in real-time.

    Push frequency: real-time

    Topic:
    publicTrade.{symbol}
    Note: option uses baseCoin, e.g., publicTrade.BTC

    Response Parameters

    ParameterTypeComments
    idstringMessage id. Unique field for option
    topicstringTopic name
    typestringData type. snapshot
    tsnumberThe timestamp (ms) that the system generates the data
    dataarrayObject. The element in the array is sort by matching time in ascending order
    > TnumberThe timestamp (ms) that the order is filled
    > sstringSymbol name
    > SstringSide of taker. Buy,Sell
    > vstringTrade size
    > pstringTrade price
    > LstringDirection of price change. Unique field for future
    > istringTrade ID
    > BTbooleanWhether it is a block trade order or not

    Subscribe Example

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.trade_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "publicTrade.BTCUSDT",
    "type": "snapshot",
    "ts": 1672304486868,
    "data": [
    {
    "T": 1672304486865,
    "s": "BTCUSDT",
    "S": "Buy",
    "v": "0.001",
    "p": "16578.50",
    "L": "PlusTick",
    "i": "20f43950-d8dd-5b31-9112-a178eb6023af",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/v5/ws/connect.html b/v5/ws/connect.html index c1d1603538..b140a7db8d 100644 --- a/v5/ws/connect.html +++ b/v5/ws/connect.html @@ -4,7 +4,7 @@ Connect | Bybit API Documentation - + @@ -20,7 +20,7 @@ USDC Option: wss://stream-testnet.bybit.com/v5/public/option

    WebSocket private channel:

    • Mainnet:
      wss://stream.bybit.com/v5/private

    • Testnet:
      wss://stream-testnet.bybit.com/v5/private

    Customise Private Connection Alive Time

    For private channel, you can customise alive duration by adding a param max_alive_time, the lowest value is 30s (30 seconds), the highest value is 600s (10 minutes). You can also pass 1m, 2m etc when you try to configure by minute level. e.g., wss://stream-testnet.bybit.com/v5/private?max_alive_time=1m.

    In general, if there is no "ping-pong" and no stream data sent from server end, the connection will be cut off after 10 minutes. When you have a particular need, you can configure connection alive time by max_alive_time.

    Since ticker scans every 30s, so it is not fully exact, i.e., if you configure 45s, and your last update or ping-pong is occurred on 2023-08-15 17:27:23, your disconnection time maybe happened on 2023-08-15 17:28:15

    Authentication

    info
    Public topics do not require authentication. The following section applies to private topics only.

    Apply for authentication when establishing a connection.

    Note: if you're using pybit, bybit-api, or another high-level library, you can ignore this code - as authentication is handled for you.

    {
    "req_id": "10001", // optional
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, // expires; is greater than your current timestamp
    "signature"
    ]
    }
    # based on: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    Successful authentication sample response

    {
    "success": true,
    "ret_msg": "",
    "op": "auth",
    "conn_id": "cejreaspqfh3sjdnldmg-p"
    }
    note

    Example signature algorithms can be found here.

    caution

    Due to network complexity, your may get disconnected at any time. Please follow the instructions below to ensure that you receive WebSocket messages on time:

    1. Keep connection alive by sending the heartbeat packet
    2. Reconnect as soon as possible if disconnected

    IP Limits

    • Do not frequently connect and disconnect the connection.
    • Do not build over 500 connections in 5 minutes. This is counted separately per WebSocket endpoint.

    Public channel - Args limits

    Regardless of Perpetual, Futures, Options or Spot, for one public connection, you cannot have length of "args" array over 21,000 characters.

    • Spot can input up to 10 args for each subscription request sent to one connection
    • Options can input up to 2000 args for a single connection
    • No args limit for Futures for now

    How to Send the Heartbeat Packet

    How to Send

    // req_id is a customised ID, which is optional
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    Pong message example of public channels

    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "0970e817-426e-429a-a679-ff7f55e0b16a",
    "op": "ping"
    }

    Pong message example of private channels

    {
    "req_id": "test",
    "op": "pong",
    "args": [
    "1675418560633"
    ],
    "conn_id": "cfcb4ocsvfriu23r3er0-1b"
    }
    caution

    To avoid network or program issues, we recommend that you send the ping heartbeat packet every 20 seconds to maintain the WebSocket connection.

    How to Subscribe to Topics

    Understanding WebSocket Filters

    How to subscribe with a filter

    // Subscribing level 1 orderbook
    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    Subscribing with multiple symbols and topics is supported.

    {
    "req_id": "test", // optional
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT",
    "publicTrade.BTCUSDT",
    "orderbook.1.ETHUSDT"
    ]
    }

    Understanding WebSocket Filters: Unsubscription

    You can dynamically subscribe and unsubscribe from topics without unsubscribing from the WebSocket like so:

    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.ETHUSD"
    ],
    "req_id": "customised_id"
    }

    Understanding the Subscription Response

    Topic subscription response message example

    {
    "success": true,
    "ret_msg": "",
    "op": "subscribe",
    "conn_id": "cejreassvfrsfvb9v1a0-2m"
    }
    - + \ No newline at end of file diff --git a/zh-TW/404.html b/zh-TW/404.html index 35d82559c0..87790a33c1 100644 --- a/zh-TW/404.html +++ b/zh-TW/404.html @@ -4,13 +4,13 @@ 找不到頁面 | Bybit API Documentation - +

    找不到頁面

    我們沒有您要找的頁面。

    請聯絡原始連結來源網站的所有者,並通知他們連結已毀損。

    - + \ No newline at end of file diff --git a/zh-TW/account-asset/all-balance.html b/zh-TW/account-asset/all-balance.html index 346978ca4f..49d1dd80c0 100644 --- a/zh-TW/account-asset/all-balance.html +++ b/zh-TW/account-asset/all-balance.html @@ -4,13 +4,13 @@ 查詢賬戶所有幣種余額 | Bybit API Documentation - +

    查詢賬戶所有幣種余額

    支持查詢母帳戶的各個帳戶類型的幣種餘額,以及母帳戶下各子帳戶的各個帳戶類型的幣種餘額。

    重要

    無法通過子賬戶api key獲取主賬戶的帳戶餘額

    HTTP 請求

    GET /asset/v3/private/transfer/account-coins/balance/query

    請求參數

    參數是否必須類型說明
    memberIdfalsestring用戶ID. 當使用母帳號api key查詢子帳戶的幣種餘額時,該字段必傳
    accountTypetruestring賬戶類型
    coinfalsestring幣種類型
    withBonusfalsestring是否查詢體驗金. 0(默認):不查詢; 1:查詢

    返回參數

    參數類型說明
    accountTypestring賬戶類型
    memberIdstring用戶ID
    balanceObject
    > coinstring幣種類型
    > walletBalancestring錢包余額
    > transferBalancestring可划余額
    > bonusstring体验金

    請求示例

    GET /asset/v3/private/transfer/account-coins/balance/query?accountType=FUND&coin=USDT,USDC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675865289817
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "memberId": "533285",
    "accountType": "FUND",
    "balance": [
    {
    "coin": "USDT",
    "transferBalance": "1010",
    "walletBalance": "1010",
    "bonus": ""
    },
    {
    "coin": "USDC",
    "transferBalance": "0",
    "walletBalance": "0",
    "bonus": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675865290069
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/apikey-info.html b/zh-TW/account-asset/apikey-info.html index 26281f0882..4a6867f26f 100644 --- a/zh-TW/account-asset/apikey-info.html +++ b/zh-TW/account-asset/apikey-info.html @@ -4,13 +4,13 @@ 查詢API Key相關信息 | Bybit API Documentation - +

    查詢API Key相關信息

    獲取API key的相關信息。使用待查詢的api key調用接口。適用於母、子帳戶的api key。

    提示

    任意權限可以訪問該接口

    HTTP 請求

    GET /user/v3/private/query-api

    請求參數

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray衍生品v3/v5交易的權限
    > CopyTradingarray跟單交易的權限. 子帳戶暫不支持, 總是[]
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]
    ipsarray綁定的IP
    typeintegerApi key類型. 1:個人使用, 2:綁定到第三方應用
    deadlineDayintegerAPI key失效的倒數日. 針對那些未綁定IP的api key或者修改過密碼的帳戶
    expiredAtdatetimeAPI key的過期日. 針對那些未綁定IP的api key或者修改過密碼的帳戶
    createdAtdatetimeAPI key的創建日
    unifiedintegerAPI Key所屬的帳戶是否為統一保證金帳戶. 0:普通帳戶; 1:統一保证金帳戶
    utaintegerAPI Key所屬的帳戶是否為統一交易帳戶. 0:普通帳戶; 1:統一交易账户
    userIDinteger用戶 ID
    inviterIDinteger邀請人 ID(邀請該賬號加入平台的賬號的UID)
    vipLevelstringVIP用戶等級
    mktMakerLevelstringmarket maker等級
    affiliateIDinteger代理商Id. 0: 表示無任何代理綁定關係
    rsaPublicKeystringRSA公鑰
    isMasterboolean是否為主帳戶下的api key
    parentUidstring主帳戶uid. 如果是主帳戶本身調用, 則返回"0"

    請求示例

    GET /user/v3/private/query-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671177977555
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "375764",
    "note": "ordinary",
    "apiKey": "CBIZAHQMLAPKMGUVGJ",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": []
    },
    "ips": [
    "*"
    ],
    "type": 1,
    "deadlineDay": 87,
    "expiredAt": "2023-04-04T05:44:02Z",
    "createdAt": "2023-01-04T05:44:02Z",
    "unified": 0,
    "uta": 0,
    "userID": 1135134,
    "inviterID": 0,
    "vipLevel": "No VIP",
    "mktMakerLevel": "0",
    "affiliateID": 0,
    "rsaPublicKey": "",
    "isMaster": false,
    "parentUid": "24617703"
    },
    "retExtInfo": {},
    "time": 1672986764656
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/asset-info.html b/zh-TW/account-asset/asset-info.html index e83980a399..9c6be560bb 100644 --- a/zh-TW/account-asset/asset-info.html +++ b/zh-TW/account-asset/asset-info.html @@ -4,13 +4,13 @@ 查詢資產信息 | Bybit API Documentation - +

    查詢資產信息

    提示

    僅能查詢到現貨帳戶的資產

    HTTP 請求

    GET /asset/v3/private/transfer/asset-info/query

    請求參數

    參數是否必須類型說明
    accountTypefalsestring帳戶類型. 默認是SPOT類型
    coinfalsestring幣種類型

    返回參數

    參數類型說明
    spotObject
    > statusstring
    • 賬戶狀態: ACCOUNT_STATUS_NORMAL -- 正常
    • ACCOUNT_STATUS_UNSPECIFIED -- 不正常
    > assetsarrayObject
    >> coinstring幣種類型
    >> frozenstring掛單凍結金額
    >> freestring可用余額
    >> withdrawstring提現中金額

    請求示例

    GET /asset/v3/private/transfer/asset-info/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXXXXXXX
    X-BAPI-TIMESTAMP: 1670924059987
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXXXXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "spot": {
    "status": "ACCOUNT_STATUS_NORMAL",
    "assets": [
    {
    "coin": "USDT",
    "frozen": "0",
    "free": "61.1428",
    "withdraw": ""
    }
    ]
    }
    },
    "retExtInfo": {},
    "time": 1670924060108
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/cancel-withdraw.html b/zh-TW/account-asset/cancel-withdraw.html index cbf6ea9fae..9b31feab74 100644 --- a/zh-TW/account-asset/cancel-withdraw.html +++ b/zh-TW/account-asset/cancel-withdraw.html @@ -4,13 +4,13 @@ 撤銷提幣 | Bybit API Documentation - +

    撤銷提幣

    撤銷提幣

    HTTP 請求

    POST /asset/v3/private/withdraw/cancel

    請求參數

    參數是否必須類型說明
    idtrueinteger提現ID。 (提現API響應參數中的提現請求ID)

    返回參數

    參數類型說明
    statusinteger撤銷申請結果
    • 1: 成功
    • 0: 失敗

    請求示例

    POST /asset/v3/private/withdraw/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671173665186
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 24

    {
    "id": 1234567890
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1671173665252
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/coin-balance.html b/zh-TW/account-asset/coin-balance.html index 99d11d2b94..f6d99b1972 100644 --- a/zh-TW/account-asset/coin-balance.html +++ b/zh-TW/account-asset/coin-balance.html @@ -4,14 +4,14 @@ 查詢賬戶單個幣種余額 | Bybit API Documentation - +

    查詢賬戶單個幣種余額

    支持查詢母帳戶的單個幣種餘額,以及母帳戶下各子帳戶的單個幣種餘額。 同時, 支持查詢母子帳戶、子子帳戶、子母帳戶之間的可劃轉金額,特別是針對於擁有機構借貸的用戶。

    重要

    無法通過子賬戶api key獲取主賬戶帳戶餘額

    HTTP 請求

    GET /asset/v3/private/transfer/account-coin/balance/query

    請求參數

    參數是否必須類型說明
    memberIdfalsestring用戶ID. 當使用母帳號api key查詢子帳戶的幣種餘額時,該字段必傳
    toMemberIdfalsestring劃入帳戶UID. 當查詢帳戶間劃轉時, 該字段必傳
    accountTypetruestring賬戶類型
    toAccountTypefalsestring劃入帳戶類型. 當查詢不同帳戶類型間的劃轉時, 該字段必傳
    cointruestring幣種類型
    withBonusfalseinteger是否查詢體驗金. 0(默認):不查詢; 1:查詢
    withTransferSafeAmountfalseinteger是否查詢延遲提幣安全限額
    withLtvTransferSafeAmountfalseinteger特別用於機構借貸用戶, 可以查詢風險水平內的可劃轉餘額
    • 0(default):false, 1:true
    • 此時toAccountType字段必傳

    返回參數

    參數類型說明
    accountTypestring賬戶類型
    bizTypeinteger帳戶業務子類型
    accountIdstring賬戶ID
    memberIdstring用戶ID
    balanceObject
    > coinstring幣種類型
    > walletBalancestring錢包余額
    > transferBalancestring可划余額
    > bonusstring体验金
    > transferSafeAmountstring可劃轉的安全限額. 若不查詢,則返回""
    > ltvTransferSafeAmountstring機構借貸用戶的可劃轉餘額. 若不查詢,則返回""

    請求示例

    GET /asset/v3/private/transfer/account-coin/balance/query?accountType=CONTRACT&coin=USDT&withTransferSafeAmount=1&withBonus=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1678794085278
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "accountType": "CONTRACT",
    "bizType": 1,
    "accountId": "533285",
    "memberId": "533285",
    "balance": {
    "coin": "USDT",
    "walletBalance": "0",
    "transferBalance": "-995.3506",
    "bonus": "995.3506",
    "transferSafeAmount": "-995.3506",
    "ltvTransferSafeAmount": ""
    }
    },
    "retExtInfo": {},
    "time": 1678794085705
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/coin-info.html b/zh-TW/account-asset/coin-info.html index eb8c08cb87..f6067ffba1 100644 --- a/zh-TW/account-asset/coin-info.html +++ b/zh-TW/account-asset/coin-info.html @@ -4,13 +4,13 @@ 查詢幣種信息 | Bybit API Documentation - +

    查詢幣種信息

    幣種信息查詢

    HTTP 請求

    GET /asset/v3/private/coin-info/query

    請求參數

    參數是否必須類型說明
    coinfalsestring幣種

    返回參數

    參數類型說明
    rowsarrayObject
    > namestring幣種名稱
    > coinstring幣種
    > remainAmountstring該幣種當前最大可提現數量
    > chainsarrayObject
    >> chainTypestring鏈類型
    >> confirmationstring充值上賬確認數
    >> withdrawFeestring提現手續費
    • 如果提現費為空,則表示該幣不支持提現
    • 若為0, 可能該幣種手續費為百分比, 後續會增加相關字段
    >> depositMinstring最小充值數量
    >> withdrawMinstring最小提現數量
    >> chainstring鏈名
    >> chainDepositstring幣鏈是否可充值. 0:暫停; 1:正常
    >> chainWithdrawstring幣鏈是否可提幣. 0:暫停; 1:正常
    >> minAccuracystring充提幣的最小精度
    >> withdrawPercentageFeestring提現手續費百分比. 該字段的值是實際數字,即0.022表示為2.2%

    請求示例

    GET /asset/v3/private/coin-info/query?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671172180432
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: xxxxxxxxxxx

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "rows": [
    {
    "name": "ETH",
    "coin": "ETH",
    "remainAmount": "1020000",
    "chains": [
    {
    "chainType": "ETH",
    "confirmation": "10000",
    "withdrawFee": "0.005",
    "depositMin": "0.01",
    "withdrawMin": "0.02",
    "chain": "ETH",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0.022"
    },
    {
    "chainType": "Arbitrum One",
    "confirmation": "10",
    "withdrawFee": "0.01",
    "depositMin": "0.001",
    "withdrawMin": "0.1",
    "chain": "ARBI",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677478088215
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/create-subuid-apikey.html b/zh-TW/account-asset/create-subuid-apikey.html index 4c0ffc32ae..c014af1285 100644 --- a/zh-TW/account-asset/create-subuid-apikey.html +++ b/zh-TW/account-asset/create-subuid-apikey.html @@ -4,13 +4,13 @@ 新建子帳戶的API Key | Bybit API Documentation - +

    新建子帳戶的API Key

    給新建好的子帳戶創建新的API key。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /user/v3/private/create-sub-api

    請求參數

    參數是否必須類型說明
    subuidtrueinteger子帳戶userId
    notefalsestring設置備註
    readOnlytrueinteger0:可讀可寫. 1:只讀
    ipsfalsestring綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的非永久api key將在7天後失效
    permissionstrueObject勾選api key權限.
    • 注意: 必須傳入以下權限類型的任意一種, 否則報錯n
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > Exchangefalsearray兌換. ["ExchangeHistory"]

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstringApi密鑰密碼.
    • 注意: Api密鑰密碼只會在這裡出現一次,除此之外沒有任何地方還可以獲取到密碼。請妥善保存。
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限. 子帳戶暫不支持, 總是[]
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]

    請求示例

    POST /user/v3/private/create-sub-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671176685767
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 796

    {
    "subuid": 1111111111,
    "note": "mytest",
    "readOnly": 1,
    "ips": "*",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [
    "BlockTrade"
    ],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "1111111111",
    "note": "mytest",
    "apiKey": "xxxxxxxxxxxxx",
    "readOnly": 1,
    "secret": "xxxxxxxxxxxxx",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": []
    }
    },
    "retExtInfo": {},
    "time": 1671176685954
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/create-subuid.html b/zh-TW/account-asset/create-subuid.html index d722919cf2..d09177d48f 100644 --- a/zh-TW/account-asset/create-subuid.html +++ b/zh-TW/account-asset/create-subuid.html @@ -4,13 +4,13 @@ 新建子帳戶 | Bybit API Documentation - +

    新建子帳戶

    創建新的子帳戶。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /user/v3/private/create-sub-member

    請求參數

    參數是否必須類型說明
    usernametruestring給新的子帳戶創建一個用戶名。
    • 6-16位字符,須同時含有數字和字母。
    • 不能與已存在或已刪除的帳戶用戶名重複。
    passwordfalsestring給新的子帳戶設置一個密碼。
    • 8-30位字符,須同時含有數字和大小寫字母。
    memberTypetrueinteger1: 普通子帳戶, 6: 託管子帳戶
    switchfalseinteger
    • 0: 關閉快捷登陸 (默認關閉)
    • 1: 打開快捷登陸.
    isUtafalseboolean
    • true: 創建統一帳戶
    • false(默認): 創建普通帳戶
    notefalsestring設置備註

    返回參數

    參數類型說明
    uidstring子帳戶userId
    usernamestring給新的子帳戶創建一個用戶名
    • 6-16位字符,須同時含有數字和字母。
    • 不能與已存在或已刪除的帳戶用戶名重複。
    memberTypeinteger1: 普通子帳戶, 6: 託管子帳戶
    statusinteger帳戶狀態
    • 1: 正常
    • 2: 登陸封禁
    • 4: 凍結
    remarkstring設置的備註

    請求示例

    POST /user/v3/private/create-sub-member HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671174837503
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 109

    {
    "username": "testsubaccount",
    "memberType": 1,
    "switch": 1,
    "note": "testnet subaccount"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "uid": "111111111",
    "username": "testsubaccount",
    "memberType": 1,
    "status": 1,
    "remark": "testnet subaccount"
    },
    "retExtInfo": {},
    "time": 1671174837668
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/delay-amount.html b/zh-TW/account-asset/delay-amount.html index d0d6a28f41..606189c7f9 100644 --- a/zh-TW/account-asset/delay-amount.html +++ b/zh-TW/account-asset/delay-amount.html @@ -4,13 +4,13 @@ 查詢延遲提幣凍結金額 | Bybit API Documentation - +

    查詢延遲提幣凍結金額

    信息

    如何會導致部分資金被要求延遲提幣?

    • 鏈上充值: 鏈上區塊確認數未達到風險可控程度, 部分資金被凍結一段時間, 直到解凍
    • 買幣: 若存在風險, 則一定時間內被凍結, 無法提幣

    HTTP 請求

    GET /asset/v3/private/withdraw/withdrawable-amount

    請求參數

    參數是否必需類型說明
    cointruestring幣種敏誠

    響應參數

    參數類型說明
    limitAmountUsdstring延遲提幣凍結金額 (USD)
    withdrawableAmountarrayObject
    > SPOTObject現貨錢包, 若該錢包被移除, 則不會返回該對象
    >> coinstring幣種名稱
    >> withdrawableAmountstring可提現金額
    >> availableBalancestring可用餘額
    > FUNDObject資金錢包
    >> coinstring幣種名稱
    >> withdrawableAmountstring可提現金額
    >> availableBalancestring可用餘額

    請求示例


    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "limitAmountUsd": "52853.5551",
    "withdrawableAmount": {
    "FUND": {
    "coin": "USDT",
    "withdrawableAmount": "11135.0596",
    "availableBalance": "11135.0596"
    },
    "SPOT": {
    "coin": "USDT",
    "withdrawableAmount": "0",
    "availableBalance": "0"
    }
    }
    },
    "retExtInfo": {},
    "time": 1677565632151
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/deposit-record.html b/zh-TW/account-asset/deposit-record.html index 4f7f870bc1..1cdd85daa3 100644 --- a/zh-TW/account-asset/deposit-record.html +++ b/zh-TW/account-asset/deposit-record.html @@ -4,13 +4,13 @@ 查詢充值記錄 (鏈上) | Bybit API Documentation - +

    查詢充值記錄 (鏈上)

    充值記錄查詢

    規則
  • 開始時間和截止時間差最大限制為30天
  • 支持使用母、子帳戶的api key查詢各自的入金紀錄
  • HTTP 請求

    GET /asset/v3/private/deposit/record/query

    請求參數

    參數是否必須類型說明
    startTimefalseinteger開始時間 (精確到毫秒)。 默認為當前時間之前30天
    endTimefalseinteger結束時間 (精確到毫秒)。 默認為當前時間
    coinfalsestring幣種名:舉例,BTC。默認全部
    cursorfalsestring游標信息:用來分頁。 默認空
    limitfalseinteger每頁條數, [1, 50] 默認為50

    返回參數

    參數類型說明
    rowsarrayObject
    > coinstring充值的幣種
    > chainstring鏈名
    > amountstring充值的數量
    > txIDstring交易ID。充值失敗/取消充值:為空
    > statusint
    • 0=未知
    • 1=待確認
    • 2=上賬中
    • 3=已完成
    • 4=充值失敗
    > toAddressstring充值的目標地址
    > tagstring充值目標地址的tag
    > depositFeestring充值手續費
    > successAtstring最後更新時間
    > confirmationsstring确认区块的数量
    > txIndexstring交易序列号
    > blockHashstring鏈上的哈希數
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制
    > depositTypeinteger入金類型. 0: 正常充值, 10: 充值觸發每日限額, 20: 異常充值
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/deposit/record/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671166430580
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "1234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "depositFee": "",
    "successAt": "1671018256000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1"
    },
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "01234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "depositFee": "",
    "successAt": "1669197900000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTAwNTYwNiwibWF4SUQiOjEwMzE1MjN9"
    },
    "retExtInfo": {},
    "time": 1671166430718
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/deposit-spec.html b/zh-TW/account-asset/deposit-spec.html index 0c479c44ba..5acb177df8 100644 --- a/zh-TW/account-asset/deposit-spec.html +++ b/zh-TW/account-asset/deposit-spec.html @@ -4,13 +4,13 @@ 查詢充值相關的規格 | Bybit API Documentation - +

    查詢充值相關的規格

    查詢充值相關的規格信息

    Information

    是一個公共接口,無需鑒權。 coin和chain必須在輸入參數中配對出現。 否則,視為無條件查詢。

    HTTP 請求

    GET /asset/v3/public/deposit/allowed-deposit-list/query

    請求參數

    參數是否必須類型說明
    coinfalsestring充值幣種. coin和chain必須在輸入參數中配對出現。 否則,視為無條件查詢。
    chainfalsestring充值鏈名. coin和chain必須在輸入參數中配對出現。 否則,視為無條件查詢。
    cursorfalsestring游標信息,用來分頁
    limitfalseinteger每頁條數, [1, 50], 默認為50

    返回參數

    參數類型說明
    configListarrayObject
    > coinstring充值的幣種
    > chainstring鏈名
    > coinShowNamestring币展名
    > chainTypestring鏈類型
    > blockConfirmNumberinteger充值上賬確認數
    > minDepositAmountstring最低充值金額
    nextPageCursorstring游標信息, 用來分頁

    請求示例

    GET /asset/v3/public/deposit/allowed-deposit-list/query?coin=BTC&chain=BTC HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "configList": [
    {
    "coin": "BTC",
    "chain": "BTC",
    "coinShowName": "BTC",
    "chainType": "BTC",
    "blockConfirmNumber": 10000,
    "minDepositAmount": "0.0005"
    }
    ],
    "nextPageCursor": "eyJwYWdlIjoyLCJsaW1pdCI6MTB9"
    },
    "retExtInfo": {},
    "time": 1671165256048
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/enable-unitransfer.html b/zh-TW/account-asset/enable-unitransfer.html index 8da7dd076d..bb50ae6b60 100644 --- a/zh-TW/account-asset/enable-unitransfer.html +++ b/zh-TW/account-asset/enable-unitransfer.html @@ -4,13 +4,13 @@ 配置可互相劃轉的子賬號 (廢棄) | Bybit API Documentation - +

    配置可互相劃轉的子賬號 (廢棄)

    配置可互相劃轉的子賬號列表

    信息

    無需再配置可劃轉的子帳號, 該限制已移除, 默認任意子帳號之間可以劃轉

    提示

    萬能轉賬使您可以在兩個子賬戶或者母子帳戶在各種賬戶類型(CONTRACT、SPOT等)之間劃轉。

    你需要通過這個接口來設置可互相劃轉的子賬號。如果不設置,這些子賬戶之間不能互相劃轉

    HTTP 請求

    POST /asset/v3/private/transfer/transfer-sub-member-save

    請求參數

    參數是否必須類型說明
    subMemberIdsfalsearray<string>逗號隔開的id列表,例:"123,45,14,26,46"
    • 若不傳,則表示移除子帳戶萬能劃轉的能力

    返回參數

    請求示例

    POST /asset/v3/private/transfer/transfer-sub-member-save HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670928736473
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 43

    {
    "subMemberIds": ["1111111","2222222"]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {},
    "retExtInfo": {},
    "time": 1670928736727
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/enum.html b/zh-TW/account-asset/enum.html index 0d245b016f..d0ef783e29 100644 --- a/zh-TW/account-asset/enum.html +++ b/zh-TW/account-asset/enum.html @@ -4,13 +4,13 @@ 枚舉定義 | Bybit API Documentation - +

    枚舉定義

    accountType

    • CONTRACT合約帳戶
    • SPOT現貨帳戶
    • INVESTMENT理財帳戶 (相關服務已下線)
    • OPTIONUSDC帳戶
    • UNIFIED統一帳戶
    • FUND資金帳戶

    coin

    • BTC
    • ETH
    • USDT
    • XRP
    • ...

    chain

    • BTC
    • ETH
    • TRX
    • XLM
    • LTC
    • ...

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    withdrawStatus

    • SecurityCheck
    • Pending
    • success
    • CancelByUser
    • Reject
    • Fail
    • BlockchainConfirmed
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/error.html b/zh-TW/account-asset/error.html index 828f6e03d1..596b1c03bc 100644 --- a/zh-TW/account-asset/error.html +++ b/zh-TW/account-asset/error.html @@ -4,13 +4,13 @@ 錯誤碼 | Bybit API Documentation - +

    錯誤碼

    錯誤碼描述
    0成功
    131084UTA升級中,無法提現
    131200服務不可用
    131201業務異常
    131202用戶ID無效
    131203請求參數錯誤
    131204帳戶異常
    131205查詢劃轉失敗
    131206劃轉失敗
    131207帳戶不存在
    131208劃轉封禁
    131209查詢子帳戶關係失敗
    131210金額精度錯誤
    131211轉入賬戶類型不能作為轉出賬戶類型
    131212可用餘額不足
    131213當前劃轉能力受到LTV風險率限制
    131214劃轉ID已存在
    131215金額錯誤
    131216查詢余額錯誤
    131217風險檢查失敗
    131001服務錯誤
    131002參數錯誤
    131003內部錯誤
    131004需要KYC認證
    131085提幣金額大於可用餘額,觸發延遲提幣
    131086提幣金額超過風控限制,觸發全倉槓桿限制
    131088提幣金額超過當前KYC限額,您目前的可提限額是: %s
    131089用戶24小時內進行過銘感操作,提現被禁
    131090用戶提現封禁
    131091用戶登陸封禁,無法提幣
    131092用戶狀態異常
    131093提幣地址不在白名單內
    131094用戶ID不在白名單內
    131095提幣金額超過平台24小時限額
    131096檢查提幣金額是否滿足最小最大可提金額
    131097系統暫停提幣
    131098當前時間禁止從新地址提幣
    131099當前狀態不支持取消提幣請求
    131227子帳戶未配置萬能劃轉能力
    131228可劃轉餘額不足. 請確認延遲提幣安全限額
    131229Due to compliance requirements, the current currency is not allowed to transfer 根據合規要求, 該資產不允許劃轉
    131087請不要傳入tag/memo
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/froze-subuid.html b/zh-TW/account-asset/froze-subuid.html index c12775b9fd..1b69cafe67 100644 --- a/zh-TW/account-asset/froze-subuid.html +++ b/zh-TW/account-asset/froze-subuid.html @@ -4,13 +4,13 @@ 凍結/解凍子帳戶 | Bybit API Documentation - +

    凍結/解凍子帳戶

    凍結或解凍子帳戶。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /user/v3/private/frozen-sub-member

    請求參數

    參數是否必須類型說明
    subuidtrueinteger子帳戶userId
    frozentrueinteger0:解凍, 1:凍結

    返回參數

    請求示例

    POST /user/v3/private/frozen-sub-member HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671177689823
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 42

    {
    "subuid": 111111111,
    "frozen": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671177689999
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/internal-deposit-record.html b/zh-TW/account-asset/internal-deposit-record.html index 5838fd9c43..b43ca1477d 100644 --- a/zh-TW/account-asset/internal-deposit-record.html +++ b/zh-TW/account-asset/internal-deposit-record.html @@ -4,13 +4,13 @@ 查詢充值記錄 (平台转账) | Bybit API Documentation - +

    查詢充值記錄 (平台转账)

    查詢Bybit平台內部充值紀錄

    規則
  • 開始時間和截止時間差最大限制為30天
  • 支持使用母、子帳戶的api key查詢各自的入金紀錄
  • HTTP 請求

    GET /asset/v3/private/deposit/internal-deposit-record/query

    請求參數

    參數是否必須類型說明
    startTimefalseinteger開始時間 (精確到毫秒)。 默認為當前時間之前30天
    endTimefalseinteger結束時間 (精確到毫秒)。 默認為當前時間
    coinfalsestring幣種名:舉例,BTC。默認全部
    cursorfalsestring游標信息:用來分頁。 默認空
    limitfalseinteger每頁條數, [1, 50] 默認為50

    返回參數

    參數類型說明
    rowsarrayObject
    > idstringID
    > typeinteger1: 內部充值
    > coinstring充值的幣種
    > amountstring充值的數量
    > txIDstring交易ID。充值失敗/取消充值:為空
    > statusinteger
    • 1=處理中
    • 2=已完成
    • 3=充值失敗
    > addressstring郵箱地址或者手機號
    > createdTimestring充值創建時間戳
    nextPageCursorstring游標信息:用來分頁

    請求示例


    響應示例


    - + \ No newline at end of file diff --git a/zh-TW/account-asset/internal-transfer-list.html b/zh-TW/account-asset/internal-transfer-list.html index a03684f842..18a360c85a 100644 --- a/zh-TW/account-asset/internal-transfer-list.html +++ b/zh-TW/account-asset/internal-transfer-list.html @@ -4,13 +4,13 @@ 查詢劃轉記錄(單帳號內) | Bybit API Documentation - +

    查詢劃轉記錄(單帳號內)

    查詢劃轉記錄列表

    HTTP 請求

    GET /asset/v3/private/transfer/inter-transfer/list/query

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型
    statusfalsestring劃轉狀態
    startTimefalseinteger開始時間戳(毫秒) 注意: 實際查詢時是秒級維度生效
    endTimefalseinteger結束時間戳(毫秒) 注意: 實際查詢時是秒級維度生效
    limitfalseinteger每頁數量限制
    cursorfalsestring游標, 用來分頁

    返回參數

    參數類型說明
    transferIdstringUUID,全局唯一
    coinstring幣種類型
    amountstring劃轉數量
    fromAccountTypestring轉出賬戶類型
    toAccountTypestring轉入賬戶類型
    timestampstring創建時間戳 (毫秒)
    statusstring劃轉狀態
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/transfer/inter-transfer/list/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670926842754
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: xxxxxxxxxxxxxxx

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "22b168ef-1917-4bbe-a8bd-4ea729ec5887",
    "coin": "USDT",
    "amount": "1",
    "fromAccountType": "SPOT",
    "toAccountType": "UNIFIED",
    "timestamp": "1668749670000",
    "status": "SUCCESS"
    },
    {
    "transferId": "selfTransfer_4420a136-5610-44d3-97bb-a3d0551869a9",
    "coin": "USDT",
    "amount": "1",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT",
    "timestamp": "1668570868000",
    "status": "SUCCESS"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6NTYxMzUxLCJtYXhJRCI6MTU2Mzg4OX0="
    },
    "retExtInfo": {},
    "time": 1670926842908
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/internal-transfer.html b/zh-TW/account-asset/internal-transfer.html index 081bc7181c..77f4420b4f 100644 --- a/zh-TW/account-asset/internal-transfer.html +++ b/zh-TW/account-asset/internal-transfer.html @@ -4,13 +4,13 @@ 劃轉(單帳號內) | Bybit API Documentation - +

    劃轉(單帳號內)

    在個人賬戶的不同業務賬戶之間(而非子賬戶之間)轉移資金。 例如,在現貨和衍生品賬戶之間。

    要發送賬戶類型和父子不可知的轉賬,請使用創建萬能轉賬接口。

    提示
    • 請註意該接口入參請求數據中的transferId字段為UUID全局唯一。
    • 轉入和轉出賬戶類型不能相同。
    • 升級到統一帳戶後,僅支持從現貨帳戶轉帳USDT到統保帳戶。

    HTTP 請求

    POST /asset/v3/private/transfer/inter-transfer

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型
    amounttruestring兌入數量
    fromAccountTypetruestring賬戶類型
    toAccountTypetruestring賬戶類型

    返回參數

    參數類型說明
    transferIdstringUUID,全局唯一

    請求示例

    POST /asset/v3/private/transfer/inter-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670925348932
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 164

    {
    "transferId": "42c0cfb0-6bca-c242-bc73-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "fromAccountType": "CONTRACT",
    "toAccountType": "SPOT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc73-4e6df6cbcb06"
    },
    "retExtInfo": {},
    "time": 1670925349100
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/master-deposit-addr.html b/zh-TW/account-asset/master-deposit-addr.html index 5c1a07ff45..93a2f0a857 100644 --- a/zh-TW/account-asset/master-deposit-addr.html +++ b/zh-TW/account-asset/master-deposit-addr.html @@ -4,13 +4,13 @@ 查詢主帳戶充值地址信息 | Bybit API Documentation - +

    查詢主帳戶充值地址信息

    主帳戶充值地址信息查詢

    HTTP 請求

    GET /asset/v3/private/deposit/address/query

    請求參數

    參數是否必須類型說明
    coinfalsestring幣種
    chainTypefalsestring鏈. 若為空,則返回全部.
    • 注意,此處應傳鏈名,例如ETH,而不是ERC20.

    返回參數

    參數類型說明
    coinstring幣種
    chainsarrayObject
    > chainTypestring鏈類型
    > addressDepositstring充值地址
    > tagDepositstring充值tag
    > chainstring鏈名
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制

    請求示例

    GET /asset/v3/private/deposit/address/query?coin=USDT&chainType=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671174181320
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/x-www-form-urlencoded

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": [
    {
    "chainType": "ERC20",
    "addressDeposit": "xxxxxxxxxxx",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "ETH"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671174181514
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/modify-master-apikey.html b/zh-TW/account-asset/modify-master-apikey.html index 328d9b5724..8f8eec1c5d 100644 --- a/zh-TW/account-asset/modify-master-apikey.html +++ b/zh-TW/account-asset/modify-master-apikey.html @@ -4,13 +4,13 @@ 修改母帳戶的API Key設置 | Bybit API Documentation - +

    修改母帳戶的API Key設置

    修改母帳戶API key的設置。使用待修改的api key調用接口。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    信息

    只能修改調用該接口的api key

    HTTP 請求

    POST /user/v3/private/update-api

    請求參數

    參數是否必須類型說明
    readOnlyfalseinteger0 (默認):可讀可寫. 1:只讀
    ipsfalsearray綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的api key將在7天後失效
    permissionsfalseObject勾選api key權限. 如果不修改權限, 則不要傳入該參數
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransfer"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > CopyTradingfalsearray跟單交易. ["CopyTrading"]
    > BlockTradefalsearray大宗商品交易. ["BlockTrade"]
    > Exchangefalsearray兌換. ["ExchangeHistory"]
    > NFTfalsearrayNFT. ["NFTQueryProductList"]

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是 ""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限
    > BlockTradearray大宗交易的權限
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限
    ipsarray綁定的IP

    請求示例

    POST /user/v3/private/update-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671179084116
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 741

    {
    "readOnly": 0,
    "ips": "xxx.xxx.xxx.xx",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": ["BlockTrade"],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": ["NFTQueryProductList"]
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "341509",
    "note": "TESTING12SEP",
    "apiKey": "xxxxxxxxxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [
    "BlockTrade"
    ],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    },
    "ips": [
    "xxx.xxx.xxx.xxx"
    ]
    },
    "retExtInfo": {},
    "time": 1671179084363
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/modify-sub-apikey.html b/zh-TW/account-asset/modify-sub-apikey.html index 6cae463048..eb9d50e43d 100644 --- a/zh-TW/account-asset/modify-sub-apikey.html +++ b/zh-TW/account-asset/modify-sub-apikey.html @@ -4,13 +4,13 @@ 修改子帳戶的API Key設置 | Bybit API Documentation - +

    修改子帳戶的API Key設置

    修改子帳戶API key的設置, 支持母帳戶管理子帳戶key的設置, 或者子帳戶key直接修改本身。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 子API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)"
    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /user/v3/private/update-sub-api

    請求參數

    參數是否必須類型說明
    apikeyfalsestring子帳戶的api key
    • 當您要使用母帳戶來管理子帳戶的key時, 該字段必傳
    • 如果您是用對應的子帳戶api key修改本身, 該字段請不要傳入, 否則報錯
    readOnlyfalseinteger0 (默認):可讀可寫. 1:只讀
    ipsfalsestring綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的非永久api key將在7天後失效
    permissionsfalseObject勾選api key權限. 如果不修改權限, 則不要傳入該參數
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > Exchangefalsearray兌換. ["ExchangeHistory"]

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringapi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是 ""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限e
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限. 子帳戶暫不支持, 總是[]
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]
    ipsarrayIP綁定

    請求示例

    POST /user/v3/private/update-sub-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180069231
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 531

    {
    "readOnly": 0,
    "ips": "*",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Exchange": [
    "ExchangeHistory"
    ]
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "id": "111111111",
    "note": "TESTNET subacc testing",
    "apiKey": "xxxxxxxxxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": []
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1671180069386
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/rate-limit.html b/zh-TW/account-asset/rate-limit.html index 4cd1355c3c..4e2c8f743a 100644 --- a/zh-TW/account-asset/rate-limit.html +++ b/zh-TW/account-asset/rate-limit.html @@ -4,14 +4,14 @@ 頻率限制 | Bybit API Documentation - +

    頻率限制

    IP限頻

    警告

    如果您收到HTTP 403(拒絕訪問)響應, 您的 IP 已被暫時或永久禁止。 您應立即查看以下指南,以確保您的應用程序不會繼續違反限制。如果您在 30 分鐘後 仍被禁止,則您可能會被永久禁止。

    我們不建議您在這些限制的邊緣運行您的應用程序,以防異常的網絡活動導致意外違規。

    • GET/POST 請求 (共享):
      • 連續 5 秒內每秒不超過 120 個請求
    備註

    所有到api.bybit.comapi.bytick.com的流量共享此限制,無論是訪問現貨、期貨還是期權。

    違反限制後,您的 IP 將被禁止一段時間(通常為 30 分鐘)。 持續違反限制將導致永久禁止。 我們不能撤銷永久禁令或縮短臨時禁令。

    賬戶頻率限製

    警告

    如果您收到這樣的響應"ret_msg": "Too many visits!", 則表示您觸發了帳戶頻率限制, 請等到頻率限制重置以後, 再繼續發送請求。

    Bybit基於每分鐘的滾動時間窗口來做頻率限製,並且是按賬戶(uid)來做劃分限製,每次請求API響應頭(response header)中都會包含如下字段:

    • X-Bapi-Limit-Status - 該接口當前時間窗口剩余可用請求數
    • X-Bapi-Limit - 該接口當前頻率限製上限
    • X-Bapi-Limit-Reset-Timestamp - 如果您已超過該接口當前窗口頻率限製,該字段表示下個可用時間窗口的時間戳(毫秒),即什麽時候可以恢復訪問;如果您未超過該接口當前窗口頻率限製,該字段表示返回的是當前服務器時間(毫秒).

    Http 響應頭示例

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    接口頻率限制表

    劃轉

    路徑頻率
    /asset/v3/private/transfer/inter-transfer20 req/min
    /asset/v3/private/transfer/sub-member-transfer
    /asset/v3/private/transfer/transfer-sub-member-save
    /asset/v3/private/transfer/universal-transfer5 req/sec
    /asset/v3/private/transfer/inter-transfer/list/query60 req/min
    /asset/v3/private/transfer/sub-member-transfer/list/query
    /asset/v3/private/transfer/transfer-coin/list/query
    /asset/v3/private/transfer/sub-member/list/query
    /asset/v3/private/transfer/account-coin/balance/query
    /asset/v3/private/transfer/asset-info/query
    /asset/v3/private/transfer/universal-transfer/list/query2 req/sec
    /asset/v3/private/transfer/account-coins/balance/query2 req/sec

    提現與充值相關

    路徑頻率
    /asset/v3/private/deposit/sub-member-record/query300 req/min
    /asset/v3/private/deposit/record/query
    /asset/v3/private/withdraw/record/query
    /asset/v3/private/deposit/address/query
    /asset/v3/private/deposit/sub-member-address/query
    /asset/v3/private/coin-info/query2 req/sec
    /asset/v3/private/withdraw/cancel60 req/min
    /asset/v3/private/withdraw/create10 req/min

    母子帳戶相關

    路徑頻率
    /user/v3/private/create-sub-member5 req/sec
    /user/v3/private/create-sub-api
    /user/v3/private/frozen-sub-member
    /user/v3/private/update-api
    /user/v3/private/delete-api
    /user/v3/private/update-sub-api
    /user/v3/private/delete-sub-api
    /user/v3/private/query-sub-members10 req/sec
    /user/v3/private/query-api
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/rm-master-apikey.html b/zh-TW/account-asset/rm-master-apikey.html index 4643cc5062..d05d1d23aa 100644 --- a/zh-TW/account-asset/rm-master-apikey.html +++ b/zh-TW/account-asset/rm-master-apikey.html @@ -4,13 +4,13 @@ 刪除母帳戶的API Key | Bybit API Documentation - +

    刪除母帳戶的API Key

    刪除母帳戶下的api key。使用待刪除的api key調用接口。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    危險

    當心! 用於調用本接口的API KEY將會立馬失效。

    HTTP 請求

    POST /user/v3/private/delete-api

    請求參數

    返回參數

    請求示例

    POST /user/v3/private/delete-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180438117
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 4
    {}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671180438209
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/rm-sub-apikey.html b/zh-TW/account-asset/rm-sub-apikey.html index 997492dcac..31df4270c0 100644 --- a/zh-TW/account-asset/rm-sub-apikey.html +++ b/zh-TW/account-asset/rm-sub-apikey.html @@ -4,13 +4,13 @@ 刪除子帳戶下的API Key | Bybit API Documentation - +

    刪除子帳戶下的API Key

    刪除子帳戶下的api key。使用待刪除的子帳戶api key調用接口或者使用母帳戶調用刪除指定api key

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 子API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)"
    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    危險

    當心! 用於調用本接口後, 對應的子帳戶api key會立馬失效。

    HTTP 請求

    POST /user/v3/private/delete-sub-api

    請求參數

    參數是否必須類型說明
    apikeyfalsestring子帳戶的api key
    • 當您要使用母帳戶來管理子帳戶的key時, 該字段必傳
    • 如果您是用對應的子帳戶api key修改本身, 該字段請不要傳入, 否則報錯

    返回參數

    請求示例

    POST /user/v3/private/delete-sub-api HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671180557996
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    {
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1671180558095
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/set-deposit-acct.html b/zh-TW/account-asset/set-deposit-acct.html index bb293a4881..fc3e800e64 100644 --- a/zh-TW/account-asset/set-deposit-acct.html +++ b/zh-TW/account-asset/set-deposit-acct.html @@ -4,13 +4,13 @@ 設置充值帳戶 | Bybit API Documentation - +

    設置充值帳戶

    設置充值後的自動轉入帳戶類型。該功能與網頁端-設置-充值保持一致。

    信息
    • 資金會默認充值至資金帳戶, 通過該接口設置自動劃轉帳戶後,系統將會自動劃轉至目標帳戶。
    • 僅支持主帳號調用。
    提示
    • 統一交易帳戶(UTA)擁有FUND, UNIFIED, CONTRACT(反向期貨錢包), SPOT(將在2月底合併入UNIFIED錢包)
    • 統一保證金帳戶(UMA)擁有FUND, UNIFIED, CONTRACT(反向期貨錢包), SPOT
    • 普通帳戶擁有FUND, OPTION(USDC錢包), CONTRACT(期貨錢包), SPOT

    HTTP 請求

    POST /asset/v3/private/deposit/deposit-to-account

    請求參數

    參數是否必須類型說明
    accountTypetruestring帳戶類型
    • UNIFIED
    • SPOT
    • OPTION
    • CONTRACT
    • FUND

    返回參數

    參數類型說明
    statusinteger請求狀態:
    • 1: 修改成功
    • 0: 修改失敗

    請求示例

    POST /asset/v3/private/deposit/deposit-to-account HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676887913670
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "accountType": "CONTRACT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1676887914363
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/sub-deposit-addr.html b/zh-TW/account-asset/sub-deposit-addr.html index 39f34b6b89..7d3f3d8cec 100644 --- a/zh-TW/account-asset/sub-deposit-addr.html +++ b/zh-TW/account-asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ 查詢子帳戶充值地址信息 | Bybit API Documentation - +

    查詢子帳戶充值地址信息

    子帳戶充值地址信息查詢

    信息

    查詢子帳戶的充值地址信息。需使用帳戶的API key。

    HTTP 請求

    GET /asset/v3/private/deposit/sub-member-address/query

    請求參數

    參數是否必須類型說明
    coinfalsestring幣種
    chainTypefalsestring鏈名.
    • 注意,此處應傳鏈名,例如ETH,而不是ERC20
    subMemberIdtruestring子帳戶UID

    返回參數

    參數類型說明
    coinstring幣種
    chainsarrayObject
    > chainTypestring鏈類型
    > addressDepositstring充值地址
    > tagDepositstring充值tag
    > chainstring鏈名
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制

    請求示例

    GET /asset/v3/private/deposit/sub-member-address/query?coin=USDT&chainType=ETH&subMemberId=407767 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671174486288
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": {
    "chainType": "ERC20",
    "addressDeposit": "xxxxxxxxxxx",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "-1"
    }
    },
    "retExtInfo": {},
    "time": 1671174486505
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/sub-deposit-record.html b/zh-TW/account-asset/sub-deposit-record.html index 7b2e6c7da8..df75faefc1 100644 --- a/zh-TW/account-asset/sub-deposit-record.html +++ b/zh-TW/account-asset/sub-deposit-record.html @@ -4,13 +4,13 @@ 查詢子帳戶充值 (鏈上) | Bybit API Documentation - +

    查詢子帳戶充值 (鏈上)

    子帳戶充值紀錄

    Rules

    規則: 獲取子帳戶的入金紀錄。需使用帳戶的API Key。若要通過子帳戶API Key查詢入金紀錄,請使用充值紀錄查詢

    HTTP 請求

    GET /asset/v3/private/deposit/sub-member-record/query

    請求參數

    參數是否必須類型說明
    subMemberIdtrueinteger子帳戶UID
    startTimefalseinteger開始時間 (精確到毫秒)。 默認為當前時間之前30天
    endTimefalseinteger結束時間 (精確到毫秒)。 默認為當前時間
    coinfalsestring幣種名:舉例,BTC。默認全部
    cursorfalsestring游標信息:用來分頁。 默認空
    limitfalseinteger每頁條數。[1, 50], 默認為50

    返回參數

    參數類型說明
    rowsarrayObject
    > coinstring充值的幣種
    > chainstring鏈名
    > amountstring充值的數量
    > txIDstring交易ID。充值失敗/取消充值:為空
    > statusinteger
    • 0=未知
    • 1=待確認
    • 2=上賬中
    • 3=已完成
    • 4=充值失敗
    > toAddressstring充值的目標地址
    > tagstring充值目標地址的tag
    > depositFeestring充值手續費
    > successAtstring最後更新時間
    > confirmationsstring确认区块的数量
    > txIndexstring交易序列号
    > blockHashstring鏈上的哈希數
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制
    > depositTypeinteger入金類型. 0: 正常充值, 10: 充值觸發每日限額, 20: 異常充值
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/deposit/sub-member-record/query?subMemberId=xxxxxxxxxxx HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671169682466
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "1234567890",
    "status": 3,
    "toAddress": "xxxxxxxxxxx",
    "tag": "11234567890",
    "depositFee": "",
    "successAt": "1671018256000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTAwNTYwNiwibWF4SUQiOjEwMzE1MjN9"
    },
    "retExtInfo": {},
    "time": 1671166430718
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/sub-transfer-list.html b/zh-TW/account-asset/sub-transfer-list.html index ef82ecd95a..20d1eddf26 100644 --- a/zh-TW/account-asset/sub-transfer-list.html +++ b/zh-TW/account-asset/sub-transfer-list.html @@ -4,13 +4,13 @@ 查詢子母間劃轉記錄 | Bybit API Documentation - +

    查詢子母間劃轉記錄

    查詢子母帳戶間的劃轉記錄

    警告

    僅支持使用母帳戶API key查詢

    HTTP 請求

    GET /asset/v3/private/transfer/sub-member-transfer/list/query

    請求參數

    參數是否必須類型說明
    transferIdfalsestringUUID,全局唯一
    coinfalsestring幣種類型
    statusfalsestring劃轉狀態
    startTimefalseinteger開始時間戳(毫秒)
    endTimefalseinteger結束時間戳(毫秒)
    limitfalseinteger每頁數量限制
    cursorfalsestring游標,用來分頁

    返回參數

    參數類型說明
    listarrayObject
    > transferIdstringUUID,全局唯一
    > coinstring幣種類型
    > amountstring劃轉數量
    > memberIdinteger母賬戶ID
    > subMemberIdinteger子賬戶ID
    > timestampstring創建時間戳 (毫秒)
    > statusstring劃轉狀態
    > typestring轉入轉出類型.
    • IN 從主賬戶轉賬到子賬戶
    • OUT 從子賬戶轉賬到主賬戶
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/transfer/sub-member-transfer/list/query?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670927635525
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "memberId": xxxxxxx,
    "subMemberId": xxxxxxx,
    "timestamp": "1670925916000",
    "status": "SUCCESS",
    "type": "IN"
    },
    {
    "transferId": "11ff9144-2d5d-4233-913d-4595c9ad2170",
    "coin": "USDT",
    "amount": "100",
    "memberId": xxxxxxx,
    "subMemberId": xxxxxxx,
    "timestamp": "1658732947000",
    "status": "SUCCESS",
    "type": "OUT"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MzU2MTA0LCJtYXhJRCI6MTcyMDk2OH0="
    },
    "retExtInfo": {},
    "time": 1670927635641
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/sub-transfer.html b/zh-TW/account-asset/sub-transfer.html index da130c8b6f..8b2cce973a 100644 --- a/zh-TW/account-asset/sub-transfer.html +++ b/zh-TW/account-asset/sub-transfer.html @@ -4,13 +4,13 @@ 子母劃轉 | Bybit API Documentation - +

    子母劃轉

    觸發子母劃轉動作

    要發送賬戶類型和父子不可知的轉賬,請使用創建萬能轉賬接口。

    提示
    • 請註意該接口入參請求數據中的transferId字段為UUID全局唯一。
    • 該接口只能用於母子賬號之間的劃轉。
    • 一個子賬號只會歸屬於一個母賬號。
    • 如果您遇到錯誤碼是131228並且錯誤信息是your balance is not enough, 請前往查詢賬戶單個幣種余額接口確認安全限額。
    • 使用此API端点必须使用主账户的API key

    HTTP 請求

    POST /asset/v3/private/transfer/sub-member-transfer

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型
    amounttruestring兌入數量
    subMemberIdtrueinteger子賬戶ID
    typetruestring轉入轉出類型
    • IN 從主賬戶轉賬到子賬戶
    • OUT 從子賬戶轉賬到主賬戶

    返回參數

    參數類型說明
    transferIdstringUUID,全局唯一

    請求示例

    POST /asset/v3/private/transfer/sub-member-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670925915816
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: xxxxxxxxxxxxx
    Content-Type: application/json
    Content-Length: 144

    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "subMemberId": 554137,
    "type": "IN"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f"
    },
    "retExtInfo": {},
    "time": 1670925915979
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/sub-uid-list.html b/zh-TW/account-asset/sub-uid-list.html index 45a380c209..bf2b94a3bb 100644 --- a/zh-TW/account-asset/sub-uid-list.html +++ b/zh-TW/account-asset/sub-uid-list.html @@ -4,13 +4,13 @@ 查詢子賬號列表 | Bybit API Documentation - +

    查詢子賬號列表

    查詢子賬號列表

    HTTP 請求

    GET /asset/v3/private/transfer/sub-member/list/query

    請求參數

    返回參數

    參數類型說明
    subMemberIdsarray<string>所有子賬號列表
    transferableSubMemberIdsarray<string>所有可互相劃轉的子賬號列表

    請求示例

    GET /asset/v3/private/transfer/sub-member/list/query HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1670928351923
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "subMemberIds": [
    "111111",
    "2222222",
    "3333333"
    ],
    "transferableSubMemberIds": [
    "111111",
    "2222222",
    "3333333"
    ]
    },
    "retExtInfo": {},
    "time": 1670928352175
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/subuid-list.html b/zh-TW/account-asset/subuid-list.html index c14234856a..425da68953 100644 --- a/zh-TW/account-asset/subuid-list.html +++ b/zh-TW/account-asset/subuid-list.html @@ -4,13 +4,13 @@ 查詢子帳戶UID列表 | Bybit API Documentation - +

    查詢子帳戶UID列表

    獲取當前母帳戶下所有的子帳戶列表。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    GET /user/v3/private/query-sub-members

    請求參數

    返回參數

    參數類型說明
    subMembersarrayObject
    > uidstring子帳戶userId
    > usernamestring用戶名
    > memberTypeinteger1: 普通子帳戶, 6: 託管子帳戶
    > statusinteger帳戶狀態.
    • 1: 正常
    • 2: 登陸封禁
    • 4: 凍結
    > remarkstring備註

    請求示例

    GET /user/v3/private/query-sub-members HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430318405
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "subMembers": [
    {
    "uid": "53888001",
    "username": "xxx001",
    "memberType": 1,
    "status": 1,
    "remark": "test"
    },
    {
    "uid": "53888002",
    "username": "xxx002",
    "memberType": 6,
    "status": 1,
    "remark": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676430319452
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/transferable-coin-list.html b/zh-TW/account-asset/transferable-coin-list.html index d46c10bed3..36a632e71e 100644 --- a/zh-TW/account-asset/transferable-coin-list.html +++ b/zh-TW/account-asset/transferable-coin-list.html @@ -4,13 +4,13 @@ 賬號內可劃轉幣種列表 | Bybit API Documentation - +

    賬號內可劃轉幣種列表

    賬號內可劃轉幣種列表

    您可以在當前API key所屬的UID下確認不同賬戶類型之間的可劃轉的幣種

    HTTP 請求

    GET /asset/v3/private/transfer/transfer-coin/list/query

    請求參數

    參數是否必須類型說明
    fromAccountTypetruestring劃出賬戶類型. 劃入劃出帳戶類型必須不一樣
    toAccountTypetruestring劃出賬戶類型. 劃入劃出帳戶類型必須不一樣

    返回參數

    參數類型說明
    listarray賬號內互轉支持的幣種

    請求示例

    GET /asset/v3/private/transfer/transfer-coin/list/query?fromAccountType=SPOT&toAccountType=CONTRACT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163888641
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    "ETH",
    "EOS",
    "USDT",
    "ADA",
    "BIT",
    "BTC",
    "DAI",
    "DOT",
    "LTC",
    "MANA",
    "XRP"
    ]
    },
    "retExtInfo": {},
    "time": 1671163888818
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/uni-transfer-list.html b/zh-TW/account-asset/uni-transfer-list.html index 04d604cea7..146e06bb43 100644 --- a/zh-TW/account-asset/uni-transfer-list.html +++ b/zh-TW/account-asset/uni-transfer-list.html @@ -4,13 +4,13 @@ 查詢萬能劃轉記錄 | Bybit API Documentation - +

    查詢萬能劃轉記錄

    查詢萬能劃轉記錄

    該接口僅返回通過萬能劃轉接口以及網頁端的母子和子子劃轉的紀錄,通過其他劃轉接口的轉帳的紀錄將不會返回。

    提示
    • 母子帳號的api key都支持調用
    • 母帳號的api key需擁有"母子帳戶劃轉"(SubMemberTransfer)權限
    • 子帳號的api key需擁有"母子帳戶劃轉"(SubMemberTransferList)權限

    HTTP 請求

    GET /asset/v3/private/transfer/universal-transfer/list/query

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型
    statusfalsestring劃轉狀態
    startTimefalseinteger開始時間戳(毫秒) 注意: 實際查詢時是秒級維度生效
    endTimefalseinteger結束時間戳(毫秒) 注意: 實際查詢時是秒級維度生效
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標, 用來分頁

    返回參數

    參數類型說明
    listarrayObject
    > transferIdstringUUID,全局唯一
    > coinstring幣種類型
    > amountstring劃轉數量
    > timestampstring創建時間戳 (毫秒)
    > statusstring劃轉狀態
    > fromAccountTypestring劃出賬戶類型
    > toAccountTypestring劃入賬戶類型
    > fromMemberIdstring劃出的UID
    > toMemberIdstring劃入UID
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/transfer/universal-transfer/list/query?coin=USDT&status=SUCCESS HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163509262
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "timestamp": "1671163374000",
    "status": "SUCCESS",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT",
    "fromMemberId": "11111111",
    "toMemberId": "22222222"
    },
    {
    "transferId": "2811a2ca-b42c-4cda-a21f-3df0a1f2516f",
    "coin": "USDT",
    "amount": "5",
    "timestamp": "1670925916000",
    "status": "SUCCESS",
    "fromAccountType": "SPOT",
    "toAccountType": "SPOT",
    "fromMemberId": "111111111",
    "toMemberId": "33333333"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MzU2MTA0LCJtYXhJRCI6MTczNDQ5Mn0="
    },
    "retExtInfo": {},
    "time": 1671163509474
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/uni-transfer.html b/zh-TW/account-asset/uni-transfer.html index 907128f3a4..e37a7c57ed 100644 --- a/zh-TW/account-asset/uni-transfer.html +++ b/zh-TW/account-asset/uni-transfer.html @@ -4,13 +4,13 @@ 萬能劃轉 | Bybit API Documentation - +

    萬能劃轉

    萬能劃轉, 您可以進行子帳戶之間,以及母子之間的劃轉

    警告
    • 支持使用母帳戶或者子帳號api key請求
      • 若要使用子帳號api key, 需要有"母子帳戶劃轉"(SubMemberTransferList)權限
      • 當使用子帳號api key劃轉時, 僅能劃轉到母帳號下
    • 如果您遇到錯誤碼是131228並且錯誤信息是your balance is not enough, 請前往查詢賬戶單個幣種余額接口確認安全限額.

    HTTP 請求

    POST /asset/v3/private/transfer/universal-transfer

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型
    amounttruestring劃轉數量
    fromMemberIdtruestring劃出的賬號uid. fromMemberIdtoMemberId不能一樣
    toMemberIdtruestring劃入的賬號uid. fromMemberIdtoMemberId不能一樣
    fromAccountTypetruestring劃出賬戶類型
    toAccountTypetruestring劃入賬戶類型

    返回參數

    參數類型說明
    transferIdstringUUID,全局唯一

    請求示例

    POST /asset/v3/private/transfer/universal-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671163372208
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 219

    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06",
    "coin": "USDT",
    "amount": "10",
    "fromMemberId":"111111",
    "toMemberId":"222222",
    "fromAccountType": "UNIFIED",
    "toAccountType": "SPOT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb06"
    },
    "retExtInfo": {},
    "time": 1671163373537
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/wallet-type.html b/zh-TW/account-asset/wallet-type.html index 8373d653f4..50452d0d42 100644 --- a/zh-TW/account-asset/wallet-type.html +++ b/zh-TW/account-asset/wallet-type.html @@ -4,13 +4,13 @@ 查詢帳戶支持的錢包類型 | Bybit API Documentation - +

    查詢帳戶支持的錢包類型

    查詢母帳戶或者子帳戶下支持的錢包類型

    提示
    • 使用母帳戶api key: 您可以查詢到母帳戶以及指定的子帳戶的錢包類型, 子帳戶的uid最多單次可查詢200個.
    • 使用子帳戶api key: 僅能查詢自身的錢包類型
    最佳實踐

    "FUND" - 這個資金錢包, 如果您從未存入或者轉入過資金, 該接口返回的數組裡將不會呈現該枚舉值, 但實際上您的帳戶總是擁有該錢包.

    • ["SPOT","OPTION","FUND","CONTRACT"] : 普通帳戶並且資金錢包曾經操作過
    • ["SPOT","OPTION","CONTRACT"] : 普通帳戶並且資金錢包不曾操作過
    • ["SPOT","UNIFIED","FUND","CONTRACT"] : UMA帳戶並且資金錢包曾經操作過. (等強制或主動升級到UTA後, 就沒有UMA帳戶的概念了)
    • ["SPOT","UNIFIED","CONTRACT"] : UMA帳戶並且資金錢包不曾操作過. (等強制或主動升級到UTA後, 就沒有UMA帳戶的概念了)
    • ["UNIFIED""FUND","CONTRACT"] : UTA帳戶並且資金錢包曾經操作過
    • ["UNIFIED","CONTRACT"] : UTA帳戶並且資金錢包不曾操作過

    HTTP 請求

    GET /user/v3/private/get-member-type

    請求參數

    參數是否必須類型說明
    memberIdsfalsestring
    • 不入参時, 僅查詢自身
    • 當使用母帳戶api key查詢子uid時, 母帳戶的數據總是返回且在數組的第一個
    • 支持輸入多個子uid, 用逗號隔開, 單次查詢最多支持200個
    • 子帳戶api key查詢時, 該入参將會被忽略

    返回參數

    參數類型說明
    accountsarrayObject
    > uidstring母/子 uid
    > accountTypearraySPOT, CONTRACT, FUND, OPTION, UNIFIED. 請查閱上面的最佳實踐來理解返回的值

    Request Example

    GET /user/v3/private/get-member-type HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686882546210
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "accounts": [
    {
    "uid": "XXXXX",
    "accountType": [
    "SPOT",
    "OPTION",
    "FUND",
    "CONTRACT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686880658551
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/withdraw-record.html b/zh-TW/account-asset/withdraw-record.html index b143eac1b9..adbb862b0b 100644 --- a/zh-TW/account-asset/withdraw-record.html +++ b/zh-TW/account-asset/withdraw-record.html @@ -4,13 +4,13 @@ 查詢提現記錄 | Bybit API Documentation - +

    查詢提現記錄

    提現記錄查詢

    信息

    規則:按id倒序進行,開始時間和截止時間差最大限制為30天

    HTTP 請求

    GET /asset/v3/private/withdraw/record/query

    請求參數

    參數是否必須類型說明
    withdrawIDfalseinteger提現ID。 (提現API響應參數中的提現請求ID)
    startTimefalseinteger開始時間 (毫秒)。 默認為當前時間之前30天
    endTimefalseinteger結束時間 (毫秒)。 默認為當前時間
    coinfalsestring幣種名:舉例,BTC。默認全部
    withdrawTypefalsestring
    • 0 (默認):鏈上提現.
    • 1:平台內部轉帳.
    • 2:鏈上提現和內部轉帳
    cursorfalsestring游標信息:用來分頁。 默認空
    limitfalseinteger每頁條數。[1, 50], 默認為50

    返回參數

    ParameterTypeComments
    rowsarrayObject
    > coinstring提現的幣種
    > chainstring鏈名
    > amountstring提現的數量
    > txIDstring交易ID。提現失敗/提現撤銷/內部轉帳:為空
    > statusinteger提現狀態
    > toAddressstring提現目標地址. 內部轉帳:顯示郵箱或手機號
    > tagstring提現目標地址的tag
    > withdrawFeestring提現手續費
    > createTimestring發起提幣時間
    > updateTimestring提幣狀態更新時間
    > withdrawIdstring提現ID
    > withdrawTypeinteger出金類型.
    • 0:鏈上出金;
    • 1:內部地址轉帳
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /asset/v3/private/withdraw/record/query HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671171632559
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "TRX",
    "amount": "10",
    "txID": "",
    "status": "CancelByUser",
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "withdrawFee": "1",
    "createTime": "1670906044000",
    "updateTime": "1670906050000",
    "withdrawId": "9965",
    "withdrawType": 0
    },
    {
    "coin": "USDT",
    "chain": "TRX",
    "amount": "10",
    "txID": "",
    "status": "CancelByUser",
    "toAddress": "xxxxxxxxxxx",
    "tag": "",
    "withdrawFee": "1",
    "createTime": "1670905993000",
    "updateTime": "1670906001000",
    "withdrawId": "9964",
    "withdrawType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6OTk2NCwibWF4SUQiOjk5NjV9"
    },
    "retExtInfo": {},
    "time": 1671171632649
    }
    - + \ No newline at end of file diff --git a/zh-TW/account-asset/withdraw.html b/zh-TW/account-asset/withdraw.html index 0d7142c5aa..99ba388f0b 100644 --- a/zh-TW/account-asset/withdraw.html +++ b/zh-TW/account-asset/withdraw.html @@ -4,13 +4,13 @@ 提現 | Bybit API Documentation - +

    提現

    若目標地址是Bybit平台內部地址,您可以實現內部平台轉帳

    信息
    • 確保您已經將提幣地址加入到這裡
    危險
    • UTA用戶注意, Bybit預計在二月底將操作現貨帳戶合併入統一帳戶, 所以請調整提現邏輯,即先將資金轉入資金帳戶,然完成提現。
    • 如何確定當前帳戶是否為UTA帳戶? 調用該接口, 若uta=1, 則表面該api key所屬的帳戶是UTA帳戶。
    公式

    feeType=0:

    • 若百分比手續費 != 0: 手續費 = 輸入金額 / (1 - 百分比手續費) * 百分比手續費 + 固定手續費
    • 若百分比手續費 = 0: 手續費 = 固定手續費

    feeType=1:

    • 若百分比手續費 != 0: 手續費 = 固定手續費 + (輸入金額 - 固定手續費) * 百分比手續費
    • 若百分比手續費 = 0: 手續費 = 固定手續費

    HTTP 請求

    POST /asset/v3/private/withdraw/create

    請求參數

    參數是否必須類型說明
    cointruestring幣種
    chaintruestring鏈名
    addresstruestring提幣地址. 注意大小寫,請使用和提幣地址簿中完全一樣的地址
    tagfalsestring存在tag的需要填寫. 注意: 如果鏈不支持tag/memo,請移除地址簿中的tag/memo,然後調用接口時,也不要傳tag字段
    amounttruestring提幣數量。最小提幣金額可從幣種信息接口獲取。
    timestamptrueinteger取用當前時間戳
    forceChainfalseinteger是否強制走鏈提幣.
    • 0(默認):解析到若為內部地址 ,則內部轉帳
    • 1:強制走鏈
    accountTypefalsestring設置出金帳戶.
    • SPOT(默認):走現貨錢包出金
    • FUND:走資金錢包出金
    feeTypefalseinteger手續費選項
    • 0(默認): 輸入金額即實際收到的金額, 所以您需要額外考慮手續費
    • 1: 輸入金額不是實際收到的金額, 系統將會自動計算所需的手續費

    返回參數

    參數類型說明
    idstring提現ID

    請求示例

    POST /asset/v3/private/withdraw/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671172758674
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json
    Content-Length: 193

    {
    "coin": "USDT",
    "chain": "ETH",
    "address": "xxxxxxxxxxx",
    "tag": null,
    "amount": "10",
    "timestamp": 1670919612851,
    "forceChain": 1,
    "accountType": "FUND"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "xxxxxxxxxxx"
    },
    "retExtInfo": {},
    "time": 1671172180550
    }
    - + \ No newline at end of file diff --git a/zh-TW/account_asset.html b/zh-TW/account_asset.html index c2d73fb1d9..e0206f5e9e 100644 --- a/zh-TW/account_asset.html +++ b/zh-TW/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/account_asset/v1.html b/zh-TW/account_asset/v1.html index a5deac105d..fbe3d7f09d 100644 --- a/zh-TW/account_asset/v1.html +++ b/zh-TW/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/account_asset/v3.html b/zh-TW/account_asset/v3.html index 6860328574..7ba26a93f2 100644 --- a/zh-TW/account_asset/v3.html +++ b/zh-TW/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/category.html b/zh-TW/api-explorer/derivatives/category.html index 0055a220c1..78dc544d0b 100644 --- a/zh-TW/api-explorer/derivatives/category.html +++ b/zh-TW/api-explorer/derivatives/category.html @@ -4,13 +4,13 @@ Derivatives API | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/delivery-price.html b/zh-TW/api-explorer/derivatives/market/delivery-price.html index 84a6ccdb8b..a75a48a1e5 100644 --- a/zh-TW/api-explorer/derivatives/market/delivery-price.html +++ b/zh-TW/api-explorer/derivatives/market/delivery-price.html @@ -4,13 +4,13 @@ Delivery price | Bybit API Documentation - +

    Delivery price

    Get delivery price of option

    Query Parameters
    • category string[]

      Possible values: [option]

      Products category. option only

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • direction string

      Possible values: [prev, next]

      The direction to pagination

    • limit string

      Default value: 50

      Maximum 200

    • cursor string

      The cursor, used to pagination

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/his-fund-rate.html b/zh-TW/api-explorer/derivatives/market/his-fund-rate.html index 0c2f8375a6..c8f6ffbd3e 100644 --- a/zh-TW/api-explorer/derivatives/market/his-fund-rate.html +++ b/zh-TW/api-explorer/derivatives/market/his-fund-rate.html @@ -4,13 +4,13 @@ Funding Rate History | Bybit API Documentation - +

    Funding Rate History

    Get historical funding rate

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • start string

      The start timstamp (ms)

    • end string

      The end timstamp (ms)

    • limit string

      Default value: 200

      Maximum 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/index-kline.html b/zh-TW/api-explorer/derivatives/market/index-kline.html index 12185710a0..5442cfdf90 100644 --- a/zh-TW/api-explorer/derivatives/market/index-kline.html +++ b/zh-TW/api-explorer/derivatives/market/index-kline.html @@ -4,13 +4,13 @@ Index Price Kline | Bybit API Documentation - +

    Index Price Kline

    Get index price kline data

    Query Parameters
    • category string[]

      Possible values: [future]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms)

    • end integer required

      end timestamp (ms)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/instrument.html b/zh-TW/api-explorer/derivatives/market/instrument.html index b054eaff30..46c02fe09a 100644 --- a/zh-TW/api-explorer/derivatives/market/instrument.html +++ b/zh-TW/api-explorer/derivatives/market/instrument.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - +

    Instrument Info

    Get launched instruments information. category=option is required for option.

    Query Parameters
    • category string[]

      Possible values: [future, option]

      Products category

    • symbol string

      Symbol name

    • baseCoin string

      Default value: BTC

      for option ONLY

    • limit string

      Default value: 500

      Maximum 1000

    • cusor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • category string
    • list object[]
    • symbol string
    • contractType string
    • status string
    • baseCoin string
    • quoteCoin string
    • launchTime string
    • deliveryTime string
    • deliveryFeeRate string
    • priceScale string
    • leverageFilter object
    • minLeverage string
    • maxLeverage string
    • leverageStep string
    • priceFilter object
    • minPrice string
    • maxPrice string
    • tickSize string
    • lotSizeFilter object
    • maxTradingQty string
    • minTradingQty string
    • qtyStep string
    • nexPageCursor string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/kline.html b/zh-TW/api-explorer/derivatives/market/kline.html index 2793afd6e4..73e5b8cba0 100644 --- a/zh-TW/api-explorer/derivatives/market/kline.html +++ b/zh-TW/api-explorer/derivatives/market/kline.html @@ -4,13 +4,13 @@ Kline | Bybit API Documentation - +

    Kline

    Get kline data

    Query Parameters
    • category string[]

      Possible values: [future]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms)

    • end integer required

      end timestamp (ms)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/mark-kline.html b/zh-TW/api-explorer/derivatives/market/mark-kline.html index b12310b542..4f6616cc6b 100644 --- a/zh-TW/api-explorer/derivatives/market/mark-kline.html +++ b/zh-TW/api-explorer/derivatives/market/mark-kline.html @@ -4,13 +4,13 @@ Mark Price Kline | Bybit API Documentation - +

    Mark Price Kline

    Get mark price kline data

    Query Parameters
    • category string[]

      Possible values: [future]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms)

    • end integer required

      end timestamp (ms)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/market.html b/zh-TW/api-explorer/derivatives/market/market.html index ff0cfc5855..4409f36a6d 100644 --- a/zh-TW/api-explorer/derivatives/market/market.html +++ b/zh-TW/api-explorer/derivatives/market/market.html @@ -4,13 +4,13 @@ Market Data Endpoints | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/open-interest.html b/zh-TW/api-explorer/derivatives/market/open-interest.html index 953d8beff7..5f7ea2cd9c 100644 --- a/zh-TW/api-explorer/derivatives/market/open-interest.html +++ b/zh-TW/api-explorer/derivatives/market/open-interest.html @@ -4,13 +4,13 @@ Open Interest | Bybit API Documentation - +

    Open Interest

    Get open interest

    Query Parameters
    • category string[]

      Possible values: [linear, inverse]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [5min, 15min, 30min, 1h, 4h, 1d]

      interval

    • startTime string

      The start timstamp (ms)

    • endTime string

      The end timstamp (ms)

    • limit string

      Default value: 50

      Maximum 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/orderbook.html b/zh-TW/api-explorer/derivatives/market/orderbook.html index 2c472902d8..2c5adb34c1 100644 --- a/zh-TW/api-explorer/derivatives/market/orderbook.html +++ b/zh-TW/api-explorer/derivatives/market/orderbook.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - +

    Order Book

    Get order book data

    Query Parameters
    • category string[]

      Possible values: [future, option]

      Default value: future

      Products category

    • symbol string required

      Symbol name

    • limit int

      Default value: 25

      Maximum 500

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • s string
    • b array[]
    • a array[]
    • ts timestamp
    • u sequence
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/premium-index-kline.html b/zh-TW/api-explorer/derivatives/market/premium-index-kline.html index 585e5febaa..c94bd78abd 100644 --- a/zh-TW/api-explorer/derivatives/market/premium-index-kline.html +++ b/zh-TW/api-explorer/derivatives/market/premium-index-kline.html @@ -4,13 +4,13 @@ Premium Index Price Kline | Bybit API Documentation - +

    Premium Index Price Kline

    Get premium index price kline data

    Query Parameters
    • category string[]

      Possible values: [future]

      Products category

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer required

      start timestamp (ms)

    • end integer required

      end timestamp (ms)

    • limit integer

      Default value: 200

      Maximum 200

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • symbol string
    • category string
    • list array[]
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/public-trade.html b/zh-TW/api-explorer/derivatives/market/public-trade.html index e608907024..31f491b3da 100644 --- a/zh-TW/api-explorer/derivatives/market/public-trade.html +++ b/zh-TW/api-explorer/derivatives/market/public-trade.html @@ -4,13 +4,13 @@ Public trade | Bybit API Documentation - +

    Public trade

    Get public trade

    Query Parameters
    • category string[]

      Possible values: [linear, inverse, option]

      Products category

    • symbol string

      Symbol name. linear or inverse, required

    • baseCoin string

      Base coin. Valid for option.

    • optionType string

      Possible values: [Call, Put]

      Option type. Valid for option.

    • limit integer

      Default value: 500

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/risk-limit.html b/zh-TW/api-explorer/derivatives/market/risk-limit.html index af66bdf1a1..a9136fe7bb 100644 --- a/zh-TW/api-explorer/derivatives/market/risk-limit.html +++ b/zh-TW/api-explorer/derivatives/market/risk-limit.html @@ -4,13 +4,13 @@ Risk limit | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/market/ticker.html b/zh-TW/api-explorer/derivatives/market/ticker.html index 26283789f0..1e3286df05 100644 --- a/zh-TW/api-explorer/derivatives/market/ticker.html +++ b/zh-TW/api-explorer/derivatives/market/ticker.html @@ -4,13 +4,13 @@ Tikcer Info | Bybit API Documentation - +

    Tikcer Info

    Get all latest information of symbols. All parameters are needed for OPTION

    Query Parameters
    • category string[]

      Possible values: [future, option]

      Products category

    • symbol string

      Symbol name

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • category string
    • list object[]
    • symbol string
    • bidPrice string
    • askPrice string
    • lastPrice string
    • lastTickDirection string
    • prevPrice24h string
    • price24hPcnt string
    • highPrice24h string
    • lowPrice24h string
    • prevPrice1h string
    • markPrice string
    • indexPrice string
    • openInterest string
    • turnover24h string
    • volume24h string
    • fundingRate string
    • nextFundingTime string
    • predictedDeliveryPrice string
    • basisRate string
    • deliveryFeeRate string
    • deliveryTime string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/auto-margin.html b/zh-TW/api-explorer/derivatives/trade/contract/auto-margin.html index 0a094abf5e..7aa030fe02 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/auto-margin.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/auto-margin.html @@ -4,13 +4,13 @@ Set Auto Add Margin | Bybit API Documentation - +

    Set Auto Add Margin

    Turn on/off auto add position margin.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

      Side

    • autoAddMargin integer required

      Possible values: [0, 1]

      Turn on / off. 0=off, 1=on

    • positionIdx integer

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/cancel-all.html b/zh-TW/api-explorer/derivatives/trade/contract/cancel-all.html index cef9a5e388..9a9c0bfe13 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/cancel-all.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Order | Bybit API Documentation - +

    Cancel All Order

    Cancel all orders.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string

      Symbol name

    • baseCoin string

      Cancel by base coin

    • settleCoin string

      Cancel by settle coin

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/cancel-order.html b/zh-TW/api-explorer/derivatives/trade/contract/cancel-order.html index fe366db288..b3d57c8f15 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/cancel-order.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/cancel-order.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    Cancel a order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/close-pnl.html b/zh-TW/api-explorer/derivatives/trade/contract/close-pnl.html index 850e4b8873..14c5baa56a 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/close-pnl.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/close-pnl.html @@ -4,13 +4,13 @@ Get Closed PnL | Bybit API Documentation - +

    Get Closed PnL

    Get closed pnl.

    Query Parameters
    • symbol string

      Symbol name

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/contract.html b/zh-TW/api-explorer/derivatives/trade/contract/contract.html index d30881dc8a..fd1a4fdade 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/contract.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/contract.html @@ -4,13 +4,13 @@ Contract | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/create-order.html b/zh-TW/api-explorer/derivatives/trade/contract/create-order.html index b8fd10d9e3..34537f5c00 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/create-order.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/create-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +

    Place Order

    Place a future or option order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required

      Order qty

    • price string

      ignore it if Market order

    • triggerPrice string

      param for StopOrder

    • triggerDirection integer

      param for StopOrder. 1=rise, 2=fall

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      param for StopOrder

    • timeInForce string required

      Possible values: [GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly]

      Time in force

    • positionIdx integer required

      Possible values: [0, 1, 2]

      0=one-way mode, 1=buy-hedge-mode, 2=sell-hedge-mode

    • orderLinkId string

      User customised order ID

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger stop loss price price type

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger string

      Possible values: [true, false]

      close on trigger

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/cross-isolated-margin.html b/zh-TW/api-explorer/derivatives/trade/contract/cross-isolated-margin.html index 20bd1f3b00..aff2a3cbcc 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/cross-isolated-margin.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/cross-isolated-margin.html @@ -4,13 +4,13 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +

    Switch Cross/Isolated Margin

    Switch cross/isolated margin mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • tradeMode integer required

      Possible values: [0, 1]

      Trade mode. 0=crossMargin, 1=isolatedMargin

    • buyLeverage string required

      Buy side leverage. Make sure buyLeverage equals to sellLeverage

    • sellLeverage string required

      Sell side leverage. Make sure buyLeverage equals to sellLeverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/execution.html b/zh-TW/api-explorer/derivatives/trade/contract/execution.html index 68fcc67c49..73308d2544 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/execution.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/execution.html @@ -4,13 +4,13 @@ Get Execution List | Bybit API Documentation - +

    Get Execution List

    Get execution list.

    Query Parameters
    • symbol string required

      Symbol name

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • execType string

      Execution type

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/leverage.html b/zh-TW/api-explorer/derivatives/trade/contract/leverage.html index 1f5a14fb1c..e62b8dc543 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/leverage.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set levearage.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/open-order.html b/zh-TW/api-explorer/derivatives/trade/contract/open-order.html index 600970211c..cb31a01004 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/open-order.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    Get unfilled orders.

    Query Parameters
    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • settleCoin string
    • orderId string
    • orderLinkId string

      User customised order id

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor for pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/order-list.html b/zh-TW/api-explorer/derivatives/trade/contract/order-list.html index f12c117ce2..a4cb24a01b 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/order-list.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/order-list.html @@ -4,13 +4,13 @@ Get Order List | Bybit API Documentation - +

    Get Order List

    Get order history.

    Query Parameters
    • symbol string

      Symbol name

    • orderId string
    • orderLinkId string

      User customised order id

    • orderStatus string

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/position-info.html b/zh-TW/api-explorer/derivatives/trade/contract/position-info.html index f8a0b260f8..1e74950658 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/position-info.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/position-info.html @@ -4,13 +4,13 @@ My Position | Bybit API Documentation - +

    My Position

    Get real-time position data.

    Query Parameters
    • symbol string

      Symbol name

    • settleCoin string

      symbol or settleCoin is required

    • limit string

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/position-mode.html b/zh-TW/api-explorer/derivatives/trade/contract/position-mode.html index 1f21ef9e55..21989e2bcd 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/position-mode.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/position-mode.html @@ -4,13 +4,13 @@ Switch Position Mode | Bybit API Documentation - +

    Switch Position Mode

    Switch position mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string

      Symbol name. Either symbol or coin is required

    • coin string

      Coin. Either symbol or coin is required

    • mode string required

      Possible values: [0, 3]

      Position mode. 0=mergedSingle, 3=bothSide

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/replace-order.html b/zh-TW/api-explorer/derivatives/trade/contract/replace-order.html index 1e98b3859f..77c715f0e8 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/replace-order.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +

    Replace Order

    Replace an order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/set-risk-limit.html b/zh-TW/api-explorer/derivatives/trade/contract/set-risk-limit.html index 7ac7510cfa..1eb139bfd9 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/set-risk-limit.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/set-risk-limit.html @@ -4,13 +4,13 @@ Set Risk Limit | Bybit API Documentation - +

    Set Risk Limit

    Set risk limit.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • riskId integer required

      Risk limit id

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/tpsl-mode.html b/zh-TW/api-explorer/derivatives/trade/contract/tpsl-mode.html index a99d3de3f2..572018d1e0 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/tpsl-mode.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/tpsl-mode.html @@ -4,13 +4,13 @@ Switch TP/SL Mode | Bybit API Documentation - +

    Switch TP/SL Mode

    Switch tp/sl mode.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • tpSlMode string required

      Possible values: [Full, Partial]

      Full=full position TP/SL, Partial=partial mode tp/sl

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/contract/trading-stop.html b/zh-TW/api-explorer/derivatives/trade/contract/trading-stop.html index 4c9c704da7..ee18a950ec 100644 --- a/zh-TW/api-explorer/derivatives/trade/contract/trading-stop.html +++ b/zh-TW/api-explorer/derivatives/trade/contract/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +

    Set Trading Stop

    Set trade stop.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpSize string

      Take profit size

    • slSize string

      Stop loss size

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Take profit trigger price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Stop loss trigger price type

    • trailingStop string

      Trailing stop

    • activePrice string

      Trailing stop trigger price

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/batch-cancel.html b/zh-TW/api-explorer/derivatives/trade/unified/batch-cancel.html index d51c83ed88..0df1b16db1 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/batch-cancel.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +

    Batch Cancel Order

    Batch cancel orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/batch-place.html b/zh-TW/api-explorer/derivatives/trade/unified/batch-place.html index 5a63d77d43..80204c93ca 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/batch-place.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/batch-place.html @@ -4,13 +4,13 @@ Batch Place Order | Bybit API Documentation - +

    Batch Place Order

    Batch place orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required
    • price string
    • iv string
    • timeInForce string required

      Possible values: [GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0]

      Position mode. one-way mode only for unified.

    • orderLinkId string

      REQUIRED param when place an option order

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger string

      Possible values: [true, false]

      close on trigger

    • mmp boolean

      Possible values: [true, false]

      market marker protection. for option order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/batch-replace-place.html b/zh-TW/api-explorer/derivatives/trade/unified/batch-replace-place.html index 2dff15a320..2f28a9a87c 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/batch-replace-place.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/batch-replace-place.html @@ -4,13 +4,13 @@ Batch Replace Order | Bybit API Documentation - +

    Batch Replace Order

    Batch replace orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • iv string

      Modify option order iv

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/cancel-all.html b/zh-TW/api-explorer/derivatives/trade/unified/cancel-all.html index 61e52746cc..e533188d34 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/cancel-all.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/cancel-all.html @@ -4,13 +4,13 @@ Cancl All Orders | Bybit API Documentation - +

    Cancl All Orders

    Cancel all orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string

      Possible values: [linear, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin, e.g., BTC

    • settleCoin string

      Base coin, e.g., USDT

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/cancel-order.html b/zh-TW/api-explorer/derivatives/trade/unified/cancel-order.html index 9f7ca34db4..1ebcd01c15 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/cancel-order.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/cancel-order.html @@ -4,13 +4,13 @@ Cancl Order | Bybit API Documentation - +

    Cancl Order

    Cancel a future or option order

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string

      Possible values: [linear, option]

      Product type

    • symbol string

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/create-order.html b/zh-TW/api-explorer/derivatives/trade/unified/create-order.html index 07b1742bba..a70736226e 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/create-order.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/create-order.html @@ -4,13 +4,13 @@ Create order | Bybit API Documentation - +

    Create order

    Place a future or option order

    Header Parameters
    • apiKey string

      Please pass unified account api key

    • secret string

      Please pass unified account api secret

    Request Body
    • category string

      Possible values: [linear, option]

      Product category

    • symbol string
    • side string

      Possible values: [Buy, Sell]

    • orderType string

      Possible values: [Market, Sell]

    • qty string
    • price string
    • triggerPrice string
    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

    • iv string
    • timeInForce string
    • positionIdx string
    • orderLinkId string
    • takeProfit string
    • stopLoss string
    • tpTriggerBy string
    • slTriggerBy string
    • reduceOnly string
    • closeOnTrigger string
    • mmp string
    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/myposition.html b/zh-TW/api-explorer/derivatives/trade/unified/myposition.html index 2cb989bca9..6ce66ab8e9 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/myposition.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/myposition.html @@ -4,13 +4,13 @@ Get position | Bybit API Documentation - +

    Get position

    Get your position info

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string
    • baseCoin string

      Default value: BTC

      for option only

    • direction string

      Possible values: [prev, next]

      Default value: next

      direction to page

    • limit string

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      Please pass unified account api key

    • secret string

      Please pass unified account api secret

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/open-order.html b/zh-TW/api-explorer/derivatives/trade/unified/open-order.html index c746a51289..6d898e5d07 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/open-order.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    Get unfilled orders

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string

      Symbol name

    • baseCoin string

      for option only

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/order-list.html b/zh-TW/api-explorer/derivatives/trade/unified/order-list.html index ad65c5e2ee..bdfe7acd8d 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/order-list.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/order-list.html @@ -4,13 +4,13 @@ Get Order List | Bybit API Documentation - +

    Get Order List

    Get order list

    Query Parameters
    • category string required

      Possible values: [linear, option]

    • symbol string

      Symbol name

    • baseCoin string

      for option only

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderStatus string

      Possible values: [New, Filled, Cancelled, Rejected, PartiallyFilled, Untriggered, Deactivated, Triggered]

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/replace-order.html b/zh-TW/api-explorer/derivatives/trade/unified/replace-order.html index 8884913238..c7ef84db16 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/replace-order.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/replace-order.html @@ -4,13 +4,13 @@ Replace Order | Bybit API Documentation - +

    Replace Order

    Replace an order

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, option]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, StopOrder]

      active order or conditional order

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • iv string

      Modify option order iv

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    Responses

    successful operation


    Schema
    • retCode integer
    • retMsg string
    • result object
    • orderId string
    • orderLinkId string
    • retExtInfo object
    • time timestamp
    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/derivatives/trade/unified/unified.html b/zh-TW/api-explorer/derivatives/trade/unified/unified.html index ec499b202d..96f73b22ca 100644 --- a/zh-TW/api-explorer/derivatives/trade/unified/unified.html +++ b/zh-TW/api-explorer/derivatives/trade/unified/unified.html @@ -4,13 +4,13 @@ Unified Margin Account | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/category.html b/zh-TW/api-explorer/spot/category.html index bcefe585ff..dee884479a 100644 --- a/zh-TW/api-explorer/spot/category.html +++ b/zh-TW/api-explorer/spot/category.html @@ -4,13 +4,13 @@ Spot API | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/borrow-margin-loan.html b/zh-TW/api-explorer/spot/crossmargin/borrow-margin-loan.html index ed4262bcaa..0619292301 100644 --- a/zh-TW/api-explorer/spot/crossmargin/borrow-margin-loan.html +++ b/zh-TW/api-explorer/spot/crossmargin/borrow-margin-loan.html @@ -4,13 +4,13 @@ Borrow Margin Loan | Bybit API Documentation - +

    Borrow Margin Loan

    Borrow Margin Loan

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • coin string required

      currency

    • qty string required

      Amount To Borrow

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/crossmargin.html b/zh-TW/api-explorer/spot/crossmargin/crossmargin.html index 838143ed8e..b4b0365f20 100644 --- a/zh-TW/api-explorer/spot/crossmargin/crossmargin.html +++ b/zh-TW/api-explorer/spot/crossmargin/crossmargin.html @@ -4,13 +4,13 @@ Spot Margin Trade | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/query-account-info.html b/zh-TW/api-explorer/spot/crossmargin/query-account-info.html index 25455a5d7d..9e2875b33a 100644 --- a/zh-TW/api-explorer/spot/crossmargin/query-account-info.html +++ b/zh-TW/api-explorer/spot/crossmargin/query-account-info.html @@ -4,13 +4,13 @@ Query Account Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/query-borrowing-info.html b/zh-TW/api-explorer/spot/crossmargin/query-borrowing-info.html index 0be7370336..e6043353fb 100644 --- a/zh-TW/api-explorer/spot/crossmargin/query-borrowing-info.html +++ b/zh-TW/api-explorer/spot/crossmargin/query-borrowing-info.html @@ -4,13 +4,13 @@ Query Borrowing Info | Bybit API Documentation - +

    Query Borrowing Info

    Query Borrowing Info

    Query Parameters
    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • coin string

      currency

    • status integer[]

      Possible values: [0, 1, 2]

      Status. 0 by default. 0:get all kinds of status; 1:uncleared; 2:cleared

    • limit string

      Default value: 500

      Default value is 500, max 500

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/query-interest-quota.html b/zh-TW/api-explorer/spot/crossmargin/query-interest-quota.html index b21f953d83..cb2596c6dd 100644 --- a/zh-TW/api-explorer/spot/crossmargin/query-interest-quota.html +++ b/zh-TW/api-explorer/spot/crossmargin/query-interest-quota.html @@ -4,13 +4,13 @@ Query Interest and Quota | Bybit API Documentation - +

    Query Interest and Quota

    Query Interest and Quota

    Query Parameters
    • coin string

      currency

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/query-repayment-history.html b/zh-TW/api-explorer/spot/crossmargin/query-repayment-history.html index f47f5b0860..39c0f6a040 100644 --- a/zh-TW/api-explorer/spot/crossmargin/query-repayment-history.html +++ b/zh-TW/api-explorer/spot/crossmargin/query-repayment-history.html @@ -4,13 +4,13 @@ Query Repayment History | Bybit API Documentation - +

    Query Repayment History

    Query Repayment History

    Query Parameters
    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • coin string

      currency

    • limit string

      Default value: 500

      Default value is 500, max 500

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/crossmargin/redeem.html b/zh-TW/api-explorer/spot/crossmargin/redeem.html index b6d96c83ec..eb63adf663 100644 --- a/zh-TW/api-explorer/spot/crossmargin/redeem.html +++ b/zh-TW/api-explorer/spot/crossmargin/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +

    Redeem

    Redeem

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • coin string required

      currency

    • qty string required

      Repayment Amount

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/all-asset-info.html b/zh-TW/api-explorer/spot/lttrade/all-asset-info.html index 8ef7ddc6d6..d297f57933 100644 --- a/zh-TW/api-explorer/spot/lttrade/all-asset-info.html +++ b/zh-TW/api-explorer/spot/lttrade/all-asset-info.html @@ -4,13 +4,13 @@ All Asset Infos | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/etp.html b/zh-TW/api-explorer/spot/lttrade/etp.html index 9625eb0260..619a042c21 100644 --- a/zh-TW/api-explorer/spot/lttrade/etp.html +++ b/zh-TW/api-explorer/spot/lttrade/etp.html @@ -4,13 +4,13 @@ Spot Leverage Token | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/market-info.html b/zh-TW/api-explorer/spot/lttrade/market-info.html index c5c6577d09..7452f8e2a0 100644 --- a/zh-TW/api-explorer/spot/lttrade/market-info.html +++ b/zh-TW/api-explorer/spot/lttrade/market-info.html @@ -4,13 +4,13 @@ Market Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/purchase-redemption-history.html b/zh-TW/api-explorer/spot/lttrade/purchase-redemption-history.html index 133d2cf41a..64b29cba62 100644 --- a/zh-TW/api-explorer/spot/lttrade/purchase-redemption-history.html +++ b/zh-TW/api-explorer/spot/lttrade/purchase-redemption-history.html @@ -4,13 +4,13 @@ Get Purchase or Redemption History | Bybit API Documentation - +

    Get Purchase or Redemption History

    Get Purchase or Redemption History

    Query Parameters
    • ltCode string

      Abbreviation of the LT.

    • orderId string

      Order ID

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • limit string

      Default value: 100

      Default value is 100, max 500

    • orderType integer[]

      Possible values: [1, 2]

      Order type; 1. Purchase; 2. Redemption

    • serialNo string

      Serial number

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/purchase.html b/zh-TW/api-explorer/spot/lttrade/purchase.html index 079a0ef3fe..c77a9668ae 100644 --- a/zh-TW/api-explorer/spot/lttrade/purchase.html +++ b/zh-TW/api-explorer/spot/lttrade/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +

    Purchase

    Purchase

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • ltCode string required

      Abbreviation of the LT.

    • ltAmount string required

      Market Buy order, it is amount to pay.

    • serialNo string

      Serial number

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/lttrade/redeem.html b/zh-TW/api-explorer/spot/lttrade/redeem.html index 18cc950811..46063b4136 100644 --- a/zh-TW/api-explorer/spot/lttrade/redeem.html +++ b/zh-TW/api-explorer/spot/lttrade/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +

    Redeem

    Redeem

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • ltCode string required

      Abbreviation of the LT.

    • ltQuantity string required

      Market Buy order, it is amount to pay.

    • serialNo string

      Serial number

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/best-bidask-price.html b/zh-TW/api-explorer/spot/market/best-bidask-price.html index f59c5391e2..eb496f68d6 100644 --- a/zh-TW/api-explorer/spot/market/best-bidask-price.html +++ b/zh-TW/api-explorer/spot/market/best-bidask-price.html @@ -4,13 +4,13 @@ Best Bid/Ask Price | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/instrument-info.html b/zh-TW/api-explorer/spot/market/instrument-info.html index b2b7bff25b..489474ea68 100644 --- a/zh-TW/api-explorer/spot/market/instrument-info.html +++ b/zh-TW/api-explorer/spot/market/instrument-info.html @@ -4,13 +4,13 @@ Instrument Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/last-traded-price.html b/zh-TW/api-explorer/spot/market/last-traded-price.html index 07719fe4ee..d1fd968fc2 100644 --- a/zh-TW/api-explorer/spot/market/last-traded-price.html +++ b/zh-TW/api-explorer/spot/market/last-traded-price.html @@ -4,13 +4,13 @@ Name of the trading pair | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/lastest-information-for-symbol.html b/zh-TW/api-explorer/spot/market/lastest-information-for-symbol.html index 5a23bf6a8b..2eb59a060c 100644 --- a/zh-TW/api-explorer/spot/market/lastest-information-for-symbol.html +++ b/zh-TW/api-explorer/spot/market/lastest-information-for-symbol.html @@ -4,13 +4,13 @@ Lastest Information for Symbol | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/market.html b/zh-TW/api-explorer/spot/market/market.html index 739144c7ad..b448e1e4e2 100644 --- a/zh-TW/api-explorer/spot/market/market.html +++ b/zh-TW/api-explorer/spot/market/market.html @@ -4,13 +4,13 @@ Market data | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/merged-order-book.html b/zh-TW/api-explorer/spot/market/merged-order-book.html index 0b028519a4..d51ccd07de 100644 --- a/zh-TW/api-explorer/spot/market/merged-order-book.html +++ b/zh-TW/api-explorer/spot/market/merged-order-book.html @@ -4,13 +4,13 @@ Merged Order Book | Bybit API Documentation - +

    Merged Order Book

    Get Merged Order Book

    Query Parameters
    • symbol string required

      Name of the trading pair

    • scale integer

      Precision of the merged orderbook, 1 means 1 digit

    • limit integer

      Default value: 100

      Default value is 100. Max value is 200

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/order-book.html b/zh-TW/api-explorer/spot/market/order-book.html index 11332b6a9f..4f00a39e54 100644 --- a/zh-TW/api-explorer/spot/market/order-book.html +++ b/zh-TW/api-explorer/spot/market/order-book.html @@ -4,13 +4,13 @@ Order Book | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/public-trading-records.html b/zh-TW/api-explorer/spot/market/public-trading-records.html index 548562752e..c3cd616522 100644 --- a/zh-TW/api-explorer/spot/market/public-trading-records.html +++ b/zh-TW/api-explorer/spot/market/public-trading-records.html @@ -4,13 +4,13 @@ Public Trading Records | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/market/query-kline.html b/zh-TW/api-explorer/spot/market/query-kline.html index 1576b13ba8..5d74c43498 100644 --- a/zh-TW/api-explorer/spot/market/query-kline.html +++ b/zh-TW/api-explorer/spot/market/query-kline.html @@ -4,13 +4,13 @@ Query Kline | Bybit API Documentation - +

    Query Kline

    Get Kline

    Query Parameters
    • symbol string required

      Name of the trading pair

    • interval string[] required

      Possible values: [1m, 3m, 5m, 15m, 30m, 1h, 2h, 4h, 6h, 12h, 1d, 1w, 1m]

      kline interval

    • limit integer

      Default value: 1000

      Default value is 1000, max 1000

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html b/zh-TW/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html index 6406a3f46a..58ae2cdace 100644 --- a/zh-TW/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html +++ b/zh-TW/api-explorer/spot/trade/batch-cancel-active-order-by-ids.html @@ -4,13 +4,13 @@ Batch Cancel Active Order By IDs | Bybit API Documentation - +

    Batch Cancel Active Order By IDs

    Batch Cancel Active Order By IDs

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • orderIds string required

      Order ID, use commas to indicate multiple orderIds. Maximum of 100 ids.

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/batch-cancel-active-order.html b/zh-TW/api-explorer/spot/trade/batch-cancel-active-order.html index c47985f4c9..2c90e97184 100644 --- a/zh-TW/api-explorer/spot/trade/batch-cancel-active-order.html +++ b/zh-TW/api-explorer/spot/trade/batch-cancel-active-order.html @@ -4,13 +4,13 @@ Batch Cancel Active Order | Bybit API Documentation - +

    Batch Cancel Active Order

    Batch Cancel Active Order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Name of the trading pair

    • side string

      Possible values: [Buy, Sell]

      Side

    • orderType string

      Order type. LIMIT in default. It allows multiple types, separated by comma, e.a LIMIT,LIMIT_MAKER

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/cancel-active-order.html b/zh-TW/api-explorer/spot/trade/cancel-active-order.html index 5130b8eb87..c4ce118152 100644 --- a/zh-TW/api-explorer/spot/trade/cancel-active-order.html +++ b/zh-TW/api-explorer/spot/trade/cancel-active-order.html @@ -4,13 +4,13 @@ Cancel Active Order | Bybit API Documentation - +

    Cancel Active Order

    Cancel Active Order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • orderId string

      Order ID. Required if not passing orderLinkId

    • orderLinkId string

      Unique user-set order ID. Required if not passing orderId

    • orderCategory string

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/open-order.html b/zh-TW/api-explorer/spot/trade/open-order.html index 2aca54e911..66e082c0eb 100644 --- a/zh-TW/api-explorer/spot/trade/open-order.html +++ b/zh-TW/api-explorer/spot/trade/open-order.html @@ -4,13 +4,13 @@ Get Open Orders | Bybit API Documentation - +

    Get Open Orders

    Get Open Orders.

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 500

      Default value is 500, max 500

    • orderCategory integer[]

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/order-history.html b/zh-TW/api-explorer/spot/trade/order-history.html index 8df27590fa..2b30a4219d 100644 --- a/zh-TW/api-explorer/spot/trade/order-history.html +++ b/zh-TW/api-explorer/spot/trade/order-history.html @@ -4,13 +4,13 @@ Get Order History | Bybit API Documentation - +

    Get Order History

    Get Order History

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 100

      Default value is 100, max 500

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • orderCategory integer[]

      Possible values: [0, 1]

      Order category. 0:normal order by default; 1:TP/SL order, Required for TP/SL order.

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/place-order.html b/zh-TW/api-explorer/spot/trade/place-order.html index 4066654619..3755ad4d6d 100644 --- a/zh-TW/api-explorer/spot/trade/place-order.html +++ b/zh-TW/api-explorer/spot/trade/place-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +

    Place Order

    Place a order

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Request Body
    • symbol string required

      Symbol name

    • orderQty string required

      Market Buy order, it is amount to pay.

    • side string required

      Possible values: [Buy, Sell]

      Side

    • orderType string required

      Possible values: [MARKET, LIMIT, LIMITMAKER]

      Order type

    • timeInForce string

      Possible values: [GTC, FOK, IOC]

      Time in force

    • orderPrice string

      Order price

    • orderLinkId string

      User customised order id

    • orderCategory integer

      Possible values: [0, 1]

      Order category. 0=normal order, 1=TP/SL order

    • triggerPrice string

      Tp/Sl order trigger price

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/spot-trade.html b/zh-TW/api-explorer/spot/trade/spot-trade.html index cdabd750ef..81c5bb3bb5 100644 --- a/zh-TW/api-explorer/spot/trade/spot-trade.html +++ b/zh-TW/api-explorer/spot/trade/spot-trade.html @@ -4,13 +4,13 @@ Trade | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/trade-history.html b/zh-TW/api-explorer/spot/trade/trade-history.html index 23156850f8..9dd62c6a9e 100644 --- a/zh-TW/api-explorer/spot/trade/trade-history.html +++ b/zh-TW/api-explorer/spot/trade/trade-history.html @@ -4,13 +4,13 @@ Get Trade History | Bybit API Documentation - +

    Get Trade History

    Get Trade History

    Query Parameters
    • symbol string

      Name of the trading pair

    • orderId string

      Specify orderId to return all the orders that orderId of which are smaller than this particular one for pagination purpose

    • limit string

      Default value: 100

      Default value is 100, max 500

    • startTime integer

      Start time, unit in millisecond

    • endTime integer

      End time, unit in millisecond

    • fromTradeId string

      Query greater than the trade ID. (fromTicketId < trade ID)

    • toTradeId string

      Query smaller than the trade ID. (trade ID < toTicketId)

    Header Parameters
    • apiKey string

      A normal sub account API key is provided by default

    • secret string

      A normal sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/spot/trade/wallet-balance.html b/zh-TW/api-explorer/spot/trade/wallet-balance.html index 40369c6bdf..0ef94ed450 100644 --- a/zh-TW/api-explorer/spot/trade/wallet-balance.html +++ b/zh-TW/api-explorer/spot/trade/wallet-balance.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/account-info.html b/zh-TW/api-explorer/v5/account/account-info.html index 70e2e4776d..b862c88c12 100644 --- a/zh-TW/api-explorer/v5/account/account-info.html +++ b/zh-TW/api-explorer/v5/account/account-info.html @@ -4,13 +4,13 @@ Get Account Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/account.html b/zh-TW/api-explorer/v5/account/account.html index 0587ea5d5a..1789cf71b7 100644 --- a/zh-TW/api-explorer/v5/account/account.html +++ b/zh-TW/api-explorer/v5/account/account.html @@ -4,13 +4,13 @@ Account | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/borrow-history.html b/zh-TW/api-explorer/v5/account/borrow-history.html index 3f6930dc66..4dbc1a0dfd 100644 --- a/zh-TW/api-explorer/v5/account/borrow-history.html +++ b/zh-TW/api-explorer/v5/account/borrow-history.html @@ -4,13 +4,13 @@ Get Borrow History | Bybit API Documentation - +

    Get Borrow History

    Get borrow history

    Query Parameters
    • currency string

      e.g., USDC, USDT, BTC, ETH

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit per page. 1-50

    • cursor string

      Cusor, used for pagiation

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/coin-greeks.html b/zh-TW/api-explorer/v5/account/coin-greeks.html index a54b6d662c..24f151dcc3 100644 --- a/zh-TW/api-explorer/v5/account/coin-greeks.html +++ b/zh-TW/api-explorer/v5/account/coin-greeks.html @@ -4,13 +4,13 @@ Get Coin Greeks | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/collateral-info.html b/zh-TW/api-explorer/v5/account/collateral-info.html index 11afc9f122..8f6adb0418 100644 --- a/zh-TW/api-explorer/v5/account/collateral-info.html +++ b/zh-TW/api-explorer/v5/account/collateral-info.html @@ -4,13 +4,13 @@ Get Collateral Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/fee-rate.html b/zh-TW/api-explorer/v5/account/fee-rate.html index 4bb8ae72fd..4d8b7af7ce 100644 --- a/zh-TW/api-explorer/v5/account/fee-rate.html +++ b/zh-TW/api-explorer/v5/account/fee-rate.html @@ -4,13 +4,13 @@ Get Fee Rate | Bybit API Documentation - +

    Get Fee Rate

    Get fee rate

    Query Parameters
    • category string required

      Possible values: [spot, linear, inverse, option]

      Product type. working for spot and option

    • symbol string

      Symbol name. valid for linear,inverse and spot

    • baseCoin string

      Possible values: [SOL, BTC, ETH]

      Base coin. Valid for option

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/set-margin-mode.html b/zh-TW/api-explorer/v5/account/set-margin-mode.html index 0ebf7e833b..27f4e12724 100644 --- a/zh-TW/api-explorer/v5/account/set-margin-mode.html +++ b/zh-TW/api-explorer/v5/account/set-margin-mode.html @@ -4,13 +4,13 @@ Set Margin Mode | Bybit API Documentation - +

    Set Margin Mode

    Set margin mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • setMarginMode string required

      Possible values: [REGULAR_MARGIN, ISOLATED_MARGIN, PORTFOLIO_MARGIN]

      Margin mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/transaction-log.html b/zh-TW/api-explorer/v5/account/transaction-log.html index 6e1dcc1c69..fec4d38e0d 100644 --- a/zh-TW/api-explorer/v5/account/transaction-log.html +++ b/zh-TW/api-explorer/v5/account/transaction-log.html @@ -4,13 +4,13 @@ Get Transaction Log | Bybit API Documentation - +

    Get Transaction Log

    Get transaction log

    Query Parameters
    • accountType string

      Possible values: [UNIFIED]

      Support UNIFIED for now

    • category string

      Possible values: [spot, linear, option]

      Product category

    • currency string

      Currency

    • baseCoin string

      Base coin

    • type string

      Possible values: [TRANSFER_IN, TRANSFER_OUT, TRADE, SETTLEMENT, DELIVERY, LIQUIDATION, BONUS, FEE_REFUND, INTEREST, CURRENCY_BUY, CURRENCY_SELL]

      Transaction log type

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size for each page. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/upgrade-unified-account.html b/zh-TW/api-explorer/v5/account/upgrade-unified-account.html index b6b6d2dc94..01c215b114 100644 --- a/zh-TW/api-explorer/v5/account/upgrade-unified-account.html +++ b/zh-TW/api-explorer/v5/account/upgrade-unified-account.html @@ -4,13 +4,13 @@ Upgrade to Unified Account | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/account/wallet.html b/zh-TW/api-explorer/v5/account/wallet.html index 0c6bea6353..dfffdc7ab1 100644 --- a/zh-TW/api-explorer/v5/account/wallet.html +++ b/zh-TW/api-explorer/v5/account/wallet.html @@ -4,13 +4,13 @@ Get Wallet Balance | Bybit API Documentation - +

    Get Wallet Balance

    Get wallet balance

    Query Parameters
    • accountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT]

      Account type

    • coin string

      Coin name. You can pass mutiple coins like USDT,USDC

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/account-coin-balance.html b/zh-TW/api-explorer/v5/asset/account-coin-balance.html index 64eec05015..aa8179722c 100644 --- a/zh-TW/api-explorer/v5/asset/account-coin-balance.html +++ b/zh-TW/api-explorer/v5/asset/account-coin-balance.html @@ -4,13 +4,13 @@ Get Single Coin Balance | Bybit API Documentation - +

    Get Single Coin Balance

    Get Single Coin Balance

    Query Parameters
    • memberId string

      If query sub user balance, please input sub uid

    • accountType string required

      Possible values: [SPOT, CONTRACT, UNIFIED, OPTION, INVESTMENT, FUND]

      Account type

    • coin string required

      Coin name

    • withBonus integer

      Possible values: [0, 1]

      Query bonus or not. 0=false, 1=true

    • withTransferSafeAmount integer

      Possible values: [0, 1]

      Whether query delay withdraw/transfer safe amount. 0:false, 1;true

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/all-balance.html b/zh-TW/api-explorer/v5/asset/all-balance.html index 05a00aa1d2..b1693e95e3 100644 --- a/zh-TW/api-explorer/v5/asset/all-balance.html +++ b/zh-TW/api-explorer/v5/asset/all-balance.html @@ -4,13 +4,13 @@ Get All Coins Balance | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/asset-info.html b/zh-TW/api-explorer/v5/asset/asset-info.html index 9086877248..e2a2f3ec67 100644 --- a/zh-TW/api-explorer/v5/asset/asset-info.html +++ b/zh-TW/api-explorer/v5/asset/asset-info.html @@ -4,13 +4,13 @@ Get Asset Info (Spot) | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/asset.html b/zh-TW/api-explorer/v5/asset/asset.html index aeae146a30..45bc1d7484 100644 --- a/zh-TW/api-explorer/v5/asset/asset.html +++ b/zh-TW/api-explorer/v5/asset/asset.html @@ -4,13 +4,13 @@ Asset | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/coin-info.html b/zh-TW/api-explorer/v5/asset/coin-info.html index 3f4691aba4..d453370f2e 100644 --- a/zh-TW/api-explorer/v5/asset/coin-info.html +++ b/zh-TW/api-explorer/v5/asset/coin-info.html @@ -4,13 +4,13 @@ Get Coin Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/create-inter-transfer.html b/zh-TW/api-explorer/v5/asset/create-inter-transfer.html index 93dd41a873..e8fef1f641 100644 --- a/zh-TW/api-explorer/v5/asset/create-inter-transfer.html +++ b/zh-TW/api-explorer/v5/asset/create-inter-transfer.html @@ -4,13 +4,13 @@ Create Internal Transfer | Bybit API Documentation - +

    Create Internal Transfer

    Create internal transfer

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • transferId string required

      UUID

    • coin string required

      Coin

    • amount string required

      Amount

    • fromAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, OPTION, INVESTMENT, FUND]

      From account type

    • toAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, OPTION, INVESTMENT, FUND]

      To account type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/deposit-coin-spec.html b/zh-TW/api-explorer/v5/asset/deposit-coin-spec.html index af5c2264e5..70f698fac0 100644 --- a/zh-TW/api-explorer/v5/asset/deposit-coin-spec.html +++ b/zh-TW/api-explorer/v5/asset/deposit-coin-spec.html @@ -4,13 +4,13 @@ Get Allowed Deposit Coin Info | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/deposit-record.html b/zh-TW/api-explorer/v5/asset/deposit-record.html index 208c19ea39..03b759309c 100644 --- a/zh-TW/api-explorer/v5/asset/deposit-record.html +++ b/zh-TW/api-explorer/v5/asset/deposit-record.html @@ -4,13 +4,13 @@ Get Deposit Record (on-chain) | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/enable-unitransfer-subuid.html b/zh-TW/api-explorer/v5/asset/enable-unitransfer-subuid.html index 3a07f9c483..3bf82a0636 100644 --- a/zh-TW/api-explorer/v5/asset/enable-unitransfer-subuid.html +++ b/zh-TW/api-explorer/v5/asset/enable-unitransfer-subuid.html @@ -4,13 +4,13 @@ Enable Universal Transfer For Sub UID | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/exchange.html b/zh-TW/api-explorer/v5/asset/exchange.html index 03268e40b2..c447abb869 100644 --- a/zh-TW/api-explorer/v5/asset/exchange.html +++ b/zh-TW/api-explorer/v5/asset/exchange.html @@ -4,13 +4,13 @@ Get Coin Exchange Records | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/inter-transfer-list.html b/zh-TW/api-explorer/v5/asset/inter-transfer-list.html index 700ad4a15b..deb4927edb 100644 --- a/zh-TW/api-explorer/v5/asset/inter-transfer-list.html +++ b/zh-TW/api-explorer/v5/asset/inter-transfer-list.html @@ -4,13 +4,13 @@ Get Internal Transfer Records | Bybit API Documentation - +

    Get Internal Transfer Records

    Get internal transfer records

    Query Parameters
    • transferId string

      Transfer id

    • coin string

      Coin name

    • status string

      Possible values: [SUCCESS, PENDING, FAILED]

      Status

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/internal-deposit-record.html b/zh-TW/api-explorer/v5/asset/internal-deposit-record.html index 44781560ab..21912d85c2 100644 --- a/zh-TW/api-explorer/v5/asset/internal-deposit-record.html +++ b/zh-TW/api-explorer/v5/asset/internal-deposit-record.html @@ -4,13 +4,13 @@ Get Internal Deposit Records (across Bybit) | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/master-deposit-addr.html b/zh-TW/api-explorer/v5/asset/master-deposit-addr.html index ff3569e6fe..f5d3252af9 100644 --- a/zh-TW/api-explorer/v5/asset/master-deposit-addr.html +++ b/zh-TW/api-explorer/v5/asset/master-deposit-addr.html @@ -4,13 +4,13 @@ Get Master Deposit Address | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/option-delivery.html b/zh-TW/api-explorer/v5/asset/option-delivery.html index 942ed8afda..7c759624af 100644 --- a/zh-TW/api-explorer/v5/asset/option-delivery.html +++ b/zh-TW/api-explorer/v5/asset/option-delivery.html @@ -4,13 +4,13 @@ Get Option Delivery Record | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/set-deposit-acct.html b/zh-TW/api-explorer/v5/asset/set-deposit-acct.html index b412b25255..2d3890e038 100644 --- a/zh-TW/api-explorer/v5/asset/set-deposit-acct.html +++ b/zh-TW/api-explorer/v5/asset/set-deposit-acct.html @@ -4,13 +4,13 @@ Set Deposit Account | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/settlement.html b/zh-TW/api-explorer/v5/asset/settlement.html index 858ca4ba55..47904b74bb 100644 --- a/zh-TW/api-explorer/v5/asset/settlement.html +++ b/zh-TW/api-explorer/v5/asset/settlement.html @@ -4,13 +4,13 @@ Get USDC Perpetual Settlement | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/sub-deposit-addr.html b/zh-TW/api-explorer/v5/asset/sub-deposit-addr.html index 08f1b6bd35..12498082a0 100644 --- a/zh-TW/api-explorer/v5/asset/sub-deposit-addr.html +++ b/zh-TW/api-explorer/v5/asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ Get Sub Deposit Address | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/sub-deposit-record.html b/zh-TW/api-explorer/v5/asset/sub-deposit-record.html index 9eb18f87e1..0625b92f77 100644 --- a/zh-TW/api-explorer/v5/asset/sub-deposit-record.html +++ b/zh-TW/api-explorer/v5/asset/sub-deposit-record.html @@ -4,13 +4,13 @@ Get Sub Account Deposit Records (on-chain) | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/sub-uid-list.html b/zh-TW/api-explorer/v5/asset/sub-uid-list.html index a0e4992524..60d54a3d56 100644 --- a/zh-TW/api-explorer/v5/asset/sub-uid-list.html +++ b/zh-TW/api-explorer/v5/asset/sub-uid-list.html @@ -4,13 +4,13 @@ Get Sub UID | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/transferable-coin.html b/zh-TW/api-explorer/v5/asset/transferable-coin.html index 1cc7b703fe..1a10851aab 100644 --- a/zh-TW/api-explorer/v5/asset/transferable-coin.html +++ b/zh-TW/api-explorer/v5/asset/transferable-coin.html @@ -4,13 +4,13 @@ Get Transferable Coin | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/unitransfer-list.html b/zh-TW/api-explorer/v5/asset/unitransfer-list.html index d0a9dbabdd..57009bc25c 100644 --- a/zh-TW/api-explorer/v5/asset/unitransfer-list.html +++ b/zh-TW/api-explorer/v5/asset/unitransfer-list.html @@ -4,13 +4,13 @@ Get Universal Transfer Records | Bybit API Documentation - +

    Get Universal Transfer Records

    Get universal transfer record

    Query Parameters
    • transferId string

      Transfer id

    • coin string

      Coin name

    • status string

      Possible values: [SUCCESS, FAILED, PENDING]

      Status

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 20

      Limit size. 1-50

    • cursor string

      Cursor, used for pagination

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/unitransfer.html b/zh-TW/api-explorer/v5/asset/unitransfer.html index e33cf5d860..a799dee182 100644 --- a/zh-TW/api-explorer/v5/asset/unitransfer.html +++ b/zh-TW/api-explorer/v5/asset/unitransfer.html @@ -4,13 +4,13 @@ Create Universal Transfer | Bybit API Documentation - +

    Create Universal Transfer

    Create universal transfer

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Request Body
    • transferId sting required

      Transfer id. UUID

    • coin sting required

      Coin name

    • amount sting required

      Amount

    • fromMemberId intger required

      From UID

    • toMemberId integer required

      To UID

    • fromAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, INVESTMENT, OPTION, FUND]

      From account type

    • toAccountType string required

      Possible values: [UNIFIED, CONTRACT, SPOT, INVESTMENT, OPTION, FUND]

      To account type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/asset/withdraw-record.html b/zh-TW/api-explorer/v5/asset/withdraw-record.html index 898eff9010..b197c3e833 100644 --- a/zh-TW/api-explorer/v5/asset/withdraw-record.html +++ b/zh-TW/api-explorer/v5/asset/withdraw-record.html @@ -4,13 +4,13 @@ Get Withdraw Records | Bybit API Documentation - +

    Get Withdraw Records

    Get withdraw record

    Query Parameters
    • withdrawID string

      Withdraw ID

    • coin string

      Coin name

    • withdrawType integer

      Possible values: [0, 1, 2]

      Withdraw type. 0=on chain, 1=off chain, 2=all

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      Limit size. 1-50

    • cursor string

      Cursor, used to pagination

    Header Parameters
    • apiKey string required

      Use master UID api key

    • secret string required

      Use master UID api secret

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/category.html b/zh-TW/api-explorer/v5/category.html index 512ae86264..62d3c5be86 100644 --- a/zh-TW/api-explorer/v5/category.html +++ b/zh-TW/api-explorer/v5/category.html @@ -4,13 +4,13 @@ V5 API | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/etp.html b/zh-TW/api-explorer/v5/lt/etp.html index 7bd43b4f99..b34ded2f2b 100644 --- a/zh-TW/api-explorer/v5/lt/etp.html +++ b/zh-TW/api-explorer/v5/lt/etp.html @@ -4,13 +4,13 @@ Spot Leverage Token | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/leverage-token-info.html b/zh-TW/api-explorer/v5/lt/leverage-token-info.html index 2642fd20eb..e460fea87e 100644 --- a/zh-TW/api-explorer/v5/lt/leverage-token-info.html +++ b/zh-TW/api-explorer/v5/lt/leverage-token-info.html @@ -4,13 +4,13 @@ Get Leverage Token Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/leverage-token-reference.html b/zh-TW/api-explorer/v5/lt/leverage-token-reference.html index 3c65d33fe1..4fee97eff5 100644 --- a/zh-TW/api-explorer/v5/lt/leverage-token-reference.html +++ b/zh-TW/api-explorer/v5/lt/leverage-token-reference.html @@ -4,13 +4,13 @@ Get Leverage Token Market | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/order-record.html b/zh-TW/api-explorer/v5/lt/order-record.html index 7d0a48d9a4..e5a34459cd 100644 --- a/zh-TW/api-explorer/v5/lt/order-record.html +++ b/zh-TW/api-explorer/v5/lt/order-record.html @@ -4,13 +4,13 @@ Get Purchase or Redeem Records | Bybit API Documentation - +

    Get Purchase or Redeem Records

    Get the order history of purchase or redeem

    Query Parameters
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • orderId string

      Order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 100

      Limit size of each page. 1-500

    • ltOrderType integer

      Possible values: [1, 2]

      LT order type. 1=purchase, 2=redeem

    • serialNo string

      Serial number

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/purchase.html b/zh-TW/api-explorer/v5/lt/purchase.html index 637550e5f5..4b828ebb3a 100644 --- a/zh-TW/api-explorer/v5/lt/purchase.html +++ b/zh-TW/api-explorer/v5/lt/purchase.html @@ -4,13 +4,13 @@ Purchase | Bybit API Documentation - +

    Purchase

    Purchase leverage token

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • ltAmount string

      Purchase amount

    • serialNo string

      Serial number, customised order id

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/lt/redeem.html b/zh-TW/api-explorer/v5/lt/redeem.html index db89a6a9ca..46ed399127 100644 --- a/zh-TW/api-explorer/v5/lt/redeem.html +++ b/zh-TW/api-explorer/v5/lt/redeem.html @@ -4,13 +4,13 @@ Redeem | Bybit API Documentation - +

    Redeem

    Redeem leverage token

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • ltCoin string

      Levearage coin name. e.g., BTC3L

    • quantity string

      Redeem quantity

    • serialNo string

      Serial number, customised order id

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/delivery-price.html b/zh-TW/api-explorer/v5/market/delivery-price.html index f4579aa142..a75bd1ba1a 100644 --- a/zh-TW/api-explorer/v5/market/delivery-price.html +++ b/zh-TW/api-explorer/v5/market/delivery-price.html @@ -4,13 +4,13 @@ Get Option Delivery Price | Bybit API Documentation - +

    Get Option Delivery Price

    Get delivery price of option

    Query Parameters
    • category string[] required

      Possible values: [option]

      Product type. option only

    • symbol string

      Symbol name

    • baseCoin string

      Default value: BTC

      Base coin. Return BTC by default

    • limit string

      Default value: 50

      Maximum 200

    • cursor string

      The cursor, used for pagination

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/history-fund-rate.html b/zh-TW/api-explorer/v5/market/history-fund-rate.html index 3f58f6ad42..f2b6c2aaf7 100644 --- a/zh-TW/api-explorer/v5/market/history-fund-rate.html +++ b/zh-TW/api-explorer/v5/market/history-fund-rate.html @@ -4,13 +4,13 @@ Get Funding Rate History | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/index-kline.html b/zh-TW/api-explorer/v5/market/index-kline.html index 5ea480c7f9..15e3b0858f 100644 --- a/zh-TW/api-explorer/v5/market/index-kline.html +++ b/zh-TW/api-explorer/v5/market/index-kline.html @@ -4,13 +4,13 @@ Get Index Price Kline | Bybit API Documentation - +

    Get Index Price Kline

    Get Index Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/instrument.html b/zh-TW/api-explorer/v5/market/instrument.html index 10f7338875..c533abaf75 100644 --- a/zh-TW/api-explorer/v5/market/instrument.html +++ b/zh-TW/api-explorer/v5/market/instrument.html @@ -4,13 +4,13 @@ Get Instrument Info | Bybit API Documentation - +

    Get Instrument Info

    Get launched instruments information.

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • status string

      Possible values: [PreLaunch, Trading, Settling, Delivering, Closed]

      Status filter

    • baseCoin string

      for linear, invere and option ONLY

    • limit integer

      Default value: 500

      Maximum 1000. spot does not have pagination

    • cursor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/insurance.html b/zh-TW/api-explorer/v5/market/insurance.html index f0d32e451d..c28b69cf7f 100644 --- a/zh-TW/api-explorer/v5/market/insurance.html +++ b/zh-TW/api-explorer/v5/market/insurance.html @@ -4,13 +4,13 @@ Get Insurance | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/iv.html b/zh-TW/api-explorer/v5/market/iv.html index 786868536e..faf7d5685d 100644 --- a/zh-TW/api-explorer/v5/market/iv.html +++ b/zh-TW/api-explorer/v5/market/iv.html @@ -4,13 +4,13 @@ Get Historical Volatility | Bybit API Documentation - +

    Get Historical Volatility

    Get historical volatility

    Query Parameters
    • category string[] required

      Possible values: [option]

      Product type

    • baseCoin string

      Default value: BTC

      Base coin. If not passed, BTC returned by default

    • period integer[]

      Possible values: [7, 14, 21, 30, 60, 90, 180, 270]

      Period. If not passed, it returns 7 days by default. SOL does not have 180 and 270

    • startTime integer

      The start timstamp (ms)

    • endTime integer

      The end timstamp (ms)

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/kline.html b/zh-TW/api-explorer/v5/market/kline.html index 8d49269f88..cf7d27392a 100644 --- a/zh-TW/api-explorer/v5/market/kline.html +++ b/zh-TW/api-explorer/v5/market/kline.html @@ -4,13 +4,13 @@ Get Kline | Bybit API Documentation - +

    Get Kline

    Get kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, spot]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/mark-kline.html b/zh-TW/api-explorer/v5/market/mark-kline.html index 22e0134f71..13ce906d07 100644 --- a/zh-TW/api-explorer/v5/market/mark-kline.html +++ b/zh-TW/api-explorer/v5/market/mark-kline.html @@ -4,13 +4,13 @@ Get Mark Price Kline | Bybit API Documentation - +

    Get Mark Price Kline

    Get Mark Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, spot]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/market.html b/zh-TW/api-explorer/v5/market/market.html index 7b1f8c2f35..bd607f6945 100644 --- a/zh-TW/api-explorer/v5/market/market.html +++ b/zh-TW/api-explorer/v5/market/market.html @@ -4,13 +4,13 @@ Market | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/open-interest.html b/zh-TW/api-explorer/v5/market/open-interest.html index 2bf2e5e69e..4561ddc982 100644 --- a/zh-TW/api-explorer/v5/market/open-interest.html +++ b/zh-TW/api-explorer/v5/market/open-interest.html @@ -4,13 +4,13 @@ Get Open Interest | Bybit API Documentation - +

    Get Open Interest

    Get open interest

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • intervalTime string[] required

      Possible values: [5min, 15min, 30min, 1h, 4h, 1d]

      interval time

    • startTime integer

      The start timstamp (ms)

    • endTime integer

      The end timstamp (ms)

    • limit integer

      Default value: 50

      Maximum 200

    • cursor string

      pass cursor from the response param "nagePageCursor" to paginate

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/orderbook.html b/zh-TW/api-explorer/v5/market/orderbook.html index face16f19c..38c5080d9f 100644 --- a/zh-TW/api-explorer/v5/market/orderbook.html +++ b/zh-TW/api-explorer/v5/market/orderbook.html @@ -4,13 +4,13 @@ Get Orderbook | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/premium-index-kline.html b/zh-TW/api-explorer/v5/market/premium-index-kline.html index 4dd21e7005..201d30f476 100644 --- a/zh-TW/api-explorer/v5/market/premium-index-kline.html +++ b/zh-TW/api-explorer/v5/market/premium-index-kline.html @@ -4,13 +4,13 @@ Get Premium Index Price Kline | Bybit API Documentation - +

    Get Premium Index Price Kline

    Get Premium Index Price Kline data

    Query Parameters
    • category string[] required

      Possible values: [linear]

      Product type

    • symbol string required

      Symbol name

    • interval string[] required

      Possible values: [1, 3, 5, 15, 30, 60, 120, 240, 360, 720, D, M, W]

      kline interval

    • start integer

      start timestamp (ms). e.g., 1669852800000 (1 DEC 2022 UTC 0:00)

    • end integer

      end timestamp (ms). e.g., 1671062400000 (15 DEC 2022 UTC 0:00)

    • limit integer

      Default value: 200

      Maximum 1000

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/recent-trade.html b/zh-TW/api-explorer/v5/market/recent-trade.html index 1181e3981d..1ce876168d 100644 --- a/zh-TW/api-explorer/v5/market/recent-trade.html +++ b/zh-TW/api-explorer/v5/market/recent-trade.html @@ -4,13 +4,13 @@ Get Public Recent Trading History | Bybit API Documentation - +

    Get Public Recent Trading History

    Get public trade

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name.

    • baseCoin string

      Default value: BTC

      Base coin. Valid for option. Default is BTC

    • optionType string

      Possible values: [Call, Put]

      Option type. Valid for option.

    • limit integer

      Maximum 60 for spot. Maximum 1000 for others

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/risk-limit.html b/zh-TW/api-explorer/v5/market/risk-limit.html index e02d19863f..4248875db5 100644 --- a/zh-TW/api-explorer/v5/market/risk-limit.html +++ b/zh-TW/api-explorer/v5/market/risk-limit.html @@ -4,13 +4,13 @@ Get Risk Limit | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/tickers.html b/zh-TW/api-explorer/v5/market/tickers.html index 75a70b7702..9daa22e99a 100644 --- a/zh-TW/api-explorer/v5/market/tickers.html +++ b/zh-TW/api-explorer/v5/market/tickers.html @@ -4,13 +4,13 @@ Get Tickers | Bybit API Documentation - +

    Get Tickers

    Get all latest information of symbols. All parameters are needed for OPTION

    Query Parameters
    • category string[] required

      Possible values: [linear, inverse, option, spot]

      Product type

    • baseCoin string

      for option ONLY, baseCoin or symbol must be passed when query option

    • expDate string

      Expiry date. For option only. Default is all, and the parameter format is 25MAR22.

    • symbol string

      Symbol name

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/market/time.html b/zh-TW/api-explorer/v5/market/time.html index 9502afbf02..3a2905b0e6 100644 --- a/zh-TW/api-explorer/v5/market/time.html +++ b/zh-TW/api-explorer/v5/market/time.html @@ -4,13 +4,13 @@ Get Bybit Server Time | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/auto-add-margin.html b/zh-TW/api-explorer/v5/position/auto-add-margin.html index 678b9e5fd3..18c90220f4 100644 --- a/zh-TW/api-explorer/v5/position/auto-add-margin.html +++ b/zh-TW/api-explorer/v5/position/auto-add-margin.html @@ -4,13 +4,13 @@ Set Auto Add Margin | Bybit API Documentation - +

    Set Auto Add Margin

    Set Auto Add Margin

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • autoAddMargin integer required

      0 - turn off, 1 - turn on

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/close-pnl.html b/zh-TW/api-explorer/v5/position/close-pnl.html index b9a25e671d..1a8db936e0 100644 --- a/zh-TW/api-explorer/v5/position/close-pnl.html +++ b/zh-TW/api-explorer/v5/position/close-pnl.html @@ -4,13 +4,13 @@ Get Closed PnL | Bybit API Documentation - +

    Get Closed PnL

    Get closed pnl

    Query Parameters
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string

      Symbol name

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • limit integer

      Default value: 50

      1-200. max 200

    • cursor string

      cursor for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/cross-isolate.html b/zh-TW/api-explorer/v5/position/cross-isolate.html index 925a0637b3..e58fdeaea5 100644 --- a/zh-TW/api-explorer/v5/position/cross-isolate.html +++ b/zh-TW/api-explorer/v5/position/cross-isolate.html @@ -4,13 +4,13 @@ Switch Cross/Isolated Margin | Bybit API Documentation - +

    Switch Cross/Isolated Margin

    Select cross margin mode or isolated margin mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • tradeMode integer required

      Possible values: [0, 1]

      0 - cross margin, 1 - isolated margin

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/execution.html b/zh-TW/api-explorer/v5/position/execution.html index 02acd3ab71..f55d4b9eb5 100644 --- a/zh-TW/api-explorer/v5/position/execution.html +++ b/zh-TW/api-explorer/v5/position/execution.html @@ -4,13 +4,13 @@ Get Execution (2 years) | Bybit API Documentation - +

    Get Execution (2 years)

    Get execution list

    Query Parameters
    • category string required

      Possible values: [linear, inverse, spot, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • execType string

      Execution type

    • limit integer

      Default value: 50

      1-100. max 100

    • cursor string

      cursor to pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/leverage.html b/zh-TW/api-explorer/v5/position/leverage.html index acfc577fd5..3ed2b834bc 100644 --- a/zh-TW/api-explorer/v5/position/leverage.html +++ b/zh-TW/api-explorer/v5/position/leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set levearage.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • buyLeverage string

      Buy side leverage

    • sellLeverage string

      Sell side leverage

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/manual-add-margin.html b/zh-TW/api-explorer/v5/position/manual-add-margin.html index ce3883ed29..c832285cf7 100644 --- a/zh-TW/api-explorer/v5/position/manual-add-margin.html +++ b/zh-TW/api-explorer/v5/position/manual-add-margin.html @@ -4,13 +4,13 @@ Add Or Reduce Margin | Bybit API Documentation - +

    Add Or Reduce Margin

    Manually add or reduce margin for isolated margin position

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • margin string required

      10 - add, -10 - reduce

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/position-info.html b/zh-TW/api-explorer/v5/position/position-info.html index 099fca720a..d762cb2b8f 100644 --- a/zh-TW/api-explorer/v5/position/position-info.html +++ b/zh-TW/api-explorer/v5/position/position-info.html @@ -4,13 +4,13 @@ Get Position Info | Bybit API Documentation - +

    Get Position Info

    Get Position Info

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin. For option only

    • settleCoin string

      Used for linear & inverse, symbol or settleCoin is required

    • limit integer

      Default value: 20

      1-200. max 200

    • cursor string

      cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/position-mode.html b/zh-TW/api-explorer/v5/position/position-mode.html index e44229205d..e68ff23169 100644 --- a/zh-TW/api-explorer/v5/position/position-mode.html +++ b/zh-TW/api-explorer/v5/position/position-mode.html @@ -4,13 +4,13 @@ Switch Position Mode | Bybit API Documentation - +

    Switch Position Mode

    Switch Position Mode

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string

      Symbol name

    • coin string

      Coin name

    • mode integer required

      Possible values: [0, 3]

      Position mode. 0 - Merged single, 3 - Both sides

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/position.html b/zh-TW/api-explorer/v5/position/position.html index 0d7f552665..0a874f6a06 100644 --- a/zh-TW/api-explorer/v5/position/position.html +++ b/zh-TW/api-explorer/v5/position/position.html @@ -4,13 +4,13 @@ Position | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/set-risk-limit.html b/zh-TW/api-explorer/v5/position/set-risk-limit.html index feab1a1233..44be5e43b8 100644 --- a/zh-TW/api-explorer/v5/position/set-risk-limit.html +++ b/zh-TW/api-explorer/v5/position/set-risk-limit.html @@ -4,13 +4,13 @@ Set Risk Limit | Bybit API Documentation - +

    Set Risk Limit

    Set risk limit.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • riskId integer required

      Risk limit id

    • positionIdx integer

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/tpsl-mode.html b/zh-TW/api-explorer/v5/position/tpsl-mode.html index 2565005d1b..0379ae5145 100644 --- a/zh-TW/api-explorer/v5/position/tpsl-mode.html +++ b/zh-TW/api-explorer/v5/position/tpsl-mode.html @@ -4,13 +4,13 @@ Set TP/SL Mode | Bybit API Documentation - +

    Set TP/SL Mode

    Set tp/sl mode.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • tpSlMode string required

      Possible values: [Full, Partial]

      Full = full position TP/SL, Partial = partial mode tp/sl

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/position/trading-stop.html b/zh-TW/api-explorer/v5/position/trading-stop.html index 244a92b0f6..c29f5bd3e6 100644 --- a/zh-TW/api-explorer/v5/position/trading-stop.html +++ b/zh-TW/api-explorer/v5/position/trading-stop.html @@ -4,13 +4,13 @@ Set Trading Stop | Bybit API Documentation - +

    Set Trading Stop

    Set trade stop.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse]

      Product type

    • symbol string required

      Symbol name

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpSize string

      Take profit size

    • slSize string

      Stop loss size

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Take profit trigger price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Stop loss trigger price type

    • trailingStop string

      Trailing stop

    • activePrice string

      Trailing stop trigger price

    • positionIdx integer required

      Possible values: [0, 1, 2]

      Position index. 0=one-way-mode, 1=buy-hedge-mode, 2=sell-hedege-mode. REQUIRED for hedge-mode

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    • tpOrderType string

      Possible values: [Market, Limit]

      The order type when take profit is triggered

    • slOrderType string

      Possible values: [Market, Limit]

      The order type when stop loss is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/account-info.html b/zh-TW/api-explorer/v5/spot-margin-normal/account-info.html index e77d66f708..af19576f2e 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/account-info.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/account-info.html @@ -4,13 +4,13 @@ Get Loan Account Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/borrow-order.html b/zh-TW/api-explorer/v5/spot-margin-normal/borrow-order.html index a83d0166d9..8e36ac7520 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/borrow-order.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/borrow-order.html @@ -4,13 +4,13 @@ Get Borrow Order Detail | Bybit API Documentation - +

    Get Borrow Order Detail

    Get Borrow Order Detail

    Query Parameters
    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • coin string

      Coin name

    • status string

      Possible values: [0, 1, 2]

      Status filter. 0:get all kinds of status, 1:uncleared, 2:cleared

    • limit integer

      Limit for data size per page. 1 - 500. Default:500

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/borrow.html b/zh-TW/api-explorer/v5/spot-margin-normal/borrow.html index 23a287dd92..8136860516 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/borrow.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/borrow.html @@ -4,13 +4,13 @@ Borrow | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/borrowable-data.html b/zh-TW/api-explorer/v5/spot-margin-normal/borrowable-data.html index 6393f4ea08..62b1c7d23d 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/borrowable-data.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/borrowable-data.html @@ -4,13 +4,13 @@ Get Borrowable Coin Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/interest-quota.html b/zh-TW/api-explorer/v5/spot-margin-normal/interest-quota.html index 04d60809b6..4678f4f754 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/interest-quota.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/interest-quota.html @@ -4,13 +4,13 @@ Get Interest & Quota | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/margin-data.html b/zh-TW/api-explorer/v5/spot-margin-normal/margin-data.html index 4391a4f32a..f569e15250 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/margin-data.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/margin-data.html @@ -4,13 +4,13 @@ Get Margin Coin Info | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/normal-margin-trade.html b/zh-TW/api-explorer/v5/spot-margin-normal/normal-margin-trade.html index af9676ceb6..8ac77c60bc 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/normal-margin-trade.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/normal-margin-trade.html @@ -4,13 +4,13 @@ Spot Margin Trade (Normal) | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/repay-order.html b/zh-TW/api-explorer/v5/spot-margin-normal/repay-order.html index ee7d0b27ac..4ceb7221d2 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/repay-order.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/repay-order.html @@ -4,13 +4,13 @@ Get Repayment Order Detail | Bybit API Documentation - +

    Get Repayment Order Detail

    Get Repayment Order Detail

    Query Parameters
    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • coin string

      Coin name

    • limit integer

      Limit for data size per page. 1 - 500. Default:500

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/repay.html b/zh-TW/api-explorer/v5/spot-margin-normal/repay.html index 8de02ca7fc..cdfe627ada 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/repay.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/repay.html @@ -4,13 +4,13 @@ Repay | Bybit API Documentation - +

    Repay

    Repay

    Header Parameters
    • apiKey string required

      Please use normal mode account API KEY

    • secret string required

      Please use normal mode account API SECRET

    Request Body
    • coin string

      Coin name

    • qty string

      Amount to repay

    • completeRepayment integer

      Possible values: [0, 1]

      Whether to pay off all debts. 0:false, 1:true

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-normal/switch-mode.html b/zh-TW/api-explorer/v5/spot-margin-normal/switch-mode.html index f830b5808d..011afd366d 100644 --- a/zh-TW/api-explorer/v5/spot-margin-normal/switch-mode.html +++ b/zh-TW/api-explorer/v5/spot-margin-normal/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-uta/set-leverage.html b/zh-TW/api-explorer/v5/spot-margin-uta/set-leverage.html index f078773b55..64b3af7a8c 100644 --- a/zh-TW/api-explorer/v5/spot-margin-uta/set-leverage.html +++ b/zh-TW/api-explorer/v5/spot-margin-uta/set-leverage.html @@ -4,13 +4,13 @@ Set Leverage | Bybit API Documentation - +

    Set Leverage

    Set leverage for margin trade

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • leverage integer

      Possible values: [2, 3, 4, 5, 6, 7, 8, 9, 10]

      Levearge, support 2-10

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-uta/switch-mode.html b/zh-TW/api-explorer/v5/spot-margin-uta/switch-mode.html index 53bb55fa7f..2e30586915 100644 --- a/zh-TW/api-explorer/v5/spot-margin-uta/switch-mode.html +++ b/zh-TW/api-explorer/v5/spot-margin-uta/switch-mode.html @@ -4,13 +4,13 @@ Toggle Margin Trade | Bybit API Documentation - +

    Toggle Margin Trade

    Toggle margin trade

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • spotMarginMode integer

      Possible values: [0, 1]

      Margin mode. 0=off, 1=on

    • required
    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/spot-margin-uta/uta-margin-trade.html b/zh-TW/api-explorer/v5/spot-margin-uta/uta-margin-trade.html index 6a86da759c..bde94fb17f 100644 --- a/zh-TW/api-explorer/v5/spot-margin-uta/uta-margin-trade.html +++ b/zh-TW/api-explorer/v5/spot-margin-uta/uta-margin-trade.html @@ -4,13 +4,13 @@ Spot Margin Trade (UTA) | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/amend-order.html b/zh-TW/api-explorer/v5/trade/amend-order.html index d0192ad57d..66c50d17ba 100644 --- a/zh-TW/api-explorer/v5/trade/amend-order.html +++ b/zh-TW/api-explorer/v5/trade/amend-order.html @@ -4,13 +4,13 @@ Amend Order | Bybit API Documentation - +

    Amend Order

    Amend an order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • orderIv string

      Modify option order iv

    • triggerPrice string

      Modify StopOrder trigger price

    • takeProfit string

      Modify take profit price

    • stopLoss string

      Modify stop loss price

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify the type of trigger price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Modify trigger stop loss price price type

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/batch-amend.html b/zh-TW/api-explorer/v5/trade/batch-amend.html index efa76dc456..e35457f801 100644 --- a/zh-TW/api-explorer/v5/trade/batch-amend.html +++ b/zh-TW/api-explorer/v5/trade/batch-amend.html @@ -4,13 +4,13 @@ Batch Amend Order | Bybit API Documentation - +

    Batch Amend Order

    Batch amend orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • qty string

      Modify the order qty

    • price string

      Modify the order price

    • orderIv string

      Modify option order iv

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/batch-cancel.html b/zh-TW/api-explorer/v5/trade/batch-cancel.html index f24e68e621..78d5569caa 100644 --- a/zh-TW/api-explorer/v5/trade/batch-cancel.html +++ b/zh-TW/api-explorer/v5/trade/batch-cancel.html @@ -4,13 +4,13 @@ Batch Cancel Order | Bybit API Documentation - +

    Batch Cancel Order

    Batch cancel orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/batch-place.html b/zh-TW/api-explorer/v5/trade/batch-place.html index 0561b18d15..5d4eabe221 100644 --- a/zh-TW/api-explorer/v5/trade/batch-place.html +++ b/zh-TW/api-explorer/v5/trade/batch-place.html @@ -4,13 +4,13 @@ Batch Place Order | Bybit API Documentation - +

    Batch Place Order

    Batch place orders

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [option]

      Product type. option ONLY

    • request object[] required

      Possible values: <= 10

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required
    • price string
    • orderIv string
    • timeInForce string

      Possible values: [GTC, IOC, FOK, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0]

      Position mode. one-way mode only for unified.

    • orderLinkId string required

      REQUIRED param when place an option order

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • mmp boolean

      Possible values: [true, false]

      enable market marker protection

    • smpType string

      Possible values: [None, CancelMaker, CancelTaker, CancelBoth]

      Smp execution type

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/cancel-all.html b/zh-TW/api-explorer/v5/trade/cancel-all.html index 94e0b570ef..a63431e40c 100644 --- a/zh-TW/api-explorer/v5/trade/cancel-all.html +++ b/zh-TW/api-explorer/v5/trade/cancel-all.html @@ -4,13 +4,13 @@ Cancel All Orders | Bybit API Documentation - +

    Cancel All Orders

    Cancel all orders.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name. Required if not passing baseCoin or settleCoin

    • baseCoin string

      Cancel by base coin. Required if not passing symbol or settleCoin

    • settleCoin string

      Cancel by settle coin. Does not support spot. Required if not passing symbol or baseCoin

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/cancel-order.html b/zh-TW/api-explorer/v5/trade/cancel-order.html index 1250281a61..f0701a5f6c 100644 --- a/zh-TW/api-explorer/v5/trade/cancel-order.html +++ b/zh-TW/api-explorer/v5/trade/cancel-order.html @@ -4,13 +4,13 @@ Cancel Order | Bybit API Documentation - +

    Cancel Order

    Cancel a single order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name

    • orderId string

      Either orderId or orderLinkId is required

    • orderLinkId string

      Either orderId or orderLinkId is required

    • orderFilter string

      Possible values: [Order, tpslOrder]

      Default value: Order

      Take profit stop loss or ordinary order. Only valid for spot.

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/create-order.html b/zh-TW/api-explorer/v5/trade/create-order.html index 0550eea279..179899eb5a 100644 --- a/zh-TW/api-explorer/v5/trade/create-order.html +++ b/zh-TW/api-explorer/v5/trade/create-order.html @@ -4,13 +4,13 @@ Place Order | Bybit API Documentation - +

    Place Order

    Place an order.

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Request Body
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string required

      Symbol name

    • isLeverage integer

      Possible values: [0, 1]

      Whether to loan, only for spot. 0:No;1:Yes.

    • side string required

      Possible values: [Buy, Sell]

    • orderType string required

      Possible values: [Market, Limit]

      Order type

    • qty string required

      Order qty

    • price string

      ignore it if Market order

    • triggerPrice string

      param for StopOrder

    • triggerDirection integer

      param for StopOrder. 1=rise, 2=fall

    • triggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      param for StopOrder

    • orderFilter string

      Possible values: [Order, tpslOrder]

      Default value: Order

      Take profit stop loss or ordinary order. Only valid for spot.

    • orderIv string

      Implied volatility. param for option order

    • timeInForce string

      Possible values: [GTC, IOC, FOK, PostOnly]

      Time in force

    • positionIdx integer

      Possible values: [0, 1, 2]

      0=one-way mode, 1=buy-hedge-mode, 2=sell-hedge-mode

    • orderLinkId string

      required param for option order

    • takeProfit string

      Take profit price

    • stopLoss string

      Stop loss price

    • tpTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger take profit price price type

    • slTriggerBy string

      Possible values: [LastPrice, MarkPrice, IndexPrice]

      Trigger stop loss price price type

    • reduceOnly boolean

      Possible values: [true, false]

      specify true if a close position order

    • closeOnTrigger boolean

      Possible values: [true, false]

      close on trigger

    • smpType string

      Possible values: [None, CancelMaker, CancelTaker, CancelBoth]

      Smp execution type

    • mmp boolean

      Possible values: [true, false]

      market marker protection. for option order

    • tpslMode string

      Possible values: [Full, Partial]

      TP/SL mode

    • tpLimitPrice string

      The limit order price when take profit price is triggered

    • slLimitPrice string

      The limit order price when stop loss price is triggered

    • tpOrderType string

      Possible values: [Market, Limit]

      The order type when take profit is triggered

    • slOrderType string

      Possible values: [Market, Limit]

      The order type when stop loss is triggered

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/open-order.html b/zh-TW/api-explorer/v5/trade/open-order.html index cb0e8f45d0..f34529cca7 100644 --- a/zh-TW/api-explorer/v5/trade/open-order.html +++ b/zh-TW/api-explorer/v5/trade/open-order.html @@ -4,13 +4,13 @@ Get Open Orders (real-time) | Bybit API Documentation - +

    Get Open Orders (real-time)

    Get unfilled orders or partially filled orders

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin. For option only

    • settleCoin string

      Settle coin. Spot is not available

    • orderId string
    • orderLinkId string

      User customised order id

    • orderFilter string

      Possible values: [Order, StopOrder, tpslOrder]

      Order filter. Default:all kinds of orders

    • openOnly integer

      Possible values: [0, 1, 2]

      Whether to only query active orders, if openOnly = 0, only get active orders. If it is 1, return only the order data of the final status (cancelled/rejected/completely filled, etc.) in the last 10 minutes

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor, used for pagination

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/order-list.html b/zh-TW/api-explorer/v5/trade/order-list.html index 83ab3df6ee..6924070c45 100644 --- a/zh-TW/api-explorer/v5/trade/order-list.html +++ b/zh-TW/api-explorer/v5/trade/order-list.html @@ -4,13 +4,13 @@ Get Order History (2 years) | Bybit API Documentation - +

    Get Order History (2 years)

    Get order history.

    Query Parameters
    • category string required

      Possible values: [linear, inverse, option, spot]

      Product type

    • symbol string

      Symbol name

    • baseCoin string

      Base coin

    • orderId string
    • orderLinkId string

      User customised order id

    • startTime integer

      The start timestamp (ms)

    • endTime integer

      The end timestamp (ms)

    • orderStatus string

      Possible values: [Created, New, Rejected, PartiallyFilled, PartillyFilledCancelled, Filled, PendingCancel, Cancelled, Untriggered, Triggered, Deactivated, Active]

      Order status

    • orderFilter string

      Possible values: [Order, StopOrder, tpslOrder]

      Order filter

    • limit integer

      Default value: 20

      1-50. max 50

    • cursor string

      cursor to pagnition

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/query-spot-quota.html b/zh-TW/api-explorer/v5/trade/query-spot-quota.html index 8d6e960e1e..7eff1a85d4 100644 --- a/zh-TW/api-explorer/v5/trade/query-spot-quota.html +++ b/zh-TW/api-explorer/v5/trade/query-spot-quota.html @@ -4,13 +4,13 @@ Get Borrow Quota (Spot) | Bybit API Documentation - +

    Get Borrow Quota (Spot)

    Query user's spot available quota

    Query Parameters
    • category string required

      Possible values: [spot]

      Product type

    • symbol string required

      Symbol name

    • side string required

      Possible values: [Buy, Sell]

      Buy or Sell

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/trade/trade.html b/zh-TW/api-explorer/v5/trade/trade.html index 59dcb84a0b..38bad0e4fe 100644 --- a/zh-TW/api-explorer/v5/trade/trade.html +++ b/zh-TW/api-explorer/v5/trade/trade.html @@ -4,13 +4,13 @@ Trade | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/user/apikey-info.html b/zh-TW/api-explorer/v5/user/apikey-info.html index db5e7a0b7a..4123fed461 100644 --- a/zh-TW/api-explorer/v5/user/apikey-info.html +++ b/zh-TW/api-explorer/v5/user/apikey-info.html @@ -4,13 +4,13 @@ Get API Key Information | Bybit API Documentation - +

    Get API Key Information

    Get API Key Information

    Header Parameters
    • apiKey string

      A UTA sub account API key is provided by default

    • secret string

      A UTA sub account API key is provided by default

    Responses

    successful operation

    Loading...
    - + \ No newline at end of file diff --git a/zh-TW/api-explorer/v5/user/user.html b/zh-TW/api-explorer/v5/user/user.html index f66521c279..b5a4c92bef 100644 --- a/zh-TW/api-explorer/v5/user/user.html +++ b/zh-TW/api-explorer/v5/user/user.html @@ -4,13 +4,13 @@ User | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/assets/js/5787f6d3.b353aada.js b/zh-TW/assets/js/5787f6d3.43db6b6b.js similarity index 59% rename from zh-TW/assets/js/5787f6d3.b353aada.js rename to zh-TW/assets/js/5787f6d3.43db6b6b.js index 4fb69b395a..6233725f67 100644 --- a/zh-TW/assets/js/5787f6d3.b353aada.js +++ b/zh-TW/assets/js/5787f6d3.43db6b6b.js @@ -1 +1 @@ -"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[94900],{3905:(t,e,n)=>{n.d(e,{Zo:()=>u,kt:()=>m});var r=n(67294);function a(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t){for(var e=1;e=0||(a[n]=t[n]);return a}(t,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(a[n]=t[n])}return a}var p=r.createContext({}),d=function(t){var e=r.useContext(p),n=e;return t&&(n="function"==typeof t?t(e):i(i({},e),t)),n},u=function(t){var e=d(t.components);return r.createElement(p.Provider,{value:e},t.children)},c={inlineCode:"code",wrapper:function(t){var e=t.children;return r.createElement(r.Fragment,{},e)}},s=r.forwardRef((function(t,e){var n=t.components,a=t.mdxType,l=t.originalType,p=t.parentName,u=o(t,["components","mdxType","originalType","parentName"]),s=d(n),m=a,k=s["".concat(p,".").concat(m)]||s[m]||c[m]||l;return n?r.createElement(k,i(i({ref:e},u),{},{components:n})):r.createElement(k,i({ref:e},u))}));function m(t,e){var n=arguments,a=e&&e.mdxType;if("string"==typeof t||a){var l=n.length,i=new Array(l);i[0]=s;var o={};for(var p in e)hasOwnProperty.call(e,p)&&(o[p]=e[p]);o.originalType=t,o.mdxType="string"==typeof t?t:a,i[1]=o;for(var d=2;d{n.r(e),n.d(e,{assets:()=>p,contentTitle:()=>i,default:()=>c,frontMatter:()=>l,metadata:()=>o,toc:()=>d});var r=n(87462),a=(n(67294),n(3905));const l={title:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_label:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_position:7},i=void 0,o={unversionedId:"v5/otc/bind-uid",id:"v5/otc/bind-uid",title:"\u7d81\u5b9a/\u89e3\u7d81UID",description:"\u5c0d\u65bc\u5834\u5916\u501f\u8cb8\u7522\u54c1, \u60a8\u53ef\u4ee5\u81ea\u884c\u7d81\u5b9a\u65b0\u7684UID\u5230\u98a8\u96aa\u55ae\u5143\u5167\u6216\u8005\u89e3\u7d81\u67d0\u500bUID",source:"@site/i18n/zh-TW/docusaurus-plugin-content-docs/current/v5/otc/bind-uid.mdx",sourceDirName:"v5/otc",slug:"/v5/otc/bind-uid",permalink:"/docs/zh-TW/v5/otc/bind-uid",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_label:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_position:7},sidebar:"v5SideBar",previous:{title:"\u67e5\u8a62\u98a8\u96aa\u7387",permalink:"/docs/zh-TW/v5/otc/ltv-convert"},next:{title:"\u67e5\u8a62\u53ef\u5b58\u5165\u5e63\u7a2e\u4fe1\u606f",permalink:"/docs/zh-TW/v5/c2c-lend/coin-info"}},p={},d=[{value:"HTTP \u8acb\u6c42",id:"http-\u8acb\u6c42",level:3},{value:"\u8acb\u6c42\u53c3\u6578",id:"\u8acb\u6c42\u53c3\u6578",level:3},{value:"\u97ff\u61c9\u53c3\u6578",id:"\u97ff\u61c9\u53c3\u6578",level:3},{value:"\u8acb\u6c42\u793a\u4f8b",id:"\u8acb\u6c42\u793a\u4f8b",level:3},{value:"\u97ff\u61c9\u793a\u4f8b",id:"\u97ff\u61c9\u793a\u4f8b",level:3}],u={toc:d};function c(t){let{components:e,...n}=t;return(0,a.kt)("wrapper",(0,r.Z)({},u,n,{components:e,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5c0d\u65bc\u5834\u5916\u501f\u8cb8\u7522\u54c1, \u60a8\u53ef\u4ee5\u81ea\u884c\u7d81\u5b9a\u65b0\u7684UID\u5230\u98a8\u96aa\u55ae\u5143\u5167\u6216\u8005\u89e3\u7d81\u67d0\u500bUID"),(0,a.kt)("admonition",{type:"info"},(0,a.kt)("ul",{parentName:"admonition"},(0,a.kt)("li",{parentName:"ul"},"\u98a8\u96aa\u55ae\u5143\u7684\u4e3bUID\u4e0d\u80fd\u89e3\u7d81"),(0,a.kt)("li",{parentName:"ul"},"\u8a72\u63a5\u53e3\u53ea\u80fd\u7531\u5728\u98a8\u96aa\u55ae\u5143\u5167\u7684UID\u4f86\u8acb\u6c42"),(0,a.kt)("li",{parentName:"ul"},"\u7d81\u5b9a\u7684UID\u5fc5\u9808\u5347\u7d1a\u5230\u4e86\u7d71\u4e00\u5e33\u6236"))),(0,a.kt)("h3",{id:"http-\u8acb\u6c42"},"HTTP \u8acb\u6c42"),(0,a.kt)("p",null,"POST ",(0,a.kt)("inlineCode",{parentName:"p"},"/v5/ins-loan/association-uid")),(0,a.kt)("h3",{id:"\u8acb\u6c42\u53c3\u6578"},"\u8acb\u6c42\u53c3\u6578"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"\u53c3\u6578"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u662f\u5426\u5fc5\u9700"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u985e\u578b"),(0,a.kt)("th",{parentName:"tr",align:null},"\u8aaa\u660e"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": \u7d81\u5b9a, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": \u89e3\u7d81")))),(0,a.kt)("h3",{id:"\u97ff\u61c9\u53c3\u6578"},"\u97ff\u61c9\u53c3\u6578"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"\u53c3\u6578"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u985e\u578b"),(0,a.kt)("th",{parentName:"tr",align:null},"\u8aaa\u660e"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": \u7d81\u5b9a, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": \u89e3\u7d81")))),(0,a.kt)("h3",{id:"\u8acb\u6c42\u793a\u4f8b"},"\u8acb\u6c42\u793a\u4f8b"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-http"},'POST /v5/ins-loan/association-uid HTTP/1.1\nHost: api-testnet.bybit.com\nX-BAPI-API-KEY: XXXXX\nX-BAPI-TIMESTAMP: 1699257853101\nX-BAPI-RECV-WINDOW: 5000\nX-BAPI-SIGN: XXXXX\nContent-Type: application/json\nContent-Length: 43\n\n{\n "uid": "592324",\n "operate": "0"\n}\n')),(0,a.kt)("h3",{id:"\u97ff\u61c9\u793a\u4f8b"},"\u97ff\u61c9\u793a\u4f8b"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-json"},'{\n "retCode": 0,\n "retMsg": "OK",\n "result": {\n "uid": "592324",\n "operate": "0"\n },\n "retExtInfo": {},\n "time": 1699257746135\n}\n')))}c.isMDXComponent=!0}}]); \ No newline at end of file +"use strict";(self.webpackChunkdocusaurus_docs=self.webpackChunkdocusaurus_docs||[]).push([[94900],{3905:(t,e,n)=>{n.d(e,{Zo:()=>u,kt:()=>m});var r=n(67294);function a(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t){for(var e=1;e=0||(a[n]=t[n]);return a}(t,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(a[n]=t[n])}return a}var p=r.createContext({}),d=function(t){var e=r.useContext(p),n=e;return t&&(n="function"==typeof t?t(e):i(i({},e),t)),n},u=function(t){var e=d(t.components);return r.createElement(p.Provider,{value:e},t.children)},c={inlineCode:"code",wrapper:function(t){var e=t.children;return r.createElement(r.Fragment,{},e)}},s=r.forwardRef((function(t,e){var n=t.components,a=t.mdxType,l=t.originalType,p=t.parentName,u=o(t,["components","mdxType","originalType","parentName"]),s=d(n),m=a,k=s["".concat(p,".").concat(m)]||s[m]||c[m]||l;return n?r.createElement(k,i(i({ref:e},u),{},{components:n})):r.createElement(k,i({ref:e},u))}));function m(t,e){var n=arguments,a=e&&e.mdxType;if("string"==typeof t||a){var l=n.length,i=new Array(l);i[0]=s;var o={};for(var p in e)hasOwnProperty.call(e,p)&&(o[p]=e[p]);o.originalType=t,o.mdxType="string"==typeof t?t:a,i[1]=o;for(var d=2;d{n.r(e),n.d(e,{assets:()=>p,contentTitle:()=>i,default:()=>c,frontMatter:()=>l,metadata:()=>o,toc:()=>d});var r=n(87462),a=(n(67294),n(3905));const l={title:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_label:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_position:7},i=void 0,o={unversionedId:"v5/otc/bind-uid",id:"v5/otc/bind-uid",title:"\u7d81\u5b9a/\u89e3\u7d81UID",description:"\u5c0d\u65bc\u5834\u5916\u501f\u8cb8\u7522\u54c1, \u60a8\u53ef\u4ee5\u81ea\u884c\u7d81\u5b9a\u65b0\u7684UID\u5230\u98a8\u96aa\u55ae\u5143\u5167\u6216\u8005\u89e3\u7d81\u67d0\u500bUID",source:"@site/i18n/zh-TW/docusaurus-plugin-content-docs/current/v5/otc/bind-uid.mdx",sourceDirName:"v5/otc",slug:"/v5/otc/bind-uid",permalink:"/docs/zh-TW/v5/otc/bind-uid",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_label:"\u7d81\u5b9a/\u89e3\u7d81UID",sidebar_position:7},sidebar:"v5SideBar",previous:{title:"\u67e5\u8a62\u98a8\u96aa\u7387",permalink:"/docs/zh-TW/v5/otc/ltv-convert"},next:{title:"\u67e5\u8a62\u53ef\u5b58\u5165\u5e63\u7a2e\u4fe1\u606f",permalink:"/docs/zh-TW/v5/c2c-lend/coin-info"}},p={},d=[{value:"HTTP \u8acb\u6c42",id:"http-\u8acb\u6c42",level:3},{value:"\u8acb\u6c42\u53c3\u6578",id:"\u8acb\u6c42\u53c3\u6578",level:3},{value:"\u97ff\u61c9\u53c3\u6578",id:"\u97ff\u61c9\u53c3\u6578",level:3},{value:"\u8acb\u6c42\u793a\u4f8b",id:"\u8acb\u6c42\u793a\u4f8b",level:3},{value:"\u97ff\u61c9\u793a\u4f8b",id:"\u97ff\u61c9\u793a\u4f8b",level:3}],u={toc:d};function c(t){let{components:e,...n}=t;return(0,a.kt)("wrapper",(0,r.Z)({},u,n,{components:e,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5c0d\u65bc\u5834\u5916\u501f\u8cb8\u7522\u54c1, \u60a8\u53ef\u4ee5\u81ea\u884c\u7d81\u5b9a\u65b0\u7684UID\u5230\u98a8\u96aa\u55ae\u5143\u5167\u6216\u8005\u89e3\u7d81\u67d0\u500bUID"),(0,a.kt)("admonition",{type:"info"},(0,a.kt)("ul",{parentName:"admonition"},(0,a.kt)("li",{parentName:"ul"},"\u98a8\u96aa\u55ae\u5143\u7684\u4e3bUID\u4e0d\u80fd\u89e3\u7d81"),(0,a.kt)("li",{parentName:"ul"},"\u8a72\u63a5\u53e3\u53ea\u80fd\u7531\u5728\u98a8\u96aa\u55ae\u5143\u5167\u7684UID\u4f86\u8acb\u6c42"),(0,a.kt)("li",{parentName:"ul"},"\u7d81\u5b9a\u7684UID\u5fc5\u9808\u5347\u7d1a\u5230\u4e86UTA Pro"))),(0,a.kt)("h3",{id:"http-\u8acb\u6c42"},"HTTP \u8acb\u6c42"),(0,a.kt)("p",null,"POST ",(0,a.kt)("inlineCode",{parentName:"p"},"/v5/ins-loan/association-uid")),(0,a.kt)("h3",{id:"\u8acb\u6c42\u53c3\u6578"},"\u8acb\u6c42\u53c3\u6578"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"\u53c3\u6578"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u662f\u5426\u5fc5\u9700"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u985e\u578b"),(0,a.kt)("th",{parentName:"tr",align:null},"\u8aaa\u660e"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},(0,a.kt)("strong",{parentName:"td"},"true")),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": \u7d81\u5b9a, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": \u89e3\u7d81")))),(0,a.kt)("h3",{id:"\u97ff\u61c9\u53c3\u6578"},"\u97ff\u61c9\u53c3\u6578"),(0,a.kt)("table",null,(0,a.kt)("thead",{parentName:"table"},(0,a.kt)("tr",{parentName:"thead"},(0,a.kt)("th",{parentName:"tr",align:"left"},"\u53c3\u6578"),(0,a.kt)("th",{parentName:"tr",align:"left"},"\u985e\u578b"),(0,a.kt)("th",{parentName:"tr",align:null},"\u8aaa\u660e"))),(0,a.kt)("tbody",{parentName:"table"},(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"uid"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},"UID")),(0,a.kt)("tr",{parentName:"tbody"},(0,a.kt)("td",{parentName:"tr",align:"left"},"operate"),(0,a.kt)("td",{parentName:"tr",align:"left"},"string"),(0,a.kt)("td",{parentName:"tr",align:null},(0,a.kt)("inlineCode",{parentName:"td"},"0"),": \u7d81\u5b9a, ",(0,a.kt)("inlineCode",{parentName:"td"},"1"),": \u89e3\u7d81")))),(0,a.kt)("h3",{id:"\u8acb\u6c42\u793a\u4f8b"},"\u8acb\u6c42\u793a\u4f8b"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-http"},'POST /v5/ins-loan/association-uid HTTP/1.1\nHost: api-testnet.bybit.com\nX-BAPI-API-KEY: XXXXX\nX-BAPI-TIMESTAMP: 1699257853101\nX-BAPI-RECV-WINDOW: 5000\nX-BAPI-SIGN: XXXXX\nContent-Type: application/json\nContent-Length: 43\n\n{\n "uid": "592324",\n "operate": "0"\n}\n')),(0,a.kt)("h3",{id:"\u97ff\u61c9\u793a\u4f8b"},"\u97ff\u61c9\u793a\u4f8b"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-json"},'{\n "retCode": 0,\n "retMsg": "OK",\n "result": {\n "uid": "592324",\n "operate": "0"\n },\n "retExtInfo": {},\n "time": 1699257746135\n}\n')))}c.isMDXComponent=!0}}]); \ No newline at end of file diff --git a/zh-TW/assets/js/runtime~main.ce61000b.js b/zh-TW/assets/js/runtime~main.c5ab26b0.js similarity index 92% rename from zh-TW/assets/js/runtime~main.ce61000b.js rename to zh-TW/assets/js/runtime~main.c5ab26b0.js index e11adc266f..226e75a5f1 100644 --- a/zh-TW/assets/js/runtime~main.ce61000b.js +++ b/zh-TW/assets/js/runtime~main.c5ab26b0.js @@ -1 +1 @@ -(()=>{"use strict";var e,f,b,a,d,c={},r={};function t(e){var f=r[e];if(void 0!==f)return f.exports;var b=r[e]={id:e,loaded:!1,exports:{}};return c[e].call(b.exports,b,b.exports,t),b.loaded=!0,b.exports}t.m=c,e=[],t.O=(f,b,a,d)=>{if(!b){var c=1/0;for(i=0;i=d)&&Object.keys(t.O).every((e=>t.O[e](b[o])))?b.splice(o--,1):(r=!1,d0&&e[i-1][2]>d;i--)e[i]=e[i-1];e[i]=[b,a,d]},t.n=e=>{var f=e&&e.__esModule?()=>e.default:()=>e;return t.d(f,{a:f}),f},b=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,t.t=function(e,a){if(1&a&&(e=this(e)),8&a)return e;if("object"==typeof e&&e){if(4&a&&e.__esModule)return e;if(16&a&&"function"==typeof e.then)return e}var d=Object.create(null);t.r(d);var c={};f=f||[null,b({}),b([]),b(b)];for(var r=2&a&&e;"object"==typeof r&&!~f.indexOf(r);r=b(r))Object.getOwnPropertyNames(r).forEach((f=>c[f]=()=>e[f]));return c.default=()=>e,t.d(d,c),d},t.d=(e,f)=>{for(var b in f)t.o(f,b)&&!t.o(e,b)&&Object.defineProperty(e,b,{enumerable:!0,get:f[b]})},t.f={},t.e=e=>Promise.all(Object.keys(t.f).reduce(((f,b)=>(t.f[b](e,f),f)),[])),t.u=e=>"assets/js/"+({16:"a2a78cd2",17:"5df371ad",288:"575a2139",482:"4ef5f34b",520:"fb1a77b4",547:"3365bb5d",930:"bc8f9087",1045:"3ef25e43",1046:"ee503142",1288:"ecc882d7",1325:"1ff2c95d",1369:"2be8d75a",1669:"f58086e5",1770:"e6847b95",1893:"4c5e977b",1972:"ed99de2c",2050:"f54e89d1",2143:"64e17396",2201:"8ba34e88",2222:"0c82f1cb",2269:"a596dc7e",2281:"652aa3bb",2487:"b7b09b70",2751:"faa6790b",3300:"655c39d2",3507:"2425c15c",3909:"3e441ee4",4086:"78ec6490",4147:"345d96d3",4193:"95ce3c59",4746:"93a1b6a2",4879:"98b08a7f",4993:"7cfe228b",5209:"bcd351e4",5569:"2ad4d3fa",5665:"7bb9f034",5805:"ba875990",5899:"4dab1df6",6147:"1f54c2ac",6352:"e628edd4",6542:"af2c52ce",6576:"fc169afb",6768:"4eb9b8ff",6907:"0393be11",7338:"833a1fde",7841:"179c9190",7848:"b760913b",8156:"38784009",8179:"136658e4",8214:"9755f20c",8392:"8d4600d0",8478:"401fb871",8718:"b76d73e0",8883:"6860968b",9087:"23b7e03a",9642:"0002f649",9706:"2eca92d8",9817:"14eb3368",9862:"d5ac6535",10040:"954c355d",10235:"a7d19085",10293:"fa570740",10471:"b71c170b",11013:"e8acd80e",11053:"7205acf7",11119:"988d8e24",11120:"7c3d9323",11434:"99aca8b2",11500:"d68165b9",11606:"5016f915",11762:"30de7014",11921:"0dfefb75",11968:"f34bbf22",12319:"e6b47cdb",12920:"ee2d7736",12944:"a4a7c88e",13055:"97600ac6",13085:"1f391b9e",13364:"74e68634",13408:"fdf22a50",13467:"08cdb8be",13586:"c668d467",13667:"bf60373a",13845:"f7318e59",13874:"643f775f",14030:"c5d3bb95",14188:"035fc0a7",14243:"0744e06b",14710:"2492320d",14945:"b9fef5ef",15114:"ee7f03d8",15262:"664d32ba",15365:"b82d00b2",15408:"2435c844",15772:"b568538e",15903:"f4c85b32",16021:"a42811bf",16039:"4e6201a8",16052:"8aab06bf",16175:"567ff302",16401:"1a7a3335",16649:"a19cf377",16677:"3d4af990",16950:"b43e4353",16991:"3f53f1c4",17175:"c4f64aee",17217:"4ef1736a",17446:"eaca4732",17661:"265355c2",17929:"d56e3bd7",18085:"f56ba7e1",18350:"0f2e9443",18387:"2be7eaec",18455:"762969cd",18471:"2bfafb22",18610:"c5a9135f",19063:"0004065d",19122:"c1adbe0b",19219:"f2bfa581",19396:"9f35e670",19423:"1912069b",20183:"f40511f8",20202:"1e049e66",20367:"05a3c259",21493:"79022373",21945:"ccaa939a",22043:"269c0fa1",22190:"89f7284f",22477:"2b25df32",22620:"cf587678",22821:"dac58f9a",22982:"f041af6f",23105:"6ac88df6",23198:"15df18f8",23349:"5b6fa4ec",23389:"9041aea1",23563:"935cb8db",23656:"98dd666f",23733:"b82293b3",23747:"bedf2929",23891:"642b1006",23903:"19b9d2d9",24215:"13696f7b",24669:"f552bd00",24697:"c54eca7f",24698:"92e11b3f",24947:"e9b84ed8",25090:"87897be6",25817:"7988f281",25968:"156751cf",26467:"302d24dc",26560:"5b788f5c",27e3:"3326e4c4",27078:"d7ac3c03",27079:"49a0e813",27133:"92e99bf6",27188:"5036ec9d",27507:"68f233e4",28135:"89179ad6",28155:"094ce30e",28268:"b8161d6a",28271:"f7eb3a66",28429:"b052b80c",28751:"e31a16ba",28772:"d5f94c50",29010:"8c2621f5",29140:"1d8ede30",29513:"0ac7fcd1",29514:"1be78505",29538:"4c950052",29728:"38c90751",29776:"5dab34b6",30051:"6dd54b46",30321:"751792b8",30499:"24774f91",30561:"bc670d5c",30601:"e5d84bc0",30708:"124f7953",30717:"ecdb20a1",31218:"eeea228c",31287:"b2d0af62",31404:"3e301362",31538:"19b883ea",31640:"4f7dcb1e",31657:"8fbaa47b",31833:"86fd2478",31854:"b45ff73d",32446:"6870c8c4",32854:"6c46dea8",33034:"41ed4202",33232:"6131b9f8",33404:"afdda5b6",33431:"e35d3956",33451:"f5b6c895",33509:"786f71e5",33790:"c423df2e",33887:"10ca1dd8",33912:"1bc94aef",33949:"1e577d6c",34346:"1db637b2",34533:"3abccbcc",34756:"9c643b6e",34826:"70e3a7c5",35123:"b45cdd21",35226:"e7958aaa",35330:"eadead04",35424:"3635a766",35708:"41eb0037",35898:"eb050011",35943:"bc53881b",36137:"fcda79ce",36586:"8c3021dd",36648:"a6b8b35b",36733:"16dd13c1",36904:"e71641ea",37146:"86320adf",37193:"49541ebb",37442:"f6ef3039",37486:"dcc6b54d",37487:"a9bf2227",37570:"ab214d24",37742:"969753d7",38270:"5393ce94",38461:"917300a3",38527:"4f9fd89c",38601:"f7242226",38818:"7e40020f",39066:"a4a7a840",39229:"429a6f3e",39494:"01804294",39626:"fd867f7c",39675:"62547fbf",40081:"39f63e6a",40293:"7190026f",40701:"1ce0a301",40733:"6099ba0c",40830:"c343ef35",40916:"e4459066",41003:"d0d62bb5",41150:"fe26f94f",41276:"a6c72656",41650:"c7707dd8",41847:"82a30884",41890:"53fc083e",41957:"d69803c7",42008:"9e43e7b6",42124:"19357a65",42181:"be510d4c",42355:"2f504c6e",42573:"ce346131",42793:"35d5d226",42885:"acdbee8e",42954:"2814cf01",43600:"1dcc65e0",43726:"6b85e2ea",43777:"b9aefb1a",43819:"fc1db29b",44018:"d50a8def",44209:"278665dc",44484:"3cd952ae",44497:"d32e6b20",44588:"3c5750f8",44685:"f5c87087",44880:"e7d2e6f0",44962:"1c5f7d2b",45208:"034a556b",45350:"e8c60e9b",45841:"0c0bbaea",45843:"e4bacbbb",45919:"8070429a",45960:"5b3c1c53",46294:"db229a81",46581:"c2d91591",47234:"ae346411",47328:"6daf901a",47422:"1cf37028",47615:"84ebbbbf",47629:"0cd0cfa8",47769:"196fab6d",47834:"09be2ba2",48124:"553f321c",48343:"2c056d5d",48733:"d21505c8",48890:"d5603669",48954:"b0bdb7f3",49313:"79d1baac",49346:"b8919bdb",49486:"e72cf26a",49549:"48e0b5d4",49567:"f0cf672d",49871:"b2f83e6d",49907:"f2e41396",50030:"fd3dbbb4",50561:"254ac25b",51435:"fe2b089e",51537:"431ad29b",51618:"2cbe9533",51953:"c3e83a7d",52021:"25b6fab0",52486:"de127d6b",52603:"a4b6f3a5",52631:"c46f1db0",52745:"68843839",52814:"2cc833a8",53111:"203d8c37",53302:"cb8de75d",53309:"63ee150d",53559:"ebe9f683",53587:"73567145",53609:"81be975d",53685:"8c00b41d",53778:"2fa02bf3",54013:"2f5fda3e",54235:"695f8b9b",54487:"5ebc7423",54709:"2b93221c",54736:"a5463d8a",54747:"8acd050c",54749:"bf25430f",55035:"ea64ac1c",55260:"9e4d6f26",55328:"74c40fe4",55480:"006095b2",55945:"79aa13fb",56025:"c3aed80f",56122:"f5dc225c",56248:"8a1c8da1",56364:"281b126c",56370:"36f93d19",56419:"80e8986a",56615:"b4f4317d",56955:"51ca6efd",56963:"1b80e345",56979:"d005934a",57060:"4be15b13",57103:"77d0fddc",57145:"5c71c40a",57287:"bde9fb45",57361:"3e26f8b3",57480:"c86abbf7",57573:"e3e4fe7d",58e3:"fbf4432e",58634:"e6a2b2bf",58729:"dbbfa97d",59131:"3b0223df",59273:"fcae69e8",59469:"68648e27",59485:"edfdb191",59728:"aa5bd2a7",59856:"e5c88a3e",59865:"e8ee0390",60217:"92ddf9a4",60377:"2d4599ae",60389:"a03d8b30",60439:"fca48710",60679:"353f52a3",60946:"bb292d37",61304:"8d5fe6f9",61528:"2b6f680f",61683:"86ce5bc1",61928:"15113e52",61931:"4c21dbbd",62062:"988ba51e",62536:"431b5d0e",62726:"748490a7",62746:"00468222",62954:"90305fb4",63119:"d7567838",63157:"586e3f5e",63453:"37da3438",64131:"52c1dace",64195:"c4f5d8e4",64302:"05c5421d",64364:"4bec54d5",64549:"788d9fe0",64807:"8a495097",64814:"8ade285d",65010:"877bdd66",65064:"4840c3eb",65135:"789f108c",65349:"796ce4fb",65368:"cc468388",65369:"c15b67f7",65649:"8047f3a3",65858:"1290c878",65882:"6aa5826c",65957:"e4627c87",66073:"97b92a45",66334:"3c39ccf9",67098:"6df78374",67112:"7196ee6c",67125:"ca3aabfb",67140:"e8b2d68f",67328:"137314dd",67365:"18f77871",67396:"a9dd1cc8",67673:"6eb57332",67744:"6ca8826f",67813:"8894256f",67818:"baa3212e",67821:"bcd02ebb",67995:"ff2d6dd8",68005:"73ce7b01",68026:"e63b451d",68189:"26e12baa",68224:"78bca219",68265:"389bb65e",68349:"3d3a07f6",68618:"88e3fe7e",68755:"a79a2e70",68960:"03cc88eb",69043:"9ad8637e",69113:"e8e02f59",69184:"30b61715",69345:"01a16f71",69360:"98a6b9c4",69413:"71063c2b",69905:"e23eefc0",69998:"b7cfb3da",70147:"b9535f14",70207:"68556356",70421:"a934672d",70509:"3b768736",70520:"e2df322b",70611:"fa114b0c",70633:"b50c9021",70838:"22bdf908",71253:"970a27d6",71360:"17b00a4a",71386:"b1892b20",71525:"3b7cd1e1",71568:"43cca846",71670:"6d8024b7",71723:"0328b0c9",72069:"57494db5",72145:"a5c74766",72371:"47c64002",72464:"8b8c4320",72474:"f9e1fd09",72556:"5614add0",72841:"bb0e99df",72939:"a626e327",73088:"955e06fd",73091:"04849bf5",73894:"9b6eea2c",74010:"37cea19d",74123:"a8654aa2",74190:"84cf2087",74199:"67db246e",74298:"48db5030",74318:"b8d9b1bd",74400:"aacc2fee",74904:"c0ad5dc6",75034:"30a22249",75062:"add4d791",75063:"cf69f832",75066:"466daf09",75212:"19b0499c",75248:"e82ff315",75384:"42bb1101",75478:"200e51df",75647:"2b3e7a7f",76255:"94a29094",76413:"777bd32a",76559:"93b78259",76614:"3f21c259",76907:"a208e2a5",77183:"a94c7dba",77184:"11b4dd89",77665:"97d979ce",77769:"60ea2d86",77771:"56a38f24",77787:"53bd4095",78023:"2b20c80a",78297:"71051dda",78301:"676afd3b",78382:"1a77ceda",78494:"e49348be",78560:"fd37922c",78880:"44befa6d",78897:"8a942fcc",79022:"9beaa53d",79046:"904cfab0",79256:"d2a246a6",79315:"378b1b2a",79376:"6249c7de",79527:"20358428",79639:"7cd86536",79796:"d2c4b928",80053:"935f2afb",80371:"c038b4a2",80536:"17c91901",80693:"cfc8b1e5",80802:"48d397c0",80954:"db449848",81030:"d312cf7c",81188:"476a319a",81355:"9ad476bb",81747:"f1e3befe",81832:"a8e44541",81981:"c8450cf2",82251:"989904ef",82268:"55042936",82294:"555d583b",82591:"de89bf85",82946:"3b83c135",83443:"f47c1d11",83540:"6500be67",83667:"ab4a8e8f",83771:"8c02dfd8",83773:"39c791a9",83882:"3a4337ef",83922:"cc806444",84191:"cf7f1202",84453:"fc15d889",84683:"25b7eef7",84769:"2f53b05f",84840:"2e4eadd3",84857:"b4eef555",84878:"2e8d4eda",85015:"f21b2fb0",85064:"d02b76f9",85185:"e1b9cf16",85188:"c0e80954",85228:"2fcb69bb",85313:"06848362",85660:"6dd1645f",85694:"db0d392c",85897:"6b3775fc",85953:"b700f6c8",86072:"26183636",86098:"149e5a51",86181:"a01bbcd4",86401:"fed0304a",86451:"f2a10594",86455:"e8c8f122",86948:"af7ab695",87173:"87a13df2",87306:"aebe3827",87414:"393be207",87582:"7fc0684b",87655:"40230f21",87658:"6dde3b76",88042:"5daee80f",88184:"87f76dec",88856:"e8351d64",88935:"99494472",89101:"e2c0c813",89415:"3f0d1ba4",89645:"e760b063",89786:"c1d23c47",89912:"75a6ad06",89964:"b82b3205",89987:"9ccbc3bf",90058:"24f02aa4",90558:"93f8b8b5",90888:"5c18dc43",90951:"76e9b4e1",91172:"864138a2",91233:"46972690",91250:"8758e270",91538:"0248575c",91919:"d51ffe49",92416:"726fea1f",93056:"73bfea73",93065:"812cb8ed",93387:"007a6c32",93519:"6f951ae3",93546:"1010372b",93610:"caba9b9f",93822:"7d52489f",93903:"5610cdb3",94018:"046df3c9",94089:"d9ffe17e",94091:"5c128c28",94194:"4b3e38af",94201:"d6b0fe44",94215:"189eacae",94229:"c8a044ba",94319:"d0816b53",94722:"5282f1c8",94900:"5787f6d3",94907:"29f28a73",95034:"64be7568",95188:"b42420f8",95190:"f8dc48d9",95690:"f4bc196f",96276:"8aadacf1",96826:"68f43c04",97482:"4a3e680b",97889:"02193fc8",97900:"954fe569",97920:"1a4e3797",98016:"ffb2e417",98105:"acc38ec3",98276:"2205312d",98444:"cc9c20e3",98509:"92ac5c16",98623:"394c74c3",98630:"68e9a632",98666:"f64e920b",98692:"67044a7a",98792:"0d6f57e0",99074:"e8646b2e",99156:"ff6e33f8",99350:"196bfd5c",99438:"b5511831",99533:"a6f4eced",99875:"57d9a11e",99889:"f56b8973",99959:"ebec70a2"}[e]||e)+"."+{16:"95e0997a",17:"ed5abb28",288:"33a85255",482:"59ff1c0e",520:"1e46e45b",547:"9305bdd4",930:"68112f0d",1045:"2e5edf24",1046:"d713be58",1288:"3d55ced1",1325:"36daf010",1369:"f97380b2",1669:"7c92e3ef",1770:"33a46207",1893:"4a98b5fe",1972:"3767f63a",2050:"7b453b74",2143:"6cedb54a",2201:"ad3df26d",2222:"ec9f034c",2269:"bd53496e",2281:"c533a6a9",2487:"2b476883",2751:"5c44f3e3",3300:"56abba7d",3507:"3145d6a9",3909:"d63592c0",4086:"6391b158",4147:"4db3769d",4193:"2d5c593a",4746:"9948c140",4879:"84274f1c",4972:"c1e0c51c",4993:"3fe34bb0",5209:"ffef8faa",5569:"b2bf6d68",5665:"d466007a",5805:"57eba598",5899:"fc5291bb",6147:"eb09fe54",6338:"b6c9a516",6352:"5d14f184",6542:"a4de5f7b",6576:"ab962437",6768:"5e0b70d5",6907:"286e36f7",7338:"2c210096",7841:"67e1419a",7848:"4c2aa69e",8156:"2d6a320e",8179:"350c6a2c",8214:"b6746997",8392:"35ef4166",8478:"7bac00a3",8718:"a7889de4",8883:"ddf92a47",9087:"4957ed1d",9642:"6869b485",9706:"349d0471",9799:"cdb5b12a",9817:"f9d79ca6",9862:"33c1d656",10040:"efab490a",10235:"ab4f13c3",10293:"6cceee53",10471:"5fe12cb7",11013:"ade95505",11053:"531ec399",11119:"734ff14a",11120:"935a1320",11434:"799e8557",11500:"da44a65e",11606:"56683491",11762:"9448562a",11921:"da387b1f",11968:"a755f5af",12319:"7d20f0da",12920:"d03eea4e",12944:"2add0bd9",13055:"65361055",13085:"74c4de50",13364:"6afac0b7",13408:"2e25889f",13467:"d658b843",13586:"8c682e32",13667:"8d362cf8",13845:"3c3b327f",13874:"f9d065b6",14030:"57c1e1f4",14188:"09ab5b8d",14243:"e3763bcb",14710:"b8be2c99",14945:"55a1da25",15114:"4bf1aaa7",15262:"c9098fcb",15365:"45578418",15408:"b511830f",15772:"edae0608",15903:"08ac177d",16021:"e645f895",16039:"38a142bf",16052:"bc5fd83f",16175:"12751b0b",16401:"c743db5b",16649:"8a2a38f3",16677:"10a87717",16950:"6054afa1",16991:"82fcf322",17175:"d885a1cf",17217:"7e67cf71",17446:"ab51932f",17661:"0f5a68ec",17929:"bfd49b0b",18085:"2d3b6630",18350:"af482d40",18387:"e5c6f0ed",18455:"262e8aee",18471:"e7a7dd5f",18610:"8a8f909a",18894:"2da9821d",19063:"8389be42",19122:"48bf3aff",19219:"8a00ddc5",19396:"e4d6fd46",19423:"6ee26968",20183:"258ccbd0",20202:"2a93bb92",20367:"e00fbdaa",21493:"56dc5cff",21945:"c3855c24",22043:"ee188a85",22190:"8252be8d",22477:"a26ee541",22620:"7883a084",22761:"365a347a",22821:"8f42977b",22982:"ac9e007a",23105:"63d5d573",23198:"09670e1a",23349:"c40a6a59",23389:"f05fa93a",23563:"143e8437",23656:"d3c2b7e5",23733:"3abb3db5",23747:"2cb9229a",23891:"142c057e",23903:"0f444c6c",24215:"b033301b",24669:"e5147b47",24697:"4956e563",24698:"cafbaf96",24947:"6da1c2c1",25090:"a928e25d",25817:"a09a6bc8",25968:"8988001f",26467:"59a420c1",26560:"d5cc94c4",27e3:"b6946233",27078:"f6c4a7ff",27079:"f2221d2a",27133:"20e10a7b",27188:"787c6412",27507:"e3274b92",28135:"68b3b465",28155:"e5eb2a4b",28268:"c2ebb553",28271:"798bcbda",28429:"1399b650",28751:"a3f317d7",28772:"d9b16730",29010:"1941991d",29140:"080e50b9",29513:"760b6e5b",29514:"e4bcc747",29538:"8ebe6590",29728:"651a8f72",29776:"49e857bf",30051:"fc3a747d",30321:"fb4aba14",30499:"37a4a9be",30561:"039f452c",30601:"6cd65da7",30708:"4fc498e6",30717:"467f93e7",31218:"00a3b7fc",31287:"9c6d9c6d",31404:"81c31d94",31538:"f7fbf7d0",31640:"59558e17",31657:"78307e2b",31833:"b2b7fa8e",31854:"e06feffa",32446:"2ed3abb0",32854:"ddf29eef",33034:"dbadc1fd",33232:"2f974a7f",33404:"a71820ed",33431:"52e788b4",33451:"7ae801f2",33509:"8d723cab",33790:"d0c835a8",33887:"17393ec9",33912:"edf434b6",33949:"e23a7733",34346:"1c8bba18",34533:"15d33a5b",34756:"b9a1b5f0",34826:"c819b9d0",35123:"365f8e55",35226:"c1a6f8ac",35330:"0efdba7e",35424:"a0ae2d81",35708:"3302f660",35898:"fbfd559c",35943:"dbdd3cbe",36137:"46710853",36586:"7b9a86d2",36648:"96e68b71",36733:"0f6d9905",36904:"692a4593",37146:"95a5b1ed",37193:"9b715ee1",37442:"855253b6",37486:"30e1048f",37487:"77385b9d",37570:"f06e7349",37742:"6df71594",38270:"47996dae",38461:"436fd90f",38527:"4e989100",38601:"2994690a",38818:"8675c575",39066:"b79135f9",39229:"c2d088d4",39494:"7fd53958",39626:"87b8e7f0",39675:"705b00c7",40081:"9a9e2898",40293:"188b2c3f",40701:"c7a732a6",40733:"32cab819",40830:"8c10284c",40916:"9faa28b3",41003:"c513ea13",41150:"54f1938d",41276:"b4ce0c08",41650:"87e23358",41847:"18e415a1",41890:"918a2cb0",41957:"872fd2cc",42008:"4baa50ab",42124:"29d2adbd",42181:"c63517e6",42355:"907b5d47",42573:"5e2ffde6",42793:"2246a342",42885:"597a5b93",42954:"982828f1",43600:"a6c32670",43726:"68f5efdb",43777:"5a399a38",43819:"675dae2a",44018:"8f65b8b4",44209:"28c163b6",44484:"2af5cc3b",44497:"ffa431fd",44588:"bf959556",44685:"2ee48679",44880:"015a15cd",44962:"d7b564f7",45208:"0272932e",45350:"fd8b516f",45841:"570201b8",45843:"a9a07245",45919:"4a338e93",45960:"7978ebf9",46294:"651bf1a2",46581:"d63d089d",46945:"11021670",47234:"a8b2d9e0",47328:"ba206b7c",47422:"6f8a62fd",47615:"2c0ce109",47629:"72d9f63d",47769:"fc73db0d",47834:"a88f922d",48124:"f3e92f58",48343:"b7f71889",48733:"59d26878",48890:"adb90665",48954:"ba099550",49313:"b13bff8e",49346:"6674f8cf",49486:"57020263",49549:"27827632",49567:"92eb0037",49871:"e1429d77",49907:"47cabb35",50030:"9189d3a0",50561:"77dfad07",51435:"20e8cb72",51537:"e2d07b22",51618:"c7cef798",51953:"4735510a",52021:"8d7b0aff",52486:"199db7e6",52603:"775aff17",52631:"4f55daff",52745:"ae807db1",52814:"0c690675",53111:"9d7b28ec",53302:"5849778f",53309:"a82ae674",53559:"12412e01",53587:"1fb9decf",53609:"a92abd6d",53685:"1f4e0d5f",53778:"682baded",54013:"a26125c3",54235:"8079012f",54487:"ad59b2d4",54709:"650cb9bc",54736:"3e402a46",54747:"f0beb7cd",54749:"392dc4ca",55035:"98dbe40d",55260:"5d41948f",55328:"0e766fb1",55480:"c3efb67c",55945:"f34b6a65",56025:"a3c35d87",56122:"5757629e",56248:"0b9a9c44",56364:"90eaed50",56370:"856183a4",56419:"49bee624",56615:"b2ed7291",56955:"d0daf666",56963:"98579cc6",56979:"a3e32621",57060:"eb1daae8",57103:"7ae80bb8",57145:"2ac314ed",57287:"67e9f784",57361:"9e1a42d7",57480:"e20af009",57573:"58f0fd4c",58e3:"cd2d1850",58634:"1b039a54",58729:"d9e7d269",59131:"6321bc6c",59273:"fd6dd25c",59469:"f796170e",59485:"b1365bd5",59728:"21c34987",59856:"05158744",59865:"5e11a3f2",60217:"16bcd99f",60377:"2d831025",60389:"835d02b6",60439:"933bd6f9",60679:"eb62ceaa",60946:"4cb32984",61304:"b5145ede",61528:"f4658bf4",61683:"510791da",61928:"e1f7a82f",61931:"7f952791",62062:"02a4c5ee",62536:"0e9efbf3",62726:"d4a8d49a",62746:"61728815",62954:"c0994e7f",63119:"bd396e75",63157:"fb4e705c",63453:"3a28774e",64131:"9dd0ebf3",64195:"07350901",64302:"b378118d",64364:"2ed66396",64549:"29ef3ede",64807:"4ae3099a",64814:"dd635f11",65010:"7c021cfb",65064:"e02beba7",65135:"e398eaec",65349:"e144c66d",65368:"a9c66679",65369:"04bd7c84",65649:"b62f9c6f",65858:"c176b875",65882:"a7d22042",65957:"fee0bf24",66073:"44a91d45",66334:"612fa150",67098:"623263b0",67112:"76622bed",67125:"6c8ed788",67140:"c47f094f",67328:"1b5bed7c",67365:"7b86ab6b",67396:"3148d21e",67673:"bae0b73d",67744:"90a92bd7",67813:"e6d17ef0",67818:"babc89ec",67821:"57c9faa1",67995:"2b2b3914",68005:"32aaf09a",68026:"f39c5846",68189:"974dced1",68224:"4795aaa2",68265:"63ef79da",68349:"079b6e78",68618:"c0280dcd",68724:"bd00f8e9",68755:"ff5fc04a",68960:"c8fcea47",69043:"5b3372ec",69113:"9a25faed",69184:"84eff599",69345:"a9a29a15",69360:"fb554b2a",69413:"4eb3fec6",69905:"b7945067",69998:"f655e642",70147:"1a3bf353",70207:"407299fe",70421:"36abd26a",70509:"d2d25df7",70520:"3cd3b2ef",70611:"856f10fd",70633:"85e93002",70838:"480c517b",71253:"2b0d6026",71360:"1a050205",71386:"c3817b5c",71525:"617f499c",71568:"de7550e1",71670:"a589435d",71723:"fd4e157c",71814:"56dd82a2",72069:"4c34905a",72145:"fa9f9929",72371:"94b0cd5c",72464:"2f3537e5",72474:"773f920d",72556:"237dc3b3",72841:"caffb96e",72939:"3a3441fd",73088:"2f2c0b3e",73091:"70e82282",73894:"9238f3c8",74010:"08c1f0b0",74123:"ea47ea58",74190:"7398e24f",74199:"1ea66b8c",74298:"a6a915f6",74318:"a04f57b5",74400:"78ed677d",74904:"dde48faf",75034:"bdf96616",75062:"ee60c5b9",75063:"f29d5448",75066:"bdcf5989",75212:"91e125de",75248:"c64c9475",75384:"ffa1d26f",75478:"3ee066fd",75647:"7059c2c1",76255:"1274d929",76413:"3c778b15",76559:"718e9bd1",76614:"c5f4c7d5",76780:"a2521cf6",76907:"e13d00cb",77183:"c0ad547e",77184:"5344e158",77665:"66d873f8",77769:"b98f4bd0",77771:"d3e7506f",77787:"55ad9510",78023:"91f04978",78297:"e4f53ff6",78301:"77cdbff5",78382:"6d65334c",78494:"05fed9af",78560:"ecc9e3d8",78880:"ba3defe8",78897:"d547a45e",79022:"887e7198",79046:"4a0cd362",79256:"2b88f421",79315:"6cf693ea",79376:"c29d26d4",79527:"bd63dac4",79639:"140e4410",79796:"3a32726b",80053:"abf3cb81",80371:"23ddacc4",80536:"6f369947",80693:"971642c7",80802:"240a9b32",80954:"eb30c055",81030:"57a47c8f",81188:"94bba1c6",81355:"c0630deb",81747:"1ced556a",81832:"82672c60",81981:"b924f531",82251:"f49cb2c9",82268:"27d906d5",82294:"49da49ee",82591:"a17d8a02",82946:"c0443f2e",83443:"eef9f70e",83540:"e709cdec",83667:"e6c21a7a",83771:"d9804327",83773:"006f8a90",83882:"7c359e50",83922:"b74510b1",84191:"8343448a",84453:"199639b4",84683:"528a792d",84769:"065e2485",84840:"380d1462",84857:"599bf366",84878:"be257491",85015:"6922a556",85064:"8f791a22",85185:"233e0254",85188:"a650d516",85228:"218217bc",85313:"9a50c753",85660:"064c8b88",85694:"07d821c8",85897:"41a11ee9",85953:"eeb2a562",86072:"5080c454",86098:"dd1b5cbc",86181:"fbf80418",86401:"48dafb8a",86451:"4f27bddb",86455:"61100b46",86948:"ab755430",87173:"05476b30",87306:"b725a1ab",87414:"a1d1b84b",87582:"d8c159ba",87655:"e65ff3fe",87658:"e5b03297",88042:"9fef88e7",88184:"4d0515ff",88856:"74871638",88935:"a09c52f8",89101:"32b7e8ad",89415:"b181847e",89645:"1108f5d1",89786:"5bd78ce4",89912:"34970590",89964:"1c2c8bd0",89987:"bac72195",90058:"71963b6b",90558:"b97b6728",90888:"2be72233",90951:"1622a070",91172:"4f311445",91233:"78e70798",91250:"2ee39d23",91538:"00df8c22",91919:"d8634b77",92416:"a19046b2",93056:"cdda519d",93065:"1213cde1",93387:"09b65a76",93519:"ed16d81d",93546:"8c92d65e",93610:"97e39690",93822:"e6a0ebb3",93903:"0b154eb3",94018:"b831695c",94089:"96e09e44",94091:"1b160458",94194:"4c05d3ad",94201:"e65fe66b",94215:"de9eb9e1",94229:"39be4c83",94319:"f653c4f9",94722:"974775bd",94900:"b353aada",94907:"b832eea5",95034:"a2e482de",95188:"d5c0ca2e",95190:"e5b131fa",95690:"fffc088f",96276:"7dc68782",96826:"e517860b",97482:"f5466d75",97889:"abe5362e",97900:"0c672f08",97920:"d5457aa2",98016:"75b6d8f9",98105:"1192fd1f",98276:"2904fbe2",98444:"ea450473",98509:"22a5087f",98623:"e4d949a9",98630:"a1951a5d",98666:"ef80b98e",98692:"74506fb9",98792:"68a0e6ce",99074:"a1d05c43",99156:"8926d233",99350:"d2165e86",99438:"d621c348",99533:"30301d9e",99875:"14b35e8a",99889:"c23c19b6",99959:"03d89ae8"}[e]+".js",t.miniCssF=e=>{},t.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),t.o=(e,f)=>Object.prototype.hasOwnProperty.call(e,f),a={},d="docusaurus-docs:",t.l=(e,f,b,c)=>{if(a[e])a[e].push(f);else{var r,o;if(void 0!==b)for(var n=document.getElementsByTagName("script"),i=0;i{r.onerror=r.onload=null,clearTimeout(l);var d=a[e];if(delete a[e],r.parentNode&&r.parentNode.removeChild(r),d&&d.forEach((e=>e(b))),f)return f(b)},l=setTimeout(s.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=s.bind(null,r.onerror),r.onload=s.bind(null,r.onload),o&&document.head.appendChild(r)}},t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),t.p="/docs/zh-TW/",t.gca=function(e){return e={20358428:"79527",26183636:"86072",38784009:"8156",46972690:"91233",55042936:"82268",68556356:"70207",68843839:"52745",73567145:"53587",79022373:"21493",99494472:"88935",a2a78cd2:"16","5df371ad":"17","575a2139":"288","4ef5f34b":"482",fb1a77b4:"520","3365bb5d":"547",bc8f9087:"930","3ef25e43":"1045",ee503142:"1046",ecc882d7:"1288","1ff2c95d":"1325","2be8d75a":"1369",f58086e5:"1669",e6847b95:"1770","4c5e977b":"1893",ed99de2c:"1972",f54e89d1:"2050","64e17396":"2143","8ba34e88":"2201","0c82f1cb":"2222",a596dc7e:"2269","652aa3bb":"2281",b7b09b70:"2487",faa6790b:"2751","655c39d2":"3300","2425c15c":"3507","3e441ee4":"3909","78ec6490":"4086","345d96d3":"4147","95ce3c59":"4193","93a1b6a2":"4746","98b08a7f":"4879","7cfe228b":"4993",bcd351e4:"5209","2ad4d3fa":"5569","7bb9f034":"5665",ba875990:"5805","4dab1df6":"5899","1f54c2ac":"6147",e628edd4:"6352",af2c52ce:"6542",fc169afb:"6576","4eb9b8ff":"6768","0393be11":"6907","833a1fde":"7338","179c9190":"7841",b760913b:"7848","136658e4":"8179","9755f20c":"8214","8d4600d0":"8392","401fb871":"8478",b76d73e0:"8718","6860968b":"8883","23b7e03a":"9087","0002f649":"9642","2eca92d8":"9706","14eb3368":"9817",d5ac6535:"9862","954c355d":"10040",a7d19085:"10235",fa570740:"10293",b71c170b:"10471",e8acd80e:"11013","7205acf7":"11053","988d8e24":"11119","7c3d9323":"11120","99aca8b2":"11434",d68165b9:"11500","5016f915":"11606","30de7014":"11762","0dfefb75":"11921",f34bbf22:"11968",e6b47cdb:"12319",ee2d7736:"12920",a4a7c88e:"12944","97600ac6":"13055","1f391b9e":"13085","74e68634":"13364",fdf22a50:"13408","08cdb8be":"13467",c668d467:"13586",bf60373a:"13667",f7318e59:"13845","643f775f":"13874",c5d3bb95:"14030","035fc0a7":"14188","0744e06b":"14243","2492320d":"14710",b9fef5ef:"14945",ee7f03d8:"15114","664d32ba":"15262",b82d00b2:"15365","2435c844":"15408",b568538e:"15772",f4c85b32:"15903",a42811bf:"16021","4e6201a8":"16039","8aab06bf":"16052","567ff302":"16175","1a7a3335":"16401",a19cf377:"16649","3d4af990":"16677",b43e4353:"16950","3f53f1c4":"16991",c4f64aee:"17175","4ef1736a":"17217",eaca4732:"17446","265355c2":"17661",d56e3bd7:"17929",f56ba7e1:"18085","0f2e9443":"18350","2be7eaec":"18387","762969cd":"18455","2bfafb22":"18471",c5a9135f:"18610","0004065d":"19063",c1adbe0b:"19122",f2bfa581:"19219","9f35e670":"19396","1912069b":"19423",f40511f8:"20183","1e049e66":"20202","05a3c259":"20367",ccaa939a:"21945","269c0fa1":"22043","89f7284f":"22190","2b25df32":"22477",cf587678:"22620",dac58f9a:"22821",f041af6f:"22982","6ac88df6":"23105","15df18f8":"23198","5b6fa4ec":"23349","9041aea1":"23389","935cb8db":"23563","98dd666f":"23656",b82293b3:"23733",bedf2929:"23747","642b1006":"23891","19b9d2d9":"23903","13696f7b":"24215",f552bd00:"24669",c54eca7f:"24697","92e11b3f":"24698",e9b84ed8:"24947","87897be6":"25090","7988f281":"25817","156751cf":"25968","302d24dc":"26467","5b788f5c":"26560","3326e4c4":"27000",d7ac3c03:"27078","49a0e813":"27079","92e99bf6":"27133","5036ec9d":"27188","68f233e4":"27507","89179ad6":"28135","094ce30e":"28155",b8161d6a:"28268",f7eb3a66:"28271",b052b80c:"28429",e31a16ba:"28751",d5f94c50:"28772","8c2621f5":"29010","1d8ede30":"29140","0ac7fcd1":"29513","1be78505":"29514","4c950052":"29538","38c90751":"29728","5dab34b6":"29776","6dd54b46":"30051","751792b8":"30321","24774f91":"30499",bc670d5c:"30561",e5d84bc0:"30601","124f7953":"30708",ecdb20a1:"30717",eeea228c:"31218",b2d0af62:"31287","3e301362":"31404","19b883ea":"31538","4f7dcb1e":"31640","8fbaa47b":"31657","86fd2478":"31833",b45ff73d:"31854","6870c8c4":"32446","6c46dea8":"32854","41ed4202":"33034","6131b9f8":"33232",afdda5b6:"33404",e35d3956:"33431",f5b6c895:"33451","786f71e5":"33509",c423df2e:"33790","10ca1dd8":"33887","1bc94aef":"33912","1e577d6c":"33949","1db637b2":"34346","3abccbcc":"34533","9c643b6e":"34756","70e3a7c5":"34826",b45cdd21:"35123",e7958aaa:"35226",eadead04:"35330","3635a766":"35424","41eb0037":"35708",eb050011:"35898",bc53881b:"35943",fcda79ce:"36137","8c3021dd":"36586",a6b8b35b:"36648","16dd13c1":"36733",e71641ea:"36904","86320adf":"37146","49541ebb":"37193",f6ef3039:"37442",dcc6b54d:"37486",a9bf2227:"37487",ab214d24:"37570","969753d7":"37742","5393ce94":"38270","917300a3":"38461","4f9fd89c":"38527",f7242226:"38601","7e40020f":"38818",a4a7a840:"39066","429a6f3e":"39229","01804294":"39494",fd867f7c:"39626","62547fbf":"39675","39f63e6a":"40081","7190026f":"40293","1ce0a301":"40701","6099ba0c":"40733",c343ef35:"40830",e4459066:"40916",d0d62bb5:"41003",fe26f94f:"41150",a6c72656:"41276",c7707dd8:"41650","82a30884":"41847","53fc083e":"41890",d69803c7:"41957","9e43e7b6":"42008","19357a65":"42124",be510d4c:"42181","2f504c6e":"42355",ce346131:"42573","35d5d226":"42793",acdbee8e:"42885","2814cf01":"42954","1dcc65e0":"43600","6b85e2ea":"43726",b9aefb1a:"43777",fc1db29b:"43819",d50a8def:"44018","278665dc":"44209","3cd952ae":"44484",d32e6b20:"44497","3c5750f8":"44588",f5c87087:"44685",e7d2e6f0:"44880","1c5f7d2b":"44962","034a556b":"45208",e8c60e9b:"45350","0c0bbaea":"45841",e4bacbbb:"45843","8070429a":"45919","5b3c1c53":"45960",db229a81:"46294",c2d91591:"46581",ae346411:"47234","6daf901a":"47328","1cf37028":"47422","84ebbbbf":"47615","0cd0cfa8":"47629","196fab6d":"47769","09be2ba2":"47834","553f321c":"48124","2c056d5d":"48343",d21505c8:"48733",d5603669:"48890",b0bdb7f3:"48954","79d1baac":"49313",b8919bdb:"49346",e72cf26a:"49486","48e0b5d4":"49549",f0cf672d:"49567",b2f83e6d:"49871",f2e41396:"49907",fd3dbbb4:"50030","254ac25b":"50561",fe2b089e:"51435","431ad29b":"51537","2cbe9533":"51618",c3e83a7d:"51953","25b6fab0":"52021",de127d6b:"52486",a4b6f3a5:"52603",c46f1db0:"52631","2cc833a8":"52814","203d8c37":"53111",cb8de75d:"53302","63ee150d":"53309",ebe9f683:"53559","81be975d":"53609","8c00b41d":"53685","2fa02bf3":"53778","2f5fda3e":"54013","695f8b9b":"54235","5ebc7423":"54487","2b93221c":"54709",a5463d8a:"54736","8acd050c":"54747",bf25430f:"54749",ea64ac1c:"55035","9e4d6f26":"55260","74c40fe4":"55328","006095b2":"55480","79aa13fb":"55945",c3aed80f:"56025",f5dc225c:"56122","8a1c8da1":"56248","281b126c":"56364","36f93d19":"56370","80e8986a":"56419",b4f4317d:"56615","51ca6efd":"56955","1b80e345":"56963",d005934a:"56979","4be15b13":"57060","77d0fddc":"57103","5c71c40a":"57145",bde9fb45:"57287","3e26f8b3":"57361",c86abbf7:"57480",e3e4fe7d:"57573",fbf4432e:"58000",e6a2b2bf:"58634",dbbfa97d:"58729","3b0223df":"59131",fcae69e8:"59273","68648e27":"59469",edfdb191:"59485",aa5bd2a7:"59728",e5c88a3e:"59856",e8ee0390:"59865","92ddf9a4":"60217","2d4599ae":"60377",a03d8b30:"60389",fca48710:"60439","353f52a3":"60679",bb292d37:"60946","8d5fe6f9":"61304","2b6f680f":"61528","86ce5bc1":"61683","15113e52":"61928","4c21dbbd":"61931","988ba51e":"62062","431b5d0e":"62536","748490a7":"62726","00468222":"62746","90305fb4":"62954",d7567838:"63119","586e3f5e":"63157","37da3438":"63453","52c1dace":"64131",c4f5d8e4:"64195","05c5421d":"64302","4bec54d5":"64364","788d9fe0":"64549","8a495097":"64807","8ade285d":"64814","877bdd66":"65010","4840c3eb":"65064","789f108c":"65135","796ce4fb":"65349",cc468388:"65368",c15b67f7:"65369","8047f3a3":"65649","1290c878":"65858","6aa5826c":"65882",e4627c87:"65957","97b92a45":"66073","3c39ccf9":"66334","6df78374":"67098","7196ee6c":"67112",ca3aabfb:"67125",e8b2d68f:"67140","137314dd":"67328","18f77871":"67365",a9dd1cc8:"67396","6eb57332":"67673","6ca8826f":"67744","8894256f":"67813",baa3212e:"67818",bcd02ebb:"67821",ff2d6dd8:"67995","73ce7b01":"68005",e63b451d:"68026","26e12baa":"68189","78bca219":"68224","389bb65e":"68265","3d3a07f6":"68349","88e3fe7e":"68618",a79a2e70:"68755","03cc88eb":"68960","9ad8637e":"69043",e8e02f59:"69113","30b61715":"69184","01a16f71":"69345","98a6b9c4":"69360","71063c2b":"69413",e23eefc0:"69905",b7cfb3da:"69998",b9535f14:"70147",a934672d:"70421","3b768736":"70509",e2df322b:"70520",fa114b0c:"70611",b50c9021:"70633","22bdf908":"70838","970a27d6":"71253","17b00a4a":"71360",b1892b20:"71386","3b7cd1e1":"71525","43cca846":"71568","6d8024b7":"71670","0328b0c9":"71723","57494db5":"72069",a5c74766:"72145","47c64002":"72371","8b8c4320":"72464",f9e1fd09:"72474","5614add0":"72556",bb0e99df:"72841",a626e327:"72939","955e06fd":"73088","04849bf5":"73091","9b6eea2c":"73894","37cea19d":"74010",a8654aa2:"74123","84cf2087":"74190","67db246e":"74199","48db5030":"74298",b8d9b1bd:"74318",aacc2fee:"74400",c0ad5dc6:"74904","30a22249":"75034",add4d791:"75062",cf69f832:"75063","466daf09":"75066","19b0499c":"75212",e82ff315:"75248","42bb1101":"75384","200e51df":"75478","2b3e7a7f":"75647","94a29094":"76255","777bd32a":"76413","93b78259":"76559","3f21c259":"76614",a208e2a5:"76907",a94c7dba:"77183","11b4dd89":"77184","97d979ce":"77665","60ea2d86":"77769","56a38f24":"77771","53bd4095":"77787","2b20c80a":"78023","71051dda":"78297","676afd3b":"78301","1a77ceda":"78382",e49348be:"78494",fd37922c:"78560","44befa6d":"78880","8a942fcc":"78897","9beaa53d":"79022","904cfab0":"79046",d2a246a6:"79256","378b1b2a":"79315","6249c7de":"79376","7cd86536":"79639",d2c4b928:"79796","935f2afb":"80053",c038b4a2:"80371","17c91901":"80536",cfc8b1e5:"80693","48d397c0":"80802",db449848:"80954",d312cf7c:"81030","476a319a":"81188","9ad476bb":"81355",f1e3befe:"81747",a8e44541:"81832",c8450cf2:"81981","989904ef":"82251","555d583b":"82294",de89bf85:"82591","3b83c135":"82946",f47c1d11:"83443","6500be67":"83540",ab4a8e8f:"83667","8c02dfd8":"83771","39c791a9":"83773","3a4337ef":"83882",cc806444:"83922",cf7f1202:"84191",fc15d889:"84453","25b7eef7":"84683","2f53b05f":"84769","2e4eadd3":"84840",b4eef555:"84857","2e8d4eda":"84878",f21b2fb0:"85015",d02b76f9:"85064",e1b9cf16:"85185",c0e80954:"85188","2fcb69bb":"85228","06848362":"85313","6dd1645f":"85660",db0d392c:"85694","6b3775fc":"85897",b700f6c8:"85953","149e5a51":"86098",a01bbcd4:"86181",fed0304a:"86401",f2a10594:"86451",e8c8f122:"86455",af7ab695:"86948","87a13df2":"87173",aebe3827:"87306","393be207":"87414","7fc0684b":"87582","40230f21":"87655","6dde3b76":"87658","5daee80f":"88042","87f76dec":"88184",e8351d64:"88856",e2c0c813:"89101","3f0d1ba4":"89415",e760b063:"89645",c1d23c47:"89786","75a6ad06":"89912",b82b3205:"89964","9ccbc3bf":"89987","24f02aa4":"90058","93f8b8b5":"90558","5c18dc43":"90888","76e9b4e1":"90951","864138a2":"91172","8758e270":"91250","0248575c":"91538",d51ffe49:"91919","726fea1f":"92416","73bfea73":"93056","812cb8ed":"93065","007a6c32":"93387","6f951ae3":"93519","1010372b":"93546",caba9b9f:"93610","7d52489f":"93822","5610cdb3":"93903","046df3c9":"94018",d9ffe17e:"94089","5c128c28":"94091","4b3e38af":"94194",d6b0fe44:"94201","189eacae":"94215",c8a044ba:"94229",d0816b53:"94319","5282f1c8":"94722","5787f6d3":"94900","29f28a73":"94907","64be7568":"95034",b42420f8:"95188",f8dc48d9:"95190",f4bc196f:"95690","8aadacf1":"96276","68f43c04":"96826","4a3e680b":"97482","02193fc8":"97889","954fe569":"97900","1a4e3797":"97920",ffb2e417:"98016",acc38ec3:"98105","2205312d":"98276",cc9c20e3:"98444","92ac5c16":"98509","394c74c3":"98623","68e9a632":"98630",f64e920b:"98666","67044a7a":"98692","0d6f57e0":"98792",e8646b2e:"99074",ff6e33f8:"99156","196bfd5c":"99350",b5511831:"99438",a6f4eced:"99533","57d9a11e":"99875",f56b8973:"99889",ebec70a2:"99959"}[e]||e,t.p+t.u(e)},(()=>{var e={51303:0,40532:0};t.f.j=(f,b)=>{var a=t.o(e,f)?e[f]:void 0;if(0!==a)if(a)b.push(a[2]);else if(/^(40532|51303)$/.test(f))e[f]=0;else{var d=new Promise(((b,d)=>a=e[f]=[b,d]));b.push(a[2]=d);var c=t.p+t.u(f),r=new Error;t.l(c,(b=>{if(t.o(e,f)&&(0!==(a=e[f])&&(e[f]=void 0),a)){var d=b&&("load"===b.type?"missing":b.type),c=b&&b.target&&b.target.src;r.message="Loading chunk "+f+" failed.\n("+d+": "+c+")",r.name="ChunkLoadError",r.type=d,r.request=c,a[1](r)}}),"chunk-"+f,f)}},t.O.j=f=>0===e[f];var f=(f,b)=>{var a,d,c=b[0],r=b[1],o=b[2],n=0;if(c.some((f=>0!==e[f]))){for(a in r)t.o(r,a)&&(t.m[a]=r[a]);if(o)var i=o(t)}for(f&&f(b);n{"use strict";var e,b,f,a,d,c={},r={};function t(e){var b=r[e];if(void 0!==b)return b.exports;var f=r[e]={id:e,loaded:!1,exports:{}};return c[e].call(f.exports,f,f.exports,t),f.loaded=!0,f.exports}t.m=c,e=[],t.O=(b,f,a,d)=>{if(!f){var c=1/0;for(i=0;i=d)&&Object.keys(t.O).every((e=>t.O[e](f[o])))?f.splice(o--,1):(r=!1,d0&&e[i-1][2]>d;i--)e[i]=e[i-1];e[i]=[f,a,d]},t.n=e=>{var b=e&&e.__esModule?()=>e.default:()=>e;return t.d(b,{a:b}),b},f=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,t.t=function(e,a){if(1&a&&(e=this(e)),8&a)return e;if("object"==typeof e&&e){if(4&a&&e.__esModule)return e;if(16&a&&"function"==typeof e.then)return e}var d=Object.create(null);t.r(d);var c={};b=b||[null,f({}),f([]),f(f)];for(var r=2&a&&e;"object"==typeof r&&!~b.indexOf(r);r=f(r))Object.getOwnPropertyNames(r).forEach((b=>c[b]=()=>e[b]));return c.default=()=>e,t.d(d,c),d},t.d=(e,b)=>{for(var f in b)t.o(b,f)&&!t.o(e,f)&&Object.defineProperty(e,f,{enumerable:!0,get:b[f]})},t.f={},t.e=e=>Promise.all(Object.keys(t.f).reduce(((b,f)=>(t.f[f](e,b),b)),[])),t.u=e=>"assets/js/"+({16:"a2a78cd2",17:"5df371ad",288:"575a2139",482:"4ef5f34b",520:"fb1a77b4",547:"3365bb5d",930:"bc8f9087",1045:"3ef25e43",1046:"ee503142",1288:"ecc882d7",1325:"1ff2c95d",1369:"2be8d75a",1669:"f58086e5",1770:"e6847b95",1893:"4c5e977b",1972:"ed99de2c",2050:"f54e89d1",2143:"64e17396",2201:"8ba34e88",2222:"0c82f1cb",2269:"a596dc7e",2281:"652aa3bb",2487:"b7b09b70",2751:"faa6790b",3300:"655c39d2",3507:"2425c15c",3909:"3e441ee4",4086:"78ec6490",4147:"345d96d3",4193:"95ce3c59",4746:"93a1b6a2",4879:"98b08a7f",4993:"7cfe228b",5209:"bcd351e4",5569:"2ad4d3fa",5665:"7bb9f034",5805:"ba875990",5899:"4dab1df6",6147:"1f54c2ac",6352:"e628edd4",6542:"af2c52ce",6576:"fc169afb",6768:"4eb9b8ff",6907:"0393be11",7338:"833a1fde",7841:"179c9190",7848:"b760913b",8156:"38784009",8179:"136658e4",8214:"9755f20c",8392:"8d4600d0",8478:"401fb871",8718:"b76d73e0",8883:"6860968b",9087:"23b7e03a",9642:"0002f649",9706:"2eca92d8",9817:"14eb3368",9862:"d5ac6535",10040:"954c355d",10235:"a7d19085",10293:"fa570740",10471:"b71c170b",11013:"e8acd80e",11053:"7205acf7",11119:"988d8e24",11120:"7c3d9323",11434:"99aca8b2",11500:"d68165b9",11606:"5016f915",11762:"30de7014",11921:"0dfefb75",11968:"f34bbf22",12319:"e6b47cdb",12920:"ee2d7736",12944:"a4a7c88e",13055:"97600ac6",13085:"1f391b9e",13364:"74e68634",13408:"fdf22a50",13467:"08cdb8be",13586:"c668d467",13667:"bf60373a",13845:"f7318e59",13874:"643f775f",14030:"c5d3bb95",14188:"035fc0a7",14243:"0744e06b",14710:"2492320d",14945:"b9fef5ef",15114:"ee7f03d8",15262:"664d32ba",15365:"b82d00b2",15408:"2435c844",15772:"b568538e",15903:"f4c85b32",16021:"a42811bf",16039:"4e6201a8",16052:"8aab06bf",16175:"567ff302",16401:"1a7a3335",16649:"a19cf377",16677:"3d4af990",16950:"b43e4353",16991:"3f53f1c4",17175:"c4f64aee",17217:"4ef1736a",17446:"eaca4732",17661:"265355c2",17929:"d56e3bd7",18085:"f56ba7e1",18350:"0f2e9443",18387:"2be7eaec",18455:"762969cd",18471:"2bfafb22",18610:"c5a9135f",19063:"0004065d",19122:"c1adbe0b",19219:"f2bfa581",19396:"9f35e670",19423:"1912069b",20183:"f40511f8",20202:"1e049e66",20367:"05a3c259",21493:"79022373",21945:"ccaa939a",22043:"269c0fa1",22190:"89f7284f",22477:"2b25df32",22620:"cf587678",22821:"dac58f9a",22982:"f041af6f",23105:"6ac88df6",23198:"15df18f8",23349:"5b6fa4ec",23389:"9041aea1",23563:"935cb8db",23656:"98dd666f",23733:"b82293b3",23747:"bedf2929",23891:"642b1006",23903:"19b9d2d9",24215:"13696f7b",24669:"f552bd00",24697:"c54eca7f",24698:"92e11b3f",24947:"e9b84ed8",25090:"87897be6",25817:"7988f281",25968:"156751cf",26467:"302d24dc",26560:"5b788f5c",27e3:"3326e4c4",27078:"d7ac3c03",27079:"49a0e813",27133:"92e99bf6",27188:"5036ec9d",27507:"68f233e4",28135:"89179ad6",28155:"094ce30e",28268:"b8161d6a",28271:"f7eb3a66",28429:"b052b80c",28751:"e31a16ba",28772:"d5f94c50",29010:"8c2621f5",29140:"1d8ede30",29513:"0ac7fcd1",29514:"1be78505",29538:"4c950052",29728:"38c90751",29776:"5dab34b6",30051:"6dd54b46",30321:"751792b8",30499:"24774f91",30561:"bc670d5c",30601:"e5d84bc0",30708:"124f7953",30717:"ecdb20a1",31218:"eeea228c",31287:"b2d0af62",31404:"3e301362",31538:"19b883ea",31640:"4f7dcb1e",31657:"8fbaa47b",31833:"86fd2478",31854:"b45ff73d",32446:"6870c8c4",32854:"6c46dea8",33034:"41ed4202",33232:"6131b9f8",33404:"afdda5b6",33431:"e35d3956",33451:"f5b6c895",33509:"786f71e5",33790:"c423df2e",33887:"10ca1dd8",33912:"1bc94aef",33949:"1e577d6c",34346:"1db637b2",34533:"3abccbcc",34756:"9c643b6e",34826:"70e3a7c5",35123:"b45cdd21",35226:"e7958aaa",35330:"eadead04",35424:"3635a766",35708:"41eb0037",35898:"eb050011",35943:"bc53881b",36137:"fcda79ce",36586:"8c3021dd",36648:"a6b8b35b",36733:"16dd13c1",36904:"e71641ea",37146:"86320adf",37193:"49541ebb",37442:"f6ef3039",37486:"dcc6b54d",37487:"a9bf2227",37570:"ab214d24",37742:"969753d7",38270:"5393ce94",38461:"917300a3",38527:"4f9fd89c",38601:"f7242226",38818:"7e40020f",39066:"a4a7a840",39229:"429a6f3e",39494:"01804294",39626:"fd867f7c",39675:"62547fbf",40081:"39f63e6a",40293:"7190026f",40701:"1ce0a301",40733:"6099ba0c",40830:"c343ef35",40916:"e4459066",41003:"d0d62bb5",41150:"fe26f94f",41276:"a6c72656",41650:"c7707dd8",41847:"82a30884",41890:"53fc083e",41957:"d69803c7",42008:"9e43e7b6",42124:"19357a65",42181:"be510d4c",42355:"2f504c6e",42573:"ce346131",42793:"35d5d226",42885:"acdbee8e",42954:"2814cf01",43600:"1dcc65e0",43726:"6b85e2ea",43777:"b9aefb1a",43819:"fc1db29b",44018:"d50a8def",44209:"278665dc",44484:"3cd952ae",44497:"d32e6b20",44588:"3c5750f8",44685:"f5c87087",44880:"e7d2e6f0",44962:"1c5f7d2b",45208:"034a556b",45350:"e8c60e9b",45841:"0c0bbaea",45843:"e4bacbbb",45919:"8070429a",45960:"5b3c1c53",46294:"db229a81",46581:"c2d91591",47234:"ae346411",47328:"6daf901a",47422:"1cf37028",47615:"84ebbbbf",47629:"0cd0cfa8",47769:"196fab6d",47834:"09be2ba2",48124:"553f321c",48343:"2c056d5d",48733:"d21505c8",48890:"d5603669",48954:"b0bdb7f3",49313:"79d1baac",49346:"b8919bdb",49486:"e72cf26a",49549:"48e0b5d4",49567:"f0cf672d",49871:"b2f83e6d",49907:"f2e41396",50030:"fd3dbbb4",50561:"254ac25b",51435:"fe2b089e",51537:"431ad29b",51618:"2cbe9533",51953:"c3e83a7d",52021:"25b6fab0",52486:"de127d6b",52603:"a4b6f3a5",52631:"c46f1db0",52745:"68843839",52814:"2cc833a8",53111:"203d8c37",53302:"cb8de75d",53309:"63ee150d",53559:"ebe9f683",53587:"73567145",53609:"81be975d",53685:"8c00b41d",53778:"2fa02bf3",54013:"2f5fda3e",54235:"695f8b9b",54487:"5ebc7423",54709:"2b93221c",54736:"a5463d8a",54747:"8acd050c",54749:"bf25430f",55035:"ea64ac1c",55260:"9e4d6f26",55328:"74c40fe4",55480:"006095b2",55945:"79aa13fb",56025:"c3aed80f",56122:"f5dc225c",56248:"8a1c8da1",56364:"281b126c",56370:"36f93d19",56419:"80e8986a",56615:"b4f4317d",56955:"51ca6efd",56963:"1b80e345",56979:"d005934a",57060:"4be15b13",57103:"77d0fddc",57145:"5c71c40a",57287:"bde9fb45",57361:"3e26f8b3",57480:"c86abbf7",57573:"e3e4fe7d",58e3:"fbf4432e",58634:"e6a2b2bf",58729:"dbbfa97d",59131:"3b0223df",59273:"fcae69e8",59469:"68648e27",59485:"edfdb191",59728:"aa5bd2a7",59856:"e5c88a3e",59865:"e8ee0390",60217:"92ddf9a4",60377:"2d4599ae",60389:"a03d8b30",60439:"fca48710",60679:"353f52a3",60946:"bb292d37",61304:"8d5fe6f9",61528:"2b6f680f",61683:"86ce5bc1",61928:"15113e52",61931:"4c21dbbd",62062:"988ba51e",62536:"431b5d0e",62726:"748490a7",62746:"00468222",62954:"90305fb4",63119:"d7567838",63157:"586e3f5e",63453:"37da3438",64131:"52c1dace",64195:"c4f5d8e4",64302:"05c5421d",64364:"4bec54d5",64549:"788d9fe0",64807:"8a495097",64814:"8ade285d",65010:"877bdd66",65064:"4840c3eb",65135:"789f108c",65349:"796ce4fb",65368:"cc468388",65369:"c15b67f7",65649:"8047f3a3",65858:"1290c878",65882:"6aa5826c",65957:"e4627c87",66073:"97b92a45",66334:"3c39ccf9",67098:"6df78374",67112:"7196ee6c",67125:"ca3aabfb",67140:"e8b2d68f",67328:"137314dd",67365:"18f77871",67396:"a9dd1cc8",67673:"6eb57332",67744:"6ca8826f",67813:"8894256f",67818:"baa3212e",67821:"bcd02ebb",67995:"ff2d6dd8",68005:"73ce7b01",68026:"e63b451d",68189:"26e12baa",68224:"78bca219",68265:"389bb65e",68349:"3d3a07f6",68618:"88e3fe7e",68755:"a79a2e70",68960:"03cc88eb",69043:"9ad8637e",69113:"e8e02f59",69184:"30b61715",69345:"01a16f71",69360:"98a6b9c4",69413:"71063c2b",69905:"e23eefc0",69998:"b7cfb3da",70147:"b9535f14",70207:"68556356",70421:"a934672d",70509:"3b768736",70520:"e2df322b",70611:"fa114b0c",70633:"b50c9021",70838:"22bdf908",71253:"970a27d6",71360:"17b00a4a",71386:"b1892b20",71525:"3b7cd1e1",71568:"43cca846",71670:"6d8024b7",71723:"0328b0c9",72069:"57494db5",72145:"a5c74766",72371:"47c64002",72464:"8b8c4320",72474:"f9e1fd09",72556:"5614add0",72841:"bb0e99df",72939:"a626e327",73088:"955e06fd",73091:"04849bf5",73894:"9b6eea2c",74010:"37cea19d",74123:"a8654aa2",74190:"84cf2087",74199:"67db246e",74298:"48db5030",74318:"b8d9b1bd",74400:"aacc2fee",74904:"c0ad5dc6",75034:"30a22249",75062:"add4d791",75063:"cf69f832",75066:"466daf09",75212:"19b0499c",75248:"e82ff315",75384:"42bb1101",75478:"200e51df",75647:"2b3e7a7f",76255:"94a29094",76413:"777bd32a",76559:"93b78259",76614:"3f21c259",76907:"a208e2a5",77183:"a94c7dba",77184:"11b4dd89",77665:"97d979ce",77769:"60ea2d86",77771:"56a38f24",77787:"53bd4095",78023:"2b20c80a",78297:"71051dda",78301:"676afd3b",78382:"1a77ceda",78494:"e49348be",78560:"fd37922c",78880:"44befa6d",78897:"8a942fcc",79022:"9beaa53d",79046:"904cfab0",79256:"d2a246a6",79315:"378b1b2a",79376:"6249c7de",79527:"20358428",79639:"7cd86536",79796:"d2c4b928",80053:"935f2afb",80371:"c038b4a2",80536:"17c91901",80693:"cfc8b1e5",80802:"48d397c0",80954:"db449848",81030:"d312cf7c",81188:"476a319a",81355:"9ad476bb",81747:"f1e3befe",81832:"a8e44541",81981:"c8450cf2",82251:"989904ef",82268:"55042936",82294:"555d583b",82591:"de89bf85",82946:"3b83c135",83443:"f47c1d11",83540:"6500be67",83667:"ab4a8e8f",83771:"8c02dfd8",83773:"39c791a9",83882:"3a4337ef",83922:"cc806444",84191:"cf7f1202",84453:"fc15d889",84683:"25b7eef7",84769:"2f53b05f",84840:"2e4eadd3",84857:"b4eef555",84878:"2e8d4eda",85015:"f21b2fb0",85064:"d02b76f9",85185:"e1b9cf16",85188:"c0e80954",85228:"2fcb69bb",85313:"06848362",85660:"6dd1645f",85694:"db0d392c",85897:"6b3775fc",85953:"b700f6c8",86072:"26183636",86098:"149e5a51",86181:"a01bbcd4",86401:"fed0304a",86451:"f2a10594",86455:"e8c8f122",86948:"af7ab695",87173:"87a13df2",87306:"aebe3827",87414:"393be207",87582:"7fc0684b",87655:"40230f21",87658:"6dde3b76",88042:"5daee80f",88184:"87f76dec",88856:"e8351d64",88935:"99494472",89101:"e2c0c813",89415:"3f0d1ba4",89645:"e760b063",89786:"c1d23c47",89912:"75a6ad06",89964:"b82b3205",89987:"9ccbc3bf",90058:"24f02aa4",90558:"93f8b8b5",90888:"5c18dc43",90951:"76e9b4e1",91172:"864138a2",91233:"46972690",91250:"8758e270",91538:"0248575c",91919:"d51ffe49",92416:"726fea1f",93056:"73bfea73",93065:"812cb8ed",93387:"007a6c32",93519:"6f951ae3",93546:"1010372b",93610:"caba9b9f",93822:"7d52489f",93903:"5610cdb3",94018:"046df3c9",94089:"d9ffe17e",94091:"5c128c28",94194:"4b3e38af",94201:"d6b0fe44",94215:"189eacae",94229:"c8a044ba",94319:"d0816b53",94722:"5282f1c8",94900:"5787f6d3",94907:"29f28a73",95034:"64be7568",95188:"b42420f8",95190:"f8dc48d9",95690:"f4bc196f",96276:"8aadacf1",96826:"68f43c04",97482:"4a3e680b",97889:"02193fc8",97900:"954fe569",97920:"1a4e3797",98016:"ffb2e417",98105:"acc38ec3",98276:"2205312d",98444:"cc9c20e3",98509:"92ac5c16",98623:"394c74c3",98630:"68e9a632",98666:"f64e920b",98692:"67044a7a",98792:"0d6f57e0",99074:"e8646b2e",99156:"ff6e33f8",99350:"196bfd5c",99438:"b5511831",99533:"a6f4eced",99875:"57d9a11e",99889:"f56b8973",99959:"ebec70a2"}[e]||e)+"."+{16:"95e0997a",17:"ed5abb28",288:"33a85255",482:"59ff1c0e",520:"1e46e45b",547:"9305bdd4",930:"68112f0d",1045:"2e5edf24",1046:"d713be58",1288:"3d55ced1",1325:"36daf010",1369:"f97380b2",1669:"7c92e3ef",1770:"33a46207",1893:"4a98b5fe",1972:"3767f63a",2050:"7b453b74",2143:"6cedb54a",2201:"ad3df26d",2222:"ec9f034c",2269:"bd53496e",2281:"c533a6a9",2487:"2b476883",2751:"5c44f3e3",3300:"56abba7d",3507:"3145d6a9",3909:"d63592c0",4086:"6391b158",4147:"4db3769d",4193:"2d5c593a",4746:"9948c140",4879:"84274f1c",4972:"c1e0c51c",4993:"3fe34bb0",5209:"ffef8faa",5569:"b2bf6d68",5665:"d466007a",5805:"57eba598",5899:"fc5291bb",6147:"eb09fe54",6338:"b6c9a516",6352:"5d14f184",6542:"a4de5f7b",6576:"ab962437",6768:"5e0b70d5",6907:"286e36f7",7338:"2c210096",7841:"67e1419a",7848:"4c2aa69e",8156:"2d6a320e",8179:"350c6a2c",8214:"b6746997",8392:"35ef4166",8478:"7bac00a3",8718:"a7889de4",8883:"ddf92a47",9087:"4957ed1d",9642:"6869b485",9706:"349d0471",9799:"cdb5b12a",9817:"f9d79ca6",9862:"33c1d656",10040:"efab490a",10235:"ab4f13c3",10293:"6cceee53",10471:"5fe12cb7",11013:"ade95505",11053:"531ec399",11119:"734ff14a",11120:"935a1320",11434:"799e8557",11500:"da44a65e",11606:"56683491",11762:"9448562a",11921:"da387b1f",11968:"a755f5af",12319:"7d20f0da",12920:"d03eea4e",12944:"2add0bd9",13055:"65361055",13085:"74c4de50",13364:"6afac0b7",13408:"2e25889f",13467:"d658b843",13586:"8c682e32",13667:"8d362cf8",13845:"3c3b327f",13874:"f9d065b6",14030:"57c1e1f4",14188:"09ab5b8d",14243:"e3763bcb",14710:"b8be2c99",14945:"55a1da25",15114:"4bf1aaa7",15262:"c9098fcb",15365:"45578418",15408:"b511830f",15772:"edae0608",15903:"08ac177d",16021:"e645f895",16039:"38a142bf",16052:"bc5fd83f",16175:"12751b0b",16401:"c743db5b",16649:"8a2a38f3",16677:"10a87717",16950:"6054afa1",16991:"82fcf322",17175:"d885a1cf",17217:"7e67cf71",17446:"ab51932f",17661:"0f5a68ec",17929:"bfd49b0b",18085:"2d3b6630",18350:"af482d40",18387:"e5c6f0ed",18455:"262e8aee",18471:"e7a7dd5f",18610:"8a8f909a",18894:"2da9821d",19063:"8389be42",19122:"48bf3aff",19219:"8a00ddc5",19396:"e4d6fd46",19423:"6ee26968",20183:"258ccbd0",20202:"2a93bb92",20367:"e00fbdaa",21493:"56dc5cff",21945:"c3855c24",22043:"ee188a85",22190:"8252be8d",22477:"a26ee541",22620:"7883a084",22761:"365a347a",22821:"8f42977b",22982:"ac9e007a",23105:"63d5d573",23198:"09670e1a",23349:"c40a6a59",23389:"f05fa93a",23563:"143e8437",23656:"d3c2b7e5",23733:"3abb3db5",23747:"2cb9229a",23891:"142c057e",23903:"0f444c6c",24215:"b033301b",24669:"e5147b47",24697:"4956e563",24698:"cafbaf96",24947:"6da1c2c1",25090:"a928e25d",25817:"a09a6bc8",25968:"8988001f",26467:"59a420c1",26560:"d5cc94c4",27e3:"b6946233",27078:"f6c4a7ff",27079:"f2221d2a",27133:"20e10a7b",27188:"787c6412",27507:"e3274b92",28135:"68b3b465",28155:"e5eb2a4b",28268:"c2ebb553",28271:"798bcbda",28429:"1399b650",28751:"a3f317d7",28772:"d9b16730",29010:"1941991d",29140:"080e50b9",29513:"760b6e5b",29514:"e4bcc747",29538:"8ebe6590",29728:"651a8f72",29776:"49e857bf",30051:"fc3a747d",30321:"fb4aba14",30499:"37a4a9be",30561:"039f452c",30601:"6cd65da7",30708:"4fc498e6",30717:"467f93e7",31218:"00a3b7fc",31287:"9c6d9c6d",31404:"81c31d94",31538:"f7fbf7d0",31640:"59558e17",31657:"78307e2b",31833:"b2b7fa8e",31854:"e06feffa",32446:"2ed3abb0",32854:"ddf29eef",33034:"dbadc1fd",33232:"2f974a7f",33404:"a71820ed",33431:"52e788b4",33451:"7ae801f2",33509:"8d723cab",33790:"d0c835a8",33887:"17393ec9",33912:"edf434b6",33949:"e23a7733",34346:"1c8bba18",34533:"15d33a5b",34756:"b9a1b5f0",34826:"c819b9d0",35123:"365f8e55",35226:"c1a6f8ac",35330:"0efdba7e",35424:"a0ae2d81",35708:"3302f660",35898:"fbfd559c",35943:"dbdd3cbe",36137:"46710853",36586:"7b9a86d2",36648:"96e68b71",36733:"0f6d9905",36904:"692a4593",37146:"95a5b1ed",37193:"9b715ee1",37442:"855253b6",37486:"30e1048f",37487:"77385b9d",37570:"f06e7349",37742:"6df71594",38270:"47996dae",38461:"436fd90f",38527:"4e989100",38601:"2994690a",38818:"8675c575",39066:"b79135f9",39229:"c2d088d4",39494:"7fd53958",39626:"87b8e7f0",39675:"705b00c7",40081:"9a9e2898",40293:"188b2c3f",40701:"c7a732a6",40733:"32cab819",40830:"8c10284c",40916:"9faa28b3",41003:"c513ea13",41150:"54f1938d",41276:"b4ce0c08",41650:"87e23358",41847:"18e415a1",41890:"918a2cb0",41957:"872fd2cc",42008:"4baa50ab",42124:"29d2adbd",42181:"c63517e6",42355:"907b5d47",42573:"5e2ffde6",42793:"2246a342",42885:"597a5b93",42954:"982828f1",43600:"a6c32670",43726:"68f5efdb",43777:"5a399a38",43819:"675dae2a",44018:"8f65b8b4",44209:"28c163b6",44484:"2af5cc3b",44497:"ffa431fd",44588:"bf959556",44685:"2ee48679",44880:"015a15cd",44962:"d7b564f7",45208:"0272932e",45350:"fd8b516f",45841:"570201b8",45843:"a9a07245",45919:"4a338e93",45960:"7978ebf9",46294:"651bf1a2",46581:"d63d089d",46945:"11021670",47234:"a8b2d9e0",47328:"ba206b7c",47422:"6f8a62fd",47615:"2c0ce109",47629:"72d9f63d",47769:"fc73db0d",47834:"a88f922d",48124:"f3e92f58",48343:"b7f71889",48733:"59d26878",48890:"adb90665",48954:"ba099550",49313:"b13bff8e",49346:"6674f8cf",49486:"57020263",49549:"27827632",49567:"92eb0037",49871:"e1429d77",49907:"47cabb35",50030:"9189d3a0",50561:"77dfad07",51435:"20e8cb72",51537:"e2d07b22",51618:"c7cef798",51953:"4735510a",52021:"8d7b0aff",52486:"199db7e6",52603:"775aff17",52631:"4f55daff",52745:"ae807db1",52814:"0c690675",53111:"9d7b28ec",53302:"5849778f",53309:"a82ae674",53559:"12412e01",53587:"1fb9decf",53609:"a92abd6d",53685:"1f4e0d5f",53778:"682baded",54013:"a26125c3",54235:"8079012f",54487:"ad59b2d4",54709:"650cb9bc",54736:"3e402a46",54747:"f0beb7cd",54749:"392dc4ca",55035:"98dbe40d",55260:"5d41948f",55328:"0e766fb1",55480:"c3efb67c",55945:"f34b6a65",56025:"a3c35d87",56122:"5757629e",56248:"0b9a9c44",56364:"90eaed50",56370:"856183a4",56419:"49bee624",56615:"b2ed7291",56955:"d0daf666",56963:"98579cc6",56979:"a3e32621",57060:"eb1daae8",57103:"7ae80bb8",57145:"2ac314ed",57287:"67e9f784",57361:"9e1a42d7",57480:"e20af009",57573:"58f0fd4c",58e3:"cd2d1850",58634:"1b039a54",58729:"d9e7d269",59131:"6321bc6c",59273:"fd6dd25c",59469:"f796170e",59485:"b1365bd5",59728:"21c34987",59856:"05158744",59865:"5e11a3f2",60217:"16bcd99f",60377:"2d831025",60389:"835d02b6",60439:"933bd6f9",60679:"eb62ceaa",60946:"4cb32984",61304:"b5145ede",61528:"f4658bf4",61683:"510791da",61928:"e1f7a82f",61931:"7f952791",62062:"02a4c5ee",62536:"0e9efbf3",62726:"d4a8d49a",62746:"61728815",62954:"c0994e7f",63119:"bd396e75",63157:"fb4e705c",63453:"3a28774e",64131:"9dd0ebf3",64195:"07350901",64302:"b378118d",64364:"2ed66396",64549:"29ef3ede",64807:"4ae3099a",64814:"dd635f11",65010:"7c021cfb",65064:"e02beba7",65135:"e398eaec",65349:"e144c66d",65368:"a9c66679",65369:"04bd7c84",65649:"b62f9c6f",65858:"c176b875",65882:"a7d22042",65957:"fee0bf24",66073:"44a91d45",66334:"612fa150",67098:"623263b0",67112:"76622bed",67125:"6c8ed788",67140:"c47f094f",67328:"1b5bed7c",67365:"7b86ab6b",67396:"3148d21e",67673:"bae0b73d",67744:"90a92bd7",67813:"e6d17ef0",67818:"babc89ec",67821:"57c9faa1",67995:"2b2b3914",68005:"32aaf09a",68026:"f39c5846",68189:"974dced1",68224:"4795aaa2",68265:"63ef79da",68349:"079b6e78",68618:"c0280dcd",68724:"bd00f8e9",68755:"ff5fc04a",68960:"c8fcea47",69043:"5b3372ec",69113:"9a25faed",69184:"84eff599",69345:"a9a29a15",69360:"fb554b2a",69413:"4eb3fec6",69905:"b7945067",69998:"f655e642",70147:"1a3bf353",70207:"407299fe",70421:"36abd26a",70509:"d2d25df7",70520:"3cd3b2ef",70611:"856f10fd",70633:"85e93002",70838:"480c517b",71253:"2b0d6026",71360:"1a050205",71386:"c3817b5c",71525:"617f499c",71568:"de7550e1",71670:"a589435d",71723:"fd4e157c",71814:"56dd82a2",72069:"4c34905a",72145:"fa9f9929",72371:"94b0cd5c",72464:"2f3537e5",72474:"773f920d",72556:"237dc3b3",72841:"caffb96e",72939:"3a3441fd",73088:"2f2c0b3e",73091:"70e82282",73894:"9238f3c8",74010:"08c1f0b0",74123:"ea47ea58",74190:"7398e24f",74199:"1ea66b8c",74298:"a6a915f6",74318:"a04f57b5",74400:"78ed677d",74904:"dde48faf",75034:"bdf96616",75062:"ee60c5b9",75063:"f29d5448",75066:"bdcf5989",75212:"91e125de",75248:"c64c9475",75384:"ffa1d26f",75478:"3ee066fd",75647:"7059c2c1",76255:"1274d929",76413:"3c778b15",76559:"718e9bd1",76614:"c5f4c7d5",76780:"a2521cf6",76907:"e13d00cb",77183:"c0ad547e",77184:"5344e158",77665:"66d873f8",77769:"b98f4bd0",77771:"d3e7506f",77787:"55ad9510",78023:"91f04978",78297:"e4f53ff6",78301:"77cdbff5",78382:"6d65334c",78494:"05fed9af",78560:"ecc9e3d8",78880:"ba3defe8",78897:"d547a45e",79022:"887e7198",79046:"4a0cd362",79256:"2b88f421",79315:"6cf693ea",79376:"c29d26d4",79527:"bd63dac4",79639:"140e4410",79796:"3a32726b",80053:"abf3cb81",80371:"23ddacc4",80536:"6f369947",80693:"971642c7",80802:"240a9b32",80954:"eb30c055",81030:"57a47c8f",81188:"94bba1c6",81355:"c0630deb",81747:"1ced556a",81832:"82672c60",81981:"b924f531",82251:"f49cb2c9",82268:"27d906d5",82294:"49da49ee",82591:"a17d8a02",82946:"c0443f2e",83443:"eef9f70e",83540:"e709cdec",83667:"e6c21a7a",83771:"d9804327",83773:"006f8a90",83882:"7c359e50",83922:"b74510b1",84191:"8343448a",84453:"199639b4",84683:"528a792d",84769:"065e2485",84840:"380d1462",84857:"599bf366",84878:"be257491",85015:"6922a556",85064:"8f791a22",85185:"233e0254",85188:"a650d516",85228:"218217bc",85313:"9a50c753",85660:"064c8b88",85694:"07d821c8",85897:"41a11ee9",85953:"eeb2a562",86072:"5080c454",86098:"dd1b5cbc",86181:"fbf80418",86401:"48dafb8a",86451:"4f27bddb",86455:"61100b46",86948:"ab755430",87173:"05476b30",87306:"b725a1ab",87414:"a1d1b84b",87582:"d8c159ba",87655:"e65ff3fe",87658:"e5b03297",88042:"9fef88e7",88184:"4d0515ff",88856:"74871638",88935:"a09c52f8",89101:"32b7e8ad",89415:"b181847e",89645:"1108f5d1",89786:"5bd78ce4",89912:"34970590",89964:"1c2c8bd0",89987:"bac72195",90058:"71963b6b",90558:"b97b6728",90888:"2be72233",90951:"1622a070",91172:"4f311445",91233:"78e70798",91250:"2ee39d23",91538:"00df8c22",91919:"d8634b77",92416:"a19046b2",93056:"cdda519d",93065:"1213cde1",93387:"09b65a76",93519:"ed16d81d",93546:"8c92d65e",93610:"97e39690",93822:"e6a0ebb3",93903:"0b154eb3",94018:"b831695c",94089:"96e09e44",94091:"1b160458",94194:"4c05d3ad",94201:"e65fe66b",94215:"de9eb9e1",94229:"39be4c83",94319:"f653c4f9",94722:"974775bd",94900:"43db6b6b",94907:"b832eea5",95034:"a2e482de",95188:"d5c0ca2e",95190:"e5b131fa",95690:"fffc088f",96276:"7dc68782",96826:"e517860b",97482:"f5466d75",97889:"abe5362e",97900:"0c672f08",97920:"d5457aa2",98016:"75b6d8f9",98105:"1192fd1f",98276:"2904fbe2",98444:"ea450473",98509:"22a5087f",98623:"e4d949a9",98630:"a1951a5d",98666:"ef80b98e",98692:"74506fb9",98792:"68a0e6ce",99074:"a1d05c43",99156:"8926d233",99350:"d2165e86",99438:"d621c348",99533:"30301d9e",99875:"14b35e8a",99889:"c23c19b6",99959:"03d89ae8"}[e]+".js",t.miniCssF=e=>{},t.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),t.o=(e,b)=>Object.prototype.hasOwnProperty.call(e,b),a={},d="docusaurus-docs:",t.l=(e,b,f,c)=>{if(a[e])a[e].push(b);else{var r,o;if(void 0!==f)for(var n=document.getElementsByTagName("script"),i=0;i{r.onerror=r.onload=null,clearTimeout(l);var d=a[e];if(delete a[e],r.parentNode&&r.parentNode.removeChild(r),d&&d.forEach((e=>e(f))),b)return b(f)},l=setTimeout(s.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=s.bind(null,r.onerror),r.onload=s.bind(null,r.onload),o&&document.head.appendChild(r)}},t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),t.p="/docs/zh-TW/",t.gca=function(e){return e={20358428:"79527",26183636:"86072",38784009:"8156",46972690:"91233",55042936:"82268",68556356:"70207",68843839:"52745",73567145:"53587",79022373:"21493",99494472:"88935",a2a78cd2:"16","5df371ad":"17","575a2139":"288","4ef5f34b":"482",fb1a77b4:"520","3365bb5d":"547",bc8f9087:"930","3ef25e43":"1045",ee503142:"1046",ecc882d7:"1288","1ff2c95d":"1325","2be8d75a":"1369",f58086e5:"1669",e6847b95:"1770","4c5e977b":"1893",ed99de2c:"1972",f54e89d1:"2050","64e17396":"2143","8ba34e88":"2201","0c82f1cb":"2222",a596dc7e:"2269","652aa3bb":"2281",b7b09b70:"2487",faa6790b:"2751","655c39d2":"3300","2425c15c":"3507","3e441ee4":"3909","78ec6490":"4086","345d96d3":"4147","95ce3c59":"4193","93a1b6a2":"4746","98b08a7f":"4879","7cfe228b":"4993",bcd351e4:"5209","2ad4d3fa":"5569","7bb9f034":"5665",ba875990:"5805","4dab1df6":"5899","1f54c2ac":"6147",e628edd4:"6352",af2c52ce:"6542",fc169afb:"6576","4eb9b8ff":"6768","0393be11":"6907","833a1fde":"7338","179c9190":"7841",b760913b:"7848","136658e4":"8179","9755f20c":"8214","8d4600d0":"8392","401fb871":"8478",b76d73e0:"8718","6860968b":"8883","23b7e03a":"9087","0002f649":"9642","2eca92d8":"9706","14eb3368":"9817",d5ac6535:"9862","954c355d":"10040",a7d19085:"10235",fa570740:"10293",b71c170b:"10471",e8acd80e:"11013","7205acf7":"11053","988d8e24":"11119","7c3d9323":"11120","99aca8b2":"11434",d68165b9:"11500","5016f915":"11606","30de7014":"11762","0dfefb75":"11921",f34bbf22:"11968",e6b47cdb:"12319",ee2d7736:"12920",a4a7c88e:"12944","97600ac6":"13055","1f391b9e":"13085","74e68634":"13364",fdf22a50:"13408","08cdb8be":"13467",c668d467:"13586",bf60373a:"13667",f7318e59:"13845","643f775f":"13874",c5d3bb95:"14030","035fc0a7":"14188","0744e06b":"14243","2492320d":"14710",b9fef5ef:"14945",ee7f03d8:"15114","664d32ba":"15262",b82d00b2:"15365","2435c844":"15408",b568538e:"15772",f4c85b32:"15903",a42811bf:"16021","4e6201a8":"16039","8aab06bf":"16052","567ff302":"16175","1a7a3335":"16401",a19cf377:"16649","3d4af990":"16677",b43e4353:"16950","3f53f1c4":"16991",c4f64aee:"17175","4ef1736a":"17217",eaca4732:"17446","265355c2":"17661",d56e3bd7:"17929",f56ba7e1:"18085","0f2e9443":"18350","2be7eaec":"18387","762969cd":"18455","2bfafb22":"18471",c5a9135f:"18610","0004065d":"19063",c1adbe0b:"19122",f2bfa581:"19219","9f35e670":"19396","1912069b":"19423",f40511f8:"20183","1e049e66":"20202","05a3c259":"20367",ccaa939a:"21945","269c0fa1":"22043","89f7284f":"22190","2b25df32":"22477",cf587678:"22620",dac58f9a:"22821",f041af6f:"22982","6ac88df6":"23105","15df18f8":"23198","5b6fa4ec":"23349","9041aea1":"23389","935cb8db":"23563","98dd666f":"23656",b82293b3:"23733",bedf2929:"23747","642b1006":"23891","19b9d2d9":"23903","13696f7b":"24215",f552bd00:"24669",c54eca7f:"24697","92e11b3f":"24698",e9b84ed8:"24947","87897be6":"25090","7988f281":"25817","156751cf":"25968","302d24dc":"26467","5b788f5c":"26560","3326e4c4":"27000",d7ac3c03:"27078","49a0e813":"27079","92e99bf6":"27133","5036ec9d":"27188","68f233e4":"27507","89179ad6":"28135","094ce30e":"28155",b8161d6a:"28268",f7eb3a66:"28271",b052b80c:"28429",e31a16ba:"28751",d5f94c50:"28772","8c2621f5":"29010","1d8ede30":"29140","0ac7fcd1":"29513","1be78505":"29514","4c950052":"29538","38c90751":"29728","5dab34b6":"29776","6dd54b46":"30051","751792b8":"30321","24774f91":"30499",bc670d5c:"30561",e5d84bc0:"30601","124f7953":"30708",ecdb20a1:"30717",eeea228c:"31218",b2d0af62:"31287","3e301362":"31404","19b883ea":"31538","4f7dcb1e":"31640","8fbaa47b":"31657","86fd2478":"31833",b45ff73d:"31854","6870c8c4":"32446","6c46dea8":"32854","41ed4202":"33034","6131b9f8":"33232",afdda5b6:"33404",e35d3956:"33431",f5b6c895:"33451","786f71e5":"33509",c423df2e:"33790","10ca1dd8":"33887","1bc94aef":"33912","1e577d6c":"33949","1db637b2":"34346","3abccbcc":"34533","9c643b6e":"34756","70e3a7c5":"34826",b45cdd21:"35123",e7958aaa:"35226",eadead04:"35330","3635a766":"35424","41eb0037":"35708",eb050011:"35898",bc53881b:"35943",fcda79ce:"36137","8c3021dd":"36586",a6b8b35b:"36648","16dd13c1":"36733",e71641ea:"36904","86320adf":"37146","49541ebb":"37193",f6ef3039:"37442",dcc6b54d:"37486",a9bf2227:"37487",ab214d24:"37570","969753d7":"37742","5393ce94":"38270","917300a3":"38461","4f9fd89c":"38527",f7242226:"38601","7e40020f":"38818",a4a7a840:"39066","429a6f3e":"39229","01804294":"39494",fd867f7c:"39626","62547fbf":"39675","39f63e6a":"40081","7190026f":"40293","1ce0a301":"40701","6099ba0c":"40733",c343ef35:"40830",e4459066:"40916",d0d62bb5:"41003",fe26f94f:"41150",a6c72656:"41276",c7707dd8:"41650","82a30884":"41847","53fc083e":"41890",d69803c7:"41957","9e43e7b6":"42008","19357a65":"42124",be510d4c:"42181","2f504c6e":"42355",ce346131:"42573","35d5d226":"42793",acdbee8e:"42885","2814cf01":"42954","1dcc65e0":"43600","6b85e2ea":"43726",b9aefb1a:"43777",fc1db29b:"43819",d50a8def:"44018","278665dc":"44209","3cd952ae":"44484",d32e6b20:"44497","3c5750f8":"44588",f5c87087:"44685",e7d2e6f0:"44880","1c5f7d2b":"44962","034a556b":"45208",e8c60e9b:"45350","0c0bbaea":"45841",e4bacbbb:"45843","8070429a":"45919","5b3c1c53":"45960",db229a81:"46294",c2d91591:"46581",ae346411:"47234","6daf901a":"47328","1cf37028":"47422","84ebbbbf":"47615","0cd0cfa8":"47629","196fab6d":"47769","09be2ba2":"47834","553f321c":"48124","2c056d5d":"48343",d21505c8:"48733",d5603669:"48890",b0bdb7f3:"48954","79d1baac":"49313",b8919bdb:"49346",e72cf26a:"49486","48e0b5d4":"49549",f0cf672d:"49567",b2f83e6d:"49871",f2e41396:"49907",fd3dbbb4:"50030","254ac25b":"50561",fe2b089e:"51435","431ad29b":"51537","2cbe9533":"51618",c3e83a7d:"51953","25b6fab0":"52021",de127d6b:"52486",a4b6f3a5:"52603",c46f1db0:"52631","2cc833a8":"52814","203d8c37":"53111",cb8de75d:"53302","63ee150d":"53309",ebe9f683:"53559","81be975d":"53609","8c00b41d":"53685","2fa02bf3":"53778","2f5fda3e":"54013","695f8b9b":"54235","5ebc7423":"54487","2b93221c":"54709",a5463d8a:"54736","8acd050c":"54747",bf25430f:"54749",ea64ac1c:"55035","9e4d6f26":"55260","74c40fe4":"55328","006095b2":"55480","79aa13fb":"55945",c3aed80f:"56025",f5dc225c:"56122","8a1c8da1":"56248","281b126c":"56364","36f93d19":"56370","80e8986a":"56419",b4f4317d:"56615","51ca6efd":"56955","1b80e345":"56963",d005934a:"56979","4be15b13":"57060","77d0fddc":"57103","5c71c40a":"57145",bde9fb45:"57287","3e26f8b3":"57361",c86abbf7:"57480",e3e4fe7d:"57573",fbf4432e:"58000",e6a2b2bf:"58634",dbbfa97d:"58729","3b0223df":"59131",fcae69e8:"59273","68648e27":"59469",edfdb191:"59485",aa5bd2a7:"59728",e5c88a3e:"59856",e8ee0390:"59865","92ddf9a4":"60217","2d4599ae":"60377",a03d8b30:"60389",fca48710:"60439","353f52a3":"60679",bb292d37:"60946","8d5fe6f9":"61304","2b6f680f":"61528","86ce5bc1":"61683","15113e52":"61928","4c21dbbd":"61931","988ba51e":"62062","431b5d0e":"62536","748490a7":"62726","00468222":"62746","90305fb4":"62954",d7567838:"63119","586e3f5e":"63157","37da3438":"63453","52c1dace":"64131",c4f5d8e4:"64195","05c5421d":"64302","4bec54d5":"64364","788d9fe0":"64549","8a495097":"64807","8ade285d":"64814","877bdd66":"65010","4840c3eb":"65064","789f108c":"65135","796ce4fb":"65349",cc468388:"65368",c15b67f7:"65369","8047f3a3":"65649","1290c878":"65858","6aa5826c":"65882",e4627c87:"65957","97b92a45":"66073","3c39ccf9":"66334","6df78374":"67098","7196ee6c":"67112",ca3aabfb:"67125",e8b2d68f:"67140","137314dd":"67328","18f77871":"67365",a9dd1cc8:"67396","6eb57332":"67673","6ca8826f":"67744","8894256f":"67813",baa3212e:"67818",bcd02ebb:"67821",ff2d6dd8:"67995","73ce7b01":"68005",e63b451d:"68026","26e12baa":"68189","78bca219":"68224","389bb65e":"68265","3d3a07f6":"68349","88e3fe7e":"68618",a79a2e70:"68755","03cc88eb":"68960","9ad8637e":"69043",e8e02f59:"69113","30b61715":"69184","01a16f71":"69345","98a6b9c4":"69360","71063c2b":"69413",e23eefc0:"69905",b7cfb3da:"69998",b9535f14:"70147",a934672d:"70421","3b768736":"70509",e2df322b:"70520",fa114b0c:"70611",b50c9021:"70633","22bdf908":"70838","970a27d6":"71253","17b00a4a":"71360",b1892b20:"71386","3b7cd1e1":"71525","43cca846":"71568","6d8024b7":"71670","0328b0c9":"71723","57494db5":"72069",a5c74766:"72145","47c64002":"72371","8b8c4320":"72464",f9e1fd09:"72474","5614add0":"72556",bb0e99df:"72841",a626e327:"72939","955e06fd":"73088","04849bf5":"73091","9b6eea2c":"73894","37cea19d":"74010",a8654aa2:"74123","84cf2087":"74190","67db246e":"74199","48db5030":"74298",b8d9b1bd:"74318",aacc2fee:"74400",c0ad5dc6:"74904","30a22249":"75034",add4d791:"75062",cf69f832:"75063","466daf09":"75066","19b0499c":"75212",e82ff315:"75248","42bb1101":"75384","200e51df":"75478","2b3e7a7f":"75647","94a29094":"76255","777bd32a":"76413","93b78259":"76559","3f21c259":"76614",a208e2a5:"76907",a94c7dba:"77183","11b4dd89":"77184","97d979ce":"77665","60ea2d86":"77769","56a38f24":"77771","53bd4095":"77787","2b20c80a":"78023","71051dda":"78297","676afd3b":"78301","1a77ceda":"78382",e49348be:"78494",fd37922c:"78560","44befa6d":"78880","8a942fcc":"78897","9beaa53d":"79022","904cfab0":"79046",d2a246a6:"79256","378b1b2a":"79315","6249c7de":"79376","7cd86536":"79639",d2c4b928:"79796","935f2afb":"80053",c038b4a2:"80371","17c91901":"80536",cfc8b1e5:"80693","48d397c0":"80802",db449848:"80954",d312cf7c:"81030","476a319a":"81188","9ad476bb":"81355",f1e3befe:"81747",a8e44541:"81832",c8450cf2:"81981","989904ef":"82251","555d583b":"82294",de89bf85:"82591","3b83c135":"82946",f47c1d11:"83443","6500be67":"83540",ab4a8e8f:"83667","8c02dfd8":"83771","39c791a9":"83773","3a4337ef":"83882",cc806444:"83922",cf7f1202:"84191",fc15d889:"84453","25b7eef7":"84683","2f53b05f":"84769","2e4eadd3":"84840",b4eef555:"84857","2e8d4eda":"84878",f21b2fb0:"85015",d02b76f9:"85064",e1b9cf16:"85185",c0e80954:"85188","2fcb69bb":"85228","06848362":"85313","6dd1645f":"85660",db0d392c:"85694","6b3775fc":"85897",b700f6c8:"85953","149e5a51":"86098",a01bbcd4:"86181",fed0304a:"86401",f2a10594:"86451",e8c8f122:"86455",af7ab695:"86948","87a13df2":"87173",aebe3827:"87306","393be207":"87414","7fc0684b":"87582","40230f21":"87655","6dde3b76":"87658","5daee80f":"88042","87f76dec":"88184",e8351d64:"88856",e2c0c813:"89101","3f0d1ba4":"89415",e760b063:"89645",c1d23c47:"89786","75a6ad06":"89912",b82b3205:"89964","9ccbc3bf":"89987","24f02aa4":"90058","93f8b8b5":"90558","5c18dc43":"90888","76e9b4e1":"90951","864138a2":"91172","8758e270":"91250","0248575c":"91538",d51ffe49:"91919","726fea1f":"92416","73bfea73":"93056","812cb8ed":"93065","007a6c32":"93387","6f951ae3":"93519","1010372b":"93546",caba9b9f:"93610","7d52489f":"93822","5610cdb3":"93903","046df3c9":"94018",d9ffe17e:"94089","5c128c28":"94091","4b3e38af":"94194",d6b0fe44:"94201","189eacae":"94215",c8a044ba:"94229",d0816b53:"94319","5282f1c8":"94722","5787f6d3":"94900","29f28a73":"94907","64be7568":"95034",b42420f8:"95188",f8dc48d9:"95190",f4bc196f:"95690","8aadacf1":"96276","68f43c04":"96826","4a3e680b":"97482","02193fc8":"97889","954fe569":"97900","1a4e3797":"97920",ffb2e417:"98016",acc38ec3:"98105","2205312d":"98276",cc9c20e3:"98444","92ac5c16":"98509","394c74c3":"98623","68e9a632":"98630",f64e920b:"98666","67044a7a":"98692","0d6f57e0":"98792",e8646b2e:"99074",ff6e33f8:"99156","196bfd5c":"99350",b5511831:"99438",a6f4eced:"99533","57d9a11e":"99875",f56b8973:"99889",ebec70a2:"99959"}[e]||e,t.p+t.u(e)},(()=>{var e={51303:0,40532:0};t.f.j=(b,f)=>{var a=t.o(e,b)?e[b]:void 0;if(0!==a)if(a)f.push(a[2]);else if(/^(40532|51303)$/.test(b))e[b]=0;else{var d=new Promise(((f,d)=>a=e[b]=[f,d]));f.push(a[2]=d);var c=t.p+t.u(b),r=new Error;t.l(c,(f=>{if(t.o(e,b)&&(0!==(a=e[b])&&(e[b]=void 0),a)){var d=f&&("load"===f.type?"missing":f.type),c=f&&f.target&&f.target.src;r.message="Loading chunk "+b+" failed.\n("+d+": "+c+")",r.name="ChunkLoadError",r.type=d,r.request=c,a[1](r)}}),"chunk-"+b,b)}},t.O.j=b=>0===e[b];var b=(b,f)=>{var a,d,c=f[0],r=f[1],o=f[2],n=0;if(c.some((b=>0!==e[b]))){for(a in r)t.o(r,a)&&(t.m[a]=r[a]);if(o)var i=o(t)}for(b&&b(f);n Derivatives Guides | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/category/spot.html b/zh-TW/category/spot.html index 13f8c413aa..adbc365f2c 100644 --- a/zh-TW/category/spot.html +++ b/zh-TW/category/spot.html @@ -4,13 +4,13 @@ Spot Guides | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/changelog/asset-v3.html b/zh-TW/changelog/asset-v3.html index d467966147..51f7b6dcc2 100644 --- a/zh-TW/changelog/asset-v3.html +++ b/zh-TW/changelog/asset-v3.html @@ -4,13 +4,13 @@ 帳戶資產 V3 | Bybit API Documentation - +

    帳戶資產 V3

    2023-09-18

    REST API

    • 新建子帳戶的API Key [更新]
      • 請求參數ips字段實際上是字符串類型, 但原有的數組類型依然可以使用.
      • 請求參數Derivatives字段已經廢棄, 系統會自動識別帳戶類型來決定是否添加統一帳戶權限
    • 修改母帳戶的API Key設置 [更新]
      • 請求參數ips字段實際上是字符串類型, 但原有的數組類型依然可以使用.
      • 請求參數Derivatives字段已經廢棄, 系統會自動識別帳戶類型來決定是否添加統一帳戶權限
    • 修改子帳戶的API Key設置 [更新]
      • 新增請求字段apikey, 用於母帳戶管理子帳戶的key
      • 請求參數ips字段實際上是字符串類型, 但原有的數組類型依然可以使用.
      • 請求參數Derivatives字段已經廢棄, 系統會自動識別帳戶類型來決定是否添加統一帳戶權限
    • 刪除子帳戶的API Key [更新]
      • 新增請求字段apikey, 用於母帳戶刪除子帳戶的key

    2023-08-31

    REST API

    • Get Deposit Records (on chain) [更新]
      • 新增響應字段depositType, 表示該筆充值的類型, 如觸發了每日充值限額或者充值異常, 可以在網站上處理那些無法充值成功的資產
    • Get Sub Deposit Records (on chain) [更新]
      • 新增響應字段depositType, 表示該筆充值的類型, 如觸發了每日充值限額或者充值異常, 可以在網站上處理那些無法充值成功的資產

    2023-08-30

    REST API

    2023-08-17

    REST API

    2023-08-07

    REST API

    2023-07-24

    REST API

    • 查詢賬戶單個幣種余額 [更新]
      • 新增請求參數: toAccountType, toMemberId, withLtvTransferSafeAmount
      • 新增響應字段: ltvTransferSafeAmount

    2023-06-15

    REST API

    2023-06-06

    REST API

    • 提現 [更新]
      • 新增請求參數 feeType, 支持選擇手續費內扣還是外扣

    2023-03-23

    REST API

    2023-03-15

    REST API

    2023-02-28

    REST API

    2023-02-20

    REST API

    2023-02-14

    REST API

    • 提現 [更新]
      • 支持選擇出金帳戶
      • 默認出金錢包是現貨錢包
    入参是否必需類型說明
    accountTypefalsestring設置出金帳戶.
    • SPOT:走現貨錢包出金 (默認)
    • FUND:走資金錢包出金

    2023-02-09

    REST API

    2023-02-06

    REST API

    - + \ No newline at end of file diff --git a/zh-TW/changelog/copytrade.html b/zh-TW/changelog/copytrade.html index c5fa0528e4..073644cb00 100644 --- a/zh-TW/changelog/copytrade.html +++ b/zh-TW/changelog/copytrade.html @@ -4,13 +4,13 @@ 跟單交易 | Bybit API Documentation - +

    跟單交易

    2023-06-24

    REST API

    • Bybit將在6月24日開始陸續開啟帶單交易uid允許升級到新的帶單交易功能, 如果您選擇升級, 請注意以下事項:
      • 您的帳戶將會被分配一個全新子帳戶, 並擁有USDT永續的帶單交易功能
      • 您需要為此帳戶創建新的api key, 並且勾選"合約"權限
      • 您不再允許使用老版本的Copy Trade V3接口, 然而可選擇合約 V3 or V5進行帶單交易, V5接口更為推薦.

    2023-03-23

    REST API

    2023-03-15

    REST API

    - + \ No newline at end of file diff --git a/zh-TW/changelog/derivatives-v3.html b/zh-TW/changelog/derivatives-v3.html index 95306fd31a..4a4819aae2 100644 --- a/zh-TW/changelog/derivatives-v3.html +++ b/zh-TW/changelog/derivatives-v3.html @@ -4,13 +4,13 @@ 衍生品 V3 | Bybit API Documentation - +

    衍生品 V3

    2023-10-25

    REST API

    • 查詢持倉 (實時) [更新]

      • 新增響應字段 isReduceOnly, mmrSysUpdatedTime, leverageSysUpdatedTime
    • 確認新的風險限額 [新增]

      • 新增接口, 用於在主動調整完風險水位後, 觸發接口來讓系統移除只減倉限制

    Websocket API

    • 持倉 [更新]
      • 新增響應字段 isReduceOnly, mmrSysUpdatedTime, leverageSysUpdatedTime

    2023-09-28

    REST API

    2023-08-11

    REST API

    WebSocket API

    • 錢包
      • availableToBorrow 總是返回"" 因為母子共享借貸上限

    2023-07-31

    REST API

    WebSocket API

    2023-07-13

    REST API

    2023-05-23

    REST API

    • 創建委託單 [更新]
      • 針對新版止盈止損, 新增請求參數 tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType
    • 修改委託單 [更新]
      • 針對新版止盈止損, 新增請求參數 tpLimitPrice, slLimitPrice
    • 查詢實時委託單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice
    • 查詢歷史訂單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice
    • 查詢持倉 (實時) [更新]
      • tpSlMode 字段從倉位數據中廢棄
    • 設置止盈止損 [更新]
      • 針對新版止盈止損, 新增請求參數 tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType

    WebSocket API

    • 持倉 [更新]
      • tpSlMode 字段從倉位數據中廢棄
    • 訂單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice

    2023-05-10

    REST API

    老錯誤碼新錯誤碼消息
    10001140071RiskId is not modified

    2023-04-20

    REST API

    • 查詢帳戶配置 [更新]
      • 新增響應參數 dcpStatus, timeWindow, smpGroup
    • 創建委託單 [更新]
      • 新增請求參數 smpType 來選擇自成交執行類型
    • 查詢實時委託單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp
    • 查詢歷史訂單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp

    WebSocket API

    • 訂單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp

    2023-04-12

    REST API

    WebSocket API

    • 持倉 [更新]
      • 新增響應字段adlRankIndicator

    2023-03-08

    REST API

    2023-03-03

    REST API

    2023-02-28

    REST API

    • IP限頻 [更新]
      • 由於切換到CloundFront, 因此IP規則做了適當調整

    2023-02-20

    WebSocket API

    • 個人成交 [更新]
      • 新增返回字段: blockTradeId, markPrice

    2023-02-09

    REST API

    WebSocket API

    • 訂單 [更新]
      • 新增返回字段: avgPrice, blockTradeId, cancelType, cumExecFee, leavesValue, positionIdx, rejectReason

    2023-01-19

    REST API

    WebSocket API

    • 持倉
      • 組合保證金模式下, positionIM, positionMM, leverage返回"", riskId返回0
    • 訂單
      • 組合保證金模式下, orderIM返回""
    • 錢包
      • 組合保證金模式下, totalOrderIM, totalPositionIM, totoalPositionMM返回""

    2023-01-16

    WebSocket API

    • 深度
      • 增加500檔的推送,頻率為100ms

    2023-01-05

    WebSocket API

    • 行情
      • nextFundingTime 從日期2023-01-05T08:00:00Z變動為UTC時間戳(毫秒)1672905600000
      • predicatedFundingRate 從消息中移除
    - + \ No newline at end of file diff --git a/zh-TW/changelog/spot-v3.html b/zh-TW/changelog/spot-v3.html index d9f8e0a7f3..82d3426f25 100644 --- a/zh-TW/changelog/spot-v3.html +++ b/zh-TW/changelog/spot-v3.html @@ -4,13 +4,13 @@ 現貨 V3 | Bybit API Documentation - +

    現貨 V3

    2023-04-20

    REST API

    • 創建活動委托單 [更新]
      • 新增請求參數 smpType 來選擇自成交執行類型
      • 新增響應參數 smpType
    • 訂單列表 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增響應參數 cancelType, 對應枚舉值為CancelBySmpUNKNOWN
    • 查詢活動委托 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增響應參數 cancelType, 對應枚舉值為CancelBySmpUNKNOWN
    • 歷史訂單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增響應參數 cancelType, 對應枚舉值為 CancelBySmpUNKNOWN

    WebSocket API

    • 訂單 [更新]
      • 新增響應參數 st, sg, so
      • 新增響應參數 ct, 對應枚舉值為 CancelBySmpUNKNOWN

    2023-04-12

    REST API

    • 訂單列表 [更新]
      • 新增返回字段 blockTradeId 大宗交易ID
    • 查詢活動委托 [更新]
      • 新增返回字段 blockTradeId 大宗交易ID
    • 歷史訂單 [更新]
      • 新增返回字段 blockTradeId 大宗交易ID
    • 交易記錄 [更新]
      • 新增返回字段 blockTradeId 大宗交易ID

    WebSocket API

    • 訂單 [更新]
      • 新增返回字段 b 表示大宗交易ID
    • 個人成交 [更新]
      • 新增返回字段 b 表示大宗交易ID

    2023-03-13

    WebSocket API

    2023-03-09

    REST API

    2023-02-28

    REST API

    2023-01-16

    WebSocket API

    • 行情
      • xp 已經添加到推送中. 該字段表示為USD指數價格, 可以為空。
    - + \ No newline at end of file diff --git a/zh-TW/changelog/v5.html b/zh-TW/changelog/v5.html index 71f1014d21..529c50e088 100644 --- a/zh-TW/changelog/v5.html +++ b/zh-TW/changelog/v5.html @@ -4,7 +4,7 @@ V5 | Bybit API Documentation - + @@ -14,7 +14,7 @@ USDTPerpetualLeverage, symbol, leverage, USDCContractLeverage
  • 查詢借貸訂單信息
    • 新增響應字段USDTPerpetualOpenLine, USDCContractOpenLine, USDCOptionsOpenLine, USDTPerpetualCloseLine, USDCContractCloseLine, USDCOptionsCloseLine, USDCContractSymbols, USDCOptionsSymbols, marginLeverage, USDTPerpetualLeverage, symbol, leverage, USDCContractLeverage
  • 查詢賬戶單個幣種余額
    • 新增請求參數: toAccountType, toMemberId, withLtvTransferSafeAmount
    • 新增響應字段: ltvTransferSafeAmount
  • 新增錯誤碼適配UTA帳戶支持場外借貸的交易限制場景
  • 新增錯誤碼描述
    30133USDT永續: 當交易對不在白名單內
    30134USDT合約: 當交易對不在白名單內
    30135USDT永續: 當設置的槓桿大於機構借貸規定的
    30136USDC合約: 當設置的槓桿大於機構借貸規定的
    3200316期權: 限制交易
    3200317期權: 限制買入
    170709現貨: 當交易對不在白名單內
    170215現貨: 限制買入
    170216現貨: 全倉槓桿倍數超過機構借貸規定的
    170220現貨: 限制交易

    2023-07-13

    REST API

    2023-07-04

    REST API

    2023-06-29

    WebSocket API

    2023-06-26

    WebSocket API

    • 深度 [現貨]
      • 將50檔位的頻率從100ms提升到20ms

    2023-06-24

    REST API

    2023-06-15

    REST API

    2023-06-14

    REST API

    2023-06-08

    REST API

    2023-06-07

    REST API

    • 提現 [更新]
      • 新增請求參數 feeType, 支持選擇手續費內扣還是外扣

    2023-06-06

    REST API

    2023-06-02

    REST API

    2023-06-01

    REST API

    WebSocket API

    • 持倉 [更新]
      • 新增響應參數字段 positionBalance

    2023-05-30

    REST API

    2023-05-23

    REST API

    • 創建委託單 [更新]
      • 針對新版止盈止損, 新增請求參數 tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType
    • 修改委託單 [更新]
      • 針對新版止盈止損, 新增請求參數 tpLimitPrice, slLimitPrice
    • 查詢實時委託單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice
    • 查詢歷史訂單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice
    • 查詢持倉 (實時) [更新]
      • tpslMode 字段從倉位數據中廢棄
    • 設置止盈止損 [更新]
      • 針對新版止盈止損, 新增請求參數 tpslMode, tpLimitPrice, slLimitPrice, tpOrderType, slOrderType

    WebSocket API

    • 持倉 [更新]
      • tpslMode 字段從倉位數據中廢棄
    • 訂單 [更新]
      • 針對新版止盈止損, 新增響應參數 tpslMode, tpLimitPrice, slLimitPrice

    2023-05-10

    REST API

    老錯誤碼新錯誤碼消息
    10001110075RiskId is not modified

    2023-05-05

    REST API

    2023-05-04

    REST API

    • 查詢成交紀錄 [更新]
      • 對於普通帳戶查詢期貨時,symbol 不再是必傳字段
    • 查詢平倉盈虧 [更新]
      • 對於普通帳戶查詢期貨時,symbol 不再是必傳字段

    2023-04-20

    REST API

    • 創建委託單 [更新]
      • 新增請求參數 smpType 來選擇自成交執行類型
    • 查詢實時委託單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp
    • 查詢歷史訂單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp
    • 查詢賬戶配置 [更新]
      • 新增響應參數 dcpStatus, timeWindow, smpGroup

    WebSocket API

    • 訂單 [更新]
      • 新增響應參數 smpType, smpOrderId, smpGroup
      • 新增cancelType枚舉cancelBySmp

    2023-04-06

    REST API

    2023-04-04

    REST API

    WebSocket API

    • 持倉 [更新]
      • 新增響應字段adlRankIndicator
      • UTA帳戶的推送新增字段category
    • 訂單 [更新]
      • 新增響應字段 placeType, 供期權訂單使用
    • 個人成交 [更新]
      • 新增響應字段 closedSize

    2023-03-24

    REST API

    2023-03-23

    REST API

    WebSocket API

    • 錢包 [更新]
      • 新增返回字段 accountLTV

    2023-03-22

    REST API

    2023-03-15

    REST API

    2023-03-10

    REST API

    • 查詢可交易產品的規格信息 [更新]
      • 統一現貨、期貨和期權的交易對狀態枚舉值。統一使用Trading, Closed, Settling, PreLaunch, Deliverying
      • 移除期權響應體中多餘的字段category
    • 查詢手續費率 [更新]
      • 支持查詢期權的手續費率

    2023-03-09

    REST API

    • 全倉槓桿設置 [更新]
      • UTA用戶支持10倍全倉槓桿交易
    • 查詢錢包餘額 [更新]
      • 更新前: 普通帳戶調用接口, accountType=UNIFIED時, 返回錯誤碼和錯誤信息.
        更新後: 普通帳戶調用接口, accountType=UNIFIED時, 返回http code 400

    2023-02-28

    REST API

    WebSocket API

    • 錢包 [更新]
      • 新增推送字段 bonus

    2023-02-20

    REST API

    2023-02-15

    REST API

    • 用戶 [新增]
      • 增加一組用戶API Key管理的接口

    2023-02-14

    REST API

    入参是否必需類型說明
    accountTypefalsestring設置出金帳戶.
    • SPOT:走現貨錢包出金 (默認)
    • FUND:走資金錢包出金

    2023-02-09

    REST API

    2023-01-19

    REST API

    WebSocket API

    • 持倉
      • 組合保證金模式下, positionIM, positionMM, leverage, riskLimitValue 返回 "", riskId 返回 0
    • 錢包
      • 組合保證金模式下, totalOrderIM, totalPositionIM, totoalPositionMM 返回 ""

    2023-01-16

    REST API

    • 查詢最新行情信息 [現貨]
      • usdIndexPrice 已經添加到響應體中. 該字段表示為USD指數價格, 可以為空。

    WebSocket API

    • 行情 [現貨]
      • usdIndexPrice 已經添加到推送中. 該字段表示為USD指數價格, 可以為空。
    • 深度 [正向合約以及反向合約]
      • 增加500檔的推送,頻率為100ms

    2023-01-09

    WebSocket API

    • 行情 [正向合約以及反向合約]
      • nextFundingTime 從日期 2023-01-05T08:00:00Z 變動為UTC時間戳(毫秒) 1672905600000
      • predicatedFundingRate 從消息中移除
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/account/transfer-list.html b/zh-TW/copy-trade/account/transfer-list.html index 1fdba3074a..55c6ace6f1 100644 --- a/zh-TW/copy-trade/account/transfer-list.html +++ b/zh-TW/copy-trade/account/transfer-list.html @@ -4,13 +4,13 @@ 查詢劃轉紀錄 | Bybit API Documentation - +

    查詢劃轉紀錄

    查詢帶單錢包的劃轉紀錄

    提示

    需要: 錢包 - "帳戶劃轉" 權限

    HTTP Request

    GET /asset/v3/private/transfer/copy-trading/list/query

    請求參數

    參數是否必須類型說明
    transferIdfalsestring劃轉ID
    coinfalsestring幣種名稱
    statusfalsestring劃轉狀態. 不傳,默認查全部
    copyTradeTypefalseinteger帶單類型. 0: 所有, 1: 合約帶單, 2 (暫不支持): 現貨帶單
    startTimefalseinteger開始時間戳 (毫秒). 不傳,默認查詢過去30天
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    返回參數

    參數類型說明
    listarrayObject
    > transferIdstring劃轉ID
    > coinstring幣種名稱
    > amountstring金額
    > fromAccountTypestring劃出錢包
    > toAccountTypestring劃入錢包
    > timestampstring劃轉時間戳 (毫秒)
    > statusstring劃轉狀態
    > copyTradeTypeinteger帶單類型. 1: 合約帶單, 2 (暫不支持): 現貨帶單
    nextPageCursorstring游標, 用於翻頁

    請求示例

    GET /asset/v3/private/transfer/copy-trading/list/query?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1679560892359
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "cb86de08-b10f-4abe-9746-7b95c4a37d307",
    "coin": "USDT",
    "amount": "100",
    "fromAccountType": "UNIFIED",
    "toAccountType": "COPYTRADE",
    "timestamp": "1678861757000",
    "status": "SUCCESS",
    "copyTradeType": 1
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MjY4MTAzNSwibWF4SUQiOjI2ODEwMzV9"
    },
    "retExtInfo": {},
    "time": 1679560892812
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/account/transfer.html b/zh-TW/copy-trade/account/transfer.html index d969120b64..25ce32c49d 100644 --- a/zh-TW/copy-trade/account/transfer.html +++ b/zh-TW/copy-trade/account/transfer.html @@ -4,13 +4,13 @@ 交易員劃轉資金 | Bybit API Documentation - +

    交易員劃轉資金

    交易員劃轉資金

    HTTP 請求

    POST /contract/v3/private/copytrading/wallet/transfer

    請求參數

    參數是否必須類型說明
    transferIdtruestringUUID,全局唯一
    cointruestring幣種類型. 僅USDT
    amounttruestring兌入數量
    fromAccountTypetruestringfrom賬戶類型
    toAccountTypetruestringTo賬戶類型

    返回參數

    參數類型說明
    transferIdstringUUID,全局唯一

    請求示例

    POST /contract/v3/private/copytrading/wallet/transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673257786588
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 173

    {
    "transferId": "5f95de08-b10f-43be-9746-7b95c4a37d307",
    "coin": "USDT",
    "amount": "500",
    "fromAccountType": "UNIFIED",
    "toAccountType": "COPYTRADING"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "transferId": "5f95de08-b10f-43be-9746-7b95c4a37d307"
    },
    "retExtInfo": {},
    "time": 1673258002526
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/account/wallet.html b/zh-TW/copy-trade/account/wallet.html index bf26c5e216..a2d51641f1 100644 --- a/zh-TW/copy-trade/account/wallet.html +++ b/zh-TW/copy-trade/account/wallet.html @@ -4,13 +4,13 @@ 交易員獲取錢包余額 | Bybit API Documentation - +

    交易員獲取錢包余額

    交易員獲取跟單帳戶的錢包余額

    HTTP 請求

    GET /contract/v3/private/copytrading/wallet/balance

    請求參數

    返回參數

    參數類型說明
    coinstring幣種類型
    equitystring用戶資產 (wallet_balance + unrealised_pnl)
    availableBalancestring可用余額 = wallet balance - used margin
    usedMarginstring已用保證金
    orderMarginstring委托預占用保證金
    positionMarginstring倉位保證金
    walletBalancestring錢包余額
    realisedPnlstring當日已結盈虧
    unrealisedPnlstring未結盈虧
    cumRealisedPnlstring累計已結盈虧

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/contract/v3/private/copytrading/wallet/balance' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841373442' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "availableBalance": "985.4988359",
    "usedMargin": "0",
    "orderMargin": "0",
    "positionMargin": "0",
    "walletBalance": "985.4988359",
    "realisedPnl": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "-14.5011641",
    "coin": "USDT",
    "equity": "985.4988359"
    },
    "retExtInfo": {},
    "time": 1673257786956
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/enum.html b/zh-TW/copy-trade/enum.html index 7c331779e7..46d4df6504 100644 --- a/zh-TW/copy-trade/enum.html +++ b/zh-TW/copy-trade/enum.html @@ -4,13 +4,13 @@ 枚舉定義 | Bybit API Documentation - +

    枚舉定義

    accountType

    • UNIFIED統一帳戶
    • CONTRACT期貨帳戶
    • COPYTRADING跟單帳戶

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    symbol

    跟單交易僅支持USDT永續

    • BTCUSDT
    • ETHUSDT
    • SOLUSDT
    • ...

    orderType

    • Market
    • Limit

    execType

    triggerBy

    • LastPrice
    • IndexPrice
    • MarkPrice

    lastLiquidityInd

    • AddedLiquidity增加流動性
    • RemovedLiquidity吃流動性
    • LiquidityIndNA不存在流動性變化

    copyTradeOrderStatus

    • UNKNOWN
    • PendingNew
    • New
    • OpenOrderPartiallyFilled
    • OpenOrderFilled
    • OpenOrderClosing
    • OpenOrderClosedFilled
    • CloseOrderPartiallyFilled
    • CloseOrderFilled
    • Cancelled
    • Untriggered
    • Triggered

    timeInForce

    • GoodTillCancel
    • ImmediateOrCancel
    • FillOrKill
    • PostOnly

    positionIdx

    • 0單向持倉
    • 1買側的雙向持倉
    • 2賣側的雙向持倉

    interval

    • 1 3 5 15 30 60 120 240 360 720分鐘
    • D
    • W
    • M

    tickDirection

    • PlusTick價格上漲
    • ZeroPlusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格高於前一筆交易的價格
    • MinusTick價格下跌
    • ZeroMinusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格低於前一筆交易的價格
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/error.html b/zh-TW/copy-trade/error.html index a109d0d064..3c44b86250 100644 --- a/zh-TW/copy-trade/error.html +++ b/zh-TW/copy-trade/error.html @@ -4,13 +4,13 @@ 錯誤碼 | Bybit API Documentation - +

    錯誤碼

    錯誤碼描述
    10000處理請求時發生未知錯誤。
    10001傳遞給API的值有問題。
    10002請求未授權-API金鑰是必需的,應包含在所有請求中。
    10003無效的api金鑰
    10004無效的symbol
    10005當前apikey的許可權被拒絕。 API金鑰是在沒有正確許可權的情况下創建的(例如,沒有Order許可權,或設定為只讀)
    10006訪問次數太多。 參攷API速率限制。 請使用WebSocket進行即時更新。 當前限制為每分鐘%s個請求。
    10007後端服務器的響應超時。 傳遞和請求狀態未知。
    10010請求IP不匹配。
    10012資料庫錯誤
    10014不支持交易對。
    10015新訂單太多。 請降低請求頻率。
    10016服務不可用。
    10017未找到請求路徑或請求方法無效
    10018超過IP速率限制。
    10020不支持請求。
    10021請求的時間戳記在recvWindow之外。 此請求的時間戳記比服務器時間早1000毫秒。 請檢查本地時間和服務器時間。
    10022請求簽名無效。
    11000不支持參數字元。
    11001為此終結點發送的參數太多。
    11002未發送所需參數。 參數為空/null或格式不正確。
    11003發送了未知參數。
    11004未讀取發送的所有參數。
    11005空參數。
    11006不再需要時發送了參數。
    11011訂單價格超過上限。
    11012交易對不存在。
    11014不需要時發送TimeInForce參數。
    11015timeInForce無效。
    11016orderType無效。
    11017方向無效。
    11018用戶生成的訂單ID為空。
    11019用戶生成的訂單ID為空。
    11020間隔無效。
    11021無效symbol。
    11025listenKey不存在。
    11027査詢間隔太大。
    11028參數組合無效。
    11030發送的參數無效。
    11031餘額不足。
    11032訂單價格超過上限。
    11033訂單價格超過下限。
    11034訂單價格小數位數太多。
    11035訂單數量超過上限。
    11036訂單數量超過下限。
    11037訂單數量的小數位數太多。
    11038訂單價格超出限制。
    11039訂單已完成。
    11040訂單值超過下限。
    11041clientOrderId重複。
    11042訂單已取消。
    11043未找到訂單。
    11044訂單被取消。 不支持操作。
    11045無法取消訂單。
    11046訂單創建超時。
    11047訂單取消超時。
    11090取消訂單已完成。
    11091無法取消訂單,請稍後再試。
    20001訂單不存在。
    20003缺少參數side
    20004無效參數side
    20005缺少參數symbol
    20006無效參數symbol
    20007缺少參數order_type
    20008無效參數order_type
    20009缺少參數數量
    20010新訂單被拒絕。
    20011取消被拒絕。
    20012數量必須大於零且小於100萬
    20013訂單不存在。
    20014API金鑰格式無效。
    20015API金鑰或IP無效。
    20016當前對的交易視窗尚未打開。
    20017缺少參數order_id
    20018無效的日期格式
    20019缺少參數stop_px
    20020缺少參數base_price
    20021缺少參數stop_order_id
    20022缺少參數杠杆
    20023杠杆必須是一個數位
    20031杠杆率必須大於零
    20070缺少參數margin
    20071margin必須大於零
    20084需要<code>order_id</code>或<code>order_link_id</code>
    20094order_link_id不是唯一的。
    30002退出訂單已存在。
    30003qty必須高於允許的最小值。
    30004qty必須高於允許的最小值。 合約數量超過了允許的最大限制。 每個訂單的訂單數量應少於100萬。
    30005訂單價格超出允許範圍。
    30006last_price
    30007訂單價格超出允許範圍。
    30008無效的order_type
    30009找不到倉位。
    30010錢包餘額不足。
    30011由於頭寸正在清算,囙此不允許操作
    30012由於倉位正在進行ADL,囙此不允許操作
    30013倉位處於liq或adl狀態
    30014關閉訂單無效,數量不應大於大小。
    30015關閉順序無效,一側應相反。
    30016關閉倉位前必須取消TP和SL。
    30017估計填充價格不能低於當前購買liq_price。
    30018估計填充價格不能高於當前的賣出liq_price。
    30019下非開放倉位訂單時,無法為非零倉位附加TP/SL參數。
    30020倉位已具有TP/SL參數。
    30021無法提供估計的position_margin。
    30022估計買入liq_price不能高於當前mark_price。
    30023預計銷售價格不能低於當前價格。
    30024無法為零倉位設定TP/SL/TS
    30025觸發價格應大於上次價格的10%。
    30026價格太高。
    30027為獲利設定的價格應高於上次交易價格。
    30028止損價格應介於清算價格和最後交易價格之間。
    30029止損價格應介於最後交易價格和清算價格之間。
    30030為Take Profit設定的價格應低於上次交易價格。
    30031訂單成本可用餘額不足。
    30032訂單已填寫或取消。
    30033停止訂單的數量超過了允許的最大限制。
    30034未找到停止訂單。
    30035取消太快,請稍後再試。
    30036訂單執行後的預期倉位值超過當前風險限額
    30037訂單已取消
    30038無標記價格。
    30039施加的杠杆已超出允許範圍。
    30040所做的任何調整都將引發立即清算。
    30041找不到倉位。
    30042錢包餘額不足。
    30043由於頭寸正在清算,囙此不允許操作。
    30044不允許操作,因為倉位正在進行ADL。
    30045由於倉位不在正常狀態,不允許操作。
    30046有多個未觸發的止損單。
    30047p:o不一致。
    30048施加的杠杆已超出允許範圍。
    30049可用餘額不足。
    30050所做的任何調整都將引發立即清算!
    30051由於風險限制,無法調整杠杆。
    30052杠杆率不能低於1倍。
    30053max_affordable_position_bmargin<=0,倉位:%s
    30054fixed_new_position_margin無效。
    30055可用餘額不足以新增保證金。
    30056倉位在cross_margin中。
    30057請求的合約數量超過了風險限額,請在重試之前調整您的風險限額級別。
    30063不滿足僅减少規則
    30066設定自動添加保證金失敗。
    30067可用餘額不足。
    30068退出值必須為正。
    30073活動訂單數大於500。
    30074無法創建止損單,因為您希望當LastPrice(或IndexPrice, MarkPrice],由trigger_by確定)上升到stop_px時觸發止損單,但LastPrice(或IndexPriceMarkPrice)已等於或大於stop_px, 請調整base_pricestop_px
    30075無法創建止損單,因為您希望當LastPrice(或IndexPrice,MarkPrice],由trigger_by確定)降至stop_px時觸發止損單,但LastPrice(或IndexPriceMarkPrice)已等於或小於stop_px, 請調整base_pricestop_px
    30076替換參數無效。 訂單未修改。
    30077根據公開利益,提交訂單將導致違反用戶限制。
    30078非交易狀態的合約
    30079該頭寸即將引發清算
    30080價格不能低於當前購買liq_Price
    30081價格不能大於當前銷售價格
    30082倉位存在不允許切換倉位模式
    30083倉位模式無變化
    30084未更改每個倉位的完整倉位模型
    30085保證金不變
    30086對於委託訂單,不允許切換倉位模式
    30087symbol不支持雙向打開倉位
    30088symbol不存在
    30089重複訂單號
    30090風險限額資訊不存在
    30091非法訂單(意味著訂單在各種情况下都不合法)
    30092不允許任何倉位設定保證金
    30093無淨頭寸
    30094在清算未結束前撤回命令
    30095不允許滿倉修改杠杆
    31003使用者帳戶被禁用
    32006可用餘額不足以支付手續費。
    32008可用保證金不足。
    32009所做的任何調整都將引發立即清算。
    32010由於可用保證金不足,無法調整風險限額。
    32011由於當前/預期持倉價值超過修訂後的風險限額,囙此無法調整風險限額。
    33004apikey已過期
    34010錢包餘額小於零。
    34015無法設定新杠杆,因為它等於以前的杠杆。
    34017當前杠杆率小於1X
    34018無法將杠杆設定為低於1X
    34019不能將杠杆設定為大於maxLeverage。
    34020無法設定與先前杠杆相同的杠杆。
    34021無法取消occ_calc_data,數據錯誤。
    34022無法設定將導致可用餘額小於0的杠杆。
    34023請求已取消,因為源請求已處理。
    34024請求不包括添加保證金數據。
    34025杠杆率的新增失敗了。
    34026新限制等於舊限制(無變化)。
    34027無法調整杠杆。
    34028重新計算資金費用失敗。
    34030positionInfo與當前exec_rpt不同步。
    34032撤回時PositionSeq不匹配。
    34033已實現PNL已旋轉。
    34035添加未修改的保證金。
    34036未修改設定杠杆。
    34037設定未修改的自定義費率。
    34038更新未修改的去杠杆名額。
    34039更新倉位狀態未修改。
    34040設定TP/SL/TS未修改。
    35014超過未結利息。
    37001兩側倉位tp_sl_mode相等。
    37002相同的tp_sl_mode。
    37003此倉位至少有一個止損連結訂單,無法在止損和獲利模式之間切換。
    37004此倉位至少有一個止損連結訂單,無法在止損和獲利模式之間切換。
    37005此倉位至少有一個尾隨止損或尾隨止損連結訂單,無法切換為獲利止損模式。
    37006有條件或限制訂單帶有獲利和止損參數
    37007剩餘倉位數量不足,無法設定止損和獲利
    37008活動訂單在修改觸發價格時不允許修改價格和數量
    37009如果訂單已部分完成,則不允許活動訂單修改止損和獲利設定
    37010在完全獲利止損模式下,不允許修改止盈止損大小
    37011在部分SL模式下,SL設定為大於20。 設定SL/TP超過限制oldTpNum+oldStNum+newNum=(2,num為TP+SL)
    37012止損價格必須大於基本價格。
    37013止損價格必須低於基本價格。
    38101根據公開利益,更換訂單將導致違反用戶限制。
    90015餘額不足
    90016被風險控制拒絕。 轉讓後可能導致清算。
    90063正在進行清算
    90066在對賬中
    90067對賬失敗
    131200服務器錯誤
    131201Biz err
    131212用戶餘額不足
    131217風險檢查錯誤
    131203請求參數錯誤
    131204帳戶資訊錯誤
    131206無法傳輸
    131214transferId存在
    131215金額誤差
    131216查詢餘額錯誤
    131218統一轉出風險,用戶的頭寸目前處於強制清算狀態
    131219統一轉出風險,轉出預警
    131220統一轉出風險,轉出無息貸款限額預警
    131221統一轉出風險,轉出預警
    131222統一轉出風險,對賬檢查失敗
    131223統一轉出風險,拒絕
    131224統一轉出風險,餘額不足
    131225不支持的統一狀態
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/position/close-position.html b/zh-TW/copy-trade/position/close-position.html index 3f96a8a334..ff147cc7d2 100644 --- a/zh-TW/copy-trade/position/close-position.html +++ b/zh-TW/copy-trade/position/close-position.html @@ -4,13 +4,13 @@ 交易員一鍵平倉 | Bybit API Documentation - +

    交易員一鍵平倉

    HTTP 請求

    GET /contract/v3/private/copytrading/position/close

    請求參數

    參數是否必須類型說明
    symboltruestring合約類型
    positionIdxtruestringPosition idx, 用於在不同倉位模式下標識倉位:0-單向持倉; 1-雙向持倉Buy; 2-雙向持倉Sell

    返回參數

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/close' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841189767' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","positionIdx":"1"}'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/position/execution-list.html b/zh-TW/copy-trade/position/execution-list.html index 5e02154031..90390f15ac 100644 --- a/zh-TW/copy-trade/position/execution-list.html +++ b/zh-TW/copy-trade/position/execution-list.html @@ -4,13 +4,13 @@ 查詢成交紀錄 (兩年) | Bybit API Documentation - +

    查詢成交紀錄 (兩年)

    獲取用戶成交紀錄,返回結果按execTime降序排列

    提示

    單筆訂單可能會有多次成交

    HTTP 請求

    GET /contract/v3/private/copytrading/execution/list

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring用戶自定義訂單iD
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    execTypefalsestring成交類型
    limitfalseinteger每頁數量限制. [1, 100]. default: 50
    cursorfalsestring游標,用於翻頁,需要對返回的游標字符串進行urlencode

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義訂單iD
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > orderTypestring訂單類型. 市價單: Market,限價單: Limit
    > execFeestring交易手續費
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring交易類型
    > execValuestring成交價值
    > feeRatestring手續費率
    > lastLiquidityIndstring流動性類型. AddedLiquidity, RemovedLiquidity, LiquidityIndNA
    > isMakerboolean是否是maker單
    > leavesQtystring剩餘委託未成交價值
    > closedSizestring平倉數量
    > markPricestring成交執行時,該 symbol 當時的標記價格
    > execTimestring成交時間(毫秒)

    請求示例

    GET /contract/v3/private/copytrading/execution/list?symbol=XRPUSDT&execType=Funding HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1678788154878
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "nextPageCursor": "0o+MpbbRsIrLhRXdulAiDPRZFkidzCCKmEOQR4TzFIYyq1tofpJ/bOX92Vn8uwRBSEUuSxC/9jnLZs7oFLgcMQ==",
    "list": [
    {
    "symbol": "XRPUSDT",
    "side": "Buy",
    "orderId": "1678780800-XRPUSDT-1019213-Buy",
    "orderLinkId": "",
    "orderPrice": "0.0000",
    "orderQty": "0",
    "orderType": "UNKNOWN",
    "execFee": "0.003679",
    "execId": "73729a92-caf5-4911-8e85-5194dd2ee1c5",
    "execPrice": "0.3679",
    "execQty": "100",
    "execType": "Funding",
    "execValue": "36.79",
    "feeRate": "0.0001",
    "lastLiquidityInd": "LiquidityIndNA",
    "isMaker": false,
    "leavesQty": "0",
    "closedSize": "0",
    "markPrice": "0.3679",
    "execTime": "1678780800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1678788155282
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/position/leverage.html b/zh-TW/copy-trade/position/leverage.html index e82bfbb20e..e59ec8740c 100644 --- a/zh-TW/copy-trade/position/leverage.html +++ b/zh-TW/copy-trade/position/leverage.html @@ -4,13 +4,13 @@ 交易員設置帶單槓桿 | Bybit API Documentation - +

    交易員設置帶單槓桿

    交易員設置帶單槓桿, 設置槓桿只能設置整數

    HTTP 請求

    GET /contract/v3/private/copytrading/position/set-leverage

    請求參數

    參數是否必須類型說明
    symboltruestring合約類型
    buyLeveragetruestring全倉/逐倉切換,需要傳杠桿並且buy_leveragesell_leverage必須傳入相同參數。
    sellLeveragetruestring全倉/逐倉切換,需要傳杠桿並且buy_leveragesell_leverage必須傳入相同參數。

    返回參數

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/set-leverage' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670841373442' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","buyLeverage":"4","sellLeverage":"4"}'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/position/position-info.html b/zh-TW/copy-trade/position/position-info.html index 93d026dd48..052833634b 100644 --- a/zh-TW/copy-trade/position/position-info.html +++ b/zh-TW/copy-trade/position/position-info.html @@ -4,13 +4,13 @@ 交易員帶單倉位匯總 | Bybit API Documentation - +

    交易員帶單倉位匯總

    交易員帶單倉位匯總

    HTTP 請求

    GET /contract/v3/private/copytrading/position/list

    請求示例

    參數是否必須類型說明
    symbolfalsestring合約類型

    響應示例

    參數類型說明
    listarrayObject
    > symbolstring合約類型
    > sidestring方向
    > sizestring倉位數量
    > positionValuestring倉位價值
    > entryPricestring平均入場價
    > liqPricestring強平價格
    > bustPricestring破產價格
    > markPricestring標記價格
    > leveragestring逐倉模式下, 值為用戶設置的杠桿;全倉模式下,值為當前風險限額下最大杠桿
    > isIsolatedboolean是否逐倉,true-逐倉 false-全倉
    > positionMarginstring倉位保證金
    > occClosingFeestring倉位占用的平倉手續費
    > occFundingFeestring倉位size和當前資金費率預占用資金費用
    > cumRealisedPnlstring累計已結盈虧
    > freeQtystring可平倉位數量(如果您有多頭頭寸,free_qty 為負數。反之亦然)
    > unrealisedPnlstring未結盈虧
    > positionIdxstring倉位標識, 用於在不同倉位模式下標識倉位:0-單向持倉; 1-雙向持倉Buy; 2-雙向持倉Sell
    > createdTimestring創建時間
    > updatedTimestring更新時間

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/contract/v3/private/copytrading/position/list' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "side": "Sell",
    "size": "0.02",
    "positionValue": "25.2665",
    "entryPrice": "1263.325",
    "liqPrice": "1383.30",
    "bustPrice": "1389.65",
    "markPrice": "1254.60",
    "leverage": "10",
    "isIsolated": true,
    "positionMargin": "2.52665009",
    "occClosingFee": "0.0166758",
    "occFundingFee": "0",
    "cumRealisedPnl": "132.46751301",
    "freeQty": "0.02",
    "unrealisedPnl": "0.1745",
    "positionIdx": "2",
    "createdTime": "1652324549816",
    "updatedTime": "1670841190027"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670841190031
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/rate-limit.html b/zh-TW/copy-trade/rate-limit.html index 7c808c6abb..b8a29a6009 100644 --- a/zh-TW/copy-trade/rate-limit.html +++ b/zh-TW/copy-trade/rate-limit.html @@ -4,14 +4,14 @@ 頻率限制 | Bybit API Documentation - +

    頻率限制

    IP限頻

    警告

    如果您收到HTTP 403(拒絕訪問)響應, 您的 IP 已被暫時或永久禁止。 您應立即查看以下指南,以確保您的應用程序不會繼續違反限制。如果您在 30 分鐘後 仍被禁止,則您可能會被永久禁止。

    我們不建議您在這些限制的邊緣運行您的應用程序,以防異常的網絡活動導致意外違規。

    • GET/POST 請求 (共享):
      • 連續 5 秒內每秒不超過 120 個請求
    備註

    所有到api.bybit.comapi.bytick.com的流量共享此限制,無論是訪問現貨、期貨還是期權。

    違反限制後,您的 IP 將被禁止一段時間(通常為 30 分鐘)。 持續違反限制將導致永久禁止。 我們不能撤銷永久禁令或縮短臨時禁令。

    賬戶頻率限製

    警告

    如果您收到這樣的響應"ret_msg": "Too many visits!", 則表示您觸發了帳戶頻率限制, 請等到頻率限制重置以後, 再繼續發送請求。

    Bybit基於每分鍾的滾動時間窗口來做頻率限製,並且是按賬戶(uid)來做劃分限製,每次請求API響應頭(response header)中都會包含如下字段:

    • X-Bapi-Limit-Status - 該接口當前時間窗口剩余可用請求數
    • X-Bapi-Limit - 該接口當前頻率限製上限
    • X-Bapi-Limit-Reset-Timestamp - 如果您已超過該接口當前窗口頻率限製,該字段表示下個可用時間窗口的時間戳(毫秒),即什麽時候可以恢復訪問;如果您未超過該接口當前窗口頻率限製,該字段表示返回的是當前服務器時間(毫秒).

    Http 響應頭示例

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    接口頻率限制表

    路徑頻率消費
    /contract/v3/private/copytrading/position/set-leverage75 req/min1/request
    /contract/v3/private/copytrading/position/close1/request
    /contract/v3/private/copytrading/position/list1/request
    /contract/v3/private/copytrading/order/create100 req/min1/request
    /contract/v3/private/copytrading/order/close1/request
    /contract/v3/private/copytrading/order/cancel1/request
    /contract/v3/private/copytrading/order/list 1/request
    /contract/v3/private/copytrading/wallet/balance120 req/min1/request
    /contract/v3/private/copytrading/wallet/transfer1/request

    如何提高頻率限製

    請發送郵件到 api@bybit.com,我們會在 1-4 個工作日內答復。郵件內容必須包含以下內容:

    1. 您的姓名和公司名稱和簡介
    2. 您的bybit 賬號uid或註冊郵箱手機號,以及您要申請提頻的交易對
    3. 您上個月的交易量(吃單/掛單)並提供截圖
    4. 簡單介紹您的交易策略和為什麽需要更高限頻
    5. 如果可以,請提供您的成交記錄csv文檔
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/trade/cancel.html b/zh-TW/copy-trade/trade/cancel.html index 283c30c1c6..c1d6477700 100644 --- a/zh-TW/copy-trade/trade/cancel.html +++ b/zh-TW/copy-trade/trade/cancel.html @@ -4,13 +4,13 @@ 交易員取消訂單 | Bybit API Documentation - +

    交易員取消訂單

    交易員取消訂單

    HTTP 請求

    POST /contract/v3/private/copytrading/order/cancel

    請求參數

    參數是否必須類型說明
    symboltruestring合約類型
    orderIdfalsestring訂單ID. orderIdorderLinkId二者必傳一個
    orderLinkIdfalsestring自定義機構ID. orderIdorderLinkId二者必傳一個

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/cancel' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"orderId": "a4f60d8d-2957-46cb-9fff-126367e7fdc6"}'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": ""
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/trade/close-order.html b/zh-TW/copy-trade/trade/close-order.html index 051b3241b4..382310784c 100644 --- a/zh-TW/copy-trade/trade/close-order.html +++ b/zh-TW/copy-trade/trade/close-order.html @@ -4,13 +4,13 @@ 交易員發起平倉-訂單 | Bybit API Documentation - +

    交易員發起平倉-訂單

    交易員發起平倉-訂單

    HTTP 請求

    POST /contract/v3/private/copytrading/order/close

    請求參數

    參數是否必須類型說明
    symboltruestring合約類型
    orderLinkIdfalsestring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復
    parentOrderIdfalsestring訂單ID。如果未填parentOrderLinkId, 則該字段為必填
    parentOrderLinkIdfalsestring機構ID。如果未填parentOrderId, 則該字段為必填

    返回參數

    參數類型說明
    orderIdstring用戶ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/close' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{"symbol":"BTCUSDT","parentOrderId":"cf252fd5-f25f-4623-9080-c60201b22575"}'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": ""
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/trade/create-order.html b/zh-TW/copy-trade/trade/create-order.html index 3639345eab..66a5686925 100644 --- a/zh-TW/copy-trade/trade/create-order.html +++ b/zh-TW/copy-trade/trade/create-order.html @@ -4,13 +4,13 @@ 交易員創建訂單 | Bybit API Documentation - +

    交易員創建訂單

    交易員創建訂單

    HTTP 請求

    POST /contract/v3/private/copytrading/order/create

    請求參數

    參數是否必須類型說明
    sidetruestring方向
    symboltruestring合約類型
    orderTypetruestring委托單價格類型
    qtytruestring委托數量
    pricefalsestring委托價格
    takeProfitfalsestring止盈價格
    stopLossfalsestring止損價格
    tpTriggerByfalsestring止盈激活價格類型,默認為LastPrice
    slTriggerByfalsestring止損激活價格類型,默認為LastPrice
    orderLinkIdfalsestring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/contract/v3/private/copytrading/order/create' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1670831398044' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json; charset=utf-8' \
    --data-raw '{"side":"Sell","symbol":"BTCUSDT","orderType":"Limit","qty":"0.001","price":"20000","takeProfit":"0","stopLoss":"0","tpTriggerBy":"LastPrice","slTriggerBy":"LastPrice"}'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "orderId": "419190fe-016c-469a-810e-936bef2f5d59",
    "orderLinkId": "234590fe-016c-44f6-fg78"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/trade/get-order.html b/zh-TW/copy-trade/trade/get-order.html index 6d9746b748..7c0fd63984 100644 --- a/zh-TW/copy-trade/trade/get-order.html +++ b/zh-TW/copy-trade/trade/get-order.html @@ -4,13 +4,13 @@ 查詢交易員歷史帶單訂單 | Bybit API Documentation - +

    查詢交易員歷史帶單訂單

    查詢交易員帶單訂單

    HTTP 請求

    GET /contract/v3/private/copytrading/order/list

    請求參數

    參數是否必須類型說明
    symbolfalsestring合約類型
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復
    copyTradeOrderTypefalsestring跟單交易委托單類型

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復
    symbolstring合約類型
    sidestring方向
    pricestring委托價格
    qtystring委托數量
    timeInForcestring執行策略
    isIsolatedboolean是否逐倉,true-逐倉 false-全倉
    leveragestring逐倉模式下, 值為用戶設置的杠桿;全倉模式下,值為當前風險限額下最大杠桿
    copyTradeOrderStatusstring跟單交易記錄類型
    leavesQtystring剩余委托數量
    leavesValuestring剩余掛單數量對應的預估價值
    cumExecValuestring累計成交價值
    cumExecFeestring累計成交手續費
    takeProfitstring止盈價格
    stopLossstring止損價格
    tpTriggerBystring止盈激活價格類型,默認為LastPrice
    slTriggerBystring止損激活價格類型,默認為LastPrice
    createdTimestring創建時間 (毫秒)
    updatedTimestring更新時間 (毫秒)

    請求示例

    curl "https://api-testnet.bybit.com/contract/v3/private/copytrading/order/list?api_key={api_key}&timestamp={timestamp}&sign={sign}&symbol=ETHUSDT"

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "orderId": "ae0700f6-c990-4de5-9d6e-0fdf8d5aabea",
    "symbol": "ETHUSDT",
    "orderLinkId": "234500f6-c45f-4de5-9d6e",
    "side": "Sell",
    "copyTradeOrderStatus": "New",
    "price": "4000.00",
    "qty": "5.55",
    "timeInForce": "GoodTillCancel",
    "leavesQty": "5.55",
    "isIsolated": true,
    "leavesValue": "22200",
    "leverage": "44",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "createdTime": "1652216213331",
    "updatedTime": "1652216213365"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/trade/trading-stop.html b/zh-TW/copy-trade/trade/trading-stop.html index 3de17e3205..b38a3e7f93 100644 --- a/zh-TW/copy-trade/trade/trading-stop.html +++ b/zh-TW/copy-trade/trade/trading-stop.html @@ -4,13 +4,13 @@ 設置止盈止損 | Bybit API Documentation - +

    設置止盈止損

    設置止盈止損

    HTTP 請求

    POST /contract/v3/private/copytrading/order/trading-stop

    請求參數

    參數是否必須類型說明
    symboltruestring合約類型
    parentOrderIdtruestring母訂單Id
    takeProfitfalsestring止盈觸發價格. 傳 0, 表示清除止盈設置; 傳"", 表示不做修改
    stopLossfalsestring止損觸發價格. 傳 0, 表示清除止損設置; 傳"", 表示不做修改
    tpTriggerByfalsestring止盈激活價格類型,默認為LastPrice
    slTriggerByfalsestring止損激活價格類型,默認為LastPrice
    parentOrderLinkIdfalsestring母訂單orderLinkID

    返回參數

    參數類型說明

    請求示例

    curl --location --request POST 'https://api.bybit.com/contract/v3/private/copytrading/order/trading-stop' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662026807816' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "parentOrderId": "XXXXXXXX",
    "takeProfit": "0",
    "stopLoss": "0",
    "tpTriggerBy": "MarkPrice",
    "slTriggerBy": "LastPrice",
    "parentOrderLinkId": "XXXXXXXX"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {}
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-private/execution.html b/zh-TW/copy-trade/ws-private/execution.html index 0f808a463a..c7152a8b25 100644 --- a/zh-TW/copy-trade/ws-private/execution.html +++ b/zh-TW/copy-trade/ws-private/execution.html @@ -4,14 +4,14 @@ 成交 | Bybit API Documentation - +

    成交

    Topic:
    copyTradeExecution

    返回參數

    ParameterTypeComments
    orderIdstring訂單ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復
    symbolstring合約類型
    sidestring方向
    execIdstring成交ID
    execQtystring成交數量
    execTypestring交易類型(不能為"Funding")
    execFeestring交易手續費
    pricestring成交價格
    orderQtystring訂單數量
    tradeTimenumber交易時間

    請求訂閱

    ws.send('{"op": "subscribe", "args": ["copyTradeExecution"]}')

    響應示例

    {
    "topic": "copyTradeExecution",
    "data": [
    {
    "orderId": "6d667921-3cf4-4efd-b93f-727bd10a3b62",
    "orderLinkId": "w11a313223ddd132111",
    "symbol": "ETHUSDT",
    "side": "Sell",
    "execId": "0182b08b-a3ce-5038-a8be-5e1e9f862e90",
    "execQty": "0.010000",
    "execType": "Trade",
    "execFee": "0.01175970",
    "price": "1863.250000",
    "orderQty": "0.010000",
    "tradeTime": 1652932133873
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-private/order.html b/zh-TW/copy-trade/ws-private/order.html index 2fd4a9af9a..b8e35d81f8 100644 --- a/zh-TW/copy-trade/ws-private/order.html +++ b/zh-TW/copy-trade/ws-private/order.html @@ -4,14 +4,14 @@ 訂單 | Bybit API Documentation - +

    訂單

    Topic:
    copyTradeOrder

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring機構自定義訂單ID, 最大長度36位,且同一機構下自定義ID不可重復
    symbolstring合約類型
    orderTypestring委托單下單類型
    pricestring委托價格
    qtystring成交數量
    sidestring方向
    positionIdxstringPosition idx, 用於在不同倉位模式下標識倉位:1-雙向持倉Buy; 2-雙向持倉Sell
    cumExecFeestring累計成交手續費
    cumExecValuestring累計成交價值
    lastExecPricestring最近一次成交價格
    cumExecQtystring累計成交數量
    takeProfitstring止盈價格
    stopLossstring止損價格
    tpTriggerBystring止盈激活價格類型,默認為LastPrice
    slTriggerBystring止損激活價格類型,默認為LastPrice
    createTimenumber委托時間
    updateTimenumber成交時間
    copyTradeOrderStatusstringcopy trade 訂單狀態

    請求訂閱

    ws.send('{"op": "subscribe", "args": ["copyTradeOrder"]}')

    響應示例

    {
    "topic": "copyTradeOrder",
    "data": [
    {
    "orderId": "6d667921-3cf4-4efd-b93f-727bd10a3b62",
    "orderLinkId": "w11a313223ddd132111",
    "symbol": "ETHUSDT",
    "orderType": "Market",
    "price": "1863.250000",
    "qty": "0.010000",
    "side": "Sell",
    "positionIdx": "2",
    "cumExecFee": "0.01175970",
    "cumExecValue": "19.59950000",
    "lastExecPrice": "1959.949951",
    "cumExecQty": "0.010000",
    "takeProfit": "1750",
    "stopLoss": "2000",
    "tpTriggerBy": "LastPrice",
    "slTriggerBy": "LastPrice",
    "createTime": 1652932133873,
    "updateTime": 1652932133892,
    "copyTradeOrderStatus": "OpenOrderFilled"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-private/position.html b/zh-TW/copy-trade/ws-private/position.html index 1edd19ec7c..a4dfc7e932 100644 --- a/zh-TW/copy-trade/ws-private/position.html +++ b/zh-TW/copy-trade/ws-private/position.html @@ -4,14 +4,14 @@ 持倉 | Bybit API Documentation - +

    持倉

    Topic:
    copyTradePosition

    返回參數

    參數類型說明
    symbolstring合約類型
    positionIdxstringPosition idx, 用於在不同倉位模式下標識倉位:1-雙向持倉Buy; 2-雙向持倉Sell
    positionValuestring倉位價值
    riskIdinteger風險限額ID
    leveragestring逐倉模式下, 值為用戶設置的杠桿
    isolatedboolean是否逐倉,true-逐倉 false-全倉
    sidestring方向
    sizestring倉位數量
    unrealisedPnlstring未結盈虧
    liqPricestring強平價格
    bustPricestring破產價格
    entryPricestring平均入場價
    positionMarginstring倉位保證金
    orderMarginstring委托預占用保證金
    occClosingFeestring倉位占用的平倉手續費
    cumRealisedPnlstring累計已結盈虧
    positionStatusstring倉位狀態,Normal: 正常,Liq: 強平,Adl: 減倉
    positionSeqnumber倉位變化版本號

    請求訂閱

    ws.send('{"op": "subscribe", "args": ["copyTradePosition"]}')

    響應示例

    {
    "topic": "copyTradePosition",
    "data": [
    {
    "symbol": "ETHUSDT",
    "positionIdx": "2",
    "positionValue": "80.05065626",
    "riskId": 11,
    "leverage": "10.000000",
    "isIsolated": true,
    "side": "Sell",
    "size": "0.040000",
    "unrealisedPnl": "1.62665626",
    "liqPrice": "2191.350098",
    "bustPrice": "2201.350098",
    "entryPrice": "2001.26640650",
    "positionMargin": "8.00506666",
    "orderMargin": "0.00000000",
    "occClosingFee": "0.05283240",
    "cumRealisedPnl": "0.55284374",
    "positionStatus": "Normal",
    "positionSeq": 0
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-private/wallet.html b/zh-TW/copy-trade/ws-private/wallet.html index b371833633..fdb3ba604f 100644 --- a/zh-TW/copy-trade/ws-private/wallet.html +++ b/zh-TW/copy-trade/ws-private/wallet.html @@ -4,14 +4,14 @@ 錢包 | Bybit API Documentation - +

    錢包

    Topic:
    copyTradeWallet

    返回參數

    參數類型說明
    walletBalancenumber錢包余額
    availableBalancenumber可用余額 = wallet balance - used margin

    請求訂閱

    ws.send('{"op": "subscribe", "args": ["copyTradeWallet"]}')

    響應示例

    {
    "topic": "copyTradeWallet",
    "data": {
    "walletBalance": "14009.12164704",
    "availableBalance": "13998.97749271"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-public/kline.html b/zh-TW/copy-trade/ws-public/kline.html index 375e17c110..c73ca871a2 100644 --- a/zh-TW/copy-trade/ws-public/kline.html +++ b/zh-TW/copy-trade/ws-public/kline.html @@ -4,14 +4,14 @@ K線 | Bybit API Documentation - +

    K線

    訂閱K線數據

    可用時間粒度:

    • 1 3 5 15 30 60 120 240 360 720分鐘
    • D
    • W
    • M
    信息

    註意如果字段confirm為true, 則表明這是這根K線的最後一個tick;否則,這只是一個快照數據,即中間價格

    推送頻率: 1-60s

    Topic: kline.{interval}.{symbol} e.g., kline.30.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > startnumber開始時間戳 (毫秒)
    > endnumber結束時間戳 (毫秒). 若時間還未到時間跨度的最後時間,則表示當前時間
    > intervalstringK線粒度
    > openstring開盤價
    > closestring收盤價
    > highstring最高價
    > lowstring最低價
    > volumestring交易量
    > turnoverstring交易額
    > confirmboolean是否確認
    > timestampnumber蠟燭中最後一筆淨值時間戳 (毫秒)

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "kline.5.BTCUSDT"
    ],
    "req_id": "test" // 可選
    }

    推送示例

    {
    "topic": "kline.5.BTCUSDT",
    "data": [
    {
    "start": 1671187800000,
    "end": 1671188099999,
    "interval": "5",
    "open": "16991",
    "close": "16980.5",
    "high": "16991",
    "low": "16980.5",
    "volume": "2.501",
    "turnover": "42493.2305",
    "confirm": false,
    "timestamp": 1671187815755
    }
    ],
    "ts": 1671187815755,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-public/liquidation.html b/zh-TW/copy-trade/ws-public/liquidation.html index 8ef5f771bd..c53f29d353 100644 --- a/zh-TW/copy-trade/ws-public/liquidation.html +++ b/zh-TW/copy-trade/ws-public/liquidation.html @@ -4,14 +4,14 @@ 強平推送 | Bybit API Documentation - +

    強平推送

    訂閱Bybit平台上的期貨強平推送

    推送頻率: 實時

    Topic: liquidation.{symbol} e.g., liquidation.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > updatedTimenumber數據更新時間戳 (毫秒)
    > symbolstring合約名稱
    > sizestring成交數量
    > pricestring成交價格
    > sidestring方向

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "liquidation.GALAUSDT"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-public/orderbook.html b/zh-TW/copy-trade/ws-public/orderbook.html index 8b8375b890..10e2b5fcc3 100644 --- a/zh-TW/copy-trade/ws-public/orderbook.html +++ b/zh-TW/copy-trade/ws-public/orderbook.html @@ -4,14 +4,14 @@ 深度 | Bybit API Documentation - +

    深度

    訂閱不同深度的推送

    信息
    • 訂閱成功後,會立即得到一個當前快照包的推送消息.
    • websocket將會繼續推送這些增量數據. 收到snapshot的報文,就需要重置本地的orderbook.
    • snapshot=全量orderbook, delta=增量orderbook
    • 如果因為Bybit服務原因,會重新發送snapshot報文,該報文已保證是最新且準確的.
    提示

    1檔數據: 若3秒內無變化,將會再次推送snapshot數據.

    • 1 檔數據, 推送頻率: 10ms
    • 50 檔數據, 推送頻率: 20ms
    • 200 檔數據, 推送頻率: 100ms

    Topic:
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot,delta
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > sstring合約名稱
    > barrayBid, 買方. 按照價格從大到小
    >> b[0]string買方報價
    >> b[1]string買方數量
    > aarrayAsk, 賣方. 按照價格從小到大
    >> a[0]string賣方報價
    >> a[1]string賣方數量
    uinteger更新id, 一般情況下該id是連續的。偶爾會因後台的重啟而發送"u"=1的全量數據,接收到後請覆蓋本地保存的orderbook
    seqinteger撮合版本號

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "orderbook.50.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1671179923028,
    "data": {
    "s": "BTCUSDT",
    "b": [
    [
    "17440.00",
    "40.833"
    ],
    [
    "17439.50",
    "0.513"
    ],
    ...
    [
    "17416.00",
    "6.156"
    ],
    [
    "17415.50",
    "32.268"
    ]
    ],
    "a": [
    [
    "17440.50",
    "78.815"
    ],
    [
    "17441.00",
    "8.858"
    ],
    ...
    [
    "17464.50",
    "4.901"
    ],
    [
    "17465.00",
    "5.744"
    ]
    ],
    "u": 13079592,
    "seq": 22520573250
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-public/ticker.html b/zh-TW/copy-trade/ws-public/ticker.html index b9f822c9f8..401bdc0704 100644 --- a/zh-TW/copy-trade/ws-public/ticker.html +++ b/zh-TW/copy-trade/ws-public/ticker.html @@ -4,14 +4,14 @@ 行情 | Bybit API Documentation - +

    行情

    訂閱行情數據

    重要

    該topic推送delta數據和snapshot数据。如果delta數據為空,表明信息沒有發生變化。

    推送頻率: 實時

    Topic: tickers.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名稱
    typestring數據類型. `snapshot`,`delta`
    csinteger撮合版本號
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > symbolstring合約名稱
    > tickDirectionstring價格變化方向
    > price24hPcntstring市場價格相對24h前變化的百分比
    > lastPricestring最新市場成交價
    > prevPrice24hstring24小時前的整點市價
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價
    > prevPrice1hstring1小時前的整點市價
    > markPricestring標記價格
    > indexPricestring指數價格
    > openIntereststring未平倉合約的數量
    > openInterestValuestring未平倉合約的價值
    > turnover24hstring最近24小時成交額
    > volume24hstring最近24小時成交量
    > nextFundingTimestring下次結算資金費用的時間戳 (毫秒)
    > fundingRatestring資金費率
    > bid1Pricestring買1價
    > bid1Sizestring買1價的數量
    > ask1Pricestring賣1價
    > ask1Sizestring賣1價的數量

    推送示例

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "MinusTick",
    "price24hPcnt": "0.017367",
    "lastPrice": "17222.00",
    "prevPrice24h": "16928.00",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17224.40",
    "indexPrice": "17234.84",
    "openInterest": "68795.534",
    "openInterestValue": "1184961795.83",
    "turnover24h": "1572429119.324499",
    "volume24h": "91823.449",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000211",
    "bid1Price": "17222.00",
    "bid1Size": "220.358",
    "ask1Price": "17222.50",
    "ask1Size": "3.902"
    },
    "cs": 24988405605,
    "ts": 1673273043686
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws-public/trade.html b/zh-TW/copy-trade/ws-public/trade.html index 0dc4ade3d1..c62fd9af37 100644 --- a/zh-TW/copy-trade/ws-public/trade.html +++ b/zh-TW/copy-trade/ws-public/trade.html @@ -4,14 +4,14 @@ 平台成交 | Bybit API Documentation - +

    平台成交

    訂閱Bybit平台上最近成交的推送. 從用戶訂閱開始, 實時推送增量交易歷史, 有成交數據就推送.

    推送頻率: 實時

    Topic: publicTrade.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > Tnumber成交時間戳 (毫秒)
    > sstring合約名稱
    > Sstring方向. Buy,Sell
    > vstring成交數量
    > pstring成交價格
    > Lstring價格變化的方向
    > istring成交Id
    > BTboolean成交類型是否為大宗交易

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "publicTrade.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "topic": "publicTrade.BTCUSDT",
    "type": "snapshot",
    "ts": 1671181689023,
    "data": [
    {
    "T": 1671181689021,
    "s": "BTCUSDT",
    "S": "Buy",
    "v": "0.002",
    "p": "17032.50",
    "L": "MinusTick",
    "i": "d9cd8295-40dc-5dce-8deb-42882580a7ab",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/copy-trade/ws/connect.html b/zh-TW/copy-trade/ws/connect.html index 71821409e4..d4fd826e42 100644 --- a/zh-TW/copy-trade/ws/connect.html +++ b/zh-TW/copy-trade/ws/connect.html @@ -4,14 +4,14 @@ 訂閱WebSocket | Bybit API Documentation - +

    訂閱WebSocket

    警告

    請注意,目前copytrading只支持正向永續,以下接口僅適用於 正向永續

    訂閱地址:
    測試網:

    • 公有頻道: wss://stream-testnet.bybit.com/contract/usdt/public/v3
    • 私有頻道: wss://stream-testnet.bybit.com/realtime_private

    主網:

    • 公有頻道: wss://stream.bybit.com/contract/usdt/public/v3
    • 私有頻道: wss://stream.bybit.com/realtime_private
    信息

    公有頻道不需要鑒權. 以下內容僅適用於私有頻道的訂閱

    構建連接時,創建鑒權請求。

    注意: 如果您正在使用pybit, bybit-api或者其他第三方庫, 您可以忽略此項-因為鑒權已經內建。

    {
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //過期時間應當大於當前時間戳
    "singature"
    ]
    }
    # 基於: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # 生成expires
    expires = int((time.time() + 1) * 1000)

    # 生成簽名
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # 發送鑒權請求
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    鑒權成功的響應示例

    {
    "success": true,
    "ret_msg": "",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "auth",
    "args": [
    "OZUDHROKUZZNVZWHKN",
    "1673261297304",
    "63ae5f1064130d8e931b5d937500461b87c00b2a939284e455fe8ea1e27387f6"
    ]
    }
    }
    信息

    簽名生成的示例可以參考這裡

    警告

    由於網絡的複雜性,您可能隨時遇到斷連。請參考以下建議確保您能即時接收到推送:

    1. 通過發送心跳
    2. 遇到斷連時,立即重新連接

    IP限頻

    • 不要嘗試頻繁地構建連接與斷開連接;
    • 不要在5分鐘內構建超過500個連接。

    如何發送心跳

    發送ping的示例

    ws.send('{"op":"ping"}');

    接收到pong的響應示例

    // 公共頻道的Pong示例
    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "13271fcb-53ed-4e80-948e-2bdbe3a6587d",
    "req_id": "",
    "op": "ping"
    }
    // 私有頻道的Pong示例
    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "ping",
    "args": null
    }
    }
    警告

    為了維持連接,我們推薦您每20秒發送一次心跳。

    如何訂閱topic

    理解Websocket裡的args

    通過傳入args來訂閱指定topic

    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    通過","來訂閱同一個topic下的多個交易對

    // 示例: 訂閱trade下的BTCUSDT和ETHUSDT
    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "publicTrade.BTCUSDT",
    "publicTrade.ETHUSDT"
    ]
    }

    訂閱多個topic

    ws.send('{"op": "subscribe", "args": ["orderbook.1.BTCUSDT","publicTrade.BTCUSDT","orderbook.1.ETHUSDT]}')

    理解如何取消訂閱

    您可以通過發送請求來動態地停止訂閱

    ws.send('{"op": "unsubscribe", "args": ["publicTrade.BTCUSDT"]}');
    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.BTCUSDT"
    ]
    }

    理解訂閱的響應

    訂閱成功後的響應示例

    // 公共頻道的訂閱響應
    {
    "success": true,
    "ret_msg": "",
    "conn_id": "322b49ce-d6a5-494a-9019-f1d51cd541ae",
    "req_id": "",
    "op": "subscribe"
    }
    // 私有頻道的訂閱響應
    {
    "success": true,
    "ret_msg": "",
    "conn_id": "16c79bf6-267d-4e06-a0c1-3ca4ed3a293d",
    "request": {
    "op": "subscribe",
    "args": [
    "copyTradePosition",
    "copyTradeOrder",
    "copyTradeExecution"
    ]
    }
    }

    訂閱成功後,您將收到結果信息。可以根據響應判斷訂閱是否成功。

    - + \ No newline at end of file diff --git a/zh-TW/copy_trading.html b/zh-TW/copy_trading.html index 19e89d53bb..1fec11d6a4 100644 --- a/zh-TW/copy_trading.html +++ b/zh-TW/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/copytrade/public/instrument-info.html b/zh-TW/copytrade/public/instrument-info.html index 0135661105..9d70652d98 100644 --- a/zh-TW/copytrade/public/instrument-info.html +++ b/zh-TW/copytrade/public/instrument-info.html @@ -4,13 +4,13 @@ 交易員獲取可帶單合約規格 | Bybit API Documentation - +

    交易員獲取可帶單合約規格

    交易員獲取可帶單合約的規格

    提示

    該接口是公共接口,無需鑒權

    HTTP 請求

    GET /contract/v3/public/copytrading/symbol/list

    請求參數

    返回參數

    參數類型說明
    listarrayObject
    > symbolstring合約類型
    > baseCurrencystring基礎貨幣
    > quoteCurrencystring報價貨幣
    > priceScalestring價格範圍(可以提交價格的小數位數,儘管最終價格可能會四捨五入以符合 價格最小增加或減少數量)
    > takerFeestringtaker 手續費
    > makerFeestringmaker 手續費
    > fundingIntervalstring資金費用結算週期
    > leverageFilterObject槓桿屬性
    >> maxLeveragestring最大杠桿數 (假設在最低風險限額設置時候的最大槓桿數)
    >> minLeveragestring最小杠桿數
    > priceFilterObject價格屬性
    >> minPricestring最小價格
    >> maxPricestring最大價格
    >> tickSizestring價格最小增加或減少數量
    > lotSizeFilterObject下單數量屬性
    >> qtyStepstring合約數量最小單位
    >> maxOrderQtystring最大交易數量
    >> minOrderQtystring最小交易數量

    請求示例

    curl https://api-testnet.bybit.com/contract/v3/public/copytrading/symbol/list

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "baseCurrency": "BTC",
    "quoteCurrency": "USDT",
    "priceScale": "1",
    "takerFee": "0.00075",
    "makerFee": "-0.00025",
    "fundingInterval": "480",
    "leverageFilter": {
    "maxLeverage": "100",
    "minLeverage": "1"
    },
    "priceFilter": {
    "minPrice": "0.5",
    "maxPrice": "999999.0",
    "tickSize": "0.5"
    },
    "lotSizeFilter": {
    "qtyStep": "0.001",
    "maxOrderQty": "100.000",
    "minOrderQty": "0.001"
    }
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/auto-margin.html b/zh-TW/derivatives/contract/auto-margin.html index 38e5e72e7c..153fb0f790 100644 --- a/zh-TW/derivatives/contract/auto-margin.html +++ b/zh-TW/derivatives/contract/auto-margin.html @@ -4,13 +4,13 @@ 設置自動追加保證金 | Bybit API Documentation - +

    設置自動追加保證金

    開關自動追加保證金. 欲了解更多,請參閱這裡

    提示

    該功能僅支持逐倉模式下的USDT永續

    HTTP 請求

    POST /contract/v3/private/position/set-auto-add-margin

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    sidetruestring方向. Buy,Sell
    autoAddMargintrueinteger開關自動追加保證金. 0: 關閉. 1: 打開
    positionIdxtrueinteger倉位標識符

    響應參數

    請求示例

    POST /contract/v3/private/position/set-auto-add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670826151188
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "ETHUSDT",
    "side": "Buy",
    "autoAddMargin": 1,
    "positionIdx": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670826151500
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/cancel-all.html b/zh-TW/derivatives/contract/cancel-all.html index dec1be2729..abb9906415 100644 --- a/zh-TW/derivatives/contract/cancel-all.html +++ b/zh-TW/derivatives/contract/cancel-all.html @@ -4,13 +4,13 @@ 撤銷所有訂單 | Bybit API Documentation - +

    撤銷所有訂單

    撤銷全部委託單

    提示
    • baseCoin, settleCoin, symbol三個參數必傳其中一個

    HTTP 請求

    POST /contract/v3/private/order/cancel-all

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種
    settleCoinfalsestring結算幣種

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> orderIdstring訂單ID
    >> orderLinkIdstring用戶自定義ID

    请求示例

    POST /contract/v3/private/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670571959925
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "settleCoin": "USDT",
    "symbol": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "4545cab5-0f98-45c4-b137-6c42f3b33d4a",
    "orderLinkId": ""
    },
    {
    "orderId": "66c1beaf-aadd-4b36-be37-7f80ec315422",
    "orderLinkId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670571961179
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/cancel.html b/zh-TW/derivatives/contract/cancel.html index 8306d19171..d607431833 100644 --- a/zh-TW/derivatives/contract/cancel.html +++ b/zh-TW/derivatives/contract/cancel.html @@ -4,13 +4,13 @@ 撤銷委託單 | Bybit API Documentation - +

    撤銷委託單

    備註
    • 您必須指定orderId或者orderLinkId.
    • orderIdorderLinkId之間不匹配, 系統將會優先處理orderId.
    • 您只能撤銷未成交和部分成交的訂單.

    HTTP 請求

    POST /contract/v3/private/order/cancel

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個

    響應參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring用戶自定義訂單ID

    请求示例

    POST /contract/v3/private/order/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670570871662
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "BTCUSDT",
    "orderLinkId": null,
    "orderId": "a0c76874-1777-48dd-9f99-b4120ec71cc0"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "a0c76874-1777-48dd-9f99-b4120ec71cc0",
    "orderLinkId": "xrp_12"
    },
    "retExtInfo": {},
    "time": 1670570872075
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/closepnl.html b/zh-TW/derivatives/contract/closepnl.html index cb829068e6..040a3f4429 100644 --- a/zh-TW/derivatives/contract/closepnl.html +++ b/zh-TW/derivatives/contract/closepnl.html @@ -4,13 +4,13 @@ 查詢平倉盈虧 | Bybit API Documentation - +

    查詢平倉盈虧

    獲取當前用戶的所有平倉盈虧數據,返回結果按照createdTime降序排列.

    信息

    支持 USDT永續, 反向永續和反向交割

    查詢時間範圍:

    • 指定的了startTimeendTime, 您可以查詢過去2年的數據
    • 若不指定startTimeendTime, 默認返回近6個月的數據

    HTTP 請求

    GET /contract/v3/private/position/closed-pnl

    請求參數

    參數是否必需類型說明
    symboltruestring產品類型
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 200]. default: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > sidestring買賣方向. Buy, Side
    > qtystring訂單數量
    > leveragestring持倉槓桿
    > orderPricestring訂單價格
    > orderTypestring訂單類型. Market,Limit
    > execTypestring執行類型
    > closedSizestring平倉數量
    > cumEntryValuestring被平倉位的累計入場價值
    > avgEntryPricestring平均入場價格
    > cumExitValuestring被平倉位的累計出場價值
    > avgExitPricestring平均出場價格
    > closedPnlstring被平倉位的盈虧
    > fillCountstring單筆訂單的成交筆數
    > createdAtstring訂單創建時間, 同createdTime
    > createdTimestring訂單創建時間, 同createdAt
    > updatedTimestring訂單更新時間
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /contract/v3/private/position/closed-pnl?symbol=ETHUSDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670855140626
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "orderId": "ee650123-74bf-4094-aadb-efa139d99c50",
    "side": "Buy",
    "qty": "0.30",
    "orderPrice": "1314.75",
    "orderType": "Market",
    "execType": "Trade",
    "closedSize": "0.30",
    "cumEntryValue": "373.71078947",
    "avgEntryPrice": "1245.7026",
    "cumExitValue": "375.532",
    "avgExitPrice": "1251.7734",
    "closedPnl": "-2.27050237",
    "fillCount": "2",
    "leverage": "50",
    "createdAt": "1670838034412",
    "createdTime": "1670838034412",
    "updatedTime": "1670838034450"
    }
    ],
    "nextPageCursor": "eyJza2lwX2xvY2FsX3N5bWJvbCI6ZmFsc2UsInBhZ2VfdG9rZW4iOiJleUpOSWpwN0lsOTFjM2N4WHlJNmV5SkNJam9pUVRnMlZFcEJSVWRCVVVVOUluMHNJbkJySWpwN0lrSWlPaUpLUjFac1RtcFZkMDFVU1hwTVZHTXdXVzFaZEU1RVFUVk9RekZvV1ZkU2FVeFhWbTFaVkVWNlQxZFJOVTlYVFRGTlFUMDlJbjBzSWw5emExOGlPbnNpUWlJNklrWjZRVU5XZGpWcVkyTXlSblJoTTJSQlp6MDlJbjE5ZlE9PSJ9"
    },
    "retExtInfo": {},
    "time": 1670855140831
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/confirm-mmr.html b/zh-TW/derivatives/contract/confirm-mmr.html index 6c72315e3a..09e5cb04ed 100644 --- a/zh-TW/derivatives/contract/confirm-mmr.html +++ b/zh-TW/derivatives/contract/confirm-mmr.html @@ -4,14 +4,14 @@ 確認新的風險限額 | Bybit API Documentation - +

    確認新的風險限額

    僅適用於當用戶被標記為僅減倉時(請看持倉接口中的isReduceOnly字段), 在用戶主動調整風險水位後, 調用該接口來試算調整後的風 險水平, 若通過(retCode=0), 則系統會移除僅減倉標記, 推薦自行再調用下倉位接口確認isReduceOnly字段是否變成false

    HTTP 請求

    POST /contract/v3/private/position/confirm-pending-mmr

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱

    響應參數

    請求示例

    POST /contract/v3/private/position/confirm-pending-mmr HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698051546759
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 32

    {

    "symbol": "BTCUSDT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698051124588
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/cross-isolated.html b/zh-TW/derivatives/contract/cross-isolated.html index e2a8321033..8e0456b050 100644 --- a/zh-TW/derivatives/contract/cross-isolated.html +++ b/zh-TW/derivatives/contract/cross-isolated.html @@ -4,13 +4,13 @@ 切換全倉/逐倉 | Bybit API Documentation - +

    切換全倉/逐倉

    切換全倉/逐倉模式. 欲了解更多,請參閱這裡

    信息

    支持USDT永續,反向永續和反向交割

    HTTP 請求

    POST /contract/v3/private/position/switch-isolated

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    tradeModetrueinteger0: 全倉. 1: 逐倉
    buyLeveragetruestring買方向的槓桿倍數. 確保buyLeverage等於sellLeverage
    sellLeveragetruestring賣方向的槓桿倍數. 確保buyLeverage等於sellLeverage

    響應參數

    請求示例

    POST /contract/v3/private/position/switch-isolated HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670848559156
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSDT",
    "tradeMode": 1,
    "buyLeverage": "8",
    "sellLeverage": "8"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670848559569
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/execution-list.html b/zh-TW/derivatives/contract/execution-list.html index 437524f9aa..5cd5057289 100644 --- a/zh-TW/derivatives/contract/execution-list.html +++ b/zh-TW/derivatives/contract/execution-list.html @@ -4,13 +4,13 @@ 查詢成交紀錄 | Bybit API Documentation - +

    查詢成交紀錄

    獲取用戶成交紀錄,返回結果按execTime降序排列

    支持時間範圍:

    • USDT永續, 反向永續, 反向交割: 過去兩年
    提示

    單筆訂單可能會有多次成交

    HTTP 請求

    GET /contract/v3/private/execution/list

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    orderIdfalsestring訂單ID
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    execTypefalsestring成交類型
    limitfalseinteger每頁數量限制. [1, 100]. default: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義訂單iD
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > orderTypestring訂單類型. 市價單: Market,限價單: Limit
    > stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则不会返回任何类型
    > execFeestring交易手續費
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring交易類型
    > execValuestring成交價值
    > feeRatestring手續費率
    > lastLiquidityIndstring流動性類型. AddedLiquidity, RemovedLiquidity
    > isMakerboolean是否是maker單
    > leavesQtystring剩餘委託未成交價值
    > closedSizestring平倉數量
    > ivstring隱含波動率
    > blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID
    > markPricestring成交執行時,該 symbol 當時的標記價格
    > indexPricestring成交執行時,該 symbol 當時的指數價格
    > markIvstring標記價格的隱含波動率
    > underlyingPricestring成交執行時,該 symbol 當時的底層資產價格
    > execTimestring成交時間(毫秒)

    請求示例

    GET /contract/v3/private/execution/list?symbol=ETHUSDT&limit=1&category=linear HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670853954362
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "execFee": "-0.08720013",
    "execId": "208751d8-f70e-4570-a5fd-d208c82af99d",
    "execPrice": "1263.77",
    "execQty": "0.69",
    "execType": "Funding",
    "execValue": "872.0013",
    "feeRate": "-0.0001",
    "lastLiquidityInd": "UNKNOWN",
    "leavesQty": "0.00",
    "orderId": "1673136000-ETHUSDT-592334-Sell",
    "orderLinkId": "",
    "orderPrice": "0.00",
    "orderQty": "0.00",
    "orderType": "UNKNOWN",
    "stopOrderType": "UNKNOWN",
    "side": "Sell",
    "execTime": "1673136000000",
    "closedSize": "0.00",
    "iv": "",
    "blockTradeId": "",
    "markPrice": "",
    "markIv": "",
    "underlyingPrice": "",
    "indexPrice": "",
    "isMaker": false
    }
    ],
    "nextPageCursor": "ZzU3NlU4M1JlLzhFTWkzeW9hemRVcitqUk4wVW9LL21KVTRWV3JPR0tYTG9uTENWSkFvUDJuWk44OVBlNnB0ZjJHTTFwdlJRV0tpZFM0Z0RzUlQ0d2FSbzVRN2lpZ0ZrZmt2UTZuRlJVSHdQSHdoYXUvdDN6aExzOEpmcDNFY2NLc2dYTnRvOXhmTmY3NVNreVgzQ2RKUFZtekptU0NQNU1rOWd5YzZRV1ZDejVFM0t0MGdlMENNc04ybzQvc2JQQ3BVRkQycHU3MFdBK3RqdFlWaVRkMTNGQmZRUUZpaVc4MkE1SnRCT09iZDRNL2FlNDVSMithdU96NTROWGFxcTFucW1MSnJSaTluM29pZm85dHVkNzJMSVQwODk4UTJLbHEybDJ0Uk9UYmtCcU5ScU9zZWRCa2Znc0dwbmNEOWJoaCtnZkRkWjlrMEl6elRmWnljeHZpYXBPWVdzZSs0UEtvdnZ4cTJHQ2JZcm1UQkU3TXFKS01yU1dmaloyT3pVS1psbmVaamh3N3Ntc0hFbEgwckxtQT09",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1673150404910
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/fee-rate.html b/zh-TW/derivatives/contract/fee-rate.html index 2138a7804f..7b4109f626 100644 --- a/zh-TW/derivatives/contract/fee-rate.html +++ b/zh-TW/derivatives/contract/fee-rate.html @@ -4,13 +4,13 @@ 查詢交易費率 | Bybit API Documentation - +

    查詢交易費率

    獲取用戶的交易手續費率

    HTTP 請求

    GET /contract/v3/private/account/fee-rate

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱

    響應參數

    參數類型說明
    listarrayObject
    > symbolstring合約名稱
    > takerFeeRatestringTaker手續費率
    > makerFeeRatestringMaker手續費率

    請求示例

    GET /contract/v3/private/account/fee-rate?symbol=SOLUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670924049902
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "SOLUSDT",
    "takerFeeRate": "0.0006",
    "makerFeeRate": "0.0001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670924050413
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/leverage.html b/zh-TW/derivatives/contract/leverage.html index 7838fa3cb0..b45e210e44 100644 --- a/zh-TW/derivatives/contract/leverage.html +++ b/zh-TW/derivatives/contract/leverage.html @@ -4,13 +4,13 @@ 設置槓桿倍數 | Bybit API Documentation - +

    設置槓桿倍數

    設置槓桿

    HTTP 請求

    POST /contract/v3/private/position/set-leverage

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    buyLeveragetruestring(0, 風險限額允許的最大槓桿數]. 單倉模式下,buyLeverage需要和sellLeverage保持一致
    sellLeveragetruestring(0, 風險限額允許的最大槓桿數]. 單倉模式下,buyLeverage需要和sellLeverage保持一致

    響應參數

    請求示例

    POST /contract/v3/private/position/set-leverage HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670849911829
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSD",
    "buyLeverage":"20",
    "sellLeverage":"20"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670849912024
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/open-order.html b/zh-TW/derivatives/contract/open-order.html index 38876fd806..c5c64b0698 100644 --- a/zh-TW/derivatives/contract/open-order.html +++ b/zh-TW/derivatives/contract/open-order.html @@ -4,13 +4,13 @@ 查詢實時委託單 | Bybit API Documentation - +

    查詢實時委託單

    實時查詢未成交或部分成交的訂單信息. 若需要查詢更久的訂單紀錄,請使用查詢歷史訂單接口.

    提示
    • 當不指定orderIdorderLinkId時,最多500條紀錄返回
    • 返回的結果將以createdTime從新到舊排序.

    HTTP 請求

    GET /contract/v3/private/order/unfilled-orders

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種
    settleCoinfalsestring結算幣種. symbol,baseCoinsettleCoin必傳其中一個. 優先級: symbol > baseCoin > settleCoin
    orderIdfalsestring訂單id
    orderLinkIdfalsestring用戶自定義訂單Id
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarraystring
    > symbolstring合約名稱
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義ID
    > sidestringSide. Buy,Sell
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
    > pricestring訂單價格
    > ivstring隱含波動率
    > qtystring訂單數量
    > timeInForcestring執行策略
    > orderStatusstring訂單狀態
    > lastPriceOnCreatedstring下單時的市場價格
    > cancelTypestring訂單被取消類型
    > stopOrderTypestring條件單類型
    > triggerDirectionstring1: 上升時觸發, 2: 下降時觸發
    > triggerBystring觸發價格的觸發類型
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > cumExecQtystring訂單累計成交數量
    > leavesValuestring訂單剩餘未成交的價值
    > leavesQtystring訂單剩餘未成交的數量
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?. 該字段對期權無效,一直是""
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring訂單創建時間戳 (毫秒)
    > updatedTimestring訂單更新時間戳 (毫秒)

    請求示例

    GET /contract/v3/private/order/unfilled-orders?symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670564324211
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "806f5fc6-d487-46d1-9a57-4b4964126c90",
    "side": "Buy",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "price": "26864.40",
    "qty": "0.003",
    "timeInForce": "PostOnly",
    "orderStatus": "New",
    "triggerPrice": "0.00",
    "orderLinkId": "YLxaWKMiHU",
    "createdTime": "1684810640078",
    "updatedTime": "1684810640080",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "reduceOnly": false,
    "leavesQty": "0.003",
    "leavesValue": "80.5932",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "triggerDirection": 0,
    "cancelType": "UNKNOWN",
    "lastPriceOnCreated": "",
    "iv": "",
    "closeOnTrigger": false,
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ],
    "nextPageCursor": "",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1684810643363
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/order-list.html b/zh-TW/derivatives/contract/order-list.html index f2bea195c5..abfc0da36f 100644 --- a/zh-TW/derivatives/contract/order-list.html +++ b/zh-TW/derivatives/contract/order-list.html @@ -4,13 +4,13 @@ 查詢歷史訂單 | Bybit API Documentation - +

    查詢歷史訂單

    提示

    獲取歷史訂單紀錄. 由於訂單創建/撤銷是異步的, 該接口返回數據可能會有延遲. 若您想實時獲取訂單信息, 您可以查詢該接口或者通過websocket推送(推薦)

    HTTP 請求

    GET /contract/v3/private/order/list

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring用戶自定義訂單ID
    orderStatusfalsestring訂單狀態。不傳則默認查詢所有狀態
    orderFilterfalsestringOrder,StopOrder
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listlistObject
    > symbolstringSymbol name
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義ID
    > sidestring方向. Buy,Sell
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
    > pricestring訂單價格
    > ivstring隱含波動率
    > qtystring訂單數量
    > timeInForcestring執行策略
    > orderStatusstring訂單狀態
    > positionIdxinteger倉位標識. 0: 單向持倉, 1: 買側雙向持倉, 2: 賣側雙向持倉
    > lastPriceOnCreatedstring創建訂單時的市場價
    > cancelTypestring取消類型
    > rejectReasonstring被拒絕原因
    > stopOrderTypestring條件單類型
    > triggerDirectionstring1: 上升時觸發, 2: 下降時觸發
    > triggerBystring觸發價格的觸發類型
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > cumExecQtystring訂單累計成交數量
    > leavesValuestring訂單剩餘未成交的價值
    > leavesQtystring訂單剩餘未成交的數量
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > blockTradeIdstringParadigm 大宗交易ID
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring訂單創建時間戳 (毫秒)
    > updatedTimestring訂單更新時間戳 (毫秒)

    請求示例

    GET /contract/v3/private/order/list?symbol=BTCUSDT&orderId=806f5fc6-d487-46d1-9a57-4b4964126c90 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673420679798
    X-BAPI-RECV-WINDOW: 5000
    cdn-request-id: test-10

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "price": "26864.40",
    "qty": "0.003",
    "reduceOnly": false,
    "timeInForce": "PostOnly",
    "orderStatus": "Cancelled",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "lastPriceOnCreated": "0.00",
    "rejectReason": "EC_PerCancelRequest",
    "orderLinkId": "YLxaWKMiHU",
    "createdTime": "1684810640078",
    "updatedTime": "1684810770380",
    "orderId": "806f5fc6-d487-46d1-9a57-4b4964126c90",
    "stopOrderType": "UNKNOWN",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerPrice": "0.00",
    "closeOnTrigger": false,
    "triggerDirection": 0,
    "positionIdx": 1,
    "cancelType": "CancelByUser",
    "iv": "",
    "triggerBy": "UNKNOWN",
    "blockTradeId": "",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ],
    "nextPageCursor": "eyJza2lwX2xvY2FsX3N5bWJvbCI6ZmFsc2UsInBhZ2VfdG9rZW4iOiIzOTQ3NCJ9",
    "category": ""
    },
    "retExtInfo": {},
    "time": 1684810802126
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/place-order.html b/zh-TW/derivatives/contract/place-order.html index 26d668d045..78f562bf15 100644 --- a/zh-TW/derivatives/contract/place-order.html +++ b/zh-TW/derivatives/contract/place-order.html @@ -4,7 +4,7 @@ 創建委託單 | Bybit API Documentation - + @@ -16,7 +16,7 @@ 該訂單ID去取消活動委托,同時要求您傳遞的自定義訂單ID 最大長度不超過36個字段且唯一

  • 訂單持有上限: 期貨: 單個账户针对合约可持有每个 symbol 最多可同时持有500个普通活动订单。这是针对合约的,因此可以允许出现例如:账户同时持有300个BTCUSD的活动单、 280个ETHUSD合约的活动单。針對條件單,單個帳戶針對合約可持有每個 symbol 最多同時持有 10 個條件單。 期權: 最多可持有100個委託單

  • HTTP 請求

    POST /contract/v3/private/order/create

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    sidetruestring方向. Buy,Sell
    orderTypetruestring訂單類型. Market, Limit
    qtytruestring下單數量
    timeInForcetruestring訂單策略.
    pricefalsestring訂單價格. orderType=Market時,值將被忽略
    positionIdxfalseinteger倉位標識. 0: 單向持倉, 1: 買側雙向持倉, 2: 賣側雙向持倉. 雙向模式下,該字段必傳
    triggerDirectionfalseinteger條件單參數. 用於辨別期望的方向.
    • 1: 當市場價上漲到了triggerPrice時觸發條件單
    • 2: 當市場價下跌到了triggerPrice時觸發條件單
    triggerPricefalsestring條件單觸發價格參數. 若您希望市場價是要上升後觸發, 確保::
    triggerPrice > 市場價格
    否則, triggerPrice < 市場價格
    triggerByfalsestring觸發價格類型. LastPrice, IndexPrice, MarkPrice. 默認: LastPrice
    orderLinkIdfalsestring用戶自定義訂單ID, 最大長度36位,且同一機構下自定義ID支持數字、字母(大小寫)、中劃線、下劃線這些字符的組合
    期貨規則:
    • 該參數選填
    • USDC永續和USDT永續的orderLinkId互相獨立,即orderLinkId可相同
    • 在訂單未完全成交或取消前,orderLinkId需保持不一致; 訂單完全成交或取消後,orderLinkId可使用之前使用過的
    • 期權規則:
    • 該參數必傳
    • 總是唯一
    takeProfitfalsestring止盈價格
    stopLossfalsestring止損價格
    tpTriggerByfalsestring止盈激活價格類型,MarkPrice, IndexPrice, 默認:LastPrice
    slTriggerByfalsestring止損激活價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    reduceOnlyfalseboolean什麼是只減倉? true 將這筆訂單設為只減倉. 只減倉單的止盈止損不生效
    closeOnTriggerfalseboolean什麼是觸發後平倉委託? 此選項可以確保您的止損單被用於減倉(平倉)而非加倉,並且在可用保證金不足的情況下,取消其他委託,騰出保證金以確保平倉委託的執行.
    smpTypefalsestringSmp執行類型. 什麼是SMP?
    tpslModefalsestring止盈止損模式
    • Full: 全部倉位止盈止損. 此時, tpOrderType或者slOrderType必須傳Market
    • Partial: 部分倉位止盈止損. 支持創建限價止盈止損. 注意: 創建限價止盈止損時, tpslMode必傳且為Partial
    tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 僅tpslMode=Partial且tpOrderType=Limit時有效
    slLimitPricefalsestring觸發止損後轉換為限價單的價格. 僅tpslMode=Partial且slOrderType=Limit時有效
    tpOrderTypefalsestring止盈觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持tpOrderType=Market
    slOrderTypefalsestring止損觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持slOrderType=Market

    響應參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring用戶自定義訂單ID

    請求示例

    POST /contract/v3/private/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670487164902
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json; charset=utf-8
    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "qty": "0.05",
    "price": "18500",
    "timeInForce": "GoodTillCancel",
    "positionIdx": null,
    "triggerDirection": 1,
    "triggerPrice": "19000"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "0cf62262-7dc2-4503-9566-8835c841509b",
    "orderLinkId": ""
    },
    "retExtInfo": {},
    "time": 1670486764551
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/position-list.html b/zh-TW/derivatives/contract/position-list.html index 305e763810..61dcc520ba 100644 --- a/zh-TW/derivatives/contract/position-list.html +++ b/zh-TW/derivatives/contract/position-list.html @@ -4,13 +4,13 @@ 查詢持倉 (實時) | Bybit API Documentation - +

    查詢持倉 (實時)

    該接口可以獲取用戶的持倉信息,比如持倉數量,累計盈虧等

    HTTP 請求

    GET /contract/v3/private/position/list

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱
    settleCoinfalsestring結算幣種. 查詢期貨時, symbolsettleCoin二者必傳一個. symbol優先級更高

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > symbolstring合約名称
    > sidestring方向. Buy, Sell. 單倉模式下,無倉位則返回None
    > sizestring當前倉位的數量,按照合約張數計算
    > entryPricestring平均入場價
    > leveragestring槓桿倍數
    > positionValuestring仓位的價值
    > positionIdxinteger倉位標識符, 用于在不同仓位模式下标识仓位
    > riskIdinteger风险限额ID. 參見風險限額接口
    > riskLimitValuestring當前風險限額ID對應的持倉限制量
    > tradeModeinteger0: 全倉模式. 1: 逐倉模式
    > autoAddMargininteger0: 否. 1: 是. 僅適用於逐倉模式
    > positionBalancestring倉位保證金
    > liqPricestring預估強平價. 當強平價 <= minPrice 或者強平價 >= maxPrice時, 則為""
    > bustPricestring預估破產價
    > tpSlModestring該字段已廢棄, 無意義, 總是返回"Full"
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > trailingStopstring追蹤止損(與當前價格的距離)
    > activePricestring追蹤止損的激活價格
    > markPricestring實時標記價格
    > unrealisedPnlstring未结盈亏
    > cumRealisedPnlstring累计已结盈亏
    > positionMMstring倉位維持保證金
    > positionIMstring倉位起始保證金
    > positionStatusstring倉位狀態
    > sessionAvgPricestring結算價格
    > occClosingFeestring預佔用平倉手續費
    > adlRankIndicatorinteger自動減倉燈. 什麼是自動減倉機制?
    > isReduceOnlyboolean僅當Bybit需要降低某個Symbol的風險限額時有用
    • true: 僅允許減倉操作. 您可以考慮一系列的方式, 比如, 降低risk limit檔位, 或者同檔位修改槓桿或減少倉位, 或者增加保證金, 或者撤單, 這些操作做完後, 可以主動調用確認新的風險限額接口
    • false(默認): 沒有交易限制, 表示您的倉位在系統調整時處於風險水平之下
    • 僅對逐倉和全倉的期貨倉位有意義
    > mmrSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改MMR的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了MMR調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > leverageSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改槓桿的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了槓桿調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > createdTimestring倉位創建時間戳 (毫秒)
    > updatedTimestring倉位數據更新時間 (毫秒)

    請求示例

    GET /contract/v3/private/position/list?symbol=ETCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673421074950
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "positionIdx": 0,
    "riskId": 236,
    "symbol": "ETCUSDT",
    "side": "None",
    "size": "0.0",
    "positionValue": "0",
    "entryPrice": "0",
    "tradeMode": 0,
    "autoAddMargin": 0,
    "leverage": "10",
    "positionBalance": "0",
    "liqPrice": "",
    "bustPrice": "0.000",
    "takeProfit": "0.000",
    "stopLoss": "0.000",
    "trailingStop": "0.000",
    "unrealisedPnl": "0",
    "createdTime": "1672986751942",
    "updatedTime": "1675382400091",
    "tpSlMode": "Full",
    "riskLimitValue": "200000",
    "activePrice": "0.000",
    "markPrice": "15.126",
    "cumRealisedPnl": "-10.69094915",
    "positionMM": "0",
    "positionIM": "0",
    "positionStatus": "Normal",
    "sessionAvgPrice": "0.000",
    "occClosingFee": "0",
    "avgPrice": "0",
    "adlRankIndicator": 0,
    "isReduceOnly": false,
    "mmrSysUpdatedTime": "",
    "leverageSysUpdatedTime": ""
    }
    ],
    "category": "",
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1697685149803
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/position-mode.html b/zh-TW/derivatives/contract/position-mode.html index 5cd0fbf69d..3d9c0fd90c 100644 --- a/zh-TW/derivatives/contract/position-mode.html +++ b/zh-TW/derivatives/contract/position-mode.html @@ -4,13 +4,13 @@ 切換倉位模式 | Bybit API Documentation - +

    切換倉位模式

    該接口可以切換USDT永續反向交割的倉位模式。單倉模式下,只能在單方向下持倉; 雙倉模式下,可以同時在兩個方向持倉。

    提示
    • 配置生效的優先級:symbol 配置 > coin 配置 > 系统默认配置
    • 目前系統默認配置:單向持倉模式
    • 如果請求參數中是按照coin的配置參數(此coin=settleCoin),則僅對該settleCoin下無持倉無委託單的symbol進行批量設置,並且未來新上線基於該settleCoin的結算的symol也是該模式。

    舉例

    系統默認coinsymbol
    初始配置單向持倉未設置過未設置過
    生效結果所有USDT正向交易對都是單向持倉
    變更 1--BTCUSDT 設置為雙向持倉模式
    生效結果當前交易對BTCUSDT為雙向持倉,其他交易對都是單向持倉(繼承系統默認規則)
    新上線交易對 ETHUSDT新上線的ETHUSDT為單向持倉 (繼承系統默認規則)
    變更 2-USDT 設置為雙向持倉-
    生效結果當前所有未持倉未有訂單的交易對都是雙向持倉,有持倉和有委託單的交易對不做調整
    新上線交易對 SOLUSDT新上線的SOLUSDT為雙向持倉 (繼承coin規則)
    變更 3--ASXUSDT 設置為單向持倉模式
    生效結果AXSUSDT為單向持倉模式,其餘交易對不做任何變更(繼承coin規則)
    新上線交易對 BITUSDT新上線的BITUSDT為雙向持倉 (繼承coin規則)

    當前合約單雙向持倉切換能力

    非統一保證金模式統一保證金模式
    USDT永續合約支持單雙向持倉僅支持單向持倉
    USDC永續合約僅支持單向持倉僅支持單向持倉
    反向永續合約僅支持單向持倉不支持該模式下交易該合約
    反向交割合約支持單雙向持倉不支持該模式下交易該合約

    HTTP 請求

    POST /contract/v3/private/position/switch-mode

    請求參數

    參數是否必需類型說明
    symbolfalsestring合約名稱. symbolcoin二者必傳一個. symbol優先級更高
    coinfalsestring幣種名稱
    modetrueinteger倉位模式. 0: 單向持倉. 3: 雙向持倉

    響應參數

    請求示例

    POST /contract/v3/private/position/switch-mode HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670848915553
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"CHZUSDT",
    "coin": null,
    "mode": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670848915768
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/replace-order.html b/zh-TW/derivatives/contract/replace-order.html index c9510877ba..2b7ef8423a 100644 --- a/zh-TW/derivatives/contract/replace-order.html +++ b/zh-TW/derivatives/contract/replace-order.html @@ -4,13 +4,13 @@ 修改委託單 | Bybit API Documentation - +

    修改委託單

    備註

    您只能修改那些未成交或者部分成交的訂單。

    HTTP 請求

    POST /contract/v3/private/order/replace

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    pricefalsestring修改後的訂單價格. 若不修改,請不要傳該字段
    qtyfalsestring修改後的訂單數量. 若不修改,請不要傳該字段
    triggerPricefalsestring觸發價格. 若不修改,請不要傳該字段
    takeProfitfalsestring修改後的止盈價格. 若不修改,請不要傳該字段
    stopLossfalsestring修改後的止損價格. 若不修改,請不要傳該字段
    tpTriggerByfalsestring止盈價格觸發類型. 若下單時未設置該值,則調用該接口修改止盈價格時,該字段必傳
    slTriggerByfalsestring止損價格觸發類型. 若下單時未設置該值,則調用該接口修改止損價格時,該字段必傳
    triggerByfalsestring觸發價格的觸發類型. LastPrice, IndexPrice, MarkPrice
    tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效
    slLimitPricefalsestring觸發止損後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效

    響應參數

    參數類型說明
    orderIdstring訂單Id
    orderLinkIdstring用戶自定義訂單Id

    請求示例

    POST /contract/v3/private/order/replace HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670554903846
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "XRPUSDT",
    "orderId": "5ba57394-0ff0-4cb8-8000-59085d2c3aba",
    "orderLinkId": null,
    "price": "14.5"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "5ba57394-0ff0-4cb8-8000-59085d2c3aba",
    "orderLinkId": ""
    },
    "retExtInfo": {},
    "time": 1670554904609
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/set-risk-limit.html b/zh-TW/derivatives/contract/set-risk-limit.html index 8d19a77302..2a7bd8b618 100644 --- a/zh-TW/derivatives/contract/set-risk-limit.html +++ b/zh-TW/derivatives/contract/set-risk-limit.html @@ -4,14 +4,14 @@ 設置風險限額 | Bybit API Documentation - +

    設置風險限額

    風險限額會限制你在不同的保證金要求下的可持倉的最大倉位數量,如果要持有更多的倉位,需要更多的保證金要求。本接口可以設置單個倉位的風險限額, 下單時如果超過當前的風險限額,則會被拒絕。點擊這裡了解更多關於風險限額.

    提示

    您可以獲取通過該接口查詢到風險限額信息.

    HTTP 請求

    POST /contract/v3/private/position/set-risk-limit

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    riskIdtrueinteger風險限額Id
    positionIdxtrueinteger倉位標識,用於標識不同倉位
    • 0: 單向持倉模式
    • 1: 買側雙向模式
    • 2: 賣側雙向模式

    響應參數

    請求示例

    POST /contract/v3/private/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670853142896
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"ETHUSDT",
    "riskId": 12,
    "positionIdx": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670853143027
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/tpsl-mode.html b/zh-TW/derivatives/contract/tpsl-mode.html index b1bc5a2984..a94848912f 100644 --- a/zh-TW/derivatives/contract/tpsl-mode.html +++ b/zh-TW/derivatives/contract/tpsl-mode.html @@ -4,14 +4,14 @@ 切換止盈止損模式 | Bybit API Documentation - +

    切換止盈止損模式

    提示

    某種程度上來說,該接口已經廢棄, 原因在於新版的止盈止損機制是基於訂單維度. 這個接口當初主要是用於倉位維度的止盈止損

    但是, 您仍然可以使用該接口, 為某個合約設置一個隱式的止盈止損模式, 因為當您在下單接口或者設置止盈止損接口時, 不傳入字段"tpslMode"時, 系統將會獲取一個默認值, 該 默認值實際上是源於是否調用過該接口做過修改, 不曾修改過的symbol, 都是默認Full

    可以將止盈止損模式設置為部分止盈止損或者全部止盈止損

    備註

    支持USDT永續, 反向永續和反向交割

    HTTP 請求

    POST /contract/v3/private/position/switch-tpsl-mode

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    tpSlModetruestringFull: 全部倉位止盈止損. Partial: 部分倉位止盈止損

    響應參數

    請求示例

    POST /contract/v3/private/position/switch-tpsl-mode HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670849702461
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol":"BTCUSDT",
    "tpSlMode":"Full"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670849702655
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/trading-stop.html b/zh-TW/derivatives/contract/trading-stop.html index b6e17ab5bb..42f7ee7bfe 100644 --- a/zh-TW/derivatives/contract/trading-stop.html +++ b/zh-TW/derivatives/contract/trading-stop.html @@ -4,14 +4,14 @@ 設置止盈止損 | Bybit API Documentation - +

    設置止盈止損

    該接口可以設置止盈、止損和追蹤止損.

    提示
    • 在提交請求後,系統內部將會自動創建對應類型的條件單
    • 若倉位被平,系統將會調整相關條件訂單數量或者取消這些條件單。
    • 支持USDT永續,USDC永續,反向永續和反向交割.
    信息

    新版止盈止損, 支持既持有全部止盈止損單, 也可以持有部分止盈止損單

    • 全部倉位止盈止損單: 該接口可用於修改該類型的止盈止損單的參數
    • 部分倉位止盈止損單: 該接口僅能新增部分倉位止盈止損單
    備註

    新版止盈止損下, 調用該接口對持倉上的已有的止盈止損進行單邊止盈或者止損修改時, 會導致成對的tp/sl訂單失去綁定關係, 這意味著當通過tp/sl訂單ID調用 取消接口時, 只會取消對應訂單ID的單邊止盈或止損.

    HTTP 請求

    POST /contract/v3/private/position/trading-stop

    請求參數

    參數是否必需類型說明
    symboltruestring合約名稱
    takeProfitfalsestring不能小於0. 設置為0時,則表示取消止盈. 部分止盈止損無法通過設置0來取消
    stopLossfalsestring不能小於0. 設置為0時,則表示取消止損. 部分止盈止損無法通過設置0來取消
    tpSizefalsestring止盈倉位數量. 僅部分止盈止損時有效. 注意: tpSize和slSize的數值必須相等
    slSizefalsestring止盈倉位數量. 僅部分止盈止損時有效. 注意: tpSize和slSize的數值必須相等
    tpTriggerByfalsestring止盈價格類型
    slTriggerByfalsestring止損價格類型
    trailingStopfalsestring不能小於0. 設置為0時,則表示取消追蹤止損. 注意: 僅對USDT永續有效
    activePricefalsestring追蹤止損激活價格. 追蹤止損會在到達該價格時觸發
    tpslModefalsestring止盈止損模式. Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損. 由於每個合約都有初始的止盈止損模式(Full), 若曾經修改過, 那麼可能是Partial, 因此若不傳入, 則系統會自動獲取該合約當前的止盈止損模式配置
    tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 僅tpslMode=Partial且tpOrderType=Limit時有效
    slLimitPricefalsestring觸發止損後轉換為限價單的價格. 僅tpslMode=Partial且slOrderType=Limit時有效
    tpOrderTypefalsestring止盈觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持tpOrderType=Market
    slOrderTypefalsestring止損觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持slOrderType=Market
    positionIdxtrueinteger倉位標識,用於識別倉位.
    • 0: 單向持倉
    • 1: 買側雙向持倉
    • 2: 賣側雙向持倉

    響應參數

    請求示例

    POST /contract/v3/private/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670852788387
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {
    "symbol": "SOLPERP",
    "takeProfit": "19",
    "stopLoss": "10",
    "activePrice": null,
    "trailingStop": null,
    "tpTriggerBy": null,
    "slTriggerBy": null,
    "tpslMode": "Partial",
    "tpOrderType": "Limit"
    "slOrderType": "Limit"
    "tpSize": "50",
    "slSize": "50",
    "tpLimitPrice": "18",
    "slLimitPrice": "11",
    "positionIdx": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1670852788558
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/wallet-fund.html b/zh-TW/derivatives/contract/wallet-fund.html index 067129d39d..2fdded015d 100644 --- a/zh-TW/derivatives/contract/wallet-fund.html +++ b/zh-TW/derivatives/contract/wallet-fund.html @@ -4,13 +4,13 @@ 查詢錢包資金紀錄 | Bybit API Documentation - +

    查詢錢包資金紀錄

    獲取錢包資金紀錄. 這個接口還展示來自網頁上資產兌換下的兌換紀錄, 其中對應的type兌換類型是ExchangeOrderWithdrawExchangeOrderDeposit

    提示
    • 這個接口返回的關於衍生品帳戶下的劃轉紀錄的內容是不完整的。推薦使用帳戶資產API完成資產劃轉的操作和紀錄檢索。
    • 該接口不顯示2021-07-15之後發生的充值提現記錄。要在此日期之後獲取記錄,您應該調用 查詢充值記錄查詢提現記錄接口。這是由於此時引入了現貨錢包。

    HTTP 請求

    GET /contract/v3/private/account/wallet/fund-records

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種
    walletFundTypefalsestring資金類型
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種
    > typestring資金類型
    > amountstring金額
    > walletBalancestring錢包餘額
    > execTimestring執行時間戳 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /contract/v3/private/account/wallet/fund-records?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670931970500
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "BTC",
    "type": "RealisedPNL",
    "amount": "-0.00003034",
    "walletBalance": "0.68146653",
    "execTime": "1665792000030"
    }
    ],
    "nextPageCursor": "K2tqR0xUQ1B1Tyt1a0ZFeVZRa1I2R2ZOT2pVekNKeGZPOTEyWFNpeXd1ejRmRTFoUkhabnVKVlRBNnFtZGk0dlBhRThLdFNHTGxFdWJGQVFMdXBnZ29Bb3JmSDlkczZHV1p1V1JoZmc2dnlRc1VMZ1ZVYlRXeW51ZUVBT3QycjlYSml3alNZampKTHdrdDJzSzFWdnlWK0djRklqczB1M0JYN04wVXltV0ljPQ=="
    },
    "retExtInfo": {},
    "time": 1670931971341
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/contract/wallet.html b/zh-TW/derivatives/contract/wallet.html index 17a8c3c203..8298bc0e8e 100644 --- a/zh-TW/derivatives/contract/wallet.html +++ b/zh-TW/derivatives/contract/wallet.html @@ -4,13 +4,13 @@ 錢包餘額 | Bybit API Documentation - +

    錢包餘額

    獲取錢包餘額信息,包括衍生品帳戶和USDC帳戶

    HTTP 請求

    GET /contract/v3/private/account/wallet/balance

    請求參數

    參數是否必需類型說明
    coinfalsestring币种
    • 如果不傳參數coin,將返回所有錢包余額
    • 可以傳遞多個幣,逗號隔開,比如:USDT,USDC

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種
    > equitystring總資產淨值
    > walletBalancestring錢包余額
    > positionMarginstring倉位保證金
    > availableBalancestring可用餘額
    > orderMarginstring委托預占用保證金
    > occClosingFeestring倉位占用的平倉手續費
    > occFundingFeestring預占用資金費用
    > unrealisedPnlstring未結盈虧
    > cumRealisedPnlstring累計已結盈虧
    > givenCashstring體驗金. 點擊這裡, 了解更多
    > serviceCashstring抵扣金. 點擊這裡, 了解更多
    > accountIMstringUSDC帳戶的初始保證金
    > accountMMstringUSDC帳戶的維持保證金

    請求示例

    GET /contract/v3/private/account/wallet/balance?coin=USDC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670923630734
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "USDC",
    "equity": "1259.7788251",
    "walletBalance": "1259.7488251",
    "positionMargin": "1259.7788251",
    "availableBalance": "1246.7387871",
    "orderMargin": "0",
    "occClosingFee": "0",
    "occFundingFee": "0",
    "unrealisedPnl": "0.03",
    "cumRealisedPnl": "26.6561752",
    "givenCash": "0",
    "serviceCash": "0",
    "accountIM": "13.040038",
    "accountMM": "1.367038"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1670923631261
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/enum.html b/zh-TW/derivatives/enum.html index a7914bc83b..be0909ce38 100644 --- a/zh-TW/derivatives/enum.html +++ b/zh-TW/derivatives/enum.html @@ -4,13 +4,13 @@ 枚舉定義 | Bybit API Documentation - +

    枚舉定義

    category

    合約

    • linear正向合約,包含USDT永續
    • inverse反向合約,包含反向永續, 反向交割

    統一保證金

    • linear正向合約,包含USDT永續, USDC永續
    • option期權

    interval

    • 1 3 5 15 30 60 120 240 360 720分鐘
    • D
    • W
    • M

    symbol

    USDT永續:

    • BTCUSDT
    • ETHUSDT

    USDC永續:

    • BTCPERP
    • ETHPERP

    反向永續:

    • BTCUSD
    • ETHUSD

    反向交割:

    • BTCUSDH23H: 第一季度; 23: 2023
    • BTCUSDM23M: 第二季度; 23: 2023
    • BTCUSDU23U: 第三季度; 23: 2023
    • BTCUSDZ23Z: 第四季度; 23: 2023

    positionIdx

    • 0單向持倉
    • 1買側的雙向持倉
    • 2賣側的雙向持倉

    positionStatus

    • Normal
    • Liq強平中
    • Adl自動減倉中

    triggerBy

    • LastPrice
    • MarkPrice
    • IndexPrice

    timeInForce

    • GoodTillCancel一直有效至取消
    • ImmediateOrCancel立即成交或取消
    • FillOrKlii完全成交或取消
    • PostOnly 被動委託

    orderFilter

    • Order普通單
    • StopOrder條件單

    orderStatus

    • Created訂單已經被系統接收但還沒有推送到撮合引擎中
    • New訂單成功下達
    • Rejected
    • PartiallyFilled
    • Filled
    • PendingCancel撮合引擎收到了取消申請但是還未成功取消
    • Cancelled
    • Untriggered
    • Triggered
    • Deactivated
    • Active條件單已經被觸發,並且活動單已經成功創建。該狀態是條件單成功觸發後的終態

    cancelType

    • CancelByUser
    • CancelByReduceOnly
    • CancelByPrepareLiq CancelAllBeforeLiq由於強平而取消
    • CancelByPrepareAdl CancelAllBeforeAdl由於自動減倉而取消
    • CancelByAdmin
    • CancelByTpSlTsClear
    • CancelByPzSideCh
    • CancelBySmp

    期權:

    • CancelByUser
    • CancelByReduceOnly
    • CancelAllBeforeLiq由於強平而取消
    • CancelAllBeforeAdl由於自動減倉而取消
    • CancelBySettle
    • CancelByCannotAffordOrderCost
    • CancelByPmTrialMmOverEquity
    • CancelByAccountBlocking
    • CancelByDelivery
    • CancelByMmpTriggered
    • CancelByCrossSelfMuch
    • CancelByCrossReachMaxTradeNum
    • CancelByDCP

    stopOrderType

    • TakeProfit止盈單
    • StopLoss止損單
    • TrailingStop追蹤止損單
    • Stop條件單
    • PartialTakeProfit部分止盈單
    • PartialStopLoss部分止損單

    rejectReason

    • EC_NoError
    • EC_Others
    • EC_UnknownMessageType
    • EC_MissingClOrdID
    • EC_MissingOrigClOrdID
    • EC_ClOrdIDOrigClOrdIDAreTheSame
    • EC_DuplicatedClOrdID
    • EC_OrigClOrdIDDoesNotExist
    • EC_TooLateToCancel
    • EC_UnknownOrderType
    • EC_UnknownSide
    • EC_UnknownTimeInForce
    • EC_WronglyRouted
    • EC_MarketOrderPriceIsNotZero
    • EC_LimitOrderInvalidPrice
    • EC_NoEnoughQtyToFill
    • EC_NoImmediateQtyToFill
    • EC_PerCancelRequest
    • EC_MarketOrderCannotBePostOnly
    • EC_PostOnlyWillTakeLiquidity
    • EC_CancelReplaceOrder
    • EC_InvalidSymbolStatus

    positionMode

    • 0單向持倉模式
    • 3雙向持倉模式

    execType

    lastLiquidityInd

    統一保證金

    • TAKER
    • MAKER

    合約

    • AddedLiquidity增加流動性
    • RemovedLiquidity吃流動性

    walletFundType

    • Deposit入金
    • Withdraw提幣
    • RealisedPNL已結盈虧
    • Commission佣金
    • Refund系統返還
    • Prize贈金
    • ExchangeOrderWithdraw兌出
    • ExchangeOrderDeposit兌入
    • ReturnServiceCash返還手續費贈金
    • Insurance保險金
    • SubMember母子帳戶劃轉
    • Coupon生息券
    • AccountTransfer帳戶劃轉
    • CashBack返現

    type

    • TRANSFER_IN
    • TRANSFER_OUT
    • TRADE
    • SETTLEMENT
    • DELIVERY
    • LIQUIDATION
    • BONUS
    • FEE_REFUND
    • INTEREST
    • CURRENCY_BUY
    • CURRENCY_SELL

    tickDirection

    • PlusTick價格上漲
    • ZeroPlusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格高於前一筆交易的價格
    • MinusTick價格下跌
    • ZeroMinusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格低於前一筆交易的價格

    adlRankIndicator

    • 0空倉時默認值
    • 1
    • 2
    • 3
    • 4
    • 5

    smpType

    • 默認: None
    • CancelMaker
    • CancelTaker
    • CancelBoth

    unifiedMarginStatus

    • 1普通帳戶
    • 2已升級到了統一保證金帳戶,僅支持交易期貨和期權
    • 3已升級到了統一帳戶,支持交易期貨、期權和現貨
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/error.html b/zh-TW/derivatives/error.html index 0b16c3bc00..dd86c50a6d 100644 --- a/zh-TW/derivatives/error.html +++ b/zh-TW/derivatives/error.html @@ -4,13 +4,13 @@ 錯誤碼 | Bybit API Documentation - +

    錯誤碼

    統一保證金

    錯誤碼描述
    10000服務超時
    10001參數錯誤
    10002請求無效,請檢查時間戳記和recv_window參數
    10003無效的api_key
    10004錯誤標誌
    10005許可權被拒絕
    10006訪問次數過多
    10008當前用戶被禁止訪問
    10009IP已被禁止
    10010不匹配的IP
    10014請求重複
    10016服務器錯誤
    10018超出IP的頻率限制
    10024合規牆攔截
    10027禁止交易
    110001訂單不存在
    110003訂單價格超出允許範圍
    110004錢包餘額不足
    110005倉位狀態
    110006無法承擔估計的倉位邊際
    110007可用餘額不足
    110008訂單已完成或取消
    110009停止訂單數量超過允許的最大限制
    110010訂單已取消
    110011所做的任何調整都將引發立即清算
    110012可用餘額不足
    110013由於風險限制,無法設定杠杆
    110014可用餘額不足以新增保證金
    110015倉位處於全倉保證金模式下
    110016請求的合約數量超過風險限額,請在重試之前調整風險限額級別
    110017不滿足reduceOnly規則
    110018userId非法
    110019orderId非法
    110020大於500的有效訂單數
    110021超過未結利息
    110022數量已被限制,無法修改訂單以添加數量
    110023本合約僅支持減倉操作,詳情請聯系客服
    110024您有一個現有倉位,因此無法切換倉位模式
    110025倉位模式未修改
    110026未修改全倉/逐倉保證金模式
    110027未修改保證金
    110028存在未結訂單,因此您無法更改倉位模式
    110029對沖模式不適用於此合約
    110030訂單ID重複
    110031風險限額資訊不存在
    110032非法訂單
    110033沒有倉位,無法設定保證金
    110034沒有淨頭寸
    110035清算前未完成取消訂單
    110036全倉保證金模式不允許更改杠杆
    110037用戶設置清單沒有此合約
    110038投資組合保證金模式不允許更改杠杆
    110039維持保證金率過高,可能引發清算
    110040訂單將觸發強制清算,請重新提交訂單
    110041當存在倉位或製造商訂單時,不允許跳過清算
    110042交割前狀態只能减少倉位
    110043未修改設定杠杆
    110044可用保證金不足
    110045錢包餘額不足
    110046所做的任何調整都將引發立即清算
    110047由於可用保證金不足,無法調整風險限額
    110048由於當前/預期持倉價值超過修訂後的風險限額,因此無法調整風險限額
    110049記號筆只能是數位
    110050幣種不在所選範圍內
    110051用戶的可用餘額不能覆蓋當前市場的最低價格
    110052用戶的可用餘額不足以設定價格
    110053用戶可用餘額不能覆蓋當前市場價格和上限價格
    110054此倉位至少有一個止盈連結訂單,因此無法切換止盈和止損模式
    110055此倉位至少有一個止損連結訂單,因此無法切換止盈和止損模式
    110056此倉位至少有一個尾隨止損連結訂單,因此無法切換止盈和止損模式
    110057條件訂單或限制訂單包含TP/SL相關參數
    110058剩餘倉位數量不足,無法設定止盈和止損
    110059在未結訂單部分填充的情况下,不允許修改未結訂單的止盈和止損設定
    110060在完全TP/SL模式下,不允許修改TP/SL
    110061在部分TP/SL模式下,TP/SL設定超過20
    110062未找到機构MMP設定檔。
    110063結算正在進行中! {{key0}}不可用於交易。
    110064修改的合约數不能小於或等於已成交的數量
    110065尚未為您的帳戶啟用MMP。 請聯系您的BD經理。
    110066當前時間不允許交易
    110067不支持統一帳戶
    110068不允許杠杆用戶交易
    110069不允許場外借貸用戶進行交易
    110070ETP合約不允許交易
    3400045設置保證金模式失敗
    340099系統異常

    合約

    錯誤碼描述
    10000服務超時
    10001參數錯誤
    10002請求無效,請檢查時間戳記和recv_window參數
    10003無效的api_key
    10004錯誤標誌
    10005許可權被拒絕
    10006訪問次數過多
    10008當前用戶被禁止訪問
    10009IP已被禁止
    10010不匹配的IP
    10014請求重複
    10016服務器錯誤
    10018超出IP的頻率限制
    10027禁止交易
    140001訂單不存在
    140003訂單價格超出允許範圍
    140004錢包餘額不足
    140005倉位狀態
    140006無法承擔估計的倉位保證金
    140007可用餘額不足
    140008訂單已完成或取消
    140009停止訂單數量超過允許的最大限制
    140010訂單已取消
    140011所做的任何調整都將引發立即清算
    140012可用餘額不足
    140013由於風險限制,無法設定杠杆
    140014可用餘額不足以新增保證金
    140015倉位在全倉邊緣
    140016請求的合約數量超過風險限額,請在重試之前調整風險限額級別
    140017不滿足僅减少規則
    140018userId非法
    140019orderId非法
    140020大於500的有效訂單數
    140021超過未結利息
    140022數量已被限制,無法修改訂單以添加數量
    140023本合約僅支持減倉操作,詳情請聯系客服
    140024您有一個現有倉位,因此無法切換倉位模式
    140025倉位模式未修改
    140026未修改全倉/逐倉保證金模式
    140027未修改保證金
    140028存在未結訂單,因此您無法更改倉位模式
    140029對沖模式不適用於此合約
    140030訂單ID重複
    140031風險限額資訊不存在
    140032非法訂單
    140033沒有倉位,無法設定保證金
    140034沒有淨頭寸
    140035清算前未完成取消訂單
    140036全倉保證金模式不允許更改杠杆
    140037用戶設置清單沒有此合約
    140038投資組合保證金模式不允許更改杠杆
    140039維持保證金率過高,可能引發清算
    140040訂單將觸發強制清算,請重新提交訂單
    140041當存在倉位或製造商訂單時,不允許跳過清算
    140042交割前狀態只能减少倉位
    140043未修改設定杠杆
    140044可用保證金不足
    140045錢包餘額不足
    140046所做的任何調整都將引發立即清算
    140047由於可用保證金不足,無法調整風險限額
    140048由於當前/預期持倉價值超過修訂後的風險限額,因此無法調整風險限額
    140049記號筆只能是數位
    140050幣種不在所選範圍內
    140051用戶的可用餘額不能覆蓋當前市場的最低價格
    140052用戶的可用餘額不足以設定價格
    140053用戶可用餘額不能覆蓋當前市場價格和上限價格
    140054此倉位至少有一個止盈連結訂單,因此無法切換止盈和止損模式
    140055此倉位至少有一個止損連結訂單,因此無法切換止盈和止損模式
    140056此倉位至少有一個尾隨止損連結訂單,因此無法切換止盈和止損模式
    140057條件訂單或限制訂單包含TP/SL相關參數
    140058剩餘倉位數量不足,無法設定止盈和止損
    140059在未結訂單部分填充的情况下,不允許修改未結訂單的止盈和止損設定
    140060在完全TP/SL模式下,不允許修改TP/SL
    140061在部分TP/SL模式下,TP/SL設定超過20
    140062未找到機构MMP設定檔。
    140063結算正在進行中! {{key0}}不可用於交易。
    140064修改的合約數不能小於或等於填寫的數量
    140065尚未為您的帳戶啟用MMP。 請聯系您的BD經理。
    140066當前時間不允許交易
    140067不支持統一帳戶
    140068不允許杠杆用戶交易
    140069不允許場外借貸用戶進行交易
    140070ETP合約不允許交易
    140071RiskId沒有修改
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/funding-rate.html b/zh-TW/derivatives/public/funding-rate.html index fb3ca5d770..4c4c782d24 100644 --- a/zh-TW/derivatives/public/funding-rate.html +++ b/zh-TW/derivatives/public/funding-rate.html @@ -4,14 +4,14 @@ 查詢歷史資金費率 | Bybit API Documentation - +

    查詢歷史資金費率

    查詢資金費率,每個symbol的資金費率產生週期不同。假設資金費率為8小時,當前時間是UTC12點,則返回的是上一個結算即UTC8點產生的資金費率。 如要查詢symbol的資金費率時間間隔,請查詢可交易產品規格接口

    時間入参規則
    • 只傳startTime會報錯
    • 只傳endTime,則返回endTime往前的200條數據
    • 都不傳,返回當前時間的往前200條數據

    HTTP請求

    GET /derivatives/v3/public/funding/history-funding-rate

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回""
    symboltruestring合約名稱
    startfalseinteger開始時間戳 (毫秒)
    endfalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > fundingRatestring資金費率
    > fundingRateTimestampstring資金費率時間戳(毫秒)

    請求示例

    GET /derivatives/v3/public/funding/history-funding-rate?symbol=BTCPERP&limit=2 HTTP/1.1
    Host: api.bybit.com​​

    響應示例

        {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "",
    "list": [
    {
    "symbol": "BTCPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1671955200000"
    },
    {
    "symbol": "BTCPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1671926400000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671970750651
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/index-kline.html b/zh-TW/derivatives/public/index-kline.html index acbbbfecf4..82a6f02f90 100644 --- a/zh-TW/derivatives/public/index-kline.html +++ b/zh-TW/derivatives/public/index-kline.html @@ -4,13 +4,13 @@ 查詢指數價格K線數據 | Bybit API Documentation - +

    查詢指數價格K線數據

    查詢指數價格K線

    HTTP請求

    GET /derivatives/v3/public/index-price-kline

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回 ""
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueinteger開始時間戳 (毫秒)
    endtrueinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    symbolstring合約名稱
    categorystring產品類型
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照start降序排列
    • 蠟燭數組中的元素分別是start, open, high, low, close

    請求示例

    GET /derivatives/v3/public/index-price-kline?category=linear&symbol=BTCUSDT&interval=60&start=1668441600000&end=1668528000000&limit=2 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "linear",
    "list": [
    [
    "1668445200000",
    "16471.28",
    "16619.57",
    "16445.28",
    "16584.01"
    ],
    [
    "1668441600000",
    "16594.06",
    "16624.76",
    "16358",
    "16471.28"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968874797
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/instrument-info.html b/zh-TW/derivatives/public/instrument-info.html index 48466c9224..2c1dfc5c8f 100644 --- a/zh-TW/derivatives/public/instrument-info.html +++ b/zh-TW/derivatives/public/instrument-info.html @@ -4,13 +4,13 @@ 查詢可交易產品的規格信息 | Bybit API Documentation - +

    查詢可交易產品的規格信息

    查詢全站可交易產品的基礎配置規則信息

    HTTP請求

    GET /derivatives/v3/public/instruments-info

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse,option. 默認返回期貨
    symbolfalsestring合約名稱.
    • 查詢期權時, category必傳
    baseCoinfalsestring交易幣種.
    • option有效
    • 不傳時,默認返回BTC相關數據
    limitfalseinteger每頁數量限制. [1,1000]. 默認: 500
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > contractTypestring合約類型. `LinearPerpetual`, `InversePerpetual`, `InverseFutures`
    > statusstring合約狀態
    > baseCoinstring交易幣種. e.g BTCUSDT中的BTC
    > quoteCoinstring報價幣種. e.g BTCPERP中的USDC
    > settleCoinstring結算幣種. e.g BTCUSD的結算幣種是BTC
    > launchTimestring發佈時間 (毫秒)
    > deliveryTimestring交割時間戳 (毫秒). 永續返回`"0"`
    > deliveryFeeRatestring交割費率
    > priceScalestring價格精度
    > leverageFilterObject槓桿屬性
    >> minLeveragestring最低槓桿
    >> maxLeveragestring最高槓桿
    >> leverageStepstring修改槓桿的步長
    > priceFilterObject價格屬性
    >> minPricestring最小訂單價格
    >> maxPricestring最大訂單價格
    >> tickSizestring修改價格的步長
    > lotSizeFilterObject下單數量屬性
    >> maxOrderQtystring單筆訂單的最大下單量
    >> minOrderQtystring單筆訂單的最小下單量
    >> qtyStepstring修改訂單下單量的步長
    > unifiedMarginTradeboolean是否支持統一保證金交易
    > fundingIntervalstring資金費率週期 (分鐘)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /derivatives/v3/public/instruments-info?symbol=BTCPERP&category=linear HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "BTCPERP",
    "contractType": "LinearPerpetual",
    "status": "Trading",
    "baseCoin": "BTC",
    "quoteCoin": "USD",
    "launchTime": "1610604231000",
    "deliveryTime": "0",
    "deliveryFeeRate": "",
    "priceScale": "2",
    "leverageFilter": {
    "minLeverage": "1",
    "maxLeverage": "125.00",
    "leverageStep": "0.01"
    },
    "priceFilter": {
    "minPrice": "0.50",
    "maxPrice": "999999.00",
    "tickSize": "0.50"
    },
    "lotSizeFilter": {
    "maxTradingQty": "20.000",
    "minTradingQty": "0.001",
    "qtyStep": "0.001",
    "postOnlyMaxOrderQty": "100.000",
    "maxOrderQty": "20.000",
    "minOrderQty": "0.001"
    },
    "unifiedMarginTrade": true,
    "fundingInterval": 480,
    "settleCoin": "USDC"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1671969788515
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/kline.html b/zh-TW/derivatives/public/kline.html index d2d3ca069b..5058cb46b2 100644 --- a/zh-TW/derivatives/public/kline.html +++ b/zh-TW/derivatives/public/kline.html @@ -4,13 +4,13 @@ 查詢市場價格K線數據 | Bybit API Documentation - +

    查詢市場價格K線數據

    查詢市場價格K線數據

    HTTP請求

    GET /derivatives/v3/public/kline

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回""
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueinteger開始時間戳 (毫秒)
    endtrueinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    symbolstring合約名稱
    categorystring產品類型
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照start降序排列
    • 蠟燭數組中的元素分別是start, open, high, low, close, volume, turnover

    請求示例

    GET /derivatives/v3/public/kline?category=linear&symbol=BTCPERP&interval=1&start=1670371140000&end=1670371200000 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCPERP",
    "category": "linear",
    "list": [
    [
    "1670371200000",
    "17077",
    "17084",
    "17077",
    "17084",
    "0.017",
    "290.412"
    ],
    [
    "1670371140000",
    "17074",
    "17077.5",
    "17074",
    "17077",
    "0.006",
    "102.457"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968612436
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/long-short-ratio.html b/zh-TW/derivatives/public/long-short-ratio.html index a0d280c145..17b65a8484 100644 --- a/zh-TW/derivatives/public/long-short-ratio.html +++ b/zh-TW/derivatives/public/long-short-ratio.html @@ -4,13 +4,13 @@ 查詢多空比 | Bybit API Documentation - +

    查詢多空比

    HTTP請求

    GET /derivatives/v3/public/account-ratio

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear(僅USDT永續),inverse
    symboltruestring合約名稱
    periodtruestring數據週期. 5min, 15min, 30min, 1h, 4h, 4d
    limitfalseinteger每頁數量限制. [1, 500]. 默認: 50

    響應參數

    參數類型說明
    listarrayObject
    > symbolstring合約名稱
    > buyRatiostring持多倉的用户比例
    > sellRatiostring持空倉的用户比例
    > timestampstring時間戳 (毫秒)

    請求示例

    GET /derivatives/v3/public/account-ratio?category=linear&symbol=BTCUSDT&period=1d&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "buyRatio": "0.5777",
    "sellRatio": "0.4223",
    "timestamp": "1695772800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1695785131028
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/mark-kline.html b/zh-TW/derivatives/public/mark-kline.html index a288fa1d0e..ff646f2cec 100644 --- a/zh-TW/derivatives/public/mark-kline.html +++ b/zh-TW/derivatives/public/mark-kline.html @@ -4,13 +4,13 @@ 查詢標記價格K線數據 | Bybit API Documentation - +

    查詢標記價格K線數據

    查詢標記價格K線

    HTTP請求

    GET /derivatives/v3/public/mark-price-kline

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回 ""
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueinteger開始時間戳 (毫秒)
    endtrueinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    symbolstring合約名稱
    categorystring產品類型
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照start降序排列
    • 蠟燭數組中的元素分別是start, open, high, low, close

    請求示例

    GET /derivatives/v3/public/mark-price-kline?symbol=BTCUSD&interval=1&start=1670261100000&end=1670261280000&category=inverse HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    [
    "1670261280000",
    "17064.76",
    "17068.45",
    "17063.5",
    "17067"
    ],
    [
    "1670261220000",
    "17062.5",
    "17064.88",
    "17062.5",
    "17064.76"
    ],
    [
    "1670261160000",
    "17064",
    "17064",
    "17062.5",
    "17062.5"
    ],
    [
    "1670261100000",
    "17072",
    "17072",
    "17064",
    "17064"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671968706092
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/open-interest.html b/zh-TW/derivatives/public/open-interest.html index 899025ab71..67373fd769 100644 --- a/zh-TW/derivatives/public/open-interest.html +++ b/zh-TW/derivatives/public/open-interest.html @@ -4,13 +4,13 @@ 查詢未平倉合約持倉數量 | Bybit API Documentation - +

    查詢未平倉合約持倉數量

    查詢各個合約市場內所有未平倉的數量

    信息
    • 返回單邊數據
    • 最久可以查詢到自合約上線開始的數據

    HTTP請求

    GET /derivatives/v3/public/open-interest

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回 ""
    symboltruestring合約名稱
    intervaltruestring時間粒度. 5min 15min 30min 1h 4h 1d
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 50
    cursorfalsestring游標,用於翻頁

    Response Parameters

    ParameterTypeComments
    symbolstring合約名稱
    categorystring產品類型
    listarrayObject
    > openIntereststring未平倉合約數量
    > timestampstring數據產生的時間戳(毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /derivatives/v3/public/open-interest?category=linear&symbol=ETHUSDT&interval=5min&limit=2 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "ETHUSDT",
    "category": "linear",
    "list": [
    {
    "openInterest": "411496.22000000",
    "timestamp": "1677832800000"
    },
    {
    "openInterest": "411484.61000000",
    "timestamp": "1677832500000"
    }
    ],
    "nextPageCursor": "lastid%3D44487872"
    },
    "retExtInfo": {},
    "time": 1677832955976
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/option-delivery.html b/zh-TW/derivatives/public/option-delivery.html index 1068780e86..29785424bf 100644 --- a/zh-TW/derivatives/public/option-delivery.html +++ b/zh-TW/derivatives/public/option-delivery.html @@ -4,13 +4,13 @@ 查詢期權交割價格 | Bybit API Documentation - +

    查詢期權交割價格

    查詢平台交割產品的交割價格,目前僅支持期權

    HTTP請求

    GET /derivatives/v3/public/delivery-price

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. 僅option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易貨幣. 默認: BTC
    directionfalsestring翻頁方向. prev, next. 默認: next
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 50
    cursorfalsestring游標,用於分頁

    響應參數

    參數類型說明
    resultTotalSizeinteger返回結果數量
    cursorstring游標,用於分頁
    dataListarrayObject
    > categorystring產品類型
    > symbolstring合約名稱
    > deliveryPricestring交割價格
    > deliveryTimestring交割時間戳 (毫秒)

    請求示例

    GET /derivatives/v3/public/delivery-price?limit=1&baseCoin=ETH HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "resultTotalSize": 4830,
    "cursor": "0%2C1",
    "dataList": [
    {
    "category": "option",
    "symbol": "ETH-25DEC22-1450-C",
    "deliveryPrice": "1218.856238890",
    "deliveryTime": "1671955200000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671971138308
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/orderbook.html b/zh-TW/derivatives/public/orderbook.html index 1cea78c0fe..f90e9d1a2d 100644 --- a/zh-TW/derivatives/public/orderbook.html +++ b/zh-TW/derivatives/public/orderbook.html @@ -4,13 +4,13 @@ Order Book (深度) | Bybit API Documentation - +

    Order Book (深度)

    獲取深度數據

    信息

    響應是當前時間的切片數據

    HTTP請求

    GET /derivatives/v3/public/order-book/L2

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse,option. 默認: linear, 當不傳時,響應返回 ""
    symboltruestring合約名稱. 查詢期權時,category必傳
    limitfalseinteger每頁數量限制 [1, 500]. 默認: 25. option僅25可用

    響應參數

    參數類型說明
    sstring合約名稱
    bstringBid, 買方. 按照價格從小到大
    astringAsk, 賣方. 按照價格從小到大
    tsinteger行情服務生成數據時間戳(毫秒)
    uinteger表示數據連續性的id

    請求示例

    GET /derivatives/v3/public/order-book/L2?category=linear&symbol=BTCPERP&limit=2 HTTP/1.1
    Host: api.bybit.com​

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "s": "BTCPERP",
    "b": [
    [
    "16818", // 價格
    "0.156" // 數量
    ],
    [
    "16818.5",
    "0.183"
    ]
    ],
    "a": [
    [
    "16819",
    "0.454"
    ],
    [
    "16819.5",
    "0.054"
    ]
    ],
    "ts": 1671969122791,
    "u": 6404345
    },
    "retExtInfo": {},
    "time": 1671969122869
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/premium-index-kline.html b/zh-TW/derivatives/public/premium-index-kline.html index aace4d3e09..903303f7f3 100644 --- a/zh-TW/derivatives/public/premium-index-kline.html +++ b/zh-TW/derivatives/public/premium-index-kline.html @@ -4,13 +4,13 @@ 查詢溢價指數價格K線數據 | Bybit API Documentation - +

    查詢溢價指數價格K線數據

    查詢溢價指數價格K線數據

    HTTP請求

    GET /derivatives/v3/public/premium-index-price-kline

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回 ""
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1 3 5 15 30 60 120 240 360 720 D M W
    starttrueinteger開始時間戳 (毫秒)
    endtrueinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    symbolstring合約名稱
    categorystring產品類型
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照start降序排列
    • 蠟燭數組中的元素分別是start, open, high, low, close

    請求示例

    GET /derivatives/v3/public/premium-index-price-kline?symbol=BTCUSDT&interval=D&start=1668441600000&end=1668528000000 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "",
    "list": [
    [
    "1668470400000",
    "-0.000754",
    "-0.001071",
    "-0.001072",
    "-0.001072"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1671969006930
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/risk-limit.html b/zh-TW/derivatives/public/risk-limit.html index 790ccf8bac..dbc732487f 100644 --- a/zh-TW/derivatives/public/risk-limit.html +++ b/zh-TW/derivatives/public/risk-limit.html @@ -4,13 +4,13 @@ 查詢合約風險限額 | Bybit API Documentation - +

    查詢合約風險限額

    查詢期貨合約的風險限額表

    提示

    什麼是風險限額? 風險限額(USDT合約)

    HTTP請求

    GET /derivatives/v3/public/risk-limit/list

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse. 默認: linear, 當不傳時,響應返回 ""
    symbolfalsestring合約名稱

    響應參數

    參數類型說明
    categorystring合約類型
    listarrayObject
    > idstring風險限額id
    > symbolstring合約名稱
    > limitstring風險限制額度
    > maintainMarginstring維持保證金率
    > initialMarginstring初始保證金率
    > isLowerRiskinteger是否是最低風險限額. 1: true, 0: false
    > maxLeveragestring該風險限額允許的最大槓桿

    請求示例

    GET /derivatives/v3/public/risk-limit/list?symbol=ETHPERP HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "",
    "list": [
    {
    "id": 1,
    "symbol": "ETHPERP",
    "limit": "500000",
    "maintainMargin": "0.01",
    "initialMargin": "0.015",
    "isLowestRisk": 1,
    "maxLeverage": "66.67"
    },
    ...,

    ]
    },
    "retExtInfo": {},
    "time": 1671970615467
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/ticker.html b/zh-TW/derivatives/public/ticker.html index 2b782fce8c..3aa723c9f1 100644 --- a/zh-TW/derivatives/public/ticker.html +++ b/zh-TW/derivatives/public/ticker.html @@ -4,13 +4,13 @@ 查詢最新行情信息 | Bybit API Documentation - +

    查詢最新行情信息

    可獲取到快照的最新市場價格,最佳買賣價格,以及過去時間內的交易量等.

    HTTP請求

    GET /derivatives/v3/public/tickers

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型. linear,inverse,option. 默認: linear, 當不傳時,響應返回""
    symbolfalsestring合約名稱.
    • 查詢期權相關合約時,symbol 和 category都是必傳

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > bidPricestring買1價
    > askPricestring賣1價
    > lastPricestring最新市場成交價
    > lastTickDirectionstring價格變化方向
    > prevPrice24hstring24小時前的整點市價
    > price24hPcntstring市場價格相對24h前變化的百分比
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價
    > prevPrice1hstring1小時前的整點市價
    > markPricestring標記價格
    > indexPricestring指數價格
    > openIntereststring未平倉合約的數量
    > turnover24hstring最近24小時成交額
    > volume24hstring最近24小時成交量
    > fundingRatestring資金費率
    > nextFundingTimestring下次結算資金費用的時間 (毫秒)
    > predictedDeliveryPricestring預計交割價格. 交割前30分鐘有值
    > basisRatestring交割合約基差率
    > deliveryFeeRatestring交割費率
    > deliveryTimestring交割時間戳 (毫秒)
    > openInterestValuestring未平倉合約價值

    請求示例

    GET /derivatives/v3/public/tickers?category=linear&symbol=BTCUSDZ22 HTTP/1.1
    Host: api.bybit.com​

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "symbol": "BTCUSDZ22",
    "bidPrice": "16825",
    "askPrice": "16825.5",
    "lastPrice": "16825.00",
    "lastTickDirection": "ZeroPlusTick",
    "prevPrice24h": "16830.50",
    "price24hPcnt": "-0.000326",
    "highPrice24h": "16859.50",
    "lowPrice24h": "16798.50",
    "prevPrice1h": "16824.50",
    "markPrice": "16824.02",
    "indexPrice": "16825.28",
    "openInterest": "7653441",
    "turnover24h": "30.80109312",
    "volume24h": "518542",
    "fundingRate": "",
    "nextFundingTime": "0",
    "predictedDeliveryPrice": "0.00",
    "basisRate": "-0.00009093",
    "deliveryFeeRate": "0.0005",
    "deliveryTime": "1672387200000",
    "openInterestValue": "21887.06"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671969377669
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/public/trade.html b/zh-TW/derivatives/public/trade.html index 0258f1aacf..0fe90a56ec 100644 --- a/zh-TW/derivatives/public/trade.html +++ b/zh-TW/derivatives/public/trade.html @@ -4,13 +4,13 @@ 查詢平台成交歷史 | Bybit API Documentation - +

    查詢平台成交歷史

    獲取平台最近成交數據. 您可以從這裡下載到歸檔的更多的歷史成交數據

    HTTP請求

    GET /derivatives/v3/public/recent-trade

    請求參數

    參數是否必需類型說明
    categoryfalsestring產品類型.linear,inverse,option
    • category不傳,或者傳的是linerar,inverse, 那麼 symbol必傳
    • category=option, 那麼symbol is 可選
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種. 默認: BTC. 僅category=option時有效
    optionTypefalsestring期權類型. Call,Put. 僅category=option時有效
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 500

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > execIdstring成交id
    > symbolstring合約名稱
    > pricestring成交價格
    > sizestring成交數量
    > sidestring吃單方向. Buy, Sell
    > timestring成交時間戳 (毫秒)
    > isBlockTradeboolean成交類型是否為大宗交易

    請求示例

    GET /derivatives/v3/public/recent-trade?category=linear&symbol=BTCUSDT&limit=1 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "execId": "5706445b-8543-59bc-8988-93e0f4a3f0f9",
    "symbol": "BTCUSDT",
    "price": "16814.50",
    "size": "0.001",
    "side": "Buy",
    "time": "1671970297430",
    "isBlockTrade": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1671970297723
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/rate-limit.html b/zh-TW/derivatives/rate-limit.html index b19726aada..1071557dde 100644 --- a/zh-TW/derivatives/rate-limit.html +++ b/zh-TW/derivatives/rate-limit.html @@ -4,14 +4,14 @@ 頻率限制 | Bybit API Documentation - +

    頻率限制

    IP限頻

    警告

    如果您收到HTTP 403(拒絕訪問)響應, 您的 IP 已被暫時或永久禁止。 您應立即查看以下指南,以確保您的應用程序不會繼續違反限制。如果您在 30 分鐘後 仍被禁止,則您可能會被永久禁止。

    我們不建議您在這些限制的邊緣運行您的應用程序,以防異常的網絡活動導致意外違規。

    • GET/POST 請求 (共享):
      • 連續 5 秒內每秒不超過 120 個請求
    備註

    所有到api.bybit.comapi.bytick.com的流量共享此限制,無論是訪問現貨、期貨還是期權。

    違反限制後,您的 IP 將被禁止一段時間(通常為 30 分鐘)。 持續違反限制將導致永久禁止。 我們不能撤銷永久禁令或縮短臨時禁令。

    賬戶頻率限製

    警告

    如果您收到這樣的響應"ret_msg": "Too many visits!", 則表示您觸發了帳戶頻率限制, 請等到頻率限制重置以後, 再繼續發送請求。

    提示

    目前, 統一保證金(unified/v3)的帳戶頻率會有一些不一樣.

    • linear: 按分鐘計算限頻率
    • option: 按計算限制頻率

    Bybit基於每秒鍾的滾動時間窗口來做頻率限製,並且是按賬戶(uid)來做劃分限製,每次請求API響應頭(response header)中都會包含如下字段:

    • X-Bapi-Limit-Status - 該接口當前時間窗口剩余可用請求數
    • X-Bapi-Limit - 該接口當前頻率限製上限
    • X-Bapi-Limit-Reset-Timestamp - 如果您已超過該接口當前窗口頻率限製,該字段表示下個可用時間窗口的時間戳(毫秒),即什麽時候可以恢復訪問;如果您未超過該接口當前窗口頻率限製,該字段表示返回的是當前服務器時間(毫秒).

    Http 響應頭示例

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    接口頻率限制表

    統一保證金

    路徑正向合約(linear)期權(option)
    /unified/v3/private/order/create100 req/min (共享)5 req/s
    /unified/v3/private/order/replace5 req/s
    /unified/v3/private/order/cancel5 req/s
    /unified/v3/private/order/create-batch100 req/min (共享)
    5 req/s
    /unified/v3/private/order/replace-batch5 req/s
    /unified/v3/private/order/cancel-batch5 req/s
    /unified/v3/private/order/cancel-all1 req/s
    /unified/v3/private/order/list50 req/s50 req/s
    /unified/v3/private/order/unfilled-orders50 req/s50 req/s
    /unified/v3/private/position/list50 req/s50 req/s
    /unified/v3/private/execution/list50 req/s50 req/s
    /unified/v3/private/account/wallet/balance50 req/s50 req/s
    /unified/v3/private/delivery-record50 req/s50 req/s
    /unified/v3/private/account/transaction-log50 req/s50 req/s
    /unified/v3/private/settlement-record50 req/s50 req/s
    /unified/v3/private/account/assets50 req/s50 req/s
    /unified/v3/private/position/usdc-marginmode-info50 req/s50 req/s
    /unified/v3/private/account/borrow-history50 req/s50 req/s
    /unified/v3/private/account/borrow-rate50 req/s50 req/s

    合約

    路徑頻率
    所有私有接口10 req/s

    如何提高頻率限製

    請發送郵件到 api@bybit.com,我們會在 1-4 個工作日內答復。郵件內容必須包含以下內容:

    1. 您的姓名和公司名稱和簡介
    2. 您的bybit 賬號uid或註冊郵箱手機號,以及您要申請提頻的交易對
    3. 您上個月的交易量(吃單/掛單)並提供截圖
    4. 簡單介紹您的交易策略和為什麽需要更高限頻
    5. 如果可以,請提供您的成交記錄csv文檔
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/batch-cancel.html b/zh-TW/derivatives/unified/batch-cancel.html index cc1a062894..a1e3e3e5df 100644 --- a/zh-TW/derivatives/unified/batch-cancel.html +++ b/zh-TW/derivatives/unified/batch-cancel.html @@ -4,13 +4,13 @@ 批量撤銷委託單 | Bybit API Documentation - +

    批量撤銷委託單

    提示

    該接口可以批量撤銷多筆訂單

    • 您必須指定orderId或者orderLinkId.
    • 若orderId和orderLinkId之間不匹配, 系統將會優先處理orderId
    • 您只能撤銷未成交和部分成交的訂單.
    • 期貨和期權的訂單撤銷無法同時在一次請求裏同時撤單。如果期貨和期權的訂單都在一個請求裏,則根據category的類型,僅會操作與category相匹配的訂單。

    HTTP請求

    POST /unified/v3/private/order/cancel-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,option
    requesttruearrayObject
    > symboltruestring合約名稱
    > orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    > orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    retExtInfoObject
    > listarrayObject
    >> codeinteger成功/錯誤碼
    >> msgstring成功/錯誤信息

    請求示例

    POST /unified/v3/private/order/cancel-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672818987475
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderLinkId": "test-002"
    },
    {
    "symbol": "XRPUSDT",
    "orderLinkId": "test-003"
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "",
    "orderLinkId": "test-002"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "",
    "orderLinkId": "test-003"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 110001,
    "msg": "order not exists or too late to cancel"
    }
    ]
    },
    "time": 1672818989928
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/batch-place.html b/zh-TW/derivatives/unified/batch-place.html index 7900e9de3b..e6c96d05c8 100644 --- a/zh-TW/derivatives/unified/batch-place.html +++ b/zh-TW/derivatives/unified/batch-place.html @@ -4,13 +4,13 @@ 批量創建委託單 | Bybit API Documentation - +

    批量創建委託單

    提示

    該接口支持批量創建委託單

    • 下單時需確保帳戶內有足夠的資金。一旦下單,根據訂單所需資金,您的帳戶資金將在訂單生命週期內凍結相應額度,被凍結的資金額度取決於訂單屬性。
    • 同一個請求中只能包含同一種合約的訂單,期權、期貨不可同時下單。僅支持Limit / Market order,不支持條件單。
    • 如果期貨和期權的訂單都在一個請求裏 ,則根據category的類型,僅會操作symbol與category相匹配的訂單。
    • 每個請求包含的訂單數最大10筆訂單。返回的數據列表中分成兩個 list,訂單創建的 list 和創建的信息返回,兩個 list 的訂單是完全序列保持一致的。

    HTTP請求

    POST /unified/v3/private/order/create-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    requesttruearrayObject
    > symboltruestring合約名稱
    > sidetruestring訂單方向. Buy, Sell
    > orderTypetruestring訂單類型. Market, Limit
    > qtytruestring訂單數量
    > pricefalsestring訂單價格. 當orderType=Market時,設置的價格將被忽略
    > ivfalsestring隱含波動率. 僅option有效. 按照實際值傳慘,如10%,則傳0.1
    > timeInForcetruestring訂單執行策略. GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly
    > positionIdxfalseinteger倉位標識. 0: 單向持倉, 1: 買側雙向持倉, 2: 賣側雙向持倉. 統一保證金僅支持單向持倉
    > orderLinkIdfalsestring用戶自定義訂單Id, 最大長度36位,且同一機構下自定義ID支持數字、字母(大小寫)、中劃線、下劃線這些字符的組合
    期貨規則:
    • 該參數選填
    • USDC永續和USDT永續的orderLinkId互相獨立,即orderLinkId可相同
    • 在訂單未完全成交或取消前,orderLinkId需保持不一致; 訂單完全成交或取消後,orderLinkId可使用之前使用過的
    • 期權規則:
    • 該參數必傳
    • 總是唯一
    > reduceOnlyfalseboolean什麼是只減倉? true 將這筆訂單設為只減倉. 只減倉單的止盈止損不生效
    > closeOnTriggerfalseboolean什麼是觸發後平倉委託? 此選項可以確保您的止損單被用於減倉(平倉)而非加倉,並且在可用保證金不足的情況下,取消其他委託,騰出保證金以確保平倉委託的執行.
    > mmpfalseboolean做市商保護. 僅對期權生效. true表示該訂單是做市商保護訂單

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    >> createAtstring訂單創建時間 (毫秒)
    retExtInfoObject
    > listarrayObject
    >> codeinteger成功/錯誤碼
    >> msgstring成功/錯誤信息

    請求示例

    POST /unified/v3/private/order/create-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672817108675
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.05",
    "price": "1000",
    "timeInForce": "GoodTillCancel",
    "orderLinkId": "test-002",
    "reduceOnly": false,
    "closeOntrigger": false
    },
    {
    "symbol": "XRPUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "100",
    "price": "0.3",
    "timeInForce": "GoodTillCancel",
    "orderLinkId": "test-003",
    "reduceOnly": false,
    "closeOntrigger": false
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "ce295fcb-8c8a-4f12-89f4-4ab23d38ccd8",
    "orderLinkId": "test-002",
    "createAt": "1672817109797"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "e97f0355-6586-49a4-965f-feb7253cef14",
    "orderLinkId": "test-003",
    "createAt": "1672817109796"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672817109804
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/batch-replace.html b/zh-TW/derivatives/unified/batch-replace.html index b4e4fc5209..234812e661 100644 --- a/zh-TW/derivatives/unified/batch-replace.html +++ b/zh-TW/derivatives/unified/batch-replace.html @@ -4,13 +4,13 @@ 批量修改委託單 | Bybit API Documentation - +

    批量修改委託單

    提示

    該接口支持批量修改委託單

    • 您只能修改那些未成交或部分成交的訂單. 條件單不支持批量修改..
    • 如果期貨和期權的訂單都在一個請求裏,則根據category的類型,僅會操作與category相匹配的訂單.

    HTTP 請求

    POST /unified/v3/private/order/replace-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    requesttruearrayObject
    > symboltruestring合約名稱
    > orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    > orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    > qtyfalsestring修改後的訂單數量. 若不修改,請不要傳該字段
    > pricefalsestring修改後的訂單價格. 若不修改,請不要傳該字段
    > ivfalsestring隱含波動率. 僅對期權有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    retExtInfoObject
    > listarrayObject
    >> codeinteger成功/錯誤碼
    >> msgstring成功/錯誤信息

    請求示例

    POST /unified/v3/private/order/replace-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672818010133
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "request": [
    {
    "symbol": "ETHUSDT",
    "orderId": null,
    "price": null,
    "qty": "0.1",
    "orderLinkId": "test-002"
    },
    {
    "symbol": "XRPUSDT",
    "orderId": null,
    "price": "120",
    "qty": null,
    "orderLinkId": "test-003"
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "",
    "orderLinkId": "test-002"
    },
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "orderId": "",
    "orderLinkId": "test-003"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    },
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672818011076
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/borrow-history.html b/zh-TW/derivatives/unified/borrow-history.html index 2912df2990..c6c895a3a4 100644 --- a/zh-TW/derivatives/unified/borrow-history.html +++ b/zh-TW/derivatives/unified/borrow-history.html @@ -4,13 +4,13 @@ 查詢利息記錄 | Bybit API Documentation - +

    查詢利息記錄

    獲取利息記錄,按照創建時間倒敘排列。

    HTTP 請求

    GET /unified/v3/private/account/borrow-history

    請求參數

    參數是否必需類型說明
    currencyfalsestringUSDC、USDT、BTC、ETH
    startTimefalseinteger開始時間 (毫秒)
    endTimefalseinteger結束時間 (毫秒)
    directionfalsestring翻頁方向: prev: 上一頁, next: 下一頁, 默認 next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    currencystringnull
    listarrayObject
    > currencystringUSDC、USDT、BTC、ETH
    > createTimeinteger創建時間戳(毫秒)
    > borrowCoststring利息
    > hourlyBorrowRatestring每小時利率
    > InterestBearingBorrowSizestring豁免利息額度
    > costExemptionstring豁免計息成本

    請求示例

    GET /unified/v3/private/account/borrow-history?limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673078071099
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "1625%3A0%2C1625%3A0",
    "currency": null,
    "list": [
    {
    "createTime": 1667282700269,
    "costExemption": "0.00063175360150218",
    "InterestBearingBorrowSize": "0",
    "currency": "USDT",
    "hourlyBorrowRate": "0.000001142",
    "borrowCost": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673078071991
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/borrow-rate.html b/zh-TW/derivatives/unified/borrow-rate.html index 001b78cad3..b76b8063d8 100644 --- a/zh-TW/derivatives/unified/borrow-rate.html +++ b/zh-TW/derivatives/unified/borrow-rate.html @@ -4,13 +4,13 @@ 借貸利率查詢 | Bybit API Documentation - +

    借貸利率查詢

    HTTP 請求

    GET /unified/v3/private/account/borrow-rate

    請求參數

    參數是否必需類型說明
    currencyfalsestring僅USDC, USDT (UMA)

    響應參數

    參數類型說明
    listarrayObject
    > currencystring抵押品幣種
    > hourlyBorrowRatestring每小時借款利率
    > maxBorrowAmountstring最大可借貸額度
    > freeBorrowAmountstring免息借貸額度

    請求示例

    GET /unified/v3/private/account/borrow-rate HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673078229194
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "list": [
    {
    "freeBorrowingAmount": "30000",
    "currency": "USDT",
    "maxBorrowingAmount": "2500000",
    "hourlyBorrowRate": "0.0000055139"
    },
    {
    "freeBorrowingAmount": "15000",
    "currency": "USDC",
    "maxBorrowingAmount": "1500000",
    "hourlyBorrowRate": "0.00000342460000000000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672023307465
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/cancel-all.html b/zh-TW/derivatives/unified/cancel-all.html index 3b36bc85bb..027786f226 100644 --- a/zh-TW/derivatives/unified/cancel-all.html +++ b/zh-TW/derivatives/unified/cancel-all.html @@ -4,13 +4,13 @@ 撤銷所有訂單 | Bybit API Documentation - +

    撤銷所有訂單

    撤銷全部委託單

    提示
    • category=linear, 則baseCoin, settleCoin, symbol三個參數必傳其中一個

    HTTP請求

    POST /unified/v3/private/order/cancel-all

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種
    settleCoinfalsestring結算幣種. 僅期貨有效
    orderFilterfalsestringOrder: 活動單, StopOrder: 條件單

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義Id
    retExtInfoObject
    > listarrayObject
    >> codeinteger成功/錯誤碼
    >> msgstring成功/錯誤信息

    请求示例

    POST /unified/v3/private/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672810386137
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "baseCoin": "ETH",
    "settleCoin": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "6cba55ea-6996-44f5-bd0f-ac09ffda4ab1",
    "orderLinkId": "liang-001"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "success"
    }
    ]
    },
    "time": 1672810388787
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/cancel.html b/zh-TW/derivatives/unified/cancel.html index 0ddbce7324..73a2871345 100644 --- a/zh-TW/derivatives/unified/cancel.html +++ b/zh-TW/derivatives/unified/cancel.html @@ -4,13 +4,13 @@ 撤銷委託單 | Bybit API Documentation - +

    撤銷委託單

    警告
    • 您必須指定orderId或者orderLinkId.
    • orderIdorderLinkId之間不匹配, 系統將會優先處理orderId.
    • 您只能撤銷未成交和部分成交的訂單.

    HTTP 請求

    POST /unified/v3/private/order/cancel

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單

    響應參數

    參數類型說明
    orderIdstring訂單Id
    orderLinkIdstring用戶自定義訂單Id

    请求示例

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/cancel' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "category": "linear",
    "orderId": "4c51a45f-7795-4b38-9b66-3c306b73f112",
    "symbol": "BTCUSDT"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "4c51a45f-7795-4b38-9b66-3c306b73f112",
    "orderLinkId": "e80d558e-ed"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/dcp.html b/zh-TW/derivatives/unified/dcp.html index dec1be0b94..04a07551bb 100644 --- a/zh-TW/derivatives/unified/dcp.html +++ b/zh-TW/derivatives/unified/dcp.html @@ -4,7 +4,7 @@ 設置斷線保護時間 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    設置斷線保護時間

    信息

    什麼是斷線保護 (Disconnection Protect)?

    Bybit基於websocket私有連接和心跳機制,提供斷線保護功能。這計時從第一次斷開開始。如果Bybit服務器在一段時間內沒有收到客戶端的重連超過10秒(默認)並 恢復心跳“ping”,則客戶端處於“斷線保護”狀態,客戶所有活躍的期權訂單將自動取消。如果在 10 秒內,客戶端重新連接並恢復心跳“ping”,計時會在下次斷線 時重置並重新開始。

    如何啟用斷線保護

    若您需要開啟/關閉斷線保護功能, 您可以諮詢客戶經理. 開啟後,默認的斷線保護時間為10秒。

    適用對象

    僅適用於期權交易。

    提示

    API請求發送成功後,系統需要一定的時間才能生效。建議10秒後再查詢或設置。

    HTTP請求

    POST /derivatives/v3/private/dcp-set-timewindow

    請求參數

    參數是否必需類型說明
    timeWindowtrueinteger斷線保護時間窗口. [3, 300], 單位: 秒

    響應參數

    請求示例

    POST /derivatives/v3/private/dcp-set-timewindow HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675852742375
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "timeWindow": 40
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/delivery.html b/zh-TW/derivatives/unified/delivery.html index 8b6d6c878d..6624bf9842 100644 --- a/zh-TW/derivatives/unified/delivery.html +++ b/zh-TW/derivatives/unified/delivery.html @@ -4,13 +4,13 @@ 查詢交割紀錄 (期權) | Bybit API Documentation - +

    查詢交割紀錄 (期權)

    查詢期權交割紀錄, 返回結果按照deliveryTime降序排列

    HTTP 請求

    GET /unified/v3/private/delivery-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. option
    symbolfalsestring合約名稱
    expDatefalsestring到期日. 格式: 25MAR22. 默認: 返回所有
    directionfalsestringprev: 前一頁, next: 後一頁. 默認: next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > sidestring方向. Buy,Sell
    > strikestring行權價
    > feestring手續費,正數表支出,負數表收取
    > positionstring交割數量
    > deliveryTimenumber交割時間戳 (毫秒)
    > deliveryPricestring交割價格
    > deliveryRplstring交割已實現盈虧

    Request Example

    GET /unified/v3/private/delivery-record?category=option&limit=5 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020598623
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "45%3A0%2C45%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "BTC-29JUL22-27000-C",
    "side": "Sell",
    "deliveryTime": 1659081601928,
    "strike": "27000",
    "fee": "0.00000000",
    "position": "0.0300",
    "deliveryPrice": "23927.85304688",
    "deliveryRpl": "0.00000000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672020600013
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/exchange.html b/zh-TW/derivatives/unified/exchange.html index f0868421e4..c3be1bbdc7 100644 --- a/zh-TW/derivatives/unified/exchange.html +++ b/zh-TW/derivatives/unified/exchange.html @@ -4,13 +4,13 @@ 查詢幣幣兌換紀錄查詢 | Bybit API Documentation - +

    查詢幣幣兌換紀錄查詢

    獲取幣幣兌換紀錄

    HTTP 請求

    GET /asset/v2/private/exchange/exchange-order-all

    請求參數

    參數是否必需類型說明
    fromCoinfalsestring兌出幣種. e.g,BTC
    toCoinfalsestring兌入幣種. e.g,USDT

    響應參數

    參數類型說明
    totalCountstring返回數據數量
    orderarrayObject
    > fromCoinstring兌出幣種
    > fromAmountstring兌出金額
    > toCoinstring兌入幣種
    > toAmountstring兌入金額
    > exchangeRatestring兌換匯率
    > createdTimestring兌換創建時間戳 (秒)
    > exchangeTxIdstring兌換訂單號

    請求示例

    GET /asset/v2/private/exchange/exchange-order-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673079087093
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "order": [
    {
    "fromCoin": "ETH",
    "fromAmount": "0.10000000",
    "toCoin": "XRP",
    "toAmount": "372.37487085",
    "exchangeRate": "3723.74870857",
    "createdTime": "1672989418000",
    "exchangeTxId": "251239533285211865273079980032"
    },
    {
    "fromCoin": "BTC",
    "fromAmount": "0.10000000",
    "toCoin": "ETH",
    "toAmount": "1.38586623",
    "exchangeRate": "13.85866238",
    "createdTime": "1672197760000",
    "exchangeTxId": "145102533285208544812654440448"
    }
    ],
    "totalCount": "2"
    },
    "retExtInfo": {},
    "time": 1673079089361
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/execution-list.html b/zh-TW/derivatives/unified/execution-list.html index 0af2ab3feb..25c3e9a6c5 100644 --- a/zh-TW/derivatives/unified/execution-list.html +++ b/zh-TW/derivatives/unified/execution-list.html @@ -4,13 +4,13 @@ 查詢成交紀錄 (半年) | Bybit API Documentation - +

    查詢成交紀錄 (半年)

    獲取用戶成交紀錄,返回結果按execTime降序排列

    提示
    • 單筆訂單可能會有多次成交
    • 該接口支持查詢半年內數據

    HTTP 請求

    POST /unified/v3/private/execution/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,option
    symbolfalsestring合約名稱
    orderIdfalsestring訂單Id
    orderLinkIdfalsestring用戶自定義訂單id
    baseCoinfalsestring交易幣種. 僅對option有效. 若不傳,則返回所有類型的交易幣種數據
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    execTypefalsestring成交類型
    directionfalsestringprev: 前一頁, next: 後一頁. 默認: next
    limitfalseinteger每頁數量限制. [1, 100]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型. linear,option
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義訂單id
    > sidestring訂單方向. Buy,Sell
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > leavesQtystring剩餘委託未成交數量,如果訂單被取消了,則 leavesQty 會返回為 0
    > orderTypestring訂單類型. 市價單: Market,限價單: Limit
    > stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则不会返回任何类型
    > execFeestring交易手續費
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring交易類型
    > execValuestring成交價值
    > execTimenumber成交時間(毫秒)
    > feeRatestring手續費率
    > blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /unified/v3/private/execution/list?category=linear&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020216382
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "2203%3A0%2C2203%3A0",
    "category": "option",
    "list": [
    {
    "orderType": "Market",
    "symbol": "ETH-30DEC22-700-C",
    "orderLinkId": "",
    "side": "Sell",
    "orderId": "cc8012bc-ddc1-443c-8dd9-88cfb946d3b0",
    "leavesQty": "0.0000",
    "execTime": 1672018465365,
    "execFee": "0.03656010",
    "feeRate": "0.000300",
    "execId": "f4309658-62be-5f2b-b262-852909c45bba",
    "blockTradeId": "",
    "execPrice": "498.00000000",
    "lastLiquidityInd": "TAKER",
    "orderQty": "0.1000",
    "orderPrice": "496.50000000",
    "execValue": "49.80000000",
    "execType": "Trade",
    "execQty": "0.1000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672019908409
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/get-dcp.html b/zh-TW/derivatives/unified/get-dcp.html index ba727fdbbf..60e7e9ca2a 100644 --- a/zh-TW/derivatives/unified/get-dcp.html +++ b/zh-TW/derivatives/unified/get-dcp.html @@ -4,13 +4,13 @@ 查詢斷線保護配置 | Bybit API Documentation - +

    查詢斷線保護配置

    HTTP請求

    GET /derivatives/v3/private/query-dcp-info

    請求參數

    響應參數

    參數類型說明
    retCodeinteger成功/錯誤碼
    retMsgstring成功/錯誤信息
    dcpStatusstringDCP狀態. ON: 開啟, OFF: 關閉
    timeWindowstring設置的斷線保護時間窗口 (秒)

    請求示例

    GET /derivatives/v3/private/query-dcp-info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675861979020
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "dcpStatus": "ON",
    "timeWindow": "40"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/get-mmp-state.html b/zh-TW/derivatives/unified/get-mmp-state.html index 6dd9fe4836..055a8e4ad5 100644 --- a/zh-TW/derivatives/unified/get-mmp-state.html +++ b/zh-TW/derivatives/unified/get-mmp-state.html @@ -4,13 +4,13 @@ 查詢市商保護配置信息 | Bybit API Documentation - +

    查詢市商保護配置信息

    HTTP 請求

    GET /unified/v3/private/account/mmp-state

    請求參數

    參數是否必需類型說明
    baseCointruestringBase coin

    響應參數

    參數類型說明
    resultarrayObject
    > baseCoinstring交易幣種
    > mmpEnabledboolean帳戶是否開啟了mmp
    > windowstring時間窗口 (毫秒)
    > frozenPeriodstring凍結時間長度 (毫秒)
    > qtyLimitstring成交數量上限
    > deltaLimitstringDelta值上限
    > mmpFrozenUntilstring解凍時間戳 (毫秒)
    > mmpFrozenboolean當前是否觸發了mmp凍結.
    • true: mmpFrozenUntil的值有意義
    • false: 請忽略mmpFrozenUntil字段的值

    請求示例

    POST /unified/v3/private/account/mmp-state HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "result": [
    {
    "baseCoin": "BTC",
    "mmpEnabled": true,
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "0.01",
    "deltaLimit": "0.01",
    "mmpFrozenUntil": "1675760625519",
    "mmpFrozen": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675843188984
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/leverage.html b/zh-TW/derivatives/unified/leverage.html index dc0143382e..56011ca5fd 100644 --- a/zh-TW/derivatives/unified/leverage.html +++ b/zh-TW/derivatives/unified/leverage.html @@ -4,13 +4,13 @@ 設置槓桿倍數 | Bybit API Documentation - +

    設置槓桿倍數

    設置槓桿倍數

    HTTP 請求

    POST /unified/v3/private/position/set-leverage

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. 僅linear
    symboltruestring合約名稱
    buyLeveragetruestring(0, 風險限額允許的最大槓桿數]. 注意:單倉模式下,buyLeverage需要和sellLeverage保持一致
    sellLeveragetruestring(0, 風險限額允許的最大槓桿數]. 注意:單倉模式下,buyLeverage需要和sellLeverage保持一致

    響應參數

    請求示例

    POST /unified/v3/private/position/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016383313
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "ARUSDT",
    "buyLeverage": "11",
    "sellLeverage": "11"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016384347
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/open-order.html b/zh-TW/derivatives/unified/open-order.html index e1dca3777f..2c56f8ca7d 100644 --- a/zh-TW/derivatives/unified/open-order.html +++ b/zh-TW/derivatives/unified/open-order.html @@ -4,13 +4,13 @@ 查詢實時委託單 | Bybit API Documentation - +

    查詢實時委託單

    實時查詢未成交或部分成交的訂單信息. 若需要查詢更久的訂單紀錄,請使用查詢歷史訂單接口.

    提示
    • orderIdorderLinkId不傳時,最多返回500條紀錄
    • 返回的結果將以createdTime從新到舊排序.

    HTTP 請求

    GET /unified/v3/private/order/unfilled-orders

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種. 若category=option,不傳時,默認返回BTC相關數據
    orderIdfalsestring訂單id
    orderLinkIdfalsestring用戶自定義訂單Id
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單
    directionfalsestring翻頁方向. prev: 向前翻頁, next: 向後翻頁. 默認: next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義ID
    > blockTradeIdstringParadigm大宗交易ID
    > symbolstring合約名稱
    > ivstring隱含波動率. linear沒有該字段
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > orderStatusstring訂單狀態
    > orderTypestring訂單類型. Market,Limit
    > stopOrderTypestring條件單類型. option沒有該字段
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > cumExecQtystring訂單累計成交數量
    > tpTriggerBystring觸發止盈的價格類型. option沒有該字段
    > slTriggerBystring觸發止損的價格類型. option沒有該字段
    > timeInForcestring執行策略
    > basePricestring當前市價,用於條件單
    > triggerBystring觸發價格的觸發類型. option沒有該字段
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格. option沒有該字段
    > leavesQtystring訂單剩餘未成交的數量
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. option沒有該字段
    > takeProfitstring止盈價格. option沒有該字段
    > stopLossstring止損價格. option沒有該字段
    > orderIMstring訂單初始保證金. 組合保證金模式下,該字段返回空字符串
    > createdTimenumber創建訂單的時間戳 (毫秒)
    > updatedTimenumber訂單更新的時間戳 (毫秒)

    請求示例

    GET /unified/v3/private/order/unfilled-orders?category=option&baseCoin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1673079658059
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "d00b5b7b-4e05-4a12-a81c-8afb6ddf76bc%3A1673079539417%2Cd00b5b7b-4e05-4a12-a81c-8afb6ddf76bc%3A1673079539417",
    "category": "linear",
    "list": [
    {
    "symbol": "MATICUSDT",
    "orderType": "Limit",
    "orderLinkId": "",
    "orderId": "d00b5b7b-4e05-4a12-a81c-8afb6ddf76bc",
    "stopOrderType": "UNKNOWN",
    "orderStatus": "New",
    "takeProfit": "",
    "cumExecValue": "0.00000000",
    "blockTradeId": "",
    "price": "1.00000000",
    "createdTime": 1673079539417,
    "tpTriggerBy": "UNKNOWN",
    "timeInForce": "PostOnly",
    "basePrice": "",
    "updatedTime": 1673079539426,
    "side": "Sell",
    "triggerPrice": "",
    "cumExecFee": "0.00000000",
    "slTriggerBy": "UNKNOWN",
    "leavesQty": "500.0000",
    "closeOnTrigger": true,
    "cumExecQty": "0.00000000",
    "reduceOnly": true,
    "qty": "500.0000",
    "stopLoss": "",
    "triggerBy": "UNKNOWN",
    "orderIM": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673079551691
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/order-list.html b/zh-TW/derivatives/unified/order-list.html index 18416b0b2f..e55c4b5b27 100644 --- a/zh-TW/derivatives/unified/order-list.html +++ b/zh-TW/derivatives/unified/order-list.html @@ -4,13 +4,13 @@ 查詢歷史訂單 | Bybit API Documentation - +

    查詢歷史訂單

    提示

    獲取歷史訂單紀錄. 由於訂單創建/撤銷是異步的, 該接口返回數據可能會有延遲. 若您想實時獲取訂單信息, 您可以查詢該接口或者通過websocket推送(推薦)

    HTTP 請求

    GET /unified/v3/private/order/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種. 若category=option,不傳時,默認返回BTC相關數據
    orderIdfalsestring訂單Id
    orderLinkIdfalsestring用戶自定義訂單Id
    orderStatusfalsestring訂單狀態。不傳則默認查詢所有狀態
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單
    directionfalsestring翻頁方向. prev: 向前, next: 向後. 默認: next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義Id
    > blockTradeIdstringParadigm大宗交易Id
    > symbolstring合約名稱
    > ivstring隱含波動率. linear沒有該字段
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > orderStatusstring訂單狀態
    > orderTypestring訂單類型. Market,Limit
    > stopOrderTypestring條件單類型. option沒有該字段
    > rejectReasonstring被拒絕原因
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > cumExecQtystring訂單累計成交數量
    > tpTriggerBystring觸發止盈的價格類型. option沒有該字段
    > slTriggerBystringStop loss price. option沒有該字段
    > timeInForcestring執行策略
    > basePricestring當前市價,用於條件單
    > triggerBystring觸發價格的觸發類型. option沒有該字段
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格. option沒有該字段
    > leavesQtystring訂單剩餘未成交的數量
    > leavesValuestring訂單剩餘未成交的價值. option沒有該字段
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. option沒有該字段
    > takeProfitstring止盈價格. option沒有該字段
    > stopLossstring止損價格. option沒有該字段
    > orderIMstring訂單初始保證金. 組合保證金模式下,該字段返回空字符串
    > createdTimenumber創建訂單的時間戳 (毫秒)
    > updatedTimenumber訂單更新的時間戳 (毫秒)

    請求示例

    GET /unified/v3/private/order/list?category=linear&orderFilter=StopOrder&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672811957817
    X-BAPI-RECV-WINDOW: 5000
    cdn-request-id: test-002

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "c6f055d9-7f21-4079-913d-e6523a9cfffa%3A1672216686849%2Cc6f055d9-7f21-4079-913d-e6523a9cfffa%3A1672216686849",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Limit",
    "orderLinkId": "linear-004",
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "stopOrderType": "Stop",
    "orderStatus": "Deactivated",
    "takeProfit": "",
    "cumExecValue": "0",
    "blockTradeId": "",
    "rejectReason": "EC_NoError",
    "price": "1050",
    "createdTime": 1672216686849,
    "tpTriggerBy": "UNKNOWN",
    "timeInForce": "GoodTillCancel",
    "basePrice": "1188",
    "leavesValue": "0",
    "updatedTime": 1672217377166,
    "side": "Sell",
    "triggerPrice": "1145.00000000",
    "cumExecFee": "0",
    "slTriggerBy": "UNKNOWN",
    "leavesQty": "0",
    "closeOnTrigger": false,
    "cumExecQty": "0",
    "reduceOnly": false,
    "qty": "0.15",
    "stopLoss": "",
    "triggerBy": "MarkPrice",
    "orderIM": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672811958171
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/place-order.html b/zh-TW/derivatives/unified/place-order.html index 7a23856cb9..4fbba419b8 100644 --- a/zh-TW/derivatives/unified/place-order.html +++ b/zh-TW/derivatives/unified/place-order.html @@ -4,7 +4,7 @@ 創建委託單 | Bybit API Documentation - + @@ -16,7 +16,7 @@ 該訂單ID去取消活動委托,同時要求您傳遞的自定義訂單ID 最大長度不超過36個字段且唯一

  • 訂單持有上限: 期貨: 單個账户针对合约可持有每个 symbol 最多可同时持有500个普通活动订单。这是针对合约的,因此可以允许出现例如:账户同时持有300个BTCUSD的活动单、 280个ETHUSD合约的活动单。針對條件單,單個帳戶針對合約可持有每個 symbol 最多同時持有 10 個條件單。 期權: 最多可持有100個委託單

  • 期權不支持創建條件單

  • HTTP 請求

    POST /unified/v3/private/order/create

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symboltruestring合約名稱
    sidetruestring方向. Buy, Sell
    orderTypetruestring訂單類型. Market, Limit
    qtytruestring下單數量
    pricefalsestring訂單價格. orderType=Market時,值將被忽略
    basePricefalsestring當前市價
    • 用於和triggerPrice值進行比較,確定當前條件委托是看空到triggerPrice時觸發還是看多到triggerPrice觸發
    • 主要是用來標識當前條件單預期的方向
    triggerPricefalsestring觸發價格. 如果您期望價格上漲时觸發您的條件訂單, 請確保:
    triggerPrice > max(market price, basePrice)
    否則, triggerPrice < min(market price, basePrice)
    triggerByfalsestring觸發價格類型. LastPrice, IndexPrice, MarkPrice. 默認: LastPrice
    ivfalsestring隱含波動率. 僅適用於option. 按照實際值傳慘,如10%,則傳0.1
    timeInForcetruestring訂單執行策略 GoodTillCancel, ImmediateOrCancel, FillOrKill, PostOnly
    positionIdxfalseinteger倉位標識. 0: 單向持倉, 1: 買側雙向持倉, 2: 賣側雙向持倉. 統一保證金僅支持單向持倉
    orderLinkIdfalsestring用戶自定義訂單ID, 最大長度36位,且同一機構下自定義ID支持數字、字母(大小寫)、中劃線、下劃線這些字符的組合
    期貨規則:
    • 該參數選填
    • USDC永續和USDT永續的orderLinkId互相獨立,即orderLinkId可相同
    • 在訂單未完全成交或取消前,orderLinkId需保持不一致; 訂單完全成交或取消後,orderLinkId可使用之前使用過的
    • 期權規則:
    • 該參數必傳
    • 總是唯一
    takeProfitfalsestring止盈價格
    stopLossfalsestring止損價格
    tpTriggerByfalsestring止盈激活價格類型,MarkPrice, IndexPrice, 默認:LastPrice
    slTriggerByfalsestring止損激活價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    reduceOnlyfalseboolean什麼是只減倉? true 將這筆訂單設為只減倉. 只減倉單的止盈止損不生效
    closeOnTriggerfalseboolean什麼是觸發後平倉委託? 此選項可以確保您的止損單被用於減倉(平倉)而非加倉,並且在可用保證金不足的情況下,取消其他委託,騰出保證金以確保平倉委託的執行.
    mmpfalseboolean做市商保護. 僅對期權生效. true表示該訂單是做市商保護訂單

    響應參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring用戶自定義訂單ID

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/create' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.01",
    "price": "20002",
    "timeInForce": "GoodTillCancel",
    "category": "linear"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "e10b0716-7c91-4091-b98a-1fa0f401c7d5",
    "orderLinkId": "test0000003"
    },
    "retExtInfo": {},
    "time": 1664441344238
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/position-info.html b/zh-TW/derivatives/unified/position-info.html index d40fdf309b..e2c6b84c43 100644 --- a/zh-TW/derivatives/unified/position-info.html +++ b/zh-TW/derivatives/unified/position-info.html @@ -4,13 +4,13 @@ 查詢持倉 (實時) | Bybit API Documentation - +

    查詢持倉 (實時)

    該接口可以獲取用戶的持倉信息,比如持倉數量,累計盈虧等

    HTTP 請求

    GET /unified/v3/private/position/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種.
    • category=option時有效, 若不傳,則僅返回BTC持倉
    settleCoinfalsestring結算幣種
    directionfalsestring翻頁方向. prev: 向前, next: 向後. 默認: next
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > leveragestring槓桿倍數. 注意: 組合保證金模式下,該字段返回"",槓桿規則失效
    > updatedTimeinteger倉位數據更新時間戳 (ms)
    > sidestring訂單方向. `Buy`, `Sell`
    > positionValuestring倉位價值
    > takeProfitstring止盈價格
    > tpslModestring止盈止損模式. `Partial`, `Full`
    > riskIdinteger風險限額ID. 注意: 組合保證金模式下,該字段返回0,風險限額規則失效
    > trailingStopstring追蹤止損 (距離當前價格的距離)
    > entryPricestring平均入場價
    > unrealisedPnlstring未結盈虧
    > markPricestring標記價格
    > sizestring倉位大小
    > stopLossstring止損價格
    > cumRealisedPnlstring累計已結盈虧
    > positionMMstring倉位維持保證金. 組合保證金模式下,該字段返回""
    > createdTimeinteger建立倉位時間戳 (毫秒)
    > positionIdxinteger倉位標識, 用于在不同仓位模式下标识仓位
  • `0`: 單向持倉, 統一保證金只有單向持倉
  • > positionIMstring倉位初始保證金. 組合保證金模式下,該字段返回""

    請求示例

    GET /unified/v3/private/position/list?category=linear&symbol=XRPUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672820718517
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "updateAt%3D1672819200214",
    "category": "linear",
    "list": [
    {
    "symbol": "XRPUSDT",
    "updatedTime": 1672819200214,
    "leverage": "10",
    "side": "Buy",
    "positionValue": "34.91000000",
    "takeProfit": "",
    "tpslMode": "Partial",
    "riskId": 41,
    "trailingStop": "0",
    "entryPrice": "0.34910000",
    "unrealisedPnl": "0.00000000",
    "markPrice": "0.34910000",
    "size": "100.0000",
    "cumRealisedPnl": "-0.02444200",
    "stopLoss": "",
    "positionMM": "0.36795140",
    "createdTime": 1672016298024,
    "positionIdx": 0,
    "positionIM": "3.50985140"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672820720159
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/replace-order.html b/zh-TW/derivatives/unified/replace-order.html index ed2523b9d8..698c97db87 100644 --- a/zh-TW/derivatives/unified/replace-order.html +++ b/zh-TW/derivatives/unified/replace-order.html @@ -4,13 +4,13 @@ 修改委託單 | Bybit API Documentation - +

    修改委託單

    警告

    您只能修改那些未成交或者部分成交的訂單。

    HTTP 請求

    POST /unified/v3/private/order/replace

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單
    ivfalsestring隱含波動率. 僅對期權有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1
    triggerPricefalsestring觸發價格. 若希望市場趨勢是上漲至觸發條件單, 則確保:
    triggerPrice > max(market price, basePrice) 否則,
    triggerPrice < min(market price, basePrice)
    qtyfalsestring修改後的訂單數量. 若不修改,請不要傳該字段
    pricefalsestring修改後的訂單價格. 若不修改,請不要傳該字段
    takeProfitfalsestring修改後的止盈價格. 若不修改,請不要傳該字段
    stopLossfalsestring修改後的止損價格. 若不修改,請不要傳該字段
    tpTriggerByfalsestring止盈價格觸發類型. 若下單時未設置該值,則調用該接口修改止盈價格時,該字段必傳
    slTriggerByfalsestring止損價格觸發類型. 若下單時未設置該值,則調用該接口修改止損價格時,該字段必傳
    triggerByfalsestring觸發價格的觸發類型

    響應參數

    參數類型說明
    orderIdstring訂單Id
    orderLinkIdstring用戶自定義訂單Id

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/unified/v3/private/order/replace' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1657871228347' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "category": "linear",
    "symbol":"BTCUSDT",
    "orderId":"1a1ae001-2034-4a6b-8b25-45aa9100b1ec",
    "price":"35000"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1a1ae001-2034-4a6b-8b25-45aa9100b1ec",
    "orderLinkId": "e80d558e-ed"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/reset-mmp.html b/zh-TW/derivatives/unified/reset-mmp.html index db4952754c..162ea8ecc2 100644 --- a/zh-TW/derivatives/unified/reset-mmp.html +++ b/zh-TW/derivatives/unified/reset-mmp.html @@ -4,13 +4,13 @@ 重置市商保護凍結 | Bybit API Documentation - +

    重置市商保護凍結

    信息

    一旦mmp被觸發, 您的帳戶可以調用該接口進行主動解凍。

    HTTP 請求

    POST /unified/v3/private/account/mmp-reset

    請求參數

    參數是否必需類型說明
    baseCointruestring交易幣種

    響應參數

    請求示例

    POST /unified/v3/private/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/risk-limit.html b/zh-TW/derivatives/unified/risk-limit.html index 76b1e42264..c7340605d7 100644 --- a/zh-TW/derivatives/unified/risk-limit.html +++ b/zh-TW/derivatives/unified/risk-limit.html @@ -4,14 +4,14 @@ 設置風險限額 | Bybit API Documentation - +

    設置風險限額

    風險限額會限制你在不同的保證金要求下的可持倉的最大倉位數量,如果要持有更多的倉位,需要更多的保證金要求。本接口可以設置單個倉位的風險限額, 下單時如果超過當前的風險限額,則會被拒絕。點擊這裡了解更多關於風險限額.

    提示

    您可以獲取通過該接口查詢到風險限額信息.

    HTTP 請求

    POST /unified/v3/private/position/set-risk-limit

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symboltruestring合約名稱
    riskIdtrueinteger風險限額Id
    positionIdxfalseinteger倉位標識,用於標識不同倉位. 0: 單倉模式, 統一保證金僅有單倉模式

    響應參數

    請求示例

    POST /unified/v3/private/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016123862
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "riskId": 2,
    "positionIdx": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016125676
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/set-mmp.html b/zh-TW/derivatives/unified/set-mmp.html index 79af7e01a9..5f0ece487d 100644 --- a/zh-TW/derivatives/unified/set-mmp.html +++ b/zh-TW/derivatives/unified/set-mmp.html @@ -4,7 +4,7 @@ 设置市商保護 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 在短時間內的總交易額超過了配置的限額,該賬戶的做市商保護將被觸發。當做市商保護被觸發時,賬戶現有的做市商保護訂單(被標記為做市商保護的訂單)將被 交易引擎自動取消,而該賬戶新的做市商保護訂單將在未來一段時間(稱為凍結期)被拒絕(常規非MMP訂單不受影響)。用戶可以利用這段時間重新評估行情並修改報價。

    如何開通MMP

    您可通過郵件Bybit【financial.inst@bybit.com】或聯繫對應的客戶經理申請開通。 開通後,MMP的默認配置為:

    參數類型說明默認值
    baseCoinstring交易幣種BTC
    windowstring時間窗口 (毫秒)5000
    frozenPeriodstring凍結時間段 (毫秒)100
    qtyLimitstring成交數量上限100
    deltaLimitstringDelta值上限100

    適用對象

    僅適用於期權交易. 當創建期權訂單時, 設置參數mmp=true, 則表示將此訂單納入市商保護。

    HTTP 請求

    POST /unified/v3/private/account/mmp-modify

    請求參數

    參數是否必需類型說明
    baseCointruestring交易幣種
    windowtruestring時間窗口 (毫秒)
    frozenPeriodtruestring凍結時間長度 (毫秒). 設置為"0"則表示帳戶會保持凍結狀態,除非手動重置
    qtyLimittruestring成交數量上限 (正數,至多2位小數)
    deltaLimittruestringDelta上限 (正數,至多2位小數)

    響應參數

    請求示例

    POST /unified/v3/private/account/mmp-modify HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675833524616
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "baseCoin": "ETH",
    "window":"5000",
    "frozenPeriod":"100000",
    "qtyLimit":"50",
    "deltaLimit":"20"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/settlement.html b/zh-TW/derivatives/unified/settlement.html index 7d595f51de..5e730a9e39 100644 --- a/zh-TW/derivatives/unified/settlement.html +++ b/zh-TW/derivatives/unified/settlement.html @@ -4,13 +4,13 @@ 查詢結算紀錄 (USDC永續) | Bybit API Documentation - +

    查詢結算紀錄 (USDC永續)

    查詢USDC永續的結算紀錄

    HTTP 請求

    GET /unified/v3/private/settlement-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symbolfalsestring合約名稱
    directionfalsestringprev: 前一頁, next: 後一頁. 默認: next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > sidestring方向. Buy,Sell
    > sizestring倉位大小
    > sessionAvgPricestring結算價格
    > markPricestring標記價格
    > realisedPnlstring已實現盈虧
    > timestring結算時間 (毫秒)

    請求示例

    GET /unified/v3/private/settlement-record?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672020804664
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "1516%3A0%2C1516%3A0",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "0.72230000",
    "symbol": "BTCPERP",
    "side": "Buy",
    "markPrice": "19769.82000000",
    "size": "0.0100",
    "time": "1666828800000",
    "sessionAvgPrice": "19769.82000000"
    },
    ]
    },
    "retExtInfo": {},
    "time": 1672020805170
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/tp-sl-mode.html b/zh-TW/derivatives/unified/tp-sl-mode.html index 63058dd55b..b1e49b8156 100644 --- a/zh-TW/derivatives/unified/tp-sl-mode.html +++ b/zh-TW/derivatives/unified/tp-sl-mode.html @@ -4,13 +4,13 @@ 切換止盈止損模式 | Bybit API Documentation - +

    切換止盈止損模式

    可以將止盈止損模式設置為部分止盈止損或者全部止盈止損

    HTTP 請求

    POST /unified/v3/private/position/tpsl/switch-mode

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symboltruestring合約名稱
    tpSlModetruestring止盈止損模式. Full, Partial

    響應參數

    請求示例

    POST /unified/v3/private/position/tpsl/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672016302990
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "tpSlMode": "Partial"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672016303452
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/trading-stop.html b/zh-TW/derivatives/unified/trading-stop.html index 9fecb66713..4344f2f5ad 100644 --- a/zh-TW/derivatives/unified/trading-stop.html +++ b/zh-TW/derivatives/unified/trading-stop.html @@ -4,13 +4,13 @@ 設置止盈止損 | Bybit API Documentation - +

    設置止盈止損

    該接口可以設置止盈、止損和追蹤止損

    提示

    在提交請求後,系統內部將會自動創建對應類型的條件單。若倉位被平,系統將會調整相關條件訂單數量或者取消這些條件單。

    HTTP 請求

    POST /unified/v3/private/position/trading-stop

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symboltruestring合約名稱
    takeProfitfalsestring不能小於0. 設置為0時,則表示取消止盈. 部分止盈止損無法通過設置0來取消
    stopLossfalsestring不能小於0. 設置為0時,則表示取消止損. 部分止盈止損無法通過設置0來取消
    trailingStopfalsestring不能小於0. 設置為0時,則表示取消追蹤止損. 注意: 僅對USDT永續有效
    tpTriggerByfalsestring止盈價格類型
    slTriggerByfalsestring止損價格類型
    activePricefalsestring追蹤止損激活價格. 追蹤止損會在到達該價格時觸發
    tpSizefalsestring止盈倉位數量. 僅部分止盈止損時有效. 注意: 部分止盈止損模式僅限USDT永續
    slSizefalsestring止盈倉位數量. 僅部分止盈止損時有效. 注意: 部分止盈止損模式僅限USDT永續
    positionIdxtrueinteger倉位標識,用於識別倉位. 0: 單向持倉,對於統一保證金,僅有單向持倉模式

    響應參數

    請求示例

    POST /unified/v3/private/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXX
    X-BAPI-API-KEY: XXXX
    X-BAPI-TIMESTAMP: 1672017116301
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol":"BTCUSDT",
    "takeProfit":"18000",
    "stopLoss":"15500",
    "tpTriggerBy":"MarkPrice",
    "slTriggerBy":"MarkPrice",
    "trailingStop": null,
    "activePrice": null,
    "slSize": "0.05",
    "tpSize": "0.1",
    "positionIdx": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1672017116958
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/transaction-log.html b/zh-TW/derivatives/unified/transaction-log.html index 43d0a4c394..6c0a51269f 100644 --- a/zh-TW/derivatives/unified/transaction-log.html +++ b/zh-TW/derivatives/unified/transaction-log.html @@ -4,13 +4,13 @@ 查詢交易日誌 | Bybit API Documentation - +

    查詢交易日誌

    UNIFIED賬戶的交易日誌。

    HTTP 請求

    GET /unified/v3/private/account/transaction-log

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,option
    currencytruestring幣種. 比如:USDC、USDT、BTC、ETH
    baseCoinfalsestring交易幣種
    typefalsestring默認返回該category下所有交易日誌(除劃轉外). 注意: 查詢轉入轉出日誌,必須要傳 type=TRANSFER_IN,type=TRANSFER_OUT,否則查不到劃轉日誌.
    startTimefalseinteger開始時間戳(毫秒)
    endTimefalseinteger結束時間戳(毫秒)
    directionfalsestring搜索方向:prev:上一頁,next:下一頁,默認為 next
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於分頁

    響應參數

    參數類型說明
    categorystring產品類型
    currencystring幣種
    listarrayObject
    > transactionTimenumber交易時間戳 (毫秒)
    > typestring類型
    > symbolstring合約名稱
    > sidestring方向. Buy,Sell,None
    > qtystring訂單數量
    > sizeinteger倉位數量
    > tradePricestring交易價格
    > fundingstring資金費用
    > feestring手續費,取資產的fee,正數表示用戶付出xx手續費,負數表示賺取
    > cashFlowstring現金流
    > changestring變更
    > cashBalancestring余額(當前幣種)
    > feeRatestring手續費率
    > tradeIdstring交易ID
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義訂單ID
    nextPageCursorstring游標,用於分頁

    請求示例

    GET /unified/v3/private/account/transaction-log?category=linear&currency=USDC&limit=1&type=SETTLEMENT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023156071
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "nextPageCursor": "1516%3A0%2C1516%3A0",
    "currency": "USDC",
    "category": "linear",
    "list": [
    {
    "symbol": "BTCPERP",
    "side": "None",
    "funding": "0.00000000",
    "orderLinkId": "",
    "orderId": "",
    "fee": "",
    "change": "0.00000000",
    "cashFlow": "0.00000000",
    "transactionTime": 1666857600000,
    "type": "SETTLEMENT",
    "feeRate": "",
    "size": "0.0000",
    "qty": "",
    "cashBalance": "22.96780168",
    "tradePrice": "",
    "tradeId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672023157776
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/upgrade.html b/zh-TW/derivatives/unified/upgrade.html index 8ff374f3ef..dc99755776 100644 --- a/zh-TW/derivatives/unified/upgrade.html +++ b/zh-TW/derivatives/unified/upgrade.html @@ -4,13 +4,13 @@ 升級至統一保證金帳戶 | Bybit API Documentation - +

    升級至統一保證金帳戶

    升級至統一保證金賬戶

    HTTP 請求

    POST /unified/v3/private/account/upgrade-unified-account

    請求參數

    響應參數

    參數類型說明
    statusstring升級狀態. FAIL, SUCCESS
    > relieveLimitBizResponsearray若請求成功,則返回空數組[]
    >> relieveLimitCodestring失敗碼值
    >> relieveLimitMsgstring失敗的消息
    >> relieveLimitMobileUrlstring""
    >> relieveLimitWebUrlstring""
    >> passboolean是否滿足升級要求

    請求示例

    POST /unified/v3/private/account/upgrade-unified-account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672022838777
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {}

    響應示例

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "result": {
    "status": "FAIL",
    "relieveLimitBizResponse": [
    {
    "relieveLimitCode": "3400071",
    "relieveLimitMsg": "unable to upgrade as you haven’t met the minimum asset requirement.",
    "relieveLimitMobileUrl": "",
    "relieveLimitWebUrl": "",
    "pass": false
    },
    {
    "relieveLimitCode": "3400051",
    "relieveLimitMsg": "unable to upgrade, please close the usdt perpetual positions in USDT account.",
    "relieveLimitMobileUrl": "",
    "relieveLimitWebUrl": "",
    "pass": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672022840011
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/usc-account-info.html b/zh-TW/derivatives/unified/usc-account-info.html index b98775bf40..55b0f249c3 100644 --- a/zh-TW/derivatives/unified/usc-account-info.html +++ b/zh-TW/derivatives/unified/usc-account-info.html @@ -4,13 +4,13 @@ 查詢帳戶配置 | Bybit API Documentation - +

    查詢帳戶配置

    該接口可以查詢賬戶下的配置

    HTTP 請求

    GET /unified/v3/private/account/info

    請求參數

    響應參數

    參數類型說明
    unifiedMarginStatusinteger帳戶狀態類型
    marginModestringREGULAR_MARGIN(常規保證金模式) PORTFOLIO_MARGIN(組合保證金模式)
    dcpStatusstring設置斷線保護時間 開關狀態: ON, OFF
    timeWindowinteger設置的DCP觸發時間窗口. 範圍為[10, 300] 秒, 默認: 10 秒
    smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    updatedTimestring賬戶數據更新的時間,毫秒時間戳

    請求示例

    GET /unified/v3/private/account/info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023630281
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginMode": "REGULAR_MARGIN",
    "updatedTime": "1672918286000",
    "unifiedMarginStatus": 3,
    "dcpStatus": "ON",
    "timeWindow": 30,
    "smpGroup": 0
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/usc-margin-mode.html b/zh-TW/derivatives/unified/usc-margin-mode.html index 060b3761bf..e93fef0aa4 100644 --- a/zh-TW/derivatives/unified/usc-margin-mode.html +++ b/zh-TW/derivatives/unified/usc-margin-mode.html @@ -4,13 +4,13 @@ 設置保證金模式 | Bybit API Documentation - +

    設置保證金模式

    用戶如果不設置,默認按常規保證金。該模式支持USDT永續, USDC永續和期權

    HTTP 請求

    POST /unified/v3/private/account/setMarginMode

    請求參數

    參數是否必需類型說明
    setMarginModetruestringREGULAR_MARGIN(常規保證金模式)PORTFOLIO_MARGIN(組合保證金模式)默認常規,傳常規則返回設置成功

    響應參數

    參數類型說明
    reasonsarrayObject. 若請求提交成功, 則返回空數組
    > reasonCodestring失敗錯誤碼
    > reasonMsgstring失敗錯誤消息

    請求示例

    POST /unified/v3/private/account/setMarginMode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672023475526
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "setMarginMode": "REGULAR_MARGIN"
    }

    響應示例

    {
    "retCode": 3400045,
    "retMsg": "Set margin mode failed",
    "result": {
    "reasons": [
    {
    "reasonCode": "3400102",
    "reasonMsg": "Please ensure that there are no active orders in your USDC account, including Limit, Market and Conditional orders"
    },
    {
    "reasonCode": "3400101",
    "reasonMsg": "Please ensure that there are no positions in your USDC account, including USDC perpetual and options"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/unified/wallet.html b/zh-TW/derivatives/unified/wallet.html index 25bfb7e350..386891f939 100644 --- a/zh-TW/derivatives/unified/wallet.html +++ b/zh-TW/derivatives/unified/wallet.html @@ -4,13 +4,13 @@ 獲取錢包餘額 | Bybit API Documentation - +

    獲取錢包餘額

    獲取錢包餘額

    HTTP 請求

    GET /unified/v3/private/account/wallet/balance

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱. 允許傳多個, 用逗號隔開. 例如: BTC,ETH

    響應參數

    參數類型說明
    accountIMRatestring帳戶初始保證金率: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin.
    accountMMRatestring帳戶維持保證金率: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin。
    totalEquitystring賬戶維度換算成usd的資產淨值:Account Margin Balance Base Coin + Account Option Value Base Coin。
    totalWalletBalancestring賬戶維度換算成usd的產錢包餘額:∑ Asset Wallet Balance Base Coin。
    totalMarginBalancestring賬戶維度換算成usd的保證金餘額:Account Wallet Balance Base Coin + Account Perp UPL Base Coin。
    totalAvailableBalancestring賬戶維度換算成usd的可用餘額:RM:Account Margin Balance Base Coin - Account Initial Margin Base Coin。
    totalPerpUPLstring賬戶維度換算成usd的永續浮動盈虧:∑ Asset Perp UPL Base Coin。
    totalInitialMarginstring賬戶維度換算成usd的總初始保證金:∑ Asset Total Initial Margin Base Coin。
    totalMaintenanceMarginstring賬戶維度換算成usd的總維持保證金: ∑ Asset Total Maintenance Margin Base Coin。
    coinarray幣種列表
    > currencyCoinstring錢包幣種的名稱,例如 BTC,ETH,USDT,USDC
    > availableToBorrowstring由於母子共享借貸限額, 該字段已廢棄, 總是返回""
    > borrowSizestring已借數額. 只有 USDC,USDT 有。 BTC 和 ETH 則返回為 0
    > bonusstring體驗金
    > accruedIntereststring某資產應計利息
    > availableBalanceWithoutConvertstring可用餘額. Margin Balance - Total Initial Margin
    > totalOrderIMstring訂單委託預佔用保證金. 組合保證金模式下,該字段返回空字符串
    > equitystring用戶資產
    > totalPositionMMstring所有倉位維持保證金求和. 組合保證金模式下,該字段返回空字符串
    > usdValuestring折算成 usd 的價值
    > availableBalancestring可用餘額(其餘資產可用餘額 + 該幣種實際可用餘額)
    > unrealisedPnlstring未結盈虧
    > totalPositionIMstring所有倉位起始保證金求和 + 預佔用平倉手續費. 組合保證金模式下,該字段返回空字符串
    > marginBalanceWithoutConvertstring保證金餘額
    > walletBalancestring錢包餘額
    > cumRealisedPnlstring累計已結盈虧
    > marginBalancestring保證金餘額(其餘資產的MB + 該幣種下實際的MB)

    請求示例

    GET /unified/v3/private/account/wallet/balance?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672021457498
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    "totalEquity": "5952.13539158",
    "accountIMRate": "0.1037",
    "totalMarginBalance": "6003.96034690",
    "totalInitialMargin": "622.37237856",
    "totalAvailableBalance": "5381.58796835",
    "accountMMRate": "0.0361",
    "totalPerpUPL": "-733.16272882",
    "totalWalletBalance": "6733.45726207",
    "totalMaintenanceMargin": "216.49590186",
    "coin": [
    {
    "currencyCoin": "ETH",
    "availableToBorrow": "0.00000000",
    "borrowSize": "0.00000000",
    "bonus": "0.00000000",
    "accruedInterest": "0.00000000",
    "availableBalanceWithoutConvert": "0.00000000",
    "totalOrderIM": "",
    "equity": "0.00000000",
    "totalPositionMM": "",
    "usdValue": "0.00000000",
    "availableBalance": "4.41128415",
    "unrealisedPnl": "",
    "totalPositionIM": "",
    "marginBalanceWithoutConvert": "0.00000000",
    "walletBalance": "0.00000000",
    "cumRealisedPnl": "",
    "marginBalance": "4.92144238"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672021457963
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-contract/execution.html b/zh-TW/derivatives/ws-contract/execution.html index 76bf6c5fb3..22e34b8634 100644 --- a/zh-TW/derivatives/ws-contract/execution.html +++ b/zh-TW/derivatives/ws-contract/execution.html @@ -4,14 +4,14 @@ 個人成交 | Bybit API Documentation - +

    個人成交

    訂閱個人成交的推送

    覆蓋範圍: USDT永續, 反向合約

    推送頻率: 實時

    Topic: user.execution.contractAccount

    響應參數

    參數類型說明
    topicstringTopic名
    dataarrayObject
    > symbolstring合約名稱
    > sidestring方向. Buy,Sell
    > execIdstring成交ID
    > feeRatestring手續費率
    > execFeestring交易手續費
    > execPricestring成交價格
    > execQtystring成交數量
    > leavesQtystring剩餘委託未成交數量
    > execTypestring交易類型
    > execValuestring成交價值
    > lastLiquidityIndstring流動性標識. AddLiquidity,RemovedLiquidity
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義訂單ID
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > orderTypestring訂單類型. Market,Limit
    > stopOrderTypestring條件單類型. 若不是條件單,則不會返回任何類型
    > execTimestring交易時間戳 (毫秒)
    > closedSizestring平倉數量
    > blockTradeIdstringParadigm大宗商品交易ID
    > markPricestring標記價格

    推送示例

    {
    "topic": "user.execution.contractAccount",
    "data": [
    {
    "symbol": "ETHUSDT",
    "execFee": "0.1017888",
    "execId": "8b4b2e8c-caa1-5fde-be59-d483166885e7",
    "execPrice": "1696.48",
    "execQty": "0.1",
    "execType": "Trade",
    "execValue": "169.648",
    "feeRate": "0.0006",
    "lastLiquidityInd": "RemovedLiquidity",
    "leavesQty": "0",
    "orderId": "cd2f6f95-8031-4272-9339-e7054ff56567",
    "orderLinkId": "",
    "orderPrice": "1781.09",
    "orderQty": "0.1",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "side": "Buy",
    "execTime": "1676885237382",
    "closedSize": "0",
    "blockTradeId": "",
    "markPrice": "1696.25"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-contract/order.html b/zh-TW/derivatives/ws-contract/order.html index 1edfa65a89..73b7f9de32 100644 --- a/zh-TW/derivatives/ws-contract/order.html +++ b/zh-TW/derivatives/ws-contract/order.html @@ -4,14 +4,14 @@ 訂單 | Bybit API Documentation - +

    訂單

    訂閱訂單數據推送

    覆蓋範圍: USDT永續, 反向合約

    推送頻率: 實時

    Topic: user.order.contractAccount

    響應參數

    參數類型說明
    topicstringTopic名
    dataarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義ID
    > sidestring方向. Buy,Sell
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
    > stopOrderTypestring條件單類型. 若不是條件單,則不會返回任何類型
    > pricestring訂單價格
    > qtystring訂單數量
    > blockTradeIdstring大宗交易訂單Id
    > timeInForcestring執行策略
    > orderStatusstring訂單狀態
    > positionIdxinteger倉位標識。用戶不同倉位模式
    > cancelTypestring訂單被取消類型
    > rejectReasonstring拒絕原因
    > avgPricestring訂單平均成交價格. 若沒有成交,則返回""
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > triggerDirectioninteger觸發方向. 0: 上漲, 1: 下跌
    > triggerBystring觸發類型
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > leavesQtystring訂單剩餘未成交的數量
    > leavesValuestring訂單剩餘未成交的價值
    > lastExecQtystring成交數量
    • 當訂單狀態是成交或者部分成交時, 該字段展示的是成交數量
    • 當訂單狀態是取消時, 該字段展示的是剩餘未成交數量
    > lastExecPricestring成交價格
    > cumExecQtystring累計成交數量
    > cumExecValuestring累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring創建訂單的時間戳 (毫秒)
    > updatedTimestring訂單更新的時間戳 (毫秒)

    推送示例

    {
    "topic": "user.order.contractAccount",
    "data": [
    {
    "symbol": "ETHUSDT",
    "orderId": "e62a3099-eced-499f-bd81-185e8747187f",
    "side": "Buy",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "price": "1622.55",
    "qty": "0.2",
    "timeInForce": "ImmediateOrCancel",
    "orderStatus": "Filled",
    "triggerPrice": "0.00",
    "orderLinkId": "",
    "createdTime": "1675999655229",
    "updatedTime": "1675999655232",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "triggerDirection": 0,
    "leavesQty": "0",
    "lastExecQty": "0.2",
    "lastExecPrice": "1545.30",
    "cumExecQty": "0.2",
    "cumExecValue": "309.06",
    "avgPrice": "1545.30",
    "blockTradeId": "",
    "cancelType": "UNKNOWN",
    "cumExecFee": "0.185436",
    "leavesValue": "0",
    "positionIdx": 1,
    "rejectReason": "EC_NoError",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-contract/position.html b/zh-TW/derivatives/ws-contract/position.html index 8477a7cecb..135c20b533 100644 --- a/zh-TW/derivatives/ws-contract/position.html +++ b/zh-TW/derivatives/ws-contract/position.html @@ -4,14 +4,14 @@ 持倉 | Bybit API Documentation - +

    持倉

    訂閱持倉數據的推送

    覆蓋範圍: USDT永續,反向合約

    Topic: user.position.contractAccount

    響應參數

    參數類型說明
    topicstringTopic名
    dataarrayObject
    > symbolstring合約名稱
    > riskIdinteger風險限額ID
    > riskLimitValuestring風險限額
    > sidestring方向. Buy,Sell
    > sizestring持倉大小
    > entryPricestring平均入場價
    > positionValuestring倉位價值
    > positionIdxinteger倉位標識, 用於辨別不同持倉模式
    • 0: 單向持倉模式
    • 1: 買側雙向持倉模式
    • 2: 賣側雙向持倉模式
    > tradeModeinteger交易模式. 0: 全倉, 1: 逐倉
    > autoAddMargininteger是否自動增加保證金. 0: 否, 1: 是
    > leveragestring槓桿倍數
    > positionBalancestring倉位保證金
    > markPricestring標記價格
    > liqPricestring強平價格. 當強平價 <= minPrice 或者強平價 >= maxPrice時, 則為""
    > bustPricestring破產價格
    > tpSlModestring該字段已廢棄, 無意義, 總是返回"Full"
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > trailingStopstring追蹤止損
    > activePricestring追蹤止損的激活價格
    > unrealisedPnlstring未結盈虧
    > cumRealisedPnlstring累計盈虧
    > occClosingFeestring預佔用平倉手續費
    > sessionAvgPricestring結算價格
    > positionStatusstring倉位狀態. Normal, Abnormal
    > positionMMstring倉位初始保證金
    > positionIMstring倉位維持保證金
    > adlRankIndicatorinteger自動減倉燈. 什麼是自動減倉機制?
    > isReduceOnlyboolean僅當Bybit需要降低某個Symbol的風險限額時有用
    • true: 僅允許減倉操作. 您可以考慮一系列的方式, 比如, 降低risk limit檔位, 或者同檔位修改槓桿或減少倉位, 或者增加保證金, 或者撤單, 這些操作做完後, 可以主動調用確認新的風險限額接口
    • false(默認): 沒有交易限制, 表示您的倉位在系統調整時處於風險水平之下
    • 僅對逐倉和全倉的期貨倉位有意義
    > mmrSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改MMR的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了MMR調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > leverageSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改槓桿的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了槓桿調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > createdTimestring倉位創建時間戳 (毫秒)
    > updatedTimestring倉位創建時間戳 (毫秒)

    推送示例

    {
    "topic": "user.position.contractAccount",
    "data": [
    {
    "positionIdx": 0,
    "riskId": 1,
    "symbol": "ARBUSDT",
    "side": "None",
    "size": "0",
    "positionValue": "0",
    "entryPrice": "0",
    "tradeMode": 0,
    "autoAddMargin": 0,
    "leverage": "10",
    "positionBalance": "0",
    "liqPrice": "",
    "bustPrice": "0.0000",
    "takeProfit": "0.0000",
    "stopLoss": "0.0000",
    "trailingStop": "0.0000",
    "unrealisedPnl": "0",
    "createdTime": "1695115891722",
    "updatedTime": "1697686565866",
    "tpSlMode": "Full",
    "sessionAvgPrice": "0.0000",
    "positionStatus": "Normal",
    "occClosingFee": "0",
    "markPrice": "0.7747",
    "cumRealisedPnl": "21.84890946",
    "activePrice": "0.0000",
    "riskLimitValue": "200000",
    "positionMM": "0",
    "positionIM": "0",
    "adlRankIndicator": 0,
    "isReduceOnly": false,
    "mmrSysUpdateTime": "",
    "leverageSysUpdatedTime": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-contract/wallet.html b/zh-TW/derivatives/ws-contract/wallet.html index 9bc77727ff..beda834b7d 100644 --- a/zh-TW/derivatives/ws-contract/wallet.html +++ b/zh-TW/derivatives/ws-contract/wallet.html @@ -4,14 +4,14 @@ 錢包 | Bybit API Documentation - +

    錢包

    訂閱錢包數據推送

    覆蓋範圍: USDT永續, 反向合約

    推送頻率: 實時

    Topic: user.wallet.contractAccount

    響應參數

    參數類型說明
    topicstringTopic名
    dataarrayObject
    > coinstring幣種
    > equitystring總資產
    > walletBalancestring錢包餘額
    > positionMarginstring倉位保證金
    > availableBalancestring可用餘額
    > orderMarginstring委託單預佔用保證金
    > unrealisedPnlstring未結盈虧
    > cumRealisedPnlstring累計已結盈虧

    推送示例

    {
    "topic": "user.wallet.contractAccount",
    "data": [
    {
    "coin": "USDT",
    "equity": "8538.34927711",
    "walletBalance": "8505.77505604",
    "positionMargin": "58.93257631",
    "availableBalance": "8436.20247873",
    "orderMargin": "10.640001",
    "unrealisedPnl": "32.57422107",
    "cumRealisedPnl": "-195.05231821"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-public/kline.html b/zh-TW/derivatives/ws-public/kline.html index 4081530656..d4481f7281 100644 --- a/zh-TW/derivatives/ws-public/kline.html +++ b/zh-TW/derivatives/ws-public/kline.html @@ -4,14 +4,14 @@ K線 | Bybit API Documentation - +

    K線

    訂閱K線數據

    覆蓋範圍: 正向合約,反向合約

    可用時間粒度:

    • 1 3 5 15 30 60 120 240 360 720分鐘
    • D
    • W
    • M
    信息

    註意如果字段confirm為true, 則表明這是這根K線的最後一個tick;否則,這只是一個快照數據,即中間價格

    推送頻率: 1-60s

    Topic: kline.{interval}.{symbol} e.g., kline.30.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > startnumber開始時間戳 (毫秒)
    > endnumber結束時間戳 (毫秒). 若時間還未到時間跨度的最後時間,則表示當前時間
    > intervalstringK線粒度
    > openstring開盤價
    > closestring收盤價
    > highstring最高價
    > lowstring最低價
    > volumestring交易量
    > turnoverstring交易額
    > confirmboolean是否確認
    > timestampnumber蠟燭中最後一筆淨值時間戳 (毫秒)

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "kline.5.BTCPERP"
    ],
    "req_id": "test" // 可選
    }

    推送示例

    {
    "topic": "kline.5.BTCPERP",
    "data": [
    {
    "start": 1671187800000,
    "end": 1671188099999,
    "interval": "5",
    "open": "16991",
    "close": "16980.5",
    "high": "16991",
    "low": "16980.5",
    "volume": "2.501",
    "turnover": "42493.2305",
    "confirm": false,
    "timestamp": 1671187815755
    }
    ],
    "ts": 1671187815755,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-public/liquidation.html b/zh-TW/derivatives/ws-public/liquidation.html index 1a1c05646f..e07a39ab1d 100644 --- a/zh-TW/derivatives/ws-public/liquidation.html +++ b/zh-TW/derivatives/ws-public/liquidation.html @@ -4,14 +4,14 @@ 強平推送 | Bybit API Documentation - +

    強平推送

    訂閱Bybit平台上的期貨強平推送

    覆蓋範圍: 正向合約,反向合約

    推送頻率: 實時

    Topic: liquidation.{symbol} e.g., liquidation.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > updatedTimenumber數據更新時間戳 (毫秒)
    > symbolstring合約名稱
    > sizestring成交數量
    > pricestring成交價格
    > sidestring方向

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "liquidation.GALAUSDT"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-public/orderbook.html b/zh-TW/derivatives/ws-public/orderbook.html index 68f6e0da0e..c60dae5aaf 100644 --- a/zh-TW/derivatives/ws-public/orderbook.html +++ b/zh-TW/derivatives/ws-public/orderbook.html @@ -4,14 +4,14 @@ 深度 | Bybit API Documentation - +

    深度

    訂閱不同深度的推送

    覆蓋範圍: 正向合約, 反向合約, 期權

    信息
    • 訂閱成功後,會立即得到一個當前快照包的推送消息.
    • websocket將會繼續推送這些增量數據. 收到snapshot的報文,就需要重置本地的orderbook.
    • snapshot=全量orderbook, delta=增量orderbook
    • 如果因為Bybit服務原因,會重新發送snapshot報文,該報文已保證是最新且準確的.
    提示

    正向合約 & 反向合約 1檔數據: 若3秒內無變化,將會再次推送snapshot數據.

    正向合約 & 反向合約:

    • 1 檔數據, 推送頻率: 10ms
    • 50 檔數據, 推送頻率: 20ms
    • 200 檔數據, 推送頻率: 100ms
    • 500 檔數據, 推送頻率: 100ms

    Option:

    • 25 檔數據, 推送頻率: 20ms
    • 100 檔數據, 推送頻率: 100ms

    Topic:
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot,delta
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > sstring合約名稱
    > barrayBid, 買方. snapshot數據,是按照價格從大到小
    >> b[0]string買方報價
    >> b[1]string買方數量
    > aarrayAsk, 賣方. snapshot數據,是按照價格從小到大
    >> a[0]string賣方報價
    >> a[1]string賣方數量
    uinteger更新id, 一般情況下該id是連續的。偶爾會因後台的重啟而發送"u"=1的全量數據,接收到後請覆蓋本地保存的orderbook
    seqinteger撮合版本號

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "orderbook.50.BTCUSDT"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1671179923028,
    "data": {
    "s": "BTCUSDT",
    "b": [
    [
    "17440.00",
    "40.833"
    ],
    [
    "17439.50",
    "0.513"
    ],
    ...
    [
    "17416.00",
    "6.156"
    ],
    [
    "17415.50",
    "32.268"
    ]
    ],
    "a": [
    [
    "17440.50",
    "78.815"
    ],
    [
    "17441.00",
    "8.858"
    ],
    ...
    [
    "17464.50",
    "4.901"
    ],
    [
    "17465.00",
    "5.744"
    ]
    ],
    "u": 13079592,
    "seq": 22520573250
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-public/ticker.html b/zh-TW/derivatives/ws-public/ticker.html index 2a325c6540..f9b67e2bff 100644 --- a/zh-TW/derivatives/ws-public/ticker.html +++ b/zh-TW/derivatives/ws-public/ticker.html @@ -4,14 +4,14 @@ 行情 | Bybit API Documentation - +

    行情

    訂閱行情數據

    覆蓋範圍: 正向合約,反向合約,期權

    重要
    • 期貨,該topic推送delta數據和snapshot数据。如果delta數據為空,表明信息沒有發生變化。
    • 期權只推送snapshot類型數據

    推送頻率: 100ms

    Topic: tickers.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名稱
    typestring數據類型. `snapshot`,`delta`
    csinteger撮合版本號
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > symbolstring合約名稱
    > tickDirectionstring價格變化方向
    > price24hPcntstring市場價格相對24h前變化的百分比
    > lastPricestring最新市場成交價
    > prevPrice24hstring24小時前的整點市價
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價
    > prevPrice1hstring1小時前的整點市價
    > markPricestring標記價格
    > indexPricestring指數價格
    > openIntereststring未平倉合約的數量
    > openInterestValuestring未平倉合約的價值
    > turnover24hstring最近24小時成交額
    > volume24hstring最近24小時成交量
    > nextFundingTimestring下次結算資金費用的時間戳 (毫秒)
    > fundingRatestring資金費率
    > bid1Pricestring買1價
    > bid1Sizestring買1價的數量
    > ask1Pricestring賣1價
    > ask1Sizestring賣1價的數量

    推送示例

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "MinusTick",
    "price24hPcnt": "0.017367",
    "lastPrice": "17222.00",
    "prevPrice24h": "16928.00",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17224.40",
    "indexPrice": "17234.84",
    "openInterest": "68795.534",
    "openInterestValue": "1184961795.83",
    "turnover24h": "1572429119.324499",
    "volume24h": "91823.449",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000211",
    "bid1Price": "17222.00",
    "bid1Size": "220.358",
    "ask1Price": "17222.50",
    "ask1Size": "3.902"
    },
    "cs": 24988405605,
    "ts": 1673273043686
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-public/trade.html b/zh-TW/derivatives/ws-public/trade.html index f156bf43d6..aeca5da91c 100644 --- a/zh-TW/derivatives/ws-public/trade.html +++ b/zh-TW/derivatives/ws-public/trade.html @@ -4,14 +4,14 @@ 平台成交 | Bybit API Documentation - +

    平台成交

    訂閱Bybit平台上最近成交的推送. 從用戶訂閱開始, 實時推送增量交易歷史, 有成交數據就推送.

    覆蓋範圍: 正向合約,反向合約,期權

    推送頻率: 實時

    Topic: publicTrade.{symbol} 注意: 期權使用baseCoin, e.g., publicTrade.BTC

    響應參數

    參數類型說明
    idstring消息 id. 期權沒有該字段
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject. 如有多條, 則數組中的元素按照匹配時間升序排序
    > Tnumber成交時間戳 (毫秒)
    > sarray合約名稱
    > Sstring吃單方向. Buy,Sell
    > vstring成交數量
    > pstring成交價格
    > Lstring價格變化的方向. 期權沒有該字段
    > istring成交Id
    > BTboolean成交類型是否為大宗交易

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "publicTrade.BTCPERP"
    ],
    "req_id": "test" // optional
    }

    推送示例

    {
    "topic": "publicTrade.BTCPERP",
    "type": "snapshot",
    "ts": 1671181689023,
    "data": [
    {
    "T": 1671181689021,
    "s": "BTCPERP",
    "S": "Buy",
    "v": "0.002",
    "p": "17032.50",
    "L": "MinusTick",
    "i": "d9cd8295-40dc-5dce-8deb-42882580a7ab",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-unified/execution.html b/zh-TW/derivatives/ws-unified/execution.html index 5facd7736b..04b06b1d4c 100644 --- a/zh-TW/derivatives/ws-unified/execution.html +++ b/zh-TW/derivatives/ws-unified/execution.html @@ -4,14 +4,14 @@ 個人成交 | Bybit API Documentation - +

    個人成交

    訂閱個人成交的推送

    提示
    • 單筆訂單可能有多次成交
    • 僅USDT永續交易對推送資金費用類型的成交

    Topic:
    user.execution.unifiedAccount

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    typestring消息類型. snapshot
    tsnumber消息數據創建時間
    dataObject
    > versioninteger版本號
    > resultarrayObject
    >> symbolstring合約名稱
    >> orderIdstring訂單ID
    >> sidestring方向. Buy,Sell
    >> orderLinkIdstring用戶自定義訂單ID
    >> orderPricestring訂單價格
    >> orderQtystring訂單數量
    >> orderTypestring訂單類型. 市價單:Market,限價單:Limit
    >> execIdstring成交ID
    >> execPricestring成交價格
    >> execQtystring成交數量
    >> execValuestring成交價值
    >> feeRatestring手續費率
    >> execFeestring交易手續費
    >> execTimestring交易時間戳 (毫秒)
    >> execTypestring成交類型. TRADE, ADLTRADE, FUNDING, BUSTTRADE, SETTLE
    >> lastLiquidityIndstring流動性類型. TAKER: 吃單,MAKER: 掛單
    >> leavesQtystring剩餘委託未成交數量
    >> stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则不会返回任何类型
    >> blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID

    推送示例

    {
    "id": "331355731ff43340-3504-4643-a953-87f275de985e",
    "topic": "user.execution.unifiedAccount",
    "ts": 1672833057231,
    "data": {
    "result": [
    {
    "symbol": "ETHUSDT",
    "execFee": "0.0075063",
    "execId": "91704d47-4c11-5577-9be9-1beb35ae989d",
    "execPrice": "1251.05",
    "execQty": "0.01",
    "execType": "TRADE",
    "execValue": "12.5105",
    "feeRate": "0.0006",
    "lastLiquidityInd": "TAKER",
    "leavesQty": "0",
    "orderId": "9bb96006-711a-4235-9bc5-080302b4285c",
    "orderLinkId": "",
    "orderPrice": "1188.45",
    "orderQty": "0.01",
    "orderType": "Market",
    "stopOrderType": "",
    "side": "Sell",
    "execTime": 1672833057221,
    "blockTradeId": ""
    }
    ],
    "version": 3120492
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-unified/greek.html b/zh-TW/derivatives/ws-unified/greek.html index 4a91e016e1..99fcfa44af 100644 --- a/zh-TW/derivatives/ws-unified/greek.html +++ b/zh-TW/derivatives/ws-unified/greek.html @@ -4,14 +4,14 @@ 用戶希臘字母信息 (期權) | Bybit API Documentation - +

    用戶希臘字母信息 (期權)

    訂閱希臘字母信息,僅期權

    Topic:
    user.greeks.unifiedAccount

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    typestring消息類型. snapshot
    tsnumber消息數據創建時間
    dataObject
    > versioninteger版本號
    > resultObject
    >> baseCoinstring交易幣種
    >> totalDeltastringDelta值
    >> totalGammastringGamma值
    >> totalVegastringVega值
    >> totalThetastringTheta值

    推送示例

    {
    "id": "53328593eddf20-ebe8-47d9-8a2b-62e4e2681eaa",
    "topic": "user.greeks.unifiedAccount",
    "ts": 1672107550646,
    "data": {
    "result": [
    {
    "baseCoin": "BTC",
    "totalDelta": "-0.02077347",
    "totalGamma": "-0.00004675",
    "totalVega": "-0.52558304",
    "totalTheta": "3.48921259"
    },
    {
    "baseCoin": "ETH",
    "totalDelta": "0.05003533",
    "totalGamma": "-0.00000063",
    "totalVega": "-0.00014849",
    "totalTheta": "0.0041225"
    }
    ],
    "version": 62056
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-unified/order.html b/zh-TW/derivatives/ws-unified/order.html index 53ccddb986..007105681b 100644 --- a/zh-TW/derivatives/ws-unified/order.html +++ b/zh-TW/derivatives/ws-unified/order.html @@ -4,14 +4,14 @@ 訂單 | Bybit API Documentation - +

    訂單

    訂閱訂單數據推送

    Topic:
    user.order.unifiedAccount

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    typestring消息類型. snapshot
    tsnumber消息數據創建時間
    dataObject
    > versioninteger版本號
    > resultarrayObject
    >> symbolstring合約名稱
    >> sidestring方向. Buy,Sell
    >> orderIdstring訂單ID
    >> orderLinkIdstring用戶自定義ID
    >> orderTypestring訂單類型. Market,Limit
    >> stopOrderTypestring條件單類型
    >> orderStatusstring訂單狀態
    >> pricestring訂單價格
    >> qtystring訂單數量
    >> timeInForcestring執行策略
    >> cumExecQtystring訂單累計成交數量
    >> cumExecValuestring訂單累計成交價值
    >> cumExecFeestring訂單累計成交的手續費
    >> leavesQtystring訂單剩餘未成交的數量
    >> triggerBystring觸發價格的觸發類型
    >> triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    >> reduceOnlyboolean只減倉. true表明這是只減倉單
    >> closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    >> ivstring隱含波動率
    >> orderIMstring訂單初始保證金. 組合保證金模式下,該字段返回空字符串
    >> takeProfitstring止盈價格
    >> stopLossstring止損價格
    >> tpTriggerBystring觸發止盈的價格類型
    >> slTriggerBystring觸發止損的價格類型
    >> basePricestring當前市價
    >> blockTradeIdstring大宗交易訂單ID
    >> createdTimenumber創建訂單的時間戳 (毫秒)
    >> updatedTimenumber訂單更新的時間戳 (毫秒)

    推送示例

    {
    "id": "533285293a44e9-7925-445c-a62c-01d7726c6543",
    "topic": "user.order.unifiedAccount",
    "ts": 1672063477614,
    "data": {
    "result": [
    {
    "orderId": "38554b22-e4fa-4327-9250-3fc81aa4e30a",
    "orderLinkId": "",
    "symbol": "SCUSDT",
    "side": "Sell",
    "orderType": "Market",
    "price": "0.00224",
    "qty": "100",
    "timeInForce": "ImmediateOrCancel",
    "orderStatus": "Filled",
    "cumExecQty": "100",
    "cumExecValue": "0.234",
    "cumExecFee": "0.0001404",
    "stopOrderType": "UNKNOWN",
    "triggerBy": "UNKNOWN",
    "triggerPrice": "0",
    "reduceOnly": true,
    "closeOnTrigger": true,
    "createdTime": 1672063477568,
    "updatedTime": 1672063477578,
    "iv": "",
    "orderIM": "",
    "takeProfit": "0",
    "stopLoss": "0",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "basePrice": "0.00235",
    "blockTradeId": "",
    "leavesQty": "0"
    }
    ],
    "version": 17965
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-unified/position.html b/zh-TW/derivatives/ws-unified/position.html index c1a87dd623..5510c547a5 100644 --- a/zh-TW/derivatives/ws-unified/position.html +++ b/zh-TW/derivatives/ws-unified/position.html @@ -4,14 +4,14 @@ 持倉 | Bybit API Documentation - +

    持倉

    訂閱持倉數據的推送。當倉位有變動時,即推送消息。

    Topic:
    user.position.unifiedAccount

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    typestring消息類型. snapshot
    tsnumber消息數據創建時間
    dataObject
    > versioninteger版本號
    > resultarrayObject
    >> symbolstring合約名稱
    >> sidestring持倉方向. Buy,Sell
    >> sizestring持倉大小
    >> positionIdxinteger倉位標識
    >> riskIdinteger風險限額ID. 注意: 組合保證金模式下,該字段返回0,風險限額規則失效
    >> leveragestring槓桿倍數. 注意: 組合保證金模式下,該字段返回"",槓桿規則失效
    >> entryPricestring平均入場價
    >> markPricestring標記價
    >> positionValuestring倉位價值
    >> positionIMstring倉位初始保證金. 注意: 組合保證金模式下,該字段返回""
    >> positionMMstring倉位維持保證金. 注意: 組合保證金模式下,該字段返回""
    >> tpslModestring止盈止損模式. Full,Partial
    >> takeProfitstring止盈價格
    >> stopLossstring止損價格
    >> trailingStopstring追蹤止損
    >> unrealisedPnlstring未結盈虧
    >> cumRealisedPnlstring累計盈虧
    >> sessionAvgPricestring結算價格. 期權沒有該字段
    >> createdTimenumber倉位創建時間戳 (毫秒)
    >> updatedTimenumber倉位創建時間戳 (毫秒)

    推送示例

    {
    "id": "3313557309a19343-8362-4dde-9b5a-cef6823173f2",
    "topic": "user.position.unifiedAccount",
    "ts": 1673242361759,
    "data": {
    "result": [
    {
    "positionIdx": 0,
    "riskId": 1,
    "symbol": "BTCUSDT",
    "side": "Sell",
    "size": "-0.003",
    "entryPrice": "16790",
    "leverage": "10.1",
    "markPrice": "17225",
    "positionIM": "5.02034365",
    "positionMM": "0.28506449",
    "takeProfit": "",
    "stopLoss": "",
    "trailingStop": "",
    "positionValue": "50.37",
    "unrealisedPnl": "-1.305",
    "cumRealisedPnl": "-43.69152916",
    "createdTime": 1661488246836,
    "updatedTime": 1673242361755,
    "tpslMode": "Full",
    "sessionAvgPrice": "16790"
    }
    ],
    "version": 3342620
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws-unified/wallet.html b/zh-TW/derivatives/ws-unified/wallet.html index 5c350d8dab..1404b74111 100644 --- a/zh-TW/derivatives/ws-unified/wallet.html +++ b/zh-TW/derivatives/ws-unified/wallet.html @@ -4,14 +4,14 @@ 錢包 | Bybit API Documentation - +

    錢包

    訂閱錢包數據推送

    Topic:
    user.wallet.unifiedAccount

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    typestring消息類型. snapshot
    tsnumber消息數據創建時間
    dataObject
    > versioninteger版本號
    > resultObject
    >> accountIMRatestring帳戶初始保證金率: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin
    >> accountMMRatestring帳戶維持保證金率: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin
    >> totalEquitystring賬戶維度換算成usd的資產淨值:Account Margin Balance Base Coin + Account Option Value Base Coin
    >> totalWalletBalancestring賬戶維度換算成usd的產錢包餘額:∑ Asset Wallet Balance Base Coin
    >> totalMarginBalancestring賬戶維度換算成usd的保證金餘額:Account Wallet Balance Base Coin + Account Perp UPL Base Coin
    >> totalAvailableBalancestring賬戶維度換算成usd的可用餘額:RM:Account Margin Balance Base Coin - Account Initial Margin Base Coin
    >> totalPerpUPLstring賬戶維度換算成usd的永續浮動盈虧:∑ Asset Perp UPL Base Coin
    >> totalInitialMarginstring賬戶維度換算成usd的總初始保證金:∑ Asset Total Initial Margin Base Coin
    >> totalMaintenanceMarginstring賬戶維度換算成usd的總維持保證金: ∑ Asset Total Maintenance Margin Base Coin
    >> coinarray幣種列表
    >>> currencyCoinstring錢包幣種的名稱,例如 BTC,ETH,USDT,USDC
    >>> equitystring用戶資產
    >>> usdValuestring折算成 usd 的價值
    >>> walletBalancestring錢包餘額
    >>> marginBalancestring保證金餘額(其餘資產的MB + 該幣種下實際的MB)
    >>> availableBalancestring可用餘額(其餘資產可用餘額 + 該幣種實際可用餘額)
    >>> marginBalanceWithoutConvertstring保證金餘額
    >>> availableBalanceWithoutConvertstring可用餘額. Margin Balance - Total Initial Margin
    >>> borrowSizestring已借數額. 只有 USDC,USDT 有。 BTC 和 ETH 則返回為 0
    >>> availableToBorrowstring由於母子共享借貸限額, 該字段已廢棄, 總是返回""
    >>> accruedIntereststring某資產應計利息
    >>> totalOrderIMstring訂單委託預佔用保證金. 組合保證金模式下,該字段返回空字符串
    >>> totalPositionIMstring所有倉位起始保證金求和 + 預佔用平倉手續費. 組合保證金模式下,該字段返回空字符串
    >>> totalPositionMMstring所有倉位維持保證金求和. 組合保證金模式下,該字段返回空字符串
    >>> unrealisedPnlstring未結盈虧
    >>> cumRealisedPnlstring累計已結盈虧

    推送示例

    {
    "id": "5332858071ac1a-adcf-4c22-9967-4bdb763d993d",
    "topic": "user.wallet.unifiedAccount",
    "ts": 1673246212184,
    "data": {
    "result": {
    "accountIMRate": "0.1062",
    "accountMMRate": "0.0126",
    "totalEquity": "5306.99168766",
    "totalWalletBalance": "5015.81303189",
    "totalMarginBalance": "5315.50124767",
    "totalAvailableBalance": "4750.87543737",
    "totalPerpUPL": "299.68821577",
    "totalInitialMargin": "564.62581029",
    "totalMaintenanceMargin": "67.39562585",
    "coin": [
    {
    "currencyCoin": "USDC",
    "equity": "696.90520008",
    "usdValue": "696.90520008",
    "walletBalance": "702.87476009",
    "marginBalance": "5315.50124767",
    "availableBalance": "4750.87543737",
    "marginBalanceWithoutConvert": "705.41476009",
    "availableBalanceWithoutConvert": "472.43375944",
    "borrowSize": "0",
    "availableToBorrow": "1500000",
    "accruedInterest": "0",
    "totalOrderIM": "172.47750096",
    "totalPositionIM": "60.50349967",
    "totalPositionMM": "16.09254346",
    "unrealisedPnl": "-2.07956",
    "cumRealisedPnl": "153.26214849"
    },
    {
    "currencyCoin": "USDT",
    "equity": "2989.97442076",
    "usdValue": "2975.11272839",
    "walletBalance": "2691.34184935",
    "marginBalance": "5330.29357298",
    "availableBalance": "4750.7346256",
    "marginBalanceWithoutConvert": "2989.97442076",
    "availableBalanceWithoutConvert": "2658.33944077",
    "borrowSize": "0",
    "availableToBorrow": "2500000",
    "accruedInterest": "0",
    "totalOrderIM": "0.9205456",
    "totalPositionIM": "330.71443439",
    "totalPositionMM": "51.24010721",
    "unrealisedPnl": "298.63257142",
    "cumRealisedPnl": "-3418.29414098"
    }
    ]
    },
    "version": 177440
    },
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/derivatives/ws/connect.html b/zh-TW/derivatives/ws/connect.html index 00935ef6b6..f091e173e6 100644 --- a/zh-TW/derivatives/ws/connect.html +++ b/zh-TW/derivatives/ws/connect.html @@ -4,7 +4,7 @@ 訂閱WebSocket | Bybit API Documentation - + @@ -23,7 +23,7 @@ 合約: wss://stream.bybit.com/contract/private/v3

  • 測試網:
    統一保證金帳戶: wss://stream-testnet.bybit.com/unified/private/v3
    合約: wss://stream-testnet.bybit.com/contract/private/v3

  • 鑒權/認證

    信息

    公共頻道不需要鑒權,以下部分僅適用於私有頻道的訂閱。

    構建連接時,創建鑒權請求。

    注意: 如果您正在使用pybit, bybit-api或者其他第三方庫, 您可以忽略此項-因為鑒權已經內建。

    {
    "req_id": "10001", // 可選項
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //過期時間應當大於當前時間戳
    "singature"
    ]
    }
    # 基於: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    鑒權成功的響應示例

    {
    "success": true,
    "ret_msg": "",
    "op": "auth",
    "conn_id": "ced97gevha793pjs1t30-ob"
    }
    備註

    簽名生成的示例可以參考這裡

    警告

    由於網絡的複雜性,您可能隨時遇到斷連。請參考以下建議確保您能即時接收到推送:

    1. 通過發送心跳
    2. 遇到斷連時,立即重新連接

    IP限頻

    • 不要嘗試頻繁地構建連接與斷開連接
    • 不要在5分鐘內構建超過500個連接

    如何發送心跳

    發送ping的示例

    // req_id是可選參數
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    接收到pong的響應示例

    {
    "req_id": "test",
    "op": "pong",
    "args": [
    "1671163042443"
    ],
    "conn_id": "ce3e06kfnonvuu2e3j4g-2t5w"
    }
    警告

    為了維持連接,我們推薦您每20秒發送一次心跳。

    如何訂閱topic

    理解Websocket裡的args

    通過傳入args來訂閱指定topic

    // 訂閱1檔深度推送
    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    通過逗號隔開,可以同時訂閱多個topic或者多個symbol

    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT",
    "publicTrade.BTCUSDT",
    "orderbook.1.ETHUSDT",
    ]
    }

    理解如何取消訂閱

    您可以通過發送請求來動態地停止訂閱

    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.ETHUSD"
    ],
    "req_id": "customised_id"
    }

    理解訂閱的響應

    訂閱成功後的響應示例

    {
    "success": true,
    "ret_msg": "",
    "op": "subscribe",
    "conn_id": "ced97gevha793pjs1t30-ob"
    }

    訂閱成功後,您將收到結果信息。可以根據響應判斷訂閱是否成功。

    - + \ No newline at end of file diff --git a/zh-TW/derivativesV3/contract.html b/zh-TW/derivativesV3/contract.html index 5384ee119e..726d558df0 100644 --- a/zh-TW/derivativesV3/contract.html +++ b/zh-TW/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/derivativesV3/unified_margin.html b/zh-TW/derivativesV3/unified_margin.html index 8f472a02a6..90ab3b7941 100644 --- a/zh-TW/derivativesV3/unified_margin.html +++ b/zh-TW/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/faq.html b/zh-TW/faq.html index 3e92333d20..8b2d349623 100644 --- a/zh-TW/faq.html +++ b/zh-TW/faq.html @@ -4,7 +4,7 @@ 常見問題 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    常見問題

    Bybit的服務器在哪裡?

    AWS 新加坡, 可用區域 ID apse1-az3.

    reduceOnlycloseOnTrigger - 區別是什麼?

    • 要平倉,請提交訂單並將 reduceOnly 指定為 true。 closeOnTrigger 在這裡並不嚴格適用,但如果需要,您也可以將其設置為 true。
    • reduceOnly 是平倉時真正重要的一個,我們會在未來改進接口。
    • closeOnTrigger 指定為 true 時要小心,因為當 reduceOnly 為 false 時可能會導致衝突。

    為什麼網站上沒有顯示我的所有訂單?

    • 擁有下大量階梯訂單的機器人的用戶將受到前端界面的限制,該界面僅在屏幕上顯示最多 50 個訂單。
    • 不用擔心,您的訂單還在系統中,可以通過API查詢,但是前端顯示不會超過50個。

    根據可用錢包餘額計算訂單大小

    • price * availableBalance * leverage * perc * (1 - (0.0006 * 2))
    • 不幸的是,這不是一個完全準確的公式。實際計算很複雜,可能會在以後發佈在文檔中。
      • price - 最新價格 (或您的入場價) - 可以從最新行情信息接口中獲取。
      • availableBalance - 可以從查詢持倉(實時)接口中獲取。
      • leverage - 最高為市場各自的最大槓桿和您的風險限額(例如 2、10、50)。
      • perc - 0.1 表示 10%,0.25 表示 25%,等等。
      • 1 - (0.0006 * 2) - 用於計算最大訂單成本(始終假設進入和退出訂單使用吃單費用,而不考慮實際費用)。

    我可以用 API 兌換資產嗎?

    • 沒有接口可以交換資產。這只能在網站上完成。
    • 但是,可以使用 API 訪問您的資產交換記錄

    我如何獲得測試網的資金?

    要獲得測試網資金,只需到主賬戶資產頁面申請即可。

    為什麼我的平倉盈虧價格不准確?

    • Closed PNL接口返回的entryPriceexitPrice不是訂單的實際執行價格。
    • 它基於訂單的總成本 (頭寸是否僅由以一個價格執行的一個訂單開倉/平倉 - 如果多個訂單開倉/平倉則更加複雜。)
    • 例如,此接口報告的 entry_price 和 exit_price 受訂單支付/收到的費用的影響。

    如何確保我使用的是最新數據?

    • REST API 或(甚至不太可能)websocket 有可能(儘管不太可能)返回/推送舊數據。
    • 為了獲得最大程度的數據彈性,我們建議客戶:
      • 首先,依賴於websocket,它不僅能保證你以最快的速度得到最新的數據,還能保證你得到完整的數據
      • 其次,查詢 REST API 以填充數據中的任何差異 - 或者 websocket 斷開連接時之間的差異。
    • 最佳做法是將所有這些數據本地保存在您自己的數據庫或緩存中。
    • 這釋放了您對其他請求的速率限制,並且還確保了在數據延遲的情況下針對交易所的冗餘級別。

    交易額和成交量有什麼區別?

    • Turnover:與數量的貨幣相反的貨幣
    • Volume:與數量的貨幣使用相同的貨幣

    為什麼下市價單響應中返回的價格是錯誤的?

    市場訂單(在後端)只是以更差的價格提交的限價訂單。這是為了減少閃電崩盤或類似事件發生的可能性,在這種情況下,交易者可能會提交以比他們預期的價格低得多 的價格執行的市價單。這裡返回的價格是內部限價單價格。返回此“不准確”的價格是因為下單接口是異步的,這意味著在實際執行訂單之前將響應返回給您。

    如果你想要真正的執行價格 (execPrice),你應該訂閱 execution websocket

    - + \ No newline at end of file diff --git a/zh-TW/futuresV2/inverse.html b/zh-TW/futuresV2/inverse.html index 03b04331dd..3ae359791b 100644 --- a/zh-TW/futuresV2/inverse.html +++ b/zh-TW/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/futuresV2/inverse_futures.html b/zh-TW/futuresV2/inverse_futures.html index 50c4c16d5d..6fa4041320 100644 --- a/zh-TW/futuresV2/inverse_futures.html +++ b/zh-TW/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/futuresV2/linear.html b/zh-TW/futuresV2/linear.html index e939e02a84..f5a76b8677 100644 --- a/zh-TW/futuresV2/linear.html +++ b/zh-TW/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/index.html b/zh-TW/index.html index 08d3fb0460..fd03ade40a 100644 --- a/zh-TW/index.html +++ b/zh-TW/index.html @@ -4,13 +4,13 @@ Hello from Bybit API Documentation | Bybit API Documentation - +

    Unified APIs

    Bybit's latest v5 suite of APIs allow for a smooth and easy integration.

    Learn Exchange Mechanisms

    Learn the intricate details of Bybit's market rules to fully maximise your API usage.

    Historical Market Data

    Get comprehensive public market data in CSV format to speedily backtest and build strategies.

    - + \ No newline at end of file diff --git a/zh-TW/inverse.html b/zh-TW/inverse.html index ebfdd3a9cb..efddbaa82b 100644 --- a/zh-TW/inverse.html +++ b/zh-TW/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/inverse_futures.html b/zh-TW/inverse_futures.html index f849e8cd6b..3f134e5a6e 100644 --- a/zh-TW/inverse_futures.html +++ b/zh-TW/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/linear.html b/zh-TW/linear.html index 18b81fbad1..f2861f0460 100644 --- a/zh-TW/linear.html +++ b/zh-TW/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/markdown-page.html b/zh-TW/markdown-page.html index b68f1e990f..32385d5e7b 100644 --- a/zh-TW/markdown-page.html +++ b/zh-TW/markdown-page.html @@ -4,13 +4,13 @@ Markdown page example | Bybit API Documentation - +

    Markdown page example

    You don't need React to write simple standalone pages.

    - + \ No newline at end of file diff --git a/zh-TW/pilot-feature.html b/zh-TW/pilot-feature.html index c00c6d67ec..cdab088b68 100644 --- a/zh-TW/pilot-feature.html +++ b/zh-TW/pilot-feature.html @@ -4,7 +4,7 @@ 試點功能 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    試點功能

    現貨支持改單

    • 可用日期: 測試網 - 已上線, 主網 - 2023年11月1日
    • 覆蓋範圍: 經典帳戶和統一帳戶現貨
    • 詳細內容: 您可以通過這個改單接口對現貨訂單進行改單

    統一帳戶現貨止盈止損單、條件單邏輯修改

    • 可用日期: 測試網 - 已上線, 主網 - 2023年10月26日 (按照uid尾號灰度期間, 全量預計11月2日)
    • 覆蓋範圍: 統一帳戶的現貨交易
    • 詳細內容: 當止盈止損單或者條件單觸發後, 訂單ID保持不變

    UTA Pro支持批量下單

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月31日
    • 覆蓋範圍: UTA Pro帳戶: USDT永續, USDC永續 & USDC交割 (正向合約linear)
    • 詳細內容: UTA Pro帳戶能夠進行正向合約的批量下改撤
    示例
    POST https://api-testnet.bybit.com/v5/order/create-batch

    > 請求體
    {
    "category": "linear",
    "request": [
    {

    "symbol": "BTCUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.1",
    "price": "25500",
    "timeInForce": "GTC",
    "orderLinkId": "test-03",
    "reduceOnly": false,
    "tpslMode": "Full",
    "takeProfit": "26300",
    "stopLoss": "24800",
    "triggerDirection": null,
    "triggerPrice": null,
    "triggerBy": null,
    "positioIdx": 0,
    "smpType": null,
    "tpLimitPrice": null,
    "slLimitPrice": null,
    "slOrderType": null,
    "tpOrderType": null

    },
    {

    "symbol": "ETHUSDT",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "0.1",
    "price": "1550",
    "timeInForce": "GTC",
    "orderLinkId": "test-04",
    "reduceOnly": false,
    "tpslMode": "Full",
    "takeProfit": "1680",
    "stopLoss": "1490",
    "triggerDirection": null,
    "triggerPrice": null,
    "triggerBy": null,
    "positioIdx": 0,
    "smpType": null,
    "tpLimitPrice": null,
    "slLimitPrice": null,
    "slOrderType": null,
    "tpOrderType": null
    }
    ]
    }
    > 響應
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "orderId": "6afd7e83-7176-4f73-93e0-44a8f2babd14",
    "orderLinkId": "test-03",
    "createAt": "1693212677410"
    },
    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "orderId": "9eeef30c-c682-42b2-a4a7-7e403db8506c",
    "orderLinkId": "test-04",
    "createAt": "1693212677410"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1693212677411
    }

    增加WS私有連接可配置斷線時間

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月16日
    • 覆蓋範圍: 構建v5私有連接時可用該配置參數
    • 詳細內容: 構建連接時, 設置/v5/private?max_active_time=, 值可以是從30s600s之間。當服務端與客戶端之間無上下行數據時, 當達到這個配置的時間間隔時, 服務端則會斷開連接 (並不完全準確, 因為當前ticker的輪訓時間是30秒)

    調整錯誤碼

    舊錯誤碼新錯誤碼消息
    34001283200320Operations Restriction: The current LTV ratio of your Institutional Loan has hit the liquidation threshold. Assets in your account are being liquidated.
    1760363200320Operations Restriction: The current LTV ratio of your Institutional Loan has hit the liquidation threshold. Assets in your account are being liquidated.

    UTA母子帳戶間共享借貸額度

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月11日
    • 覆蓋範圍: 統一帳戶
    • 詳細內容: 過去, 每個uta帳戶擁有獨自的借貸額度, 上線後, 該額度由母子之間共享

    UTA用戶可以選擇保證金幣種是否進行抵押

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月10日
    • 覆蓋範圍: 統一帳戶
    • 詳細內容: UTA用戶可以選擇保證金幣種是否進行抵押通過該接口

    用戶可以自主升級到UTA Pro

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月8日
    • 覆蓋範圍: 普通帳戶, 統一帳戶
    • 詳細內容: 用戶可以通過該接口升級至UTA Pro

    OpenAPI支持現貨條件單

    • 可用日期: 測試網 - 已上線, 主網 - 2023年8月7日
    • 覆蓋範圍: 普通帳戶, 統一帳戶
    • 詳細內容: 用戶可以通過openAPI創建現貨條件單

    UTA支持機構借貸

    • 可用日期: 測試網 - 已上線, 主網 - 2023年7月24日
    • 覆蓋範圍: 統一帳戶
    • 詳細內容: 統一帳戶支持機構借貸

    USDC永續支持獲得資金費的數據

    • 可用日期: 測試網 - 已上線, 主網 - 2023年7月3日
    • 覆蓋範圍: 統一帳戶 USDC永續合約
    • 詳細內容: 查詢成交紀錄接口之前是沒有execType=Funding的且websocket個人成交不推送該數據. 現在您將會查詢到和獲得推送.

    新版帶單交易

    • 可用日期: 測試網 - 已上線, 主網 - 2023年6月24日
    • 覆蓋範圍: 舊版帶單交易
    • 詳細內容: Bybit將會從6月24日開始陸續開放uid升級功能, 如果您選擇升級到新的帶單交易, 請注意老版本的Copy Trading V3接口將不可再用, 請直接使用合約 V3 或者 V5接口

    統一帳戶支持逐倉保證金模式和雙倉模式

    • 可用日期: 測試網 - 已上線, 主網 - 2023年6月1日
    • 覆蓋範圍: 僅統一帳戶生效
    • 詳細內容: 統一帳戶的逐倉保證金是帳戶維度. 雙向持倉僅支持USDT永續

    新版止盈止損

    • 可用日期: 測試網 - 已上線, 主網 - 2023年5月23日
    • 覆蓋範圍: V5 API合約V3 API
    • 詳細內容: 統一帳戶(UTA): USDT 永續, USDC 永續 和 交割, 反向合約
      普通帳戶: USDT 永續, 反向合約

    查詢升級前紀錄

    • 可用日期: 測試網 - 已上線, 主網 - 2023年4月27日
    • 覆蓋範圍: 統一交易帳戶
    • 詳細內容: 升級後,可以通過該接口查詢到升級之前的一些交易紀錄.

    余幣寶

    • 可用日期: 測試網 - 已上線, 主網 - 2023年4月22日
    • 覆蓋範圍: 所有用戶 (目前灰度階段)
    • 詳細內容: 您可以將閒置資金存入余幣寶來賺取收益

    自成交攔截

    • 可用日期: 測試網 - 已上線, 主網 - 2023年4月20日
    • 覆蓋範圍: 請查看這裡
    • 詳細內容: 支持現貨、期貨和期權

    支持持倉升級至UTA帳戶

    • 可用日期: 測試網 - 已上線, 主網 - 2023年4月4日
    • 覆蓋範圍: 普通帳戶升級至統一帳戶
    • 詳細內容: 升級時無需平倉. 更多細節,請查閱升級接口

    統一交易帳戶支持USDC交割產品交易

    • 可用日期: 測試網 - 已上線, 主網 - 2023年3月20日
    • 覆蓋範圍: 僅限升級到UTA的帳戶
    • 詳細內容: V5接口將適用於UTA帳戶交易USDC交割

    機構借貸V5接口

    • 可用日期: 測試網 - 已上線, 主網 - 2023年3月13日
    • 覆蓋範圍: 申請了場外借貸的機構用戶
    • 詳細內容: 可以查詢到帳戶的LTV, 借款及還款等信息

    普通帳戶支持使用V5接口進行現貨交易

    • 可用日期: 測試網 - 已上線, 主網 - 2023年3月10日
    • 覆蓋範圍: 普通帳戶
    • 詳細內容: 使用V5交易現貨

    統一交易對狀態枚舉

    • 可用日期: 測試網 - 已上線, 主網 - 2023年3月10日
    • 覆蓋範圍: /v5/market/instruments-info status字段
    • 詳細內容: 統一使用Trading, Closed, Settling, PreLaunch, Deliverying

    上線全倉槓桿(普通帳戶)V5版本

    • 可用日期: 測試網 - 已上線, 主網 - 2023年3月3日
    • 覆蓋範圍: 普通帳戶能夠使用V5接口操作全倉槓桿
    • 詳細內容: 借貸、還款、查詢操作

    UTA用戶支持交易反向合約

    • 可用日期: 測試網 - 已上線, 主網 - 2023年2月21日
    • 覆蓋範圍: UTA用戶能夠通過V5接口交易反向合約
    • 詳細內容: 請注意該反向合約交易是通過反向合約錢包(CONTRACT)完成

    將現貨帳戶併入統一帳戶(重要)

    • 可用日期: 預計3月3日当天執行
    • 覆蓋範圍: 僅UTA用戶
    • 詳細內容: 您需要修改提現邏輯,先將資金轉入資金帳戶,然後調用提現接口

    使用RSA密鑰方式鑒權

    • 可用日期: 測試網 - 已上線, 主網 - 2023年2月21日
    • 覆蓋範圍: 所有V3、V5需要鑒權的接口
    • 詳細內容: 請參閱該引導完成快速上手

    execType增加新的枚舉值

    • 可用日期: 測試網 - 已上線, 主網 - 2023年2月20日
    • 覆蓋範圍: 合約 V3 - Websocket私有頻道 - 個人成交
    • 詳細內容: 新增資金費用結算的推送,其中execType=Funding

    V5接口支持普通帳戶

    • 可用日期: 測試網 - 已上線, 主網 - 2023年2月9日
    • 覆蓋範圍: 普通帳戶支持交易 USDT永續 and 反向合約
    • 詳細內容: 此次發佈之後,如果您有以下行為,您可能會遭遇一些401錯誤或者404錯誤:

    401: 您仍然在使用v1/v2的鑒權方式訪問V5接口:

    GET https://api.bybit.com/v5/position/list?api_key=xxx&category=linear&recv_window=5000&symbol=ETHUSDT&timestamp=1675929695887&sign=xxx

    您應該將鑒權參數放在請求頭當中:

    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'

    404: 對於以下接口,如果您傳入不恰當的category值, 比如, 您是普通帳戶,但category傳入了option/spot


    調整錯誤碼

    舊錯誤碼新錯誤碼消息
    3400045110073Set margin mode failed
    34009910016Server error

    增加500檔的推送

    • 可用日期: 測試網 - 2023年1月13日, 主網 - 2023年1月16日
    • 覆蓋範圍: V5 深度V3 深度
    • 詳細內容: 期貨的正反向合約將支持500檔深度的推送, 其中推送頻率為100ms.
    - + \ No newline at end of file diff --git a/zh-TW/search.html b/zh-TW/search.html index 89a3d0587a..fc1b53a96e 100644 --- a/zh-TW/search.html +++ b/zh-TW/search.html @@ -4,13 +4,13 @@ 在文件中搜尋 | Bybit API Documentation - + - + \ No newline at end of file diff --git a/zh-TW/spot.html b/zh-TW/spot.html index 788110056e..0a25b49f9a 100644 --- a/zh-TW/spot.html +++ b/zh-TW/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/spot/enum.html b/zh-TW/spot/enum.html index 9028a22629..49892a0e8c 100644 --- a/zh-TW/spot/enum.html +++ b/zh-TW/spot/enum.html @@ -4,7 +4,7 @@ 枚舉定義 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    枚舉定義

    side

    • BUY
    • SELL

    timeInForce

    • GTCGood Till Cancel,一直有效至取消
    • FOKFill or Kill,完全成交或取消
    • IOCImmediate or Cancel,立即成交或取消

    symbol

    orderType

    • MARKET
    • LIMIT
    • LIMIT_MAKER被動委託

    currency/coin

    • BTC
    • ETH
    • USDT
    • ...

    以下幣種支持全倉槓桿:

    • BTC
    • ETH
    • XRP
    • SOL
    • LTC
    • EOS
    • LINK
    • XLM
    • USDC
    • USDT
      您可以通過這個網址獲得所有全倉槓桿支持的幣種.

    orderStatus

    • NEW普通單被下達
    • ORDER_NEW止盈止損單被下達
    • PARTIALLY_FILLED
    • FILLED
    • ORDER_FILLED止盈止損單成交
    • CANCELED普通單被取消
    • ORDER_CANCELED止盈止損單被取消
    • REJECTED
    • ORDER_REJECTED止盈止損單被拒絕
    • PARTIALLY_FILLED_CANCELED
    • ORDER_FAILED止盈止損單失敗

    interval

    • 1m1 分鐘
    • 3m3 分鐘
    • 5m5 分鐘
    • 15m15 分鐘
    • 30m30 分鐘
    • 1h1 小時
    • 2h2 小時
    • 4h4 小時
    • 6h6 小時
    • 12h12 小時
    • 1d1 天
    • 1w1 周
    • 1M1 月

    ltStatus

    • 1槓桿代幣支持申贖
    • 2槓桿代幣支持申購,但無法贖回
    • 3槓桿代幣支持贖回,但是無法申購
    • 4槓桿代幣無法申贖

    ltOrderStatus

    • 1完成
    • 2進行中
    • 3失敗

    ltOrderType

    • 1申購
    • 2贖回

    smpType

    • 默認: None
    • CancelMaker
    • CancelTaker
    • CancelBoth
    - + \ No newline at end of file diff --git a/zh-TW/spot/error.html b/zh-TW/spot/error.html index d4a2be4f04..fed73a951e 100644 --- a/zh-TW/spot/error.html +++ b/zh-TW/spot/error.html @@ -4,13 +4,13 @@ 錯誤碼 | Bybit API Documentation - +

    錯誤碼

    錯誤碼描述
    5019用戶服務錯誤
    5004上游服務超時
    7001Grpc請求提交錯誤
    10003無效的api_key
    10006訪問過於頻繁,
    10001參數錯誤
    10002無效請求,請檢查您的timestmap和recv_window參數
    10004簽名錯誤
    10005權限受限
    10008UTA帳戶無法訪問當前接口,請確認您的帳戶模式
    10024合規牆攔截
    10029請檢查請求的symbol是否在交易對白名單中
    33004api_key已過期
    12940鏈結拒絕
    12999系統錯誤
    12800非法請求
    12801非法JSON信息
    12802非法event
    12803event必需的
    12804非法topic
    12805Topic必需的
    12806Param必需的
    12807Period必需的
    12808非法時間
    12809非法幣對
    12810不支持該幣對
    12811非法broker
    12812DumpScale必需的
    12813非法exchangeId
    12814Param字段錯誤
    12815幣對必需的
    12816超時,請稍後重試
    12817機構沒有開展業務
    12818客戶端斷開鏈結
    12819orgId必需的
    12820orgId必需是數字類型
    12821精度錯誤
    12822Index名稱錯誤
    12823參數錯誤
    12824參數缺失
    12825單次請求symbol數量不能超過300
    12001參數錯誤
    12007等待後端服務器響應超時。發送狀態未知
    12014不支持的訂單組合
    12005新订新訂單太多。請減少你的請求頻率
    12016該服務不可用
    12032熔斷錯誤碼
    12114風控異常
    12015UID不存在
    12011INNOVATION_BUY_FAILED_BY_QUOTA
    12010ETP_BUY_FAILED_BY_QUOTA
    12012ETP_NAV_IS_ABNORMAL
    12017CROSS_MARGIN_PRE_BUY_QUOTA_FAILED
    10020CROSS_MARGIN_PRE_SELL_QUOTA_FAILED
    12019您的帳戶被限制交易。如有疑問,請聯繫support@bybit.com
    12124訂單金額過大
    12031交易对未开放
    12105参数为空
    12115无效timeInForce
    12116无效订单类型
    12117无效买卖方向
    12121无效符号
    12130发送的参数为无效数据
    12131余额不足
    12132订单价格过高
    12133订单价格过低,请查询Broker
    12134订单价格精度过长,请查询Broker
    12135订单quantity过大
    12136订单quantity小于最小值
    12137订单quantity精度过长
    12138订单价格超出允许范围
    12139订单已经被执行
    12140交易金额小于最小值
    12141clientOrderId重复
    12142订单已经被撤销
    12143订单当前不在订单簿上
    12144订单已被锁定
    12145该订单类型不支持撤销
    12146订单生成超时
    12147订单撤销超时
    12148市價單的訂單金額小數過多
    12149創建訂單失敗
    12150撤銷訂單失敗
    12151該交易對已下架
    12156訂單數量無效
    12157該交易對不支持API交易
    12158創建LIMIT_MAKER訂單失敗
    12159由於風險控制,新上線的交易對在市場開始前的%s分鐘內不支持市價單
    12190撤销订单已完成
    12191无法撤单,
    12192訂單價格不能高於%s
    12193買單價格不能高於%s
    12194賣單價格不能低於%s
    12195您的訂單可能沒有成交
    12196您的訂單可能沒有成交
    12197您的買單的數量過大。成交價格可能嚴重偏離當前市場價格,請重試.
    12198您的賣單的數量過大。成交價格可能嚴重偏離當前市場價格,請重試.
    12199您的買單的數量過大。成交價格可能嚴重偏離nav,請重試.
    12200您的賣單的數量過大。成交價格可能嚴重偏離nav,請重試.
    12201订单种类错误
    12202触发价格为空
    12203触发价大于110%
    12204触发价小于90%
    12205不允许杠杆用户交易止盈止损
    12206止盈止损开盘前5分钟不允许下单
    12210New order rejected 新增订单被拒绝
    12211Cancelation rejected 撤销订单被拒绝
    12212Cancel order request processing 正在處理撤單請求
    12213Order does not exist 订单不存在
    12214This trading pair currently does not support trading. 根據合規要求, 該交易對不支持交易
    12217該交易對僅支持LIMIT_MAKER訂單
    12218由於價格無效,該筆LIMIT_MAKER訂單被拒絕
    12219UID {{xxx}} is not available to this feature
    12221幣種不存在
    12222請求過快
    12223場外借貸帳戶觸發吿警或爆倉
    12224非創新區用戶
    12225查詢用戶是否開通槓桿代幣協議失敗
    12226全倉用戶帳戶爆倉中
    12227功能未開放
    12228買入額度超過預估最大買入額
    12229賣出數量超過預估最大賣出量
    12230全倉槓桿中, 預佔額度校驗ltv不通過
    12231不允許全倉槓桿用戶交易大宗交易
    12232不允許場外借貸用戶交易大宗交易
    12233不允許ETP幣對交易大宗交易
    12234系統錯誤
    12400serialNo已使用過
    12401今日申購限額不足,請稍候嘗試
    12402申購訂單積壓較多,請稍後重試
    12403餘額不足,請充值後重試
    12404今日贖回限額不足,請稍候重試
    12405贖回訂單積壓較多,請稍後重試
    12406餘額不足,請充值後重試
    12407此訂單不存在
    12408當前申購未開啟
    12409申購金額超出上限
    12410您還未通過風險測試無法參與槓桿代幣的申贖和交易,請先在網頁端完成練習
    12412當前贖回未開啟
    12413贖回數量超過上限
    12414申購入口暫時關閉
    12415贖回入口暫時關閉
    12416輸入值格式不符合要求:精度或長度超出
    12417下單失敗:超出槓桿代幣持倉最大限制當前限制是XXXX USDT
    12601獲取用戶還款紀錄失敗
    12602獲取用戶帳戶信息失敗
    12603獲取用戶借款紀錄失敗
    12604獲取歷史紀錄的startTime大於endTime
    12605借款失敗
    12606還款失敗
    12607未找到借貸帳戶
    12608借貸帳戶未開通全倉槓桿,請先在web端開啟
    12609借貸帳戶未開通全倉槓桿,請先在web端和APP端開啟
    12610未找到借貸幣種
    12611幣種未開啟借貸
    12612未找到交易幣對
    12613交易比對未開啟借貸
    12614還款請求重複
    12615還款帳戶餘額不足
    12616無欠款,無需還款
    12617還款金額超過欠款金額
    12618用戶幣種已在還款中
    12619用戶還款計息強平衝突
    12620查詢不到還款紀錄
    12621借貸請求重複
    12622借貸幣種全量未開放
    12623交易對全量未開放
    12624借貸用戶狀態非正常
    12625借貸數量不能小於單詞最小借貸量
    12626借貸數量不能大於單次最大借貸量
    12627借貸數量不能大於平臺允許的單用戶最大借貸量
    12628借貸申請數量超過平臺最大借貸量
    12629借款申請數量超過用戶預估最大可借貸量
    12630獲取用戶借貸信息失敗
    12631借貸精度超過設置精度
    12632還款精度過高
    - + \ No newline at end of file diff --git a/zh-TW/spot/etp/asset-info.html b/zh-TW/spot/etp/asset-info.html index 696ae72f9e..bac2710e13 100644 --- a/zh-TW/spot/etp/asset-info.html +++ b/zh-TW/spot/etp/asset-info.html @@ -4,13 +4,13 @@ LT 全量資產基礎信息查詢 | Bybit API Documentation - +

    LT 全量資產基礎信息查詢

    信息

    這是個公共接口,無需鑒權。

    HTTP 請求

    GET /spot/v3/public/infos

    請求參數

    參數是否必須類型說明
    ltCodefalsestring想要查詢的LT資產名稱,從資產列表中獲取.

    返回參數

    參數類型說明
    listarrayObject
    > ltCodestringLT資產簡稱
    > ltNamestringLT資產全稱
    > maxPurchasestring單次最大申購金額
    > minPurchasestring單次最小申購金額
    > maxPurchaseDailystring單個自然日最大申購金額
    > maxRedeemstring單次最大贖回數量
    > minRedeemstring單次最小贖回數量
    > maxRedeemDailystring單個自然日最大贖回數量
    > purchaseFeeRatestring申購費率
    > redeemFeeRatestring贖回費率
    > statusstring目前LT資產是否可以進行申購和贖回
    > fundFeestring每天針對持有LT資產的用戶收取的資金費用
    > fundFeeTimenumber收取資金費用的時間
    > manageFeeRatestring管理費率
    > manageFeeTimenumber收取資金管理費的時間
    > valuestring平臺內部使用字段, 暫無實際意義, 可忽略
    > totalstring平臺申購總量上限
    > netValuestring當前淨值

    請求示例

    https://api-testnet.bybit.com/spot/v3/public/infos?ltCode=EOS2LUSDT

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "fundFee": "21.79800315",
    "fundFeeTime": 1673366400000,
    "ltCode": "EOS2LUSDT",
    "ltName": "Long EOS (2x Leverage)",
    "manageFeeRate": "0.00005",
    "manageFeeTime": 1673398800000,
    "maxPurchase": "5000",
    "maxPurchaseDaily": "200000",
    "maxRedeem": "861",
    "maxRedeemDaily": "20000",
    "minPurchase": "100",
    "minRedeem": "17",
    "netValue": "3.781571076822412032",
    "purchaseFeeRate": "0.0005",
    "redeemFeeRate": "0.0005",
    "status": "1",
    "total": "5000000",
    "value": "23624.848996419293002588635"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1673345413125
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/etp/market-info.html b/zh-TW/spot/etp/market-info.html index 77f0d493d9..ec977fd5f2 100644 --- a/zh-TW/spot/etp/market-info.html +++ b/zh-TW/spot/etp/market-info.html @@ -4,13 +4,13 @@ LT 行情查詢 | Bybit API Documentation - +

    LT 行情查詢

    HTTP 請求

    GET /spot/v3/private/reference

    請求參數

    參數是否必須類型說明
    ltCodetruestring想要查詢的LT資產名稱,從資產信息中獲取.

    返回參數

    參數類型說明
    basketstring名義持倉(總籃子 = 籃子頭寸*發行量)
    circulationstring在二級市場流通的代幣數量
    leveragestring真實槓桿倍數
    ltCodestringLT資產簡稱
    navstring淨值
    navTimenumber淨值更新時間戳UTC毫秒

    請求示例

    curl --location --request GET 'https://api.bybit.com/spot/v3/private/reference?ltCode=BTC3S' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662549197919' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "basket": "230666.700009559600667216",
    "circulation": "24999.840207851103706443",
    "leverage": "2.302545313639639446",
    "ltCode": "EOS2L",
    "nav": "3.790797803797135639",
    "navTime": 1673346095226
    },
    "retExtInfo": {},
    "time": 1673346095239
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/etp/order-history.html b/zh-TW/spot/etp/order-history.html index 51efef88eb..661b823db7 100644 --- a/zh-TW/spot/etp/order-history.html +++ b/zh-TW/spot/etp/order-history.html @@ -4,13 +4,13 @@ 申贖記錄查詢 | Bybit API Documentation - +

    申贖記錄查詢

    HTTP 請求

    GET /spot/v3/private/record

    請求參數

    參數是否必須類型說明
    ltCodefalsestring槓桿代幣代碼
    orderIdfalsestring訂單ID
    startTimefalseinteger起始時間戳(毫秒)
    endTimefalseinteger結束時間戳(毫秒)
    limitfalseinteger返回數量限制. [1, 500]. 默認: 100
    orderTypefalseinteger訂單類型 1. 申購 2. 贖回
    serialNofalsestring序列號

    返回參數

    參數類型說明
    amountstring實際成交的LT資產數量
    excTimenumber訂單狀態最後一次更新時間
    feestring交易手續費
    ltCodestringLT資產簡稱
    orderIdstring訂單ID
    orderStatusstring申購單狀態:1. 已完成 2. 等待中 3. 失敗
    orderTimenumber下單時間
    orderTypeinteger訂單類型 1. 申購 2. 贖回
    serialNostring序列號
    valuestring成交價值
    valueCoinstring計價幣種

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/record?ltCode=DOT3L&startTime=1662548400000&endTime=1662549840000' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662608374151' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "amount": "",
    "excTime": 1662549752000,
    "fee": "",
    "ltCode": "DOT3L",
    "orderId": "2083",
    "orderStatus": "3",
    "orderTime": 1662549752000,
    "orderType": 1,
    "serialNo": "x003",
    "value": "",
    "valueCoin": "USDT"
    },
    {
    "amount": "",
    "excTime": 1662549702000,
    "fee": "",
    "ltCode": "DOT3L",
    "orderId": "2082",
    "orderStatus": "3",
    "orderTime": 1662549702000,
    "orderType": 1,
    "serialNo": "x002",
    "value": "",
    "valueCoin": "USDT"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1662608374640
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/etp/purchase.html b/zh-TW/spot/etp/purchase.html index 36477fabae..85d5dbce4d 100644 --- a/zh-TW/spot/etp/purchase.html +++ b/zh-TW/spot/etp/purchase.html @@ -4,13 +4,13 @@ 申購 | Bybit API Documentation - +

    申購

    HTTP 請求

    POST /spot/v3/private/purchase

    請求參數

    參數是否必須類型說明
    ltCodetruestring想要查詢的LT資產名稱,從資產列表中獲取.
    ltAmounttruestring下單金額
    serialNofalsestring序列號. 自定義ID

    返回參數

    參數類型說明
    amountstring下單的LT資產金額
    idstring交易單號
    ltCodestringLT資產簡稱
    orderAmountstring實際成交金額
    orderQuantitystring實際成交的LT資產數量
    orderStatusstring申購單狀態:1. 已完成 2. 等待中 3. 失敗
    serialNostring序列號
    timestampnumber時間戳
    valueCoinstring計價幣種

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/purchase' \
    --header 'Content-Type: application/json' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662549845240' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --data-raw '{
    "ltCode": "DOT3LUSDT",
    "ltAmount": "100",
    "serialNo": "x005"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "amount": "100",
    "id": "2085",
    "ltCode": "DOT3LUSDT",
    "orderAmount": "",
    "orderQuantity": "",
    "orderStatus": "2",
    "serialNo": "x005",
    "timestamp": 1662549845373,
    "valueCoin": "USDT"
    },
    "retExtInfo": {},
    "time": 1662549845453
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/etp/redeem.html b/zh-TW/spot/etp/redeem.html index b84ef81579..009dfca25b 100644 --- a/zh-TW/spot/etp/redeem.html +++ b/zh-TW/spot/etp/redeem.html @@ -4,13 +4,13 @@ 贖回 | Bybit API Documentation - +

    贖回

    HTTP 請求

    POST /spot/v3/private/redeem

    請求參數

    參數是否必須類型說明
    ltCodetruestring想要查詢的LT資產名稱,從資產列表中獲取.
    ltQuantitytruestring贖回數量
    serialNofalsestring序列號, 自定義ID

    返回參數

    參數類型說明
    idstring交易單號
    ltCodestringLT資產簡稱
    orderAmountstring實際成交的金額. 一般返回""
    orderQuantitystring實際成交的LT資產數量
    orderStatusstring申購單狀態:1. 已完成 2. 等待中 3. 失敗
    quantitystring下單的LT資產數量. 一般返回""
    serialNostring序列號
    timestampnumber時間戳
    valueCoinstring計價幣種

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/redeem' \
    --header 'Content-Type: application/json' \
    --header 'X-BAPI-API-KEY: XXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1662605726010' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --data-raw '{
    "ltCode": "DOT3LUSDT",
    "ltQuantity": "50",
    "serialNo": "r001"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "2087",
    "ltCode": "DOT3LUSDT",
    "orderAmount": "",
    "orderQuantity": "50",
    "orderStatus": "2",
    "quantity": "",
    "serialNo": "r001",
    "timestamp": 1662605726326,
    "valueCoin": "DOT3L"
    },
    "retExtInfo": {},
    "time": 1662605727987
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/account.html b/zh-TW/spot/margin/account.html index 7d52f218d9..fa80cdc1e9 100644 --- a/zh-TW/spot/margin/account.html +++ b/zh-TW/spot/margin/account.html @@ -4,13 +4,13 @@ 查詢借貸帳戶信息 | Bybit API Documentation - +

    查詢借貸帳戶信息

    HTTP 請求

    GET /spot/v3/private/cross-margin-account

    請求參數

    返回參數

    參數類型說明
    acctBalanceSumstring總資產 (折算成BTC)
    debtBalanceSumstring總負債 (折算成BTC)
    loanAccountListarrayObject
    > freestring可用餘額
    > intereststring未還利息
    > loanstring未還本金
    > remainAmountstring總未還金額 = 未還利息 + 未還本金
    > lockedstring鎖定金額
    > tokenIdstring幣種
    > totalstring合計
    riskRatestring風險率
    statusinteger借貸帳戶狀態
    • 1: 正常
    • 2: 限制提幣/劃轉
    • 3: 預警
    • 4: 已爆倉
    switchStatusinteger全倉槓桿狀態 0: 關閉, 1: 開啟

    請求示例

    GET /spot/v3/private/cross-margin-account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751305868
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "acctBalanceSum": "0.455189592150138021",
    "debtBalanceSum": "0",
    "loanAccountList": [
    {
    "free": "0.01444",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "BTC",
    "total": "0.01444"
    },
    {
    "free": "0.21147048",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "ETH",
    "total": "0.21147048"
    },
    {
    "free": "7963.58978991849",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDT",
    "total": "7963.58978991849"
    },
    {
    "free": "1380.28832",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDC",
    "total": "1380.28832"
    }
    ],
    "riskRate": "0",
    "status": 1,
    "switchStatus": 1
    },
    "retExtInfo": {},
    "time": 1677751306287
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/borrow-history.html b/zh-TW/spot/margin/borrow-history.html index f7f11dc9ba..6e049d22be 100644 --- a/zh-TW/spot/margin/borrow-history.html +++ b/zh-TW/spot/margin/borrow-history.html @@ -4,13 +4,13 @@ 查詢借貸訂單 | Bybit API Documentation - +

    查詢借貸訂單

    HTTP 請求

    GET /spot/v3/private/cross-margin-orders

    請求參數

    參數是否必需類型說明
    startTimefalselong開始時間戳 (毫秒)
    endTimefalselong結束時間戳 (毫秒)
    coinfalsestring幣種名稱
    statusfalseinteger訂單狀態
    • 0(默認):查詢所有狀態
    • 1:查詢未還清
    • 2:查詢已還清
    limitfalseinteger每頁數量限制. [1, 500]. 默認: 500

    返回參數

    參數類型說明
    listarrayObject
    > accountIdstring帳戶ID
    > coinstring幣種名稱
    > createdTimenumber借貸訂單創建時間戳 (毫秒)
    > idstring借貸交易ID
    > interestAmountstring總利息
    > interestBalancestring未還利息
    > loanAmountstring借貸金額
    > loanBalancestring未還本金
    > remainAmountstring未還金額總和=未還利息+未還本金
    > statusinteger訂單狀態 1:未還清, 2:已還清
    > typeinteger訂單類型 1: 手動借貸, 2: 自動借貸

    請求示例

    GET /spot/v3/private/cross-margin-orders?coin=ETH&limit=1&status=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677754328650
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "accountId": "592335",
    "coin": "ETH",
    "createdTime": 1677751839000,
    "id": "21005",
    "interestAmount": "0.0001",
    "interestBalance": "0",
    "loanAmount": "10",
    "loanBalance": "0",
    "remainAmount": "0",
    "status": 2,
    "type": 1
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677754329096
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/borrow.html b/zh-TW/spot/margin/borrow.html index f638f609a8..84ba240818 100644 --- a/zh-TW/spot/margin/borrow.html +++ b/zh-TW/spot/margin/borrow.html @@ -4,13 +4,13 @@ 借款 | Bybit API Documentation - +

    借款

    HTTP 請求

    POST /spot/v3/private/cross-margin-loan

    請求參數

    參數是否必需類型說明
    cointruestring幣種
    qtytruestring借幣數量

    返回參數

    參數類型說明
    transactIdstring借款交易ID

    請求示例

    POST /spot/v3/private/cross-margin-loan HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751838628
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 38

    {
    "coin": "ETH",
    "qty": "10"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transactId": "21005"
    },
    "retExtInfo": {},
    "time": 1677751839688
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/borrowable-coin.html b/zh-TW/spot/margin/borrowable-coin.html index 54586ebf1b..f08da11595 100644 --- a/zh-TW/spot/margin/borrowable-coin.html +++ b/zh-TW/spot/margin/borrowable-coin.html @@ -4,13 +4,13 @@ 查詢可借幣種精度 | Bybit API Documentation - +

    查詢可借幣種精度

    信息

    這是個公告接口,不需要鑒權

    HTTP 請求

    GET /spot/v3/public/cross-margin-borrow-data

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > borrowingPrecisioninteger借款精度
    > repaymentPrecisioninteger還款精度

    請求示例

    GET /spot/v3/public/cross-margin-borrow-data?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750684772
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "borrowingPrecision": 5,
    "coin": "ETH",
    "repaymentPrecision": 4
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750685331
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/interest.html b/zh-TW/spot/margin/interest.html index 563ad7beae..e0b94147a2 100644 --- a/zh-TW/spot/margin/interest.html +++ b/zh-TW/spot/margin/interest.html @@ -4,13 +4,13 @@ 查詢利率及額度 | Bybit API Documentation - +

    查詢利率及額度

    HTTP 請求

    GET /spot/v3/private/cross-margin-loan-info

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱

    返回參數

    參數類型說明
    coinstring幣種名稱
    interestRatestring基礎日利率
    loanAbleAmountstring預估可借最大金額
    maxLoanAmountstring平台設置的用戶最大可借金額

    請求示例

    GET /spot/v3/private/cross-margin-loan-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750928871
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "ETH",
    "interestRate": "0.000054835",
    "loanAbleAmount": "19.220442066850037795",
    "maxLoanAmount": "300"
    },
    "retExtInfo": {},
    "time": 1677750929290
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/margin-data.html b/zh-TW/spot/margin/margin-data.html index 7f88ad92ca..c27c1b5567 100644 --- a/zh-TW/spot/margin/margin-data.html +++ b/zh-TW/spot/margin/margin-data.html @@ -4,13 +4,13 @@ 查詢保證金幣種信息 | Bybit API Documentation - +

    查詢保證金幣種信息

    信息

    這是個公共接口,不需要鑒權

    HTTP 請求

    GET /spot/v3/public/cross-margin-bond-data

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > conversionRatestring折算率, 返回為實際數值
    > liquidationOrderinteger強平順序

    請求示例

    GET /spot/v3/public/cross-margin-bond-data?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750396890
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "coin": "ETH",
    "conversionRate": "0.95",
    "liquidationOrder": 2
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750397414
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/repay-history.html b/zh-TW/spot/margin/repay-history.html index 91077bd8ca..779c2888e5 100644 --- a/zh-TW/spot/margin/repay-history.html +++ b/zh-TW/spot/margin/repay-history.html @@ -4,13 +4,13 @@ 查詢還款訂單信息 | Bybit API Documentation - +

    查詢還款訂單信息

    HTTP 請求

    GET /spot/v3/private/cross-margin-repay-history

    請求參數

    參數是否必需類型說明
    startTimefalselong開始時間戳 (毫秒)
    endTimefalselong結束時間戳 (毫秒)
    coinfalsestring幣種信息
    limitfalseinteger每頁數量限制. [1, 500], 默認: 500

    返回參數

    參數類型說明
    listarrayObject
    > accountIdstring帳戶ID
    > coinstring幣種信息
    > repaidAmountstring還款金額
    > repayIdstring還款交易ID
    > repayMarginOrderIdstring還款單號
    > repayTimestring還款交易時間戳 (毫秒)
    > transactIdsarrayObject
    >> repaidIntereststring該筆還款訂單的利息還款金額
    >> repaidPrincipalstring該筆還款訂單的本金還款金額
    >> repaidSerialNumberstring借貸訂單的還款單號
    >> transactIdstring原始借貸交易ID

    請求示例

    GET /spot/v3/private/cross-margin-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

    響應示例

    {
    "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
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/repay.html b/zh-TW/spot/margin/repay.html index 543ed42a6a..3b3e46232a 100644 --- a/zh-TW/spot/margin/repay.html +++ b/zh-TW/spot/margin/repay.html @@ -4,13 +4,13 @@ 還款 | Bybit API Documentation - +

    還款

    HTTP 請求

    POST /spot/v3/private/cross-margin-repay

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱
    qtyfalsestring還款金額
    • completeRepayment=0時, qty必傳
    • completeRepayment=1時, qty無效
    completeRepaymentfalseinteger是否一鍵全部還款. 0(默認): 否, 1: 是

    返回參數

    參數類型說明
    repayIdstring還款交易ID

    請求示例

    POST /spot/v3/private/cross-margin-repay HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751944347
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 66

    {
    "coin": "ETH",
    "qty": null,
    "completeRepayment": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "repayId": "19070"
    },
    "retExtInfo": {},
    "time": 1677751941219
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/margin/toggle.html b/zh-TW/spot/margin/toggle.html index 73f6ce7e2a..dfbf3fe954 100644 --- a/zh-TW/spot/margin/toggle.html +++ b/zh-TW/spot/margin/toggle.html @@ -4,13 +4,13 @@ 全倉槓桿開關 | Bybit API Documentation - +

    全倉槓桿開關

    開啟或關閉全倉槓桿交易

    HTTP 請求

    POST /spot/v3/private/cross-margin-switch

    請求參數

    參數是否必需類型說明
    switchtrueinteger1: 開啟, 0: 關閉

    響應參數

    參數類型說明
    switchStatusinteger槓桿交易狀態. 1: 開啟, 0: 關閉

    請求示例

    POST /spot/v3/private/cross-margin-switch HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677747804512
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 19

    {
    "switch": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "switchStatus": 0
    },
    "retExtInfo": {},
    "time": 1677747804974
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/otc/coin-info.html b/zh-TW/spot/otc/coin-info.html index 5781acf8f1..0685e98f24 100644 --- a/zh-TW/spot/otc/coin-info.html +++ b/zh-TW/spot/otc/coin-info.html @@ -4,13 +4,13 @@ 查詢保證金幣種信息 | Bybit API Documentation - +

    查詢保證金幣種信息

    提示

    這是公共接口,無需鑒權。

    HTTP 請求

    GET /spot/v3/public/margin-ensure-tokens

    請求參數

    參數是否必須類型說明
    productIdfalsestring產品ID. 若不傳,則返回所有產品的保證金幣種信息. 現貨返回折算率大於0的幣種.

    返回參數

    參數類型說明
    marginTokenarrayObject
    > productIdstring產品ID
    > spotTokenarray現貨保證金幣種信息
    >> tokenstring保證金幣種
    >> convertRatiostring保證金幣種折算率
    > contractTokenarray合約保證金幣種信息
    >> tokenstring保證金幣種
    >> convertRatiostring保證金幣種折算率

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/public/margin-ensure-tokens?productId=70'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginToken": [
    {
    "productId": "70",
    "spotToken": [
    {
    "token": "BTC",
    "convertRatio": "1.00000000"
    },
    {
    "token": "ETH",
    "convertRatio": "1.00000000"
    },
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ],
    "contractToken": [
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669363954802
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/otc/loan-info.html b/zh-TW/spot/otc/loan-info.html index fe5e0848e5..d334959dde 100644 --- a/zh-TW/spot/otc/loan-info.html +++ b/zh-TW/spot/otc/loan-info.html @@ -4,13 +4,13 @@ 查詢借貸訂單信息 | Bybit API Documentation - +

    查詢借貸訂單信息

    查詢借貸訂單的詳情

    HTTP 請求

    GET /spot/v3/private/margin-loan-infos

    請求參數

    參數是否必須類型說明
    orderIdfalsestring借貸訂單ID. 若不傳,則返回全部. 按照loanTime降序排列
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger返回數量限制. [1, 100], 默認: 10

    返回參數

    參數類型說明
    loanInfoarrayObject
    > orderIdstring借貸訂單ID
    > orderProductIdstring產品ID
    > parentUidstring用戶母帳號ID
    > loanTimestring放款時間(毫秒)
    > loanCoinstring借款幣種
    > loanAmountstring借款金額
    > unpaidAmountstring未還本金
    > unpaidIntereststring未還利息
    > repaidAmountstring已還本金
    > repaidIntereststring已還利息
    > interestRatestring日利率
    > statusinteger1:未還清; 2:已還清
    > leveragestring槓桿倍數
    > supportSpotinteger是否支持現貨. 0:否; 1:是
    > supportContractinteger是否支持合約 . 0: 否; 1: 是
    > withdrawLinestring限制提幣線
    > transferLinestring限制劃轉線
    > spotBuyLinestring限制現貨買入線
    > spotSellLinestring限制現貨賣出線
    > contractOpenLinestring限制合約開倉線
    > liquidationLinestring強平線
    > stopLiquidationLinestring停止強平線
    > contractLeveragestring允許合約開倉倍數
    > transferRatiostring借貸資金劃轉比例
    > spotSymbolsarray現貨交易對白名單
    > contractSymbolsarray合約交易對白名單

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-loan-infos' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669364798602' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXXX'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "loanInfo": [
    {
    "orderId": "1244781478207029504",
    "orderProductId": "34",
    "parentUid": "999805",
    "loanTime": "1663126149000",
    "loanCoin": "USDT",
    "loanAmount": "500000",
    "unpaidAmount": "6351.49614274",
    "unpaidInterest": "264.0137162",
    "repaidAmount": "493648.50385726",
    "repaidInterest": "0",
    "interestRate": "0.00027397",
    "status": 1,
    "leverage": "20",
    "supportSpot": 1,
    "supportContract": 1,
    "withdrawLine": "0.5",
    "transferLine": "0.6",
    "spotBuyLine": "0.7",
    "spotSellLine": "0.8",
    "contractOpenLine": "0.9",
    "liquidationLine": "0.95",
    "stopLiquidationLine": "0.20000000",
    "contractLeverage": "3",
    "transferRatio": "0.1",
    "spotSymbols": [
    "DYDXQQTEST001",
    "DYDXNEO",
    "PMTEST16USDT"
    ],
    "contractSymbols": [
    "RAYUSDT",
    "API3USDT",
    "SUSHIUSDT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669364798924
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/otc/ltv.html b/zh-TW/spot/otc/ltv.html index 3b32d25226..78f8ef9dcf 100644 --- a/zh-TW/spot/otc/ltv.html +++ b/zh-TW/spot/otc/ltv.html @@ -4,13 +4,13 @@ 查詢風險率 | Bybit API Documentation - +

    查詢風險率

    若該接口返回空數據,請前往該接口查詢LTV

    HTTP 請求

    GET /spot/v3/private/margin-ltv

    請求參數

    返回參數

    參數類型說明
    ltvInfoarrayObject
    > ltvstring風險率
    > parentUidstring用戶ID
    > subAccountUidsarray綁定的子UID
    > unpaidAmountstring總負債 (USDT)
    > unpaidInfoarray負債明細
    >> tokenstring幣種
    >> unpaidQtystring未還本金
    >> unpaidIntereststring未還利息
    > balancestring總資產(保證金幣種資產折算為USDT資產). 可以參考這裡了解詳細計算
    > spotBalanceInfoarray現貨資產明細
    >> tokenstring現貨保證金幣種
    >> pricestring現貨保證金幣種價格
    >> qtystring現貨保證金數量
    > contractInfoarray合約資產明細
    >> tokenstring合約保證金幣種
    >> pricestring合約保證金幣種指數價格
    >> qtystring合約保證金幣種數量 (合約可用餘額,不參與LTV計算)

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-ltv' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669367335035' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXXXXX'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.1147",
    "parentUid": "999805",
    "subAccountUids": [
    "999805"
    ],
    "unpaidAmount": "",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "6351.49614274",
    "unpaidInterest": "264.0137162"
    }
    ],
    "balance": "57626.875915433333333332400000000",
    "spotBalanceInfo": [
    {
    "token": "BTC",
    "price": "16375.621333333333333332",
    "qty": "0.2"
    },
    ....
    {
    "token": "XRP",
    "price": "0.409517",
    "qty": "10000"
    }
    ],
    "contractInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669367335608
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/otc/product-info.html b/zh-TW/spot/otc/product-info.html index 2c1f24fe5a..2e0a63af4e 100644 --- a/zh-TW/spot/otc/product-info.html +++ b/zh-TW/spot/otc/product-info.html @@ -4,13 +4,13 @@ 查詢保證金產品信息 | Bybit API Documentation - +

    查詢保證金產品信息

    提示

    這是公共接口,無需鑒權。

    HTTP 請求

    GET /spot/v3/public/margin-product-infos

    請求參數

    參數是否必須類型說明
    productIdfalsestring產品ID. 若不傳,則返回所有產品數據

    返回參數

    參數類型說明
    marginProductInfoarrayObject
    > productIdstring產品ID
    > leveragestring槓桿倍數
    > supportSpotinteger是否支持現貨. 0:否; 1:是
    > supportContractinteger是否支持合約 . 0: 否; 1: 是
    > withdrawLinestring限制提幣線
    > transferLinestring限制劃轉線
    > spotBuyLinestring限制現貨買入線
    > spotSellLinestring限制現貨賣出線
    > contractOpenLinestring限制合約開倉線
    > liquidationLinestring強平線
    > stopLiquidationLinestring停止強平線
    > contractLeveragestring允許合約開倉倍數
    > transferRatiostring借貸資金劃轉比例
    > spotSymbolsarray現貨交易對白名單
    > contractSymbolsarray合約交易對白名單

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/margin-product-infos?productId=70'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginProductInfo": [
    {
    "productId": "70",
    "leverage": "5.00000000",
    "supportSpot": 1,
    "supportContract": 1,
    "withdrawLine": "0.5",
    "transferLine": "0.6",
    "spotBuyLine": "0.7",
    "spotSellLine": "0.8",
    "contractOpenLine": "0.9",
    "liquidationLine": "0.95",
    "stopLiquidationLine": "0.40000000",
    "contractLeverage": "",
    "transferRatio": "",
    "spotSymbols": [
    "DYDXQQTEST001"
    ],
    "contractSymbols": [
    "RAYUSDT",
    "API3USDT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669362961705
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/otc/repay-info.html b/zh-TW/spot/otc/repay-info.html index ee3b2fa0d3..7d7e6b9d5b 100644 --- a/zh-TW/spot/otc/repay-info.html +++ b/zh-TW/spot/otc/repay-info.html @@ -4,13 +4,13 @@ 查詢還款信息 | Bybit API Documentation - +

    查詢還款信息

    HTTP 請求

    GET /spot/v3/private/margin-repaid-infos

    請求參數

    參數是否必須類型說明
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger返回數量限制. [1, 100]. 默認: 100

    返回參數

    參數類型說明
    repayInfoarrayObject
    > repayOrderIdstring還款訂單號
    > repaidTimestring還款時間(毫秒)
    > tokenstring還款幣種
    > quantitystring還款本金
    > intereststring還款利息
    > businessTypestring還款類型. 1:正常還款; 2:系統強平還款
    > statusstring1:未還清; 2:已還清

    Request Example

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-repaid-infos?startTime=1663126392000&endTime=1663126394000' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669366647851' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXXX'

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "repayInfo": [
    {
    "repayOrderId": "8189",
    "repaidTime": "1663126393000",
    "token": "USDT",
    "quantity": "30000",
    "interest": "0",
    "businessType": "1",
    "status": "1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669366648366
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/bid-ask.html b/zh-TW/spot/public/bid-ask.html index 96f1f81cec..989d7b1ba0 100644 --- a/zh-TW/spot/public/bid-ask.html +++ b/zh-TW/spot/public/bid-ask.html @@ -4,13 +4,13 @@ 最佳買賣價 | Bybit API Documentation - +

    最佳買賣價

    信息

    如果symbol沒有被發送,所有symbol的最佳訂單簿價格都會被返回。

    HTTP 請求

    GET /spot/v3/public/quote/ticker/bookTicker

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱

    返回參數

    參數類型說明
    symbolstring幣對名稱
    bidPricestring最佳買價
    bidQtystring最佳買價數量
    askPricestring最佳賣價
    askQtystring最佳賣價數量
    timenumber毫秒時間戳

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/bookTicker?symbol=BTCUSDT'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "bidPrice": "21170.14",
    "bidQty": "0.908276",
    "askPrice": "21250",
    "askQty": "0.009264",
    "time": 1659431461695
    },
    "retExtInfo": {},
    "time": 1659431462103
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/depth.html b/zh-TW/spot/public/depth.html index d2e5f0c595..c0f06fa431 100644 --- a/zh-TW/spot/public/depth.html +++ b/zh-TW/spot/public/depth.html @@ -4,13 +4,13 @@ 訂單簿 | Bybit API Documentation - +

    訂單簿

    HTTP 請求

    GET /spot/v3/public/quote/depth

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱
    limitfalseinteger返回數量限制。[1, 200], 默認為100

    返回參數

    參數類型說明
    timenumber當前時間
    bidsarraybid的價格和數量信息,最優bid價格由上到下排列
    asksarrayask的價格和數量信息,最優ask價格由上到下排列

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/depth?symbol=BTCUSDT&limit=1'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "time": 1659429083820,
    "bids": [
    [
    "21170.14",
    "0.050096"
    ]
    ],
    "asks": [
    [
    "21250",
    "0.00211"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1659429083979
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/instrument.html b/zh-TW/spot/public/instrument.html index e2e16d9e92..796edb3e9f 100644 --- a/zh-TW/spot/public/instrument.html +++ b/zh-TW/spot/public/instrument.html @@ -4,13 +4,13 @@ 查詢所有交易對 | Bybit API Documentation - +

    查詢所有交易對

    獲取所有交易對

    HTTP 請求

    GET /spot/v3/public/symbols

    請求參數

    返回參數

    參數類型說明
    listarrayObject
    > namestring幣對名稱
    > aliasstring幣對別名
    > baseCoinstringbase幣種
    > quoteCoinstringquote幣種
    > basePrecisionstringbase幣種精度
    > quotePrecisionstringquote幣種精度
    > minTradeQtystring最小訂單數量 (對市價買單無效)
    > minTradeAmtstring最小訂單額 (只對市價買單有效)
    > minPricePrecisionstring最小價格精度
    > maxTradeQtystring最大成交量(當您下訂單類型為 LIMIT_MAKER 時將被忽略)
    > maxTradeAmtstring最大成交額(當您下訂單類型為 LIMIT_MAKER 時將被忽略)
    > categorystringsymbol 所在分區:1主類別
    > innovationstring1 表示創新區:這個幣種價格波動比較大
    > showStatusstring1 表示該現貨開放交易

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/symbols'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "name": "BTCUSDT",
    "alias": "BTCUSDT",
    "baseCoin": "BTC",
    "quoteCoin": "USDT",
    "basePrecision": "0.000001",
    "quotePrecision": "0.00000001",
    "minTradeQty": "0.000001",
    "minTradeAmt": "10",
    "maxTradeQty": "63.01197227",
    "maxTradeAmt": "1000000",
    "minPricePrecision": "0.01",
    "category": "1",
    "showStatus": "1",
    "innovation": "0"
    },
    {
    "name": "ETHUSDT",
    "alias": "ETHUSDT",
    "baseCoin": "ETH",
    "quoteCoin": "USDT",
    "basePrecision": "0.00001",
    "quotePrecision": "0.0000001",
    "minTradeQty": "0.00224",
    "minTradeAmt": "10",
    "maxTradeQty": "100000000",
    "maxTradeAmt": "100000000",
    "minPricePrecision": "0.01",
    "category": "1",
    "showStatus": "1",
    "innovation": "0"
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659067662931
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/kline.html b/zh-TW/spot/public/kline.html index 88417cd799..12d50bcd31 100644 --- a/zh-TW/spot/public/kline.html +++ b/zh-TW/spot/public/kline.html @@ -4,13 +4,13 @@ 查詢K線數據 | Bybit API Documentation - +

    查詢K線數據

    信息

    返回指定的時間間隔最近1000根的K線結果

    信息

    如果startTime和endTime沒有發送,只有最新的K線會被返回

    HTTP 請求

    GET /spot/v3/public/quote/kline

    請求參數

    參數是否必須類型
    symboltruestring幣對名稱
    intervaltruestringK線圖區間。可識別發送的值為:1m, 5m, 15m, 30m, 1h, 1d, 1w, 1M (m=分鐘, h=小時, d=天, w=星期, M=月)
    limitfalseinteger返回數量限制. [1, 1000]. 默認: 1000
    startTimefalseinteger第一條返回的時間戳(毫秒)
    endTimefalseinteger最後一條返回的時間戳(毫秒)

    返回參數

    參數類型說明
    listarrayObject
    > tnumber時間戳(毫秒)
    > sstring幣對名稱
    > snstring幣對別名
    > cstring收盤價
    > hstring最高價
    > lstring最低價
    > ostring開盤價
    > vstring交易金額

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/kline?symbol=BTCUSDT&interval=1m&limit=1'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "t": 1659430380000,
    "s": "BTCUSDT",
    "sn": "BTCUSDT",
    "c": "21170.14",
    "h": "21170.14",
    "l": "21127.86",
    "o": "21127.86",
    "v": "0.907276"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659430400353
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/last-price.html b/zh-TW/spot/public/last-price.html index 947b311cbc..22f95c0b32 100644 --- a/zh-TW/spot/public/last-price.html +++ b/zh-TW/spot/public/last-price.html @@ -4,13 +4,13 @@ Symbol最新價 | Bybit API Documentation - +

    Symbol最新價

    信息

    如果symbol沒有被發送,所有symbol的價格都會被返回

    HTTP 請求

    GET /spot/v3/public/quote/ticker/price

    請求參數

    參數是否必須類型說明
    symbolfalsestring幣對名稱

    返回參數

    參數類型說明
    symbolstring幣對名稱
    pricestring訂單價格,對於LIMIT 訂單必需發送

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/price?symbol=BTCUSDT'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "price": "21127.86"
    },
    "retExtInfo": {},
    "time": 1659431315936
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/merge-depth.html b/zh-TW/spot/public/merge-depth.html index a90e7fae56..cac46ed949 100644 --- a/zh-TW/spot/public/merge-depth.html +++ b/zh-TW/spot/public/merge-depth.html @@ -4,13 +4,13 @@ 合並訂單簿 | Bybit API Documentation - +

    合並訂單簿

    HTTP 請求

    GET /spot/v3/public/quote/depth/merged

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱
    scalefalseinteger合並深度的精度,1代表1位小數
    limitfalseinteger返回數量限制。[1, 200], 默認為100

    返回參數

    參數類型說明
    timenumber當前時間
    bidsarraybid的價格和數量信息,最優bid價格由上到下排列
    asksarrayask的價格和數量信息,最優ask價格由上到下排列

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/depth/merged?symbol=BTCUSDT&scale=1&limit=1'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "time": 1659429646349,
    "bids": [
    [
    "21170.1",
    "0.049096"
    ]
    ],
    "asks": [
    [
    "21250",
    "0.00211"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1659429646652
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/recent-trade.html b/zh-TW/spot/public/recent-trade.html index d2021f8830..288eff9465 100644 --- a/zh-TW/spot/public/recent-trade.html +++ b/zh-TW/spot/public/recent-trade.html @@ -4,13 +4,13 @@ 平臺交易歷史數據 | Bybit API Documentation - +

    平臺交易歷史數據

    HTTP 請求

    GET /spot/v3/public/quote/trades

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱
    limitfalseinteger返回數量限制. [1, 60]. 默認: 60

    返回參數

    參數類型說明
    listarrayObject
    > pricestring價格
    > timenumber當前Unix時間戳(毫秒)
    > qtystring交易數量
    > isBuyerMakerinteger0:賣單或者taker單, 1:買方maker單
    > typestring0:普通交易, 1:Paradigm 大宗交易

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/trades?symbol=BTCUSDT&limit=1'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "price": "21170.14",
    "time": 1659429793926,
    "qty": "0.907276",
    "isBuyerMaker": 0,
    "type": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659429835311
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/public/tickers.html b/zh-TW/spot/public/tickers.html index ac747e5aeb..2966b5c107 100644 --- a/zh-TW/spot/public/tickers.html +++ b/zh-TW/spot/public/tickers.html @@ -4,13 +4,13 @@ 最新信息 | Bybit API Documentation - +

    最新信息

    HTTP 請求

    GET /spot/v3/public/quote/ticker/24hr

    信息

    如果symbol不傳遞,所有symbol的數據都會被返回

    請求參數

    參數是否必須類型說明
    symbolfalsestring幣對名稱

    返回參數

    參數類型說明
    tnumber當前Unix時間戳 (毫秒)
    sstring幣對名稱
    lpstring最新成交價
    hstring最高價
    lstring最低價
    ostring開盤價
    bpstring最佳買價
    apstring最佳賣價
    vstring成交量
    qvstring成交金額

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/public/quote/ticker/24hr?symbol=BTCUSDT'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "t": 1659430933736,
    "s": "BTCUSDT",
    "lp": "21127.86",
    "h": "22000",
    "l": "19779.14",
    "o": "19935.19",
    "bp": "21170.14",
    "ap": "21250",
    "v": "211.378621",
    "qv": "4460854.96730398"
    },
    "retExtInfo": {},
    "time": 1659430975794
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/rate-limit.html b/zh-TW/spot/rate-limit.html index 2b54aa0683..e20575f620 100644 --- a/zh-TW/spot/rate-limit.html +++ b/zh-TW/spot/rate-limit.html @@ -4,14 +4,14 @@ 頻率限制 | Bybit API Documentation - +

    頻率限制

    IP限頻

    警告

    如果您收到HTTP 403(拒絕訪問)響應, 您的 IP 已被暫時或永久禁止。 您應立即查看以下指南,以確保您的應用程序不會繼續違反限制。如果您在 30 分鐘後 仍被禁止,則您可能會被永久禁止。

    我們不建議您在這些限制的邊緣運行您的應用程序,以防異常的網絡活動導致意外違規。

    • GET/POST 請求 (共享):
      • 連續 5 秒內每秒不超過 120 個請求
    備註

    所有到api.bybit.comapi.bytick.com的流量共享此限制,無論是訪問現貨、期貨還是期權。

    違反限制後,您的 IP 將被禁止一段時間(通常為 30 分鐘)。 持續違反限制將導致永久禁止。 我們不能撤銷永久禁令或縮短臨時禁令。

    賬戶頻率限製

    警告

    如果您收到這樣的響應"ret_msg": "Too many visits!", 則表示您觸發了帳戶頻率限制, 請等到頻率限制重置以後, 再繼續發送請求。

    Bybit基於每秒鍾的滾動時間窗口來做頻率限製,並且是按賬戶(uid)來做劃分限製,每次請求API響應頭(response header)中都會包含如下字段:

    • X-Bapi-Limit-Status - 該接口當前時間窗口剩余可用請求數
    • X-Bapi-Limit - 該接口當前頻率限製上限
    • X-Bapi-Limit-Reset-Timestamp - 如果您已超過該接口當前窗口頻率限製,該字段表示下個可用時間窗口的時間戳(毫秒),即什麽時候可以恢復訪問;如果您未超過該接口當前窗口頻率限製,該字段表示返回的是當前服務器時間(毫秒).

    Http 響應頭示例

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    接口頻率限制表

    路徑頻率
    全倉槓桿5 req/s
    所有其他私有接口20 req/s

    如何提高頻率限製

    請發送郵件到 api@bybit.com,我們會在 1-4 個工作日內答復。郵件內容必須包含以下內容:

    1. 您的姓名和公司名稱和簡介
    2. 您的bybit 賬號uid或註冊郵箱手機號,以及您要申請提頻的交易對
    3. 您上個月的交易量(吃單/掛單)並提供截圖
    4. 簡單介紹您的交易策略和為什麽需要更高限頻
    5. 如果可以,請提供您的成交記錄csv文檔
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/batch-cancel.html b/zh-TW/spot/trade/batch-cancel.html index 819e3b64f4..e1c508543a 100644 --- a/zh-TW/spot/trade/batch-cancel.html +++ b/zh-TW/spot/trade/batch-cancel.html @@ -4,13 +4,13 @@ 批量撤銷訂單 | Bybit API Documentation - +

    批量撤銷訂單

    HTTP 請求

    POST /spot/v3/private/cancel-orders

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱
    sidefalsestring買賣方向. Buy, Sell
    orderTypesfalsestring訂單類型. 默認為LIMIT. 支持多個訂單類型取消, 用英文逗號分開, 例如:LIMIT,LIMIT_MAKER.
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    successstring是否成功. 0:失敗, 1:成功

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-orders' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659078150737' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderTypes": "LIMIT,LIMIT_MAKER"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "success": "1"
    },
    "retExtInfo": {},
    "time": 1659080154042
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/cancel-by-id.html b/zh-TW/spot/trade/cancel-by-id.html index 08675063a4..91fa834eac 100644 --- a/zh-TW/spot/trade/cancel-by-id.html +++ b/zh-TW/spot/trade/cancel-by-id.html @@ -4,13 +4,13 @@ 根據訂單號批量撤銷訂單 | Bybit API Documentation - +

    根據訂單號批量撤銷訂單

    HTTP 請求

    POST /spot/v3/private/cancel-orders-by-ids

    請求參數

    參數是否必須類型說明
    orderIdstruestring訂單號, 可用英文逗號拼接表示多個訂單, 不超過100個。
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    listarrayObject. 若全部成功,則返回空數組[]
    > orderIdstring訂單ID
    > codestring錯誤碼

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-orders-by-ids' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659080877551' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "orderIds": "1210851823244553984,1210852013162639104"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": []
    },
    "retExtInfo": {},
    "time": 1659080815222
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/cancel.html b/zh-TW/spot/trade/cancel.html index f76c65eb28..2104ae2c68 100644 --- a/zh-TW/spot/trade/cancel.html +++ b/zh-TW/spot/trade/cancel.html @@ -4,13 +4,13 @@ 撤銷活動委托單 | Bybit API Documentation - +

    撤銷活動委托單

    HTTP 請求

    POST /spot/v3/private/cancel-order

    請求參數

    參數是否必須類型說明
    orderIdfalsestring訂單ID. 當orderLinkId為空時, 則必傳
    orderLinkIdfalsestring用戶自定義ID. 當orderId為空時, 則必傳
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring自定義訂單ID,用戶自己生成
    symbolstring幣對名稱
    statusstring訂單狀態
    accountIdstring賬戶ID
    orderPricestring訂單價格
    createTimestring訂單創建時間
    orderQtystring訂單數量
    execQtystring成交數量
    timeInForcestring執行策略
    orderTypestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    sidestring買賣方向. BUY:買入, SELL:賣出.

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/cancel-order' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659078017415' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "orderId": "1210810256551063296",
    "orderLinkId": null
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1210810256551063296",
    "orderLinkId": "spotA0010",
    "symbol": "BTCUSDT",
    "status": "NEW",
    "accountId": "533287",
    "createTime": "1659075830464",
    "orderPrice": "23500",
    "orderQty": "0.01",
    "execQty": "0",
    "timeInForce": "GTC",
    "orderType": "LIMIT",
    "side": "SELL"
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659078151226
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/get-order.html b/zh-TW/spot/trade/get-order.html index 871cb3b0f9..242529f6e8 100644 --- a/zh-TW/spot/trade/get-order.html +++ b/zh-TW/spot/trade/get-order.html @@ -4,13 +4,13 @@ 查詢活動委托 | Bybit API Documentation - +

    查詢活動委托

    HTTP 請求

    GET /spot/v3/private/order

    請求參數

    參數是否必須類型說明
    orderIdfalsestring訂單ID. 當orderLinkId為空時, 則必傳
    orderLinkIdfalsestring用戶自定義ID. 當orderId為空時, 則必傳
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    accountIdstring賬戶ID
    symbolstring幣對名稱
    orderLinkIdstring特殊訂單ID,用戶自己生成
    orderIdstring訂單ID
    orderPricestring訂單價格
    orderQtystring訂單數量
    execQtystring成交數量
    cummulativeQuoteQtystring鎖定數量(如果為0,則說明該筆訂單的資金已完成結算)
    avgPricestring訂單已成交的平均價格
    statusstring訂單狀態。可能出現的值為:NEW(新訂單,無成交)、PARTIALLY_FILLED(部分成交)、FILLED(全部成交)、CANCELED(已取消)和REJECTED(訂單被拒絕).
    timeInForcestring執行策略
    orderTypestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    sidestring訂單方向, BUY(買入做多)/SELL(賣出做空)
    stopPricestring停止價
    icebergQtystring請忽略
    createTimestring撮合引擎中的創建時間
    updateTimestring訂單上次更新的時間戳
    isWorkingstring是否生效. 0:未生效, 1:已生效
    lockedstring鎖定數量(如果為0,則說明該筆訂單的資金已完成結算)
    blockTradeIdstringParadigm大宗交易ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP執行類型
    smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    smpOrderIdstring觸發此SMP執行的交易對手的 orderID

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/order?orderLinkId=spotA0010' \
    --header 'X-BAPI-SIGN: 828571067751622ed4191e7e8ee913defccd1f099b9dfb8332a6a05edf799eaf' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659076396894' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotA0010",
    "orderId": "1210810256551063296",
    "orderPrice": "23500",
    "orderQty": "0.01",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "NEW",
    "timeInForce": "GTC",
    "orderType": "LIMIT",
    "side": "SELL",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": "1659075830464",
    "updateTime": "1659075830497",
    "isWorking": "1",
    "locked": "0.01",
    "blockTradeId": "",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659076397365
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/my-trades.html b/zh-TW/spot/trade/my-trades.html index 0b964969fc..f0a90e8e59 100644 --- a/zh-TW/spot/trade/my-trades.html +++ b/zh-TW/spot/trade/my-trades.html @@ -4,14 +4,14 @@ 交易記錄 | Bybit API Documentation - +

    交易記錄

    信息
    • 如果不傳startTime,只能查詢最近7天的交易數據。如果要查詢一周之前的歷史交易數據,需要傳startTime
    • 僅當不傳入orderId, 不傳入toTicketId,但傳入fromTicketId時,返回的結果是以ticketId從小 到大排序;否則,返回的結果以ticketId從大到小排序
    • 支持查询过去180天的记录
    提示

    fromTradeIdtoTradeId的規則:

    • orderId不傳時
    1. 僅fromTradeId傳入, fromTradeId不會被包含在響應中
    2. 僅toTradeId傳入, toTradeId不會被包含在響應中
    3. 當fromTradeId和toTradeId都傳入, fromTradeId不包含,但是toTradeId會在響應中,如果它的值是存在的tradeId
    • orderId不傳時: fromTradeId和toTradeid的值會總是被包含在響應中,如果它們的值是存在的tradeId。

    HTTP 請求

    GET /spot/v3/private/my-trades

    請求參數

    參數是否必須類型說明
    symbolfalsestring幣對名稱
    orderIdfalsestring訂單ID
    limitfalsestring返回數量限制. [1, 50]. 默认: 50
    startTimefalseinteger起始時間戳(毫秒)
    endTimefalseinteger結束時間戳(毫秒)
    fromTradeIdfalsestring從大於此trade ID 開始查詢
    toTradeIdfalsestring以小於此trade ID 為終點

    返回參數

    參數類型說明
    symbolstring幣對名稱
    idstring與 API 使用無關。 該字段反映了網站交易歷史中“交易ID”的一部分
    orderIdstring訂單ID
    tradeIdstring交易ID
    orderPricestring訂單價格
    orderQtystring交易數量
    execFeestring手續費
    feeTokenIdstring手續費 Token ID
    creatTimestring撮合引擎中的創建時間
    isBuyerstring0:買方, 1:賣方
    isMakerstring0:掛單, 1:吃單
    matchOrderIdstring對手交易者的order_id
    makerRebatestringMaker折扣
    executionTimestring訂單完成時間
    blockTradeIdstringParadigm大宗交易ID

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/my-trades?symbol=BTCUSDT' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659084253772' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "id": "1210346127973428992",
    "orderId": "1210073515485572864",
    "tradeId": "2100000000001769786",
    "orderPrice": "20500",
    "orderQty": "0.02",
    "execFee": "0.00002",
    "feeTokenId": "BTC",
    "creatTime": "1659020488738",
    "isBuyer": "0",
    "isMaker": "0",
    "matchOrderId": "1210346015893229312",
    "makerRebate": "0",
    "executionTime": "1659020502026",
    "blockTradeId": ""
    },
    {
    "symbol": "BTCUSDT",
    "id": "1208702504949264128",
    "orderId": "1208702504731160320",
    "tradeId": "2100000000001753197",
    "orderPrice": "20240",
    "orderQty": "0.009881",
    "execFee": "0.000009881",
    "feeTokenId": "BTC",
    "creatTime": "1658824566874",
    "isBuyer": "0",
    "isMaker": "1",
    "matchOrderId": "1208677465155702529",
    "makerRebate": "0",
    "executionTime": "1658824566893",
    "blockTradeId": ""
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659084254366
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/open-order.html b/zh-TW/spot/trade/open-order.html index 833dd26563..67fd8613aa 100644 --- a/zh-TW/spot/trade/open-order.html +++ b/zh-TW/spot/trade/open-order.html @@ -4,13 +4,13 @@ 訂單列表 | Bybit API Documentation - +

    訂單列表

    HTTP 請求

    GET /spot/v3/private/open-orders

    請求參數

    參數是否必須類型說明
    symbolfalsestring幣對名稱
    orderIdfalsestring通過指定訂單ID返回比這個orderId小的訂單,可以用來分頁
    limitfalsestring返回數量限制. [1, 500]. 默認: 500
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    accountIdstring賬戶ID
    symbolstring幣對名稱
    orderLinkIdstring特殊訂單ID,用戶自己生成
    orderIdstring訂單ID
    orderPricestring訂單價格
    orderQtystring訂單數量
    execQtystring成交數量
    cummulativeQuoteQtystring鎖定數量(如果為0,則說明該筆訂單的資金已完成結算)
    avgPricestring訂單已成交的平均價格
    statusstring訂單狀態。可能出現的值為:NEW(新訂單,無成交)、PARTIALLY_FILLED(部分成交)、FILLED(全部成交)、CANCELED(已取消)和REJECTED(訂單被拒絕).
    timeInForcestring執行策略
    orderTypestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    sidestring買賣方向. BUY:買入, SELL:賣出 |
    stopPricestring停止價
    icebergQtystring請忽略
    createTimenumber撮合引擎中的創建時間
    updateTimenumber訂單上次更新的時間戳
    isWorkingstring是否生效. 0:未生效, 1:已生效
    orderCategoryinteger訂單種類. 0:普通單; 1:止盈止損單. 止盈止損單有這個字段
    triggerPricestring觸發價格. 止盈止損單有這個字段
    blockTradeIdstringParadigm大宗交易ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP執行類型
    smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    smpOrderIdstring觸發此SMP執行的交易對手的 orderID

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/open-orders?symbol=BTCUSDT' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659081676022' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotx004",
    "orderId": "1210858291884732160",
    "orderPrice": "23500",
    "orderQty": "0.02",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "NEW",
    "timeInForce": "GTC",
    "orderType": "LIMIT_MAKER",
    "side": "SELL",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": 1659081556722,
    "updateTime": 1659081556740,
    "isWorking": "1"
    "blockTradeId": "",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659081570356
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/order-history.html b/zh-TW/spot/trade/order-history.html index 9473863add..bb8b300d6a 100644 --- a/zh-TW/spot/trade/order-history.html +++ b/zh-TW/spot/trade/order-history.html @@ -4,13 +4,13 @@ 歷史訂單 | Bybit API Documentation - +

    歷史訂單

    信息
    • 如果startTime和endTime都不傳,則默認查詢近7天的數據。市商為3天。
    • 單次查詢最長3個月,最長支持查詢最近6個月的歷史數據。

    HTTP 請求

    GET /spot/v3/private/history-orders

    請求參數

    參數是否必須類型說明
    symbolfalsestring幣對名稱
    orderIdfalsestring通過指定訂單ID返回比這個orderId小的訂單,可以用來分頁
    limitfalseinteger返回數量限制. [1, 500]. 默認: 100
    startTimefalseinteger起始時間戳(毫秒)
    endTimefalseinteger結束時間戳(毫秒)
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳

    返回參數

    參數類型說明
    accountIdstring賬戶ID
    symbolstring幣對名稱
    orderLinkIdstring特殊訂單ID,用戶自己生成
    orderIdstring訂單ID
    orderPricestring訂單價格,對於LIMIT 訂單必需發送
    orderQtystring訂單數量
    execQtystring成交數量
    cummulativeQuoteQtystring對於某些歷史數據 cummulativeQuoteQty 可能會 < 0, 這說明數據當前不可用。
    avgPricestring訂單已成交的平均價格
    statusstring訂單狀態
    timeInForcestring執行策略
    orderTypestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    sidestring買賣方向. BUY:買入, SELL:賣出
    stopPricestring停止價
    icebergQtystring請忽略
    createTimenumber撮合引擎中的創建時間
    updateTimenumber訂單上次更新的時間戳
    isWorkingstring是否生效. 0:未生效, 1:已生效
    orderCategoryinteger訂單種類. 0:普通單; 1:止盈止損單. 止盈止損單有這個字段
    triggerPricestring觸發價格. 止盈止損單有這個字段
    blockTradeIdstringParadigm大宗交易ID
    cancelTypestringCancel type. CancelBySmp
    smpTypestringSMP執行類型
    smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    smpOrderIdstring觸發此SMP執行的交易對手的 orderID

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/history-orders?symbol=BTCUSDT&limit=2&startTime=1658246400000&endTime=1659110400000' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659082629976' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "accountId": "533287",
    "symbol": "BTCUSDT",
    "orderLinkId": "spotx003",
    "orderId": "1210856408331857664",
    "orderPrice": "23800",
    "orderQty": "0.02",
    "execQty": "0",
    "cummulativeQuoteQty": "0",
    "avgPrice": "0",
    "status": "REJECTED",
    "timeInForce": "GTC",
    "orderType": "LIMIT_MAKER",
    "side": "BUY",
    "stopPrice": "0.0",
    "icebergQty": "0.0",
    "createTime": 1659081332185,
    "updateTime": 1659081332225,
    "isWorking": "1",
    "blockTradeId": "1",
    "cancelType": "UNKNOWN"
    "smpGroup": 0,
    "smpOrderId": "",
    "smpType": "None"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1659082630638
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/trade/place-order.html b/zh-TW/spot/trade/place-order.html index 3791ed8c0a..4f1df79d46 100644 --- a/zh-TW/spot/trade/place-order.html +++ b/zh-TW/spot/trade/place-order.html @@ -4,13 +4,13 @@ 創建活動委托單 | Bybit API Documentation - +

    創建活動委托單

    信息

    普通單和止盈止損單的orderLinkId不能重複

    HTTP 請求

    POST /spot/v3/private/order

    請求參數

    參數是否必須類型說明
    symboltruestring幣對名稱
    orderQtytruestring交易數量(市價買單即type=MARKET且side=BUY currency;比如BTCUSDT的qty指的是USDT的qty, 而非市價買單時qty指向都是BTC)
    sidetruestring買賣方向. BUY:買入, SELL:賣出
    orderTypetruestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    timeInForcefalsestring執行策略
    orderPricefalsestring訂單價格。type字段為MARKET時,price字段為非必須。type字段為LIMIT或LIMIT_MAKER時,price字段為必須
    orderLinkIdfalsestring特殊訂單ID,用戶自己生成
    orderCategoryfalseinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單, 下止盈止損單,該參數必傳
    triggerPricefalsestring觸發價格. 用於止盈止損單
    smpTypefalsestringSmp執行類型. 什麼是SMP?

    返回參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring特殊訂單ID,用戶自己生成
    symbolstring幣對名稱
    createTimestring訂單創建時間
    orderPricestring訂單價格,對於LIMIT 訂單必需發送
    orderQtystring訂單數量
    orderTypestring訂單類型, LIMIT/MARKET/LIMIT_MAKER
    sidestring買賣方向. BUY:買入, SELL:賣出
    statusstring訂單狀態
    timeInForcestring執行策略
    accountIdstring賬戶ID
    execQtystring請忽略
    orderCategoryinteger訂單類型. 默認為0:普通訂單; 1止盈止損訂單,若是止盈止損則必傳
    triggerPricestring觸發價格
    smpTypestringSmp執行類型

    請求示例

    curl --location --request POST 'https://api-testnet.bybit.com/spot/v3/private/order' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659067662307' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "symbol": "BTCUSDT",
    "orderQty":"0.01",
    "side": "BUY",
    "orderType": "LIMIT",
    "timeInForce": "GTC",
    "orderPrice": "21300",
    "orderLinkId": "spotx006",
    "orderCategory": 1,
    "triggerPrice": "21700"
    }'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1230969397479298560",
    "orderLinkId": "spotx006",
    "symbol": "BTCUSDT",
    "createTime": "1661478987332",
    "orderPrice": "21300",
    "orderQty": "0.01",
    "orderType": "LIMIT",
    "side": "BUY",
    "status": "ORDER_NEW",
    "timeInForce": "GTC",
    "accountId": "554118",
    "orderCategory": 1,
    "triggerPrice": "21700",
    "smpType": "None"
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1661478987364
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/v1.html b/zh-TW/spot/v1.html index e180c85e14..4867e162d3 100644 --- a/zh-TW/spot/v1.html +++ b/zh-TW/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/spot/v3.html b/zh-TW/spot/v3.html index 3bbab687d6..f22cf14c17 100644 --- a/zh-TW/spot/v3.html +++ b/zh-TW/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/spot/wallet.html b/zh-TW/spot/wallet.html index e446ec6a62..5737e14b49 100644 --- a/zh-TW/spot/wallet.html +++ b/zh-TW/spot/wallet.html @@ -4,13 +4,13 @@ 查詢錢包余額 | Bybit API Documentation - +

    查詢錢包余額

    HTTP 請求

    GET /spot/v3/private/account

    請求參數

    返回參數

    參數類型說明
    balancesarrayObject
    > coinstring幣種
    > coinIdstring幣種ID
    > totalstring總額
    > freestring可用余額
    > lockedstring凍結余額

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/account' \
    --header 'X-BAPI-SIGN: XXXXX' \
    --header 'X-BAPI-API-KEY: {api key}' \
    --header 'X-BAPI-TIMESTAMP: 1659346886605' \
    --header 'X-BAPI-RECV-WINDOW: 5000'

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "balances": [
    {
    "coin": "BTC",
    "coinId": "BTC",
    "total": "0.20378018343",
    "free": "0.20378018343",
    "locked": "0"
    },
    {
    "coin": "BTC3L",
    "coinId": "BTC3L",
    "total": "743.03560386",
    "free": "743.03560386",
    "locked": "0"
    },
    {
    "coin": "BTC3S",
    "coinId": "BTC3S",
    "total": "0.999",
    "free": "0.999",
    "locked": "0"
    }
    ]
    },
    "retExtMap": {},
    "retExtInfo": {},
    "time": 1659346887407
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-private/execution.html b/zh-TW/spot/ws-private/execution.html index 8b6fd16db8..4a45d597c8 100644 --- a/zh-TW/spot/ws-private/execution.html +++ b/zh-TW/spot/ws-private/execution.html @@ -4,13 +4,13 @@ 個人成交 | Bybit API Documentation - +

    個人成交

    該訂閱推送成交信息

    推送頻率: 實時

    Topic: ticketInfo

    響應參數

    參數類型說明
    topicstringTopic名
    tsstring消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > estring事件類型
    > Estring事件時間戳
    > sstring交易對
    > qstring成交數量 (毫秒)
    > tstring成交時間戳 (毫秒)
    > pstring成交價格
    > Tstring成交ID
    > ostring訂單ID
    > cstring用戶自定義訂單ID
    > Ostring交易對手的訂單ID
    > astring帳戶ID
    > Astring撮合帳戶ID
    > mboolean是否為Maker. true: maker, false: taker
    > Sstring訂單方向. BUY, SELL
    > bstringParadigm大宗交易ID

    訂閱示例

    {
    "req_id": "ticketInfo_1", //optional
    "op": "subscribe",
    "args": [
    "ticketInfo"
    ]
    }

    推送示例

    {
    "type": "snapshot",
    "topic": "ticketInfo",
    "ts": "1662348310388",
    "data": [
    {
    "e": "ticketInfo",
    "E": "1662348310386",
    "s": "BTCUSDT",
    "q": "0.001007",
    "t": "1662348310373",
    "p": "19842.02",
    "T": "2100000000002220938",
    "o": "1238261807653647872",
    "c": "spotx008",
    "O": "1238225004531834368",
    "a": "533287",
    "A": "642908",
    "m": false,
    "S": "BUY",
    "b": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-private/order.html b/zh-TW/spot/ws-private/order.html index ab343e310d..be2570d458 100644 --- a/zh-TW/spot/ws-private/order.html +++ b/zh-TW/spot/ws-private/order.html @@ -4,13 +4,13 @@ 訂單 | Bybit API Documentation - +

    訂單

    該訂閱用於推送訂單信息,其中 成交均價 = Z / z

    推送頻率: 實時

    Topic: order

    響應參數

    參數類型說明
    topicstringTopic名
    tsstring消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > estring事件類型
    > Estring事件時間戳
    > sstring交易對
    > cstringU用戶自定義訂單ID
    > Sstring訂單方向. BUY, SELL
    > ostring訂單類型. LIMIT, MARKET_OF_QUOTE(市價買), MARKET_OF_BASE(市價賣)
    > fstring執行策略
    > qstring訂單數量
    > pstring訂單價格
    > Xstring訂單狀態
    > istring訂單ID
    > Mstring交易對手的訂單ID
    > lstring最近成交數量
    > zstring累計成交數量
    > Lstring最近成交價格
    > nstring手續費(單筆成交)
    > Nstring手續費幣種
    > ubooleantrue: 普通單, false: 自成交
    > wboolean是否生效. false: 未生效, true: 已生效
    > mboolean是否是LIMIT_MAKER單
    > Ostring訂單創建時間 (毫秒)
    > Zstring累計成交數額
    > Astring撮合賬戶id
    > Cboolean是否關閉
    > vstring槓桿倍數
    > dstringNO_LIQ: 非強平單. IOC: 強平單
    > tstring成交ID
    > bstringParadigm大宗交易ID
    > ctstring取消類型. CancelBySmp
    > ststringSMP執行類型
    > sginteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > sostring觸發此SMP執行的交易對手的 orderID

    訂閱示例

    {
    "req_id": "order_1", //optional
    "op": "subscribe",
    "args": [
    "order"
    ]
    }

    推送示例

    {
    "type": "snapshot",
    "topic": "order",
    "ts": "1662348310441",
    "data": [
    {
    "e": "order",
    "E": "1662348310441",
    "s": "BTCUSDT",
    "c": "spotx008",
    "S": "BUY",
    "o": "MARKET_OF_QUOTE",
    "f": "GTC",
    "q": "20",
    "p": "0",
    "X": "CANCELED",
    "i": "1238261807653647872",
    "M": "1238225004531834368",
    "l": "0.001007",
    "z": "0.001007",
    "L": "19842.02",
    "n": "0",
    "N": "BTC",
    "u": true,
    "w": true,
    "m": false,
    "O": "1662348310368",
    "Z": "19.98091414",
    "A": "0",
    "C": false,
    "v": "0",
    "d": "NO_LIQ",
    "t": "2100000000002220938",
    "sg": 1005,
    "st": "CancelTaker",
    "ct": "CancelBySmp",
    "so": "1400584538658193920",
    "b": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-private/stop-order.html b/zh-TW/spot/ws-private/stop-order.html index 7936fe6ddf..525ed578c8 100644 --- a/zh-TW/spot/ws-private/stop-order.html +++ b/zh-TW/spot/ws-private/stop-order.html @@ -4,13 +4,13 @@ 止盈止損訂單 | Bybit API Documentation - +

    止盈止損訂單

    該訂閱推送web/app下的條件和止盈止損訂單信息, 或者是openAPI下的止盈止損訂單信息推送。只要訂單狀態發生改變,就會推送消息。

    推送頻率: 實時

    Topic: stopOrder

    響應參數

    參數類型說明
    topicstringTopic名
    tsstring消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > estring事件類型
    > Estring事件時間戳
    > sstring交易對
    > cstringU用戶自定義訂單ID
    > Sstring訂單方向. BUY, SELL
    > ostring訂單類型. LIMIT, MARKET_OF_QUOTE(市價買), MARKET_OF_BASE(市價賣)
    > fstring執行策略
    > qstring訂單數量
    > pstring訂單價格
    > Xstring止盈止損單訂單狀態
    > istring訂單ID
    > Tstring訂單創建時間戳 (毫秒)
    > tstring訂單觸發時間戳 (毫秒). 僅訂單狀態是ORDER_FILLED或者ORDER_FAILED才有值
    > Cstring訂單更新時間戳 (毫秒). 每當訂單狀態發生變更時,會更新該時間
    > qpstring下單時的行情價格
    > eostring止盈止損訂單被觸發後轉化為普通訂單後的訂單ID
    > tistring與業務無關,請忽略
    > sistring與業務無關,請忽略
    > tpstring觸發價格

    訂閱示例

    {
    "req_id": "stopOrder_1", //optional
    "op": "subscribe",
    "args": [
    "stopOrder"
    ]
    }

    推送示例

    {
    "type": "snapshot",
    "topic": "stopOrder",
    "ts": "1678689442476",
    "data": [
    {
    "e": "stopOrder",
    "E": "1678689442476",
    "s": "XRPUSDT",
    "c": "1678689442086",
    "S": "BUY",
    "o": "LIMIT",
    "f": "GTC",
    "q": "100",
    "p": "0.335",
    "X": "ORDER_NEW",
    "i": "1375341158856660992",
    "T": "1678689442437",
    "t": "0",
    "C": "1678689442437",
    "qp": "0.3666",
    "eo": "1375341158856660993",
    "ti": "209a1cc923e1322315805fea6ed6fcbf",
    "si": "d980d5212ea83c87",
    "tp": "0.33"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-private/wallet.html b/zh-TW/spot/ws-private/wallet.html index 68862c9fe0..32f01723fa 100644 --- a/zh-TW/spot/ws-private/wallet.html +++ b/zh-TW/spot/ws-private/wallet.html @@ -4,13 +4,13 @@ 錢包 | Bybit API Documentation - +

    錢包

    該訂閱用於推送現貨錢包信息

    推送頻率: 實時

    Topic: outboundAccountInfo

    響應參數

    參數類型說明
    topicstringTopic名
    tsstring消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > estring事件類型
    > Estring時間戳 (毫秒)
    > Tboolean允許交易
    > Wboolean允許提現
    > Dboolean允許充值
    > Barray錢包資產變化數組
    >> astring幣種
    >> fstring可用餘額
    >> lstring委託單預佔用金額

    訂閱示例

    {
    "req_id": "acctInfo_1", //optional
    "op": "subscribe",
    "args": [
    "outboundAccountInfo"
    ]
    }

    推送示例

    {
    "type": "snapshot",
    "topic": "outboundAccountInfo",
    "ts": "1662107217641",
    "data": [
    {
    "e": "outboundAccountInfo",
    "E": "1662107217640",
    "T": true,
    "W": true,
    "D": true,
    "B": [
    {
    "a": "USDT",
    "f": "176.81254174",
    "l": "201.575"
    }
    ]
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-public/bookticker.html b/zh-TW/spot/ws-public/bookticker.html index b19bda34c9..3a441b2098 100644 --- a/zh-TW/spot/ws-public/bookticker.html +++ b/zh-TW/spot/ws-public/bookticker.html @@ -4,13 +4,13 @@ 買一賣一 | Bybit API Documentation - +

    買一賣一

    最優買一賣一價

    推送频率: 100ms

    Topic: bookticker.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名
    tsnumber消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > sstring交易對
    > bpstring買一價
    > bqstring買一價數量
    > apstring賣一價
    > aqstring賣一價數量
    > tnumber系統生成該數據的時間戳 (毫秒)

    訂閱示例

    {
    "req_id": "bookticker00001", //optional
    "op": "subscribe",
    "args": [
    "bookticker.BTCUSDT"
    ]
    }

    推送示例

    {
    "topic": "bookticker.BTCUSDT",
    "ts": 1673437259336,
    "type": "snapshot",
    "data": {
    "s": "BTCUSDT",
    "bp": "17440",
    "bq": "0.0002",
    "ap": "17440.01",
    "aq": "0.21302",
    "t": 1673437259336
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-public/kline.html b/zh-TW/spot/ws-public/kline.html index be2baf58b3..cc52394829 100644 --- a/zh-TW/spot/ws-public/kline.html +++ b/zh-TW/spot/ws-public/kline.html @@ -4,13 +4,13 @@ K線 | Bybit API Documentation - +

    K線

    訂閱K線數據推送, 請在這裡查閱期望訂閱的粒度

    Topic: kline.{interval}.{symbol} e.g., kline.30m.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    tsnumber消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > tnumber蠟燭開始時間戳 (毫秒)
    > sstring交易對
    > cstring收盤價
    > hstring最高價格
    > lstring最低價格
    > ostring開盤價格
    > vstring交易量

    訂閱示例

    {
    "req_id": "kline00001", //optional
    "op": "subscribe",
    "args": [
    "kline.30m.BTCUSDT"
    ]
    }

    推送示例

    {
    "type": "snapshot",
    "topic": "kline.30m.BTCUSDT",
    "data": {
    "s": "BTCUSDT",
    "t": 1673436600000,
    "o": "17439.16",
    "c": "17437.82",
    "h": "17450.45",
    "l": "17433.5",
    "v": "34.059614"
    },
    "ts": 1673438143609
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-public/orderbook.html b/zh-TW/spot/ws-public/orderbook.html index e65d7bf09f..36f8516d3d 100644 --- a/zh-TW/spot/ws-public/orderbook.html +++ b/zh-TW/spot/ws-public/orderbook.html @@ -4,13 +4,13 @@ 深度 | Bybit API Documentation - +

    深度

    交易對的深度信息:

    • 訂單簿快照頻率深度: bids 和 asks 各40
    • 訂單簿版本變更觸發事件:
      • 訂單進入訂單簿
      • 訂單離開訂單簿
      • 訂單數量變更
      • 訂單已完成

    僅推送快照數據

    推送頻率: 100ms

    Topic: orderbook.40.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名
    tsnumber消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > tnumber系統生成該數據的時間戳 (毫秒)
    > sstring交易對
    > barrayBid, 買方. 按照價格從大到小
    >> b[0]string買方報價
    >> b[1]string買方數量
    > aarrayAsk, 賣方. 按照價格從小到大
    >> a[0]string賣方報價
    >> a[1]string賣方數量

    訂閱示例

    {
    "req_id": "depth00001", //optional
    "op": "subscribe",
    "args": [
    "orderbook.40.BTCUSDT"
    ]
    }

    推送示例

    {
    "topic": "orderbook.40.BTCUSDT",
    "ts": 1673439424737,
    "type": "snapshot",
    "data": {
    "s": "BTCUSDT",
    "t": 1673439424737,
    "b": [
    [
    "17423",
    "0.809534"
    ],
    [
    "17422.86",
    "0.043596"
    ],
    ...
    ],
    "a": [
    ...
    [
    "17428.28",
    "0.004811"
    ],
    [
    "17428.62",
    "0.23"
    ]
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-public/public-trade.html b/zh-TW/spot/ws-public/public-trade.html index 1c9a7219d5..25c0ab1c74 100644 --- a/zh-TW/spot/ws-public/public-trade.html +++ b/zh-TW/spot/ws-public/public-trade.html @@ -4,13 +4,13 @@ 平臺成交 | Bybit API Documentation - +

    平臺成交

    逐筆交易推送每一筆成交的信息。成交,或者說交易的定義是僅有一個吃單者與一個掛單者相互交易。

    變量「v」可以理解成一個交易ID。這個變量是全局遞增的並且獨特的。例如:假設過去5秒有3筆交易發生,分別是ETHUSDT、BTCUSDT、BHTBTC。它們的「v」會為連續的值(112,113,114)。

    推送頻率: 實時

    Topic: trade.{symbol}

    參數類型說明
    topicstringTopic名
    tsnumber消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > vstring成交ID
    > tnumber撮合引擎撮合时间戳 (毫秒)
    > pstring成交價格
    > qstring成交數量
    > mboolean交易類型標識. 0:幣幣成交. 1:Paradigm 大宗交易

    訂閱示例

    {
    "req_id": "trade0001", //optional
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT"
    ]
    }

    推送示例

    {
    "topic": "trade.BTCUSDT",
    "ts": 1673437259397,
    "type": "snapshot",
    "data": {
    "v": "2290000000036455162",
    "t": 1673437259395,
    "p": "17440",
    "q": "0.0002",
    "m": false,
    "type": "0"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws-public/ticker.html b/zh-TW/spot/ws-public/ticker.html index b790370c3f..0c2e1e9d23 100644 --- a/zh-TW/spot/ws-public/ticker.html +++ b/zh-TW/spot/ws-public/ticker.html @@ -4,13 +4,13 @@ 行情 | Bybit API Documentation - +

    行情

    交易對的24小時統計數據

    推送頻率: 實時

    Topic: tickers.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名
    tsnumber消息被推送出來的時間戳 (毫秒)
    typestring數據類型. snapshot
    dataarrayObject
    > tnumber系統生成該數據的時間戳 (毫秒)
    > sstring交易對
    > ostring開盤價格
    > hstring最高價格
    > lstring最低價格
    > cstring收盤價格
    > vstring成交量
    > qvstring成交金額
    > mstring漲幅
    > xpstringUSD指數價格,可以為空

    訂閱示例

    {
    "req_id": "ticker00001", //optional
    "op": "subscribe",
    "args": [
    "tickers.BTCUSDT"
    ]
    }

    推送示例

    {
    "topic": "tickers.BTCUSDT",
    "ts": 1673853966002,
    "type": "snapshot",
    "data": {
    "t": 1673853957769,
    "s": "BTCUSDT",
    "c": "21097.53",
    "h": "21426.99",
    "l": "20575",
    "o": "20705.31",
    "v": "6786.96571",
    "qv": "142076886.7193882",
    "m": "0.0189",
    "xp": "21109.48012482"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/spot/ws/connect.html b/zh-TW/spot/ws/connect.html index 415adb74b9..d1e427999b 100644 --- a/zh-TW/spot/ws/connect.html +++ b/zh-TW/spot/ws/connect.html @@ -4,14 +4,14 @@ 訂閱WebSocket | Bybit API Documentation - +

    訂閱WebSocket

    信息

    以下WSS地址僅適用現貨. 要想接收期貨的推送,請前往:

    訂閱地址:
    測試網:

    • 公有頻道: wss://stream-testnet.bybit.com/spot/public/v3
    • 私有頻道: wss://stream-testnet.bybit.com/spot/private/v3

    主網:

    • 公有頻道: wss://stream.bybit.com/spot/public/v3
    • 私有頻道: wss://stream.bybit.com/spot/private/v3
    信息

    公有頻道不需要鑒權. 以下內容僅適用於私有頻道的訂閱

    構建連接時,創建鑒權請求。

    注意: 如果您正在使用pybit, bybit-api或者其他第三方庫, 您可以忽略此項-因為鑒權已經內建。

    {
    "req_id": "10001", // 可選
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //過期時間應當大於當前時間戳
    "singature"
    ]
    }
    # 基於: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # 生成expires
    expires = int((time.time() + 1) * 1000)

    # 生成簽名
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # 發送鑒權請求
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    鑒權成功的響應示例

    {
    "success": true,
    "ret_msg": "",
    "conn_id": "06a3cbfffe5df9cb-0000000e-00026965-fe306ee9ec20f544-4ab7116c",
    "req_id": "",
    "op": "auth"
    }
    信息

    簽名生成的示例可以參考這裡

    警告

    由於網絡的複雜性,您可能隨時遇到斷連。請參考以下建議確保您能即時接收到推送:

    1. 通過發送心跳
    2. 遇到斷連時,立即重新連接

    IP限頻

    • 不要嘗試頻繁地構建連接與斷開連接;
    • 不要在5分鐘內構建超過500個連接。

    如何發送心跳

    發送ping的示例

    // req_id是可選參數
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    接收到pong的響應示例

    // 有req_id
    {
    "op": "pong",
    "args": [
    1661741630642
    ],
    "req_id": "100001",
    "conn_id": "706b870c"
    }

    // 沒有req_id
    {
    "op": "pong",
    "args": [
    1661741654529
    ],
    "conn_id": "706b870c"
    }
    警告

    為了維持連接,我們推薦您每20秒發送一次心跳。

    頻率限制

    僅限私有頻道:

    • 每個api_key最多可以保持100個websocket私有連接,超過100個連接後的新連接會被服務器拒絕。
    • 單個IP同時最多50個websocket私有topic鏈接

    如何訂閱topic

    理解Websocket裡的args

    通過傳入args來訂閱指定topic

    // 訂閱trade下的BTCUSDT
    {
    "req_id": "10001", // 可選
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT"
    ]
    }

    通過","來訂閱同一個topic下的多個交易對

    {
    "req_id": "10001", // 可選
    "op": "subscribe",
    "args": [
    "trade.BTCUSDT",
    "trade.ETHUSDT"
    ]
    }

    訂閱多個topic

    ws.send('{"req_id": "10001", "op": "subscribe", "args": ["trade.BTCUSDT", "trade.ETHUSDT", "tickers.BTCUSDT", "bookticker.BTCUSDT"]}')
    提示

    每次向單一連接僅能發送不超過10個參數的訂閱請求,但單個公有連接沒有args訂閱限制

    理解如何取消訂閱

    您可以通過發送請求來動態地停止訂閱

    ws.send('{"req_id": "10002", "op": "unsubscribe", "args": ["trade.BTCUSDT"]}');
    // 示例: 取消訂閱BTCUSDT和ETHUSDT
    {
    "req_id": "10002", // 可選
    "op": "unsubscribe",
    "args": [
    "trade.BTCUSDT",
    "trade.ETHUSDT"
    ]
    }
    // 取消訂閱的響應
    {
    "op": "unsubscribe",
    "success": true,
    "req_id": "10002",
    "ret_msg": "unsubscribe",
    "conn_id": "46f097b7"
    }

    理解訂閱的響應

    訂閱成功後的響應示例

    // 公共頻道的響應
    {
    "op": "subscribe",
    "success": true,
    "req_id": "10001",
    "ret_msg": "subscribe",
    "conn_id": "46f097b7"
    }
    // 私有頻道的響應
    {
    "success": true,
    "ret_msg": "",
    "conn_id": "06a3cbfffe5df9cb-0000000e-00026965-fe306ee9ec20f544-4ab7116c",
    "req_id": "private0001",
    "op": "subscribe"
    }

    訂閱成功後,您將收到結果信息。可以根據響應判斷訂閱是否成功。

    - + \ No newline at end of file diff --git a/zh-TW/tax.html b/zh-TW/tax.html index 8fc352ed2f..4ffe4167db 100644 --- a/zh-TW/tax.html +++ b/zh-TW/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/tax/data-export.html b/zh-TW/tax/data-export.html index e5668a565e..911f62b6e2 100644 --- a/zh-TW/tax/data-export.html +++ b/zh-TW/tax/data-export.html @@ -4,13 +4,13 @@ 數據導出 | Bybit API Documentation - +

    數據導出

    HTTP 請求

    POST /fht/compliance/tax/v3/private/url

    請求參數

    參數是否必需類型說明
    queryIdtruestring報告請求 ID

    響應參數

    參數類型說明
    urlstring文件的URL網址 (Basepath+Files)。為了縮短生成報告所需的時間,它可以生成多個文件。請注意這一點,並在請求數據導出時使用相同的基本路徑組合多個文件
    信息

    使用python將S3文件轉換為 CSV的示例

    Python腳本


    import pandas as pd
    import os

    class Bases(object):
    @staticmethod
    def path_list(path):
    """
    :param path:
    :return: list of file paths
    """
    file_list = []
    if os.path.isdir(path):
    print("it's a directory")
    for root, dirs, files in os.walk(path):
    for f in files:
    file = os.path.join(root, f)
    file_list.append(file)
    return file_list
    elif os.path.isfile(path):
    print("it's a normal file")
    return [path]

    class pd_service(Bases):
    def get_data(self, file_path):
    """
    Read s3 files, merge forms
    :param file_path:
    :return:
    """
    df_all = pd.DataFrame()
    for paths in self.path_list(path=file_path):
    df_all = pd.concat([df_all, pd.read_orc(paths)], axis=0)
    print('Row number of tables:', df_all[df_all.columns[1]].count())
    print(df_all.columns.values)
    df_all.sort_values("TradeTime", inplace=True)
    df_all.to_csv("test_data_s3.csv", header=True, index=False)
    print(df_all)
    return df_all

    if __name__ == '__main__':
    # file path
    path = 'XXXX'
    test = pd_service()
    test.get_data(file_path=path)

    請求示例

    POST /fht/compliance/tax/v3/private/url HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671184057480
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"queryId":"12312312415325325"}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "url": "{\"Files\":[\"20221216/adfsf34234-8e87-4c72-bc70-dsa234234daf/_SUCCESS\",\"20221216/dafasdf34243-8e87-4c72-bc70-dafsd34234/part-00000-adfsd34-00bd-4fe9-9591-adfasr343-c000\"],\"Basepath\":\"https://prod-bybit-tax-api-1705-rz.s3.ap-southeast-1.amazonaws.com/\"}"
    },
    "retExtInfo": {},
    "time": 1671184057646
    }
    - + \ No newline at end of file diff --git a/zh-TW/tax/enum.html b/zh-TW/tax/enum.html index 6909ce04d3..1f9df46c5e 100644 --- a/zh-TW/tax/enum.html +++ b/zh-TW/tax/enum.html @@ -4,13 +4,13 @@ 枚舉定義 | Bybit API Documentation - +

    枚舉定義

    ReportType

    • TRADE - 交易歷史
    • P&L - 盈虧歷史
    • EARN - 賺取歷史
    • DEPOSIT&WITHDRAWAL - 充提歷史
    • BONUS - 體驗金歷史
    • AIRDROP - 空投歷史

    ReportNumber

    ReportType = "TRADE"

    • 1 - 獲取現貨交易歷史
    • 2 - 獲取合約交易歷史
    • 3 - 獲取USDC交易歷史
    • 4 - 獲取NFT交易歷史

    ReportType = "P&L"

    • 1 - 獲取合約平倉盈虧歷史

    ReportType = "EARN"

    • 1 - 獲取Bybit儲蓄收益歷史
    • 2 - 獲取流動性挖礦流動性歷史
    • 3 - 獲取流動性挖礦收益歷史
    • 4 - 獲取流動性挖礦兌換歷史
    • 5 - 獲取雙幣資產兌換歷史
    • 6 - 獲取Defi挖礦收益歷史
    • 7 - 獲取Launchpool收益歷史
    • 8 - 獲取Sharkfin收益歷史

    ReportType = "DEPOSIT&WITHDRAWAL"

    • 1 - 獲取加密貨幣入金歷史
    • 2 - 獲取P2P充值歷史
    • 3 - 獲取法幣出入金歷史
    • 4 - 獲取快捷買幣交易歷史
    • 5 - 獲取第三方入金歷史
    • 6 - 獲取加密貨幣提幣歷史
    • 7 - 獲取NFT充提歷史

    ReportType = "BONUS"

    • 1 - 獲取優惠券歷史
    • 2 - 獲取贈金歷史

    ReportType = "AIRDROP"

    • 1 - 獲取空投歷史
    - + \ No newline at end of file diff --git a/zh-TW/tax/explain.html b/zh-TW/tax/explain.html index 216dd3cd40..828f2018a0 100644 --- a/zh-TW/tax/explain.html +++ b/zh-TW/tax/explain.html @@ -4,13 +4,13 @@ 數據說明 | Bybit API Documentation - +

    數據說明

    交易歷史

    1. 現貨交易歷史

    響應參數

    參數類型說明
    OrderIDstring關閉訂單的訂單ID
    TradeIDstring平倉訂單的交易ID
    Symbolstring交易對名稱
    Sidestring買賣方向
    QuoteCoinstring報價幣種
    BaseCoinstring交易幣種
    ExecPricestring成交價格
    ExecValuestring成交價值
    TradingFeestring單次成交的手續費
    FeeTokenstring手續費幣種
    TradeTimestring成交時間戳 (毫秒)

    2. 合約交易歷史

    響應參數

    參數類型說明
    OrderIDstring關閉訂單的訂單ID
    TradeIDstring平倉訂單的交易ID
    ContractTypestring合約類型. 反向合約, 正向合約, 期貨
    Symbolstring交易對名稱
    Sidestring買賣方向
    QuoteCoinstring報價幣種
    BaseCoinstring交易幣種
    ExecPricestring成交價格
    ExecQtystring成交數量
    ExecTypestring成交類型. Trade, ADL, BustTrade
    ExecValuestring成交價值
    FeeRatestringMaker或Taker的手續費率
    FeeTokenstring手續費幣種
    TradingFeestring單次成交的手續費
    TradeTimestring成交時間戳 (毫秒)
    ClosedSizestring平倉數量
    OrderTypestring訂單類型

    3. 期權交易歷史

    響應參數

    參數類型說明
    OrderIDstring關閉訂單的訂單ID
    TradeIDstring平倉訂單的交易ID
    ContractTypestring合約類型
    Symbolstring交易對名稱
    Sidestring買賣方向
    QuoteCoinstring報價幣種
    BaseCoinstring交易幣種
    ExecPricestring成交價格
    ExecQtystring成交數量
    ExecTypestring成交類型
    ExecValuestring成交價值
    FeeRatestringMaker或Taker的手續費率
    FeeTokenstring手續費幣種
    TradingFeestring單次成交的手續費
    TradeTimestring成交時間戳 (毫秒)

    4. NFT交易歷史

    響應參數

    參數類型說明
    OrderIDstring關閉訂單的訂單ID
    Networkstring網絡名稱
    Sidestring買賣方向
    NftIdstringNFT集合ID
    ExecValuestring成交價值
    BaseCoinstring交易幣種
    PlatformFeestring平台費用,費用按照交易幣種計算
    ShareFeestring共享費用,費用按照交易幣種計算
    TradeTimestring成交時間戳 (毫秒)

    損益歷史

    響應參數

    參數類型說明
    OrderIDstring關閉訂單的訂單ID
    ContractTypestring合約類型. 反向合約, 正向合約, 期貨
    Symbolstring交易對名稱
    Sidestring買賣方向
    ClosedSizestring平倉大小
    CumEntryValuestring累計入場價值
    AvgEntryPricestring平均入場價格
    CumExitValuestring累計出場價值
    AvgExitPricestring平均出場價格
    SettleCoinstring結算幣種
    ClosedPNLstring平倉盈虧
    FillCountstring單筆訂單的成交次數
    TradeTimestring交易時間戳 (毫秒)

    賺取歷史

    1. Bybit儲蓄收益歷史

    響應參數

    參數類型說明
    AssetStakedCoinstring用於抵押在Bybit儲蓄產品中的幣種
    StakingTypestring質押類型。靈活和固定期限
    AssetEarnedCoinstring發放利息的代幣
    EffectiveStakingAmountstring使用 Asset Staked 幣質押的總金額
    Yieldstring利息收入
    TradeTimestring交易時間戳 (毫秒)

    2. 流動性挖礦歷史

    響應參數

    參數類型說明
    OrderIDstring訂單ID
    Symbolstring交易對名稱
    OrderTypestring包括不同類型的流動性挖掘。添加、刪除、降低杠桿、再投資
    EntryPricestring入場價格
    Leveragestring槓桿倍數
    Slippagestring訂單價格與訂單實際執行時的價格差值
    Liquiditystring流動性=本金變化乘以槓桿
    TradeTimestring交易時間戳 (毫秒)

    3. 流動性挖礦收益歷史

    響應參數

    參數類型說明
    AssetEarnedCoinstring發放利息的代幣
    Yieldstring利息收入
    TradeTimestring交易時間戳 (毫秒)

    4. 流動性挖礦兌換歷史

    響應參數

    參數類型說明
    OrderIdstring訂單ID
    InitialCoinstring兌出幣種
    DepositAmountstring兌出金額
    SwapCoinstring兌入幣種
    SwapAmountstring兌入金額
    SwapFeeTokenstring兌換手續費幣種
    SwapFeestring兌換手續費
    Slippagestring訂單價格與訂單實際執行時的價格差值
    TradeTimestring交易時間戳 (毫秒)

    5. 雙幣投資兌換歷史

    響應參數

    參數類型說明
    OrderIdstring訂單ID
    InitialCoinstring兌出幣種
    DepositAmountstring兌出金額
    SwapCoinstring兌入幣種
    SwapAmountstring兌入金額
    OrderTimenumber訂單創建時間戳 (毫秒)
    TradeTimenumber交易時間戳 (毫秒)

    6. DeFi Mining收益歷史

    響應參數

    參數類型說明
    OrderIdstring訂單ID
    AssetStakedCoinstring用於抵押在Bybit儲蓄產品中的幣種
    Yieldstring利息收入
    OrderTimenumber訂單創建時間戳 (毫秒)
    TradeTimenumber交易時間戳 (毫秒)

    7. Launchpool收益歷史

    響應參數

    參數類型說明
    AssetEarnedCoinstring發放利息的代幣
    EffectiveStakingAmountstring使用 Asset Staked 幣質押的總金額
    Yieldstring利息收入
    TradeTimenumber交易時間戳 (毫秒)

    8. Sharkfin收益歷史

    響應參數

    參數類型說明
    AssetEarnedCoinstring發放利息的代幣
    Yieldstring利息收入
    TradeTimenumber交易時間戳 (毫秒)

    入金提幣歷史

    1. 加密貨幣入金歷史

    響應參數

    參數類型說明
    Txidstring交易ID
    DepositTypestring入金類型. 鏈上入金
    ChainTypestring鏈名
    Symbolstring交易對名稱
    FinalAmountstring入金數量
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    2. P2P充值歷史

    響應參數

    參數類型說明
    OrderIDstringOrder ID
    OrderTypestring包括不同類型的流動性挖掘。添加、刪除、降低杠桿、再投資
    P2pSidestring對於 P2P 買家,這代表買家購買了相應的硬幣並使用法定貨幣。對於 P2P 賣家,這代表買家出售相應的硬幣並獲得法定貨幣作為回報
    Fiatstring法幣
    FiatAmountstring法幣金額
    Coinstring幣種
    CoinPricestring幣種價格
    CoinAmountstring幣種數量
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    3. 法幣出入金歷史

    響應參數

    參數類型說明
    OrderIDstring訂單ID
    Typestring類型. DEPOSIT, WITHDRAW
    Fiatstring法幣
    DepositAmountstring入金數量
    FinalAmountstring加密貨幣數量
    Feestring手續費
    PaymentMethodsstring支付方式
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    4. 快捷買幣交易歷史

    響應參數

    參數類型說明
    OrderIDstring訂單ID
    Sidestring交易方向
    Fiatstring法幣
    DepositAmountstring法幣入金數量
    DestinationCoinstring目標幣種
    CoinPricestring目標幣種價格
    FinalAmountstring獲得目標幣種數量
    Feestring手續費
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    5. 第三方入金歷史

    響應參數

    參數類型說明
    OrderIDstring訂單ID
    Txidstring交易ID
    Platformstring支付方式
    Fiatstring法幣
    DepositAmountstring法幣入金數量
    DestinationCoinstring目標幣種
    CoinPricestring目標幣種價格
    FinalAmountstring獲得目標幣種數量
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    6. 加密貨幣提幣歷史

    響應參數

    參數類型說明
    Txidstring交易ID
    ChainTypestring鏈名
    Coinstring幣種
    FinalAmountstring出金數量
    Feestring提幣手續費
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    7. NFT充提歷史

    響應參數

    參數類型說明
    OrderIdstring訂單ID
    TxHashstringNFT交易的哈希ID
    TokenIdstringNFT的tokenID
    TransferTypestring類型. 轉入或轉出
    Networkstring網絡
    FeeTokenstring手續費幣種
    Feestring手續費
    OrderTimenumber創建時間戳 (毫秒)
    CompletedTimenumber交易完成時間戳 (毫秒)

    贈金歷史

    提示
  • 贈金 - 體驗贈金直接支付到用戶資產賬戶,可用於開倉抵扣手續費和資金費率費用。顯示的所有獎金都已被用戶應用。
  • 優惠券 - 優惠券可抵扣的款項將僅用於抵消手續費。不會添加到用戶的資產賬戶中。扣除後將返還至用戶資產賬戶。 顯示的所有優惠券都已被用戶應用。
  • 1. 優惠券歷史

    響應參數

    參數類型說明
    Coinstring優惠券的幣種
    FinalAmountstring代幣數量
    CompletedTimenumber交易完成時間戳 (毫秒)

    2. 贈金歷史

    響應參數

    參數類型說明
    Coinstring體驗金的幣種
    FinalAmountstring代幣數量
    CompletedTimenumber交易完成時間戳 (毫秒)

    空投歷史

    響應參數

    參數類型說明
    Coinstring空投幣種
    FinalAmountstring代幣數量
    TransferTypestring空投的類型. 空投充值、空投提現
    TransferDescriptionstring轉帳說明
    CompletedTimenumber交易完成時間戳 (毫秒)
    - + \ No newline at end of file diff --git a/zh-TW/tax/report.html b/zh-TW/tax/report.html index d7e643f65a..36a5d6a318 100644 --- a/zh-TW/tax/report.html +++ b/zh-TW/tax/report.html @@ -4,13 +4,13 @@ 創建導出報告請求 | Bybit API Documentation - +

    創建導出報告請求

    HTTP 請求

    POST /fht/compliance/tax/v3/private/create

    請求參數

    參數是否必需類型說明
    typetruestring報告類型
    numbertruestring不同類型下的類別號
    startTimetruestringUNIX 時間。這是以秒為單位。報告開始時間的時間戳。 StartTime 包含在數據導出的時間範圍內。
    endTimetruestringUNIX 時間。這是以秒為單位。報告結束時間的時間戳。 EndTime 不包含在數據導出的時間範圍內。請注意,對於每個請求,我們最多只允許從 StartTime 開始搜索 2 個月的時間範圍。

    響應參數

    參數類型說明
    queryIdstring報告請求 ID

    請求示例

    POST /fht/compliance/tax/v3/private/create HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183681683
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"startTime":"1667264621","endTime":"1669261057","type":"TRADE","number":"2"}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "queryId": "12312312415325325"
    },
    "retExtInfo": {},
    "time": 1671183681990
    }
    - + \ No newline at end of file diff --git a/zh-TW/tax/status.html b/zh-TW/tax/status.html index d8ac69b514..1c67519194 100644 --- a/zh-TW/tax/status.html +++ b/zh-TW/tax/status.html @@ -4,13 +4,13 @@ 查詢報告導出狀態 | Bybit API Documentation - +

    查詢報告導出狀態

    HTTP 請求

    POST /fht/compliance/tax/v3/private/status

    請求參數

    參數是否必需類型說明
    queryIdtruestring報告請求 ID

    響應參數

    參數類型說明
    statusstring
    • -1: 失敗
    • 0: 隊列中
    • 1: 處理中
    • 2: 處理完成
    • 3: 已過期

    請求示例

    POST /fht/compliance/tax/v3/private/status HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183923110
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {"queryId":"12312312415325325"}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "status": "2"
    },
    "retExtInfo": {},
    "time": 1671183923244
    }
    - + \ No newline at end of file diff --git a/zh-TW/tax/time.html b/zh-TW/tax/time.html index bebb2f70a3..1386b1b98c 100644 --- a/zh-TW/tax/time.html +++ b/zh-TW/tax/time.html @@ -4,13 +4,13 @@ 查詢特定用戶在平台註冊日期 | Bybit API Documentation - +

    查詢特定用戶在平台註冊日期

    HTTP 請求

    POST /fht/compliance/tax/v3/private/registertime

    請求參數

    響應參數

    參數類型說明
    registerTimestring特定用戶在平台上註冊的日期 (秒級unix時間戳)

    請求示例

    POST /fht/compliance/tax/v3/private/registertime HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: xxxxxxxxxxxxxx
    X-BAPI-API-KEY: xxxxxxxxxxxxxx
    X-BAPI-TIMESTAMP: 1671183584043
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    {}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "registerTime": "1634515200"
    },
    "retExtInfo": {},
    "time": 1671183584270
    }
    - + \ No newline at end of file diff --git a/zh-TW/testnet/account_asset.html b/zh-TW/testnet/account_asset.html index 2b4e1587ac..daa8a5c04c 100644 --- a/zh-TW/testnet/account_asset.html +++ b/zh-TW/testnet/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/account_asset/v1.html b/zh-TW/testnet/account_asset/v1.html index 372b9942b8..6d0d4d2ba8 100644 --- a/zh-TW/testnet/account_asset/v1.html +++ b/zh-TW/testnet/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/account_asset/v3.html b/zh-TW/testnet/account_asset/v3.html index ec335617b3..0ca2daf110 100644 --- a/zh-TW/testnet/account_asset/v3.html +++ b/zh-TW/testnet/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/copy_trading.html b/zh-TW/testnet/copy_trading.html index 234cf2edc8..9c4d2ca5d1 100644 --- a/zh-TW/testnet/copy_trading.html +++ b/zh-TW/testnet/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/derivativesV3/contract.html b/zh-TW/testnet/derivativesV3/contract.html index 6ea3a7f419..6e53d4f35c 100644 --- a/zh-TW/testnet/derivativesV3/contract.html +++ b/zh-TW/testnet/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/derivativesV3/unified_margin.html b/zh-TW/testnet/derivativesV3/unified_margin.html index e2ed653a6b..81cf14ddef 100644 --- a/zh-TW/testnet/derivativesV3/unified_margin.html +++ b/zh-TW/testnet/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/futuresV2/inverse.html b/zh-TW/testnet/futuresV2/inverse.html index ba0895e77f..2c7d243390 100644 --- a/zh-TW/testnet/futuresV2/inverse.html +++ b/zh-TW/testnet/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/futuresV2/inverse_futures.html b/zh-TW/testnet/futuresV2/inverse_futures.html index b30cb70ad3..e668f03f0e 100644 --- a/zh-TW/testnet/futuresV2/inverse_futures.html +++ b/zh-TW/testnet/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/futuresV2/linear.html b/zh-TW/testnet/futuresV2/linear.html index e80055cdfe..f33f0e9e18 100644 --- a/zh-TW/testnet/futuresV2/linear.html +++ b/zh-TW/testnet/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/inverse.html b/zh-TW/testnet/inverse.html index 29e1ce6c44..747eb4882e 100644 --- a/zh-TW/testnet/inverse.html +++ b/zh-TW/testnet/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/inverse_futures.html b/zh-TW/testnet/inverse_futures.html index 38e6744c1b..8d2a18662e 100644 --- a/zh-TW/testnet/inverse_futures.html +++ b/zh-TW/testnet/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/linear.html b/zh-TW/testnet/linear.html index edc98603fd..d2ed3c68fb 100644 --- a/zh-TW/testnet/linear.html +++ b/zh-TW/testnet/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/spot.html b/zh-TW/testnet/spot.html index cf423dd5b7..c22fe9e111 100644 --- a/zh-TW/testnet/spot.html +++ b/zh-TW/testnet/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/spot/v1.html b/zh-TW/testnet/spot/v1.html index a64a169b09..f36c5831a5 100644 --- a/zh-TW/testnet/spot/v1.html +++ b/zh-TW/testnet/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/spot/v3.html b/zh-TW/testnet/spot/v3.html index 4b7aca2e15..79510d84b9 100644 --- a/zh-TW/testnet/spot/v3.html +++ b/zh-TW/testnet/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/tax.html b/zh-TW/testnet/tax.html index 2c961aa983..681c05b5b7 100644 --- a/zh-TW/testnet/tax.html +++ b/zh-TW/testnet/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/usdc/option.html b/zh-TW/testnet/usdc/option.html index f8c943c925..a7558afa66 100644 --- a/zh-TW/testnet/usdc/option.html +++ b/zh-TW/testnet/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/testnet/usdc/perpetual.html b/zh-TW/testnet/usdc/perpetual.html index a9318c689b..afb0ba906e 100644 --- a/zh-TW/testnet/usdc/perpetual.html +++ b/zh-TW/testnet/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/usdc/option.html b/zh-TW/usdc/option.html index 3ebe668288..91cf2fffcd 100644 --- a/zh-TW/usdc/option.html +++ b/zh-TW/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/usdc/perpetual.html b/zh-TW/usdc/perpetual.html index b0e416647f..cd6a9dc9b7 100644 --- a/zh-TW/usdc/perpetual.html +++ b/zh-TW/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/v3/intro.html b/zh-TW/v3/intro.html index 7606c3aa6b..f5bdb21aea 100644 --- a/zh-TW/v3/intro.html +++ b/zh-TW/v3/intro.html @@ -4,7 +4,7 @@ 概覽 | Bybit API Documentation - + @@ -13,7 +13,7 @@ server_time - recv_window <= timestamp < server_time + 1000
    其中server_time是Bybit服務器時間,您可以通過Bybit服務器時間接口獲取.

    構建請求

    提示

    為了幫助診斷高級網絡問題,您可以考慮將cdn-request-id添加到您的請求頭中。對於每個請求,它的值應該是唯一的。.

    基本步驟:

    1. 時間戳 + api-key + [recv_window]+ [queryString(無需排序) | jsonBodyString]
    2. 使用HMAC_SHA256或者RSA_SHA256算法對第1步中拼接的string簽名,並轉換為16進製字符串(HMAC_SHA256) / Base64編碼 (RSA_SHA256),得出sign參數。
    3. 添加生成的簽名到HTTP頭當中 注意: GETPOST請求的加密明文是不相同,請參考以下示例.

    對明文加密的示例

    # 拼接規則:
    timestamp+api_key+recv_window+queryString

    # 明文
    "1658384314791XXXXXXXXXX5000category=option&symbol=BTC-29JUL22-25000-C"

    # 解析
    timestamp = "1658384314791"
    api_key = "XXXXXXXXXX"
    recv_window = "5000"
    queryString = "category=option&symbol=BTC-29JUL22-25000-C"

    http請求示例

    GET /unified/v3/private/order/list?category=option&symbol=BTC-29JUL22-25000-C HTTP/1.1
    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'

    外層通用數據結構

    衍生品

    參數類型說明
    retCodenumber成功/錯誤碼
    retMsgstring成功/錯誤消息. 成功消息可以是OK,success,SUCCESS
    resultObject業務數據體
    retExtInfoObject額外信息. 大部分場景下都是{}
    timenumber當前時間戳 (毫秒)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }

    現貨

    參數類型說明
    retCodenumber成功/錯誤碼
    retMsgstring成功/錯誤消息. 成功消息可以是OK,success,SUCCESS
    resultObject業務數據體
    retExtInfoObject額外信息. 大部分場景下都是{}
    timenumber當前時間戳 (毫秒)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }

    帳戶資產

    參數類型說明
    retCodenumber成功/錯誤碼
    retMsgstring成功/錯誤消息. 成功消息可以是OK,success,SUCCESS
    resultObject業務數據體
    retExtInfoObject額外信息. 大部分場景下都是{}
    timenumber當前時間戳 (毫秒)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017473888
    }

    {
    "retCode": 0,
    "retMsg": "Success",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017572923
    }
    - + \ No newline at end of file diff --git a/zh-TW/v3/server-time.html b/zh-TW/v3/server-time.html index 2d1e97e6c0..62cfdeed49 100644 --- a/zh-TW/v3/server-time.html +++ b/zh-TW/v3/server-time.html @@ -4,13 +4,13 @@ Bybit服務器時間 | Bybit API Documentation - +

    Bybit服務器時間

    獲取Bybit服務器時間

    HTTP 請求

    GET /v3/public/time

    請求參數

    響應參數

    參數類型說明
    timeSecondstringBybit服務器時間戳 (秒)
    timeNanostringBybit 服務器時間戳 (微秒)

    請求示例

    curl https://api-testnet.bybit.com/v3/public/time

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "timeSecond": "1674026082",
    "timeNano": "1674026082947745743"
    },
    "retExtInfo": {},
    "time": 1674026082947
    }
    - + \ No newline at end of file diff --git a/zh-TW/v3/smp.html b/zh-TW/v3/smp.html index f527f9d94f..8efb17aebb 100644 --- a/zh-TW/v3/smp.html +++ b/zh-TW/v3/smp.html @@ -4,7 +4,7 @@ 自成交攔截 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 基於這點,我們強烈建議在SMP交易群組發生變更時,最好取消所有現有訂單,以避免意外執行。

    1. SMP交易群組在SMP執行中具有較高優先級,當任何一方沒有群組時,UID才會生效。

    示例
    1月1日:UID1加入SMP交易群組A,並下訂單1;
    1月2日:UID1被從SMP交易群組A中移除,但訂單1仍然處於活躍狀態且為“新”狀態。

    • 情況1:如果UID1加入了SMP交易群組B並下了訂單2,如果訂單2與訂單1相符,它將被執行,因為它們屬於兩個不同的群組。
    • 情況2:如果UID1在被從SMP交易群組A中移除後沒有加入任何其他群組並下了訂單2,如果訂單2與訂單1相符,SMP將被觸發,因為UID1在下訂單2時沒有群組,所以SMP在UID級別(同一個UID1)被觸發。

    如何管理我的UID及SMP交易群組?

    您可以聯繫您的機構業務經理或通過電子郵件聯繫Bybit,電子郵件地址為: institutional_services@bybit.com

    支持的OpenAPI版本和產品線

    產品線支持的OpenAPI版本說明
    現貨V3 (普通帳戶)
    V5 (統一帳戶&普通帳戶)
    合約合約V3 (普通帳戶): USDT永續 / 反向永續&交割
    V5 (統一帳戶): USDT永續 / 反向永續&交割 / USDC永續 & 交割
    V5 (普通帳戶): USDT永續 / 反向永續 & 交割
    期權V5 (統一帳戶)V1有基於UID維度的SMP功能
    - + \ No newline at end of file diff --git a/zh-TW/v5/abandon/enable-unitransfer-subuid.html b/zh-TW/v5/abandon/enable-unitransfer-subuid.html index 4b6bd8ae49..efe098d385 100644 --- a/zh-TW/v5/abandon/enable-unitransfer-subuid.html +++ b/zh-TW/v5/abandon/enable-unitransfer-subuid.html @@ -4,13 +4,13 @@ 配置互相劃轉的子帳號 | Bybit API Documentation - +

    配置互相劃轉的子帳號

    信息

    無需再配置可劃轉的子帳號, 該限制已移除, 默認任意子帳號之間可以劃轉

    該接口用於配置開啟萬能劃轉的子帳號列表。沒有進行配置的子帳號是無法進行萬能劃轉的。

    提示

    萬能劃轉是允許您將資金直接從一個子帳號劃轉到另一個子帳號,同樣允許母子帳號間的劃轉。

    警告

    僅支持母帳號API key

    HTTP 請求

    POST /v5/asset/transfer/save-transfer-sub-member

    請求參數

    參數是否必需類型說明
    subMemberIdstruearray<string>子帳號. 支持輸入多個子帳號,用逗號隔開, 比如, "uid1,uid2,uid3"

    響應參數


    請求示例

    POST /v5/asset/transfer/save-transfer-sub-member HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672147595971
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subMemberIds": ["554117,592324,592334"]
    }

    Response Example

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {},
    "retExtInfo": {},
    "time": 1672147593188
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/abandon/ltv.html b/zh-TW/v5/abandon/ltv.html index 6b0fc56143..3b738de238 100644 --- a/zh-TW/v5/abandon/ltv.html +++ b/zh-TW/v5/abandon/ltv.html @@ -4,13 +4,13 @@ 查詢風險率 | Bybit API Documentation - +

    查詢風險率

    HTTP 請求

    GET /v5/ins-loan/ltv

    請求參數

    返回參數

    參數類型說明
    ltvInfoarrayObject
    > ltvstring風險率
    > parentUidstring用戶ID
    > subAccountUidsarray綁定的子UID
    > unpaidAmountstring總負債 (USDT)
    > unpaidInfoarray負債明細
    >> tokenstring幣種
    >> unpaidQtystring未還本金
    >> unpaidIntereststring未還利息
    > balancestring總資產(保證金幣種資產折算為USDT資產). 可以參考這裡了解詳細計算
    > spotBalanceInfoarray現貨資產明細
    >> tokenstring現貨保證金幣種
    >> pricestring現貨保證金幣種價格
    >> qtystring現貨保證金數量
    > contractInfoarray合約資產明細
    >> tokenstring合約保證金幣種
    >> pricestring合約保證金幣種指數價格
    >> qtystring合約保證金幣種數量 (合約可用餘額,不參與LTV計算)

    請求示例

    curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/margin-ltv' \
    --header 'X-BAPI-SIGN-TYPE: 2' \
    --header 'X-BAPI-API-KEY: XXXXXXXXXXX' \
    --header 'X-BAPI-TIMESTAMP: 1669367335035' \
    --header 'X-BAPI-RECV-WINDOW: 5000' \
    --header 'X-BAPI-SIGN: XXXXXXXX'

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.1147",
    "parentUid": "999805",
    "subAccountUids": [
    "999805"
    ],
    "unpaidAmount": "",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "6351.49614274",
    "unpaidInterest": "264.0137162"
    }
    ],
    "balance": "57626.875915433333333332400000000",
    "spotBalanceInfo": [
    {
    "token": "BTC",
    "price": "16375.621333333333333332",
    "qty": "0.2"
    },
    ....
    {
    "token": "XRP",
    "price": "0.409517",
    "qty": "10000"
    }
    ],
    "contractInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669367335608
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/abandon/margin-coin-info.html b/zh-TW/v5/abandon/margin-coin-info.html index 39c7bd9a1f..10681c187b 100644 --- a/zh-TW/v5/abandon/margin-coin-info.html +++ b/zh-TW/v5/abandon/margin-coin-info.html @@ -4,13 +4,13 @@ 查詢保證金幣種信息 | Bybit API Documentation - +

    查詢保證金幣種信息

    提示

    這是公共接口,無需鑒權。

    HTTP 請求

    GET /v5/ins-loan/ensure-tokens

    請求參數

    參數是否必須類型說明
    productIdfalsestring產品ID. 若不傳,則返回所有產品的保證金幣種信息. 現貨返回折算率大於0的幣種.

    返回參數

    參數類型說明
    marginTokenarrayObject
    > productIdstring產品ID
    > spotTokenarray現貨保證金幣種信息
    >> tokenstring保證金幣種
    >> convertRatiostring保證金幣種折算率
    > contractTokenarray合約保證金幣種信息
    >> tokenstring保證金幣種
    >> convertRatiostring保證金幣種折算率

    請求示例

    GET /v5/ins-loan/ensure-tokens?productId=70 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginToken": [
    {
    "productId": "70",
    "spotToken": [
    {
    "token": "BTC",
    "convertRatio": "1.00000000"
    },
    {
    "token": "ETH",
    "convertRatio": "1.00000000"
    },
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ],
    "contractToken": [
    {
    "token": "USDT",
    "convertRatio": "1"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669363954802
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/account-info.html b/zh-TW/v5/account/account-info.html index 37ebd05399..f8ebda2785 100644 --- a/zh-TW/v5/account/account-info.html +++ b/zh-TW/v5/account/account-info.html @@ -4,13 +4,13 @@ 查詢賬戶配置 | Bybit API Documentation - +

    查詢賬戶配置

    該接口可以查詢賬戶下的配置

    HTTP 請求

    GET /v5/account/info

    請求參數

    響應參數

    參數類型說明
    unifiedMarginStatusinteger帳戶狀態類型
    marginModestringISOLATED_MARGIN(逐倉保證金), REGULAR_MARGIN(全倉保證金) PORTFOLIO_MARGIN(組合保證金)
    dcpStatusstring設置斷線保護時間 開關狀態: ON, OFF
    timeWindowinteger設置的DCP觸發時間窗口. 範圍為[3, 300] 秒, 默認: 10 秒
    smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    isMasterTraderboolean是否為帶單帳戶. true, false
    updatedTimestring賬戶數據更新的時間,毫秒時間戳

    請求示例

    GET /v5/account/info HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672129307221
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "marginMode": "REGULAR_MARGIN",
    "updatedTime": "1665645428000",
    "unifiedMarginStatus": 1,
    "dcpStatus": "ON",
    "timeWindow": 15,
    "smpGroup": 0,
    "isMasterTrader": false
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/borrow-history.html b/zh-TW/v5/account/borrow-history.html index 450a6dd0f8..d8f1a09c08 100644 --- a/zh-TW/v5/account/borrow-history.html +++ b/zh-TW/v5/account/borrow-history.html @@ -4,13 +4,13 @@ 查詢利息記錄 | Bybit API Documentation - +

    查詢利息記錄

    獲取利息記錄,按照創建時間倒敘排列。

    HTTP 請求

    GET /v5/account/borrow-history

    請求參數

    參數是否必需類型說明
    currencyfalsestringUSDC、USDT、BTC、ETH
    startTimefalseinteger開始時間 (毫秒)
    endTimefalseinteger結束時間 (毫秒)
    limitfalseinteger每頁數量, 最大50. 默認每頁20條
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > currencystringUSDC、USDT、BTC、ETH
    > createdTimeinteger時間戳(毫秒)
    > borrowCoststring利息
    > hourlyBorrowRatestring利率
    > InterestBearingBorrowSizestring豁免利息額度
    > costExemptionstring豁免計息成本
    > borrowAmountstring當前總借貸
    > unrealisedLossstring浮動虧損
    > freeBorrowedAmountstring借款中免息的數額
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/account/borrow-history?currency=BTC&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672277745427
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "2671153%3A1%2C2671153%3A1",
    "list": [
    {
    "borrowAmount": "1.06333265702840778",
    "costExemption": "0",
    "freeBorrowedAmount": "0",
    "createdTime": 1697439900204,
    "InterestBearingBorrowSize": "1.06333265702840778",
    "currency": "BTC",
    "unrealisedLoss": "0",
    "hourlyBorrowRate": "0.000001216904",
    "borrowCost": "0.00000129"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1697442206478
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/coin-greeks.html b/zh-TW/v5/account/coin-greeks.html index 06deafb6f5..42bf53eee9 100644 --- a/zh-TW/v5/account/coin-greeks.html +++ b/zh-TW/v5/account/coin-greeks.html @@ -4,13 +4,13 @@ 查詢Greeks信息 | Bybit API Documentation - +

    查詢Greeks信息

    獲取當前賬戶Greeks信息

    HTTP 請求

    GET /v5/asset/coin-greeks

    請求參數

    參數是否必需類型類型
    baseCoinfalsestringbaseCoin- 不傳入,默認返回全部baseCoin的greeks

    響應參數

    參數類型類型
    listarrayObject
    > baseCoinstringbaseCoin,例如:BTC、ETH、SOL etc
    > totalDeltastringDelta值
    > totalGammastringGamma值
    > totalVegastringVega值
    > totalThetastringTheta值

    請求示例

    GET /v5/asset/coin-greeks?baseCoin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672287887610
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "baseCoin": "BTC",
    "totalDelta": "0.00004001",
    "totalGamma": "-0.00000009",
    "totalVega": "-0.00039689",
    "totalTheta": "0.01243824"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672287887942
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/collateral-info.html b/zh-TW/v5/account/collateral-info.html index ccf3450574..cacd30a1aa 100644 --- a/zh-TW/v5/account/collateral-info.html +++ b/zh-TW/v5/account/collateral-info.html @@ -4,13 +4,13 @@ 查詢抵押品信息 | Bybit API Documentation - +

    查詢抵押品信息

    獲取當前統一保證金賬戶的抵押品信息,包括借貸利率,可藉貸金額以及抵押品折算率,是否可抵押作為保證金等信息。

    HTTP 請求

    GET /v5/account/collateral-info

    請求參數

    參數是否必需類型說明
    currencyfalsestring目前所有抵押品的資產幣種

    響應參數

    參數類型說明
    listarrayObject
    > currencystring目前所有抵押品的資產幣種
    > hourlyBorrowRatestring每小時藉款利率
    > maxBorrowingAmountstring最大可藉貸額度. 該值由母子帳號共享
    > freeBorrowingLimitstring免息借款額上限
    > freeBorrowAmountstring借款總額中免息部分的借款金額
    > borrowAmountstring已用借貸額度
    > availableToBorrowstring用戶剩餘可藉額度. 該值由母子帳號共享
    > borrowableboolean是否是可藉貸的幣種, true: 是. false: 否
    > freeBorrowingAmountstring廢棄字段, 總是返回空字符串, 請參考freeBorrowingLimit
    > borrowUsageRatestring借貸資金使用率: borrowAmount/maxBorrowingAmount. 這是一個真實值, 即區間為 0 到 1
    > marginCollateralboolean是否可作為保證金抵押幣種(平台維度), true: 是. false: 否
  • 當marginCollateral=false時, 則collateralSwitch無意義
  • > collateralSwitchboolean用戶是否開啟保證金幣種抵押(用戶維度), true: 是. false: 否
  • 僅當marginCollateral=true時, 才能主動選擇開關抵押
  • > collateralRatiostring抵押品幣種折算為保證金的折算率

    請求示例

    GET /v5/account/collateral-info?currency=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672127952719
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "availableToBorrow": "3",
    "freeBorrowingAmount": "",
    "freeBorrowAmount": "0",
    "maxBorrowingAmount": "3",
    "hourlyBorrowRate": "0.00000147",
    "borrowUsageRate": "0",
    "collateralSwitch": true,
    "borrowAmount": "0",
    "borrowable": true,
    "currency": "BTC",
    "marginCollateral": true,
    "freeBorrowingLimit": "0",
    "collateralRatio": "0.95"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1691565901952
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/fee-rate.html b/zh-TW/v5/account/fee-rate.html index 378a2ae8c5..38d9d4523b 100644 --- a/zh-TW/v5/account/fee-rate.html +++ b/zh-TW/v5/account/fee-rate.html @@ -4,13 +4,13 @@ 查詢手續費率 | Bybit API Documentation - +

    查詢手續費率

    查詢交易手續費率。

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向永續 / 反向交割 / 期權

    HTTP 請求

    GET /v5/account/fee-rate

    參數是否必需類型說明
    categorytruestring產品類型. spot, linear, inverse, option
    symbolfalsestring合約名稱. 僅spot, linear, inverse有效
    baseCoinfalsestring交易幣種. SOL, BTC, ETH.僅option有效

    響應參數

    參數類型說明
    categorystring產品類型. spot, option. 期貨不返回該字段
    listarrayObject
    > symbolstring合約名稱. 期權總是為""
    > baseCoinstring交易幣種. SOL, BTC, ETH
    • 期貨不返回該字段
    • 現貨總是返回""
    > takerFeeRatestring吃單手續費率
    > makerFeeRatestring掛單手續費率

    請求示例

    GET /v5/account/fee-rate?symbol=ETHUSDT HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXXX
    X-BAPI-API-KEY: XXXXXXX
    X-BAPI-TIMESTAMP: 1676360412362
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "ETHUSDT",
    "takerFeeRate": "0.0006",
    "makerFeeRate": "0.0001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676360412576
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/get-mmp-state.html b/zh-TW/v5/account/get-mmp-state.html index b593b50cde..73ac61c91f 100644 --- a/zh-TW/v5/account/get-mmp-state.html +++ b/zh-TW/v5/account/get-mmp-state.html @@ -4,13 +4,13 @@ 查詢市商保護配置信息 | Bybit API Documentation - +

    查詢市商保護配置信息

    HTTP 請求

    GET /v5/account/mmp-state

    請求參數

    參數是否必需類型說明
    baseCointruestringBase coin

    響應參數

    參數類型說明
    resultarrayObject
    > baseCoinstring交易幣種
    > mmpEnabledboolean帳戶是否開啟了mmp
    > windowstring時間窗口 (毫秒)
    > frozenPeriodstring凍結時間長度 (毫秒)
    > qtyLimitstring成交數量上限
    > deltaLimitstringDelta值上限
    > mmpFrozenUntilstring解凍時間戳 (毫秒)
    > mmpFrozenboolean當前是否觸發了mmp凍結.
    • true: mmpFrozenUntil的值有意義
    • false: 請忽略mmpFrozenUntil字段的值

    請求示例

    POST /v5/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "result": [
    {
    "baseCoin": "BTC",
    "mmpEnabled": true,
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "0.01",
    "deltaLimit": "0.01",
    "mmpFrozenUntil": "1675760625519",
    "mmpFrozen": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675843188984
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/reset-mmp.html b/zh-TW/v5/account/reset-mmp.html index ec15d88548..2595fc5f00 100644 --- a/zh-TW/v5/account/reset-mmp.html +++ b/zh-TW/v5/account/reset-mmp.html @@ -4,13 +4,13 @@ 重置市商保護凍結 | Bybit API Documentation - +

    重置市商保護凍結

    信息
    • 一旦mmp被觸發, 您的帳戶可以調用該接口進行主動解凍, 解凍後, qtyLimitdeltaLimit就重置為0.
    • 若帳戶沒有被凍結, 該重置接口能夠清除之前的交易, 即不計算重置前發生的總數量和淨交易delta, qtyLimitdeltaLimit就重置為0.

    HTTP 請求

    POST /v5/account/mmp-reset

    請求參數

    參數是否必需類型說明
    baseCointruestring交易幣種

    響應參數

    請求示例

    POST /v5/account/mmp-reset HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675842997277
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "baseCoin": "ETH"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/set-collateral.html b/zh-TW/v5/account/set-collateral.html index 5fe713397a..7fd7fb0ea9 100644 --- a/zh-TW/v5/account/set-collateral.html +++ b/zh-TW/v5/account/set-collateral.html @@ -4,13 +4,13 @@ 設置抵押品幣種 | Bybit API Documentation - +

    設置抵押品幣種

    用戶可以自行決定是否開啟統一帳戶中幣種是否進行抵押,默認都是開啟

    HTTP 請求

    POST /v5/account/set-collateral-switch

    請求參數

    參數類型說明默認值
    cointruestring幣種名稱
    • 您可以從這裡獲取抵押品幣種
    • USDT, USDC不支持關閉抵押狀態
    collateralSwitchtruestringON: 開啟抵押, OFF: 關閉抵押

    響應參數

    請求示例

    POST /v5/account/set-collateral-switch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1690513916181
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 55

    {
    "coin": "BTC",
    "collateralSwitch": "ON"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "result": {},
    "retExtInfo": {},
    "time": 1690515818656
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/set-margin-mode.html b/zh-TW/v5/account/set-margin-mode.html index e9dbd7a815..9af1fddb64 100644 --- a/zh-TW/v5/account/set-margin-mode.html +++ b/zh-TW/v5/account/set-margin-mode.html @@ -4,13 +4,13 @@ 設置保證金模式(帳戶) | Bybit API Documentation - +

    設置保證金模式(帳戶)

    用戶如果不設置,默認按全倉保證金

    信息
    • UTA帳戶支持切換三種帳戶維度的保證金模式, 對USDT永續, USDC永續, USDC交割以及期權有效 (其中, 期權不支持逐倉保證金模式)
    • 普通帳戶支持切換全倉保證金模式和組合保證金模式, 但僅作用於USDC永續和期權

    HTTP 請求

    POST /v5/account/set-margin-mode

    請求參數

    參數是否必需類型說明
    setMarginModetruestringISOLATED_MARGIN(逐倉保證金模式), REGULAR_MARGIN(全倉保證金模式)PORTFOLIO_MARGIN(組合保證金模式)默認常規,傳常規則返回設置成功

    響應參數

    參數類型說明
    reasonsarrayObject. 若請求提交成功, 則返回空數組
    > reasonCodestring失敗錯誤碼
    > reasonMsgstring失敗錯誤消息

    請求示例

    POST /v5/account/set-margin-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672134396332
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "setMarginMode": "PORTFOLIO_MARGIN"
    }

    響應示例

    {
    "retCode": 3400045,
    "retMsg": "Set margin mode failed",
    "result": {
    "reasons": [
    {
    "reasonCode": "3400000",
    "reasonMsg": "Equity needs to be equal to or greater than 1000 USDC"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/set-mmp.html b/zh-TW/v5/account/set-mmp.html index a9b408d5e6..bd52f7217a 100644 --- a/zh-TW/v5/account/set-mmp.html +++ b/zh-TW/v5/account/set-mmp.html @@ -4,7 +4,7 @@ 设置市商保護 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 在短時間內的總交易額超過了配置的限額,該賬戶的做市商保護將被觸發。當做市商保護被觸發時,賬戶現有的做市商保護訂單(被標記為做市商保護的訂單)將被 交易引擎自動取消,而該賬戶新的做市商保護訂單將在未來一段時間(稱為凍結期)被拒絕(常規非MMP訂單不受影響)。用戶可以利用這段時間重新評估行情並修改報價。

    如何開通MMP

    您可通過郵件Bybit【financial.inst@bybit.com】或聯繫對應的客戶經理申請開通。 開通後,MMP的默認配置為:

    參數類型說明默認值
    baseCoinstring交易幣種BTC
    windowstring時間窗口 (毫秒)5000
    frozenPeriodstring凍結時間段 (毫秒)100
    qtyLimitstring成交數量上限100
    deltaLimitstringDelta值上限100

    適用對象

    僅適用於期權交易. 當創建期權訂單時, 設置參數mmp=true, 則表示將此訂單納入市商保護。

    HTTP 請求

    POST /v5/account/mmp-modify

    請求參數

    參數是否必需類型說明
    baseCointruestring交易幣種
    windowtruestring時間窗口 (毫秒)
    frozenPeriodtruestring凍結時間長度 (毫秒). 設置為"0"則表示帳戶會保持凍結狀態,除非手動重置
    qtyLimittruestring成交數量上限 (正數,至多2位小數)
    deltaLimittruestringDelta上限 (正數,至多2位小數)

    響應參數

    請求示例

    POST /v5/account/mmp-modify HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675833524616
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "baseCoin": "ETH",
    "window": "5000",
    "frozenPeriod": "100000",
    "qtyLimit": "50",
    "deltaLimit": "20"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/transaction-log.html b/zh-TW/v5/account/transaction-log.html index 326663cdef..3f993b6a6d 100644 --- a/zh-TW/v5/account/transaction-log.html +++ b/zh-TW/v5/account/transaction-log.html @@ -4,13 +4,13 @@ 交易日誌 | Bybit API Documentation - +

    交易日誌

    整個賬戶的交易日誌。

    HTTP 請求

    GET /v5/account/transaction-log

    請求參數

    參數是否必需類型說明
    accountTypefalsestring錢包類型. 目前僅支持UNIFIED
    categoryfalsestring交易產品類型. spot:現貨;linear:USDT永續, USDC永續, USDC交割;option:期權
    currencyfalsestring貨幣
    baseCoinfalsestring交易幣種. 例如: BTCUSDT 的 baseCoin 是 BTC
    typefalsestring交易日誌的類型
    startTimefalseinteger開始時間, 毫秒時間戳
    endTimefalseinteger結束時間, 毫秒時間戳
    limitfalseinteger每頁數量, 最大50. 默認每頁20條
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > idstring唯一id
    > symbolstring合約名稱
    > categorystring產品類型
    > sidestring方向. Buy,Sell,None
    > transactionTimestring交易時間戳(毫秒)
    > typestring類型
    > qtystring數量. 特別地, 對於成交的流水來說, 這裡的qty表示每筆成交的數量, 不帶方向
    > sizestring倉位. 特別地, 對於成交的流水來說, 這裡的size表示成交後的倉位大小, 帶有方向, 比如空倉, 則有"-"
    > currencystringUSDC、USDT、BTC、ETH
    > tradePricestring交易價格
    > fundingstring資金費用. 正數表示用戶收取xx資金費,負數表示用戶支出xx資金費
    > feestring手續費,正數表示用戶付出xx手續費,負數表示返佣
    > cashFlowstring現金流, 比如平倉時的未平盈虧結算, USDC永續和交割合約的8小時結算, 以及劃入劃出等. 該值不包含任何手續費或者資金費
    > changestring變更 = cashFlow + funding - fee
    > cashBalancestring餘額(當前幣種), 資金流發生後的該幣種的錢包餘額
    > feeRatestring
    • 對於type=TRADE, 則表示交易手續費率
    • 對於type=SETTLEMENT, 則表示資金費率. 當side=Buy, feeRate=市場結算費率; 當side=Sell, feeRate=-市場結算費率
    > bonusChangestring體驗金的變化
    > tradeIdstring交易id
    > orderIdstring訂單id
    > orderLinkIdstring用戶自定義訂單id
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/account/transaction-log?accountType=UNIFIED&category=linear&currency=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672132480085
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21963%3A1%2C14954%3A1",
    "list": [
    {
    "id": "592324_XRPUSDT_161440249321",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "-0.003676",
    "orderLinkId": "",
    "orderId": "1672128000-8-592324-1-2",
    "fee": "0.00000000",
    "change": "-0.003676",
    "cashFlow": "0",
    "transactionTime": "1672128000000",
    "type": "SETTLEMENT",
    "feeRate": "0.0001",
    "bonusChange": "",
    "size": "100",
    "qty": "100",
    "cashBalance": "5086.55825002",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3676",
    "tradeId": "534c0003-4bf7-486f-aa02-78cee36825e4"
    },
    {
    "id": "592324_XRPUSDT_161440249321",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "linear-order",
    "orderId": "592b7e41-78fd-42e2-9aa3-91e1835ef3e1",
    "fee": "0.01908720",
    "change": "-0.0190872",
    "cashFlow": "0",
    "transactionTime": "1672121182224",
    "type": "TRADE",
    "feeRate": "0.0006",
    "bonusChange": "-0.1430544",
    "size": "100",
    "qty": "88",
    "cashBalance": "5086.56192602",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3615",
    "tradeId": "5184f079-88ec-54c7-8774-5173cafd2b4e"
    },
    {
    "id": "592324_XRPUSDT_161407743011",
    "symbol": "XRPUSDT",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "linear-order",
    "orderId": "592b7e41-78fd-42e2-9aa3-91e1835ef3e1",
    "fee": "0.00260280",
    "change": "-0.0026028",
    "cashFlow": "0",
    "transactionTime": "1672121182224",
    "type": "TRADE",
    "feeRate": "0.0006",
    "bonusChange": "",
    "size": "12",
    "qty": "12",
    "cashBalance": "5086.58101322",
    "currency": "USDT",
    "category": "linear",
    "tradePrice": "0.3615",
    "tradeId": "8569c10f-5061-5891-81c4-a54929847eb3"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672132481405
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/upgrade-unified-account.html b/zh-TW/v5/account/upgrade-unified-account.html index 5379285fd2..c702542f01 100644 --- a/zh-TW/v5/account/upgrade-unified-account.html +++ b/zh-TW/v5/account/upgrade-unified-account.html @@ -4,7 +4,7 @@ 升級統一保證金賬戶 | Bybit API Documentation - + @@ -14,7 +14,7 @@ 查詢賬戶配置接口來確認是否unifiedMarginStatus=3, 如果是的, 則可以開始第二次請求, 當您看見unifiedMarginStatus=4, 則表面帳戶被升級到了UTA Pro.

  • 如果unifiedMarginStatus=3, 則表示當前帳戶是統一交易帳戶 (UTA), 您可以調用以下接口升級到UTA Pro. 等到調用升級接口後一段時間, 重新調用查詢賬戶配置接口, 如果unifiedMarginStatus=4, 則表示帳戶已經成功升級至UTA Pro.

  • important

    封禁 / 極簡鏈路用戶當前無法升級至統一帳戶.

    信息

    您現在可以持倉完成升級了,但請注意以下事項:

    1. 升級請避開以下時段:
    每個小時當前時間在小時整點的前10分鐘及後5分鐘內
    1. 為保證順利升級,請確保:
    • 當前現貨帳戶內無任何掛單或負債
    • 在合約帳戶內無任何掛單,並且確保所有USDT永續倉位要麼逐倉要麼全倉
    • 在USDC合約帳戶無任何掛單
    • 注意,倉位附帶的止盈止損單也屬於掛單
    1. 帳戶升級實時返回的unifiedUpgradeProcess為PROCESS時,代表需要系統異步校驗處理,無法實時返回升級結果,您可在3-5分鐘後通過查詢API Key相關信息 接口,根據返回中的"uta"字段確認是否升級成功

    2. 帳戶升級過程中,可能會由於帳戶相關資產數據處於處理狀態中導致查詢/推送的數據不準確,建議在完成升級後,再查詢和使用。

    HTTP 請求

    POST /v5/account/upgrade-to-uta

    請求參數

    響應參數

    ParameterTypeComments
    unifiedUpdateStatusstring用戶賬戶的升級狀態. PROCESS: 處理中, FAIL: 失敗, SUCCESS: 成功
    unifiedUpdateMsgObject若是PROCESS,SUCCESS,則返回null
    msgarray錯誤原因列表. 只有FAIL時,才會有msg這個字段

    請求示例

    POST /v5/account/upgrade-to-uta HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672125123533
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {}

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "unifiedUpdateStatus": "FAIL",
    "unifiedUpdateMsg": {
    "msg": [
    "Update account failed. You have outstanding liabilities in your Spot account.",
    "Update account failed. Please close the usdc perpetual positions in USDC Account.",
    "unable to upgrade, please cancel the usdt perpetual open orders in USDT account.",
    "unable to upgrade, please close the usdt perpetual positions in USDT account."
    ]
    }
    },
    "retExtInfo": {},
    "time": 1672125124195
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/account/wallet-balance.html b/zh-TW/v5/account/wallet-balance.html index 52dbd96f10..7843a58889 100644 --- a/zh-TW/v5/account/wallet-balance.html +++ b/zh-TW/v5/account/wallet-balance.html @@ -4,13 +4,13 @@ 查詢錢包餘額 | Bybit API Documentation - +

    查詢錢包餘額

    獲取統一帳戶和普通帳戶錢包餘額, 查詢各個幣種的資產信息,以及統一保證金模式下的帳戶風險率信息。默認不返回資產或負債為0的幣種信息。

    提示
    • UTA交易反向合約是通過該帳戶下的CONTRACT錢包進行
    • 請使用該接口查詢資金帳戶的餘額

    HTTP 請求

    GET /v5/account/wallet-balance

    請求參數

    參數是否必需類型說明
    accountTypetruestring帳戶類型.
    • 統一帳戶: UNIFIED(現貨/USDT和USDC永續/期權), CONTRACT(反向)
    • 普通帳戶: CONTRACT(期貨), SPOT(現貨)
    coinfalsestring幣種名稱
    • 不傳則返回非零資產信息
    • 可以傳多個幣進行查詢,以逗號分隔, USDT,USDC

    響應參數

    參數類型說明
    listarrayObject
    > accountTypestring帳戶類型
    > accountLTVstring帳戶LTV: account total borrowed size / (account total equity + account total borrowed size). 非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > accountIMRatestring帳戶初始保證金率: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin. 非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > accountMMRatestring帳戶維持保證金率: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalEquitystring總凈值為賬戶中每個幣種資產凈值的法幣估值之和。。非統一保證金模式以及統一帳戶(反向)下,該字段返回為空。
    > totalWalletBalancestring賬戶維度換算成usd的產錢包餘額:∑ Asset Wallet Balance By USD value of each asset。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalMarginBalancestring賬戶維度換算成usd的保證金餘額:totalWalletBalance + totalPerpUPL。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalAvailableBalancestring賬戶維度換算成usd的可用餘額:RM:totalMarginBalance - totalInitialMargin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalPerpUPLstring賬戶維度換算成usd的永續和USDC交割合約的浮動盈虧:∑ Each perp and USDC Futures upl by base coin。非統一保證金模式以及統一帳戶(反向)下,該字段返回為空。
    > totalInitialMarginstring賬戶維度換算成usd的總初始保證金:∑ Asset Total Initial Margin Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalMaintenanceMarginstring賬戶維度換算成usd的總維持保證金: ∑ Asset Total Maintenance Margin Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > coinarrays幣種列表
    >> coinstring幣種名稱,例如 BTC,ETH,USDT,USDC
    >> equitystring當前幣種的資產淨值
    >> usdValuestring當前幣種折算成 usd 的價值,如果該幣種不能作為保證金的抵押品,則該數值為0
    >> walletBalancestring當前幣種的錢包餘額
    >> freestring普通帳戶現貨錢包的可用餘額. 普通帳戶現貨錢包的獨有字段
    >> lockedstring現貨掛單凍結金額
    >> borrowAmountstring當前幣種的已用借貸額度
    >> availableToBorrowstring由於母子共享借貸限額, 該字段已廢棄, 總是返回"". 請通過查詢抵押品信息接口查詢availableToBorrow
    >> availableToWithdrawstring當前幣種的可劃轉提現金額
    >> accruedIntereststring當前幣種的預計要在下一個利息週期收取的利息金額
    >> totalOrderIMstring以當前幣種結算的訂單委託預佔用保證金. 組合保證金模式下,該字段返回空字符串
    >> totalPositionIMstring以當前幣種結算的所有倉位起始保證金求和 + 所有倉位的預佔用平倉手續費. 組合保證金模式下,該字段返回空字符串
    >> totalPositionMMstring以當前幣種結算的所有倉位維持保證金求和. 組合保證金模式下,該字段返回空字符串
    >> unrealisedPnlstring以當前幣種結算的所有倉位的未結盈虧之和
    >> cumRealisedPnlstring以當前幣種結算的所有倉位的累計已結盈虧之和
    >> bonusstring體驗金. UNIFIED帳戶的獨有字段
    >> marginCollateralboolean是否可作為保證金抵押幣種(平台維度), true: 是. false: 否
    • 當marginCollateral=false時, 則collateralSwitch無意義
    • UNIFIED帳戶的獨有字段
    >> collateralSwitchboolean用戶是否開啟保證金幣種抵押(用戶維度), true: 是. false: 否
    • 僅當marginCollateral=true時, 才能主動選擇開關抵押
    • UNIFIED帳戶的獨有字段

    請求示例

    GET /v5/account/wallet-balance?accountType=UNIFIED&coin=BTC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672125440406
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "totalEquity": "18070.32797922",
    "accountIMRate": "0.0101",
    "totalMarginBalance": "18070.32797922",
    "totalInitialMargin": "182.60183684",
    "accountType": "UNIFIED",
    "totalAvailableBalance": "17887.72614237",
    "accountMMRate": "0",
    "totalPerpUPL": "-0.11001349",
    "totalWalletBalance": "18070.43799271",
    "accountLTV": "0.017",
    "totalMaintenanceMargin": "0.38106773",
    "coin": [
    {
    "availableToBorrow": "3",
    "bonus": "0",
    "accruedInterest": "0",
    "availableToWithdraw": "0",
    "totalOrderIM": "0",
    "equity": "0",
    "totalPositionMM": "0",
    "usdValue": "0",
    "unrealisedPnl": "0",
    "collateralSwitch": true,
    "borrowAmount": "0.0",
    "totalPositionIM": "0",
    "walletBalance": "0",
    "cumRealisedPnl": "0",
    "locked": "0",
    "marginCollateral": true,
    "coin": "BTC"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672125441042
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/announcement.html b/zh-TW/v5/announcement.html index e4433ed58b..b7b65f6ae5 100644 --- a/zh-TW/v5/announcement.html +++ b/zh-TW/v5/announcement.html @@ -4,13 +4,13 @@ 查詢公告 | Bybit API Documentation - +

    查詢公告

    HTTP 請求

    GET /v5/announcements/index

    請求參數

    參數是否必需類型說明
    localetruestring公告語言標識
    typefalsestring公告類型
    tagfalsestring公告標籤
    pagefalseinteger分頁頁碼. 默認: 1
    limitfalseinteger每頁數據限制. 默認: 20

    響應參數

    參數類型說明
    totalinteger可查詢公告總署
    listarrayObject
    > titlestring公告標題
    > descriptionstring公告描述
    > typeObject
    >> titlestring公告類型名稱,多語言
    >> keystring公告類型唯一鍵
    > tagsarray<string>公告標籤
    > urlstring公告鏈結
    > dateTimestampnumber公告發佈時間戳 (毫秒)
    > startDataTimestampnumber事件開始時間戳 (毫秒), 僅當list.type.key == "latest_activities"時有效
    > endDataTimestampnumber事件結束時間戳 (毫秒), 僅當list.type.key == "latest_activities"時有效

    請求示例

    GET /v5/announcements/index?locale=zh-TW&limit=1 HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "total": 569,
    "list": [
    {
    "title": "Arbitrum(ARB) 即將上線:儲值 250 ARB 即賺 25 USDT,更可解鎖 150,000 USDT 獎池!",
    "description": "好消息! ARB 即將上線 Bybit 交易平台!",
    "type": {
    "title": "新幣上線",
    "key": "new_crypto"
    },
    "tags": [
    "Spot",
    "Spot Listings"
    ],
    "url": "https://announcements.bybit.com/zh-TW/article/new-listing-arbitrum-arb-deposit-250-arb-to-earn-25-usdt-share-a-150-000-usdt-prize-pool--bltf662314c211a8616/",
    "dateTimestamp": 1679045608000,
    "startDateTimestamp": 1679564008000,
    "endDateTimestamp": 1680255208000
    }
    ]
    },
    "retExtInfo": {},
    "time": 1679416172335
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/account-coin-balance.html b/zh-TW/v5/asset/account-coin-balance.html index 4446340f64..4da2624bc6 100644 --- a/zh-TW/v5/asset/account-coin-balance.html +++ b/zh-TW/v5/asset/account-coin-balance.html @@ -4,14 +4,14 @@ 查詢帳戶單個幣種餘額 | Bybit API Documentation - +

    查詢帳戶單個幣種餘額

    獲取某帳戶類型下某指定幣種的餘額。支持通過輸入子帳戶id來查詢子帳戶的某個帳戶類型下的某個幣種餘額 同時, 支持查詢母子帳戶、子子帳戶、子母帳戶之間的可劃轉金額,特別是針對於擁有機構借貸的用戶。

    警告
    • 無法通過子賬戶api key獲取主賬戶帳戶餘額
    • 子帳戶只能查詢本身的餘額
    • 母帳戶支持本身和它的子帳戶的餘額

    HTTP 請求

    GET /v5/asset/transfer/query-account-coin-balance

    請求參數

    參數是否必需類型說明
    memberIdfalsestring用戶Id. 當查詢子帳號的餘額時,該字段必傳
    toMemberIdfalsestring劃入帳戶UID. 當查詢不同uid間劃轉時, 該字段必傳
    accountTypetruestring帳戶類型
    toAccountTypefalsestring劃入帳戶類型. 當查詢不同帳戶類型間的劃轉時, 該字段必傳
    cointruestring幣種
    withBonusfalseinteger是否查詢體驗金. 0(默認): 不查詢,1: 查詢.
    withTransferSafeAmountfalseinteger是否查詢延遲提幣安全限額
    withLtvTransferSafeAmountfalseinteger特別用於機構借貸用戶, 可以查詢風險水平內的可劃轉餘額
    • 0(default):false, 1:true
    • 此時toAccountType字段必傳

    響應參數

    參數類型說明
    accountTypestring賬戶類型
    bizTypeinteger帳戶業務子類型
    accountIdstring賬戶ID
    memberIdstring用戶ID
    balanceObject
    > coinstring幣種類型
    > walletBalancestring錢包余額
    > transferBalancestring可划余額
    > bonusstring可用金額中包含的体验金
    > transferSafeAmountstring可劃轉的安全限額. 若不查詢,則返回""
    > ltvTransferSafeAmountstring機構借貸用戶的可劃轉餘額. 若不查詢,則返回""

    請求示例

    GET /v5/asset/transfer/query-account-coin-balance?accountType=UNIFIED&coin=USDT&toAccountType=FUND&withLtvTransferSafeAmount=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: xxxxx
    X-BAPI-API-KEY: xxxxx
    X-BAPI-TIMESTAMP: 1690254520644
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "accountType": "UNIFIED",
    "bizType": 1,
    "accountId": "1631385",
    "memberId": "1631373",
    "balance": {
    "coin": "USDT",
    "walletBalance": "11999",
    "transferBalance": "11999",
    "bonus": "0",
    "transferSafeAmount": "",
    "ltvTransferSafeAmount": "7602.4861"
    }
    },
    "retExtInfo": {},
    "time": 1690254521256
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/all-balance.html b/zh-TW/v5/asset/all-balance.html index 2617948d50..8179c9e7ca 100644 --- a/zh-TW/v5/asset/all-balance.html +++ b/zh-TW/v5/asset/all-balance.html @@ -4,13 +4,13 @@ 查詢賬戶所有幣種余額 | Bybit API Documentation - +

    查詢賬戶所有幣種余額

    支持查詢母帳戶的各個帳戶類型的幣種餘額,以及母帳戶下各子帳戶的各個帳戶類型的幣種餘額。

    重要

    無法通過子賬戶api key獲取主賬戶的帳戶餘額

    HTTP 請求

    GET /v5/asset/transfer/query-account-coins-balance

    請求參數

    參數是否必須類型說明
    memberIdfalsestring用戶ID. 當使用母帳號api key查詢子帳戶的幣種餘額時,該字段必傳
    accountTypetruestring賬戶類型
    coinfalsestring幣種類型
    withBonusfalseinteger是否查詢體驗金. 0(默認):不查詢; 1:查詢

    返回參數

    參數類型說明
    accountTypestring賬戶類型
    memberIdstring用戶ID
    balanceObject
    > coinstring幣種類型
    > walletBalancestring錢包余額
    > transferBalancestring可划余額
    > bonusstring体验金

    請求示例

    GET /v5/asset/transfer/query-account-coins-balance?accountType=FUND&coin=USDC HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675866354698
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "memberId": "533285",
    "accountType": "FUND",
    "balance": [
    {
    "coin": "USDT",
    "transferBalance": "1010",
    "walletBalance": "1010",
    "bonus": ""
    },
    {
    "coin": "USDC",
    "transferBalance": "0",
    "walletBalance": "0",
    "bonus": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1675865290069
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/asset-info.html b/zh-TW/v5/asset/asset-info.html index c3e8bbf776..85754e40ee 100644 --- a/zh-TW/v5/asset/asset-info.html +++ b/zh-TW/v5/asset/asset-info.html @@ -4,13 +4,13 @@ 查詢資產信息 | Bybit API Documentation - +

    查詢資產信息

    信息

    當前只能查詢現貨帳戶中的資產

    HTTP 請求

    GET /v5/asset/transfer/query-asset-info

    請求參數

    參數是否必需類型說明
    accountTypetruestring賬戶類型. 僅SPOT
    coinfalsestring幣種

    響應參數

    參數類型說明
    spotObject
    > statusstring賬戶狀態. ACCOUNT_STATUS_NORMAL: 正常, ACCOUNT_STATUS_UNSPECIFIED: 禁用
    > assetsarrayObject
    >> coinstring幣種
    >> frozenstring掛單凍結金額
    >> freestring可用余額
    >> withdrawstring提現中金額

    請求示例

    GET /v5/asset/transfer/query-asset-info?accountType=SPOT&coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672136538042
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "spot": {
    "status": "ACCOUNT_STATUS_NORMAL",
    "assets": [
    {
    "coin": "ETH",
    "frozen": "0",
    "free": "11.53485",
    "withdraw": ""
    }
    ]
    }
    },
    "retExtInfo": {},
    "time": 1672136539127
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/cancel-withdraw.html b/zh-TW/v5/asset/cancel-withdraw.html index 9f70271088..3a2c483ec6 100644 --- a/zh-TW/v5/asset/cancel-withdraw.html +++ b/zh-TW/v5/asset/cancel-withdraw.html @@ -4,13 +4,13 @@ 撤銷提幣 | Bybit API Documentation - +

    撤銷提幣

    警告

    僅支持母帳號API key

    HTTP 請求

    POST /v5/asset/withdraw/cancel

    請求參數

    參數是否必需類型說明
    idtruestring提現Id

    響應參數

    參數類型說明
    statusinteger0: 失敗. 1: 成功

    請求示例

    POST /v5/asset/withdraw/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672197227732
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "id": "10197"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1672197228408
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/coin-info.html b/zh-TW/v5/asset/coin-info.html index 83def645d7..5480173a55 100644 --- a/zh-TW/v5/asset/coin-info.html +++ b/zh-TW/v5/asset/coin-info.html @@ -4,13 +4,13 @@ 查詢幣種信息 | Bybit API Documentation - +

    查詢幣種信息

    獲取幣種信息,包括鏈信息,是否可充可提

    HTTP 請求

    GET /v5/asset/coin/query-info

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種

    響應參數

    參數類型說明
    rowsarrayObject
    > nameinteger幣種名稱
    > coinstring幣種
    > remainAmountstring當前最大可提現數量
    > chainsarrayObject
    >> chainstring鏈名
    >> chainTypestring鏈類型
    >> confirmationstring充值上賬確認數
    >> withdrawFeestring提現手續費. 如果提現費為空,則表示該幣不支持提現
    >> depositMinstring最小充值數量
    >> withdrawMinstring最小提現數量
    >> minAccuracystring充提幣的最小精度
    >> chainDepositstring幣鏈是否可充值. 0: 暫停. 1: 正常
    >> chainWithdrawstring幣鏈是否可提幣. 0: 暫停. 1: 正常
    >> withdrawPercentageFeestring提現手續費百分比. 該字段的值是實際數字,即0.022表示為2.2%

    請求示例

    GET /v5/asset/coin/query-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194580887
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "rows": [
    {
    "name": "ETH",
    "coin": "ETH",
    "remainAmount": "1020000",
    "chains": [
    {
    "chainType": "ETH",
    "confirmation": "10000",
    "withdrawFee": "0.005",
    "depositMin": "0.01",
    "withdrawMin": "0.02",
    "chain": "ETH",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0.022"
    },
    {
    "chainType": "Arbitrum One",
    "confirmation": "10",
    "withdrawFee": "0.01",
    "depositMin": "0.001",
    "withdrawMin": "0.1",
    "chain": "ARBI",
    "chainDeposit": "1",
    "chainWithdraw": "1",
    "minAccuracy": "8",
    "withdrawPercentageFee": "0"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677478088215
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/create-inter-transfer.html b/zh-TW/v5/asset/create-inter-transfer.html index 0c804682ed..295fd38f7f 100644 --- a/zh-TW/v5/asset/create-inter-transfer.html +++ b/zh-TW/v5/asset/create-inter-transfer.html @@ -4,13 +4,13 @@ 劃轉 (單帳號內) | Bybit API Documentation - +

    劃轉 (單帳號內)

    創建單帳號下帳戶類型間的劃轉操作

    提示

    每個帳戶類型有其可接受的幣種限制, 比如, 你無法將USDC從SPOT劃轉至CONTRACT。詳情請參考可劃轉幣種接口.

    HTTP 請求

    POST /v5/asset/transfer/inter-transfer

    請求參數

    參數是否必需類型說明
    transferIdtruestringUUID. 請自行手動生成UUID
    cointruestring幣種
    amounttruestring劃入數量
    fromAccountTypetruestring轉出賬戶類型
    toAccountTypetruestring轉入賬戶類型

    響應參數

    參數類型說明
    transferIdstringUUID

    請求示例

    POST v5/asset/transfer/inter-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670986690556
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbcb16",
    "coin": "BTC",
    "amount": "0.05",
    "fromAccountType": "UNIFIED",
    "toAccountType": "CONTRACT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "42c0cfb0-6bca-c242-bc76-4e6df6cbab16"
    },
    "retExtInfo": {},
    "time": 1670986962783
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/delay-amount.html b/zh-TW/v5/asset/delay-amount.html index f2a28d8d89..1760fb8585 100644 --- a/zh-TW/v5/asset/delay-amount.html +++ b/zh-TW/v5/asset/delay-amount.html @@ -4,13 +4,13 @@ 查詢延遲提幣凍結金額 | Bybit API Documentation - +

    查詢延遲提幣凍結金額

    信息

    如何會導致部分資金被要求延遲提幣?

    • 鏈上充值: 鏈上區塊確認數未達到風險可控程度, 部分資金被凍結一段時間, 直到解凍
    • 買幣: 若存在風險, 則一定時間內被凍結, 無法提幣

    HTTP 請求

    GET /v5/asset/withdraw/withdrawable-amount

    請求參數

    參數是否必需類型說明
    cointruestring幣種敏誠

    響應參數

    參數類型說明
    limitAmountUsdstring延遲提幣凍結金額 (USD)
    withdrawableAmountarrayObject
    > SPOTObject現貨錢包, 若該錢包被移除, 則不會返回該對象
    >> coinstring幣種名稱
    >> withdrawableAmountstring可提現金額
    >> availableBalancestring可用餘額
    > FUNDObject資金錢包
    >> coinstring幣種名稱
    >> withdrawableAmountstring可提現金額
    >> availableBalancestring可用餘額

    請求示例

    GET /v5/asset/withdraw/withdrawable-amount?coin=USDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677565621998
    X-BAPI-RECV-WINDOW: 50000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "limitAmountUsd": "52853.5551",
    "withdrawableAmount": {
    "FUND": {
    "coin": "USDT",
    "withdrawableAmount": "11135.0596",
    "availableBalance": "11135.0596"
    },
    "SPOT": {
    "coin": "USDT",
    "withdrawableAmount": "0",
    "availableBalance": "0"
    }
    }
    },
    "retExtInfo": {},
    "time": 1677565632151
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/delivery.html b/zh-TW/v5/asset/delivery.html index 698b757b4e..e1e424937d 100644 --- a/zh-TW/v5/asset/delivery.html +++ b/zh-TW/v5/asset/delivery.html @@ -4,13 +4,13 @@ 查詢交割紀錄 | Bybit API Documentation - +

    查詢交割紀錄

    查詢USDC交割和期權的交割紀錄, 返回結果按照deliveryTime降序排列

    統一帳戶覆蓋範圍: USDC交割 / 期權

    HTTP 請求

    GET /v5/asset/delivery-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    symbolfalsestring合約名稱
    expDatefalsestring過期日. 格式示例: 25MAR22. 默認: 返回所有日期數據
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > deliveryTimenumber交割時間戳 (毫秒)
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > positionstring交割數量
    > deliveryPricestring交割價格
    > strikestring行權價
    > feestring手續費,正數表支出,負數表收取
    > deliveryRplstring交割已實現盈虧
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/delivery-record?expDate=29DEC22&category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672362112944
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "132791%3A0%2C132791%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "BTC-29DEC22-16000-P",
    "side": "Buy",
    "deliveryTime": 1672300800860,
    "strike": "16000",
    "fee": "0.00000000",
    "position": "0.01",
    "deliveryPrice": "16541.86369547",
    "deliveryRpl": "3.5"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672362116184
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/deposit-coin-spec.html b/zh-TW/v5/asset/deposit-coin-spec.html index 3d156dc91d..c9c9f5c3fd 100644 --- a/zh-TW/v5/asset/deposit-coin-spec.html +++ b/zh-TW/v5/asset/deposit-coin-spec.html @@ -4,13 +4,13 @@ 查詢支持的充值幣種信息 | Bybit API Documentation - +

    查詢支持的充值幣種信息

    通過幣種信息接口,獲取幣鏈組合

    提示

    該接口不需要做鑒權

    HTTP 請求

    GET /v5/asset/deposit/query-allowed-list

    請求參數

    參數是否必需類型說明
    coinfalsestring充值幣種. coinchain必須配對傳遞,否則是無效查詢
    chainfalsestring充值鏈名. coinchain必須配對傳遞,否則是無效查詢
    limitfalseinteger每頁數量限制. [1, 35]. 默認: 10
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    configListarrayObject
    > coinstring幣種
    > chainstring鏈名
    > coinShowNamestring幣種名稱
    > chainTypestring鏈的類型
    > blockConfirmNumberinteger充值上賬確認數
    > minDepositAmountstring最低充值金額
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/deposit/query-allowed-list?coin=ETH&chain=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672191495968
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "configList": [
    {
    "coin": "ETH",
    "chain": "ETH",
    "coinShowName": "ETH",
    "chainType": "ETH",
    "blockConfirmNumber": 10000,
    "minDepositAmount": "0.01"
    }
    ],
    "nextPageCursor": "eyJwYWdlIjoyLCJsaW1pdCI6MTB9"
    },
    "retExtInfo": {},
    "time": 1672191496219
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/deposit-record.html b/zh-TW/v5/asset/deposit-record.html index 595dabf097..79483756c5 100644 --- a/zh-TW/v5/asset/deposit-record.html +++ b/zh-TW/v5/asset/deposit-record.html @@ -4,13 +4,13 @@ 查詢充值紀錄 (鏈上) | Bybit API Documentation - +

    查詢充值紀錄 (鏈上)

    提示
    • endTime - startTime需要小於等於30天,默認查詢最近30天的紀錄
    • 支持母子帳號的API key查詢各自的充值紀錄

    HTTP 請求

    GET /v5/asset/deposit/query-record

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    rowsarrayObject
    > coinstring幣種
    > chainstring鏈名
    > amountstring充值金額
    > txIDstring交易Id. 充值失敗或取消充值時為空
    > statusinteger充值狀態
    > toAddressstring充值的目標地址
    > tagstring充值目標地址的tag
    > depositFeestring充值手續費
    > successAtstring最後更新時間
    > confirmationsstring确认区块的数量
    > txIndexstring交易序列号
    > blockHashstring鏈上的哈希數
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制
    > depositTypeinteger入金類型. 0: 正常充值, 10: 充值觸發每日限額, 20: 異常充值
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/deposit/query-record?coin=USDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672191991544
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "10000",
    "txID": "skip-notification-scene-test-amount-202212270944-533285-USDT",
    "status": 3,
    "toAddress": "test-amount-address",
    "tag": "",
    "depositFee": "",
    "successAt": "1672134274000",
    "confirmations": "10000",
    "txIndex": "",
    "blockHash": "",
    "batchReleaseLimit": "-1",
    "depositType": 0
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTA0NjA0MywibWF4SUQiOjEwNDYwNDN9"
    },
    "retExtInfo": {},
    "time": 1672191992512
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/exchange.html b/zh-TW/v5/asset/exchange.html index 42045dd50f..ca7afd4c39 100644 --- a/zh-TW/v5/asset/exchange.html +++ b/zh-TW/v5/asset/exchange.html @@ -4,13 +4,13 @@ 查詢兌換訂單紀錄 | Bybit API Documentation - +

    查詢兌換訂單紀錄

    信息

    該接口目前無法獲取到2023年3月12日之後的兌換紀錄, 我們將後期完成對該接口的重新支持

    警告

    您可能會遭遇較長的數據返回延遲

    HTTP 請求

    GET /v5/asset/exchange/order-record

    請求參數

    參數是否必需類型說明
    fromCoinfalsestring兌出幣種. e.g,BTC
    toCoinfalsestring兌入幣種. e.g,USDT
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 10
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    nextPageCursorstring游標,用於翻頁
    orderBodyarrayObject
    > fromCoinstring兌出幣種
    > fromAmountstring兌出金額
    > toCoinstring兌入幣種
    > toAmountstring兌入金額
    > exchangeRatestring兌換匯率
    > createdTimestring兌換創建時間戳 (秒)
    > exchangeTxIdstring兌換訂單號

    請求示例

    GET /v5/asset/exchange/order-record?limit=10 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672990462492
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderBody": [
    {
    "fromCoin": "BTC",
    "fromAmount": "0.100000000000000000",
    "toCoin": "ETH",
    "toAmount": "1.385866230000000000",
    "exchangeRate": "13.858662380000000000",
    "createdTime": "1672197760",
    "exchangeTxId": "145102533285208544812654440448"
    }
    ],
    "nextPageCursor": "173341:1672197760"
    },
    "retExtInfo": {},
    "time": 1672990464021
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/inter-transfer-list.html b/zh-TW/v5/asset/inter-transfer-list.html index 87c060d455..4abb679dca 100644 --- a/zh-TW/v5/asset/inter-transfer-list.html +++ b/zh-TW/v5/asset/inter-transfer-list.html @@ -4,13 +4,13 @@ 查詢劃轉紀錄 (單帳號內) | Bybit API Documentation - +

    查詢劃轉紀錄 (單帳號內)

    獲取單帳號內的劃轉紀錄

    HTTP 請求

    GET /v5/asset/transfer/query-inter-transfer-list

    請求參數

    參數是否必需類型說明
    transferIdfalsestringUUID. 使用創建劃轉時用的UUID
    coinfalsestring幣種
    statusfalsestring劃轉狀態
    startTimefalseinteger開始時間戳 (毫秒) 注意: 實際查詢時是秒級維度生效
    endTimefalseinteger結束時間戳 (毫秒) 注意: 實際查詢時是秒級維度生效
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > transferIdstring劃轉Id
    > coinstring劃轉幣種
    > amountstring劃轉金額
    > fromAccountTypestring劃出賬戶類型
    > toAccountTypestring劃入賬戶類型
    > timestampstring劃轉創建時間戳 (毫秒)
    > statusstring劃轉狀態
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/transfer/inter-transfer-list-query?coin=USDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1670988271299
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "selfTransfer_a1091cc7-9364-4b74-8de1-18f02c6f2d5c",
    "coin": "USDT",
    "amount": "5000",
    "fromAccountType": "SPOT",
    "toAccountType": "UNIFIED",
    "timestamp": "1667283263000",
    "status": "SUCCESS"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTM1ODQ2OCwibWF4SUQiOjEzNTg0Njh9"
    },
    "retExtInfo": {},
    "time": 1670988271677
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/internal-deposit-record.html b/zh-TW/v5/asset/internal-deposit-record.html index edc0ffe817..0d6eef867f 100644 --- a/zh-TW/v5/asset/internal-deposit-record.html +++ b/zh-TW/v5/asset/internal-deposit-record.html @@ -4,13 +4,13 @@ 查詢充值記錄 (平台转账) | Bybit API Documentation - +

    查詢充值記錄 (平台转账)

    查詢Bybit平台內部充值紀錄

    規則
  • 開始時間和截止時間差最大限制為30天
  • 支持使用母、子帳戶的api key查詢各自的入金紀錄
  • HTTP 請求

    GET /v5/asset/deposit/query-internal-record

    請求參數

    參數是否必須類型說明
    startTimefalseinteger開始時間 (精確到毫秒)。 默認為當前時間之前30天
    endTimefalseinteger結束時間 (精確到毫秒)。 默認為當前時間
    coinfalsestring幣種名:舉例,BTC。默認全部
    cursorfalsestring游標信息:用來分頁。 默認空
    limitfalseinteger每頁條數, [1, 50] 默認為50

    返回參數

    參數類型說明
    rowsarrayObject
    > idstringID
    > typeinteger1: 內部充值
    > coinstring充值的幣種
    > amountstring充值的數量
    > txIDstring交易ID。充值失敗/取消充值:為空
    > statusinteger
    • 1=處理中
    • 2=已完成
    • 3=充值失敗
    > addressstring郵箱地址或者手機號
    > createdTimestring充值創建時間戳
    nextPageCursorstring游標信息:用來分頁

    請求示例

    GET /v5/asset/deposit/query-internal-record?startTime=1667260800000&endTime=1667347200000 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682099024473
    X-BAPI-RECV-WINDOW: 50000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "id": "19097",
    "amount": "0.001",
    "type": 1,
    "coin": "BTC",
    "address": "gas***gmail.com",
    "status": 2,
    "createdTime": "1667319101"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTkwOTcsIm1heElEIjoxOTA5N30="
    },
    "retExtInfo": {},
    "time": 1682099394381
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/master-deposit-addr.html b/zh-TW/v5/asset/master-deposit-addr.html index 1fcc859e6c..73ef16cef3 100644 --- a/zh-TW/v5/asset/master-deposit-addr.html +++ b/zh-TW/v5/asset/master-deposit-addr.html @@ -4,13 +4,13 @@ 查詢主帳號充值地址 | Bybit API Documentation - +

    查詢主帳號充值地址

    警告

    僅支持母帳號API key

    HTTP 請求

    GET /v5/asset/deposit/query-address

    請求參數

    參數是否必需類型說明
    cointruestring幣種
    chainTypefalsestring鏈名, e.g.,ETH

    響應參數

    參數類型說明
    coinstring幣種
    chainsarrayObject
    > chainTypestring鏈類型
    > addressDepositstring充值地址
    > tagDepositstring地址的tag
    > chainstring鏈名
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制

    請求示例

    GET /v5/asset/deposit/query-address?coin=USDT&chainType=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672192792371
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": [
    {
    "chainType": "ERC20",
    "addressDeposit": "0xd9e1cd77afa0e50b452a62fbb68a3340602286c3",
    "tagDeposit": "",
    "chain": "ETH",
    "batchReleaseLimit": "-1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672192792860
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/set-deposit-acct.html b/zh-TW/v5/asset/set-deposit-acct.html index 829e9fe1e8..53c68e749b 100644 --- a/zh-TW/v5/asset/set-deposit-acct.html +++ b/zh-TW/v5/asset/set-deposit-acct.html @@ -4,13 +4,13 @@ 設置充值帳戶 | Bybit API Documentation - +

    設置充值帳戶

    設置充值後的自動轉入帳戶類型。該功能與網頁端-設置-充值保持一致。

    信息
    • 資金會默認充值至資金帳戶, 通過該接口設置自動劃轉帳戶後,系統將會自動劃轉至目標帳戶。
    • 僅支持主帳號調用。
    提示
    • 統一交易帳戶(UTA)擁有FUND, UNIFIED, CONTRACT(反向期貨錢包)
    • 統一保證金帳戶(UMA)擁有FUND, UNIFIED, CONTRACT(反向期貨錢包), SPOT
    • 普通帳戶擁有FUND, OPTION(USDC錢包), CONTRACT(期貨錢包), SPOT

    HTTP 請求

    POST /v5/asset/deposit/deposit-to-account

    請求參數

    參數是否必須類型說明
    accountTypetruestring帳戶類型
    • UNIFIED
    • SPOT
    • OPTION
    • CONTRACT
    • FUND

    返回參數

    參數類型說明
    statusinteger請求狀態:
    • 1: 修改成功
    • 0: 修改失敗

    請求示例

    POST /v5/asset/deposit/deposit-to-account HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676887913670
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "accountType": "CONTRACT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "status": 1
    },
    "retExtInfo": {},
    "time": 1676887914363
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/settlement.html b/zh-TW/v5/asset/settlement.html index a5bcd528f4..e517919c33 100644 --- a/zh-TW/v5/asset/settlement.html +++ b/zh-TW/v5/asset/settlement.html @@ -4,13 +4,13 @@ 查詢USDC結算紀錄 | Bybit API Documentation - +

    查詢USDC結算紀錄

    查詢USDC永續的結算紀錄

    統一帳戶覆蓋範圍: USDC永續 / USDC交割

    HTTP 請求

    GET /v5/asset/settlement-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symbolfalsestring合約名稱
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > sizestring倉位大小
    > sessionAvgPricestring結算價格
    > markPricestring標記價格
    > realisedPnlstring已實現盈虧
    > createdTimestring結算時間 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/settlement-record?category=linear HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672284883483
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "116952%3A1%2C116952%3A1",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "-71.28",
    "symbol": "BTCPERP",
    "side": "Buy",
    "markPrice": "16620",
    "size": "1.5",
    "createdTime": "1672214400000",
    "sessionAvgPrice": "16620"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672284884285
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/sub-deposit-addr.html b/zh-TW/v5/asset/sub-deposit-addr.html index 966391d7b4..be5bf584b8 100644 --- a/zh-TW/v5/asset/sub-deposit-addr.html +++ b/zh-TW/v5/asset/sub-deposit-addr.html @@ -4,13 +4,13 @@ 查詢子帳號充值地址 | Bybit API Documentation - +

    查詢子帳號充值地址

    警告

    僅能使用該母帳號的API key

    HTTP 請求

    GET /v5/asset/deposit/query-sub-member-address

    請求參數

    參數是否必需類型說明
    cointruestring幣種
    chainTypetruestring鏈名, e.g.,ETH
    subMemberIdtruestring子帳號Id

    響應參數

    參數類型說明
    coinstring幣種
    chainsarrayObject
    > chainTypestring鏈類型
    > addressDepositstring充值地址
    > tagDepositstring地址的tag
    > chainstring鏈名
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制

    請求示例

    GET /v5/asset/deposit/query-sub-member-address?coin=USDT&chainType=TRX&subMemberId=592334 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194349421
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "USDT",
    "chains": {
    "chainType": "TRC20",
    "addressDeposit": "TCB6NmwGXjn8eJYDuPxLvs4aM8Jn7gvJ1f",
    "tagDeposit": "",
    "chain": "TRX",
    "batchReleaseLimit": "-1"
    }
    },
    "retExtInfo": {},
    "time": 1672194350819
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/sub-deposit-record.html b/zh-TW/v5/asset/sub-deposit-record.html index defb703eef..06a20c1b20 100644 --- a/zh-TW/v5/asset/sub-deposit-record.html +++ b/zh-TW/v5/asset/sub-deposit-record.html @@ -4,13 +4,13 @@ 查詢子帳號的充值紀錄 (鏈上) | Bybit API Documentation - +

    查詢子帳號的充值紀錄 (鏈上)

    僅能通過主帳號的API key來查詢子帳號的充值紀錄

    提示
    • 現貨帳戶下的充值紀錄
    • endTime - startTime 需要小於等於30天. 默認查詢最近30天的紀錄

    HTTP 請求

    GET /v5/asset/deposit/query-sub-member-record

    請求參數

    參數是否必需類型說明
    subMemberIdtruestring子帳號
    coinfalsestring幣種
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    rowsarrayObject
    > coinstring幣種
    > chainstring鏈名
    > amountstring充值金額
    > txIDstring交易Id. 充值失敗或取消充值時為空
    > statusinteger充值狀態
    > toAddressstring充值的目標地址
    > tagstring充值目標地址的tag
    > depositFeestring充值手續費
    > successAtstring最後更新時間
    > confirmationsstring确认区块的数量
    > txIndexstring交易序列号
    > blockHashstring鏈上的哈希數
    > batchReleaseLimitstring當前幣鏈每日充值限額. "-1"表示無限制
    > depositTypeinteger入金類型. 0: 正常充值, 10: 充值觸發每日限額, 20: 異常充值
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/deposit/query-sub-member-record?coin=USDT&limit=1&subMemberId=592334 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672192441294
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672192441742
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/sub-uid-list.html b/zh-TW/v5/asset/sub-uid-list.html index 18a0036bb5..7bd2aa61c3 100644 --- a/zh-TW/v5/asset/sub-uid-list.html +++ b/zh-TW/v5/asset/sub-uid-list.html @@ -4,13 +4,13 @@ 查詢子帳號列表 | Bybit API Documentation - +

    查詢子帳號列表

    查詢某個母帳戶的子帳號列表

    警告

    僅支持母帳號API key

    HTTP 請求

    GET /v5/asset/transfer/query-sub-member-list

    請求參數

    響應參數

    參數類型說明
    subMemberIdsarray<string>所有子帳號
    transferableSubMemberIdsarray<string>已經開啟了萬能劃轉的子帳號

    請求示例

    GET /v5/asset/transfer/query-sub-member-list HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672147239931
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "subMemberIds": [
    "554117",
    "592324",
    "592334",
    "1055262",
    "1072055",
    "1119352"
    ],
    "transferableSubMemberIds": [
    "554117",
    "592324"
    ]
    },
    "retExtInfo": {},
    "time": 1672147241320
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/transferable-coin.html b/zh-TW/v5/asset/transferable-coin.html index b9c5729ba6..9c17289eb3 100644 --- a/zh-TW/v5/asset/transferable-coin.html +++ b/zh-TW/v5/asset/transferable-coin.html @@ -4,13 +4,13 @@ 帳戶類型間可劃轉的幣種 | Bybit API Documentation - +

    帳戶類型間可劃轉的幣種

    HTTP 請求

    GET /v5/asset/transfer/query-transfer-coin-list

    HTTP 請求

    參數是否必需類型說明
    fromAccountTypetruestring劃出帳戶類型
    toAccountTypetruestring劃入帳戶類型

    響應參數

    參數類型說明
    listarray幣種數組

    請求示例

    GET /v5/asset/transfer/query-transfer-coin-list?fromAccountType=UNIFIED&toAccountType=CONTRACT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672144322595
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    "BTC",
    "ETH"
    ]
    },
    "retExtInfo": {},
    "time": 1672144322954
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/unitransfer-list.html b/zh-TW/v5/asset/unitransfer-list.html index 33eb67d4fd..b87af7be50 100644 --- a/zh-TW/v5/asset/unitransfer-list.html +++ b/zh-TW/v5/asset/unitransfer-list.html @@ -4,13 +4,13 @@ 查詢萬能劃轉紀錄 | Bybit API Documentation - +

    查詢萬能劃轉紀錄

    提示
    • 母子帳號的api key都支持調用
    • 母帳號的api key需擁有"母子帳戶劃轉"(SubMemberTransfer)權限
    • 子帳號的api key需擁有"母子帳戶劃轉"(SubMemberTransferList)權限

    HTTP 請求

    GET /v5/asset/transfer/query-universal-transfer-list

    請求參數

    參數是否必需類型說明
    transferIdfalsestringUUID. 使用創建萬能劃轉時的UUID
    coinfalsestring幣種
    statusfalsestring劃轉狀態. SUCCESS,FAILED,PENDING
    startTimefalseinteger開始時間戳 (毫秒) 注意: 實際查詢時是秒級維度生效
    endTimefalseinteger結束時間戳 (毫秒) 注意: 實際查詢時是秒級維度生效
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > transferIdstring劃轉Id
    > coinstring劃轉幣種
    > amountstring劃轉金額
    > fromMemberIdstring劃出UID
    > toMemberIdstring劃入UID
    > fromAccountTypestring劃出賬戶類型
    > toAccountTypestring劃入賬戶類型
    > timestampstring劃轉創建時間戳 (毫秒)
    > statusstring劃轉狀態
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/asset/transfer/query-universal-transfer-list?limit=1&cursor=eyJtaW5JRCI6MTc5NjU3OCwibWF4SUQiOjE3OTY1Nzh9 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672190762800
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "transferId": "universalTransfer_4c3cfe2f-85cb-11ed-ac09-9e37823c81cd_533285",
    "coin": "USDC",
    "amount": "1000",
    "timestamp": "1672134373000",
    "status": "SUCCESS",
    "fromAccountType": "UNIFIED",
    "toAccountType": "UNIFIED",
    "fromMemberId": "533285",
    "toMemberId": "592324"
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6MTc4OTYwNSwibWF4SUQiOjE3ODk2MDV9"
    },
    "retExtInfo": {},
    "time": 1672190763079
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/unitransfer.html b/zh-TW/v5/asset/unitransfer.html index 4616f731b7..a391e59375 100644 --- a/zh-TW/v5/asset/unitransfer.html +++ b/zh-TW/v5/asset/unitransfer.html @@ -4,13 +4,13 @@ 創建萬能劃轉 | Bybit API Documentation - +

    創建萬能劃轉

    支持子子帳戶間劃轉或母子帳號間劃轉。

    警告
    • 支持使用母帳戶或者子帳號api key請求
      • 若要使用子帳號api key, 需要有"母子帳戶劃轉"(SubMemberTransferList)權限
      • 當使用子帳號api key劃轉時, 僅能劃轉到母帳號下
    • 如果您遇到錯誤碼是131228並且錯誤信息是your balance is not enough, 請前往查詢賬戶單個幣種余額接口確認安全限額.
    • 不支持同一個uid之間的劃轉

    HTTP 請求

    POST /v5/asset/transfer/universal-transfer

    請求參數

    參數是否必需類型說明
    transferIdtruestringUUID. 請求手動生成UUID
    cointruestring幣種
    amounttruestring劃轉金額
    fromMemberIdtrueinteger轉出UID
    toMemberIdtrueinteger轉入UID
    fromAccountTypetruestring轉出帳戶類型
    toAccountTypetruestring轉入帳戶類型

    響應參數

    參數類型說明
    transferIdstringUUID

    請求示例

    POST /v5/asset/transfer/universal-transfer HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672189449697
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "transferId": "be7a2462-1138-4e27-80b1-62653f24925e",
    "coin": "ETH",
    "amount": "0.5",
    "fromMemberId": 592334,
    "toMemberId": 691355,
    "fromAccountType": "CONTRACT",
    "toAccountType": "UNIFIED"

    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transferId": "be7a2462-1138-4e27-80b1-62653f24925e"
    },
    "retExtInfo": {},
    "time": 1672189450195
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/withdraw-record.html b/zh-TW/v5/asset/withdraw-record.html index 7426cfda11..d36c94d3d9 100644 --- a/zh-TW/v5/asset/withdraw-record.html +++ b/zh-TW/v5/asset/withdraw-record.html @@ -4,13 +4,13 @@ 查詢提現紀錄 | Bybit API Documentation - +

    查詢提現紀錄

    提示
    • endTime - startTime需要小於等於30天. 默認查詢最近30天的紀錄。
    • 僅支持母帳號的API key

    HTTP 請求

    GET /v5/asset/withdraw/query-record

    請求參數

    參數是否必需類型說明
    withdrawIDfalsestring提現Id
    coinfalsestring幣種
    withdrawTypefalseinteger提現類型. 0(默認): 鏈上提幣. 1: 平台內部轉帳. 2: 所有方式
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    rowsarrayObject
    > withdrawIdstring提現Id
    > txIDstring交易Id,提現失敗/提現撤銷/內部轉帳:為空
    > withdrawTypestring提現類型. 0: 鏈上提幣. 1: 內部轉帳
    > coinstring幣種
    > chainstring鏈名
    > amountstring提幣金額
    > withdrawFeestring提幣手續費
    > statusstring提幣狀態
    > toAddressstring提現目標地址. 內部轉帳:顯示Bybit UID
    > tagstring標籤
    > createTimestring提現創建時間戳 (毫秒)
    > updateTimestring提現更新時間戳 (毫秒)

    請求示例

    GET /v5/asset/withdraw/query-record?coin=USDT&withdrawType=2&limit=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672194949557
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "rows": [
    {
    "coin": "USDT",
    "chain": "ETH",
    "amount": "77",
    "txID": "",
    "status": "SecurityCheck",
    "toAddress": "0x99ced129603abc771c0dabe935c326ff6c86645d",
    "tag": "",
    "withdrawFee": "10",
    "createTime": "1670922217000",
    "updateTime": "1670922217000",
    "withdrawId": "9976",
    "withdrawType": 0
    },
    {
    "coin": "USDT",
    "chain": "internalAddressChain",
    "amount": "20.1234",
    "txID": "",
    "status": "success",
    "toAddress": "999805",
    "tag": "",
    "withdrawFee": "0",
    "createTime": "1698889833000",
    "updateTime": "1698889846000",
    "withdrawId": "13310",
    "withdrawType": 1
    }
    ],
    "nextPageCursor": "eyJtaW5JRCI6OTgwMSwibWF4SUQiOjk5NzZ9"
    },
    "retExtInfo": {},
    "time": 1672194949928
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/asset/withdraw.html b/zh-TW/v5/asset/withdraw.html index 73d1d4cd8d..5186797575 100644 --- a/zh-TW/v5/asset/withdraw.html +++ b/zh-TW/v5/asset/withdraw.html @@ -4,13 +4,13 @@ 提現 | Bybit API Documentation - +

    提現

    若目標地址是Bybit平台內部地址,您可以實現內部平台轉帳

    危險
    • UTA沒有現貨帳戶
    • 如何確定當前帳戶是否為UTA帳戶? 調用該接口, 若uta=1, 則表明該api key所屬的帳戶是UTA帳戶。
    警告
    • 確保您已經將提現地址加入到這裡
    • 僅支持母帳號的API key
    公式

    feeType=0:

    • 若百分比手續費 != 0: 手續費 = 輸入金額 / (1 - 百分比手續費) * 百分比手續費 + 固定手續費
    • 若百分比手續費 = 0: 手續費 = 固定手續費

    feeType=1:

    • 若百分比手續費 != 0: 手續費 = 固定手續費 + (輸入金額 - 固定手續費) * 百分比手續費
    • 若百分比手續費 = 0: 手續費 = 固定手續費

    HTTP 請求

    POST /v5/asset/withdraw/create

    請求參數

    參數是否必需類型說明
    cointruestring幣種
    chainfalsestring
    • 鏈名, 當forceChain=0 或者 1: 該字段必填
    • forceChain=2: 該字段可忽略
    addresstruestring錢包地址或者Bybit UID
    • forceChain=0 或者 1: 請填寫錢包地址, 確保將地址添加到了網頁地址簿中, 注意大小寫,請使用和提幣地址簿中完全一樣的地址
    • forceChain=2: 填寫目標Bybit母帳戶UID, 確保將目標UID添加到了網頁地址簿
    tagfalsestring標籤
    • 若添加地址時有填寫tag,則該字段必傳.
    • 注意: 如果鏈不支持tag/memo,請移除地址簿中的tag/memo,然後調用接口時,也不要傳tag字段
    amounttruestring提現金額
    timestamptrueinteger當前時間戳 (毫秒). 用於防止請求重放
    forceChainfalseinteger是否強制走鏈
    • 0(默認): 若提現地址解析後發現是平台內部地址,則自動轉為走內部平台轉帳
    • 1: 強制走鏈
    • 2: 使用Bybit UID轉帳
    accountTypefalsestring設置出金帳戶.
    • SPOT:走現貨錢包出金 (默認)
    • FUND:走資金錢包出金
    feeTypefalseinteger手續費選項
    • 0(默認): 輸入金額即實際收到的金額, 所以您需要額外考慮手續費
    • 1: 輸入金額不是實際收到的金額, 系統將會自動計算所需的手續費

    響應參數

    參數類型說明
    idstring提現Id

    請求示例

    POST /v5/asset/withdraw/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672196570254
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json

    {
    "coin": "USDT",
    "chain": "ETH",
    "address": "0x99ced129603abc771c0dabe935c326ff6c86645d",
    "tag": null,
    "amount": "24",
    "timestamp": 1672196561407,
    "forceChain": 0,
    "accountType": "FUND"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "id": "10195"
    },
    "retExtInfo": {},
    "time": 1672196571239
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/backup/set-pledge-token.html b/zh-TW/v5/backup/set-pledge-token.html index 3fdd18b56c..05367bbea9 100644 --- a/zh-TW/v5/backup/set-pledge-token.html +++ b/zh-TW/v5/backup/set-pledge-token.html @@ -4,13 +4,13 @@ Set Pledge Token | Bybit API Documentation - +

    Set Pledge Token

    Set Pledge Token in cross margin

    HTTP Request

    POST /v5/spot-margin-trade/set-pledge-token

    Request Parameters

    ParameterRequiredTypeComments
    cointruestringcoin
    pledgeStatustureintpledge status. 1: on, 0: off

    Response Parameters

    ParameterTypeComments
    pledgeStatusstringpledge status:1: on,0: off
    - + \ No newline at end of file diff --git a/zh-TW/v5/broker/earning.html b/zh-TW/v5/broker/earning.html index 7dccf2bf4c..43890a2620 100644 --- a/zh-TW/v5/broker/earning.html +++ b/zh-TW/v5/broker/earning.html @@ -4,13 +4,13 @@ 查詢經紀商返佣 | Bybit API Documentation - +

    查詢經紀商返佣

    信息
    • 使用經紀商的母帳戶進行查詢
    • 支持查詢過去6個月的數據
    • startTime & endTime兩個入参, 要麼同時輸入, 要麼都不輸入

    HTTP 請求

    GET /v5/broker/earning-record

    請求參數

    參數是否必需類型說明
    bizTypefalsestring業務類型. SPOT, DERIVATIVES, OPTIONS
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 1000
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > userIdstringuid
    > bizTypestring業務類型
    > symbolstring合約名稱
    > coinstring幣種名稱. 即earning的單位
    > earningstring佣金
    > orderIdstring訂單ID
    > execTimestring成交時間戳 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/broker/earning-record?bizType=SPOT&startTime=1686240000000&endTime=1686326400000&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686708862669
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "userId": "xxxx",
    "bizType": "SPOT",
    "symbol": "BTCUSDT",
    "coin": "BTC",
    "earning": "0.000015",
    "orderId": "1531607271849858304",
    "execTime": "1686306035957"
    }
    ],
    "nextPageCursor": "0%2C1"
    },
    "retExtInfo": {},
    "time": 1686708863283
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/account-info.html b/zh-TW/v5/c2c-lend/account-info.html index 390435d985..7b7f569598 100644 --- a/zh-TW/v5/c2c-lend/account-info.html +++ b/zh-TW/v5/c2c-lend/account-info.html @@ -4,13 +4,13 @@ 查詢余幣寶帳戶信息 | Bybit API Documentation - +

    查詢余幣寶帳戶信息

    HTTP 請求

    GET /v5/lending/account

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱

    響應參數

    參數類型說明
    coinstring幣種名稱
    principalIntereststring可贖回收益
    principalQtystring可贖回本金金額, 計算公式: min(用戶剩餘本金, 用戶當日可贖回額度)
    principalTotalstring可贖回總計
    quantitystring當前存入本金

    請求示例

    GET /v5/lending/account?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682049556563
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "BTC",
    "principalInterest": "0",
    "principalQty": "1",
    "principalTotal": "1",
    "quantity": "1"
    },
    "retExtInfo": {},
    "time": 1682049706988
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/cancel-redeem.html b/zh-TW/v5/c2c-lend/cancel-redeem.html index ec20153d3b..7f1240533d 100644 --- a/zh-TW/v5/c2c-lend/cancel-redeem.html +++ b/zh-TW/v5/c2c-lend/cancel-redeem.html @@ -4,13 +4,13 @@ 撤銷贖回 | Bybit API Documentation - +

    撤銷贖回

    HTTP 請求

    POST /v5/lending/redeem-cancel

    請求參數

    參數是否必需類型說明
    coinfalsestringCoin name
    orderIdfalsestringThe order ID of redemption
    serialNofalsestringSerial no. The customised ID of redemption

    響應參數

    參數類型說明
    orderIdstringOrder ID
    serialNostringSerial No
    updatedTimestringUpdated timestamp (ms)

    請求示例

    POST /v5/lending/redeem-cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682048277724
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "BTC",
    "orderId": "1403517113428086272",
    "serialNo": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1403517113428086272",
    "serialNo": "linear004",
    "updatedTime": "1682048277963"
    },
    "retExtInfo": {},
    "time": 1682048278001
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/coin-info.html b/zh-TW/v5/c2c-lend/coin-info.html index 3cb238ecb0..2c5e7364f3 100644 --- a/zh-TW/v5/c2c-lend/coin-info.html +++ b/zh-TW/v5/c2c-lend/coin-info.html @@ -4,13 +4,13 @@ 查詢可存入幣種信息 | Bybit API Documentation - +

    查詢可存入幣種信息

    查詢可存入幣種的基本信息

    信息

    所有v5/lending的接口都需要現貨權限

    HTTP 請求

    GET /v5/lending/info

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > maxRedeemQtystring單用戶每天最大可贖回數量 (0 - 24 UTC)
    > minPurchaseQtystring單筆最小存入數量
    > precisionstring精度
    > ratestring年化利率. 比如: 返回0.0002 表示 0.02%
    > loanToPoolRatiostring資金使用率. e.g. 0.0004 means 0.04%
    > actualApystring實際年化利率

    請求示例

    GET /v5/lending/info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682045949295
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "actualApy": "0.003688421873941958",
    "coin": "ETH",
    "loanToPoolRatio": "0.16855491872747133044",
    "maxRedeemQty": "161",
    "minPurchaseQty": "0.03",
    "precision": "8",
    "rate": "0.003411300771389848"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1682045942972
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/deposit.html b/zh-TW/v5/c2c-lend/deposit.html index e8d14dbd16..0153144d73 100644 --- a/zh-TW/v5/c2c-lend/deposit.html +++ b/zh-TW/v5/c2c-lend/deposit.html @@ -4,13 +4,13 @@ 存入資金 | Bybit API Documentation - +

    存入資金

    信息
    • 普通帳戶&UMA帳戶: 資金是從現貨錢包扣除
    • UTA帳戶: 資金是從統一交易錢包扣除

    HTTP 請求

    POST /v5/lending/purchase

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱
    quantitytruestring存入數量
    serialNofalsestring序列號,即自定義ID. 若不傳入,則系統自建

    響應參數

    參數類型說明
    coinstring幣種名稱
    createdTimestring創建時間戳 (毫秒)
    orderIdstring訂單ID
    quantitystring存入數量
    serialNostring序列號
    statusstring訂單狀態. 0: 初始, 1: 處理中, 2: 成功, 10: 失敗
    updatedTimestring更新時間戳 (毫秒)

    請求示例

    POST /v5/lending/purchase HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682046368938
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "USDC",
    "quantity": "20.00005",
    "serialNo": "test-00007"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "USDC",
    "createdTime": "1682046369112",
    "orderId": "1403501100816928256",
    "quantity": "20.00005",
    "serialNo": "test-00007",
    "status": "0",
    "updatedTime": "1682046369112"
    },
    "retExtInfo": {},
    "time": 1682046369120
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/order-record.html b/zh-TW/v5/c2c-lend/order-record.html index 9663e62b90..efc7519df5 100644 --- a/zh-TW/v5/c2c-lend/order-record.html +++ b/zh-TW/v5/c2c-lend/order-record.html @@ -4,13 +4,13 @@ 查詢訂單歷史 | Bybit API Documentation - +

    查詢訂單歷史

    查詢存入/贖回/收益發放的訂單歷史

    HTTP 請求

    GET /v5/lending/history-order

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱
    orderIdfalsestring訂單ID
    startTimefalselong開始時間戳 (毫秒)
    endTimefalselong結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 500]. 默認: 50
    orderTypefalsestring訂單類型. 1: 存入, 2: 贖回, 3: 收益發放

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > createdTimestring創建時間戳 (毫秒)
    > orderIdstring訂單ID
    > quantitystring數量
    > serialNostring序列號
    > statusstring訂單狀態. 0: 初始, 1: 處理中, 2: 成功, 10: 失敗, 11: 已撤銷
    updatedTimestring更新時間戳 (毫秒)

    請求示例

    GET /v5/lending/history-order?orderNo=1403517113428086272 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: 9pXyrhxTlXXXXXaVQGSaP3n
    X-BAPI-TIMESTAMP: 1682049395799
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "coin": "BTC",
    "createdTime": "1682048277963",
    "orderId": "1403517113428086272",
    "orderType": "2",
    "quantity": "0.1",
    "serialNo": "14035171132183710722373",
    "status": "2",
    "updatedTime": "1682048278245"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1682049395967
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/c2c-lend/redeem.html b/zh-TW/v5/c2c-lend/redeem.html index 6cbddeb501..78af6ccf65 100644 --- a/zh-TW/v5/c2c-lend/redeem.html +++ b/zh-TW/v5/c2c-lend/redeem.html @@ -4,13 +4,13 @@ 贖回資金 | Bybit API Documentation - +

    贖回資金

    提示

    在贖回本金時,系統還會自動贖回當前的收益。

    HTTP 請求

    POST /v5/lending/redeem

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱
    quantityturestring贖回數量
    serialNofalsestring序列號,即自定義ID. 若不傳入,則系統自建

    響應參數

    參數類型說明
    coinstring幣種名稱
    createdTimestring創建時間戳 (毫秒)
    orderIdstring訂單ID
    principalQtystring贖回數量
    serialNostring序列號
    statusstring訂單狀態. 0: 初始, 1: 處理中, 2: 成功, 10: 失敗
    updatedTimestring更新時間戳 (毫秒)

    請求示例

    POST /v5/lending/redeem HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682048277724
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "coin": "BTC",
    "quantity": "0.1",
    "serialNo": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "coin": "BTC",
    "createdTime": "1682048277963",
    "orderId": "1403517113428086272",
    "principalQty": "0.1",
    "serialNo": "14035171132183710722373",
    "status": "0",
    "updatedTime": "1682048277963"
    },
    "retExtInfo": {},
    "time": 1682048278001
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/copytrade.html b/zh-TW/v5/copytrade.html index 9c652bbb6d..209fd338a7 100644 --- a/zh-TW/v5/copytrade.html +++ b/zh-TW/v5/copytrade.html @@ -4,14 +4,14 @@ 如何使用API帶單 | Bybit API Documentation - +

    如何使用API帶單

    成為交易達人

    請前往這裡申請成為交易達人

    創建API KEY

    "合約 - 訂單 持倉"是跟單交易的必選權限項

    支持範圍

    目前, 經典帳戶和統一帳戶都支持跟單交易, 但是只能交易部分USDT永續合約對. 請通過該查詢可交易產品的規格信息接口, 檢查其中的copytrading字段, 來了解 支持的具體交易對

    下單示例

    使用V5創建訂單接口來創建一個帶單

    POST /v5/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698376189371
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 207

    {
    "symbol": "BTCUSDT",
    "side": "Buy",
    "orderType": "Limit",
    "category": "linear",
    "qty": "0.1",
    "price": "29000",
    "timeInForce": "GTC",
    "positionIdx": 1
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/enum.html b/zh-TW/v5/enum.html index a7895e5364..b2322e5b4d 100644 --- a/zh-TW/v5/enum.html +++ b/zh-TW/v5/enum.html @@ -4,13 +4,13 @@ 枚舉定義 | Bybit API Documentation - +

    枚舉定義

    locale

    • de-DE
    • en-US
    • es-AR
    • es-ES
    • es-MX
    • fr-FR
    • kk-KZ
    • id-ID
    • uk-UA
    • ja-JP
    • ru-RU
    • th-TH
    • pt-BR
    • tr-TR
    • vi-VN
    • zh-TW
    • ar-SA
    • hi-IN
    • fil-PH

    announcementType

    • new_crypto
    • latest_bybit_news
    • delistings
    • latest_activities
    • product_updates
    • maintenance_updates
    • new_fiat_listings
    • other

    announcementTag

    • Spot
    • Derivatives
    • Spot Listings
    • BTC
    • ETH
    • Trading Bots
    • USDC
    • Leveraged Tokens
    • USDT
    • Margin Trading
    • Partnerships
    • Launchpad
    • Upgrades
    • ByVotes
    • Delistings
    • VIP
    • Futures
    • Institutions
    • Options
    • WEB3
    • Copy Trading
    • Earn
    • Bybit Savings
    • Dual Asset
    • Liquidity Mining
    • Shark Fin
    • Launchpool
    • NFT GrabPic
    • Buy Crypto
    • P2P Trading
    • Fiat Deposit
    • Crypto Deposit
    • Спот
    • Спот лістинги
    • Торгові боти
    • Токени з кредитним плечем
    • Маржинальна торгівля
    • Партнерство
    • Оновлення
    • Делістинги
    • Ф'ючерси
    • Опціони
    • Копітрейдинг
    • Bybit Накопичення
    • Бівалютні інвестиції
    • Майнінг ліквідності
    • Купівля криптовалюти
    • P2P торгівля
    • Фіатні депозити
    • Криптодепозити
    • Копитрейдинг
    • Торговые боты
    • Деривативы
    • P2P
    • Спот листинги
    • Деривативи
    • MT4
    • Lucky Draw
    • Unified Trading Account
    • Єдиний торговий акаунт
    • Единый торговый аккаунт
    • Институциональный трейдинг
    • Інституціональний трейдинг
    • Делистинг

    category

    統一帳戶

    • spot現貨
    • linearUSDT永續, USDC永續, USDC交割
    • inverse反向合約,包含反向永續, 反向交割
    • option期權

    經典帳戶

    • linearUSDT永續
    • inverse反向合約,包含反向永續, 反向交割
    • spot現貨
    • option期權

    orderStatus

    • Created訂單已經被系統接收但還沒有推送到撮合引擎中
    • New訂單成功下達
    • Rejected
    • PartiallyFilled
    • PartiallyFilledCanceled僅現貨存在該枚舉值
    • Filled
    • Cancelled期貨交易,當訂單是該狀態時,是可能存在部分成交的; 經典帳戶的現貨盈止損單、條件單、OCO訂單觸發前取消
    • Untriggered
    • Triggered
    • Deactivated統一帳戶下期貨、現貨的盈止損單、條件單、OCO訂單觸發前取消
    • Active條件單已經被觸發,並且活動單已經成功創建。該狀態是條件單成功觸發後的終態

    timeInForce

    • GTC一直有效至取消
    • IOC立即成交或取消
    • FOK完全成交或取消
    • PostOnly 被動委託

    execType

    stopOrderType

    • TakeProfit止盈單
    • StopLoss止損單
    • TrailingStop追蹤止損單
    • Stop條件單
    • PartialTakeProfit部分止盈單
    • PartialStopLoss部分止損單
    • tpslOrder現貨止盈止損單
    • OcoOrder現貨OCO訂單
    • MmRateClose在web或者app端, 當倉位上設置了當達到某個MMR水平時, 自動平倉

    tickDirection

    • PlusTick價格上漲
    • ZeroPlusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格高於前一筆交易的價格
    • MinusTick價格下跌
    • ZeroMinusTick交易的價格與前一筆交易的價格相同,前一筆交易的價格低於前一筆交易的價格

    interval

    • 1 3 5 15 30 60 120 240 360 720分鐘
    • D
    • W
    • M

    intervalTime

    • 5min 15min 30min分鐘
    • 1h 4h小時
    • 1d

    positionIdx

    • 0單向持倉
    • 1買側的雙向持倉
    • 2賣側的雙向持倉

    positionStatus

    • Normal
    • Liq強平中
    • Adl自動減倉中

    rejectReason

    • EC_NoError
    • EC_Others
    • EC_UnknownMessageType
    • EC_MissingClOrdID
    • EC_MissingOrigClOrdID
    • EC_ClOrdIDOrigClOrdIDAreTheSame
    • EC_DuplicatedClOrdID
    • EC_OrigClOrdIDDoesNotExist
    • EC_TooLateToCancel
    • EC_UnknownOrderType
    • EC_UnknownSide
    • EC_UnknownTimeInForce
    • EC_WronglyRouted
    • EC_MarketOrderPriceIsNotZero
    • EC_LimitOrderInvalidPrice
    • EC_NoEnoughQtyToFill
    • EC_NoImmediateQtyToFill
    • EC_PerCancelRequest
    • EC_MarketOrderCannotBePostOnly
    • EC_PostOnlyWillTakeLiquidity
    • EC_CancelReplaceOrder
    • EC_InvalidSymbolStatus

    accountType

    • CONTRACT合約帳戶
    • SPOT現貨帳戶
    • INVESTMENTByFi帳戶 (相關服務已下線)
    • OPTIONUSDC合約帳戶
    • UNIFIED統一帳戶
    • FUND資金帳戶

    transferStatus

    • SUCCESS
    • PENDING
    • FAILED

    depositStatus

    • 0未知
    • 1等待確認
    • 2處理中
    • 3成功 (這是一筆入金成功的終態)
    • 4儲值失敗
    • 10011等待加錢到資金池
    • 10012成功加錢到資金池

    withdrawStatus

    • SecurityCheck
    • Pending
    • success
    • CancelByUser
    • Reject
    • Fail
    • BlockchainConfirmed
    • Unknown保底狀態, 一般不會出現

    triggerBy

    • LastPrice
    • IndexPrice
    • MarkPrice

    cancelType

    • CancelByUser
    • CancelByReduceOnly
    • CancelByPrepareLiq CancelAllBeforeLiq由於強平而取消
    • CancelByPrepareAdl CancelAllBeforeAdl由於自動減倉而取消
    • CancelByAdmin
    • CancelByTpSlTsClear
    • CancelByPzSideCh
    • CancelBySmp

    期權:

    • CancelByUser
    • CancelByReduceOnly
    • CancelAllBeforeLiq由於強平而取消
    • CancelAllBeforeAdl由於自動減倉而取消
    • CancelBySettle
    • CancelByCannotAffordOrderCost
    • CancelByPmTrialMmOverEquity
    • CancelByAccountBlocking
    • CancelByDelivery
    • CancelByMmpTriggered
    • CancelByCrossSelfMuch
    • CancelByCrossReachMaxTradeNum
    • CancelByDCP
    • CancelBySmp

    optionPeriod

    • BTC: 7,14,21,30,60,90,180,270
    • ETH: 7,14,21,30,60,90,180,270
    • SOL: 7,14,21,30,60,90

    dataRecordingPeriod

    • 5min 15min 30min分鐘
    • 1h 4h小時
    • 4d

    contractType

    • InversePerpetual反向永續
    • LinearPerpetual正向永續: USDT永續和USDC永續
    • LinearFuturesUSDC交割
    • InverseFutures反向交割

    status

    • PreLaunch預上線
    • Trading線上可交易
    • Settling清算中, 僅適用於USDC永續的8小時結算時的狀態
    • Delivering交割中
    • Closed已下線

    marginTrading

    • none不管是普通帳戶還是統一帳戶, 該交易對都不支持槓桿交易
    • both對於普通帳戶和統一帳戶, 該交易對都支持槓桿交易
    • utaOnly僅對於統一帳戶, 該交易對支持槓桿交易
    • normalSpotOnly僅對於普通帳戶, 該交易對支持槓桿交易

    copyTrading

    • none不管是普通帳戶還是統一帳戶, 該交易對都不支持帶單交易
    • both對於普通帳戶和統一帳戶, 該交易對都支持帶單交易
    • utaOnly僅對於統一帳戶, 該交易對支持帶單交易
    • normalOnly僅對於普通帳戶, 該交易對支持帶單交易

    type

    • TRANSFER_IN
    • TRANSFER_OUT
    • TRADE
    • SETTLEMENT
    • DELIVERY
    • LIQUIDATION
    • BONUS
    • FEE_REFUND
    • INTEREST
    • CURRENCY_BUY
    • CURRENCY_SELL
    • BORROWED_AMOUNT_INS_LOANOTC放款
    • PRINCIPLE_REPAYMENT_INS_LOAN主動償還本金
    • INTEREST_REPAYMENT_INS_LOAN主動償還利息
    • AUTO_SOLD_COLLATERAL_INS_LOANOTC強平賣出抵押品
    • AUTO_BUY_LIABILITY_INS_LOANOTC強平買入
    • AUTO_PRINCIPLE_REPAYMENT_INS_LOAN被動償還本金
    • AUTO_INTEREST_REPAYMENT_INS_LOAN被動償還利息
    • TRANSFER_IN_INS_LOAN機構借貸強平時自動劃入
    • TRANSFER_OUT_INS_LOAN機構借貸強平時自動劃出
    • SPOT_REPAYMENT_SELL一鍵還款時的賣出
    • SPOT_REPAYMENT_BUY一鍵還款時的買入

    unifiedMarginStatus

    • 1普通帳戶
    • 2已升級到了統一保證金帳戶,僅支持交易期貨和期權
    • 3已升級到了統一帳戶,支持交易期貨、期權和現貨
    • 4UTA Pro,統一帳戶的Pro版本

    ltStatus

    • 1槓桿代幣支持申贖
    • 2槓桿代幣支持申購,但無法贖回
    • 3槓桿代幣支持贖回,但是無法申購
    • 4槓桿代幣無法申贖
    • 5調倉中

    symbol

    USDT永續:

    • BTCUSDT
    • ETHUSDT

    USDC永續:

    • BTCPERP
    • ETHPERP

    USDC交割:

    • BTC-24MAR23

    反向永續:

    • BTCUSD
    • ETHUSD

    反向交割:

    • BTCUSDH23H: 第一季度; 23: 2023
    • BTCUSDM23M: 第二季度; 23: 2023
    • BTCUSDU23U: 第三季度; 23: 2023
    • BTCUSDZ23Z: 第四季度; 23: 2023

    現貨:

    • BTCUSDT
    • ETHUSDC

    adlRankIndicator

    • 0空倉時默認值
    • 1
    • 2
    • 3
    • 4
    • 5

    vipLevel

    • No VIP
    • VIP-1
    • VIP-2
    • VIP-3
    • VIP-4
    • VIP-5
    • VIP-Supreme
    • PRO-1
    • PRO-2
    • PRO-3
    • PRO-4
    • PRO-5

    smpType

    • 默認: None
    • CancelMaker
    • CancelTaker
    • CancelBoth

    現貨交易手續費幣種說明

    以BTCUSDT為例:

    • maker費率是否為正?
      • TRUE
        • 方向 = Buy -> 交易幣種 (BTC)
        • 方向 = Sell -> 報價幣種 (USDT)
      • FALSE
        • 是否是maker單 = TRUE
          • 方向 = Buy -> 報價幣種 (USDT)
          • 方向 = Sell -> 交易幣種 (BTC)
        • 是否是maker單 = FALSE
          • 方向 = Buy -> 交易幣種 (BTC)
          • 方向 = Sell -> 報價幣種 (USDT)
    - + \ No newline at end of file diff --git a/zh-TW/v5/error.html b/zh-TW/v5/error.html index 030c1c04bc..18af8de74d 100644 --- a/zh-TW/v5/error.html +++ b/zh-TW/v5/error.html @@ -4,13 +4,13 @@ 錯誤碼 | Bybit API Documentation - +

    錯誤碼

    HTTP 響應碼

    響應碼描述
    400Bad request. 請檢查您的請求方式是否為GET / POST (必需大寫)
    401無效請求. 1. 請檢查是否為正確的API密鑰; 2. 請檢查是否將鑒權參數放在了請求頭裡
    403Forbidden request. 可能原因: 1. 違反了IP請求速率; 2. 您的GET請求裡帶了空的json體
    404無法找到路由. 可能原因: 1. 請檢查您的路由; 2. 帳戶模式不支持請求的category值

    UMA & UTA

    錯誤碼描述
    0OK
    10000服務超時
    10001請求參數錯誤。
    10002請求時間超出了時間視窗範圍。
    10003API金鑰無效。
    10004錯誤簽名,請檢查簽名生成算灋。
    10005許可權被拒絕,請檢查您的API金鑰許可權。
    10006訪問次數太多。 超過API速率限制。
    10007用戶身份驗證失敗。
    10008當前帳戶模式無法訪問,請檢查您的帳戶模式
    10009IP已被禁止。
    10010IP不匹配,請檢查API金鑰的綁定IP地址。
    10014無效的重複請求。
    10016系統錯誤。
    10017未找到路由。
    10018超過IP速率限制。
    10024合規牆攔截。
    10027禁止交易。
    10028API只能由統一帳戶用戶訪問。
    10029交易對白名單限制,請求的交易對無效。
    100028統一帳戶用戶無法訪問API。
    30133OTC loan: The symbol you select for USDT Perpetual is not allowed by Institutional Lending 下單交易對不在機構借貸白名單內
    30134OTC loan: The symbol you select for USDC Contract is not allowed by Institutional Lending 下單交易對不在機構借貸白名單內
    30135The leverage you select for USDT Perpetual trading cannot exceed the maximum leverage allowed by Institutional Lending. 可設置的槓桿倍數不能超過機構借貸的上限
    30136The leverage you select for USDC Perpetual or Futures trading cannot exceed the maximum leverage allowed by Institutional Lending. 可設置的槓桿倍數不能超過機構借貸的上限
    40004the order is modified during the process of replacing 訂單已經到達終態, 無法修改
    110001訂單不存在
    110003訂單價格超出允許範圍
    110004錢包餘額不足
    110005倉位狀態
    110006估計資產無法彌補頭寸差額
    110007可用餘額不足
    110008訂單已完成或取消。
    110009停止訂單的數量超過了允許的最大限制。 您可以從我們的OpenAPI檔案中找到參攷。
    110010訂單已取消
    110011此調整將立即觸發清算
    110012可用餘額不足。
    110013由於風險限制級別,無法設定杠杆。
    110014可用餘額不足,無法添加額外保證金。
    110015該倉位處於全倉保證金模式。
    110016請求的合約數量超過了風險限額,請在重試之前調整風險限額級別
    110017不滿足ReduceOnly規則。
    110018用戶id非法。
    110019訂單id非法。
    110020不允許有超過500個活動訂單。
    110021由於未平倉,不允許超過持倉限額。
    110022數量已受到限制,無法修改訂單以新增數量。
    110023現時你只能减少你在這份合約上的頭寸。 請查看我們的公告或聯系客服瞭解詳情。
    110024您有一個持倉,因此無法切換位置模式。
    110025倉位模式尚未修改。
    110026全倉/逐倉模式尚未修改。
    110027保證金尚未修改。
    110028您已有未結訂單,因此無法切換倉位模式。
    110029此符號不支持對沖模式。
    110030訂單ID重複
    110031不存在風險限額資訊,請檢查風險限額規則。
    110032訂單不合法
    110033沒有未平倉頭寸,您無法設定保證金
    110034沒有淨頭寸
    110035清算前未完成訂單取消
    110036由於交叉保證金模式,您不允許更改杠杆。
    110037用戶設置清單沒有此交易對
    110038由於投資組合保證金模式,您不允許更改杠杆率。
    110039維護保證金率過高。 這可能引發清算。
    110040訂單將觸發強制清算,請重新提交訂單。
    110041當存在倉位或maker訂單時,不允許跳過清算
    110042現時,由於預交割狀態,您只能减少您在本合約中的頭寸。
    110043設定杠杆尚未修改。
    110044可用保證金不足。
    110045錢包餘額不足。
    110046此調整將立即觸發清算。
    110047由於可用保證金不足,無法調整風險限額。
    110048由於當前/預期頭寸值超過修訂後的風險限額,因此無法調整風險限額。
    110049tick note只能是數位
    110050無效的幣種
    110051用戶的可用餘額不能覆蓋當前市場的最低價格
    110052您的可用餘額不足以設定價格
    110053用戶可用餘額不能覆蓋當前市場價格和上限價格
    110054此倉位至少有一個獲利連結訂單,因此無法切換獲利和止損模式
    110055此倉位至少有一個止損連結訂單,因此無法切換獲利和止損模式
    110056此倉位至少有一個尾隨止損連結訂單,因此無法切換獲利和止損模式
    110057條件訂單或限制訂單包含TP/SL相關參數
    110058由於剩餘倉位大小不足,您無法設定獲利和止損。
    110059不允許修改部分填寫的未結訂單的TP/SL
    110060在完全TP/SL模式下,不允許修改TP/SL
    110061部分tpSlMode下不允許有超過20個TP/SL
    110062未找到該機构的MMP資訊。
    110063結算正在進行中! {{key0}}不可用於交易。
    110064修改後的契约數量不能小於或等於成交的數量。
    110065尚未為您的帳戶啟用MMP。 請聯系您的BD經理。
    110066現時不允許交易。
    110067不支持統一帳戶。
    110068不允許杠杆交易。
    110069機構借貸客戶不得交易。
    110070ETP合約不能交易。
    110071抱歉,我們正在修改統一保證金帳戶! 現時,不支持新的升級。 如果您有任何問題,請聯繫我們的24/7客戶支援。
    110072OrderLinkedID 不能重複
    110073設置保證金模式失敗. 請檢查響應裡的具體原因內容
    110075RiskId沒有修改
    110075 182021逐倉保證金模式下無法啟用槓桿交易. 請切換至全倉保證金或者組合保證金後再使用
    110076僅逐倉保證金下支持自動添加保證金
    110077組合保證金模式不支持此操作
    110078無法減少過多的保證金
    110079訂單正在處理中, 請稍後再試
    110080Operations Restriction: The current LTV ratio of your Institutional Lending has hit the liquidation threshold. Assets in your account are being liquidated. 目前機構借貸帳戶的LTV達到強平閾值 (交易/杠杆/风险限额等操作)
    110082You cannot lift Reduce-Only restrictions, as no Reduce-Only restrictions are applied to your position 您的倉位沒有受到Reduce-Only限制, 無需解禁
    110083Reduce-Only restrictions must be lifted for both Long and Short positions at the same time 對於多空倉位, Reduce-Only 限制需要同時解除
    110085The risk limit and margin ratio for this contract has been updated, please select a supported risk limit and place your order again 該合約的風險限額和保證金率已經更新, 請使用支持的風險限額並重新下單
    110086Current order leverage exceeds the maximum available for your current Risk Limit tier. Please lower leverage before placing an order 當前槓桿超過您當前風險限額等級的最大槓桿. 請降低槓桿後再重新下單
    110087Leverage for Perpetual or Futures contracts cannot exceed the maximum allowed for your Institutional loan 期貨的槓桿不能超過場外借貸產品規定的最大槓桿倍數
    3100181uid can not be null uid 不能為空
    3100197由於升級UTA中, 用戶暫時被封禁
    3200316USDC Options Trading Restriction: The current LTV ratio for your Institutional Lending has reached the maximum allowable amount for USDC Options trading. 目前機構借貸風險水平無法進行期權交易
    3200317USDC Options Open Position Restriction: The current LTV ratio for your Institutional Lending has reached the maximum allowable amount for opening USDC Options positions.目前機構借貸風險水平無法進行期權買入
    3100326BaseCoin is required baseCoin必須傳
    3200403逐倉保證金模式下無法進行此產品交易
    3200320Operations Restriction: The current LTV ratio of your Institutional Lending has hit the liquidation threshold. Assets in your account are being liquidated. 目前機構借貸帳戶的LTV達到強平閾值 (修改保证金模式或者现货杠杆时)
    3400208您有未關閉的雙向持倉或逐倉模式下的USDT永續倉位
    3400209有USDT永續倉位時,小時整點的前後10分鐘禁止升級
    3400210您合約帳戶當前風險率過高
    3400211升級後,帳戶風險率過高
    3400212有USDC永續倉位或者期權倉位時,小時整點的前後10分鐘禁止升級
    3400213您USDC合約帳戶當前風險率過高
    3400052您有未取消的USDC永續掛單
    3400053您有未取消的期權掛單
    3400054您有未取消的USDT永續掛單
    3400214系統處理異常,請稍候再試
    3400071您未達到帳戶升級的資產要求,無法完成升級
    3401010Cannot switch to PM mode 無法切換到PM模式(帶單帳戶嘗試切換到PM模式)
    3400139The total value of your positions and orders has exceeded the risk limit for a Perpetual or Futures contract 當前PM模式下的倉位超過了全倉或者逐倉的最大允許風險限額

    現貨交易

    錯誤碼描述
    170001openapi內部异常、及調用下游异常會拋出次异常
    170005限頻報錯
    170007調用下游超時
    170010杠杆代幣申購:超出持倉限額
    170011下單失敗,當前下單金額已超過該幣種可用額度
    170019黑名單用戶
    170031該功能已暫停
    170032下游熔斷錯誤碼
    170033保證金可用額度不足
    170034超出限額
    170035已提交系統處理(服務超時)
    170036未開通全倉杠杆
    170037所選幣種未開啟借貸
    170105參數為空
    170115無效的timeInForce
    170116無效的訂單類型
    170117無效的買賣方向
    170121下游返回的無效幣對
    170124訂單金額太大
    170130無效入参
    170131餘額不足
    170132下單價格太高
    170133下單價格太小
    170134訂單價格精度太大
    170135下單數量太大
    170136下單數量太小
    170137下單數量精度太大
    170139訂單已經成交
    170140訂單金額太小
    170141重複的clientOrderId
    170142訂單已經取消
    170143訂單取消時撮合不存在
    170144訂單被鎖定
    170145訂單類型不能取消
    170146下單超時
    170147取消訂單超時
    170148下單金額精度太大
    170149創建訂單失敗(下游發生未知异常)
    170150取消訂單失敗(下游發生未知异常)
    170151幣對未開放交易
    170157幣對不允許openapi交易
    170159開盤前五分鐘不允許下普通市價單
    170190取消訂單時訂單已經完成
    170191取消訂單時訂單狀態
    170192盤面風控(開盤後30分鐘)
    170193盤面風控限價單買入風控(開盤後前30分鐘)
    170194盤面風控片價單賣出風控(開盤後前X分鐘)
    170195ETP限價單買入偏離值風控
    170196ETP限價單賣出偏離值風控
    170197市價單買入偏離值風控
    170198市價單賣出偏離值風控
    170199ETP市價單買入偏離值風控
    170200ETP市價單賣出偏離值風控
    170201訂單種類錯誤
    170202請輸入觸發價格
    170203觸發價格大於110%
    170204觸發價格小於90%
    170206開倉前5分鐘不允許下條件單
    170207平台借貸池額度不足
    170210下單被拒絕
    170212Cancel order request processing 正在處理撤單請求
    170213訂單不存在
    170215Spot Trading (Buy) Restriction: The current LTV ratio of your institutional lending has reached the maximum allowable amount for buy orders 限制現貨買入交易, 因您當前機構借貸的LTV已觸發限制現貨買入風控線
    170216The leverage you select for Spot Trading cannot exceed the maximum leverage allowed by Institutional Lending OTC現貨切換槓桿超過機構借貸允許的槓桿上線
    170217openapi禁止成交
    170218limit-maker訂單被拒
    170219UID {{xxx}} is not available to this feature
    170220Spot Trading Restriction: The current LTV ratio of your institutional lending has reached the maximum allowable amount for Spot trading 限制現貨交易, 因您當前機構借貸的LTV已觸發限制現貨交易風控線
    170221幣種不存在
    170222請求過快
    170223場外借貸帳戶觸發告警或爆倉
    170224非創新區用戶
    170226全倉用戶帳戶爆倉中
    170227功能未開放
    170228買入額度超過預估最大買入額
    170229賣出數量超過預估最大賣出量
    170230Operations Restriction: Due to the deactivation of Margin Trading for institutional loan 機構借貸產品不支持現貨槓桿交易, 因此無法調用開關接口
    170234系統錯誤
    170310Order modification timeout 改單超時
    170311Order modification failed 改單失敗
    170312The current order does not support modification 該訂單類型不支持修改
    170313The modified contract quantity cannot be less than to the filled quantity 修改後訂單數量小於當前已成交數量
    170709OTC loan: The select trading pair is not in the whitelist pair 該交易對不在機構借貸現貨交易白名單內

    現貨槓桿代幣

    錯誤碼描述
    175000serialNo已使用過
    175001今日申購限額不足,請稍候嘗試
    175002申購訂單積壓較多,請稍後重試
    175003餘額不足,請充值後重試
    175004今日贖回限額不足,請稍候重試
    175005贖回訂單積壓較多,請稍後重試
    175006餘額不足,請充值後重試
    175007此訂單不存在
    175008當前申購未開啟
    175009申購金額超出上限
    175010您還未通過風險測試無法參與槓桿代幣的申贖和交易,請先在網頁端完成練習
    175012當前贖回未開啟
    175013贖回數量超過上限
    175014申購入口暫時關閉
    175015贖回入口暫時關閉
    175016輸入值格式不符合要求:精度或長度超出
    175017下單失敗:超出槓桿代幣持倉最大限制,當前限制是XXXX USDT
    175027用戶處於UTA升級中

    槓桿交易

    錯誤碼描述
    176002獲取用戶帳戶信息失敗, 檢查是否已經在web端完成quiz
    176003獲取用戶借款紀錄失敗
    176004獲取歷史紀錄的startTime大於endTime
    176005借款失敗
    176006還款失敗
    176007未找到借貸帳戶
    176008借貸帳戶未開通全倉槓桿,請先在web端完成練習
    176009借貸帳戶未打开全倉槓桿, 請先開啟全倉槓桿
    176010未找到借貸幣種
    176011幣種未開啟借貸
    176012未找到交易幣對
    176013交易比對未開啟借貸
    176014還款請求重複
    176015還款帳戶餘額不足
    176016無欠款,無需還款
    176017還款金額超過欠款金額
    176018用戶幣種已在還款中
    176019用戶還款計息強平衝突
    176020查詢不到還款紀錄
    176021借貸請求重複
    176022借貸幣種全量未開放
    176023交易對全量未開放
    176024借貸用戶狀態非正常
    176025借貸數量不能小於單詞最小借貸量
    176026借貸數量不能大於單次最大借貸量
    176027借貸數量不能大於平臺允許的單用戶最大借貸量
    176028借貸申請數量超過平臺最大借貸量
    176029借款申請數量超過用戶預估最大可借貸量
    176030獲取用戶借貸信息失敗
    176031借貸精度超過設置精度
    176034杠杆倍數超出範圍
    176035清算中,關閉杠杆開關失敗
    176036强平中,調整杠杆開關失敗
    176037非統一交易用戶,操作失敗
    176038現貨杠杆為關閉狀態,不允許當前操作
    176039借貸中,不允許當前操作
    176040存在現貨杠杆訂單,調整杠杆開關失敗!
    176132還款精度過高
    176133可能觸發爆倉! 請調整您的交易金額後重試
    176134帳戶已經陞級(upgrading)到UTA
    176135獲取保證金幣種失敗,請稍後重試
    176136獲取借貸幣種失敗,請稍後重試
    176137切換全倉狀態失敗,請稍後重試
    176138在關閉禁用的全倉保證金帳戶之前,您需要償還所有債務
    176139抱歉,您沒有資格啟用全倉保證金,因為您已經啟用了場外借貸
    176201Account exception. 確認是否是綁定了機構借貸的帳戶

    資產服務

    錯誤碼描述
    131001服務錯誤
    131002參數錯誤
    131002Withdraw address chain or destination tag are not equal 需要檢查提幣地址是否添加到網頁端的地址簿中, 以及是否存在tag
    131003內部錯誤
    131004需要KYC認證
    131075Internal address cannot be yourself 內部提現時目標UID不能是自身
    131076internal transfer not support sub-accounts 內部提現不支持提幣到子帳戶
    131077receive user not exist 接收方UID不再村
    131078receive user deposit has been banned 接收方被禁止入金
    131079receive user need kyc 接收方需要做KYC
    131080User left retry times is zero 所剩的重試次數為0
    131081Do not input memo/tag,please. 不要輸入memo/tag
    131082Do not repeat the request 不要重複發送請求
    131083Withdraw only allowed from address book 僅能提幣到地址簿中的地址
    131084uta upgrading, and withdraw is prohibited UTA升級中, 無法提現
    131085提幣金額大於可用餘額,觸發延遲提幣
    131086提幣金額超過風控限制,觸發全倉槓桿限制
    131087your current account spot risk level is too high, withdrawal is prohibited, please adjust and try again
    131088提幣金額超過當前KYC限額,您目前的可提限額是: %s
    131089用戶24小時內進行過銘感操作,提現被禁
    131090用戶提現封禁
    131091用戶登陸封禁,無法提幣
    131092用戶狀態異常
    131093提幣地址不在白名單內
    131094用戶ID不在白名單內
    131095提幣金額超過平台24小時限額
    131096檢查提幣金額是否滿足最小最大可提金額
    131097系統暫停提幣
    131098當前時間禁止從新地址提幣
    131099當前狀態不支持取消提幣請求
    131200服務不可用
    131201業務異常
    131202用戶ID無效
    131203請求參數錯誤
    131204帳戶異常
    131205查詢劃轉失敗
    131206劃轉失敗
    131207帳戶不存在
    131208劃轉封禁
    131209查詢子帳戶關係失敗
    131210金額精度錯誤
    131211轉入賬戶類型不能作為轉出賬戶類型
    131212可用餘額不足
    131213當前劃轉能力受到LTV風險率限制
    131214劃轉ID已存在
    131215金額錯誤
    131216查詢余額錯誤
    131217風險檢查失敗
    131227子帳戶未配置萬能劃轉能力
    131228可劃轉餘額不足. 請確認延遲提幣安全限額
    131229Due to compliance requirements, the current currency is not allowed to transfer 根據合規要求, 該資產不允許劃轉
    131230The system is busy, please try again later 系統繁忙, 請重試
    141004sub member is not normal 可能是帳戶的母子關係不正確
    141025This sub-account has assets and cannot be deleted 該子帳戶存在資產, 無法刪除
    181000category不能為空
    181001類別僅支持正向合約,期權或現貨
    181002symbol不能為空.
    181003side不能為空.
    181004side僅支持Buy或者Sell
    181005orderStatus所填的枚舉值不正確
    181006startTime所傳入的不是一個數字類型
    181007endTime所傳入的不是一個數字類型
    181008入參startTime和endTime都需要
    181009入參startTime應當小於結束時間
    181010startTime和endTime的間隔不能超過7天
    181011limit所傳入的不是一個數字類型
    181012該交易對名不存在
    181013結算幣種僅支持USDC
    181014Classic account is not supported 經典帳戶不支持
    182000交易品種相關報價不能為空

    機構借貸

    錯誤碼描述
    3777002UID cannot be bound repeatedly. UID不能重複綁定
    3777003UID cannot be unbound because the UID has not been bound to a risk unit. 無法解綁, 因為UID還沒有在風險單元內
    3777004The main UID of the risk unit cannot be unbound. 風險單元主UID不允許解綁
    3777006UID cannot be bound, please try again with a different UID." 導致的原因: 1. 請求接口的UID不是風險單元內的UID; 2. 請求接口的UID與被操作的UID不存在母子或子子關係
    3777007UID cannot be bound, please upgrade to UTA Pro." UID無法綁定, 請先將該UID升級到統一帳戶
    3777027UID cannot be bound, leveraged trading closure failed. UID無法綁定, 因為無法自動關閉槓桿交易

    余幣寶

    錯誤碼描述
    177000未知錯誤
    177001系統內部錯誤
    177002超時
    177003系統繁忙,請稍候再試
    177004參數錯誤
    177005無法找到可存入幣種
    177006請求過於頻繁
    177007正在升級至統一帳戶,贖回暫不支持
    177008存入數量太小
    177009數量精度過小
    177010餘額不足
    177011超過平台限制
    177012超過最大可贖回數量
    177013重複的serial number
    177014訂單正在進行中,請稍候再試
    177015超出用戶每天的限額
    177019Cannot continue lending because reached this crypto lending limit 由於超過上限, 無法繼續申購

    經紀商

    錯誤碼描述
    3500402limit值校驗失敗. 請檢查是否在支持範圍內
    3500403僅適用於經紀商的主帳戶
    3500404無效的cursor
    3500405startTimeendTime必須同時傳入
    - + \ No newline at end of file diff --git a/zh-TW/v5/guide.html b/zh-TW/v5/guide.html index 1b1d0986c5..7f3f68f41f 100644 --- a/zh-TW/v5/guide.html +++ b/zh-TW/v5/guide.html @@ -4,7 +4,7 @@ 接入指南 | Bybit API Documentation - + @@ -13,7 +13,7 @@ server_time - recv_window <= timestamp < server_time + 1000
    其中server_time是Bybit服務器時間,您可以通過Bybit服務器時間接口獲取.

    構建請求

    提示

    為了幫助診斷高級網絡問題,您可以考慮將cdn-request-id添加到您的請求頭中。對於每個請求,它的值應該是唯一的。.

    基本步驟:

    1. 時間戳 + API key + [recv_window]+ [queryString(無需排序) | jsonBodyString]
    2. 使用HMAC_SHA256或者RSA_SHA256算法對第1步中拼接的string簽名,並轉換為16進製字符串(HMAC_SHA256) / Base64編碼 (RSA_SHA256),得出sign參數。
    3. 添加生成的簽名到HTTP頭當中 注意: GETPOST請求的加密明文是不相同,請參考以下示例.

    對明文加密的示例

    # 拼接規則:
    timestamp+api_key+recv_window+queryString

    # 明文
    "1658384314791XXXXXXXXXX5000category=option&symbol=BTC-29JUL22-25000-C"

    # 解析
    timestamp = "1658384314791"
    api_key = "XXXXXXXXXX"
    recv_window = "5000"
    queryString = "category=option&symbol=BTC-29JUL22-25000-C"

    http請求示例

    GET /v5/order/realtime?category=option&symbol=BTC-29JUL22-25000-C HTTP/1.1
    Host: api-testnet.bybit.com
    -H 'X-BAPI-SIGN: XXXXXXXXXX' \
    -H 'X-BAPI-API-KEY: XXXXXXXXXX' \
    -H 'X-BAPI-TIMESTAMP: 1658384431891' \
    -H 'X-BAPI-RECV-WINDOW: 5000'

    外層通用數據結構

    參數類型說明
    retCodenumber成功/錯誤碼
    retMsgstring成功/錯誤消息. 成功消息可以是OK,success,SUCCESS
    resultObject業務數據體
    retExtInfoObject額外信息. 大部分場景下都是{}
    timenumber當前時間戳 (毫秒)
    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    },
    "retExtInfo": {},
    "time": 1671017382656
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/intro.html b/zh-TW/v5/intro.html index 8a5b8db751..d8945ef1ee 100644 --- a/zh-TW/v5/intro.html +++ b/zh-TW/v5/intro.html @@ -4,7 +4,7 @@ 概覽 | Bybit API Documentation - + @@ -23,7 +23,7 @@ 參考 websocket 接口文檔的描述。同時 orderbook 中增加可用於校驗數據連續性的 updateId 來判斷 orderbook 的數據是否丟失,用於您維護本地 正確的 orderbook。以及增加 seq(Sequence)字段用於您判斷不同檔位推送的數據先後對比,以更快的響應行情變化。

    業務線1檔25檔50檔100檔200檔500檔
    現貨10ms-20ms---
    期貨10ms-20ms-100ms100ms
    期權-20ms-100ms--

    提升 PostOnly 單筆下單數量

    針對期貨業務,提交 Post Only 類型的訂單,可以獲得單筆下單更多的數量,通常是普通訂單數量的 5倍。可以通過衍生品交易規格接口獲取 單個 symbol 可以交易的最大下單數量。

    數據精度統一規範

    在之前的 API 中,會返回 E2 ,E8 類型的數據。在 V3 和 V5 版本,返回的所有數值都是實際數值,您不需要做轉換調整。

    Open API 文檔可讀性提升

    Open API 文檔梳理和校對,將大部分之前文檔描述不清晰的部分進行了改善,減少客戶對接的困惑。

    V5 和 V3 接口映射列表:

    模塊V5接口V3接口
    公有行情/v5/market/kline/derivatives/v3/public/kline
    /spot/v3/public/quote/kline
    /v5/market/mark-price-kline/derivatives/v3/public/mark-price-kline
    /v5/market/index-price-kline/derivatives/v3/public/index-price-kline
    /v5/market/premium-index-price-kline/derivatives/v3/public/premium-index-price-kline
    /v5/market/orderbook/derivatives/v3/public/order-book/L2
    /spot/v3/public/quote/depth
    /v5/market/tickers/derivatives/v3/public/tickers
    /spot/v3/public/quote/ticker/24hr
    /spot/v3/public/quote/ticker/price
    /spot/v3/public/quote/ticker/bookTicker
    /v5/market/funding/history/derivatives/v3/public/funding/history-funding-rate
    /v5/market/recent-trade/derivatives/v3/public/recent-trade
    /spot/v3/public/quote/trades
    /v5/market/open-interest/derivatives/v3/public/open-interest
    /v5/market/historical-volatility/derivatives/v3/public/historical-volatility
    /v5/market/insurance/derivatives/v3/public/insurance
    /v5/market/instruments-info/derivatives/v3/public/instruments-info
    /spot/v3/public/infos
    /spot/v3/public/symbols
    /v5/market/risk-limit/derivatives/v3/public/risk-limit/list
    /v5/market/delivery-price/derivatives/v3/public/delivery-price
    交易/v5/order/create/unified/v3/private/order/create
    /contract/v3/private/order/create
    /v5/order/amend/unified/v3/private/order/replace
    /contract/v3/private/order/replace
    /v5/order/cancel/unified/v3/private/order/cancel
    /contract/v3/private/order/cancel
    /v5/order/realtime/unified/v3/private/order/unfilled-orders
    /contract/v3/private/order/unfilled-orders
    /v5/order/cancel-all/unified/v3/private/order/cancel-all
    /contract/v3/private/order/cancel-all
    /v5/order/history/unified/v3/private/order/list
    /contract/v3/private/order/list
    /v5/order/create-batch/unified/v3/private/order/create-batch
    /v5/order/amend-batch/unified/v3/private/order/replace-batch
    /v5/order/cancel-batch/unified/v3/private/order/cancel-batch
    /v5/order/spot-borrow-check
    持倉/v5/position/list/unified/v3/private/position/list
    /contract/v3/private/position/list
    /v5/position/set-leverage/unified/v3/private/position/set-leverage
    /contract/v3/private/position/set-leverage
    /v5/position/set-risk-limit/unified/v3/private/position/set-risk-limit
    /contract/v3/private/position/set-risk-limit
    /v5/position/trading-stop/unified/v3/private/position/trading-stop
    /contract/v3/private/position/trading-stop
    /v5/position/switch-isolated/contract/v3/private/position/switch-isolated
    /v5/position/switch-mode/contract/v3/private/position/switch-mode
    /v5/position/set-auto-add-margin/contract/v3/private/position/set-auto-add-margin
    /v5/position/closed-pnl/contract/v3/position/closed-pnl
    /v5/execution/list/unified/v3/private/execution/list
    /contract/v3/private/execution/list
    帳戶/v5/account/wallet-balance/unified/v3/private/account/wallet/balance
    /contract/v3/private/account/wallet/balance
    /v5/account/upgrade-to-uta/unified/v3/private/account/upgrade-unified-account
    /v5/account/borrow-history/unified/v3/private/account/borrow-history
    /v5/account/collateral-info/unified/v3/private/account/borrow-rate
    /v5/asset/coin-greeks
    /v5/account/info
    /v5/account/transaction-log/unified/v3/private/account/transaction-log
    /v5/account/set-margin-mode/contract/v3/private/account/setMarginMode
    槓桿代幣/v5/spot-lever-token/info/spot/v3/public/infos
    /v5/spot-lever-token/reference/spot/v3/private/order/reference
    /v5/spot-lever-token/purchase/spot/v3/private/order/purchase
    /v5/spot-lever-token/redeem/spot/v3/private/order/redeem
    /v5/spot-lever-token/order-record/spot/v3/private/order/record
    全倉槓桿/v5/spot-margin-trade/switch-mode/spot/v3/private/cross-margin-switch
    /v5/spot-margin-trade/set-leverage
    /v5/spot-margin-trade/set-pledge-token
    資產/v5/asset/delivery-record/unified/v3/private/delivery-record
    /v5/asset/settlement-record/unified/v3/private/settlement-record
    /v5/asset/transfer/inter-transfer/asset/v3/private/transfer/inter-transfer
    v5/asset/transfer/query-inter-transfer-list/asset/v3/private/transfer/inter-transfer/list/query
    v5/asset/transfer/save-transfer-sub-member/asset/v3/private/transfer/transfer-sub-member-save
    /v5/asset/transfer/universal-transfer/asset/v3/private/transfer/universal-transfer
    /v5/asset/transfer/query-universal-transfer-list/asset/v3/private/transfer/universal-transfer/list/query
    /v5/asset/transfer/query-transfer-coin-list/asset/v3/private/transfer/transfer-coin/list/query
    /v5/asset/transfer/query-sub-member-list/asset/v3/private/transfer/sub-member/list/quer
    /v5/asset/transfer/query-account-coin-balance/asset/v3/private/transfer/account-coin/balance/query
    /v5/asset/transfer/query-asset-info/asset/v3/private/transfer/asset-info/query
    /v5/asset/deposit/query-allowed-list/asset/v3/public/deposit/allowed-deposit-list/query
    /v5/asset/deposit/query-record/asset/v3/private/deposit/record/query
    /v5/asset/deposit/query-sub-member-record/asset/v3/private/deposit/sub-member-record/query
    /v5/asset/withdraw/query-record/asset/v3/private/withdraw/record/query
    /v5/asset/coin/query-info/asset/v3/private/coin-info/query
    /v5/asset/withdraw/create/asset/v3/private/withdraw/create
    /v5/asset/withdraw/cancel/asset/v3/private/withdraw/cancel
    /v5/asset/deposit/query-address/asset/v3/private/deposit/address/query
    /v5/asset/deposit/query-sub-member-address/asset/v3/private/deposit/sub-member-address/query
    /v5/asset/exchange/order-record/asset/v2/private/exchange/query-exchange-order
    WebSocket公共頻道wss://stream.bybit.com/v5/public/spotwss://stream.bybit.com/spot/public/v3
    wss://stream.bybit.com/v5/public/linearwss://stream.bybit.com/contract/usdt/public/v3
    wss://stream.bybit.com/contract/usdc/public/v3
    wss://stream.bybit.com/v5/public/inversewss://stream.bybit.com/contract/inverse/public/v3
    wss://stream.bybit.com/v5/public/optionwss://stream.bybit.com/option/usdc/public/v3
    WebSocket私有頻道wss://stream.bybit.com/v5/privatewss://stream.bybit.com/spot/private/v3
    wss://stream.bybit.com/unified/private/v3
    wss://stream.bybit.com/contract/private/v3
    - + \ No newline at end of file diff --git a/zh-TW/v5/lt/leverage-token-info.html b/zh-TW/v5/lt/leverage-token-info.html index d0b9bb6920..64292743ff 100644 --- a/zh-TW/v5/lt/leverage-token-info.html +++ b/zh-TW/v5/lt/leverage-token-info.html @@ -4,13 +4,13 @@ LT全量資產查詢 | Bybit API Documentation - +

    LT全量資產查詢

    查詢槓桿代幣信息

    HTTP 請求

    GET /v5/spot-lever-token/info

    請求參數

    參數是否必需類型說明
    ltCoinfalsestringLT資產名稱,例如BTC3L

    響應參數

    參數類型說明
    listarrayObject
    > ltCoinstring槓桿代幣資產簡稱
    > ltNamestring槓桿代幣資產全稱
    > maxPurchasestring單次最大申購金額
    > minPurchasestring單次最小申購金額
    > maxPurchaseDailystring單個自然日最大申購金額
    > maxRedeemstring單次最大贖回數量
    > minRedeemstring單次最小贖回數量
    > maxRedeemDailystring單個自然日最大贖回數量
    > purchaseFeeRatestring申購費率
    > redeemFeeRatestring贖回費率
    > ltStatusstring目前杠桿代幣資產是否可以進行申購贖回
    > fundFeestring每天針對持有槓桿代幣資產的用戶收取的資金費用
    > fundFeeTimenumber收取資金費用的時間
    > manageFeeRatestring管理費率
    > manageFeeTimenumber收取資金管理費的時間
    > valuestring名義資產規模
    > netValuestring當前淨值
    > totalstring平台申購總量上限

    請求示例

    GET /v5/spot-lever-token/info?ltCoin=BTC3L HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "fundFee": "299.70622821",
    "fundFeeTime": "1672992000000",
    "ltCoin": "BTC3L",
    "ltName": "3X Long",
    "ltStatus": "1",
    "manageFeeRate": "0.00005",
    "manageFeeTime": "1673053200000",
    "maxPurchase": "10000",
    "maxPurchaseDaily": "200000",
    "maxRedeem": "14434",
    "maxRedeemDaily": "2100000",
    "minPurchase": "100",
    "minRedeem": "144",
    "netValue": "0.376482201140738147",
    "purchaseFeeRate": "0.0005",
    "redeemFeeRate": "0.0005",
    "total": "5000000",
    "value": "49464463114.022994974075443169"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672991427073
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/lt/leverage-token-reference.html b/zh-TW/v5/lt/leverage-token-reference.html index 1ee8d7a1f2..3f10d3fb23 100644 --- a/zh-TW/v5/lt/leverage-token-reference.html +++ b/zh-TW/v5/lt/leverage-token-reference.html @@ -4,13 +4,13 @@ 查詢LT行情 | Bybit API Documentation - +

    查詢LT行情

    查詢LT行情

    HTTP 請求

    GET /v5/spot-lever-token/reference

    請求參數

    參數是否必需類型說明
    ltCointruestringLT資產名稱,例如BTC3L

    響應參數

    參數類型說明
    ltCoinstring槓桿代幣資產簡稱
    navstring淨值
    navTimestring淨值更新時間戳UTC毫秒
    circulationstring在二級市場流通的代幣數量
    basketstring籃子
    leveragestring真實槓桿倍數

    請求示例

    GET /v5/spot-lever-token/reference?ltCoin=BTC3S HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "basket": "-132.460000082171973364",
    "circulation": "30097.901900052619091704",
    "leverage": "-2.666924651755770729",
    "ltCoin": "BTC3S",
    "nav": "27.692082719770373048",
    "navTime": "1672991679858"
    },
    "retExtInfo": {},
    "time": 1672991679937
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/lt/order-record.html b/zh-TW/v5/lt/order-record.html index c370e6bfc1..fa03b52ff6 100644 --- a/zh-TW/v5/lt/order-record.html +++ b/zh-TW/v5/lt/order-record.html @@ -4,13 +4,13 @@ 申贖記錄查詢 | Bybit API Documentation - +

    申贖記錄查詢

    申贖記錄查詢

    HTTP 請求

    GET /v5/spot-lever-token/order-record

    請求參數

    參數是否必需類型說明
    ltCoinfalsestringLT資產名稱,例如BTC3L
    orderIdfalsestring訂單ID
    startTimefalselong起始時間
    endTimefalselong截止時間
    limitfalseint每頁數量限制。返回數據最大500條. 默認返回100條
    ltOrderTypefalseint訂單類型 1: 申購, 2: 贖回
    serialNofalsestring序列號

    響應參數

    參數類型說明
    listarrayObject
    > ltCoinstring槓桿代幣資產簡稱
    > orderIdstring訂單ID
    > ltOrderTypestring訂單類型 1: 申購, 2: 贖回
    > orderTimenumber下單時間
    > updateTimenumber訂單狀態最後一次更新時間
    > ltOrderStatusstring訂單狀態:1: 已成交, 2: 等待中, 3`: 失敗
    > feestring交易手續費
    > amountstring下單的槓桿代幣資產數量
    > valuestring成交價值
    > valueCoinstring報價幣種
    > serialNostring序列號

    請求示例

    GET /v5/spot-lever-token/order-record?orderId=2611 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672294422027
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "amount": "222.90757477",
    "fee": "0",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "1",
    "ltOrderType": "1",
    "orderId": "3016",
    "orderTime": "1672737465000",
    "serialNo": "pruchase-002",
    "updateTime": "1672737478000",
    "value": "95.13860435",
    "valueCoin": "USDT"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672294446137
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/lt/purchase.html b/zh-TW/v5/lt/purchase.html index 6337d75ecb..3229861318 100644 --- a/zh-TW/v5/lt/purchase.html +++ b/zh-TW/v5/lt/purchase.html @@ -4,13 +4,13 @@ 申購 | Bybit API Documentation - +

    申購

    申購

    HTTP 請求

    POST /v5/spot-lever-token/purchase

    請求參數

    參數是否必需類型說明
    ltCointruestringLT資產名稱,例如BTC3L
    ltAmounttruestring申購金額
    serialNofalsestring序列號,即自定義訂單號

    響應參數

    參數類型說明
    ltCoinstring槓桿代幣資產簡稱
    ltOrderStatusstring申購單狀態:1: 已完成,2: 處理中 3: 失敗
    execQtystring實際成交的槓桿代幣資產數量
    execAmtstring實際成交金額
    amountstring下單的報價幣種金額
    purchaseIdstring訂單id
    serialNostring序列號
    valueCoinstring報價幣種

    請求示例

    POST /v5/spot-lever-token/purchase HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672294730346
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "ltCoin": "EOS3L",
    "amount": "200",
    "serialNo": "purchase-001"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "amount": "200",
    "execAmt": "",
    "execQty": "",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "2",
    "purchaseId": "2611",
    "serialNo": "pruchase-001",
    "valueCoin": "USDT"
    },
    "retExtInfo": {},
    "time": 1672293867729
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/lt/redeem.html b/zh-TW/v5/lt/redeem.html index ebdadb481f..16635ac277 100644 --- a/zh-TW/v5/lt/redeem.html +++ b/zh-TW/v5/lt/redeem.html @@ -4,13 +4,13 @@ 贖回 | Bybit API Documentation - +

    贖回

    贖回

    HTTP 請求

    POST /v5/spot-lever-token/redeem

    請求參數

    參數是否必需類型說明
    ltCointruestringLT資產名稱,例如BTC3L
    quantityturestring贖回代幣數量
    serialNofalsestring序列號

    響應參數

    參數類型說明
    ltCoinstring槓桿代幣資產簡稱
    ltOrderStatusstring申購單狀態. 1: 已完成, 2: 等待中, 3: 失敗
    quantitystring數量
    execQtystring訂單數量
    execAmtstring實際成交的金額
    redeemIdstring交易單號
    serialNostring序列號
    valueCoinstring報價幣種

    請求示例

    POST /v5/spot-lever-token/redeem HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672296416024
    X-BAPI-SIGN: XXXXX
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "ltCoin": "EOS3L",
    "quantity": "150",
    "serialNo": "redeem-001"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "execAmt": "",
    "execQty": "150",
    "ltCoin": "EOS3L",
    "ltOrderStatus": "2",
    "quantity": "",
    "redeemId": "2619",
    "serialNo": "redeem-001",
    "valueCoin": "EOS3L"
    },
    "retExtInfo": {},
    "time": 1672296417363
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/delivery-price.html b/zh-TW/v5/market/delivery-price.html index 07ffeedb00..26fe6c5c72 100644 --- a/zh-TW/v5/market/delivery-price.html +++ b/zh-TW/v5/market/delivery-price.html @@ -4,13 +4,13 @@ 查詢交割價格 | Bybit API Documentation - +

    查詢交割價格

    查詢平台交割產品的交割價格,支持反向交割, USDC交割和期權

    覆蓋範圍: USDC交割 / 反向交割 / 期權

    HTTP請求

    GET /v5/market/delivery-price

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, inverse, option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易貨幣. 默認: BTC. 僅支持option
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 50
    cursorfalsestring游標,用於分頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > deliveryPricestring交割價格
    > deliveryTimestring交割時間戳 (毫秒)
    nextPageCursorstring游標,用於分頁

    請求示例

    GET /v5/market/delivery-price?category=option&symbol=ETH-26DEC22-1400-C HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "category": "option",
    "nextPageCursor": "",
    "list": [
    {
    "symbol": "ETH-26DEC22-1400-C",
    "deliveryPrice": "1220.728594450",
    "deliveryTime": "1672041600000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672055336993
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/history-fund-rate.html b/zh-TW/v5/market/history-fund-rate.html index 9965a8bf3d..8ef694596d 100644 --- a/zh-TW/v5/market/history-fund-rate.html +++ b/zh-TW/v5/market/history-fund-rate.html @@ -4,13 +4,13 @@ 查詢歷史資金費率 | Bybit API Documentation - +

    查詢歷史資金費率

    查詢資金費率,每個symbol的資金費率產生週期不同。假設資金費率為8小時,當前時間是UTC12點,則返回的是上一個結算即UTC8點產生的資金費率。如要查詢symbol的資金費率時間間隔,請查詢可交易產品規格接口

    覆蓋範圍: USDT和USDC永續 / 反向永續

    時間入参規則
    • 只傳startTime會報錯
    • 只傳endTime,則返回endTime往前的200條數據
    • 都不傳,返回當前時間的往前200條數據

    HTTP請求

    GET /v5/market/funding/history

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,inverse
    symboltruestring合約名稱
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > fundingRatestring資金費率
    > fundingRateTimestampstring資金費率時間戳 (毫秒)

    請求示例

    GET /v5/market/funding/history?category=linear&symbol=ETHPERP&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "fundingRate": "0.0001",
    "fundingRateTimestamp": "1672041600000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672051897447
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/index-kline.html b/zh-TW/v5/market/index-kline.html index 02536f7e6f..0023fd8923 100644 --- a/zh-TW/v5/market/index-kline.html +++ b/zh-TW/v5/market/index-kline.html @@ -4,13 +4,13 @@ 查詢指數價格K線數據 | Bybit API Documentation - +

    查詢指數價格K線數據

    查詢指數價格K線

    覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約

    HTTP請求

    GET /v5/market/index-price-kline

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,inverse
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseinteger開始時間戳 (毫秒)
    endfalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名稱
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照startTime降序排列
    > list[0]: startTimestring蠟燭的開始時間戳 (毫秒)
    > list[1]: openPricestring開始價格
    > list[2]: highPricestring最高價格
    > list[3]: lowPricestring最低價格
    > list[4]: closePricestring結束價格. 如果蠟燭尚未結束,則表示為最新成交價格

    請求示例

    GET /v5/market/index-price-kline?category=inverse&symbol=BTCUSDZ22&interval=1&start=1670601600000&end=1670608800000&limit=2 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDZ22",
    "category": "inverse",
    "list": [
    [
    "1670608800000",
    "17167.00",
    "17167.00",
    "17161.90",
    "17163.07"
    ],
    [
    "1670608740000",
    "17166.54",
    "17167.69",
    "17165.42",
    "17167.00"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672026471128
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/instrument.html b/zh-TW/v5/market/instrument.html index ff8c5764a8..4a7aad112a 100644 --- a/zh-TW/v5/market/instrument.html +++ b/zh-TW/v5/market/instrument.html @@ -4,13 +4,13 @@ 查詢可交易產品的規格信息 | Bybit API Documentation - +

    查詢可交易產品的規格信息

    查詢全站可交易產品的基礎配置規則信息

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權

    警告
    • 現貨不支持翻頁,因此limit, cusor無效.
    • 當通過baseCoin查詢時, 不管category=linearinverse, 返回結果中都會包含USDT永續, USDC永續, USDC交割和反向合約的交易對.

    HTTP請求

    GET /v5/market/instruments-info

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot,linear,inverse,option
    symbolfalsestring合約名稱
    statusfalsestring交易對狀態篩選
    • 現貨/期貨 僅有Trading狀態
    baseCoinfalsestring交易貨幣. 僅對期貨/期權有效
  • 對於期權, 默認返回baseCoin為BTC的
  • limitfalseinteger每頁數量限制. [1, 1000]. 默認: 500
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > symbolstring合約名稱
    > contractTypestring合約類型
    > statusstring合約狀態
    > baseCoinstring交易幣種
    > quoteCoinstring報價幣種
    > launchTimestring發佈時間 (ms)
    > deliveryTimestring交割時間 (ms). 僅對交割合約有效
    > deliveryFeeRatestring交割費率. 僅對交割合約有效
    > priceScalestring價格精度
    > leverageFilterObject槓桿屬性
    >> minLeveragestring最小槓桿
    >> maxLeveragestring最大槓桿
    >> leverageStepstring修改槓桿的步長
    > priceFilterObject價格屬性
    >> minPricestring訂單最小價格
    >> maxPricestring訂單最大價格
    >> tickSizestring修改價格的步長
    > lotSizeFilterObject訂單數量屬性
    >> maxOrderQtystring單筆訂單最大下單量
    >> minOrderQtystring單筆訂單最小下單量
    >> qtyStepstring修改下單量的步長
    >> postOnlyMaxOrderQtystringPostOnly單允許的最大下單量
    > unifiedMarginTradeboolean是否支持統一保證金交易
    > fundingIntervalinteger資金費率結算週期 (分鐘)
    > settleCoinstring結算幣種
    > copyTradingstring當前交易對是否支持帶單交易

    請求示例

    GET /v5/market/instruments-info?category=linear&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "linear",
    "list": [
    {
    "symbol": "BTCUSDT",
    "contractType": "LinearPerpetual",
    "status": "Trading",
    "baseCoin": "BTC",
    "quoteCoin": "USDT",
    "launchTime": "1585526400000",
    "deliveryTime": "0",
    "deliveryFeeRate": "",
    "priceScale": "2",
    "leverageFilter": {
    "minLeverage": "1",
    "maxLeverage": "100.00",
    "leverageStep": "0.01"
    },
    "priceFilter": {
    "minPrice": "0.50",
    "maxPrice": "999999.00",
    "tickSize": "0.50"
    },
    "lotSizeFilter": {
    "maxOrderQty": "100.000",
    "minOrderQty": "0.001",
    "qtyStep": "0.001",
    "postOnlyMaxOrderQty": "1000.000"
    },
    "unifiedMarginTrade": true,
    "fundingInterval": 480,
    "settleCoin": "USDT"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672712495660
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/insurance.html b/zh-TW/v5/market/insurance.html index 1ad4bd79eb..0e6beb9f7b 100644 --- a/zh-TW/v5/market/insurance.html +++ b/zh-TW/v5/market/insurance.html @@ -4,13 +4,13 @@ 查詢保險基金 | Bybit API Documentation - +

    查詢保險基金

    查詢Bybit平台的保險基金的數據,包含所有保險池的數據,數據每24小時更新一次。

    HTTP請求

    GET /v5/market/insurance

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱. 默認: 返回目前所有的保險池幣種

    響應參數

    參數類型說明
    updateTimestring數據最近更新的時間戳 (ms)
    listarrayObject
    > coinstring保險池的幣種
    > balancestring保險基金的幣種數量
    > valuestring保險基金的幣種價值,折合成USD的價值

    請求示例

    GET /v5/market/insurance?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "updatedTime": "1672012800000",
    "list": [
    {
    "coin": "ETH",
    "balance": "0.00187332",
    "value": "0"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672053931991
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/iv.html b/zh-TW/v5/market/iv.html index 4c48195493..0349bfc68d 100644 --- a/zh-TW/v5/market/iv.html +++ b/zh-TW/v5/market/iv.html @@ -4,13 +4,13 @@ 查詢期權波動率 | Bybit API Documentation - +

    查詢期權波動率

    獲取期權的歷史波動率數據

    覆蓋範圍: 期權

    信息
    • 數據為每小時數據.
    • 若沒有入参時間,則默認返回最近1小時的數據,即最近的一條數據.
    • starTimeendTime 要麼都傳,要麼都不傳
    • 接口支持查詢過去2年的數據, 但確保[endTime - startTime] 小於等於30天.

    HTTP請求

    GET /v5/market/historical-volatility

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. option
    baseCoinfalsestring交易幣種. 不傳則默認返回BTC數據
    periodfalsestring週期. 不傳則默認返回7天加權的數據
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > periodstring週期
    > valuestring波動率
    > timestring數據生成時間戳 (毫秒)

    請求示例

    GET /v5/market/historical-volatility?category=option&baseCoin=ETH&period=30 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "category": "option",
    "result": [
    {
    "period": 7,
    "value": "0.27545620",
    "time": "1672232400000"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/kline.html b/zh-TW/v5/market/kline.html index a51ce89f84..ab0511fb21 100644 --- a/zh-TW/v5/market/kline.html +++ b/zh-TW/v5/market/kline.html @@ -4,13 +4,13 @@ 查詢市場價格K線數據 | Bybit API Documentation - +

    查詢市場價格K線數據

    查詢市場價格K線數據

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約

    HTTP請求

    GET /v5/market/kline

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot,linear,inverse
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseinteger開始時間戳 (毫秒)
    endfalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名稱
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照startTime降序排列
    > list[0]: startTimestring蠟燭的開始時間戳 (毫秒)
    > list[1]: openPricestring開始價格
    > list[2]: highPricestring最高價格
    > list[3]: lowPricestring最低價格
    > list[4]: closePricestring結束價格. 如果蠟燭尚未結束,則表示為最新成交價格
    > list[5]: volumestring交易量. 合約單位: 合約的張數. 現貨單位: 幣種的數量
    > list[6]: turnoverstring交易額. 單位: 報價貨幣的數量

    請求示例

    GET /v5/market/kline?category=inverse&symbol=BTCUSD&interval=60&start=1670601600000&end=1670608800000 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    [
    "1670608800000",
    "17071",
    "17073",
    "17027",
    "17055.5",
    "268611",
    "15.74462667"
    ],
    [
    "1670605200000",
    "17071.5",
    "17071.5",
    "17061",
    "17071",
    "4177",
    "0.24469757"
    ],
    [
    "1670601600000",
    "17086.5",
    "17088",
    "16978",
    "17071.5",
    "6356",
    "0.37288112"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672025956592
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/long-short-ratio.html b/zh-TW/v5/market/long-short-ratio.html index 08c4f469b2..cfc3984f39 100644 --- a/zh-TW/v5/market/long-short-ratio.html +++ b/zh-TW/v5/market/long-short-ratio.html @@ -4,13 +4,13 @@ 查詢多空比 | Bybit API Documentation - +

    查詢多空比

    HTTP請求

    GET /v5/market/account-ratio

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear(僅USDT永續),inverse
    symboltruestring合約名稱
    periodtruestring數據週期. 5min, 15min, 30min, 1h, 4h, 1d
    limitfalseinteger每頁數量限制. [1, 500]. 默認: 50

    響應參數

    參數類型說明
    listarrayObject
    > symbolstring合約名稱
    > buyRatiostring持多倉的用户比例
    > sellRatiostring持空倉的用户比例
    > timestampstring時間戳 (毫秒)

    請求示例

    GET /v5/market/account-ratio?category=linear&symbol=BTCUSDT&period=1d&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "buyRatio": "0.5777",
    "sellRatio": "0.4223",
    "timestamp": "1695772800000"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1695785131028
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/mark-kline.html b/zh-TW/v5/market/mark-kline.html index c855eabe4c..a31c99b6b5 100644 --- a/zh-TW/v5/market/mark-kline.html +++ b/zh-TW/v5/market/mark-kline.html @@ -4,13 +4,13 @@ 查詢標記價格K線數據 | Bybit API Documentation - +

    查詢標記價格K線數據

    查詢標記價格K線

    覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約

    HTTP請求

    GET /v5/market/mark-price-kline

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,inverse
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseinteger開始時間戳 (毫秒)
    endfalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名稱
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照startTime降序排列
    > list[0]: startTimestring蠟燭的開始時間戳 (毫秒)
    > list[1]: openPricestring開始價格
    > list[2]: highPricestring最高價格
    > list[3]: lowPricestring最低價格
    > list[4]: closePricestring結束價格. 如果蠟燭尚未結束,則表示為最新成交價格

    請求示例

    GET /v5/market/mark-price-kline?category=linear&symbol=BTCUSDT&interval=15&start=1670601600000&end=1670608800000&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "category": "linear",
    "list": [
    [
    "1670608800000",
    "17164.16",
    "17164.16",
    "17121.5",
    "17131.64"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672026361839
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/open-interest.html b/zh-TW/v5/market/open-interest.html index 5b4650f251..3eb1e34a6b 100644 --- a/zh-TW/v5/market/open-interest.html +++ b/zh-TW/v5/market/open-interest.html @@ -4,13 +4,13 @@ 查詢未平倉合約持倉數量 | Bybit API Documentation - +

    查詢未平倉合約持倉數量

    查詢各個合約市場內所有未平倉的數量

    覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約

    信息
    • 返回單邊數據
    • 最久可以查詢到自合約上線開始的數據

    HTTP請求

    GET /v5/market/open-interest

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,inverse
    symboltruestring合約名稱
    intervalTimetruestring時間粒度. 5min 15min 30min 1h 4h 1d
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名稱
    listarrayObject
    > openIntereststring未平倉合約數量
    > timestampstring數據產生的時間戳(毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/market/open-interest?category=inverse&symbol=BTCUSD&intervalTime=5min&startTime=1669571100000&endTime=1669571400000 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSD",
    "category": "inverse",
    "list": [
    {
    "openInterest": "461134384.00000000",
    "timestamp": "1669571400000"
    },
    {
    "openInterest": "461134292.00000000",
    "timestamp": "1669571100000"
    }
    ],
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1672053548579
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/orderbook.html b/zh-TW/v5/market/orderbook.html index 422e82b54e..53ead1defa 100644 --- a/zh-TW/v5/market/orderbook.html +++ b/zh-TW/v5/market/orderbook.html @@ -4,13 +4,13 @@ Order Book (深度) | Bybit API Documentation - +

    Order Book (深度)

    獲取深度數據

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權

    • 期貨: 最多返回200檔的數據.
    • 現貨: 最多返回50檔的數據.
    • 期權: 僅返回25檔的數據.
    提示

    響應是當前時間的切片數據

    HTTP請求

    GET /v5/market/orderbook

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot, linear, inverse, option
    symboltruestring合約名稱
    limitfalseinteger深度限制.
    • spot: [1, 200], 默認: 1.
    • linear&inverse: [1, 200],默認: 25.
    • option: [1, 25],默認: 1.

    響應參數

    參數類型說明
    sstring合約名稱
    barrayBid, 買方. 按照價格從大到小
    > b[0]string買方報價
    > b[1]string買方數量
    aarrayAsk, 賣方. 按照價格從小到大
    > a[0]string賣方報價
    > a[1]string賣方數量
    tsinteger行情服務生成數據時間戳(毫秒)
    uinteger表示數據連續性的id.
    • 對於期貨, 它和wss推送裡的200檔的u對齊
    • 對於現貨, 它和wss推送裡的50檔的u對齊

    請求示例

    GET /v5/market/orderbook?category=spot&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "SUCCESS",
    "result": {
    "s": "BTC-30DEC22-18000-C",
    "b": [
    [
    "5",
    "3.12"
    ]
    ],
    "a": [
    [
    "175",
    "4.88"
    ]
    ],
    "u": 1203433656,
    "ts": 1672043188375
    },
    "retExtInfo": {},
    "time": 1672043199230
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/preimum-index-kline.html b/zh-TW/v5/market/preimum-index-kline.html index 3b88b6872c..2c8c6c9586 100644 --- a/zh-TW/v5/market/preimum-index-kline.html +++ b/zh-TW/v5/market/preimum-index-kline.html @@ -4,13 +4,13 @@ 查詢溢價指數價格K線數據 | Bybit API Documentation - +

    查詢溢價指數價格K線數據

    查詢溢價指數價格K線數據

    覆蓋範圍: USDT和USDC永續

    HTTP請求

    GET /v5/market/premium-index-price-kline

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symboltruestring合約名稱
    intervaltruestring時間粒度. 1,3,5,15,30,60,120,240,360,720,D,M,W
    startfalseinteger開始時間戳 (毫秒)
    endfalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 1000]. 默認: 200

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名稱
    listarray
    • 一個字符串數組構成單個蠟燭
    • 按照startTime降序排列
    > list[0]string蠟燭的開始時間戳 (毫秒)
    > list[1]string開始價格
    > list[2]string最高價格
    > list[3]string最低價格
    > list[4]string結束價格. 如果蠟燭尚未結束,則表示為最新成交價格

    請求示例

    GET /v5/market/premium-index-price-kline?category=linear&symbol=BTCUSDT&interval=D&start=1652112000000&end=1652544000000 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCPERP",
    "category": "linear",
    "list": [
    [
    "1672026540000",
    "0.000000",
    "0.000000",
    "0.000000",
    "0.000000"
    ],
    [
    "1672026480000",
    "0.000000",
    "0.000000",
    "0.000000",
    "0.000000"
    ]
    ]
    },
    "retExtInfo": {},
    "time": 1672026605042
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/recent-trade.html b/zh-TW/v5/market/recent-trade.html index 2d4ebb6cb2..27fe06b37b 100644 --- a/zh-TW/v5/market/recent-trade.html +++ b/zh-TW/v5/market/recent-trade.html @@ -4,13 +4,13 @@ 查詢平台最近成交歷史 | Bybit API Documentation - +

    查詢平台最近成交歷史

    獲取平台最近成交數據

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權

    您可以從這裡下載到歸檔的更多的歷史成交數據:

    HTTP請求

    GET /v5/market/recent-trade

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot,linear,inverse,option
    symbolfalsestring合約名稱
    • 現貨/期權必傳
    • 期權選傳
    baseCoinfalsestring交易幣種. 僅option, 若不傳, 則默認返回BTC數據
    optionTypefalsestring期權類型. CallPut. 僅option
    limitfalseinteger每頁數量限制.
    • spot: [1,60], 默认: 60.
    • others: [1,1000], 默認: 500

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > execIdstring成交id
    > symbolstring合約名稱
    > pricestring成交價格
    > sizestring成交數量
    > sidestring吃單方向. Buy, Sell
    > timestring成交時間戳 (毫秒)
    > isBlockTradeboolean成交類型是否為大宗交易

    請求示例

    GET /v5/market/recent-trade?category=spot&symbol=BTCUSDT&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "spot",
    "list": [
    {
    "execId": "2100000000007764263",
    "symbol": "BTCUSDT",
    "price": "16618.49",
    "size": "0.00012",
    "side": "Buy",
    "time": "1672052955758",
    "isBlockTrade": false
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672053054358
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/risk-limit.html b/zh-TW/v5/market/risk-limit.html index 9d16c3a212..aa6c8dc5c6 100644 --- a/zh-TW/v5/market/risk-limit.html +++ b/zh-TW/v5/market/risk-limit.html @@ -4,13 +4,13 @@ 查詢合約風險限額 | Bybit API Documentation - +

    查詢合約風險限額

    查詢期貨合約的風險限額表

    覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約

    提示

    什麼是風險限額?風險限額(USDT合約)

    HTTP請求

    GET /v5/market/risk-limit

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear,inverse
    symbolfalsestring合約名稱

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > idinteger風險限額id
    > symbolstring合約名稱
    > riskLimitValuestring風險限制額度
    > maintenanceMarginnumber維持保證金率
    > initialMarginnumber初始保證金率
    > sectionarraysection數組
    > isLowestRiskinteger是否是最低風險限額. 1: true, 0: false
    > maxLeveragestring該風險限額允許的最大槓桿

    請求示例

    GET /v5/market/risk-limit?category=inverse&symbol=BTCUSD HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "id": 1,
    "symbol": "BTCUSD",
    "riskLimitValue": "150",
    "maintenanceMargin": "0.5",
    "initialMargin": "1",
    "isLowestRisk": 1,
    "maxLeverage": "100.00"
    },
    ....
    ]
    },
    "retExtInfo": {},
    "time": 1672054488010
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/tickers.html b/zh-TW/v5/market/tickers.html index 981fa65f14..a59bf97901 100644 --- a/zh-TW/v5/market/tickers.html +++ b/zh-TW/v5/market/tickers.html @@ -4,13 +4,13 @@ 查詢最新行情信息 | Bybit API Documentation - +

    查詢最新行情信息

    可獲取到快照的最新市場價格,最佳買賣價格,以及過去時間內的交易量等.

    覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權

    HTTP請求

    GET /v5/market/tickers

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot,linear,inverse,option
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種. 僅option有效, baseCoinsymbol必傳其中一個
    expDatefalsestring到期日. 舉例, 25DEC22. 僅option有效

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > lastPricestring最新市場成交價
    > indexPricestring指數價格
    > markPricestring標記價格
    > prevPrice24hstring24小時前的整點市價
    > price24hPcntstring市場價格相對24h前變化的百分比
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價
    > prevPrice1hstring1小時前的整點市價
    > openIntereststring未平倉合約的數量
    > openInterestValuestring未平倉合約的價值
    > turnover24hstring最近24小時成交額
    > volume24hstring最近24小時成交量
    > fundingRatestring資金費率
    > nextFundingTimestring下次結算資金費用的時間 (毫秒)
    > predictedDeliveryPricestring預計交割價格. 交割前30分鐘有值
    > basisRatestring交割合約基差率
    > basisstring交割合約基差
    > deliveryFeeRatestring交割費率
    > deliveryTimestring交割時間戳 (毫秒)
    > ask1Sizestring買1價的數量
    > bid1Pricestring買1價
    > ask1Pricestring賣1價
    > bid1Sizestring買1價的數量

    請求示例

    GET /v5/market/tickers?category=inverse&symbol=BTCUSD HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "list": [
    {
    "symbol": "BTCUSD",
    "lastPrice": "16597.00",
    "indexPrice": "16598.54",
    "markPrice": "16596.00",
    "prevPrice24h": "16464.50",
    "price24hPcnt": "0.008047",
    "highPrice24h": "30912.50",
    "lowPrice24h": "15700.00",
    "prevPrice1h": "16595.50",
    "openInterest": "373504107",
    "openInterestValue": "22505.67",
    "turnover24h": "2352.94950046",
    "volume24h": "49337318",
    "fundingRate": "-0.001034",
    "nextFundingTime": "1672387200000",
    "predictedDeliveryPrice": "",
    "basisRate": "",
    "deliveryFeeRate": "",
    "deliveryTime": "0",
    "ask1Size": "1",
    "bid1Price": "16596.00",
    "ask1Price": "16597.50",
    "bid1Size": "1",
    "basis": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672376496682
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/market/time.html b/zh-TW/v5/market/time.html index 8c82be0218..5d2bc3835c 100644 --- a/zh-TW/v5/market/time.html +++ b/zh-TW/v5/market/time.html @@ -4,13 +4,13 @@ Bybit服務器時間 | Bybit API Documentation - +
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/amend-order.html b/zh-TW/v5/order/amend-order.html index 0c7b40412d..576bbfd536 100644 --- a/zh-TW/v5/order/amend-order.html +++ b/zh-TW/v5/order/amend-order.html @@ -4,14 +4,14 @@ 修改委託單 | Bybit API Documentation - +

    修改委託單

    統一帳戶覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權
    普通帳戶覆蓋範圍: 現貨 / USDT永續 / 反向合約

    important

    您只能修改那些未成交或者部分成交的訂單。

    Websocket現貨推送邏輯

    經典帳戶: 如果原始訂單是PostOnly訂單, 在修改訂單後, 變成了taker訂單, 那麼您將先收到一條推送orderStatus="New"的消息, 然後是orderStatus="Rejected"的消息

    統一帳戶: 如果原始訂單是PostOnly訂單, 在修改訂單後, 變成了taker訂單, 那麼您將直接收到一條推送orderStatus="Rejected"的消息

    HTTP請求

    POST /v5/order/amend

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse, spot, option
    • 普通帳戶: linear, inverse, spot
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    orderIvfalsestring隱含波動率. 僅option有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1
    triggerPricefalsestring
    • 對於期貨, 是條件單觸發價格參數. 若您希望市場價是要上升後觸發, 確保:
      triggerPrice > 市場價格
      否則, triggerPrice < 市場價格
    • 對於現貨, 這是下止盈止損單或者條件單的觸發價格參數
    qtyfalsestring修改後的訂單數量. 若不修改,請不要傳該字段
    pricefalsestring修改後的訂單價格. 若不修改,請不要傳該字段
    tpslModefalsestring止盈止損模式
    • Full: 全部倉位止盈止損. 此時, tpOrderType或者slOrderType必須傳Market
    • Partial: 部分倉位止盈止損. 支持創建限價止盈止損. 注意: 創建限價止盈止損時, tpslMode必傳且為Partial
    僅對linearinverse有效
    takeProfitfalsestring修改後的止盈價格. 當傳"0"時, 表示取消當前訂單上設置的止盈. 若不修改,請不要傳該字段
    stopLossfalsestring修改後的止損價格. 當傳"0"時, 表示取消當前訂單上設置的止損. 若不修改,請不要傳該字段
    tpTriggerByfalsestring止盈價格觸發類型. 若下單時未設置該值,則調用該接口修改止盈價格時,該字段必傳
    slTriggerByfalsestring止損價格觸發類型. 若下單時未設置該值,則調用該接口修改止損價格時,該字段必傳
    triggerByfalsestring觸發價格的觸發類型
    tpLimitPricefalsestring*觸發止盈後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效
    slLimitPricefalsestring*觸發止損後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效

    響應參數

    參數類型說明
    orderIdstring訂單Id
    orderLinkIdstring用戶自定義訂單Id

    請求示例

    POST /v5/order/amend HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672217108106
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "ETHPERP",
    "orderLinkId": "linear-004",
    "triggerPrice": "1145",
    "qty": "0.15",
    "price": "1050",
    "takeProfit": "0",
    "stopLoss": "0"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "orderLinkId": "linear-004"
    },
    "retExtInfo": {},
    "time": 1672217093461
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/batch-amend.html b/zh-TW/v5/order/batch-amend.html index 885791c50b..8fb6fe35bf 100644 --- a/zh-TW/v5/order/batch-amend.html +++ b/zh-TW/v5/order/batch-amend.html @@ -4,13 +4,13 @@ 批量修改委託單 | Bybit API Documentation - +

    批量修改委託單

    覆蓋範圍: 期權 (統一帳戶) / USDT永續、USDC永續、USDC交割 (UTA Pro)

    提示

    該接口支持批量修改委託單

    • 您只能修改那些未成交部分成交的訂單. 條件單不支持批量修改.
    • 最多支持單個請求中修改, 期權: 20個訂單, 期貨: 10个訂單.

    HTTP請求

    POST /v5/order/amend-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    requesttruearrayObject
    > symboltruestring合約名稱
    > orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    > orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    > orderIvfalsestring隱含波動率. 僅option有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1
    > triggerPricefalsestring觸發價格. 若希望市場趨勢是上漲至觸發條件單, 則確保:
    觸發價格 > 市場價格
    否則,觸發價格 < 市場價格
    > qtyfalsestring修改後的訂單數量. 若不修改,請不要傳該字段
    > pricefalsestring修改後的訂單價格. 若不修改,請不要傳該字段
    > tpslModefalsestring止盈止損模式
    • Full: 全部倉位止盈止損. 此時, tpOrderType或者slOrderType必須傳Market
    • Partial: 部分倉位止盈止損. 支持創建限價止盈止損. 注意: 創建限價止盈止損時, tpslMode必傳且為Partial
    僅對linear有效
    > takeProfitfalsestring修改後的止盈價格. 當傳"0"時, 表示取消當前訂單上設置的止盈. 若不修改,請不要傳該字段
    > stopLossfalsestring修改後的止損價格. 當傳"0"時, 表示取消當前訂單上設置的止損. 若不修改,請不要傳該字段
    > tpTriggerByfalsestring止盈價格觸發類型. 若下單時未設置該值,則調用該接口修改止盈價格時,該字段必傳
    > slTriggerByfalsestring止損價格觸發類型. 若下單時未設置該值,則調用該接口修改止損價格時,該字段必傳
    > triggerByfalsestring觸發價格的觸發類型
    > tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效
    > slLimitPricefalsestring觸發止損後轉換為限價單的價格. 當且僅當原始訂單下單時創建的是部分止盈止損限價單, 本字段才有效

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    retExtInfoObject
    > listarrayObject
    >> codenumber成功/錯誤碼
    >> msgstring成功/錯誤信息

    請求示例

    POST /v5/order/amend-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672222935987
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "qty": null,
    "price": null,
    "orderIv": "6.8",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2"
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "qty": null,
    "price": "650",
    "orderIv": null,
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52"
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": ""
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": ""
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672222808060
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/batch-cancel.html b/zh-TW/v5/order/batch-cancel.html index 25ee3a8c39..c4a4d6574e 100644 --- a/zh-TW/v5/order/batch-cancel.html +++ b/zh-TW/v5/order/batch-cancel.html @@ -4,13 +4,13 @@ 批量撤銷委託單 | Bybit API Documentation - +

    批量撤銷委託單

    該接口可以批量撤銷多筆訂單

    覆蓋範圍: 期權 (統一帳戶) / USDT永續、USDC永續、USDC交割 (UTA Pro)

    重要
    • 您必須指定orderId或者orderLinkId.
    • orderIdorderLinkId之間不匹配, 系統將會優先處理orderId.
    • 您只能撤銷未成交和部分成交的訂單.
    • 單個請求最多支持撤銷, 期權: 20個訂單, 期貨: 10个訂單.

    HTTP請求

    POST /v5/order/cancel-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    requesttruearrayObject
    > symboltruestring合約名稱
    > orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    > orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    retExtInfoObject
    > listarrayObject
    >> codenumber成功/錯誤碼
    >> msgstring成功/錯誤信息

    請求示例

    POST /v5/order/cancel-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672223356634
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2"
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52"
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": "option-test-001"
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-700-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": "option-test-001"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672223357252
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/batch-place.html b/zh-TW/v5/order/batch-place.html index 13ce11e173..84413012fa 100644 --- a/zh-TW/v5/order/batch-place.html +++ b/zh-TW/v5/order/batch-place.html @@ -4,7 +4,7 @@ 批量創建委託單 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    批量創建委託單

    覆蓋範圍: 期權 (統一帳戶) / USDT永續、USDC永續、USDC交割 (UTA Pro)

    提示

    該接口支持批量創建委託單

    • 下單時需確保帳戶內有足夠的資金。一旦下單,根據訂單所需資金,您的帳戶資金將在訂單生命週期內凍結相應額度,被凍結的資金額度取決於訂單屬性。
    • 每個請求包含的訂單數最大是: 20筆(期权), 10筆(期貨),返回的數據列表中分成兩個list,訂單創建的列表和創建結果的信息返回,兩個list的訂單的序列是完全保持一致的。
    信息
    • 當category=linear時, 請從這裡查閱其API限頻說明

    • 風控限制提示:
      Bybit 將針對您的 API 請求進行統計監控,當單日 (UTC 0点 - UTC 24点) 單帳號(母帳號和子帳號整體運算)訂單總数超過一定上限,平台將保留提醒、警告,以及進行必要性限制的權利。 使用API的客戶預設接受本條款並負有配合調整的義務。

    HTTP請求

    POST /v5/order/create-batch

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, option
    requesttruearrayObject
    > symboltruestring合約名稱
    > sidetruestring方向. Buy, Sell
    > orderTypetruestring訂單類型. Market, Limit
    > qtytruestring訂單數量
  • 特別地, 對於期貨而言, 如果您傳入qty="0", 則可以全部平掉對應合約的倉位
  • > pricefalsestring訂單價格
    • 市價單將會忽視該字段
    • 請通過該接口確認最低價格和精度要求
    • 如果有持倉, 確保價格優於強平價格
    > triggerDirectionfalseinteger條件單參數. 用於辨別期望的方向.
    • 1: 當市場價上漲到了triggerPrice時觸發條件單
    • 2: 當市場價下跌到了triggerPrice時觸發條件單
    linear有效
    > triggerPricefalsestring
    • 對於期貨, 是條件單觸發價格參數. 若您希望市場價是要上升後觸發, 確保:
      triggerPrice > 市場價格
      否則, triggerPrice < 市場價格
    linear有效
    > triggerByfalsestring條件單參數. 觸發價格類型. LastPrice, IndexPrice, MarkPrice
    linear有效
    > orderIvfalsestring隱含波動率. 僅option有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1. orderIvprice有更高的優先級
    > timeInForcefalsestring訂單執行策略
    • 市價單,系統直接使用IOC
    • 若不傳,默認使用GTC
    > positionIdxfalseinteger倉位標識, 用戶不同倉位模式. 該字段對於雙向持倉模式(USDT永續支持雙向模式)是必傳:
    • 0: 單向持倉
    • 1: 買側雙向持倉
    • 2: 賣側雙向持倉
    linear有效
    > orderLinkIdfalsestring用戶自定義訂單Id. category=option時,該參數必傳
    > takeProfitfalsestring止盈價格, 僅linear有效
    > stopLossfalsestring止損價格, 僅linear有效
    > tpTriggerByfalsestring觸發止盈的價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    linear有效
    > slTriggerByfalsestring觸發止損的價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    linear有效
    > reduceOnlyfalseboolean什麼是只減倉? true 將這筆訂單設為只減倉
    • 當減倉時, reduceOnly=true必傳
    • 只減倉單的止盈止損不生效
    > closeOnTriggerfalseboolean什麼是觸發後平倉委託?此選項可以確保您的止損單被用於減倉(平倉)而非加倉,並且在可用保證金不足的情況下,取消其他委託,騰出保證金以確保平倉委託的執行.
    linear有效
    > smpTypefalsestringSmp執行類型. 什麼是SMP?
    > mmpfalseboolean做市商保護. 僅option有效. true 表示該訂單是做市商保護訂單. 什麼是做市商保護?
    > tpslModefalsestring止盈止損模式
    • Full: 全部倉位止盈止損. 此時, tpOrderType或者slOrderType必須傳Market
    • Partial: 部分倉位止盈止損. 支持創建限價止盈止損. 注意: 創建限價止盈止損時, tpslMode必傳且為Partial
    linear有效
    > tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 僅tpslMode=Partial且tpOrderType=Limit時有效
    linear有效
    > slLimitPricefalsestring觸發止損後轉換為限價單的價格. 僅tpslMode=Partial且slOrderType=Limit時有效
    linear有效
    > tpOrderTypefalsestring止盈觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持tpOrderType=Market
    linear有效
    > slOrderTypefalsestring止損觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持slOrderType=Market
    linear有效

    響應參數

    參數類型說明
    resultObject
    > listarrayObject
    >> categorystring產品類型
    >> symbolstring合約名稱
    >> orderIdstring訂單Id
    >> orderLinkIdstring用戶自定義訂單Id
    >> createAtstring訂單創建時間 (毫秒)
    retExtInfoObject
    > listarrayObject
    >> codenumber成功/錯誤碼
    >> msgstring成功/錯誤消息

    請求示例

    POST /v5/order/create-batch HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672222064519
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "option",
    "request": [
    {
    "symbol": "ETH-30DEC22-500-C",
    "orderType": "Limit",
    "side": "Buy",
    "qty": "1",
    "price": null,
    "orderIv": "6",
    "timeInForce": "GTC",
    "orderLinkId": "option-test-001",
    "mmp": false,
    "reduceOnly": false
    },
    {
    "symbol": "ETH-30DEC22-700-C",
    "orderType": "Limit",
    "side": "Sell",
    "qty": "2",
    "price": "700",
    "iv": null,
    "timeInForce": "GTC",
    "orderLinkId": "option-test-001",
    "mmp": false,
    "reduceOnly": false
    }
    ]
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "b551f227-7059-4fb5-a6a6-699c04dbd2f2",
    "orderLinkId": "option-test-001",
    "createAt": "1672222047683"
    },
    {
    "category": "option",
    "symbol": "ETH-30DEC22-500-C",
    "orderId": "fa6a595f-1a57-483f-b9d3-30e9c8235a52",
    "orderLinkId": "option-test-001",
    "createAt": "1672222047683"
    }
    ]
    },
    "retExtInfo": {
    "list": [
    {
    "code": 0,
    "msg": "OK"
    },
    {
    "code": 0,
    "msg": "OK"
    }
    ]
    },
    "time": 1672222047684
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/cancel-all.html b/zh-TW/v5/order/cancel-all.html index 7da6d44309..f333bafd81 100644 --- a/zh-TW/v5/order/cancel-all.html +++ b/zh-TW/v5/order/cancel-all.html @@ -4,7 +4,7 @@ 撤銷所有訂單 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 普通帳戶覆蓋範圍: USDT永續 / 反向合約

    信息
    • 支持按照symbol/baseCoin/settleCoin撤銷訂單,若您傳入了多個參數組合, 系統僅會處理其中一個參數,其中優先級為symbol > baseCoin > settleCoin.
    • 注意: 當category=option, 您可以不傳人三個參數中的任何一個,就能取消所有期權的委託單。但是, 對於linearinverse, 您必需指定三個參數的其中一個。
    • 注意: 當category=spot, 您可以不傳人任何參數,就能取消所有現貨的委託單 (默認普通單)。
    信息

    現貨: 經典帳戶 - 最多取消500單; 統一帳戶 - 無限制
    期貨: 經典帳戶 - 最多取消500單; 統一帳戶 - 最多取消500單
    期權: 統一帳戶 - 無限制

    HTTP請求

    POST /v5/order/cancel-all

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse
    symbolfalsestring合約名稱. 對於linear & inverse: 若不傳baseCoinsettleCoin, 該字段必傳
    baseCoinfalsestring交易幣種
    • 對於經典帳戶下的linear & inverse: 當通過baseCoin來全部撤單時,會將linear和inverse訂單全部撤掉。若不傳symbolbaseCoin, 則該字段必傳
    • 對於統一帳戶下的linear & inverse: 當通過baseCoin來全部撤單時,會將對應category的訂單全部撤掉。若不傳symbolbaseCoin, 則該字段必傳
    • 對於經典帳戶的現貨: 該字段無效
    settleCoinfalsestring結算幣種
    • 對於linear & inverse: 該字段必傳, 若不傳symbolbaseCoin
    • 該字段不支持spot
    orderFilterfalsestring
    • 當category=spot, 該字段可以傳Order(普通單), tpslOrder(止盈止損單), StopOrder(條件單). 若不傳, 則默認是撤掉Order
    • 當category=linear 或者 inverse, 該字段可以傳Order(普通單), StopOrder(條件單, 包括止盈止損單和追蹤出場單). 若不傳, 則所有類型的訂單都會被撤掉
    • 當category=option, 該字段可以傳Order, 不管傳與不傳, 都是撤掉所有訂單
    stopOrderTypefalsestring條件單類型, Stop
  • 僅用於當category=linear 或者 inverse以及orderFilter=StopOrder時, 若想僅取消條件單 (不包括止盈止損單和追蹤出場單), 則可以傳入該字段

  • 響應參數

    參數類型說明
    listarrayObject
    > orderIdstringOrder ID
    > orderLinkIdstringUser customised order ID

    請求示例

    POST /v5/order/cancel-all HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672219779140
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": null,
    "settleCoin": "USDT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "f6a73e1f-39b5-4dee-af21-1460b2e3b27c",
    "orderLinkId": "a001"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672219780463
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/cancel-order.html b/zh-TW/v5/order/cancel-order.html index 382ca0c235..3d68c5e952 100644 --- a/zh-TW/v5/order/cancel-order.html +++ b/zh-TW/v5/order/cancel-order.html @@ -4,14 +4,14 @@ 撤銷委託單 | Bybit API Documentation - +

    撤銷委託單

    統一帳戶覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 期權
    普通帳戶覆蓋範圍: 現貨 / USDT永續 / 反向合約

    重要
    • 您必須指定orderId或者orderLinkId.
    • orderIdorderLinkId之間不匹配, 系統將會優先處理orderId.
    • 您只能撤銷未成交和部分成交的訂單.

    HTTP請求

    POST /v5/order/cancel

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, option
    • 普通帳戶: spot, linear, inverse
    symboltruestring合約名稱
    orderIdfalsestring訂單Id. orderIdorderLinkId必傳其中一個
    orderLinkIdfalsestring用戶自定義訂單Id. orderIdorderLinkId必傳其中一個
    orderFilterfalsestringspot有效. Order: 普通單,tpslOrder: 止盈止損單,StopOrder: 條件單. 若不傳, 默認是Order

    響應參數

    參數類型說明
    orderIdstring訂單Id
    orderLinkIdstring用戶自定義訂單Id

    請求示例

    POST /v5/order/cancel HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672217376681
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCPERP",
    "orderLinkId": null,
    "orderId":"c6f055d9-7f21-4079-913d-e6523a9cfffa"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "c6f055d9-7f21-4079-913d-e6523a9cfffa",
    "orderLinkId": "linear-004"
    },
    "retExtInfo": {},
    "time": 1672217377164
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/create-order.html b/zh-TW/v5/order/create-order.html index e81b42e6a0..6b43f2aea7 100644 --- a/zh-TW/v5/order/create-order.html +++ b/zh-TW/v5/order/create-order.html @@ -4,7 +4,7 @@ 創建委託單 | Bybit API Documentation - + @@ -25,7 +25,7 @@ 使用API的客戶預設接受本條款並負有配合調整的義務。

    提示

    對於普通帳戶進行全倉槓桿交易時,您需要先去這裡進行借貸

    現貨條件單規則

    現貨支持止盈止損單, 條件單, 但是背後的處理邏輯略有不同
    經典帳戶: 當止盈止損或者條件單創建後, 您將會得到一個訂單ID. 當它被觸發後, 您將獲取到一個全新的訂單ID
    統一帳戶: 當止盈止損或者條件單創建後, 您將會得到一個訂單ID. 當它被觸發後, 訂單ID將會保持不變

    HTTP請求

    POST /v5/order/create

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse
    symboltruestring合約名稱
    isLeveragefalseinteger是否借貸. 僅統一帳戶的現貨交易有效. 0(default): 否,則是幣幣訂單, 1: 是,則是槓桿訂單
    sidetruestringBuy, Sell
    orderTypetruestring訂單類型. Market, Limit
    qtytruestring訂單數量
    • 若category=spot, 且是Market Buy單,則qty表示為報價幣種金額,精度需要满足交易產品規格接口現貨下的quotePrecision
    • 除此之外, 輸入的qty需要是各產品規定的minOrderQty的整數倍
    • 特別地, 對於期貨而言, 如果您傳入qty="0", 則可以全部平掉對應合約的倉位
    pricefalsestring訂單價格.
    • 市價單將會忽視該字段
    • 請通過該接口確認最低價格和精度要求
    • 如果有持倉, 確保價格優於強平價格
    triggerDirectionfalseinteger條件單參數. 用於辨別期望的方向.
    • 1: 當市場價上漲到了triggerPrice時觸發條件單
    • 2: 當市場價下跌到了triggerPrice時觸發條件單
    linearinverse有效
    orderFilterfalsestring指定訂單品種. Order: 普通單,tpslOrder: 止盈止損單,StopOrder: 條件單. 若不傳, 默認Order
    僅對現貨有效
    triggerPricefalsestring
    • 對於期貨, 是條件單觸發價格參數. 若您希望市場價是要上升後觸發, 確保:
      triggerPrice > 市場價格
      否則, triggerPrice < 市場價格
    • 對於現貨, 這是下止盈止損單或者條件單的觸發價格參數
    triggerByfalsestring條件單參數. 觸發價格類型. LastPrice, IndexPrice, MarkPrice
    僅對linearinverse有效
    orderIvfalsestring隱含波動率. 僅option有效. 按照實際值傳入, e.g., 對於10%, 則傳入0.1. orderIvprice有更高的優先級
    timeInForcefalsestring訂單執行策略
    • 市價單,系統直接使用IOC
    • 若不傳,默認使用GTC
    positionIdxfalseinteger倉位標識, 用戶不同倉位模式. 該字段對於雙向持倉模式(僅USDT永續和反向期貨有雙向模式)是必傳:
    • 0: 單向持倉
    • 1: 買側雙向持倉
    • 2: 賣側雙向持倉
    僅對linearinverse有效
    orderLinkIdfalsestring用戶自定義訂單Id. category=option時,該參數必傳
    takeProfitfalsestring止盈價格, 僅對linearinverse有效
    stopLossfalsestring止損價格, 僅對linearinverse有效
    tpTriggerByfalsestring觸發止盈的價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    僅對linearinverse有效
    slTriggerByfalsestring觸發止損的價格類型. MarkPrice, IndexPrice, 默認:LastPrice
    僅對linearinverse有效
    reduceOnlyfalseboolean什麼是只減倉? true 將這筆訂單設為只減倉
    • 當減倉時, reduceOnly=true必傳
    • 只減倉單的止盈止損不生效
    linear, inverseoption有效
    closeOnTriggerfalseboolean什麼是觸發後平倉委託?此選項可以確保您的止損單被用於減倉(平倉)而非加倉,並且在可用保證金不足的情況下,取消其他委託,騰出保證金以確保平倉委託的執行.
    僅對linearinverse有效
    smpTypefalsestringSmp執行類型. 什麼是SMP?
    mmpfalseboolean做市商保護. 僅option有效. true 表示該訂單是做市商保護訂單. 什麼是做市商保護?
    tpslModefalsestring止盈止損模式
    • Full: 全部倉位止盈止損. 此時, tpOrderType或者slOrderType必須傳Market
    • Partial: 部分倉位止盈止損. 支持創建限價止盈止損. 注意: 創建限價止盈止損時, tpslMode必傳且為Partial
    僅對linearinverse有效
    tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 僅tpslMode=Partial且tpOrderType=Limit時有效
    僅對linearinverse有效
    slLimitPricefalsestring觸發止損後轉換為限價單的價格. 僅tpslMode=Partial且slOrderType=Limit時有效
    僅對linearinverse有效
    tpOrderTypefalsestring止盈觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持tpOrderType=Market
    僅對linearinverse有效
    slOrderTypefalsestring止損觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持slOrderType=Market
    僅對linearinverse有效

    響應參數

    參數類型說明
    orderIdstring訂單ID
    orderLinkIdstring用戶自定義訂單ID

    請求示例

    POST /v5/order/create HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672211928338
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    // 現貨下僅maker單
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","timeInForce":"PostOnly","orderLinkId":"spot-test-01","isLeverage":0,"orderFilter":"Order"}

    // 現貨止盈止損單
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","triggerPrice": "15000", "timeInForce":"Limit","orderLinkId":"spot-test-02","isLeverage":0,"orderFilter":"tpslOrder"}

    // 槓桿交易單 (統一帳戶)
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"0.1","price":"15600","timeInForce":"Limit","orderLinkId":"spot-test-limit","isLeverage":1,"orderFilter":"Order"}

    // 現貨市價單, qty為報價幣種金額
    {"category":"spot","symbol":"BTCUSDT","side":"Buy","orderType":"Market","qty":"200","timeInForce":"IOC","orderLinkId":"spot-test-04","isLeverage":0,"orderFilter":"Order"}


    // USDT永續開多倉訂單 (單向持倉)
    {"category":"linear","symbol":"BTCUSDT","side":"Buy","orderType":"Limit","qty":"1","price":"25000","timeInForce":"GTC","positionIdx":0,"orderLinkId":"usdt-test-01","reduceOnly":false,"takeProfit":"28000","stopLoss":"20000","tpslMode":"Partial","tpOrderType":"Limit","slOrderType":"Limit","tpLimitPrice":"27500","slLimitPrice":"20500"}

    // USDT永續平多倉訂單 (單向持倉)
    {"category": "linear", "symbol": "BTCUSDT", "side": "Sell", "orderType": "Limit", "qty": "1", "price": "30000", "timeInForce": "GTC", "positionIdx": 0, "orderLinkId": "usdt-test-02", "reduceOnly": true}

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "orderId": "1321003749386327552",
    "orderLinkId": "spot-test-postonly"
    },
    "retExtInfo": {},
    "time": 1672211918471
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/dcp.html b/zh-TW/v5/order/dcp.html index afe7a719c0..9b277fe698 100644 --- a/zh-TW/v5/order/dcp.html +++ b/zh-TW/v5/order/dcp.html @@ -4,7 +4,7 @@ 設置斷線保護時間 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    設置斷線保護時間

    覆蓋範圍: 期權 (統一帳戶)

    信息

    什麼是斷線保護 (Disconnection Protect)?

    Bybit基於websocket私有連接和心跳機制,提供斷線保護功能。這計時從第一次斷開開始。如果Bybit服務器在一段時間內沒有收到客戶端的重連超過10秒(默認)並 恢復心跳“ping”,則客戶端處於“斷線保護”狀態,客戶所有活躍的期權訂單將自動取消。如果在 10 秒內,客戶端重新連接並恢復心跳“ping”,計時會在下次斷線 時重置並重新開始。

    如何啟用斷線保護

    若您需要開啟/關閉斷線保護功能, 您可以諮詢客戶經理. 開啟後,默認的斷線保護時間為10秒。

    適用對象

    僅適用於期權交易。

    提示

    API請求發送成功後,系統需要一定的時間才能生效。建議10秒後再查詢或設置。

    • 您可以使用該接口來查詢當前DCP配置
    • 您的私有連接必須訂閱斷線保護, 才能確保DCP功能被觸發

    HTTP請求

    POST /v5/order/disconnected-cancel-all

    請求參數

    參數是否必需類型說明
    timeWindowtrueinteger斷線保護時間窗口. [3, 300], 單位: 秒

    響應參數

    請求示例

    POST v5/order/disconnected-cancel-all HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675852742375
    X-BAPI-RECV-WINDOW: 50000
    Content-Type: application/json

    {
    "timeWindow": 40
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success"
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/open-order.html b/zh-TW/v5/order/open-order.html index ce7c82102a..baf85df4c0 100644 --- a/zh-TW/v5/order/open-order.html +++ b/zh-TW/v5/order/open-order.html @@ -4,14 +4,14 @@ 查詢實時委託單 | Bybit API Documentation - +

    查詢實時委託單

    實時查詢未成交或部分成交的訂單信息. 若需要查詢更久的訂單紀錄,請使用查詢歷史訂單接口.

    統一帳戶覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權
    普通帳戶覆蓋範圍: 現貨 / USDT永續 / 反向合約

    提示
    • 該接口還支持查詢已成交,取消和拒絕類型的訂單信息,但僅限最近10分鐘內且最多每個UID下提供500條數據.
    • 您可以通過指定symbol, baseCoin, orderId 和 orderLinkId字段來查詢。如果您使用多字段組合,系統的查詢優先級如下: orderId > orderLinkId > symbol > baseCoin.
    • 返回的結果將以createdTime從新到舊排序.
    信息

    普通帳戶現貨交易僅能查詢活動委託單

    HTTP請求

    GET /v5/order/realtime

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse
    symbolfalsestring合約名稱. 對於linear, symbol, baseCoinsettleCoin必傳其中一個
    baseCoinfalsestring交易幣種. 支持linear, inverseoption. 對於若不傳,則返回期權下所有活動委託單
    settleCoinfalsestring結算幣種
    • linear: symbolsettleCoin必傳其中一個
    • spot: 該字段無效
    orderIdfalsestring訂單Id
    orderLinkIdfalsestring用戶自定義訂單Id
    openOnlyfalseinteger
    • 統一帳戶 & 普通帳戶0(默認): 僅查詢活動委託訂單
    • 統一帳戶: 1,統一帳戶(反向)和普通帳戶: 2
      返回最近10分鐘僅終態(已取消/拒絕/完全成交)的訂單數據, 每個帳戶下最多保留500條紀錄,如果因Bybit服務更新重啟則該部分數據會情況並重新累計, 但是訂單紀錄仍然可以從歷史訂單中查詢到
    • 普通帳戶現貨: 該字段無效, 僅返回活動委託單
    orderFilterfalsestringOrder: 活動單, StopOrder: 條件單, 支持現貨和期貨, tpslOrder: 止盈止損單, 僅現貨有效, OcoOrder: OCO訂單, 僅UTA現貨有效
    • 普通帳戶現貨: 默認是Order活動單
    • 其他: 默認是全部類型訂單
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    nextPageCursorstring游標,用於翻頁
    listarrayObject
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義Id
    > blockTradeIdstringParadigm大宗交易Id
    > symbolstring合約名稱
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > isLeveragestring是否借貸. 僅統一帳戶spot有效. 0: 否, 1: 是. 普通帳戶現貨交易不支持, 總是0
    > positionIdxinteger倉位標識。用戶不同倉位模式
    > orderStatusstring訂單狀態
    > cancelTypestring訂單被取消類型
    > rejectReasonstring拒絕原因. 普通帳戶現貨交易不支持
    > avgPricestring訂單平均成交價格. 若沒有成交,則返回"0"
    > leavesQtystring訂單剩餘未成交的數量. 普通帳戶現貨交易不支持
    > leavesValuestring訂單剩餘未成交的價值. 普通帳戶現貨交易不支持
    > cumExecQtystring訂單累計成交數量
    > cumExecValuestring訂單累計成交價值. 普通帳戶現貨交易不支持
    > cumExecFeestring訂單累計成交的手續費. 普通帳戶現貨交易不支持
    > timeInForcestring執行策略
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
    > stopOrderTypestring條件單類型
    > orderIvstring隱含波動率
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損. 現貨不返回該字段, 期權總是返回""
    > ocoTriggerTypestring現貨OCO訂單的觸發類型.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. 經典帳戶現貨不支持該字段
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > triggerDirectioninteger觸發方向. 1: 上漲, 2: 下跌
    > triggerBystring觸發價格的觸發類型
    > lastPriceOnCreatedstring下單時的市場價格
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > placeTypestring下單類型, 僅期權使用. iv, price
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring創建訂單的時間戳 (毫秒)
    > updatedTimestring訂單更新的時間戳 (毫秒)

    請求示例

    GET /v5/order/realtime?symbol=ETHUSDT&category=linear&openOnly=0&limit=1  HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672219525810
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "fd4300ae-7847-404e-b947-b46980a4d140",
    "orderLinkId": "test-000005",
    "blockTradeId": "",
    "symbol": "ETHUSDT",
    "price": "1600.00",
    "qty": "0.10",
    "side": "Buy",
    "isLeverage": "",
    "positionIdx": 1,
    "orderStatus": "New",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_NoError",
    "avgPrice": "0",
    "leavesQty": "0.10",
    "leavesValue": "160",
    "cumExecQty": "0.00",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "timeInForce": "GTC",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "2500.00",
    "stopLoss": "1500.00",
    "tpTriggerBy": "LastPrice",
    "slTriggerBy": "LastPrice",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "tpslMode": "Full",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "placeType": "",
    "createdTime": "1684738540559",
    "updatedTime": "1684738540561"
    }
    ],
    "nextPageCursor": "page_args%3Dfd4300ae-7847-404e-b947-b46980a4d140%26symbol%3D6%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1684765770483
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/order-list.html b/zh-TW/v5/order/order-list.html index 013095e07b..c639d48e65 100644 --- a/zh-TW/v5/order/order-list.html +++ b/zh-TW/v5/order/order-list.html @@ -4,14 +4,14 @@ 查詢歷史訂單 | Bybit API Documentation - +

    查詢歷史訂單

    獲取歷史訂單紀錄. 由於訂單創建/撤銷是異步的, 該接口返回數據可能會有延遲. 若您想實時獲取訂單信息, 您可以查詢該接口或者通過websocket推送(推薦)

    統一帳戶覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權
    普通帳戶覆蓋範圍: USDT永續 / 反向合約 / 現貨

    信息
    • 7天內的訂單: 支持查詢全狀態
    • 7天外的訂單: 可以查詢僅成交的訂單類型
    • 您可以通過指定symbol, baseCoin, orderId 和 orderLinkId字段來查詢。如果您使用多字段組合,系統的查詢優先級如下: orderId > orderLinkId > symbol > baseCoin.
    提示

    普通現貨僅能查詢終態訂單

    HTTP請求

    GET /v5/order/history

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse
    symbolfalsestring合約名稱
    baseCoinfalsestring交易幣種. 統一帳戶(反向)以及普通帳戶不支持該字段的查詢
    settleCoinfalsestring結算幣種. 統一帳戶(反向)以及普通帳戶不支持該字段的查詢
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring用戶自定義訂單ID
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單, 支持現貨和期貨, tpslOrder: 現貨止盈止損單, OcoOrder: OCO訂單, 僅UTA現貨有效
    • 普通帳戶現貨: 默認是Order活動單
    • 其他: 默認是全部類型訂單
    orderStatusfalsestring訂單狀態
    • 普通帳戶spot: 該字段無效
    • 其他: 不傳則默認查詢所有狀態
    不傳則默認查詢所有狀態
    startTimefalseinteger開始時間戳 (毫秒)
    • 普通現貨暫不支持
    • startTime 和 endTime要麼同時傳入,要麼同時不傳
    • 若不傳,默認查詢過去7天的數據
    • startTime 和 endTime每次傳遞的間隔必須在7天內
    endTimefalseinteger結束時間戳 (毫秒)
    • startTime 和 endTime每次傳遞的間隔必須在7天內
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義Id
    > blockTradeIdstring大宗交易訂單Id
    > symbolstring合約名稱
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > isLeveragestring是否借貸. 僅統一帳戶spot有效. 0: 否, 1: 是. 普通帳戶現貨交易不支持, 總是0
    > positionIdxinteger倉位標識。用戶不同倉位模式
    > orderStatusstring訂單狀態
    > cancelTypestring訂單被取消類型
    > rejectReasonstring拒絕原因. 普通帳戶現貨交易不支持
    > avgPricestring訂單平均成交價格. 若沒有成交,則返回""
    > leavesQtystring訂單剩餘未成交的數量. 普通帳戶現貨交易不支持
    > leavesValuestring訂單剩餘未成交的價值. 普通帳戶現貨交易不支持
    > cumExecQtystring訂單累計成交數量
    > cumExecValuestring訂單累計成交價值. 普通帳戶現貨交易不支持
    > cumExecFeestring訂單累計成交的手續費. 普通帳戶現貨交易不支持
    > timeInForcestring執行策略
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
  • Block trade Roll Back, Block trade-Limit: 統一帳戶大宗交易獨有的兩個枚舉值
  • > stopOrderTypestring條件單類型
    > orderIvstring隱含波動率
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損. 現貨不返回該字段, 期權總是返回""
    > ocoTriggerTypestring現貨OCO訂單的觸發類型.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. 經典帳戶現貨不支持該字段
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > triggerDirectioninteger觸發方向. 1: 上漲, 2: 下跌
    > triggerBystring觸發價格的觸發類型
    > lastPriceOnCreatedstring下單時的市場價格
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > placeTypestring下單類型, 僅期權使用. iv, price
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring創建訂單的時間戳 (毫秒)
    > updatedTimestring訂單更新的時間戳 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/order/history?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672221263407
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "14bad3a1-6454-43d8-bcf2-5345896cf74d",
    "orderLinkId": "YLxaWKMiHU",
    "blockTradeId": "",
    "symbol": "BTCUSDT",
    "price": "26864.40",
    "qty": "0.003",
    "side": "Buy",
    "isLeverage": "",
    "positionIdx": 1,
    "orderStatus": "Cancelled",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_PostOnlyWillTakeLiquidity",
    "avgPrice": "0",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.000",
    "cumExecValue": "0",
    "cumExecFee": "0",
    "timeInForce": "PostOnly",
    "orderType": "Limit",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "0.00",
    "reduceOnly": false,
    "closeOnTrigger": false,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "tpslMode": "",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "placeType": "",
    "createdTime": "1684476068369",
    "updatedTime": "1684476068372"
    }
    ],
    "nextPageCursor": "page_token%3D39380%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1684766282976
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/order/spot-borrow-quota.html b/zh-TW/v5/order/spot-borrow-quota.html index aff458c474..ec81c7f61c 100644 --- a/zh-TW/v5/order/spot-borrow-quota.html +++ b/zh-TW/v5/order/spot-borrow-quota.html @@ -4,13 +4,13 @@ 查詢用戶可用額度 (現貨) | Bybit API Documentation - +

    查詢用戶可用額度 (現貨)

    可以查詢現貨幣幣交易以及槓桿交易時, 可用對應幣種的實時餘額

    覆蓋範圍: 現貨 (統一帳戶)

    HTTP請求

    GET /v5/order/spot-borrow-check

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. spot
    symboltruestring交易對名稱
    sidetruestring交易方向. Buy,Sell

    響應參數

    參數類型說明
    symbolstring交易對名稱
    sidestring方向
    maxTradeQtystring最大可用於交易的交易幣種數量
    • 若啟用了全倉槓桿且是槓桿幣對, 則返回本身擁有的+最大可借貸數量
    • 否則, 僅代表實際的餘額
    • 最多支持4位小數
    maxTradeAmountstring最大可用於交易的報價幣種金額
    • 若啟用了全倉槓桿且是槓桿幣對, 則返回本身擁有的+最大可借貸數量
    • 否則, 僅代表實際的餘額
    • 最多支持8位小數
    spotMaxTradeQtystring無論是否開啟了槓桿, 這個字段表示交易幣種在幣幣交易下的可交易數量或者餘額, 最多支持4位小數
    spotMaxTradeAmountstring無論是否開啟了槓桿, 這個字段表示報價幣種在幣幣交易下的可交易數量或者餘額, 最多支持8位小數
    borrowCoinstring借貸幣種

    請求示例

    GET /v5/order/spot-borrow-check?category=spot&symbol=BTCUSDT&side=Buy HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672228522214
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "symbol": "BTCUSDT",
    "maxTradeQty": "6.6065",
    "side": "Buy",
    "spotMaxTradeAmount": "9004.75628594",
    "maxTradeAmount": "218014.01330797",
    "borrowCoin": "USDT",
    "spotMaxTradeQty": "0.2728"
    },
    "retExtInfo": {},
    "time": 1698895841534
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/otc/bind-uid.html b/zh-TW/v5/otc/bind-uid.html index c26bea90d9..cfef597dc1 100644 --- a/zh-TW/v5/otc/bind-uid.html +++ b/zh-TW/v5/otc/bind-uid.html @@ -4,13 +4,13 @@ 綁定/解綁UID | Bybit API Documentation - +
    -

    綁定/解綁UID

    對於場外借貸產品, 您可以自行綁定新的UID到風險單元內或者解綁某個UID

    信息
    • 風險單元的主UID不能解綁
    • 該接口只能由在風險單元內的UID來請求
    • 綁定的UID必須升級到了統一帳戶

    HTTP 請求

    POST /v5/ins-loan/association-uid

    請求參數

    參數是否必需類型說明
    uidtruestringUID
    operatetruestring0: 綁定, 1: 解綁

    響應參數

    參數類型說明
    uidstringUID
    operatestring0: 綁定, 1: 解綁

    請求示例

    POST /v5/ins-loan/association-uid HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1699257853101
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    Content-Length: 43

    {
    "uid": "592324",
    "operate": "0"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "uid": "592324",
    "operate": "0"
    },
    "retExtInfo": {},
    "time": 1699257746135
    }
    - +

    綁定/解綁UID

    對於場外借貸產品, 您可以自行綁定新的UID到風險單元內或者解綁某個UID

    信息
    • 風險單元的主UID不能解綁
    • 該接口只能由在風險單元內的UID來請求
    • 綁定的UID必須升級到了UTA Pro

    HTTP 請求

    POST /v5/ins-loan/association-uid

    請求參數

    參數是否必需類型說明
    uidtruestringUID
    operatetruestring0: 綁定, 1: 解綁

    響應參數

    參數類型說明
    uidstringUID
    operatestring0: 綁定, 1: 解綁

    請求示例

    POST /v5/ins-loan/association-uid HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1699257853101
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX
    Content-Type: application/json
    Content-Length: 43

    {
    "uid": "592324",
    "operate": "0"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "uid": "592324",
    "operate": "0"
    },
    "retExtInfo": {},
    "time": 1699257746135
    }
    + \ No newline at end of file diff --git a/zh-TW/v5/otc/loan-info.html b/zh-TW/v5/otc/loan-info.html index 685f3f3847..99860d6347 100644 --- a/zh-TW/v5/otc/loan-info.html +++ b/zh-TW/v5/otc/loan-info.html @@ -4,13 +4,13 @@ 查詢借貸訂單信息 | Bybit API Documentation - +

    查詢借貸訂單信息

    查詢借貸訂單的詳情

    提示
    • 默認查詢過去2年的數據
    • 最多支持查詢過去2年的數據

    HTTP 請求

    GET /v5/ins-loan/loan-order

    請求參數

    參數是否必須類型說明
    orderIdfalsestring借貸訂單ID. 若不傳,則返回全部. 按照loanTime降序排列
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger返回數量限制. [1, 100], 默認: 10

    返回參數

    參數類型說明
    loanInfoarrayObject
    > orderIdstring借貸訂單ID
    > orderProductIdstring產品ID
    > parentUidstring綁定場外借貸產品的UID
    > loanTimestring放款時間(毫秒)
    > loanCoinstring借款幣種
    > loanAmountstring借款金額
    > unpaidAmountstring未還本金
    > unpaidIntereststring未還利息
    > repaidAmountstring已還本金
    > repaidIntereststring已還利息
    > interestRatestring日利率
    > statusstring1:未還清; 2:已還清
    > leveragestring該借貸產品的最大槓桿倍數
    > supportSpotstring是否支持現貨. 0:否; 1:是
    > supportContractstring是否支持合約 . 0: 否; 1: 是
    > supportMarginTradingstring是否支持現貨槓桿交易. 0: 否; 1: 是
    > withdrawLinestring限制提幣線
    > transferLinestring限制劃轉線
    > spotBuyLinestring限制現貨買入線
    > spotSellLinestring限制現貨交易線
    > contractOpenLinestring限制USDT永續合約開倉線
    > liquidationLinestring強平線
    > stopLiquidationLinestring停止強平線
    > contractLeveragestring允許USDT永續默認開倉倍數
    > transferRatiostring現貨帳戶到合約帳戶的借貸資金劃轉比例
    > spotSymbolsarray現貨交易對白名單. 若沒有配置白名單, 則返回[]
    > contractSymbolsarrayUSDT永續合約交易對白名單
    • 若沒有配置白名單, 則返回[]
    • 若supportContract="0", 則也是[]
    > supportUSDCContractstring是否支持USDC合約交易. '0':否; '1':是
    > supportUSDCOptionsstring是否支持期權交易. '0':false; '1':true
    > USDTPerpetualOpenLinestring限制USDT永續的開倉線
    > USDCContractOpenLinestring限制USDC合約的開倉線
    > USDCOptionsOpenLinestring限制期權的開倉線
    > USDTPerpetualCloseLinestring限制USDT永續的交易線
    > USDCContractCloseLinestring限制USDC合約的交易線
    > USDCOptionsCloseLinestring限制期權的交易線
    > USDCContractSymbolsarrayUSDC合約的白名單交易對
    • 若沒有配置白名單, 則是空數組[], 可以交易任何合約
    • 如果 supportUSDCContract="0", 則也是空數組[]
    > USDCOptionsSymbolsarray期權的白名單交易對
    • 若沒有配置白名單, 則是空數組[], 可以交易任何合約
    • 如果 supportUSDCOptions="0", 則也是空數組[]
    > marginLeveragestring全倉槓桿允許可開的最高槓桿
    > USDTPerpetualLeveragearrayObject
    • 如果 supportContract="0", 則返回空數組[]
    • 如果沒有配置USDT永續交易對白名單, 則返回所有的合約和槓桿
    • 如果有白名單配置, 則只返回白名單列表的合約和槓桿
    >> symbolstring合約名
    >> leveragestring最高可開槓桿
    > USDCContractLeveragearrayObject
    • 如果 supportUSDCContract="0", 則返回空數組[]
    • 如果沒有配置USDC合約交易對白名單, 則返回所有的合約和槓桿
    • 如果有白名單配置, 則只返回白名單列表的合約和槓桿
    >> symbolstring合約名
    >> leveragestring最高可開槓桿

    請求示例

    GET /v5/ins-loan/loan-order HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1678687874060
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "loanInfo": [
    {
    "orderId": "1468005106166530304",
    "orderProductId": "96",
    "parentUid": "1631521",
    "loanTime": "1689735916000",
    "loanCoin": "USDT",
    "loanAmount": "204",
    "unpaidAmount": "52.07924201",
    "unpaidInterest": "0",
    "repaidAmount": "151.92075799",
    "repaidInterest": "0",
    "interestRate": "0.00019178",
    "status": "1",
    "leverage": "4",
    "supportSpot": "1",
    "supportContract": "1",
    "withdrawLine": "",
    "transferLine": "",
    "spotBuyLine": "0.71",
    "spotSellLine": "0.71",
    "contractOpenLine": "0.71",
    "liquidationLine": "0.75",
    "stopLiquidationLine": "0.35000000",
    "contractLeverage": "7",
    "transferRatio": "1",
    "spotSymbols": [],
    "contractSymbols": [],
    "supportUSDCContract": "1",
    "supportUSDCOptions": "1",
    "USDTPerpetualOpenLine": "0.71",
    "USDCContractOpenLine": "0.71",
    "USDCOptionsOpenLine": "0.71",
    "USDTPerpetualCloseLine": "0.71",
    "USDCContractCloseLine": "0.71",
    "USDCOptionsCloseLine": "0.71",
    "USDCContractSymbols": [],
    "USDCOptionsSymbols": [],
    "marginLeverage": "4",
    "USDTPerpetualLeverage": [
    {
    "symbol": "SUSHIUSDT",
    "leverage": "7"
    },
    {
    "symbol": "INJUSDT",
    "leverage": "7"
    },
    {
    "symbol": "RDNTUSDT",
    "leverage": "7"
    },
    {
    "symbol": "ZRXUSDT",
    "leverage": "7"
    },
    {
    "symbol": "HIGHUSDT",
    "leverage": "7"
    },
    {
    "symbol": "WAVESUSDT",
    "leverage": "7"
    },
    ...
    {
    "symbol": "ACHUSDT",
    "leverage": "7"
    },
    {
    "symbol": "SUNUSDT",
    "leverage": "7"
    }
    ],
    "USDCContractLeverage": [
    {
    "symbol": "BTCPERP",
    "leverage": "8"
    },
    {
    "symbol": "BTC-Futures",
    "leverage": "8"
    },
    ...
    {
    "symbol": "ETH-Futures",
    "leverage": "8"
    },
    {
    "symbol": "SOLPERP",
    "leverage": "8"
    },
    {
    "symbol": "ETHPERP",
    "leverage": "8"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1689745773187
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/otc/ltv-convert.html b/zh-TW/v5/otc/ltv-convert.html index 2ad3d5b0f9..61144e6c81 100644 --- a/zh-TW/v5/otc/ltv-convert.html +++ b/zh-TW/v5/otc/ltv-convert.html @@ -4,13 +4,13 @@ 查詢風險率 | Bybit API Documentation - +

    查詢風險率

    HTTP 請求

    GET /v5/ins-loan/ltv-convert

    請求參數

    返回參數

    參數類型說明
    ltvInfoarrayObject
    > ltvstring風險率
    > parentUidstring用戶ID
    > subAccountUidsarray綁定場外借貸產品的UID
    > unpaidAmountstring總負債 (USDT)
    > unpaidInfoarray負債明細
    >> tokenstring幣種
    >> unpaidQtystring未還本金
    >> unpaidIntereststring該字段無效, 暫時請忽略
    > balancestring總資產(保證金幣種資產折算為USDT資產). 可以參考這裡了解詳細計算
    > balanceInfoarray資產明細
    >> tokenstring保證金幣種
    >> pricestring保證金幣種價格
    >> qtystring保證金數量
    >> convertedAmountstring保證金折算金額

    請求示例

    GET /v5/ins-loan/ltv-convert HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686638165351
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "ltvInfo": [
    {
    "ltv": "0.75",
    "parentUid": "xxxxx",
    "subAccountUids": [
    "60568258"
    ],
    "unpaidAmount": "30",
    "unpaidInfo": [
    {
    "token": "USDT",
    "unpaidQty": "30",
    "unpaidInterest": "0"
    }
    ],
    "balance": "40",
    "balanceInfo": [
    {
    "token": "USDT",
    "price": "1",
    "qty": "40",
    "convertedAmount": "40"
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686638166323
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/otc/margin-coin-convert-info.html b/zh-TW/v5/otc/margin-coin-convert-info.html index ee593dfcd7..27e1aebbeb 100644 --- a/zh-TW/v5/otc/margin-coin-convert-info.html +++ b/zh-TW/v5/otc/margin-coin-convert-info.html @@ -4,13 +4,13 @@ 查詢保證金幣種信息 | Bybit API Documentation - +

    查詢保證金幣種信息

    提示
    • 該接口在不傳入api key和secret進行鑒權時, 則返回公共數據
    • 該接口在傳入api key和secret進行鑒權時且uid綁定了場外借貸產品, 則返回特定的保證金幣種數據

    HTTP 請求

    GET /v5/ins-loan/ensure-tokens-convert

    請求參數

    參數是否必須類型說明
    productIdfalsestring產品ID. 若不傳,則返回所有產品的保證金幣種信息. 現貨返回折算率大於0的幣種.

    返回參數

    參數類型說明
    marginTokenarrayObject
    > productIdstring產品ID
    > tokenInfoarray現貨保證金幣種信息
    >> tokenstring保證金幣種
    >> convertRatioListarray保證金幣種折算率列
    >>> ladderstring階梯
    >>> convertRatiostring折算率

    請求示例

    GET /v5/ins-loan/ensure-tokens-convert HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginToken": [
    {
    "productId": "81",
    "tokenInfo": [
    {
    "token": "USDT",
    "convertRatioList": [
    {
    "ladder": "0-500",
    "convertRatio": "0.95"
    },
    {
    "ladder": "500-1000",
    "convertRatio": "0.9"
    },
    {
    "ladder": "1000-2000",
    "convertRatio": "0.8"
    },
    {
    "ladder": "2000-4000",
    "convertRatio": "0.7"
    },
    {
    "ladder": "4000-99999999999",
    "convertRatio": "0.6"
    }
    ]
    }
    ...
    ]
    },
    {
    "productId": "82",
    "tokenInfo": [
    ...
    {
    "token": "USDT",
    "convertRatioList": [
    {
    "ladder": "0-1000",
    "convertRatio": "0.7"
    },
    {
    "ladder": "1000-2000",
    "convertRatio": "0.65"
    },
    {
    "ladder": "2000-99999999999",
    "convertRatio": "0.6"
    }
    ]
    }
    ]
    },
    {
    "productId": "84",
    "tokenInfo": [
    ...
    {
    "token": "BTC",
    "convertRatioList": [
    {
    "ladder": "0-1000",
    "convertRatio": "1"
    },
    {
    "ladder": "1000-5000",
    "convertRatio": "0.9"
    },
    {
    "ladder": "5000-99999999999",
    "convertRatio": "0.55"
    }
    ]
    }
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1683276016497
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/otc/margin-product-info.html b/zh-TW/v5/otc/margin-product-info.html index 93578b7398..5175a6bc32 100644 --- a/zh-TW/v5/otc/margin-product-info.html +++ b/zh-TW/v5/otc/margin-product-info.html @@ -4,13 +4,13 @@ 查詢產品信息 | Bybit API Documentation - +

    查詢產品信息

    提示
    • 該接口在不傳入api key和secret進行鑒權時, 則返回公共產品數據
    • 該接口在傳入api key和secret進行鑒權時且uid綁定了場外借貸產品, 則返回特定的產品數據

    HTTP 請求

    GET /v5/ins-loan/product-infos

    請求參數

    參數是否必須類型說明
    productIdfalsestring產品ID. 若不傳,則返回所有產品數據

    返回參數

    參數類型說明
    marginProductInfoarrayObject
    > productIdstring產品ID
    > leveragestring該借貸產品的最大槓桿倍數
    > supportSpotinteger是否支持現貨. 0:否; 1:是
    > supportContractinteger是否支持合約 . 0: 否; 1: 是
    > withdrawLinestring限制提幣線
    > transferLinestring限制劃轉線
    > spotBuyLinestring限制現貨買入線
    > spotSellLinestring限制現貨交易線
    > contractOpenLinestring限制合約開倉線
    > liquidationLinestring強平線
    > stopLiquidationLinestring停止強平線
    > contractLeveragestring允許USDT永續默認開倉倍數
    > transferRatiostring現貨帳戶到合約帳戶的借貸資金劃轉比例
    > spotSymbolsarray現貨交易對白名單. 若沒有配置白名單, 則返回[]
    > contractSymbolsarrayUSDT永續合約交易對白名單
    • 若沒有配置白名單, 則返回[]
    • 若supportContract="0", 則也是[]
    > supportUSDCContractinteger是否支持USDC合約交易. '0':否; '1':是
    > supportUSDCOptionsinteger是否支持期權交易. '0':false; '1':true
    > supportMarginTradinginteger是否支持現貨槓桿交易. 0: 否; 1: 是
    > USDTPerpetualOpenLinestring限制USDT永續的開倉線
    > USDCContractOpenLinestring限制USDC合約的開倉線
    > USDCOptionsOpenLinestring限制期權的開倉線
    > USDTPerpetualCloseLinestring限制USDT永續的交易線
    > USDCContractCloseLinestring限制USDC合約的交易線
    > USDCOptionsCloseLinestring限制期權的交易線
    > USDCContractSymbolsarrayUSDC合約的白名單交易對
    • 若沒有配置白名單, 則是空數組[], 可以交易任何合約
    • 如果 supportUSDCContract="0", 則也是空數組[]
    > USDCOptionsSymbolsarray期權的白名單交易對
    • 若沒有配置白名單, 則是空數組[], 可以交易任何合約
    • 如果 supportUSDCOptions="0", 則也是空數組[]
    > marginLeveragestring全倉槓桿允許可開的最高槓桿
    > USDTPerpetualLeveragearrayObject
    • 如果 supportContract="0", 則返回空數組[]
    • 如果沒有配置USDT永續交易對白名單, 則返回所有的合約和槓桿
    • 如果有白名單配置, 則只返回白名單列表的合約和槓桿
    >> symbolstring合約名
    >> leveragestring最高可開槓桿
    > USDCContractLeveragearrayObject
    • 如果 supportUSDCContract="0", 則返回空數組[]
    • 如果沒有配置USDC合約交易對白名單, 則返回所有的合約和槓桿
    • 如果有白名單配置, 則只返回白名單列表的合約和槓桿
    >> symbolstring合約名
    >> leveragestring最高可開槓桿

    請求示例

    GET /v5/ins-loan/product-infos?productId=91 HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "marginProductInfo": [
    {
    "productId": "91",
    "leverage": "4.00000000",
    "supportSpot": 1,
    "supportContract": 0,
    "withdrawLine": "",
    "transferLine": "",
    "spotBuyLine": "",
    "spotSellLine": "",
    "contractOpenLine": "",
    "liquidationLine": "0.75",
    "stopLiquidationLine": "0.35000000",
    "contractLeverage": "0",
    "transferRatio": "0",
    "spotSymbols": [],
    "contractSymbols": [],
    "supportUSDCContract": 0,
    "supportUSDCOptions": 0,
    "USDTPerpetualOpenLine": "",
    "USDCContractOpenLine": "",
    "USDCOptionsOpenLine": "",
    "USDTPerpetualCloseLine": "",
    "USDCContractCloseLine": "",
    "USDCOptionsCloseLine": "",
    "USDCContractSymbols": [],
    "USDCOptionsSymbols": [],
    "marginLeverage": "0",
    "USDTPerpetualLeverage": [],
    "USDCContractLeverage": []
    }
    ]
    },
    "retExtInfo": {},
    "time": 1689747746332
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/otc/repay-info.html b/zh-TW/v5/otc/repay-info.html index 718aa7a2de..50c01fb8c1 100644 --- a/zh-TW/v5/otc/repay-info.html +++ b/zh-TW/v5/otc/repay-info.html @@ -4,13 +4,13 @@ 查詢還款信息 | Bybit API Documentation - +

    查詢還款信息

    提示
    • 默認查詢過去2年的數據
    • 最多支持查詢過去2年的數據

    HTTP 請求

    GET /v5/ins-loan/repaid-history

    請求參數

    參數是否必須類型說明
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger返回數量限制. [1, 100]. 默認: 100

    返回參數

    參數類型說明
    repayInfoarrayObject
    > repayOrderIdstring還款訂單號
    > repaidTimestring還款時間(毫秒)
    > tokenstring還款幣種
    > quantitystring還款本金
    > intereststring還款利息
    > businessTypestring還款類型. 1:正常還款; 2:系統強平還款
    > statusstring1:未還清; 2:已還清

    Request Example

    GET /v5/ins-loan/repaid-history HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1678687944725
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXX

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "repayInfo": [
    {
    "repayOrderId": "8189",
    "repaidTime": "1663126393000",
    "token": "USDT",
    "quantity": "30000",
    "interest": "0",
    "businessType": "1",
    "status": "1"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1669366648366
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position.html b/zh-TW/v5/position.html index 4ab740a187..1b15ca2f6d 100644 --- a/zh-TW/v5/position.html +++ b/zh-TW/v5/position.html @@ -4,14 +4,14 @@ 查詢持倉 (實時) | Bybit API Documentation - +

    查詢持倉 (實時)

    該接口可以獲取用戶的持倉信息,比如持倉數量,累計盈虧等

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    信息

    關於反向合約的額外查詢規則,

    1. 通過這樣子查詢"/v5/position/list?category=inverse", 您可以查詢到所有當前持有的反向合約倉位;
    2. symbol字段支持傳入最多10個反向合約;

    HTTP 請求

    GET /v5/position/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear,inverse, option
    • 普通帳戶: linear, inverse
    symbolfalsestring合約名稱
    • 若傳了symbol, 則不管是否有倉位都返回該symbol數據
    • symbol不傳但傳了settleCoin, 則僅返回有實際倉位的數據
    baseCoinfalsestring交易幣種. 僅option. 若不傳,則返回期權下所有持倉
    settleCoinfalsestring結算幣種. 對於USDT和USDC期貨而言,symbolsettleCon必傳其中一個, 若都傳,則symbol有更高的優先級
    limitfalseinteger每頁數量限制. [1, 200]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > positionIdxinteger倉位標識符, 用于在不同仓位模式下标识仓位
    > riskIdinteger风险限额ID,參見風險限額接口. 注意:若賬戶為組合保證金模式(PM),該字段返回0,風險限額規則失效
    > riskLimitValuestring當前風險限額ID對應的持倉限制量. 注意:若賬戶為組合保證金模式(PM),該字段返回"",風險限額規則失效
    > symbolstring合約名称
    > sidestring持倉方向,Buy:多头;Sell:空头.
    • 經典帳戶的單向模式下和統一帳戶的反向合約: 空倉時返回None.
    • 統一帳戶(正向合約): 單向或對沖模式空的仓位返回空字符串
    > sizestring當前倉位的合约數量
    > avgPricestring當前倉位的平均入場價格
  • 對於8小時結算的USDC合約倉位, 該字段表示的是平均開倉價格, 不隨著結算而改變
  • > positionValuestring仓位的價值
    > tradeModeinteger交易模式。
    • 統一帳戶 (反向合約) & 普通帳戶: 0: 全倉, 1: 逐倉
    • 統一帳戶: 廢棄, 總是 0
    > autoAddMargininteger是否自動追加保證金. 0: 否, 1: 是. 僅當統一帳戶(除反向合約)開啟了帳戶維度的逐倉保證金模式, 該字段才有意義
    > positionStatusString倉位状态. Normal,Liq, Adl
    > leveragestring當前倉位的槓桿,仅适用于合约. 注意:若賬戶為組合保證金模式(PM),該字段返回空字符串,槓桿規則失效
    > markPricestringsymbol 的最新標記價格
    > liqPricestring倉位強平價格,
    • UTA(反向合約) & 普通账户 & UTA(開啟逐倉保證金模式):是逐倉和全倉持仓的真實價格, 當強平價 <= minPrice或者 強平價 >= maxPrice, 則為""
    • 統一帳戶(全倉保證金):是全倉持仓的预估价格(因为统一帳戶模式是按照帳戶維度控制风险率), 當強平價 <= minPrice或者 強平價 >= maxPrice, 則為""
    但是對於組合保證金模式,此字段為空,不會提供強平價格
    > bustPricestring倉位破產價格. 統一保證金模式返回"", 無倉位破產價格 (不包括統一帳戶下的反向交易)
    > positionIMstring倉位起始保證金. 組合保證金模式(PM)下, 該字段返回為空字符串
    > positionMMstring倉位維持保證金. 組合保證金模式(PM)下, 該字段返回為空字符串
    > tpslModestring該字段廢棄, 無意義, 總是返回"Full". 期權總是返回""
    > positionBalancestring倉位保證金. 組合保證金模式(PM)下, 該字段返回為空字符串
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > trailingStopstring追蹤止損(與當前價格的距離)
    > unrealisedPnlstring未结盈亏
    > cumRealisedPnlstring累计已结盈亏
    • 期貨: 是從第一次開始有持倉加總的已結盈虧
    • 期權: 它是本次持倉的加總已結盈虧
    > adlRankIndicatorinteger自動減倉燈. 什麼是自動減倉機制?
    > isReduceOnlyboolean僅當Bybit需要降低某個Symbol的風險限額時有用
    • true: 僅允許減倉操作. 您可以考慮一系列的方式, 比如, 降低risk limit檔位, 或者同檔位修改槓桿或減少倉位, 或者增加保證金, 或者撤單, 這些操作做完後, 可以主動調用確認新的風險限額接口
    • false(默認): 沒有交易限制, 表示您的倉位在系統調整時處於風險水平之下
    • 僅對逐倉和全倉的期貨倉位有意義
    > mmrSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改MMR的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了MMR調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > leverageSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改槓桿的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了槓桿調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > createdTimestring倉位創建時間
    > updatedTimestring倉位數據更新時間
    > seqlong序列號, 用於關聯成交和倉位的更新
    • 不同的幣對會存在相同seq, 可以使用seq + symbol來做唯一性識別
    • 如果該幣對從未被交易過, 查詢時則會返回"-1"
    • 對於更新槓桿、更新風險限額等非交易行為, 將會返回上一次成交時更新的seq
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/position/list?category=linear&symbol=XRPUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672280218882
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "positionIdx": 0,
    "riskId": 1,
    "riskLimitValue": "150",
    "symbol": "BTCUSD",
    "side": "Sell",
    "size": "300",
    "avgPrice": "27464.50441675",
    "positionValue": "0.01092319",
    "tradeMode": 0,
    "positionStatus": "Normal",
    "autoAddMargin": 1,
    "adlRankIndicator": 2,
    "leverage": "10",
    "positionBalance": "0.00139186",
    "markPrice": "28224.50",
    "liqPrice": "",
    "bustPrice": "999999.00",
    "positionMM": "0.0000015",
    "positionIM": "0.00010923",
    "tpslMode": "Full",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "trailingStop": "0.00",
    "unrealisedPnl": "-0.00029413",
    "cumRealisedPnl": "-0.00096902",
    "seq": 5723621632,
    "isReduceOnly": false,
    "mmrSysUpdateTime": "",
    "leverageSysUpdatedTime": "",
    "createdTime": "1676538056258",
    "updatedTime": "1697673600012"
    }
    ],
    "nextPageCursor": "",
    "category": "inverse"
    },
    "retExtInfo": {},
    "time": 1697684980172
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/auto-add-margin.html b/zh-TW/v5/position/auto-add-margin.html index 63c15cb437..febebe28fe 100644 --- a/zh-TW/v5/position/auto-add-margin.html +++ b/zh-TW/v5/position/auto-add-margin.html @@ -4,14 +4,14 @@ 設置自動追加保證金 | Bybit API Documentation - +

    設置自動追加保證金

    開關自動追加保證金,僅適用於逐倉保證金模式

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    POST /v5/position/set-auto-add-margin

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse
    symboltruestring合約名稱
    autoAddMargintrueinteger是否自動追加保證金. 0: 關閉. 1: 開啟
    positionIdxfalseinteger倉位標識,用於標識不同倉位, 雙向持倉模式下,該字段必傳
    • 0: 單向持倉模式
    • 1: 買側雙向持倉模式
    • 2: 賣側雙向持倉模式

    響應參數

    請求示例

    POST /v5/position/set-auto-add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675255134857
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "autoAddmargin": 1,
    "positionIdx": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675255135069
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/close-pnl.html b/zh-TW/v5/position/close-pnl.html index 64979e0c33..8a99cb8b8c 100644 --- a/zh-TW/v5/position/close-pnl.html +++ b/zh-TW/v5/position/close-pnl.html @@ -4,14 +4,14 @@ 查詢平倉盈虧 | Bybit API Documentation - +

    查詢平倉盈虧

    獲取當前用戶的所有平倉盈虧數據,返回結果按照createdTime降序排列.

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    GET /v5/position/closed-pnl

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symbolfalsestring合約名稱
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 100]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > sidestring買賣方向 Buy, Side
    > qtystring訂單數量
    > orderPricestring訂單價格
    > orderTypestring訂單類型. Market,Limit
    > execTypestring執行類型. Trade, BustTrade, SessionSettlePnL, Settle
    > closedSizestring平倉數量
    > cumEntryValuestring被平倉位的累計入場價值
    > avgEntryPricestring平均入場價格
    > cumExitValuestring被平倉位的累計出場價值
    > avgExitPricestring平均出場價格
    > closedPnlstring被平倉位的盈虧
    > fillCountstring成交筆數
    > leveragestring持倉槓桿
    > createdTimestring創建時間 (毫秒)
    > updatedTimestring更新時間 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/position/closed-pnl?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672284128523
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "5a373bfe-188d-4913-9c81-d57ab5be8068%3A1672214887231423699%2C5a373bfe-188d-4913-9c81-d57ab5be8068%3A1672214887231423699",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Market",
    "leverage": "3",
    "updatedTime": "1672214887236",
    "side": "Sell",
    "orderId": "5a373bfe-188d-4913-9c81-d57ab5be8068",
    "closedPnl": "-47.4065323",
    "avgEntryPrice": "1194.97516667",
    "qty": "3",
    "cumEntryValue": "3584.9255",
    "createdTime": "1672214887231423699",
    "orderPrice": "1122.95",
    "closedSize": "3",
    "avgExitPrice": "1180.59833333",
    "execType": "Trade",
    "fillCount": "4",
    "cumExitValue": "3541.795"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672284129153
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/confirm-mmr.html b/zh-TW/v5/position/confirm-mmr.html index 9c152beb5e..e98c998f45 100644 --- a/zh-TW/v5/position/confirm-mmr.html +++ b/zh-TW/v5/position/confirm-mmr.html @@ -4,7 +4,7 @@ 確認新的風險限額 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    確認新的風險限額

    僅適用於當用戶被標記為僅減倉 (請看持倉接口中的isReduceOnly字段) 時, 在用戶主動調整風險水位後, 調用該接口來試算調整後的風 險水平, 若通過(retCode=0), 則系統會移除僅減倉標記, 推薦自行再調用下倉位接口確認isReduceOnly字段是否變成false

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    POST /v5/position/confirm-pending-mmr

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse
    symboltruestring合約名稱

    響應參數

    請求示例

    POST /v5/position/confirm-pending-mmr HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698051123673
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 53

    {
    "category": "linear",
    "symbol": "BTCUSDT"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698051124588
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/cross-isolate.html b/zh-TW/v5/position/cross-isolate.html index 00387f1c44..34ed5aca0a 100644 --- a/zh-TW/v5/position/cross-isolate.html +++ b/zh-TW/v5/position/cross-isolate.html @@ -4,14 +4,14 @@ 切換全倉/逐倉保證金(交易對) | Bybit API Documentation - +

    切換全倉/逐倉保證金(交易對)

    選擇全倉保證金或者是逐倉保證金,請參閱這裡了解關於全倉/逐倉保證金模式。

    統一帳戶覆蓋範圍: 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    POST /v5/position/switch-isolated

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symboltruestring合約名稱
    tradeModetrueinteger0: 全倉. 1: 逐倉
    buyLeveragetruestring買側槓桿倍數. 必須與sellLeverage的值保持相同
    sellLeveragetruestring賣側槓桿倍數. 必須與buyLeverage的值保持相同

    響應參數

    請求示例

    POST /v5/position/switch-isolated HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN-TYPE: 2
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675248447965
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 121

    {
    "category": "linear",
    "symbol": "ETHUSDT",
    "tradeMode": 1,
    "buyLeverage": "10",
    "sellLeverage": "10"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675248433635
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/execution.html b/zh-TW/v5/position/execution.html index ac0471d951..2fa2aacb6c 100644 --- a/zh-TW/v5/position/execution.html +++ b/zh-TW/v5/position/execution.html @@ -4,14 +4,14 @@ 查詢成交紀錄 | Bybit API Documentation - +

    查詢成交紀錄

    獲取用戶成交紀錄,返回結果按execTime降序排列。但是,對於普通帳戶現貨交易,返回結果按execId降序排列

    統一帳戶覆蓋範圍: 現貨 / USDT永續 / USDC永續 / USDC交割 / 反向合約 / 期權
    普通帳戶覆蓋範圍: 現貨 / USDT永續 / 反向合約

    提示
    • 儅execTime相同時,返回會有排序問題,此問題已在優化中預計10月底發佈,如果您想獲取實時成交信息建議使用websocket stream.
    • 單筆訂單可能會有多次成交.
    • 您可以通過指定symbol, baseCoin, orderId 和 orderLinkId字段來查詢。如果您使用多字段組合,系統的查詢優先級如下: orderId > orderLinkId > symbol > baseCoin.

    HTTP 請求

    GET /v5/execution/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse
    symbolfalsestring合約名稱
    orderIdfalsestring訂單Id
    orderLinkIdfalsestring用戶自定義訂單id. 普通帳戶不支持該字段查詢
    baseCoinfalsestring交易幣種. 統一帳戶(反向)和普通帳戶不支持該字段查詢
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    execTypefalsestring執行類型. 普通帳戶現貨交易無效
    limitfalseinteger每頁數量限制. [1, 100]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義訂單id. 普通帳戶現貨交易不支持
    > sidestring訂單方向.買: Buy,賣:Sell
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > leavesQtystring剩餘委託未成交數量. 普通帳戶現貨交易不支持
    > orderTypestring訂單類型. 市價單:Market,限價單:Limit
    > stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则可能返回""或者UNKNOWN. 普通帳戶現貨交易不支持
    > execFeestring交易手續費. 您可以從這裡了解現貨手續費幣種信息
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring交易類型. 普通帳戶現貨交易不支持
    > execValuestring成交價值. 普通帳戶現貨交易不支持
    > execTimestring成交時間(毫秒)
    > isMakerBool是否是 Maker 訂單,true 為 maker 訂單,false 為 taker 訂單
    > feeRatestring手續費率. 普通帳戶現貨交易不支持
    > tradeIvstring隱含波動率,僅期權有效
    > markIvstring標記價格的隱含波動率,僅期權有效
    > markPricestring成交執行時,該 symbol 當時的標記價格. 普通帳戶現貨交易不支持
    > indexPricestring成交執行時,該 symbol 當時的指數價格,目前僅對期權業務有效
    > underlyingPricestring成交執行時,該 symbol 當時的底層資產價格,僅期權有效
    > blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID
    > closedSizestring平倉數量
    > seqlong序列號, 用於關聯成交和倉位的更新
    • 同一時間有多筆成交, seq相同
    • 不同的幣對會存在相同seq, 可以使用seq + symbol來做唯一性識別
    • 經典帳戶下現貨交易沒有該字段
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/execution/list?category=linear&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672283754132
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "132766%3A2%2C132766%3A2",
    "category": "linear",
    "list": [
    {
    "symbol": "ETHPERP",
    "orderType": "Market",
    "underlyingPrice": "",
    "orderLinkId": "",
    "side": "Buy",
    "indexPrice": "",
    "orderId": "8c065341-7b52-4ca9-ac2c-37e31ac55c94",
    "stopOrderType": "UNKNOWN",
    "leavesQty": "0",
    "execTime": "1672282722429",
    "isMaker": false,
    "execFee": "0.071409",
    "feeRate": "0.0006",
    "execId": "e0cbe81d-0f18-5866-9415-cf319b5dab3b",
    "tradeIv": "",
    "blockTradeId": "",
    "markPrice": "1183.54",
    "execPrice": "1190.15",
    "markIv": "",
    "orderQty": "0.1",
    "orderPrice": "1236.9",
    "execValue": "119.015",
    "execType": "Trade",
    "execQty": "0.1",
    "closedSize": "0.1",
    "seq": 4688002127
    }
    ]
    },
    "retExtInfo": {},
    "time": 1672283754510
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/leverage.html b/zh-TW/v5/position/leverage.html index b46ce0125c..a470882bdb 100644 --- a/zh-TW/v5/position/leverage.html +++ b/zh-TW/v5/position/leverage.html @@ -4,14 +4,14 @@ 設置槓桿 | Bybit API Documentation - +

    設置槓桿

    設置槓桿

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    POST /v5/position/set-leverage

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symboltruestring合約名稱
    buyLeveragetruestring[1, 風險限額允許的最大槓桿數]
    • 普通帳戶: 單倉模式下, buyLeverage 必須等於sellLeverage
    • 統一帳戶: 無論什麼模式, buyLeverage必須等於sellLeverage
    sellLeveragetruestring[1, 風險限額允許的最大槓桿數]
    • 普通帳戶: 單倉模式下, buyLeverage 必須等於sellLeverage
    • 統一帳戶: 無論什麼模式, buyLeverage必須等於sellLeverage

    響應參數

    請求示例

    POST /v5/position/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672281605082
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "buyLeverage": "6",
    "sellLeverage": "6"

    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672281607343
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/manual-add-margin.html b/zh-TW/v5/position/manual-add-margin.html index 4a52ea4acc..7ece1316bf 100644 --- a/zh-TW/v5/position/manual-add-margin.html +++ b/zh-TW/v5/position/manual-add-margin.html @@ -4,14 +4,14 @@ 手動增加或減少保證金 | Bybit API Documentation - +

    手動增加或減少保證金

    手動增加或減少保證金,僅適用於逐倉保證金模式

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    HTTP 請求

    POST /v5/position/add-margin

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse
    symboltruestring合約名稱
    margintruestring增加或減少的保證金金額. 增加, 則為正數, 比如10; 減少, 則為負數, 比如-10. 最多支持4位小數
    positionIdxfalseinteger倉位標識,用於標識不同倉位, 雙向持倉模式下,該字段必傳
    • 0: 單向持倉模式
    • 1: 買側雙向持倉模式
    • 2: 賣側雙向持倉模式

    響應參數

    參數類型說明
    categorystring產品類型
    symbolstring合約名称
    positionIdxinteger倉位標識符, 用于在不同仓位模式下标识仓位
    riskIdinteger风险限额ID,參見風險限額接口
    riskLimitValuestring當前風險限額ID對應的持倉限制量
    sizestring當前倉位的合约數量
    avgPricestring當前倉位的平均入場價格
    liqPricestring倉位強平價格
    bustPricestring倉位破產價格
    markPricestring最新標記價格
    positionValuestring仓位的價值
    leveragestring當前倉位的槓桿
    autoAddMargininteger是否自動追加保證金. 0: 否, 1: 是
    positionStatusString倉位状态. Normal, Liq, Adl
    positionIMstring倉位起始保證金
    positionMMstring倉位維持保證金
    takeProfitstring止盈價格
    stopLossstring止損價格
    trailingStopstring追蹤止損(與當前價格的距離)
    unrealisedPnlstring未结盈亏
    cumRealisedPnlstring累计已结盈亏
    createdTimestring倉位創建時間
    updatedTimestring倉位數據更新時間

    請求示例

    POST /v5/position/add-margin HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1684234363665
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 97

    {
    "category": "inverse",
    "symbol": "ETHUSD",
    "margin": "0.01",
    "positionIdx": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "category": "inverse",
    "symbol": "ETHUSD",
    "positionIdx": 0,
    "riskId": 11,
    "riskLimitValue": "500",
    "size": "200",
    "positionValue": "0.11033265",
    "avgPrice": "1812.70004844",
    "liqPrice": "1550.80",
    "bustPrice": "1544.20",
    "markPrice": "1812.90",
    "leverage": "12",
    "autoAddMargin": 0,
    "positionStatus": "Normal",
    "positionIM": "0.01926611",
    "positionMM": "0",
    "unrealisedPnl": "0.00001217",
    "cumRealisedPnl": "-0.04618929",
    "stopLoss": "0.00",
    "takeProfit": "0.00",
    "trailingStop": "0.00",
    "createdTime": "1672737740039",
    "updatedTime": "1684234363788"
    },
    "retExtInfo": {},
    "time": 1684234363789
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/position-mode.html b/zh-TW/v5/position/position-mode.html index 2a8feb13d7..0b5d3e04b1 100644 --- a/zh-TW/v5/position/position-mode.html +++ b/zh-TW/v5/position/position-mode.html @@ -4,14 +4,14 @@ 切換持倉模式 | Bybit API Documentation - +

    切換持倉模式

    該接口支持切換USDT永續和反向交割的持倉模式。如果處於單向持倉模式下,您只能要麼持有多頭要麼空頭倉位;如果處於雙向持倉模式下,您可以同時持倉多頭和空頭的倉位。

    統一帳戶覆蓋範圍: USDT永續 / 反向交割
    普通帳戶覆蓋範圍: USDT永續 / 反向交割

    提示
    • 配置生效優先級: symbol > coin > 系統默認
    • 系統默認: 單向持倉
    • 如果請求是按幣種(settleCoin),則所有基於該settleCoin的交易品種沒有持倉和活動單的將被批量切換,並且基於該settleCoin的新上市交易品種將與您設置的模式相同。

    示例

    系統默認coinsymbol
    初始配置單向持倉未設置過未設置過
    生效結果所有USDT正向交易對都是單向持倉
    變更 1--BTCUSDT 設置為雙向持倉模式
    生效結果當前交易對BTCUSDT為雙向持倉,其他交易對都是單向持倉(繼承系統默認規則
    新上線交易對 ETHUSDT新上線的ETHUSDT為單向持倉 (繼承系統默認規則)
    變更 2-USDT 設置為雙向持倉-
    生效結果當前所有未持倉未有訂單的交易對都是雙向持倉,有持倉和有委託單的交易對不做調整
    新上線交易對 SOLUSDT新上線的SOLUSDT為雙向持倉 (繼承coin規則)
    變更 3--ASXUSDT 設置為單向持倉模式
    生效結果AXSUSDT為單向持倉模式,其餘交易對不做任何變更(繼承coin規則)
    新上線交易對 BITUSDT新上線的BITUSDT為雙向持倉 (繼承coin規則)

    當前合約單雙向持倉切換能力

    普通帳戶統一帳戶
    USDT 永續支持單雙向持倉支持單雙向持倉
    USDC 永續僅支持單向持倉僅支持單向持倉
    反向永續僅支持單向持倉僅支持單向持倉
    反向交割支持單雙向持倉支持單雙向持倉

    HTTP 请求

    POST /v5/position/switch-mode

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear: USDT永續; inverse: 反向交割
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symbolfalsestring合約名稱. symbolcoin必須傳其中一個. symbol有更高優先級
    coinfalsestring結算幣種
    modetrueinteger倉位模式. 0: 單向持倉. 3: 雙向持倉

    響應參數

    請求示例

    POST /v5/position/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1675249072041
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json
    Content-Length: 87

    {
    "category":"inverse",
    "symbol":"BTCUSDH23",
    "coin": null,
    "mode": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1675249072814
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/set-risk-limit.html b/zh-TW/v5/position/set-risk-limit.html index 3b92855c31..d5fcd7226f 100644 --- a/zh-TW/v5/position/set-risk-limit.html +++ b/zh-TW/v5/position/set-risk-limit.html @@ -4,14 +4,14 @@ 設置風險限額 | Bybit API Documentation - +

    設置風險限額

    風險限額會限制你在不同的保證金要求下的可持倉的最大倉位數量,如果要持有更多的倉位,需要更多的保證金要求。本接口可以設置單個倉位的風險限額,下單時如果超過當前的風險限額,則會被拒絕。點擊這裡了解更多關於風險限額.

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    提示

    您可以獲取通過該接口查詢到風險限額信息.

    HTTP 請求

    POST /v5/position/set-risk-limit

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symboltruestring合約名稱
    riskIdtrueinteger風險限額Id
    positionIdxfalseinteger倉位標識,用於標識不同倉位, 雙向持倉模式下,該字段必傳
    • 0: 單向持倉模式
    • 1: 買側雙向持倉模式
    • 2: 賣側雙向持倉模式

    響應參數

    參數類型說明
    categorystring產品類型
    riskIdinteger風險限額Id
    riskLimitValuestring風險限額Id對應的風險限額

    請求示例

    POST /v5/position/set-risk-limit HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672282269774
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category": "linear",
    "symbol": "BTCUSDT",
    "riskId": 4,
    "positionIdx": null
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "riskId": 4,
    "riskLimitValue": "8000000",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1672282270571
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/tpsl-mode.html b/zh-TW/v5/position/tpsl-mode.html index 55cee4c106..b90e70435b 100644 --- a/zh-TW/v5/position/tpsl-mode.html +++ b/zh-TW/v5/position/tpsl-mode.html @@ -4,7 +4,7 @@ 設置止盈止損模式 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    設置止盈止損模式

    提示

    某種程度上來說,該接口已經廢棄, 原因在於新版的止盈止損機制是基於訂單維度. 這個接口當初主要是用於倉位維度的止盈止損

    但是, 您仍然可以使用該接口, 為某個合約設置一個隱式的止盈止損模式, 因為當您在下單接口或者設置止盈止損接口時, 不傳入字段"tpslMode"時, 系統將會獲取一個默認值, 該 默認值實際上是源於是否調用過該接口做過修改, 不曾修改過的symbol, 都是默認Full

    可以將止盈止損模式設置為部分止盈止損或者全部止盈止損

    統一帳戶覆蓋範圍: USDT永續 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    信息

    在部分止盈止損下,您可以設置小於倉位大小的止盈止損數量

    HTTP 請求

    POST /v5/position/set-tpsl-mode

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symboltruestring合約名稱
    tpSlModetruestringTP/SL模式. Full,Partial

    響應參數

    參數類型說明
    tpSlModestringFull,Partial

    請求示例

    POST /v5/position/set-tpsl-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672279325035
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "symbol": "XRPUSDT",
    "category": "linear",
    "tpSlMode": "Full"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "tpSlMode": "Full"
    },
    "retExtInfo": {},
    "time": 1672279322666
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/position/trading-stop.html b/zh-TW/v5/position/trading-stop.html index c86ceff0f7..54409d211c 100644 --- a/zh-TW/v5/position/trading-stop.html +++ b/zh-TW/v5/position/trading-stop.html @@ -4,7 +4,7 @@ 設置止盈止損 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    設置止盈止損

    該接口可以設置止盈、止損和追蹤止損

    統一帳戶覆蓋範圍: USDT永續 / USDC永續 / USDC交割 / 反向合約
    普通帳戶覆蓋範圍: USDT永續 / 反向合約

    提示

    在提交請求後,系統內部將會自動創建對應類型的條件單。若倉位被平,系統將會調整相關條件訂單數量或者取消這些條件單。

    信息

    新版止盈止損, 支持既持有全部止盈止損單, 也可以持有部分止盈止損單

    • 全部倉位止盈止損單: 該接口可用於修改該類型的止盈止損單的參數
    • 部分倉位止盈止損單: 該接口僅能新增部分倉位止盈止損單
    備註

    新版止盈止損下, 調用該接口對持倉上的已有的止盈止損進行單邊止盈或者止損修改時, 會導致成對的tp/sl訂單失去綁定關係, 這意味著當通過tp/sl訂單ID調用 取消接口時, 只會取消對應訂單ID的單邊止盈或止損.

    HTTP 請求

    POST /v5/position/trading-stop

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型
    • 統一帳戶: linear, inverse
    • 普通帳戶: linear, inverse. 這裡category字段不參與業務邏輯,僅做路由使用
    symboltruestring合約名稱
    takeProfitfalsestring止盈價格. 等於0表示取消止盈,若不修改,則不要傳遞該參數
    stopLossfalsestring止損價格. 等於0表示取消止損,若不修改,則不要傳遞該參數
    trailingStopfalsestring追蹤止損, 僅支持按價差設置. 等於0表示取消追蹤止損,若不修改,則不要傳遞該參數
    tpTriggerByfalsestring止盈價格類型
    slTriggerByfalsestring止損價格類型
    activePricefalsestring追蹤止損激活價格. 追蹤止損會在到達該價格時觸發
    tpslModefalsestring止盈止損模式. Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損. 由於每個合約都有初始的止盈止損模式(Full), 若曾經修改過, 那麼可能是Partial, 因此若不傳入, 則系統會自動獲取該合約當前的止盈止損模式配置
    tpSizefalsestring止盈倉位數量. 僅部分止盈止損時有效. 注意: tpSize和slSize的數值必須相等
    slSizefalsestring止損倉位數量. 僅部分止盈止損時有效. 注意: tpSize和slSize的數值必須相等
    tpLimitPricefalsestring觸發止盈後轉換為限價單的價格. 僅tpslMode=Partial且tpOrderType=Limit時有效
    slLimitPricefalsestring觸發止損後轉換為限價單的價格. 僅tpslMode=Partial且slOrderType=Limit時有效
    tpOrderTypefalsestring止盈觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持tpOrderType=Market
    slOrderTypefalsestring止損觸發後的訂單類型. Market(默認), Limit. 對於tpslMode=Full時, 僅支持slOrderType=Market
    positionIdxtrueinteger倉位標識,用戶識別倉位.
    • 0: 單向持倉
    • 1: 買側雙向持倉
    • 2: 賣側雙向持倉

    響應參數

    請求示例

    POST /v5/position/trading-stop HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672283124270
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "category":"linear",
    "symbol": "XRPUSDT",
    "takeProfit": "0.6",
    "stopLoss": "0.2",
    "tpTriggerBy": "MarkPrice",
    "slTriggerBy": "IndexPrice",
    "tpslMode": "Partial",
    "tpOrderType": "Limit",
    "slOrderType": "Limit",
    "tpSize": "50",
    "tpLimitPrice": "0.57",
    "slLimitPrice": "0.21",
    "positionIdx": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672283125359
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/close-pnl.html b/zh-TW/v5/pre-upgrade/close-pnl.html index ca47266b46..de0ad00a11 100644 --- a/zh-TW/v5/pre-upgrade/close-pnl.html +++ b/zh-TW/v5/pre-upgrade/close-pnl.html @@ -4,13 +4,13 @@ 查詢升級前平倉盈虧 | Bybit API Documentation - +

    查詢升級前平倉盈虧

    僅支持查詢升級到統一帳戶之前發生的USDT永續 / 反向合約, 返回結果按照createdTime降序排列

    HTTP 請求

    GET /v5/pre-upgrade/position/closed-pnl

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型 linear, inverse
    symboltruestring合約名稱
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 100]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > sidestring買賣方向 Buy, Side
    > qtystring訂單數量
    > orderPricestring訂單價格
    > orderTypestring訂單類型. Market,Limit
    > execTypestring執行類型. Trade, BustTrade, SessionSettlePnL, Settle
    > closedSizestring平倉數量
    > cumEntryValuestring被平倉位的累計入場價值
    > avgEntryPricestring平均入場價格
    > cumExitValuestring被平倉位的累計出場價值
    > avgExitPricestring平均出場價格
    > closedPnlstring被平倉位的盈虧
    > fillCountstring成交筆數
    > leveragestring持倉槓桿
    > createdTimestring創建時間 (毫秒)
    > updatedTimestring更新時間 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/pre-upgrade/position/closed-pnl?category=linear&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682580911998
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "67836246-460e-4c52-a009-af0c3e1d12bc",
    "side": "Sell",
    "qty": "0.200",
    "orderPrice": "27203.40",
    "orderType": "Market",
    "execType": "Trade",
    "closedSize": "0.200",
    "cumEntryValue": "5588.88",
    "avgEntryPrice": "27944.40",
    "cumExitValue": "5726.4252",
    "avgExitPrice": "28632.13",
    "closedPnl": "204.25510011",
    "fillCount": "22",
    "leverage": "10",
    "createdTime": "1682487465732",
    "updatedTime": "1682487465732"
    }
    ],
    "category": "linear",
    "nextPageCursor": ""
    },
    "retExtInfo": {},
    "time": 1682580912259
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/delivery.html b/zh-TW/v5/pre-upgrade/delivery.html index 523da58950..363fad495b 100644 --- a/zh-TW/v5/pre-upgrade/delivery.html +++ b/zh-TW/v5/pre-upgrade/delivery.html @@ -4,13 +4,13 @@ 查詢升級前期權交割紀錄 | Bybit API Documentation - +

    查詢升級前期權交割紀錄

    查詢升級到統一帳戶之前發生的期權的交割紀錄, 返回結果按照deliveryTime降序排列

    HTTP 請求

    GET /v5/pre-upgrade/asset/delivery-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. option
    symbolfalsestring合約名稱
    expDatefalsestring過期日. 格式示例: 25MAR22. 默認: 返回所有日期數據
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > deliveryTimenumber交割時間戳 (毫秒)
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > positionstring交割數量
    > deliveryPricestring交割價格
    > strikestring行權價
    > feestring手續費,正數表支出,負數表收取
    > deliveryRplstring交割已實現盈虧
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/pre-upgrade/asset/delivery-record?category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686809005774
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21%3A0%2C21%3A0",
    "category": "option",
    "list": [
    {
    "symbol": "ETH-14JUN23-1750-C",
    "side": "Buy",
    "deliveryTime": 1686729604507,
    "strike": "1750",
    "fee": "0",
    "position": "0.5",
    "deliveryPrice": "1740.25036667",
    "deliveryRpl": "0.175"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686796328492
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/execution.html b/zh-TW/v5/pre-upgrade/execution.html index 5e5cc93c85..934446a030 100644 --- a/zh-TW/v5/pre-upgrade/execution.html +++ b/zh-TW/v5/pre-upgrade/execution.html @@ -4,13 +4,13 @@ 查詢升級前成交紀錄 | Bybit API Documentation - +

    查詢升級前成交紀錄

    目前,僅支持查詢升級到統一帳戶之前發生的USDT永續, USDC永續, 反向合約和期權, 返回結果按execTime降序排列

    提示
    • 儅execTime相同時,返回會有排序問題,此問題已在優化中預計10月底發佈,如果您想獲取實時成交信息建議使用websocket stream.
    • 單筆訂單可能會有多次成交.
    • 您可以通過指定symbol, baseCoin, orderId 和 orderLinkId字段來查詢。如果您使用多字段組合,系統的查詢優先級如下: orderId > orderLinkId > symbol > baseCoin.

    HTTP 請求

    GET v5/pre-upgrade/execution/list

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型 linear, inverse, option
    symbolfalsestring合約名稱
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring用戶自定義訂單ID
    baseCoinfalsestring交易幣種. 僅期權使用
    startTimefalseinteger開始時間戳 (毫秒)
    endTimefalseinteger結束時間戳 (毫秒)
    execTypefalsestring執行類型
    limitfalseinteger每頁數量限制. [1, 100]. 默認: 50
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義訂單id
    > sidestring訂單方向.買: Buy,賣:Sell
    > orderPricestring訂單價格
    > orderQtystring訂單數量
    > leavesQtystring剩餘委託未成交數量
    > orderTypestring訂單類型. 市價單:Market,限價單:Limit
    > stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则不会返回任何类型
    > execFeestring交易手續費
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring交易類型
    > execValuestring成交價值
    > execTimestring成交時間(毫秒)
    > isMakerBool是否是 Maker 訂單,true 為 maker 訂單,false 為 taker 訂單
    > feeRatestring手續費率
    > tradeIvstring隱含波動率,僅期權有效
    > markIvstring標記價格的隱含波動率,僅期權有效
    > markPricestring成交執行時,該 symbol 當時的標記價格
    > indexPricestring成交執行時,該 symbol 當時的指數價格,目前僅對期權業務有效
    > underlyingPricestring成交執行時,該 symbol 當時的底層資產價格,僅期權有效
    > blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID
    > closedSizestring平倉數量
    nextPageCursorstring游標,用於翻頁

    Request Example

    GET /v5/pre-upgrade/execution/list?category=linear&limit=1&execType=Funding&symbol=BTCUSDT HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682580752432
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "symbol": "BTCUSDT",
    "orderId": "1682553600-BTCUSDT-592334-Sell",
    "orderLinkId": "",
    "side": "Sell",
    "orderPrice": "0.00",
    "orderQty": "0.000",
    "leavesQty": "0.000",
    "orderType": "UNKNOWN",
    "stopOrderType": "UNKNOWN",
    "execFee": "0.6364003",
    "execId": "11f1c4ed-ff20-4d73-acb7-96e43a917f25",
    "execPrice": "28399.90",
    "execQty": "0.011",
    "execType": "Funding",
    "execValue": "312.3989",
    "execTime": "1682553600000",
    "isMaker": false,
    "feeRate": "0.00203714",
    "tradeIv": "",
    "markIv": "",
    "markPrice": "28399.90",
    "indexPrice": "",
    "underlyingPrice": "",
    "blockTradeId": "",
    "closedSize": "0.000"
    }
    ],
    "nextPageCursor": "page_token%3D96184191%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1682580752717
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/order-list.html b/zh-TW/v5/pre-upgrade/order-list.html index 304eb1e1e7..3fe0766e3b 100644 --- a/zh-TW/v5/pre-upgrade/order-list.html +++ b/zh-TW/v5/pre-upgrade/order-list.html @@ -4,13 +4,13 @@ 查詢升級前訂單紀錄 | Bybit API Documentation - +

    查詢升級前訂單紀錄

    支持查詢升級到統一帳戶之前發生的USDT永續, USDC永續, 反向合約和期權

    信息
    • 7天內,可以查詢到全狀態的紀錄
    • 7天外,僅能查詢到已成交的紀錄

    HTTP 請求

    GET /v5/pre-upgrade/order/history

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear, inverse, option
    symbolfalsestring合約名稱.
    • 對於linear, 如果不傳symbol, 默認返回數據是結算幣種=USDT
    • 要查詢USDC永續, 請傳遞對應的合約名稱
    baseCoinfalsestring交易幣種. 期權的預留字段
    orderIdfalsestring訂單ID
    orderLinkIdfalsestring用戶自定義訂單ID
    orderFilterfalsestringOrder: 普通單, StopOrder: 條件單
    orderStatusfalsestring訂單狀態. 不支持現貨
    startTimefalseinteger開始時間戳 (毫秒)
    • startTime 和 endTime要麼同時傳入,要麼同時不傳
    • 若不傳,默認查詢過去7天的數據
    endTimefalseinteger結束時間戳 (毫秒)
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > orderIdstring訂單Id
    > orderLinkIdstring用戶自定義Id
    > blockTradeIdstring大宗交易訂單Id
    > symbolstring合約名稱
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > isLeveragestring該字段對升級前的帳戶訂單無意義
    > positionIdxinteger倉位標識。用戶不同倉位模式
    > orderStatusstring訂單狀態
    > cancelTypestring訂單被取消類型
    > rejectReasonstring拒絕原因
    > avgPricestring訂單平均成交價格. 若沒有成交,則返回""
    > leavesQtystring訂單剩餘未成交的數量
    > leavesValuestring訂單剩餘未成交的價值
    > cumExecQtystring訂單累計成交數量
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費
    > timeInForcestring執行策略
    > orderTypestring訂單類型. Market,Limit
    > stopOrderTypestring條件單類型
    > orderIvstring隱含波動率
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > triggerDirectioninteger觸發方向. 1: 上漲, 2: 下跌
    > triggerBystring觸發價格的觸發類型
    > lastPriceOnCreatedstring下單時的市場價格
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > placeTypestring下單類型, 僅期權使用. iv, price
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring創建訂單的時間戳 (毫秒)
    > updatedTimestring訂單更新的時間戳 (毫秒)
    nextPageCursorstring游標,用於翻頁

    Request Example

    GET /v5/pre-upgrade/order/history?category=linear&limit=1&orderStatus=Filled HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1682576940304
    X-BAPI-RECV-WINDOW: 5000

    Response Example

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "list": [
    {
    "orderId": "67836246-460e-4c52-a009-af0c3e1d12bc",
    "orderLinkId": "",
    "blockTradeId": "",
    "symbol": "BTCUSDT",
    "price": "27203.40",
    "qty": "0.200",
    "side": "Sell",
    "isLeverage": "",
    "positionIdx": 0,
    "orderStatus": "Filled",
    "cancelType": "UNKNOWN",
    "rejectReason": "EC_NoError",
    "avgPrice": "28632.126000",
    "leavesQty": "0.000",
    "leavesValue": "0",
    "cumExecQty": "0.200",
    "cumExecValue": "5726.4252",
    "cumExecFee": "3.43585512",
    "timeInForce": "IOC",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "orderIv": "",
    "triggerPrice": "0.00",
    "takeProfit": "0.00",
    "stopLoss": "0.00",
    "tpTriggerBy": "UNKNOWN",
    "slTriggerBy": "UNKNOWN",
    "triggerDirection": 0,
    "triggerBy": "UNKNOWN",
    "lastPriceOnCreated": "0.00",
    "reduceOnly": true,
    "closeOnTrigger": true,
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "createdTime": "1682487465732",
    "updatedTime": "1682487465735",
    "placeType": ""
    }
    ],
    "nextPageCursor": "page_token%3D69406%26",
    "category": "linear"
    },
    "retExtInfo": {},
    "time": 1682576940540
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/settlement.html b/zh-TW/v5/pre-upgrade/settlement.html index ccf5a8e556..fc0fecad04 100644 --- a/zh-TW/v5/pre-upgrade/settlement.html +++ b/zh-TW/v5/pre-upgrade/settlement.html @@ -4,13 +4,13 @@ 查詢升級前USDC結算紀錄 | Bybit API Documentation - +

    查詢升級前USDC結算紀錄

    查詢升級到統一帳戶之前發生的USDC永續的結算紀錄

    HTTP 請求

    GET /v5/pre-upgrade/asset/settlement-record

    請求參數

    參數是否必需類型說明
    categorytruestring產品類型. linear
    symbolfalsestring合約名稱
    limitfalseinteger每頁數量限制. [1, 50]. 默認: 20
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    categorystring產品類型
    listarrayObject
    > symbolstring合約名稱
    > sidestringBuy,Sell
    > sizestring倉位大小
    > sessionAvgPricestring結算價格
    > markPricestring標記價格
    > realisedPnlstring已實現盈虧
    > createdTimestring結算時間 (毫秒)
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/pre-upgrade/asset/settlement-record?category=linear&symbol=ETHPERP&limit=1 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686809850982
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "25%3A0%2C25%3A0",
    "category": "linear",
    "list": [
    {
    "realisedPnl": "45.76",
    "symbol": "ETHPERP",
    "side": "Sell",
    "markPrice": "1668.44",
    "size": "-0.5",
    "createdTime": "1686787200000",
    "sessionAvgPrice": "1668.41"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686809851749
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/pre-upgrade/transaction-log.html b/zh-TW/v5/pre-upgrade/transaction-log.html index 71b8a7aba2..8f4b4cd136 100644 --- a/zh-TW/v5/pre-upgrade/transaction-log.html +++ b/zh-TW/v5/pre-upgrade/transaction-log.html @@ -4,13 +4,13 @@ 查詢升級前交易日誌 | Bybit API Documentation - +

    查詢升級前交易日誌

    查詢升級到統一帳戶之前USDC合約帳戶裡的交易日誌

    HTTP 請求

    GET /v5/pre-upgrade/account/transaction-log

    請求參數

    參數是否必需類型說明
    categoryfalsestring交易產品類型. linear:USDC永續, option:期權
    baseCoinfalsestring交易幣種. 例如: BTCUSDT 的 baseCoin 是 BTC
    typefalsestring交易日誌的類型
    startTimefalseinteger開始時間, 毫秒時間戳
    endTimefalseinteger結束時間, 毫秒時間戳
    limitfalseinteger每頁數量, 最大50. 默認每頁20條
    cursorfalsestring游標,用於翻頁

    響應參數

    參數類型說明
    listarrayObject
    > symbolstring合約名稱
    > categorystring產品類型
    > sidestring方向. Buy,Sell,None
    > transactionTimestring交易時間戳(毫秒)
    > typestring類型
    > qtystring數量
    > sizestring倉位
    > currencystringUSDC、USDT、BTC、ETH
    > tradePricestring交易價格
    > fundingstring資金費用. 正數表示用戶收取xx資金費,負數表示用戶支出xx資金費
    > feestring手續費,正數表示用戶付出xx手續費,負數表示返佣
    > cashFlowstring現金流
    > changestring變更
    > cashBalancestring餘額(當前幣種)
    > feeRatestring
    • 對於type=TRADE, 則表示交易手續費率
    • 對於type=SETTLEMENT, 則表示資金費率. 當side=Buy, feeRate=市場結算費率; 當side=Sell, feeRate=-市場結算費率
    > bonusChangestring體驗金的變化
    > tradeIdstring交易id
    > orderIdstring訂單id
    > orderLinkIdstring用戶自定義訂單id
    nextPageCursorstring游標,用於翻頁

    請求示例

    GET /v5/pre-upgrade/account/transaction-log?category=option HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686808288265
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "nextPageCursor": "21%3A0%2C21%3A0",
    "list": [
    {
    "symbol": "ETH-14JUN23-1750-C",
    "side": "Buy",
    "funding": "",
    "orderLinkId": "",
    "orderId": "",
    "fee": "0",
    "change": "0",
    "cashFlow": "0",
    "transactionTime": "1686729604507",
    "type": "DELIVERY",
    "feeRate": "0",
    "bonusChange": "",
    "size": "0",
    "qty": "0.5",
    "cashBalance": "1001.1438885",
    "currency": "USDC",
    "category": "option",
    "tradePrice": "1740.25036667",
    "tradeId": ""
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686809006792
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/rate-limit.html b/zh-TW/v5/rate-limit.html index fbd068fa74..24b79b9848 100644 --- a/zh-TW/v5/rate-limit.html +++ b/zh-TW/v5/rate-limit.html @@ -4,7 +4,7 @@ 頻率限制 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 仍被禁止,則您可能會被永久禁止。

    我們不建議您在這些限制的邊緣運行您的應用程序,以防異常的網絡活動導致意外違規。

    • GET/POST 請求 (共享):
      • 連續 5 秒內每秒不超過 120 個請求
    備註

    所有到api.bybit.comapi.bytick.com的流量共享此限制,無論是訪問現貨、期貨還是期權。

    違反限制後,您的 IP 將被禁止一段時間(通常為 30 分鐘)。 持續違反限制將導致永久禁止。 我們不能撤銷永久禁令或縮短臨時禁令。

    賬戶頻率限製

    警告

    如果您收到這樣的響應"ret_msg": "Too many visits!", 則表示您觸發了帳戶頻率限制, 請等到頻率限制重置以後, 再繼續發送請求。

    Bybit基於每秒鍾的滾動時間窗口來做頻率限製,並且是按賬戶(uid)來做劃分限製,每次請求API響應頭(response header)中都會包含如下字段:

    • X-Bapi-Limit-Status - 該接口當前時間窗口剩余可用請求數
    • X-Bapi-Limit - 該接口當前頻率限製上限
    • X-Bapi-Limit-Reset-Timestamp - 如果您已超過該接口當前窗口頻率限製,該字段表示下個可用時間窗口的時間戳(毫秒),即什麽時候可以恢復訪問;如果您未超過該接口當前窗口頻率限製,該字段表示返回的是當前服務器時間(毫秒).

    Http 響應頭示例

    ▶Response Headers
    Content-Type: application/json; charset=utf-8
    Content-Length: 141
    X-Bapi-Limit: 100
    X-Bapi-Limit-Status: 99
    X-Bapi-Limit-Reset-Timestamp: 1672738134824

    接口頻率限制表

    交易

    請求方式路徑經典帳戶是否可提頻
    inverselinearspot
    POST/v5/order/create10/s20/sY
    /v5/order/amend10/s-Y
    /v5/order/cancel10/s20/sY
    /v5/order/cancel-all10/s20/sN
    GET/v5/order/realtime10/s20/sN
    /v5/order/history10/s20/sN

    持倉

    請求方式路徑經典帳戶是否可提頻
    inverselinearspot
    GET/v5/position/list10/s-N
    /v5/execution/list10/s20/sN
    /v5/position/closed-pnl10/s-N

    帳戶

    請求方式路徑頻率是否可提頻
    GET/v5/account/wallet-balanceaccountType=SPOT20/sN
    accountType=CONTRACT10/sN
    /v5/account/fee-ratecategory=linear10/sN
    category=spot5/sN
    category=option5/sN

    資產

    請求方式路徑頻率是否可提頻
    GET/v5/asset/transfer/query-asset-info60 req/minN
    /v5/asset/transfer/query-transfer-coin-list60 req/minN
    /v5/asset/transfer/query-transfer-coin-list60 req/minN
    /v5/asset/transfer/query-inter-transfer-list60 req/minN
    /v5/asset/transfer/query-sub-member-list60 req/minN
    /v5/asset/transfer/query-universal-transfer-list2 req/sN
    /v5/asset/transfer/query-account-coins-balance2 req/sN
    /v5/asset/deposit/query-record300 req/minN
    /v5/asset/deposit/query-sub-member-record300 req/minN
    /v5/asset/deposit/query-address300 req/minN
    /v5/asset/deposit/query-sub-member-address300 req/minN
    /v5/asset/withdraw/query-record300 req/minN
    /v5/asset/coin/query-info2 req/sN
    /v5/asset/exchange/order-record600 req/minN
    POST/v5/asset/transfer/inter-transfer20 req/minN
    /v5/asset/transfer/save-transfer-sub-member20 req/minN
    /v5/asset/transfer/universal-transfer5 req/sN
    /v5/asset/withdraw/create10 req/minN
    /v5/asset/withdraw/cancel60 req/minN

    用戶

    請求方式路徑頻率是否可提頻
    POSTv5/user/create-sub-member5 req/sN
    /v5/user/create-sub-api5 req/sN
    /v5/user/frozen-sub-member5 req/sN
    /v5/user/update-api5 req/sN
    /v5/user/update-sub-api5 req/sN
    /v5/user/delete-api5 req/sN
    /v5/user/delete-sub-api5 req/sN
    GET/v5/user/query-sub-members10 req/sN
    /v5/user/query-api10 req/sN

    槓桿代幣

    請求方式路徑頻率是否可提頻
    GET/v5/spot-lever-token/order-record50 req/sN
    POST/v5/spot-lever-token/purchase20 req/sN
    POST/v5/spot-lever-token/redeem20 req/sN

    全倉槓桿 (統一帳戶)

    目前,該目錄下的接口沒有頻率限制

    全倉槓桿 (普通帳戶)

    請求方式路徑頻率是否可提頻
    GET/v5/spot-cross-margin-trade/loan-info50 req/sN
    GET/v5/spot-cross-margin-trade/account50 req/sN
    GET/v5/spot-cross-margin-trade/orders50 req/sN
    GET/v5/spot-cross-margin-trade/repay-history50 req/sN
    POST/v5/spot-cross-margin-trade/loan20 req/sN
    POST/v5/spot-cross-margin-trade/repay20 req/sN
    POST/v5/spot-cross-margin-trade/switch20 req/sN

    不同VIP/PRO等級的接口限頻規則

    信息
    • 表格中的數值,代表對應等級的可申請上限,並不代表處於該等級的用戶實際默認自動享有對應的API Rate Limit
    • 經典帳戶不支持交易USDC衍生品
    批量接口特別說明

    批次訂單接口(包括創建、修改和取消)的速率限制不會與單一的下改撤請求共享。例如,單一下單接口頻率是100/秒, 批量下單接口是100/秒,,那麼當結合兩個接口一起下單時, 就擁有200單每秒的能力

    僅category=linear時

    • 批量下單的接口,api rate limit:接口的頻次,還是統一沿用當前配置,但是計數消耗會根據實際的訂單數來消耗。(消耗數 = 請求數 * 請求中包含的訂單數),業務線配置相互獨立。

    • 批量接口允許1-10orders/request,例如,批量下單請求一次,包含5個orders,則本次請求limit數量消耗5。

    • 若1s內的最後一次請求的批量訂單,部分超限,則超過的部分會失敗(報錯超過上限),未超過的部分會成功。例如,這1s中,limit還剩5,但是此時下了一個包含8個orders的批量請求, 那麼前5個orders會下單成功,第6-8的orders,會報錯超過上限,下單失敗。

    經典帳戶UTA Pro
    等級\產品期貨期權現貨期貨期權現貨
    默認10/s10/s20/s10/s10/s20/s
    VIP 120/s20/s25/s20/s20/s25/s
    VIP 240/s40/s30/s40/s40/s30/s
    VIP 360/s60/s40/s60/s60/s40/s
    VIP 460/s60/s40/s60/s60/s40/s
    VIP 560/s60/s40/s60/s60/s40/s
    至尊VIP60/s60/s40/s60/s60/s40/s
    PRO1100/s100/s50/s150/s150/s150/s
    PRO2150/s150/s75/s200/s200/s200/s
    PRO3200/s200/s100/s250/s250/s250/s
    PRO4200/s200/s100/s300/s300/s300/s
    PRO5200/s200/s100/s300/s300/s300/s

    如何提高頻率限製

    請聯繫您的客戶經理或者發送郵件到 institutional_services@bybit.com,我們會在 1-4 個工作日內答復。郵件內容必須包含以下內容:

    1. 您的姓名和公司名稱和簡介
    2. 您的bybit 賬號uid或註冊郵箱手機號,以及您要申請提頻的交易對
    3. 您上個月的交易量(吃單/掛單)並提供截圖
    4. 簡單介紹您的交易策略和為什麽需要更高限頻
    5. 如果可以,請提供您的成交記錄csv文檔
    - + \ No newline at end of file diff --git a/zh-TW/v5/smp.html b/zh-TW/v5/smp.html index 06e598c328..c84a87ff3c 100644 --- a/zh-TW/v5/smp.html +++ b/zh-TW/v5/smp.html @@ -4,7 +4,7 @@ 自成交攔截 | Bybit API Documentation - + @@ -13,7 +13,7 @@ 基於這點,我們強烈建議在SMP交易群組發生變更時,最好取消所有現有訂單,以避免意外執行。

    1. SMP交易群組在SMP執行中具有較高優先級,當任何一方沒有群組時,UID才會生效。

    2. 一旦訂單進入訂單簿,其 smp 標誌就不再重要。系統始終遵循後一個訂單的smp標籤。

    示例
    1月1日:UID1加入SMP交易群組A,並下訂單1;
    1月2日:UID1被從SMP交易群組A中移除,但訂單1仍然處於活躍狀態且為“新”狀態。

    • 情況1:如果UID1加入了SMP交易群組B並下了訂單2,如果訂單2與訂單1相符,它將被執行,因為它們屬於兩個不同的群組。
    • 情況2:如果UID1在被從SMP交易群組A中移除後沒有加入任何其他群組並下了訂單2,如果訂單2與訂單1相符,SMP將被觸發,因為UID1在下訂單2時沒有群組,所以SMP在UID級別(同一個UID1)被觸發。

    如何管理我的UID及SMP交易群組?

    您可以聯繫您的機構業務經理或通過電子郵件聯繫Bybit,電子郵件地址為: institutional_services@bybit.com

    支持的OpenAPI版本和產品線

    產品線支持的OpenAPI版本說明
    現貨V3 (普通帳戶)
    V5 (統一帳戶&普通帳戶)
    合約合約V3 (普通帳戶): USDT永續 / 反向永續&交割
    V5 (統一帳戶): USDT永續 / 反向永續&交割 / USDC永續 & 交割
    V5 (普通帳戶): USDT永續 / 反向永續 & 交割
    期權V5 (統一帳戶)V1有基於UID維度的SMP功能
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/account-info.html b/zh-TW/v5/spot-margin-normal/account-info.html index 83e20461a4..a32235cfb8 100644 --- a/zh-TW/v5/spot-margin-normal/account-info.html +++ b/zh-TW/v5/spot-margin-normal/account-info.html @@ -4,13 +4,13 @@ 查詢借貸帳戶信息 | Bybit API Documentation - +

    查詢借貸帳戶信息

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    GET /v5/spot-cross-margin-trade/account

    請求參數

    響應參數

    參數類型說明
    acctBalanceSumstring總資產 (折算成BTC)
    debtBalanceSumstring總負債 (折算成BTC)
    loanAccountListarrayObject
    > freestring可用餘額
    > intereststring未還利息
    > loanstring未還本金
    > remainAmountstring總未還金額 = 未還利息 + 未還本金
    > lockedstring鎖定金額
    > tokenIdstring幣種
    > totalstring合計
    riskRatestring風險率
    statusinteger借貸帳戶狀態
    • 1: 正常
    • 2: 限制提幣/劃轉
    • 3: 預警
    • 4: 已爆倉
    switchStatusinteger全倉槓桿狀態 0: 關閉, 1: 開啟

    請求示例

    GET /v5/spot-cross-margin-trade/account HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751305868
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "acctBalanceSum": "0.455189592150138021",
    "debtBalanceSum": "0",
    "loanAccountList": [
    {
    "free": "0.01444",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "BTC",
    "total": "0.01444"
    },
    {
    "free": "0.21147048",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "ETH",
    "total": "0.21147048"
    },
    {
    "free": "7963.58978991849",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDT",
    "total": "7963.58978991849"
    },
    {
    "free": "1380.28832",
    "interest": "0",
    "loan": "0",
    "locked": "0",
    "remainAmount": "0",
    "tokenId": "USDC",
    "total": "1380.28832"
    }
    ],
    "riskRate": "0",
    "status": 1,
    "switchStatus": 1
    },
    "retExtInfo": {},
    "time": 1677751306287
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/borrow-order.html b/zh-TW/v5/spot-margin-normal/borrow-order.html index 2b9c618b59..d1a0d4e682 100644 --- a/zh-TW/v5/spot-margin-normal/borrow-order.html +++ b/zh-TW/v5/spot-margin-normal/borrow-order.html @@ -4,13 +4,13 @@ 查詢借貸訂單 | Bybit API Documentation - +

    查詢借貸訂單

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    GET /v5/spot-cross-margin-trade/orders

    請求參數

    參數是否必需類型說明
    startTimefalselong開始時間戳 (毫秒)
    endTimefalselong結束時間戳 (毫秒)
    coinfalsestring幣種名稱
    statusfalseinteger訂單狀態
    • 0(默認):查詢所有狀態
    • 1:查詢未還清
    • 2:查詢已還清
    limitfalseinteger每頁數量限制. [1, 500]. 默認: 500

    響應參數

    參數類型說明
    listarrayObject
    > accountIdstring帳戶ID
    > coinstring幣種名稱
    > createdTimenumber借貸訂單創建時間戳 (毫秒)
    > idstring借貸交易ID
    > interestAmountstring總利息
    > interestBalancestring未還利息
    > loanAmountstring借貸金額
    > loanBalancestring未還本金
    > remainAmountstring未還金額總和=未還利息+未還本金
    > statusinteger訂單狀態 1:未還清, 2:已還清
    > typeinteger訂單類型 1: 手動借貸, 2: 自動借貸

    請求示例

    GET /v5/spot-cross-margin-trade/orders?coin=ETH&limit=1&status=2 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677754328650
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "accountId": "592335",
    "coin": "ETH",
    "createdTime": 1677751839000,
    "id": "21005",
    "interestAmount": "0.0001",
    "interestBalance": "0",
    "loanAmount": "10",
    "loanBalance": "0",
    "remainAmount": "0",
    "status": 2,
    "type": 1
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677754329096
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/borrow.html b/zh-TW/v5/spot-margin-normal/borrow.html index f471622605..1b65ca9a8a 100644 --- a/zh-TW/v5/spot-margin-normal/borrow.html +++ b/zh-TW/v5/spot-margin-normal/borrow.html @@ -4,13 +4,13 @@ 借款 | Bybit API Documentation - +

    借款

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    POST /v5/spot-cross-margin-trade/loan

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱
    qtytruestring借貸金額

    響應參數

    參數類型說明
    transactIdstring借款交易ID

    請求示例

    POST /v5/spot-cross-margin-trade/loan HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751838628
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 38

    {
    "coin": "ETH",
    "qty": "10"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "transactId": "21005"
    },
    "retExtInfo": {},
    "time": 1677751839688
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/borrowable-data.html b/zh-TW/v5/spot-margin-normal/borrowable-data.html index c61d9a322d..22c95c1f5b 100644 --- a/zh-TW/v5/spot-margin-normal/borrowable-data.html +++ b/zh-TW/v5/spot-margin-normal/borrowable-data.html @@ -4,13 +4,13 @@ 查詢可借幣種精度 | Bybit API Documentation - +

    查詢可借幣種精度

    信息

    不需要鑒權

    HTTP 請求

    GET /v5/spot-cross-margin-trade/borrow-token

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > borrowingPrecisioninteger借款精度
    > repaymentPrecisioninteger還款精度

    請求示例

    GET /v5/spot-cross-margin-trade/borrow-token?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "borrowingPrecision": 5,
    "coin": "ETH",
    "repaymentPrecision": 4
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750685331
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/interest-quota.html b/zh-TW/v5/spot-margin-normal/interest-quota.html index e41a8f1356..f40eecb412 100644 --- a/zh-TW/v5/spot-margin-normal/interest-quota.html +++ b/zh-TW/v5/spot-margin-normal/interest-quota.html @@ -4,13 +4,13 @@ 查詢利率及額度 | Bybit API Documentation - +

    查詢利率及額度

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    GET /v5/spot-cross-margin-trade/loan-info

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱

    響應參數

    參數類型說明
    coinstring幣種名稱
    interestRatestring基礎日利率
    loanAbleAmountstring預估可借最大金額
    maxLoanAmountstring平台設置的用戶最大可借金額

    請求示例

    GET /v5/spot-cross-margin-trade/loan-info?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677750928871
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "coin": "ETH",
    "interestRate": "0.000054835",
    "loanAbleAmount": "19.220442066850037795",
    "maxLoanAmount": "300"
    },
    "retExtInfo": {},
    "time": 1677750929290
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/margin-data.html b/zh-TW/v5/spot-margin-normal/margin-data.html index 57eb5063ee..d96c01412c 100644 --- a/zh-TW/v5/spot-margin-normal/margin-data.html +++ b/zh-TW/v5/spot-margin-normal/margin-data.html @@ -4,13 +4,13 @@ 查詢保證金幣種信息 | Bybit API Documentation - +

    查詢保證金幣種信息

    信息

    不需要鑒權

    HTTP 請求

    GET /v5/spot-cross-margin-trade/pledge-token

    請求參數

    參數是否必需類型說明
    coinfalsestring幣種名稱

    響應參數

    參數類型說明
    listarrayObject
    > coinstring幣種名稱
    > conversionRatestring折算率, 返回為實際數值
    > liquidationOrderinteger強平順序

    請求示例

    GET /v5/spot-cross-margin-trade/pledge-token?coin=ETH HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "list": [
    {
    "coin": "ETH",
    "conversionRate": "0.95",
    "liquidationOrder": 2
    }
    ]
    },
    "retExtInfo": {},
    "time": 1677750397414
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/repay-order.html b/zh-TW/v5/spot-margin-normal/repay-order.html index d402936bb3..5c8e74b94e 100644 --- a/zh-TW/v5/spot-margin-normal/repay-order.html +++ b/zh-TW/v5/spot-margin-normal/repay-order.html @@ -4,13 +4,13 @@ 查詢還款訂單信息 | Bybit API Documentation - +

    查詢還款訂單信息

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    GET /v5/spot-cross-margin-trade/repay-history

    請求參數

    參數是否必需類型說明
    startTimefalselong開始時間戳 (毫秒)
    endTimefalselong結束時間戳 (毫秒)
    coinfalsestring幣種信息
    limitfalseinteger每頁數量限制. [1, 500], 默認: 500

    響應參數

    參數類型說明
    listarrayObject
    > accountIdstring帳戶ID
    > coinstring幣種信息
    > repaidAmountstring還款金額
    > repayIdstring還款交易ID
    > repayMarginOrderIdstring還款單號
    > repayTimestring還款交易時間戳 (毫秒)
    > transactIdsarrayObject
    >> repaidIntereststring該筆還款訂單的利息還款金額
    >> repaidPrincipalstring該筆還款訂單的本金還款金額
    >> repaidSerialNumberstring借貸訂單的還款單號
    >> transactIdstring原始借貸交易ID

    請求示例

    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

    響應示例

    {
    "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
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/repay.html b/zh-TW/v5/spot-margin-normal/repay.html index 31de72f610..5e89b75cb6 100644 --- a/zh-TW/v5/spot-margin-normal/repay.html +++ b/zh-TW/v5/spot-margin-normal/repay.html @@ -4,13 +4,13 @@ 還款 | Bybit API Documentation - +

    還款

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    POST /v5/spot-cross-margin-trade/repay

    請求參數

    參數是否必需類型說明
    cointruestring幣種名稱
    qtyfalsestring還款金額
    • completeRepayment=0時, qty必傳
    • completeRepayment=1時, qty無效
    completeRepaymentfalseinteger是否一鍵全部還款. 0(默認): 否, 1: 是

    響應參數

    參數類型說明
    repayIdstring還款交易ID

    請求示例

    POST /v5/spot-cross-margin-trade/repay HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677751944347
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 66

    {
    "coin": "ETH",
    "qty": null,
    "completeRepayment": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "repayId": "19070"
    },
    "retExtInfo": {},
    "time": 1677751941219
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/switch-mode.html b/zh-TW/v5/spot-margin-normal/switch-mode.html index 55f5fece7a..785f189fff 100644 --- a/zh-TW/v5/spot-margin-normal/switch-mode.html +++ b/zh-TW/v5/spot-margin-normal/switch-mode.html @@ -4,13 +4,13 @@ 全倉槓桿開關 | Bybit API Documentation - +

    全倉槓桿開關

    開啟或關閉全倉槓桿交易

    覆蓋範圍: 全倉槓桿 (普通帳戶)

    HTTP 請求

    POST /v5/spot-cross-margin-trade/switch

    請求參數

    參數是否必需類型說明
    switchtrueinteger1: 開啟, 0: 關閉

    響應參數

    參數類型說明
    switchStatusinteger槓桿交易狀態. 1: 開啟, 0: 關閉

    請求示例

    POST /v5/spot-cross-margin-trade/switch HTTP/1.1
    Host: api-testnet.bybit.com
    Content-Type: application/json
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1677747804512
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Length: 19

    {
    "switch": 0
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "switchStatus": 0
    },
    "retExtInfo": {},
    "time": 1677747804974
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-normal/vip-margin.html b/zh-TW/v5/spot-margin-normal/vip-margin.html index 5ce916c7f4..3a73e820f1 100644 --- a/zh-TW/v5/spot-margin-normal/vip-margin.html +++ b/zh-TW/v5/spot-margin-normal/vip-margin.html @@ -4,13 +4,13 @@ 查詢不同VIP的槓桿數據 | Bybit API Documentation - +

    查詢不同VIP的槓桿數據

    查詢經典帳戶下不同VIP等級的槓桿數據

    信息

    不需要鑒權

    HTTP 請求

    GET /v5/spot-cross-margin-trade/data

    請求參數

    參數是否必需類型說明
    vipLevelfalsestringVIP 等級
    currencyfalsestring幣種名稱

    響應參數

    參數類型說明
    vipCoinListarrayObject
    > listarrayObject
    >> borrowableboolean幣種是否支持借貸
    >> collateralRatiostring抵押率
    >> currencystring幣種名稱
    >> hourlyBorrowRatestring每小時借貸利率
    >> liquidationOrderstring強平順序
    >> marginCollateralboolean幣種是否支持作為保證金
    >> maxBorrowingAmountstring最大借貸額度
    > vipLevelstringVIP 等級

    請求示例

    GET /v5/spot-cross-margin-trade/data?vipLevel=No VIP&currency=BTC HTTP/1.1
    Host: api.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "vipCoinList": [
    {
    "list": [
    {
    "borrowable": true,
    "collateralRatio": "0.95",
    "currency": "BTC",
    "hourlyBorrowRate": "0.000003964522",
    "liquidationOrder": "2",
    "marginCollateral": true,
    "maxBorrowingAmount": "5"
    }
    ],
    "vipLevel": "No VIP"
    }
    ]
    },
    "retExtInfo": {},
    "time": 1692071381663
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-uta/set-leverage.html b/zh-TW/v5/spot-margin-uta/set-leverage.html index f9a769e8da..2e0ead7435 100644 --- a/zh-TW/v5/spot-margin-uta/set-leverage.html +++ b/zh-TW/v5/spot-margin-uta/set-leverage.html @@ -4,13 +4,13 @@ 全倉槓桿設置 | Bybit API Documentation - +

    全倉槓桿設置

    全倉槓桿設置用戶最大槓桿倍數

    覆蓋範圍: 全倉槓桿 (統一帳戶)

    警告

    需要先開啟全倉槓桿,才能調整槓桿。

    HTTP 請求

    POST /v5/spot-margin-trade/set-leverage

    請求參數

    參數是否必需類型說明
    leveragetruestring槓桿倍數 (整數), 支持區間 [2, 10]

    響應參數

    請求示例

    POST /v5/spot-margin-trade/set-leverage HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672299806626
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "leverage": "4"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1672710944282
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-uta/status.html b/zh-TW/v5/spot-margin-uta/status.html index 89874d168d..3950f140e9 100644 --- a/zh-TW/v5/spot-margin-uta/status.html +++ b/zh-TW/v5/spot-margin-uta/status.html @@ -4,13 +4,13 @@ 查詢開關狀態和倍數 | Bybit API Documentation - +

    查詢開關狀態和倍數

    查詢統一帳戶下槓桿交易的開關狀態和槓桿倍數

    覆蓋範圍: 全倉槓桿 (統一帳戶)

    HTTP 請求

    GET /v5/spot-margin-trade/state

    請求參數

    請求參數

    參數是否必需類型
    spotLeveragestring槓桿倍數. 如果處於關閉狀態的話, 則返回 ""
    spotMarginModestring開關狀態. 1: 開啟, 0: 關閉

    請求示例

    GET /v5/spot-margin-trade/state HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1692696840996
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "spotLeverage": "10",
    "spotMarginMode": "1"
    },
    "retExtInfo": {},
    "time": 1692696841231
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-uta/switch-mode.html b/zh-TW/v5/spot-margin-uta/switch-mode.html index ec60e65881..46b5acf21a 100644 --- a/zh-TW/v5/spot-margin-uta/switch-mode.html +++ b/zh-TW/v5/spot-margin-uta/switch-mode.html @@ -4,13 +4,13 @@ 全倉槓桿開關 | Bybit API Documentation - +

    全倉槓桿開關

    全倉槓桿開關

    覆蓋範圍: 全倉槓桿 (統一帳戶)

    警告

    您的帳戶需要先開啟全倉槓桿

    HTTP 請求

    POST /v5/spot-margin-trade/switch-mode

    請求參數

    參數是否必需類型說明
    spotMarginModetruestring1: 開啟,0: 關閉

    響應參數

    參數類型說明
    spotMarginModestring全倉槓桿狀態(1: 開啟,0: 關閉)

    請求示例

    POST /v5/spot-margin-trade/switch-mode HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1672297794480
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "spotMarginMode": "0"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {
    "spotMarginMode": "0"
    },
    "retExtInfo": {},
    "time": 1672297795542
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/spot-margin-uta/vip-margin.html b/zh-TW/v5/spot-margin-uta/vip-margin.html index cedb697b81..08511c49dd 100644 --- a/zh-TW/v5/spot-margin-uta/vip-margin.html +++ b/zh-TW/v5/spot-margin-uta/vip-margin.html @@ -4,13 +4,13 @@ 查詢不同VIP的槓桿數據 | Bybit API Documentation - +

    查詢不同VIP的槓桿數據

    查詢統一帳戶下不同VIP等級的槓桿數據

    信息

    不需要鑒權

    HTTP 請求

    GET /v5/spot-margin-trade/data

    請求參數

    參數是否必需類型說明
    vipLevelfalsestringVIP 等級
    currencyfalsestring幣種名稱

    響應參數

    參數類型說明
    vipCoinListarrayObject
    > listarrayObject
    >> borrowableboolean幣種是否支持借貸
    >> collateralRatiostring抵押率
    >> currencystring幣種名稱
    >> hourlyBorrowRatestring每小時借貸利率
    >> liquidationOrderstring強平順序
    >> marginCollateralboolean幣種是否支持作為保證金
    >> maxBorrowingAmountstring最大借貸額度
    > vipLevelstringVIP 等級

    請求示例

    GET /v5/spot-margin-trade/data?vipLevel=No VIP&currency=BTC HTTP/1.1
    Host: api-testnet.bybit.com

    響應示例

    {
    "retCode": 0,
    "retMsg": "success",
    "result": {
    "vipCoinList": [
    {
    "list": [
    {
    "borrowable": true,
    "collateralRatio": "0.95",
    "currency": "BTC",
    "hourlyBorrowRate": "0.0000015020640000",
    "liquidationOrder": "11",
    "marginCollateral": true,
    "maxBorrowingAmount": "3"
    }
    ],
    "vipLevel": "No VIP"
    }
    ]
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/affiliate-info.html b/zh-TW/v5/user/affiliate-info.html index 8872d6d557..b605c59e1d 100644 --- a/zh-TW/v5/user/affiliate-info.html +++ b/zh-TW/v5/user/affiliate-info.html @@ -4,13 +4,13 @@ 查詢代理用戶信息 | Bybit API Documentation - +

    查詢代理用戶信息

    該接口是給代理商查詢他們用戶的一些基本信息的

    提示
    • 僅支持使用母帳戶uid
    • 若要查詢該接口, api key僅能擁有代理商權限, 若擁有任何其他權限想, 請移除
    • 交易量和入金金額為用戶在Bybit上的總量,與結傭無關,任何結傭相關的交易量數據,以Affiliate Portal為準。

    HTTP 請求

    GET /v5/user/aff-customer-info

    請求參數

    參數是否必須類型說明
    uidtruestring被代理用戶的母帳戶uid

    返回參數

    參數類型說明
    uidstring帳戶uid
    vipLevelstringVIP等級
    takerVol30Daystring過去30天的吃單交易量. 單位: USDT. 所有下方交易量相關的字段, 包含了期貨、期權和現貨的交易量
    makerVol30Daystring過去30天的掛單交易量. 單位: USDT
    tradeVol30Daystring過去30天的總交易量. 單位: USDT
    depositAmount30Daystring過去30天的入金金額. 單位: USDT
    takerVol365Daystring過去一年的吃單交易量. 單位: USDT
    makerVol365Daystring過去一年的掛單交易量. 單位: USDT
    tradeVol365Daystring過去一年的總交易量. 單位: USDT
    depositAmount365Daystring過去一年的總入金金額. 單位: USDT
    totalWalletBalancestring資產餘額區間
    • 1: 少於100 USDT的價值
    • 2: 100(含) ~ 250 USDT的價值
    • 3: 250(含) ~ 500 USDT的價值
    • 4: 大於 500USDT的價值
    depositUpdateTimestring入金數據更新時間. UTC時間
    volUpdateTimestring交易量數據更新時間. UTC時間

    請求示例

    GET /v5/user/aff-customer-info?uid=1513500 HTTP/1.1
    Host: api-testnet.bybit.com
    X-BAPI-API-KEY: uQ61dcX0lSe7ygD2EA
    X-BAPI-TIMESTAMP: 1685596324209
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: xxxxxx
    Content-Type: application/json

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "uid": "1513500",
    "takerVol30Day": "10",
    "makerVol30Day": "20",
    "tradeVol30Day": "30",
    "depositAmount30Day": "90",
    "takerVol365Day": "100",
    "makerVol365Day": "500",
    "tradeVol365Day": "600",
    "depositAmount365Day": "1300",
    "totalWalletBalance": "4",
    "depositUpdateTime": "2023-06-01 05:12:04",
    "vipLevel": "99",
    "volUpdateTime": "2023-06-02 00:00:00"
    },
    "retExtInfo": {},
    "time": 1685596324508
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/apikey-info.html b/zh-TW/v5/user/apikey-info.html index 6c4a0a1681..1365511b54 100644 --- a/zh-TW/v5/user/apikey-info.html +++ b/zh-TW/v5/user/apikey-info.html @@ -4,13 +4,13 @@ 查詢API Key相關信息 | Bybit API Documentation - +

    查詢API Key相關信息

    獲取API key的相關信息。使用待查詢的api key調用接口。適用於母、子帳戶的api key。

    提示

    任意權限可以訪問該接口

    HTTP 請求

    GET /v5/user/query-api

    請求參數

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray衍生品v3/v5交易的權限
    > CopyTradingarray跟單交易的權限. 子帳戶暫不支持, 總是[]
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]
    ipsarray綁定的IP
    typeintegerApi key類型. 1:個人使用, 2:綁定到第三方應用
    deadlineDayintegerAPI key失效的倒數日. 針對那些未綁定IP的api key或者修改過密碼的帳戶
    expiredAtdatetimeAPI key的過期日. 針對那些未綁定IP的api key或者修改過密碼的帳戶
    createdAtdatetimeAPI key的創建日
    unifiedintegerAPI Key所屬的帳戶是否為統一保證金帳戶. 0:普通帳戶; 1:統一保证金帳戶
    utaintegerAPI Key所屬的帳戶是否為統一交易帳戶. 0:普通帳戶; 1:統一交易账户
    userIDinteger用戶 ID
    inviterIDinteger邀請人 ID(邀請該賬號加入平台的賬號的UID)
    vipLevelstringVIP用戶等級
    mktMakerLevelstringmarket maker等級
    affiliateIDinteger代理商Id. 0: 表示無任何代理綁定關係
    rsaPublicKeystringRSA公鑰
    isMasterboolean是否為主帳戶下的api key
    parentUidstring主帳戶uid. 如果是主帳戶本身調用, 則返回"0"
    kycLevelstring個人帳戶的kyc等級. LEVEL_DEFAULT, LEVEL_1LEVEL_2
    kycRegionstring個人帳戶的kyc地區

    請求示例

    GET /v5/user/query-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676430842094
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "13770661",
    "note": "readwrite api key",
    "apiKey": "XXXXXX",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": [],
    "Affiliate": []
    },
    "ips": [
    "*"
    ],
    "type": 1,
    "deadlineDay": 66,
    "expiredAt": "2023-12-22T07:20:25Z",
    "createdAt": "2022-10-16T02:24:40Z",
    "unified": 0,
    "uta": 0,
    "userID": 24617703,
    "inviterID": 0,
    "vipLevel": "No VIP",
    "mktMakerLevel": "0",
    "affiliateID": 0,
    "rsaPublicKey": "",
    "isMaster": true,
    "parentUid": "0",
    "kycLevel": "LEVEL_DEFAULT",
    "kycRegion": ""
    },
    "retExtInfo": {},
    "time": 1697525990798
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/create-subuid-apikey.html b/zh-TW/v5/user/create-subuid-apikey.html index 9fd911ded4..7ce352fff3 100644 --- a/zh-TW/v5/user/create-subuid-apikey.html +++ b/zh-TW/v5/user/create-subuid-apikey.html @@ -4,13 +4,13 @@ 新建子帳戶的API Key | Bybit API Documentation - +

    新建子帳戶的API Key

    給新建好的子帳戶創建新的API key。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /v5/user/create-sub-api

    請求參數

    參數是否必須類型說明
    subuidtrueinteger子帳戶userId
    notefalsestring設置備註
    readOnlytrueinteger0:可讀可寫. 1:只讀
    ipsfalsestring綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的非永久api key將在7天後失效
    permissionstrueObject勾選api key權限.
    • 注意: 必須傳入以下權限類型的任意一種, 否則報錯
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > Exchangefalsearray兌換. ["ExchangeHistory"]
    > CopyTradingfalsearray跟單交易. ["CopyTrading"]

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstringApi密鑰密碼.
    • 注意: Api密鑰密碼只會在這裡出現一次,除此之外沒有任何地方還可以獲取到密碼。請妥善保存。
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]

    請求示例

    POST /v5/user/create-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430005459
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subuid": 53888000,
    "note": "testxxx",
    "readOnly": 0,
    "permissions": {
    "Wallet": [
    "AccountTransfer"
    ]
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "16651283",
    "note": "testxxx",
    "apiKey": "xxxxx",
    "readOnly": 0,
    "secret": "xxxxxxxx",
    "permissions": {
    "ContractTrade": [],
    "Spot": [],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "Derivatives": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    }
    },
    "retExtInfo": {},
    "time": 1676430007643
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/create-subuid.html b/zh-TW/v5/user/create-subuid.html index 26e9db64c1..bbf98e5be9 100644 --- a/zh-TW/v5/user/create-subuid.html +++ b/zh-TW/v5/user/create-subuid.html @@ -4,13 +4,13 @@ 新建子帳戶 | Bybit API Documentation - +

    新建子帳戶

    創建新的子帳戶。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /v5/user/create-sub-member

    請求參數

    參數是否必須類型說明
    usernametruestring給新的子帳戶創建一個用戶名。
    • 6-16位字符,須同時含有數字和字母。
    • 不能與已存在或已刪除的帳戶用戶名重複。
    passwordfalsestring給新的子帳戶設置一個密碼。
    • 8-30位字符,須同時含有數字和大小寫字母。
    memberTypetrueinteger1: 普通子帳戶, 6: 託管子帳戶
    switchfalseinteger
    • 0: 關閉快捷登陸 (默認關閉)
    • 1: 打開快捷登陸.
    isUtafalseboolean
    • true: 創建統一帳戶
    • false(默認): 創建普通帳戶
    notefalsestring設置備註

    返回參數

    參數類型說明
    uidstring子帳戶userId
    usernamestring給新的子帳戶創建一個用戶名
    • 6-16位字符,須同時含有數字和字母。
    • 不能與已存在或已刪除的帳戶用戶名重複。
    memberTypeinteger1: 普通子帳戶, 6: 託管子帳戶
    statusinteger帳戶狀態
    • 1: 正常
    • 2: 登陸封禁
    • 4: 凍結
    remarkstring設置的備註

    請求示例

    POST /v5/user/create-sub-member HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXXX
    X-BAPI-API-KEY: XXXXXXX
    X-BAPI-TIMESTAMP: 1676429344202
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "username": "xxxxx",
    "memberType": 1,
    "switch": 1,
    "note": "test"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "uid": "53888000",
    "username": "xxxxx",
    "memberType": 1,
    "status": 1,
    "remark": "test"
    },
    "retExtInfo": {},
    "time": 1676429344734
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/froze-subuid.html b/zh-TW/v5/user/froze-subuid.html index 9f8578523c..f01359181a 100644 --- a/zh-TW/v5/user/froze-subuid.html +++ b/zh-TW/v5/user/froze-subuid.html @@ -4,13 +4,13 @@ 凍結/解凍子帳戶 | Bybit API Documentation - +

    凍結/解凍子帳戶

    凍結或解凍子帳戶。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /v5/user/frozen-sub-member

    請求參數

    參數是否必須類型說明
    subuidtrueinteger子帳戶userId
    frozentrueinteger0:解凍, 1:凍結

    返回參數

    請求示例

    POST /v5/user/frozen-sub-member HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430842094
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "subuid": 53888001,
    "frozen": 1
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676430697553
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/modify-master-apikey.html b/zh-TW/v5/user/modify-master-apikey.html index 1ad9573e4b..82f6d42315 100644 --- a/zh-TW/v5/user/modify-master-apikey.html +++ b/zh-TW/v5/user/modify-master-apikey.html @@ -4,13 +4,13 @@ 修改母帳戶的API Key設置 | Bybit API Documentation - +

    修改母帳戶的API Key設置

    修改母帳戶API key的設置。使用待修改的api key調用接口。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    信息

    只能修改調用該接口的api key

    HTTP 請求

    POST /v5/user/update-api

    請求參數

    參數是否必須類型說明
    readOnlyfalseinteger0 (默認):可讀可寫. 1:只讀
    ipsfalsestring綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的非永久api key將在7天後失效
    permissionsfalseObject勾選api key權限. 如果不修改權限, 則不要傳入該參數
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransfer"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > CopyTradingfalsearray跟單交易. ["CopyTrading"]
    > BlockTradefalsearray大宗商品交易. ["BlockTrade"]
    > Exchangefalsearray兌換. ["ExchangeHistory"]
    > NFTfalsearrayNFT. ["NFTQueryProductList"]
    > Affiliatefalsearray代理商查詢權限. ["Affiliate"]
    • 該權限僅作用於代理商
    • 如果您需要該權限, 請確保移除所有其他權限項

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringApi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是 ""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限
    > BlockTradearray大宗交易的權限
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限
    ipsarray綁定的IP

    請求示例

    POST /v5/user/update-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431264739
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {
    "readOnly": null,
    "ips": "*",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "13770661",
    "note": "xxxxx",
    "apiKey": "xxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [
    "Order",
    "Position"
    ],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer",
    "SubMemberTransfer"
    ],
    "Options": [
    "OptionsTrade"
    ],
    "Derivatives": [
    "DerivativesTrade"
    ],
    "CopyTrading": [
    "CopyTrading"
    ],
    "BlockTrade": [],
    "Exchange": [
    "ExchangeHistory"
    ],
    "NFT": [
    "NFTQueryProductList"
    ]
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1676431265427
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/modify-sub-apikey.html b/zh-TW/v5/user/modify-sub-apikey.html index a574c2fd87..e8da88b93b 100644 --- a/zh-TW/v5/user/modify-sub-apikey.html +++ b/zh-TW/v5/user/modify-sub-apikey.html @@ -4,13 +4,13 @@ 修改子帳戶的API Key設置 | Bybit API Documentation - +

    修改子帳戶的API Key設置

    修改子帳戶API key的設置, 支持母帳戶管理子帳戶key的設置, 或者子帳戶key直接修改本身。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 子API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)"
    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /v5/user/update-sub-api

    請求參數

    參數是否必須類型說明
    apikeyfalsestring子帳戶的api key
    • 當您要使用母帳戶來管理子帳戶的key時, 該字段必傳
    • 如果您是用對應的子帳戶api key修改本身, 該字段請不要傳入, 否則報錯
    readOnlyfalseinteger0 (默認):可讀可寫. 1:只讀
    ipsfalsestring綁定IP. 比如: "192.168.0.1,192.168.0.2"注意:
    • 不傳參數ips 或者入参值為"*"意味著不綁定
    • 不綁定IP的api key將有90天的有效期限
    • 一旦帳戶密碼做了修改,帳戶下的非永久api key將在7天後失效
    permissionsfalseObject勾選api key權限. 如果不修改權限, 則不要傳入該參數
    > ContractTradefalsearray合約. ["Order","Position"]
    > Spotfalsearray現貨. ["SpotTrade"]
    > Walletfalsearray錢包. ["AccountTransfer","SubMemberTransferList"]
    > OptionsfalsearrayUSDC合約. ["OptionsTrade"]
    > Derivativesfalsearray統一帳戶權限. 該字段失效, 因為系統將會自動根據您的帳戶類型(經典帳戶和統一帳戶)來決定是否增加該權限
    > Exchangefalsearray兌換. ["ExchangeHistory"]
    > CopyTradingfalsearray跟單交易. ["CopyTrading"]

    返回參數

    參數類型說明
    idstring唯一id. 內部使用
    notestring備註
    apiKeystringapi key
    readOnlyinteger0:可讀可寫. 1:只讀
    secretstring總是 ""
    permissionsObject權限類型
    > ContractTradearray合約交易的權限e
    > Spotarray現貨交易的權限
    > Walletarray錢包的權限
    > OptionsarrayUSDC合約的權限. 該權限支持USDC合約下的期權和永續交易
    > Derivativesarray統一帳戶權限
    > CopyTradingarray跟單交易的權限
    > BlockTradearray大宗交易的權限. 子帳戶暫不支持,總是[]
    > Exchangearray兌換的權限
    > NFTarrayNFT的權限. 子帳戶暫不支持, 總是[]
    ipsarrayIP綁定

    請求示例

    POST /v5/user/update-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXXX
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431795752
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    {
    "readOnly": 0,
    "ips": "*",
    "permissions": {
    "ContractTrade": [],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    }
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "id": "16651472",
    "note": "testxxx",
    "apiKey": "xxxxxx",
    "readOnly": 0,
    "secret": "",
    "permissions": {
    "ContractTrade": [],
    "Spot": [
    "SpotTrade"
    ],
    "Wallet": [
    "AccountTransfer"
    ],
    "Options": [],
    "Derivatives": [],
    "CopyTrading": [],
    "BlockTrade": [],
    "Exchange": [],
    "NFT": []
    },
    "ips": [
    "*"
    ]
    },
    "retExtInfo": {},
    "time": 1676431796263
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/rm-master-apikey.html b/zh-TW/v5/user/rm-master-apikey.html index dd62df1e60..cafb142643 100644 --- a/zh-TW/v5/user/rm-master-apikey.html +++ b/zh-TW/v5/user/rm-master-apikey.html @@ -4,13 +4,13 @@ 刪除母帳戶的API Key | Bybit API Documentation - +

    刪除母帳戶的API Key

    刪除母帳戶下的api key。使用待刪除的api key調用接口。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    危險

    當心! 用於調用本接口的API KEY將會立馬失效。

    HTTP 請求

    POST /v5/user/delete-api

    請求參數

    返回參數

    請求示例

    POST /v5/user/delete-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431576621
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {

    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676431577675
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/rm-sub-apikey.html b/zh-TW/v5/user/rm-sub-apikey.html index b68ba113f5..43a76e3504 100644 --- a/zh-TW/v5/user/rm-sub-apikey.html +++ b/zh-TW/v5/user/rm-sub-apikey.html @@ -4,13 +4,13 @@ 刪除子帳戶下的API Key | Bybit API Documentation - +

    刪除子帳戶下的API Key

    刪除子帳戶下的api key。使用待刪除的子帳戶api key調用接口或者使用母帳戶調用刪除指定api key

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 子API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)"
    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
    危險

    當心! 用於調用本接口後, 對應的子帳戶api key會立馬失效。

    HTTP 請求

    POST /v5/user/delete-sub-api

    請求參數

    參數是否必須類型說明
    apikeyfalsestring子帳戶的api key
    • 當您要使用母帳戶來管理子帳戶的key時, 該字段必傳
    • 如果您是用對應的子帳戶api key修改本身, 該字段請不要傳入, 否則報錯

    返回參數

    請求示例

    POST /v5/user/delete-sub-api HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1676431922953
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json

    {

    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {},
    "retExtInfo": {},
    "time": 1676431924719
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/rm-subuid.html b/zh-TW/v5/user/rm-subuid.html index 6bcac3fbef..2ebee06e39 100644 --- a/zh-TW/v5/user/rm-subuid.html +++ b/zh-TW/v5/user/rm-subuid.html @@ -4,14 +4,14 @@ 刪除子帳戶 | Bybit API Documentation - +

    刪除子帳戶

    刪除子帳戶. 在刪除前, 確保該帳戶已經沒有資產了
    僅可使用帳戶api key調用.

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    POST /v5/user/del-submember

    請求參數

    參數是否必須類型說明
    subMemberIdtruestringSub UID

    返回參數

    請求示例

    POST /v5/user/del-submember HTTP/1.1
    Host: api.bybit.com
    X-BAPI-API-KEY: XXXXXX
    X-BAPI-TIMESTAMP: 1698907012755
    X-BAPI-RECV-WINDOW: 5000
    X-BAPI-SIGN: XXXXXX
    Content-Type: application/json
    Content-Length: 34

    {
    "subMemberId": "112725187"
    }

    響應示例

    {
    "retCode": 0,
    "retMsg": "OK",
    "result": {},
    "retExtInfo": {},
    "time": 1698907012962
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/subuid-list.html b/zh-TW/v5/user/subuid-list.html index 5d0e2b9587..f9bb254b53 100644 --- a/zh-TW/v5/user/subuid-list.html +++ b/zh-TW/v5/user/subuid-list.html @@ -4,13 +4,13 @@ 查詢子帳戶UID列表 | Bybit API Documentation - +

    查詢子帳戶UID列表

    獲取當前母帳戶下所有的子帳戶列表。需使用帳戶的API key。

    提示

    在調用接口時,使用的API key至少需要擁有以下其中一種權限

    • 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"

    HTTP 請求

    GET /v5/user/query-sub-members

    請求參數

    返回參數

    參數類型說明
    subMembersarrayObject
    > uidstring子帳戶userId
    > usernamestring用戶名
    > memberTypeinteger1: 普通子帳戶, 6: 託管子帳戶
    > statusinteger帳戶狀態.
    • 1: 正常
    • 2: 登陸封禁
    • 4: 凍結
    > accountModeinteger帳戶模式.
    • 1: 經典帳戶
    • 2: UMA帳戶
    • 3: UTA帳戶
    > remarkstring備註

    請求示例

    GET /v5/user/query-sub-members HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1676430318405
    X-BAPI-RECV-WINDOW: 5000

    響應示例

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "subMembers": [
    {
    "uid": "53888001",
    "username": "xxx001",
    "memberType": 1,
    "status": 1,
    "remark": "test",
    "accountMode": 1
    },
    {
    "uid": "53888002",
    "username": "xxx002",
    "memberType": 6,
    "status": 1,
    "remark": "",
    "accountMode": 3
    }
    ]
    },
    "retExtInfo": {},
    "time": 1676430319452
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/user/wallet-type.html b/zh-TW/v5/user/wallet-type.html index d4230388a8..e0aa7e510b 100644 --- a/zh-TW/v5/user/wallet-type.html +++ b/zh-TW/v5/user/wallet-type.html @@ -4,13 +4,13 @@ 查詢帳戶支持的錢包類型 | Bybit API Documentation - +

    查詢帳戶支持的錢包類型

    查詢母帳戶或者子帳戶下支持的錢包類型

    提示
    • 使用母帳戶api key: 您可以查詢到母帳戶以及指定的子帳戶的錢包類型, 子帳戶的uid最多單次可查詢200個.
    • 使用子帳戶api key: 僅能查詢自身的錢包類型
    最佳實踐

    "FUND" - 這個資金錢包, 如果您從未存入或者轉入過資金, 該接口返回的數組裡將不會呈現該枚舉值, 但實際上您的帳戶總是擁有該錢包.

    • ["SPOT","OPTION","FUND","CONTRACT"] : 普通帳戶並且資金錢包曾經操作過
    • ["SPOT","OPTION","CONTRACT"] : 普通帳戶並且資金錢包不曾操作過
    • ["SPOT","UNIFIED","FUND","CONTRACT"] : UMA帳戶並且資金錢包曾經操作過. (等強制或主動升級到UTA後, 就沒有UMA帳戶的概念了)
    • ["SPOT","UNIFIED","CONTRACT"] : UMA帳戶並且資金錢包不曾操作過. (等強制或主動升級到UTA後, 就沒有UMA帳戶的概念了)
    • ["UNIFIED""FUND","CONTRACT"] : UTA帳戶並且資金錢包曾經操作過
    • ["UNIFIED","CONTRACT"] : UTA帳戶並且資金錢包不曾操作過

    HTTP 請求

    GET /v5/user/get-member-type

    請求參數

    參數是否必須類型說明
    memberIdsfalsestring
    • 不入参時, 僅查詢自身
    • 當使用母帳戶api key查詢子uid時, 母帳戶的數據總是返回且在數組的第一個
    • 支持輸入多個子uid, 用逗號隔開, 單次查詢最多支持200個
    • 子帳戶api key查詢時, 該入参將會被忽略

    返回參數

    參數類型說明
    accountsarrayObject
    > uidstring母/子 uid
    > accountTypearraySPOT, CONTRACT, FUND, OPTION, UNIFIED. 請查閱上面的最佳實踐來理解返回的值

    Request Example

    GET /v5/user/get-member-type HTTP/1.1
    Host: api.bybit.com
    X-BAPI-SIGN: XXXXX
    X-BAPI-API-KEY: XXXXX
    X-BAPI-TIMESTAMP: 1686888846320
    X-BAPI-RECV-WINDOW: 5000
    Content-Type: application/json

    Response Example

    {
    "retCode": 0,
    "retMsg": "",
    "result": {
    "accounts": [
    {
    "uid": "24617703",
    "accountType": [
    "SPOT",
    "OPTION",
    "FUND",
    "CONTRACT"
    ]
    }
    ]
    },
    "retExtInfo": {},
    "time": 1686895670002
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/dcp.html b/zh-TW/v5/websocket/private/dcp.html index c495f3faaa..ea30540a20 100644 --- a/zh-TW/v5/websocket/private/dcp.html +++ b/zh-TW/v5/websocket/private/dcp.html @@ -4,13 +4,13 @@ 斷線保護 (期權) | Bybit API Documentation - +

    斷線保護 (期權)

    通過訂閱DCP流來觸發功能

    舉例: 私有連接A訂閱了"dcp", 私有連接B沒有訂閱"dcp", 私有連接C訂閱了"dcp".

    1. 如果連接A在線, 連接B斷線, 連接C在線, 那麼這種情況下不會觸發DCP功能.
    2. 如果連接A在線, 連接B斷線, 連接C斷線, 那麼這種情況下不會觸發DCP功能.
    3. 如果連接A斷線, 連接B在線, 連接C斷線, 那麼這種情況下就會當達到時間窗口的閾值後觸發斷線保護機制.

    綜上, 只有當所有訂閱了"dcp"的私有連接斷線後, 斷線保護機制才會被觸發.

    Topic: dcp

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "dcp"
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/execution.html b/zh-TW/v5/websocket/private/execution.html index 67ced68c20..10658795f5 100644 --- a/zh-TW/v5/websocket/private/execution.html +++ b/zh-TW/v5/websocket/private/execution.html @@ -4,14 +4,14 @@ 個人成交 | Bybit API Documentation - +

    個人成交

    訂閱個人成交的推送

    提示

    單筆訂單可能有多次成交

    All-In-One Topic: execution
    Categorised Topic: execution.spot, execution.linear, execution.inverse, execution.option

    信息
    • All-In-One topic 和 Categorised topic 不能放在同一個訂閱請求裡
    • All-In-One topic: 允許您監聽所有業務線的websocket更新(現貨, 正向合約, 反向合約, 期權)
    • Categorised Topic: 您只能監聽您指定的那個業務的websocket更新

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    creationTimenumber消息數據創建時間
    dataarrayObject
    > categorystring產品類型
    • 統一帳戶: spot, linear, iverse, option
    • 普通帳戶: spot, linear, inverse.
    > symbolstring合約名稱
    > isLeveragestring是否借貸. 僅統一帳戶spot有效. 0: 否, 1: 是. 普通帳戶現貨交易不支持, 總是0
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義訂單ID
    > sidestring訂單方向.買:Buy,賣:Sell
    > orderPricestring訂單價格. 普通帳戶現貨交易不支持
    > orderQtystring訂單數量. 普通帳戶現貨交易不支持
    > leavesQtystring剩餘委託未成交數量. 普通帳戶現貨交易不支持
    > orderTypestring訂單類型. 市價單:Market,限價單:Limit
    > stopOrderTypestring条件单的订单类型。如果该订单不是条件单,则不会返回任何类型. 普通帳戶現貨交易不支持
    > execFeestring交易手續費. 您可以從這裡了解現貨手續費幣種信息. 普通帳戶現貨交易不支持
    > execIdstring成交Id
    > execPricestring成交價格
    > execQtystring成交數量
    > execTypestring成交類型. 普通帳戶現貨交易不支持
    > execValuestring成交價值. 普通帳戶現貨交易不支持
    > execTimestring成交時間(毫秒)
    > isMakerBool是否是 Maker 訂單,true 為 maker 訂單,false 為 taker 訂單
    > feeRatestring手續費率. 普通帳戶現貨交易不支持
    > tradeIvstring隱含波動率,僅期權有效
    > markIvstring標記價格的隱含波動率,僅期權有效
    > markPricestring成交執行時,該 symbol 當時的標記價格. 目前僅對期權業務有效
    > indexPricestring成交執行時,該 symbol 當時的指數價格,目前僅對期權業務有效
    > underlyingPricestring成交執行時,該 symbol 當時的底層資產價格,僅期權有效
    > blockTradeIdstring大宗交易的订单 ID ,使用 paradigm 进行大宗交易时生成的 ID
    > closedSizestring平倉數量
    > seqlong序列號, 用於關聯成交和倉位的更新
    • 同一時間有多筆成交, seq相同
    • 不同的幣對會存在相同seq, 可以使用seq + symbol來做唯一性識別

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "execution"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.execution_stream(callback=handle_message)
    while True:
    sleep(1)

    推送示例

    {
    "id": "592324803b2785-26fa-4214-9963-bdd4727f07be",
    "topic": "execution",
    "creationTime": 1672364174455,
    "data": [
    {
    "category": "linear",
    "symbol": "XRPUSDT",
    "execFee": "0.005061",
    "execId": "7e2ae69c-4edf-5800-a352-893d52b446aa",
    "execPrice": "0.3374",
    "execQty": "25",
    "execType": "Trade",
    "execValue": "8.435",
    "isMaker": false,
    "feeRate": "0.0006",
    "tradeIv": "",
    "markIv": "",
    "blockTradeId": "",
    "markPrice": "0.3391",
    "indexPrice": "",
    "underlyingPrice": "",
    "leavesQty": "0",
    "orderId": "f6e324ff-99c2-4e89-9739-3086e47f9381",
    "orderLinkId": "",
    "orderPrice": "0.3207",
    "orderQty": "25",
    "orderType": "Market",
    "stopOrderType": "UNKNOWN",
    "side": "Sell",
    "execTime": "1672364174443",
    "isLeverage": "0",
    "closedSize": "25",
    "seq": 4688002127
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/greek.html b/zh-TW/v5/websocket/private/greek.html index a7fed53966..d1c7116b1e 100644 --- a/zh-TW/v5/websocket/private/greek.html +++ b/zh-TW/v5/websocket/private/greek.html @@ -4,13 +4,13 @@ 用戶希臘字母信息 (期權) | Bybit API Documentation - +

    用戶希臘字母信息 (期權)

    訂閱用戶希臘字母數據推送

    Topic: greeks

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    creationTimenumber消息數據創建時間
    dataarrayObject
    > baseCoinstring交易幣種
    > totalDeltastringDelta值
    > totalGammastringGamma值
    > totalVegastringVega值
    > totalThetastringTheta值

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "greeks"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.greek_stream(callback=handle_message)
    while True:
    sleep(1)

    推送示例

    {
    "id": "592324fa945a30-2603-49a5-b865-21668c29f2a6",
    "topic": "greeks",
    "creationTime": 1672364262482,
    "data": [
    {
    "baseCoin": "ETH",
    "totalDelta": "0.06999986",
    "totalGamma": "-0.00000001",
    "totalVega": "-0.00000024",
    "totalTheta": "0.00001314"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/order.html b/zh-TW/v5/websocket/private/order.html index 13df226423..b57622ab29 100644 --- a/zh-TW/v5/websocket/private/order.html +++ b/zh-TW/v5/websocket/private/order.html @@ -4,14 +4,14 @@ 訂單 | Bybit API Documentation - +

    訂單

    訂閱訂單數據推送

    All-In-One Topic: order
    Categorised Topic: order.spot, order.linear, order.inverse, order.option

    信息
    • All-In-One topic 和 Categorised topic 不能放在同一個訂閱請求裡
    • All-In-One topic: 允許您監聽所有業務線的websocket更新(現貨, 正向合約, 反向合約, 期權)
    • Categorised Topic: 您只能監聽您指定的那個業務的websocket更新

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    creationTimenumber消息數據創建時間
    dataarrayObject
    > categorystring產品類型
    • 統一帳戶: spot, linear, inverse, option
    • 普通帳戶: spot, linear, inverse.
    > orderIdstring訂單ID
    > orderLinkIdstring用戶自定義ID
    > isLeveragestring是否借貸. 僅統一帳戶spot有效. 0: 否, 1: 是. 普通帳戶現貨交易不支持, 總是0
    > blockTradeIdstring大宗交易訂單Id
    > symbolstring合約名稱
    > pricestring訂單價格
    > qtystring訂單數量
    > sidestring方向. Buy,Sell
    > positionIdxinteger倉位標識。用戶不同倉位模式
    > orderStatusstring訂單狀態
    > cancelTypestring訂單被取消類型. 普通帳戶現貨交易不支持
    > rejectReasonstring拒絕原因. 普通帳戶現貨交易不支持
    > avgPricestring訂單平均成交價格. 若沒有成交,則返回"".
    • 普通帳戶的USDT永續和反向合約交易, 如果是一筆部分成交訂單且終態是Cancelled, 則avgPrice是"0"
    • 普通現貨帳戶交易不支持該字段, 總是""
    > leavesQtystring訂單剩餘未成交的數量. 普通帳戶現貨交易不支持
    > leavesValuestring訂單剩餘未成交的價值. 普通帳戶現貨交易不支持
    > cumExecQtystring訂單累計成交數量
    > cumExecValuestring訂單累計成交價值
    > cumExecFeestring訂單累計成交的手續費. 特別地, 對於普通帳戶現貨, 該字段表示的是單筆成交的手續費
    > feeCurrencystring現貨交易的手續費幣種. 可以從這裡了解現貨交易的手續費幣種規則
    > timeInForcestring執行策略
    > orderTypestring訂單類型. Market,Limit. 對於止盈止損單, 則表示為觸發後的訂單類型
    > stopOrderTypestring條件單類型
    > ocoTriggerTypestring現貨OCO訂單的觸發類型.OcoTriggerByUnknown, OcoTriggerTp, OcoTriggerBySl. 經典帳戶現貨不支持該字段
    > orderIvstring隱含波動率
    > triggerPricestring觸發價格. 若stopOrderType=TrailingStop, 則這是激活價格. 否則, 它是觸發價格
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > tpslModestring止盈止損模式 Full: 全部倉位止盈止損, Partial: 部分倉位止盈止損. 現貨不返回該字段, 期權總是返回""
    > tpLimitPricestring觸發止盈後轉換為限價單的價格
    > slLimitPricestring觸發止損後轉換為限價單的價格
    > tpTriggerBystring觸發止盈的價格類型
    > slTriggerBystring觸發止損的價格類型
    > triggerDirectioninteger觸發方向. 1: 上漲, 2: 下跌
    > triggerBystring觸發價格的觸發類型
    > lastPriceOnCreatedstring下單時的市場價格
    > reduceOnlyboolean只減倉. true表明這是只減倉單
    > closeOnTriggerboolean觸發後平倉委託. 什麼是觸發後平倉委託?
    > placeTypestringPlace type, option used. iv, price
    > smpTypestringSMP執行類型
    > smpGroupinteger所屬Smp組ID. 如果uid不屬於任何組, 則默認為0
    > smpOrderIdstring觸發此SMP執行的交易對手的 orderID
    > createdTimestring創建訂單的時間戳 (毫秒)
    > updatedTimestring訂單更新的時間戳 (毫秒)

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "order"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.order_stream(callback=handle_message)
    while True:
    sleep(1)

    推送示例

    {
    "id": "5923240c6880ab-c59f-420b-9adb-3639adc9dd90",
    "topic": "order",
    "creationTime": 1672364262474,
    "data": [
    {
    "symbol": "ETH-30DEC22-1400-C",
    "orderId": "5cf98598-39a7-459e-97bf-76ca765ee020",
    "side": "Sell",
    "orderType": "Market",
    "cancelType": "UNKNOWN",
    "price": "72.5",
    "qty": "1",
    "orderIv": "",
    "timeInForce": "IOC",
    "orderStatus": "Filled",
    "orderLinkId": "",
    "lastPriceOnCreated": "",
    "reduceOnly": false,
    "leavesQty": "",
    "leavesValue": "",
    "cumExecQty": "1",
    "cumExecValue": "75",
    "avgPrice": "75",
    "blockTradeId": "",
    "positionIdx": 0,
    "cumExecFee": "0.358635",
    "createdTime": "1672364262444",
    "updatedTime": "1672364262457",
    "rejectReason": "EC_NoError",
    "stopOrderType": "",
    "tpslMode": "",
    "triggerPrice": "",
    "takeProfit": "",
    "stopLoss": "",
    "tpTriggerBy": "",
    "slTriggerBy": "",
    "tpLimitPrice": "",
    "slLimitPrice": "",
    "triggerDirection": 0,
    "triggerBy": "",
    "closeOnTrigger": false,
    "category": "option",
    "placeType": "price",
    "smpType": "None",
    "smpGroup": 0,
    "smpOrderId": "",
    "feeCurrency": ""
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/position.html b/zh-TW/v5/websocket/private/position.html index 45c8851400..45b6c48fa6 100644 --- a/zh-TW/v5/websocket/private/position.html +++ b/zh-TW/v5/websocket/private/position.html @@ -4,14 +4,14 @@ 持倉 | Bybit API Documentation - +

    持倉

    訂閱持倉數據的推送

    All-In-One Topic: position
    Categorised Topic: position.linear, position.inverse, position.option

    信息
    • All-In-One topic 和 Categorised topic 不能放在同一個訂閱請求裡
    • All-In-One topic: 允許您監聽所有業務線的websocket倉位更新(正向合約, 反向合約, 期權)
    • Categorised Topic: 您只能監聽您指定的那個業務的websocket更新

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    creationTimenumber消息數據創建時間
    dataarrayObject
    > categorystring產品類型
    > symbolstring合約名稱
    > sidestring持倉方向. Buy,Sell
    > sizestring持倉大小
    > positionIdxinteger倉位標識
    > tradeModeinteger交易模式。
    • 統一帳戶 (反向合約) & 普通帳戶: 0: 全倉, 1: 逐倉
    • 統一帳戶: 廢棄, 總是 0
    > positionValuestring倉位價值
    > riskIdinteger風險限額id. 注意: 組合保證金模式下,該字段返回0,風險限額規則失效
    > riskLimitValuestring風險限額id對應的風險限額度. 注意: 組合保證金模式下,該字段返回空字符串,風險限額規則失效
    > entryPricestring入場價
    > markPricestring標記價
    > leveragestring槓桿. 注意: 組合保證金模式下,該字段返回"",槓桿規則失效
    > positionBalancestring倉位保證金. 組合保證金模式(PM)下, 該字段返回為空字符串
    > autoAddMargininteger是否自動追加保證金. 0: 否, 1: 是. 僅當統一帳戶(除反向合約)開啟了帳戶維度的逐倉保證金模式, 該字段才有意義
    > positionMMstring倉位維持保證金. 注意: 組合保證金模式下,該字段返回空字符串
    > positionIMstring倉位初始保證金. 注意: 組合保證金模式下,該字段返回空字符串
    > liqPricestring倉位強平價格,
    • UTA(反向合約) & 普通账户 & UTA(開啟逐倉保證金模式):是逐倉和全倉持仓的真實價格, 當強平價 <= minPrice或者 強平價 >= maxPrice, 則為""
    • 統一帳戶(全倉保證金):是全倉持仓的预估价格(因为统一帳戶模式是按照帳戶維度控制风险率), 當強平價 <= minPrice或者 強平價 >= maxPrice, 則為""
    但是對於組合保證金模式,此字段為空,不會提供強平價格
    > bustPricestring預估破產價. 統一帳戶(現貨/USDT和USDC永續/期權)為空
    > tpslModestring該字段廢棄, 無意義, 總是返回"Full". 期權總是返回""
    > takeProfitstring止盈價格
    > stopLossstring止損價格
    > trailingStopstring追蹤止損
    > unrealisedPnlstring未結盈虧
    > cumRealisedPnlstring累计已结盈亏
    • 期貨: 是從第一次開始有持倉加總的已結盈虧
    • 期權: 它是本次持倉的加總已結盈虧
    > positionStatusstring倉位狀態. Normal,Liq, Adl
    > adlRankIndicatorinteger自動減倉燈. 什麼是自動減倉機制?
    > isReduceOnlyboolean僅當Bybit需要降低某個Symbol的風險限額時有用
    • true: 僅允許減倉操作. 您可以考慮一系列的方式, 比如, 降低risk limit檔位, 或者同檔位修改槓桿或減少倉位, 或者增加保證金, 或者撤單, 這些操作做完後, 可以主動調用確認新的風險限額接口
    • false(默認): 沒有交易限制, 表示您的倉位在系統調整時處於風險水平之下
    • 僅對逐倉和全倉的期貨倉位有意義
    > mmrSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改MMR的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了MMR調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > leverageSysUpdatedTimestring僅當Bybit需要降低某個Symbol的風險限額時有用
    • 當isReduceOnly=true: 這個時間戳表示系統強制修改槓桿的時間
    • 當isReduceOnly=false: 若不為空, 則表示系統已經完成了槓桿調整的時間
    • 僅當系統調整才會賦值, 對於主動的調整, 不會在這裡展示時間戳
    • 默認為"", 但如果曾經這個symbol有過系統降檔的操作, 那麼這裡會顯示上一次操作的時間
    • 僅對逐倉和全倉的期貨倉位有意義
    > createdTimestring倉位創建時間戳 (毫秒)
    > updatedTimestring倉位數據更新時間戳 (毫秒)
    > seqlong序列號, 用於關聯成交和倉位的更新
    • 不同的幣對會存在相同seq, 可以使用seq + symbol來做唯一性識別
    • 如果該幣對從未被交易過, 查詢時則會返回"-1"
    • 對於更新槓桿、更新風險限額等非交易行為, 將會返回上一次成交時更新的seq

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "position"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.position_stream(callback=handle_message)
    while True:
    sleep(1)

    推送示例

    {
    "id": "1003076014fb7eedb-c7e6-45d6-a8c1-270f0169171a",
    "topic": "position",
    "creationTime": 1697682317044,
    "data": [
    {
    "positionIdx": 2,
    "tradeMode": 0,
    "riskId": 1,
    "riskLimitValue": "2000000",
    "symbol": "BTCUSDT",
    "side": "",
    "size": "0",
    "entryPrice": "0",
    "leverage": "10",
    "positionValue": "0",
    "positionBalance": "0",
    "markPrice": "28184.5",
    "positionIM": "0",
    "positionMM": "0",
    "takeProfit": "0",
    "stopLoss": "0",
    "trailingStop": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "-25.06579337",
    "createdTime": "1694402496913",
    "updatedTime": "1697682317038",
    "tpslMode": "Full",
    "liqPrice": "0",
    "bustPrice": "",
    "category": "linear",
    "positionStatus": "Normal",
    "adlRankIndicator": 0,
    "autoAddMargin": 0,
    "leverageSysUpdatedTime": "",
    "mmrSysUpdatedTime": "",
    "seq": 8327597863,
    "isReduceOnly": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/private/wallet.html b/zh-TW/v5/websocket/private/wallet.html index 6342207dd7..6d1bc7f07c 100644 --- a/zh-TW/v5/websocket/private/wallet.html +++ b/zh-TW/v5/websocket/private/wallet.html @@ -4,13 +4,13 @@ 錢包 | Bybit API Documentation - +

    錢包

    訂閱錢包數據推送

    Topic: wallet

    響應參數

    參數類型說明
    idstring消息id
    topicstringTopic名
    creationTimenumber消息數據創建時間
    dataarrayObject
    > accountTypestring帳戶類型.
    • 統一帳戶: UNIFIED(現貨/USDT和USDC永續/期權), CONTRACT(反向合約)
    • 普通帳戶: CONTRACT, SPOT
    > accountLTVstring帳戶LTV: account total borrowed size / (account total equity + account total borrowed size). 非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > accountIMRatestring帳戶初始保證金率: Account Total Initial Margin Base Coin / Account Margin Balance Base Coin. 非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > accountMMRatestring帳戶維持保證金率: Account Total Maintenance Margin Base Coin / Account Margin Balance Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalEquitystring賬戶維度換算成usd的資產淨值:Account Margin Balance Base Coin + Account Option Value Base Coin。非統一保證金模式和統一帳戶(反向)下,該字段返回為空。
    > totalWalletBalancestring賬戶維度換算成usd的產錢包餘額:∑ Asset Wallet Balance By USD value of each asset。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalMarginBalancestring賬戶維度換算成usd的保證金餘額:totalWalletBalance + totalPerpUPL。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalAvailableBalancestring賬戶維度換算成usd的可用餘額:RM:totalMarginBalance - totalInitialMargin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalPerpUPLstring賬戶維度換算成usd的永續和USDC交割合約的浮動盈虧:∑ Each perp and USDC Futures upl by base coin。非統一保證金模式以及統一帳戶(反向)下,該字段返回為空。
    > totalInitialMarginstring賬戶維度換算成usd的總初始保證金:∑ Asset Total Initial Margin Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > totalMaintenanceMarginstring賬戶維度換算成usd的總維持保證金: ∑ Asset Total Maintenance Margin Base Coin。非統一保證金模式和統一帳戶(反向)以及統一帳戶(逐倉模式),該字段返回為空。
    > coinarrayObject. 幣種列表
    >> coinstring幣種名稱,例如 BTC,ETH,USDT,USDC
    >> equitystring當前幣種的資產淨值
    >> usdValuestring當前幣種折算成 usd 的價值,如果該幣種不能作為保證金的抵押品,則該數值為0
    >> walletBalancestring當前幣種的錢包餘額
    >> freestring普通帳戶現貨錢包的可用餘額. 普通帳戶現貨錢包的獨有字段
    >> lockedstring現貨掛單凍結金額
    >> borrowAmountstring當前幣種的已用借貸額度
    >> availableToBorrowstring由於母子共享借貸限額, 該字段已廢棄, 總是返回"". 請通過查詢抵押品信息接口查詢availableToBorrow
    >> availableToWithdrawstring當前幣種的可劃轉提現金額
    >> accruedIntereststring當前幣種的預計要在下一個利息週期收取的利息金額
    >> totalOrderIMstring以當前幣種結算的訂單委託預佔用保證金. 組合保證金模式下,該字段返回空字符串
    >> totalPositionIMstring以當前幣種結算的所有倉位起始保證金求和 + 所有倉位的預佔用平倉手續費. 組合保證金模式下,該字段返回空字符串
    >> totalPositionMMstring以當前幣種結算的所有倉位維持保證金求和. 組合保證金模式下,該字段返回空字符串
    >> unrealisedPnlstring以當前幣種結算的所有倉位的未結盈虧之和
    >> cumRealisedPnlstring以當前幣種結算的所有倉位的累計已結盈虧之和
    >> bonusstring體驗金. UNIFIED帳戶的獨有字段
    >> marginCollateralboolean是否可作為保證金抵押幣種(平台維度), true: 是. false: 否
    • 當marginCollateral=false時, 則collateralSwitch無意義
    • UNIFIED帳戶的獨有字段
    >> collateralSwitchboolean用戶是否開啟保證金幣種抵押(用戶維度), true: 是. false: 否
    • 僅當marginCollateral=true時, 才能主動選擇開關抵押
    • UNIFIED帳戶的獨有字段

    訂閱示例

    {
    "op": "subscribe",
    "args": [
    "wallet"
    ]
    }
    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="private",
    api_key="XXXXX",
    api_secret="XXXXX",
    )
    def handle_message(message):
    print(message)
    ws.wallet_stream(callback=handle_message)
    while True:
    sleep(1)

    推送示例

    {
    "id": "5923242c464be9-25ca-483d-a743-c60101fc656f",
    "topic": "wallet",
    "creationTime": 1672364262482,
    "data": [
    {
    "accountIMRate": "0.016",
    "accountMMRate": "0.003",
    "totalEquity": "12837.78330098",
    "totalWalletBalance": "12840.4045924",
    "totalMarginBalance": "12837.78330188",
    "totalAvailableBalance": "12632.05767702",
    "totalPerpUPL": "-2.62129051",
    "totalInitialMargin": "205.72562486",
    "totalMaintenanceMargin": "39.42876721",
    "coin": [
    {
    "coin": "USDC",
    "equity": "200.62572554",
    "usdValue": "200.62572554",
    "walletBalance": "201.34882644",
    "availableToWithdraw": "0",
    "availableToBorrow": "1500000",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "202.99874213",
    "totalPositionMM": "39.14289747",
    "unrealisedPnl": "74.2768991",
    "cumRealisedPnl": "-209.1544627",
    "bonus": "0"
    },
    {
    "coin": "BTC",
    "equity": "0.06488393",
    "usdValue": "1023.08402268",
    "walletBalance": "0.06488393",
    "availableToWithdraw": "0.06488393",
    "availableToBorrow": "2.5",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "0",
    "bonus": "0"
    },
    {
    "coin": "ETH",
    "equity": "0",
    "usdValue": "0",
    "walletBalance": "0",
    "availableToWithdraw": "0",
    "availableToBorrow": "26",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "0",
    "bonus": "0"
    },
    {
    "coin": "USDT",
    "equity": "11726.64664904",
    "usdValue": "11613.58597018",
    "walletBalance": "11728.54414904",
    "availableToWithdraw": "11723.92075829",
    "availableToBorrow": "2500000",
    "borrowAmount": "0",
    "accruedInterest": "0",
    "totalOrderIM": "0",
    "totalPositionIM": "2.72589075",
    "totalPositionMM": "0.28576575",
    "unrealisedPnl": "-1.8975",
    "cumRealisedPnl": "0.64782276",
    "bonus": "0"
    },
    {
    "coin": "EOS3L",
    "equity": "215.0570412",
    "usdValue": "0",
    "walletBalance": "215.0570412",
    "availableToWithdraw": "215.0570412",
    "availableToBorrow": "0",
    "borrowAmount": "0",
    "accruedInterest": "",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "0",
    "bonus": "0"
    },
    {
    "coin": "BIT",
    "equity": "1.82",
    "usdValue": "0.48758257",
    "walletBalance": "1.82",
    "availableToWithdraw": "1.82",
    "availableToBorrow": "0",
    "borrowAmount": "0",
    "accruedInterest": "",
    "totalOrderIM": "0",
    "totalPositionIM": "0",
    "totalPositionMM": "0",
    "unrealisedPnl": "0",
    "cumRealisedPnl": "0",
    "bonus": "0"
    }
    ],
    "accountType": "UNIFIED",
    "accountLTV": "0.017"
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/etp-kline.html b/zh-TW/v5/websocket/public/etp-kline.html index deb390bf7b..de56935ea1 100644 --- a/zh-TW/v5/websocket/public/etp-kline.html +++ b/zh-TW/v5/websocket/public/etp-kline.html @@ -4,14 +4,14 @@ ETP淨值K線 | Bybit API Documentation - +

    ETP淨值K線

    訂閱槓桿代幣的淨值K線行情推送服務

    提示

    confirm=true, 則表示這根蠟燭是最後一根K線, 否則,這是切片數據

    可用的時間粒度:

    • 1 3 5 15 30 (分鐘)
    • 60 120 240 360 720 (分鐘)
    • D (天)
    • W (週)
    • M (月)

    推送頻率: 1-60秒

    Topic:
    kline_lt.{interval}.{symbol} e.g., kline_lt.30.BTC3SUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > startnumber開始時間戳 (毫秒)
    > endnumber結束時間戳 (毫秒). 若時間還未到時間跨度的最後時間,則表示當前時間
    > intervalstringK線粒度
    > openstring開盤價
    > closestring收盤價
    > highstring最高價
    > lowstring最低價
    > confirmboolean是否確認
    > timestampnumber蠟燭中最後一筆淨值時間戳 (毫秒)

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_kline_stream(
    interval=30,
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "type": "snapshot",
    "topic": "kline_lt.5.EOS3LUSDT",
    "data": [
    {
    "start": 1672325100000,
    "end": 1672325399999,
    "interval": "5",
    "open": "0.416039541212402799",
    "close": "0.41477848043290448",
    "high": "0.416039541212402799",
    "low": "0.409734237314911206",
    "confirm": false,
    "timestamp": 1672325322393
    }
    ],
    "ts": 1672325322393
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/etp-nav.html b/zh-TW/v5/websocket/public/etp-nav.html index 2c3a3576e6..f2d621a5ce 100644 --- a/zh-TW/v5/websocket/public/etp-nav.html +++ b/zh-TW/v5/websocket/public/etp-nav.html @@ -4,14 +4,14 @@ ETP最新淨值推送 | Bybit API Documentation - +

    ETP最新淨值推送

    訂閱槓桿代幣的最新淨值行情數據

    推送頻率: 300ms

    Topic:
    lt.{symbol} e.g.,lt.BTC3SUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > timenumber淨值生成時間戳 (毫秒)
    > symbolstring合約名稱
    > navstring淨值
    > basketPositionstring籃子頭寸
    > leveragestring槓桿倍數
    > basketLoanstring籃子借貸
    > circulationstring發行量
    > basketstring籃子

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_nav_stream(
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "topic": "lt.EOS3LUSDT",
    "ts": 1672325564669,
    "type": "snapshot",
    "data": {
    "symbol": "EOS3LUSDT",
    "time": 1672325564554,
    "nav": "0.413517419653406162",
    "basketPosition": "1.261060779498318641",
    "leverage": "2.656197506416192150",
    "basketLoan": "-0.684866519289629374",
    "circulation": "72767.309468460367138199",
    "basket": "91764.000000292013277472"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/etp-ticker.html b/zh-TW/v5/websocket/public/etp-ticker.html index 438963e20c..9c54090bdb 100644 --- a/zh-TW/v5/websocket/public/etp-ticker.html +++ b/zh-TW/v5/websocket/public/etp-ticker.html @@ -4,14 +4,14 @@ ETP淨值行情推送 | Bybit API Documentation - +

    ETP淨值行情推送

    訂閱槓桿代幣淨值行情數據

    推送頻率: 300ms

    Topic:
    tickers_lt.{symbol} e.g.,tickers_lt.BTC3SUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > symbolstring合約名稱
    > price24hPcntstring市價相對24h變化百分比
    > lastPricestring最新淨值
    > prevPrice24hstring24小時前的整點市價
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="spot",
    )
    def handle_message(message):
    print(message)
    ws.lt_ticker_stream(
    symbol="EOS3LUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    Response Example

    {
    "topic": "tickers_lt.EOS3LUSDT",
    "ts": 1672325446847,
    "type": "snapshot",
    "data": {
    "symbol": "EOS3LUSDT",
    "lastPrice": "0.41477848043290448",
    "highPrice24h": "0.435285472510871305",
    "lowPrice24h": "0.394601507960931382",
    "prevPrice24h": "0.431502290172376349",
    "price24hPcnt": "-0.0388"
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/kline.html b/zh-TW/v5/websocket/public/kline.html index c437ec5fb3..759dab6f3a 100644 --- a/zh-TW/v5/websocket/public/kline.html +++ b/zh-TW/v5/websocket/public/kline.html @@ -4,14 +4,14 @@ K線 | Bybit API Documentation - +

    K線

    訂閱K線推送

    提示

    註意如果字段confirm為true, 則表明這是這根K線的最後一個tick;否則,這只是一個快照數據,即中間價格

    可用時間粒度:

    • 1 3 5 15 30 (分鐘)
    • 60 120 240 360 720 (分鐘)
    • D (天)
    • W (週)
    • M (月)

    推送頻率: 1-60s

    Topic:
    kline.{interval}.{symbol} e.g., kline.30.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > startnumber開始時間戳 (毫秒)
    > endnumber結束時間戳 (毫秒)
    > intervalstringK線粒度
    > openstring開盤價
    > closestring收盤價
    > highstring最高價
    > lowstring最低價
    > volumestring交易量
    > turnoverstring交易額
    > confirmboolean是否確認
    > timestampnumber蠟燭中最後一筆淨值時間戳 (毫秒)

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.kline_stream(
    interval=5,
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "topic": "kline.5.BTCUSDT",
    "data": [
    {
    "start": 1672324800000,
    "end": 1672325099999,
    "interval": "5",
    "open": "16649.5",
    "close": "16677",
    "high": "16677",
    "low": "16608",
    "volume": "2.081",
    "turnover": "34666.4005",
    "confirm": false,
    "timestamp": 1672324988882
    }
    ],
    "ts": 1672324988882,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/liquidation.html b/zh-TW/v5/websocket/public/liquidation.html index 22a3f9cc6e..d1a861fcff 100644 --- a/zh-TW/v5/websocket/public/liquidation.html +++ b/zh-TW/v5/websocket/public/liquidation.html @@ -4,14 +4,14 @@ 強平推送 | Bybit API Documentation - +

    強平推送

    訂閱Bybit平台上的強平推送

    推送頻率: 實時

    Topic:
    liquidation.{symbol} e.g., liquidation.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > updatedTimenumber數據更新時間戳 (毫秒)
    > symbolstring合約名稱
    > sidestring被平的倉位方向. Buy,Sell
  • 如果您收到一條Buy的推送更新, 則表面有一個多倉被強平了
  • > sizestring成交數量
    > pricestring破產價格

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.liquidation_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "data": {
    "price": "0.03803",
    "side": "Buy",
    "size": "1637",
    "symbol": "GALAUSDT",
    "updatedTime": 1673251091822
    },
    "topic": "liquidation.GALAUSDT",
    "ts": 1673251091822,
    "type": "snapshot"
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/orderbook.html b/zh-TW/v5/websocket/public/orderbook.html index 3ad44842ed..41292f351f 100644 --- a/zh-TW/v5/websocket/public/orderbook.html +++ b/zh-TW/v5/websocket/public/orderbook.html @@ -4,7 +4,7 @@ 深度 | Bybit API Documentation - + @@ -20,7 +20,7 @@ 25 檔數據, 推送頻率: 20ms
    100 檔數據, 推送頻率: 100ms

    Topic:
    orderbook.{depth}.{symbol} e.g., orderbook.1.BTCUSDT

    響應參數

    參數類型說明
    topicstringTopic名
    typestring數據類型. snapshot,delta
    tsnumber行情服務生成數據的時間戳 (毫秒)
    datamapObject
    > sstring合約名稱
    > barrayBid, 買方. snapshot數據,是按照價格從大到小
    >> b[0]string買方報價
    >> b[1]string買方數量
  • 增量數據的推送當出現size=0時,這意味著該價位的報價單全部成交或者全部撤銷
  • > aarrayAsk, 賣方. snapshot數據,是按照價格從小到大
    >> a[0]string賣方報價
    >> a[1]string賣方數量
  • 增量數據的推送當出現size=0時,這意味著該價位的報價單全部成交或者全部撤銷
  • > uinteger更新id, 一般情況下該id是連續的。偶爾會因後台的重啟而發送"u"=1的全量數據,接收到後請覆蓋本地保存的orderbook
    > seqinteger撮合版本號
  • 該字段可以用於關聯不同檔位的orderbook, 如果值越小, 則說明數據生成越早
  • 訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.orderbook_stream(
    depth=50,
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "topic": "orderbook.50.BTCUSDT",
    "type": "snapshot",
    "ts": 1672304484978,
    "data": {
    "s": "BTCUSDT",
    "b": [
    ...,
    [
    "16493.50",
    "0.006"
    ],
    [
    "16493.00",
    "0.100"
    ]
    ],
    "a": [
    [
    "16611.00",
    "0.029"
    ],
    [
    "16612.00",
    "0.213"
    ],
    ...,
    ],
    "u": 18521288,
    "seq": 7961638724
    }
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/ticker.html b/zh-TW/v5/websocket/public/ticker.html index 40fab01a8d..b3c996a30e 100644 --- a/zh-TW/v5/websocket/public/ticker.html +++ b/zh-TW/v5/websocket/public/ticker.html @@ -4,14 +4,14 @@ 行情 | Bybit API Documentation - +

    行情

    訂閱行情數據推送.

    警告
    • 注意,該topic推送delta數據和snapshot数据。如果delta數據中缺失一些字段,表明該字段自上次推送以來沒有發生變化。
    • 現貨和期權只推送snapshot類型數據

    推送頻率: 期貨和期權 - 100ms, 現貨 - 實時

    Topic:
    tickers.{symbol}

    響應參數

    參數類型說明
    topicstringTopic名稱
    typestring數據類型. `snapshot`,`delta`
    csinteger撮合版本號
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject
    > symbolstring合約名稱
    > tickDirectionstring價格變化方向
    > price24hPcntstring市場價格相對24h前變化的百分比
    > lastPricestring最新市場成交價
    > prevPrice24hstring24小時前的整點市價
    > highPrice24hstring最近24小時的最高價
    > lowPrice24hstring最近24小時的最低價
    > prevPrice1hstring1小時前的整點市價
    > markPricestring標記價格
    > indexPricestring指數價格
    > openIntereststring未平倉合約的數量
    > openInterestValuestring未平倉合約的價值
    > turnover24hstring最近24小時成交額
    > volume24hstring最近24小時成交量
    > nextFundingTimestring下次結算資金費用的時間戳 (毫秒)
    > fundingRatestring資金費率
    > bid1Pricestring買1價
    > bid1Sizestring買1價的數量
    > ask1Pricestring賣1價
    > ask1Sizestring賣1價的數量
    > deliveryTimedatetime交割日期時間 (UTC+0). 反向交割和USDC交割獨有字段
    > basisRatestring基差率. 反向交割和USDC交割獨有字段
    > deliveryFeeRatestring交割費率. 反向交割和USDC交割獨有字段
    > predictedDeliveryPricestring預估交割價格. 反向交割和USDC交割獨有字段

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.ticker_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "topic": "tickers.BTCUSDT",
    "type": "snapshot",
    "data": {
    "symbol": "BTCUSDT",
    "tickDirection": "PlusTick",
    "price24hPcnt": "0.017103",
    "lastPrice": "17216.00",
    "prevPrice24h": "16926.50",
    "highPrice24h": "17281.50",
    "lowPrice24h": "16915.00",
    "prevPrice1h": "17238.00",
    "markPrice": "17217.33",
    "indexPrice": "17227.36",
    "openInterest": "68744.761",
    "openInterestValue": "1183601235.91",
    "turnover24h": "1570383121.943499",
    "volume24h": "91705.276",
    "nextFundingTime": "1673280000000",
    "fundingRate": "-0.000212",
    "bid1Price": "17215.50",
    "bid1Size": "84.489",
    "ask1Price": "17216.00",
    "ask1Size": "83.020"
    },
    "cs": 24987956059,
    "ts": 1673272861686
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/websocket/public/trade.html b/zh-TW/v5/websocket/public/trade.html index 0b1998d896..cea47e9416 100644 --- a/zh-TW/v5/websocket/public/trade.html +++ b/zh-TW/v5/websocket/public/trade.html @@ -4,7 +4,7 @@ 平台成交 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    平台成交

    訂閱Bybit平台上最近成交的推送.
    從用戶訂閱開始, 實時推送增量交易歷史, 有成交數據就推送.

    推送頻率: 實時

    Topic:
    publicTrade.{symbol} 注意: 期權使用baseCoin, e.g., publicTrade.BTC

    響應參數

    參數類型說明
    idstring消息 id. 期權沒有該字段
    topicstringTopic名
    typestring數據類型. snapshot
    tsnumber行情服務生成數據的時間戳 (毫秒)
    dataarrayObject. 如有多條, 則數組中的元素按照匹配時間升序排序
    > Tnumber成交時間戳 (毫秒)
    > sarray合約名稱
    > Sstring吃單方向. Buy,Sell
    > vstring成交數量
    > pstring成交價格
    > Lstring價格變化的方向. 期權沒有該字段
    > istring成交Id
    > BTboolean成交類型是否為大宗交易

    訂閱示例

    from pybit.unified_trading import WebSocket
    from time import sleep
    ws = WebSocket(
    testnet=True,
    channel_type="linear",
    )
    def handle_message(message):
    print(message)
    ws.trade_stream(
    symbol="BTCUSDT",
    callback=handle_message
    )
    while True:
    sleep(1)

    響應示例

    {
    "topic": "publicTrade.BTCUSDT",
    "type": "snapshot",
    "ts": 1672304486868,
    "data": [
    {
    "T": 1672304486865,
    "s": "BTCUSDT",
    "S": "Buy",
    "v": "0.001",
    "p": "16578.50",
    "L": "PlusTick",
    "i": "20f43950-d8dd-5b31-9112-a178eb6023af",
    "BT": false
    }
    ]
    }
    - + \ No newline at end of file diff --git a/zh-TW/v5/ws/connect.html b/zh-TW/v5/ws/connect.html index 6ad5b90eab..c6f98de33a 100644 --- a/zh-TW/v5/ws/connect.html +++ b/zh-TW/v5/ws/connect.html @@ -4,7 +4,7 @@ 訂閱WebSocket | Bybit API Documentation - + @@ -20,7 +20,7 @@ 期權: wss://stream-testnet.bybit.com/v5/public/option

    WebSocket私有頻道:

    • 主網:
      wss://stream.bybit.com/v5/private

    • 測試網:
      wss://stream-testnet.bybit.com/v5/private

    自定義私有連接存活時長

    針對私有連接, 您可以自定義連接存活時長, 通過增加參數max_alive_time, 最小支持30s (30秒), 最大支持600s (10分鐘). 如果您需要按分鐘級別配置, 您也可以傳遞1m, 2m等. 例如, wss://stream-testnet.bybit.com/v5/private?max_alive_time=1m.

    一般來說, 當客戶端與服務端沒有上下行數據, 包括心跳和交易數據下發, 那麼該連接會在最後一條交互後維持10分鐘, 由服務端斷開. 當您由特別的需求時, 可以通過該字段max_alive_time自行控制存活時間.

    由於系統每30秒掃描一次, 因此配置的時長可能無法非常精確, 換句話說, 如果您配置了45秒, 然後最後一條數據下發或者心跳發生在2023-08-15 17:27:23, 您的私有連接可能在2023-08-15 17:28:15發生斷連.

    鑒權

    信息
    公共頻道不需要鑒權,以下部分僅適用於私有頻道的訂閱。

    構建連接時,創建鑒權請求。

    注意: 如果您正在使用pybit, bybit-api或者其他第三方庫, 您可以忽略此項-因為鑒權已經內建。

    {
    "req_id": "10001", // 可選項
    "op": "auth",
    "args": [
    "api_key",
    1662350400000, //過期時間應當大於當前時間戳
    "singature"
    ]
    }
    # based on: https://github.com/bybit-exchange/pybit/blob/master/pybit/_http_manager.py

    import hmac
    import json
    import time
    import websocket

    api_key = ""
    api_secret = ""

    # Generate expires.
    expires = int((time.time() + 1) * 1000)

    # Generate signature.
    signature = str(hmac.new(
    bytes(api_secret, "utf-8"),
    bytes(f"GET/realtime{expires}", "utf-8"), digestmod="sha256"
    ).hexdigest())

    ws = websocket.WebSocketApp(
    url=url,
    ...
    )

    # Authenticate with API.
    ws.send(
    json.dumps({
    "op": "auth",
    "args": [api_key, expires, signature]
    })
    )

    鑒權成功的響應示例

    {
    "success": true,
    "ret_msg": "",
    "op": "auth",
    "conn_id": "cejreaspqfh3sjdnldmg-p"
    }
    備註

    簽名生成的示例可以參考這裡

    警告

    由於網絡的複雜性,您可能隨時遇到斷連。請參考以下建議確保您能即時接收到推送:

    1. 通過發送心跳來維持連接;
    2. 遇到斷連時,立即重新連接。

    IP限頻

    • 不要嘗試頻繁地構建連接與斷開連接;
    • 不要在5分鐘內構建超過500個連接。

    公有頻道訂閱參數限制

    不管是期貨、現貨、期權, 對於單個連接, args裡的數組元素長度總和不能超過21,000個字符

    • 現貨每次向單一連接僅能發送不超過10個參數的訂閱請求,但單個連接沒有args訂閱限制
    • 期權單個連接,至多訂閱2000個args
    • 期貨單個連接沒有args限制

    如何發送心跳

    // req_id is a customised id, which is optional
    ws.send(JSON.stringify({"req_id": "100001", "op": "ping"}));

    公共頻道接收到pong的響應示例

    {
    "success": true,
    "ret_msg": "pong",
    "conn_id": "0970e817-426e-429a-a679-ff7f55e0b16a",
    "op": "ping"
    }

    私有頻道接收到pong的響應示例

    {
    "req_id": "test",
    "op": "pong",
    "args": [
    "1675418560633"
    ],
    "conn_id": "cfcb4ocsvfriu23r3er0-1b"
    }
    警告

    為了維持連接,我們推薦您每20秒發送一次心跳。

    如何訂閱topic

    理解Websocket裡的args

    通過傳入args來訂閱指定topic

    // 訂閱1檔的orderbook
    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT"
    ]
    }

    通過逗號隔開,可以同時訂閱多個topic或者多個symbol

    {
    "req_id": "test", // 可選
    "op": "subscribe",
    "args": [
    "orderbook.1.BTCUSDT",
    "publicTrade.BTCUSDT",
    "orderbook.1.ETHUSDT"
    ]
    }

    理解如何取消訂閱

    您可以通過發送請求來動態地停止訂閱:

    {
    "op": "unsubscribe",
    "args": [
    "publicTrade.ETHUSD"
    ],
    "req_id": "customised_id"
    }

    理解訂閱的響應

    訂閱成功後的響應示例

    {
    "success": true,
    "ret_msg": "",
    "op": "subscribe",
    "conn_id": "cejreassvfrsfvb9v1a0-2m"
    }
    - + \ No newline at end of file diff --git a/zh-TW/zh-my/account_asset.html b/zh-TW/zh-my/account_asset.html index 5e4d0cf1c2..c24c19e368 100644 --- a/zh-TW/zh-my/account_asset.html +++ b/zh-TW/zh-my/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/account_asset/v1.html b/zh-TW/zh-my/account_asset/v1.html index 65dc304edb..d01979a36c 100644 --- a/zh-TW/zh-my/account_asset/v1.html +++ b/zh-TW/zh-my/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/account_asset/v3.html b/zh-TW/zh-my/account_asset/v3.html index f63fdecf00..fdd88398cc 100644 --- a/zh-TW/zh-my/account_asset/v3.html +++ b/zh-TW/zh-my/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/copy_trading.html b/zh-TW/zh-my/copy_trading.html index 760f1ad78c..81fd563f17 100644 --- a/zh-TW/zh-my/copy_trading.html +++ b/zh-TW/zh-my/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/derivativesV3/contract.html b/zh-TW/zh-my/derivativesV3/contract.html index 3457cfc37f..b4fe4e2447 100644 --- a/zh-TW/zh-my/derivativesV3/contract.html +++ b/zh-TW/zh-my/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/derivativesV3/unified_margin.html b/zh-TW/zh-my/derivativesV3/unified_margin.html index aa3d4f6cf4..bfdbb83d43 100644 --- a/zh-TW/zh-my/derivativesV3/unified_margin.html +++ b/zh-TW/zh-my/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/futuresV2/inverse.html b/zh-TW/zh-my/futuresV2/inverse.html index b53c3da7f9..848e2cae9d 100644 --- a/zh-TW/zh-my/futuresV2/inverse.html +++ b/zh-TW/zh-my/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/futuresV2/inverse_futures.html b/zh-TW/zh-my/futuresV2/inverse_futures.html index 8b282c4a21..323b7e2eeb 100644 --- a/zh-TW/zh-my/futuresV2/inverse_futures.html +++ b/zh-TW/zh-my/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/futuresV2/linear.html b/zh-TW/zh-my/futuresV2/linear.html index 5f843b6aff..69d7805606 100644 --- a/zh-TW/zh-my/futuresV2/linear.html +++ b/zh-TW/zh-my/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/inverse.html b/zh-TW/zh-my/inverse.html index 5d09ddb724..2150a0c3d5 100644 --- a/zh-TW/zh-my/inverse.html +++ b/zh-TW/zh-my/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/inverse_futures.html b/zh-TW/zh-my/inverse_futures.html index 4ac2944f60..d7d8ad9820 100644 --- a/zh-TW/zh-my/inverse_futures.html +++ b/zh-TW/zh-my/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/linear.html b/zh-TW/zh-my/linear.html index ee0c2ccb1b..5fabcb70de 100644 --- a/zh-TW/zh-my/linear.html +++ b/zh-TW/zh-my/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/spot.html b/zh-TW/zh-my/spot.html index 0677a75ee7..689e7dec11 100644 --- a/zh-TW/zh-my/spot.html +++ b/zh-TW/zh-my/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/spot/v1.html b/zh-TW/zh-my/spot/v1.html index adfe540418..deb532ddb5 100644 --- a/zh-TW/zh-my/spot/v1.html +++ b/zh-TW/zh-my/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/spot/v3.html b/zh-TW/zh-my/spot/v3.html index cf236a7270..a19ffcc593 100644 --- a/zh-TW/zh-my/spot/v3.html +++ b/zh-TW/zh-my/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/tax.html b/zh-TW/zh-my/tax.html index 60f8cebf44..ab95e9debb 100644 --- a/zh-TW/zh-my/tax.html +++ b/zh-TW/zh-my/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/account_asset/v1.html b/zh-TW/zh-my/testnet/account_asset/v1.html index 838be30550..9bf251dc71 100644 --- a/zh-TW/zh-my/testnet/account_asset/v1.html +++ b/zh-TW/zh-my/testnet/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/account_asset/v3.html b/zh-TW/zh-my/testnet/account_asset/v3.html index ce5371aef7..53f71147de 100644 --- a/zh-TW/zh-my/testnet/account_asset/v3.html +++ b/zh-TW/zh-my/testnet/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/copy_trading.html b/zh-TW/zh-my/testnet/copy_trading.html index 58baf6e9f4..1869b9eb7e 100644 --- a/zh-TW/zh-my/testnet/copy_trading.html +++ b/zh-TW/zh-my/testnet/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/futuresV2/inverse.html b/zh-TW/zh-my/testnet/futuresV2/inverse.html index f1aab05065..e8af86ceea 100644 --- a/zh-TW/zh-my/testnet/futuresV2/inverse.html +++ b/zh-TW/zh-my/testnet/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/futuresV2/inverse_futures.html b/zh-TW/zh-my/testnet/futuresV2/inverse_futures.html index 7e8765d690..1fa19f0d1e 100644 --- a/zh-TW/zh-my/testnet/futuresV2/inverse_futures.html +++ b/zh-TW/zh-my/testnet/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/futuresV2/linear.html b/zh-TW/zh-my/testnet/futuresV2/linear.html index 4208e2d6ff..2a6a2138e9 100644 --- a/zh-TW/zh-my/testnet/futuresV2/linear.html +++ b/zh-TW/zh-my/testnet/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/inverse.html b/zh-TW/zh-my/testnet/inverse.html index b4a21184aa..ca925c7b59 100644 --- a/zh-TW/zh-my/testnet/inverse.html +++ b/zh-TW/zh-my/testnet/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/inverse_futures.html b/zh-TW/zh-my/testnet/inverse_futures.html index 8daedf5707..07c1b21079 100644 --- a/zh-TW/zh-my/testnet/inverse_futures.html +++ b/zh-TW/zh-my/testnet/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/linear.html b/zh-TW/zh-my/testnet/linear.html index feab2993fb..5f80341994 100644 --- a/zh-TW/zh-my/testnet/linear.html +++ b/zh-TW/zh-my/testnet/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/spot.html b/zh-TW/zh-my/testnet/spot.html index 26f20db2cf..d3dec906d8 100644 --- a/zh-TW/zh-my/testnet/spot.html +++ b/zh-TW/zh-my/testnet/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/spot/v1.html b/zh-TW/zh-my/testnet/spot/v1.html index 4daf468329..9a2fab7df4 100644 --- a/zh-TW/zh-my/testnet/spot/v1.html +++ b/zh-TW/zh-my/testnet/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/spot/v3.html b/zh-TW/zh-my/testnet/spot/v3.html index da3b9027d0..463b12d021 100644 --- a/zh-TW/zh-my/testnet/spot/v3.html +++ b/zh-TW/zh-my/testnet/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/usdc/option.html b/zh-TW/zh-my/testnet/usdc/option.html index a502fe0688..c07eaee966 100644 --- a/zh-TW/zh-my/testnet/usdc/option.html +++ b/zh-TW/zh-my/testnet/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/testnet/usdc/perpetual.html b/zh-TW/zh-my/testnet/usdc/perpetual.html index 4d24e2ef6c..04556d2757 100644 --- a/zh-TW/zh-my/testnet/usdc/perpetual.html +++ b/zh-TW/zh-my/testnet/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/usdc/option.html b/zh-TW/zh-my/usdc/option.html index d5f24f3206..fc852cf041 100644 --- a/zh-TW/zh-my/usdc/option.html +++ b/zh-TW/zh-my/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-TW/zh-my/usdc/perpetual.html b/zh-TW/zh-my/usdc/perpetual.html index ccccbb1393..248a4d0c72 100644 --- a/zh-TW/zh-my/usdc/perpetual.html +++ b/zh-TW/zh-my/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/account_asset.html b/zh-my/account_asset.html index e909e88766..ccc115e2cb 100644 --- a/zh-my/account_asset.html +++ b/zh-my/account_asset.html @@ -4,7 +4,7 @@ account_asset | Bybit API Documentation - + @@ -12,7 +12,7 @@

    account_asset

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/account_asset/v1.html b/zh-my/account_asset/v1.html index 4646368e19..51494a4330 100644 --- a/zh-my/account_asset/v1.html +++ b/zh-my/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/account_asset/v3.html b/zh-my/account_asset/v3.html index 579d448fa3..0315cd2dc7 100644 --- a/zh-my/account_asset/v3.html +++ b/zh-my/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/copy_trading.html b/zh-my/copy_trading.html index ec346ededb..222b46d115 100644 --- a/zh-my/copy_trading.html +++ b/zh-my/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/derivativesV3/contract.html b/zh-my/derivativesV3/contract.html index de6f43ddc8..276c878c40 100644 --- a/zh-my/derivativesV3/contract.html +++ b/zh-my/derivativesV3/contract.html @@ -4,7 +4,7 @@ contract | Bybit API Documentation - + @@ -12,7 +12,7 @@

    contract

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/derivativesV3/unified_margin.html b/zh-my/derivativesV3/unified_margin.html index 93d62b91ca..87ecb6fd02 100644 --- a/zh-my/derivativesV3/unified_margin.html +++ b/zh-my/derivativesV3/unified_margin.html @@ -4,7 +4,7 @@ unified_margin | Bybit API Documentation - + @@ -12,7 +12,7 @@

    unified_margin

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/futuresV2/inverse.html b/zh-my/futuresV2/inverse.html index f47a14326d..e7a6518eee 100644 --- a/zh-my/futuresV2/inverse.html +++ b/zh-my/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/futuresV2/inverse_futures.html b/zh-my/futuresV2/inverse_futures.html index e10afa36db..ebe6725121 100644 --- a/zh-my/futuresV2/inverse_futures.html +++ b/zh-my/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/futuresV2/linear.html b/zh-my/futuresV2/linear.html index 3f4c6d50da..de3f6fe62f 100644 --- a/zh-my/futuresV2/linear.html +++ b/zh-my/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/inverse.html b/zh-my/inverse.html index be3b1bba82..aae0e6a428 100644 --- a/zh-my/inverse.html +++ b/zh-my/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/inverse_futures.html b/zh-my/inverse_futures.html index 8e4934d03c..df76b37d07 100644 --- a/zh-my/inverse_futures.html +++ b/zh-my/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/linear.html b/zh-my/linear.html index d753795220..148046f107 100644 --- a/zh-my/linear.html +++ b/zh-my/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/spot.html b/zh-my/spot.html index d6db3e7bb4..3e4cf95a0c 100644 --- a/zh-my/spot.html +++ b/zh-my/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/spot/v1.html b/zh-my/spot/v1.html index aafc63ec81..da967d6019 100644 --- a/zh-my/spot/v1.html +++ b/zh-my/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/spot/v3.html b/zh-my/spot/v3.html index 86b4e41ae7..e96146ff0c 100644 --- a/zh-my/spot/v3.html +++ b/zh-my/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/tax.html b/zh-my/tax.html index 22d475c1d9..e68a49f9c1 100644 --- a/zh-my/tax.html +++ b/zh-my/tax.html @@ -4,7 +4,7 @@ tax | Bybit API Documentation - + @@ -12,7 +12,7 @@

    tax

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/account_asset/v1.html b/zh-my/testnet/account_asset/v1.html index a5945edabe..219fb07e47 100644 --- a/zh-my/testnet/account_asset/v1.html +++ b/zh-my/testnet/account_asset/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/account_asset/v3.html b/zh-my/testnet/account_asset/v3.html index 584dc97909..d3e76d8a6c 100644 --- a/zh-my/testnet/account_asset/v3.html +++ b/zh-my/testnet/account_asset/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/copy_trading.html b/zh-my/testnet/copy_trading.html index 2e6f12bcb5..132c5614a4 100644 --- a/zh-my/testnet/copy_trading.html +++ b/zh-my/testnet/copy_trading.html @@ -4,7 +4,7 @@ copy_trading | Bybit API Documentation - + @@ -12,7 +12,7 @@

    copy_trading

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/futuresV2/inverse.html b/zh-my/testnet/futuresV2/inverse.html index a2975a3e6e..500ffeead1 100644 --- a/zh-my/testnet/futuresV2/inverse.html +++ b/zh-my/testnet/futuresV2/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/futuresV2/inverse_futures.html b/zh-my/testnet/futuresV2/inverse_futures.html index 5e97aae412..c4090db5ae 100644 --- a/zh-my/testnet/futuresV2/inverse_futures.html +++ b/zh-my/testnet/futuresV2/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/futuresV2/linear.html b/zh-my/testnet/futuresV2/linear.html index 54ad38ac9a..011c1d6080 100644 --- a/zh-my/testnet/futuresV2/linear.html +++ b/zh-my/testnet/futuresV2/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/inverse.html b/zh-my/testnet/inverse.html index 6dfbcd33ab..5d57ca7f74 100644 --- a/zh-my/testnet/inverse.html +++ b/zh-my/testnet/inverse.html @@ -4,7 +4,7 @@ inverse | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/inverse_futures.html b/zh-my/testnet/inverse_futures.html index d1018d7888..119e469257 100644 --- a/zh-my/testnet/inverse_futures.html +++ b/zh-my/testnet/inverse_futures.html @@ -4,7 +4,7 @@ inverse_futures | Bybit API Documentation - + @@ -12,7 +12,7 @@

    inverse_futures

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/linear.html b/zh-my/testnet/linear.html index 0d7605db7d..70e15d50b4 100644 --- a/zh-my/testnet/linear.html +++ b/zh-my/testnet/linear.html @@ -4,7 +4,7 @@ linear | Bybit API Documentation - + @@ -12,7 +12,7 @@

    linear

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/spot.html b/zh-my/testnet/spot.html index 296575c3d2..e5ae06c53e 100644 --- a/zh-my/testnet/spot.html +++ b/zh-my/testnet/spot.html @@ -4,7 +4,7 @@ spot | Bybit API Documentation - + @@ -12,7 +12,7 @@

    spot

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/spot/v1.html b/zh-my/testnet/spot/v1.html index 91810efc46..f83e32a0d0 100644 --- a/zh-my/testnet/spot/v1.html +++ b/zh-my/testnet/spot/v1.html @@ -4,7 +4,7 @@ v1 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v1

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/spot/v3.html b/zh-my/testnet/spot/v3.html index 6310a35656..4f60d1e787 100644 --- a/zh-my/testnet/spot/v3.html +++ b/zh-my/testnet/spot/v3.html @@ -4,7 +4,7 @@ v3 | Bybit API Documentation - + @@ -12,7 +12,7 @@

    v3

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/usdc/option.html b/zh-my/testnet/usdc/option.html index 549b6cc3e1..f5bb7003b8 100644 --- a/zh-my/testnet/usdc/option.html +++ b/zh-my/testnet/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/testnet/usdc/perpetual.html b/zh-my/testnet/usdc/perpetual.html index 1b0c1c6499..6fc042999b 100644 --- a/zh-my/testnet/usdc/perpetual.html +++ b/zh-my/testnet/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/usdc/option.html b/zh-my/usdc/option.html index c7ffb281de..e04f0ab46f 100644 --- a/zh-my/usdc/option.html +++ b/zh-my/usdc/option.html @@ -4,7 +4,7 @@ option | Bybit API Documentation - + @@ -12,7 +12,7 @@

    option

    const Home = () => { return ; };

    - + \ No newline at end of file diff --git a/zh-my/usdc/perpetual.html b/zh-my/usdc/perpetual.html index 428051a759..92db4b1400 100644 --- a/zh-my/usdc/perpetual.html +++ b/zh-my/usdc/perpetual.html @@ -4,7 +4,7 @@ perpetual | Bybit API Documentation - + @@ -12,7 +12,7 @@

    perpetual

    const Home = () => { return ; };

    - + \ No newline at end of file