ERC1155 Standard
You can utilize these features of the SDK if your contract implements the ERC1155 standard.
View NFT Balance
Get a wallet's NFT balance (number of NFTs in this contract owned by the wallet) for a specific token ID.
- React
- Javascript
- Python
- Go
- Unity
// Address of the wallet to check NFT balance
const walletAddress = "{{wallet_address}}";
const tokenId = 0; // Id of the NFT to check
const balance = await contract.erc1155.balanceOf(walletAddress, tokenId);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in React SDK Documentation// Address of the wallet to check NFT balance
const walletAddress = "{{wallet_address}}";
const tokenId = 0; // Id of the NFT to check
const balance = await contract.erc1155.balanceOf(walletAddress, tokenId);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in Javascript SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Python SDK documentation for more information.
Reach out on Discord for further assistance!
View Python SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Go SDK documentation for more information.
Reach out on Discord for further assistance!
View Go SDK Documentation// Address of the wallet to check NFT balance
var walletAddress = "{{wallet_address}}";
var tokenId = "0"; // Id of the NFT to check
var balance = await contract.ERC1155.BalanceOf(walletAddress, tokenId);
Get NFT Metadata
Read the URI this NFT points to and fetch that data automatically.
If the metadata is stored on IPFS, this function uses our IPFS gateway (or the one you specify) to read the data.
- React
- Javascript
- Python
- Go
- Unity
const nft = await contract.erc1155.get(0);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in React SDK Documentationconst nft = await contract.erc1155.get(0);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in Javascript SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Python SDK documentation for more information.
Reach out on Discord for further assistance!
View Python SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Go SDK documentation for more information.
Reach out on Discord for further assistance!
View Go SDK Documentationvar tokenId = "0";
var nft = await contract.ERC1155.Get(tokenId);
Transfer NFTs
Transfer an NFT from the connected wallet to another wallet.
- React
- Javascript
- Python
- Go
- Unity
// Address of the wallet you want to send the NFT to
const toAddress = "{{wallet_address}}";
const tokenId = "0"; // The token ID of the NFT you want to send
const amount = 3; // How many copies of the NFTs to transfer
await contract.erc1155.transfer(toAddress, tokenId, amount);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in React SDK Documentation// Address of the wallet you want to send the NFT to
const toAddress = "{{wallet_address}}";
const tokenId = "0"; // The token ID of the NFT you want to send
const amount = 3; // How many copies of the NFTs to transfer
await contract.erc1155.transfer(toAddress, tokenId, amount);
This snippet is for v3 of the SDK. Learn how to upgrade.
View in Javascript SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Python SDK documentation for more information.
Reach out on Discord for further assistance!
View Python SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Go SDK documentation for more information.
Reach out on Discord for further assistance!
View Go SDK Documentation// Address of the wallet you want to send the NFT to
var toAddress = "{{wallet_address}}";
var tokenId = "0"; // The token ID of the NFT you want to send
var amount = 3; // How many copies of the NFTs to transfer
await contract.ERC1155.Transfer(toAddress, tokenId, amount);
Airdrop NFTs
Transfer NFTs to a list of wallets in one transaction.
- React
- Javascript
- Python
- Go
- Unity
This feature is missing a code snippet or might not be supported yet.
Check the React SDK documentation for more information.
Reach out on Discord for further assistance!
View React SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Javascript SDK documentation for more information.
Reach out on Discord for further assistance!
View Javascript SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Python SDK documentation for more information.
Reach out on Discord for further assistance!
View Python SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Go SDK documentation for more information.
Reach out on Discord for further assistance!
View Go SDK DocumentationThis feature is missing a code snippet or might not be supported yet.
Check the Unity SDK documentation for more information.
Reach out on Discord for further assistance!
View Unity SDK Documentation