{"openapi":"3.0.0","paths":{"/v1/prediction-markets/tokens":{"post":{"description":"Issues a short-lived JWT bound to the caller's wallet address for use on customer endpoints.","operationId":"CustomerAuthController_createToken","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTokenBody"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTokenResult"}}}}},"summary":"Create a customer JWT","tags":["Customer Auth"]}},"/v1/prediction-markets/contract-info":{"get":{"description":"Returns the chain IDs and contract addresses needed to construct on-chain transactions.","operationId":"CustomerContractInfoController_getContractInfo","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerContractInfo"}}}}},"summary":"Get on-chain contract info","tags":["Customer Contract Info"]}},"/v1/prediction-markets/partner-limits":{"get":{"description":"Returns the calling partner's aggregate trading limit and current usage.","operationId":"CustomerLimitController_getPartnerLimits","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerLimit"}}}}},"summary":"Get partner trading limits","tags":["Customer Limits"]}},"/v1/prediction-markets/user-limits":{"get":{"description":"Returns the authenticated user's aggregate trading limit and current usage.","operationId":"CustomerLimitController_getUserLimits","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerLimit"}}}}},"summary":"Get user trading limits","tags":["Customer Limits"]}},"/v1/prediction-markets/markets":{"get":{"description":"Paginated list of available prediction markets.","operationId":"CustomerMarketController_listMarkets","parameters":[{"name":"limit","required":false,"in":"query","description":"Maximum number of results to return (1-100)","schema":{"minimum":1,"maximum":100,"example":25,"type":"integer"}},{"name":"starting_after","required":false,"in":"query","description":"Cursor for forward pagination. Mutually exclusive with endingBefore.","schema":{"type":"string"}},{"name":"ending_before","required":false,"in":"query","description":"Cursor for backward pagination. Mutually exclusive with startingAfter.","schema":{"type":"string"}},{"name":"expand","required":false,"in":"query","description":"Comma-separated list of additional fields to include in the response. Allowed values: total_count, prices.","schema":{"type":"string"}},{"name":"sort","required":false,"in":"query","description":"Sort order for results. 'ticker_asc' sorts alphabetically, 'depth_desc' sorts by market depth (largest first).","schema":{"default":"ticker_asc","type":"string","enum":["ticker_asc","depth_desc"]}},{"name":"accepting_new_positions","required":false,"in":"query","description":"Filter for markets currently accepting new positions","schema":{"example":true,"type":"boolean"}},{"name":"category","required":false,"in":"query","description":"Filter markets by category","schema":{"type":"string","enum":["crypto","sport"]}},{"name":"provider","required":false,"in":"query","description":"Filter markets by prediction market provider","schema":{"type":"string","enum":["polymarket","kalshi"]}},{"name":"status","required":false,"in":"query","description":"Filter markets by status","schema":{"type":"string","enum":["active","closed","determined","finalized","disputed"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","required":["data","has_more"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomerMarket"}},"has_more":{"type":"boolean"},"total_count":{"type":"integer","description":"Total matching records. Present only when expand=total_count."}}}}}}},"summary":"List markets","tags":["Customer Markets"]}},"/v1/prediction-markets/markets/search":{"get":{"description":"Paginated free-text search across market tickers and titles.","operationId":"CustomerMarketController_searchMarkets","parameters":[{"name":"limit","required":false,"in":"query","description":"Maximum number of results to return (1-100)","schema":{"minimum":1,"maximum":100,"example":25,"type":"integer"}},{"name":"starting_after","required":false,"in":"query","description":"Cursor for forward pagination. Mutually exclusive with endingBefore.","schema":{"type":"string"}},{"name":"ending_before","required":false,"in":"query","description":"Cursor for backward pagination. Mutually exclusive with startingAfter.","schema":{"type":"string"}},{"name":"expand","required":false,"in":"query","description":"Comma-separated list of additional fields to include in the response. Allowed values: total_count, prices.","schema":{"type":"string"}},{"name":"sort","required":false,"in":"query","description":"Sort order for results. 'ticker_asc' sorts alphabetically, 'depth_desc' sorts by market depth (largest first).","schema":{"default":"ticker_asc","type":"string","enum":["ticker_asc","depth_desc"]}},{"name":"accepting_new_positions","required":false,"in":"query","description":"Filter for markets currently accepting new positions","schema":{"example":true,"type":"boolean"}},{"name":"category","required":false,"in":"query","description":"Filter markets by category","schema":{"type":"string","enum":["crypto","sport"]}},{"name":"provider","required":false,"in":"query","description":"Filter markets by prediction market provider","schema":{"type":"string","enum":["polymarket","kalshi"]}},{"name":"status","required":false,"in":"query","description":"Filter markets by status","schema":{"type":"string","enum":["active","closed","determined","finalized","disputed"]}},{"name":"query","required":true,"in":"query","description":"Free-text search query matched against market ticker and title","schema":{"minLength":1,"example":"trump","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","required":["data","has_more"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomerMarket"}},"has_more":{"type":"boolean"},"total_count":{"type":"integer","description":"Total matching records. Present only when expand=total_count."}}}}}}},"summary":"Search markets","tags":["Customer Markets"]}},"/v1/prediction-markets/markets/{ticker}":{"get":{"description":"Fetch a single market by its ticker identifier.","operationId":"CustomerMarketController_getMarketByTicker","parameters":[{"name":"ticker","required":true,"in":"path","description":"Market ticker identifier","schema":{"example":"TRUMP-2024-WIN","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerMarket"}}}}},"summary":"Get market by ticker","tags":["Customer Markets"]}},"/v1/prediction-markets/positions":{"get":{"description":"Paginated list of the authenticated customer's open and closed positions.","operationId":"CustomerPositionController_listPositions","parameters":[{"name":"limit","required":false,"in":"query","description":"Maximum number of results to return (1-100)","schema":{"minimum":1,"maximum":100,"example":25,"type":"integer"}},{"name":"starting_after","required":false,"in":"query","description":"Cursor for forward pagination. Mutually exclusive with endingBefore.","schema":{"type":"string"}},{"name":"ending_before","required":false,"in":"query","description":"Cursor for backward pagination. Mutually exclusive with startingAfter.","schema":{"type":"string"}},{"name":"expand","required":false,"in":"query","description":"Comma-separated list of additional fields to include in the response. Allowed values: unwinds, total_count.","schema":{"type":"string"}},{"name":"sort_by","required":false,"in":"query","description":"Field to sort positions by","schema":{"type":"string","enum":["created_at","closed_at"]}},{"name":"sort_direction","required":false,"in":"query","description":"Sort direction","schema":{"type":"string","enum":["asc","desc"]}},{"name":"status","required":false,"in":"query","description":"Filter positions by a single status. Mutually exclusive with `state`.","schema":{"type":"string","enum":["open","unwinding","pending","closing","closed","settled","liquidated"]}},{"name":"state","required":false,"in":"query","description":"Filter positions by lifecycle group: `active` (open + unwinding + pending + closing + settling) or `inactive` (closed + settled + liquidated + cancelled). Mutually exclusive with `status`.","schema":{"type":"string","enum":["active","inactive"]}},{"name":"ticker","required":false,"in":"query","description":"Filter positions by market ticker","schema":{"example":"TRUMP-2024-WIN","type":"string"}},{"name":"token_id","required":false,"in":"query","description":"Filter positions by on-chain position token id","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","required":["data","has_more"],"properties":{"data":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/CustomerOpenPosition"},{"$ref":"#/components/schemas/CustomerClosedPosition"}]}},"has_more":{"type":"boolean"},"total_count":{"type":"integer","description":"Total matching records. Present only when expand=total_count."}}}}}}},"summary":"List customer positions","tags":["Customer Positions"]}},"/v1/prediction-markets/offers":{"post":{"operationId":"CustomerOfferController_createOffer","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOfferBody"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}},"/v1/prediction-markets/draft-offers":{"post":{"operationId":"CustomerOfferController_createDraftOffer","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOfferBody"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}},"/v1/prediction-markets/quotes":{"post":{"operationId":"CustomerOfferController_createQuote","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOfferBody"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}},"/v1/prediction-markets/draft-quotes":{"post":{"operationId":"CustomerOfferController_createDraftQuote","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOfferBody"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}},"/v1/prediction-markets/positions/{position_id}":{"get":{"description":"Fetch a single position (open or closed) by its position ID.","operationId":"CustomerPositionController_getPositionById","parameters":[{"name":"position_id","required":true,"in":"path","description":"Position identifier","schema":{"example":"dm_pos_abc123","type":"string"}},{"name":"expand","required":false,"in":"query","description":"Comma-separated list of related sub-resources to embed inline in the response. Allowed values: unwinds.","schema":{"example":"unwinds","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/CustomerOpenPosition"},{"$ref":"#/components/schemas/CustomerClosedPosition"}]}}}}},"summary":"Get position by ID","tags":["Customer Positions"]}},"/v1/prediction-markets/positions/{position_id}/transactions":{"get":{"description":"Returns every on-chain transaction tied to a position, grouped by operation type, including the nested exchange (CLOB/DEX) fill hashes. Only transactions that landed and finalized on chain are returned.","operationId":"CustomerPositionTransactionsController_listPositionTransactions","parameters":[{"name":"position_id","required":true,"in":"path","description":"Position identifier","schema":{"example":"dm_pos_abc123","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PositionTransactions"}}}}},"summary":"List on-chain transactions for a position","tags":["Customer Position Transactions"]}},"/v1/prediction-markets/positions/{position_id}/unwinds":{"get":{"deprecated":true,"description":"Returns the executed unwind (deleveraging) history for a specific position, in chronological order. Deprecated — prefer `expand=unwinds` on `GET /positions` or `GET /positions/{id}` to fetch unwinds inline with the position(s) in a single request.","operationId":"CustomerPositionUnwindController_listPositionUnwinds","parameters":[{"name":"position_id","required":true,"in":"path","description":"Position identifier","schema":{"example":"dm_pos_abc123","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerPositionUnwindList"}}}}},"summary":"List position unwind history","tags":["Customer Position Unwinds"]}},"/v1/prediction-markets/promoted-quotes/{draft_offer_id}":{"post":{"operationId":"CustomerOfferController_createPromotedQuote","parameters":[{"name":"draft_offer_id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}},"/v1/prediction-markets/promoted-offers/{draft_offer_id}":{"post":{"operationId":"CustomerOfferController_createPromotedOffer","parameters":[{"name":"draft_offer_id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerOffer"}}}}},"tags":["Customer Offers"]}}},"info":{"title":"Dimes Customer API","description":"Dimes API for prediction markets","version":"1.0","contact":{}},"tags":[],"servers":[],"components":{"schemas":{"CreateTokenBody":{"type":"object","properties":{"wallet_address":{"type":"string","description":"Customer wallet address (Solana public key or EVM address)","example":"0x1234567890123456789012345678901234567890"}},"required":["wallet_address"]},"CreateTokenResult":{"type":"object","properties":{"token":{"type":"string","description":"JWT authentication token"},"expires_at":{"type":"string","description":"ISO 8601 timestamp when token expires","example":"2025-01-15T10:35:00.000Z"}},"required":["expires_at","token"]},"CustomerContractInfo":{"type":"object","properties":{"evm_chain_id":{"type":"string","description":"EVM chain ID","example":"137"},"polygon_signer_address":{"type":"string","description":"Checksummed address of the authorized offer signer on Polygon","example":"0x70997970C51812dc3A010C7d01b50e0d17dc79C8"},"polygon_vault_contract_address":{"type":"string","description":"Checksummed address of the vault contract on Polygon","example":"0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc"}},"required":["evm_chain_id","polygon_signer_address","polygon_vault_contract_address"]},"CustomerLimit":{"type":"object","properties":{"limit_usd":{"type":"string","description":"Total limit formatted as USD","example":"1000.00"},"limit_usd_pips":{"type":"string","description":"Total limit in USD pips (10000 pips = $1)","example":"10000000"},"remaining_usd":{"type":"string","description":"Remaining available limit formatted as USD","example":"750.00"},"remaining_usd_pips":{"type":"string","description":"Remaining available limit in USD pips","example":"7500000"},"usage_usd":{"type":"string","description":"Current usage formatted as USD","example":"250.00"},"usage_usd_pips":{"type":"string","description":"Current usage in USD pips","example":"2500000"}},"required":["limit_usd","limit_usd_pips","remaining_usd","remaining_usd_pips","usage_usd","usage_usd_pips"]},"CustomerOriginationTier":{"type":"object","properties":{"fee_bps":{"type":"number","description":"Origination fee in basis points for this tier","example":100},"max_leverage_bps":{"type":"number","description":"Maximum leverage in basis points for this tier","example":20000}},"required":["fee_bps","max_leverage_bps"]},"CustomerFees":{"type":"object","properties":{"lifetime_apr_bps":{"type":"number","description":"Lifetime fee APR in basis points","example":500},"liquidation_bps":{"type":"number","description":"Liquidation fee in basis points","example":200},"origination_tiers":{"description":"Origination fee tiers by leverage","type":"array","items":{"$ref":"#/components/schemas/CustomerOriginationTier"}}},"required":["lifetime_apr_bps","liquidation_bps","origination_tiers"]},"CustomerMaxMarketLeveragePerNotional":{"type":"object","properties":{"at100_usd_bps":{"type":"number","description":"Maximum market leverage in basis points when the position notional is $100","example":100000},"at500_usd_bps":{"type":"number","description":"Maximum market leverage in basis points when the position notional is $500","example":80000},"at1000_usd_bps":{"type":"number","description":"Maximum market leverage in basis points when the position notional is $1,000","example":60000},"at10000_usd_bps":{"type":"number","description":"Maximum market leverage in basis points when the position notional is $10,000","example":30000}},"required":["at100_usd_bps","at500_usd_bps","at1000_usd_bps","at10000_usd_bps"]},"CustomerSidedMaxMarketLeveragePerNotional":{"type":"object","properties":{"yes":{"description":"Per-notional max market leverage for the YES side","allOf":[{"$ref":"#/components/schemas/CustomerMaxMarketLeveragePerNotional"}]},"no":{"description":"Per-notional max market leverage for the NO side","allOf":[{"$ref":"#/components/schemas/CustomerMaxMarketLeveragePerNotional"}]}},"required":["yes","no"]},"CustomerLeverage":{"type":"object","properties":{"max_bps":{"type":"number","deprecated":true,"description":"Deprecated: use maxYesBps and maxNoBps. Populated as min(maxYesBps, maxNoBps) for backwards compatibility.","example":50000},"max_market_leverage_per_notional":{"description":"Max market leverage per side, broken out by position notional. Slippage grows with notional, so larger notionals have lower max leverage. The UI slider should publish the leverage that matches the user's selected notional.","allOf":[{"$ref":"#/components/schemas/CustomerSidedMaxMarketLeveragePerNotional"}]},"max_no_bps":{"type":"number","description":"Maximum leverage in basis points for the NO side","example":50000},"max_yes_bps":{"type":"number","description":"Maximum leverage in basis points for the YES side","example":50000},"min_bps":{"type":"number","description":"Minimum leverage in basis points","example":10000},"step_bps":{"type":"number","description":"Leverage step increment in basis points","example":1000}},"required":["max_bps","max_market_leverage_per_notional","max_no_bps","max_yes_bps","min_bps","step_bps"]},"CustomerSideEligibility":{"type":"object","properties":{"accepting_new_positions":{"type":"boolean","description":"Whether this market is accepting new positions on this side","example":true},"rejection_reason_code":{"type":"string","nullable":true,"description":"Reason code if this side is not accepting new positions; null when accepting","example":"QUOTE_MARKET_NOT_ELIGIBLE"}},"required":["accepting_new_positions"]},"CustomerSidedEligibility":{"type":"object","properties":{"yes":{"description":"Eligibility for the YES side","allOf":[{"$ref":"#/components/schemas/CustomerSideEligibility"}]},"no":{"description":"Eligibility for the NO side","allOf":[{"$ref":"#/components/schemas/CustomerSideEligibility"}]}},"required":["yes","no"]},"CustomerMarketPrices":{"type":"object","properties":{"no_ask_price_usd":{"type":"string","description":"NO side ask price formatted as USD","example":"0.51"},"no_ask_price_usd_pips":{"type":"string","description":"NO side ask price in USD pips (10000 pips = $1)","example":"5100"},"no_bid_price_usd":{"type":"string","description":"NO side bid price formatted as USD","example":"0.49"},"no_bid_price_usd_pips":{"type":"string","description":"NO side bid price in USD pips (10000 pips = $1)","example":"4900"},"yes_ask_price_usd":{"type":"string","description":"YES side ask price formatted as USD","example":"0.51"},"yes_ask_price_usd_pips":{"type":"string","description":"YES side ask price in USD pips (10000 pips = $1)","example":"5100"},"yes_bid_price_usd":{"type":"string","description":"YES side bid price formatted as USD","example":"0.49"},"yes_bid_price_usd_pips":{"type":"string","description":"YES side bid price in USD pips (10000 pips = $1)","example":"4900"}},"required":["no_ask_price_usd","no_ask_price_usd_pips","no_bid_price_usd","no_bid_price_usd_pips","yes_ask_price_usd","yes_ask_price_usd_pips","yes_bid_price_usd","yes_bid_price_usd_pips"]},"CustomerMarket":{"type":"object","properties":{"category":{"type":"string","description":"Market category","example":"politics"},"fees":{"description":"Fee configuration","allOf":[{"$ref":"#/components/schemas/CustomerFees"}]},"id":{"type":"string","description":"Market ID","example":"dm_mkt_abc123"},"leverage":{"description":"Leverage configuration","allOf":[{"$ref":"#/components/schemas/CustomerLeverage"}]},"provider":{"type":"string","enum":["kalshi","polymarket"],"description":"Prediction market provider"},"status":{"type":"string","enum":["active","amended","closed","determined","disputed","finalized","inactive","initialized"],"description":"Current market status"},"tags":{"description":"Market tags for filtering","example":["politics","election"],"type":"array","items":{"type":"string"}},"ticker":{"type":"string","description":"Market ticker sourced from the upstream trading venue (e.g. the Polymarket slug)","example":"will-trump-win-the-2024-election"},"title":{"type":"string","description":"Market title"},"prices":{"nullable":true,"description":"Latest bid/ask prices for YES and NO sides. Only present when the request includes `expand=prices`.","type":"object","allOf":[{"$ref":"#/components/schemas/CustomerMarketPrices"}]},"accepting_new_positions":{"type":"boolean","description":"Whether this market is accepting new positions","example":true},"close_time":{"type":"string","description":"ISO 8601 timestamp when market closes","example":"2025-01-20T12:00:00.000Z"},"latest_enter_at":{"type":"string","description":"ISO 8601 timestamp of the latest time a new position can be opened in this market","example":"2025-01-20T11:30:00.000Z"},"min_collateral_usd":{"type":"string","description":"Minimum collateral amount formatted as USD","example":"0.02"},"min_collateral_usd_pips":{"type":"string","description":"Minimum collateral amount in USD pips (10000 pips = $1)","example":"200000"},"min_notional_usd":{"type":"string","description":"Minimum notional amount formatted as USD","example":"5.00"},"min_notional_usd_pips":{"type":"string","description":"Minimum notional amount in USD pips (10000 pips = $1)","example":"50000"},"capacity_max_notional_no_usd":{"type":"string","nullable":true,"description":"Capacity-limited maximum notional for NO side formatted as USD","example":"50.00"},"capacity_max_notional_no_usd_pips":{"type":"string","nullable":true,"description":"Capacity-limited maximum notional for NO side in USD pips (10000 pips = $1)","example":"500000000"},"capacity_max_notional_yes_usd":{"type":"string","nullable":true,"description":"Capacity-limited maximum notional for YES side formatted as USD","example":"50.00"},"capacity_max_notional_yes_usd_pips":{"type":"string","nullable":true,"description":"Capacity-limited maximum notional for YES side in USD pips (10000 pips = $1)","example":"500000000"},"max_notional_no_usd":{"type":"string","description":"Maximum notional available for NO side formatted as USD","example":"50.00"},"max_notional_no_usd_pips":{"type":"string","description":"Maximum notional available for NO side in USD pips (10000 pips = $1)","example":"500000000"},"max_notional_yes_usd":{"type":"string","description":"Maximum notional available for YES side formatted as USD","example":"50.00"},"max_notional_yes_usd_pips":{"type":"string","description":"Maximum notional available for YES side in USD pips (10000 pips = $1)","example":"500000000"},"slippage_max_notional_no_usd":{"type":"string","nullable":true,"description":"Slippage-limited maximum notional for NO side formatted as USD","example":"50.00"},"slippage_max_notional_no_usd_pips":{"type":"string","nullable":true,"description":"Slippage-limited maximum notional for NO side in USD pips (10000 pips = $1)","example":"500000000"},"slippage_max_notional_yes_usd":{"type":"string","nullable":true,"description":"Slippage-limited maximum notional for YES side formatted as USD","example":"50.00"},"slippage_max_notional_yes_usd_pips":{"type":"string","nullable":true,"description":"Slippage-limited maximum notional for YES side in USD pips (10000 pips = $1)","example":"500000000"},"rejection_reason_code":{"type":"string","description":"Reason code if market is not accepting new positions","example":"QUOTE_MARKET_NOT_ELIGIBLE"},"sided_eligibility":{"description":"Per-side eligibility. A market may accept positions on one side while rejecting the other (e.g. thin opposite-side liquidity, side max-leverage below the floor).","allOf":[{"$ref":"#/components/schemas/CustomerSidedEligibility"}]},"yes_sub_title":{"type":"string","description":"Subtitle for the YES outcome"}},"required":["accepting_new_positions","category","fees","id","leverage","min_collateral_usd","min_collateral_usd_pips","min_notional_usd","min_notional_usd_pips","provider","status","tags","ticker","sided_eligibility"]},"CustomerPositionEntry":{"type":"object","properties":{"collateral_usd":{"type":"string","description":"Entry collateral formatted as USD","example":"2.50"},"collateral_usd_pips":{"type":"string","description":"Entry collateral in USD pips (10000 pips = $1)","example":"25000"},"leverage_bps":{"type":"number","description":"Entry leverage in basis points (20000 = 2x)","example":20000},"notional_usd":{"type":"string","description":"Entry notional formatted as USD","example":"5.00"},"notional_usd_pips":{"type":"string","description":"Entry notional in USD pips","example":"50000"},"open_latency_ms":{"type":"number","nullable":true,"description":"Time in milliseconds from position creation to on-chain open confirmation. Null until the position is fully opened on chain.","example":12500},"opened_at":{"type":"string","description":"ISO 8601 timestamp when position was opened","example":"2025-01-15T10:30:00.000Z"},"origination_fee_bps":{"type":"number","description":"Combined origination fee in basis points. `protocolOriginationFeeBps + partnerOriginationFeeBps === originationFeeBps`.","example":100},"protocol_origination_fee_bps":{"type":"number","description":"Protocol portion of the origination fee in basis points. `protocolOriginationFeeBps + partnerOriginationFeeBps === originationFeeBps`.","example":80},"partner_origination_fee_bps":{"type":"number","description":"Partner portion of the origination fee in basis points. `protocolOriginationFeeBps + partnerOriginationFeeBps === originationFeeBps`.","example":20},"origination_fee_usd":{"type":"string","description":"Origination fee formatted as USD","example":"0.05"},"origination_fee_usd_pips":{"type":"string","description":"Origination fee in USD pips","example":"500"},"price_usd":{"type":"string","description":"Entry price formatted as USD","example":"0.50"},"price_usd_pips":{"type":"string","description":"Entry price in USD pips","example":"5000"},"effective_entry_price_usd":{"type":"string","nullable":true,"description":"Effective entry price (actual fill price on the prediction market) formatted as USD. Null until the fill is recorded on chain.","example":"0.5025"},"effective_entry_price_usd_pips":{"type":"string","nullable":true,"description":"Effective entry price in USD pips. Null until the fill is recorded on chain.","example":"5025"},"effective_slippage_bps":{"type":"number","nullable":true,"description":"Execution slippage between the offer's indicative entry price and the actual fill price, in basis points. Signed: positive means the fill was worse than the quote, negative means the fill was better. Null until the fill is recorded on chain.","example":50}},"required":["collateral_usd","collateral_usd_pips","leverage_bps","notional_usd","notional_usd_pips","origination_fee_bps","protocol_origination_fee_bps","partner_origination_fee_bps","origination_fee_usd","origination_fee_usd_pips","price_usd","price_usd_pips"]},"CustomerPositionFailure":{"type":"object","properties":{"reason":{"type":"string","description":"Failure reason code","example":"price_exceeded_tolerance"}},"required":["reason"]},"CustomerPositionUnwind":{"type":"object","properties":{"after_leverage_bps":{"type":"number","description":"Leverage after unwind in basis points (20000 = 2x)","example":30000},"before_leverage_bps":{"type":"number","description":"Leverage before unwind in basis points (20000 = 2x)","example":60000},"executed_at":{"type":"string","description":"ISO 8601 timestamp when the unwind was executed on-chain","example":"2025-06-02T14:30:00.000Z"}},"required":["after_leverage_bps","before_leverage_bps","executed_at"]},"CustomerPositionUnwindList":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomerPositionUnwind"}},"has_more":{"type":"boolean"},"total_count":{"type":"number"},"current_leverage_bps":{"type":"number","nullable":true,"description":"Current leverage of the position in basis points (20000 = 2x), null if not yet calculated","example":30000},"originated_at":{"type":"string","nullable":true,"description":"ISO 8601 timestamp when the position was opened on-chain (null if not yet opened)","example":"2025-06-01T12:00:00.000Z"},"origination_leverage_bps":{"type":"number","description":"Leverage at position origination in basis points (20000 = 2x)","example":60000}},"required":["data","has_more","current_leverage_bps","originated_at","origination_leverage_bps"]},"CustomerPositionCurrent":{"type":"object","properties":{"book_leverage_bps":{"type":"number","description":"Current book-value leverage in basis points (20000 = 2x)","example":18000},"collateral_usd":{"type":"string","description":"Current collateral formatted as USD","example":"2.50"},"collateral_usd_pips":{"type":"string","description":"Current collateral in USD pips","example":"25000"},"effective_collateral_usd":{"type":"string","description":"Effective collateral formatted as USD","example":"2.45"},"effective_collateral_usd_pips":{"type":"string","description":"Effective collateral after fees in USD pips","example":"24500"},"leverage_bps":{"type":"number","description":"Current leverage in basis points","example":18000,"deprecated":true},"market_leverage_bps":{"type":"number","nullable":true,"description":"Current market-value leverage in basis points, computed from the live oracle price. Null when the position is insolvent (equity <= 0).","example":19500},"mark_price_usd":{"type":"string","description":"Current mark price formatted as USD","example":"0.55"},"mark_price_usd_pips":{"type":"string","description":"Current mark price in USD pips","example":"5500"},"net_unrealized_pnl_bps":{"type":"number","description":"Unrealized PnL net of all fees (origination + pending lifetime + accrued venue) as return on equity in basis points","example":1800},"net_unrealized_pnl_usd":{"type":"string","description":"Unrealized PnL net of all fees (origination + pending lifetime + accrued venue) formatted as USD","example":"0.45"},"net_unrealized_pnl_usd_pips":{"type":"string","description":"Unrealized PnL net of all fees (origination + pending lifetime + accrued venue) in USD pips (can be negative)","example":"4500"},"notional_usd":{"type":"string","description":"Current notional formatted as USD","example":"5.50"},"notional_usd_pips":{"type":"string","description":"Current notional in USD pips","example":"55000"},"position_token_units":{"type":"string","description":"Position token units held (1000000 units = 1 token)","example":"10000000"},"position_value_usd":{"type":"string","description":"Total position value formatted as USD","example":"3.00"},"position_value_usd_pips":{"type":"string","description":"Total position value in USD pips","example":"30000"},"unrealized_pnl_bps":{"type":"number","description":"Unrealized PnL as return on equity in basis points (1000 = 10%)","example":2000},"unrealized_pnl_usd":{"type":"string","description":"Unrealized PnL formatted as USD","example":"0.50"},"unrealized_pnl_usd_pips":{"type":"string","description":"Unrealized PnL in USD pips (can be negative)","example":"5000"}},"required":["book_leverage_bps","collateral_usd","collateral_usd_pips","effective_collateral_usd","effective_collateral_usd_pips","leverage_bps","mark_price_usd","mark_price_usd_pips","net_unrealized_pnl_bps","net_unrealized_pnl_usd","net_unrealized_pnl_usd_pips","notional_usd","notional_usd_pips","position_token_units","position_value_usd","position_value_usd_pips","unrealized_pnl_bps","unrealized_pnl_usd","unrealized_pnl_usd_pips"]},"CustomerPositionOpenFees":{"type":"object","properties":{"accrued_lifetime_fee_usd":{"type":"string","description":"Accrued lifetime fee formatted as USD","example":"0.01"},"accrued_lifetime_fee_usd_pips":{"type":"string","description":"Accrued lifetime fee in USD pips","example":"100"},"accrued_venue_fee_usd":{"type":"string","description":"Venue (Polymarket/Kalshi) trading fees paid so far on this position, summed across open and any force-unwind exchange transactions, formatted as USD.","example":"0.02"},"accrued_venue_fee_usd_pips":{"type":"string","description":"Venue trading fees paid so far on this position in USD pips.","example":"200"},"lifetime_apr_bps":{"type":"number","description":"Lifetime fee APR in basis points","example":500},"pending_lifetime_fee_usd":{"type":"string","description":"Pending lifetime fee formatted as USD","example":"0.005"},"pending_lifetime_fee_usd_pips":{"type":"string","description":"Pending lifetime fee in USD pips","example":"50"},"total_fees_usd":{"type":"string","description":"Sum of all fees accrued or owed so far (origination + accrued lifetime + pending lifetime + accrued venue), formatted as USD. Mirrors closed positions' `fees.totalFeesUsd`.","example":"0.085"},"total_fees_usd_pips":{"type":"string","description":"Sum of all fees accrued or owed so far (origination + accrued lifetime + pending lifetime + accrued venue) in USD pips.","example":"850"}},"required":["accrued_lifetime_fee_usd","accrued_lifetime_fee_usd_pips","accrued_venue_fee_usd","accrued_venue_fee_usd_pips","lifetime_apr_bps","pending_lifetime_fee_usd","pending_lifetime_fee_usd_pips","total_fees_usd","total_fees_usd_pips"]},"CustomerPositionRisk":{"type":"object","properties":{"current_liquidation_price_usd":{"type":"string","description":"Current liquidation price formatted as USD","example":"0.35"},"current_liquidation_price_usd_pips":{"type":"string","description":"Current liquidation price in USD pips","example":"3500"},"health_bps":{"type":"number","description":"Margin health 0-10000 (10000 at entry, 0 at liquidation)","example":7500},"liquidation_buffer_bps":{"type":"number","description":"Buffer to liquidation in basis points","example":500},"liquidation_fee_bps":{"type":"number","description":"Liquidation fee in basis points","example":200},"margin_buffer_usd":{"type":"string","description":"Dollar distance to liquidation formatted as USD","example":"0.50"},"margin_buffer_usd_pips":{"type":"string","description":"Dollar distance to liquidation in USD pips","example":"5000"}},"required":["current_liquidation_price_usd","current_liquidation_price_usd_pips","health_bps","liquidation_buffer_bps","liquidation_fee_bps","margin_buffer_usd","margin_buffer_usd_pips"]},"CustomerPositionTiming":{"type":"object","properties":{"is_settlement_pending":{"type":"boolean","description":"Whether settlement is pending (market resolved or voided, settlement not yet executed)"},"is_voided":{"type":"boolean","description":"Whether the market was voided (closed with no winner, 50/50 payout at $0.50 per token)"},"market_close_time":{"type":"string","description":"ISO 8601 timestamp when market closes","example":"2025-01-20T12:00:00.000Z"},"market_status":{"type":"string","enum":["active","amended","closed","determined","disputed","finalized","inactive","initialized"],"description":"Market status from the prediction market provider. When 'determined' or 'finalized', mark price reflects the settlement outcome ($1 or $0)","example":"active"},"time_to_close_minutes":{"type":"number","description":"Minutes until market closes","example":1440}},"required":["is_settlement_pending","is_voided","market_status"]},"CustomerOpenPosition":{"type":"object","properties":{"entry":{"description":"Entry details","allOf":[{"$ref":"#/components/schemas/CustomerPositionEntry"}]},"failure":{"description":"Failure details if the position failed","allOf":[{"$ref":"#/components/schemas/CustomerPositionFailure"}]},"id":{"type":"string","description":"Position ID","example":"dm_pos_abc123"},"provider":{"type":"string","enum":["kalshi","polymarket"],"description":"Prediction market provider"},"side":{"type":"string","enum":["yes","no"],"description":"Market side"},"status":{"type":"string","enum":["pending","open","unwinding","closing","settling","closed","settled","liquidated","cancelled"],"description":"Simplified position status"},"unwinds":{"nullable":true,"description":"Inline unwind history. Only present when the request includes `expand=unwinds`; omitted otherwise.","type":"object","allOf":[{"$ref":"#/components/schemas/CustomerPositionUnwindList"}]},"current":{"description":"Current position state","allOf":[{"$ref":"#/components/schemas/CustomerPositionCurrent"}]},"fees":{"description":"Fee details for open position","allOf":[{"$ref":"#/components/schemas/CustomerPositionOpenFees"}]},"risk":{"description":"Risk metrics","allOf":[{"$ref":"#/components/schemas/CustomerPositionRisk"}]},"timing":{"description":"Timing information","allOf":[{"$ref":"#/components/schemas/CustomerPositionTiming"}]},"effective_leverage_bps":{"type":"number","description":"Time-weighted average structural leverage in basis points over position lifetime (20000 = 2x)","example":84000},"market_ticker":{"type":"string","description":"Market ticker identifier","example":"TRUMP-2024-WIN"},"market_title":{"type":"string","description":"Market title"},"on_chain_position_key":{"type":"string","description":"On-chain position key (bytes32) for requestClose\", example: \"0xabc123..."},"wallet_address":{"type":"string","description":"Wallet address (Solana public key or EVM address)","example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU"}},"required":["effective_leverage_bps","entry","id","market_ticker","on_chain_position_key","provider","side","status","wallet_address","current","fees","risk","timing"]},"CustomerPositionClosedFees":{"type":"object","properties":{"lifetime_apr_bps":{"type":"number","description":"Lifetime fee APR in basis points","example":500},"origination_fee_bps":{"type":"number","deprecated":true,"description":"Deprecated — use `entry.originationFeeBps`. Same value, kept for backwards compatibility.","example":100},"protocol_origination_fee_bps":{"type":"number","deprecated":true,"description":"Deprecated — use `entry.protocolOriginationFeeBps`. Same value, kept for backwards compatibility.","example":80},"partner_origination_fee_bps":{"type":"number","deprecated":true,"description":"Deprecated — use `entry.partnerOriginationFeeBps`. Same value, kept for backwards compatibility.","example":20},"origination_fee_usd":{"type":"string","deprecated":true,"description":"Deprecated — use `entry.originationFeeUsd`. Same value, kept for backwards compatibility.","example":"0.05"},"origination_fee_usd_pips":{"type":"string","deprecated":true,"description":"Deprecated — use `entry.originationFeeUsdPips`. Same value, kept for backwards compatibility.","example":"500"},"total_fees_usd":{"type":"string","description":"Total blended fees formatted as USD","example":"0.085"},"total_fees_usd_pips":{"type":"string","description":"Total blended fees (origination + lifetime + liquidation + venue) in USD pips","example":"850"},"total_lifetime_fee_usd":{"type":"string","description":"Total lifetime fee formatted as USD","example":"0.015"},"total_lifetime_fee_usd_pips":{"type":"string","description":"Total lifetime fee collected in USD pips","example":"150"},"total_venue_fee_usd":{"type":"string","description":"Total venue (Polymarket/Kalshi) trading fees collected across the position lifetime (open + close/liquidation/settle + force-unwind), formatted as USD.","example":"0.02"},"total_venue_fee_usd_pips":{"type":"string","description":"Total venue trading fees collected across the position lifetime in USD pips.","example":"200"}},"required":["lifetime_apr_bps","origination_fee_bps","protocol_origination_fee_bps","partner_origination_fee_bps","origination_fee_usd","origination_fee_usd_pips","total_fees_usd","total_fees_usd_pips","total_lifetime_fee_usd","total_lifetime_fee_usd_pips","total_venue_fee_usd","total_venue_fee_usd_pips"]},"CustomerPositionResult":{"type":"object","properties":{"closed_at":{"type":"string","description":"ISO 8601 timestamp when position was closed","example":"2025-01-16T14:30:00.000Z"},"collected_lifetime_fee_usd":{"type":"string","description":"Collected lifetime fee formatted as USD","example":"0.015"},"collected_lifetime_fee_usd_pips":{"type":"string","description":"Collected lifetime fee in USD pips","example":"150"},"collected_liquidation_fee_usd":{"type":"string","description":"Collected liquidation fee formatted as USD","example":"0.00"},"collected_liquidation_fee_usd_pips":{"type":"string","description":"Collected liquidation fee in USD pips","example":"0"},"net_realized_pnl_bps":{"type":"number","description":"Realized PnL net of all fees (origination + lifetime + liquidation + venue) as return on equity in basis points","example":1700},"net_realized_pnl_usd":{"type":"string","description":"Realized PnL net of all fees (origination + lifetime + liquidation + venue) formatted as USD","example":"0.435"},"net_realized_pnl_usd_pips":{"type":"string","description":"Realized PnL net of all fees (origination + lifetime + liquidation + venue) in USD pips (can be negative)","example":"4350"},"proceeds_usd":{"type":"string","description":"Proceeds formatted as USD","example":"3.00"},"proceeds_usd_pips":{"type":"string","description":"Proceeds returned to user in USD pips","example":"30000"},"realized_pnl_usd":{"type":"string","description":"Realized PnL formatted as USD","example":"0.50"},"realized_pnl_usd_pips":{"type":"string","description":"Realized PnL in USD pips (can be negative)","example":"5000"}},"required":["closed_at","collected_lifetime_fee_usd","collected_lifetime_fee_usd_pips","collected_liquidation_fee_usd","collected_liquidation_fee_usd_pips","net_realized_pnl_bps","net_realized_pnl_usd","net_realized_pnl_usd_pips","proceeds_usd","proceeds_usd_pips","realized_pnl_usd","realized_pnl_usd_pips"]},"CustomerClosedPosition":{"type":"object","properties":{"entry":{"description":"Entry details","allOf":[{"$ref":"#/components/schemas/CustomerPositionEntry"}]},"failure":{"description":"Failure details if the position failed","allOf":[{"$ref":"#/components/schemas/CustomerPositionFailure"}]},"id":{"type":"string","description":"Position ID","example":"dm_pos_abc123"},"provider":{"type":"string","enum":["kalshi","polymarket"],"description":"Prediction market provider"},"side":{"type":"string","enum":["yes","no"],"description":"Market side"},"status":{"type":"string","enum":["pending","open","unwinding","closing","settling","closed","settled","liquidated","cancelled"],"description":"Simplified position status"},"unwinds":{"nullable":true,"description":"Inline unwind history. Only present when the request includes `expand=unwinds`; omitted otherwise.","type":"object","allOf":[{"$ref":"#/components/schemas/CustomerPositionUnwindList"}]},"fees":{"description":"Fee details for closed position","allOf":[{"$ref":"#/components/schemas/CustomerPositionClosedFees"}]},"result":{"description":"Position result/outcome","allOf":[{"$ref":"#/components/schemas/CustomerPositionResult"}]},"effective_leverage_bps":{"type":"number","description":"Time-weighted average structural leverage in basis points over position lifetime (20000 = 2x)","example":84000},"market_ticker":{"type":"string","description":"Market ticker identifier","example":"TRUMP-2024-WIN"},"market_title":{"type":"string","description":"Market title"},"on_chain_position_key":{"type":"string","description":"On-chain position key (bytes32) for requestClose\", example: \"0xabc123..."},"wallet_address":{"type":"string","description":"Wallet address (Solana public key or EVM address)","example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU"},"close_reason":{"type":"string","enum":["closed","liquidated","reverted","settled"],"description":"Reason the position was closed"}},"required":["effective_leverage_bps","entry","id","market_ticker","on_chain_position_key","provider","side","status","wallet_address","close_reason","fees","result"]},"PositionTransactionEntry":{"type":"object","properties":{"exchange_transaction_hashes":{"description":"On-chain hashes of the exchange (CLOB/DEX) fills nested under this transaction. Present only for transaction types that route through an exchange (open, close, liquidation, settle, force_unwind).","example":["0xddc31a8f7d2e4c0b9a1e5f3c8b6d4a2e0f9c7b5a3d1e8f6c4b2a0d9e7f5c3b1a"],"type":"array","items":{"type":"string"}},"transaction_hash":{"type":"string","description":"On-chain transaction hash (EVM transaction hash or Solana signature).","example":"0xffe5e3d042e9bf100fd01ad7a8d4de5d7fd20632df62e319d50275673e42e410"}},"required":["transaction_hash"]},"PositionTransactionGroup":{"type":"object","properties":{"transactions":{"description":"The on-chain transactions in this group, in execution order.","type":"array","items":{"$ref":"#/components/schemas/PositionTransactionEntry"}}},"required":["transactions"]},"PositionTransactions":{"type":"object","properties":{"cancel":{"description":"Transactions that cancelled the position before it opened.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"close":{"description":"Transactions that closed the position on chain, including the finalize-close transaction.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"liquidation":{"description":"Transactions that liquidated the position on chain, including the finalize-liquidation transaction.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"open":{"description":"Transactions that opened the position on chain, including the finalize-open transaction.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"redemption":{"description":"Transactions that redeemed settled position tokens on chain.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"revert":{"description":"Transactions that reverted a failed open back to the protocol.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"settle":{"description":"Transactions that settled the position on chain, including the finalize-settle transaction.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"cancel_request":{"description":"The close request transaction the position owner submitted on chain.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]},"force_unwind":{"description":"Transactions that force-unwound (deleveraged) the position on chain, including the finalize-unwind transaction.","allOf":[{"$ref":"#/components/schemas/PositionTransactionGroup"}]}},"required":["cancel","cancel_request","close","force_unwind","liquidation","open","redemption","revert","settle"]},"CreateOfferBody":{"type":"object","properties":{"leverage_bps":{"type":"number","minimum":15000,"maximum":100000,"description":"Leverage in basis points (20000 = 2x, 100000 = 10x). Must be divisible by 2500. Maximum 10x.","example":50000},"market_ticker":{"type":"string","description":"Market ticker","example":"TRUMP-2024-WIN"},"notional_amount_usd_pips":{"type":"string","description":"Notional amount in USD pips (10,000 pips = $1.00)","example":"50000"},"effective_side":{"type":"string","enum":["yes","no"],"description":"Market side (yes or no)"},"slippage_bps":{"type":"number","minimum":100,"maximum":1000,"description":"Maximum acceptable slippage in basis points (100 bps = 1%). Must be between 1% and 10%.","example":200},"pm_provider":{"type":"string","enum":["kalshi","polymarket"],"default":"kalshi","description":"Prediction market provider","example":"kalshi"}},"required":["leverage_bps","market_ticker","notional_amount_usd_pips","effective_side","slippage_bps"]},"CustomerOffer":{"type":"object","properties":{"id":{"type":"string","description":"Offer ID","example":"dm_off_abc123"},"provider":{"type":"string","enum":["kalshi","polymarket"],"description":"Prediction market provider"},"authority_public_key":{"type":"string","description":"Wallet address (Solana public key or EVM address)","example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU"},"current_liquidation_price_usd":{"type":"string","description":"Current liquidation price formatted as USD","example":"0.35"},"current_liquidation_price_usd_pips":{"type":"string","description":"Current liquidation price in USD pips (10000 pips = $1). Position will be liquidated if market price reaches this level.","example":"3500"},"entry_price_usd":{"type":"string","description":"Entry price on the offer's effective side, formatted as USD","example":"0.50"},"entry_price_usd_pips":{"type":"string","description":"Entry price on the offer's effective side, in USD pips (10000 pips = $1)","example":"5000"},"collateral_usdc_units":{"type":"string","description":"Collateral in USDC units (1,000,000 units = 1 USDC). Contract-ready value for createPosition.","example":"2500000"},"evm_chain_id":{"type":"string","description":"Chain ID for EVM signature","example":"137"},"polymarket_market_id":{"type":"string","description":"On-chain bytes32 Polymarket market identifier","example":"0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890"},"contract_signature":{"type":"string","description":"EIP-191 signature for contract create position"},"polymarket_token_id":{"type":"string","description":"Polymarket ERC1155 conditional token ID for the selected side","example":"52114319501245915516055106046884209969926127482827954674443846427813813222426"},"polygon_vault_contract_address":{"type":"string","description":"Vault contract address on Polygon","example":"0x1234567890123456789012345678901234567890"},"expected_open_trading_fee_usd":{"type":"string","description":"Expected trading fee formatted as USD","example":"0.02"},"expected_open_trading_fee_usd_pips":{"type":"string","description":"Expected trading fee in USD pips","example":"225"},"expected_open_trading_fee_usdc_units":{"type":"string","description":"Expected open trading fee in USDC units (1,000,000 units = 1 USDC). Contract-ready value.","example":"20000"},"expires_at":{"type":"string","description":"ISO 8601 timestamp when offer expires","example":"2025-01-15T10:35:00.000Z"},"leverage_bps":{"type":"number","description":"Leverage in basis points (20000 = 2x)","example":20000},"lifetime_fee_apr_bps":{"type":"number","description":"Lifetime fee APR in basis points","example":2000},"liquidation_fee_bps":{"type":"number","description":"Liquidation fee in basis points","example":250},"market_ticker":{"type":"string","description":"Market ticker identifier","example":"TRUMP-2024-WIN"},"min_expected_position_token_units":{"type":"string","description":"Minimum expected position tokens after accounting for slippage (1000000 units = 1 token)","example":"9900000"},"notional_amount_usd":{"type":"string","description":"Notional amount formatted as USD","example":"5.00"},"notional_amount_usd_pips":{"type":"string","description":"Notional amount in USD pips (10000 pips = $1)","example":"50000"},"notional_usdc_units":{"type":"string","description":"Notional amount in USDC units (1,000,000 units = 1 USDC). Contract-ready value for createPosition.","example":"5000000"},"origination_fee_bps":{"type":"number","description":"Origination fee in basis points","example":100},"origination_fee_usd":{"type":"string","description":"Origination fee formatted as USD","example":"0.05"},"origination_fee_usd_pips":{"type":"string","description":"Origination fee in USD pips","example":"500"},"origination_fee_usdc_units":{"type":"string","description":"Origination fee in USDC units (1,000,000 units = 1 USDC). Contract-ready value; on Polymarket the contract pulls collateral + originationFee from the user at createPosition.","example":"50000"},"protocol_origination_fee_bps":{"type":"number","description":"Protocol component of the origination fee in basis points. `protocolOriginationFeeBps + partnerOriginationFeeBps === originationFeeBps`.","example":100},"protocol_origination_fee_usd":{"type":"string","description":"Protocol component of the origination fee formatted as USD","example":"0.04"},"protocol_origination_fee_usd_pips":{"type":"string","description":"Protocol component of the origination fee in USD pips (10000 pips = $1)","example":"400"},"protocol_origination_fee_usdc_units":{"type":"string","description":"Protocol component of the origination fee in USDC units (1,000,000 units = 1 USDC).","example":"40000"},"partner_origination_fee_bps":{"type":"number","description":"Partner component of the origination fee in basis points. `protocolOriginationFeeBps + partnerOriginationFeeBps === originationFeeBps`.","example":25},"partner_origination_fee_usd":{"type":"string","description":"Partner component of the origination fee formatted as USD","example":"0.01"},"partner_origination_fee_usd_pips":{"type":"string","description":"Partner component of the origination fee in USD pips (10000 pips = $1)","example":"100"},"partner_origination_fee_usdc_units":{"type":"string","description":"Partner component of the origination fee in USDC units (1,000,000 units = 1 USDC).","example":"10000"},"polymarket_trading_fee_bps":{"type":"number","description":"Polymarket venue trading fee rate in basis points. Applied to expectedOpenTradingFeeUsdcUnits. `0` for Kalshi.","example":100},"partner_trading_fee_bps":{"type":"number","description":"Partner trading fee rate in basis points — the partner's Polymarket builder fee, a flat percentage of the traded notional included in expectedOpenTradingFeeUsdcUnits. `0` when the partner has no builder fee.","example":100},"partner_trading_fee_usd":{"type":"string","description":"Partner trading fee formatted as USD","example":"0.50"},"partner_trading_fee_usd_pips":{"type":"string","description":"Partner trading fee in USD pips (10000 pips = $1)","example":"5000"},"partner_trading_fee_usdc_units":{"type":"string","description":"Partner trading fee in USDC units (1,000,000 units = 1 USDC), included in expectedOpenTradingFeeUsdcUnits.","example":"500000"},"position_seed":{"type":"string","description":"Position seed for on-chain account derivation","example":"abc123"},"position_seed_hex":{"type":"string","description":"Position seed as 0x-prefixed bytes16 hex. Contract-ready value for createPosition.","example":"0xa1b2c3d4e5f67890abcdef1234567890"},"on_chain_position_key":{"type":"string","description":"On-chain position key (bytes32) that will be derived when the position is created. Matches on_chain_position_key on the position response — use it to link an offer to its future position.","example":"0x1a2b3c4d5e6f7890abcdef1234567890abcdef1234567890abcdef1234567890"},"effective_side":{"type":"string","enum":["yes","no"],"description":"Market side (yes or no)"},"signature_expiry":{"type":"string","description":"Unix timestamp when signature expires"},"slippage_bps":{"type":"number","description":"Slippage tolerance in basis points","example":200},"swap_transaction":{"type":"string","description":"Base64-encoded Solana transaction (present for Solana markets only)"},"total_user_amount_usd":{"type":"string","description":"Total amount user must provide formatted as USD","example":"2.73"},"total_user_amount_usd_pips":{"type":"string","description":"Total amount user must provide in USD pips","example":"27250"},"total_user_amount_usdc_units":{"type":"string","description":"Total amount user must transfer at createPosition in USDC units (1,000,000 units = 1 USDC). Contract-ready value. On Polymarket = collateral + originationFee; on Kalshi = collateral + tradingFee.","example":"2730000"}},"required":["authority_public_key","current_liquidation_price_usd","current_liquidation_price_usd_pips","entry_price_usd","entry_price_usd_pips","collateral_usdc_units","evm_chain_id","polymarket_market_id","contract_signature","polymarket_token_id","polygon_vault_contract_address","expected_open_trading_fee_usd","expected_open_trading_fee_usd_pips","expected_open_trading_fee_usdc_units","expires_at","id","leverage_bps","lifetime_fee_apr_bps","liquidation_fee_bps","market_ticker","min_expected_position_token_units","notional_amount_usd","notional_amount_usd_pips","notional_usdc_units","origination_fee_bps","origination_fee_usd","origination_fee_usd_pips","origination_fee_usdc_units","protocol_origination_fee_bps","protocol_origination_fee_usd","protocol_origination_fee_usd_pips","protocol_origination_fee_usdc_units","partner_origination_fee_bps","partner_origination_fee_usd","partner_origination_fee_usd_pips","partner_origination_fee_usdc_units","polymarket_trading_fee_bps","partner_trading_fee_bps","partner_trading_fee_usd","partner_trading_fee_usd_pips","partner_trading_fee_usdc_units","position_seed","position_seed_hex","on_chain_position_key","provider","effective_side","signature_expiry","slippage_bps","total_user_amount_usd","total_user_amount_usd_pips","total_user_amount_usdc_units"]}}}}