Retrieve all balances
curl --request GET \
--url https://api.example.com/accounts/balances \
--header 'x-digest-key: <api-key>' \
--header 'x-digest-signature: <x-digest-signature>' \
--header 'x-digest-timestamp: <x-digest-timestamp>'import requests
url = "https://api.example.com/accounts/balances"
headers = {
"x-digest-timestamp": "<x-digest-timestamp>",
"x-digest-key": "<api-key>",
"x-digest-signature": "<x-digest-signature>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'x-digest-timestamp': '<x-digest-timestamp>',
'x-digest-key': '<api-key>',
'x-digest-signature': '<x-digest-signature>'
}
};
fetch('https://api.example.com/accounts/balances', 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.example.com/accounts/balances",
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-digest-key: <api-key>",
"x-digest-signature: <x-digest-signature>",
"x-digest-timestamp: <x-digest-timestamp>"
],
]);
$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.example.com/accounts/balances"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-digest-timestamp", "<x-digest-timestamp>")
req.Header.Add("x-digest-key", "<api-key>")
req.Header.Add("x-digest-signature", "<x-digest-signature>")
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.example.com/accounts/balances")
.header("x-digest-timestamp", "<x-digest-timestamp>")
.header("x-digest-key", "<api-key>")
.header("x-digest-signature", "<x-digest-signature>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/accounts/balances")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-digest-timestamp"] = '<x-digest-timestamp>'
request["x-digest-key"] = '<api-key>'
request["x-digest-signature"] = '<x-digest-signature>'
response = http.request(request)
puts response.read_body{
"USDC:GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5": {
"balance": "0.00"
},
"EURS:GCWPTOH75K6Y7B3F267SDWEY5OVDQEK6OQ2VUINEZFOL5HX544NECR6Y": {
"balance": "20.23"
}
}{
"reason": "Unauthorized",
"statusCode": 401
}{
"reason": "Internal Server Error",
"statusCode": 500
}Accounts
Get All Balances
Fetches all balances for the logged-in merchant.
GET
/
accounts
/
balances
Retrieve all balances
curl --request GET \
--url https://api.example.com/accounts/balances \
--header 'x-digest-key: <api-key>' \
--header 'x-digest-signature: <x-digest-signature>' \
--header 'x-digest-timestamp: <x-digest-timestamp>'import requests
url = "https://api.example.com/accounts/balances"
headers = {
"x-digest-timestamp": "<x-digest-timestamp>",
"x-digest-key": "<api-key>",
"x-digest-signature": "<x-digest-signature>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'x-digest-timestamp': '<x-digest-timestamp>',
'x-digest-key': '<api-key>',
'x-digest-signature': '<x-digest-signature>'
}
};
fetch('https://api.example.com/accounts/balances', 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.example.com/accounts/balances",
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-digest-key: <api-key>",
"x-digest-signature: <x-digest-signature>",
"x-digest-timestamp: <x-digest-timestamp>"
],
]);
$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.example.com/accounts/balances"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-digest-timestamp", "<x-digest-timestamp>")
req.Header.Add("x-digest-key", "<api-key>")
req.Header.Add("x-digest-signature", "<x-digest-signature>")
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.example.com/accounts/balances")
.header("x-digest-timestamp", "<x-digest-timestamp>")
.header("x-digest-key", "<api-key>")
.header("x-digest-signature", "<x-digest-signature>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/accounts/balances")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-digest-timestamp"] = '<x-digest-timestamp>'
request["x-digest-key"] = '<api-key>'
request["x-digest-signature"] = '<x-digest-signature>'
response = http.request(request)
puts response.read_body{
"USDC:GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5": {
"balance": "0.00"
},
"EURS:GCWPTOH75K6Y7B3F267SDWEY5OVDQEK6OQ2VUINEZFOL5HX544NECR6Y": {
"balance": "20.23"
}
}{
"reason": "Unauthorized",
"statusCode": 401
}{
"reason": "Internal Server Error",
"statusCode": 500
}Authorizations
Your public API key
Headers
Current Unix timestamp
Your public api key
Digest Auth Signature
Response
On success, the endpoint will return a JSON object with detailed account balances for each asset.
Each key is an asset identifier and the value is an object containing the balance information.
Show child attributes
Show child attributes
⌘I