Loading
PRICE DISCUSSION DOCS
APP
Updated 2026-10-12·View as Markdown

For Artists — The Mint Flow

What actually happens on-chain when a Project is deployed and minted. Signatures below are from the deployed contract source; the full references are PDFactory and PDProject.

Deployment

A script of up to 18,429 bytes (one chunk) usually deploys in a single transaction calling the factory:

function createProject(
    string calldata name,
    string calldata symbol,
    uint256 maxSupply,      // 22 to 9,999
    uint256 mintPrice,      // in wei, fixed forever
    uint256 libraryId,      // a blessed on-chain library, or none
    bytes[] calldata scriptChunks,  // your generative script, stored on-chain
    string calldata description,
    string calldata colorway,       // your signature color (six hex chars), or empty
    uint256 expectedInflaterId      // the library unzipper you tested with
) external returns (address project);

That is the whole signature — there is no window parameter, because every Project opens with the same fixed 60-second entry window. You do not choose it, turn it on, or tune it. expectedInflaterId protects you: if the registry's unzipper changed after you tested, the deploy reverts rather than binding code you never previewed.

The factory checks that your wallet is whitelisted, the supply is within bounds, your script fits, and your 60-day cooldown has elapsed, then atomically deploys:

  1. Your PDProject contract — the ERC-721. Your script is stored forever in on-chain data contracts (SSTORE2), which the Project reads it from.
  2. Your PaymentSplitter — the immutable 60/40 splitter that receives the Project's secondary royalties.

The deploying transaction emits ProjectCreated with the new addresses and parameters. From that moment nothing about the Project can be changed — by you, by PD, by anyone.

The script space

Your script, plus the library you bind and its unzipper, gets 1.5 MB on Ethereum. A bigger script goes up in pieces from your own wallet: one stageScriptChunk transaction per chunk, then createProjectFromStaged, which deploys exactly the script you staged and nothing else. If an upload stops partway, it picks up from the last chunk that landed. Each chunk is public on Ethereum as soon as it lands, before the Project exists. The factory reference has the exact rules.

Your wallet pays the gas for storing the script. At today's prices that is roughly 500 gas per byte: a script that fills the whole 1.5 MB takes 87 transactions and about 770 million gas. Ethereum is due to reprice storage, so treat these as today's numbers; your wallet shows the live cost before you sign each one.

What a mint does

Collectors call mint(uint256 quantity) on your Project (up to 22 per transaction). Each mint transaction, atomically:

  1. Checks payment exactly. msg.value must equal mintPrice × quantity plus the per-token storage fee — no overpayment accepted, nothing to refund.
  2. Commits each token to its hash. Token IDs are 1-indexed and sequential. The mint records the block it landed in; the Output's tokenHash is made from that block's hash, which doesn't exist until the block is finished. Nobody can see an outcome during the mint and cancel it, so rare traits can't be fished for. A moment later anyone (PD, in practice) calls reveal, which writes the hash. The caller and the timing can't change it. See Writing for the Chain.
  3. Pays everyone immediately. 95% of the mint price goes to your wallet and 5% to the platform wallet in the same transaction. The storage fee goes to the platform's storage wallet. The contract's balance is zero before and after every transaction — there is no escrow and no withdrawal step for primary proceeds.
One mint transaction pays three parties atomically: 95% of the mint price to the artist, 5% to the platform wallet, and the flat storage fee to the storage wallet. The contract holds nothing. mint(quantity) exact ETH in · contract keeps nothing ARTIST · 95% of mint price your immutable address — paid inside the mint PLATFORM · 5% of mint price platformWallet(), read live from the factory STORAGE · flat fee per token funds previews, reveals, drop records · capped

Where the art lives

tokenURI returns a fully self-contained data URI: metadata JSON whose animation_url is an HTML document inlining your script, the bound library (decompressed from its on-chain copy), and the token's hash. The artwork renders from Ethereum alone. In the moments between mint and reveal, the Output shows the placeholder and its Token Hash reads pending. Your script is never run on a stand-in hash.

Each Output's image field starts as an on-chain placeholder and is upgraded exactly once, after the reveal, by the platform's writer key to a preview drawn from your own on-chain code and pinned on Arweave — that preview is a convenience for wallets and marketplaces; the art itself never leaves the chain.

What the contract does not do

  • No allowlists and no auctions. The contract is an open, fixed-price mint. PD's filter deliberately favors the clean default: open mint, fixed price, fixed supply.
  • Every drop opens the same way. Your Project's first 60 seconds are its entry window: presses inside it count as simultaneous, so being milliseconds faster buys nothing and your drop cannot be sniped. If demand fits your supply (which is most drops), every entry mints as the minute ends, then your drop opens to everyone, and nobody sees anything unusual. If you are oversubscribed, a draw anyone can verify decides who mints, at your same fixed price, over the next few minutes. This is not a mode you enable; it is how minting works on PD. And a deadline fixed in your contract (the minute plus 15 minutes) opens minting to everyone even if PD were offline, so nothing can ever hold your mint shut.
  • No admin mint, and no skipping the line. You can mint your own Project as many times as you like for the storage fee (Arweave) alone, with no mint price, through the same entry window as everyone else.
  • No pausing and no upgrades. Once live, the mint runs to sell-out on its own terms.

Further reading