bybit

package
v0.2.47 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 15, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HostPublic  = "public"
	HostPrivate = "private"
)
View Source
const (
	MethodPublicGetSpotV3PublicSymbols                                 = "publicGetSpotV3PublicSymbols"
	MethodPublicGetSpotV3PublicQuoteDepth                              = "publicGetSpotV3PublicQuoteDepth"
	MethodPublicGetSpotV3PublicQuoteDepthMerged                        = "publicGetSpotV3PublicQuoteDepthMerged"
	MethodPublicGetSpotV3PublicQuoteTrades                             = "publicGetSpotV3PublicQuoteTrades"
	MethodPublicGetSpotV3PublicQuoteKline                              = "publicGetSpotV3PublicQuoteKline"
	MethodPublicGetSpotV3PublicQuoteTicker24hr                         = "publicGetSpotV3PublicQuoteTicker24hr"
	MethodPublicGetSpotV3PublicQuoteTickerPrice                        = "publicGetSpotV3PublicQuoteTickerPrice"
	MethodPublicGetSpotV3PublicQuoteTickerBookTicker                   = "publicGetSpotV3PublicQuoteTickerBookTicker"
	MethodPublicGetSpotV3PublicServerTime                              = "publicGetSpotV3PublicServerTime"
	MethodPublicGetSpotV3PublicInfos                                   = "publicGetSpotV3PublicInfos"
	MethodPublicGetSpotV3PublicMarginProductInfos                      = "publicGetSpotV3PublicMarginProductInfos"
	MethodPublicGetSpotV3PublicMarginEnsureTokens                      = "publicGetSpotV3PublicMarginEnsureTokens"
	MethodPublicGetV3PublicTime                                        = "publicGetV3PublicTime"
	MethodPublicGetContractV3PublicCopytradingSymbolList               = "publicGetContractV3PublicCopytradingSymbolList"
	MethodPublicGetDerivativesV3PublicOrderBookL2                      = "publicGetDerivativesV3PublicOrderBookL2"
	MethodPublicGetDerivativesV3PublicKline                            = "publicGetDerivativesV3PublicKline"
	MethodPublicGetDerivativesV3PublicTickers                          = "publicGetDerivativesV3PublicTickers"
	MethodPublicGetDerivativesV3PublicInstrumentsInfo                  = "publicGetDerivativesV3PublicInstrumentsInfo"
	MethodPublicGetDerivativesV3PublicMarkPriceKline                   = "publicGetDerivativesV3PublicMarkPriceKline"
	MethodPublicGetDerivativesV3PublicIndexPriceKline                  = "publicGetDerivativesV3PublicIndexPriceKline"
	MethodPublicGetDerivativesV3PublicFundingHistoryFundingRate        = "publicGetDerivativesV3PublicFundingHistoryFundingRate"
	MethodPublicGetDerivativesV3PublicRiskLimitList                    = "publicGetDerivativesV3PublicRiskLimitList"
	MethodPublicGetDerivativesV3PublicDeliveryPrice                    = "publicGetDerivativesV3PublicDeliveryPrice"
	MethodPublicGetDerivativesV3PublicRecentTrade                      = "publicGetDerivativesV3PublicRecentTrade"
	MethodPublicGetDerivativesV3PublicOpenInterest                     = "publicGetDerivativesV3PublicOpenInterest"
	MethodPublicGetDerivativesV3PublicInsurance                        = "publicGetDerivativesV3PublicInsurance"
	MethodPublicGetV5AnnouncementsIndex                                = "publicGetV5AnnouncementsIndex"
	MethodPublicGetV5MarketTime                                        = "publicGetV5MarketTime"
	MethodPublicGetV5MarketKline                                       = "publicGetV5MarketKline"
	MethodPublicGetV5MarketMarkPriceKline                              = "publicGetV5MarketMarkPriceKline"
	MethodPublicGetV5MarketIndexPriceKline                             = "publicGetV5MarketIndexPriceKline"
	MethodPublicGetV5MarketPremiumIndexPriceKline                      = "publicGetV5MarketPremiumIndexPriceKline"
	MethodPublicGetV5MarketInstrumentsInfo                             = "publicGetV5MarketInstrumentsInfo"
	MethodPublicGetV5MarketOrderbook                                   = "publicGetV5MarketOrderbook"
	MethodPublicGetV5MarketTickers                                     = "publicGetV5MarketTickers"
	MethodPublicGetV5MarketFundingHistory                              = "publicGetV5MarketFundingHistory"
	MethodPublicGetV5MarketRecentTrade                                 = "publicGetV5MarketRecentTrade"
	MethodPublicGetV5MarketOpenInterest                                = "publicGetV5MarketOpenInterest"
	MethodPublicGetV5MarketHistoricalVolatility                        = "publicGetV5MarketHistoricalVolatility"
	MethodPublicGetV5MarketInsurance                                   = "publicGetV5MarketInsurance"
	MethodPublicGetV5MarketRiskLimit                                   = "publicGetV5MarketRiskLimit"
	MethodPublicGetV5MarketDeliveryPrice                               = "publicGetV5MarketDeliveryPrice"
	MethodPublicGetV5MarketAccountRatio                                = "publicGetV5MarketAccountRatio"
	MethodPublicGetV5SpotLeverTokenInfo                                = "publicGetV5SpotLeverTokenInfo"
	MethodPublicGetV5SpotLeverTokenReference                           = "publicGetV5SpotLeverTokenReference"
	MethodPublicGetV5SpotMarginTradeData                               = "publicGetV5SpotMarginTradeData"
	MethodPublicGetV5SpotCrossMarginTradeData                          = "publicGetV5SpotCrossMarginTradeData"
	MethodPublicGetV5SpotCrossMarginTradePledgeToken                   = "publicGetV5SpotCrossMarginTradePledgeToken"
	MethodPublicGetV5SpotCrossMarginTradeBorrowToken                   = "publicGetV5SpotCrossMarginTradeBorrowToken"
	MethodPublicGetV5InsLoanProductInfos                               = "publicGetV5InsLoanProductInfos"
	MethodPublicGetV5InsLoanEnsureTokensConvert                        = "publicGetV5InsLoanEnsureTokensConvert"
	MethodPrivateGetV5MarketInstrumentsInfo                            = "privateGetV5MarketInstrumentsInfo"
	MethodPrivateGetV2PrivateWalletFundRecords                         = "privateGetV2PrivateWalletFundRecords"
	MethodPrivateGetSpotV3PrivateOrder                                 = "privateGetSpotV3PrivateOrder"
	MethodPrivateGetSpotV3PrivateOpenOrders                            = "privateGetSpotV3PrivateOpenOrders"
	MethodPrivateGetSpotV3PrivateHistoryOrders                         = "privateGetSpotV3PrivateHistoryOrders"
	MethodPrivateGetSpotV3PrivateMyTrades                              = "privateGetSpotV3PrivateMyTrades"
	MethodPrivateGetSpotV3PrivateAccount                               = "privateGetSpotV3PrivateAccount"
	MethodPrivateGetSpotV3PrivateReference                             = "privateGetSpotV3PrivateReference"
	MethodPrivateGetSpotV3PrivateRecord                                = "privateGetSpotV3PrivateRecord"
	MethodPrivateGetSpotV3PrivateCrossMarginOrders                     = "privateGetSpotV3PrivateCrossMarginOrders"
	MethodPrivateGetSpotV3PrivateCrossMarginAccount                    = "privateGetSpotV3PrivateCrossMarginAccount"
	MethodPrivateGetSpotV3PrivateCrossMarginLoanInfo                   = "privateGetSpotV3PrivateCrossMarginLoanInfo"
	MethodPrivateGetSpotV3PrivateCrossMarginRepayHistory               = "privateGetSpotV3PrivateCrossMarginRepayHistory"
	MethodPrivateGetSpotV3PrivateMarginLoanInfos                       = "privateGetSpotV3PrivateMarginLoanInfos"
	MethodPrivateGetSpotV3PrivateMarginRepaidInfos                     = "privateGetSpotV3PrivateMarginRepaidInfos"
	MethodPrivateGetSpotV3PrivateMarginLtv                             = "privateGetSpotV3PrivateMarginLtv"
	MethodPrivateGetAssetV3PrivateTransferInterTransferListQuery       = "privateGetAssetV3PrivateTransferInterTransferListQuery"
	MethodPrivateGetAssetV3PrivateTransferSubMemberListQuery           = "privateGetAssetV3PrivateTransferSubMemberListQuery"
	MethodPrivateGetAssetV3PrivateTransferSubMemberTransferListQuery   = "privateGetAssetV3PrivateTransferSubMemberTransferListQuery"
	MethodPrivateGetAssetV3PrivateTransferUniversalTransferListQuery   = "privateGetAssetV3PrivateTransferUniversalTransferListQuery"
	MethodPrivateGetAssetV3PrivateCoinInfoQuery                        = "privateGetAssetV3PrivateCoinInfoQuery"
	MethodPrivateGetAssetV3PrivateDepositAddressQuery                  = "privateGetAssetV3PrivateDepositAddressQuery"
	MethodPrivateGetContractV3PrivateCopytradingOrderList              = "privateGetContractV3PrivateCopytradingOrderList"
	MethodPrivateGetContractV3PrivateCopytradingPositionList           = "privateGetContractV3PrivateCopytradingPositionList"
	MethodPrivateGetContractV3PrivateCopytradingWalletBalance          = "privateGetContractV3PrivateCopytradingWalletBalance"
	MethodPrivateGetContractV3PrivatePositionLimitInfo                 = "privateGetContractV3PrivatePositionLimitInfo"
	MethodPrivateGetContractV3PrivateOrderUnfilledOrders               = "privateGetContractV3PrivateOrderUnfilledOrders"
	MethodPrivateGetContractV3PrivateOrderList                         = "privateGetContractV3PrivateOrderList"
	MethodPrivateGetContractV3PrivatePositionList                      = "privateGetContractV3PrivatePositionList"
	MethodPrivateGetContractV3PrivateExecutionList                     = "privateGetContractV3PrivateExecutionList"
	MethodPrivateGetContractV3PrivatePositionClosedPnl                 = "privateGetContractV3PrivatePositionClosedPnl"
	MethodPrivateGetContractV3PrivateAccountWalletBalance              = "privateGetContractV3PrivateAccountWalletBalance"
	MethodPrivateGetContractV3PrivateAccountFeeRate                    = "privateGetContractV3PrivateAccountFeeRate"
	MethodPrivateGetContractV3PrivateAccountWalletFundRecords          = "privateGetContractV3PrivateAccountWalletFundRecords"
	MethodPrivateGetUnifiedV3PrivateOrderUnfilledOrders                = "privateGetUnifiedV3PrivateOrderUnfilledOrders"
	MethodPrivateGetUnifiedV3PrivateOrderList                          = "privateGetUnifiedV3PrivateOrderList"
	MethodPrivateGetUnifiedV3PrivatePositionList                       = "privateGetUnifiedV3PrivatePositionList"
	MethodPrivateGetUnifiedV3PrivateExecutionList                      = "privateGetUnifiedV3PrivateExecutionList"
	MethodPrivateGetUnifiedV3PrivateDeliveryRecord                     = "privateGetUnifiedV3PrivateDeliveryRecord"
	MethodPrivateGetUnifiedV3PrivateSettlementRecord                   = "privateGetUnifiedV3PrivateSettlementRecord"
	MethodPrivateGetUnifiedV3PrivateAccountWalletBalance               = "privateGetUnifiedV3PrivateAccountWalletBalance"
	MethodPrivateGetUnifiedV3PrivateAccountTransactionLog              = "privateGetUnifiedV3PrivateAccountTransactionLog"
	MethodPrivateGetUnifiedV3PrivateAccountBorrowHistory               = "privateGetUnifiedV3PrivateAccountBorrowHistory"
	MethodPrivateGetUnifiedV3PrivateAccountBorrowRate                  = "privateGetUnifiedV3PrivateAccountBorrowRate"
	MethodPrivateGetUnifiedV3PrivateAccountInfo                        = "privateGetUnifiedV3PrivateAccountInfo"
	MethodPrivateGetUserV3PrivateFrozenSubMember                       = "privateGetUserV3PrivateFrozenSubMember"
	MethodPrivateGetUserV3PrivateQuerySubMembers                       = "privateGetUserV3PrivateQuerySubMembers"
	MethodPrivateGetUserV3PrivateQueryApi                              = "privateGetUserV3PrivateQueryApi"
	MethodPrivateGetUserV3PrivateGetMemberType                         = "privateGetUserV3PrivateGetMemberType"
	MethodPrivateGetAssetV3PrivateTransferTransferCoinListQuery        = "privateGetAssetV3PrivateTransferTransferCoinListQuery"
	MethodPrivateGetAssetV3PrivateTransferAccountCoinBalanceQuery      = "privateGetAssetV3PrivateTransferAccountCoinBalanceQuery"
	MethodPrivateGetAssetV3PrivateTransferAccountCoinsBalanceQuery     = "privateGetAssetV3PrivateTransferAccountCoinsBalanceQuery"
	MethodPrivateGetAssetV3PrivateTransferAssetInfoQuery               = "privateGetAssetV3PrivateTransferAssetInfoQuery"
	MethodPrivateGetAssetV3PublicDepositAllowedDepositListQuery        = "privateGetAssetV3PublicDepositAllowedDepositListQuery"
	MethodPrivateGetAssetV3PrivateDepositRecordQuery                   = "privateGetAssetV3PrivateDepositRecordQuery"
	MethodPrivateGetAssetV3PrivateWithdrawRecordQuery                  = "privateGetAssetV3PrivateWithdrawRecordQuery"
	MethodPrivateGetV5OrderRealtime                                    = "privateGetV5OrderRealtime"
	MethodPrivateGetV5OrderHistory                                     = "privateGetV5OrderHistory"
	MethodPrivateGetV5OrderSpotBorrowCheck                             = "privateGetV5OrderSpotBorrowCheck"
	MethodPrivateGetV5PositionList                                     = "privateGetV5PositionList"
	MethodPrivateGetV5ExecutionList                                    = "privateGetV5ExecutionList"
	MethodPrivateGetV5PositionClosedPnl                                = "privateGetV5PositionClosedPnl"
	MethodPrivateGetV5PositionMoveHistory                              = "privateGetV5PositionMoveHistory"
	MethodPrivateGetV5PreUpgradeOrderHistory                           = "privateGetV5PreUpgradeOrderHistory"
	MethodPrivateGetV5PreUpgradeExecutionList                          = "privateGetV5PreUpgradeExecutionList"
	MethodPrivateGetV5PreUpgradePositionClosedPnl                      = "privateGetV5PreUpgradePositionClosedPnl"
	MethodPrivateGetV5PreUpgradeAccountTransactionLog                  = "privateGetV5PreUpgradeAccountTransactionLog"
	MethodPrivateGetV5PreUpgradeAssetDeliveryRecord                    = "privateGetV5PreUpgradeAssetDeliveryRecord"
	MethodPrivateGetV5PreUpgradeAssetSettlementRecord                  = "privateGetV5PreUpgradeAssetSettlementRecord"
	MethodPrivateGetV5AccountWalletBalance                             = "privateGetV5AccountWalletBalance"
	MethodPrivateGetV5AccountBorrowHistory                             = "privateGetV5AccountBorrowHistory"
	MethodPrivateGetV5AccountCollateralInfo                            = "privateGetV5AccountCollateralInfo"
	MethodPrivateGetV5AssetCoinGreeks                                  = "privateGetV5AssetCoinGreeks"
	MethodPrivateGetV5AccountFeeRate                                   = "privateGetV5AccountFeeRate"
	MethodPrivateGetV5AccountInfo                                      = "privateGetV5AccountInfo"
	MethodPrivateGetV5AccountTransactionLog                            = "privateGetV5AccountTransactionLog"
	MethodPrivateGetV5AccountContractTransactionLog                    = "privateGetV5AccountContractTransactionLog"
	MethodPrivateGetV5AccountSmpGroup                                  = "privateGetV5AccountSmpGroup"
	MethodPrivateGetV5AccountMmpState                                  = "privateGetV5AccountMmpState"
	MethodPrivateGetV5AssetExchangeQueryCoinList                       = "privateGetV5AssetExchangeQueryCoinList"
	MethodPrivateGetV5AssetExchangeConvertResultQuery                  = "privateGetV5AssetExchangeConvertResultQuery"
	MethodPrivateGetV5AssetExchangeQueryConvertHistory                 = "privateGetV5AssetExchangeQueryConvertHistory"
	MethodPrivateGetV5AssetExchangeOrderRecord                         = "privateGetV5AssetExchangeOrderRecord"
	MethodPrivateGetV5AssetDeliveryRecord                              = "privateGetV5AssetDeliveryRecord"
	MethodPrivateGetV5AssetSettlementRecord                            = "privateGetV5AssetSettlementRecord"
	MethodPrivateGetV5AssetTransferQueryAssetInfo                      = "privateGetV5AssetTransferQueryAssetInfo"
	MethodPrivateGetV5AssetTransferQueryAccountCoinsBalance            = "privateGetV5AssetTransferQueryAccountCoinsBalance"
	MethodPrivateGetV5AssetTransferQueryAccountCoinBalance             = "privateGetV5AssetTransferQueryAccountCoinBalance"
	MethodPrivateGetV5AssetTransferQueryTransferCoinList               = "privateGetV5AssetTransferQueryTransferCoinList"
	MethodPrivateGetV5AssetTransferQueryInterTransferList              = "privateGetV5AssetTransferQueryInterTransferList"
	MethodPrivateGetV5AssetTransferQuerySubMemberList                  = "privateGetV5AssetTransferQuerySubMemberList"
	MethodPrivateGetV5AssetTransferQueryUniversalTransferList          = "privateGetV5AssetTransferQueryUniversalTransferList"
	MethodPrivateGetV5AssetDepositQueryAllowedList                     = "privateGetV5AssetDepositQueryAllowedList"
	MethodPrivateGetV5AssetDepositQueryRecord                          = "privateGetV5AssetDepositQueryRecord"
	MethodPrivateGetV5AssetDepositQuerySubMemberRecord                 = "privateGetV5AssetDepositQuerySubMemberRecord"
	MethodPrivateGetV5AssetDepositQueryInternalRecord                  = "privateGetV5AssetDepositQueryInternalRecord"
	MethodPrivateGetV5AssetDepositQueryAddress                         = "privateGetV5AssetDepositQueryAddress"
	MethodPrivateGetV5AssetDepositQuerySubMemberAddress                = "privateGetV5AssetDepositQuerySubMemberAddress"
	MethodPrivateGetV5AssetCoinQueryInfo                               = "privateGetV5AssetCoinQueryInfo"
	MethodPrivateGetV5AssetWithdrawQueryRecord                         = "privateGetV5AssetWithdrawQueryRecord"
	MethodPrivateGetV5AssetWithdrawWithdrawableAmount                  = "privateGetV5AssetWithdrawWithdrawableAmount"
	MethodPrivateGetV5AssetWithdrawVaspList                            = "privateGetV5AssetWithdrawVaspList"
	MethodPrivateGetV5UserQuerySubMembers                              = "privateGetV5UserQuerySubMembers"
	MethodPrivateGetV5UserQueryApi                                     = "privateGetV5UserQueryApi"
	MethodPrivateGetV5UserSubApikeys                                   = "privateGetV5UserSubApikeys"
	MethodPrivateGetV5UserGetMemberType                                = "privateGetV5UserGetMemberType"
	MethodPrivateGetV5UserAffCustomerInfo                              = "privateGetV5UserAffCustomerInfo"
	MethodPrivateGetV5UserDelSubmember                                 = "privateGetV5UserDelSubmember"
	MethodPrivateGetV5UserSubmembers                                   = "privateGetV5UserSubmembers"
	MethodPrivateGetV5SpotLeverTokenOrderRecord                        = "privateGetV5SpotLeverTokenOrderRecord"
	MethodPrivateGetV5SpotMarginTradeInterestRateHistory               = "privateGetV5SpotMarginTradeInterestRateHistory"
	MethodPrivateGetV5SpotMarginTradeState                             = "privateGetV5SpotMarginTradeState"
	MethodPrivateGetV5SpotCrossMarginTradeLoanInfo                     = "privateGetV5SpotCrossMarginTradeLoanInfo"
	MethodPrivateGetV5SpotCrossMarginTradeAccount                      = "privateGetV5SpotCrossMarginTradeAccount"
	MethodPrivateGetV5SpotCrossMarginTradeOrders                       = "privateGetV5SpotCrossMarginTradeOrders"
	MethodPrivateGetV5SpotCrossMarginTradeRepayHistory                 = "privateGetV5SpotCrossMarginTradeRepayHistory"
	MethodPrivateGetV5InsLoanProductInfos                              = "privateGetV5InsLoanProductInfos"
	MethodPrivateGetV5InsLoanEnsureTokensConvert                       = "privateGetV5InsLoanEnsureTokensConvert"
	MethodPrivateGetV5InsLoanLoanOrder                                 = "privateGetV5InsLoanLoanOrder"
	MethodPrivateGetV5InsLoanRepaidHistory                             = "privateGetV5InsLoanRepaidHistory"
	MethodPrivateGetV5InsLoanLtvConvert                                = "privateGetV5InsLoanLtvConvert"
	MethodPrivateGetV5LendingInfo                                      = "privateGetV5LendingInfo"
	MethodPrivateGetV5LendingHistoryOrder                              = "privateGetV5LendingHistoryOrder"
	MethodPrivateGetV5LendingAccount                                   = "privateGetV5LendingAccount"
	MethodPrivateGetV5BrokerEarningRecord                              = "privateGetV5BrokerEarningRecord"
	MethodPrivateGetV5BrokerEarningsInfo                               = "privateGetV5BrokerEarningsInfo"
	MethodPrivateGetV5BrokerAccountInfo                                = "privateGetV5BrokerAccountInfo"
	MethodPrivateGetV5BrokerAssetQuerySubMemberDepositRecord           = "privateGetV5BrokerAssetQuerySubMemberDepositRecord"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1PlaceOrder              = "privatePostOptionUsdcOpenapiPrivateV1PlaceOrder"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1ReplaceOrder            = "privatePostOptionUsdcOpenapiPrivateV1ReplaceOrder"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1CancelOrder             = "privatePostOptionUsdcOpenapiPrivateV1CancelOrder"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1CancelAll               = "privatePostOptionUsdcOpenapiPrivateV1CancelAll"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1QueryActiveOrders       = "privatePostOptionUsdcOpenapiPrivateV1QueryActiveOrders"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1QueryOrderHistory       = "privatePostOptionUsdcOpenapiPrivateV1QueryOrderHistory"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1ExecutionList           = "privatePostOptionUsdcOpenapiPrivateV1ExecutionList"
	MethodPrivatePostOptionUsdcOpenapiPrivateV1QueryPosition           = "privatePostOptionUsdcOpenapiPrivateV1QueryPosition"
	MethodPrivatePostPerpetualUsdcOpenapiPrivateV1PlaceOrder           = "privatePostPerpetualUsdcOpenapiPrivateV1PlaceOrder"
	MethodPrivatePostPerpetualUsdcOpenapiPrivateV1ReplaceOrder         = "privatePostPerpetualUsdcOpenapiPrivateV1ReplaceOrder"
	MethodPrivatePostPerpetualUsdcOpenapiPrivateV1CancelOrder          = "privatePostPerpetualUsdcOpenapiPrivateV1CancelOrder"
	MethodPrivatePostPerpetualUsdcOpenapiPrivateV1CancelAll            = "privatePostPerpetualUsdcOpenapiPrivateV1CancelAll"
	MethodPrivatePostPerpetualUsdcOpenapiPrivateV1PositionLeverageSave = "privatePostPerpetualUsdcOpenapiPrivateV1PositionLeverageSave"
	MethodPrivatePostSpotV3PrivateOrder                                = "privatePostSpotV3PrivateOrder"
	MethodPrivatePostSpotV3PrivateCancelOrder                          = "privatePostSpotV3PrivateCancelOrder"
	MethodPrivatePostSpotV3PrivateCancelOrders                         = "privatePostSpotV3PrivateCancelOrders"
	MethodPrivatePostSpotV3PrivateCancelOrdersByIds                    = "privatePostSpotV3PrivateCancelOrdersByIds"
	MethodPrivatePostSpotV3PrivatePurchase                             = "privatePostSpotV3PrivatePurchase"
	MethodPrivatePostSpotV3PrivateRedeem                               = "privatePostSpotV3PrivateRedeem"
	MethodPrivatePostSpotV3PrivateCrossMarginLoan                      = "privatePostSpotV3PrivateCrossMarginLoan"
	MethodPrivatePostSpotV3PrivateCrossMarginRepay                     = "privatePostSpotV3PrivateCrossMarginRepay"
	MethodPrivatePostAssetV3PrivateTransferInterTransfer               = "privatePostAssetV3PrivateTransferInterTransfer"
	MethodPrivatePostAssetV3PrivateWithdrawCreate                      = "privatePostAssetV3PrivateWithdrawCreate"
	MethodPrivatePostAssetV3PrivateWithdrawCancel                      = "privatePostAssetV3PrivateWithdrawCancel"
	MethodPrivatePostAssetV3PrivateTransferSubMemberTransfer           = "privatePostAssetV3PrivateTransferSubMemberTransfer"
	MethodPrivatePostAssetV3PrivateTransferTransferSubMemberSave       = "privatePostAssetV3PrivateTransferTransferSubMemberSave"
	MethodPrivatePostAssetV3PrivateTransferUniversalTransfer           = "privatePostAssetV3PrivateTransferUniversalTransfer"
	MethodPrivatePostUserV3PrivateCreateSubMember                      = "privatePostUserV3PrivateCreateSubMember"
	MethodPrivatePostUserV3PrivateCreateSubApi                         = "privatePostUserV3PrivateCreateSubApi"
	MethodPrivatePostUserV3PrivateUpdateApi                            = "privatePostUserV3PrivateUpdateApi"
	MethodPrivatePostUserV3PrivateDeleteApi                            = "privatePostUserV3PrivateDeleteApi"
	MethodPrivatePostUserV3PrivateUpdateSubApi                         = "privatePostUserV3PrivateUpdateSubApi"
	MethodPrivatePostUserV3PrivateDeleteSubApi                         = "privatePostUserV3PrivateDeleteSubApi"
	MethodPrivatePostContractV3PrivateCopytradingOrderCreate           = "privatePostContractV3PrivateCopytradingOrderCreate"
	MethodPrivatePostContractV3PrivateCopytradingOrderCancel           = "privatePostContractV3PrivateCopytradingOrderCancel"
	MethodPrivatePostContractV3PrivateCopytradingOrderClose            = "privatePostContractV3PrivateCopytradingOrderClose"
	MethodPrivatePostContractV3PrivateCopytradingPositionClose         = "privatePostContractV3PrivateCopytradingPositionClose"
	MethodPrivatePostContractV3PrivateCopytradingPositionSetLeverage   = "privatePostContractV3PrivateCopytradingPositionSetLeverage"
	MethodPrivatePostContractV3PrivateCopytradingWalletTransfer        = "privatePostContractV3PrivateCopytradingWalletTransfer"
	MethodPrivatePostContractV3PrivateCopytradingOrderTradingStop      = "privatePostContractV3PrivateCopytradingOrderTradingStop"
	MethodPrivatePostContractV3PrivateOrderCreate                      = "privatePostContractV3PrivateOrderCreate"
	MethodPrivatePostContractV3PrivateOrderCancel                      = "privatePostContractV3PrivateOrderCancel"
	MethodPrivatePostContractV3PrivateOrderCancelAll                   = "privatePostContractV3PrivateOrderCancelAll"
	MethodPrivatePostContractV3PrivateOrderReplace                     = "privatePostContractV3PrivateOrderReplace"
	MethodPrivatePostContractV3PrivatePositionSetAutoAddMargin         = "privatePostContractV3PrivatePositionSetAutoAddMargin"
	MethodPrivatePostContractV3PrivatePositionSwitchIsolated           = "privatePostContractV3PrivatePositionSwitchIsolated"
	MethodPrivatePostContractV3PrivatePositionSwitchMode               = "privatePostContractV3PrivatePositionSwitchMode"
	MethodPrivatePostContractV3PrivatePositionSwitchTpslMode           = "privatePostContractV3PrivatePositionSwitchTpslMode"
	MethodPrivatePostContractV3PrivatePositionSetLeverage              = "privatePostContractV3PrivatePositionSetLeverage"
	MethodPrivatePostContractV3PrivatePositionTradingStop              = "privatePostContractV3PrivatePositionTradingStop"
	MethodPrivatePostContractV3PrivatePositionSetRiskLimit             = "privatePostContractV3PrivatePositionSetRiskLimit"
	MethodPrivatePostContractV3PrivateAccountSetMarginMode             = "privatePostContractV3PrivateAccountSetMarginMode"
	MethodPrivatePostUnifiedV3PrivateOrderCreate                       = "privatePostUnifiedV3PrivateOrderCreate"
	MethodPrivatePostUnifiedV3PrivateOrderReplace                      = "privatePostUnifiedV3PrivateOrderReplace"
	MethodPrivatePostUnifiedV3PrivateOrderCancel                       = "privatePostUnifiedV3PrivateOrderCancel"
	MethodPrivatePostUnifiedV3PrivateOrderCreateBatch                  = "privatePostUnifiedV3PrivateOrderCreateBatch"
	MethodPrivatePostUnifiedV3PrivateOrderReplaceBatch                 = "privatePostUnifiedV3PrivateOrderReplaceBatch"
	MethodPrivatePostUnifiedV3PrivateOrderCancelBatch                  = "privatePostUnifiedV3PrivateOrderCancelBatch"
	MethodPrivatePostUnifiedV3PrivateOrderCancelAll                    = "privatePostUnifiedV3PrivateOrderCancelAll"
	MethodPrivatePostUnifiedV3PrivatePositionSetLeverage               = "privatePostUnifiedV3PrivatePositionSetLeverage"
	MethodPrivatePostUnifiedV3PrivatePositionTpslSwitchMode            = "privatePostUnifiedV3PrivatePositionTpslSwitchMode"
	MethodPrivatePostUnifiedV3PrivatePositionSetRiskLimit              = "privatePostUnifiedV3PrivatePositionSetRiskLimit"
	MethodPrivatePostUnifiedV3PrivatePositionTradingStop               = "privatePostUnifiedV3PrivatePositionTradingStop"
	MethodPrivatePostUnifiedV3PrivateAccountUpgradeUnifiedAccount      = "privatePostUnifiedV3PrivateAccountUpgradeUnifiedAccount"
	MethodPrivatePostUnifiedV3PrivateAccountSetMarginMode              = "privatePostUnifiedV3PrivateAccountSetMarginMode"
	MethodPrivatePostFhtComplianceTaxV3PrivateRegistertime             = "privatePostFhtComplianceTaxV3PrivateRegistertime"
	MethodPrivatePostFhtComplianceTaxV3PrivateCreate                   = "privatePostFhtComplianceTaxV3PrivateCreate"
	MethodPrivatePostFhtComplianceTaxV3PrivateStatus                   = "privatePostFhtComplianceTaxV3PrivateStatus"
	MethodPrivatePostFhtComplianceTaxV3PrivateUrl                      = "privatePostFhtComplianceTaxV3PrivateUrl"
	MethodPrivatePostV5OrderCreate                                     = "privatePostV5OrderCreate"
	MethodPrivatePostV5OrderAmend                                      = "privatePostV5OrderAmend"
	MethodPrivatePostV5OrderCancel                                     = "privatePostV5OrderCancel"
	MethodPrivatePostV5OrderCancelAll                                  = "privatePostV5OrderCancelAll"
	MethodPrivatePostV5OrderCreateBatch                                = "privatePostV5OrderCreateBatch"
	MethodPrivatePostV5OrderAmendBatch                                 = "privatePostV5OrderAmendBatch"
	MethodPrivatePostV5OrderCancelBatch                                = "privatePostV5OrderCancelBatch"
	MethodPrivatePostV5OrderDisconnectedCancelAll                      = "privatePostV5OrderDisconnectedCancelAll"
	MethodPrivatePostV5PositionSetLeverage                             = "privatePostV5PositionSetLeverage"
	MethodPrivatePostV5PositionSwitchIsolated                          = "privatePostV5PositionSwitchIsolated"
	MethodPrivatePostV5PositionSetTpslMode                             = "privatePostV5PositionSetTpslMode"
	MethodPrivatePostV5PositionSwitchMode                              = "privatePostV5PositionSwitchMode"
	MethodPrivatePostV5PositionSetRiskLimit                            = "privatePostV5PositionSetRiskLimit"
	MethodPrivatePostV5PositionTradingStop                             = "privatePostV5PositionTradingStop"
	MethodPrivatePostV5PositionSetAutoAddMargin                        = "privatePostV5PositionSetAutoAddMargin"
	MethodPrivatePostV5PositionAddMargin                               = "privatePostV5PositionAddMargin"
	MethodPrivatePostV5PositionMovePositions                           = "privatePostV5PositionMovePositions"
	MethodPrivatePostV5PositionConfirmPendingMmr                       = "privatePostV5PositionConfirmPendingMmr"
	MethodPrivatePostV5AccountUpgradeToUta                             = "privatePostV5AccountUpgradeToUta"
	MethodPrivatePostV5AccountQuickRepayment                           = "privatePostV5AccountQuickRepayment"
	MethodPrivatePostV5AccountSetMarginMode                            = "privatePostV5AccountSetMarginMode"
	MethodPrivatePostV5AccountSetHedgingMode                           = "privatePostV5AccountSetHedgingMode"
	MethodPrivatePostV5AccountMmpModify                                = "privatePostV5AccountMmpModify"
	MethodPrivatePostV5AccountMmpReset                                 = "privatePostV5AccountMmpReset"
	MethodPrivatePostV5AssetExchangeQuoteApply                         = "privatePostV5AssetExchangeQuoteApply"
	MethodPrivatePostV5AssetExchangeConvertExecute                     = "privatePostV5AssetExchangeConvertExecute"
	MethodPrivatePostV5AssetTransferInterTransfer                      = "privatePostV5AssetTransferInterTransfer"
	MethodPrivatePostV5AssetTransferSaveTransferSubMember              = "privatePostV5AssetTransferSaveTransferSubMember"
	MethodPrivatePostV5AssetTransferUniversalTransfer                  = "privatePostV5AssetTransferUniversalTransfer"
	MethodPrivatePostV5AssetDepositDepositToAccount                    = "privatePostV5AssetDepositDepositToAccount"
	MethodPrivatePostV5AssetWithdrawCreate                             = "privatePostV5AssetWithdrawCreate"
	MethodPrivatePostV5AssetWithdrawCancel                             = "privatePostV5AssetWithdrawCancel"
	MethodPrivatePostV5UserCreateSubMember                             = "privatePostV5UserCreateSubMember"
	MethodPrivatePostV5UserCreateSubApi                                = "privatePostV5UserCreateSubApi"
	MethodPrivatePostV5UserFrozenSubMember                             = "privatePostV5UserFrozenSubMember"
	MethodPrivatePostV5UserUpdateApi                                   = "privatePostV5UserUpdateApi"
	MethodPrivatePostV5UserUpdateSubApi                                = "privatePostV5UserUpdateSubApi"
	MethodPrivatePostV5UserDeleteApi                                   = "privatePostV5UserDeleteApi"
	MethodPrivatePostV5UserDeleteSubApi                                = "privatePostV5UserDeleteSubApi"
	MethodPrivatePostV5SpotLeverTokenPurchase                          = "privatePostV5SpotLeverTokenPurchase"
	MethodPrivatePostV5SpotLeverTokenRedeem                            = "privatePostV5SpotLeverTokenRedeem"
	MethodPrivatePostV5SpotMarginTradeSwitchMode                       = "privatePostV5SpotMarginTradeSwitchMode"
	MethodPrivatePostV5SpotMarginTradeSetLeverage                      = "privatePostV5SpotMarginTradeSetLeverage"
	MethodPrivatePostV5SpotCrossMarginTradeLoan                        = "privatePostV5SpotCrossMarginTradeLoan"
	MethodPrivatePostV5SpotCrossMarginTradeRepay                       = "privatePostV5SpotCrossMarginTradeRepay"
	MethodPrivatePostV5SpotCrossMarginTradeSwitch                      = "privatePostV5SpotCrossMarginTradeSwitch"
	MethodPrivatePostV5InsLoanAssociationUid                           = "privatePostV5InsLoanAssociationUid"
	MethodPrivatePostV5LendingPurchase                                 = "privatePostV5LendingPurchase"
	MethodPrivatePostV5LendingRedeem                                   = "privatePostV5LendingRedeem"
	MethodPrivatePostV5LendingRedeemCancel                             = "privatePostV5LendingRedeemCancel"
	MethodPrivatePostV5AccountSetCollateralSwitch                      = "privatePostV5AccountSetCollateralSwitch"
	MethodPrivatePostV5AccountSetCollateralSwitchBatch                 = "privatePostV5AccountSetCollateralSwitchBatch"
	MethodPrivatePostV5AccountDemoApplyMoney                           = "privatePostV5AccountDemoApplyMoney"
)
View Source
const (
	OptRecvWindow = "RecvWindow"
)

