|
4 | 4 |
|
5 | 5 |
|
6 | 6 |
|
7 |
| -BASE: ERC721Base EXTENSION: LazyMint, DelayedReveal The `ERC721DelayedReveal` contract uses the `ERC721Base` contract, along with the `LazyMint` and `DelayedReveal` extension. 'Lazy minting' means defining the metadata of NFTs without minting it to an address. Regular 'minting' of NFTs means actually assigning an owner to an NFT. As a contract admin, this lets you prepare the metadata for NFTs that will be minted by an external party, without paying the gas cost for actually minting the NFTs. 'Delayed reveal' is a mechanism by which you can distribute NFTs to your audience and reveal the metadata of the distributed NFTs, after the fact. You can read more about how the `DelayedReveal` extension works, here: https://blog.thirdweb.com/delayed-reveal-nfts |
| 7 | +BASE: ERC721LazyMint EXTENSION: DelayedReveal The `ERC721DelayedReveal` contract uses the `ERC721LazyMint` contract, along with `DelayedReveal` extension. 'Lazy minting' means defining the metadata of NFTs without minting it to an address. Regular 'minting' of NFTs means actually assigning an owner to an NFT. As a contract admin, this lets you prepare the metadata for NFTs that will be minted by an external party, without paying the gas cost for actually minting the NFTs. 'Delayed reveal' is a mechanism by which you can distribute NFTs to your audience and reveal the metadata of the distributed NFTs, after the fact. You can read more about how the `DelayedReveal` extension works, here: https://blog.thirdweb.com/delayed-reveal-nfts |
8 | 8 |
|
9 | 9 |
|
10 | 10 |
|
@@ -49,40 +49,38 @@ function balanceOf(address owner) external view returns (uint256)
|
49 | 49 | |---|---|---|
|
50 | 50 | | _0 | uint256 | undefined |
|
51 | 51 |
|
52 |
| -### batchMintTo |
| 52 | +### burn |
53 | 53 |
|
54 | 54 | ```solidity
|
55 |
| -function batchMintTo(address _to, uint256 _quantity, string, bytes _data) external nonpayable |
| 55 | +function burn(uint256 _tokenId) external nonpayable |
56 | 56 | ```
|
57 | 57 |
|
58 |
| -Lets an authorized address mint multiple lazy minted NFTs at once to a recipient. |
| 58 | +Lets an owner or approved operator burn the NFT of the given tokenId. |
59 | 59 |
|
60 |
| -*The logic in the `_canMint` function determines whether the caller is authorized to mint NFTs.* |
| 60 | +*ERC721A's `_burn(uint256,bool)` internally checks for token approvals.* |
61 | 61 |
|
62 | 62 | #### Parameters
|
63 | 63 |
|
64 | 64 | | Name | Type | Description |
|
65 | 65 | |---|---|---|
|
66 |
| -| _to | address | The recipient of the NFT to mint. | |
67 |
| -| _quantity | uint256 | The number of NFTs to mint. | |
68 |
| -| _2 | string | undefined | |
69 |
| -| _data | bytes | Additional data to pass along during the minting of the NFT. | |
| 66 | +| _tokenId | uint256 | The tokenId of the NFT to burn. | |
70 | 67 |
|
71 |
| -### burn |
| 68 | +### claim |
72 | 69 |
|
73 | 70 | ```solidity
|
74 |
| -function burn(uint256 _tokenId) external nonpayable |
| 71 | +function claim(address _receiver, uint256 _quantity) external payable |
75 | 72 | ```
|
76 | 73 |
|
77 |
| -Lets an owner or approved operator burn the NFT of the given tokenId. |
| 74 | +Lets an address claim multiple lazy minted NFTs at once to a recipient. Contract creators should override this function to create custom logic for claiming, for e.g. price collection, allowlist, max quantity, etc. |
78 | 75 |
|
79 |
| -*ERC721A's `_burn(uint256,bool)` internally checks for token approvals.* |
| 76 | +*The logic in the `verifyClaim` function determines whether the caller is authorized to mint NFTs.* |
80 | 77 |
|
81 | 78 | #### Parameters
|
82 | 79 |
|
83 | 80 | | Name | Type | Description |
|
84 | 81 | |---|---|---|
|
85 |
| -| _tokenId | uint256 | The tokenId of the NFT to burn. | |
| 82 | +| _receiver | address | The recipient of the NFT to mint. | |
| 83 | +| _quantity | uint256 | The number of NFTs to mint. | |
86 | 84 |
|
87 | 85 | ### contractURI
|
88 | 86 |
|
@@ -294,29 +292,6 @@ function isApprovedForAll(address owner, address operator) external view returns
|
294 | 292 | |---|---|---|
|
295 | 293 | | _0 | bool | undefined |
|
296 | 294 |
|
297 |
| -### isApprovedOrOwner |
298 |
| - |
299 |
| -```solidity |
300 |
| -function isApprovedOrOwner(address _operator, uint256 _tokenId) external view returns (bool isApprovedOrOwnerOf) |
301 |
| -``` |
302 |
| - |
303 |
| -Returns whether a given address is the owner, or approved to transfer an NFT. |
304 |
| - |
305 |
| - |
306 |
| - |
307 |
| -#### Parameters |
308 |
| - |
309 |
| -| Name | Type | Description | |
310 |
| -|---|---|---| |
311 |
| -| _operator | address | undefined | |
312 |
| -| _tokenId | uint256 | undefined | |
313 |
| - |
314 |
| -#### Returns |
315 |
| - |
316 |
| -| Name | Type | Description | |
317 |
| -|---|---|---| |
318 |
| -| isApprovedOrOwnerOf | bool | undefined | |
319 |
| - |
320 | 295 | ### isEncryptedBatch
|
321 | 296 |
|
322 | 297 | ```solidity
|
@@ -363,23 +338,6 @@ Lets an authorized address lazy mint a given amount of NFTs.
|
363 | 338 | |---|---|---|
|
364 | 339 | | batchId | uint256 | A unique integer identifier for the batch of NFTs lazy minted together. |
|
365 | 340 |
|
366 |
| -### mintTo |
367 |
| - |
368 |
| -```solidity |
369 |
| -function mintTo(address _to, string) external nonpayable |
370 |
| -``` |
371 |
| - |
372 |
| -Lets an authorized address mint a lazy minted NFT to a recipient. |
373 |
| - |
374 |
| -*The logic in the `_canMint` function determines whether the caller is authorized to mint NFTs.* |
375 |
| - |
376 |
| -#### Parameters |
377 |
| - |
378 |
| -| Name | Type | Description | |
379 |
| -|---|---|---| |
380 |
| -| _to | address | The recipient of the NFT to mint. | |
381 |
| -| _1 | string | undefined | |
382 |
| - |
383 | 341 | ### multicall
|
384 | 342 |
|
385 | 343 | ```solidity
|
@@ -419,6 +377,23 @@ function name() external view returns (string)
|
419 | 377 | |---|---|---|
|
420 | 378 | | _0 | string | undefined |
|
421 | 379 |
|
| 380 | +### nextTokenIdToClaim |
| 381 | + |
| 382 | +```solidity |
| 383 | +function nextTokenIdToClaim() external view returns (uint256) |
| 384 | +``` |
| 385 | + |
| 386 | +The tokenId assigned to the next new NFT to be claimed. |
| 387 | + |
| 388 | + |
| 389 | + |
| 390 | + |
| 391 | +#### Returns |
| 392 | + |
| 393 | +| Name | Type | Description | |
| 394 | +|---|---|---| |
| 395 | +| _0 | uint256 | undefined | |
| 396 | + |
422 | 397 | ### nextTokenIdToMint
|
423 | 398 |
|
424 | 399 | ```solidity
|
@@ -739,6 +714,23 @@ function transferFrom(address from, address to, uint256 tokenId) external nonpay
|
739 | 714 | | to | address | undefined |
|
740 | 715 | | tokenId | uint256 | undefined |
|
741 | 716 |
|
| 717 | +### verifyClaim |
| 718 | + |
| 719 | +```solidity |
| 720 | +function verifyClaim(address _claimer, uint256 _quantity) external view |
| 721 | +``` |
| 722 | + |
| 723 | +Override this function to add logic for claim verification, based on conditions such as allowlist, price, max quantity etc. |
| 724 | + |
| 725 | +*Checks a request to claim NFTs against a custom condition.* |
| 726 | + |
| 727 | +#### Parameters |
| 728 | + |
| 729 | +| Name | Type | Description | |
| 730 | +|---|---|---| |
| 731 | +| _claimer | address | Caller of the claim function. | |
| 732 | +| _quantity | uint256 | The number of NFTs being claimed. | |
| 733 | + |
742 | 734 |
|
743 | 735 |
|
744 | 736 | ## Events
|
|
0 commit comments