Margin Watch

Method Name

public/margin_watch

Calculates MtM and maintenance margin for a given subaccount.

Parameters

subaccount_id integer required
Subaccount ID to get margin for.

Response

id string or integer required
result object required
result.currency string required
Currency of subaccount
result.maintenance_margin string required
Total maintenance margin requirement of all positions and collaterals.If this value falls below zero, the subaccount will be flagged for liquidation.
result.margin_type string required
Margin type of subaccount (PM (Portfolio Margin) or SM (Standard Margin))
enum PM SM
result.subaccount_id integer required
Subaccount_id
result.subaccount_value string required
Total mark-to-market value of all positions and collaterals
result.valuation_timestamp integer required
Timestamp (in seconds since epoch) of when margin and MtM were computed.

Example

{request_example_shell}
{request_example_javascript}
{request_example_python}

The above command returns JSON structured like this:

{response_example_json}