Variables

Functions

func NewExchange

func NewExchange(Options map[string]interface{}) (banexg.BanExchange, *errs.Error)

Types

type BaseMarket

type BaseMarket struct {
	Symbol    string `json:"symbol"`
	BaseCoin  string `json:"baseCoin"`
	QuoteCoin string `json:"quoteCoin"`
	Status    string `json:"status"`
}

func (*BaseMarket) ToStdMarket

func (m *BaseMarket) ToStdMarket(e *Bybit) *banexg.Market

type BaseTicker

type BaseTicker struct {
	Symbol       string `json:"symbol"`
	Bid1Price    string `json:"bid1Price"`
	Bid1Size     string `json:"bid1Size"`
	Ask1Price    string `json:"ask1Price"`
	Ask1Size     string `json:"ask1Size"`
	LastPrice    string `json:"lastPrice"`
	HighPrice24h string `json:"highPrice24h"`
	LowPrice24h  string `json:"lowPrice24h"`
	Turnover24h  string `json:"turnover24h"`
	Volume24h    string `json:"volume24h"`
}

func (*BaseTicker) ToStdTicker

func (t *BaseTicker) ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker

type Bybit

type Bybit struct {
	*banexg.Exchange
	RecvWindow int // 允许的和服务器最大毫秒时间差
}

