get_eth_position

Documentation for eth_defi.lighter.api.get_eth_position function.

get_eth_position(account, market_index=0)

Read a signed ETH position size from a Lighter account response.

Parameters
  • account (Any) – Lighter detailed account model.

  • market_index (int) – Lighter market index.

Returns

Signed ETH position amount.

Return type

decimal.Decimal