> For a complete index of Agora Finance documentation, fetch https://docs.agora.finance/llms.txt

# Create a Route

POST https://api.sandbox.agora.finance/v0/routes
Content-Type: application/json

Create a persistent source → destination route. The response includes reusable settlement instructions — a wire memo for fiat sources, or one mint or redeem address per supported chain for blockchain sources — that the caller uses to initiate transfers. A single set of instructions is valid indefinitely; every inbound transfer matching them triggers a separate settlement to the route's destination.

The route topology is determined by `from.currency`, `to.currency`, and the destination `to.chain`. `to.accountId` references a registered account from `GET /v0/accounts`.

**No US dollars move in the sandbox.** Fiat routes return fake wire instructions so you can build fiat flows. **Never send a real wire to them.** To test a mint, simulate the wire with `POST /v0/sandbox/wires`.

### Supported topologies

| `from.currency` | `to.currency` (+ `to.chain`) | Behavior                                                                                |
| --------------- | ---------------------------- | --------------------------------------------------------------------------------------- |
| `usd`           | `ausd` on a chain            | Mint from simulated USD. Never send a real wire.                                        |
| `ausd`          | `usd` (bank account)         | Redeem to simulated USD. No payout is sent.                                             |
| `ctk`           | `ausd` on a chain            | Mint with stablecoins: send `ctk` to the mint address, receive AUSD at the destination. |
| `ausd`          | `ctk` on a chain             | Redeem to tokens: send AUSD to the redeem address, receive `ctk`.                       |

Reference: https://docs.agora.finance/api/endpoints/routes/create

## Authentication

- `Authorization` header (bearer token, required) — Session JWT from `POST /v0/auth/token`, sent as `Authorization: Bearer <sessionJwt>`. See [Authentication](/api/authentication) for more details.

## Request

### Body (application/json)

This endpoint expects an object.

- `from` (V0RoutesPostRequestBodyContentApplicationJsonSchemaFrom, required)
- `to` (V0RoutesPostRequestBodyContentApplicationJsonSchemaTo, required)
- `name` (string, optional)

## Response

### 200

The route already existed, so nothing was created and the stored route is returned.

- `id` (string, required) — Deterministic route UUID; same canonical inputs always derive the same id.
- `createdAt` (datetime, required)
- `direction` (enum, required) — Which of the four flows this route is.
  - Allowed values: `mint-fiat`, `mint-stablecoin`, `redeem-fiat`, `redeem-stablecoin`
- `to` (V0RoutesPostResponsesContentApplicationJsonSchemaTo, required)
- `instructions` (list of V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems, required) — Next-step instructions. Mint-fiat: one wire instruction with memo + beneficiary. On-chain directions: one deposit address per supported chain, alphabetical by chain.
- `name` (string, optional, nullable) — User-set label, or null when unset.

### 201

Route created.

- `id` (string, required) — Deterministic route UUID; same canonical inputs always derive the same id.
- `createdAt` (datetime, required)
- `direction` (enum, required) — Which of the four flows this route is.
  - Allowed values: `mint-fiat`, `mint-stablecoin`, `redeem-fiat`, `redeem-stablecoin`
- `to` (V0RoutesPostResponsesContentApplicationJsonSchemaTo, required)
- `instructions` (list of V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems, required) — Next-step instructions. Mint-fiat: one wire instruction with memo + beneficiary. On-chain directions: one deposit address per supported chain, alphabetical by chain.
- `name` (string, optional, nullable) — User-set label, or null when unset.

## Errors

### 400 Bad Request Error

- `chain_unsupported`: The requested chain is not supported. - `currency_unsupported`: The requested currency is not supported. - `direction_unsupported`: The requested route direction is not supported. - `parameter_invalid`: One or more request parameters are invalid.

- `code` (enum, required)
  - Allowed values: `chain_unsupported`, `currency_unsupported`, `direction_unsupported`, `parameter_invalid`
