The response body shown here is a static example, not live data. After you click Send, your live result appears in a separate panel headed 200 OK. The panel under the status-code tabs is a fixed sample from the spec — its field values (fees, prices, sizes, IDs, timestamps) are placeholders. Use Send, or call the endpoint, for current values.
Submit a withdrawal of collateral to the chain. The optional spotAssetId field selects what is withdrawn:
USDG (default, spotAssetId omitted or 0): quote-currency collateral, amount in quote quantums — the original v0 behavior, byte-for-byte.
Spot collateral asset (spotAssetId > 0): an asset from GET /v1/spotAssets (e.g. 1 = SPY-USD-SPOT), amount in the ASSET’S base quantums. Wallet-signed requests sign the dedicated EIP-712 type (SpotAssetWithdraw, see below); API-key-signed requests include the conditional sa key in the WithdrawV1 canonical payload (see below).
Two mutually exclusive authentication modes are supported, selected by the presence of the X-API-Key header:
Wallet-signed (default): the request is self-authenticated by a secp256k1 EIP-712 typed-data signature in the body’s signature field — no X-API-Key / X-Signature headers. This is the original v0 mode, unchanged.
API-key-signed: the request carries the X-API-Key / X-Timestamp / X-Signature header triple with an Ed25519 signature over the ordersign WithdrawV1 typed canonical payload (see below); the body signature field is ignored. The key must be bound to exactly the requested (ethereumAddress, accountIndex) and must carry the opt-in withdraw permission (grantable only through the operator’s provisioning flow — keys from the public POST /createApiKey are always trade-only and are rejected with HTTP 403). This mode exists for contract-owned accounts (e.g. vaults), which cannot produce wallet signatures. Spot-asset withdrawals (spotAssetId > 0) are supported under the same withdraw permission: the canonical payload’s conditional sa key binds the asset id, so a captured USDG signature can never be replayed as a spot withdrawal or vice versa.
In v0 only withdraw-to-self is supported on both modes: the recipient is always the wallet that owns the account (ethereumAddress), so there is no to field — an API key can only move funds to the account owner’s own address.
Response behavior
Asynchronous. A 202 Accepted means the withdrawal passed validation and was queued to the matching engine with status: PENDING. The definitive outcome (applied, or rejected for insufficient free collateral) is delivered asynchronously — poll GET /v1/accountTransferUpdates or subscribe to the account transfer update WebSocket channel and correlate on withdrawalId. Spot-specific rejections: REJECTED_INSUFFICIENT_SPOT_BALANCE (holds less than amount), REJECTED_ACCOUNT_IN_WIND_DOWN (account is a frozen estate under liquidation), REJECTED_INVALID_MARKET, and REJECTED_INSUFFICIENT_COLLATERAL (removing the collateral would leave an outstanding loan under-collateralized).
Signing the request (USDG)
Withdrawals use EIP-712 typed data (eth_signTypedData_v4), so wallets render each field and institutional / MPC signers can whitelist on the domain. Sign this typed data with the wallet that owns ethereumAddress, then split the 65-byte result into {r, s, v} for the signature field. The gateway recovers the signer and rejects mismatches with HTTP 401.Domain
{ "name": "Arcus Withdraw", "version": "1", "chainId": <rootchain chain id, e.g. 4663>, "verifyingContract": "<BridgeVault address for that chain>"}
The v component must be 0x1b (27) or 0x1c (28); wallets that return 0 / 1 should have 27 added before sending.
Signing the request (spot asset, spotAssetId > 0)
Spot-asset withdrawals sign the SpotAssetWithdraw primary type under a domain dedicated to spot withdrawals — a captured USDG Withdraw signature can never authorize a spot withdrawal, and vice versa. spotAssetId (in both the signed message and HTTP body) and amount are both signed, so neither can be swapped after signing.Domain — same chainId / verifyingContract (BridgeVault) as the USDG domain above; only the name differs:
The X-Signature header carries a lowercase-hex Ed25519 signature over the ordersign WithdrawV1 typed canonical payload — the same compact key-sorted-JSON convention as placeOrder. The payload is built from parsed request values (never raw body bytes):
Keys are strictly alphabetical (ad, ai, ct, n, op, q, [sa,] v) with no whitespace. ct must equal the X-Timestamp header value (nanosecond epoch), binding the signature to the drift window; op is fixed at 5 (withdraw — an order signature can never authorize a withdrawal); q is the integer quantum amount (same value as the amount field, unquoted): quote quantums for USDG, the asset’s base quantums for a spot asset; n is the body nonce signed verbatim.The sa key is conditional: present if and only if the body’s spotAssetId is > 0 (it then binds the asset id into the signature). For USDG withdrawals (spotAssetId omitted or 0) the payload must NOT contain an sa key at all — "sa":0 is not a valid encoding and fails verification. USDG payload bytes are therefore identical to clients built before spot support existed.Example (USDG payload → signature):
Replay protection is two-layered on this mode: the X-Timestamp drift window bounds how long a captured signature stays valid, and the nonce is single-use per (ethereumAddress, accountIndex) — plus spotAssetId for spot assets — exactly as on the wallet-signed mode (409 on reuse).
Authorizations
X-API-Key
string
header
required
Hex-encoded Ed25519 public key (64 chars). The public key IS the API key — register it via POST /createApiKey. Required on every authenticated request, both read-only and signed.
X-Timestamp
string
header
required
Unix time in nanoseconds as a decimal string (e.g. "1713825891591000000"). Millisecond or second epochs are rejected with 401 Unauthorized. Must be within ±30,000 ms of server wall-clock, or the request is rejected with 401 Unauthorized. Required on all mutating / credential-creating endpoints. This same value must appear as the ct field in the ordersign typed canonical payload (single-order endpoints) or in each element's ct field (batch endpoints).
Single-order endpoints (placeOrder, cancelOrder, modifyOrder, and other non-batch mutating routes) sign over the ordersign typed canonical payload — a compact, key-sorted JSON object built from parsed request fields using engine-native integer values:
placeOrder: {"ad":"0x…","ai":N,[,"c":"…"],"ct":N,"g":N,"m":N,"op":1,"p":N,"q":N,"r":0|1,"s":N,"t":N,"v":1} cancelOrder: {"ad":"0x…","ai":N,[,"c":"…"],"ct":N,[,"id":"…"],"m":N,"op":2,"v":1} modifyOrder: {"ad":"0x…","ai":N,[,"c":"…"],"ct":N,"g":N,[,"id":"…"],"m":N,"op":3,"p":N,"q":N,"r":0|1,"s":N,"t":N,"v":1} (exactly one of id / c)
ct must equal the X-Timestamp header value. Keys in brackets are conditional (omitted when empty). op values: 1=place, 2=cancel, 3=modify. See the ordersign package for field definitions and reference signing code.
Other signed routes (e.g. createApiKey) still use the legacy scheme: signing_message = X-Timestamp + ACTION + canonicalJSON(body), where ACTION is the camelCase final path segment.
Batch endpoints (batchPlaceOrders, batchCancelOrders, batchModifyOrders) do NOT use this header. They authenticate with per-element typed ordersign signatures embedded in the request body (see the global auth description and the per-field signature descriptions on OrderRequest / CancelOrderRequest / ModifyOrderRequest).
Read endpoints are authenticated by ?address= (and optionally X-API-Key) only — no signature is required, except for the signed affiliate reads (see the Referral tag), which require the full header triple; with no body their signing message is X-Timestamp + ACTION. canonicalJSON(body) is the JSON body with object keys sorted lexicographically at every level and no whitespace; the server canonicalizes the received body before verifying, so only the bytes signed over must be canonical. Required on all mutating / credential-creating endpoints.
Body
application/json
ethereumAddress
string
required
Master EVM address initiating the withdrawal. In v0 this is also the on-chain recipient (withdraw-to-self) — there is no separate destination field.
Pattern: ^(0x|0X)?[0-9a-fA-F]{40}$
Example:
"0x742d35cc6634c0532925a3b844bc9e7595f2bd18"
amount
string
required
Amount to withdraw, as a base-10 integer string of quantums. The unit follows spotAssetId — USDG (spotAssetId omitted/0): quote quantums (1e9 = $1; for example, 1000000000 represents $1); requests below the minimum withdrawal size, or above the maximum single-withdrawal size ($1,000,000 / 1000000000000000 quote quantums), are rejected with HTTP 400 (e.g. validation error on field 'amount': must be at least 1000000000 quote quantums, or must be at most 1000000000000000 quote quantums), and the amount must be exactly representable in collateral base units. Spot asset (spotAssetId > 0): the ASSET'S base quantums — see stepSize on the asset's spotAssets entry (e.g. SPY inherits 1e-7 SPY from SPY-USD, so 70000000 = 7 shares); the engine rejects asynchronously with REJECTED_INSUFFICIENT_SPOT_BALANCE if the account holds less, REJECTED_ACCOUNT_IN_WIND_DOWN while the account is a frozen estate, or REJECTED_INSUFFICIENT_COLLATERAL if removing the collateral would leave the loan under-collateralized. In both cases amounts must be positive and fit in a signed 64-bit integer; float-style decimals are rejected.
Pattern: ^[0-9]+$
Example:
"5000000000000"
nonce
string
required
Replay-protection nonce, single-use per (ethereumAddress, accountIndex) — plus spotAssetId for spot-asset withdrawals — a repeated nonce is rejected with 409. Send the current time as nanoseconds since the Unix epoch (a plain base-10 integer, e.g. 1730000000000000000); the server accepts a timestamp up to 48 hours in the past by default (covers slow multi-approver / MPC custody signing) and up to 24 hours in the future by default (clock skew only) — both bounds are configurable per environment, so treat these as defaults, not guarantees. A legacy opaque nonce (e.g. a UUID) is still accepted for backward compatibility but is deprecated — prefer the nanosecond timestamp form. At most 64 characters.
Required string length: 1 - 64
Example:
"1730000000000000000"
accountIndex
integer
Trading account to debit. Defaults to 0 when omitted.
Required range: 0 <= x <= 9
spotAssetId
integer
What to withdraw. Omitted or 0 = USDG (quote currency, the default). A value > 0 names a spot collateral asset to withdraw instead (e.g. 1 = SPY-USD-SPOT — see GET /v1/spotAssets), which switches the amount unit to the asset's base quantums, the signed EIP-712 type to SpotAssetWithdraw (wallet-signed mode), and adds the conditional sa key to the WithdrawV1 canonical payload (API-key mode).
Example:
1
signature
object
secp256k1 EIP-712 typed-data signature (r, s, v) produced with eth_signTypedData_v4 by the wallet that owns ethereumAddress. The primary type follows spotAssetId: the Withdraw payload for USDG, the SpotAssetWithdraw payload (which additionally binds spotAssetId) when spotAssetId > 0 — see the POST /v1/withdraw endpoint description for the exact domains, types, and messages. Requests whose recovered signer does not match are rejected with HTTP 401. Conditionally required: mandatory on the default wallet-signed path (its absence is a 400); ignored on the API-key path, where the request instead carries the X-API-Key / X-Timestamp / X-Signature headers and the Ed25519 WithdrawV1 proof lives in the X-Signature header.
Show child attributes
Response
Withdrawal accepted and queued to the matching engine. The body carries status: PENDING and a withdrawalId; the terminal outcome is delivered on the account transfer update stream.
withdrawalId
string
required
Server-generated identifier (UUID) correlating this withdrawal with the matching AccountTransferUpdate on the account transfer update stream.
Example:
"b3f1c2d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
ethereumAddress
string
required
20-byte EVM address as hex: optional 0x or 0X prefix and exactly 40 hexadecimal digits. API responses normalize to lowercase a–f after 0x.
Pattern: ^(0x|0X)?[0-9a-fA-F]{40}$
accountIndex
integer
required
Account index (account index, 0–9). Identifies the account for orders, positions, fills, and API keys.
Required range: 0 <= x <= 9
amount
string
required
Withdrawal amount echoed back as a human-readable decimal in the withdrawn asset's units — quote currency (quote resolution 1e9) for USDG, the asset's own units for a spot asset (a spot request amount of "98795" base quantums at stepSize 0.0000001 echoes "0.0098795"), matching how the amount is reported on the account transfer update feed.
Examples:
"5000"
"1.5"
status
enum<string>
required
Synchronous status of a submitted withdrawal. Always PENDING on the 202 response — the withdrawal has been queued to the matching engine but not yet applied. The terminal outcome (APPLIED, REJECTED_INSUFFICIENT_COLLATERAL, ...) is delivered asynchronously on the account transfer update stream (see AccountTransferUpdate).
Available options:
PENDING
submittedAt
integer<int64>
required
Server receive timestamp (epoch microseconds).
spotAssetId
integer
Spot asset id being withdrawn. Present only on spot-asset withdrawals (request had spotAssetId > 0) — USDG responses omit both spotAssetId and spotAssetDisplayName, keeping their shape identical to before the field existed.
Example:
1
spotAssetDisplayName
string
Display name for spotAssetId (mirrors spotAssetDisplayName on GET /v1/spotAssets). Present only on spot-asset withdrawals.
Example:
"SPY-USD-SPOT"
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Arcus Docs","colors":{"primary":"#16A34A","light":"#07C983","dark":"#15803D"},"logo":{"light":"https://mintcdn.com/arcus-11aecf6e/Pw2ZUiZemhLSrOMO/logo/light.svg?fit=max\u0026auto=format\u0026n=Pw2ZUiZemhLSrOMO\u0026q=85\u0026s=9bbd1de2de2a31d08c50e0d58bdac466","dark":"https://mintcdn.com/arcus-11aecf6e/Pw2ZUiZemhLSrOMO/logo/dark.svg?fit=max\u0026auto=format\u0026n=Pw2ZUiZemhLSrOMO\u0026q=85\u0026s=811a9395d1f3457230f9f5defa23c9d0"},"favicon":"https://mintcdn.com/arcus-11aecf6e/cwobDWFqGCQyNAqW/favicon.svg?fit=max\u0026auto=format\u0026n=cwobDWFqGCQyNAqW\u0026q=85\u0026s=c3d0e980a4a9fe344d7143e7f3c18caf","navbar":{"links":[{"href":"https://help.arcus.xyz","label":"Help Center"}],"primary":{"type":"button","label":"Go to Arcus","href":"https://app.arcus.xyz"}},"integrations":{"ga4":{"measurementId":"G-1232GKGLVQ"},"intercom":{"appId":"fdd72bam"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"arcus-11aecf6e","hasAudioNarration":false,"actualSubdomain":"arcus-11aecf6e","customDomains":["docs.arcus.xyz"],"gitSource":{"type":"github","owner":"dydxprotocol","repo":"v5-documentation","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true,"agentFeedback":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6af6b1f7aa6a9b02a8ca4e72","clientVersion":"0.0.4143","searchFilterCounts":[{"language":"default","tag":"API reference","count":99},{"language":"default","tag":"Endpoints","count":69},{"language":"default","tag":"Public","count":36},{"language":"default","tag":"WebSocket","count":22},{"language":"default","tag":"Concepts","count":20},{"language":"default","tag":"Referral","count":17},{"language":"default","tag":"Exchange","count":13},{"language":"default","tag":"Market data","count":11},{"language":"default","tag":"Guides","count":10},{"language":"default","tag":"Perpetuals","count":10}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":true,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[{"_id":"6a0c053228609ad420f986bc","deploymentId":"69f19afe69cb5ad533409b0a","questionText":"How do I place an order","status":"active","generatedBy":"manual","createdAt":"2026-05-19T06:37:38.436Z","updatedAt":"2026-05-19T06:37:38.436Z","__v":0}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/exchange/submit-withdrawal","slug":"/api-reference/exchange/submit-withdrawal","pageMetadata":{"title":"Submit withdrawal","description":"Submit a withdrawal of collateral to the chain.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/withdraw","href":"/api-reference/exchange/submit-withdrawal","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Submit a withdrawal of collateral to the chain.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Note,Table}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsxs(Note,{children:[_jsx(_components.strong,{children:`The response body shown here is a static example, not live data.`}),` After you click `,_jsx(_components.strong,{children:`Send`}),`, your live result appears in a separate panel headed `,_jsx(_components.strong,{children:`200 OK`}),`. The panel under the status-code tabs is a fixed sample from the spec — its field values (fees, prices, sizes, IDs, timestamps) are placeholders. Use `,_jsx(_components.strong,{children:`Send`}),`, or call the endpoint, for current values.`]}),`\n`,_jsxs(_components.p,{children:[`Submit a withdrawal of collateral to the chain. The optional `,_jsx(_components.code,{children:`spotAssetId`}),` field selects `,_jsx(_components.strong,{children:`what`}),` is withdrawn:`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[`USDG (default, `,_jsx(_components.code,{children:`spotAssetId`}),` omitted or `,_jsx(_components.code,{children:`0`}),`):`]}),` quote-currency collateral, `,_jsx(_components.code,{children:`amount`}),` in quote quantums — the original v0 behavior, byte-for-byte.`]}),`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[`Spot collateral asset (`,_jsx(_components.code,{children:`spotAssetId`}),` > 0):`]}),` an asset from `,_jsx(_components.code,{children:`GET /v1/spotAssets`}),` (e.g. 1 = SPY-USD-SPOT), `,_jsx(_components.code,{children:`amount`}),` in the ASSET’S base quantums. Wallet-signed requests sign the dedicated EIP-712 type (`,_jsx(_components.code,{children:`SpotAssetWithdraw`}),`, see below); API-key-signed requests include the conditional `,_jsx(_components.code,{children:`sa`}),` key in the `,_jsx(_components.code,{children:`WithdrawV1`}),` canonical payload (see below).`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`Two mutually exclusive authentication modes are supported, selected by the presence of the `,_jsx(_components.code,{children:`X-API-Key`}),` header:`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Wallet-signed (default):`}),` the request is self-authenticated by a secp256k1 `,_jsx(_components.strong,{children:`EIP-712`}),` typed-data signature in the body’s `,_jsx(_components.code,{children:`signature`}),` field — no `,_jsx(_components.code,{children:`X-API-Key`}),` / `,_jsx(_components.code,{children:`X-Signature`}),` headers. This is the original v0 mode, unchanged.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API-key-signed:`}),` the request carries the `,_jsx(_components.code,{children:`X-API-Key`}),` / `,_jsx(_components.code,{children:`X-Timestamp`}),` / `,_jsx(_components.code,{children:`X-Signature`}),` header triple with an Ed25519 signature over the `,_jsxs(_components.strong,{children:[`ordersign `,_jsx(_components.code,{children:`WithdrawV1`}),` typed canonical payload`]}),` (see below); the body `,_jsx(_components.code,{children:`signature`}),` field is ignored. The key must be bound to exactly the requested `,_jsx(_components.code,{children:`(ethereumAddress, accountIndex)`}),` and must carry the opt-in `,_jsx(_components.code,{children:`withdraw`}),` permission (grantable only through the operator’s provisioning flow — keys from the public `,_jsx(_components.code,{children:`POST /createApiKey`}),` are always trade-only and are rejected with HTTP 403). This mode exists for contract-owned accounts (e.g. vaults), which cannot produce wallet signatures. Spot-asset withdrawals (`,_jsx(_components.code,{children:`spotAssetId`}),` > 0) are supported under the same `,_jsx(_components.code,{children:`withdraw`}),` permission: the canonical payload’s conditional `,_jsx(_components.code,{children:`sa`}),` key binds the asset id, so a captured USDG signature can never be replayed as a spot withdrawal or vice versa.`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`In v0 only withdraw-to-self is supported on `,_jsx(_components.strong,{children:`both`}),` modes: the recipient is always the wallet that owns the account (`,_jsx(_components.code,{children:`ethereumAddress`}),`), so there is no `,_jsx(_components.code,{children:`to`}),` field — an API key can only move funds to the account owner’s own address.`]}),`\n`,_jsx(Heading,{level:`3`,id:`response-behavior`,children:`Response behavior`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Asynchronous.`}),` A `,_jsx(_components.code,{children:`202 Accepted`}),` means the withdrawal passed validation and was queued to the matching engine with `,_jsx(_components.code,{children:`status: PENDING`}),`. The definitive outcome (applied, or rejected for insufficient free collateral) is delivered asynchronously — poll `,_jsx(_components.code,{children:`GET /v1/accountTransferUpdates`}),` or subscribe to the account transfer update WebSocket channel and correlate on `,_jsx(_components.code,{children:`withdrawalId`}),`. Spot-specific rejections: `,_jsx(_components.code,{children:`REJECTED_INSUFFICIENT_SPOT_BALANCE`}),` (holds less than `,_jsx(_components.code,{children:`amount`}),`), `,_jsx(_components.code,{children:`REJECTED_ACCOUNT_IN_WIND_DOWN`}),` (account is a frozen estate under liquidation), `,_jsx(_components.code,{children:`REJECTED_INVALID_MARKET`}),`, and `,_jsx(_components.code,{children:`REJECTED_INSUFFICIENT_COLLATERAL`}),` (removing the collateral would leave an outstanding loan under-collateralized).`]}),`\n`,_jsx(Heading,{level:`2`,id:`signing-the-request-usdg`,children:`Signing the request (USDG)`}),`\n`,_jsxs(_components.p,{children:[`Withdrawals use `,_jsx(_components.strong,{children:`EIP-712 typed data`}),` (`,_jsx(_components.code,{children:`eth_signTypedData_v4`}),`), so wallets render each field and institutional / MPC signers can whitelist on the domain. Sign this typed data with the wallet that owns `,_jsx(_components.code,{children:`ethereumAddress`}),`, then split the 65-byte result into `,_jsx(_components.code,{children:`{r, s, v}`}),` for the `,_jsx(_components.code,{children:`signature`}),` field. The gateway recovers the signer and rejects mismatches with HTTP 401.`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Domain`})}),`\n`,_jsx(CodeBlock,{numberOfLines:`7`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`{`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"name\": \"Arcus Withdraw\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"version\": \"1\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"chainId\": \u003crootchain chain id, e.g. 4663>,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"verifyingContract\": \"\u003cBridgeVault address for that chain>\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Types`})}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`Withdraw(address ethereumAddress,uint8 accountIndex,uint256 amount,string nonce)`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Message`})}),`\n`,_jsx(CodeBlock,{numberOfLines:`7`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`{`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"ethereumAddress\": \"\u003cethereumAddress>\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"accountIndex\": \u003caccountIndex>,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"amount\": \"\u003camount>\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"nonce\": \"\u003cnonce>\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`amount`}),` is the integer collateral quote-quantum amount (same value as the `,_jsx(_components.code,{children:`amount`}),` request field).`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Per-environment domain parameters`})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Environment`}),_jsx(_components.th,{children:_jsx(_components.code,{children:`chainId`})}),_jsxs(_components.th,{children:[_jsx(_components.code,{children:`verifyingContract`}),` (`,_jsx(_components.code,{children:`BridgeVault`}),`)`]})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`testnet`}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`46630`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`0x9a6d3499149fea853efe775a3577701539054eaf`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`production`}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`4663`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`0x14b107cf534239c59571b066cb6497a321da897c`})})]})]})]}),`\n`,_jsx(_components.p,{children:_jsxs(_components.strong,{children:[`Complete `,_jsx(_components.code,{children:`eth_signTypedData_v4`}),` call (ethers v6 / viem)`]})}),`\n`,_jsx(CodeBlock,{numberOfLines:`26`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`26`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// ethers v6`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` domain`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Arcus Withdraw\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` version:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"1\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` chainId:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 4663`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// production`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` verifyingContract:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"0x14b107cf534239c59571b066cb6497a321da897c\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` types`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` Withdraw:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"ethereumAddress\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"address\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"accountIndex\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"uint8\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"amount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"uint256\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"nonce\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` message`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` ethereumAddress:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"0xYourAddress\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` accountIndex:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` amount:`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` BigInt`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"5000000000000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`), `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// quote quantums`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` nonce:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"b1c2d3e4-5f60-7182-93a4-b5c6d7e8f901\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sig`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` signer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`signTypedData`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`domain`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`types`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`message`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Split into r / s / v for the request body:`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` r`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`slice`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`66`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` s`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"0x\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` +`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`slice`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`66`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`130`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` v`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"0x\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` +`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`slice`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`130`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`132`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`]})})}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// viem`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sig`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` walletClient`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`signTypedData`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`domain`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`types`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`primaryType:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Withdraw\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`message`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`v`}),` component must be `,_jsx(_components.code,{children:`0x1b`}),` (27) or `,_jsx(_components.code,{children:`0x1c`}),` (28); wallets that return `,_jsx(_components.code,{children:`0`}),` / `,_jsx(_components.code,{children:`1`}),` should have 27 added before sending.`]}),`\n`,_jsxs(Heading,{level:`2`,id:`signing-the-request-spot-asset-spotassetid->-0`,children:[`Signing the request (spot asset, `,_jsx(_components.code,{children:`spotAssetId`}),` > 0)`]}),`\n`,_jsxs(_components.p,{children:[`Spot-asset withdrawals sign the `,_jsx(_components.strong,{children:_jsx(_components.code,{children:`SpotAssetWithdraw`})}),` primary type under a domain dedicated to spot withdrawals — a captured USDG `,_jsx(_components.code,{children:`Withdraw`}),` signature can never authorize a spot withdrawal, and vice versa. `,_jsx(_components.code,{children:`spotAssetId`}),` (in both the signed message and HTTP body) and `,_jsx(_components.code,{children:`amount`}),` are both signed, so neither can be swapped after signing.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Domain`}),` — same `,_jsx(_components.code,{children:`chainId`}),` / `,_jsx(_components.code,{children:`verifyingContract`}),` (BridgeVault) as the USDG domain above; only the name differs:`]}),`\n`,_jsx(CodeBlock,{numberOfLines:`7`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`{`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"name\": \"Arcus Spot Withdraw\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"version\": \"1\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"chainId\": \u003crootchain chain id>,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"verifyingContract\": \"\u003cBridgeVault address>\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Types / message`})}),`\n`,_jsx(CodeBlock,{numberOfLines:`17`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`17`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` types`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` SpotAssetWithdraw:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"ethereumAddress\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"address\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"accountIndex\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"uint8\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"spotAssetId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"uint16\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"amount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"uint256\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"nonce\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` message`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` ethereumAddress:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"0xYourAddress\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` accountIndex:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` spotAssetId:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// SPY-USD-SPOT`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` amount:`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` BigInt`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"70000000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`), `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// asset base quantums (7 SPY)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` nonce:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"1730000000000000000\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sig`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` signer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`signTypedData`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`domain`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`types`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`message`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`signing-the-request-api-key-mode`,children:`Signing the request (API-key mode)`}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`X-Signature`}),` header carries a lowercase-hex Ed25519 signature over the `,_jsxs(_components.strong,{children:[`ordersign `,_jsx(_components.code,{children:`WithdrawV1`}),` typed canonical payload`]}),` — the same compact key-sorted-JSON convention as `,_jsx(_components.code,{children:`placeOrder`}),`. The payload is built from parsed request values (never raw body bytes):`]}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`{\"ad\":\"\u003cethereumAddress, lowercase 0x hex>\",\"ai\":\u003caccountIndex>,\"ct\":\u003cX-Timestamp value, ns>,\"n\":\"\u003cnonce, verbatim>\",\"op\":5,\"q\":\u003camount, integer quantums>,\"v\":1}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[`Keys are strictly alphabetical (`,_jsx(_components.code,{children:`ad`}),`, `,_jsx(_components.code,{children:`ai`}),`, `,_jsx(_components.code,{children:`ct`}),`, `,_jsx(_components.code,{children:`n`}),`, `,_jsx(_components.code,{children:`op`}),`, `,_jsx(_components.code,{children:`q`}),`, [`,_jsx(_components.code,{children:`sa`}),`,] `,_jsx(_components.code,{children:`v`}),`) with no whitespace. `,_jsx(_components.code,{children:`ct`}),` must equal the `,_jsx(_components.code,{children:`X-Timestamp`}),` header value (nanosecond epoch), binding the signature to the drift window; `,_jsx(_components.code,{children:`op`}),` is fixed at `,_jsx(_components.code,{children:`5`}),` (withdraw — an order signature can never authorize a withdrawal); `,_jsx(_components.code,{children:`q`}),` is the integer quantum amount (same value as the `,_jsx(_components.code,{children:`amount`}),` field, unquoted): quote quantums for USDG, the asset’s base quantums for a spot asset; `,_jsx(_components.code,{children:`n`}),` is the body `,_jsx(_components.code,{children:`nonce`}),` signed verbatim.`]}),`\n`,_jsxs(_components.p,{children:[_jsxs(_components.strong,{children:[`The `,_jsx(_components.code,{children:`sa`}),` key is conditional`]}),`: present if and only if the body’s `,_jsx(_components.code,{children:`spotAssetId`}),` is > 0 (it then binds the asset id into the signature). For USDG withdrawals (`,_jsx(_components.code,{children:`spotAssetId`}),` omitted or `,_jsx(_components.code,{children:`0`}),`) the payload must NOT contain an `,_jsx(_components.code,{children:`sa`}),` key at all — `,_jsx(_components.code,{children:`\"sa\":0`}),` is not a valid encoding and fails verification. USDG payload bytes are therefore identical to clients built before spot support existed.`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Example (USDG payload → signature):`})}),`\n`,_jsx(CodeBlock,{numberOfLines:`3`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`3`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`payload = {\"ad\":\"0x1111111111111111111111111111111111111111\",\"ai\":0,\"ct\":1718644999000000000,\"n\":\"1718644999000\",\"op\":5,\"q\":2000000000000,\"v\":1}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`X-Signature = hex(ed25519_sign(privateKey, payload))`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:_jsxs(_components.strong,{children:[`Example (spot-asset payload, `,_jsx(_components.code,{children:`spotAssetId: 1`}),`):`]})}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`payload = {\"ad\":\"0x1111111111111111111111111111111111111111\",\"ai\":0,\"ct\":1718644999000000000,\"n\":\"1718644999000\",\"op\":5,\"q\":2000000000000,\"sa\":1,\"v\":1}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[`Replay protection is two-layered on this mode: the `,_jsx(_components.code,{children:`X-Timestamp`}),` drift window bounds how long a captured signature stays valid, and the `,_jsx(_components.code,{children:`nonce`}),` is single-use per `,_jsx(_components.code,{children:`(ethereumAddress, accountIndex)`}),` — plus `,_jsx(_components.code,{children:`spotAssetId`}),` for spot assets — exactly as on the wallet-signed mode (409 on reuse).`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Submit withdrawal","description":"Submit a withdrawal of collateral to the chain.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/withdraw","href":"/api-reference/exchange/submit-withdrawal","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Response behavior","slug":"response-behavior","depth":3,"children":[]},{"title":"Signing the request (USDG)","slug":"signing-the-request-usdg","depth":2,"children":[]},{"title":"Signing the request (spot asset, spotAssetId > 0)","slug":"signing-the-request-spot-asset-spotassetid->-0","depth":2,"children":[]},{"title":"Signing the request (API-key mode)","slug":"signing-the-request-api-key-mode","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"summary":"Submit withdrawal","description":"Submit a withdrawal of collateral to the chain.","operationId":"withdraw","tags":["Exchange"],"security":["dd966c3c-1017-4868-9ca6-dc9c9a2f9014","163b2ad5-ba14-4fc5-a7cb-4a45849d64ad"],"requestBody":"d834b0fe-becf-4793-922b-ee168b60b111","responses":{"202":"41963272-f1aa-4b1b-8278-edc83db70755","400":"33fc22a4-3dd6-4cd5-93b8-598ffa31e5ad","401":"6ceb377b-4cc8-4d49-b5e7-b0beb787ae0f","403":"febccd29-2e66-48fb-a04b-b1451beb823f","409":"b54f5481-c35f-4489-8c2c-5e75784daf64","429":"ac69423b-1fa7-4654-93f5-dc33992ab281","500":"4709bc18-11e9-4930-9b2c-c2eef1e981cd"},"x-mint":{"content":"\u003cNote>**The response body shown here is a static example, not live data.** After you click **Send**, your live result appears in a separate panel headed **200 OK**. The panel under the status-code tabs is a fixed sample from the spec — its field values (fees, prices, sizes, IDs, timestamps) are placeholders. Use **Send**, or call the endpoint, for current values.\u003c/Note>\n\nSubmit a withdrawal of collateral to the chain. The optional `spotAssetId` field selects **what** is withdrawn:\n\n- **USDG (default, `spotAssetId` omitted or `0`):** quote-currency collateral, `amount` in quote quantums — the original v0 behavior, byte-for-byte.\n- **Spot collateral asset (`spotAssetId` > 0):** an asset from `GET /v1/spotAssets` (e.g. 1 = SPY-USD-SPOT), `amount` in the ASSET'S base quantums. Wallet-signed requests sign the dedicated EIP-712 type (`SpotAssetWithdraw`, see below); API-key-signed requests include the conditional `sa` key in the `WithdrawV1` canonical payload (see below).\n\nTwo mutually exclusive authentication modes are supported, selected by the presence of the `X-API-Key` header:\n\n- **Wallet-signed (default):** the request is self-authenticated by a secp256k1 **EIP-712** typed-data signature in the body's `signature` field — no `X-API-Key` / `X-Signature` headers. This is the original v0 mode, unchanged.\n- **API-key-signed:** the request carries the `X-API-Key` / `X-Timestamp` / `X-Signature` header triple with an Ed25519 signature over the **ordersign `WithdrawV1` typed canonical payload** (see below); the body `signature` field is ignored. The key must be bound to exactly the requested `(ethereumAddress, accountIndex)` and must carry the opt-in `withdraw` permission (grantable only through the operator's provisioning flow — keys from the public `POST /createApiKey` are always trade-only and are rejected with HTTP 403). This mode exists for contract-owned accounts (e.g. vaults), which cannot produce wallet signatures. Spot-asset withdrawals (`spotAssetId` > 0) are supported under the same `withdraw` permission: the canonical payload's conditional `sa` key binds the asset id, so a captured USDG signature can never be replayed as a spot withdrawal or vice versa.\n\nIn v0 only withdraw-to-self is supported on **both** modes: the recipient is always the wallet that owns the account (`ethereumAddress`), so there is no `to` field — an API key can only move funds to the account owner's own address.\n\n### Response behavior\n\n**Asynchronous.** A `202 Accepted` means the withdrawal passed validation and was queued to the matching engine with `status: PENDING`. The definitive outcome (applied, or rejected for insufficient free collateral) is delivered asynchronously — poll `GET /v1/accountTransferUpdates` or subscribe to the account transfer update WebSocket channel and correlate on `withdrawalId`. Spot-specific rejections: `REJECTED_INSUFFICIENT_SPOT_BALANCE` (holds less than `amount`), `REJECTED_ACCOUNT_IN_WIND_DOWN` (account is a frozen estate under liquidation), `REJECTED_INVALID_MARKET`, and `REJECTED_INSUFFICIENT_COLLATERAL` (removing the collateral would leave an outstanding loan under-collateralized).\n\n## Signing the request (USDG)\n\nWithdrawals use **EIP-712 typed data** (`eth_signTypedData_v4`), so wallets render each field and institutional / MPC signers can whitelist on the domain. Sign this typed data with the wallet that owns `ethereumAddress`, then split the 65-byte result into `{r, s, v}` for the `signature` field. The gateway recovers the signer and rejects mismatches with HTTP 401.\n\n**Domain**\n\n```\n{\n \"name\": \"Arcus Withdraw\",\n \"version\": \"1\",\n \"chainId\": \u003crootchain chain id, e.g. 4663>,\n \"verifyingContract\": \"\u003cBridgeVault address for that chain>\"\n}\n```\n\n**Types**\n\n```\nWithdraw(address ethereumAddress,uint8 accountIndex,uint256 amount,string nonce)\n```\n\n**Message**\n\n```\n{\n \"ethereumAddress\": \"\u003cethereumAddress>\",\n \"accountIndex\": \u003caccountIndex>,\n \"amount\": \"\u003camount>\",\n \"nonce\": \"\u003cnonce>\"\n}\n```\n\n`amount` is the integer collateral quote-quantum amount (same value as the `amount` request field).\n\n**Per-environment domain parameters**\n\n| Environment | `chainId` | `verifyingContract` (`BridgeVault`) |\n|-------------|-----------|-------------------------------------|\n| testnet | `46630` | `0x9a6d3499149fea853efe775a3577701539054eaf` |\n| production | `4663` | `0x14b107cf534239c59571b066cb6497a321da897c` |\n\n**Complete `eth_signTypedData_v4` call (ethers v6 / viem)**\n\n```js\n// ethers v6\nconst domain = {\n name: \"Arcus Withdraw\",\n version: \"1\",\n chainId: 4663, // production\n verifyingContract: \"0x14b107cf534239c59571b066cb6497a321da897c\"\n};\nconst types = {\n Withdraw: [\n { name: \"ethereumAddress\", type: \"address\" },\n { name: \"accountIndex\", type: \"uint8\" },\n { name: \"amount\", type: \"uint256\" },\n { name: \"nonce\", type: \"string\" }\n ]\n};\nconst message = {\n ethereumAddress: \"0xYourAddress\",\n accountIndex: 0,\n amount: BigInt(\"5000000000000\"), // quote quantums\n nonce: \"b1c2d3e4-5f60-7182-93a4-b5c6d7e8f901\"\n};\nconst sig = await signer.signTypedData(domain, types, message);\n// Split into r / s / v for the request body:\nconst r = sig.slice(0, 66);\nconst s = \"0x\" + sig.slice(66, 130);\nconst v = \"0x\" + sig.slice(130, 132);\n```\n\n```ts\n// viem\nconst sig = await walletClient.signTypedData({ domain, types, primaryType: \"Withdraw\", message });\n```\n\nThe `v` component must be `0x1b` (27) or `0x1c` (28); wallets that return `0` / `1` should have 27 added before sending.\n\n## Signing the request (spot asset, `spotAssetId` > 0)\n\nSpot-asset withdrawals sign the **`SpotAssetWithdraw`** primary type under a domain dedicated to spot withdrawals — a captured USDG `Withdraw` signature can never authorize a spot withdrawal, and vice versa. `spotAssetId` (in both the signed message and HTTP body) and `amount` are both signed, so neither can be swapped after signing.\n\n**Domain** — same `chainId` / `verifyingContract` (BridgeVault) as the USDG domain above; only the name differs:\n\n```\n{\n \"name\": \"Arcus Spot Withdraw\",\n \"version\": \"1\",\n \"chainId\": \u003crootchain chain id>,\n \"verifyingContract\": \"\u003cBridgeVault address>\"\n}\n```\n\n**Types / message**\n\n```js\nconst types = {\n SpotAssetWithdraw: [\n { name: \"ethereumAddress\", type: \"address\" },\n { name: \"accountIndex\", type: \"uint8\" },\n { name: \"spotAssetId\", type: \"uint16\" },\n { name: \"amount\", type: \"uint256\" },\n { name: \"nonce\", type: \"string\" }\n ]\n};\nconst message = {\n ethereumAddress: \"0xYourAddress\",\n accountIndex: 0,\n spotAssetId: 1, // SPY-USD-SPOT\n amount: BigInt(\"70000000\"), // asset base quantums (7 SPY)\n nonce: \"1730000000000000000\"\n};\nconst sig = await signer.signTypedData(domain, types, message);\n```\n\n## Signing the request (API-key mode)\n\nThe `X-Signature` header carries a lowercase-hex Ed25519 signature over the **ordersign `WithdrawV1` typed canonical payload** — the same compact key-sorted-JSON convention as `placeOrder`. The payload is built from parsed request values (never raw body bytes):\n\n```\n{\"ad\":\"\u003cethereumAddress, lowercase 0x hex>\",\"ai\":\u003caccountIndex>,\"ct\":\u003cX-Timestamp value, ns>,\"n\":\"\u003cnonce, verbatim>\",\"op\":5,\"q\":\u003camount, integer quantums>,\"v\":1}\n```\n\nKeys are strictly alphabetical (`ad`, `ai`, `ct`, `n`, `op`, `q`, [`sa`,] `v`) with no whitespace. `ct` must equal the `X-Timestamp` header value (nanosecond epoch), binding the signature to the drift window; `op` is fixed at `5` (withdraw — an order signature can never authorize a withdrawal); `q` is the integer quantum amount (same value as the `amount` field, unquoted): quote quantums for USDG, the asset's base quantums for a spot asset; `n` is the body `nonce` signed verbatim.\n\n**The `sa` key is conditional**: present if and only if the body's `spotAssetId` is > 0 (it then binds the asset id into the signature). For USDG withdrawals (`spotAssetId` omitted or `0`) the payload must NOT contain an `sa` key at all — `\"sa\":0` is not a valid encoding and fails verification. USDG payload bytes are therefore identical to clients built before spot support existed.\n\n**Example (USDG payload → signature):**\n\n```\npayload = {\"ad\":\"0x1111111111111111111111111111111111111111\",\"ai\":0,\"ct\":1718644999000000000,\"n\":\"1718644999000\",\"op\":5,\"q\":2000000000000,\"v\":1}\nX-Signature = hex(ed25519_sign(privateKey, payload))\n```\n\n**Example (spot-asset payload, `spotAssetId: 1`):**\n\n```\npayload = {\"ad\":\"0x1111111111111111111111111111111111111111\",\"ai\":0,\"ct\":1718644999000000000,\"n\":\"1718644999000\",\"op\":5,\"q\":2000000000000,\"sa\":1,\"v\":1}\n```\n\nReplay protection is two-layered on this mode: the `X-Timestamp` drift window bounds how long a captured signature stays valid, and the `nonce` is single-use per `(ethereumAddress, accountIndex)` — plus `spotAssetId` for spot assets — exactly as on the wallet-signed mode (409 on reuse)."},"method":"post","type":"path","servers":["8bcbded4-ced7-41f7-9103-ef78afb86c4b","db341041-78f8-47d5-bb08-4c97d4cfedb3"],"path":"/v1/withdraw","baseUrlOptions":["https://api.arcus.xyz","https://api.testnet.arcus.xyz"],"title":"Submit withdrawal","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ethereumAddress","amount","nonce"],"properties":{"ethereumAddress":{"type":"string","pattern":"^(0x|0X)?[0-9a-fA-F]{40}$","description":"Master EVM address initiating the withdrawal. In v0 this is also the on-chain recipient (withdraw-to-self) — there is no separate destination field.","examples":["0x742d35cc6634c0532925a3b844bc9e7595f2bd18"],"isRequired":true,"uniqueKey":"ethereumAddress","typeLabel":"string"},"amount":{"type":"string","pattern":"^[0-9]+$","description":"Amount to withdraw, as a base-10 integer string of quantums. The unit follows `spotAssetId` — **USDG (spotAssetId omitted/0):** quote quantums (1e9 = $1; for example, 1000000000 represents $1); requests below the minimum withdrawal size, or above the maximum single-withdrawal size ($1,000,000 / `1000000000000000` quote quantums), are rejected with HTTP 400 (e.g. `validation error on field 'amount': must be at least 1000000000 quote quantums`, or `must be at most 1000000000000000 quote quantums`), and the amount must be exactly representable in collateral base units. **Spot asset (spotAssetId > 0):** the ASSET'S base quantums — see `stepSize` on the asset's `spotAssets` entry (e.g. SPY inherits 1e-7 SPY from SPY-USD, so 70000000 = 7 shares); the engine rejects asynchronously with `REJECTED_INSUFFICIENT_SPOT_BALANCE` if the account holds less, `REJECTED_ACCOUNT_IN_WIND_DOWN` while the account is a frozen estate, or `REJECTED_INSUFFICIENT_COLLATERAL` if removing the collateral would leave the loan under-collateralized. In both cases amounts must be positive and fit in a signed 64-bit integer; float-style decimals are rejected.","examples":["5000000000000"],"isRequired":true,"uniqueKey":"amount","typeLabel":"string"},"nonce":{"type":"string","minLength":1,"maxLength":64,"description":"Replay-protection nonce, single-use per `(ethereumAddress, accountIndex)` — plus `spotAssetId` for spot-asset withdrawals — a repeated nonce is rejected with 409. Send the current time as nanoseconds since the Unix epoch (a plain base-10 integer, e.g. `1730000000000000000`); the server accepts a timestamp up to 48 hours in the past by default (covers slow multi-approver / MPC custody signing) and up to 24 hours in the future by default (clock skew only) — both bounds are configurable per environment, so treat these as defaults, not guarantees. A legacy opaque nonce (e.g. a UUID) is still accepted for backward compatibility but is deprecated — prefer the nanosecond timestamp form. At most 64 characters.","examples":["1730000000000000000"],"isRequired":true,"uniqueKey":"nonce","typeLabel":"string"},"accountIndex":{"type":"integer","minimum":0,"maximum":9,"description":"Trading account to debit. Defaults to 0 when omitted.","uniqueKey":"accountIndex","typeLabel":"integer"},"spotAssetId":{"type":"integer","description":"What to withdraw. Omitted or `0` = USDG (quote currency, the default). A value > 0 names a spot collateral asset to withdraw instead (e.g. 1 = SPY-USD-SPOT — see `GET /v1/spotAssets`), which switches the `amount` unit to the asset's base quantums, the signed EIP-712 type to `SpotAssetWithdraw` (wallet-signed mode), and adds the conditional `sa` key to the `WithdrawV1` canonical payload (API-key mode).","examples":[1],"uniqueKey":"spotAssetId","typeLabel":"integer"},"signature":{"type":"object","description":"secp256k1 **EIP-712** typed-data signature `(r, s, v)` produced with `eth_signTypedData_v4` by the wallet that owns `ethereumAddress`. The primary type follows `spotAssetId`: the `Withdraw` payload for USDG, the `SpotAssetWithdraw` payload (which additionally binds `spotAssetId`) when `spotAssetId` > 0 — see the `POST /v1/withdraw` endpoint description for the exact domains, types, and messages. Requests whose recovered signer does not match are rejected with HTTP 401. **Conditionally required:** mandatory on the default wallet-signed path (its absence is a 400); ignored on the API-key path, where the request instead carries the `X-API-Key` / `X-Timestamp` / `X-Signature` headers and the Ed25519 `WithdrawV1` proof lives in the `X-Signature` header.","required":["r","s","v"],"properties":{"r":{"type":"string","pattern":"^(?=.*[1-9a-fA-F])(0x)?[0-9a-fA-F]{1,64}$","minLength":1,"maxLength":66,"description":"Hex-encoded r component of the secp256k1 signature (up to 32 bytes; leading zeros may be omitted, but the value must be non-zero).","examples":["0x69e7308419769592ec8363d002e3077e803e403b4e1920fc30e485b63d76e2a3"],"isRequired":true,"uniqueKey":"signature.r","typeLabel":"string"},"s":{"type":"string","pattern":"^(?=.*[1-9a-fA-F])(0x)?[0-9a-fA-F]{1,64}$","minLength":1,"maxLength":66,"description":"Hex-encoded s component of the secp256k1 signature (up to 32 bytes; leading zeros may be omitted, but the value must be non-zero).","examples":["0x0980d0742c9e65037af9d54e559704ae2c2285f3112a9d89544191a740f103cf"],"isRequired":true,"uniqueKey":"signature.s","typeLabel":"string"},"v":{"type":"string","pattern":"^(0x)?[0-9a-fA-F]{1,8}$","minLength":1,"maxLength":10,"description":"Hex-encoded recovery byte (`v`). Accepts any standard Ethereum encoding: raw recovery id (`0x00` / `0x01`), legacy (`0x1b` / `0x1c`), or EIP-155 chain-bound values; the gateway normalizes internally. Most wallet signing APIs (`eth_signTypedData_v4`, `personal_sign`) emit `0x1b`/`0x1c`.","examples":["0x1c"],"isRequired":true,"uniqueKey":"signature.v","typeLabel":"string"}},"uniqueKey":"signature","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"ethereumAddress":"0x742d35cc6634c0532925a3b844bc9e7595f2bd18","amount":"5000000000000","nonce":"1730000000000000000","accountIndex":4,"spotAssetId":1}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"41963272-f1aa-4b1b-8278-edc83db70755":{"description":"Withdrawal accepted and queued to the matching engine. The body carries `status: PENDING` and a `withdrawalId`; the terminal outcome is delivered on the account transfer update stream.\n","content":{"application/json":{"schema":{"type":"object","required":["withdrawalId","ethereumAddress","accountIndex","amount","status","submittedAt"],"properties":{"withdrawalId":{"type":"string","description":"Server-generated identifier (UUID) correlating this withdrawal with the matching `AccountTransferUpdate` on the account transfer update stream.","examples":["b3f1c2d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"],"isRequired":true,"uniqueKey":"withdrawalId","typeLabel":"string"},"ethereumAddress":{"type":"string","pattern":"^(0x|0X)?[0-9a-fA-F]{40}$","description":"20-byte EVM address as hex: optional `0x` or `0X` prefix and exactly 40 hexadecimal digits. API responses normalize to lowercase `a`–`f` after `0x`.\n","isRequired":true,"uniqueKey":"ethereumAddress","typeLabel":"string"},"accountIndex":{"type":"integer","minimum":0,"maximum":9,"description":"Account index (account index, 0–9). Identifies the account for orders, positions, fills, and API keys.","isRequired":true,"uniqueKey":"accountIndex","typeLabel":"integer"},"amount":{"type":"string","description":"Withdrawal amount echoed back as a human-readable decimal in the withdrawn asset's units — quote currency (quote resolution 1e9) for USDG, the asset's own units for a spot asset (a spot request `amount` of `\"98795\"` base quantums at `stepSize` 0.0000001 echoes `\"0.0098795\"`), matching how the amount is reported on the account transfer update feed.","examples":["5000","1.5"],"isRequired":true,"uniqueKey":"amount","typeLabel":"string"},"status":{"type":"string","enum":["PENDING"],"description":"Synchronous status of a submitted withdrawal. Always `PENDING` on the `202` response — the withdrawal has been queued to the matching engine but not yet applied. The terminal outcome (`APPLIED`, `REJECTED_INSUFFICIENT_COLLATERAL`, ...) is delivered asynchronously on the account transfer update stream (see `AccountTransferUpdate`).","isRequired":true,"uniqueKey":"status","typeLabel":"enum\u003cstring>"},"submittedAt":{"type":"integer","format":"int64","description":"Server receive timestamp (epoch microseconds).","isRequired":true,"uniqueKey":"submittedAt","typeLabel":"integer\u003cint64>"},"spotAssetId":{"type":"integer","description":"Spot asset id being withdrawn. Present only on spot-asset withdrawals (request had `spotAssetId` > 0) — USDG responses omit both `spotAssetId` and `spotAssetDisplayName`, keeping their shape identical to before the field existed.","examples":[1],"uniqueKey":"spotAssetId","typeLabel":"integer"},"spotAssetDisplayName":{"type":"string","description":"Display name for `spotAssetId` (mirrors `spotAssetDisplayName` on `GET /v1/spotAssets`). Present only on spot-asset withdrawals.","examples":["SPY-USD-SPOT"],"uniqueKey":"spotAssetDisplayName","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"withdrawalId":"b3f1c2d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d","ethereumAddress":"\u003cstring>","accountIndex":4,"amount":"5000","status":"PENDING","submittedAt":123,"spotAssetId":1,"spotAssetDisplayName":"SPY-USD-SPOT"}}},"exampleType":"generated"}},"exampleType":"generated"},"33fc22a4-3dd6-4cd5-93b8-598ffa31e5ad":{"description":"Validation error: missing `ethereumAddress` / `amount` / `nonce` / `signature`, account index out of range, amount not a positive base-10 integer, below the minimum withdrawal size or above the maximum single-withdrawal size for the collateral currency (USDG; maximum $1,000,000 / `1000000000000000` quote quantums), not exactly representable in collateral base units (USDG), a `spotAssetId` that does not name an allocated spot collateral market, overflowing int64, malformed Ethereum address, a malformed `(r, s, v)` signature, or a nanosecond-timestamp nonce that is not in nanoseconds or falls outside the accepted drift window. A below-minimum amount returns an error such as `validation error on field 'amount': must be at least 1000000000 quote quantums`. An above-maximum amount returns `validation error on field 'amount': must be at most 1000000000000000 quote quantums`.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message.","examples":["Invalid request body"],"isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","description":"Machine-readable error code for generic (non-order) rejections. Present on geo-restriction blocks; clients should key product-availability UI off this rather than the human `error` string.\n\n| Value | Meaning |\n|------------------|---------|\n| `GEO_RESTRICTED` | The action is not available from the caller's country/region for this product (perps and/or spot). Reads remain available; only state-changing actions are blocked. |\n","enum":["GEO_RESTRICTED"],"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"errorSource":{"type":"string","description":"Scopes the failure to a specific operation. Present on structured order errors (place / cancel / modify flows); absent on generic HTTP errors.\n","enum":["Order","Cancel"],"uniqueKey":"errorSource","typeLabel":"enum\u003cstring>"},"errorType":{"type":"string","description":"Machine-readable reason for the API-layer rejection. Present alongside `errorSource` on structured order errors; absent on generic HTTP errors.\n\n| Value | Meaning |\n|-------------------|---------|\n| `Tick` | Price or size does not align to the market's tick size / step size. |\n| `InvalidRequest` | A request field failed validation (bad address, unknown market, invalid enum, etc.). TPSL-specific causes: `stopPrice` required when `tpslType` is set; `tpslType` must be `STOP_LOSS` or `TAKE_PROFIT`; `reduceOnly` must be `true` for TPSL orders; trigger price must not sit on the wrong side of the current mark (would fire immediately); batch grouping/shape constraints violated (wrong order count, missing or duplicate `tpslType` legs). |\n| `OracleDeviation` | The order's price deviates from the current oracle price by more than the allowed threshold. Adjust the price closer to the oracle and resubmit. |\n| `ReduceOnly` | A reduce-only order was rejected because filling it would open or increase the account's position rather than reduce it. |\n| `Unavailable` | The requested operation (place / cancel) is temporarily disabled. |\n| `Unauthorized` | API key or trading-identity check failed. |\n| `Forbidden` | The authenticated key is not permitted to perform the requested operation. |\n| `NotImplemented` | The requested capability is not yet available on this path (e.g. TPSL over WebSocket). |\n| `Transmission` | The gateway accepted and validated the request but could not deliver it to the matching engine. Retry. |\n| `Internal` | Unexpected gateway-side failure unrelated to transmission. |\n","enum":["Tick","InvalidRequest","OracleDeviation","ReduceOnly","Unavailable","Unauthorized","Forbidden","NotImplemented","Transmission","Internal"],"uniqueKey":"errorType","typeLabel":"enum\u003cstring>"},"rejectionReason":{"type":"string","description":"Machine-readable engine-level rejection code. Present on `OrderResponse` / `BatchOrderItemResponse` when `status` is `REJECTED` on the synchronous `200` path (i.e. the gateway already had a definitive engine reject before responding). Absent on `202` responses and on HTTP error bodies — in those cases rejection reasons are delivered asynchronously via the `orders` WebSocket channel.\n\n| Value | Meaning |\n|------------------------------------|---------|\n| `POST_ONLY_WOULD_CROSS` | Post-only order would have crossed the book and taken liquidity. |\n| `SELF_TRADE` | Order would match against the account's own resting order; blocked by self-trade prevention. |\n| `UNDERCOLLATERALIZED` | Account has insufficient free collateral / margin to support the order. |\n| `COULD_NOT_FILL` | Generic \"could not fill\" (legacy; prefer `IOC_CANCELED` / `FOK_FAILED`). |\n| `IOC_CANCELED` | IOC order produced zero fills and was canceled. |\n| `FOK_FAILED` | FOK order could not be fully filled at submission. |\n| `REDUCE_ONLY_WOULD_INCREASE` | reduce-only order would have opened or increased the position. |\n| `TOO_MANY_CLIENT_IDS` | Account already has 10,000 live `clientId`s (the per-account maximum). Cancel or let existing orders reach a terminal state to free slots before placing new ones with distinct `clientId`s. |\n| `DUPLICATE_CLIENT_ID` | Account already has an open order with the same `clientId`. |\n| `POSITION_TPSL_ALREADY_EXISTS` | A position-level TPSL of the same trigger class (TP or SL) already exists for this account+market. At most one TP and one SL per market. |\n| `ENTRY_TPSL_CANNOT_BE_POSITION_TPSL` | A TPSL bound to an entry order (`parentOrderId` set) cannot also be a position-level TPSL; entry-linked TPSLs are sized partial legs. |\n| `OPEN_ORDER_CAP_EXCEEDED` | Account has reached its per-account open-order cap; cancel a resting order or let one reach a terminal state before placing another. |\n| `FILL_WILL_EXCEED_TRADING_BOUND` | Outside regular trading hours, the order would fill at or beyond the active off-hours trading bound. Per-order rejection; in-band trading continues. |\n| `OPEN_INTEREST_CAP_EXCEEDED` | Market is at its operator-set open-interest cap and the order's next fill would have increased open interest. OI-neutral and OI-reducing orders still match. |\n| `ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT` | Deprecated — no longer emitted; replaced by `FILL_WILL_EXCEED_TRADING_BOUND`. |\n| `ORDER_NOT_FOUND` | `cancelOrder` referenced an order not on the orderbook (already filled, canceled, never placed, or owned by another account). |\n| `ORDER_NOT_FOUND_FOR_MODIFY` | `modifyOrder` referenced an order not on the regular orderbook; TPSL and untriggered orders cannot be modified. The rejected modify is also buffered briefly and applied if the target placement arrives shortly after. |\n| `MODIFY_CHANGED_IMMUTABLE_FIELD` | `modifyOrder` attempted to change an immutable field (`side`, `timeInForce`, `reduceOnly`, or `orderType`). |\n| `MODIFY_ZERO_SIZE` | `modifyOrder` specified a new size of zero or less. |\n| `POSITION_SIZE_CAP_EXCEEDED` | The order, modify, or resulting fill would exceed the per-market position notional cap. Distinct from `UNDERCOLLATERALIZED`: the account may be fully funded — the size is the problem. |\n| `MODIFY_TPSL_NOT_SUPPORTED` | `modifyOrder` targeted an untriggered TPSL order; TPSL trigger parameters cannot be changed via modify. A live TPSL survives unchanged; a buffered modify that meets an arriving TPSL placement cancels that placement as a precaution. |\n| `MODIFY_SUPERSEDED_BY_CANCEL` | `modifyOrder` was discarded because a `cancelOrder` for the same order is pending; cancels always dominate modifies and the order's final state is canceled. |\n| `MODIFY_SIZE_ALREADY_FILLED` | Under total-size modify semantics, `modifyOrder`'s new size (the order's new TOTAL size) is at or below the quantity already filled, leaving nothing to rest. The original order is canceled (a `CANCELED` update precedes this rejection). |\n","enum":["POST_ONLY_WOULD_CROSS","SELF_TRADE","UNDERCOLLATERALIZED","COULD_NOT_FILL","IOC_CANCELED","FOK_FAILED","REDUCE_ONLY_WOULD_INCREASE","TOO_MANY_CLIENT_IDS","DUPLICATE_CLIENT_ID","POSITION_TPSL_ALREADY_EXISTS","ENTRY_TPSL_CANNOT_BE_POSITION_TPSL","OPEN_ORDER_CAP_EXCEEDED","ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT","ORDER_NOT_FOUND","ORDER_NOT_FOUND_FOR_MODIFY","MODIFY_CHANGED_IMMUTABLE_FIELD","MODIFY_ZERO_SIZE","FILL_WILL_EXCEED_TRADING_BOUND","OPEN_INTEREST_CAP_EXCEEDED","POSITION_SIZE_CAP_EXCEEDED","MODIFY_TPSL_NOT_SUPPORTED","MODIFY_SUPERSEDED_BY_CANCEL","MODIFY_SIZE_ALREADY_FILLED"],"uniqueKey":"rejectionReason","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Invalid request body","code":"GEO_RESTRICTED","errorSource":"Order","errorType":"Tick","rejectionReason":"POST_ONLY_WOULD_CROSS"}}},"exampleType":"generated"}},"exampleType":"generated"},"6ceb377b-4cc8-4d49-b5e7-b0beb787ae0f":{"description":"Authentication failed. Wallet-signed mode: the address recovered from `signature` did not match `ethereumAddress` (including a signature over the wrong EIP-712 type for the request's `spotAssetId`). API-key mode: missing or malformed auth headers, `X-Timestamp` outside the drift window, an unregistered/expired API key, a key not bound to the requested `(ethereumAddress, accountIndex)`, or an Ed25519 `WithdrawV1` signature that does not verify (including one whose conditional `sa` key does not match the request `spotAssetId`).","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message.","examples":["Invalid request body"],"isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","description":"Machine-readable error code for generic (non-order) rejections. Present on geo-restriction blocks; clients should key product-availability UI off this rather than the human `error` string.\n\n| Value | Meaning |\n|------------------|---------|\n| `GEO_RESTRICTED` | The action is not available from the caller's country/region for this product (perps and/or spot). Reads remain available; only state-changing actions are blocked. |\n","enum":["GEO_RESTRICTED"],"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"errorSource":{"type":"string","description":"Scopes the failure to a specific operation. Present on structured order errors (place / cancel / modify flows); absent on generic HTTP errors.\n","enum":["Order","Cancel"],"uniqueKey":"errorSource","typeLabel":"enum\u003cstring>"},"errorType":{"type":"string","description":"Machine-readable reason for the API-layer rejection. Present alongside `errorSource` on structured order errors; absent on generic HTTP errors.\n\n| Value | Meaning |\n|-------------------|---------|\n| `Tick` | Price or size does not align to the market's tick size / step size. |\n| `InvalidRequest` | A request field failed validation (bad address, unknown market, invalid enum, etc.). TPSL-specific causes: `stopPrice` required when `tpslType` is set; `tpslType` must be `STOP_LOSS` or `TAKE_PROFIT`; `reduceOnly` must be `true` for TPSL orders; trigger price must not sit on the wrong side of the current mark (would fire immediately); batch grouping/shape constraints violated (wrong order count, missing or duplicate `tpslType` legs). |\n| `OracleDeviation` | The order's price deviates from the current oracle price by more than the allowed threshold. Adjust the price closer to the oracle and resubmit. |\n| `ReduceOnly` | A reduce-only order was rejected because filling it would open or increase the account's position rather than reduce it. |\n| `Unavailable` | The requested operation (place / cancel) is temporarily disabled. |\n| `Unauthorized` | API key or trading-identity check failed. |\n| `Forbidden` | The authenticated key is not permitted to perform the requested operation. |\n| `NotImplemented` | The requested capability is not yet available on this path (e.g. TPSL over WebSocket). |\n| `Transmission` | The gateway accepted and validated the request but could not deliver it to the matching engine. Retry. |\n| `Internal` | Unexpected gateway-side failure unrelated to transmission. |\n","enum":["Tick","InvalidRequest","OracleDeviation","ReduceOnly","Unavailable","Unauthorized","Forbidden","NotImplemented","Transmission","Internal"],"uniqueKey":"errorType","typeLabel":"enum\u003cstring>"},"rejectionReason":{"type":"string","description":"Machine-readable engine-level rejection code. Present on `OrderResponse` / `BatchOrderItemResponse` when `status` is `REJECTED` on the synchronous `200` path (i.e. the gateway already had a definitive engine reject before responding). Absent on `202` responses and on HTTP error bodies — in those cases rejection reasons are delivered asynchronously via the `orders` WebSocket channel.\n\n| Value | Meaning |\n|------------------------------------|---------|\n| `POST_ONLY_WOULD_CROSS` | Post-only order would have crossed the book and taken liquidity. |\n| `SELF_TRADE` | Order would match against the account's own resting order; blocked by self-trade prevention. |\n| `UNDERCOLLATERALIZED` | Account has insufficient free collateral / margin to support the order. |\n| `COULD_NOT_FILL` | Generic \"could not fill\" (legacy; prefer `IOC_CANCELED` / `FOK_FAILED`). |\n| `IOC_CANCELED` | IOC order produced zero fills and was canceled. |\n| `FOK_FAILED` | FOK order could not be fully filled at submission. |\n| `REDUCE_ONLY_WOULD_INCREASE` | reduce-only order would have opened or increased the position. |\n| `TOO_MANY_CLIENT_IDS` | Account already has 10,000 live `clientId`s (the per-account maximum). Cancel or let existing orders reach a terminal state to free slots before placing new ones with distinct `clientId`s. |\n| `DUPLICATE_CLIENT_ID` | Account already has an open order with the same `clientId`. |\n| `POSITION_TPSL_ALREADY_EXISTS` | A position-level TPSL of the same trigger class (TP or SL) already exists for this account+market. At most one TP and one SL per market. |\n| `ENTRY_TPSL_CANNOT_BE_POSITION_TPSL` | A TPSL bound to an entry order (`parentOrderId` set) cannot also be a position-level TPSL; entry-linked TPSLs are sized partial legs. |\n| `OPEN_ORDER_CAP_EXCEEDED` | Account has reached its per-account open-order cap; cancel a resting order or let one reach a terminal state before placing another. |\n| `FILL_WILL_EXCEED_TRADING_BOUND` | Outside regular trading hours, the order would fill at or beyond the active off-hours trading bound. Per-order rejection; in-band trading continues. |\n| `OPEN_INTEREST_CAP_EXCEEDED` | Market is at its operator-set open-interest cap and the order's next fill would have increased open interest. OI-neutral and OI-reducing orders still match. |\n| `ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT` | Deprecated — no longer emitted; replaced by `FILL_WILL_EXCEED_TRADING_BOUND`. |\n| `ORDER_NOT_FOUND` | `cancelOrder` referenced an order not on the orderbook (already filled, canceled, never placed, or owned by another account). |\n| `ORDER_NOT_FOUND_FOR_MODIFY` | `modifyOrder` referenced an order not on the regular orderbook; TPSL and untriggered orders cannot be modified. The rejected modify is also buffered briefly and applied if the target placement arrives shortly after. |\n| `MODIFY_CHANGED_IMMUTABLE_FIELD` | `modifyOrder` attempted to change an immutable field (`side`, `timeInForce`, `reduceOnly`, or `orderType`). |\n| `MODIFY_ZERO_SIZE` | `modifyOrder` specified a new size of zero or less. |\n| `POSITION_SIZE_CAP_EXCEEDED` | The order, modify, or resulting fill would exceed the per-market position notional cap. Distinct from `UNDERCOLLATERALIZED`: the account may be fully funded — the size is the problem. |\n| `MODIFY_TPSL_NOT_SUPPORTED` | `modifyOrder` targeted an untriggered TPSL order; TPSL trigger parameters cannot be changed via modify. A live TPSL survives unchanged; a buffered modify that meets an arriving TPSL placement cancels that placement as a precaution. |\n| `MODIFY_SUPERSEDED_BY_CANCEL` | `modifyOrder` was discarded because a `cancelOrder` for the same order is pending; cancels always dominate modifies and the order's final state is canceled. |\n| `MODIFY_SIZE_ALREADY_FILLED` | Under total-size modify semantics, `modifyOrder`'s new size (the order's new TOTAL size) is at or below the quantity already filled, leaving nothing to rest. The original order is canceled (a `CANCELED` update precedes this rejection). |\n","enum":["POST_ONLY_WOULD_CROSS","SELF_TRADE","UNDERCOLLATERALIZED","COULD_NOT_FILL","IOC_CANCELED","FOK_FAILED","REDUCE_ONLY_WOULD_INCREASE","TOO_MANY_CLIENT_IDS","DUPLICATE_CLIENT_ID","POSITION_TPSL_ALREADY_EXISTS","ENTRY_TPSL_CANNOT_BE_POSITION_TPSL","OPEN_ORDER_CAP_EXCEEDED","ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT","ORDER_NOT_FOUND","ORDER_NOT_FOUND_FOR_MODIFY","MODIFY_CHANGED_IMMUTABLE_FIELD","MODIFY_ZERO_SIZE","FILL_WILL_EXCEED_TRADING_BOUND","OPEN_INTEREST_CAP_EXCEEDED","POSITION_SIZE_CAP_EXCEEDED","MODIFY_TPSL_NOT_SUPPORTED","MODIFY_SUPERSEDED_BY_CANCEL","MODIFY_SIZE_ALREADY_FILLED"],"uniqueKey":"rejectionReason","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Invalid request body","code":"GEO_RESTRICTED","errorSource":"Order","errorType":"Tick","rejectionReason":"POST_ONLY_WOULD_CROSS"}}},"exampleType":"generated"}},"exampleType":"generated"},"febccd29-2e66-48fb-a04b-b1451beb823f":{"description":"Forbidden. Either geo-restricted (withdrawals are blocked from the caller's country/region; body carries `code: GEO_RESTRICTED`), or — on the API-key mode — the key authenticated correctly but does not carry the `withdraw` permission (trade-only keys, including every key created via the public `POST /createApiKey`, cannot withdraw).","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message.","examples":["Invalid request body"],"isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","description":"Machine-readable error code for generic (non-order) rejections. Present on geo-restriction blocks; clients should key product-availability UI off this rather than the human `error` string.\n\n| Value | Meaning |\n|------------------|---------|\n| `GEO_RESTRICTED` | The action is not available from the caller's country/region for this product (perps and/or spot). Reads remain available; only state-changing actions are blocked. |\n","enum":["GEO_RESTRICTED"],"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"errorSource":{"type":"string","description":"Scopes the failure to a specific operation. Present on structured order errors (place / cancel / modify flows); absent on generic HTTP errors.\n","enum":["Order","Cancel"],"uniqueKey":"errorSource","typeLabel":"enum\u003cstring>"},"errorType":{"type":"string","description":"Machine-readable reason for the API-layer rejection. Present alongside `errorSource` on structured order errors; absent on generic HTTP errors.\n\n| Value | Meaning |\n|-------------------|---------|\n| `Tick` | Price or size does not align to the market's tick size / step size. |\n| `InvalidRequest` | A request field failed validation (bad address, unknown market, invalid enum, etc.). TPSL-specific causes: `stopPrice` required when `tpslType` is set; `tpslType` must be `STOP_LOSS` or `TAKE_PROFIT`; `reduceOnly` must be `true` for TPSL orders; trigger price must not sit on the wrong side of the current mark (would fire immediately); batch grouping/shape constraints violated (wrong order count, missing or duplicate `tpslType` legs). |\n| `OracleDeviation` | The order's price deviates from the current oracle price by more than the allowed threshold. Adjust the price closer to the oracle and resubmit. |\n| `ReduceOnly` | A reduce-only order was rejected because filling it would open or increase the account's position rather than reduce it. |\n| `Unavailable` | The requested operation (place / cancel) is temporarily disabled. |\n| `Unauthorized` | API key or trading-identity check failed. |\n| `Forbidden` | The authenticated key is not permitted to perform the requested operation. |\n| `NotImplemented` | The requested capability is not yet available on this path (e.g. TPSL over WebSocket). |\n| `Transmission` | The gateway accepted and validated the request but could not deliver it to the matching engine. Retry. |\n| `Internal` | Unexpected gateway-side failure unrelated to transmission. |\n","enum":["Tick","InvalidRequest","OracleDeviation","ReduceOnly","Unavailable","Unauthorized","Forbidden","NotImplemented","Transmission","Internal"],"uniqueKey":"errorType","typeLabel":"enum\u003cstring>"},"rejectionReason":{"type":"string","description":"Machine-readable engine-level rejection code. Present on `OrderResponse` / `BatchOrderItemResponse` when `status` is `REJECTED` on the synchronous `200` path (i.e. the gateway already had a definitive engine reject before responding). Absent on `202` responses and on HTTP error bodies — in those cases rejection reasons are delivered asynchronously via the `orders` WebSocket channel.\n\n| Value | Meaning |\n|------------------------------------|---------|\n| `POST_ONLY_WOULD_CROSS` | Post-only order would have crossed the book and taken liquidity. |\n| `SELF_TRADE` | Order would match against the account's own resting order; blocked by self-trade prevention. |\n| `UNDERCOLLATERALIZED` | Account has insufficient free collateral / margin to support the order. |\n| `COULD_NOT_FILL` | Generic \"could not fill\" (legacy; prefer `IOC_CANCELED` / `FOK_FAILED`). |\n| `IOC_CANCELED` | IOC order produced zero fills and was canceled. |\n| `FOK_FAILED` | FOK order could not be fully filled at submission. |\n| `REDUCE_ONLY_WOULD_INCREASE` | reduce-only order would have opened or increased the position. |\n| `TOO_MANY_CLIENT_IDS` | Account already has 10,000 live `clientId`s (the per-account maximum). Cancel or let existing orders reach a terminal state to free slots before placing new ones with distinct `clientId`s. |\n| `DUPLICATE_CLIENT_ID` | Account already has an open order with the same `clientId`. |\n| `POSITION_TPSL_ALREADY_EXISTS` | A position-level TPSL of the same trigger class (TP or SL) already exists for this account+market. At most one TP and one SL per market. |\n| `ENTRY_TPSL_CANNOT_BE_POSITION_TPSL` | A TPSL bound to an entry order (`parentOrderId` set) cannot also be a position-level TPSL; entry-linked TPSLs are sized partial legs. |\n| `OPEN_ORDER_CAP_EXCEEDED` | Account has reached its per-account open-order cap; cancel a resting order or let one reach a terminal state before placing another. |\n| `FILL_WILL_EXCEED_TRADING_BOUND` | Outside regular trading hours, the order would fill at or beyond the active off-hours trading bound. Per-order rejection; in-band trading continues. |\n| `OPEN_INTEREST_CAP_EXCEEDED` | Market is at its operator-set open-interest cap and the order's next fill would have increased open interest. OI-neutral and OI-reducing orders still match. |\n| `ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT` | Deprecated — no longer emitted; replaced by `FILL_WILL_EXCEED_TRADING_BOUND`. |\n| `ORDER_NOT_FOUND` | `cancelOrder` referenced an order not on the orderbook (already filled, canceled, never placed, or owned by another account). |\n| `ORDER_NOT_FOUND_FOR_MODIFY` | `modifyOrder` referenced an order not on the regular orderbook; TPSL and untriggered orders cannot be modified. The rejected modify is also buffered briefly and applied if the target placement arrives shortly after. |\n| `MODIFY_CHANGED_IMMUTABLE_FIELD` | `modifyOrder` attempted to change an immutable field (`side`, `timeInForce`, `reduceOnly`, or `orderType`). |\n| `MODIFY_ZERO_SIZE` | `modifyOrder` specified a new size of zero or less. |\n| `POSITION_SIZE_CAP_EXCEEDED` | The order, modify, or resulting fill would exceed the per-market position notional cap. Distinct from `UNDERCOLLATERALIZED`: the account may be fully funded — the size is the problem. |\n| `MODIFY_TPSL_NOT_SUPPORTED` | `modifyOrder` targeted an untriggered TPSL order; TPSL trigger parameters cannot be changed via modify. A live TPSL survives unchanged; a buffered modify that meets an arriving TPSL placement cancels that placement as a precaution. |\n| `MODIFY_SUPERSEDED_BY_CANCEL` | `modifyOrder` was discarded because a `cancelOrder` for the same order is pending; cancels always dominate modifies and the order's final state is canceled. |\n| `MODIFY_SIZE_ALREADY_FILLED` | Under total-size modify semantics, `modifyOrder`'s new size (the order's new TOTAL size) is at or below the quantity already filled, leaving nothing to rest. The original order is canceled (a `CANCELED` update precedes this rejection). |\n","enum":["POST_ONLY_WOULD_CROSS","SELF_TRADE","UNDERCOLLATERALIZED","COULD_NOT_FILL","IOC_CANCELED","FOK_FAILED","REDUCE_ONLY_WOULD_INCREASE","TOO_MANY_CLIENT_IDS","DUPLICATE_CLIENT_ID","POSITION_TPSL_ALREADY_EXISTS","ENTRY_TPSL_CANNOT_BE_POSITION_TPSL","OPEN_ORDER_CAP_EXCEEDED","ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT","ORDER_NOT_FOUND","ORDER_NOT_FOUND_FOR_MODIFY","MODIFY_CHANGED_IMMUTABLE_FIELD","MODIFY_ZERO_SIZE","FILL_WILL_EXCEED_TRADING_BOUND","OPEN_INTEREST_CAP_EXCEEDED","POSITION_SIZE_CAP_EXCEEDED","MODIFY_TPSL_NOT_SUPPORTED","MODIFY_SUPERSEDED_BY_CANCEL","MODIFY_SIZE_ALREADY_FILLED"],"uniqueKey":"rejectionReason","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Invalid request body","code":"GEO_RESTRICTED","errorSource":"Order","errorType":"Tick","rejectionReason":"POST_ONLY_WOULD_CROSS"}}},"exampleType":"generated"}},"exampleType":"generated"},"b54f5481-c35f-4489-8c2c-5e75784daf64":{"description":"Replay: this `(ethereumAddress, accountIndex, nonce)` — plus `spotAssetId` for spot-asset withdrawals — was already accepted by a prior submission. A signed withdrawal is single-use — resubmitting the identical signed body (or any body with the same `nonce`) does not queue a second withdrawal. Use a fresh `nonce` for each new withdrawal.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message.","examples":["Invalid request body"],"isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","description":"Machine-readable error code for generic (non-order) rejections. Present on geo-restriction blocks; clients should key product-availability UI off this rather than the human `error` string.\n\n| Value | Meaning |\n|------------------|---------|\n| `GEO_RESTRICTED` | The action is not available from the caller's country/region for this product (perps and/or spot). Reads remain available; only state-changing actions are blocked. |\n","enum":["GEO_RESTRICTED"],"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"errorSource":{"type":"string","description":"Scopes the failure to a specific operation. Present on structured order errors (place / cancel / modify flows); absent on generic HTTP errors.\n","enum":["Order","Cancel"],"uniqueKey":"errorSource","typeLabel":"enum\u003cstring>"},"errorType":{"type":"string","description":"Machine-readable reason for the API-layer rejection. Present alongside `errorSource` on structured order errors; absent on generic HTTP errors.\n\n| Value | Meaning |\n|-------------------|---------|\n| `Tick` | Price or size does not align to the market's tick size / step size. |\n| `InvalidRequest` | A request field failed validation (bad address, unknown market, invalid enum, etc.). TPSL-specific causes: `stopPrice` required when `tpslType` is set; `tpslType` must be `STOP_LOSS` or `TAKE_PROFIT`; `reduceOnly` must be `true` for TPSL orders; trigger price must not sit on the wrong side of the current mark (would fire immediately); batch grouping/shape constraints violated (wrong order count, missing or duplicate `tpslType` legs). |\n| `OracleDeviation` | The order's price deviates from the current oracle price by more than the allowed threshold. Adjust the price closer to the oracle and resubmit. |\n| `ReduceOnly` | A reduce-only order was rejected because filling it would open or increase the account's position rather than reduce it. |\n| `Unavailable` | The requested operation (place / cancel) is temporarily disabled. |\n| `Unauthorized` | API key or trading-identity check failed. |\n| `Forbidden` | The authenticated key is not permitted to perform the requested operation. |\n| `NotImplemented` | The requested capability is not yet available on this path (e.g. TPSL over WebSocket). |\n| `Transmission` | The gateway accepted and validated the request but could not deliver it to the matching engine. Retry. |\n| `Internal` | Unexpected gateway-side failure unrelated to transmission. |\n","enum":["Tick","InvalidRequest","OracleDeviation","ReduceOnly","Unavailable","Unauthorized","Forbidden","NotImplemented","Transmission","Internal"],"uniqueKey":"errorType","typeLabel":"enum\u003cstring>"},"rejectionReason":{"type":"string","description":"Machine-readable engine-level rejection code. Present on `OrderResponse` / `BatchOrderItemResponse` when `status` is `REJECTED` on the synchronous `200` path (i.e. the gateway already had a definitive engine reject before responding). Absent on `202` responses and on HTTP error bodies — in those cases rejection reasons are delivered asynchronously via the `orders` WebSocket channel.\n\n| Value | Meaning |\n|------------------------------------|---------|\n| `POST_ONLY_WOULD_CROSS` | Post-only order would have crossed the book and taken liquidity. |\n| `SELF_TRADE` | Order would match against the account's own resting order; blocked by self-trade prevention. |\n| `UNDERCOLLATERALIZED` | Account has insufficient free collateral / margin to support the order. |\n| `COULD_NOT_FILL` | Generic \"could not fill\" (legacy; prefer `IOC_CANCELED` / `FOK_FAILED`). |\n| `IOC_CANCELED` | IOC order produced zero fills and was canceled. |\n| `FOK_FAILED` | FOK order could not be fully filled at submission. |\n| `REDUCE_ONLY_WOULD_INCREASE` | reduce-only order would have opened or increased the position. |\n| `TOO_MANY_CLIENT_IDS` | Account already has 10,000 live `clientId`s (the per-account maximum). Cancel or let existing orders reach a terminal state to free slots before placing new ones with distinct `clientId`s. |\n| `DUPLICATE_CLIENT_ID` | Account already has an open order with the same `clientId`. |\n| `POSITION_TPSL_ALREADY_EXISTS` | A position-level TPSL of the same trigger class (TP or SL) already exists for this account+market. At most one TP and one SL per market. |\n| `ENTRY_TPSL_CANNOT_BE_POSITION_TPSL` | A TPSL bound to an entry order (`parentOrderId` set) cannot also be a position-level TPSL; entry-linked TPSLs are sized partial legs. |\n| `OPEN_ORDER_CAP_EXCEEDED` | Account has reached its per-account open-order cap; cancel a resting order or let one reach a terminal state before placing another. |\n| `FILL_WILL_EXCEED_TRADING_BOUND` | Outside regular trading hours, the order would fill at or beyond the active off-hours trading bound. Per-order rejection; in-band trading continues. |\n| `OPEN_INTEREST_CAP_EXCEEDED` | Market is at its operator-set open-interest cap and the order's next fill would have increased open interest. OI-neutral and OI-reducing orders still match. |\n| `ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT` | Deprecated — no longer emitted; replaced by `FILL_WILL_EXCEED_TRADING_BOUND`. |\n| `ORDER_NOT_FOUND` | `cancelOrder` referenced an order not on the orderbook (already filled, canceled, never placed, or owned by another account). |\n| `ORDER_NOT_FOUND_FOR_MODIFY` | `modifyOrder` referenced an order not on the regular orderbook; TPSL and untriggered orders cannot be modified. The rejected modify is also buffered briefly and applied if the target placement arrives shortly after. |\n| `MODIFY_CHANGED_IMMUTABLE_FIELD` | `modifyOrder` attempted to change an immutable field (`side`, `timeInForce`, `reduceOnly`, or `orderType`). |\n| `MODIFY_ZERO_SIZE` | `modifyOrder` specified a new size of zero or less. |\n| `POSITION_SIZE_CAP_EXCEEDED` | The order, modify, or resulting fill would exceed the per-market position notional cap. Distinct from `UNDERCOLLATERALIZED`: the account may be fully funded — the size is the problem. |\n| `MODIFY_TPSL_NOT_SUPPORTED` | `modifyOrder` targeted an untriggered TPSL order; TPSL trigger parameters cannot be changed via modify. A live TPSL survives unchanged; a buffered modify that meets an arriving TPSL placement cancels that placement as a precaution. |\n| `MODIFY_SUPERSEDED_BY_CANCEL` | `modifyOrder` was discarded because a `cancelOrder` for the same order is pending; cancels always dominate modifies and the order's final state is canceled. |\n| `MODIFY_SIZE_ALREADY_FILLED` | Under total-size modify semantics, `modifyOrder`'s new size (the order's new TOTAL size) is at or below the quantity already filled, leaving nothing to rest. The original order is canceled (a `CANCELED` update precedes this rejection). |\n","enum":["POST_ONLY_WOULD_CROSS","SELF_TRADE","UNDERCOLLATERALIZED","COULD_NOT_FILL","IOC_CANCELED","FOK_FAILED","REDUCE_ONLY_WOULD_INCREASE","TOO_MANY_CLIENT_IDS","DUPLICATE_CLIENT_ID","POSITION_TPSL_ALREADY_EXISTS","ENTRY_TPSL_CANNOT_BE_POSITION_TPSL","OPEN_ORDER_CAP_EXCEEDED","ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT","ORDER_NOT_FOUND","ORDER_NOT_FOUND_FOR_MODIFY","MODIFY_CHANGED_IMMUTABLE_FIELD","MODIFY_ZERO_SIZE","FILL_WILL_EXCEED_TRADING_BOUND","OPEN_INTEREST_CAP_EXCEEDED","POSITION_SIZE_CAP_EXCEEDED","MODIFY_TPSL_NOT_SUPPORTED","MODIFY_SUPERSEDED_BY_CANCEL","MODIFY_SIZE_ALREADY_FILLED"],"uniqueKey":"rejectionReason","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Invalid request body","code":"GEO_RESTRICTED","errorSource":"Order","errorType":"Tick","rejectionReason":"POST_ONLY_WOULD_CROSS"}}},"exampleType":"generated"}},"exampleType":"generated"},"ac69423b-1fa7-4654-93f5-dc33992ab281":{"description":"Rate limit exceeded. Two signals are returned, designed to coexist with both naive HTTP clients and rate-limit-aware SDK clients:\n\n- `Retry-After` header (integer seconds, RFC 7231 compliant). Rounds up — clients that obey this header sleep at least as long as required. Safe for generic HTTP libraries to read.\n- JSON body `retryAfterMs` (precise milliseconds, matches the server's internal computation). Sophisticated clients should prefer this over the header to avoid the round-up overshoot.\n- JSON body `reason` indicates which rate-limit layer rejected: `ip` (per-IP weight bucket), `account_empty` (per-subaccount pool fully exhausted, in drip throttle), `account_partial` (pool has some credit but not enough for this batch — split the request smaller to drain), or `unknown` (defensive fallback).\n- JSON body `clientId` (single-order endpoints) or `clientIds` (batch endpoints) echoes the request's client-supplied order identifier(s) so the client can correlate the rejection to a specific order request.\n","headers":{"Retry-After":{"description":"Seconds the client should wait before retrying the request.","schema":{"type":"integer","minimum":1,"example":1}}},"content":{"application/json":{"schema":{"description":"429 response body shape. Extends the generic `Error` with two rate-limit-specific fields:\n\n- `reason` — which limiter rejected the request. Stable string enum; new values may be added in future versions, so clients should treat unknown values as opaque.\n- `retryAfterMs` — precise milliseconds the client should wait before retrying. The HTTP `Retry-After` header carries the same information rounded up to whole seconds (RFC 7231); prefer this field when sub-second precision matters.\n","type":"object","required":["error"],"properties":{"error":{"type":"string","example":"rate limited","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"reason":{"type":"string","enum":["ip","account_empty","account_partial","unknown"],"description":"Layer that rejected the request:\n * `ip` — per-IP weight bucket exhausted.\n * `account_empty` — per-subaccount pool fully exhausted; the\n drip-throttle has no token available either.\n * `account_partial` — pool has some credit but not enough\n for this batch. Split the request into smaller chunks to\n drain the remaining headroom.\n * `unknown` — defensive fallback; clients should retry per\n `retryAfterMs` and report the occurrence.\n","uniqueKey":"reason","typeLabel":"enum\u003cstring>"},"retryAfterMs":{"type":"integer","format":"int64","minimum":0,"description":"Milliseconds to wait before retrying. Matches the precise wait the rate limiter computed (the `Retry-After` header rounds up to the next whole second).","uniqueKey":"retryAfterMs","typeLabel":"integer\u003cint64>"},"clientId":{"type":"string","description":"Echo of the request's client-supplied `clientId`, so the client can correlate the rejection to a specific order request. Present only on single-order endpoints (placeOrder, modifyOrder, cancelOrder) when the request carried a `clientId`. Omitted on batch endpoints (see `clientIds`) and when the request had none.\n","uniqueKey":"clientId","typeLabel":"string"},"clientIds":{"type":"array","items":{"type":"string","uniqueKey":"clientIds.items.[INDEX]","typeLabel":"string"},"description":"Echo of every client-supplied `clientId` in a batch request (batchPlaceOrders, batchCancelOrders), positionally aligned with the submitted `orders` / `cancels` array. A batch is rejected all-or-nothing, so every listed order was rejected; the echo lets a client submitting multiple batches concurrently correlate the 429 to a specific batch. An entry is empty when that element carried no `clientId` (e.g. a cancel-by-orderId). Omitted on single-order endpoints (see `clientId`).\n","uniqueKey":"clientIds","typeLabel":"string[]"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":"rate limited","reason":"account_empty","retryAfterMs":850,"clientId":"my-order-42"},"examples":{"Example":{"title":"Example","value":{"error":"rate limited","reason":"account_empty","retryAfterMs":850,"clientId":"my-order-42"}}},"exampleType":"examples"}},"exampleType":"examples"},"4709bc18-11e9-4930-9b2c-c2eef1e981cd":{"description":"Internal error (e.g. failed to encode or dispatch the withdrawal).","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message.","examples":["Invalid request body"],"isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","description":"Machine-readable error code for generic (non-order) rejections. Present on geo-restriction blocks; clients should key product-availability UI off this rather than the human `error` string.\n\n| Value | Meaning |\n|------------------|---------|\n| `GEO_RESTRICTED` | The action is not available from the caller's country/region for this product (perps and/or spot). Reads remain available; only state-changing actions are blocked. |\n","enum":["GEO_RESTRICTED"],"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"errorSource":{"type":"string","description":"Scopes the failure to a specific operation. Present on structured order errors (place / cancel / modify flows); absent on generic HTTP errors.\n","enum":["Order","Cancel"],"uniqueKey":"errorSource","typeLabel":"enum\u003cstring>"},"errorType":{"type":"string","description":"Machine-readable reason for the API-layer rejection. Present alongside `errorSource` on structured order errors; absent on generic HTTP errors.\n\n| Value | Meaning |\n|-------------------|---------|\n| `Tick` | Price or size does not align to the market's tick size / step size. |\n| `InvalidRequest` | A request field failed validation (bad address, unknown market, invalid enum, etc.). TPSL-specific causes: `stopPrice` required when `tpslType` is set; `tpslType` must be `STOP_LOSS` or `TAKE_PROFIT`; `reduceOnly` must be `true` for TPSL orders; trigger price must not sit on the wrong side of the current mark (would fire immediately); batch grouping/shape constraints violated (wrong order count, missing or duplicate `tpslType` legs). |\n| `OracleDeviation` | The order's price deviates from the current oracle price by more than the allowed threshold. Adjust the price closer to the oracle and resubmit. |\n| `ReduceOnly` | A reduce-only order was rejected because filling it would open or increase the account's position rather than reduce it. |\n| `Unavailable` | The requested operation (place / cancel) is temporarily disabled. |\n| `Unauthorized` | API key or trading-identity check failed. |\n| `Forbidden` | The authenticated key is not permitted to perform the requested operation. |\n| `NotImplemented` | The requested capability is not yet available on this path (e.g. TPSL over WebSocket). |\n| `Transmission` | The gateway accepted and validated the request but could not deliver it to the matching engine. Retry. |\n| `Internal` | Unexpected gateway-side failure unrelated to transmission. |\n","enum":["Tick","InvalidRequest","OracleDeviation","ReduceOnly","Unavailable","Unauthorized","Forbidden","NotImplemented","Transmission","Internal"],"uniqueKey":"errorType","typeLabel":"enum\u003cstring>"},"rejectionReason":{"type":"string","description":"Machine-readable engine-level rejection code. Present on `OrderResponse` / `BatchOrderItemResponse` when `status` is `REJECTED` on the synchronous `200` path (i.e. the gateway already had a definitive engine reject before responding). Absent on `202` responses and on HTTP error bodies — in those cases rejection reasons are delivered asynchronously via the `orders` WebSocket channel.\n\n| Value | Meaning |\n|------------------------------------|---------|\n| `POST_ONLY_WOULD_CROSS` | Post-only order would have crossed the book and taken liquidity. |\n| `SELF_TRADE` | Order would match against the account's own resting order; blocked by self-trade prevention. |\n| `UNDERCOLLATERALIZED` | Account has insufficient free collateral / margin to support the order. |\n| `COULD_NOT_FILL` | Generic \"could not fill\" (legacy; prefer `IOC_CANCELED` / `FOK_FAILED`). |\n| `IOC_CANCELED` | IOC order produced zero fills and was canceled. |\n| `FOK_FAILED` | FOK order could not be fully filled at submission. |\n| `REDUCE_ONLY_WOULD_INCREASE` | reduce-only order would have opened or increased the position. |\n| `TOO_MANY_CLIENT_IDS` | Account already has 10,000 live `clientId`s (the per-account maximum). Cancel or let existing orders reach a terminal state to free slots before placing new ones with distinct `clientId`s. |\n| `DUPLICATE_CLIENT_ID` | Account already has an open order with the same `clientId`. |\n| `POSITION_TPSL_ALREADY_EXISTS` | A position-level TPSL of the same trigger class (TP or SL) already exists for this account+market. At most one TP and one SL per market. |\n| `ENTRY_TPSL_CANNOT_BE_POSITION_TPSL` | A TPSL bound to an entry order (`parentOrderId` set) cannot also be a position-level TPSL; entry-linked TPSLs are sized partial legs. |\n| `OPEN_ORDER_CAP_EXCEEDED` | Account has reached its per-account open-order cap; cancel a resting order or let one reach a terminal state before placing another. |\n| `FILL_WILL_EXCEED_TRADING_BOUND` | Outside regular trading hours, the order would fill at or beyond the active off-hours trading bound. Per-order rejection; in-band trading continues. |\n| `OPEN_INTEREST_CAP_EXCEEDED` | Market is at its operator-set open-interest cap and the order's next fill would have increased open interest. OI-neutral and OI-reducing orders still match. |\n| `ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT` | Deprecated — no longer emitted; replaced by `FILL_WILL_EXCEED_TRADING_BOUND`. |\n| `ORDER_NOT_FOUND` | `cancelOrder` referenced an order not on the orderbook (already filled, canceled, never placed, or owned by another account). |\n| `ORDER_NOT_FOUND_FOR_MODIFY` | `modifyOrder` referenced an order not on the regular orderbook; TPSL and untriggered orders cannot be modified. The rejected modify is also buffered briefly and applied if the target placement arrives shortly after. |\n| `MODIFY_CHANGED_IMMUTABLE_FIELD` | `modifyOrder` attempted to change an immutable field (`side`, `timeInForce`, `reduceOnly`, or `orderType`). |\n| `MODIFY_ZERO_SIZE` | `modifyOrder` specified a new size of zero or less. |\n| `POSITION_SIZE_CAP_EXCEEDED` | The order, modify, or resulting fill would exceed the per-market position notional cap. Distinct from `UNDERCOLLATERALIZED`: the account may be fully funded — the size is the problem. |\n| `MODIFY_TPSL_NOT_SUPPORTED` | `modifyOrder` targeted an untriggered TPSL order; TPSL trigger parameters cannot be changed via modify. A live TPSL survives unchanged; a buffered modify that meets an arriving TPSL placement cancels that placement as a precaution. |\n| `MODIFY_SUPERSEDED_BY_CANCEL` | `modifyOrder` was discarded because a `cancelOrder` for the same order is pending; cancels always dominate modifies and the order's final state is canceled. |\n| `MODIFY_SIZE_ALREADY_FILLED` | Under total-size modify semantics, `modifyOrder`'s new size (the order's new TOTAL size) is at or below the quantity already filled, leaving nothing to rest. The original order is canceled (a `CANCELED` update precedes this rejection). |\n","enum":["POST_ONLY_WOULD_CROSS","SELF_TRADE","UNDERCOLLATERALIZED","COULD_NOT_FILL","IOC_CANCELED","FOK_FAILED","REDUCE_ONLY_WOULD_INCREASE","TOO_MANY_CLIENT_IDS","DUPLICATE_CLIENT_ID","POSITION_TPSL_ALREADY_EXISTS","ENTRY_TPSL_CANNOT_BE_POSITION_TPSL","OPEN_ORDER_CAP_EXCEEDED","ORDER_WILL_TAKE_LIQUIDITY_DURING_MARKET_HALT","ORDER_NOT_FOUND","ORDER_NOT_FOUND_FOR_MODIFY","MODIFY_CHANGED_IMMUTABLE_FIELD","MODIFY_ZERO_SIZE","FILL_WILL_EXCEED_TRADING_BOUND","OPEN_INTEREST_CAP_EXCEEDED","POSITION_SIZE_CAP_EXCEEDED","MODIFY_TPSL_NOT_SUPPORTED","MODIFY_SUPERSEDED_BY_CANCEL","MODIFY_SIZE_ALREADY_FILLED"],"uniqueKey":"rejectionReason","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Invalid request body","code":"GEO_RESTRICTED","errorSource":"Order","errorType":"Tick","rejectionReason":"POST_ONLY_WOULD_CROSS"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"dd966c3c-1017-4868-9ca6-dc9c9a2f9014":{"apiKey":{"type":"apiKey","in":"header","name":"X-API-Key","description":"Hex-encoded Ed25519 public key (64 chars). The public key IS the API key — register it via `POST /createApiKey`. Required on every authenticated request, both read-only and signed.\n","scopes":[],"schemeName":"apiKey"},"timestamp":{"type":"apiKey","in":"header","name":"X-Timestamp","description":"Unix time in **nanoseconds** as a decimal string (e.g. `\"1713825891591000000\"`). Millisecond or second epochs are rejected with `401 Unauthorized`. Must be within ±30,000 ms of server wall-clock, or the request is rejected with `401 Unauthorized`. Required on all mutating / credential-creating endpoints. This same value must appear as the `ct` field in the ordersign typed canonical payload (single-order endpoints) or in each element's `ct` field (batch endpoints).\n","scopes":[],"schemeName":"timestamp"},"signature":{"type":"apiKey","in":"header","name":"X-Signature","description":"Lowercase hex-encoded Ed25519 signature (128 chars).\n\n**Single-order endpoints** (`placeOrder`, `cancelOrder`, `modifyOrder`, and other non-batch mutating routes) sign over the **ordersign typed canonical payload** — a compact, key-sorted JSON object built from parsed request fields using engine-native integer values:\n\n```\nplaceOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,\"m\":N,\"op\":1,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1}\ncancelOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,[,\"id\":\"…\"],\"m\":N,\"op\":2,\"v\":1}\nmodifyOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,[,\"id\":\"…\"],\"m\":N,\"op\":3,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1} (exactly one of id / c)\n```\n\n`ct` must equal the `X-Timestamp` header value. Keys in brackets are conditional (omitted when empty). `op` values: `1`=place, `2`=cancel, `3`=modify. See the `ordersign` package for field definitions and reference signing code.\n\nOther signed routes (e.g. `createApiKey`) still use the legacy scheme: `signing_message = X-Timestamp + ACTION + canonicalJSON(body)`, where `ACTION` is the camelCase final path segment.\n\n**Batch endpoints (`batchPlaceOrders`, `batchCancelOrders`, `batchModifyOrders`) do NOT use this header.** They authenticate with per-element typed ordersign signatures embedded in the request body (see the global auth description and the per-field `signature` descriptions on `OrderRequest` / `CancelOrderRequest` / `ModifyOrderRequest`).\n\nRead endpoints are authenticated by `?address=` (and optionally `X-API-Key`) only — no signature is required, except for the signed affiliate reads (see the Referral tag), which require the full header triple; with no body their signing message is `X-Timestamp + ACTION`. `canonicalJSON(body)` is the JSON body with object keys sorted lexicographically at every level and no whitespace; the server canonicalizes the received body before verifying, so only the bytes signed over must be canonical. Required on all mutating / credential-creating endpoints.\n","scopes":[],"schemeName":"signature"}},"163b2ad5-ba14-4fc5-a7cb-4a45849d64ad":{}},"servers":{"8bcbded4-ced7-41f7-9103-ef78afb86c4b":{"url":"https://api.arcus.xyz","description":"Mainnet"},"db341041-78f8-47d5-bb08-4c97d4cfedb3":{"url":"https://api.testnet.arcus.xyz","description":"Testnet"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"X-API-Key","description":"Hex-encoded Ed25519 public key (64 chars). The public key IS the API key — register it via `POST /createApiKey`. Required on every authenticated request, both read-only and signed.\n","scopes":[],"schemeName":"apiKey"},"schema":{"title":"X-API-Key","type":"string","description":"Hex-encoded Ed25519 public key (64 chars). The public key IS the API key — register it via `POST /createApiKey`. Required on every authenticated request, both read-only and signed.\n","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"apiKey","name":"X-API-Key"},{"scheme":{"type":"apiKey","in":"header","name":"X-Timestamp","description":"Unix time in **nanoseconds** as a decimal string (e.g. `\"1713825891591000000\"`). Millisecond or second epochs are rejected with `401 Unauthorized`. Must be within ±30,000 ms of server wall-clock, or the request is rejected with `401 Unauthorized`. Required on all mutating / credential-creating endpoints. This same value must appear as the `ct` field in the ordersign typed canonical payload (single-order endpoints) or in each element's `ct` field (batch endpoints).\n","scopes":[],"schemeName":"timestamp"},"schema":{"title":"X-Timestamp","type":"string","description":"Unix time in **nanoseconds** as a decimal string (e.g. `\"1713825891591000000\"`). Millisecond or second epochs are rejected with `401 Unauthorized`. Must be within ±30,000 ms of server wall-clock, or the request is rejected with `401 Unauthorized`. Required on all mutating / credential-creating endpoints. This same value must appear as the `ct` field in the ordersign typed canonical payload (single-order endpoints) or in each element's `ct` field (batch endpoints).\n","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"timestamp","name":"X-Timestamp"},{"scheme":{"type":"apiKey","in":"header","name":"X-Signature","description":"Lowercase hex-encoded Ed25519 signature (128 chars).\n\n**Single-order endpoints** (`placeOrder`, `cancelOrder`, `modifyOrder`, and other non-batch mutating routes) sign over the **ordersign typed canonical payload** — a compact, key-sorted JSON object built from parsed request fields using engine-native integer values:\n\n```\nplaceOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,\"m\":N,\"op\":1,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1}\ncancelOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,[,\"id\":\"…\"],\"m\":N,\"op\":2,\"v\":1}\nmodifyOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,[,\"id\":\"…\"],\"m\":N,\"op\":3,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1} (exactly one of id / c)\n```\n\n`ct` must equal the `X-Timestamp` header value. Keys in brackets are conditional (omitted when empty). `op` values: `1`=place, `2`=cancel, `3`=modify. See the `ordersign` package for field definitions and reference signing code.\n\nOther signed routes (e.g. `createApiKey`) still use the legacy scheme: `signing_message = X-Timestamp + ACTION + canonicalJSON(body)`, where `ACTION` is the camelCase final path segment.\n\n**Batch endpoints (`batchPlaceOrders`, `batchCancelOrders`, `batchModifyOrders`) do NOT use this header.** They authenticate with per-element typed ordersign signatures embedded in the request body (see the global auth description and the per-field `signature` descriptions on `OrderRequest` / `CancelOrderRequest` / `ModifyOrderRequest`).\n\nRead endpoints are authenticated by `?address=` (and optionally `X-API-Key`) only — no signature is required, except for the signed affiliate reads (see the Referral tag), which require the full header triple; with no body their signing message is `X-Timestamp + ACTION`. `canonicalJSON(body)` is the JSON body with object keys sorted lexicographically at every level and no whitespace; the server canonicalizes the received body before verifying, so only the bytes signed over must be canonical. Required on all mutating / credential-creating endpoints.\n","scopes":[],"schemeName":"signature"},"schema":{"title":"X-Signature","type":"string","description":"Lowercase hex-encoded Ed25519 signature (128 chars).\n\n**Single-order endpoints** (`placeOrder`, `cancelOrder`, `modifyOrder`, and other non-batch mutating routes) sign over the **ordersign typed canonical payload** — a compact, key-sorted JSON object built from parsed request fields using engine-native integer values:\n\n```\nplaceOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,\"m\":N,\"op\":1,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1}\ncancelOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,[,\"id\":\"…\"],\"m\":N,\"op\":2,\"v\":1}\nmodifyOrder: {\"ad\":\"0x…\",\"ai\":N,[,\"c\":\"…\"],\"ct\":N,\"g\":N,[,\"id\":\"…\"],\"m\":N,\"op\":3,\"p\":N,\"q\":N,\"r\":0|1,\"s\":N,\"t\":N,\"v\":1} (exactly one of id / c)\n```\n\n`ct` must equal the `X-Timestamp` header value. Keys in brackets are conditional (omitted when empty). `op` values: `1`=place, `2`=cancel, `3`=modify. See the `ordersign` package for field definitions and reference signing code.\n\nOther signed routes (e.g. `createApiKey`) still use the legacy scheme: `signing_message = X-Timestamp + ACTION + canonicalJSON(body)`, where `ACTION` is the camelCase final path segment.\n\n**Batch endpoints (`batchPlaceOrders`, `batchCancelOrders`, `batchModifyOrders`) do NOT use this header.** They authenticate with per-element typed ordersign signatures embedded in the request body (see the global auth description and the per-field `signature` descriptions on `OrderRequest` / `CancelOrderRequest` / `ModifyOrderRequest`).\n\nRead endpoints are authenticated by `?address=` (and optionally `X-API-Key`) only — no signature is required, except for the signed affiliate reads (see the Referral tag), which require the full header triple; with no body their signing message is `X-Timestamp + ACTION`. `canonicalJSON(body)` is the JSON body with object keys sorted lexicographically at every level and no whitespace; the server canonicalizes the received body before verifying, so only the bytes signed over must be canonical. Required on all mutating / credential-creating endpoints.\n","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"signature","name":"X-Signature"}],"title":"apiKey \u0026 timestamp \u0026 signature"}]},"originalFileLocation":"api-reference/openapi.yml"},"subdomain":"arcus-11aecf6e","siteName":"Arcus Docs","title":"Submit withdrawal - Arcus Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-12T03:48:06.552Z","originalFileLocation":"api-reference/exchange/submit-withdrawal.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Submit a withdrawal of collateral to the chain.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Arcus Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Submit withdrawal - Arcus Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Submit a withdrawal of collateral to the chain.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Arcus Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://arcus-11aecf6e.mintlify.site/_mintlify/api/og/v2?division=Exchange\u0026amp;title=Submit+withdrawal\u0026amp;description=Submit+a+withdrawal+of+collateral+to+the+chain.\u0026amp;theme=8f431044d56cd21a41b03f79\u0026amp;signature=2ee72199dc562df1b7595b28682c0316248cd0b3de4e805b28e8b0b47553ee64\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Submit withdrawal - Arcus Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Submit a withdrawal of collateral to the chain.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://arcus-11aecf6e.mintlify.site/_mintlify/api/og/v2?division=Exchange\u0026amp;title=Submit+withdrawal\u0026amp;description=Submit+a+withdrawal+of+collateral+to+the+chain.\u0026amp;theme=8f431044d56cd21a41b03f79\u0026amp;signature=2ee72199dc562df1b7595b28682c0316248cd0b3de4e805b28e8b0b47553ee64\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/arcus-11aecf6e/zluNDxrkwkprdXlm/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Arcus Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#16A34A\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/exchange/submit-withdrawal.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.arcus.xyz/#organization\",\"name\":\"Arcus Docs\",\"url\":\"https://docs.arcus.xyz\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/arcus-11aecf6e/Pw2ZUiZemhLSrOMO/logo/light.svg?fit=max\u0026auto=format\u0026n=Pw2ZUiZemhLSrOMO\u0026q=85\u0026s=9bbd1de2de2a31d08c50e0d58bdac466\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.arcus.xyz#website\",\"name\":\"Arcus Docs\",\"url\":\"https://docs.arcus.xyz\",\"publisher\":{\"@id\":\"https://docs.arcus.xyz/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal#webpage\",\"url\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal\",\"name\":\"Submit withdrawal\",\"description\":\"Submit a withdrawal of collateral to the chain.\",\"dateModified\":\"2026-11-12T03:48:06.552Z\",\"isPartOf\":{\"@id\":\"https://docs.arcus.xyz#website\"},\"breadcrumb\":{\"@id\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Endpoints\",\"item\":\"https://docs.arcus.xyz/api-reference/public/service-info\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Exchange\",\"item\":\"https://docs.arcus.xyz/api-reference/exchange/place-order\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Submit withdrawal\",\"item\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal#apireference\",\"headline\":\"Submit withdrawal\",\"name\":\"Submit withdrawal\",\"description\":\"Submit a withdrawal of collateral to the chain.\",\"url\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal\",\"mainEntityOfPage\":{\"@id\":\"https://docs.arcus.xyz/api-reference/exchange/submit-withdrawal#webpage\"},\"dateModified\":\"2026-11-12T03:48:06.552Z\",\"publisher\":{\"@id\":\"https://docs.arcus.xyz/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.arcus.xyz#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Arcus Docs\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Arcus Docs\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/exchange/submit-withdrawal.md","siteName":"Arcus Docs","nav":{"global":null,"tabs":[{"tab":"Guides","pages":[{"title":"Guides","href":"/guides/fund-testnet-account"}]},{"tab":"Concepts","pages":[{"title":"Concepts","href":"/concepts/onboarding"}]},{"tab":"API reference","groups":[{"group":"API documentation","pages":[{"title":"Introduction","href":"/api-reference/introduction"},{"title":"Authentication","href":"/api-reference/authentication"},{"title":"WebSocket","href":"/api-reference/websocket"},{"title":"Rate limits","href":"/api-reference/rate-limits"}]},{"group":"Endpoints","pages":[{"group":"Public","pages":[{"title":"Service info","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /","href":"/api-reference/public/service-info"},{"title":"Health check","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /health","href":"/api-reference/public/health-check"},{"title":"Get L2 orderbook snapshot","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/l2OrderBook/{market}","href":"/api-reference/public/get-l2-orderbook-snapshot"},{"title":"Get Best Bid Offer (BBO)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/bbo/{market}","href":"/api-reference/public/get-best-bid-offer-bbo"},{"title":"Get current server time","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/time","href":"/api-reference/public/get-current-server-time"},{"title":"Get all mid prices","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/mids","href":"/api-reference/public/get-all-mid-prices"},{"title":"Get live prices for all markets","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/prices","href":"/api-reference/public/get-live-prices-for-all-markets"},{"title":"Get fee tier table","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/feetiers","href":"/api-reference/public/get-fee-tier-table"},{"title":"Get referral commission rate schedule","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/commissionrates","href":"/api-reference/public/get-referral-commission-rate-schedule"},{"title":"Get markets","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/markets","href":"/api-reference/public/get-markets"},{"title":"Get market fee schedules","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/markets/feeSchedules","href":"/api-reference/public/get-market-fee-schedules"},{"title":"Get corporate actions","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/corporateActions","href":"/api-reference/public/get-corporate-actions"},{"title":"Get corporate actions for a market","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/corporateActions/{market_id}","href":"/api-reference/public/get-corporate-actions-for-a-market"},{"title":"Get spot collateral assets","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/spotAssets","href":"/api-reference/public/get-spot-collateral-assets"},{"title":"Get global lending attributes","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/lendingAttributes","href":"/api-reference/public/get-global-lending-attributes"},{"title":"Get recent public trades","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/trades","href":"/api-reference/public/get-recent-public-trades"},{"title":"Get a single trade by ID","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/trade/{tradeId}","href":"/api-reference/public/get-a-single-trade-by-id"},{"title":"Get OHLCV candles","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/candles","href":"/api-reference/public/get-ohlcv-candles"},{"title":"Get open orders","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/openOrders","href":"/api-reference/public/get-open-orders"},{"title":"Get order history","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/orders","href":"/api-reference/public/get-order-history"},{"title":"Get fills","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/fills","href":"/api-reference/public/get-fills"},{"title":"Get spot fills","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/spotFills","href":"/api-reference/public/get-spot-fills"},{"title":"Get fill by ID","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/fill/{tradeId}","href":"/api-reference/public/get-fill-by-id"},{"title":"Get account transfer updates","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/accountTransferUpdates","href":"/api-reference/public/get-account-transfer-updates"},{"title":"Get funding payments","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/funding","href":"/api-reference/public/get-funding-payments"},{"title":"Get interest payments","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/interest","href":"/api-reference/public/get-interest-payments"},{"title":"Get market funding rates","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/fundingRates","href":"/api-reference/public/get-market-funding-rates"},{"title":"Get portfolio history","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/portfolio","href":"/api-reference/public/get-portfolio-history"},{"title":"Get current rate-limit usage","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/rateLimit","href":"/api-reference/public/get-current-rate-limit-usage"},{"title":"Get positions","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/positions","href":"/api-reference/public/get-positions"},{"title":"Get spot positions","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/spotPositions","href":"/api-reference/public/get-spot-positions"},{"title":"Get account","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/account","href":"/api-reference/public/get-account"},{"title":"Get account stats","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/account/stats","href":"/api-reference/public/get-account-stats"},{"title":"Get order status","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/order/{orderId}","href":"/api-reference/public/get-order-status"},{"title":"Get leverage and margin mode for an account across all markets","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/leverages","href":"/api-reference/public/get-leverage-and-margin-mode-for-an-account-across-all-markets"},{"title":"Get the all-traders leaderboard","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/leaderboard","href":"/api-reference/public/get-the-all-traders-leaderboard"}]},{"group":"Exchange","pages":[{"title":"Place order","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/placeOrder","href":"/api-reference/exchange/place-order"},{"title":"Place batch orders","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/batchPlaceOrders","href":"/api-reference/exchange/place-batch-orders"},{"title":"Cancel order","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/cancelOrder","href":"/api-reference/exchange/cancel-order"},{"title":"Batch cancel orders","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/batchCancelOrders","href":"/api-reference/exchange/batch-cancel-orders"},{"title":"Schedule cancel-all (dead man's switch)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/scheduleCancel","href":"/api-reference/exchange/schedule-cancel-all-dead-mans-switch"},{"title":"Cancel all open orders","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/cancelAllOrders","href":"/api-reference/exchange/cancel-all-open-orders"},{"title":"Modify order","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/modifyOrder","href":"/api-reference/exchange/modify-order"},{"title":"Batch modify orders","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/batchModifyOrders","href":"/api-reference/exchange/batch-modify-orders"},{"title":"Set leverage for a market","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/setLeverage","href":"/api-reference/exchange/set-leverage-for-a-market"},{"title":"Add or remove margin on an isolated-mode position","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/adjustIsolatedMargin","href":"/api-reference/exchange/add-or-remove-margin-on-an-isolated-mode-position"},{"title":"Sell spot collateral to settle the account's loan","description":"Voluntarily settle an outstanding loan balance by selling spot collateral to the exchange's liquidity provider at the mark price minus a configured spread (25 bps by default).","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/settleLoan","href":"/api-reference/exchange/sell-spot-collateral-to-settle-the-accounts-loan"},{"title":"Submit withdrawal","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/withdraw","href":"/api-reference/exchange/submit-withdrawal"},{"title":"Submit internal transfer","description":"Move collateral between two account indexes of the **same wallet**.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/transfer","href":"/api-reference/exchange/submit-internal-transfer"}]},{"group":"Onboarding","pages":[{"title":"Get API keys","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/apiKeys","href":"/api-reference/onboarding/get-api-keys"},{"title":"Create API key","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/createApiKey","href":"/api-reference/onboarding/create-api-key"},{"title":"Revoke API key","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/revokeApiKey","href":"/api-reference/onboarding/revoke-api-key"}]},{"group":"Referral","pages":[{"title":"Create referral code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/createCode","href":"/api-reference/referral/create-referral-code"},{"title":"Register as referee","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/registerAffiliate","href":"/api-reference/referral/register-as-referee"},{"title":"Update kickback rate","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/kickback","href":"/api-reference/referral/update-kickback-rate"},{"title":"Revoke referral code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/revokeCode","href":"/api-reference/referral/revoke-referral-code"},{"title":"Rename referral code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/modifyCode","href":"/api-reference/referral/rename-referral-code"},{"title":"Claim accrued commission","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/claim","href":"/api-reference/referral/claim-accrued-commission"},{"title":"Get affiliate info","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/info","href":"/api-reference/referral/get-affiliate-info"},{"title":"Get the caller's referral code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/code","href":"/api-reference/referral/get-the-callers-referral-code"},{"title":"Get referees","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/referees","href":"/api-reference/referral/get-referees"},{"title":"Get my referrer","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/myReferrer","href":"/api-reference/referral/get-my-referrer"},{"title":"Get affiliate leaderboard","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/leaderboard","href":"/api-reference/referral/get-affiliate-leaderboard"},{"title":"Get affiliate commission history","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/commissions","href":"/api-reference/referral/get-affiliate-commission-history"},{"title":"Get affiliate claim history","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/claims","href":"/api-reference/referral/get-affiliate-claim-history"},{"title":"Look up a single claim","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/claimStatus","href":"/api-reference/referral/look-up-a-single-claim"},{"title":"Check whether a referral code is available","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/codeAvailable","href":"/api-reference/referral/check-whether-a-referral-code-is-available"},{"title":"List the caller's invite codes","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml get /v1/affiliate/inviteCodes","href":"/api-reference/referral/list-the-callers-invite-codes"},{"title":"Redeem an invite code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.yml post /v1/affiliate/redeemInvite","href":"/api-reference/referral/redeem-an-invite-code"}]}]},{"group":"WebSocket","pages":[{"group":"Market data","pages":[{"asyncapi":"api-reference/asyncapi.yaml l2Orderbook","href":"/api-reference/market-data/l2orderbook","title":"L2 orderbook","version":null},{"asyncapi":"api-reference/asyncapi.yaml l2OrderbookUpdates","href":"/api-reference/market-data/l2orderbookupdates","title":"L2 orderbook updates","version":null},{"asyncapi":"api-reference/asyncapi.yaml trades","href":"/api-reference/market-data/trades","title":"Trades","version":null},{"asyncapi":"api-reference/asyncapi.yaml markets","href":"/api-reference/market-data/markets","title":"Markets","version":null},{"asyncapi":"api-reference/asyncapi.yaml oraclePrices","href":"/api-reference/market-data/oracleprices","title":"Oracle prices","version":null},{"asyncapi":"api-reference/asyncapi.yaml bbo","href":"/api-reference/market-data/bbo","title":"Bbo","version":null},{"asyncapi":"api-reference/asyncapi.yaml lendingRates","href":"/api-reference/market-data/lendingrates","title":"Lending rates","version":null},{"asyncapi":"api-reference/asyncapi.yaml predictedFunding","href":"/api-reference/market-data/predictedfunding","title":"Predicted funding","version":null},{"asyncapi":"api-reference/asyncapi.yaml exchangeAttributeUpdates","href":"/api-reference/market-data/exchangeattributeupdates","title":"Exchange attribute updates","version":null},{"asyncapi":"api-reference/asyncapi.yaml marketAttributes","href":"/api-reference/market-data/marketattributes","title":"Market attributes","version":null},{"asyncapi":"api-reference/asyncapi.yaml candles","href":"/api-reference/market-data/candles","title":"Candles","version":null}]},{"group":"Account","pages":[{"asyncapi":"api-reference/asyncapi.yaml account","href":"/api-reference/account/account","title":"Account","version":null},{"asyncapi":"api-reference/asyncapi.yaml positions","href":"/api-reference/account/positions","title":"Positions","version":null},{"asyncapi":"api-reference/asyncapi.yaml spotPositions","href":"/api-reference/account/spotpositions","title":"Spot positions","version":null},{"asyncapi":"api-reference/asyncapi.yaml userFills","href":"/api-reference/account/userfills","title":"User fills","version":null},{"asyncapi":"api-reference/asyncapi.yaml spotFills","href":"/api-reference/account/spotfills","title":"Spot fills","version":null},{"asyncapi":"api-reference/asyncapi.yaml settleLoanResults","href":"/api-reference/account/settleloanresults","title":"Settle loan results","version":null},{"asyncapi":"api-reference/asyncapi.yaml orders","href":"/api-reference/account/orders","title":"Orders","version":null},{"asyncapi":"api-reference/asyncapi.yaml funding","href":"/api-reference/account/funding","title":"Funding","version":null},{"asyncapi":"api-reference/asyncapi.yaml accountTransferUpdates","href":"/api-reference/account/accounttransferupdates","title":"Account transfer updates","version":null},{"asyncapi":"api-reference/asyncapi.yaml accountAttributeUpdates","href":"/api-reference/account/accountattributeupdates","title":"Account attribute updates","version":null}]},{"group":"Trading","pages":[{"asyncapi":"api-reference/asyncapi.yaml orderOperations","href":"/api-reference/trading/orderoperations","title":"Order operations","version":null}]}]},{"group":"Changelog","pages":[{"title":"Changelog API (Mainnet)","href":"/changelog"},{"title":"Upcoming mainnet release","href":"/changelog/upcoming"},{"title":"Changelog API (Testnet)","href":"/changelog/testnet"},{"title":"Arcus Changelog","href":"/changelog/frontend"}]}]}]},"basePath":"","title":"Submit withdrawal - Arcus Docs","buildId":"dpl_Fyv1NbzwP68g2bEH2Roy98uY1zmE","deploymentId":"dpl_Fyv1NbzwP68g2bEH2Roy98uY1zmE","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-DdEMm2kG.js","utils-BMo572L7.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-C-4m9KAx.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-DPLK2Oq9.js","snippetPresets-BKjfJMC9.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-DTsgtCEj.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-C8vmhyQM.js","shallow-r9w8LQGS.js","getApiPlaygroundDisplay-DjPI64HQ.js","CodeSnippet-C8Bvhl16.js","CodeSnippets-BtWUwcMy.js","Page-BIYvYBgk.js","getPastedJson-Dcm_3Pgl.js","icon-BXwrTpjc.js","MethodPill-CcjfVmmy.js","DuplicateIcon-BuKIbXAQ.js","createIcon-DaL9yXsO.js","DynamicMarkdown-Co5nikxh.js","SectionHeading-P4UNTsMZ.js","axios-vUo_bRtp.js","Markdown-CEfymfIH.js","clsx-Dq9TQuNi.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-D2J8knkn.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-BgZ2ThuU.js"]}