Skip to main content

TokenDrop class

Create a Drop contract for a standard crypto token or cryptocurrency.

Example

import { ThirdwebSDK } from "@thirdweb-dev/sdk";

const sdk = new ThirdwebSDK("{{chainName}}");
const contract = sdk.getTokenDrop("{{contract_address}}");

Constructors

ConstructorModifiersDescription
(constructor)(network, address, storage, options, contractWrapper)Constructs a new instance of the TokenDrop class

Properties

PropertyModifiersTypeDescription
claimConditionsDropClaimConditions<DropERC20>Configure claim conditions
contractAbistaticany
contractRolesstaticreadonly ["admin", "transfer"]
contractTypestatic"token-drop"
encoderContractEncoder<DropERC20>
estimatorGasCostEstimator<DropERC20>
metadataContractMetadata<DropERC20, typeof TokenDrop.schema>
platformFeesContractPlatformFee<DropERC20>
rolesContractRoles<DropERC20, typeof TokenDrop.contractRoles[number]>
salesContractPrimarySale<DropERC20>

Methods

MethodModifiersDescription
burnFrom(holder, amount)Burn Tokens
burnTokens(amount)Burn Tokens
claim(amount, checkERC20Allowance)Claim a certain amount of tokens
claimTo(destinationAddress, amount, checkERC20Allowance)Claim a certain amount of tokens to a specific Wallet
getDelegation()Get your voting delegatee address
getDelegationOf(account)Get a specific address voting delegatee address
getVoteBalance()Get your wallet voting power for the current checkpoints
getVoteBalanceOf(account)
isTransferRestricted()Get whether users can transfer tokens from this contract

Signature:

export declare class TokenDrop extends Erc20<DropERC20>

Extends: Erc20<DropERC20