getwalletnftcollections-1
description: Get all NFTs minted by the given wallet address.
getWalletMintedNFTs
How to use getWalletMintedNFTs method ?
Below, you'll find an in-depth guide that provides a comprehensive explanation of how to utilize the getWalletMintedNFTs method effectively using Blast.
Parameters
Below, you can find the query parameters accepted by the method.
Parameter | Type | Description |
---|---|---|
walletAddress* | string | The wallet address of the owner |
contractAddress | string | The contract address for the NFT contract |
pageSize | number | Maximum number of records to be retrieved in one page (max 100, default 25) |
pageKey | string | Key used to get the next page of results. Must be set to the value of nextPageKey returned in the previous response |
Returns
Parameter | Type | Description |
---|---|---|
count | number | Number of records returned in the current page |
nextPageKey | string | Key used to get the next page of results |
nfts | array<object> | array of NFT objects (see the getNFT method for more details) |
This API is paginated, response items are ordered descending by:
- blockNumber
- transferIndex
Example Request and Result for getWalletMintedNFTs
In this section, you can find an illustrative example of a request made to retrieve all NFTs minted by the given wallet address using the getWalletMintedNFTs method.
The example in this section uses a non-existing project id.
Make sure you replace it with your Starknet endpoint when issuing the Builder API calls.
Don't have a project id? Here's a straightforward guide on how to obtain one!
Returns all NFTs currently owned by a wallet.
GET
https://starknet-mainnet.blastapi.io/<project_id>/builder/getWalletMintedNFTs?
Query Parameters
Name | Type | Value |
---|---|---|
walletAddress | string |
|
contractAddress | string |
|
pageSize | number |
|
- 200: OK
{
"count": 2,
"nextPageKey": "Y2ZiNjA3ZDBiNjFiOjE3MTIzMTYzMzc6MzE4MDEwOjM1Mg",
"nfts": [
{
"contractAddress": "0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af",
"contractName": "Starknet.id",
"contractSymbol": "ID",
"contractType": "erc721",
"tokenId": "552582037414",
"minterAddress": "0x031c0b3ce1e629066ff59578f212a1bd2db6efda0788d718fb5303df90292772",
"mintBlockNumber": 318010,
"mintTimestamp": 1697176956,
"mintTransactionHash": "0x05d211557dd0060193bfba54b02af137f0ab31883911d33a5be993b9bdc06708",
"numberOfTokens": "1",
"numberOfOwners": "1",
"ownerAddress": "0x02ec66430784311624108a43e18c6f4def7c29a40113a17048be8d87d0d5a02a",
"tokenUri": "https://api.starknet.id/uri?id=552582037414",
"tokenMetadata": "{\"name\":\"Starknet ID: 552582037414\",\"description\":\"This token represents an identity on StarkNet.\",\"image\":\"https://starknet.id/api/identicons/552582037414\",\"expiry\":null,\"attributes\":null}",
"name": "Starknet ID: 552582037414",
"description": "This token represents an identity on StarkNet.",
"attributes": null,
"externalLink": null,
"imageUrl": "https://starknet.id/api/identicons/552582037414",
"animationUrl": null,
"cachedImage": null,
"cachedThumbnail": null
},
{
"contractAddress": "0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af",
"contractName": "Starknet.id",
"contractSymbol": "ID",
"contractType": "erc721",
"tokenId": "171234871067",
"minterAddress": "0x031c0b3ce1e629066ff59578f212a1bd2db6efda0788d718fb5303df90292772",
"mintBlockNumber": 318010,
"mintTimestamp": 1697176956,
"mintTransactionHash": "0x025cbb440b9b4cf3ee932ff9e68a97b82084ec29b30b11e9dd0a7d9fdbf23895",
"numberOfTokens": "1",
"numberOfOwners": "1",
"ownerAddress": "0x005ecc57ba6460f3f66df245af39ce6d842b6ecea3a04b024ee8ac29c8eedf77",
"tokenUri": "https://api.starknet.id/uri?id=171234871067",
"tokenMetadata": "{\"name\":\"Starknet ID: 171234871067\",\"description\":\"This token represents an identity on StarkNet.\",\"image\":\"https://starknet.id/api/identicons/171234871067\",\"expiry\":null,\"attributes\":null}",
"name": "Starknet ID: 171234871067",
"description": "This token represents an identity on StarkNet.",
"attributes": null,
"externalLink": null,
"imageUrl": "https://starknet.id/api/identicons/171234871067",
"animationUrl": null,
"cachedImage": null,
"cachedThumbnail": null
}
]
}
curl -X GET https://starknet-mainnet.blastapi.io/<project-id>/builder/getWalletMintedNFTs?walletAddress=0x031c0b3ce1e629066ff59578f212a1bd2db6efda0788d718fb5303df90292772&contractAddress=0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af&pageSize=2 \
-H 'Content-Type: application/json' \