func New

func New(Options map[string]interface{}) (*Bybit, *errs.Error)

func (*Bybit) FetchFundingRateHistory

func (e *Bybit) FetchFundingRateHistory(symbol string, since int64, limit int, params map[string]interface{}) ([]*banexg.FundingRate, *errs.Error)

func (*Bybit) FetchOHLCV

func (e *Bybit) FetchOHLCV(symbol, timeframe string, since int64, limit int, params map[string]interface{}) ([]*banexg.Kline, *errs.Error)

func (*Bybit) FetchTicker

func (e *Bybit) FetchTicker(symbol string, params map[string]interface{}) (*banexg.Ticker, *errs.Error)

func (*Bybit) FetchTickerPrice

func (e *Bybit) FetchTickerPrice(symbol string, params map[string]interface{}) (map[string]float64, *errs.Error)

func (*Bybit) FetchTickers

func (e *Bybit) FetchTickers(symbols []string, params map[string]interface{}) ([]*banexg.Ticker, *errs.Error)

func (*Bybit) Init

func (e *Bybit) Init() *errs.Error

type Chain

type Chain struct {
	Chain                 string `json:"chain"`
	ChainType             string `json:"chainType"`
	Confirmation          string `json:"confirmation"`
	WithdrawFee           string `json:"withdrawFee"`
	DepositMin            string `json:"depositMin"`
	WithdrawMin           string `json:"withdrawMin"`
	ChainDeposit          string `json:"chainDeposit"`
	ChainWithdraw         string `json:"chainWithdraw"`
	MinAccuracy           string `json:"minAccuracy"`
	WithdrawPercentageFee string `json:"withdrawPercentageFee"`
}

