getNFT
Get NFT metadata by contract address and token id
import { Insight } from "thirdweb"; const nft = await Insight.getNFT({ client, chain: sepolia, contractAddress: "0x1234567890123456789012345678901234567890", tokenId: 1n,});
function getNFT(args: { chain: Readonly; contractAddress: string; includeOwners?: boolean; queryOptions?: { chain?: unknown; include_owners?: "false" | "true"; }; tokenId: string | number | bigint;
let args: { chain: Readonly; contractAddress: string; includeOwners?: boolean; queryOptions?: { chain?: unknown; include_owners?: "false" | "true"; }; tokenId: string | number | bigint;};
let returnType: | { chainId: number; id: bigint; owner: string | null; tokenAddress: string; tokenURI: string; type: "ERC721"; } | { chainId: number; id: bigint; owner: string | null; supply: bigint; tokenAddress: string; tokenURI: string; type: "ERC1155"; };