Holding
A position in a brokerage account. Get holdings returns an array of holdings.
Note
Optional fields are not returned by every brokerage. Valuation fields like market_price can be absent or null when unavailable. warning, when present, explains missing values.
Fields
Stable identifier for the position: the normalized symbol, or the compact OCC symbol for options.
Ticker, crypto pair, or brokerage-reported option symbol. For options, this can be the underlying ticker; use option_symbol to identify the contract.
Symbol to show users.
Shares, coins, or contracts held. Negative for a short position.
Brokerage-specific legacy value; may be per contract for options (including multiplier). Use average_unit_cost to compare with market_price.
Average cost per share, coin, or option share, before multiplier. Null when the brokerage does not report it.
Security name or brokerage description; may be a ticker or OCC option symbol.
Asset type: 2 for stocks and options, 4 for crypto.
0248Whether the position is long or short.
longshortWhether the position is an equity, crypto, or option.
equitycryptooptionThe option's OCC symbol as the brokerage reports it.
Shares each unit controls: 100 for standard options, 1 otherwise.
Opening cost basis. Can be a positive magnitude for short positions: abs(quantity) × average_unit_cost × multiplier. Brokerage sign conventions can vary.
Current price per share, coin, or option share. Null when no price is available.
quantity × market_price × multiplier.
Unrealized gain or loss, accounting for position side. When calculated from unit prices: (market_price − average_unit_cost) × quantity × multiplier.
unrealized_pnl as a percent of the absolute cost basis, such as 12.5 for 12.5%. Null when it cannot be calculated.
Where market_price came from. midpoint is the option bid/ask midpoint.
last_trademinute_closemidpointbrokerageunavailableISO 8601 timestamp for the price or brokerage holdings snapshot. Null when unavailable.
Whether market_price is delayed.
The option's underlying ticker.
Why a value is missing, such as Current price unavailable.
Balance
Money fields are Balance objects.
Amount in currency.
ISO 4217 currency code, such as USD.