type ContractMarket

type ContractMarket struct {
	BaseMarket
	SettleCoin      string   `json:"settleCoin"`
	LaunchTime      string   `json:"launchTime"`
	DeliveryTime    string   `json:"deliveryTime"`
	DeliveryFeeRate string   `json:"deliveryFeeRate"`
	PriceFilter     *PriceFt `json:"priceFilter"`
}

func (*ContractMarket) ToStdMarket

func (m *ContractMarket) ToStdMarket(e *Bybit) *banexg.Market

type ContractTicker

type ContractTicker struct {
	BaseTicker
	IndexPrice             string `json:"indexPrice"`
	PredictedDeliveryPrice string `json:"predictedDeliveryPrice"`
	MarkPrice              string `json:"markPrice"`
	OpenInterest           string `json:"openInterest"`
}

func (*ContractTicker) ToStdTicker

func (t *ContractTicker) ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker

type Currency

type Currency struct {
	Name         string   `json:"name"`
	Coin         string   `json:"coin"`
	RemainAmount string   `json:"remainAmount"`
	Chains       []*Chain `json:"chains"`
}

type FundRate

type FundRate struct {
	Symbol               string `json:"symbol"`
	FundingRate          string `json:"fundingRate"`
	FundingRateTimestamp string `json:"fundingRateTimestamp"`
}

