Skip to main content

Cross-Margin Account Channel

Description

Request Example
{
"args":[
{
"channel":"account-crossed",
"coin":"default",
"instType":"MARGIN"
}
],
"op":"subscribe"
}

Request Parameters

ParameterTypeRequiredDescription
opStringYesOperation
subscribe Subscribe
unsubscribe Unsubscribe
argsList<Object>YesList of channels to request subscription
> instTypeStringYesProduct type: MARGIN
> channelStringYesChannel name: account-crossed
> coinStringYesCoin name,default represents all the coins,Only default is supported nows
Response Example
{
"event":"subscribe",
"arg":{
"instType":"MARGIN",
"channel":"account-crossed",
"coin":"default"
}
}

Response Parameters

ParameterTypeDescription
eventStringEvent
argObjectSubscribed channels
> instTypeStringProduct type: MARGIN
> channelString Channel name: account-crossed
> coinStringdefault
codeStringError code, returned only on error
msgStringError message
Push Data
{
"action":"snapshot",
"arg":{
"instType":"MARGIN",
"channel":"account-crossed",
"coin":"default"
},
"data":[
{
"uTime":"1695881380854",
"id":"1",
"coin":"USDT",
"available":"31092.45075078",
"borrow":"0.00000000",
"frozen":"6.00000000",
"interest":"0.00000000",
"coupon":"0.00000000"
},
{
"uTime":"1695881380854",
"id":"1",
"coin":"BTC",
"available":"0.00000000",
"borrow":"0.99990096",
"frozen":"0.00000000",
"interest":"0.00416626",
"coupon":"0.00000000"
}
],
"ts":1695881380856
}

Push Data Parameters

ParameterTypeDescription
argObjectSuccessful channel subscriptions
> instTypeStringProduct type: MARGIN
> channelStringChannel name: account-crossed
> coinStringProduct ID
actionStringPush data action, snapshot or update
dataList<Object>Subscribed data
> availableStringAvailable amount
> borrowStringRefund amount
> coinStringdefault
> frozenStringAmount frozen
> couponStringTrading bonus
> idStringNo.
> interestStringInterest
> uTimeStringUpdated

How was your Reading Experience with us?