Merge pull request #55 from JJ-Cro/BitgetResponseTypes
v2.3.0 feat(): added all response types for all endpoints
This commit is contained in:
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "bitget-api",
|
"name": "bitget-api",
|
||||||
"version": "2.2.0",
|
"version": "2.3.0",
|
||||||
"lockfileVersion": 2,
|
"lockfileVersion": 2,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "bitget-api",
|
"name": "bitget-api",
|
||||||
"version": "2.2.0",
|
"version": "2.3.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"axios": "^1.6.1",
|
"axios": "^1.6.1",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "bitget-api",
|
"name": "bitget-api",
|
||||||
"version": "2.2.0",
|
"version": "2.3.0",
|
||||||
"description": "Node.js & JavaScript SDK for Bitget REST APIs & WebSockets, with TypeScript & end-to-end tests.",
|
"description": "Node.js & JavaScript SDK for Bitget REST APIs & WebSockets, with TypeScript & end-to-end tests.",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"types": "lib/index.d.ts",
|
"types": "lib/index.d.ts",
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -1,3 +1,10 @@
|
|||||||
export * from './futures';
|
export * from './v1/futures';
|
||||||
export * from './shared';
|
export * from './v1/shared';
|
||||||
export * from './spot';
|
export * from './v1/spot';
|
||||||
|
export * from './v2/broker';
|
||||||
|
export * from './v2/common';
|
||||||
|
export * from './v2/copy-trading';
|
||||||
|
export * from './v2/earn';
|
||||||
|
export * from './v2/futures';
|
||||||
|
export * from './v2/margin';
|
||||||
|
export * from './v2/spot';
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import {
|
|||||||
FuturesHoldMode,
|
FuturesHoldMode,
|
||||||
FuturesHoldSide,
|
FuturesHoldSide,
|
||||||
FuturesMarginMode,
|
FuturesMarginMode,
|
||||||
} from '../request';
|
} from '../../request';
|
||||||
|
|
||||||
export interface FuturesMarketTrade {
|
export interface FuturesMarketTrade {
|
||||||
tradeId: string;
|
tradeId: string;
|
||||||
148
src/types/response/v2/broker.ts
Normal file
148
src/types/response/v2/broker.ts
Normal file
@@ -0,0 +1,148 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Broker | Subaccount
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CreateSubaccountResponseV2 {
|
||||||
|
subUid: string;
|
||||||
|
subaccountName: string;
|
||||||
|
status: string;
|
||||||
|
permList: string[];
|
||||||
|
label: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BrokerSubaccountV2 {
|
||||||
|
subUid: string;
|
||||||
|
subaccountName: string;
|
||||||
|
status: string;
|
||||||
|
permList: string[];
|
||||||
|
label: string;
|
||||||
|
language: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ModifySubaccountResponseV2 {
|
||||||
|
subUid: string;
|
||||||
|
subaccountName: string;
|
||||||
|
status: string;
|
||||||
|
permList: string[];
|
||||||
|
label: string;
|
||||||
|
language: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SubaccountEmailV2 {
|
||||||
|
subUid: string;
|
||||||
|
subaccountName: string;
|
||||||
|
subaccountEmail: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BrokerSubaccountSpotAssetV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
frozen: string;
|
||||||
|
locked: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BrokerSubaccountFutureAssetV2 {
|
||||||
|
marginCoin: string;
|
||||||
|
available: string;
|
||||||
|
frozen: string;
|
||||||
|
locked: string;
|
||||||
|
crossedMaxAvailable: string;
|
||||||
|
isolatedMaxAvailable: string;
|
||||||
|
maxTransferOut: string;
|
||||||
|
accountEquity: string;
|
||||||
|
usdtEquity: string;
|
||||||
|
btcEquity: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CreateSubaccountDepositAddressV2 {
|
||||||
|
subUid: string;
|
||||||
|
coin: string;
|
||||||
|
address: string;
|
||||||
|
chain: string;
|
||||||
|
tag: string;
|
||||||
|
url: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SubaccountDepositV2 {
|
||||||
|
orderId: string;
|
||||||
|
txId: string;
|
||||||
|
coin: string;
|
||||||
|
type: string;
|
||||||
|
dest: string;
|
||||||
|
amount: string;
|
||||||
|
status: string;
|
||||||
|
fromAddress: string;
|
||||||
|
toAddress: string;
|
||||||
|
fee: string;
|
||||||
|
chain: string;
|
||||||
|
confirm: string;
|
||||||
|
tag: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BrokerSubaccountWithdrawalV2 {
|
||||||
|
orderId: string;
|
||||||
|
txId: string;
|
||||||
|
coin: string;
|
||||||
|
type: string;
|
||||||
|
dest: string;
|
||||||
|
amount: string;
|
||||||
|
status: string;
|
||||||
|
fromAddress: string;
|
||||||
|
toAddress: string;
|
||||||
|
fee: string;
|
||||||
|
chain: string;
|
||||||
|
confirm: string;
|
||||||
|
tag: string;
|
||||||
|
userId: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Broker | Api Key
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CreateSubaccountApiKeyResponseV2 {
|
||||||
|
subUid: string;
|
||||||
|
apiKey: string;
|
||||||
|
secretKey: string;
|
||||||
|
label: string;
|
||||||
|
ipList: string[];
|
||||||
|
permType: string;
|
||||||
|
permList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SubaccountApiKeyV2 {
|
||||||
|
subUid: string;
|
||||||
|
label: string;
|
||||||
|
apiKey: string;
|
||||||
|
secretKey: string;
|
||||||
|
permType: string;
|
||||||
|
permList: string[];
|
||||||
|
ipList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ModifySubaccountApiKeyResponseV2 {
|
||||||
|
subUid: string;
|
||||||
|
apiKey: string;
|
||||||
|
label: string;
|
||||||
|
ipList: string[];
|
||||||
|
permType: string;
|
||||||
|
permList: string[];
|
||||||
|
}
|
||||||
425
src/types/response/v2/common.ts
Normal file
425
src/types/response/v2/common.ts
Normal file
@@ -0,0 +1,425 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Notice
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface AnnouncementV2 {
|
||||||
|
annId: string;
|
||||||
|
annTitle: string;
|
||||||
|
annDesc: string;
|
||||||
|
cTime: string;
|
||||||
|
language: string;
|
||||||
|
annUrl: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Public
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Tax
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface SpotTransactionRecordV2 {
|
||||||
|
id: string;
|
||||||
|
coin: string;
|
||||||
|
spotTaxType: string;
|
||||||
|
amount: string;
|
||||||
|
fee: string;
|
||||||
|
balance: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesTransactionRecordV2 {
|
||||||
|
id: string;
|
||||||
|
symbol: string;
|
||||||
|
marginCoin: string;
|
||||||
|
futureTaxType: string;
|
||||||
|
amount: string;
|
||||||
|
fee: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginTransactionRecordV2 {
|
||||||
|
id: string;
|
||||||
|
coin: string;
|
||||||
|
marginTaxType: string;
|
||||||
|
amount: string;
|
||||||
|
fee: string;
|
||||||
|
total: string;
|
||||||
|
symbol: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface P2PMerchantOrdersV2 {
|
||||||
|
id: string;
|
||||||
|
coin: string;
|
||||||
|
p2pTaxType: string;
|
||||||
|
total: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | P2P
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface P2PMerchantV2 {
|
||||||
|
registerTime: string;
|
||||||
|
nickName: string;
|
||||||
|
isOnline: string;
|
||||||
|
avgPaymentTime: string;
|
||||||
|
avgReleaseTime: string;
|
||||||
|
totalTrades: string;
|
||||||
|
totalBuy: string;
|
||||||
|
totalSell: string;
|
||||||
|
totalCompletionRate: string;
|
||||||
|
trades30d: string;
|
||||||
|
sell30d: string;
|
||||||
|
buy30d: string;
|
||||||
|
completionRate30d: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface P2PMerchantInfoV2 {
|
||||||
|
registerTime: string;
|
||||||
|
nickName: string;
|
||||||
|
merchantId: string;
|
||||||
|
avgPaymentTime: string;
|
||||||
|
avgReleaseTime: string;
|
||||||
|
totalTrades: string;
|
||||||
|
totalBuy: string;
|
||||||
|
totalSell: string;
|
||||||
|
totalCompletionRate: string;
|
||||||
|
trades30d: string;
|
||||||
|
sell30d: string;
|
||||||
|
buy30d: string;
|
||||||
|
completionRate30d: string;
|
||||||
|
kycStatus: boolean;
|
||||||
|
emailBindStatus: boolean;
|
||||||
|
mobileBindStatus: boolean;
|
||||||
|
email: string;
|
||||||
|
mobile: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface P2PMerchantOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
orderNo: string;
|
||||||
|
advNo: string;
|
||||||
|
side: string;
|
||||||
|
count: string;
|
||||||
|
coin: string;
|
||||||
|
price: string;
|
||||||
|
fiat: string;
|
||||||
|
withdrawTime: string;
|
||||||
|
representTime: string;
|
||||||
|
releaseTime: string;
|
||||||
|
paymentTime: string;
|
||||||
|
amount: string;
|
||||||
|
status: string;
|
||||||
|
buyerRealName: string;
|
||||||
|
sellerRealName: string;
|
||||||
|
ctime: string;
|
||||||
|
utime: string;
|
||||||
|
paymentInfo: {
|
||||||
|
paymethodName: string;
|
||||||
|
paymethodId: string;
|
||||||
|
paymethodInfo: {
|
||||||
|
name: string;
|
||||||
|
required: string;
|
||||||
|
type: string;
|
||||||
|
value: string;
|
||||||
|
}[];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface P2PMerchantAdvertismentV2 {
|
||||||
|
advId: string;
|
||||||
|
advNo: string;
|
||||||
|
side: string;
|
||||||
|
advSize: string;
|
||||||
|
size: string;
|
||||||
|
coin: string;
|
||||||
|
price: string;
|
||||||
|
coinPrecision: string;
|
||||||
|
fiat: string;
|
||||||
|
fiatPrecision: string;
|
||||||
|
fiatSymbol: string;
|
||||||
|
status: string;
|
||||||
|
hide: string;
|
||||||
|
maxTradeAmount: string;
|
||||||
|
minTradeAmount: string;
|
||||||
|
payDuration: string;
|
||||||
|
turnoverNum: string;
|
||||||
|
turnoverRate: string;
|
||||||
|
label: string | null;
|
||||||
|
userLimitList: {
|
||||||
|
minCompleteNum: string;
|
||||||
|
maxCompleteNum: string;
|
||||||
|
placeOrderNum: string;
|
||||||
|
allowMerchantPlace: string;
|
||||||
|
completeRate30d: string;
|
||||||
|
country: string;
|
||||||
|
};
|
||||||
|
paymentMethodList: {
|
||||||
|
paymentMethod: string;
|
||||||
|
paymentId: string;
|
||||||
|
paymentInfo: {
|
||||||
|
name: string;
|
||||||
|
required: boolean;
|
||||||
|
type: string;
|
||||||
|
}[];
|
||||||
|
}[];
|
||||||
|
merchantCertifiedList: {
|
||||||
|
imageUrl: string;
|
||||||
|
desc: string;
|
||||||
|
}[];
|
||||||
|
utime: string;
|
||||||
|
ctime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Trading insights
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface SpotWhaleNetFlowV2 {
|
||||||
|
volume: string;
|
||||||
|
date: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesActiveBuySellVolumeV2 {
|
||||||
|
buyVolume: string;
|
||||||
|
sellVolume: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesActiveLongShortPositionV2 {
|
||||||
|
longPositionRatio: string;
|
||||||
|
shortPositionRatio: string;
|
||||||
|
longShortPositionRatio: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface LeveragedLongShortRatioV2 {
|
||||||
|
ts: string;
|
||||||
|
longShortRatio: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginLoanGrowthRateV2 {
|
||||||
|
ts: string;
|
||||||
|
growthRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IsolatedMarginBorrowingRatioV2 {
|
||||||
|
ts: string;
|
||||||
|
borrowRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesLongShortRatioV2 {
|
||||||
|
longRatio: string;
|
||||||
|
shortRatio: string;
|
||||||
|
longShortRatio: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotFundFlowV2 {
|
||||||
|
whaleBuyVolume: string;
|
||||||
|
dolphinBuyVolume: string;
|
||||||
|
fishBuyVolume: string;
|
||||||
|
whaleSellVolume: string;
|
||||||
|
dolphinSellVolume: string;
|
||||||
|
fishSellVolume: string;
|
||||||
|
whaleBuyRatio: string;
|
||||||
|
dolphinBuyRatio: string;
|
||||||
|
fishBuyRatio: string;
|
||||||
|
whaleSellRatio: string;
|
||||||
|
dolphinSellRatio: string;
|
||||||
|
fishSellRatio: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesActiveLongShortAccountV2 {
|
||||||
|
longAccountRatio: string;
|
||||||
|
shortAccountRatio: string;
|
||||||
|
longShortAccountRatio: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Virtual Subaccount
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CreateVirtualSubAccountV2 {
|
||||||
|
failureList: {
|
||||||
|
subaAccountName: string;
|
||||||
|
}[];
|
||||||
|
successList: {
|
||||||
|
subaAccountUid: string;
|
||||||
|
subaAccountName: string;
|
||||||
|
status: string;
|
||||||
|
label: string;
|
||||||
|
permList: string[];
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CreateVirtualSubAccountAndApiKeyV2 {
|
||||||
|
subAccountUid: string;
|
||||||
|
subAccountName: string;
|
||||||
|
label: string;
|
||||||
|
subAccountApiKey: string;
|
||||||
|
secretKey: string;
|
||||||
|
permList: string[];
|
||||||
|
ipList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface VirtualSubAccountV2 {
|
||||||
|
subAccountUid: string;
|
||||||
|
subAccountName: string;
|
||||||
|
status: string;
|
||||||
|
permList: string[];
|
||||||
|
label: string;
|
||||||
|
accountType: string;
|
||||||
|
bindingTime: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CreateVirtualSubAccountApiKeyV2 {
|
||||||
|
subAccountUid: string;
|
||||||
|
label: string;
|
||||||
|
subAccountApiKey: string;
|
||||||
|
secretKey: string;
|
||||||
|
permList: string[];
|
||||||
|
ipList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ModifyVirtualSubAccountApiKeyV2 {
|
||||||
|
subAccountUid: string;
|
||||||
|
label: string;
|
||||||
|
subAccountApiKey: string;
|
||||||
|
secretKey: string;
|
||||||
|
permList: string[];
|
||||||
|
ipList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SubAccountApiKeyItemV2 {
|
||||||
|
subAccountUid: string;
|
||||||
|
label: string;
|
||||||
|
subAccountApiKey: string;
|
||||||
|
permList: string[];
|
||||||
|
ipList: string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Assets
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FundingAssetV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
frozen: string;
|
||||||
|
usdtValue: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BotAssetV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
equity: string;
|
||||||
|
bonus: string;
|
||||||
|
frozen: string;
|
||||||
|
usdtValue: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | Convert
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface ConvertCurrencyV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
maxAmount: string;
|
||||||
|
minAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ConvertQuotedPriceV2 {
|
||||||
|
fee: string;
|
||||||
|
fromCoinSize: string;
|
||||||
|
fromCoin: string;
|
||||||
|
cnvtPrice: string;
|
||||||
|
toCoinSize: string;
|
||||||
|
toCoin: string;
|
||||||
|
traceId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ConvertTradeResponseV2 {
|
||||||
|
ts: string;
|
||||||
|
cnvtPrice: string;
|
||||||
|
toCoinSize: string;
|
||||||
|
toCoin: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ConvertRecordV2 {
|
||||||
|
id: string;
|
||||||
|
ts: string;
|
||||||
|
cnvtPrice: string;
|
||||||
|
fee: string;
|
||||||
|
fromCoinSize: string;
|
||||||
|
fromCoin: string;
|
||||||
|
toCoinSize: string;
|
||||||
|
toCoin: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Common | BGB Convert
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface BGBConvertCoinV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
bgbEstAmount: string;
|
||||||
|
precision: string;
|
||||||
|
feeDetail: {
|
||||||
|
feeRate: string;
|
||||||
|
fee: string;
|
||||||
|
}[];
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ConvertBGBResponseV2 {
|
||||||
|
orderList: {
|
||||||
|
coin: string;
|
||||||
|
orderId: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface BGBConvertHistoryV2 {
|
||||||
|
orderId: string;
|
||||||
|
fromCoin: string;
|
||||||
|
fromAmount: string;
|
||||||
|
fromCoinPrice: string;
|
||||||
|
toCoin: string;
|
||||||
|
toAmount: string;
|
||||||
|
toCoinPrice: string;
|
||||||
|
feeDetail: {
|
||||||
|
feeCoin: string;
|
||||||
|
fee: string;
|
||||||
|
}[];
|
||||||
|
status: string;
|
||||||
|
ctime: string;
|
||||||
|
}
|
||||||
424
src/types/response/v2/copy-trading.ts
Normal file
424
src/types/response/v2/copy-trading.ts
Normal file
@@ -0,0 +1,424 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Copy Trading | Future copy trading | Trader Api
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CTFuturesTraderCurrentOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
openOrderId: string;
|
||||||
|
symbol: string;
|
||||||
|
posSide: string;
|
||||||
|
openLeverage: string;
|
||||||
|
openPriceAvg: string;
|
||||||
|
openTime: string;
|
||||||
|
openSize: string;
|
||||||
|
presetStopSurplusPrice: string;
|
||||||
|
presetStopLossPrice: string;
|
||||||
|
openFee: string;
|
||||||
|
followCount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderCurrentOrdersV2 {
|
||||||
|
trackingList: CTFuturesTraderCurrentOrderV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderHistoryOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
symbol: string;
|
||||||
|
openOrderId: string;
|
||||||
|
closeOrderId: string;
|
||||||
|
productType: string;
|
||||||
|
posSide: string;
|
||||||
|
openLeverage: string;
|
||||||
|
openPriceAvg: string;
|
||||||
|
openTime: string;
|
||||||
|
openSize: string;
|
||||||
|
closeSize: string;
|
||||||
|
closeTime: string;
|
||||||
|
closePriceAvg: string;
|
||||||
|
stopType: string;
|
||||||
|
achievedPL: string;
|
||||||
|
openFee: string;
|
||||||
|
closeFee: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderHistoryOrderV2 {
|
||||||
|
trackingList: CTFuturesTraderHistoryOrderV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTRateCTimeV2 {
|
||||||
|
rate: string;
|
||||||
|
ctime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTAmountCTimeV2 {
|
||||||
|
amount: string;
|
||||||
|
ctime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderTotalOrderSummaryV2 {
|
||||||
|
roi: string;
|
||||||
|
tradingOrderNum: string;
|
||||||
|
totalFollowerNum: string;
|
||||||
|
currentFollowerNum: string;
|
||||||
|
totalpl: string;
|
||||||
|
gainNum: string;
|
||||||
|
lossNum: string;
|
||||||
|
winRate: string;
|
||||||
|
tradingPairsAvailableList: string[];
|
||||||
|
lastWeekRoiList: CTRateCTimeV2[];
|
||||||
|
lastWeekProfitList: CTAmountCTimeV2[];
|
||||||
|
lastMonthRoiList: CTRateCTimeV2[];
|
||||||
|
lastMonthProfitList: CTAmountCTimeV2[];
|
||||||
|
totalEquity: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderProfitHistoryItemV2 {
|
||||||
|
coin: string;
|
||||||
|
profitCount: string;
|
||||||
|
lastProfitTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderHistoryProfitSummaryV2 {
|
||||||
|
profitSummary: {
|
||||||
|
yesterdayProfit: string;
|
||||||
|
sumProfit: string;
|
||||||
|
waitProfit: string;
|
||||||
|
yesterdayTime: string;
|
||||||
|
};
|
||||||
|
profitHistoryList: CTFuturesTraderProfitHistoryItemV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderProfitShare {
|
||||||
|
profitId: string;
|
||||||
|
coin: string;
|
||||||
|
profit: string;
|
||||||
|
nickName: string;
|
||||||
|
profitTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderProfitShareHistoryV2 {
|
||||||
|
profitList: CTFuturesTraderProfitShare[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderSymbolSettingsV2 {
|
||||||
|
symbol: string;
|
||||||
|
openTrader: string;
|
||||||
|
minOpenCount: string;
|
||||||
|
maxLeverage: string;
|
||||||
|
stopSurplusRatio: string;
|
||||||
|
stopLossRatio: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesTraderMyFollowersV2 {
|
||||||
|
accountEquity: string;
|
||||||
|
isRemove: string;
|
||||||
|
followerHeadPic: string;
|
||||||
|
followerName: string;
|
||||||
|
followerUid: string;
|
||||||
|
followerTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Copy Trading | Future copy trading | Follower Api
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerCurrentOrdersV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
traderName: string;
|
||||||
|
openOrderId: string;
|
||||||
|
closeOrderId: string;
|
||||||
|
traderId: string;
|
||||||
|
symbol: string;
|
||||||
|
posSide: string;
|
||||||
|
openLeverage: string;
|
||||||
|
openAvgPrice: string;
|
||||||
|
openTime: string;
|
||||||
|
openSize: string;
|
||||||
|
closeAvgPrice: string;
|
||||||
|
closeSize: string;
|
||||||
|
openMarginSz: string;
|
||||||
|
closeTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerHistoryOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
posSide: string;
|
||||||
|
openLeverage: string;
|
||||||
|
openSize: string;
|
||||||
|
closeSize: string;
|
||||||
|
openPriceAvg: string;
|
||||||
|
closePriceAvg: string;
|
||||||
|
achievedPL: string;
|
||||||
|
openFee: string;
|
||||||
|
closeFee: string;
|
||||||
|
symbol: string;
|
||||||
|
profitRate: string;
|
||||||
|
netProfit: string;
|
||||||
|
openOrderId: string;
|
||||||
|
closeOrderId: string;
|
||||||
|
openTime: string;
|
||||||
|
closeTime: string;
|
||||||
|
traderId: string;
|
||||||
|
productType: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerHistoryOrdersV2 {
|
||||||
|
trackingList: CTFuturesFollowerHistoryOrderV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerSettingV2 {
|
||||||
|
symbol: string;
|
||||||
|
productType: string;
|
||||||
|
marginType: string;
|
||||||
|
marginCoin: string;
|
||||||
|
leverType: string;
|
||||||
|
longLeverage: string;
|
||||||
|
shortLeverage: string;
|
||||||
|
traceType: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerSettingsV2 {
|
||||||
|
followerEnable: string;
|
||||||
|
detailList: CTFuturesFollowerSettingV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTFuturesFollowerMyTradersV2 {
|
||||||
|
certificationType: string;
|
||||||
|
traderId: string;
|
||||||
|
traderName: string;
|
||||||
|
maxFollowLimit: string;
|
||||||
|
followCount: string;
|
||||||
|
traceTotalMarginAmount: string;
|
||||||
|
traceTotalNetProfit: string;
|
||||||
|
traceTotalProfit: string;
|
||||||
|
currentTradingPairs: string[];
|
||||||
|
followerTime: string;
|
||||||
|
bgbMaxFollowLimit: string;
|
||||||
|
bgbFollowCount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Copy Trading | Spot copy trading | Trader api
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CTSpotTraderProfitSummaryV2 {
|
||||||
|
profitSummarys: {
|
||||||
|
yesterdayProfit: string;
|
||||||
|
yesterdayTime: string;
|
||||||
|
sumProfit: string;
|
||||||
|
waitProfit: string;
|
||||||
|
};
|
||||||
|
profitHistoryList: {
|
||||||
|
coin: string;
|
||||||
|
profitCount: string;
|
||||||
|
lastProfitTime: string;
|
||||||
|
historysByDateList: {
|
||||||
|
profit: string;
|
||||||
|
profitTime: string;
|
||||||
|
}[];
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderHistoryProfitShareItemV2 {
|
||||||
|
profitId: string;
|
||||||
|
coin: string;
|
||||||
|
distributeRatio: string;
|
||||||
|
profit: string;
|
||||||
|
followerName: string;
|
||||||
|
profitTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderHistoryProfitSharingV2 {
|
||||||
|
endId: string;
|
||||||
|
profitList: CTSpotTraderHistoryProfitShareItemV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderUnrealizedProfitV2 {
|
||||||
|
distributeRatio: string;
|
||||||
|
coin: string;
|
||||||
|
profit: string;
|
||||||
|
followerName: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderTotalOrderDetailV2 {
|
||||||
|
totalFollowerNum: string;
|
||||||
|
currentFollowerNum: string;
|
||||||
|
maxFollowerNum: string;
|
||||||
|
tradingOrderNum: string;
|
||||||
|
totalpl: string;
|
||||||
|
gainNum: string;
|
||||||
|
lossNum: string;
|
||||||
|
totalEquity: string;
|
||||||
|
winRate: string;
|
||||||
|
lastWeekRoiList: CTAmountCTimeV2[];
|
||||||
|
lastMonthRoiList: CTRateCTimeV2[];
|
||||||
|
lastWeekProfitList: CTAmountCTimeV2[];
|
||||||
|
lastMonthProfitList: CTAmountCTimeV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderHistoryOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
fillSize: string;
|
||||||
|
buyPrice: string;
|
||||||
|
sellPrice: string;
|
||||||
|
achievedPL: string;
|
||||||
|
buyTime: string;
|
||||||
|
sellTime: string;
|
||||||
|
buyFee: string;
|
||||||
|
sellFee: string;
|
||||||
|
achievedPLR: string;
|
||||||
|
symbol: string;
|
||||||
|
netProfit: string;
|
||||||
|
followCount: string;
|
||||||
|
}
|
||||||
|
export interface CTSpotTraderHistoryOrdersV2 {
|
||||||
|
endId: string;
|
||||||
|
trackingList: CTSpotTraderHistoryOrderV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderCurrentTrackingOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
orderId: string;
|
||||||
|
buyFillSize: string;
|
||||||
|
buyDelegateSize: string;
|
||||||
|
buyPrice: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
buyTime: string;
|
||||||
|
buyFee: string;
|
||||||
|
unrealizedPLR: string;
|
||||||
|
symbol: string;
|
||||||
|
stopLossPrice: string | null;
|
||||||
|
stopSurplusPrice: string | null;
|
||||||
|
followCount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderCurrentTrackingOrdersV2 {
|
||||||
|
endId: string;
|
||||||
|
trackingList: CTSpotTraderCurrentTrackingOrderV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotTraderFollowerListV2 {
|
||||||
|
accountEquity: string;
|
||||||
|
isRemove: string;
|
||||||
|
followerHeadPic: string | null;
|
||||||
|
followerName: string;
|
||||||
|
followerUid: string;
|
||||||
|
followerTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Copy Trading | Spot copy trading | Follower api
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CTSpotFollowerMyTraderV2 {
|
||||||
|
certificationType: string;
|
||||||
|
traceTotalAmount: string;
|
||||||
|
traceTotalNetProfit: string;
|
||||||
|
traceTotalProfit: string;
|
||||||
|
traderName: string;
|
||||||
|
traderId: string;
|
||||||
|
maxFollowLimit: string;
|
||||||
|
bgbMaxFollowLimit: string;
|
||||||
|
followCount: string;
|
||||||
|
bgbFollowCount: string;
|
||||||
|
followerTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerMyTradersV2 {
|
||||||
|
resultList: CTSpotFollowerMyTraderV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerTradeSettingV2 {
|
||||||
|
maxTraceAmount: string;
|
||||||
|
stopLossRation: string;
|
||||||
|
stopSurplusRation: string;
|
||||||
|
symbol: string;
|
||||||
|
traceType: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerTradeSymbolSettingV2 {
|
||||||
|
maxStopLossRation: string;
|
||||||
|
maxStopSurplusRation: string;
|
||||||
|
maxTraceAmount: string;
|
||||||
|
maxTraceAmountSystem: string;
|
||||||
|
maxTraceSize: string;
|
||||||
|
maxTraceRation: string;
|
||||||
|
minStopLossRation: string;
|
||||||
|
minStopSurplusRation: string;
|
||||||
|
minTraceAmount: string;
|
||||||
|
minTraceSize: string;
|
||||||
|
minTraceRation: string;
|
||||||
|
sliderMaxStopLossRatio: string;
|
||||||
|
sliderMaxStopSurplusRatio: string;
|
||||||
|
symbol: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerFollowConfigurationV2 {
|
||||||
|
enable: string;
|
||||||
|
profitRate: string;
|
||||||
|
settledInDays: string;
|
||||||
|
tradeSettingList: CTSpotFollowerTradeSettingV2[];
|
||||||
|
tradeSymbolSettingList: CTSpotFollowerTradeSymbolSettingV2[];
|
||||||
|
traderHeadPic: string;
|
||||||
|
traderName: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerHistoryOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
traderId: string;
|
||||||
|
fillSize: string;
|
||||||
|
buyPrice: string;
|
||||||
|
sellPrice: string;
|
||||||
|
buyFee: string;
|
||||||
|
sellFee: string;
|
||||||
|
achievedPL: string;
|
||||||
|
achievedPLR: string;
|
||||||
|
symbol: string;
|
||||||
|
buyTime: string;
|
||||||
|
sellTime: string;
|
||||||
|
}
|
||||||
|
export interface CTSpotFollowerHistoryOrdersV2 {
|
||||||
|
endId: string;
|
||||||
|
trackingList: CTSpotFollowerHistoryOrderV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerCurrentOrderV2 {
|
||||||
|
trackingNo: string;
|
||||||
|
traderId: string;
|
||||||
|
buyFillSize: string;
|
||||||
|
buyDelegateSize: string;
|
||||||
|
buyPrice: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
buyTime: string;
|
||||||
|
buyFee: string;
|
||||||
|
unrealizedPLR: string;
|
||||||
|
symbol: string;
|
||||||
|
stopSurplusPrice: string | null;
|
||||||
|
stopLossPrice: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CTSpotFollowerCurrentOrdersV2 {
|
||||||
|
endId: string;
|
||||||
|
trackingList: CTSpotFollowerCurrentOrderV2[];
|
||||||
|
}
|
||||||
322
src/types/response/v2/earn.ts
Normal file
322
src/types/response/v2/earn.ts
Normal file
@@ -0,0 +1,322 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Earn | Savings
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface EarnSavingsProductsV2 {
|
||||||
|
productId: string;
|
||||||
|
coin: string;
|
||||||
|
periodType: string;
|
||||||
|
period: string;
|
||||||
|
apyType: string;
|
||||||
|
advanceRedeem: string;
|
||||||
|
settleMethod: string;
|
||||||
|
apyList: {
|
||||||
|
rateLevel: string;
|
||||||
|
minStepVal: string;
|
||||||
|
maxStepVal: string;
|
||||||
|
currentApy: string;
|
||||||
|
}[];
|
||||||
|
status: string;
|
||||||
|
productLevel: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsAccountV2 {
|
||||||
|
btcAmount: string;
|
||||||
|
usdtAmount: string;
|
||||||
|
btc24hEarning: string;
|
||||||
|
usdt24hEarning: string;
|
||||||
|
btcTotalEarning: string;
|
||||||
|
usdtTotalEarning: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsAssetV2 {
|
||||||
|
productId: string;
|
||||||
|
orderId: string;
|
||||||
|
productCoin: string;
|
||||||
|
interestCoin: string;
|
||||||
|
periodType: string;
|
||||||
|
period: string;
|
||||||
|
holdAmount: string;
|
||||||
|
lastProfit: string;
|
||||||
|
totalProfit: string;
|
||||||
|
holdDays: string;
|
||||||
|
status: string;
|
||||||
|
allowRedemption: string;
|
||||||
|
productLevel: string;
|
||||||
|
apy: {
|
||||||
|
rateLevel: string;
|
||||||
|
minApy: string;
|
||||||
|
maxApy: string;
|
||||||
|
currentApy: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsAssetsV2 {
|
||||||
|
resultList: EarnSavingsAssetV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsRecordV2 {
|
||||||
|
orderId: string;
|
||||||
|
coinName: string;
|
||||||
|
settleCoinName: string;
|
||||||
|
productType: string;
|
||||||
|
period: string;
|
||||||
|
productLevel: string;
|
||||||
|
amount: string;
|
||||||
|
ts: string;
|
||||||
|
orderType: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsRecordsV2 {
|
||||||
|
resultList: EarnSavingsRecordV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSavingsSubscriptionDetailV2 {
|
||||||
|
singleMinAmount: string;
|
||||||
|
singleMaxAmount: string;
|
||||||
|
remainingAmount: string;
|
||||||
|
subscribePrecision: string;
|
||||||
|
profitPrecision: string;
|
||||||
|
subscribeTime: string;
|
||||||
|
interestTime: string;
|
||||||
|
settleTime: string;
|
||||||
|
expireTime: string;
|
||||||
|
redeemTime: string;
|
||||||
|
settleMethod: string;
|
||||||
|
apyList: {
|
||||||
|
rateLevel: string;
|
||||||
|
minStepVal: string;
|
||||||
|
maxStepVal: string;
|
||||||
|
currentApy: string;
|
||||||
|
}[];
|
||||||
|
redeemDelay: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Earn | Earn Account
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Earn | Shark Fin
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface EarnSharkfinProductV2 {
|
||||||
|
productId: string;
|
||||||
|
productName: string;
|
||||||
|
productCoin: string;
|
||||||
|
subscribeCoin: string;
|
||||||
|
farmingStartTime: string;
|
||||||
|
farmingEndTime: string;
|
||||||
|
lowerRate: string;
|
||||||
|
defaultRate: string;
|
||||||
|
upperRate: string;
|
||||||
|
period: string;
|
||||||
|
interestStartTime: string;
|
||||||
|
status: string;
|
||||||
|
minAmount: string;
|
||||||
|
limitAmount: string;
|
||||||
|
soldAmount: string;
|
||||||
|
endTime: string;
|
||||||
|
startTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinProductsV2 {
|
||||||
|
resultList: EarnSharkfinProductV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinAccountV2 {
|
||||||
|
btcSubscribeAmount: string;
|
||||||
|
usdtSubscribeAmount: string;
|
||||||
|
btcHistoricalAmount: string;
|
||||||
|
usdtHistoricalAmount: string;
|
||||||
|
btcTotalEarning: string;
|
||||||
|
usdtTotalEarning: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinAssetV2 {
|
||||||
|
productId: string;
|
||||||
|
interestStartTime: string;
|
||||||
|
interestEndTime: string;
|
||||||
|
productCoin: string;
|
||||||
|
subscribeCoin: string;
|
||||||
|
trend: string;
|
||||||
|
settleTime: string;
|
||||||
|
interestAmount: string;
|
||||||
|
productStatus: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinAssetsV2 {
|
||||||
|
resultList: EarnSharkfinAssetV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinRecordV2 {
|
||||||
|
orderId: string;
|
||||||
|
product: string;
|
||||||
|
period: string;
|
||||||
|
amount: string;
|
||||||
|
ts: string;
|
||||||
|
type: string;
|
||||||
|
}
|
||||||
|
export interface EarnSharkfinRecordsV2 {
|
||||||
|
resultList: EarnSharkfinRecordV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnSharkfinSubscriptionDetailV2 {
|
||||||
|
productCoin: string;
|
||||||
|
subscribeCoin: string;
|
||||||
|
interestTime: string;
|
||||||
|
expirationTime: string;
|
||||||
|
minPrice: string;
|
||||||
|
currentPrice: string;
|
||||||
|
maxPrice: string;
|
||||||
|
minRate: string;
|
||||||
|
defaultRate: string;
|
||||||
|
maxRate: string;
|
||||||
|
period: string;
|
||||||
|
productMinAmount: string;
|
||||||
|
availableBalance: string;
|
||||||
|
userAmount: string;
|
||||||
|
remainingAmount: string;
|
||||||
|
profitPrecision: string;
|
||||||
|
subscribePrecision: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Earn | Loan
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface EarnLoanCurrencyLoanInfoV2 {
|
||||||
|
coin: string;
|
||||||
|
hourRate7D: string;
|
||||||
|
rate7D: string;
|
||||||
|
hourRate30D: string;
|
||||||
|
rate30D: string;
|
||||||
|
minUsdt: string;
|
||||||
|
maxUsdt: string;
|
||||||
|
min: string;
|
||||||
|
max: string;
|
||||||
|
}
|
||||||
|
export interface EarnLoanCurrencyPledgeInfoV2 {
|
||||||
|
coin: string;
|
||||||
|
initRate: string;
|
||||||
|
supRate: string;
|
||||||
|
forceRate: string;
|
||||||
|
minUsdt: string;
|
||||||
|
maxUsdt: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanCurrenciesV2 {
|
||||||
|
loanInfos: EarnLoanCurrencyLoanInfoV2[];
|
||||||
|
pledgeInfos: EarnLoanCurrencyPledgeInfoV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanOrdersV2 {
|
||||||
|
orderId: string;
|
||||||
|
loanCoin: string;
|
||||||
|
loanAmount: string;
|
||||||
|
interestAmount: string;
|
||||||
|
hourInterestRate: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
pledgeAmount: string;
|
||||||
|
pledgeRate: string;
|
||||||
|
supRate: string;
|
||||||
|
forceRate: string;
|
||||||
|
borrowTime: string;
|
||||||
|
expireTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanRepayResponseV2 {
|
||||||
|
loanCoin: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
repayAmount: string;
|
||||||
|
payInterest: string;
|
||||||
|
repayLoanAmount: string;
|
||||||
|
repayUnlockAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanRepayHistoryV2 {
|
||||||
|
orderId: string;
|
||||||
|
loanCoin: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
repayAmount: string;
|
||||||
|
payInterest: string;
|
||||||
|
repayLoanAmount: string;
|
||||||
|
repayUnlockAmount: string;
|
||||||
|
repayTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanPledgeRateHistoryV2 {
|
||||||
|
loanCoin: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
orderId: string;
|
||||||
|
reviseTime: string;
|
||||||
|
reviseSide: string;
|
||||||
|
reviseAmount: string;
|
||||||
|
afterPledgeRate: string;
|
||||||
|
beforePledgeRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanHistoryV2 {
|
||||||
|
orderId: string;
|
||||||
|
loanCoin: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
initPledgeAmount: string;
|
||||||
|
initLoanAmount: string;
|
||||||
|
hourRate: string;
|
||||||
|
daily: string;
|
||||||
|
borrowTime: string;
|
||||||
|
status: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanDebtPledgeInfoV2 {
|
||||||
|
coin: string;
|
||||||
|
amount: string;
|
||||||
|
amountUsdt: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanDebtLoanInfoV2 {
|
||||||
|
coin: string;
|
||||||
|
amount: string;
|
||||||
|
amountUsdt: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanDebtsV2 {
|
||||||
|
pledgeInfos: EarnLoanDebtPledgeInfoV2[];
|
||||||
|
loanInfos: EarnLoanDebtLoanInfoV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface EarnLoanLiquidationRecordsV2 {
|
||||||
|
orderId: string;
|
||||||
|
loanCoin: string;
|
||||||
|
pledgeCoin: string;
|
||||||
|
reduceTime: string;
|
||||||
|
pledgeRate: string;
|
||||||
|
pledgePrice: string;
|
||||||
|
status: string;
|
||||||
|
pledgeAmount: string;
|
||||||
|
reduceFee: string;
|
||||||
|
residueAmount: string;
|
||||||
|
runlockAmount: string;
|
||||||
|
repayLoanAmount: string;
|
||||||
|
}
|
||||||
585
src/types/response/v2/futures.ts
Normal file
585
src/types/response/v2/futures.ts
Normal file
@@ -0,0 +1,585 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Futures | Market
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FuturesVipFeeRateV2 {
|
||||||
|
level: string;
|
||||||
|
dealAmount: string;
|
||||||
|
assetAmount: string;
|
||||||
|
takerFeeRate: string;
|
||||||
|
makerFeeRate: string;
|
||||||
|
btcWithdrawAmount: string;
|
||||||
|
usdtWithdrawAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesHistoryInterestRateV2 {
|
||||||
|
ts: string;
|
||||||
|
annualInterestRate: string;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesInterestExchangeRateV2 {
|
||||||
|
tier: string;
|
||||||
|
minAmount: string;
|
||||||
|
maxAmount: string;
|
||||||
|
exchangeRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesDiscountRateV2 {
|
||||||
|
tier: string;
|
||||||
|
minAmount: string;
|
||||||
|
maxAmount: string;
|
||||||
|
discountRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesDiscountRatesV2 {
|
||||||
|
coin: string;
|
||||||
|
userLimit: string;
|
||||||
|
totalLimit: string;
|
||||||
|
discountRateList: FuturesDiscountRateV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesMergeDepthV2 {
|
||||||
|
asks: [number, number][];
|
||||||
|
bids: [number, number][];
|
||||||
|
ts: string;
|
||||||
|
scale: string;
|
||||||
|
precision: string;
|
||||||
|
isMaxPrecision: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesTickerV2 {
|
||||||
|
symbol: string;
|
||||||
|
lastPr: string;
|
||||||
|
askPr: string;
|
||||||
|
bidPr: string;
|
||||||
|
bidSz: string;
|
||||||
|
askSz: string;
|
||||||
|
high24h: string;
|
||||||
|
low24h: string;
|
||||||
|
ts: string;
|
||||||
|
change24h: string;
|
||||||
|
baseVolume: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
usdtVolume: string;
|
||||||
|
openUtc: string;
|
||||||
|
changeUtc24h: string;
|
||||||
|
indexPrice: string;
|
||||||
|
fundingRate: string;
|
||||||
|
holdingAmount: string;
|
||||||
|
deliveryStartTime: string;
|
||||||
|
deliveryTime: string;
|
||||||
|
deliveryStatus: string;
|
||||||
|
open24h: string;
|
||||||
|
markPrice: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesFillV2 {
|
||||||
|
tradeId: string;
|
||||||
|
price: string;
|
||||||
|
size: string;
|
||||||
|
side: string;
|
||||||
|
ts: string;
|
||||||
|
symbol: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type FuturesCandlestickV2 = [
|
||||||
|
string, // timestamp
|
||||||
|
string, // open
|
||||||
|
string, // high
|
||||||
|
string, // low
|
||||||
|
string, // close
|
||||||
|
string, // baseVolume
|
||||||
|
string, // usdtVolume
|
||||||
|
string, // quoteVolume
|
||||||
|
];
|
||||||
|
|
||||||
|
export interface FuturesOpenInterestV2 {
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesFundingTimeV2 {
|
||||||
|
symbol: string;
|
||||||
|
nextFundingTime: string;
|
||||||
|
ratePeriod: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesSymbolPriceV2 {
|
||||||
|
symbol: string;
|
||||||
|
price: string;
|
||||||
|
indexPrice: string;
|
||||||
|
markPrice: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesHistoricalFundingRateV2 {
|
||||||
|
symbol: string;
|
||||||
|
fundingRate: string;
|
||||||
|
fundingTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesContractConfigV2 {
|
||||||
|
symbol: string;
|
||||||
|
baseCoin: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
buyLimitPriceRatio: string;
|
||||||
|
sellLimitPriceRatio: string;
|
||||||
|
feeRateUpRatio: string;
|
||||||
|
makerFeeRate: string;
|
||||||
|
takerFeeRate: string;
|
||||||
|
openCostUpRatio: string;
|
||||||
|
supportMarginCoins: string[];
|
||||||
|
minTradeNum: string;
|
||||||
|
priceEndStep: string;
|
||||||
|
volumePlace: string;
|
||||||
|
pricePlace: string;
|
||||||
|
sizeMultiplier: string;
|
||||||
|
symbolType: string;
|
||||||
|
minTradeUSDT: string;
|
||||||
|
maxSymbolOrderNum: string;
|
||||||
|
maxProductOrderNum: string;
|
||||||
|
maxPositionNum: string;
|
||||||
|
symbolStatus: string;
|
||||||
|
offTime: string;
|
||||||
|
limitOpenTime: string;
|
||||||
|
deliveryTime: string;
|
||||||
|
deliveryStartTime: string;
|
||||||
|
launchTime: string;
|
||||||
|
fundInterval: string;
|
||||||
|
minLever: string;
|
||||||
|
maxLever: string;
|
||||||
|
posLimit: string;
|
||||||
|
maintainTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Futures | Account
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FuturesAccountV2 {
|
||||||
|
marginCoin: string;
|
||||||
|
locked: string;
|
||||||
|
available: string;
|
||||||
|
crossedMaxAvailable: string;
|
||||||
|
isolatedMaxAvailable: string;
|
||||||
|
maxTransferOut: string;
|
||||||
|
accountEquity: string;
|
||||||
|
usdtEquity: string;
|
||||||
|
btcEquity: string;
|
||||||
|
crossedRiskRate: string;
|
||||||
|
crossedMarginLeverage: string;
|
||||||
|
isolatedLongLever: string;
|
||||||
|
isolatedShortLever: string;
|
||||||
|
marginMode: string;
|
||||||
|
posMode: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
coupon: string;
|
||||||
|
crossedUnrealizedPL: string;
|
||||||
|
isolatedUnrealizedPL: string;
|
||||||
|
assetMode: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesAccountsV2 {
|
||||||
|
marginCoin: string;
|
||||||
|
locked: string;
|
||||||
|
available: string;
|
||||||
|
crossedMaxAvailable: string;
|
||||||
|
isolatedMaxAvailable: string;
|
||||||
|
maxTransferOut: string;
|
||||||
|
accountEquity: string;
|
||||||
|
usdtEquity: string;
|
||||||
|
btcEquity: string;
|
||||||
|
crossedRiskRate: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
coupon: string;
|
||||||
|
unionTotalMagin: string;
|
||||||
|
unionAvailable: string;
|
||||||
|
unionMm: string;
|
||||||
|
assetList: {
|
||||||
|
coin: string;
|
||||||
|
balance: string;
|
||||||
|
}[];
|
||||||
|
isolatedMargin: string;
|
||||||
|
crossedMargin: string;
|
||||||
|
crossedUnrealizedPL: string;
|
||||||
|
isolatedUnrealizedPL: string;
|
||||||
|
assetMode: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesSubAccountAssetV2 {
|
||||||
|
marginCoin: string;
|
||||||
|
locked: string;
|
||||||
|
available: string;
|
||||||
|
crossedMaxAvailable: string;
|
||||||
|
isolatedMaxAvailable: string;
|
||||||
|
maxTransferOut: string;
|
||||||
|
accountEquity: string;
|
||||||
|
usdtEquity: string;
|
||||||
|
btcEquity: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
coupon: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesInterestV2 {
|
||||||
|
coin: string;
|
||||||
|
liability: string;
|
||||||
|
interestFreeLimit: string;
|
||||||
|
interestLimit: string;
|
||||||
|
hourInterestRate: string;
|
||||||
|
interest: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
export interface FuturesInterestHistoryV2 {
|
||||||
|
nextSettleTime: string;
|
||||||
|
borrowAmount: string;
|
||||||
|
borrowLimit: string;
|
||||||
|
interestList: FuturesInterestV2[];
|
||||||
|
endId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SetLeverageResponseV2 {
|
||||||
|
symbol: string;
|
||||||
|
marginCoin: string;
|
||||||
|
longLeverage: string;
|
||||||
|
shortLeverage: string;
|
||||||
|
crossMarginLeverage: string;
|
||||||
|
marginMode: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SetMarginModeResponseV2 {
|
||||||
|
symbol: string;
|
||||||
|
marginCoin: string;
|
||||||
|
longLeverage: string;
|
||||||
|
shortLeverage: string;
|
||||||
|
marginMode: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesAccountBillV2 {
|
||||||
|
billId: string;
|
||||||
|
symbol: string;
|
||||||
|
amount: string;
|
||||||
|
fee: string;
|
||||||
|
feeByCoupon: string;
|
||||||
|
businessType: string;
|
||||||
|
coin: string;
|
||||||
|
balance: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Futures | Position
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FuturesPositionTierV2 {
|
||||||
|
symbol: string;
|
||||||
|
level: string;
|
||||||
|
startUnit: string;
|
||||||
|
endUnit: string;
|
||||||
|
leverage: string;
|
||||||
|
keepMarginRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesPositionV2 {
|
||||||
|
marginCoin: string;
|
||||||
|
symbol: string;
|
||||||
|
holdSide: string;
|
||||||
|
openDelegateSize: string;
|
||||||
|
marginSize: string;
|
||||||
|
available: string;
|
||||||
|
locked: string;
|
||||||
|
total: string;
|
||||||
|
leverage: string;
|
||||||
|
achievedProfits: string;
|
||||||
|
openPriceAvg: string;
|
||||||
|
marginMode: string;
|
||||||
|
posMode: string;
|
||||||
|
unrealizedPL: string;
|
||||||
|
liquidationPrice: string;
|
||||||
|
keepMarginRate: string;
|
||||||
|
markPrice: string;
|
||||||
|
breakEvenPrice: string;
|
||||||
|
totalFee: string;
|
||||||
|
deductedFee: string;
|
||||||
|
marginRatio: string;
|
||||||
|
assetMode: string;
|
||||||
|
uTime: string;
|
||||||
|
autoMargin: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesHistoryPositionV2 {
|
||||||
|
positionId: string;
|
||||||
|
marginCoin: string;
|
||||||
|
symbol: string;
|
||||||
|
holdSide: string;
|
||||||
|
openAvgPrice: string;
|
||||||
|
closeAvgPrice: string;
|
||||||
|
marginMode: string;
|
||||||
|
openTotalPos: string;
|
||||||
|
closeTotalPos: string;
|
||||||
|
pnl: string;
|
||||||
|
netProfit: string;
|
||||||
|
totalFunding: string;
|
||||||
|
openFee: string;
|
||||||
|
closeFee: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Futures | Trade
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FuturesBatchOrderResponseV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
errorCode: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesClosePositionResponseV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
symbol: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
symbol: string;
|
||||||
|
errorMsg: string;
|
||||||
|
errorCode: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesOrderDetailV2 {
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
baseVolume: string;
|
||||||
|
priceAvg: string;
|
||||||
|
fee: string;
|
||||||
|
price: string;
|
||||||
|
state: string;
|
||||||
|
side: string;
|
||||||
|
force: string;
|
||||||
|
totalProfits: string;
|
||||||
|
posSide: string;
|
||||||
|
marginCoin: string;
|
||||||
|
presetStopSurplusPrice: string;
|
||||||
|
presetStopLossPrice: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
orderType: string;
|
||||||
|
leverage: string;
|
||||||
|
marginMode: string;
|
||||||
|
reduceOnly: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
orderSource: string;
|
||||||
|
cancelReason: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesOrderFillV2 {
|
||||||
|
tradeId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderId: string;
|
||||||
|
price: string;
|
||||||
|
baseVolume: string;
|
||||||
|
feeDetail: {
|
||||||
|
deduction: string;
|
||||||
|
feeCoin: string;
|
||||||
|
totalDeductionFee: string;
|
||||||
|
totalFee: string;
|
||||||
|
}[];
|
||||||
|
side: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
profit: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
tradeScope: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesOpenOrderV2 {
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
baseVolume: string;
|
||||||
|
fee: string;
|
||||||
|
price: string;
|
||||||
|
priceAvg: string;
|
||||||
|
status: string;
|
||||||
|
side: string;
|
||||||
|
force: string;
|
||||||
|
totalProfits: string;
|
||||||
|
posSide: string;
|
||||||
|
marginCoin: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
leverage: string;
|
||||||
|
marginMode: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
orderType: string;
|
||||||
|
orderSource: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
presetStopSurplusPrice: string;
|
||||||
|
presetStopSurplusType: string;
|
||||||
|
presetStopSurplusExecutePrice: string;
|
||||||
|
presetStopLossPrice: string;
|
||||||
|
presetStopLossType: string;
|
||||||
|
presetStopLossExecutePrice: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesHistoryOrderV2 {
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
baseVolume: string;
|
||||||
|
fee: string;
|
||||||
|
price: string;
|
||||||
|
priceAvg: string;
|
||||||
|
status: string;
|
||||||
|
side: string;
|
||||||
|
force: string;
|
||||||
|
totalProfits: string;
|
||||||
|
posSide: string;
|
||||||
|
marginCoin: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
leverage: string;
|
||||||
|
marginMode: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
orderType: string;
|
||||||
|
orderSource: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
presetStopSurplusPrice: string;
|
||||||
|
presetStopLossPrice: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesCancelAllOrdersV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
errorCode: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Futures | Trigger Orders
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface FuturesTriggerSubOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
price: string;
|
||||||
|
type: string;
|
||||||
|
status: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesPendingPlanOrderV2 {
|
||||||
|
planType: string;
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
price: string;
|
||||||
|
executePrice: string;
|
||||||
|
callbackRatio: string;
|
||||||
|
triggerPrice: string;
|
||||||
|
triggerType: string;
|
||||||
|
planStatus: string;
|
||||||
|
side: string;
|
||||||
|
posSide: string;
|
||||||
|
marginCoin: string;
|
||||||
|
marginMode: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
orderType: string;
|
||||||
|
orderSource: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
stopSurplusExecutePrice: string;
|
||||||
|
stopSurplusTriggerPrice: string;
|
||||||
|
stopSurplusTriggerType: string;
|
||||||
|
stopLossExecutePrice: string;
|
||||||
|
stopLossTriggerPrice: string;
|
||||||
|
stopLossTriggerType: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesCancelPlanOrderV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FuturesHistoryPlanOrderV2 {
|
||||||
|
planType: string;
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
orderId: string;
|
||||||
|
executeOrderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
planStatus: string;
|
||||||
|
price: string;
|
||||||
|
executePrice: string;
|
||||||
|
priceAvg: string;
|
||||||
|
baseVolume: string;
|
||||||
|
callbackRatio: string;
|
||||||
|
triggerPrice: string;
|
||||||
|
triggerType: string;
|
||||||
|
side: string;
|
||||||
|
posSide: string;
|
||||||
|
marginCoin: string;
|
||||||
|
marginMode: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
tradeSide: string;
|
||||||
|
posMode: string;
|
||||||
|
orderType: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
stopSurplusExecutePrice: string;
|
||||||
|
stopSurplusTriggerPrice: string;
|
||||||
|
stopSurplusTriggerType: string;
|
||||||
|
stopLossExecutePrice: string;
|
||||||
|
stopLossTriggerPrice: string;
|
||||||
|
stopLossTriggerType: string;
|
||||||
|
}
|
||||||
300
src/types/response/v2/margin.ts
Normal file
300
src/types/response/v2/margin.ts
Normal file
@@ -0,0 +1,300 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Margin | Common
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface MarginCurrencyV2 {
|
||||||
|
symbol: string;
|
||||||
|
baseCoin: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
maxCrossedLeverage: string;
|
||||||
|
maxIsolatedLeverage: string;
|
||||||
|
warningRiskRatio: string;
|
||||||
|
liquidationRiskRatio: string;
|
||||||
|
minTradeAmount: string;
|
||||||
|
maxTradeAmount: string;
|
||||||
|
takerFeeRate: string;
|
||||||
|
makerFeeRate: string;
|
||||||
|
pricePrecision: string;
|
||||||
|
quantityPrecision: string;
|
||||||
|
minTradeUSDT: string;
|
||||||
|
isBorrowable: boolean;
|
||||||
|
userMinBorrow: string;
|
||||||
|
status: string;
|
||||||
|
isIsolatedBaseBorrowable: boolean;
|
||||||
|
isIsolatedQuoteBorrowable: boolean;
|
||||||
|
isCrossBorrowable: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Margin | Cross/Isolated | Order Record
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface MarginBorrowHistoryItemV2 {
|
||||||
|
loanId: string;
|
||||||
|
coin: string;
|
||||||
|
borrowAmount: string;
|
||||||
|
borrowType: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginRepaymentHistoryItemV2 {
|
||||||
|
repayId: string;
|
||||||
|
coin: string;
|
||||||
|
repayAmount: string;
|
||||||
|
repayType: string;
|
||||||
|
repayInterest: string;
|
||||||
|
repayPrincipal: string;
|
||||||
|
symbol: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginInterestHistoryItemV2 {
|
||||||
|
interestId: string;
|
||||||
|
interestCoin: string;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
loanCoin: string;
|
||||||
|
interestAmount: string;
|
||||||
|
interstType: string;
|
||||||
|
symbol: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginLiquidationHistoryItemV2 {
|
||||||
|
liqId: string;
|
||||||
|
symbol: string;
|
||||||
|
liqStartTime: string;
|
||||||
|
liqEndTime: string;
|
||||||
|
liqRiskRatio: string;
|
||||||
|
totalAssets: string;
|
||||||
|
totalDebt: string;
|
||||||
|
liqFee: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginFinancialHistoryItemV2 {
|
||||||
|
coin: string;
|
||||||
|
symbol: string;
|
||||||
|
marginId: string;
|
||||||
|
amount: string;
|
||||||
|
balance: string;
|
||||||
|
fee: string;
|
||||||
|
marginType: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Margin | Cross/Isolated | Account
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface MarginAccountAssetV2 {
|
||||||
|
symbol: string;
|
||||||
|
coin: string;
|
||||||
|
totalAmount: string;
|
||||||
|
available: string;
|
||||||
|
frozen: string;
|
||||||
|
borrow: string;
|
||||||
|
interest: string;
|
||||||
|
net: string;
|
||||||
|
coupon: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CrossMaxBorrowableResponseV2 {
|
||||||
|
coin: string;
|
||||||
|
maxBorrowableAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IsolatedMaxBorrowableResponseV2 {
|
||||||
|
symbol: string;
|
||||||
|
baseCoin: string;
|
||||||
|
baseCoinMaxBorrowAmount: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
quoteCoinMaxBorrowAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CrossMaxTransferableResponseV2 {
|
||||||
|
coin: string;
|
||||||
|
maxTransferOutAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IsolatedMaxTransferableResponseV2 {
|
||||||
|
baseCoin: string;
|
||||||
|
symbol: string;
|
||||||
|
baseCoinMaxTransferOutAmount: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
quoteCoinMaxTransferOutAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CrossInterestRateAndLimitResponseV2 {
|
||||||
|
transferable: boolean;
|
||||||
|
leverage: string;
|
||||||
|
coin: string;
|
||||||
|
borrowable: boolean;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
annualInterestRate: string;
|
||||||
|
maxBorrowableAmount: string;
|
||||||
|
vipList: {
|
||||||
|
level: string;
|
||||||
|
limit: string;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
annualInterestRate: string;
|
||||||
|
discountRate: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IsolatedInterestRateAndLimitResponseV2 {
|
||||||
|
symbol: string;
|
||||||
|
leverage: string;
|
||||||
|
baseCoin: string;
|
||||||
|
baseTransferable: boolean;
|
||||||
|
baseBorrowable: boolean;
|
||||||
|
baseDailyInterestRate: string;
|
||||||
|
baseAnnuallyInterestRate: string;
|
||||||
|
baseMaxBorrowableAmount: string;
|
||||||
|
baseVipList: {
|
||||||
|
level: string;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
limit: string;
|
||||||
|
annuallyInterestRate: string;
|
||||||
|
discountRate: string;
|
||||||
|
}[];
|
||||||
|
quoteCoin: string;
|
||||||
|
quoteTransferable: boolean;
|
||||||
|
quoteBorrowable: boolean;
|
||||||
|
quoteDailyInterestRate: string;
|
||||||
|
quoteAnnuallyInterestRate: string;
|
||||||
|
quoteMaxBorrowableAmount: string;
|
||||||
|
quoteList: {
|
||||||
|
level: string;
|
||||||
|
dailyInterestRate: string;
|
||||||
|
limit: string;
|
||||||
|
annuallyInterestRate: string;
|
||||||
|
discountRate: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CrossTierConfigurationResponseV2 {
|
||||||
|
tier: string;
|
||||||
|
leverage: string;
|
||||||
|
coin: string;
|
||||||
|
maxBorrowableAmount: string;
|
||||||
|
maintainMarginRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IsolatedTierConfigurationResponseV2 {
|
||||||
|
tier: string;
|
||||||
|
symbol: string;
|
||||||
|
leverage: string;
|
||||||
|
baseCoin: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
baseMaxBorrowableAmount: string;
|
||||||
|
quoteMaxBorrowableAmount: string;
|
||||||
|
maintainMarginRate: string;
|
||||||
|
initRate: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Margin | Cross/Isolated | Trade
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface MarginBatchOrdersResponseV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginCurrentOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderType: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
clientOid: string;
|
||||||
|
loanType: string;
|
||||||
|
price: string;
|
||||||
|
side: string;
|
||||||
|
status: string;
|
||||||
|
baseSize: string;
|
||||||
|
quoteSize: string;
|
||||||
|
priceAvg: string;
|
||||||
|
size: string;
|
||||||
|
amount: string;
|
||||||
|
force: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginHistoryOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderType: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
clientOid: string;
|
||||||
|
loanType: string;
|
||||||
|
price: string;
|
||||||
|
side: string;
|
||||||
|
status: string;
|
||||||
|
baseSize: string;
|
||||||
|
quoteSize: string;
|
||||||
|
priceAvg: string;
|
||||||
|
size: string;
|
||||||
|
amount: string;
|
||||||
|
force: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginOrderFillV2 {
|
||||||
|
orderId: string;
|
||||||
|
tradeId: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
priceAvg: string;
|
||||||
|
size: string;
|
||||||
|
amount: string;
|
||||||
|
tradeScope: string;
|
||||||
|
feeDetail: {
|
||||||
|
deduction: string;
|
||||||
|
feeCoin: string;
|
||||||
|
totalDeductionFee: string;
|
||||||
|
totalFee: string;
|
||||||
|
};
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface MarginLiquidationOrderV2 {
|
||||||
|
symbol: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
priceAvg: string;
|
||||||
|
price: string;
|
||||||
|
fillSize: string;
|
||||||
|
size: string;
|
||||||
|
amount: string;
|
||||||
|
orderId: string;
|
||||||
|
fromCoin: string;
|
||||||
|
toCoin: string;
|
||||||
|
fromSize: string;
|
||||||
|
toSize: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
416
src/types/response/v2/spot.ts
Normal file
416
src/types/response/v2/spot.ts
Normal file
@@ -0,0 +1,416 @@
|
|||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Spot | Market
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface SpotCoinChainV2 {
|
||||||
|
chain: string;
|
||||||
|
needTag: boolean;
|
||||||
|
withdrawable: boolean;
|
||||||
|
rechargeable: boolean;
|
||||||
|
withdrawFee: string;
|
||||||
|
extraWithdrawFee: string;
|
||||||
|
depositConfirm: string;
|
||||||
|
withdrawConfirm: string;
|
||||||
|
minDepositAmount: string;
|
||||||
|
minWithdrawAmount: string;
|
||||||
|
browserUrl: string;
|
||||||
|
contractAddress: string;
|
||||||
|
withdrawStep: string;
|
||||||
|
withdrawMinScale: string;
|
||||||
|
congestion: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotCoinInfoV2 {
|
||||||
|
coinId: string;
|
||||||
|
coin: string;
|
||||||
|
transfer: boolean;
|
||||||
|
chains: SpotCoinChainV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotSymbolInfoV2 {
|
||||||
|
symbol: string;
|
||||||
|
baseCoin: string;
|
||||||
|
quoteCoin: string;
|
||||||
|
minTradeAmount: string;
|
||||||
|
maxTradeAmount: string;
|
||||||
|
takerFeeRate: string;
|
||||||
|
makerFeeRate: string;
|
||||||
|
pricePrecision: string;
|
||||||
|
quantityPrecision: string;
|
||||||
|
quotePrecision: string;
|
||||||
|
minTradeUSDT: string;
|
||||||
|
status: string;
|
||||||
|
buyLimitPriceRatio: string;
|
||||||
|
sellLimitPriceRatio: string;
|
||||||
|
orderQuantity: string;
|
||||||
|
areaSymbol: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotVipFeeRateV2 {
|
||||||
|
level: number;
|
||||||
|
dealAmount: string;
|
||||||
|
assetAmount: string;
|
||||||
|
takerFeeRate: string;
|
||||||
|
makerFeeRate: string;
|
||||||
|
btcWithdrawAmount: string;
|
||||||
|
usdtWithdrawAmount: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotTickerV2 {
|
||||||
|
symbol: string;
|
||||||
|
high24h: string;
|
||||||
|
open: string;
|
||||||
|
low24h: string;
|
||||||
|
lastPr: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
baseVolume: string;
|
||||||
|
usdtVolume: string;
|
||||||
|
bidPr: string;
|
||||||
|
askPr: string;
|
||||||
|
bidSz: string;
|
||||||
|
askSz: string;
|
||||||
|
openUtc: string;
|
||||||
|
ts: string;
|
||||||
|
changeUtc24h: string;
|
||||||
|
change24h: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotMergeDepthV2 {
|
||||||
|
asks: [string, string][];
|
||||||
|
bids: [string, string][];
|
||||||
|
ts: string;
|
||||||
|
scale: string;
|
||||||
|
precision: string;
|
||||||
|
isMaxPrecision: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotOrderBookDepthV2 {
|
||||||
|
asks: [string, string][];
|
||||||
|
bids: [string, string][];
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type SpotCandlestickV2 = [
|
||||||
|
string, // timestamp
|
||||||
|
string, // open
|
||||||
|
string, // high
|
||||||
|
string, // low
|
||||||
|
string, // close
|
||||||
|
string, // baseVolume
|
||||||
|
string, // usdtVolume
|
||||||
|
string, // quoteVolume
|
||||||
|
];
|
||||||
|
|
||||||
|
export interface SpotTradeV2 {
|
||||||
|
symbol: string;
|
||||||
|
tradeId: string;
|
||||||
|
side: string;
|
||||||
|
price: string;
|
||||||
|
size: string;
|
||||||
|
ts: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Spot | Trade
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface CancelAndSubmitSpotOrderResponseV2 {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string | null;
|
||||||
|
success: string;
|
||||||
|
msg: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SubmitSpotBatchOrdersResponseV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
errorCode?: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotOrderInfoV2 {
|
||||||
|
userId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
price: string;
|
||||||
|
size: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
status: string;
|
||||||
|
priceAvg: string;
|
||||||
|
baseVolume: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
feeDetail: {
|
||||||
|
BGB?: {
|
||||||
|
deduction: boolean;
|
||||||
|
feeCoinCode: string;
|
||||||
|
totalDeductionFee: string;
|
||||||
|
totalFee: string;
|
||||||
|
};
|
||||||
|
newFees?: {
|
||||||
|
c: number;
|
||||||
|
d: number;
|
||||||
|
deduction: boolean;
|
||||||
|
r: string;
|
||||||
|
t: string;
|
||||||
|
totalDeductionFee: number;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
orderSource: string;
|
||||||
|
cancelReason: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotOpenOrderV2 {
|
||||||
|
userId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
priceAvg: string;
|
||||||
|
size: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
status: string;
|
||||||
|
basePrice: string;
|
||||||
|
baseVolume: string;
|
||||||
|
quoteVolume: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
orderSource?: string;
|
||||||
|
presetTakeProfitPrice: string;
|
||||||
|
executeTakeProfitPrice: string;
|
||||||
|
presetStopLossPrice: string;
|
||||||
|
executeStopLossPrice: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime?: string;
|
||||||
|
tpslType: string;
|
||||||
|
triggerPrice: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotFillV2 {
|
||||||
|
userId: string;
|
||||||
|
symbol: string;
|
||||||
|
orderId: string;
|
||||||
|
tradeId: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
priceAvg: string;
|
||||||
|
size: string;
|
||||||
|
amount: string;
|
||||||
|
feeDetail: {
|
||||||
|
deduction: string;
|
||||||
|
feeCoin: string;
|
||||||
|
totalDeductionFee: string;
|
||||||
|
totalFee: string;
|
||||||
|
};
|
||||||
|
tradeScope: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Spot | Trigger Orders
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface SpotCurrentPlanOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
executePrice: string;
|
||||||
|
triggerPrice: string;
|
||||||
|
status: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
planType: string;
|
||||||
|
triggerType: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
uTime: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotHistoryPlanOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
symbol: string;
|
||||||
|
size: string;
|
||||||
|
executePrice: string;
|
||||||
|
triggerPrice: string;
|
||||||
|
status: string;
|
||||||
|
orderType: string;
|
||||||
|
side: string;
|
||||||
|
planType: string;
|
||||||
|
triggerType: string;
|
||||||
|
enterPointSource: string;
|
||||||
|
uTime: string;
|
||||||
|
cTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotPlanSubOrderV2 {
|
||||||
|
orderId: string;
|
||||||
|
price: string;
|
||||||
|
type: string;
|
||||||
|
status: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotCancelPlanOrdersV2 {
|
||||||
|
successList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
}[];
|
||||||
|
failureList: {
|
||||||
|
orderId: string;
|
||||||
|
clientOid: string;
|
||||||
|
errorMsg: string;
|
||||||
|
}[];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* * Spot | Account
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
export interface SpotAccountInfoV2 {
|
||||||
|
userId: string;
|
||||||
|
inviterId: string;
|
||||||
|
ips: string;
|
||||||
|
authorities: string[];
|
||||||
|
parentId: number;
|
||||||
|
traderType: string;
|
||||||
|
channelCode: string;
|
||||||
|
channel: string;
|
||||||
|
regisTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotAccountAssetV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
frozen: string;
|
||||||
|
locked: string;
|
||||||
|
limitAvailable: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotSubAccountAssetV2 {
|
||||||
|
coin: string;
|
||||||
|
available: string;
|
||||||
|
limitAvailable: string;
|
||||||
|
frozen: string;
|
||||||
|
locked: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
export interface SpotSubAccountAssetsV2 {
|
||||||
|
userId: number;
|
||||||
|
assetsList: SpotSubAccountAssetV2[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotAccountBillV2 {
|
||||||
|
cTime: string;
|
||||||
|
coin: string;
|
||||||
|
groupType: string;
|
||||||
|
businessType: string;
|
||||||
|
size: string;
|
||||||
|
balance: string;
|
||||||
|
fees: string;
|
||||||
|
billId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotMainSubTransferRecordV2 {
|
||||||
|
coin: string;
|
||||||
|
status: string;
|
||||||
|
toType: string;
|
||||||
|
fromType: string;
|
||||||
|
size: string;
|
||||||
|
ts: string;
|
||||||
|
clientOid: string;
|
||||||
|
transferId: string;
|
||||||
|
fromUserId: string;
|
||||||
|
toUserId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotTransferRecordV2 {
|
||||||
|
coin: string;
|
||||||
|
status: string;
|
||||||
|
toType: string;
|
||||||
|
toSymbol: string;
|
||||||
|
fromType: string;
|
||||||
|
fromSymbol: string;
|
||||||
|
size: string;
|
||||||
|
ts: string;
|
||||||
|
clientOid: string;
|
||||||
|
transferId: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotDepositAddressV2 {
|
||||||
|
address: string;
|
||||||
|
chain: string;
|
||||||
|
coin: string;
|
||||||
|
tag: string;
|
||||||
|
url: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotSubAccountDepositRecordV2 {
|
||||||
|
orderId: string;
|
||||||
|
tradeId: string;
|
||||||
|
coin: string;
|
||||||
|
size: string;
|
||||||
|
status: string;
|
||||||
|
toAddress: string;
|
||||||
|
dest: string;
|
||||||
|
chain: string;
|
||||||
|
fromAddress: string;
|
||||||
|
clientOid?: string;
|
||||||
|
confirm?: string;
|
||||||
|
tag?: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotWithdrawalRecordV2 {
|
||||||
|
orderId: string;
|
||||||
|
tradeId: string;
|
||||||
|
coin: string;
|
||||||
|
dest: string;
|
||||||
|
clientOid: string;
|
||||||
|
type: string;
|
||||||
|
tag: string;
|
||||||
|
size: string;
|
||||||
|
fee: string;
|
||||||
|
status: string;
|
||||||
|
toAddress: string;
|
||||||
|
fromAddress: string;
|
||||||
|
confirm: string;
|
||||||
|
chain: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SpotDepositRecordV2 {
|
||||||
|
orderId: string;
|
||||||
|
tradeId: string;
|
||||||
|
coin: string;
|
||||||
|
type: string;
|
||||||
|
size: string;
|
||||||
|
status: string;
|
||||||
|
toAddress: string;
|
||||||
|
dest: string;
|
||||||
|
chain: string;
|
||||||
|
fromAddress: string;
|
||||||
|
cTime: string;
|
||||||
|
uTime: string;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user