---
title: "Execute FX with permit"
method: POST
path: "/api/v1/fx-exchange-with-permit"
tags: ["External Wallet Access Mode"]
---

# Execute FX with permit

`POST /api/v1/fx-exchange-with-permit`

Executes an on-chain FX exchange using an EIP-2612 permit signature. Derive amountOutMinimum from the FX quote; permitValue must be at least inputAmount. Final status is trackable via txHash.

## Headers

- `tokenId` string, required
- `network` string, required
- `sign` string, required
- `hash` string, required
- `deadline` string, required

## Request body

- object
  - `userAddress` string, required — User's wallet address.
  - `inputToken` string, required — Input fiat token contract address.
  - `outputToken` string, required — Output fiat token contract address.
  - `inputAmount` string, required — Exact-in amount in smallest units.
  - `amountOutMinimum` string, required — Minimum acceptable output in smallest units, from the quote.
  - `permitValue` string, required — Permit value; must be greater than or equal to inputAmount.
  - `permitDeadline` integer, required — Unix seconds until which the permit is valid.
  - `permitV` integer, required — EIP-2612 signature component v.
  - `permitR` string, required — EIP-2612 signature component r (32-byte hex).
  - `permitS` string, required — EIP-2612 signature component s (32-byte hex).

## Response `200`

Response envelope. For the user API, retCode 0 means success; for the partner API, code 0 means success. Business rejections return HTTP 200 with a non-zero code.

- EwaEnvelope — Standard response envelope for the user API (api.ur.app).
  - `retCode` integer, required — 0 on success; non-zero indicates failure.
  - `retMsg` string, required — Human-readable message; error details when retCode is non-zero.
  - `result` unknown
  - `timeNow` integer — Server timestamp in milliseconds.

---

[API](https://skmtc.net/ur/apis/ur-api.md) · [All operations](https://skmtc.net/ur/apis/ur-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ur/ur-api/revisions/087dcf516ce2/schema)
