Message: AccountSummaryStatus

File: WebAPI/trade_routing_2.proto

Description

Account summary status. An update is sent once it is changed. Updates might be consolidated in case of frequent changes. Only changed account summary values are included into updates. When a calculation error occurs for a field, it is sent in ‘failed_fields’ and also in ‘cleared_fields’ for backward compatibility. Some fields may be valid but empty and not contained in snapshot message including ‘failed_fields’, ‘cleared_fields’. For example, ‘min_days_till_position_contract_expiration’ if there are no open positions on the account.

Request: TradeSubscription.

Used in

ServerMsg

Fields

subscription_ids

Type: uint32

Description: List of trade subscription IDs this status is related to.

is_snapshot

Type: bool

Description: True if this is a snapshot related message. Since snapshot might be sent in several messages (including none), client should use TradeSnapshotCompletion message as an indicator of complete snapshot delivery for all accounts of particular subscription. To speed up processing, the client can use the ‘is_snapshot’ field to determine when each account’s AccountSummaryStatus snapshot is complete and the data on the corresponding account is usable. This field isn’t sent after account authorization, in that case the first message contains as many fields as available.

account_id

Type: sint32

Description: Account ID of this status.

Required: yes.

currency

Type: string

Description: Currency code of account values.

Required: in snapshot and included into updates only if changed.

cleared_fields

Type: uint32

Description: Identifiers of fields being cleared. E.g. to clear ‘total_margin’ server will include value 6 into the collection. ‘cleared_fields’ contains identifiers of both failed fields and previously failed fields that are valid but empty for now (see AccountSummaryStatus description).

failed_fields

Type: uint32

Description: Identifiers of fields failed to calculate. E.g. if ‘net_change_pc’ calculation failed server will include value 26 into the collection. If the field is failed and it was in ‘failed_fields’ in the previous status too, it won’t be sent again.

deleted

Type: bool

Description: Flag used for updates and indicating that the account summary has been deleted for the account and the subscriptions (see subscription_ids). It can be set when the trader is no longer authorized for the account or the account does no longer meet filtering criteria of the subscriptions (see AccountSummaryParameters.account_filter).

Note: Client can later receive an AccountSummaryStatus for the account and the subscriptions again with this field reset once the trader is authorized on the account or a filtering criteria is met again.

total_margin

Type: double

Description: Margin requirement calculated for worst-case based on open positions and working orders.

position_margin

Type: double

Description: Margin requirement based on current positions only, with margin multiplier applied. Use no_multiplier_position_margin field to get raw value.

no_multiplier_position_margin

Type: double

Description: Margin requirement without multipliers based on current positions only.

purchasing_power

Type: double

Description: Available account funds including balance, realized profit (or loss), collateral and credits. OTE and MVO are included regarding the account risk parameters. For a group account, purchasing power is a recent snapshot calculated by the server. It uses data from all accounts in the group, so it will not be synchronized with values reported for only this account. Also, for group accounts, OTE and MVO components of purchasing power will not be synchronized with market data updates. See trading_account_2.Account.is_group_member.

ote

Type: double

Description: Open trade equity, or potential profit (or loss) from futures and future-style options positions based on opening price of the position and the current future trade/best bid/best ask (regarding to the risk account settings) or first available from: settlement price, yesterday settlement price, yesterday close price, day before yesterday settlement price, day before yesterday close price if trade is not available.

mvo

Type: double

Description: Market value of options calculated as the current market trade/best bid/best ask of the option (regarding to the risk account settings) times the number of options (positive for long options and negative for short options) in the portfolio. If trade/best bid/best ask must be used for calculations but is not available, then used first available from: settlement price, yesterday settlement price, yesterday close price, day before yesterday settlement price, day before yesterday close price.

mvf

Type: double

Description: Market value of futures calculated as the current market trade/best bid/best ask (regarding to the risk account settings) times the number of futures (positive for long and negative for short) in the portfolio. If trade/best bid/best ask must be used for calculations but is not available, then used first available from: settlement price, yesterday settlement price, yesterday close price, day before yesterday settlement price, day before yesterday close price.

margin_credit

Type: double

Description: Allowable margin credit of the account.

cash_excess

Type: double

Description: Cash Excess.

current_balance

Type: double

Description: Current account balance. In particular includes: yesterday balance, profit/loss, option premium, commission and Forex instrument positions.

profit_loss

Type: double

Description: Realized profit/loss.

unrealized_profit_loss

Type: double

Description: Unrealized profit/loss for options.

yesterday_balance

Type: double

Description: Cash balance from the last statement.

yesterday_net_liquidation_value

Type: double

Description: NLV (cash balance + collateral + OTE + MVO) from the last statement.

yesterday_ote

Type: double

Description: Open trade equity for futures and futures-style options from the last statement.

yesterday_mvo

Type: double

Description: Market value of premium-style options and fixed income from the last statement.

yesterday_collateral

Type: double

Description: Collateral on deposit.

net_change_pc

Type: double

Description: (profit_loss / abs(yesterday_balance)) in percentage.

net_liquidation_value_pc

Type: double

Description: (profit_loss / yesterday_net_liquidation_value) in percentage.

total_filled_qty

Type: cqg.Decimal

Description: Sum of all fill sizes for the current day.

total_filled_orders

Type: uint32

Description: Count of the filled orders for the current day.

total_parked_orders

Type: uint32

Description: Count of parked orders on the account.

Note: Strategy orders and their child orders are counted, except for child orders of algo strategies.

total_working_orders

Type: uint32

Description: Count of working orders on the account.

Note: Strategy orders and their child orders are counted, except for child orders of algo strategies.

long_open_positions_qty

Type: cqg.Decimal

Description: Sum of position quantities among all long open positions on the account.

short_open_positions_qty

Type: cqg.Decimal

Description: Sum of position quantities among all short open positions on the account.

min_days_till_position_contract_expiration

Type: uint32

Description: Minimal number of days until contract expiration among all open positions on expiring contracts in the account.

For each position, the time to expiration is measured in 24-hour intervals from the contract’s last_trading_date, using a server-defined cutoff time within that date. This field is the minimal value across all such positions. Not set if there are no open positions on the account.

purchasing_power_limit

Type: double

Description: Limit of the maximum value of purchasing power for the account. Can be empty e.g., when the account is a group account member. See trading_account_2.Account.is_group_member.

option_premium

Type: double

Description: Option premium for open positions with statement_date later than the account last_statement_date.

yesterday_oldest_margin_call_age_days

Type: uint32

Description: Age (in days) of the oldest outstanding margin call from the last statement.

yesterday_total_outstanding_margin_calls

Type: double

Description: Total outstanding margin calls in the account from the last statement.