POST getNFTCollectionBatch

Get collection data for multiple NFT contract addresses.

How to use getNFTCollectionBatch method ?

Below, you'll find an in-depth guide that provides a comprehensive explanation of how to utilize the getNFTCollectionBatch method effectively using Blast.

Parameters

Below, you can find the query parameters accepted by the method.

ParameterTypeDescription

contractAddress*

array<string>

The NFT contract addresses

Returns

ParameterTypeDescription

count

number

Number of records returned in the current page

contractAddress

string

The contract address of the NFT collection

contractName

string

The contract name of the NFT collection

contractSymbol

string

The symbol of the NFT collection contract

contractType

string

The type of contract governing the NFT collection

deployBlockNumber

number

The block number at which the NFT collection contract was deployed

totalSupply

string

The total supply of NFTs in the collection.

numberOfOwners

number

The total number of unique owners of NFTs in the collection

numberOfDistinctTokens

number

The number of unique NFTs (distinct tokens) within the collection

numberOfTransfers

number

The total number of transfers

walletBalance

NFTBalance object(optional)

The balance information associated with the owner of the collection (see getNFTCollectionBatch method for more details)

description

string

A description providing further details about the NFT collection, if available

website

string

The website associated with the NFT collection, if available

cachedBanner

CachedMedia object

An object containing cached banner media data for the collection, if available

cachedLogo

CachedMedia object

An object containing cached logo media data for the collection, if available

Example Request and Result for getNFTCollectionBatch

In this section, you can find an illustrative example of a request made to retrieve the collection data for multiple NFT objects using the getNFTCollectionBatch 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 array of NFTCollection objects

POST https://starknet-mainnet.blastapi.io/<project_id>/builder/getNFTCollectionBatch

Query Parameters

NameTypeValue

contractAddresses

String

{"contractAddresses":[{"contractAddress":"0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af"},{"contractAddress":"0x076503062d78f4481be03c9145022d6a4a71ec0719aa07756f79a2384dc7ef16"}]}
{
  "count": 2,
  "collections": [
    {
      "contractAddress": "0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af",
      "contractName": "Starknet.id",
      "contractSymbol": "ID",
      "contractType": "erc721",
      "deployBlockNumber": 10553,
      "totalSupply": "4316985",
      "numberOfDistinctTokens": 4316957,
      "numberOfOwners": 1681152,
      "numberOfTransfers": 4612580,
      "description": "Identity and naming service for #starknet  Mint your identity and choose\nyour .stark domain now",
      "website": "app.starknet.id",
      "cachedBanner": {
        "mimetype": "image/png",
        "size": 25233,
        "url": "https://builder-assets.blastapi.io/6fcc83fb5997352765cba618c189abb7903b339e"
      },
      "cachedLogo": {
        "mimetype": "image/png",
        "size": 333150,
        "url": "https://builder-assets.blastapi.io/e8675f17e8034cede40f94a38bdc552b2914c942"
      }
    },
    {
      "contractAddress": "0x076503062d78f4481be03c9145022d6a4a71ec0719aa07756f79a2384dc7ef16",
      "contractName": "Starknet Quest",
      "contractSymbol": "SKQ",
      "contractType": "erc721",
      "deployBlockNumber": 49783,
      "totalSupply": "2931421",
      "numberOfDistinctTokens": 2931369,
      "numberOfOwners": 613051,
      "numberOfTransfers": 3066796,
      "description": "Starknet Quest - The Collection of your Starknet achievements",
      "website": "starknet.quest",
      "cachedBanner": {
        "mimetype": "image/png",
        "size": 112592,
        "url": "https://builder-assets.blastapi.io/52bfd7312718883255956cfa40ff9e04ff5d2551"
      },
      "cachedLogo": {
        "mimetype": "image/png",
        "size": 41804,
        "url": "https://builder-assets.blastapi.io/5a4341bbb52570c0c97c836b573e953178b0243e"
      }
    }
  ]
}
curl -X POST https://starknet-mainnet.blastapi.io/5<project-id>/builder/getNFTCollectionBatch? \
-H 'Content-Type: application/json' \-d '{"contractAddresses":[{"contractAddress":"0x05dbdedc203e92749e2e746e2d40a768d966bd243df04a6b712e222bc040a9af"},{"contractAddress":"0x076503062d78f4481be03c9145022d6a4a71ec0719aa07756f79a2384dc7ef16"}]}' \

Last updated