-
Notifications
You must be signed in to change notification settings - Fork 43
/
Copy pathmodel_cross_margin_account.go
46 lines (44 loc) · 2.31 KB
/
model_cross_margin_account.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
* Gate API v4
*
* Welcome to Gate.io API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user's behalf.
*
* Contact: support@mail.gate.io
* Generated by: OpenAPI Generator (https://openapi-generator.tech)
*/
package gateapi
type CrossMarginAccount struct {
// User ID
UserId int64 `json:"user_id,omitempty"`
// Time of the most recent refresh
RefreshTime int64 `json:"refresh_time,omitempty"`
// Whether account is locked
Locked bool `json:"locked,omitempty"`
Balances map[string]CrossMarginBalance `json:"balances,omitempty"`
// Total account value in USDT, i.e., the sum of all currencies' `(available+freeze)*price*discount`
Total string `json:"total,omitempty"`
// Total borrowed value in USDT, i.e., the sum of all currencies' `borrowed*price*discount`
Borrowed string `json:"borrowed,omitempty"`
// Total unpaid interests in USDT, i.e., the sum of all currencies' `interest*price*discount`
Interest string `json:"interest,omitempty"`
// Risk rate. When it belows 110%, liquidation will be triggered. Calculation formula: `total / (borrowed+interest)`
Risk string `json:"risk,omitempty"`
// Total initial margin
TotalInitialMargin string `json:"total_initial_margin,omitempty"`
// Total Margin Balance (∑(positive equity * index price * discount) + ∑(negative equity * index price))
TotalMarginBalance string `json:"total_margin_balance,omitempty"`
// Total maintenance margin
TotalMaintenanceMargin string `json:"total_maintenance_margin,omitempty"`
// Total initial margin rate
TotalInitialMarginRate string `json:"total_initial_margin_rate,omitempty"`
// Total maintenance margin rate
TotalMaintenanceMarginRate string `json:"total_maintenance_margin_rate,omitempty"`
// Total available margin
TotalAvailableMargin string `json:"total_available_margin,omitempty"`
// Total amount of the portfolio margin account
PortfolioMarginTotal string `json:"portfolio_margin_total,omitempty"`
// Total liabilities of the portfolio margin account
PortfolioMarginTotalLiab string `json:"portfolio_margin_total_liab,omitempty"`
// Total equity of the portfolio margin account
PortfolioMarginTotalEquity string `json:"portfolio_margin_total_equity,omitempty"`
}