curl --request POST \
--url https://api.raeth.exchange/v1/withdrawals \
--header 'Content-Type: application/json' \
--header 'DX-ACCESS-KEY: <api-key>' \
--header 'DX-ACCESS-SIGNATURE: <api-key>' \
--header 'DX-ACCESS-TIMESTAMP: <api-key>' \
--data '
{
"client_withdrawal_id": "182390",
"amount": "182390",
"dest": "<string>"
}
'import requests
url = "https://api.raeth.exchange/v1/withdrawals"
payload = {
"client_withdrawal_id": "182390",
"amount": "182390",
"dest": "<string>"
}
headers = {
"DX-ACCESS-KEY": "<api-key>",
"DX-ACCESS-TIMESTAMP": "<api-key>",
"DX-ACCESS-SIGNATURE": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'DX-ACCESS-KEY': '<api-key>',
'DX-ACCESS-TIMESTAMP': '<api-key>',
'DX-ACCESS-SIGNATURE': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({client_withdrawal_id: '182390', amount: '182390', dest: '<string>'})
};
fetch('https://api.raeth.exchange/v1/withdrawals', 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.raeth.exchange/v1/withdrawals",
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([
'client_withdrawal_id' => '182390',
'amount' => '182390',
'dest' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"DX-ACCESS-KEY: <api-key>",
"DX-ACCESS-SIGNATURE: <api-key>",
"DX-ACCESS-TIMESTAMP: <api-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.raeth.exchange/v1/withdrawals"
payload := strings.NewReader("{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("DX-ACCESS-KEY", "<api-key>")
req.Header.Add("DX-ACCESS-TIMESTAMP", "<api-key>")
req.Header.Add("DX-ACCESS-SIGNATURE", "<api-key>")
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.raeth.exchange/v1/withdrawals")
.header("DX-ACCESS-KEY", "<api-key>")
.header("DX-ACCESS-TIMESTAMP", "<api-key>")
.header("DX-ACCESS-SIGNATURE", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.raeth.exchange/v1/withdrawals")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["DX-ACCESS-KEY"] = '<api-key>'
request["DX-ACCESS-TIMESTAMP"] = '<api-key>'
request["DX-ACCESS-SIGNATURE"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"wid": "9001",
"status": "reserved"
}{
"wid": "9001",
"status": "requested"
}{
"error": {
"code": "unknown_field",
"num": null,
"origin": "gateway",
"message": "unknown_field",
"details": null
}
}{
"error": {
"code": "unauthorized",
"num": null,
"origin": "gateway",
"message": "unauthorized",
"details": null
}
}{
"error": {
"code": "missing_scope",
"num": null,
"origin": "gateway",
"message": "missing_scope",
"details": null
}
}{
"error": {
"code": "unknown_order",
"num": 260,
"origin": "core",
"message": "unknown_order",
"details": null
}
}{
"error": {
"code": "duplicate_client_order_id",
"num": 259,
"origin": "core",
"message": "duplicate_client_order_id",
"details": null
}
}{
"error": {
"code": "insufficient_balance",
"num": 257,
"origin": "core",
"message": "insufficient_balance",
"details": null
}
}{
"error": {
"code": "rate_limited",
"num": null,
"origin": "gateway",
"message": "rate_limited",
"details": null
}
}{
"error": {
"code": "funding_capacity",
"num": null,
"origin": "port",
"message": "funding_capacity",
"details": null
}
}{
"error": {
"code": "sequencing_timeout",
"num": null,
"origin": "gateway",
"message": "sequencing_timeout",
"details": null
}
}Closed schema (api.md §6A.2). client_withdrawal_id is the per-user
idempotency key and must be strictly increasing: a fresh id
(> hwm) is forwarded; an equal id (== hwm) is treated as an
idempotent retry and returns the current phase; a stale id (< hwm)
returns 409 stale_client_withdrawal_id. 201 = freshly accepted;
200 = a phase report for a retry/known id. The gateway validates
dest structurally only and forwards its casing verbatim for the
funding port’s EIP-55 check.
curl --request POST \
--url https://api.raeth.exchange/v1/withdrawals \
--header 'Content-Type: application/json' \
--header 'DX-ACCESS-KEY: <api-key>' \
--header 'DX-ACCESS-SIGNATURE: <api-key>' \
--header 'DX-ACCESS-TIMESTAMP: <api-key>' \
--data '
{
"client_withdrawal_id": "182390",
"amount": "182390",
"dest": "<string>"
}
'import requests
url = "https://api.raeth.exchange/v1/withdrawals"
payload = {
"client_withdrawal_id": "182390",
"amount": "182390",
"dest": "<string>"
}
headers = {
"DX-ACCESS-KEY": "<api-key>",
"DX-ACCESS-TIMESTAMP": "<api-key>",
"DX-ACCESS-SIGNATURE": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'DX-ACCESS-KEY': '<api-key>',
'DX-ACCESS-TIMESTAMP': '<api-key>',
'DX-ACCESS-SIGNATURE': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({client_withdrawal_id: '182390', amount: '182390', dest: '<string>'})
};
fetch('https://api.raeth.exchange/v1/withdrawals', 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.raeth.exchange/v1/withdrawals",
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([
'client_withdrawal_id' => '182390',
'amount' => '182390',
'dest' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"DX-ACCESS-KEY: <api-key>",
"DX-ACCESS-SIGNATURE: <api-key>",
"DX-ACCESS-TIMESTAMP: <api-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.raeth.exchange/v1/withdrawals"
payload := strings.NewReader("{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("DX-ACCESS-KEY", "<api-key>")
req.Header.Add("DX-ACCESS-TIMESTAMP", "<api-key>")
req.Header.Add("DX-ACCESS-SIGNATURE", "<api-key>")
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.raeth.exchange/v1/withdrawals")
.header("DX-ACCESS-KEY", "<api-key>")
.header("DX-ACCESS-TIMESTAMP", "<api-key>")
.header("DX-ACCESS-SIGNATURE", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.raeth.exchange/v1/withdrawals")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["DX-ACCESS-KEY"] = '<api-key>'
request["DX-ACCESS-TIMESTAMP"] = '<api-key>'
request["DX-ACCESS-SIGNATURE"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_withdrawal_id\": \"182390\",\n \"amount\": \"182390\",\n \"dest\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"wid": "9001",
"status": "reserved"
}{
"wid": "9001",
"status": "requested"
}{
"error": {
"code": "unknown_field",
"num": null,
"origin": "gateway",
"message": "unknown_field",
"details": null
}
}{
"error": {
"code": "unauthorized",
"num": null,
"origin": "gateway",
"message": "unauthorized",
"details": null
}
}{
"error": {
"code": "missing_scope",
"num": null,
"origin": "gateway",
"message": "missing_scope",
"details": null
}
}{
"error": {
"code": "unknown_order",
"num": 260,
"origin": "core",
"message": "unknown_order",
"details": null
}
}{
"error": {
"code": "duplicate_client_order_id",
"num": 259,
"origin": "core",
"message": "duplicate_client_order_id",
"details": null
}
}{
"error": {
"code": "insufficient_balance",
"num": 257,
"origin": "core",
"message": "insufficient_balance",
"details": null
}
}{
"error": {
"code": "rate_limited",
"num": null,
"origin": "gateway",
"message": "rate_limited",
"details": null
}
}{
"error": {
"code": "funding_capacity",
"num": null,
"origin": "port",
"message": "funding_capacity",
"details": null
}
}{
"error": {
"code": "sequencing_timeout",
"num": null,
"origin": "gateway",
"message": "sequencing_timeout",
"details": null
}
}Authorizations
The API key id (decimal string).
Request timestamp, Unix milliseconds (decimal). ±5000 ms replay window.
base64(HMAC-SHA256(secret, "timestamp\nMETHOD\npath?query\nbody")). For the WS handshake the body is empty and the path is /v1/ws.
Body
Closed schema (api.md §6A.2).
nonzero, strictly increasing per user (idempotency key)
^[0-9]+$"182390"
nonzero cents
^[0-9]+$"182390"
exactly 42 chars: lowercase 0x + 40 hex (either case); mixed-case triggers the funding port's EIP-55 checksum verify
^0x[0-9a-fA-F]{40}$