nft_uri
Returns URI of the token id.
You can specify the contract address and ID of the NFT, then you can obtain the original URI information.
Supported on Ethereum, BNB Chain, Optimism, and Arbitrum.

Parameters

Object - An object with the following fields (required):
  • contractAddress(hex string, required) - the contract address of the collection. BlockVision currently support both ERC721 and ERC1155.
  • tokenId(string, required) - id of the NFT.
  • blockNumber(integer number, optional) - specify the blockNumber for snapshot query (default latest). BlockVision can not only support users to query the current position, but also support users to query the historical information at any time.

Returns

Object - An object with the following fields:
  • id(integer number) - json-rpc id.
  • jsonrpc(string) - json-rpc version
  • result(string) - URI of the NFT.

Example

Request

curl https://api.blockvision.org/v1/<api key> \
-X POST \
-H "Content-Type: application/json" \
-d '{
"id": 1,
"jsonrpc": "2.0",
"method": "nft_uri",
"params": {
"contractAddress": "0x495f947276749Ce646f68AC8c248420045cb7b5e",
"tokenID": "49130440647659772150626580756595337563119039889199175888700692953658833240065",
"blockNumber": 0
}
}'

Result

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"URI": "ipfs://QmSnQ4CKfkmUx9bs8yTymmU1nDBkboCWCV2LN33UdDR2XT/1"
}
}
Copy link
Outline
Parameters
Returns
Example
Request
Result