type FutureLotSizeFt

type FutureLotSizeFt struct {
	OptionLotSizeFt
	MaxMktOrderQty      string `json:"maxMktOrderQty"`
	PostOnlyMaxOrderQty string `json:"postOnlyMaxOrderQty"`
	MinNotionalValue    string `json:"minNotionalValue"`
}

type FutureMarket

type FutureMarket struct {
	ContractMarket
	ContractType       string           `json:"contractType"`
	PriceScale         string           `json:"priceScale"`
	LeverageFilter     *LeverageFt      `json:"leverageFilter"`
	LotSizeFilter      *FutureLotSizeFt `json:"lotSizeFilter"`
	UnifiedMarginTrade bool             `json:"unifiedMarginTrade"`
	FundingInterval    int              `json:"fundingInterval"`
	CopyTrading        string           `json:"copyTrading"`
	UpperFundingRate   string           `json:"upperFundingRate"`
	LowerFundingRate   string           `json:"lowerFundingRate"`
}

type FutureTicker

type FutureTicker struct {
	ContractTicker
	PrevPrice24h      string `json:"prevPrice24h"`
	Price24hPcnt      string `json:"price24hPcnt"`
	PrevPrice1h       string `json:"prevPrice1h"`
	OpenInterestValue string `json:"openInterestValue"`
	FundingRate       string `json:"fundingRate"`
	NextFundingTime   string `json:"nextFundingTime"`
	BasisRate         string `json:"basisRate"`
	DeliveryFeeRate   string `json:"deliveryFeeRate"`
	DeliveryTime      string `json:"deliveryTime"`
	Basis             string `json:"basis"`
}