- `docs_url` (string, required)
- `message` (string, required)
- `context` (ErrorResponse400ChainUnsupportedCurrencyUnsupportedDirectionUnsupportedParameterInvalidContext, optional)

### 401 Unauthorized Error

Authentication is required.

- `code` (enum, required)
  - Allowed values: `unauthorized`
- `docs_url` (string, required)
- `message` (string, required)
- `context` (ErrorResponse401UnauthorizedContext, optional)

### 403 Forbidden Error

- `account_not_eligible`: The account is not eligible for this request. - `account_not_provisioned`: The account is not provisioned for this product. - `account_verification_pending`: Account verification for this product is pending. - `forbidden`: Access to this resource is forbidden.

- `code` (enum, required)
  - Allowed values: `account_not_eligible`, `account_not_provisioned`, `account_verification_pending`, `forbidden`
- `docs_url` (string, required)
- `message` (string, required)

### 404 Not Found Error

- `account_not_found`: Account not found. - `not_found`: Resource not found.

- `code` (enum, required)
  - Allowed values: `account_not_found`, `not_found`
- `docs_url` (string, required)
- `message` (string, required)

### 409 Conflict Error

A route with these parameters exists but cannot be served. Contact support.

- `code` (enum, required)
  - Allowed values: `route_already_exists`
- `docs_url` (string, required)
- `message` (string, required)
- `context` (ErrorResponse409RouteAlreadyExistsContext, optional)

### 429 Too Many Requests Error

Too many requests.

- `code` (enum, required)
  - Allowed values: `rate_limit_exceeded`
- `docs_url` (string, required)
- `message` (string, required)

### 500 Internal Server Error

An unexpected error occurred.

- `code` (enum, required)
  - Allowed values: `internal_error`
- `docs_url` (string, required)
- `message` (string, required)

### 503 Service Unavailable Error

Route creation temporarily unavailable. Please retry shortly.

- `code` (enum, required)
  - Allowed values: `route_creation_unavailable`
- `docs_url` (string, required)
- `message` (string, required)

## Types

### V0RoutesPostRequestBodyContentApplicationJsonSchemaFrom

- `currency` (enum, required) — Source currency. `usd` (wire), or any accepted token.
  - Allowed values: `ausd`, `usd`, `ctk`

### V0RoutesPostRequestBodyContentApplicationJsonSchemaTo

- `currency` (enum, required) — Destination currency. `usd` (wire), or any accepted token.
  - Allowed values: `ausd`, `usd`, `ctk`
- `accountId` (string, required)
- `chain` (enum, optional) — Destination chain (kebab-case). Restricted to chains Agora supports for routes (EVM + Solana).
  - Allowed values: `avalanche-fuji`, `ethereum-sepolia`

### V0RoutesPostResponsesContentApplicationJsonSchemaTo

- `currency` (enum, required) — Currency identifier.
  - Allowed values: `ausd`, `usd`, `ctk`
- `accountId` (string, required)
- `chain` (enum, optional) — Route chain (kebab-case). Restricted to chains Agora supports for routes (EVM + Solana).
  - Allowed values: `avalanche-fuji`, `ethereum-sepolia`

### V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems

- V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems0
- V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems1

### ErrorResponse400ChainUnsupportedCurrencyUnsupportedDirectionUnsupportedParameterInvalidContext

- `issues` (list of ErrorResponse400ChainUnsupportedCurrencyUnsupportedDirectionUnsupportedParameterInvalidContextIssuesItems, required)

### ErrorResponse401UnauthorizedContext

- `reason` (enum, required)
  - Allowed values: `invalid_token`, `key_not_provisioned`, `missing_claim`, `missing_header`, `token_expired`, `token_paused`, `token_revoked`, `unknown_tenant`

### ErrorResponse409RouteAlreadyExistsContext

- `routeId` (string, required)

### V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems0

