curl --request GET \
--url https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts', 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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"nftId": "nft_abc123",
"name": "Cool NFT #1",
"description": "A cool NFT",
"imageUrl": "https://example.com/nft.png",
"chainId": "eip155:1",
"contractAddress": "0x1234567890abcdef1234567890abcdef12345678",
"tokenId": "1",
"collection": {
"name": "Cool Collection",
"description": "A collection of cool NFTs",
"imageUrl": "https://example.com/collection.png"
},
"rarity": {
"rank": 100,
"score": 85.5
},
"floorPrice": "0.5",
"detailedInfo": {
"ownerCount": 5000,
"tokenCount": 10000,
"attributes": [],
"owners": []
}
}
]{
"error": "<string>"
}Get wallet NFTs
Retrieves all NFTs owned by the client’s wallet on the specified chain. Only returns results for EVM (EIP-155) chains. Returns an empty array for non-EVM chains.
curl --request GET \
--url https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts', 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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.portalhq.io/api/v3/clients/me/chains/{chain}/assets/nfts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"nftId": "nft_abc123",
"name": "Cool NFT #1",
"description": "A cool NFT",
"imageUrl": "https://example.com/nft.png",
"chainId": "eip155:1",
"contractAddress": "0x1234567890abcdef1234567890abcdef12345678",
"tokenId": "1",
"collection": {
"name": "Cool Collection",
"description": "A collection of cool NFTs",
"imageUrl": "https://example.com/collection.png"
},
"rarity": {
"rank": 100,
"score": 85.5
},
"floorPrice": "0.5",
"detailedInfo": {
"ownerCount": 5000,
"tokenCount": 10000,
"attributes": [],
"owners": []
}
}
]{
"error": "<string>"
}Authorizations
Client API Key or Client Session Token (CST). Pass as a Bearer token in the Authorization header.
Path Parameters
The blockchain chain identifier. Use either a friendly name or CAIP-2 format.
When using CAIP-2 format in URLs, ensure the colon (:) is URI-encoded as %3A.
Supported chains:
ethereum(eip155:1)sepolia(eip155:11155111)base(eip155:8453)base-sepolia(eip155:84532)polygon(eip155:137)polygon-mumbai(eip155:80001)celo(eip155:42220)celo-alfajores(eip155:44787)monad(eip155:143)monad-testnet(eip155:10143)solana(solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp)solana-devnet(solana:EtWTRABZaYq6iMfeYKouRu166VU2xqa1)tron(tron:mainnet)tron-nile(tron:nile)tron-shasta(tron:shasta)stellar(stellar:pubnet)stellar-testnet(stellar:testnet)bitcoin-segwit(bip122:000000000019d6689c085ae165831e93-p2wpkh)bitcoin-segwit-testnet(bip122:000000000933ea01ad0ee984209779ba-p2wpkh)bitcoin-p2wpkh(bip122:000000000019d6689c085ae165831e93-p2wpkh)bitcoin-p2wpkh-testnet(bip122:000000000933ea01ad0ee984209779ba-p2wpkh)
Response
NFTs retrieved successfully
Unique NFT identifier.
NFT name.
NFT description.
URL of the NFT image.
CAIP-2 chain ID where the NFT lives.
NFT contract address.
Token ID within the contract.
Show child attributes
Show child attributes
Last sale information, if available.
Show child attributes
Show child attributes
Current floor price for the collection.
Show child attributes
Show child attributes
Was this page helpful?