# Register a cross-chain order

`POST https://api.getchord.xyz/v1/xswap/order`

Source: https://getchord.xyz/docs/api-reference/operations/xswaporder/

Quotes and records the order the wallet is about to sign so it can be resumed after a refresh: the server tracks the bridge (Relay status or Circle attestation), mints CCTP transfers on Arc, and re-quotes the final leg at the amount that actually arrived. Poll `GET /xswap/order?id=`. `path: "direct"` registers the Relay end-to-end candidate instead.

## Request body (JSON)

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| `user` | yes | string | EVM address, hex, case-insensitive. |
| `chainIn` | yes | `143` · `4663` · `5042` |  |
| `chainOut` | yes | `143` · `4663` · `5042` |  |
| `tokenIn` | yes | string | EVM address, hex, case-insensitive. |
| `tokenOut` | yes | string | EVM address, hex, case-insensitive. |
| `amount` | yes | string | Amount in the token's smallest unit, as a decimal string. Never a float. |
| `slippageBps` | no | integer |  |
| `recipient` | no | string | EVM address, hex, case-insensitive. |
| `rail` | no | `auto` · `relay` · `cctp` | Force a rail; `auto` applies the corridor rules (Robinhood → Relay; Monad ↔ Arc → CCTP when the mint relayer is funded; else Relay). |
| `path` | no | `composed` · `direct` |  |

```json
{
  "user": "0xb145400da27a2497d9fc2cd5621f2bfd37617af4",
  "chainIn": 5042,
  "chainOut": 143,
  "tokenIn": "0x3600000000000000000000000000000000000000",
  "tokenOut": "0x350035555e10d9afaf1566aaebfced5ba6c27777",
  "amount": "1000000000",
  "slippageBps": 100
}
```

## Response 200

- **400**: Invalid parameters — `error` names the check that failed (`INVALID_PARAMS`, `BAD_ADDRESS`, `BAD_LIMIT`, `BAD_HOURS`, …).
- **404**: Nothing at this identity (`NOT_FOUND`, `UNKNOWN_TOKEN`, `NO_ROUTE`).
- **429**: Over the per-minute limit (`RATE_LIMIT_EXCEEDED`). Read `X-RateLimit-Reset` and back off.
- **502**: The routing engine or an upstream did not answer (`ENGINE_ERROR`, `ROUTE_ERROR`).
- **503**: The lane behind this endpoint is not ready or not enabled here (`NOT_READY`, `CHAIN_NOT_ENABLED`, `NOT_ENABLED`, `*_UNAVAILABLE`). Retry later; do not treat it as an empty answer.