- `memo` (string, required) — Memo / reference field that uniquely identifies the route on the inbound wire.
- `beneficiaryName` (string, required)
- `beneficiaryAddress` (string, required)
- `accountNumber` (string, required)
- `bankName` (string, required)
- `bankAddress` (string, required)
- `routingNumber` (string, required)
- `supportedCurrencies` (list of enum, required) — Currencies this wire instruction accepts
  - Allowed values: `ausd`, `usd`, `ctk`
- `swiftCode` (string, optional)

### V0RoutesPostResponsesContentApplicationJsonSchemaInstructionsItems1

- `chain` (enum, required) — Route chain (kebab-case). Restricted to chains Agora supports for routes (EVM + Solana).
  - Allowed values: `avalanche-fuji`, `ethereum-sepolia`
- `depositAddress` (string, required)
- `supportedCurrencies` (list of enum, required) — Currencies the deposit address accepts
  - Allowed values: `ausd`, `usd`, `ctk`

### ErrorResponse400ChainUnsupportedCurrencyUnsupportedDirectionUnsupportedParameterInvalidContextIssuesItems

- `field` (string, required)
- `message` (string, required)

## Examples

### Mint from fiat

**Request**

```json
{
  "from": {
    "currency": "usd"
  },
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "name": "Operating wire → ETH treasury"
}
```

**Response**

```json
{
  "id": "5a8e9f12-1b2c-4d3e-9f0a-1b2c3d4e5f6a",
  "createdAt": "2026-05-13T18:00:00Z",
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "instructions": [
    {
      "accountNumber": "00000000",
      "bankAddress": "0 Nowhere Street, Example City, XX 00000, SANDBOX",
      "bankName": "SANDBOX TEST BANK, NOT A REAL BANK",
      "beneficiaryAddress": "0 Nowhere Street, Example City, XX 00000, SANDBOX",
      "beneficiaryName": "SANDBOX TEST ACCOUNT, NOT A REAL BENEFICIARY",
      "memo": "eth93e6c8",
      "routingNumber": "000000000",
      "supportedCurrencies": [
        "usd"
      ],
      "swiftCode": "SANDBOX0"
    }
  ],
  "name": "Operating wire → ETH treasury",
  "from": {
    "currency": "usd"
  }
}
```

**SDK Code**

```python Mint from fiat
import requests

url = "https://api.sandbox.agora.finance/v0/routes"

payload = {
    "from": { "currency": "usd" },
    "to": {
        "currency": "ausd",
        "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
        "chain": "ethereum-sepolia"
    },
    "name": "Operating wire → ETH treasury"
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Mint from fiat
const url = 'https://api.sandbox.agora.finance/v0/routes';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"from":{"currency":"usd"},"to":{"currency":"ausd","accountId":"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c","chain":"ethereum-sepolia"},"name":"Operating wire → ETH treasury"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Mint from fiat
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sandbox.agora.finance/v0/routes"

	payload := strings.NewReader("{\n  \"from\": {\n    \"currency\": \"usd\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Operating wire → ETH treasury\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Mint from fiat
require 'uri'
require 'net/http'

url = URI("https://api.sandbox.agora.finance/v0/routes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"from\": {\n    \"currency\": \"usd\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Operating wire → ETH treasury\"\n}"

response = http.request(request)
puts response.read_body
```

```java Mint from fiat
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sandbox.agora.finance/v0/routes")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"from\": {\n    \"currency\": \"usd\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Operating wire → ETH treasury\"\n}")
  .asString();
```

