curl --request GET \
--url https://api.zerion.io/v1/wallet-sets/charts/{chart_period} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.zerion.io/v1/wallet-sets/charts/{chart_period}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.zerion.io/v1/wallet-sets/charts/{chart_period}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zerion.io/v1/wallet-sets/charts/{chart_period}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"links": {
"self": "https://api.zerion.io/v1/wallet-sets/charts/week?addresses=0x42b9df65b219b3dd36ff330a4dd8f327a6ada990%2C8BH9pjtgyZDC4iAQH5ZiYDZ1MDWC98xki2V8NzqqKW3K¤cy=eth&filter%5Bchain_ids%5D=ethereum%2Csolana"
},
"data": {
"type": "wallet_chart",
"id": "0x42b9df65b219b3dd36ff330a4dd8f327a6ada990,8BH9pjtgyZDC4iAQH5ZiYDZ1MDWC98xki2V8NzqqKW3K-week",
"attributes": {
"begin_at": "2023-01-18T11:00:00Z",
"end_at": "2023-01-25T10:30:00Z",
"points": [
[
1674039600,
1145.00999
]
]
}
}
}{
"errors": [
{
"title": "Parameter is malformed",
"detail": "Some validation errors will be described here"
}
]
}{
"errors": [
{
"title": "Unauthorized Error",
"detail": "The API key is invalid, please, make sure that you are using a valid key"
}
]
}{
"errors": [
{
"title": "Too many requests",
"detail": "Your request had been throttled"
}
]
}Get wallet set balance chart
Combined portfolio value over time for an EVM and Solana address, filterable by chain and asset type.
curl --request GET \
--url https://api.zerion.io/v1/wallet-sets/charts/{chart_period} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.zerion.io/v1/wallet-sets/charts/{chart_period}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.zerion.io/v1/wallet-sets/charts/{chart_period}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zerion.io/v1/wallet-sets/charts/{chart_period}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"links": {
"self": "https://api.zerion.io/v1/wallet-sets/charts/week?addresses=0x42b9df65b219b3dd36ff330a4dd8f327a6ada990%2C8BH9pjtgyZDC4iAQH5ZiYDZ1MDWC98xki2V8NzqqKW3K¤cy=eth&filter%5Bchain_ids%5D=ethereum%2Csolana"
},
"data": {
"type": "wallet_chart",
"id": "0x42b9df65b219b3dd36ff330a4dd8f327a6ada990,8BH9pjtgyZDC4iAQH5ZiYDZ1MDWC98xki2V8NzqqKW3K-week",
"attributes": {
"begin_at": "2023-01-18T11:00:00Z",
"end_at": "2023-01-25T10:30:00Z",
"points": [
[
1674039600,
1145.00999
]
]
}
}
}{
"errors": [
{
"title": "Parameter is malformed",
"detail": "Some validation errors will be described here"
}
]
}{
"errors": [
{
"title": "Unauthorized Error",
"detail": "The API key is invalid, please, make sure that you are using a valid key"
}
]
}{
"errors": [
{
"title": "Too many requests",
"detail": "Your request had been throttled"
}
]
}Authorizations
Path Parameters
Chart period. Determines both the time window covered and the spacing
between chart points (points). Each period samples the window at a fixed
interval, so the number of points is roughly constant (~290–460) regardless
of period:
| Period | Point interval | Time window |
|---|---|---|
hour | 10 seconds | last 1 hour |
day | 5 minutes | last 24 hours |
week | 30 minutes | last 7 days |
month | 2 hours | last 30 days |
3months | 6 hours | last 90 days |
6months | 12 hours | last 180 days |
year | 1 day | last 365 days |
5years | 4 days | last 5 years |
max | varies | full available history |
Point counts are approximate, and begin_at / end_at are aligned to the
interval. For max, the interval is derived from the amount of available
history (targeting ~400 points), so it varies; for wallet and wallet-set
charts the spacing is at least 1 day.
hour, day, week, month, 3months, 6months, year, 5years, max 3 - 7Query Parameters
A list of wallet addresses forming a wallet set. example: 0x42b9df65b219b3dd36ff330a4dd8f327a6ada990,8BH9pjtgyZDC4iAQH5ZiYDZ1MDWC98xki2V8NzqqKW3K
The set must contain at least one address and may include at most one address per supported chain type (currently EVM and Solana). The order of addresses does not matter.
Returns 400 if an address in the set is not one Zerion tracks, such as a token contract, router or exchange hot wallet.
1 - 2 elementsDenominated currency value of returned prices
eth, btc, usd, eur, krw, rub, gbp, aud, cad, inr, jpy, nzd, try, zar, cny, chf Chart only the balance on these chains (comma-separated list). Only chains reporting both supports_transactions and supports_positions in the flags of GET /v1/chains/ are accepted here. Naming a chain that fails that gate returns 400 rather than an empty result, with detail reading chain <id> does not support charts (for example chain bob does not support charts). A chain of the wrong network family for the wallet set's addresses is rejected the same way, with does not support this wallet address type. When the filter is omitted, chains that fail the gate are left out of data silently, with no error and no meta signal.
25["aurora"]
Chart only the balance of these fungible IDs (comma-separated list). Can't be combined with filter[exclude_fungible_ids]. Passing both returns 400.
2544Leave these fungible IDs out of the chart (comma-separated list). Use it when the set to drop is smaller than the set to keep. Can't be combined with filter[fungible_ids]. Passing both returns 400.
2544Chart only these liquidity pool or vault positions (comma-separated list). Simple token and native-coin balances are left out.
Each protocol takes a different value:
- Uniswap V2 - the LP token contract address, for example
0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc. - Uniswap V3 - the pool contract address, for example
0x4e68ccd3e89f51c3074ca5072bbac773960dfa36. The LP NFT form also works and selects the same position. - Uniswap V4 - the LP NFT as
<position_manager_address>:<token_id>, for example0xbd216513d74c8cf14cf4747e6aaa6420ff64ee9e:229217.token_idmust be a canonical unsigned 256-bit decimal: digits only, no leading zeros, from0through2^256 - 1(115792089237316195423570985008687907853269984665640564039457584007913129639935) inclusive. Invalid or out-of-range values return400. Raw V4 pool IDs are 32-byte hashes, not contract addresses, and return400. - ERC-4626 vaults (for example Morpho) - the vault contract address.
Get these values from the positions endpoint with filter[positions]=no_filter. attributes.pool_address holds the pool contract address, attributes.receipt.fungible_info.implementations[].address the LP token or vault share address, and attributes.receipt.nft_info the LP NFT's contract_address and token_id. Join those two with a colon.
Addresses are case-insensitive. A syntactically valid address that matches none of the wallet's positions isn't an error: the response is 200 with an all-zero series.
These are protocol positions, so combining this filter with filter[positions]=only_simple returns 400. If filter[positions] is omitted, it defaults to no_filter instead of only_simple, so the selected positions are charted. Can't be combined with filter[exclude_pool_addresses]: passing both returns 400.
25121Leave these liquidity pool or vault positions out of the chart (comma-separated list). The rest of the portfolio, simple balances included, is kept.
Values take the same form as in filter[pool_addresses]: the Uniswap V2 LP token address, the Uniswap V3 pool contract address, the Uniswap V4 LP NFT as <position_manager_address>:<token_id>, or the ERC-4626 vault address. All come from the positions endpoint and are case-insensitive. A syntactically valid address that matches none of the wallet's positions excludes nothing and returns 200. A raw V4 pool ID returns 400. token_id must be a canonical unsigned 256-bit decimal: digits only, no leading zeros, from 0 through 2^256 - 1 (115792089237316195423570985008687907853269984665640564039457584007913129639935) inclusive. Invalid or out-of-range values return 400.
These are protocol positions, so combining this filter with filter[positions]=only_simple returns 400: only_simple already drops every protocol position, so the exclusion would do nothing. If filter[positions] is omitted, it defaults to no_filter instead of only_simple. Can't be combined with filter[pool_addresses]: passing both returns 400.
25121Which positions count toward the chart. Defaults to only_simple.
only_simple- tokens and native coins held directly in the wallet. DeFi protocol positions are left out.only_complex- DeFi protocol positions only, such as liquidity pool and vault positions.no_filter- both simple and protocol positions.
Supported protocols today: Uniswap V2, V3 and V4 liquidity positions and ERC-4626 vault positions (for example Morpho). More are being added.
With filter[pool_addresses] or filter[exclude_pool_addresses] and no filter[positions], the default is no_filter instead: pool filters select protocol positions, so only_simple would make them do nothing.
only_simple, only_complex, no_filter Was this page helpful?