curl --request POST \
--url https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"direction": "aud_to_stablecoin",
"destination": {
"address": "<string>"
},
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": true,
"metadata": {}
}
'import requests
url = "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes"
payload = {
"direction": "aud_to_stablecoin",
"destination": { "address": "<string>" },
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": True,
"metadata": {}
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
direction: 'aud_to_stablecoin',
destination: {address: '<string>'},
limits: {min: '<string>', max: '<string>', daily: '<string>'},
clientGate: true,
metadata: {}
})
};
fetch('https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'direction' => 'aud_to_stablecoin',
'destination' => [
'address' => '<string>'
],
'limits' => [
'min' => '<string>',
'max' => '<string>',
'daily' => '<string>'
],
'clientGate' => true,
'metadata' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes"
payload := strings.NewReader("{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"counterpartyId": "<string>",
"customerId": "<string>",
"direction": "aud_to_stablecoin",
"destination": {
"network": "ethereum",
"address": "<string>",
"currency": "USDC"
},
"status": "active",
"instructions": {
"title": "<string>",
"reference": "<string>",
"deposit": {
"kind": "aud",
"bsb": "<string>",
"accountNumber": "<string>",
"reference": "<string>",
"payId": {
"type": "email",
"value": "<string>"
},
"payeeName": "<string>"
},
"destinationSummary": "<string>",
"steps": [
"<string>"
],
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"routeStatus": "active"
},
"createdAt": "2023-11-07T05:31:56Z",
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": true,
"clientGateActive": true,
"deactivatedAt": "2023-11-07T05:31:56Z",
"deactivatedBy": "<string>",
"deactivationNote": "<string>"
}Create a payment route for a customer
Creates a standing payment route under the customer identified in the URL.
curl --request POST \
--url https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"direction": "aud_to_stablecoin",
"destination": {
"address": "<string>"
},
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": true,
"metadata": {}
}
'import requests
url = "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes"
payload = {
"direction": "aud_to_stablecoin",
"destination": { "address": "<string>" },
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": True,
"metadata": {}
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
direction: 'aud_to_stablecoin',
destination: {address: '<string>'},
limits: {min: '<string>', max: '<string>', daily: '<string>'},
clientGate: true,
metadata: {}
})
};
fetch('https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'direction' => 'aud_to_stablecoin',
'destination' => [
'address' => '<string>'
],
'limits' => [
'min' => '<string>',
'max' => '<string>',
'daily' => '<string>'
],
'clientGate' => true,
'metadata' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes"
payload := strings.NewReader("{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.rails.wayex.com/v1/customers/{customerId}/payment-routes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"direction\": \"aud_to_stablecoin\",\n \"destination\": {\n \"address\": \"<string>\"\n },\n \"limits\": {\n \"min\": \"<string>\",\n \"max\": \"<string>\",\n \"daily\": \"<string>\"\n },\n \"clientGate\": true,\n \"metadata\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"counterpartyId": "<string>",
"customerId": "<string>",
"direction": "aud_to_stablecoin",
"destination": {
"network": "ethereum",
"address": "<string>",
"currency": "USDC"
},
"status": "active",
"instructions": {
"title": "<string>",
"reference": "<string>",
"deposit": {
"kind": "aud",
"bsb": "<string>",
"accountNumber": "<string>",
"reference": "<string>",
"payId": {
"type": "email",
"value": "<string>"
},
"payeeName": "<string>"
},
"destinationSummary": "<string>",
"steps": [
"<string>"
],
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"routeStatus": "active"
},
"createdAt": "2023-11-07T05:31:56Z",
"limits": {
"min": "<string>",
"max": "<string>",
"daily": "<string>"
},
"clientGate": true,
"clientGateActive": true,
"deactivatedAt": "2023-11-07T05:31:56Z",
"deactivatedBy": "<string>",
"deactivationNote": "<string>"
}What this endpoint does
Creates a standing payment route under the customer identified in the URL.When to use it
Use this customer-scoped form when your integration already works from a customer record. On an AUD-to-stablecoin route, setclientGate: true to hold each funding for your progress or refund decision.
Before you call
Use a secret API key with route write access. The customer must belong to this tenant account and have the required approved entitlement.clientGate needs the capability to be enabled for your account by Wayex (403 onramp_client_gate_not_available otherwise).
Money and balance effect
Creating the route does not move money. Funding the issued instructions later starts a transfer.States and completion
Creation confirms route provisioning, not funding or settlement. Track each later funding through its transfer. A client-gated route returnsclientGate: true and clientGateActive.
Safe retries
Send a uniqueIdempotency-Key for the logical action. If the response is lost, retry the same payload with the same key; never create a new key merely because the first response timed out.
Read Payment routes for the complete workflow.Authorizations
Send the same Wayex API key as Authorization: Bearer <key>.
Headers
A unique key for this logical action. Reuse the same key and identical payload when retrying after an unknown response.
8 - 255Path Parameters
Body
- Option 1
- Option 2
The customer funds AUD and receives stablecoin at the destination address.
aud_to_stablecoin Where the converted stablecoin is delivered.
Show child attributes
Show child attributes
Optional per-route min/max/daily limits; a deposit outside them is held, not converted.
Show child attributes
Show child attributes
Hold every funding of this route at awaiting_client_action until you progress or refund it. Requires the capability to be enabled for your account.
Show child attributes
Show child attributes
Response
The created payment route with deposit instructions.
- Option 1
- Option 2
1The client account (counterparty) this route belongs to. For API callers this is always your own account id.
11aud_to_stablecoin Show child attributes
Show child attributes
active, inactive Show child attributes
Show child attributes
Show child attributes
Show child attributes
When the route was deactivated. Present only on an inactive route.
Who deactivated the route: the console user id, or the API key id for an API call. Present only on an inactive route.
1The reason given when the route was deactivated.
1