```php Mint from fiat
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sandbox.agora.finance/v0/routes', [
  'body' => '{
  "from": {
    "currency": "usd"
  },
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "name": "Operating wire → ETH treasury"
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Mint from fiat
using RestSharp;

var client = new RestClient("https://api.sandbox.agora.finance/v0/routes");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"from\": {\n    \"currency\": \"usd\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Operating wire → ETH treasury\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Mint from fiat
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "from": ["currency": "usd"],
  "to": [
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  ],
  "name": "Operating wire → ETH treasury"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sandbox.agora.finance/v0/routes")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Mint from stablecoin

**Request**

```json
{
  "from": {
    "currency": "ctk"
  },
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "name": "Stablecoin deposits → ETH treasury"
}
```

**Response**

```json
{
  "id": "8f2c4d6e-1a3b-4c7d-9e0f-2a4b6c8d0e2f",
  "createdAt": "2026-05-22T14:05:00Z",
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "instructions": [
    {
      "chain": "ethereum-sepolia",
      "depositAddress": "0xdeadc3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0",
      "supportedCurrencies": [
        "ctk"
      ]
    }
  ],
  "name": "Stablecoin deposits → ETH treasury",
  "from": {
    "currency": "ctk"
  }
}
```

**SDK Code**

```python Mint from stablecoin
import requests

url = "https://api.sandbox.agora.finance/v0/routes"

