burn
Description
This function burns an ERC721 token with the specified token ID.
Parameters
| Name | Type | Description |
|---|---|---|
| tokenId | number | The ID of the token to burn. |
| overrides? | Overrides | Optional overrides for the contract call. |
Example
import { ContractType } from "@openformat/sdk";
const contract = sdk.getContract({
contractAddress: "0x123...",
type: ContractType.NFT,
});
const tokenId = 5;
const tx = await contract.burn({ tokenId: nextId });