{"components":{"parameters":{},"schemas":{"ActivityCursor":{"additionalProperties":false,"properties":{"eventId":{"format":"uuid","type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"seq":{"minimum":0,"type":"integer"},"time":{"type":"number"}},"required":["time","marketId","seq","eventId"],"type":["object","null"]},"ActivityItem":{"additionalProperties":false,"properties":{"cashDelta":{"description":"Signed uq wallet delta: `−gross` on a buy, `+gross` on a sell, and a flat `0` on a swap, which moves no quote atom through the wallet at all — the from-side gross never left a vault.","maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":["string","null"]},"commitment":{"description":"Commitment the event was ingested at. Always `confirmed`: the cursor poller is the only writer of an event row, and ADR 0020 lowered it from `finalized` so a trade reaches the screen in about a second. A trailing reconcile deletes rows the canonical chain does not name.","enum":["confirmed"],"type":"string"},"createdAt":{"format":"date-time","type":"string"},"creatorFee":{"description":"uq the creator's share of the program's fee, which is charged once on every direction, a swap included. Null for non-money activity.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"gross":{"description":"uq the trade moved: `charged` on a buy, `payout` on a sell, and on a swap `payout` again — the from-side gross drop, which is how a swap is measured in every volume fold. Null for non-money activity.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"id":{"format":"uuid","type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"operation":{"$ref":"#/components/schemas/ActivityOperation"},"outerIndex":{"description":"Index of the outer instruction within the transaction.","minimum":0,"type":["integer","null"]},"position":{"description":"Index of the event within that instruction.","minimum":0,"type":["integer","null"]},"price":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"Effective fill price, `gross / tokens`: uq per token atom, the same denomination as `MarketSummary.prices`. Null when the trade has no single fill — a swap fills on both sides over two different denominators, so neither is *the* price — or no token count at all. Never a stand-in zero."},"principalId":{"maxLength":128,"minLength":1,"type":["string","null"]},"protocolFee":{"description":"uq the protocol's residual share of that same fee. Null for non-money activity.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"seq":{"minimum":0,"type":"integer"},"side":{"anyOf":[{"enum":[0],"type":"number"},{"enum":[1],"type":"number"},{"type":"null"}]},"signature":{"description":"Base58 transaction signature this event was emitted by. Null only on a row whose ingest key cannot be read.","maxLength":128,"minLength":1,"type":["string","null"]},"time":{"type":"number"},"tokens":{"description":"Token atoms executed, straight off the stored engine event: minted on a buy, burnt on a sell, and on a swap minted on the side OPPOSITE `side` — never the atoms the swap burnt. Null for non-money activity.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"type":{"maxLength":64,"minLength":1,"type":"string"}},"required":["id","marketId","seq","type","time","createdAt","signature","outerIndex","position","commitment","principalId","operation","side","gross","creatorFee","protocolFee","cashDelta","tokens","price"],"type":"object"},"ActivityOperation":{"anyOf":[{"enum":["buy","sell","swap","fund","fee_collected","market_created"],"type":"string"},{"type":"null"},{"type":"null"}]},"ActivityPage":{"additionalProperties":false,"properties":{"items":{"items":{"$ref":"#/components/schemas/ActivityItem"},"type":"array"},"nextBefore":{"$ref":"#/components/schemas/ActivityCursor"}},"required":["items","nextBefore"],"type":"object"},"AddBackofficeAssetBody":{"additionalProperties":false,"properties":{"canDeposit":{"type":"boolean"},"canQuoteMarkets":{"type":"boolean"},"category":{"$ref":"#/components/schemas/AssetCategory"},"gate":{"type":"boolean"},"logoMediaId":{"maxLength":64,"minLength":1,"type":["string","null"]},"mint":{"maxLength":64,"minLength":1,"type":"string"},"name":{"maxLength":128,"minLength":1,"type":"string"},"pinned":{"type":"boolean"},"rateSource":{"$ref":"#/components/schemas/BackofficeAssetRateSource"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":16,"minLength":1,"type":"string"}},"required":["mint","symbol","name","category","logoMediaId","sortOrder","pinned","rateSource","canDeposit","canQuoteMarkets","gate"],"type":"object"},"AddBackofficeGateMintBody":{"additionalProperties":false,"properties":{"mint":{"maxLength":64,"minLength":1,"type":"string"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":16,"minLength":1,"type":"string"}},"required":["mint","symbol","sortOrder"],"type":"object"},"Asset":{"additionalProperties":false,"properties":{"canDeposit":{"type":"boolean"},"canQuoteMarkets":{"type":"boolean"},"category":{"$ref":"#/components/schemas/AssetCategory"},"logoUrl":{"description":"The catalogue's own logo; `null` until one is attached.","type":["string","null"]},"mint":{"maxLength":64,"minLength":32,"type":"string"},"name":{"maxLength":128,"minLength":1,"type":"string"},"pinned":{"type":"boolean"},"rate":{"$ref":"#/components/schemas/AssetRate"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":32,"minLength":1,"type":"string"}},"required":["mint","symbol","name","category","logoUrl","pinned","sortOrder","canDeposit","canQuoteMarkets","rate"],"type":"object"},"AssetCategory":{"enum":["sol","usdc","stock","prestock","coin"],"type":"string"},"AssetRate":{"additionalProperties":false,"description":"The latest USD reading, or `null` where none has been observed — unknown, never zero.","properties":{"ageMs":{"description":"How old the reading was when it was served. A display surface prints the figure and says how old it is; a charge refuses instead.","minimum":0,"type":"integer"},"observedAt":{"format":"date-time","type":"string"},"source":{"enum":["jupiter","twin","fixed","operator"],"type":"string"},"usdPerAtom":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"US dollars per RAW UNIT of the mint — per atom, never per whole token, because no decimals field travels with it."}]}},"required":["usdPerAtom","observedAt","ageMs","source"],"type":["object","null"]},"AssetsResponse":{"additionalProperties":false,"properties":{"assets":{"items":{"$ref":"#/components/schemas/Asset"},"type":"array"}},"required":["assets"],"type":"object"},"BackofficeActorLeaders":{"additionalProperties":false,"properties":{"bestPnlAbs":{"allOf":[{"$ref":"#/components/schemas/BackofficeActorRow"},{"type":["object","null"]}]},"bestPnlPercent":{"allOf":[{"$ref":"#/components/schemas/BackofficeActorRow"},{"type":["object","null"]}]},"biggestStake":{"allOf":[{"$ref":"#/components/schemas/BackofficeActorRow"},{"type":["object","null"]}]},"topVolume":{"allOf":[{"$ref":"#/components/schemas/BackofficeActorRow"},{"type":["object","null"]}]}},"required":["topVolume","bestPnlAbs","bestPnlPercent","biggestStake"],"type":"object"},"BackofficeActorRow":{"additionalProperties":false,"properties":{"actorUsername":{"type":["string","null"]},"holdings":{"$ref":"#/components/schemas/SupplyPair"},"investedUq":{"description":"Cumulative gross of this actor's buys, in uq. A swap adds nothing: it moves no quote through the wallet.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"kind":{"minLength":1,"type":"string"},"lastTradeTime":{"description":"Most recent trade engine time in seconds, or null.","type":["number","null"]},"markUq":{"description":"floor(markOf(state, principal)) in uq at read time.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"pnlPercent":{"$ref":"#/components/schemas/NullableSignedRatJson"},"positionSide":{"allOf":[{"$ref":"#/components/schemas/SideIndex"},{"anyOf":[{"enum":[0],"type":"number"},{"enum":[1],"type":"number"},{"type":"null"}],"description":"Larger-holdings side, 0 on a tie, null when flat (exited)."}]},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"realizedPnlUq":{"maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":"string"},"stake":{"$ref":"#/components/schemas/BackofficeActorStake"},"totalPnlUq":{"maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":"string"},"tradeCount":{"minimum":0,"type":"integer"},"unrealizedPnlUq":{"maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":"string"},"volumeUq":{"description":"Exact uq sum of trade gross for this actor.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["principalId","actorUsername","kind","volumeUq","tradeCount","lastTradeTime","holdings","positionSide","realizedPnlUq","unrealizedPnlUq","totalPnlUq","investedUq","pnlPercent","markUq","stake"],"type":"object"},"BackofficeActorStake":{"additionalProperties":false,"properties":{"ratio":{"$ref":"#/components/schemas/RatJson"},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["side","ratio"],"type":["object","null"]},"BackofficeAdminAudit":{"additionalProperties":false,"properties":{"nextCursor":{"type":["string","null"]},"rows":{"items":{"$ref":"#/components/schemas/BackofficeAdminAuditRow"},"type":"array"}},"required":["rows","nextCursor"],"type":"object"},"BackofficeAdminAuditRow":{"additionalProperties":false,"properties":{"actorPrincipalId":{"allOf":[{"$ref":"#/components/schemas/PrincipalId"},{"type":["string","null"]}]},"actorRole":{"enum":["user","operator","admin"],"type":["string","null"]},"actorUsername":{"type":["string","null"]},"at":{"format":"date-time","type":"string"},"detail":{"additionalProperties":{},"type":"object"},"event":{"minLength":1,"type":"string"},"id":{"format":"uuid","type":"string"},"reason":{"type":["string","null"]},"subjectId":{"minLength":1,"type":"string"},"subjectType":{"minLength":1,"type":"string"}},"required":["id","at","event","actorPrincipalId","actorRole","actorUsername","subjectType","subjectId","reason","detail"],"type":"object"},"BackofficeAdminGrantedBy":{"additionalProperties":false,"properties":{"actorPrincipalId":{"allOf":[{"$ref":"#/components/schemas/PrincipalId"},{"type":["string","null"]}]},"actorUsername":{"type":["string","null"]},"at":{"format":"date-time","type":"string"},"bootstrap":{"type":"boolean"}},"required":["actorPrincipalId","actorUsername","at","bootstrap"],"type":["object","null"]},"BackofficeAdminParameter":{"additionalProperties":false,"properties":{"defaultValue":{"anyOf":[{"type":"boolean"},{"type":"integer"}]},"id":{"minLength":1,"type":"string"},"isDefault":{"type":"boolean"},"kind":{"enum":["boolean","integer"],"type":"string"},"max":{"type":"integer"},"min":{"type":"integer"},"updatedAt":{"format":"date-time","type":["string","null"]},"updatedBy":{"allOf":[{"$ref":"#/components/schemas/PrincipalId"},{"type":["string","null"]}]},"value":{"anyOf":[{"type":"boolean"},{"type":"integer"}]}},"required":["id","kind","value","defaultValue","isDefault","updatedAt","updatedBy"],"type":"object"},"BackofficeAdminParameters":{"additionalProperties":false,"properties":{"parameters":{"items":{"$ref":"#/components/schemas/BackofficeAdminParameter"},"type":"array"}},"required":["parameters"],"type":"object"},"BackofficeAdminPrincipal":{"additionalProperties":false,"properties":{"address":{"type":["string","null"]},"grantedBy":{"$ref":"#/components/schemas/BackofficeAdminGrantedBy"},"lastActiveAt":{"format":"date-time","type":["string","null"]},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"role":{"enum":["user","operator","admin"],"type":"string"},"username":{"type":["string","null"]}},"required":["principalId","username","address","role","lastActiveAt","grantedBy"],"type":"object"},"BackofficeAdminPrincipals":{"additionalProperties":false,"properties":{"adminCount":{"minimum":0,"type":"integer"},"principals":{"items":{"$ref":"#/components/schemas/BackofficeAdminPrincipal"},"type":"array"},"truncated":{"type":"boolean"}},"required":["principals","adminCount","truncated"],"type":"object"},"BackofficeAnalytics":{"additionalProperties":false,"properties":{"byAsset":{"items":{"$ref":"#/components/schemas/BackofficeAnalyticsAsset"},"type":"array"},"day":{"pattern":"^\\d{4}-\\d{2}-\\d{2}$","type":"string"},"users":{"additionalProperties":false,"properties":{"active3d":{"description":"Accounts one of whose wallets traded in the trailing 3 × 24 h.","minimum":0,"type":"integer"},"joinedToday":{"minimum":0,"type":"integer"},"total":{"minimum":0,"type":"integer"}},"required":["total","active3d","joinedToday"],"type":"object"}},"required":["day","byAsset","users"],"type":"object"},"BackofficeAnalyticsAsset":{"additionalProperties":false,"properties":{"beneficiaryClaims":{"allOf":[{"$ref":"#/components/schemas/BackofficeAnalyticsWindows"},{"description":"What beneficiaries claimed, by the claim's block time."}]},"creatorFees":{"$ref":"#/components/schemas/BackofficeAnalyticsWindows"},"decimals":{"minimum":0,"type":"integer"},"protocolFees":{"$ref":"#/components/schemas/BackofficeAnalyticsWindows"},"quoteMint":{"minLength":1,"type":"string"},"symbol":{"type":["string","null"]},"volume":{"allOf":[{"$ref":"#/components/schemas/BackofficeAnalyticsWindows"},{"description":"Gross quote volume: a buy's `charged`, a sell's or swap's `payout`."}]}},"required":["quoteMint","symbol","decimals","protocolFees","creatorFees","beneficiaryClaims","volume"],"type":"object"},"BackofficeAnalyticsWindows":{"additionalProperties":false,"description":"The protocol's slice of every trade fee: `fee − feeCreator − feeBeneficiary`.","properties":{"month":{"description":"Over the trailing 30 × 24 h.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"today":{"description":"Since 00:00 UTC today.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"total":{"description":"Over every ingested row.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"week":{"description":"Over the trailing 7 × 24 h.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["today","week","month","total"],"type":"object"},"BackofficeAsset":{"additionalProperties":false,"properties":{"addedAt":{"format":"date-time","type":"string"},"addedBy":{"$ref":"#/components/schemas/PrincipalId"},"canDeposit":{"type":"boolean"},"canQuoteMarkets":{"type":"boolean"},"category":{"$ref":"#/components/schemas/AssetCategory"},"gate":{"type":"boolean"},"logoMediaId":{"type":["string","null"]},"logoUrl":{"type":["string","null"]},"mint":{"maxLength":44,"minLength":32,"type":"string"},"name":{"maxLength":128,"minLength":1,"type":"string"},"pinned":{"type":"boolean"},"rate":{"additionalProperties":false,"description":"The last reading, or null where nothing has priced it.","properties":{"ageMs":{"minimum":0,"type":"integer"},"observedAt":{"format":"date-time","type":"string"},"source":{"enum":["jupiter","twin","fixed","operator"],"type":"string"},"stale":{"description":"Older than the display bound: printed as old, never as an error.","type":"boolean"},"usdPerAtom":{"$ref":"#/components/schemas/RatJson"}},"required":["usdPerAtom","observedAt","ageMs","source","stale"],"type":["object","null"]},"rateSource":{"$ref":"#/components/schemas/BackofficeAssetRateSource"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":12,"minLength":1,"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"$ref":"#/components/schemas/PrincipalId"}},"required":["mint","symbol","name","category","logoMediaId","logoUrl","sortOrder","pinned","rateSource","canDeposit","canQuoteMarkets","gate","addedAt","addedBy","updatedAt","updatedBy","rate"],"type":"object"},"BackofficeAssetChain":{"additionalProperties":false,"properties":{"epoch":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"facts":{"items":{"$ref":"#/components/schemas/BackofficeAssetChainFacts"},"type":"array"},"state":{"enum":["read","unread"],"type":"string"},"unreadReason":{"enum":["not_configured","unreachable"],"type":["string","null"]}},"required":["state","unreadReason","epoch","facts"],"type":"object"},"BackofficeAssetChainFacts":{"additionalProperties":false,"properties":{"collector":{"additionalProperties":false,"properties":{"account":{"type":"string"},"exists":{"type":"boolean"}},"required":["account","exists"],"type":["object","null"]},"drift":{"additionalProperties":false,"properties":{"beyond":{"description":"Strictly beyond 20 %: `5·|num−den| > den`.","type":"boolean"},"ratio":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"`driftRatio(listed, rate)`, unreduced: rate ÷ listed."}]}},"required":["ratio","beyond"],"type":["object","null"]},"epoch":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"listing":{"additionalProperties":false,"properties":{"listedUsdPerAtom":{"$ref":"#/components/schemas/RatJson"},"openingSizeAtoms":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"p0":{"$ref":"#/components/schemas/RatJson"},"quantum":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["quantum","p0","openingSizeAtoms","listedUsdPerAtom"],"type":["object","null"]},"metadata":{"additionalProperties":false,"description":"The name and ticker a Token-2022 mint carries itself — the issuer's text, offered for an operator to approve.","properties":{"name":{"type":"string"},"symbol":{"type":"string"}},"required":["name","symbol"],"type":["object","null"]},"mint":{"maxLength":44,"minLength":32,"type":"string"},"openingSizeUsdNow":{"$ref":"#/components/schemas/NullableRatJson"},"quoteBlocker":{"enum":["not_listed","refused","collector_account_missing"],"type":["string","null"]},"refusal":{"enum":["non_transferable","hook_program_set","default_state_not_initialized","paused","unknown_extension"],"type":["string","null"]},"token":{"additionalProperties":false,"properties":{"decimals":{"maximum":255,"minimum":0,"type":"integer"},"extensions":{"items":{"additionalProperties":false,"properties":{"name":{"type":["string","null"]},"type":{"minimum":0,"type":"integer"}},"required":["type","name"],"type":"object"},"type":["array","null"]},"tokenProgram":{"type":"string"}},"required":["tokenProgram","decimals","extensions"],"type":["object","null"]},"transferFee":{"additionalProperties":false,"properties":{"epoch":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"now":{"additionalProperties":false,"properties":{"basisPoints":{"maximum":10000,"minimum":0,"type":"integer"},"maximumFee":{"description":"The cap per transfer, in the mint's own atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["basisPoints","maximumFee"],"type":"object"},"scheduled":{"additionalProperties":false,"properties":{"basisPoints":{"maximum":10000,"minimum":0,"type":"integer"},"epoch":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"maximumFee":{"description":"The cap per transfer, in the mint's own atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["basisPoints","maximumFee","epoch"],"type":["object","null"]}},"required":["epoch","now","scheduled"],"type":["object","null"]},"verdict":{"enum":["listed","not_listed","refused"],"type":"string"}},"required":["mint","epoch","token","metadata","transferFee","verdict","refusal","listing","collector","drift","openingSizeUsdNow","quoteBlocker"],"type":"object"},"BackofficeAssetRateSource":{"oneOf":[{"additionalProperties":false,"properties":{"kind":{"enum":["own"],"type":"string"}},"required":["kind"],"type":"object"},{"additionalProperties":false,"properties":{"kind":{"enum":["none"],"type":"string"}},"required":["kind"],"type":"object"},{"additionalProperties":false,"properties":{"kind":{"enum":["twin"],"type":"string"},"twinMint":{"maxLength":44,"minLength":32,"type":"string"}},"required":["kind","twinMint"],"type":"object"},{"additionalProperties":false,"properties":{"kind":{"enum":["fixed"],"type":"string"},"usdPerAtom":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"US dollars per atom, exact — never per whole token."}]}},"required":["kind","usdPerAtom"],"type":"object"}]},"BackofficeAssets":{"additionalProperties":false,"properties":{"assets":{"items":{"$ref":"#/components/schemas/BackofficeAsset"},"type":"array"}},"required":["assets"],"type":"object"},"BackofficeCapability":{"enum":["markets","creators","tags","assets","gate","admin"],"type":"string"},"BackofficeConsensusPoint":{"additionalProperties":false,"properties":{"consensusRatio":{"type":"number"},"time":{"type":"number"}},"required":["time","consensusRatio"],"type":"object"},"BackofficeContext":{"additionalProperties":false,"properties":{"capabilities":{"items":{"$ref":"#/components/schemas/BackofficeCapability"},"type":"array"},"environment":{"$ref":"#/components/schemas/BackofficeEnvironment"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"role":{"enum":["user","operator","admin"],"type":"string"},"username":{"type":["string","null"]}},"required":["principalId","username","role","environment","capabilities"],"type":"object"},"BackofficeCreatorRow":{"additionalProperties":false,"properties":{"claimedAllTime":{"description":"All-time claimed, quote-mint atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"creator":{"description":"On-chain creator address.","maxLength":64,"minLength":32,"type":"string"},"lastClaimAt":{"format":"date-time","type":["string","null"]},"marketsCreated":{"minimum":0,"type":"integer"},"owed":{"description":"Gross minus claimed, quote-mint atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["creator","marketsCreated","owed","claimedAllTime","lastClaimAt"],"type":"object"},"BackofficeCreatorTotals":{"additionalProperties":false,"properties":{"claimedAllTime":{"description":"All-time claimed in the body's asset, its atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"creatorCount":{"description":"Creators with earnings in the body's asset.","minimum":0,"type":"integer"},"measuredMarkets":{"description":"Measured markets quoted in the body's asset.","minimum":0,"type":"integer"},"outstanding":{"description":"Outstanding (gross − claimed) in the body's asset, its atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"unmeasurableMarkets":{"description":"Venue-wide: markets whose log names no creator or no asset, which belong to no asset's figures.","minimum":0,"type":"integer"}},"required":["claimedAllTime","outstanding","measuredMarkets","unmeasurableMarkets","creatorCount"],"type":"object"},"BackofficeCreators":{"additionalProperties":false,"properties":{"decimals":{"description":"`quoteMint`'s decimals, which every amount here is counted in; `null` where no earnings are counted in that asset.","maximum":18,"minimum":0,"type":["integer","null"]},"items":{"items":{"$ref":"#/components/schemas/BackofficeCreatorRow"},"type":"array"},"nextCursor":{"type":["string","null"]},"quoteMint":{"description":"The asset `items` and `totals` are counted in: the query's, else the busiest one, else `null` on a venue with no earnings at all.","type":["string","null"]},"sort":{"$ref":"#/components/schemas/BackofficeCreatorsSort"},"totals":{"$ref":"#/components/schemas/BackofficeCreatorTotals"}},"required":["quoteMint","decimals","items","nextCursor","sort","totals"],"type":"object"},"BackofficeCreatorsSort":{"enum":["owed","claimedAllTime","marketsCreated","lastClaimAt"],"type":"string"},"BackofficeEnvironment":{"enum":["production","development"],"type":"string"},"BackofficeFeeMargin":{"additionalProperties":false,"properties":{"collectedAtoms":{"description":"What actually arrived: the payment on a clean finalize, zero on a revert and zero while in flight. Summed from what each row records as collected, never from what it was charged.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"day":{"pattern":"^\\d{4}-\\d{2}-\\d{2}$","type":"string"},"ratio":{"type":["number","null"]},"spentAtoms":{"description":"The quote-denominated cost of every submission the treasury signed today, at the price each charge itself used. The CONSERVATIVE side: it counts a submission that was signed and never broadcast, whose cost never left the wallet.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["day","spentAtoms","collectedAtoms","ratio"],"type":"object"},"BackofficeGate":{"additionalProperties":false,"properties":{"armed":{"type":"boolean"},"effectiveArmed":{"type":"boolean"},"mints":{"items":{"$ref":"#/components/schemas/BackofficeGateMint"},"type":"array"},"override":{"additionalProperties":false,"properties":{"active":{"type":"boolean"},"value":{"type":["string","null"]},"variable":{"minLength":1,"type":"string"}},"required":["variable","value","active"],"type":"object"}},"required":["armed","effectiveArmed","override","mints"],"type":"object"},"BackofficeGateMint":{"additionalProperties":false,"properties":{"addedAt":{"format":"date-time","type":"string"},"addedBy":{"$ref":"#/components/schemas/PrincipalId"},"mint":{"maxLength":44,"minLength":32,"type":"string"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":12,"minLength":1,"type":"string"}},"required":["mint","symbol","sortOrder","addedAt","addedBy"],"type":"object"},"BackofficeGatePass":{"additionalProperties":false,"properties":{"admittedInviteCampaign":{"type":["string","null"]},"admittedInviteCodeId":{"format":"uuid","type":["string","null"]},"admittedMint":{"type":["string","null"]},"admittedSymbol":{"type":["string","null"]},"admittingAddress":{"type":["string","null"]},"at":{"format":"date-time","type":"string"},"door":{"enum":["token","invite","manual","before"],"type":"string"},"grantedBy":{"additionalProperties":false,"properties":{"actorPrincipalId":{"maxLength":128,"minLength":1,"type":["string","null"]},"actorUsername":{"type":["string","null"]},"at":{"format":"date-time","type":"string"},"reason":{"type":["string","null"]}},"required":["actorPrincipalId","actorUsername","reason","at"],"type":["object","null"]},"kind":{"enum":["account","unclaimed-grant"],"type":"string"},"passId":{"format":"uuid","type":["string","null"]},"passState":{"enum":["live","revoked","expired","none"],"type":"string"},"principalId":{"maxLength":128,"minLength":1,"type":["string","null"]},"releasedAddress":{"type":["string","null"]},"releasedAt":{"format":"date-time","type":["string","null"]},"rowId":{"format":"uuid","type":"string"},"username":{"type":["string","null"]}},"required":["kind","rowId","principalId","username","door","admittedMint","admittedSymbol","admittedInviteCodeId","admittedInviteCampaign","at","passId","passState","admittingAddress","releasedAddress","releasedAt","grantedBy"],"type":"object"},"BackofficeGatePassTotals":{"additionalProperties":false,"properties":{"accounts":{"minimum":0,"type":"integer"},"beforeTheDoor":{"minimum":0,"type":"integer"},"throughTheDoor":{"minimum":0,"type":"integer"},"unclaimedPasses":{"minimum":0,"type":"integer"}},"required":["accounts","throughTheDoor","beforeTheDoor","unclaimedPasses"],"type":"object"},"BackofficeGatePasses":{"additionalProperties":false,"properties":{"nextCursor":{"type":["string","null"]},"rows":{"items":{"$ref":"#/components/schemas/BackofficeGatePass"},"type":"array"},"totals":{"$ref":"#/components/schemas/BackofficeGatePassTotals"}},"required":["rows","nextCursor","totals"],"type":"object"},"BackofficeHealth":{"additionalProperties":false,"properties":{"checkedAt":{"format":"date-time","type":"string"},"divergences":{"items":{"$ref":"#/components/schemas/BackofficeHealthDivergence"},"type":"array"},"indexer":{"$ref":"#/components/schemas/BackofficeHealthIndexer"},"queues":{"items":{"$ref":"#/components/schemas/BackofficeHealthQueue"},"type":"array"}},"required":["checkedAt","indexer","queues","divergences"],"type":"object"},"BackofficeHealthDivergence":{"additionalProperties":false,"properties":{"at":{"format":"date-time","type":"string"},"field":{"minLength":1,"type":["string","null"]},"id":{"format":"uuid","type":"string"},"marketAddress":{"minLength":1,"type":["string","null"]},"marketId":{"minLength":1,"type":"string"}},"required":["id","at","marketId","marketAddress","field"],"type":"object"},"BackofficeHealthIndexer":{"additionalProperties":false,"properties":{"data":{"minLength":1,"type":"string"},"state":{"enum":["never","fresh","quiet","slowing","stale"],"type":"string"},"worker":{"minLength":1,"type":"string"}},"required":["state","data","worker"],"type":"object"},"BackofficeHealthQueue":{"additionalProperties":false,"properties":{"pending":{"minimum":0,"type":["integer","null"]},"queue":{"minLength":1,"type":"string"}},"required":["queue","pending"],"type":"object"},"BackofficeInviteCampaign":{"additionalProperties":false,"properties":{"campaign":{"type":["string","null"]},"issuedAt":{"format":"date-time","type":"string"},"live":{"minimum":0,"type":"integer"},"revoked":{"minimum":0,"type":"integer"},"used":{"minimum":0,"type":"integer"}},"required":["campaign","live","used","revoked","issuedAt"],"type":"object"},"BackofficeInviteCampaigns":{"additionalProperties":false,"properties":{"campaigns":{"items":{"$ref":"#/components/schemas/BackofficeInviteCampaign"},"type":"array"}},"required":["campaigns"],"type":"object"},"BackofficeInviteCode":{"additionalProperties":false,"properties":{"campaign":{"type":["string","null"]},"code":{"minLength":1,"type":["string","null"]},"consumedAt":{"format":"date-time","type":["string","null"]},"id":{"format":"uuid","type":"string"},"issuedAt":{"format":"date-time","type":"string"},"issuedBy":{"minLength":1,"type":"string"},"revokedAt":{"format":"date-time","type":["string","null"]}},"required":["id","code","campaign","issuedAt","issuedBy","revokedAt","consumedAt"],"type":"object"},"BackofficeInviteSummary":{"additionalProperties":false,"properties":{"live":{"minimum":0,"type":"integer"},"revoked":{"minimum":0,"type":"integer"},"used":{"minimum":0,"type":"integer"}},"required":["live","used","revoked"],"type":"object"},"BackofficeInvites":{"additionalProperties":false,"properties":{"nextCursor":{"type":["string","null"]},"rows":{"items":{"$ref":"#/components/schemas/BackofficeInviteCode"},"type":"array"},"summary":{"$ref":"#/components/schemas/BackofficeInviteSummary"}},"required":["rows","nextCursor","summary"],"type":"object"},"BackofficeMainnetTokens":{"additionalProperties":false,"properties":{"tokens":{"items":{"additionalProperties":false,"properties":{"decimals":{"maximum":255,"minimum":0,"type":["integer","null"]},"icon":{"type":["string","null"]},"known":{"type":"boolean"},"mint":{"type":"string"},"name":{"type":"string"},"symbol":{"type":"string"},"usdPrice":{"description":"Per displayed unit, as Jupiter quotes it; shown, never converted.","exclusiveMinimum":0,"type":["number","null"]},"verified":{"type":"boolean"}},"required":["mint","symbol","name","icon","decimals","usdPrice","verified","known"],"type":"object"},"type":"array"},"unsearched":{"enum":["not_configured","rate_limited","unreachable"],"type":["string","null"]}},"required":["unsearched","tokens"],"type":"object"},"BackofficeMarketActors":{"additionalProperties":false,"properties":{"asOfTime":{"type":"number"},"leaders":{"$ref":"#/components/schemas/BackofficeActorLeaders"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"rows":{"items":{"$ref":"#/components/schemas/BackofficeActorRow"},"type":"array"},"totalCount":{"description":"Actors matching the kind filter (before limit).","minimum":0,"type":"integer"}},"required":["rows","leaders","totalCount","projectionStatus","asOfTime"],"type":"object"},"BackofficeMarketAsset":{"additionalProperties":false,"description":"The market's quote asset; null where the row does not name one.","properties":{"decimals":{"maximum":18,"minimum":0,"type":"integer"},"mint":{"maxLength":64,"minLength":32,"type":"string"},"symbol":{"maxLength":32,"minLength":1,"type":"string"}},"required":["mint","symbol","decimals"],"type":["object","null"]},"BackofficeMarketAssetStats":{"additionalProperties":false,"properties":{"decimals":{"maximum":18,"minimum":0,"type":"integer"},"feesAccruedAtoms":{"description":"Exact sum of uncollected fee-ledger balances, in atoms of `quoteMint`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"quoteMint":{"maxLength":64,"minLength":32,"type":"string"},"symbol":{"maxLength":32,"minLength":1,"type":"string"},"volume24hAtoms":{"description":"Exact sum of trade gross in the trailing 24h engine window, in atoms of `quoteMint`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["quoteMint","symbol","decimals","volume24hAtoms","feesAccruedAtoms"],"type":"object"},"BackofficeMarketDetail":{"additionalProperties":false,"properties":{"info":{"$ref":"#/components/schemas/BackofficeMarketInfo"},"market":{"$ref":"#/components/schemas/BackofficeMarketRow"},"series":{"$ref":"#/components/schemas/BackofficeMarketSeries"}},"required":["market","info","series"],"type":"object"},"BackofficeMarketInfo":{"additionalProperties":false,"properties":{"asOfTime":{"description":"Engine seconds used as the relative-age origin.","type":"number"},"asset":{"$ref":"#/components/schemas/BackofficeMarketAsset"},"chainBeneficiaryAddress":{"description":"The market's on-chain beneficiary — the subject's pre-provisioned wallet (ADR-0040). `null` where no subject is bound.","maxLength":64,"minLength":32,"type":["string","null"]},"createdAt":{"description":"Wall-clock market creation time.","format":"date-time","type":"string"},"creatorId":{"$ref":"#/components/schemas/PrincipalId"},"creatorUsername":{"type":["string","null"]},"feesAccruedUq":{"description":"Exact uq sum of uncollected fee-ledger balances.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"feesCollectedUq":{"description":"Exact uq sum of fee_collected envelope amounts.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"holderCount":{"minimum":0,"type":"integer"},"poolTvl":{"$ref":"#/components/schemas/RatJson"},"socialUserId":{"description":"The subject's id at its provider. `null` until a lookup resolved one.","maxLength":128,"minLength":1,"type":["string","null"]},"taggerLlmCalls":{"description":"OpenRouter HTTP attempts the tagger made for this market, including fallbacks and failures. Cache hits and the stub do not count.","minimum":0,"type":"integer"},"type":{"$ref":"#/components/schemas/BackofficeMarketType"},"volume24hUq":{"description":"Exact uq sum of trade gross in the trailing 24h engine window.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"volumeTotalUq":{"description":"Exact uq sum of trade gross over the whole event stream.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["type","asset","poolTvl","volume24hUq","volumeTotalUq","holderCount","feesAccruedUq","feesCollectedUq","creatorId","creatorUsername","chainBeneficiaryAddress","socialUserId","createdAt","asOfTime","taggerLlmCalls"],"type":"object"},"BackofficeMarketList":{"additionalProperties":false,"properties":{"markets":{"items":{"$ref":"#/components/schemas/BackofficeMarketRow"},"type":"array"},"stats":{"$ref":"#/components/schemas/BackofficeMarketStats"}},"required":["markets","stats"],"type":"object"},"BackofficeMarketModerationResult":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"moderatedBy":{"allOf":[{"$ref":"#/components/schemas/PrincipalId"},{"type":["string","null"]}]},"reason":{"type":["string","null"]},"status":{"$ref":"#/components/schemas/BackofficeModerationStatus"},"updatedAt":{"format":"date-time","type":["string","null"]}},"required":["marketId","status","reason","updatedAt","moderatedBy"],"type":"object"},"BackofficeMarketRow":{"additionalProperties":false,"properties":{"asset":{"$ref":"#/components/schemas/BackofficeMarketAsset"},"consensusYes":{"$ref":"#/components/schemas/RatJson"},"createdAt":{"format":"date-time","type":"string"},"creatorId":{"$ref":"#/components/schemas/PrincipalId"},"creatorUsername":{"type":["string","null"]},"hiddenFromDiscovery":{"type":"boolean"},"id":{"$ref":"#/components/schemas/MarketId"},"imageUrl":{"type":["string","null"]},"lastActivityTime":{"description":"Most recent event engine time in seconds, or null.","type":["number","null"]},"lastSeq":{"minimum":0,"type":"integer"},"moderationStatus":{"$ref":"#/components/schemas/BackofficeModerationStatus"},"prices":{"prefixItems":[{"$ref":"#/components/schemas/RatJson"},{"$ref":"#/components/schemas/RatJson"}],"type":"array"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"question":{"maxLength":512,"minLength":1,"type":"string"},"sideLabels":{"$ref":"#/components/schemas/SideLabels"},"social":{"allOf":[{"$ref":"#/components/schemas/MarketSocial"},{"description":"Privileged subject social link; public DTOs keep their own."}]},"spamFlag":{"description":"Privileged shadowban flag; absent from public market DTOs.","type":"boolean"},"supply":{"$ref":"#/components/schemas/SupplyPair"},"tags":{"items":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"type":"array"},"tradeCount24h":{"description":"Trades in the trailing 24h engine window.","minimum":0,"type":"integer"},"tradingPaused":{"type":"boolean"},"tvl":{"$ref":"#/components/schemas/RatJson"},"type":{"$ref":"#/components/schemas/BackofficeMarketType"},"volume24hUq":{"description":"Exact uq sum of trade gross in the trailing 24h engine window.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["id","question","sideLabels","creatorId","creatorUsername","imageUrl","tags","createdAt","type","moderationStatus","hiddenFromDiscovery","tradingPaused","prices","consensusYes","tvl","supply","volume24hUq","tradeCount24h","lastActivityTime","lastSeq","projectionStatus","spamFlag","social","asset"],"type":"object"},"BackofficeMarketSeries":{"additionalProperties":false,"properties":{"candles":{"items":{"$ref":"#/components/schemas/BackofficePriceCandle"},"type":"array"},"consensusPoints":{"items":{"$ref":"#/components/schemas/BackofficeConsensusPoint"},"type":"array"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"}},"required":["candles","consensusPoints","projectionStatus"],"type":"object"},"BackofficeMarketStats":{"additionalProperties":false,"properties":{"asOfTime":{"description":"Engine seconds used as the 24h volume window endpoint.","type":"number"},"byAsset":{"description":"The unfiltered world's figures per quote asset. Atoms of different assets never add; a total across them is dollars at a rate.","items":{"$ref":"#/components/schemas/BackofficeMarketAssetStats"},"type":"array"},"hiddenCount":{"minimum":0,"type":"integer"},"marketCount":{"minimum":0,"type":"integer"},"marketsCreated24h":{"description":"Wall-clock count of markets whose created_at falls in the trailing 24h.","minimum":0,"type":"integer"}},"required":["marketCount","marketsCreated24h","hiddenCount","byAsset","asOfTime"],"type":"object"},"BackofficeMarketTape":{"additionalProperties":false,"properties":{"asOfTime":{"type":"number"},"rows":{"items":{"$ref":"#/components/schemas/BackofficeTapeRow"},"type":"array"},"totalCount":{"description":"Trades matching the active filter (before limit).","minimum":0,"type":"integer"}},"required":["rows","totalCount","asOfTime"],"type":"object"},"BackofficeMarketType":{"enum":["public","simulation_only"],"type":"string"},"BackofficeModerationStatus":{"enum":["active","paused","hidden","removed"],"type":"string"},"BackofficePriceCandle":{"additionalProperties":false,"properties":{"bucketStart":{"type":"number"},"close":{"type":"number"},"high":{"type":"number"},"low":{"type":"number"},"open":{"type":"number"},"volume":{"type":"number"}},"required":["bucketStart","open","high","low","close","volume"],"type":"object"},"BackofficeSubmission":{"additionalProperties":false,"properties":{"createdAt":{"format":"date-time","type":"string"},"finalizedAt":{"format":"date-time","type":["string","null"]},"kind":{"$ref":"#/components/schemas/ChainSubmissionKind"},"principalId":{"maxLength":128,"minLength":1,"type":"string"},"quoteCostAtoms":{"description":"What the treasury spent on this submission, in quote atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"signature":{"type":["string","null"]},"status":{"$ref":"#/components/schemas/ChainSubmissionStatus"},"submissionId":{"format":"uuid","type":"string"},"username":{"type":["string","null"]},"withdraw":{"additionalProperties":false,"properties":{"amountAtoms":{"description":"What the recipient gets, in the asset's own units.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"asset":{"enum":["sol","token"],"type":"string"},"decimals":{"maximum":18,"minimum":0,"type":"integer"},"mint":{"description":"The delivered token's mint; null for SOL.","type":["string","null"]},"recipient":{"type":"string"},"symbol":{"description":"The quote ticker, `SOL`, or null for any other token.","type":["string","null"]}},"required":["asset","mint","symbol","recipient","amountAtoms","decimals"],"type":["object","null"]}},"required":["submissionId","kind","status","principalId","username","createdAt","finalizedAt","signature","quoteCostAtoms","withdraw"],"type":"object"},"BackofficeSubmissions":{"additionalProperties":false,"properties":{"items":{"items":{"$ref":"#/components/schemas/BackofficeSubmission"},"type":"array"},"nextCursor":{"type":["string","null"]}},"required":["items","nextCursor"],"type":"object"},"BackofficeTagCatalogResponse":{"additionalProperties":false,"properties":{"tags":{"items":{"$ref":"#/components/schemas/TagCatalogAdminEntry"},"type":"array"}},"required":["tags"],"type":"object"},"BackofficeTapeRow":{"additionalProperties":false,"properties":{"actorUsername":{"type":["string","null"]},"amountUq":{"description":"Trade gross in uq atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"eventId":{"format":"uuid","type":"string"},"isServiceActor":{"description":"True iff this row's trader is on the bot service's wallet roster.","type":"boolean"},"leg":{"enum":["buy","sell"],"type":"string"},"mcapAfterUq":{"description":"Post-trade total market capitalisation, floored to uq.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"operation":{"enum":["buy","sell","swap"],"type":"string"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"seq":{"minimum":0,"type":"integer"},"side":{"$ref":"#/components/schemas/SideIndex"},"time":{"description":"Engine seconds from the trade envelope.","type":"number"}},"required":["eventId","seq","time","principalId","actorUsername","isServiceActor","side","leg","operation","amountUq","mcapAfterUq"],"type":"object"},"BackofficeTopUpBody":{"additionalProperties":false,"properties":{"account":{"maxLength":64,"minLength":1,"type":"string"},"mint":{"maxLength":44,"minLength":32,"type":"string"}},"required":["account","mint"],"type":"object"},"BackofficeTopUpResult":{"additionalProperties":false,"properties":{"amountAtoms":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"destination":{"type":"string"},"grantId":{"format":"uuid","type":"string"},"mint":{"type":"string"},"principalId":{"type":"string"},"repeated":{"type":"boolean"},"signature":{"type":["string","null"]},"status":{"type":"string"},"symbol":{"type":"string"},"usd":{"type":"string"}},"required":["grantId","principalId","destination","amountAtoms","mint","symbol","usd","status","signature","repeated"],"type":"object"},"BackofficeTreasury":{"additionalProperties":false,"properties":{"checkedAt":{"format":"date-time","type":["string","null"]},"mode":{"enum":["off","on"],"type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/BackofficeTreasuryWallet"},"type":"array"},"withdrawTo":{"items":{"maxLength":44,"minLength":32,"type":"string"},"type":"array"}},"required":["mode","checkedAt","wallets","withdrawTo"],"type":"object"},"BackofficeTreasuryDeskSol":{"additionalProperties":false,"properties":{"reserve":{"pattern":"^\\d+$","type":"string"},"spendable":{"pattern":"^\\d+$","type":["string","null"]}},"required":["spendable","reserve"],"type":["object","null"]},"BackofficeTreasuryGrant":{"additionalProperties":false,"properties":{"grantId":{"format":"uuid","type":"string"},"signature":{"type":["string","null"]},"status":{"enum":["claimed","built","finalized","expired"],"type":"string"}},"required":["grantId","status","signature"],"type":"object"},"BackofficeTreasuryWallet":{"additionalProperties":false,"properties":{"address":{"minLength":1,"type":["string","null"]},"asset":{"minLength":1,"type":"string"},"balance":{"pattern":"^\\d+$","type":["string","null"]},"canQuoteMarkets":{"type":"boolean"},"decimals":{"maximum":18,"minimum":0,"type":"integer"},"deskSol":{"$ref":"#/components/schemas/BackofficeTreasuryDeskSol"},"id":{"minLength":1,"type":"string"},"kind":{"enum":["treasury"],"type":"string"},"mint":{"type":["string","null"]},"role":{"enum":["feePayer","distributor"],"type":"string"},"status":{"enum":["ok","low","unconfigured","refused","unreachable","unpriced","unjudged"],"type":"string"},"threshold":{"pattern":"^\\d+$","type":"string"},"tokenAccount":{"type":["string","null"]}},"required":["kind","id","role","asset","mint","address","tokenAccount","balance","threshold","decimals","canQuoteMarkets","status","deskSol"],"type":"object"},"BackofficeWithdrawBody":{"additionalProperties":false,"properties":{"amount":{"anyOf":[{"enum":["all"],"type":"string"},{"maxLength":39,"pattern":"^[1-9][0-9]*$","type":"string"}]},"destination":{"maxLength":44,"minLength":32,"type":"string"},"mint":{"maxLength":44,"minLength":32,"type":"string"}},"required":["mint","destination","amount"],"type":"object"},"BackofficeWithdrawResult":{"additionalProperties":false,"properties":{"amountAtoms":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"destination":{"type":"string"},"grantId":{"format":"uuid","type":"string"},"mint":{"type":"string"},"repeated":{"type":"boolean"},"signature":{"type":["string","null"]},"status":{"type":"string"},"symbol":{"type":"string"}},"required":["grantId","destination","mint","symbol","amountAtoms","status","signature","repeated"],"type":"object"},"BulkSparklines":{"additionalProperties":false,"properties":{"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"series":{"items":{"$ref":"#/components/schemas/SparklineSeries"},"type":"array"}},"required":["series","projectionStatus"],"type":"object"},"ChainAdoptBody":{"additionalProperties":false,"properties":{"submissionId":{"format":"uuid","type":"string"}},"required":["submissionId"],"type":"object"},"ChainAdoptedMarket":{"additionalProperties":false,"properties":{"marketAddress":{"description":"From the decoded MarketCreated, never pre-derived.","maxLength":64,"minLength":32,"type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"question":{"maxLength":512,"minLength":1,"type":"string"}},"required":["marketId","marketAddress","question"],"type":"object"},"ChainBalances":{"additionalProperties":false,"properties":{"closedLots":{"description":"Quote sales folded from Trade events, including partial sales, plus proceeds of tokens the trader had not bought. Those proceeds rows have no profit figure.","items":{"$ref":"#/components/schemas/ChainClosedLot"},"type":"array"},"outside":{"description":"Tokens bought from the program that are not in this wallet, at their purchase cost. A withdrawal is a move, not a sale: these rows are excluded from open profit.","items":{"$ref":"#/components/schemas/ChainOutsideHolding"},"type":"array"},"positions":{"description":"Opinion-token holdings read from chain token accounts. Tokens are ordinary transferable SPL tokens, so this is the balance, not the trading history.","items":{"$ref":"#/components/schemas/ChainPosition"},"type":"array"},"quoteBalance":{"description":"testUSDC atoms, read from the chain token account.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"quoteMint":{"maxLength":64,"minLength":32,"type":"string"},"trader":{"description":"The account's address the identity token resolved to, echoed so a client can confirm which account it is looking at.","maxLength":64,"minLength":32,"type":"string"}},"required":["trader","quoteMint","quoteBalance","positions","outside","closedLots"],"type":"object"},"ChainBeneficiaryFee":{"additionalProperties":false,"properties":{"accrued":{"description":"Outstanding share in the market's own asset's atoms, from the claims projection (`gross − claimed`). It is not a lifetime total: a sweep zeroes the counter.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"collected":{"description":"All-time claimed for this market in the same asset's atoms, from the claims projection. `null` where this pass could not measure it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"conversion":{"allOf":[{"$ref":"#/components/schemas/ConversionQuoteDto"},{"description":"The conversion behind the sweep; `null` without one."}]},"decimals":{"description":"That asset's decimals, for printing its atoms.","maximum":18,"minimum":0,"type":"integer"},"issuerFeeAtoms":{"description":"The cut the asset's transfer fee takes from `accrued` when it is swept, `0` for an asset without one. What arrives is `accrued − issuerFeeAtoms`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"marketAddress":{"maxLength":64,"minLength":32,"type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"quoteMint":{"description":"The asset every figure on this entry is counted in — the mint the market's `MarketCreated` names.","maxLength":64,"minLength":32,"type":"string"},"receive":{"allOf":[{"$ref":"#/components/schemas/ConversionReceive"},{"description":"What the claim leaves in the wallet once converted, in the asset it converts into; `null` when it converts nothing. On a fee row, what a claim that names no `receive` converts into."}]},"receiveOptions":{"description":"Every way this claim may be received, `keep` first, then each asset the market offers where this deployment converts, at the money rates. The dialog prints these before any quote; a converting option's conversion is the claim quote's.","items":{"$ref":"#/components/schemas/ChainClaimReceiveOption"},"type":"array"}},"required":["marketId","marketAddress","quoteMint","decimals","accrued","collected","issuerFeeAtoms","receive","conversion","receiveOptions"],"type":"object"},"ChainBeneficiaryFees":{"additionalProperties":false,"description":"The same read for the seat the market's subject holds (ADR-0040). `null` where this deployment cannot measure it or cannot price its claim in every asset it holds. Unknown, never nothing accrued.","properties":{"beneficiary":{"description":"The wallet every entry is the beneficiary of.","maxLength":64,"minLength":32,"type":"string"},"claimable":{"description":"Per asset the entries name: the accrual and its floor.","items":{"$ref":"#/components/schemas/ChainClaimableByAsset"},"type":"array"},"collectedByAsset":{"description":"All-time claimed, one row per asset, from the earnings projection — never a sum of `entries`. `[]` where the wallet has no earnings row.","items":{"$ref":"#/components/schemas/ChainFeeAssetTotal"},"type":"array"},"entries":{"items":{"$ref":"#/components/schemas/ChainBeneficiaryFee"},"type":"array"},"unreadableMarketIds":{"items":{"$ref":"#/components/schemas/MarketId"},"type":"array"}},"required":["beneficiary","entries","collectedByAsset","claimable","unreadableMarketIds"],"type":["object","null"]},"ChainBuildBody":{"additionalProperties":false,"properties":{"amount":{"description":"Buy: atoms of the paying asset offered — USDC atoms for `usdc`, lamports for `sol`, the market asset's own atoms for `market` — a MAXIMUM. Sell: token atoms to burn. Swap: from-side token atoms to burn.","maxLength":39,"pattern":"^[1-9][0-9]*$","type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"operation":{"$ref":"#/components/schemas/ChainTradeOperation"},"payWith":{"allOf":[{"$ref":"#/components/schemas/PayWith"},{"default":"usdc","description":"Buy: the asset the person pays with. Sell: the asset the person receives — ignored on a SOL or USDC market, whose sale pays out in the market's own. Where it is not the market's own it is converted inside the transaction; `market` is the market's own and converts nothing. Defaults to `usdc`."}]},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["marketId","side","operation","amount"],"type":"object"},"ChainBuildResult":{"additionalProperties":false,"properties":{"chargeFromPosition":{"description":"Whether the charge comes out of the position being traded rather than out of the wallet.","type":"boolean"},"chargeMint":{"description":"The mint the network charge is taken in — the market's own quote mint, or behind a conversion the asset a buy pays with or a sell receives, unless only the other one covers the charge. On a swap in a market in neither SOL nor the quote token: SOL, else the market's asset, else the quote token — the first the signed-in wallet covers, and SOL on a quote without a session.","maxLength":64,"minLength":32,"type":"string"},"charged":{"description":"What the engine takes, in quote-mint units. Zero on a swap, which moves no quote atom through the wallet.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"conversion":{"$ref":"#/components/schemas/ConversionQuoteDto"},"drop":{"description":"Swap only: what the swap costs the trader, in quote-mint units. At least the fee and usually above it; never the fee itself.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"fee":{"description":"The program's fee, in quote-mint units — charged once, a swap included.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"feePayer":{"description":"The treasury address paying fees and rent, base58.","maxLength":64,"minLength":32,"type":"string"},"issuerCutAtoms":{"description":"The issuer's cut of this trade under the quote mint's transfer fee: on a buy the part of `netOut` above `charged + fee`, on a sell the part of `charged − fee` that never arrives. `\"0\"` without a cut. Never added to `charged`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"kind":{"$ref":"#/components/schemas/ChainSubmissionKind"},"lastValidBlockHeight":{"minimum":0,"type":"integer"},"message":{"description":"The unsigned transaction message, base64: v1 where the treasury pays, v0 for an external wallet paying its own fee. Sign exactly these bytes with the account's wallet; the server keeps its own copy and verifies against it.","maxLength":8192,"minLength":1,"type":"string"},"minOut":{"description":"The on-chain bound: `min_tokens_out` on a buy, `min_quote_out` on a sell — the quote against a fresh processed-tier read, times 0.995. A swap has one output and one bound: the to-side token amount. It reverts whole if the state has moved past it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"netOut":{"description":"What leaves the wallet on a buy — `charged + fee` grossed up by the quote mint's transfer fee; what arrives on a sell, after that fee; zero on a swap, whose cost is `drop`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkFee":{"description":"The network charge, in `chargeMint` atoms: what this transaction's transfer takes to have itself paid for on chain — the wrapped-SOL account's rent inside it when the message opens one. Its own line, because it is neither the engine's `charged` nor the program's `fee`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"payWith":{"anyOf":[{"$ref":"#/components/schemas/PayWith"},{"type":"null"},{"type":"null"}],"description":"The paying asset the request named, echoed; `null` only for a build no request named one for."},"rentAtoms":{"description":"The wrapped-SOL account's rent inside `networkFee`, in `chargeMint` atoms; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"rentReturnAtoms":{"description":"The lamports the wrap's close hands back to the wallet of that rent; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"submissionId":{"format":"uuid","type":"string"},"tokens":{"description":"Token atoms out on a buy, in on a sell, out on a swap.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["submissionId","kind","message","feePayer","lastValidBlockHeight","tokens","charged","fee","netOut","issuerCutAtoms","minOut","networkFee","rentAtoms","rentReturnAtoms","chargeMint","chargeFromPosition","conversion","payWith"],"type":"object"},"ChainClaimBody":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"receive":{"description":"The asset the claim is asked to be received as, which the response's `receive` then states as it arrives: `keep` pays the market's own asset, `sol` and `usdc` convert it inside the claim's own message. A market's own asset is `keep`. Absent, a market in neither SOL nor the quote token converts into the quote token and every other pays out in its own asset. An asset the market does not offer, or one this deployment cannot convert into, is refused.","enum":["keep","sol","usdc"],"type":"string"},"seat":{"default":"creator","description":"Which side of the market's fee split to sweep. `beneficiary` is refused until the beneficiary seat ships; the default keeps every existing client on the creator's sweep.","enum":["creator","beneficiary"],"type":"string"},"slippageBps":{"anyOf":[{"enum":[10],"type":"number"},{"enum":[50],"type":"number"},{"enum":[100],"type":"number"}],"description":"Jupiter's slippage bound for this claim's conversion, in basis points, which the quote's least output follows. Absent, the deployment's own bound. The treasury desk's rate is exact and ignores it, as does a claim that converts nothing."}},"required":["marketId"],"type":"object"},"ChainClaimBuildResult":{"allOf":[{"$ref":"#/components/schemas/ChainSubmission"},{"additionalProperties":false,"properties":{"accrued":{"description":"What the sweep pays out, in quote-mint units.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"chargeMint":{"description":"The mint `networkFee` is taken in when the claim converts: wrapped SOL, or the quote token; wrapped SOL from a wallet paying its own fee, in lamports. Absent on a plain claim charged in the market's asset.","maxLength":64,"minLength":32,"type":"string"},"conversion":{"allOf":[{"$ref":"#/components/schemas/ConversionQuoteDto"},{"description":"The conversion behind the sweep; `null` without one."}]},"feePayer":{"description":"The treasury address paying fees and rent, base58.","maxLength":64,"minLength":32,"type":"string"},"message":{"description":"The unsigned transaction message, base64: v1 where the treasury pays, v0 for an external wallet paying its own fee. Sign exactly these bytes and submit through POST /chain/submit, as a trade does.","maxLength":8192,"minLength":1,"type":"string"},"networkFee":{"description":"What the claim is charged, in `chargeMint` atoms — the market's own asset where it names none — measured, not estimated, the wrapped-SOL account's rent inside it where the claim wraps. A claim costing more than it pays out, net of that rent, is refused at build.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"receive":{"allOf":[{"$ref":"#/components/schemas/ConversionReceive"},{"description":"What the claim leaves in the wallet once converted, in the asset it converts into; `null` when it converts nothing. On a fee row, what a claim that names no `receive` converts into."}]},"rentAtoms":{"description":"The wrapped-SOL account's rent inside `networkFee`, in its atoms; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"rentReturnAtoms":{"description":"The lamports the wrap's close hands back to the wallet of that rent; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["receive"],"type":"object"}]},"ChainClaimQuote":{"additionalProperties":false,"properties":{"chargeMint":{"description":"The asset the network charge is taken in: wrapped SOL or the quote token behind a conversion, the market's own asset on `keep`. On a refusal, the asset the claim would have been charged in as far as known.","maxLength":64,"minLength":32,"type":"string"},"conversion":{"anyOf":[{"allOf":[{"$ref":"#/components/schemas/ConversionQuoteDto"},{"type":"object"}]},{"type":"null"},{"type":"null"}],"description":"The conversion behind the sweep, as the build would quote it; `null` on `keep` and on a refusal."},"conversionCostUsd":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"What the conversion itself costs, in US dollars. Its asset and atoms are `conversion`'s `costMint` and `costAtoms`; `null` where there is no conversion."},"conversionRateStale":{"description":"`true` when the conversion's cost was priced from a rate past the age bound, so the conversion may cost more than `conversion` states. `false` where no conversion stands behind the preview.","type":"boolean"},"marketId":{"$ref":"#/components/schemas/MarketId"},"networkFee":{"description":"What the network would charge, estimated, in `chargeMint` atoms; the measured figure appears on the build response. Absent when this deployment cannot price one, and on a refusal.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkFeeUsd":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"`networkFee` in US dollars at the display rate; `null` where the figure or its rate is unknown."},"receive":{"anyOf":[{"allOf":[{"$ref":"#/components/schemas/ConversionReceive"},{"type":"object"}]},{"type":"null"},{"type":"null"}],"description":"What is expected to arrive, in the asset it arrives in, net of the network charge where that is taken in the same asset. `null` on a refusal, and where no dollar reading exists."},"receiveAs":{"description":"The body as the build treats it: a `receive` naming the market's own asset, or none where the market converts nothing by default, reads `keep`.","enum":["keep","sol","usdc"],"type":"string"},"receiveMinAtoms":{"description":"The least that arrives, in `receive`'s asset, net of the network charge where that is taken in it. `null` on a refusal.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"refusal":{"additionalProperties":false,"description":"The refusal the build would give for this claim — a conversion below the minimum routed, no route, a claim that would cost more than it pays — as `ErrorBody`'s inner object. `null` when the claim would be built.","properties":{"code":{"minLength":1,"type":"string"},"details":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"},{"type":"null"}]},"type":"object"},"message":{"minLength":1,"type":"string"}},"required":["code","message"],"type":["object","null"]}},"required":["marketId","receiveAs","conversion","conversionRateStale","conversionCostUsd","receive","receiveMinAtoms","chargeMint","networkFeeUsd","refusal"],"type":"object"},"ChainClaimReceiveOption":{"additionalProperties":false,"properties":{"atoms":{"description":"What arrives, in `mint` atoms. `keep`: `accrued − issuerFeeAtoms`. A converting option: that, at the money rates — a reading, never a quote. `null` where either asset has no rate.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"mint":{"description":"The asset that arrives; the market's own on `keep`.","maxLength":64,"minLength":32,"type":"string"},"rate":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"Atoms of `mint` one atom of the market's asset is worth at the money rates `atoms` was read at; `null` on `keep` and where a rate is unread."},"receiveAs":{"description":"What the claim is received as: the market's own asset, or converted into SOL or the quote token. The value a claim body's `receive` names.","enum":["keep","sol","usdc"],"type":"string"},"usd":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"`atoms` in US dollars at the money rate; `null` unread."}},"required":["receiveAs","mint","atoms","usd","rate"],"type":"object"},"ChainClaimableByAsset":{"additionalProperties":false,"properties":{"atoms":{"description":"The seat's accrued in this asset, its atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"decimals":{"maximum":18,"minimum":0,"type":"integer"},"floorAtoms":{"description":"The least accrual a plain claim in this asset buys anything with: one atom over the claim's network charge, converted into this asset at the money rate. The floor is met by what arrives — an entry's `accrued − issuerFeeAtoms` — not by the accrual. A conversion's own minimum is not in it: a converting option meets that as the claim quote's refusal.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"issuerFeeAtoms":{"description":"The sum of this asset's entries' `issuerFeeAtoms`: what its transfer fee takes on the way out.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"quoteMint":{"maxLength":64,"minLength":32,"type":"string"}},"required":["quoteMint","decimals","atoms","issuerFeeAtoms","floorAtoms"],"type":"object"},"ChainClosedLot":{"additionalProperties":false,"properties":{"atRateNow":{"description":"True when a leg with no rate and a nonzero net was valued at the asset's rate now. Never true on a `cash` lot, false when `profitUq` is null.","type":"boolean"},"basisUq":{"$ref":"#/components/schemas/NullableSignedRatJson"},"closedAt":{"format":"date-time","type":"string"},"closedBySignature":{"description":"Base58 signature of the transaction whose sell or swap closed this row. Every row is exactly one such trade, never a merge of two; two trades in one transaction are two rows under one signature. Null only when that trade's ingest key cannot be read.","maxLength":128,"minLength":1,"type":["string","null"]},"entry":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Null when the sold tokens were not bought here.","type":["object","null"]}]},"exit":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Null when the sold tokens were not bought here.","type":["object","null"]}]},"marketId":{"$ref":"#/components/schemas/MarketId"},"openedAt":{"format":"date-time","type":["string","null"]},"proceeds":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"USDC atoms from selling tokens this trader had not bought. Null on a sale whose cost is known. Profit is `realized`, and it is null exactly when this is set.","type":["object","null"]}]},"profitKind":{"description":"`cash` when every leg of the closed lot landed a conversion, `rate` otherwise. Null exactly when the cost is unknown.","enum":["cash","rate"],"type":["string","null"]},"profitUq":{"$ref":"#/components/schemas/NullableSignedRatJson"},"realized":{"$ref":"#/components/schemas/NullableSignedRatJson"},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["marketId","side","entry","exit","realized","proceeds","openedAt","closedAt","closedBySignature","profitUq","basisUq","profitKind","atRateNow"],"type":"object"},"ChainCreateBody":{"additionalProperties":false,"properties":{"assetMint":{"description":"The mint the market is denominated in. It must be in the asset catalogue with \"may quote markets\" on, and listed by the program; there is no default.","maxLength":44,"minLength":32,"type":"string"},"imageUrl":{"$ref":"#/components/schemas/MarketImageUrl"},"question":{"description":"Two characters to 40 Unicode code points. The ceiling is the PROGRAM's (contracts ADR-0044), counted on the NFC form in code points rather than UTF-16 units, so an emoji or a CJK character counts once. It was 512 characters while the question was only ever stored off chain.","maxLength":40,"minLength":2,"type":"string"},"sideTickers":{"prefixItems":[{"pattern":"^[A-Za-z0-9]{1,8}$","type":"string"},{"pattern":"^[A-Za-z0-9]{1,8}$","type":"string"}],"type":"array"},"social":{"additionalProperties":false,"properties":{"handle":{"description":"Handle of the person the market is about, who receives the market's beneficiary fee share. Accepts `name`, `@name`, or a profile URL on the named platform (x.com/twitter.com, github.com); stored as the stripped handle.","maxLength":256,"minLength":1,"type":"string"},"platform":{"enum":["x","github"],"type":"string"}},"required":["platform","handle"],"type":"object"},"tags":{"description":"1 to 3 catalogue slugs the creator picked from `POST /tags/derive`'s suggestions.","items":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"maxItems":3,"minItems":1,"type":"array"},"tickerBase":{"pattern":"^[A-Za-z0-9]{1,8}$","type":"string"}},"required":["question","assetMint","tickerBase","sideTickers","tags"],"type":"object"},"ChainCreateEstimate":{"additionalProperties":false,"properties":{"asset":{"additionalProperties":false,"description":"The asset the creation is denominated in, as the catalogue names it: the requested mint and its symbol.","properties":{"decimals":{"description":"The mint's decimals, read off its account with the estimate; `null` where that read failed — unknown, never a default.","maximum":255,"minimum":0,"type":["integer","null"]},"mint":{"maxLength":64,"minLength":32,"type":"string"},"symbol":{"maxLength":32,"minLength":1,"type":"string"}},"required":["mint","symbol","decimals"],"type":["object","null"]},"chargeAsset":{"allOf":[{"$ref":"#/components/schemas/ChainWithdrawAsset"},{"description":"The asset `networkFee` and `xLookupFee` are in: the quote token a creation's charge falls back to, or SOL for a creation in wrapped SOL. A creation's charge is never in any other market asset."}]},"chargeDecimals":{"description":"`chargeAsset`'s decimals: 9 for SOL, else the quote mint's.","type":"integer"},"chargeSymbol":{"description":"`chargeAsset`'s ticker: `SOL` or the quote ticker.","type":"string"},"inSol":{"additionalProperties":false,"description":"The same charge in lamports: the build takes it in SOL when the wallet's SOL covers it, and the form shows whichever the wallet it knows would pay. Null for a creation in wrapped SOL, whose charge is always SOL.","properties":{"networkFeeLamports":{"description":"`networkFee` at cost in lamports; absent when unpriceable.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"xLookupFeeLamports":{"description":"`xLookupFee` in lamports, at SOL's rate; `null` when unpriceable.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]}},"required":["xLookupFeeLamports"],"type":["object","null"]},"minimumOpeningBuyAtoms":{"description":"The smallest opening buy a launch may carry, in the asset's units: the launch's dollar minimum at the asset's money rate, rounded up to a whole unit. It is what the buy must deliver to the market.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"minimumOpeningBuyDebitAtoms":{"description":"What the wallet pays for that minimum under the asset's transfer fee. The program grosses a buy's transfer up so the market receives the whole minimum; equal to the minimum when the asset has no fee.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkFee":{"description":"What a creation would charge, estimated, in `chargeAsset`'s units. The rent is a constant; the SOL price and the priority fee are live. Absent when this deployment cannot price one — the line reads as unknown rather than as free. The measured figure appears on the build response.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"openingBuy":{"additionalProperties":false,"description":"The opening buy, signed as its own transaction after the creation, when `payWith` is not the market's asset and `amountIn` is given; `null` otherwise.","properties":{"chargeMint":{"description":"The paying asset, which the buy's network charge is taken in.","maxLength":64,"minLength":32,"type":"string"},"conversion":{"$ref":"#/components/schemas/ConversionQuoteDto"},"networkFee":{"description":"The buy's own network charge — its transaction, the conversion, the accounts it opens and the wrap when its message opens one — in `chargeMint` atoms. The creation's charge is `networkFee` above, in its own asset. Absent when unpriceable.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["conversion","chargeMint"],"type":["object","null"]},"openingSizeAtoms":{"description":"The opening size the asset's listing prescribes at the moment of the estimate, in the asset's units. A preview, not a promise: a re-pricing of the listing between build and landing changes it, and the created market keeps the quantum its creation carried.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"payer":{"description":"Who the creation's network and rent are priced for: `wallet` for a signed-in account whose external wallet pays them itself in SOL (ADR 0043) — `inSol.networkFeeLamports`, or `networkFee` on a creation in wrapped SOL, with no charge and no lookup line; `treasury` for an embedded account and a signed-out caller.","enum":["treasury","wallet"],"type":"string"},"transferFee":{"additionalProperties":false,"description":"The asset's transfer-fee schedule in force. Null for SOL, a mint without the extension or a zero rate.","properties":{"basisPoints":{"description":"The rate the token program withholds, in basis points.","maximum":10000,"minimum":1,"type":"integer"},"maximumFeeAtoms":{"description":"The most it withholds from one transfer, in the asset's own units.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["basisPoints","maximumFeeAtoms"],"type":["object","null"]},"xLookupFee":{"description":"What the subject lookup adds to a creation, in `chargeAsset`'s units. `null` where this deployment cannot price one — the line reads as unknown rather than as free.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]}},"required":["payer","xLookupFee","chargeAsset","chargeDecimals","chargeSymbol","inSol","asset","minimumOpeningBuyAtoms","minimumOpeningBuyDebitAtoms","transferFee","openingSizeAtoms","openingBuy"],"type":"object"},"ChainCreateResult":{"additionalProperties":false,"properties":{"chargeAsset":{"allOf":[{"$ref":"#/components/schemas/ChainWithdrawAsset"},{"description":"What the network charge is taken in: SOL when the wallet's SOL covers it, else the quote token; always SOL for a creation in wrapped SOL. Never the market's own asset otherwise. Decided by the server."}]},"chargeDecimals":{"description":"`chargeAsset`'s decimals: 9 for SOL, else the quote mint's.","type":"integer"},"chargeSymbol":{"description":"`chargeAsset`'s ticker: `SOL` or the quote ticker.","type":"string"},"feePayer":{"description":"The treasury address paying fees and creation rent.","maxLength":64,"minLength":32,"type":"string"},"kind":{"$ref":"#/components/schemas/ChainSubmissionKind"},"lastValidBlockHeight":{"minimum":0,"type":"integer"},"message":{"description":"The unsigned transaction message, base64: v1 where the treasury pays, v0 for an external wallet paying its own fee. It carries one `create_market` and the creator's network charge, and nothing else. The treasury is its payer, so no rent moves to the creator, and no opening buy rides with it: the creation's three signers took a bundle with a buy past Solana's 1232-byte transaction limit. A creator buys afterwards, through the ordinary trade routes.","maxLength":8192,"minLength":1,"type":"string"},"networkFee":{"description":"What the creation charges the creator, in `chargeAsset`'s units: the rent and the flat metadata fee the treasury fronts, the signatures and the priority fee — at cost in SOL, with the operator's margin in the quote token — and the X lookup's line when one is priced. Collected in the same transaction; the treasury advances and never spends.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"submissionId":{"format":"uuid","type":"string"}},"required":["submissionId","kind","message","feePayer","lastValidBlockHeight","networkFee","chargeAsset","chargeDecimals","chargeSymbol"],"type":"object"},"ChainCreatorFee":{"additionalProperties":false,"properties":{"accrued":{"description":"Outstanding share in the market's own asset's atoms, from the claims projection (`gross − claimed`). It is not a lifetime total: a sweep zeroes the counter.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"collected":{"description":"All-time claimed for this market in the same asset's atoms, from the claims projection. `null` where this pass could not measure it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"conversion":{"allOf":[{"$ref":"#/components/schemas/ConversionQuoteDto"},{"description":"The conversion behind the sweep; `null` without one."}]},"decimals":{"description":"That asset's decimals, for printing its atoms.","maximum":18,"minimum":0,"type":"integer"},"issuerFeeAtoms":{"description":"The cut the asset's transfer fee takes from `accrued` when it is swept, `0` for an asset without one. What arrives is `accrued − issuerFeeAtoms`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"marketAddress":{"maxLength":64,"minLength":32,"type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"quoteMint":{"description":"The asset every figure on this entry is counted in — the mint the market's `MarketCreated` names.","maxLength":64,"minLength":32,"type":"string"},"receive":{"allOf":[{"$ref":"#/components/schemas/ConversionReceive"},{"description":"What the claim leaves in the wallet once converted, in the asset it converts into; `null` when it converts nothing. On a fee row, what a claim that names no `receive` converts into."}]},"receiveOptions":{"description":"Every way this claim may be received, `keep` first, then each asset the market offers where this deployment converts, at the money rates. The dialog prints these before any quote; a converting option's conversion is the claim quote's.","items":{"$ref":"#/components/schemas/ChainClaimReceiveOption"},"type":"array"}},"required":["marketId","marketAddress","quoteMint","decimals","accrued","collected","issuerFeeAtoms","receive","conversion","receiveOptions"],"type":"object"},"ChainCreatorFees":{"additionalProperties":false,"properties":{"beneficiary":{"$ref":"#/components/schemas/ChainBeneficiaryFees"},"claimable":{"description":"Per asset the entries name: the accrual and its floor. `null` where this deployment cannot price a claim in some asset the seat holds — the floor is unknown, never zero.","items":{"$ref":"#/components/schemas/ChainClaimableByAsset"},"type":["array","null"]},"collectedByAsset":{"description":"All-time claimed, one row per asset, from the earnings projection — never a sum of `entries`. `[]` where the wallet has no earnings row.","items":{"$ref":"#/components/schemas/ChainFeeAssetTotal"},"type":"array"},"convertMinUsd":{"anyOf":[{"$ref":"#/components/schemas/RatJson"},{"type":"null"},{"type":"null"}],"description":"The smallest conversion either seat's converting option is routed at, in US dollars: a claim quote or a claim that converts less is refused `CONVERT_BELOW_MINIMUM`. What is held to it is what the claim would convert — the sweep after the issuer's cut, plus, on a market in neither SOL nor the quote token, what the wallet already holds of its asset — at the display rate. `null` where this deployment converts no claim or cannot read its minimum; a client then judges no size itself."},"creator":{"description":"The account's address the identity token resolved to. Every entry is a market whose projected creator is this account.","maxLength":64,"minLength":32,"type":"string"},"entries":{"items":{"$ref":"#/components/schemas/ChainCreatorFee"},"type":"array"},"unreadableMarketIds":{"description":"Markets this pass could not measure: a half-ingested row, or a market whose log names no `MarketCreated` or no asset. Reported rather than dropped — unmeasurable is not an accrual of zero, and a client must render it as unknown rather than as nothing.","items":{"$ref":"#/components/schemas/MarketId"},"type":"array"}},"required":["creator","entries","collectedByAsset","claimable","unreadableMarketIds","beneficiary","convertMinUsd"],"type":"object"},"ChainFeeAssetTotal":{"additionalProperties":false,"properties":{"atoms":{"description":"A figure in this asset's atoms — never summed across assets.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"decimals":{"maximum":18,"minimum":0,"type":"integer"},"quoteMint":{"maxLength":64,"minLength":32,"type":"string"}},"required":["quoteMint","decimals","atoms"],"type":"object"},"ChainOpenSubmissions":{"additionalProperties":false,"properties":{"submissions":{"description":"Non-terminal submissions, newest first.","items":{"$ref":"#/components/schemas/ChainSubmission"},"type":"array"}},"required":["submissions"],"type":"object"},"ChainOutsideHolding":{"additionalProperties":false,"properties":{"amount":{"description":"Token atoms bought here that are not in this wallet.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"costBasis":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Purchase cost of `amount`, whole uq atoms, `den` \"1\". Not a mark, and not part of open profit."}]},"marketId":{"$ref":"#/components/schemas/MarketId"},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["marketId","side","amount","costBasis"],"type":"object"},"ChainPosition":{"additionalProperties":false,"properties":{"amount":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"costBasis":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"In-wallet share of the remaining debit (`charged + fee` minus relieved), in whole uq atoms carried as `{ num, den }` with `den` \"1\" (ADR 0039). Null when this wallet holds tokens whose cost is unknown. A shortfall's cost is `outside`, not erased.","type":["object","null"]}]},"costUnstampedAtoms":{"description":"Atoms of the in-wallet cost carried by legs with no rate (stamped `none`, or not yet stamped), for the reader to value at the rate now; the server prices no open row. Null exactly when `costBasis` is.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"costUq":{"description":"Whole micro-dollars of the in-wallet cost carried by legs that were stamped with a rate. Null exactly when `costBasis` is.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"entryConsensusYes":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"The crowd's split on the Trade that opened the current hold. Null when the cost is unknown or the hold has not been opened from zero.","type":["object","null"]}]},"includesReceived":{"description":"True when the wallet holds more tokens on this side than this trader still carries a cost for. Entry and profit are then absent: tokens received from elsewhere are not a zero cost basis.","type":"boolean"},"marketId":{"allOf":[{"$ref":"#/components/schemas/MarketId"},{"type":["string","null"]}]},"mint":{"maxLength":64,"minLength":32,"type":"string"},"openedAt":{"description":"ISO instant of the Trade that took this side from 0 to a positive costed balance. Later adds do not restamp.","format":"date-time","type":["string","null"]},"side":{"allOf":[{"$ref":"#/components/schemas/SideIndex"},{"anyOf":[{"enum":[0],"type":"number"},{"enum":[1],"type":"number"},{"type":"null"}]}]},"tokenAccount":{"maxLength":64,"minLength":32,"type":"string"}},"required":["mint","marketId","side","tokenAccount","amount","costBasis","entryConsensusYes","openedAt","includesReceived","costUq","costUnstampedAtoms"],"type":"object"},"ChainQuoteBody":{"additionalProperties":false,"properties":{"amount":{"description":"Buy: atoms of the paying asset offered — USDC atoms for `usdc`, lamports for `sol`, the market asset's own atoms for `market` — a MAXIMUM and not a payment. Sell: token atoms to redeem, exactly. Swap: from-side token atoms to redeem, exactly.","maxLength":39,"pattern":"^[1-9][0-9]*$","type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"operation":{"$ref":"#/components/schemas/ChainTradeOperation"},"payWith":{"allOf":[{"$ref":"#/components/schemas/PayWith"},{"default":"usdc","description":"Buy: the asset the person pays with. Sell: the asset the person receives — ignored on a SOL or USDC market, whose sale pays out in the market's own. Where it is not the market's own it is converted inside the transaction; `market` is the market's own and converts nothing. Defaults to `usdc`."}]},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["marketId","side","operation","amount"],"type":"object"},"ChainQuoteResult":{"additionalProperties":false,"properties":{"accountsToOpen":{"description":"Token accounts this trade would open for the signed-in caller, once each: `quote` for the quote mint's, `side` for the traded side's (a swap's to side). Absent when none, or signed out.","items":{"enum":["quote","side"],"type":"string"},"minItems":1,"type":"array"},"chargeFromPosition":{"description":"Whether the charge comes out of the position being traded rather than out of the wallet.","type":"boolean"},"chargeMint":{"description":"The mint the network charge is taken in — the market's own quote mint, or behind a conversion the asset a buy pays with or a sell receives, unless only the other one covers the charge. On a swap in a market in neither SOL nor the quote token: SOL, else the market's asset, else the quote token — the first the signed-in wallet covers, and SOL on a quote without a session.","maxLength":64,"minLength":32,"type":"string"},"charged":{"description":"What the engine takes, in quote-mint units. Zero on a swap, which moves no quote atom through the wallet.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"consensusYesAfter":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Where the trade would leave the crowd's split, in `0..1` — the figure the market page prints as consensus."}]},"conversion":{"$ref":"#/components/schemas/ConversionQuoteDto"},"conversionAtRates":{"description":"`true` when `conversion` was priced from the cached display rates with no route asked, as for a caller with no session: an estimate whose routed figures come once the caller signs in. `false` where it was routed, or no conversion stands behind the preview.","type":"boolean"},"conversionRateStale":{"description":"`true` when the conversion's cost was priced from a rate past the age bound, so the conversion may cost more than `conversion` states. `false` where no conversion stands behind the preview.","type":"boolean"},"drop":{"description":"Swap only: what the swap costs the trader, in quote-mint units. At least the fee and usually above it; never the fee itself.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"fee":{"description":"The program's fee, in quote-mint units — charged once, a swap included.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"issuerCutAtoms":{"description":"The issuer's cut of this trade under the quote mint's transfer fee: on a buy the part of `netOut` above `charged + fee`, on a sell the part of `charged − fee` that never arrives. `\"0\"` without a cut. Never added to `charged`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"netOut":{"description":"The number that moves: what leaves the wallet on a buy — `charged + fee` grossed up by the quote mint's transfer fee — and what arrives on a sell, after that fee. Never `quoteIn`, never bare `charged`. Zero on a swap; what a swap costs is `drop`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkFee":{"description":"What the network would charge this trade, estimated, in `chargeMint` atoms — for a signed-in caller including the rent of every account in `accountsToOpen`, and on a SOL market's buy or sell the wrapped-SOL account's rent, `rentAtoms`, which the close returns. Absent when this deployment cannot price one — the line reads as unknown rather than as free. The measured figure appears on the build response.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkFeeUsd":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"The transaction's network charge — `networkFee`, in `chargeMint` — in US dollars at the display rate. `null` where the figure or its rate is unknown.","type":["object","null"]}]},"operation":{"$ref":"#/components/schemas/ChainTradeOperation"},"payWith":{"anyOf":[{"$ref":"#/components/schemas/PayWith"},{"type":"null"},{"type":"null"}],"description":"The paying asset the request named, echoed; `null` only for a build no request named one for."},"receive":{"$ref":"#/components/schemas/ConversionReceive"},"receiveMinAtoms":{"description":"Sell only: the least `receive` may be, in its mint's atoms, net of the network charge. `null` when nothing is converted.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"rentAtoms":{"description":"The wrapped-SOL account's rent inside `networkFee`, in `chargeMint` atoms. Present whenever `networkFee` is; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"rentReturnAtoms":{"description":"The lamports the wrap's close hands back to the wallet of that rent. Present whenever `networkFee` is; `\"0\"` when nothing wraps.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"seq":{"description":"The projection sequence this advisory quote was priced at. Quotes are advisory; the on-chain `min_*` bound is the only guarantee.","minimum":0,"type":"integer"},"side":{"$ref":"#/components/schemas/SideIndex"},"tokens":{"description":"Token atoms out on a buy, in on a sell, out on a swap.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["marketId","side","operation","tokens","charged","fee","netOut","issuerCutAtoms","chargeMint","chargeFromPosition","seq","conversion","conversionRateStale","conversionAtRates","payWith","receive","receiveMinAtoms","networkFeeUsd"],"type":"object"},"ChainSubmission":{"additionalProperties":false,"properties":{"conversion":{"additionalProperties":false,"description":"The conversion a row carries — a buy's in front of it or a sell's behind it, inside its own message — or, on a conversion's own row, its outcome; null otherwise.","properties":{"inputMint":{"description":"What the conversion spent from; `null` where the row does not state it.","maxLength":64,"minLength":32,"type":["string","null"]},"outputMint":{"maxLength":64,"minLength":32,"type":"string"},"realisedInAtoms":{"description":"What the conversion spent, in `inputMint` atoms, the charge inside when it was taken there; `null` until it landed or where the row does not state it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"realisedOutAtoms":{"description":"What the conversion delivered, in `outputMint` atoms; `null` until it landed.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"status":{"enum":["pending","landed","expired"],"type":"string"},"submissionId":{"format":"uuid","type":"string"}},"required":["submissionId","status","outputMint","realisedOutAtoms","inputMint","realisedInAtoms"],"type":["object","null"]},"createdAt":{"format":"date-time","type":"string"},"failureDetail":{"maxLength":512,"type":["string","null"]},"kind":{"$ref":"#/components/schemas/ChainSubmissionKind"},"lamportsCharged":{"minimum":0,"type":"integer"},"lastValidBlockHeight":{"minimum":0,"type":["integer","null"]},"marketId":{"allOf":[{"$ref":"#/components/schemas/MarketId"},{"type":["string","null"]}]},"reverted":{"description":"Finalized carrying `meta.err`: the transaction landed and failed, so nothing it asked for happened. `failureDetail` holds the cluster's reason. False on every other row.","type":"boolean"},"signature":{"maxLength":128,"minLength":32,"type":["string","null"]},"status":{"$ref":"#/components/schemas/ChainSubmissionStatus"},"submissionId":{"format":"uuid","type":"string"},"terminal":{"description":"True once polling can stop: finalized or expired.","type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"withdraw":{"additionalProperties":false,"description":"A withdrawal's recipient and amount; null on every other kind.","properties":{"amountAtoms":{"description":"The amount the transfer names, in the asset's own units; a transfer fee on the asset is withheld from it on the way.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"asset":{"$ref":"#/components/schemas/ChainWithdrawAsset"},"decimals":{"description":"The asset's decimals: 9 for SOL, else the mint's.","type":"integer"},"recipient":{"description":"The destination wallet, as the build read it.","type":"string"},"symbol":{"description":"The quote ticker, `SOL`, or null for any other token.","type":["string","null"]}},"required":["asset","decimals","symbol","recipient","amountAtoms"],"type":["object","null"]}},"required":["submissionId","kind","status","marketId","signature","lastValidBlockHeight","lamportsCharged","failureDetail","terminal","reverted","withdraw","conversion","createdAt","updatedAt"],"type":"object"},"ChainSubmissionKind":{"enum":["buy","sell","create","swap","claim","withdraw","convert","claim_convert","buy_convert","sell_convert"],"type":"string"},"ChainSubmissionStatus":{"enum":["built","signed","submitted","confirmed","finalized","expired"],"type":"string"},"ChainSubmitBody":{"additionalProperties":false,"properties":{"signature":{"description":"The wallet's ed25519 signature over the built message, base58. Without `transaction` the server reassembles the transaction from its own stored message. From an external wallet that pays its own fee (ADR 0043) it is the signature the wallet already sent the transaction under, and the row only records it — or, with `transaction`, the wallet's signature in it.","maxLength":128,"minLength":64,"type":"string"},"submissionId":{"format":"uuid","type":"string"},"transaction":{"description":"Only from an external wallet whose transaction the server still signs (ADR 0043): the whole transaction the wallet signed first, base64. The server signs it only when every instruction it built is present and unchanged and the wallet added nothing but compute budget and Lighthouse instructions, then sends it.","maxLength":2048,"minLength":1,"type":"string"}},"required":["submissionId","signature"],"type":"object"},"ChainTradeOperation":{"enum":["buy","sell","swap"],"type":"string"},"ChainWalletAsset":{"additionalProperties":false,"properties":{"amountAtoms":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"decimals":{"type":"integer"},"kind":{"enum":["token"],"type":"string"},"mint":{"type":"string"},"program":{"description":"The mint's owner program: SPL Token or Token-2022.","type":"string"},"role":{"enum":["quote","other"],"type":"string"},"symbol":{"description":"The quote ticker for the quote mint, otherwise null.","type":["string","null"]}},"required":["kind","mint","program","amountAtoms","decimals","symbol","role"],"type":"object"},"ChainWalletAssets":{"additionalProperties":false,"properties":{"assets":{"items":{"$ref":"#/components/schemas/ChainWalletAsset"},"type":"array"},"sol":{"additionalProperties":false,"properties":{"lamports":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["lamports"],"type":"object"},"trader":{"type":"string"}},"required":["trader","sol","assets"],"type":"object"},"ChainWithdrawAsset":{"oneOf":[{"additionalProperties":false,"properties":{"kind":{"enum":["sol"],"type":"string"}},"required":["kind"],"type":"object"},{"additionalProperties":false,"properties":{"kind":{"enum":["token"],"type":"string"},"mint":{"maxLength":44,"minLength":32,"type":"string"}},"required":["kind","mint"],"type":"object"}]},"ChainWithdrawBody":{"additionalProperties":false,"properties":{"amount":{"anyOf":[{"description":"The asset's own units (lamports for SOL) the recipient receives, exactly; the charge comes on top.","maxLength":39,"pattern":"^[1-9][0-9]*$","type":"string"},{"description":"Send the whole balance — less the charge when the charge is taken in the asset itself; the build names the amount.","enum":["max"],"type":"string"}]},"asset":{"$ref":"#/components/schemas/ChainWithdrawAsset"},"recipient":{"description":"The destination wallet address, base58.","maxLength":44,"minLength":32,"type":"string"}},"required":["asset","recipient","amount"],"type":"object"},"ChainWithdrawBuildResult":{"additionalProperties":false,"properties":{"feePayer":{"description":"The treasury address paying fees and rent, base58.","maxLength":64,"minLength":32,"type":"string"},"kind":{"enum":["withdraw"],"type":"string"},"lastValidBlockHeight":{"minimum":0,"type":"integer"},"message":{"description":"The unsigned transaction message, base64: v1 where the treasury pays, v0 for an external wallet paying its own fee. Sign exactly these bytes with the account's wallet; the server keeps its own copy and verifies against it.","maxLength":8192,"minLength":1,"type":"string"},"submissionId":{"format":"uuid","type":"string"},"withdraw":{"additionalProperties":false,"properties":{"accountOpeningAtoms":{"description":"The rent of the recipient's token account for the asset, in `chargeAsset`'s units; null for SOL or when that account already exists.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"amountAtoms":{"description":"The amount the transfer names, in the asset's own units; the recipient's account is credited `receivedAtoms`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"asset":{"$ref":"#/components/schemas/ChainWithdrawAsset"},"chargeAsset":{"allOf":[{"$ref":"#/components/schemas/ChainWithdrawAsset"},{"description":"What the network charge is taken in: SOL when the wallet holds enough of it for a SOL or other-token withdrawal, else the quote token. Decided by the server."}]},"chargeAtoms":{"description":"`networkCostAtoms + (accountOpeningAtoms ?? 0)` — the amount of the charge transfer, in `chargeAsset`'s units.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"chargeDecimals":{"description":"`chargeAsset`'s decimals: 9 for SOL, else the quote mint's.","type":"integer"},"chargeSymbol":{"description":"`chargeAsset`'s ticker: `SOL` or the quote ticker.","type":"string"},"debitedAtoms":{"description":"What leaves the wallet in the asset: `amountAtoms + chargeAtoms` when the charge is taken in the asset itself, else `amountAtoms`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"decimals":{"description":"The asset's decimals: 9 for SOL, else the mint's.","type":"integer"},"issuerFeeAtoms":{"description":"What the token program withholds from `amountAtoms` under the asset's transfer fee, in the asset's own units; \"0\" without one.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkCostAtoms":{"description":"The charge without rent, in `chargeAsset`'s units — lamports when the charge is in SOL.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"receivedAtoms":{"description":"`amountAtoms − issuerFeeAtoms`: what the recipient's account is credited with, exactly.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"recipient":{"description":"The destination as the server read it. The form renders this, never its own input.","type":"string"},"recipientTokenAccount":{"description":"Null for SOL, which is sent to the wallet itself.","type":["string","null"]},"symbol":{"description":"The quote ticker, `SOL`, or null for any other token.","type":["string","null"]}},"required":["recipient","asset","decimals","symbol","recipientTokenAccount","amountAtoms","issuerFeeAtoms","receivedAtoms","chargeAsset","chargeDecimals","chargeSymbol","networkCostAtoms","accountOpeningAtoms","chargeAtoms","debitedAtoms"],"type":"object"}},"required":["submissionId","kind","message","feePayer","lastValidBlockHeight","withdraw"],"type":"object"},"ChainWithdrawEstimate":{"additionalProperties":false,"properties":{"accountOpeningAtoms":{"description":"What opening the recipient's token account for the asset adds to that charge, in quote-mint units: its measured rent and its compute — charged only when the build opens that account; \"0\" for SOL, which needs none.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"asset":{"$ref":"#/components/schemas/ChainWithdrawAsset"},"inSol":{"additionalProperties":false,"description":"For SOL or another token, the charge in lamports — taken in SOL when the wallet holds enough, else in the quote token. Null for the quote token, whose charge is always the quote token.","properties":{"accountOpeningLamports":{"description":"The same addition, in lamports; \"0\" for SOL.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"networkCostLamports":{"description":"The same charge without rent, in lamports: what it costs when the wallet's SOL pays it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["networkCostLamports","accountOpeningLamports"],"type":["object","null"]},"networkCostAtoms":{"description":"What a withdrawal would charge without rent, estimated, in quote-mint units: the kind's compute at the cached priority-fee sample, plus the operator's margin.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"transferFee":{"additionalProperties":false,"description":"The asset's transfer-fee schedule in force: every transfer of it is cut by the rate, up to the maximum. A schedule and no atom figure, because the estimate names no amount; the build states the cut. Null for SOL, a mint without the extension or a zero rate.","properties":{"basisPoints":{"description":"The rate the token program withholds, in basis points.","maximum":10000,"minimum":1,"type":"integer"},"maximumFeeAtoms":{"description":"The most it withholds from one transfer, in the asset's own units.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["basisPoints","maximumFeeAtoms"],"type":["object","null"]}},"required":["asset","networkCostAtoms","accountOpeningAtoms","inSol","transferFee"],"type":"object"},"ChartCandle":{"additionalProperties":false,"description":"One closed bucket: both sides' OHLC, the quote volume through it, the supply pair at its close, and how many trades made it.","properties":{"bucketStart":{"description":"Bucket start in epoch seconds, UTC, floored to the grid.","type":"integer"},"infoBits":{"description":"Information the bucket's trades carried, in bits: the SUM of each trade's Kullback-Leibler divergence against the belief it found, never their net. Two opposing trades inside one bucket therefore report both moves rather than cancelling. Never negative.","minimum":0,"type":"number"},"sides":{"prefixItems":[{"$ref":"#/components/schemas/PriceOhlc"},{"$ref":"#/components/schemas/PriceOhlc"}],"type":"array"},"supply":{"prefixItems":[{"description":"Outstanding supply of side 0 in token atoms, at the close.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},{"description":"Outstanding supply of side 1 in token atoms, at the close.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}],"type":"array"},"tradeCount":{"description":"Trades folded into this bucket. Always positive: a bucket with no trades is absent from the series, never a fabricated zero.","exclusiveMinimum":0,"type":"integer"},"volumeUq":{"description":"Exact uq gross that moved through this bucket.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["bucketStart","sides","volumeUq","supply","tradeCount","infoBits"],"type":"object"},"ChartResolution":{"description":"Stored resolution: the `1m` base bucket and the `1h`/`1d` rollups, all produced by the same fold. There is no read-time aggregation.","enum":["1m","1h","1d"],"type":"string"},"ChartTvlPoint":{"additionalProperties":false,"description":"One bucket's close values that are not prices: TVL, and the crowd's split. No OHLC — neither is a price.","properties":{"bucketStart":{"type":"integer"},"consensusYes":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"The crowd's split at the bucket's close, in `0..1`. The consensus view of the chart is drawn from this, on the window the request already carries."}]},"tvl":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Value locked at the bucket's close, in uq. Not a cash counter: a donation straight into the vault moves no point here."}]}},"required":["bucketStart","tvl","consensusYes"],"type":"object"},"ChartWindow":{"additionalProperties":false,"properties":{"anchor":{"$ref":"#/components/schemas/NullableChartCandle"},"anchorTvl":{"$ref":"#/components/schemas/NullableChartTvlPoint"},"bucketSeconds":{"exclusiveMinimum":0,"type":"integer"},"candles":{"items":{"$ref":"#/components/schemas/ChartCandle"},"type":"array"},"clamped":{"description":"True when the requested span exceeded the server's bucket cap and the most recent slice was served instead. The series is never returned unbounded.","type":"boolean"},"from":{"description":"Effective inclusive lower bound after defaulting/clamping.","type":"integer"},"generation":{"description":"Projection generation, bumped on a rebuild. The `ETag` is a digest of this body, so a rebuild moves it.","exclusiveMinimum":0,"type":"integer"},"immutable":{"type":"boolean"},"lastSeq":{"minimum":0,"type":"integer"},"marketId":{"$ref":"#/components/schemas/MarketId"},"openBucketStart":{"description":"Start of the bucket still forming, when it falls inside this window. Such a window is never served as immutable, and only such a window's `ETag` moves with `lastSeq`.","type":["integer","null"]},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"resolution":{"$ref":"#/components/schemas/ChartResolution"},"to":{"description":"Effective inclusive upper bound after defaulting.","type":"integer"},"tvl":{"items":{"$ref":"#/components/schemas/ChartTvlPoint"},"type":"array"}},"required":["marketId","resolution","bucketSeconds","from","to","clamped","generation","lastSeq","projectionStatus","openBucketStart","immutable","anchor","anchorTvl","candles","tvl"],"type":"object"},"Consensus":{"additionalProperties":false,"properties":{"current":{"$ref":"#/components/schemas/MarketObservation"},"history":{"items":{"$ref":"#/components/schemas/ConsensusPoint"},"maxItems":0,"type":"array"},"lastSeq":{"minimum":0,"type":"integer"},"marketId":{"$ref":"#/components/schemas/MarketId"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"}},"required":["marketId","current","lastSeq","history","projectionStatus"],"type":"object"},"ConsensusPoint":{"additionalProperties":false,"properties":{"consensusRatio":{"type":"number"},"time":{"type":"number"}},"required":["time","consensusRatio"],"type":"object"},"ConversionQuoteDto":{"additionalProperties":false,"description":"The conversion in front of a buy or behind a sell, inside the same transaction; `null` when the trade converts nothing.","properties":{"accountCount":{"description":"The accounts the conversion's route adds to the message; on a routed estimate, the most it may add; 0 on an estimate at the cached rates.","minimum":0,"type":"integer"},"costAtoms":{"description":"What the conversion itself costs, in `costMint` atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"costMint":{"maxLength":64,"minLength":32,"type":"string"},"expectedOutAtoms":{"description":"What the conversion is expected to deliver, in `outputMint` atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"inputAtoms":{"description":"What the conversion spends, in `inputMint` atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"inputMint":{"maxLength":64,"minLength":32,"type":"string"},"maximumIn":{"description":"The most the conversion may spend, in `inputMint` atoms: `inputAtoms` itself when exact-in, as every buy's, sell's and claim's is.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"minOutAtoms":{"description":"The least it may deliver, in `outputMint` atoms: the expectation less the slippage bound. The next leg is sized from this.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"mode":{"description":"`exactIn` spends `inputAtoms` and guarantees `minOutAtoms`, estimating `expectedOutAtoms` above it — a buy's, a sell's and a claim's. `exactOut` delivers `expectedOutAtoms` exactly; no buy, sell or claim asks it.","enum":["exactIn","exactOut"],"type":"string"},"outputMint":{"maxLength":64,"minLength":32,"type":"string"},"source":{"description":"Who converts: Jupiter's router on mainnet, R8's treasury elsewhere.","enum":["jupiter","desk"],"type":"string"}},"required":["inputMint","inputAtoms","outputMint","expectedOutAtoms","minOutAtoms","costMint","costAtoms","source","accountCount","maximumIn","mode"],"type":["object","null"]},"ConversionReceive":{"additionalProperties":false,"description":"Sell only: what the wallet keeps once the proceeds are converted, net of the network charge. `null` when nothing is converted, or no dollar reading exists.","properties":{"atoms":{"description":"What arrives, in `mint` atoms.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"mint":{"maxLength":64,"minLength":32,"type":"string"},"usd":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"`atoms` in US dollars at the display rate."}]}},"required":["mint","atoms","usd"],"type":["object","null"]},"CreateBackofficeTagBody":{"additionalProperties":false,"properties":{"label":{"maxLength":64,"minLength":1,"type":"string"},"slug":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"sortOrder":{"type":"integer"}},"required":["slug","label"],"type":"object"},"CreateSessionRequest":{"additionalProperties":false,"properties":{"privyAccessToken":{"maxLength":4096,"minLength":1,"type":"string"},"privyIdentityToken":{"maxLength":8192,"minLength":1,"type":"string"}},"required":["privyAccessToken"],"type":"object"},"CreateSessionResponse":{"additionalProperties":false,"properties":{"address":{"$ref":"#/components/schemas/WalletAddress"},"expiresAt":{"format":"date-time","type":"string"},"firstSignIn":{"type":"boolean"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"role":{"enum":["user","operator","admin"],"type":"string"},"sessionId":{"format":"uuid","type":"string"},"token":{"minLength":1,"type":"string"}},"required":["token","sessionId","principalId","address","role","expiresAt","firstSignIn"],"type":"object"},"DeriveTagsBody":{"additionalProperties":false,"properties":{"sideTickers":{"prefixItems":[{"pattern":"^[A-Za-z0-9]{1,8}$","type":"string"},{"pattern":"^[A-Za-z0-9]{1,8}$","type":"string"}],"type":["array","null"]},"tickerBase":{"pattern":"^[A-Za-z0-9]{1,8}$","type":["string","null"]},"title":{"maxLength":512,"type":"string"}},"required":["title","tickerBase","sideTickers"],"type":"object"},"DeriveTagsResponse":{"additionalProperties":false,"properties":{"source":{"enum":["model","cache","stub","unavailable"],"type":"string"},"tags":{"items":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"maxItems":5,"type":"array"}},"required":["tags","source"],"type":"object"},"ErrorBody":{"additionalProperties":false,"properties":{"error":{"additionalProperties":false,"properties":{"code":{"minLength":1,"type":"string"},"details":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"},{"items":{"anyOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"null"},{"type":"null"}]},"type":"array"},{"type":"null"}]},"type":"object"},"message":{"minLength":1,"type":"string"}},"required":["code","message"],"type":"object"}},"required":["error"],"type":"object"},"GateChallengeRequest":{"additionalProperties":false,"properties":{"address":{"pattern":"^[1-9A-HJ-NP-Za-km-z]{32,44}$","type":"string"}},"required":["address"],"type":"object"},"GateChallengeResponse":{"additionalProperties":false,"properties":{"expiresAt":{"format":"date-time","type":"string"},"message":{"maxLength":2048,"minLength":1,"type":"string"}},"required":["message","expiresAt"],"type":"object"},"GateClaimRequest":{"additionalProperties":false,"properties":{"handle":{"maxLength":128,"minLength":1,"type":"string"}},"required":["handle"],"type":"object"},"GateConfigResponse":{"additionalProperties":false,"properties":{"armed":{"type":"boolean"},"envOverride":{"enum":["open"],"type":["string","null"]},"mints":{"items":{"$ref":"#/components/schemas/GateMint"},"type":"array"},"passed":{"type":"boolean"}},"required":["armed","envOverride","mints","passed"],"type":"object"},"GateMint":{"additionalProperties":false,"properties":{"mint":{"maxLength":64,"minLength":32,"type":"string"},"symbol":{"maxLength":16,"minLength":1,"type":"string"}},"required":["mint","symbol"],"type":"object"},"GateVerdict":{"oneOf":[{"additionalProperties":false,"properties":{"address":{"maxLength":64,"minLength":32,"type":"string"},"balance":{"maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"balanceDisplay":{"maxLength":128,"pattern":"^(0|[1-9][0-9]{0,2}(,[0-9]{3})*)(\\.[0-9]+)?$","type":"string"},"door":{"enum":["token"],"type":"string"},"mint":{"maxLength":64,"minLength":32,"type":"string"},"status":{"enum":["granted-by-admission"],"type":"string"},"symbol":{"maxLength":16,"minLength":1,"type":"string"}},"required":["status","door","address","mint","symbol","balance","balanceDisplay"],"type":"object"},{"additionalProperties":false,"properties":{"door":{"enum":["token","invite","manual"],"type":"string"},"status":{"enum":["granted-by-pass"],"type":"string"}},"required":["status","door"],"type":"object"},{"additionalProperties":false,"properties":{"reason":{"enum":["NO_BALANCE","ADDRESS_SPENT"],"type":"string"},"status":{"enum":["denied"],"type":"string"},"symbols":{"items":{"maxLength":16,"minLength":1,"type":"string"},"type":"array"}},"required":["status","reason","symbols"],"type":"object"},{"additionalProperties":false,"properties":{"reason":{"enum":["MAINNET_UNAVAILABLE"],"type":"string"},"status":{"enum":["unavailable"],"type":"string"}},"required":["status","reason"],"type":"object"},{"additionalProperties":false,"properties":{"address":{"maxLength":64,"minLength":32,"type":"string"},"status":{"enum":["account-exists"],"type":"string"}},"required":["status","address"],"type":"object"}]},"GrantBackofficeGatePassBody":{"additionalProperties":false,"properties":{"address":{"maxLength":64,"minLength":1,"type":["string","null"]},"reason":{"maxLength":280,"minLength":1,"type":"string"}},"required":["reason"],"type":"object"},"GrantedBackofficeGatePass":{"additionalProperties":false,"properties":{"address":{"type":["string","null"]},"claimUrl":{"minLength":1,"type":"string"},"expiresAt":{"format":"date-time","type":"string"},"passId":{"format":"uuid","type":"string"}},"required":["passId","claimUrl","address","expiresAt"],"type":"object"},"Holder":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"side0":{"description":"Token atoms held on side 0.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"side1":{"description":"Token atoms held on side 1.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["marketId","principalId","side0","side1"],"type":"object"},"HolderStanding":{"allOf":[{"$ref":"#/components/schemas/Holder"},{"additionalProperties":false,"properties":{"entryPrice":{"description":"Average buy price per side — charged plus fee over every buy, divided by the tokens bought — in a price's unit (quote atoms per token atom); null where the holder never bought that side.","prefixItems":[{"$ref":"#/components/schemas/NullableRatJson"},{"$ref":"#/components/schemas/NullableRatJson"}],"type":"array"},"pnlAtoms":{"description":"Net quote flow plus open holdings at the current side prices, on this market, in quote atoms truncated toward zero — the leaderboard's mark. Null where the holder has no rolled-up row.","maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":["string","null"]}},"required":["entryPrice","pnlAtoms"],"type":"object"}]},"HoldersPage":{"additionalProperties":false,"properties":{"holderCount":{"description":"How many holders the market has in total, not on this page.","minimum":0,"type":"integer"},"items":{"items":{"$ref":"#/components/schemas/HolderStanding"},"maxItems":200,"type":"array"},"nextOffset":{"description":"Offset of the next page, or null when this page exhausted the set.","minimum":0,"type":["integer","null"]},"totalShares":{"description":"Sum of side0 + side1 token atoms over every holder of the market.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["items","holderCount","totalShares","nextOffset"],"type":"object"},"InviteRedeemRequest":{"additionalProperties":false,"properties":{"ticket":{"maxLength":128,"minLength":1,"type":"string"}},"required":["ticket"],"type":"object"},"InviteReserveRequest":{"additionalProperties":false,"properties":{"code":{"maxLength":64,"minLength":1,"type":"string"}},"required":["code"],"type":"object"},"InviteTicket":{"additionalProperties":false,"properties":{"expiresAt":{"format":"date-time","type":"string"},"ticket":{"minLength":1,"type":"string"}},"required":["ticket","expiresAt"],"type":"object"},"IssueBackofficeInvitesBody":{"additionalProperties":false,"properties":{"campaign":{"maxLength":64,"type":["string","null"]},"count":{"maximum":100,"minimum":1,"type":"integer"}},"required":["count"],"type":"object"},"IssuedBackofficeInvites":{"additionalProperties":false,"properties":{"campaign":{"type":["string","null"]},"codes":{"items":{"minLength":1,"type":"string"},"type":"array"},"issuedAt":{"format":"date-time","type":"string"}},"required":["codes","campaign","issuedAt"],"type":"object"},"LabAttachBody":{"additionalProperties":false,"description":"The market is the path, and the caller is the session. Parameters and seed are the fleet's to choose.","properties":{"definitionSlug":{"maxLength":128,"minLength":1,"type":"string"},"definitionVersion":{"exclusiveMinimum":0,"type":"integer"}},"required":["definitionSlug"],"type":"object"},"LabDefinition":{"additionalProperties":false,"properties":{"blurb":{"minLength":1,"type":"string"},"name":{"minLength":1,"type":"string"},"slug":{"minLength":1,"type":"string"},"version":{"exclusiveMinimum":0,"type":"integer"}},"required":["slug","version","name","blurb"],"type":"object"},"LabDefinitions":{"additionalProperties":false,"properties":{"botsAdminUrl":{"description":"Where an operator opens the full fleet view, or null when this deployment publishes none. Display only.","type":["string","null"]},"definitions":{"items":{"$ref":"#/components/schemas/LabDefinition"},"type":"array"}},"required":["definitions","botsAdminUrl"],"type":"object"},"LabRun":{"additionalProperties":false,"properties":{"contributedVolumeUq":{"description":"Quote atoms this run has traded on this market.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"definitionName":{"minLength":1,"type":"string"},"definitionSlug":{"minLength":1,"type":"string"},"definitionVersion":{"exclusiveMinimum":0,"type":"integer"},"id":{"description":"The fleet's own id for this run.","format":"uuid","type":"string"},"seed":{"minLength":1,"type":"string"},"startedAt":{"format":"date-time","type":["string","null"]},"state":{"$ref":"#/components/schemas/LabRunState"},"status":{"enum":["running","stopped","failed"],"type":"string"},"tradeCount":{"description":"Fills this run has landed, or null when the fleet has not reported yet. Never a confident zero.","minimum":0,"type":["integer","null"]}},"required":["id","definitionSlug","definitionName","definitionVersion","status","state","startedAt","tradeCount","contributedVolumeUq","seed"],"type":"object"},"LabRunState":{"enum":["failed","stopped","below_floor","cooling_down","resuming","past_due","at_target","warming_up","holding","running"],"type":"string"},"LabRuns":{"additionalProperties":false,"properties":{"items":{"items":{"$ref":"#/components/schemas/LabRun"},"type":"array"}},"required":["items"],"type":"object"},"Leaderboard":{"additionalProperties":false,"properties":{"assets":{"description":"Every asset an entry's `byAsset` names.","items":{"$ref":"#/components/schemas/LeaderboardAsset"},"type":"array"},"entries":{"items":{"$ref":"#/components/schemas/LeaderboardEntry"},"type":"array"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"rangeHours":{"exclusiveMinimum":0,"type":["number","null"]}},"required":["rangeHours","assets","entries","projectionStatus"],"type":"object"},"LeaderboardAsset":{"additionalProperties":false,"properties":{"decimals":{"maximum":18,"minimum":0,"type":"integer"},"mint":{"maxLength":64,"minLength":32,"type":"string"},"symbol":{"maxLength":32,"minLength":1,"type":"string"}},"required":["mint","symbol","decimals"],"type":"object"},"LeaderboardAssetFigures":{"additionalProperties":false,"properties":{"mint":{"maxLength":64,"minLength":32,"type":"string"},"realizedPnlAtoms":{"description":"Realized quote cash-flow plus mark-to-market of open holdings at the side price, in atoms of `mint`, truncated toward zero.","maxLength":40,"pattern":"^-?(0|[1-9][0-9]*)$","type":"string"},"volumeAtoms":{"description":"Quote spent plus quote received, in atoms of `mint`.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["mint","realizedPnlAtoms","volumeAtoms"],"type":"object"},"LeaderboardBestTrade":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"roi":{"type":"number"},"side":{"$ref":"#/components/schemas/SideIndex"}},"required":["marketId","side","roi"],"type":["object","null"]},"LeaderboardEntry":{"additionalProperties":false,"properties":{"bestTrade":{"$ref":"#/components/schemas/LeaderboardBestTrade"},"byAsset":{"items":{"$ref":"#/components/schemas/LeaderboardAssetFigures"},"type":"array"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"realizedPnlUsd":{"description":"Profit in dollars, the rank key: the stamped cash flow in dollars at each trade's time, plus open positions and any trade with no stamped rate valued at its asset's rate now, summed across assets. Null when an asset whose unstamped flow plus open mark is not zero has no rate now; a null ranks after every figure.","type":["number","null"]},"volumeUsd":{"description":"Volume in dollars: the stamped volume at each trade's time, plus the unstamped volume at the rate now; null on the same rule.","type":["number","null"]},"winRate":{"maximum":1,"minimum":0,"type":["number","null"]}},"required":["principalId","byAsset","realizedPnlUsd","volumeUsd","winRate","bestTrade"],"type":"object"},"ListTagCatalogResponse":{"additionalProperties":false,"properties":{"tags":{"items":{"additionalProperties":false,"properties":{"active":{"type":"boolean"},"curated":{"type":"boolean"},"label":{"maxLength":64,"minLength":1,"type":"string"},"slug":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"sortOrder":{"type":"integer"}},"required":["slug","label","sortOrder","curated","active"],"type":"object"},"type":"array"}},"required":["tags"],"type":"object"},"MarketChain":{"additionalProperties":false,"properties":{"address":{"description":"The market's program-derived address on Solana.","maxLength":64,"minLength":32,"type":"string"},"origin":{"description":"`app` for markets this app created; `foreign` for permissionless markets on the same program id, which are ingested unlisted.","enum":["app","foreign"],"type":"string"},"quantum":{"description":"How many uq one atom of `quoteMint` is worth on THIS market's grid — the market's own unit, copied from the quote listing at creation. Every price, TVL and candle this API states is in quote atoms through it, so it is NOT a function of `quoteDecimals`: two markets in the same mint can carry different quanta. An integer safely below 2^53, because the program's listing rule bounds it.","minimum":1,"type":"integer"},"quoteDecimals":{"description":"Decimals of `quoteMint`. 6 for the pinned testUSDC mint.","maximum":18,"minimum":0,"type":"integer"},"quoteMint":{"description":"The SPL mint the market is denominated in.","maxLength":64,"minLength":32,"type":"string"},"quoteSymbol":{"description":"The ticker `quoteMint` is printed under — the one name the product prints for it, never read from the mint's own metadata.","maxLength":32,"minLength":1,"type":"string"},"sideMints":{"description":"The two outcome SPL mints, `[yes, no]` — the contract address of each side's token. Derived from `address` under the selected program id, so it is the same pair the program itself derives. `null` only for an `address` that decodes to no public key, which no ingested market has.","prefixItems":[{"maxLength":64,"minLength":32,"type":"string"},{"maxLength":64,"minLength":32,"type":"string"}],"type":["array","null"]}},"required":["address","quoteMint","quoteDecimals","quantum","origin","quoteSymbol","sideMints"],"type":"object"},"MarketDetail":{"additionalProperties":false,"properties":{"chain":{"$ref":"#/components/schemas/MarketChain"},"consensusYes":{"$ref":"#/components/schemas/RatJson"},"createdAt":{"format":"date-time","type":"string"},"creatorId":{"$ref":"#/components/schemas/PrincipalId"},"creatorUsername":{"type":["string","null"]},"id":{"$ref":"#/components/schemas/MarketId"},"imageUrl":{"description":"Absolute https URL, or the server-relative path of an image uploaded to this app (`/media/uploads/<uuid>`).","maxLength":512,"type":["string","null"]},"lastSeq":{"minimum":0,"type":"integer"},"prices":{"$ref":"#/components/schemas/PricePair"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"promotedAt":{"description":"Block time of the market's first `MarketPromoted` event; `null` until the market is promoted.","format":"date-time","type":["string","null"]},"promotionThreshold":{"description":"Atoms of `chain.quoteMint` the engine's cash must reach before the market can be promoted — the unit `tvl` is stated in. `null` when no `MarketCreated` carrying a threshold has been ingested.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"question":{"maxLength":512,"minLength":1,"type":"string"},"sideLabels":{"$ref":"#/components/schemas/SideLabels"},"sideTickers":{"$ref":"#/components/schemas/SideTickers"},"social":{"$ref":"#/components/schemas/MarketSocial"},"supply":{"$ref":"#/components/schemas/SupplyPair"},"tags":{"items":{"type":"string"},"type":"array"},"tickerBase":{"$ref":"#/components/schemas/TickerBase"},"tradingPaused":{"type":"boolean"},"tvl":{"$ref":"#/components/schemas/RatJson"},"volume24h":{"$ref":"#/components/schemas/RatJson"}},"required":["id","question","sideLabels","creatorId","creatorUsername","createdAt","prices","consensusYes","tvl","volume24h","supply","lastSeq","projectionStatus","imageUrl","tags","tradingPaused","tickerBase","sideTickers","social","promotedAt","promotionThreshold","chain"],"type":"object"},"MarketFeeSeat":{"additionalProperties":false,"properties":{"accrued":{"description":"Accrued and not yet swept, in the market's quote atoms — what a claim would move now. A sweep zeroes it.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"collected":{"description":"Swept all-time, in the market's quote atoms. Above zero exactly when the seat has claimed.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"wallet":{"description":"The seat's wallet as the chain last stated it; `null` for an unset seat.","maxLength":64,"minLength":32,"type":["string","null"]}},"required":["wallet","accrued","collected"],"type":"object"},"MarketFees":{"additionalProperties":false,"properties":{"beneficiary":{"$ref":"#/components/schemas/MarketFeeSeat"},"creator":{"$ref":"#/components/schemas/MarketFeeSeat"},"marketId":{"$ref":"#/components/schemas/MarketId"}},"required":["marketId","creator","beneficiary"],"type":"object"},"MarketId":{"format":"uuid","type":"string"},"MarketImageUrl":{"maxLength":512,"type":"string"},"MarketObservation":{"additionalProperties":false,"properties":{"consensusYes":{"$ref":"#/components/schemas/RatJson"},"prices":{"$ref":"#/components/schemas/PricePair"},"supply":{"$ref":"#/components/schemas/SupplyPair"},"tvl":{"$ref":"#/components/schemas/RatJson"}},"required":["prices","consensusYes","tvl","supply"],"type":"object"},"MarketSearchResponse":{"additionalProperties":false,"properties":{"hasMore":{"type":"boolean"},"markets":{"items":{"$ref":"#/components/schemas/MarketSummary"},"type":"array"}},"required":["markets","hasMore"],"type":"object"},"MarketSocial":{"additionalProperties":false,"properties":{"handle":{"pattern":"^[A-Za-z0-9_]{1,15}$","type":"string"},"platform":{"enum":["x","github"],"type":"string"}},"required":["platform","handle"],"type":["object","null"]},"MarketStats":{"additionalProperties":false,"properties":{"lastSeq":{"minimum":0,"type":"integer"},"marketId":{"$ref":"#/components/schemas/MarketId"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"tradeCount":{"minimum":0,"type":"integer"},"volumeUq":{"description":"Cumulative quote through this market in uq: `quoteIn + quoteOut`, counting every actor's trades and not the caller's. The denominator the bot service measures a volume target against.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["marketId","lastSeq","tradeCount","volumeUq","projectionStatus"],"type":"object"},"MarketSummary":{"additionalProperties":false,"properties":{"chain":{"$ref":"#/components/schemas/MarketChain"},"consensusYes":{"$ref":"#/components/schemas/RatJson"},"createdAt":{"format":"date-time","type":"string"},"creatorId":{"$ref":"#/components/schemas/PrincipalId"},"creatorUsername":{"type":["string","null"]},"id":{"$ref":"#/components/schemas/MarketId"},"imageUrl":{"description":"Absolute https URL, or the server-relative path of an image uploaded to this app (`/media/uploads/<uuid>`).","maxLength":512,"type":["string","null"]},"lastSeq":{"minimum":0,"type":"integer"},"prices":{"$ref":"#/components/schemas/PricePair"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"},"promotedAt":{"description":"Block time of the market's first `MarketPromoted` event; `null` until the market is promoted.","format":"date-time","type":["string","null"]},"promotionThreshold":{"description":"Atoms of `chain.quoteMint` the engine's cash must reach before the market can be promoted — the unit `tvl` is stated in. `null` when no `MarketCreated` carrying a threshold has been ingested.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":["string","null"]},"question":{"maxLength":512,"minLength":1,"type":"string"},"sideLabels":{"$ref":"#/components/schemas/SideLabels"},"sideTickers":{"$ref":"#/components/schemas/SideTickers"},"social":{"$ref":"#/components/schemas/MarketSocial"},"supply":{"$ref":"#/components/schemas/SupplyPair"},"tags":{"items":{"type":"string"},"type":"array"},"tickerBase":{"$ref":"#/components/schemas/TickerBase"},"tradingPaused":{"type":"boolean"},"tvl":{"$ref":"#/components/schemas/RatJson"},"volume24h":{"$ref":"#/components/schemas/RatJson"}},"required":["id","question","sideLabels","creatorId","creatorUsername","createdAt","prices","consensusYes","tvl","volume24h","supply","lastSeq","projectionStatus","imageUrl","tags","tradingPaused","tickerBase","sideTickers","social","promotedAt","promotionThreshold","chain"],"type":"object"},"MarketsPage":{"additionalProperties":false,"properties":{"items":{"items":{"$ref":"#/components/schemas/MarketSummary"},"maxItems":200,"type":"array"},"nextOffset":{"description":"Offset of the next page, or null when this page exhausted the listed set.","minimum":0,"type":["integer","null"]}},"required":["items","nextOffset"],"type":"object"},"NullableChartCandle":{"additionalProperties":false,"description":"Newest bucket strictly before `from`, so a window opening on a quiet stretch still has an honest last close to extend. Null when the window opens at the series' own start.","properties":{"bucketStart":{"description":"Bucket start in epoch seconds, UTC, floored to the grid.","type":"integer"},"infoBits":{"description":"Information the bucket's trades carried, in bits: the SUM of each trade's Kullback-Leibler divergence against the belief it found, never their net. Two opposing trades inside one bucket therefore report both moves rather than cancelling. Never negative.","minimum":0,"type":"number"},"sides":{"prefixItems":[{"$ref":"#/components/schemas/PriceOhlc"},{"$ref":"#/components/schemas/PriceOhlc"}],"type":"array"},"supply":{"prefixItems":[{"description":"Outstanding supply of side 0 in token atoms, at the close.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},{"description":"Outstanding supply of side 1 in token atoms, at the close.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}],"type":"array"},"tradeCount":{"description":"Trades folded into this bucket. Always positive: a bucket with no trades is absent from the series, never a fabricated zero.","exclusiveMinimum":0,"type":"integer"},"volumeUq":{"description":"Exact uq gross that moved through this bucket.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["bucketStart","sides","volumeUq","supply","tradeCount","infoBits"],"type":["object","null"]},"NullableChartTvlPoint":{"additionalProperties":false,"description":"The anchor bucket's TVL and consensus, on the same terms as `NullableChartCandle`.","properties":{"bucketStart":{"type":"integer"},"consensusYes":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"The crowd's split at the bucket's close, in `0..1`. The consensus view of the chart is drawn from this, on the window the request already carries."}]},"tvl":{"allOf":[{"$ref":"#/components/schemas/RatJson"},{"description":"Value locked at the bucket's close, in uq. Not a cash counter: a donation straight into the vault moves no point here."}]}},"required":["bucketStart","tvl","consensusYes"],"type":["object","null"]},"NullableRatJson":{"additionalProperties":false,"description":"Exact rational `num/den`, or null where it is not defined.","properties":{"den":{"pattern":"^[1-9][0-9]*$","type":"string"},"num":{"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["num","den"],"type":["object","null"]},"NullableSignedRatJson":{"anyOf":[{"$ref":"#/components/schemas/SignedRatJson"},{"type":"null"},{"type":"null"}],"description":"Exact signed rational `num/den` as decimal integer strings, or null where the figure is not defined. Each field that carries it states its unit and when it is null."},"PassReasonBody":{"additionalProperties":false,"properties":{"reason":{"maxLength":280,"minLength":1,"type":"string"}},"required":["reason"],"type":"object"},"PatchProfileRequest":{"additionalProperties":false,"properties":{"acceptTerms":{"type":"boolean"},"username":{"maxLength":64,"minLength":1,"type":"string"}},"type":"object"},"PayWith":{"description":"`usdc` is the deployment's stablecoin, `sol` is SOL and `market` is the asset the market is quoted in, which is never converted.","enum":["usdc","sol","market"],"type":"string"},"Position":{"additionalProperties":false,"properties":{"cash":{"deprecated":true,"description":"Deprecated compatibility field. Spendable cash is in the principal wallet and this value is always \"0\".","enum":["0"],"type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"side0":{"description":"Token atoms held on side 0.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},"side1":{"description":"Token atoms held on side 1.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["marketId","principalId","cash","side0","side1"],"type":"object"},"PriceOhlc":{"additionalProperties":false,"description":"Exact per-side OHLC over one bucket, in atoms of the market's quote asset per token atom. Open is the first post-trade price in the bucket; close is the last. Never pre-divided.","properties":{"close":{"$ref":"#/components/schemas/RatJson"},"high":{"$ref":"#/components/schemas/RatJson"},"low":{"$ref":"#/components/schemas/RatJson"},"open":{"$ref":"#/components/schemas/RatJson"}},"required":["open","high","low","close"],"type":"object"},"PricePair":{"prefixItems":[{"$ref":"#/components/schemas/RatJson"},{"$ref":"#/components/schemas/RatJson"}],"type":"array"},"PrincipalDisplay":{"additionalProperties":false,"properties":{"principalId":{"$ref":"#/components/schemas/PrincipalId"},"username":{"type":["string","null"]}},"required":["principalId","username"],"type":"object"},"PrincipalId":{"maxLength":128,"minLength":1,"type":"string"},"PrincipalsResponse":{"additionalProperties":false,"properties":{"principals":{"items":{"$ref":"#/components/schemas/PrincipalDisplay"},"type":"array"}},"required":["principals"],"type":"object"},"ProfileView":{"additionalProperties":false,"properties":{"principalId":{"$ref":"#/components/schemas/PrincipalId"},"profileComplete":{"type":"boolean"},"termsAcceptedAt":{"format":"date-time","type":["string","null"]},"termsVersion":{"type":["string","null"]},"username":{"type":["string","null"]},"usernameUpdatedAt":{"format":"date-time","type":["string","null"]}},"required":["principalId","username","usernameUpdatedAt","termsVersion","termsAcceptedAt","profileComplete"],"type":"object"},"ProjectionStatus":{"enum":["pending","partial","ready"],"type":"string"},"RatJson":{"additionalProperties":false,"description":"Exact rational `num/den` as decimal integer strings. Never pre-divided: both sides can exceed 2^53, so clients must divide with big integers.","properties":{"den":{"pattern":"^[1-9][0-9]*$","type":"string"},"num":{"pattern":"^(0|[1-9][0-9]*)$","type":"string"}},"required":["num","den"],"type":"object"},"ReleaseBackofficeGatePassResult":{"additionalProperties":false,"properties":{"releasedAddress":{"minLength":1,"type":"string"}},"required":["releasedAddress"],"type":"object"},"RevokeAllSessionsResponse":{"additionalProperties":false,"properties":{"revoked":{"enum":[true],"type":"boolean"},"revokedCount":{"minimum":0,"type":"integer"}},"required":["revoked","revokedCount"],"type":"object"},"RevokeBackofficeGatePassResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"}},"required":["changed"],"type":"object"},"RevokeBackofficeInviteCampaignBody":{"additionalProperties":false,"properties":{"campaign":{"maxLength":64,"minLength":1,"type":"string"}},"required":["campaign"],"type":"object"},"RevokeBackofficeInviteCampaignResult":{"additionalProperties":false,"properties":{"revoked":{"minimum":0,"type":"integer"}},"required":["revoked"],"type":"object"},"RevokeBackofficeInviteResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"}},"required":["changed"],"type":"object"},"RevokeSessionResponse":{"additionalProperties":false,"properties":{"revoked":{"enum":[true],"type":"boolean"}},"required":["revoked"],"type":"object"},"SessionView":{"additionalProperties":false,"properties":{"address":{"$ref":"#/components/schemas/WalletAddress"},"expiresAt":{"format":"date-time","type":"string"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"profileComplete":{"type":"boolean"},"role":{"enum":["user","operator","admin"],"type":"string"},"sessionId":{"format":"uuid","type":"string"},"termsAcceptedAt":{"format":"date-time","type":["string","null"]},"username":{"type":["string","null"]}},"required":["sessionId","principalId","address","role","expiresAt","username","termsAcceptedAt","profileComplete"],"type":"object"},"SetBackofficeAdminParameterBody":{"additionalProperties":false,"properties":{"value":{"anyOf":[{"type":"boolean"},{"type":"integer"}]}},"required":["value"],"type":"object"},"SetBackofficeAdminParameterResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"},"id":{"minLength":1,"type":"string"},"newValue":{"anyOf":[{"type":"boolean"},{"type":"integer"}]},"previousValue":{"anyOf":[{"type":"boolean"},{"type":"integer"}]},"previousWasDefault":{"type":"boolean"}},"required":["id","previousValue","newValue","previousWasDefault","changed"],"type":"object"},"SetBackofficeAdminPrincipalRoleBody":{"additionalProperties":false,"properties":{"role":{"enum":["user","operator","admin"],"type":"string"}},"required":["role"],"type":"object"},"SetBackofficeAdminPrincipalRoleResult":{"additionalProperties":false,"properties":{"bootstrap":{"type":"boolean"},"changed":{"type":"boolean"},"previousRole":{"enum":["user","operator","admin"],"type":"string"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"role":{"enum":["user","operator","admin"],"type":"string"}},"required":["principalId","previousRole","role","changed","bootstrap"],"type":"object"},"SetBackofficeAdminPrincipalSuspensionBody":{"additionalProperties":false,"properties":{"reason":{"maxLength":500,"minLength":1,"type":["string","null"]},"suspended":{"type":"boolean"}},"required":["suspended"],"type":"object"},"SetBackofficeAdminPrincipalSuspensionResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"},"principalId":{"$ref":"#/components/schemas/PrincipalId"},"revokedSessionCount":{"minimum":0,"type":"integer"},"suspended":{"type":"boolean"},"suspendedAt":{"format":"date-time","type":["string","null"]}},"required":["principalId","suspended","changed","suspendedAt","revokedSessionCount"],"type":"object"},"SetBackofficeMarketModerationBody":{"additionalProperties":false,"properties":{"reason":{"description":"Free-text reason recorded on the audit row. Required by the panel for takedown and restore; hide and unhide send none.","maxLength":1000,"minLength":1,"type":["string","null"]}},"type":"object"},"SetBackofficeMarketSocialLinkBody":{"additionalProperties":false,"properties":{"social":{"additionalProperties":false,"properties":{"handle":{"description":"Handle of the person the market is about, who receives the market's beneficiary fee share. Accepts `name`, `@name`, or a profile URL on the named platform (x.com/twitter.com, github.com); stored as the stripped handle.","maxLength":256,"minLength":1,"type":"string"},"platform":{"enum":["x","github"],"type":"string"}},"required":["platform","handle"],"type":["object","null"]}},"required":["social"],"type":"object"},"SetBackofficeMarketSocialLinkResult":{"additionalProperties":false,"properties":{"action":{"enum":["set","clear"],"type":"string"},"changed":{"type":"boolean"},"marketId":{"$ref":"#/components/schemas/MarketId"},"previousSocial":{"$ref":"#/components/schemas/MarketSocial"},"social":{"$ref":"#/components/schemas/MarketSocial"}},"required":["marketId","previousSocial","social","changed","action"],"type":"object"},"SetBackofficeMarketSpamFlagBody":{"additionalProperties":false,"properties":{"spamFlag":{"type":"boolean"}},"required":["spamFlag"],"type":"object"},"SetBackofficeMarketSpamFlagResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"},"marketId":{"$ref":"#/components/schemas/MarketId"},"previousSpamFlag":{"type":"boolean"},"spamFlag":{"type":"boolean"}},"required":["marketId","previousSpamFlag","spamFlag","changed"],"type":"object"},"SetBackofficeMarketTagsBody":{"additionalProperties":false,"properties":{"tags":{"items":{"type":"string"},"type":"array"}},"required":["tags"],"type":"object"},"SetBackofficeMarketTagsResult":{"additionalProperties":false,"properties":{"changed":{"type":"boolean"},"marketId":{"$ref":"#/components/schemas/MarketId"},"previousTags":{"items":{"type":"string"},"type":"array"},"tags":{"items":{"type":"string"},"type":"array"}},"required":["marketId","previousTags","tags","changed"],"type":"object"},"SideIndex":{"anyOf":[{"enum":[0],"type":"number"},{"enum":[1],"type":"number"}]},"SideLabels":{"prefixItems":[{"maxLength":64,"minLength":1,"type":"string"},{"maxLength":64,"minLength":1,"type":"string"}],"type":"array"},"SideTickers":{"prefixItems":[{"pattern":"^[A-Z0-9]{1,8}$","type":"string"},{"pattern":"^[A-Z0-9]{1,8}$","type":"string"}],"type":["array","null"]},"SignedRatJson":{"additionalProperties":false,"description":"Exact signed rational `num/den` as decimal integer strings. Never pre-divided.","properties":{"den":{"pattern":"^[1-9][0-9]*$","type":"string"},"num":{"pattern":"^-?(0|[1-9][0-9]*)$","type":"string"}},"required":["num","den"],"type":"object"},"SiwsProof":{"additionalProperties":false,"properties":{"message":{"maxLength":2048,"minLength":1,"type":"string"},"signature":{"maxLength":128,"minLength":1,"type":"string"}},"required":["message","signature"],"type":"object"},"SparklineSeries":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"points":{"items":{"type":"number"},"type":"array"},"projectionStatus":{"$ref":"#/components/schemas/ProjectionStatus"}},"required":["marketId","points","projectionStatus"],"type":"object"},"SpotlightResponse":{"additionalProperties":false,"properties":{"computedAt":{"type":"string"},"slots":{"items":{"$ref":"#/components/schemas/SpotlightSlot"},"maxItems":9,"type":"array"}},"required":["slots","computedAt"],"type":"object"},"SpotlightSlot":{"additionalProperties":false,"properties":{"category":{"enum":["most_traded","just_launched","whale_print","move_of_the_day"],"type":"string"},"marketId":{"$ref":"#/components/schemas/MarketId"},"metric":{"type":"string"},"tag":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"}},"required":["category","marketId","metric"],"type":"object"},"SupplyPair":{"prefixItems":[{"description":"Outstanding token supply on this side, in token atoms (1 token = \"1000000\"). Never pre-divided into whole tokens.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"},{"description":"Outstanding token supply on this side, in token atoms (1 token = \"1000000\"). Never pre-divided into whole tokens.","maxLength":39,"pattern":"^(0|[1-9][0-9]*)$","type":"string"}],"type":"array"},"TagCatalogAdminEntry":{"allOf":[{"$ref":"#/components/schemas/TagCatalogEntry"},{"additionalProperties":false,"properties":{"usageCount":{"minimum":0,"type":"integer"}},"required":["usageCount"],"type":"object"}]},"TagCatalogEntry":{"additionalProperties":false,"properties":{"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"curated":{"type":"boolean"},"label":{"maxLength":64,"minLength":1,"type":"string"},"promotedBy":{"type":["string","null"]},"slug":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"},"sortOrder":{"type":"integer"}},"required":["slug","label","sortOrder","curated","active","createdAt","promotedBy"],"type":"object"},"TickerBase":{"pattern":"^[A-Z0-9]{1,8}$","type":["string","null"]},"TickerPairAnswer":{"oneOf":[{"additionalProperties":false,"properties":{"kind":{"enum":["free"],"type":"string"}},"required":["kind"],"type":"object"},{"additionalProperties":false,"properties":{"kind":{"enum":["crowned"],"type":"string"},"market":{"anyOf":[{"$ref":"#/components/schemas/TickerPairMarket"},{"type":"null"},{"type":"null"}],"description":"The promoted market that holds the pair, for good. Null when that market is not visible, so nothing names it."}},"required":["kind","market"],"type":"object"},{"additionalProperties":false,"properties":{"closest":{"$ref":"#/components/schemas/TickerPairMarket"},"kind":{"enum":["shared"],"type":"string"},"more":{"description":"How many other visible markets share the pair.","minimum":0,"type":"integer"}},"required":["kind","closest","more"],"type":"object"}]},"TickerPairLookup":{"additionalProperties":false,"properties":{"answer":{"$ref":"#/components/schemas/TickerPairAnswer"},"base":{"allOf":[{"$ref":"#/components/schemas/TickerBase"},{"type":"string"}]},"no":{"pattern":"^[A-Z0-9]{1,8}$","type":"string"},"yes":{"pattern":"^[A-Z0-9]{1,8}$","type":"string"}},"required":["base","yes","no","answer"],"type":"object"},"TickerPairMarket":{"additionalProperties":false,"properties":{"marketId":{"$ref":"#/components/schemas/MarketId"},"question":{"type":"string"}},"required":["marketId","question"],"type":"object"},"UpdateBackofficeAssetBody":{"additionalProperties":false,"properties":{"canDeposit":{"type":"boolean"},"canQuoteMarkets":{"type":"boolean"},"category":{"$ref":"#/components/schemas/AssetCategory"},"logoMediaId":{"maxLength":64,"minLength":1,"type":["string","null"]},"name":{"maxLength":128,"minLength":1,"type":"string"},"pinned":{"type":"boolean"},"rateSource":{"$ref":"#/components/schemas/BackofficeAssetRateSource"},"sortOrder":{"type":"integer"},"symbol":{"maxLength":16,"minLength":1,"type":"string"}},"type":"object"},"UpdateBackofficeTagBody":{"additionalProperties":false,"properties":{"active":{"type":"boolean"},"curated":{"type":"boolean"},"label":{"maxLength":64,"minLength":1,"type":"string"},"sortOrder":{"type":"integer"}},"type":"object"},"UploadMarketImageBody":{"additionalProperties":false,"properties":{"file":{"format":"binary","type":"string"}},"required":["file"],"type":"object"},"UploadMarketImageResult":{"additionalProperties":false,"properties":{"imageId":{"format":"uuid","type":"string"},"imageUrl":{"description":"Server-relative path the stored image is served from. Pass it back as `imageUrl` on create.","example":"/media/uploads/2f1c1e2a-4d5b-4a3f-9c8e-7b6a5d4c3b2a","maxLength":512,"type":"string"}},"required":["imageId","imageUrl"],"type":"object"},"UsernameAvailabilityResponse":{"additionalProperties":false,"properties":{"available":{"type":"boolean"},"reason":{"enum":["USERNAME_INVALID","USERNAME_RESERVED","USERNAME_TAKEN"],"type":"string"},"username":{"type":"string"}},"required":["username","available"],"type":"object"},"WalletAddress":{"maxLength":128,"minLength":1,"type":"string"}},"securitySchemes":{"sessionBearer":{"description":"R8 session token (r8s_…), issued once by POST /auth/session in exchange for a Privy access token.","scheme":"bearer","type":"http"}}},"info":{"description":"Versioned on-chain market, trading, portfolio, wallet-session, profile, tag, and backoffice REST contract.","title":"R8 API","version":"1.0.0"},"openapi":"3.1.0","paths":{"/api/v1/activity":{"get":{"description":"Recent trades, newest first. A request names a subject — `marketId` or `principalId` — or it is the global tape, which is answered only while it stays bounded: an unscoped read states a `limit` of at most 50 and cannot page (`R8-P15-10`).","operationId":"listActivity","parameters":[{"in":"query","name":"marketId","required":false,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"principalId","required":false,"schema":{"$ref":"#/components/schemas/PrincipalId"}},{"in":"query","name":"limit","required":false,"schema":{"exclusiveMinimum":0,"maximum":200,"type":"integer"}},{"in":"query","name":"beforeTime","required":false,"schema":{"type":["number","null"]}},{"in":"query","name":"beforeMarketId","required":false,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"beforeSeq","required":false,"schema":{"minimum":0,"type":["integer","null"]}},{"in":"query","name":"beforeEventId","required":false,"schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityPage"}}},"description":"Recent activity page"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["activity"]}},"/api/v1/assets":{"get":{"operationId":"listAssets","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssetsResponse"}}},"description":"The assets this deployment lists, pinned first"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["assets"]}},"/api/v1/auth/session":{"delete":{"operationId":"deleteWalletSession","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeSessionResponse"}}},"description":"Session revoked"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unverifiable Privy token, or a missing, expired, or revoked session"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["auth"]},"get":{"operationId":"getWalletSession","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionView"}}},"description":"Current wallet session (no token)"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unverifiable Privy token, or a missing, expired, or revoked session"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["auth"]},"post":{"operationId":"createSession","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSessionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSessionResponse"}}},"description":"Issued wallet session (token shown once)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Auth request validation failure"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unverifiable Privy token, or a missing, expired, or revoked session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden role, or a suspended principal"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"ACCOUNT_ADDRESS_MISMATCH: the identity does not present the account's one Solana address (ADR 0043); nothing is merged or stored"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Privy identity carries no usable Solana wallet address"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Auth rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Identity provider verification keys are unavailable"}},"tags":["auth"]}},"/api/v1/auth/sessions":{"delete":{"operationId":"deleteWalletSessions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeAllSessionsResponse"}}},"description":"Every live session for the caller's principal revoked"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unverifiable Privy token, or a missing, expired, or revoked session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden role, or a suspended principal"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["auth"]}},"/api/v1/backoffice/admin/analytics":{"get":{"operationId":"readBackofficeAnalytics","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAnalytics"}}},"description":"Fees, claims and volume per quote asset over today, 7 days, 30 days and all time, and user counts"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/audit":{"get":{"operationId":"listBackofficeAdminAudit","parameters":[{"in":"query","name":"event","required":false,"schema":{"maxLength":128,"minLength":1,"type":"string"}},{"in":"query","name":"actorPrincipalId","required":false,"schema":{"$ref":"#/components/schemas/PrincipalId"}},{"in":"query","name":"subjectType","required":false,"schema":{"maxLength":64,"minLength":1,"type":"string"}},{"in":"query","name":"subjectId","required":false,"schema":{"maxLength":128,"minLength":1,"type":"string"}},{"in":"query","name":"from","required":false,"schema":{"format":"date-time","type":"string"}},{"in":"query","name":"to","required":false,"schema":{"format":"date-time","type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"cursor","required":false,"schema":{"maxLength":512,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAdminAudit"}}},"description":"Audit journal newest-first with keyset cursor"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/fee-margin":{"get":{"operationId":"readBackofficeFeeMargin","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeFeeMargin"}}},"description":"The day's network-fee spend, collections and the ratio between them"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate":{"get":{"operationId":"readBackofficeGate","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeGate"}}},"description":"The arm switch, the environment override, and the configured mints"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/invites":{"get":{"operationId":"listBackofficeInvites","parameters":[{"in":"query","name":"campaign","required":false,"schema":{"maxLength":64,"minLength":1,"type":"string"}},{"in":"query","name":"unlabelled","required":false,"schema":{"description":"When true, read only the codes issued with no campaign. Cannot be sent with campaign.","enum":["true","false"],"type":"string"}},{"in":"query","name":"state","required":false,"schema":{"enum":["all","live","used","revoked"],"type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"cursor","required":false,"schema":{"maxLength":512,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeInvites"}}},"description":"A page of invite codes, newest first, with the campaign's three figures"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]},"post":{"operationId":"issueBackofficeInvites","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IssueBackofficeInvitesBody"}}},"description":"How many codes to issue, and the campaign label that groups them"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IssuedBackofficeInvites"}}},"description":"The codes this batch made, also readable afterwards on the list route"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/invites/campaigns":{"get":{"operationId":"listBackofficeInviteCampaigns","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeInviteCampaigns"}}},"description":"Every campaign, newest-first, with its whole-campaign figures"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/invites/revoke-campaign":{"post":{"operationId":"revokeBackofficeInviteCampaign","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeBackofficeInviteCampaignBody"}}},"description":"The exact campaign label whose live codes stop working"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeBackofficeInviteCampaignResult"}}},"description":"How many live codes were revoked"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/invites/{id}/revoke":{"post":{"operationId":"revokeBackofficeInvite","parameters":[{"in":"path","name":"id","required":true,"schema":{"example":"0f5d5d4c-2f18-4a2e-9a2b-1b7a5f0b41c2","format":"uuid","type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeBackofficeInviteResult"}}},"description":"Whether this call was the one that revoked it"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/mints":{"post":{"operationId":"addBackofficeGateMint","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddBackofficeGateMintBody"}}},"description":"The mint to configure; the symbol is stored without its `$`"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeGateMint"}}},"description":"The configured mint"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/mints/{mint}/remove":{"post":{"operationId":"removeBackofficeGateMint","parameters":[{"in":"path","name":"mint","required":true,"schema":{"example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU","maxLength":64,"minLength":1,"type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeGateMint"}}},"description":"The removed mint"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/passes":{"get":{"operationId":"listBackofficeGatePasses","parameters":[{"in":"query","name":"q","required":false,"schema":{"maxLength":200,"minLength":1,"type":"string"}},{"in":"query","name":"door","required":false,"schema":{"enum":["token","invite","manual","before"],"type":"string"}},{"in":"query","name":"state","required":false,"schema":{"enum":["live","revoked","expired","none"],"type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"cursor","required":false,"schema":{"maxLength":512,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeGatePasses"}}},"description":"A page of accounts and how each one got in, with the four figures"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]},"post":{"operationId":"grantBackofficeGatePass","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GrantBackofficeGatePassBody"}}},"description":"The wallet to bind the pass to, if any, and the required reason"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GrantedBackofficeGatePass"}}},"description":"The claim link, shown once and never again"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"That wallet already opened an account; release its address first"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/passes/{passId}/release":{"post":{"operationId":"releaseBackofficeGatePassAddress","parameters":[{"in":"path","name":"passId","required":true,"schema":{"example":"5f2b1c8e-7a41-4d3f-9c2a-8e6b0d4f1a37","format":"uuid","type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PassReasonBody"}}},"description":"Why the address was released"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReleaseBackofficeGatePassResult"}}},"description":"The address that is free again"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Release refused: no such pass, not revoked, already released, or no wallet"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/gate/passes/{passId}/revoke":{"post":{"operationId":"revokeBackofficeGatePass","parameters":[{"in":"path","name":"passId","required":true,"schema":{"example":"5f2b1c8e-7a41-4d3f-9c2a-8e6b0d4f1a37","format":"uuid","type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PassReasonBody"}}},"description":"Why the pass was revoked"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeBackofficeGatePassResult"}}},"description":"Whether this call was the one that revoked it"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/health":{"get":{"operationId":"readBackofficeHealth","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeHealth"}}},"description":"Divergences, data freshness, worker liveness and queue depth"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/markets/{marketId}/restore":{"post":{"operationId":"restoreBackofficeMarket","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketModerationBody"}}},"description":"Optional reason, recorded on the audit row"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketModerationResult"}}},"description":"The moderation status the server wrote"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/markets/{marketId}/social-link":{"post":{"operationId":"setBackofficeMarketSocialLink","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketSocialLinkBody"}}},"description":"Social link set or clear (null)"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketSocialLinkResult"}}},"description":"Social link set/clear result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/markets/{marketId}/spam-flag":{"post":{"operationId":"setBackofficeMarketSpamFlag","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketSpamFlagBody"}}},"description":"Spam flag value"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketSpamFlagResult"}}},"description":"Spam flag set result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/markets/{marketId}/tags":{"post":{"operationId":"setBackofficeMarketTags","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketTagsBody"}}},"description":"Whole-set replacement (empty clears)"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketTagsResult"}}},"description":"Tag set result (changed may be false)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/markets/{marketId}/takedown":{"post":{"operationId":"takedownBackofficeMarket","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketModerationBody"}}},"description":"Optional reason, recorded on the audit row"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketModerationResult"}}},"description":"The moderation status the server wrote"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/parameters":{"get":{"operationId":"listBackofficeAdminParameters","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAdminParameters"}}},"description":"Whitelisted operational parameters with effective values"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/parameters/{parameterId}":{"post":{"operationId":"setBackofficeAdminParameter","parameters":[{"in":"path","name":"parameterId","required":true,"schema":{"example":"discovery.zero_coverage_hidden","minLength":1,"type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminParameterBody"}}},"description":"New parameter value"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminParameterResult"}}},"description":"Parameter set result (changed may be false)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/principals":{"get":{"operationId":"listBackofficeAdminPrincipals","parameters":[{"in":"query","name":"q","required":false,"schema":{"maxLength":200,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAdminPrincipals"}}},"description":"Privileged principals, or search hits when q is set"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/principals/{principalId}/role":{"post":{"operationId":"setBackofficeAdminPrincipalRole","parameters":[{"in":"path","name":"principalId","required":true,"schema":{"$ref":"#/components/schemas/PrincipalId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminPrincipalRoleBody"}}},"description":"Target role"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminPrincipalRoleResult"}}},"description":"Role change result (changed may be false)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/principals/{principalId}/suspension":{"post":{"operationId":"setBackofficeAdminPrincipalSuspension","parameters":[{"in":"path","name":"principalId","required":true,"schema":{"$ref":"#/components/schemas/PrincipalId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminPrincipalSuspensionBody"}}},"description":"Target suspension state"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeAdminPrincipalSuspensionResult"}}},"description":"Suspension result (changed may be false)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/submissions":{"get":{"operationId":"listBackofficeSubmissions","parameters":[{"in":"query","name":"kind","required":false,"schema":{"$ref":"#/components/schemas/ChainSubmissionKind"}},{"in":"query","name":"status","required":false,"schema":{"$ref":"#/components/schemas/ChainSubmissionStatus"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"cursor","required":false,"schema":{"maxLength":512,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeSubmissions"}}},"description":"Chain submissions newest-first with keyset cursor"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/treasury":{"get":{"operationId":"readBackofficeTreasury","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeTreasury"}}},"description":"Funding wallet balances against their alert thresholds"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/treasury/grants/{grantId}":{"get":{"operationId":"readBackofficeTreasuryGrant","parameters":[{"in":"path","name":"grantId","required":true,"schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeTreasuryGrant"}}},"description":"The grant's status and the transaction it is on"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/treasury/top-up":{"post":{"operationId":"pressBackofficeTreasuryTopUp","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeTopUpBody"}}},"description":"The account to top up — wallet address or username — and the asset"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeTopUpResult"}}},"description":"The grant this press claimed, and its status after one delivery step"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"No treasury to press from, or no fresh rate for the asset"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/admin/treasury/withdraw":{"post":{"operationId":"pressBackofficeTreasuryWithdrawal","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeWithdrawBody"}}},"description":"The asset, one of the deployment's withdrawal addresses, and an amount in atoms or `all`"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeWithdrawResult"}}},"description":"The grant this press claimed, and its status after one delivery step"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The distributor's balance could not be read, or there is no treasury to press from"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/assets":{"get":{"operationId":"listBackofficeAssets","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAssets"}}},"description":"Every catalogue row with its last rate reading"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]},"post":{"operationId":"addBackofficeAsset","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddBackofficeAssetBody"}}},"description":"The row to list"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAsset"}}},"description":"The listed row"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The chain is not configured or unread"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/assets/chain":{"get":{"operationId":"readBackofficeAssetChain","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAssetChain"}}},"description":"The chain facts for every row in one batched read, or `unread`"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/assets/{mint}":{"delete":{"operationId":"removeBackofficeAsset","parameters":[{"in":"path","name":"mint","required":true,"schema":{"example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU","maxLength":64,"minLength":1,"type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAsset"}}},"description":"The row as it stood"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]},"patch":{"operationId":"updateBackofficeAsset","parameters":[{"in":"path","name":"mint","required":true,"schema":{"example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU","maxLength":64,"minLength":1,"type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateBackofficeAssetBody"}}},"description":"The fields to change"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAsset"}}},"description":"The row as it now stands"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The chain is not configured or unread"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/assets/{mint}/probe":{"post":{"operationId":"probeBackofficeAsset","parameters":[{"in":"path","name":"mint","required":true,"schema":{"example":"7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU","maxLength":64,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeAssetChainFacts"}}},"description":"The chain facts for one mint, read at confirmed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The chain is not configured or unread"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/context":{"get":{"operationId":"getBackofficeContext","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeContext"}}},"description":"Backoffice principal context and server-authored capability set"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/creators":{"get":{"operationId":"listBackofficeCreators","parameters":[{"in":"query","name":"quoteMint","required":false,"schema":{"description":"The asset to rank creators in. Default: the busiest asset — the one with the most measured markets. A ranking never spans assets.","maxLength":64,"minLength":32,"type":"string"}},{"in":"query","name":"sort","required":false,"schema":{"allOf":[{"$ref":"#/components/schemas/BackofficeCreatorsSort"},{"description":"Rank key. Default owed. One canonical direction per key; no dir field."}]}},{"in":"query","name":"limit","required":false,"schema":{"description":"Page size. Default 50, capped at 200.","maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"cursor","required":false,"schema":{"description":"Keyset continuation from the previous page's nextCursor.","maxLength":512,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeCreators"}}},"description":"Ranked creator earnings page with venue totals"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/mainnet-tokens":{"get":{"operationId":"searchBackofficeMainnetTokens","parameters":[{"in":"query","name":"query","required":false,"schema":{"description":"A ticker, a name or a mint address; required.","maxLength":64,"type":"string"}},{"in":"query","name":"copy","required":false,"schema":{"description":"The query is a devnet copy's ticker: search its original.","enum":["1"],"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMainnetTokens"}}},"description":"The mainnet tokens the query names, the likeliest twin first"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets":{"get":{"operationId":"listBackofficeMarkets","parameters":[{"in":"query","name":"type","required":false,"schema":{"allOf":[{"$ref":"#/components/schemas/BackofficeMarketType"},{"description":"Restrict to this market type. Omitted means all types."}]}},{"in":"query","name":"tag","required":false,"schema":{"description":"Exact tag slug match, including simulation-only markets.","pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"}},{"in":"query","name":"q","required":false,"schema":{"description":"Case-insensitive substring match on the market question (trimmed, 1–120).","maxLength":120,"minLength":1,"type":"string"}},{"in":"query","name":"hidden","required":false,"schema":{"description":"When \"only\", restrict to markets hidden from public discovery.","enum":["only"],"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketList"}}},"description":"Privileged market list with unfiltered world stats"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets/{marketId}":{"get":{"operationId":"getBackofficeMarketDetail","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketDetail"}}},"description":"Privileged market detail with series, run windows, and active run"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets/{marketId}/actors":{"get":{"operationId":"listBackofficeMarketActors","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"kind","required":false,"schema":{"description":"Restrict to organic or service actors. Omitted means all.","enum":["organic","service"],"type":"string"}},{"in":"query","name":"sort","required":false,"schema":{"description":"Sort key. Default volume.","enum":["volume","pnl","pnlPercent","stake","trades","last"],"type":"string"}},{"in":"query","name":"direction","required":false,"schema":{"description":"Sort direction. Default desc.","enum":["asc","desc"],"type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"description":"Max rows to return (1–500). Default 200.","maximum":500,"minimum":1,"type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketActors"}}},"description":"Actor analytics with server-side filter, sort, and leaders"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets/{marketId}/hide":{"post":{"operationId":"hideBackofficeMarket","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketModerationBody"}}},"description":"Optional reason, recorded on the audit row"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketModerationResult"}}},"description":"The moderation status the server wrote"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Refused: the market was taken down and only restore returns it"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets/{marketId}/tape":{"get":{"operationId":"listBackofficeMarketTape","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"limit","required":false,"schema":{"description":"Max rows to return (1–500). Default 200.","maximum":500,"minimum":1,"type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketTape"}}},"description":"Newest-first market tape, capped by the limit query parameter"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/markets/{marketId}/unhide":{"post":{"operationId":"unhideBackofficeMarket","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetBackofficeMarketModerationBody"}}},"description":"Optional reason, recorded on the audit row"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeMarketModerationResult"}}},"description":"The moderation status the server wrote"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market or record"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Refused: the market was taken down and only restore returns it"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/tags":{"get":{"operationId":"listBackofficeTags","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackofficeTagCatalogResponse"}}},"description":"Whole tag catalogue including retired and demoted rows"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]},"post":{"operationId":"createBackofficeTag","parameters":[{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBackofficeTagBody"}}},"description":"New catalogue tag"},"responses":{"201":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TagCatalogAdminEntry"}}},"description":"Created catalogue tag"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/backoffice/tags/{slug}":{"patch":{"operationId":"updateBackofficeTag","parameters":[{"in":"path","name":"slug","required":true,"schema":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateBackofficeTagBody"}}},"description":"Catalogue tag patch"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TagCatalogAdminEntry"}}},"description":"Updated catalogue tag"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid query"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Principal role below the required minimum"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Conflict with the record's current state"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["backoffice"]}},"/api/v1/chain/balances":{"get":{"operationId":"getChainBalances","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainBalances"}}},"description":"testUSDC and opinion-token holdings, read from chain token accounts"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/build":{"post":{"operationId":"buildChainTransaction","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainBuildBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainBuildResult"}}},"description":"An unsigned v1 message with the treasury as fee payer"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"A daily sponsorship budget is exhausted"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Sponsorship is paused or unavailable"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/claim/build":{"post":{"description":"Build one market's fee sweep for the seat the body names — the market's creator, or the wallet sitting in its beneficiary seat — received as the asset the body names: the market's own, or converted into SOL or the quote token inside the same message. Guards and a `built` row; nothing is signed or broadcast. An already-open charged claim for this principal and market is the answer whichever seat it sweeps and whatever the body asks, so a lost submit can be named. The claim is then signed and submitted through `POST /chain/submit`, exactly as a trade is. Its network cost is charged in the asset the response's `chargeMint` names, or in the swept seat's own token account when it names none, whose owner alone can authorise that debit.","operationId":"buildChainCreatorFeeClaim","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainClaimBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainClaimBuildResult"}}},"description":"A built row to sign, or the already-open charged claim"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The caller's wallet does not sit in the seat asked for, or that seat is unset"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Nothing has accrued, or less than the claim's own network charge"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The daily transaction cap is exhausted"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Sponsorship is paused or unavailable"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/claim/quote":{"post":{"description":"Quote one market's fee sweep for the seat the body names, received as the asset the body names, as the claim build would stage it: what arrives, the conversion's cost in its asset and in dollars, and the network cost. Nothing is stored, signed or broadcast. A refusal the build would give for the claim itself — a conversion below the minimum routed, no route, a claim that would cost more than it pays — is the body's `refusal` with every figure null, not an error. The conversion's figures are the build's own at the same accrued, held and rates; the network cost is an estimate where the build's is a measurement.","operationId":"quoteChainClaim","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainClaimBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainClaimQuote"}}},"description":"The quote of one claim, or the refusal its build would give"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The caller's wallet does not sit in the seat asked for, or that seat is unset"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/create/adopt":{"post":{"operationId":"adoptChainMarket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainAdoptBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainAdoptedMarket"}}},"description":"The market row, its address taken from the decoded MarketCreated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"No such submission, or the transaction is not yet served at confirmed"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/create/build":{"post":{"operationId":"buildChainMarketCreation","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainCreateBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainCreateResult"}}},"description":"One unsigned v1 message: create_market and the creator's network charge, with the treasury as payer"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The message would be refused on chain, the asset cannot back a market (`ASSET_UNKNOWN`, `ASSET_NOT_QUOTABLE`, `ASSET_NOT_LISTED`, `ASSET_LISTING_REFUSED`), or the subject the `social` handle names cannot hold a beneficiary wallet: `SUBJECT_NOT_FOUND`, `SUBJECT_SUSPENDED`, `SUBJECT_IS_ORGANIZATION`, or a crowned market already holds the ticker pair: `TICKER_PAIR_CROWNED`"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"A daily sponsorship budget or the creation sub-cap is exhausted, or the subject-lookup allowance is: `SUBJECT_LOOKUP_LIMITED`"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Sponsorship is paused or unavailable, or the subject's provider is: `SUBJECT_PROVIDER_UNAVAILABLE`, `SUBJECT_PROVIDER_DISABLED`"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/create/estimate":{"get":{"operationId":"estimateChainMarketCreation","parameters":[{"in":"query","name":"asset","required":true,"schema":{"description":"The mint the creation would be denominated in.","maxLength":44,"minLength":32,"type":"string"}},{"in":"query","name":"payWith","required":false,"schema":{"allOf":[{"$ref":"#/components/schemas/PayWith"},{"default":"usdc","description":"The asset the person pays with; where it is not the market's own, it is converted inside the transaction. Defaults to `usdc`."}]}},{"in":"query","name":"amountIn","required":false,"schema":{"description":"The opening buy's cap in atoms of `payWith`'s asset — USDC atoms for `usdc`, lamports for `sol`, the asset's own atoms for `market`. Where that asset is not the market's own, the answer's `openingBuy` prices the conversion and the buy's charge; absent, nothing of the buy is priced.","maxLength":39,"pattern":"^[1-9][0-9]*$","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainCreateEstimate"}}},"description":"What a creation in the asset would charge the creator, estimated from the measured rent table and a cached cluster-wide priority-fee sample, with the opening buy's minimum and the listing's opening size."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"The asset cannot back a market: `ASSET_UNKNOWN`, `ASSET_NOT_QUOTABLE`, `ASSET_NOT_LISTED`, `ASSET_LISTING_REFUSED`; or the opening buy's conversion is refused: `CONVERT_NO_ROUTE` (details `{ payWith, alternative }`), `CONVERT_BELOW_MINIMUM`"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain, or the asset's money rate is missing or stale: `RATE_UNAVAILABLE`, `RATE_STALE`; or it converts nothing for the opening buy: `CONVERT_PAIR_UNAVAILABLE`, `CONVERT_UNAVAILABLE`"}},"tags":["chain"]}},"/api/v1/chain/fees":{"get":{"operationId":"getChainCreatorFees","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainCreatorFees"}}},"description":"The caller's fees on both seats, from the claims projections: each market's figures in its own asset, every way its claim may be received at the money rates, all-time collected per asset, and per asset the least accrual a plain claim buys anything with."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/quote":{"post":{"operationId":"quoteChainTrade","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainQuoteBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainQuoteResult"}}},"description":"Advisory quote over the projected finalized state. The network-cost estimate adds a cached priority-fee sample per market."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"tags":["chain"]}},"/api/v1/chain/submissions":{"get":{"operationId":"listOpenChainSubmissions","parameters":[{"in":"query","name":"open","required":true,"schema":{"description":"Required. Only open (non-terminal) submissions are listed.","enum":["true"],"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainOpenSubmissions"}}},"description":"The caller's non-terminal submissions, newest first"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/submissions/{submissionId}":{"get":{"operationId":"getChainSubmission","parameters":[{"in":"path","name":"submissionId","required":true,"schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainSubmission"}}},"description":"The lifecycle, with a terminal flag the client stops polling on"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/submit":{"post":{"operationId":"submitChainTransaction","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainSubmitBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainSubmission"}}},"description":"Co-signed, simulated, forwarded — or, from an external wallet that sent its own transaction, recorded"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"A daily sponsorship budget is exhausted"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Sponsorship is paused or unavailable"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/wallet":{"get":{"operationId":"getChainWalletAssets","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainWalletAssets"}}},"description":"SOL and the wallet's token accounts, read from the chain"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/withdraw/build":{"post":{"operationId":"buildChainWithdraw","parameters":[{"in":"header","name":"x-privy-identity-token","required":true,"schema":{"description":"Privy identity token for this request. The account's address is the embedded Solana account of its verified claims, else its one external Solana wallet; writes from an external wallet are refused.","maxLength":4096,"minLength":1,"type":"string"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainWithdrawBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainWithdrawBuildResult"}}},"description":"One unsigned v1 message: the recipient's quote account when it is missing, the delivery and the network charge, with the treasury as payer"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"A daily sponsorship budget is exhausted"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Sponsorship is paused or unavailable"}},"security":[{"sessionBearer":[]}],"tags":["chain"]}},"/api/v1/chain/withdraw/estimate":{"get":{"operationId":"estimateChainWithdraw","parameters":[{"in":"query","name":"asset","required":true,"schema":{"anyOf":[{"enum":["sol"],"type":"string"},{"maxLength":44,"minLength":32,"type":"string"}],"description":"`sol`, or the mint address of the token to withdraw."}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainWithdrawEstimate"}}},"description":"What a withdrawal would charge, estimated from the measured rent table and a cached cluster-wide priority-fee sample."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Insufficient cash or holdings, budget below the fee-inclusive minimum, sell net below minQuoteOut, or an ordinary engine reject"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain, or cannot price a withdrawal"}},"tags":["chain"]}},"/api/v1/gate/challenge":{"post":{"operationId":"createGateChallenge","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateChallengeRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateChallengeResponse"}}},"description":"The message to sign, and the instant it stops being accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/gate/claim":{"post":{"operationId":"claimGatePass","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateClaimRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateVerdict"}}},"description":"The pass this link carried, as the door's own verdict"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/gate/config":{"get":{"operationId":"getGateConfig","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateConfigResponse"}}},"description":"Whether the door is armed, which mints open it, and this browser's pass"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/gate/invites/redeem":{"post":{"operationId":"redeemGateInvite","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InviteRedeemRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateVerdict"}}},"description":"The pass this code opened, as the door's own verdict"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/gate/invites/reserve":{"post":{"operationId":"reserveGateInvite","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InviteReserveRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InviteTicket"}}},"description":"A ticket for this code, and the instant it stops being redeemable"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/gate/verdict":{"post":{"operationId":"createGateVerdict","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiwsProof"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GateVerdict"}}},"description":"Whether this wallet may open an account, or already has one"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["gate"]}},"/api/v1/lab/definitions":{"get":{"description":"Operators only. `503 LAB_UNAVAILABLE` when this deployment configures no bot fleet or the fleet does not answer within two seconds.","operationId":"listLabDefinitions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LabDefinitions"}}},"description":"Bots an operator may attach from a market's LAB panel, and where the fleet is managed"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"No bot fleet is reachable from this deployment"}},"security":[{"sessionBearer":[]}],"tags":["lab"]}},"/api/v1/lab/markets/{marketId}/runs":{"get":{"description":"Operators only. `503 LAB_UNAVAILABLE` when this deployment configures no bot fleet or the fleet does not answer within two seconds.","operationId":"listLabMarketRuns","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LabRuns"}}},"description":"Bots attached to this market"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"No bot fleet is reachable from this deployment"}},"security":[{"sessionBearer":[]}],"tags":["lab"]},"post":{"description":"Operators only. `503 LAB_UNAVAILABLE` when this deployment configures no bot fleet or the fleet does not answer within two seconds. A spam-flagged market, or one whose trading is paused, is refused with `409 BOT_MARKET_NOT_ATTACHABLE` and the fleet is never asked. A refusal from the fleet itself arrives with the fleet's own status and body.","operationId":"attachLabMarketRun","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"header","name":"idempotency-key","required":true,"schema":{"maxLength":128,"minLength":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LabAttachBody"}}},"required":true},"responses":{"201":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LabRun"}}},"description":"The attached bot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Idempotency conflict, stale state, or no collectible balance"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"No bot fleet is reachable from this deployment"}},"security":[{"sessionBearer":[]}],"tags":["lab"]}},"/api/v1/leaderboard":{"get":{"operationId":"getLeaderboard","parameters":[{"in":"query","name":"rangeHours","required":false,"schema":{"description":"Window length in hours, at most 87600. Omit for the all-time board.","exclusiveMinimum":0,"maximum":87600,"type":"number"}},{"in":"query","name":"limit","required":false,"schema":{"description":"How many ranks to answer. Defaults to 50, at most 200.","maximum":200,"minimum":1,"type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Leaderboard"}}},"description":"Leaderboard"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["leaderboard"]}},"/api/v1/markets":{"get":{"description":"One page of the listed board, newest first — the market created last leads, which is the terminal's default `Live` order as served. `limit` defaults to its own maximum (200): the board is a list every client wants whole, so this bound exists to stop the response growing without limit rather than to hand out a small first page (`R8-P13B-12`). `offset` walks it, and `nextOffset` is null exactly when this page reached the end of the listed set.","operationId":"listMarkets","parameters":[{"in":"query","name":"tag","required":false,"schema":{"pattern":"^[a-z0-9][a-z0-9-]{0,23}$","type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"offset","required":false,"schema":{"minimum":0,"type":["integer","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketsPage"}}},"description":"One page of market summaries"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/search":{"get":{"description":"Case-insensitive substring search over the visible market set — question, tags, ticker base, both side suffixes, both `base.suffix` forms, and the subject handle. Visibility matches `GET /markets`; the active tag filter is not applied, so search is global. A leading `$` is stripped and LIKE metacharacters are literal. A term that normalizes to nothing at all is answered with an empty page (200), never an error; one character is a term and is searched, at the cost of a sequential scan, since no trigram index can serve a needle that short. Results are ordered newest first by creation time with an id tiebreak — `GET /markets`'s own order, made total — so pages are disjoint and stable. This document used to promise TVL ordering that no code applied (`R8-P13B-12`, finding S9): TVL is folded from `events` and is not a column, so ranking on it would mean loading and folding the whole listed set, which is the cost the trigram index exists to avoid.","operationId":"searchMarkets","parameters":[{"in":"query","name":"q","required":true,"schema":{"maxLength":120,"minLength":1,"type":"string"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":50,"minimum":1,"type":"integer"}},{"in":"query","name":"offset","required":false,"schema":{"maximum":10000,"minimum":0,"type":["integer","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketSearchResponse"}}},"description":"Matching market summaries"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/sparklines":{"get":{"operationId":"getMarketSparklines","parameters":[{"description":"Comma-separated market ids, at most 50.","in":"query","name":"marketIds","required":true,"schema":{"description":"Comma-separated market ids, at most 50.","minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSparklines"}}},"description":"Bulk market sparklines"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/spotlight":{"get":{"description":"The spotlight rail: the four global categories, then at most one MOST TRADED card per promoted tag, already-deduplicated slots whose wire order is the render order. Never computed inside a request — the composition is built by a prewarmed memo at most once per window and served from it, so this endpoint costs one database read per five seconds no matter how many visitors ask. `metric` is diagnostic and never rendered. The weak `ETag` tracks the slot membership and order alone, so a client holding the last rail revalidates into a 304 while the metrics underneath it move.","operationId":"getSpotlight","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpotlightResponse"}}},"description":"The current spotlight composition"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/ticker-pair":{"get":{"description":"The public ticker-pair lookup, with no session. `answer.kind` is `crowned` when a promoted market holds the pair for good, and names that market only while it is visible. Otherwise it is `shared`, naming the closest visible uncrowned market on the pair and how many others there are, or `free` when no visible market uses it. Every answer is read from chain rows, and a part outside the stored grammar is a 400.","operationId":"getTickerPair","parameters":[{"in":"query","name":"base","required":true,"schema":{"allOf":[{"$ref":"#/components/schemas/TickerBase"},{"description":"The pair's base, as stored: `^[A-Z0-9]{1,8}$`.","type":"string"}]}},{"in":"query","name":"yes","required":true,"schema":{"description":"The YES side's suffix, as stored.","pattern":"^[A-Z0-9]{1,8}$","type":"string"}},{"in":"query","name":"no","required":true,"schema":{"description":"The NO side's suffix, as stored.","pattern":"^[A-Z0-9]{1,8}$","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TickerPairLookup"}}},"description":"The pair's answer: free, crowned or shared"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"tags":["markets"]}},"/api/v1/markets/{marketId}":{"get":{"operationId":"getMarket","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketDetail"}}},"description":"Market detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/{marketId}/chart":{"get":{"operationId":"getMarketChart","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"resolution","required":false,"schema":{"allOf":[{"$ref":"#/components/schemas/ChartResolution"},{"description":"Defaults to `1h`."}]}},{"in":"query","name":"from","required":false,"schema":{"description":"Inclusive lower bound in epoch seconds. Defaults to 168 buckets before `to`.","type":["number","null"]}},{"in":"query","name":"to","required":false,"schema":{"description":"Inclusive upper bound in epoch seconds. Defaults to now.","type":["number","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChartWindow"}}},"description":"Bounded price + TVL window, in atoms of the market's quote asset. The `ETag` is a digest of the body; a window with no forming bucket whose last bucket closed long enough ago for ingest to have caught up is cacheable as immutable."},"304":{"description":"Window unchanged — `If-None-Match` matched."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"This deployment talks to no chain"}},"tags":["consensus"]}},"/api/v1/markets/{marketId}/consensus":{"get":{"operationId":"getConsensus","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Consensus"}}},"description":"Market consensus"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["consensus"]}},"/api/v1/markets/{marketId}/fees":{"get":{"operationId":"getMarketFees","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketFees"}}},"description":"Market fee seats"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/markets/{marketId}/holders":{"get":{"description":"One ranked page of a market's holders, largest traded balance first with an id tiebreak, plus `holderCount` and `totalShares` over the **whole** set (`R8-P13B-11`). `limit` defaults to the same bound the market frame carries (16) and is capped at 200; `offset` walks the ranking. The ranking reshuffles on every trade, so this pages by offset rather than by a cursor: a rank cursor would be no more stable, and pages are meant to be read one after another rather than resumed hours later.","operationId":"listHolders","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}},{"in":"query","name":"limit","required":false,"schema":{"maximum":200,"minimum":1,"type":"integer"}},{"in":"query","name":"offset","required":false,"schema":{"minimum":0,"type":["integer","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HoldersPage"}}},"description":"One page of market holders"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["portfolio"]}},"/api/v1/markets/{marketId}/stats":{"get":{"operationId":"getMarketStats","parameters":[{"in":"path","name":"marketId","required":true,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketStats"}}},"description":"Market traded totals"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["markets"]}},"/api/v1/positions":{"get":{"description":"The traded balances of one wallet, optionally narrowed to one market. `principalId` is required (`R8-P15-10`): it is the subject the fold loads, so there is no form of this read that answers about every holder of every listed market. Any address may be named — the feed is open, and naming a subject is not authorization.","operationId":"listPositions","parameters":[{"in":"query","name":"principalId","required":true,"schema":{"$ref":"#/components/schemas/PrincipalId"}},{"in":"query","name":"marketId","required":false,"schema":{"$ref":"#/components/schemas/MarketId"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Position"},"type":"array"}}},"description":"Positions"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unknown market"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["portfolio"]}},"/api/v1/principals":{"get":{"operationId":"listPrincipals","parameters":[{"in":"query","name":"ids","required":true,"schema":{"maxLength":4096,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PrincipalsResponse"}}},"description":"Principal display lookup"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Profile validation failure"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["profile"]}},"/api/v1/profile":{"patch":{"operationId":"patchProfile","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchProfileRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileView"}}},"description":"Updated profile"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Profile validation failure"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["profile"]}},"/api/v1/profile/username-availability":{"get":{"operationId":"getUsernameAvailability","parameters":[{"in":"query","name":"username","required":true,"schema":{"maxLength":64,"minLength":1,"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsernameAvailabilityResponse"}}},"description":"Username availability"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, expired, or revoked wallet session"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["profile"]}},"/api/v1/tags":{"get":{"operationId":"listTagCatalog","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTagCatalogResponse"}}},"description":"Curated active tag catalog for dashboard tabs"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"tags":["tags"]}},"/api/v1/tags/derive":{"post":{"operationId":"deriveTags","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeriveTagsBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeriveTagsResponse"}}},"description":"Catalogue slugs the creator picks from — the tagger's, topped up from the catalogue — and where the tagger's came from"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["tags"]}},"/api/v1/uploads/market-image":{"post":{"operationId":"uploadMarketImage","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/UploadMarketImageBody"}}},"required":true},"responses":{"201":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadMarketImageResult"}}},"description":"Stored image; pass `imageUrl` back as the market's `imageUrl`"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Validation or invalid command"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Missing, invalid, expired, or revoked credential"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Forbidden action, paused market, or insufficient role"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Rate limit exceeded"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorBody"}}},"description":"Unexpected server error"}},"security":[{"sessionBearer":[]}],"tags":["markets"]}}},"webhooks":{}}