PerpsUserStateExtended
Extended perps user state with optional PnL, equity, margin, and liquidation fields.
Definition
type PerpsUserStateExtended = {
margin: string
vaultShares: string
unlocks: PerpsUnlock[]
reservedMargin: string
openOrderCount: number
equity: string | null
availableMargin: string | null
maintenanceMargin: string | null
positions: Record<string, PerpsPositionExtended>
}
type PerpsPositionExtended = PerpsPosition & {
unrealizedPnl: string | null
unrealizedFunding: string | null
liquidationPrice: string | null
}Notes
- Each
* | nullfield is populated only when the matchinginclude*flag was set in the query. SeegetPerpsUserStateExtended.
See also
PerpsUserState— non-extendedgetPerpsUserStateExtended