{"asyncapi":"3.0.0","info":{"title":"Wagyu Consumer Realtime API","version":"v2","description":"Public WebSocket contract for current order snapshots. REST order reads remain the durable source of truth."},"defaultContentType":"application/json","channels":{"swapOrder":{"address":"/v2/swaps/{id}/events","title":"Receive full snapshots for one swap order","description":"The server sends complete current-order snapshots matching `/v2/swaps/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","parameters":{"id":{"description":"Durable order identifier. An order ID alone does not authorize this connection.","schema":{"type":"string"}}},"messages":{"swapOrderSnapshot":{"name":"swapOrderSnapshot","title":"Receive full snapshots for one swap order","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"swap"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"type":"string"},"depositAddress":{"type":"string"},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"depositChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"depositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}},"sourceDepositAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"observedDepositTxHash":{"type":"string"},"observedDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"fundedExpectedOutput":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"refund":{"type":"object","properties":{"txHash":{"type":"string"},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"toAddress":{"type":"string"}},"required":["txHash","chainId","toAddress"],"additionalProperties":false},"coinflip":{"anyOf":[{"type":"object","properties":{"eligible":{"type":"boolean"},"accepted":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"seedHash":{"type":"string"},"clientSeed":{"type":"string"},"assetSymbol":{"type":"string"},"assetKey":{"anyOf":[{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."}],"description":"Asset a coinflip was staked in: a table pool asset or a bridge asset."},"result":{"type":"number"},"won":{"type":"boolean"},"serverSeed":{"type":"string"},"resolvedAt":{"type":"string"},"side":{"anyOf":[{"type":"string","enum":["cow","milk"]},{"type":"null"}]},"currentRound":{"type":"number"},"currentMultiplier":{"type":"number"},"finalMultiplier":{"anyOf":[{"type":"number"},{"type":"null"}]},"finalWon":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"rounds":{"type":"array","items":{"type":"object","properties":{"round":{"type":"number"},"serverSeed":{"type":"string"},"serverSeedHash":{"type":"string"},"clientSeed":{"type":"string"},"side":{"type":"string","enum":["cow","milk"]},"result":{"type":"number"},"won":{"type":"boolean"},"resolvedAt":{"type":"string"},"stakeAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"balanceAfterAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."}},"required":["round"],"additionalProperties":false}},"policy":{"type":"object","properties":{"edgePercent":{"type":"number"},"milkWinBelow":{"type":"number"},"cowWinAbove":{"type":"number"},"winChancePercent":{"type":"number"},"maxWalletFractionPercent":{"type":"number"},"maxPayoutAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["edgePercent","milkWinBelow","cowWinAbove","winChancePercent"],"additionalProperties":false},"decisionDeadline":{"type":"string"},"mode":{"type":"string","const":"session"},"balanceAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"creditedInAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wageredAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"minBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"maxBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wagyuPoints":{"type":"number"},"refusal":{"type":"string","enum":["not_a_positive_amount","above_balance","below_minimum","below_payout_minimum","above_exposure_cap","limits_unavailable"]},"pendingTopUp":{"type":"object","properties":{"atomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"}},"required":["atomic","confirmations","requiredConfirmations"],"additionalProperties":false}},"required":["eligible","accepted","seedHash","clientSeed"],"additionalProperties":false},{"type":"null"}]},"twap":{"anyOf":[{"type":"object","properties":{"enabled":{"type":"boolean","const":true},"status":{"type":"string","enum":["running","completed","failed"]},"side":{"type":"string","enum":["buy","sell"]},"filledPercent":{"type":"number"},"chunksCompleted":{"type":"number"},"chunksTotal":{"type":"number"},"estimatedTimeRemainingMs":{"type":"number"},"estimatedTimeRemaining":{"type":"string"},"startedAt":{"type":"string"},"expectedCompleteAt":{"type":"string"},"completedAt":{"type":"string"}},"required":["enabled","status","filledPercent","chunksCompleted","chunksTotal","startedAt"],"additionalProperties":false},{"type":"null"}]},"route":{"anyOf":[{"type":"object","properties":{"provider":{"type":"string"},"tool":{"type":"string"},"txHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"status":{"type":"string","enum":["pending","done","refunded","failed","partial","unavailable"]},"statusMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["provider","tool","txHash","toChainId","status","statusMessage"],"additionalProperties":false},{"type":"null"}]},"routing":{"type":"object","properties":{"topology":{"type":"string","enum":["single","parallel"]},"branchCount":{"type":"integer","minimum":0,"maximum":9007199254740991},"phase":{"type":"string","enum":["preparing","executing","recovering","settled","attention","unavailable"]},"status":{"type":"string","enum":["pending","done","partial","failed","unavailable"]},"branches":{"type":"object","properties":{"total":{"type":"integer","minimum":0,"maximum":9007199254740991},"completed":{"type":"integer","minimum":0,"maximum":9007199254740991},"pending":{"type":"integer","minimum":0,"maximum":9007199254740991},"attention":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["total","completed","pending","attention"],"additionalProperties":false},"routes":{"type":"array","items":{"type":"object","properties":{"provider":{"type":"string","minLength":1},"tool":{"type":"string","minLength":1},"txHash":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"attempt":{"anyOf":[{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},{"type":"null"}]},"status":{"type":"string","enum":["pending","done","refunded","failed","partial","unavailable"]},"statusMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["provider","tool","txHash","fromChainId","toChainId","attempt","status","statusMessage"],"additionalProperties":false}}},"required":["topology","branchCount","phase","status","branches","routes"],"additionalProperties":false},"hlFills":{"anyOf":[{"type":"array","items":{"type":"object","properties":{"tradeId":{"type":"string","pattern":"^\\d+$"},"coin":{"type":"string","pattern":"^@\\d+$"},"txHash":{"type":"string","minLength":66,"maxLength":66,"pattern":"^0x(?!0{64}$)[0-9a-fA-F]{64}$"},"time":{"type":"integer","minimum":0,"maximum":9007199254740991},"side":{"type":"string","enum":["Buy","Sell"]},"price":{"type":"number","exclusiveMinimum":0},"size":{"type":"number","exclusiveMinimum":0},"value":{"type":"number","minimum":0},"fee":{"type":"number"},"feeToken":{"type":"string","minLength":1},"twapId":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991}},"required":["time","side","price","size","value","fee","feeToken"],"additionalProperties":false}},{"type":"null"}]},"hlFillsStatus":{"type":"string","enum":["pending","complete","incomplete"]},"hlFillsNextCursor":{"anyOf":[{"type":"string","pattern":"^[1-9]\\d{0,18}$"},{"type":"null"}]}},"required":["orderId","product","status","chainId","toAddress","depositAddress","createdAt","updatedAt","fromChainId","depositChainId","fromToken","depositToken","fromTokenSymbol","depositTokenSymbol","fromTokenDecimals","depositTokenDecimals","fromAmount","depositAmount","toChainId","toToken","toTokenSymbol","toTokenDecimals","customerState","errorMessage","coinflipLost","hasReview"],"additionalProperties":false}}}},"bridgeOrder":{"address":"/v2/bridges/{id}/events","title":"Receive full snapshots for one native bridge order","description":"The server sends complete current-order snapshots matching `/v2/bridges/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","parameters":{"id":{"description":"Durable order identifier. An order ID alone does not authorize this connection.","schema":{"type":"string"}}},"messages":{"bridgeOrderSnapshot":{"name":"bridgeOrderSnapshot","title":"Receive full snapshots for one native bridge order","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","oneOf":[{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"bridge"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","const":"deposit"},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"destination":{"type":"string"},"amount":{"anyOf":[{"type":"string"},{"type":"number"}]},"txIn":{"anyOf":[{"type":"string"},{"type":"null"}]},"txOut":{"anyOf":[{"type":"string"},{"type":"null"}]},"txid":{"anyOf":[{"type":"string"},{"type":"null"}]},"bridgeSettlement":{"anyOf":[{"type":"object","properties":{"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"input":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"output":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"fee":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36},"percent":{"type":"number"},"amountUsd":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["asset","amountAtomic","decimals","percent","amountUsd"],"additionalProperties":false},{"type":"null"}]}},"required":["direction","input","output","fee"],"additionalProperties":false},{"type":"null"}]},"receivedXmr":{"anyOf":[{"type":"number"},{"type":"null"}]},"delivered":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"depositAddress":{"type":"string"},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}}},"required":["orderId","product","status","asset","direction","chainId","toAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview","destination","depositAddress"],"additionalProperties":false},{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"bridge"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","const":"withdraw"},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"destination":{"type":"string"},"amount":{"anyOf":[{"type":"string"},{"type":"number"}]},"txIn":{"anyOf":[{"type":"string"},{"type":"null"}]},"txOut":{"anyOf":[{"type":"string"},{"type":"null"}]},"txid":{"anyOf":[{"type":"string"},{"type":"null"}]},"bridgeSettlement":{"anyOf":[{"type":"object","properties":{"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"input":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"output":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"fee":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36},"percent":{"type":"number"},"amountUsd":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["asset","amountAtomic","decimals","percent","amountUsd"],"additionalProperties":false},{"type":"null"}]}},"required":["direction","input","output","fee"],"additionalProperties":false},{"type":"null"}]},"receivedXmr":{"anyOf":[{"type":"number"},{"type":"null"}]},"delivered":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"xmr1DepositAddress":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["orderId","product","status","asset","direction","chainId","toAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview","destination","xmr1DepositAddress"],"additionalProperties":false}]}}}},"coinflipOrder":{"address":"/v2/coinflips/{id}/events","title":"Receive full snapshots for one coinflip-table order","description":"The server sends complete current-order snapshots matching `/v2/coinflips/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","parameters":{"id":{"description":"Durable order identifier. An order ID alone does not authorize this connection.","schema":{"type":"string"}}},"messages":{"coinflipOrderSnapshot":{"name":"coinflipOrderSnapshot","title":"Receive full snapshots for one coinflip-table order","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"coinflip"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."},"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"depositAddress":{"type":"string"},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"maxPayoutUsd":{"type":"number","minimum":0},"destination":{"type":"string"},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}},"coinflip":{"anyOf":[{"type":"object","properties":{"eligible":{"type":"boolean"},"accepted":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"seedHash":{"type":"string"},"clientSeed":{"type":"string"},"assetSymbol":{"type":"string"},"assetKey":{"anyOf":[{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."}],"description":"Asset a coinflip was staked in: a table pool asset or a bridge asset."},"result":{"type":"number"},"won":{"type":"boolean"},"serverSeed":{"type":"string"},"resolvedAt":{"type":"string"},"side":{"anyOf":[{"type":"string","enum":["cow","milk"]},{"type":"null"}]},"currentRound":{"type":"number"},"currentMultiplier":{"type":"number"},"finalMultiplier":{"anyOf":[{"type":"number"},{"type":"null"}]},"finalWon":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"rounds":{"type":"array","items":{"type":"object","properties":{"round":{"type":"number"},"serverSeed":{"type":"string"},"serverSeedHash":{"type":"string"},"clientSeed":{"type":"string"},"side":{"type":"string","enum":["cow","milk"]},"result":{"type":"number"},"won":{"type":"boolean"},"resolvedAt":{"type":"string"},"stakeAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"balanceAfterAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."}},"required":["round"],"additionalProperties":false}},"policy":{"type":"object","properties":{"edgePercent":{"type":"number"},"milkWinBelow":{"type":"number"},"cowWinAbove":{"type":"number"},"winChancePercent":{"type":"number"},"maxWalletFractionPercent":{"type":"number"},"maxPayoutAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["edgePercent","milkWinBelow","cowWinAbove","winChancePercent"],"additionalProperties":false},"decisionDeadline":{"type":"string"},"mode":{"type":"string","const":"session"},"balanceAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"creditedInAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wageredAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"minBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"maxBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wagyuPoints":{"type":"number"},"refusal":{"type":"string","enum":["not_a_positive_amount","above_balance","below_minimum","below_payout_minimum","above_exposure_cap","limits_unavailable"]},"pendingTopUp":{"type":"object","properties":{"atomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"}},"required":["atomic","confirmations","requiredConfirmations"],"additionalProperties":false}},"required":["eligible","accepted","seedHash","clientSeed"],"additionalProperties":false},{"type":"null"}]}},"required":["orderId","product","status","asset","chainId","toAddress","depositAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview"],"additionalProperties":false}}}},"coinflipActivity":{"address":"/v2/coinflips/recent/events","title":"Receive the latest anonymous table rounds as they are played","description":"The server sends the complete current list matching `/v2/coinflips/recent` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","messages":{"coinflipActivitySnapshot":{"name":"coinflipActivitySnapshot","title":"Receive the latest anonymous table rounds as they are played","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"round":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"assetSymbol":{"type":"string","minLength":1},"atomicDecimals":{"type":"integer","minimum":0,"maximum":36},"stakeAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"side":{"type":"string","enum":["cow","milk"]},"won":{"type":"boolean"},"playedAt":{"type":"string"}},"required":["id","round","assetSymbol","atomicDecimals","stakeAtomic","side","won","playedAt"],"additionalProperties":false}}}}},"recentSwaps":{"address":"/v2/recent-swaps/events","title":"Receive the latest completed swaps as they settle","description":"The server sends the complete current list matching `/v2/recent-swaps` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","messages":{"recentSwapsSnapshot":{"name":"recentSwapsSnapshot","title":"Receive the latest completed swaps as they settle","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","type":"array","items":{"type":"object","properties":{"orderId":{"type":"string","description":"Opaque key for this row, stable across polls. Not the order's id: it opens no order."},"status":{"type":"string","const":"completed"},"from":{"type":"string"},"fromChainId":{"type":"integer","minimum":0,"maximum":9007199254740991},"fromAmount":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":9007199254740991},"to":{"type":"string"},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991},"toAmount":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":9007199254740991},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["orderId","status","from","to","createdAt","completedAt"],"additionalProperties":false}}}}},"recentBridges":{"address":"/v2/bridges/recent/events","title":"Receive the latest completed bridge orders as they settle","description":"The server sends the complete current list matching `/v2/bridges/recent` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","messages":{"recentBridgesSnapshot":{"name":"recentBridgesSnapshot","title":"Receive the latest completed bridge orders as they settle","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","type":"array","items":{"type":"object","properties":{"orderId":{"type":"string","description":"Opaque key for this row, stable across polls. Not the order's id: it opens no order."},"status":{"type":"string","const":"completed"},"from":{"type":"string"},"fromChainId":{"type":"integer","minimum":0,"maximum":9007199254740991},"fromAmount":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":9007199254740991},"to":{"type":"string"},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991},"toAmount":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":9007199254740991},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["orderId","status","from","to","createdAt","completedAt"],"additionalProperties":false}}}}},"orders":{"address":"/v2/orders/events","title":"Subscribe to live snapshots for owned orders","description":"Send a subscribe message for each order to follow; each message carries that order’s owner session. The server immediately sends a complete current-order snapshot, then sends complete snapshots after order changes and periodically. Send unsubscribe when an order is no longer needed. Server frames contain only the complete order object, with no wrapper.","messages":{"orderSubscription":{"name":"orderSubscription","title":"Subscribe or unsubscribe from owned order snapshots","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"subscribe"},"orderId":{"type":"string","pattern":"^[A-Za-z0-9:_-]{1,128}$","description":"Public order identifier. Not a credential: every read still requires the owner session or the destination proof."},"sessionId":{"type":"string","pattern":"^[0-9a-f-]{16,64}$","description":"16–64 character hexadecimal/hyphen owner-session credential."}},"required":["type","orderId","sessionId"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"unsubscribe"},"orderId":{"type":"string","pattern":"^[A-Za-z0-9:_-]{1,128}$","description":"Public order identifier. Not a credential: every read still requires the owner session or the destination proof."}},"required":["type","orderId"],"additionalProperties":false}]}},"orderSnapshot":{"name":"orderSnapshot","title":"Complete order snapshot","contentType":"application/json","payload":{"$schema":"http://json-schema.org/draft-07/schema#","anyOf":[{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"swap"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"type":"string"},"depositAddress":{"type":"string"},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"depositChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"depositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}},"sourceDepositAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"observedDepositTxHash":{"type":"string"},"observedDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"fundedExpectedOutput":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"refund":{"type":"object","properties":{"txHash":{"type":"string"},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"toAddress":{"type":"string"}},"required":["txHash","chainId","toAddress"],"additionalProperties":false},"coinflip":{"anyOf":[{"type":"object","properties":{"eligible":{"type":"boolean"},"accepted":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"seedHash":{"type":"string"},"clientSeed":{"type":"string"},"assetSymbol":{"type":"string"},"assetKey":{"anyOf":[{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."}],"description":"Asset a coinflip was staked in: a table pool asset or a bridge asset."},"result":{"type":"number"},"won":{"type":"boolean"},"serverSeed":{"type":"string"},"resolvedAt":{"type":"string"},"side":{"anyOf":[{"type":"string","enum":["cow","milk"]},{"type":"null"}]},"currentRound":{"type":"number"},"currentMultiplier":{"type":"number"},"finalMultiplier":{"anyOf":[{"type":"number"},{"type":"null"}]},"finalWon":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"rounds":{"type":"array","items":{"type":"object","properties":{"round":{"type":"number"},"serverSeed":{"type":"string"},"serverSeedHash":{"type":"string"},"clientSeed":{"type":"string"},"side":{"type":"string","enum":["cow","milk"]},"result":{"type":"number"},"won":{"type":"boolean"},"resolvedAt":{"type":"string"},"stakeAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"balanceAfterAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."}},"required":["round"],"additionalProperties":false}},"policy":{"type":"object","properties":{"edgePercent":{"type":"number"},"milkWinBelow":{"type":"number"},"cowWinAbove":{"type":"number"},"winChancePercent":{"type":"number"},"maxWalletFractionPercent":{"type":"number"},"maxPayoutAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["edgePercent","milkWinBelow","cowWinAbove","winChancePercent"],"additionalProperties":false},"decisionDeadline":{"type":"string"},"mode":{"type":"string","const":"session"},"balanceAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"creditedInAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wageredAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"minBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"maxBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wagyuPoints":{"type":"number"},"refusal":{"type":"string","enum":["not_a_positive_amount","above_balance","below_minimum","below_payout_minimum","above_exposure_cap","limits_unavailable"]},"pendingTopUp":{"type":"object","properties":{"atomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"}},"required":["atomic","confirmations","requiredConfirmations"],"additionalProperties":false}},"required":["eligible","accepted","seedHash","clientSeed"],"additionalProperties":false},{"type":"null"}]},"twap":{"anyOf":[{"type":"object","properties":{"enabled":{"type":"boolean","const":true},"status":{"type":"string","enum":["running","completed","failed"]},"side":{"type":"string","enum":["buy","sell"]},"filledPercent":{"type":"number"},"chunksCompleted":{"type":"number"},"chunksTotal":{"type":"number"},"estimatedTimeRemainingMs":{"type":"number"},"estimatedTimeRemaining":{"type":"string"},"startedAt":{"type":"string"},"expectedCompleteAt":{"type":"string"},"completedAt":{"type":"string"}},"required":["enabled","status","filledPercent","chunksCompleted","chunksTotal","startedAt"],"additionalProperties":false},{"type":"null"}]},"route":{"anyOf":[{"type":"object","properties":{"provider":{"type":"string"},"tool":{"type":"string"},"txHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"toChainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"status":{"type":"string","enum":["pending","done","refunded","failed","partial","unavailable"]},"statusMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["provider","tool","txHash","toChainId","status","statusMessage"],"additionalProperties":false},{"type":"null"}]},"routing":{"type":"object","properties":{"topology":{"type":"string","enum":["single","parallel"]},"branchCount":{"type":"integer","minimum":0,"maximum":9007199254740991},"phase":{"type":"string","enum":["preparing","executing","recovering","settled","attention","unavailable"]},"status":{"type":"string","enum":["pending","done","partial","failed","unavailable"]},"branches":{"type":"object","properties":{"total":{"type":"integer","minimum":0,"maximum":9007199254740991},"completed":{"type":"integer","minimum":0,"maximum":9007199254740991},"pending":{"type":"integer","minimum":0,"maximum":9007199254740991},"attention":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["total","completed","pending","attention"],"additionalProperties":false},"routes":{"type":"array","items":{"type":"object","properties":{"provider":{"type":"string","minLength":1},"tool":{"type":"string","minLength":1},"txHash":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"attempt":{"anyOf":[{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},{"type":"null"}]},"status":{"type":"string","enum":["pending","done","refunded","failed","partial","unavailable"]},"statusMessage":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["provider","tool","txHash","fromChainId","toChainId","attempt","status","statusMessage"],"additionalProperties":false}}},"required":["topology","branchCount","phase","status","branches","routes"],"additionalProperties":false},"hlFills":{"anyOf":[{"type":"array","items":{"type":"object","properties":{"tradeId":{"type":"string","pattern":"^\\d+$"},"coin":{"type":"string","pattern":"^@\\d+$"},"txHash":{"type":"string","minLength":66,"maxLength":66,"pattern":"^0x(?!0{64}$)[0-9a-fA-F]{64}$"},"time":{"type":"integer","minimum":0,"maximum":9007199254740991},"side":{"type":"string","enum":["Buy","Sell"]},"price":{"type":"number","exclusiveMinimum":0},"size":{"type":"number","exclusiveMinimum":0},"value":{"type":"number","minimum":0},"fee":{"type":"number"},"feeToken":{"type":"string","minLength":1},"twapId":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991}},"required":["time","side","price","size","value","fee","feeToken"],"additionalProperties":false}},{"type":"null"}]},"hlFillsStatus":{"type":"string","enum":["pending","complete","incomplete"]},"hlFillsNextCursor":{"anyOf":[{"type":"string","pattern":"^[1-9]\\d{0,18}$"},{"type":"null"}]}},"required":["orderId","product","status","chainId","toAddress","depositAddress","createdAt","updatedAt","fromChainId","depositChainId","fromToken","depositToken","fromTokenSymbol","depositTokenSymbol","fromTokenDecimals","depositTokenDecimals","fromAmount","depositAmount","toChainId","toToken","toTokenSymbol","toTokenDecimals","customerState","errorMessage","coinflipLost","hasReview"],"additionalProperties":false},{"oneOf":[{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"bridge"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","const":"deposit"},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"destination":{"type":"string"},"amount":{"anyOf":[{"type":"string"},{"type":"number"}]},"txIn":{"anyOf":[{"type":"string"},{"type":"null"}]},"txOut":{"anyOf":[{"type":"string"},{"type":"null"}]},"txid":{"anyOf":[{"type":"string"},{"type":"null"}]},"bridgeSettlement":{"anyOf":[{"type":"object","properties":{"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"input":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"output":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"fee":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36},"percent":{"type":"number"},"amountUsd":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["asset","amountAtomic","decimals","percent","amountUsd"],"additionalProperties":false},{"type":"null"}]}},"required":["direction","input","output","fee"],"additionalProperties":false},{"type":"null"}]},"receivedXmr":{"anyOf":[{"type":"number"},{"type":"null"}]},"delivered":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"depositAddress":{"type":"string"},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}}},"required":["orderId","product","status","asset","direction","chainId","toAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview","destination","depositAddress"],"additionalProperties":false},{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"bridge"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},"direction":{"type":"string","const":"withdraw"},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"destination":{"type":"string"},"amount":{"anyOf":[{"type":"string"},{"type":"number"}]},"txIn":{"anyOf":[{"type":"string"},{"type":"null"}]},"txOut":{"anyOf":[{"type":"string"},{"type":"null"}]},"txid":{"anyOf":[{"type":"string"},{"type":"null"}]},"bridgeSettlement":{"anyOf":[{"type":"object","properties":{"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"input":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"output":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["asset","amountAtomic","decimals"],"additionalProperties":false},{"type":"null"}]},"fee":{"anyOf":[{"type":"object","properties":{"asset":{"type":"string"},"amountAtomic":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36},"percent":{"type":"number"},"amountUsd":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["asset","amountAtomic","decimals","percent","amountUsd"],"additionalProperties":false},{"type":"null"}]}},"required":["direction","input","output","fee"],"additionalProperties":false},{"type":"null"}]},"receivedXmr":{"anyOf":[{"type":"number"},{"type":"null"}]},"delivered":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"completedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"xmr1DepositAddress":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["orderId","product","status","asset","direction","chainId","toAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview","destination","xmr1DepositAddress"],"additionalProperties":false}]},{"type":"object","properties":{"orderId":{"type":"string"},"product":{"type":"string","const":"coinflip"},"status":{"type":"string","enum":["awaiting_deposit","awaiting_xmr1","awaiting_trx1","awaiting_zec1","processing","completed","failed","expired","refunded","needs_review"]},"asset":{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."},"direction":{"type":"string","enum":["deposit","withdraw"],"description":"deposit mints the wrapped asset from a native-coin deposit; withdraw returns the native coin against the wrapped asset."},"chainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"depositAddress":{"type":"string"},"createdAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"fromChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"depositChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"fromToken":{"type":"string"},"depositToken":{"type":"string"},"fromTokenSymbol":{"type":"string"},"depositTokenSymbol":{"type":"string"},"fromTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"depositTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"fromAmount":{"type":"string"},"depositAmount":{"type":"string"},"toChainId":{"anyOf":[{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},{"type":"null"}]},"toToken":{"type":"string"},"toTokenSymbol":{"type":"string"},"toTokenDecimals":{"type":"integer","minimum":0,"maximum":36},"expectedOutput":{"type":"string"},"depositTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"receivingTxHash":{"anyOf":[{"type":"string"},{"type":"null"}]},"sessionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundAddress":{"anyOf":[{"type":"string"},{"type":"null"}]},"refundRequestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"expiresAt":{"type":"string"},"amountUsd":{"type":"number"},"bonusStage":{"type":"string","enum":["none","coinflip"]},"coinflipRequested":{"type":"boolean"},"fundingProvider":{"anyOf":[{"type":"string","enum":["privy"]},{"type":"null"}]},"integratorFeeUsd":{"anyOf":[{"type":"number"},{"type":"null"}]},"customerState":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"awaiting_deposit"},"notice":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"below_expected"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"below_minimum"},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","minimumDepositAmount"],"additionalProperties":false}]}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"processing"},"stage":{"type":"string","enum":["processing","confirming","routing","trading","sending","refunding"]},"notice":{"type":"object","properties":{"kind":{"type":"string","const":"checking"}},"required":["kind"],"additionalProperties":false}},"required":["kind","stage"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"action_required"},"action":{"type":"string","enum":["coinflip","refund_address","payout_address"]}},"required":["kind","action"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"paused"},"reason":{"type":"string","enum":["preparing_refund","below_minimum"]},"minimumDepositAmount":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["kind","reason"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"completed"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"refunded"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"expired"}},"required":["kind"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"failed"}},"required":["kind"],"additionalProperties":false}],"description":"Authoritative customer display/action state. Clients must not infer lifecycle from status or resource presence."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"},"depositObserved":{"type":"boolean"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"actualOutput":{"description":"What the customer received, in atomic units of `deliveredToken` when present, otherwise of `toToken`. Only on completed orders.","type":"string"},"deliveredToken":{"type":"object","properties":{"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"token":{"type":"string"},"symbol":{"type":"string"},"decimals":{"type":"integer","minimum":0,"maximum":36}},"required":["chainId","token","symbol","decimals"],"additionalProperties":false,"description":"Present only when the order completed in a different asset than `toToken`; `actualOutput` is then denominated in this token."},"coinflipLost":{"type":"boolean"},"hasReview":{"type":"boolean"},"refundRecovery":{"anyOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["wrong_chain","source","table_deposit"]},"phase":{"type":"string","enum":["address_required","requested","in_progress"]},"chainId":{"type":"integer","minimum":0,"maximum":9007199254740991,"description":"Non-negative integer chain identifier."},"asset":{"type":"object","properties":{"type":{"type":"string","enum":["native","erc20","spl"]},"token":{"anyOf":[{"type":"string"},{"type":"null"}]},"symbol":{"type":"string"},"decimals":{"anyOf":[{"type":"integer","minimum":0,"maximum":36},{"type":"null"}]}},"required":["type","token","symbol","decimals"],"additionalProperties":false},"amountAtomic":{"type":"string"},"requestedAt":{"anyOf":[{"type":"string"},{"type":"null"}]},"suggestedAddress":{"description":"An address the order already has on file for this chain (for table_deposit, the table's payout address), offered as the prefill while phase is address_required. An offer only: nothing is sent to it until it is submitted.","type":"string"},"destination":{"description":"Where the refund goes once that is decided (phase requested or in_progress). source is customer when someone submitted the address, sender when the refund returns to the wallet the deposit came from without anyone having to submit one.","type":"object","properties":{"address":{"type":"string"},"source":{"type":"string","enum":["customer","sender"]}},"required":["address","source"],"additionalProperties":false}},"required":["kind","phase","chainId","asset","amountAtomic","requestedAt"],"additionalProperties":false},{"type":"null"}]},"rewards":{"type":"object","properties":{"status":{"type":"string","enum":["pending","earned","not_eligible"]},"wagyuEarned":{"type":"number"},"wagyuBonusEarned":{"type":"number"},"wagyuCompensation":{"type":"number","minimum":0},"wagyuTotalEarned":{"type":"number"},"policyKey":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["status","wagyuEarned","wagyuBonusEarned","wagyuTotalEarned","policyKey"],"additionalProperties":false},"maxPayoutUsd":{"type":"number","minimum":0},"destination":{"type":"string"},"depositAddressForms":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["shielded","transparent"]},"address":{"type":"string"}},"required":["kind","address"],"additionalProperties":false}},"coinflip":{"anyOf":[{"type":"object","properties":{"eligible":{"type":"boolean"},"accepted":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"seedHash":{"type":"string"},"clientSeed":{"type":"string"},"assetSymbol":{"type":"string"},"assetKey":{"anyOf":[{"type":"string","enum":["xmr","trx","zec"],"description":"Registered native-bridge asset key, never a display symbol."},{"type":"string","enum":["xmr","btc","sol","eth","zec"],"description":"Coinflip-table pool asset key, never a display symbol."}],"description":"Asset a coinflip was staked in: a table pool asset or a bridge asset."},"result":{"type":"number"},"won":{"type":"boolean"},"serverSeed":{"type":"string"},"resolvedAt":{"type":"string"},"side":{"anyOf":[{"type":"string","enum":["cow","milk"]},{"type":"null"}]},"currentRound":{"type":"number"},"currentMultiplier":{"type":"number"},"finalMultiplier":{"anyOf":[{"type":"number"},{"type":"null"}]},"finalWon":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"rounds":{"type":"array","items":{"type":"object","properties":{"round":{"type":"number"},"serverSeed":{"type":"string"},"serverSeedHash":{"type":"string"},"clientSeed":{"type":"string"},"side":{"type":"string","enum":["cow","milk"]},"result":{"type":"number"},"won":{"type":"boolean"},"resolvedAt":{"type":"string"},"stakeAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"balanceAfterAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."}},"required":["round"],"additionalProperties":false}},"policy":{"type":"object","properties":{"edgePercent":{"type":"number"},"milkWinBelow":{"type":"number"},"cowWinAbove":{"type":"number"},"winChancePercent":{"type":"number"},"maxWalletFractionPercent":{"type":"number"},"maxPayoutAtomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."}},"required":["edgePercent","milkWinBelow","cowWinAbove","winChancePercent"],"additionalProperties":false},"decisionDeadline":{"type":"string"},"mode":{"type":"string","const":"session"},"balanceAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"creditedInAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wageredAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"minBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"maxBetAtomic":{"type":"string","pattern":"^0*[0-9]+$","description":"Non-negative base-10 integer in the asset’s atomic unit."},"wagyuPoints":{"type":"number"},"refusal":{"type":"string","enum":["not_a_positive_amount","above_balance","below_minimum","below_payout_minimum","above_exposure_cap","limits_unavailable"]},"pendingTopUp":{"type":"object","properties":{"atomic":{"type":"string","pattern":"^0*[1-9][0-9]*$","description":"Positive base-10 integer in the asset’s atomic unit."},"confirmations":{"type":"number"},"requiredConfirmations":{"type":"number"}},"required":["atomic","confirmations","requiredConfirmations"],"additionalProperties":false}},"required":["eligible","accepted","seedHash","clientSeed"],"additionalProperties":false},{"type":"null"}]}},"required":["orderId","product","status","asset","chainId","toAddress","depositAddress","createdAt","updatedAt","customerState","errorMessage","coinflipLost","hasReview"],"additionalProperties":false}]}}}}},"operations":{"receiveSwapOrderSnapshots":{"action":"receive","summary":"Receive full snapshots for one swap order","description":"The server sends complete current-order snapshots matching `/v2/swaps/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","channel":{"$ref":"#/channels/swapOrder"},"messages":[{"$ref":"#/channels/swapOrder/messages/swapOrderSnapshot"}],"security":[{"orderSession":[]},{"destinationProof":[]}]},"receiveBridgeOrderSnapshots":{"action":"receive","summary":"Receive full snapshots for one native bridge order","description":"The server sends complete current-order snapshots matching `/v2/bridges/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","channel":{"$ref":"#/channels/bridgeOrder"},"messages":[{"$ref":"#/channels/bridgeOrder/messages/bridgeOrderSnapshot"}],"security":[{"orderSession":[]},{"destinationProof":[]}]},"receiveCoinflipOrderSnapshots":{"action":"receive","summary":"Receive full snapshots for one coinflip-table order","description":"The server sends complete current-order snapshots matching `/v2/coinflips/:id`. It sends one after a successful connection, after order changes, and periodically; frames can be repeated or coalesced. There are no client-to-server application messages. Reconnects and missed frames must be followed by an authorized REST read. Missing, unauthorized, and nonexistent orders all close with opaque code 4404.","channel":{"$ref":"#/channels/coinflipOrder"},"messages":[{"$ref":"#/channels/coinflipOrder/messages/coinflipOrderSnapshot"}],"security":[{"orderSession":[]},{"destinationProof":[]}]},"receiveCoinflipActivitySnapshots":{"action":"receive","summary":"Receive the latest anonymous table rounds as they are played","description":"The server sends the complete current list matching `/v2/coinflips/recent` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","channel":{"$ref":"#/channels/coinflipActivity"},"messages":[{"$ref":"#/channels/coinflipActivity/messages/coinflipActivitySnapshot"}],"security":[]},"receiveRecentSwapsSnapshots":{"action":"receive","summary":"Receive the latest completed swaps as they settle","description":"The server sends the complete current list matching `/v2/recent-swaps` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","channel":{"$ref":"#/channels/recentSwaps"},"messages":[{"$ref":"#/channels/recentSwaps/messages/recentSwapsSnapshot"}],"security":[]},"receiveRecentBridgesSnapshots":{"action":"receive","summary":"Receive the latest completed bridge orders as they settle","description":"The server sends the complete current list matching `/v2/bridges/recent` — the same public data, never a delta. It sends one after a successful connection, after each new round, and periodically; frames can be repeated or coalesced. No authentication and no client-to-server application messages. A reconnect simply takes the next frame. Connections beyond the per-client or server capacity close with code 1013.","channel":{"$ref":"#/channels/recentBridges"},"messages":[{"$ref":"#/channels/recentBridges/messages/recentBridgesSnapshot"}],"security":[]},"subscribeToOrders":{"action":"send","summary":"Subscribe to live snapshots for owned orders","description":"Send a subscribe message for each order to follow; each message carries that order’s owner session. The server immediately sends a complete current-order snapshot, then sends complete snapshots after order changes and periodically. Send unsubscribe when an order is no longer needed. Server frames contain only the complete order object, with no wrapper.","channel":{"$ref":"#/channels/orders"},"messages":[{"$ref":"#/channels/orders/messages/orderSubscription"}],"security":[{"orderSession":[]}]},"receiveOrderSnapshots":{"action":"receive","summary":"Subscribe to live snapshots for owned orders","description":"Send a subscribe message for each order to follow; each message carries that order’s owner session. The server immediately sends a complete current-order snapshot, then sends complete snapshots after order changes and periodically. Send unsubscribe when an order is no longer needed. Server frames contain only the complete order object, with no wrapper.","channel":{"$ref":"#/channels/orders"},"messages":[{"$ref":"#/channels/orders/messages/orderSnapshot"}],"security":[{"orderSession":[]}]}},"components":{"securitySchemes":{"orderSession":{"type":"httpApiKey","in":"header","name":"x-session-id","description":"Owner credential returned at order creation. Use only in a header, never in a URL."},"destinationProof":{"type":"httpApiKey","in":"query","name":"verify","description":"Read-only proof: the exact order destination address. Browser WebSockets use this proof."}}},"x-wagyu-close-codes":{"4404":"Missing, unauthorized, and nonexistent orders are intentionally indistinguishable."}}