func (*FutureTicker) ToStdTicker

func (t *FutureTicker) ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker

type ITicker

type ITicker interface {
	ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker
}

type LeverageFt

type LeverageFt struct {
	MinLeverage  string `json:"minLeverage"`
	MaxLeverage  string `json:"maxLeverage"`
	LeverageStep string `json:"leverageStep"`
}

type LotSizeFt

type LotSizeFt struct {
	BasePrecision  string `json:"basePrecision"`
	QuotePrecision string `json:"quotePrecision"`
	MinOrderQty    string `json:"minOrderQty"`
	MaxOrderQty    string `json:"maxOrderQty"`
	MinOrderAmt    string `json:"minOrderAmt"`
	MaxOrderAmt    string `json:"maxOrderAmt"`
}

type OptionLotSizeFt

type OptionLotSizeFt struct {
	MinOrderQty string `json:"minOrderQty"`
	MaxOrderQty string `json:"maxOrderQty"`
	QtyStep     string `json:"qtyStep"`
}

type OptionMarket

type OptionMarket struct {
	ContractMarket
	OptionsType   string           `json:"optionsType"`
	LotSizeFilter *OptionLotSizeFt `json:"lotSizeFilter"`
}

type OptionTicker

type OptionTicker struct {
	ContractTicker
	Bid1Iv          string `json:"bid1Iv"`
	Ask1Iv          string `json:"ask1Iv"`
	MarkIv          string `json:"markIv"`
	UnderlyingPrice string `json:"underlyingPrice"`
	TotalVolume     string `json:"totalVolume"`
	TotalTurnover   string `json:"totalTurnover"`
	Delta           string `json:"delta"`
	Gamma           string `json:"gamma"`
	Vega            string `json:"vega"`
	Theta           string `json:"theta"`
	Change24h       string `json:"change24h"`
}

func (*OptionTicker) ToStdTicker

func (t *OptionTicker) ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker

type PriceFt

type PriceFt struct {
	MinPrice string `json:"minPrice"` // empty for spot
	MaxPrice string `json:"maxPrice"` // empty for spot
	TickSize string `json:"tickSize"`
}

type RiskParams

type RiskParams struct {
	LimitParameter  string `json:"limitParameter"`
	MarketParameter string `json:"marketParameter"`
}

type SpotMarket

type SpotMarket struct {
	BaseMarket
	Innovation     string      `json:"innovation"`
	MarginTrading  string      `json:"marginTrading"`
	LotSizeFilter  *LotSizeFt  `json:"lotSizeFilter"`
	PriceFilter    *PriceFt    `json:"priceFilter"`
	RiskParameters *RiskParams `json:"riskParameters"`
}

type SpotTicker

type SpotTicker struct {
	BaseTicker
	PrevPrice24h  string `json:"prevPrice24h"`
	Price24hPcnt  string `json:"price24hPcnt"`
	UsdIndexPrice string `json:"usdIndexPrice"`
}

func (*SpotTicker) ToStdTicker

func (t *SpotTicker) ToStdTicker(e *Bybit, marketType string, info map[string]interface{}) *banexg.Ticker

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL