Skip to main content

qn_fetchNFTs RPC Method

Returns aggregated data on NFTs for a given wallet.

Updated on
Feb 6, 2024

qn_fetchNFTs RPC Method

Please note that the qn_fetchNFTs method will be phased out in the future. We strongly recommend migrating to the Solana DAS API for better features and improved performance.

Parameters

object
object
Custom Object with the following fields:
wallet
string
The wallet address to check for NFTs
omitFields
string
Optionally omit specific properties of objects from the assets array of the response. Any property of the asset object can be omitted. If omitFields is not included in the request, response will return all available fields by default
page
integer
The page number you would like returned. Page numbers start at 1 and end at totalPages. If omitted, defaults to the first page (page 1). If the page number requested is less than 1 or higher than totalPages, an empty assets array will be returned
perPage
integer
The maximum amount of NFT assets to return on each page. You can request up to 40 items per page. If omitted, defaults to 20 items per page

Returns

Object
object
Custom Response Object, or null if no NFTs are found:
owner
The wallet address we checked for NFTs
assets
An array of objects representing NFTs with the following shape:
name
The name of this specific NFT
tokenAddress
The token address of this NFT in its collection
collectionName
The name of this NFT's collection
imageUrl
The URL where the image for this NFT can be seen
collectionAddress
The contract address that this NFT lives in
traits
An array of traits that this NFT has
creators
An array of creator addresses for this NFT token
chain
The chain this aggregation happened on
network
The network this aggregation happened on
description
The description of this NFT token
symbol
The symbol for this NFT token
external_url
The external URL for this NFT token
provenance
An array of transfers from previous owners for this NFT. It's important to note that this only has owners from recent blocks, for full ownership history, you'll need to enable the archive add on. This is only available for select customers at this time
totalItems
The total number of results
totalPages
The total number of results pages available
pageNumber
The page number of results that was returned with this response
Request
1
curl https://docs-demo.solana-mainnet.quiknode.pro/ \
2
-X POST \
3
-H "Content-Type: application/json" \
4
-H "x-qn-api-version: 1" \
5
--data '{
6
"id":67,
7
"jsonrpc":"2.0",
8
"method":"qn_fetchNFTs",
9
"params":{
10
"wallet": "DcTmx4VLcf5euAB17nynax7g55xuB3XKBDyz1pudMcjW",
11
"omitFields": [
12
"provenance",
13
"traits"
14
],
15
"page": 1,
16
"perPage": 10
17
}
18
}'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free