curl --request GET \
--url https://api.dexploit.dev/wallets/{w}/holdings \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.dexploit.dev/wallets/{w}/holdings"
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.dexploit.dev/wallets/{w}/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://api.dexploit.dev/wallets/{w}/holdings",
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.dexploit.dev/wallets/{w}/holdings"
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.dexploit.dev/wallets/{w}/holdings")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.dexploit.dev/wallets/{w}/holdings")
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{
"wallet": "<string>",
"holdings_source": "shyft",
"holdings": [
{
"mint": "<string>",
"qty": 123,
"no_cost_basis": true,
"price_stale": true,
"cost_basis_sol": 123,
"current_value_sol": 123,
"current_value_usd": 123,
"unrealized_pnl_sol": 123
}
],
"computed_at": 123
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}On-chain holdings with cost-basis overlay
Returns the wallet’s current on-chain SPL token holdings sourced from Shyft’s all_tokens API, with FIFO cost-basis and unrealized PnL overlaid where Dexploit has swap history.
Tokens acquired via airdrop or off-platform transfers will appear with no_cost_basis: true and cost_basis_sol: null.
When Shyft is temporarily unavailable the endpoint degrades to FIFO-derived holdings and sets holdings_source: "fifo_fallback" — it never returns 5xx on a Shyft outage.
Response is cached 30 seconds per wallet. See Wallet portfolio for a full explanation of the two holdings sources.
curl --request GET \
--url https://api.dexploit.dev/wallets/{w}/holdings \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.dexploit.dev/wallets/{w}/holdings"
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.dexploit.dev/wallets/{w}/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://api.dexploit.dev/wallets/{w}/holdings",
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.dexploit.dev/wallets/{w}/holdings"
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.dexploit.dev/wallets/{w}/holdings")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.dexploit.dev/wallets/{w}/holdings")
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{
"wallet": "<string>",
"holdings_source": "shyft",
"holdings": [
{
"mint": "<string>",
"qty": 123,
"no_cost_basis": true,
"price_stale": true,
"cost_basis_sol": 123,
"current_value_sol": 123,
"current_value_usd": 123,
"unrealized_pnl_sol": 123
}
],
"computed_at": 123
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}{
"success": false,
"error": {
"code": "INVALID_PARAM",
"message": "use pair_address; see /api/v1/pairs?token_address=X to discover pools"
}
}Authorizations
Preferred for swaps-api endpoints (/swaps/*, /stats/*, /trending, /pool-events).
Path Parameters
Wallet address (base58, 32–44 characters).
Query Parameters
Filter FIFO cost-basis computation to a single DEX by integer ID. See DexId for the mapping. Has no effect on the Shyft on-chain token list.
Response
Holdings with cost-basis
Response from /wallets/{w}/holdings. holdings_source indicates whether the token list came from Shyft (authoritative) or fell back to FIFO-derived data.
shyft = authoritative on-chain balances. fifo_fallback = Shyft was temporarily unavailable; list is derived from Dexploit's swap index only.
shyft, fifo_fallback Show child attributes
Show child attributes
Unix epoch milliseconds when this response was assembled.