payload = {
    "from": { "currency": "ctk" },
    "to": {
        "currency": "ausd",
        "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
        "chain": "ethereum-sepolia"
    },
    "name": "Stablecoin deposits → ETH treasury"
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Mint from stablecoin
const url = 'https://api.sandbox.agora.finance/v0/routes';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"from":{"currency":"ctk"},"to":{"currency":"ausd","accountId":"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c","chain":"ethereum-sepolia"},"name":"Stablecoin deposits → ETH treasury"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Mint from stablecoin
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sandbox.agora.finance/v0/routes"

	payload := strings.NewReader("{\n  \"from\": {\n    \"currency\": \"ctk\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Stablecoin deposits → ETH treasury\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Mint from stablecoin
require 'uri'
require 'net/http'

url = URI("https://api.sandbox.agora.finance/v0/routes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"from\": {\n    \"currency\": \"ctk\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Stablecoin deposits → ETH treasury\"\n}"

response = http.request(request)
puts response.read_body
```

```java Mint from stablecoin
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sandbox.agora.finance/v0/routes")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"from\": {\n    \"currency\": \"ctk\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Stablecoin deposits → ETH treasury\"\n}")
  .asString();
```

```php Mint from stablecoin
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sandbox.agora.finance/v0/routes', [
  'body' => '{
  "from": {
    "currency": "ctk"
  },
  "to": {
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "name": "Stablecoin deposits → ETH treasury"
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Mint from stablecoin
using RestSharp;

var client = new RestClient("https://api.sandbox.agora.finance/v0/routes");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"from\": {\n    \"currency\": \"ctk\"\n  },\n  \"to\": {\n    \"currency\": \"ausd\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  },\n  \"name\": \"Stablecoin deposits → ETH treasury\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Mint from stablecoin
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "from": ["currency": "ctk"],
  "to": [
    "currency": "ausd",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  ],
  "name": "Stablecoin deposits → ETH treasury"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sandbox.agora.finance/v0/routes")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Redeem to fiat

**Request**

```json
{
  "from": {
    "currency": "ausd"
  },
  "to": {
    "currency": "usd",
    "accountId": "8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"
  }
}
```

**Response**

```json
{
  "id": "3d7e1a9b-c0d4-4e5f-86a7-b8c9d0e1f2a3",
  "createdAt": "2026-05-13T17:20:00Z",
  "to": {
    "currency": "usd",
    "accountId": "8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"
  },
  "instructions": [
    {
      "chain": "ethereum-sepolia",
      "depositAddress": "0xdeadd7c8b9a0f5e6d7c8b9a0f5e6d7c8b9a0f5e6",
      "supportedCurrencies": [
        "ausd"
      ]
    }
  ],
  "name": null,
  "from": {
    "currency": "ausd"
  }
}
```

**SDK Code**

```python Redeem to fiat
import requests

url = "https://api.sandbox.agora.finance/v0/routes"

payload = {
    "from": { "currency": "ausd" },
    "to": {
        "currency": "usd",
        "accountId": "8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"
    }
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Redeem to fiat
const url = 'https://api.sandbox.agora.finance/v0/routes';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"from":{"currency":"ausd"},"to":{"currency":"usd","accountId":"8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Redeem to fiat
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sandbox.agora.finance/v0/routes"

	payload := strings.NewReader("{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"usd\",\n    \"accountId\": \"8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Redeem to fiat
require 'uri'
require 'net/http'

url = URI("https://api.sandbox.agora.finance/v0/routes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"usd\",\n    \"accountId\": \"8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c\"\n  }\n}"

response = http.request(request)
puts response.read_body
```

```java Redeem to fiat
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sandbox.agora.finance/v0/routes")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"usd\",\n    \"accountId\": \"8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c\"\n  }\n}")
  .asString();
```

```php Redeem to fiat
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sandbox.agora.finance/v0/routes', [
  'body' => '{
  "from": {
    "currency": "ausd"
  },
  "to": {
    "currency": "usd",
    "accountId": "8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"
  }
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Redeem to fiat
using RestSharp;

var client = new RestClient("https://api.sandbox.agora.finance/v0/routes");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"usd\",\n    \"accountId\": \"8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c\"\n  }\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Redeem to fiat
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "from": ["currency": "ausd"],
  "to": [
    "currency": "usd",
    "accountId": "8b3e4f12-9a7c-4d8e-b1f0-2c5d6e7a8b9c"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sandbox.agora.finance/v0/routes")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Redeem to stablecoin

**Request**

```json
{
  "from": {
    "currency": "ausd"
  },
  "to": {
    "currency": "ctk",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  }
}
```

**Response**

```json
{
  "id": "b2c3d4e5-6f70-4812-9a3b-4c5d6e7f8a90",
  "createdAt": "2026-05-22T16:40:00Z",
  "to": {
    "currency": "ctk",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  },
  "instructions": [
    {
      "chain": "ethereum-sepolia",
      "depositAddress": "0xdeadb7d6e5f4a3b2c1d0e9f8a7b6c5d4e3f2a1b0",
      "supportedCurrencies": [
        "ausd"
      ]
    }
  ],
  "name": "AUSD → CTK on Sepolia",
  "from": {
    "currency": "ausd"
  }
}
```

**SDK Code**

```python Redeem to stablecoin
import requests

url = "https://api.sandbox.agora.finance/v0/routes"

payload = {
    "from": { "currency": "ausd" },
    "to": {
        "currency": "ctk",
        "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
        "chain": "ethereum-sepolia"
    }
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Redeem to stablecoin
const url = 'https://api.sandbox.agora.finance/v0/routes';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"from":{"currency":"ausd"},"to":{"currency":"ctk","accountId":"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c","chain":"ethereum-sepolia"}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Redeem to stablecoin
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sandbox.agora.finance/v0/routes"

	payload := strings.NewReader("{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"ctk\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Redeem to stablecoin
require 'uri'
require 'net/http'

url = URI("https://api.sandbox.agora.finance/v0/routes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"ctk\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  }\n}"

response = http.request(request)
puts response.read_body
```

```java Redeem to stablecoin
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sandbox.agora.finance/v0/routes")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"ctk\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  }\n}")
  .asString();
```

```php Redeem to stablecoin
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sandbox.agora.finance/v0/routes', [
  'body' => '{
  "from": {
    "currency": "ausd"
  },
  "to": {
    "currency": "ctk",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  }
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Redeem to stablecoin
using RestSharp;

var client = new RestClient("https://api.sandbox.agora.finance/v0/routes");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"from\": {\n    \"currency\": \"ausd\"\n  },\n  \"to\": {\n    \"currency\": \"ctk\",\n    \"accountId\": \"7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n    \"chain\": \"ethereum-sepolia\"\n  }\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Redeem to stablecoin
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "from": ["currency": "ausd"],
  "to": [
    "currency": "ctk",
    "accountId": "7f3a1b2c-3d4e-5f6a-7b8c-9d0e1f2a3b4c",
    "chain": "ethereum-sepolia"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sandbox.agora.finance/v0/routes")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```