Get a customer crypto wallet balance
curl --request GET \
--url https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance \
--header 'x-api-key: <api-key>'import requests
url = "https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance', 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-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <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"
"net/http"
"io"
)
func main() {
url := "https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": true,
"statusCode": 200,
"message": "Customer crypto wallet balance retrieved",
"data": [
{
"id": "61237ceb-bde6-4052-9294-38470806f672",
"address": "GAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWHF",
"network": "stellar",
"tokens": {
"xlm": { "amount": "2.5", "rawAmount": "25000000" },
"usdc": { "amount": "10.50", "rawAmount": "105000000" }
}
}
]
}
Crypto Wallets
Get Customer Wallet Balance
Retrieve a customer’s Solana or Stellar wallet balances
GET
/
api
/
v1
/
wallets
/
crypto
/
customer
/
{customerId}
/
balance
Get a customer crypto wallet balance
curl --request GET \
--url https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance \
--header 'x-api-key: <api-key>'import requests
url = "https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance', 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-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <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"
"net/http"
"io"
)
func main() {
url := "https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-production.fossapay.com/api/v1/wallets/crypto/customer/{customerId}/balance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": true,
"statusCode": 200,
"message": "Customer crypto wallet balance retrieved",
"data": [
{
"id": "61237ceb-bde6-4052-9294-38470806f672",
"address": "GAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWHF",
"network": "stellar",
"tokens": {
"xlm": { "amount": "2.5", "rawAmount": "25000000" },
"usdc": { "amount": "10.50", "rawAmount": "105000000" }
}
}
]
}
The customer and selected network wallet must belong to the merchant resolved from the production API key. Solana balances can contain SOL, USDC, and USDT; Stellar balances can contain XLM and USDC. Unsupported asset receipts remain visible in wallet transaction history but are omitted from the supported-balance response.
Use decimal-safe arithmetic and preserve the returned string values. A balance response is a point-in-time view; reconcile transaction state separately.
Path parameter
Query parameter
Header
Request example
curl --request GET \
--url 'https://api-production.fossapay.com/api/v1/wallets/crypto/customer/11111111-1111-4111-8111-111111111111/balance?network=stellar' \
--header "x-api-key: $FOSSAPAY_API_KEY"
Response
{
"status": true,
"statusCode": 200,
"message": "Customer crypto wallet balance retrieved",
"data": [
{
"id": "61237ceb-bde6-4052-9294-38470806f672",
"address": "GAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWHF",
"network": "stellar",
"tokens": {
"xlm": { "amount": "2.5", "rawAmount": "25000000" },
"usdc": { "amount": "10.50", "rawAmount": "105000000" }
}
}
]
}
Errors
| Status | Typical cause |
|---|---|
400 | Customer or selected network wallet was not found for this merchant |
401 | Missing, invalid, or inactive API key |
422 | customerId is not a valid UUID |
5xx | Temporary provider or platform error |

