Skip to content

API Reference

Complete reference for the Ezys REST API. All endpoints communicate over HTTP using JSON.

Conventions

  • Amounts — integer values in the currency's smallest (minor) unit, encoded as JSON strings (amountMinor + currency + exponent), with floor rounding. See Money & Amounts for the full contract.
  • Currencies — ISO 4217 codes for fiat (KRW, USD); registered tickers for stablecoins (USDC).

Base URL

All endpoints are served under the /v1 prefix:

Production:  https://api.ezys.io/v1
Sandbox:     https://api.ezys.sh/v1

Authentication

All requests require an API key, passed via the X-API-Key header — see Authentication.

Endpoints

Paths are relative to the /v1 base above. Availability refers to the sandbox environment (api.ezys.sh); coming soon surfaces are published here as the contract of record ahead of rollout.

Quote (RFQ)

MethodEndpointAvailabilityDescription
POST/quotesAvailableRequest indicative quotes — returns a synchronous list of scored candidates
POST/quotes/firmAvailableRequest a firm, lockable quote — returns quoteId, locked all-in rate, itemized fees, and validUntil

See the Quote API for request/response fields and lifecycle.

Intent

MethodEndpointAvailabilityDescription
POST/intentsAvailableSubmit an Intent — returns accepted or rejected

Single-step submit — there is no separate confirm step. See the Intent API.

Execution status & receipts

MethodEndpointAvailabilityDescription
GET/executions/{reference}Coming soonAggregate status of one execution — phase, events[] history, failure block
GET/intents/{intentId}/statusComing soonLightweight intent-only status (planned public exposure)
GET/executions/{reference}/receiptComing soonNormalized machine-readable receipt (offramp + payout + fees)
GET/reconciliationComing soonAggregate reconciliation view over a date range

See the Status API and Receipts & Reconciliation.

Request Format

Headers

HeaderRequiredDescription
Content-TypeYesMust be application/json
X-API-KeyYesYour API key — see Authentication
X-Idempotency-KeyYes (POST)Canonical RFC 9562 UUID. Required on partner-facing POST for safe retries — see Idempotency

Body

All request bodies must be valid JSON. The shape is per-endpoint — see the Quote API and Intent API for the exact request bodies the current endpoints accept (the illustrative pair/strategy shape below is not the literal request body of any single current endpoint).

json
{
  "pair": {
    "source": "USDC",
    "target": "KRW"
  },
  "side": "sell",
  "amount": "1000",
  "strategy": "instant",
  "constraints": {
    "maxSlippageBps": 50,
    "maxFeeBps": 30
  }
}

Response Format

The envelope wraps all responses consistently.

Success

json
{
  "success": true,
  "data": { ... }
}

Error

json
{
  "success": false,
  "error": {
    "code": "ERROR_CODE",
    "message": "A human-readable description of the error."
  }
}

HTTP Status Codes

CodeMeaning
200Request succeeded
201Resource created
202Accepted for asynchronous processing
400Invalid request — check parameters
401Authentication failed — missing or invalid API key
403Insufficient permissions
404Resource not found
409Idempotency-Key conflict, or a matching request is still in progress — see Idempotency
429Rate limit exceeded
500Internal server error
503Service temporarily unavailable — transient; retry with backoff

Error Codes

For which of these errors are safe to retry and the recommended action for each, see Error Handling & Retries.

CodeDescription
INVALID_API_KEYThe provided API key is invalid or revoked
INVALID_PAIRThe requested currency pair is not supported
INVALID_PARAMETEROne or more request parameters are malformed
INVALID_STRATEGYThe specified execution strategy is not recognized
AMOUNT_OUT_OF_RANGEThe amount exceeds the allowed min/max bounds
CONSTRAINTS_NOT_MET422 — the requested constraints cannot be satisfied (status: "rejected")
POLICY_DENIED422 — blocked by policy (limits or compliance); carries a closed subCode enum, one value conditionally retryable — see Policy subCodes
INSUFFICIENT_LIQUIDITY422 — not enough liquidity to fulfill the request (status: "rejected"; a business outcome, never 200)
INTENT_NOT_FOUNDNo Intent exists with the given ID
INTENT_EXPIREDThe Intent has expired and can no longer be acted upon
INTENT_ALREADY_EXECUTINGThe Intent is already in execution and cannot be cancelled
SETTLEMENT_FAILEDThe settlement (off-ramp) leg failed terminally — handle by compensation
PROVIDER_UNAVAILABLE5xx — a downstream provider (e.g. oracle) is temporarily unavailable; retry with backoff
PAYOUT_UNAVAILABLE5xx — the payout rail is temporarily unavailable; retry with backoff
PAYOUT_REJECTED400 — the payout was rejected (configuration or request); fix and resubmit
RATE_LIMIT_EXCEEDEDToo many requests — back off and retry
IDEMPOTENCY_KEY_REQUIRED400 — the X-Idempotency-Key header is missing on a partner-facing POST. See Idempotency
IDEMPOTENCY_KEY_INVALID400 — the key is not a canonical RFC 9562 UUID, or the request could not be fingerprinted
IDEMPOTENCY_KEY_CONFLICT409 — the same key was reused with a different request body
IDEMPOTENCY_KEY_PROCESSING409 — the original request for this key is still being processed
SERVICE_UNAVAILABLE5xx — a dependency or the service is temporarily unavailable; retry with backoff
INTERNAL_ERROR5xx — an unexpected server error; retry with backoff

Rate Limits

TierLimit
Standard100 requests / minute
EnterpriseCustom — contact sales

Detailed Guides