curl --request POST \
--url https://api.saber.money/api/v2/wallet/transaction/crypto/buy \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <x-api-key>' \
--header 'X-Request-Id: <x-request-id>' \
--header 'X-Signature: <x-signature>' \
--header 'X-Timestamp: <x-timestamp>' \
--header 'X-User-Id: <x-user-id>' \
--data '
{
"from_currency": "EUR",
"to_currency": "USDT",
"from_amount": 100,
"payment_method": "sepa_transfer",
"crypto_wallet_address": "0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724",
"network": "MATIC",
"source_id": "IT78R36772223000EM0005782376",
"bank_transaction_id": "IT78R36772223000EM0005782376_1713099131715"
}
'import requests
url = "https://api.saber.money/api/v2/wallet/transaction/crypto/buy"
payload = {
"from_currency": "EUR",
"to_currency": "USDT",
"from_amount": 100,
"payment_method": "sepa_transfer",
"crypto_wallet_address": "0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724",
"network": "MATIC",
"source_id": "IT78R36772223000EM0005782376",
"bank_transaction_id": "IT78R36772223000EM0005782376_1713099131715"
}
headers = {
"X-Api-Key": "<x-api-key>",
"X-Signature": "<x-signature>",
"X-Timestamp": "<x-timestamp>",
"X-Request-Id": "<x-request-id>",
"X-User-Id": "<x-user-id>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Api-Key': '<x-api-key>',
'X-Signature': '<x-signature>',
'X-Timestamp': '<x-timestamp>',
'X-Request-Id': '<x-request-id>',
'X-User-Id': '<x-user-id>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
from_currency: 'EUR',
to_currency: 'USDT',
from_amount: 100,
payment_method: 'sepa_transfer',
crypto_wallet_address: '0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724',
network: 'MATIC',
source_id: 'IT78R36772223000EM0005782376',
bank_transaction_id: 'IT78R36772223000EM0005782376_1713099131715'
})
};
fetch('https://api.saber.money/api/v2/wallet/transaction/crypto/buy', 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.saber.money/api/v2/wallet/transaction/crypto/buy",
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([
'from_currency' => 'EUR',
'to_currency' => 'USDT',
'from_amount' => 100,
'payment_method' => 'sepa_transfer',
'crypto_wallet_address' => '0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724',
'network' => 'MATIC',
'source_id' => 'IT78R36772223000EM0005782376',
'bank_transaction_id' => 'IT78R36772223000EM0005782376_1713099131715'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Api-Key: <x-api-key>",
"X-Request-Id: <x-request-id>",
"X-Signature: <x-signature>",
"X-Timestamp: <x-timestamp>",
"X-User-Id: <x-user-id>"
],
]);
$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.saber.money/api/v2/wallet/transaction/crypto/buy"
payload := strings.NewReader("{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Api-Key", "<x-api-key>")
req.Header.Add("X-Signature", "<x-signature>")
req.Header.Add("X-Timestamp", "<x-timestamp>")
req.Header.Add("X-Request-Id", "<x-request-id>")
req.Header.Add("X-User-Id", "<x-user-id>")
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.saber.money/api/v2/wallet/transaction/crypto/buy")
.header("X-Api-Key", "<x-api-key>")
.header("X-Signature", "<x-signature>")
.header("X-Timestamp", "<x-timestamp>")
.header("X-Request-Id", "<x-request-id>")
.header("X-User-Id", "<x-user-id>")
.header("Content-Type", "application/json")
.body("{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.saber.money/api/v2/wallet/transaction/crypto/buy")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Api-Key"] = '<x-api-key>'
request["X-Signature"] = '<x-signature>'
request["X-Timestamp"] = '<x-timestamp>'
request["X-Request-Id"] = '<x-request-id>'
request["X-User-Id"] = '<x-user-id>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "74cbe2f9-4e2a-4bd2-92d2-1a139e7cdcf9",
"uuid": "74cbe2f9-4e2a-4bd2-92d2-1a139e7cdcf9",
"status": "PROCESSING",
"fiat_symbol": "EUR",
"crypto_symbol": "USDT",
"fiat_amount": 100,
"crypto_amount": 10,
"payment_method": "sepa_transfer",
"exchange_rate": 97.61,
"crypto_wallet_address": "0xb84b44140b9c9d2a32707ba35332969c65bc918d",
"network": "MATIC",
"tag": null,
"source_id": "c41f7d27-781c-41da-b74c-278fe7202af5",
"bank_transaction_id": null,
"failure_code": null,
"failure_desc": null,
"created_at": 1684394172000
}
}Create Buy Transaction (v1)
Create Buy Transaction
Field notes (recovered from legacy docs)
Create External Buy
Price lock (quote_id)
Pass quote_id to create this transaction against a price-locked quote previously issued by the External Buy Quote endpoint (POST /api/v2/wallet/w/quote). When quote_id is supplied, the locked currency pair, payment method, amounts, network, and fees are resolved from the stored quote; the matching request fields become optional and any values sent for them are ignored. crypto_wallet_address is always required. When quote_id is absent the endpoint behaves as before and the original fields remain required.
{
"quote_id": "421b9fb7-6800-4d9d-ba17-083ad662733b",
"crypto_wallet_address": "0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724",
"source_id": "94b00193-301d-4750-b310-207393d987c9",
"bank_transaction_id": "501610337776"
}
Response field values
| Field | Possible Values |
|---|---|
status | Typically PROCESSING immediately after creation |
failure_code, failure_desc | Empty string until the transaction fails |
If crypto_wallet_address is POOL_TRANSFER, the handler may also surface broker or deposit-address service errors directly with their underlying code and message.
curl --request POST \
--url https://api.saber.money/api/v2/wallet/transaction/crypto/buy \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <x-api-key>' \
--header 'X-Request-Id: <x-request-id>' \
--header 'X-Signature: <x-signature>' \
--header 'X-Timestamp: <x-timestamp>' \
--header 'X-User-Id: <x-user-id>' \
--data '
{
"from_currency": "EUR",
"to_currency": "USDT",
"from_amount": 100,
"payment_method": "sepa_transfer",
"crypto_wallet_address": "0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724",
"network": "MATIC",
"source_id": "IT78R36772223000EM0005782376",
"bank_transaction_id": "IT78R36772223000EM0005782376_1713099131715"
}
'import requests
url = "https://api.saber.money/api/v2/wallet/transaction/crypto/buy"
payload = {
"from_currency": "EUR",
"to_currency": "USDT",
"from_amount": 100,
"payment_method": "sepa_transfer",
"crypto_wallet_address": "0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724",
"network": "MATIC",
"source_id": "IT78R36772223000EM0005782376",
"bank_transaction_id": "IT78R36772223000EM0005782376_1713099131715"
}
headers = {
"X-Api-Key": "<x-api-key>",
"X-Signature": "<x-signature>",
"X-Timestamp": "<x-timestamp>",
"X-Request-Id": "<x-request-id>",
"X-User-Id": "<x-user-id>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Api-Key': '<x-api-key>',
'X-Signature': '<x-signature>',
'X-Timestamp': '<x-timestamp>',
'X-Request-Id': '<x-request-id>',
'X-User-Id': '<x-user-id>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
from_currency: 'EUR',
to_currency: 'USDT',
from_amount: 100,
payment_method: 'sepa_transfer',
crypto_wallet_address: '0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724',
network: 'MATIC',
source_id: 'IT78R36772223000EM0005782376',
bank_transaction_id: 'IT78R36772223000EM0005782376_1713099131715'
})
};
fetch('https://api.saber.money/api/v2/wallet/transaction/crypto/buy', 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.saber.money/api/v2/wallet/transaction/crypto/buy",
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([
'from_currency' => 'EUR',
'to_currency' => 'USDT',
'from_amount' => 100,
'payment_method' => 'sepa_transfer',
'crypto_wallet_address' => '0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724',
'network' => 'MATIC',
'source_id' => 'IT78R36772223000EM0005782376',
'bank_transaction_id' => 'IT78R36772223000EM0005782376_1713099131715'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Api-Key: <x-api-key>",
"X-Request-Id: <x-request-id>",
"X-Signature: <x-signature>",
"X-Timestamp: <x-timestamp>",
"X-User-Id: <x-user-id>"
],
]);
$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.saber.money/api/v2/wallet/transaction/crypto/buy"
payload := strings.NewReader("{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Api-Key", "<x-api-key>")
req.Header.Add("X-Signature", "<x-signature>")
req.Header.Add("X-Timestamp", "<x-timestamp>")
req.Header.Add("X-Request-Id", "<x-request-id>")
req.Header.Add("X-User-Id", "<x-user-id>")
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.saber.money/api/v2/wallet/transaction/crypto/buy")
.header("X-Api-Key", "<x-api-key>")
.header("X-Signature", "<x-signature>")
.header("X-Timestamp", "<x-timestamp>")
.header("X-Request-Id", "<x-request-id>")
.header("X-User-Id", "<x-user-id>")
.header("Content-Type", "application/json")
.body("{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.saber.money/api/v2/wallet/transaction/crypto/buy")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Api-Key"] = '<x-api-key>'
request["X-Signature"] = '<x-signature>'
request["X-Timestamp"] = '<x-timestamp>'
request["X-Request-Id"] = '<x-request-id>'
request["X-User-Id"] = '<x-user-id>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"from_currency\": \"EUR\",\n \"to_currency\": \"USDT\",\n \"from_amount\": 100,\n \"payment_method\": \"sepa_transfer\",\n \"crypto_wallet_address\": \"0xf82010290b2c3169ffaB5354d7Bbd09Eb2822724\",\n \"network\": \"MATIC\",\n \"source_id\": \"IT78R36772223000EM0005782376\",\n \"bank_transaction_id\": \"IT78R36772223000EM0005782376_1713099131715\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "74cbe2f9-4e2a-4bd2-92d2-1a139e7cdcf9",
"uuid": "74cbe2f9-4e2a-4bd2-92d2-1a139e7cdcf9",
"status": "PROCESSING",
"fiat_symbol": "EUR",
"crypto_symbol": "USDT",
"fiat_amount": 100,
"crypto_amount": 10,
"payment_method": "sepa_transfer",
"exchange_rate": 97.61,
"crypto_wallet_address": "0xb84b44140b9c9d2a32707ba35332969c65bc918d",
"network": "MATIC",
"tag": null,
"source_id": "c41f7d27-781c-41da-b74c-278fe7202af5",
"bank_transaction_id": null,
"failure_code": null,
"failure_desc": null,
"created_at": 1684394172000
}
}Headers
Your API key (configured in credentials)
HMAC-SHA256 signature (auto-generated) To test manually: HMAC-SHA256 of apiKey + timestamp (or apiKey + timestamp + userId when X-User-Id is required), keyed with your API secret. The HMAC Generator flow computes this for you.
Unix timestamp in seconds (auto-generated) Unix seconds, e.g. Math.floor(Date.now() / 1000). Must match the timestamp used in the X-Signature computation.
Unique request identifier (auto-generated) Any unique string per request, e.g. a UUID.
User UUID (set above)
Body
The from_currency field
The to_currency field
The from_amount field
The payment_method field
The crypto_wallet_address field
The network field
The source_id field
The bank_transaction_id field
Was this page helpful?