Skip to main content

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

// 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",
);
View in React SDK Documentation

View Unrevealed Batches

const batches = await contract.revealer.getBatchesToReveal();
View in React SDK Documentation

Reveal Hidden NFTs

// the batch to reveal
const batchId = 0;
// reveal the batch
await contract.revealer.reveal(batchId, "my secret password");
View in React SDK Documentation