Skip to main content

DropErc1155ClaimConditions.setBatch() method

Set claim conditions on multiple NFTs at once

Example

const claimConditionsForTokens = [
{
tokenId: 0,
claimConditions: [
{
startTime: new Date(), // start the claim phase now
maxQuantity: 2, // limit how many mints for this tokenId
price: 0.01, // price for this tokenId
snapshot: ["0x...", "0x..."], // limit minting to only certain addresses
},
],
},
{
tokenId: 1,
claimConditions: [
{
startTime: new Date(),
price: 0.08, // different price for this tokenId
},
],
},
];

await dropContract.claimConditions.setBatch(claimConditionsForTokens);

Signature:

setBatch(claimConditionsForToken: ClaimConditionsForToken[], resetClaimEligibilityForAll?: boolean): Promise<{
receipt: ethers.providers.TransactionReceipt;
}>;

Parameters

ParameterTypeDescription
claimConditionsForTokenClaimConditionsForToken[]The claim conditions for each NFT
resetClaimEligibilityForAllboolean(Optional) Whether to reset the state of who already claimed NFTs previously

Returns:

Promise<{ receipt: ethers.providers.TransactionReceipt; }>

Remarks

Sets the claim conditions that need to be fulfilled by users to claim the given NFTs in this contract.