Delayed Reveals
Delayed reveals are a way to show placeholder metadata for NFTs, and use a password to reveal the metadata at a later time.
You store a password that is encrypted on-chain, and later use this same password to reveal the metadata for your NFTs.
For a step-by-step tutorial on how to set up an NFT Drop with delayed reveal, check our guide below:
Create a delayed reveal
- React
- Javascript
- Python
- Go
- Unity
// the real NFTs, these will be encrypted until your reveal them!
const realNFTs = [{
name: "Common NFT #1",
description: "Common NFT, one of many.",
image: fs.readFileSync("path/to/image.png"),
}, {
name: "Super Rare NFT #2",
description: "You got a Super Rare NFT!",
image: fs.readFileSync("path/to/image.png"),
}];
// A placeholder NFT that people will get immediately in their wallet, until the reveal happens!
const placeholderNFT = {
name: "Hidden NFT",
description: "Will be revealed next week!"
};
// Create and encrypt the NFTs
await contract.revealer.createDelayedRevealBatch(
placeholderNFT,
realNFTs,
"my secret password",
);
// the real NFTs, these will be encrypted until your reveal them!
const realNFTs = [{
name: "Common NFT #1",
description: "Common NFT, one of many.",
image: fs.readFileSync("path/to/image.png"),
}, {
name: "Super Rare NFT #2",
description: "You got a Super Rare NFT!",
image: fs.readFileSync("path/to/image.png"),
}];
// A placeholder NFT that people will get immediately in their wallet, until the reveal happens!
const placeholderNFT = {
name: "Hidden NFT",
description: "Will be revealed next week!"
};
// Create and encrypt the NFTs
await contract.revealer.createDelayedRevealBatch(
placeholderNFT,
realNFTs,
"my secret password",
);
This feature is missing a code snippet or might not be supported yet.
Check the Python SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Go SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Unity SDK Reference for more information.
Reach out on Discord for further assistance!
View Unrevealed Batches
- React
- Javascript
- Python
- Go
- Unity
const batches = await contract.revealer.getBatchesToReveal();
const batches = await contract.revealer.getBatchesToReveal();
This feature is missing a code snippet or might not be supported yet.
Check the Python SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Go SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Unity SDK Reference for more information.
Reach out on Discord for further assistance!
Reveal Hidden NFTs
- React
- Javascript
- Python
- Go
- Unity
// the batch to reveal
const batchId = 0;
// reveal the batch
await contract.revealer.reveal(batchId, "my secret password");
// the batch to reveal
const batchId = 0;
// reveal the batch
await contract.revealer.reveal(batchId, "my secret password");
This feature is missing a code snippet or might not be supported yet.
Check the Python SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Go SDK Reference for more information.
Reach out on Discord for further assistance!
This feature is missing a code snippet or might not be supported yet.
Check the Unity SDK Reference for more information.
Reach out on Discord for further assistance!