curl --request POST \
--url https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"wallet_address": "<string>",
"network": "<string>",
"limit": 10
}
'import requests
url = "https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings"
payload = {
"wallet_address": "<string>",
"network": "<string>",
"limit": 10
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({wallet_address: '<string>', network: '<string>', limit: 10})
};
fetch('https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings', 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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings",
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([
'wallet_address' => '<string>',
'network' => '<string>',
'limit' => 10
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings"
payload := strings.NewReader("{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}")
req, _ := http.NewRequest("POST", url, payload)
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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}"
response = http.request(request)
puts response.read_body{
"type": "token_holdings",
"wallet_address": "0x1111111111111111111111111111111111111111",
"data": [
{
"symbol": "EXM",
"name": "Example Token",
"contract_address": "0x3333333333333333333333333333333333333333",
"balance": 100,
"usd_value": 250,
"chain": "ethereum",
"price": 2.5
}
],
"summary": {
"total_tokens_usd_value": "$250.00",
"total_protocol_usd_value": "$0.00",
"total_value_displayed": "$250.00",
"token_count": 1,
"protocol_count": 0,
"tokens_without_price": 0
},
"metadata": {
"wallet_address": "0x1111111111111111111111111111111111111111",
"network": "ETHEREUM"
}
}get_wallet_token_holdings
Token holdings (symbol, balance, USD value) for a wallet on one network or ‘all’.
curl --request POST \
--url https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"wallet_address": "<string>",
"network": "<string>",
"limit": 10
}
'import requests
url = "https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings"
payload = {
"wallet_address": "<string>",
"network": "<string>",
"limit": 10
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({wallet_address: '<string>', network: '<string>', limit: 10})
};
fetch('https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings', 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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings",
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([
'wallet_address' => '<string>',
'network' => '<string>',
'limit' => 10
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings"
payload := strings.NewReader("{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}")
req, _ := http.NewRequest("POST", url, payload)
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://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://pro-api.nikiwa.com/api/tools/get_wallet_token_holdings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"wallet_address\": \"<string>\",\n \"network\": \"<string>\",\n \"limit\": 10\n}"
response = http.request(request)
puts response.read_body{
"type": "token_holdings",
"wallet_address": "0x1111111111111111111111111111111111111111",
"data": [
{
"symbol": "EXM",
"name": "Example Token",
"contract_address": "0x3333333333333333333333333333333333333333",
"balance": 100,
"usd_value": 250,
"chain": "ethereum",
"price": 2.5
}
],
"summary": {
"total_tokens_usd_value": "$250.00",
"total_protocol_usd_value": "$0.00",
"total_value_displayed": "$250.00",
"token_count": 1,
"protocol_count": 0,
"tokens_without_price": 0
},
"metadata": {
"wallet_address": "0x1111111111111111111111111111111111111111",
"network": "ETHEREUM"
}
}Reading the result
The response example uses made-up values and shows selected fields. Fields vary by network and available data.-
datalists holdings.balanceis the token amount;usd_valueis its USD value or"N/A"when a price is unavailable. -
summarycontains formatted currency strings.total_value_displayedcovers the returned holdings and protocol positions; it is not necessarily the full wallet balance. -
protocol_positionsappears when protocol positions are available. Fields such asprice,chain, andlogo_urlare included when available.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Wallet address to analyze. Use the address format for the selected network.
Network to query, for example ethereum. See Supported Networks for coverage. Use all to query supported networks together.
Maximum number of holdings to include in the result.
Response
Token holdings (symbol, balance, USD value) for a wallet on one network or 'all'. Fields vary by network and available data. Check for status: no_data, status: error, or an error field even when HTTP status is 200. See Errors & status.
Response fields depend on the network and available data. The example shows selected fields; see Reading the result for details.
Was this page helpful?