/** * Position data model for the Kalshi JavaScript SDK. */ import { PositionData } from '../types'; export declare class Position { readonly ticker: string; readonly side: 'yes' | 'no'; readonly position: number; readonly marketValue: number; readonly totalCost: number; readonly unrealizedPnl: number; readonly realizedPnl: number; private readonly _rawData; constructor(data: PositionData); /** * Calculate the average cost per contract. */ get averageCost(): number; /** * Check if this is a long position. */ get isLong(): boolean; /** * Check if this is a short position. */ get isShort(): boolean; /** * Check if the position is currently profitable. */ get isProfitable(): boolean; /** * Get the total profit/loss (realized + unrealized). */ get totalPnl(): number; /** * Get the return percentage based on total cost. */ get returnPercentage(): number; /** * Get the raw data from the API response. */ get rawData(): PositionData; /** * Convert the Position instance to a plain object. */ toJSON(): Record; /** * String representation of the position. */ toString(): string; }