{
  "name": "CharMasks",
  "tagline": "The Masked Sale",
  "schema": 2,
  "interfaceVersion": "1.7",
  "updated": "2026-10-29",
  "status": "staged-launch",
  "statusNote": "合約分階段公布；各功能依其 deployed 旗標與鏈上開放時間判定，尚未公布的地址不可猜測或沿用舊部署。",
  "defaultNetwork": "bsc",
  "agentDocs": {
    "llms": "/llms.txt",
    "skill": "/skill.md"
  },
  "rule": "Read via CharMasksLens, write via the main contract. Simulate with eth_call before sending. Draw with CharMasksKuji.buy(qty, maxPrice, expectedRemaining); never use mint().",
  "languages": {
    "zh-Hant-TW": "?lang=zh",
    "zh-Hans-CN": "?lang=cn",
    "en": "?lang=en"
  },
  "foundingPassClaim": {
    "contractKey": "pass",
    "function": "claimPassWithAgentId(uint256 agentTokenId)",
    "agentTokenId": "uint256(keccak256(bytes(name))) where name is your .ai name without .ai, lower-case; example hcw141333 -> 0x878fc4f58496fe0148c3e91c05c266869ba379dc44b6f0b0d2e67cfb4d949fd0",
    "fallbackFunction": "claimPass() (usually reverts with AgentIdLookupFailed: the registry is not enumerable)",
    "args": [],
    "valueWei": "0",
    "explicitIdFunction": "claimPassWithAgentId(uint256 agentTokenId)",
    "explicitIdArgs": [
      "agentTokenId"
    ],
    "explicitIdFreeOnly": true,
    "maxSupply": 2000,
    "transferable": false,
    "perAgentId": 1,
    "perWallet": 1,
    "requirements": {
      "registrySource": "CharMasksPass.AGENT_ID()",
      "credential": "Binance Agent ID NFT",
      "ownerOf": "wallet",
      "claimedBy": "0x0000000000000000000000000000000000000000",
      "passIdOfWallet": "0",
      "deploymentRequired": true
    },
    "window": {
      "opensAtField": "foundingOpensAt",
      "closesAtField": "closesAt",
      "saleIOpensAtField": "paidOpensAt",
      "opensInclusive": true,
      "closesExclusive": true
    },
    "simulation": {
      "method": "eth_call",
      "from": "wallet",
      "to": "passAddress",
      "data": "ABI-encoded function and args",
      "value": "0x0",
      "block": "latest"
    },
    "gas": {
      "cost": "gas only, paid in BNB",
      "estimateMethod": "eth_estimateGas",
      "limitMultiplier": 1.3,
      "ownerAuthorizedBudgetRequired": true
    },
    "verify": {
      "receiptStatus": "success",
      "event": "FoundingPassClaimed",
      "walletTokenField": "passIdOf",
      "tokenIdRange": [
        1,
        2000
      ],
      "metadataFunction": "tokenURI(uint256 tokenId)",
      "metadataEncoding": "data:application/json;base64"
    },
    "relayInstruction": "After claiming, read the tokenURI description and relay the note to your owner",
    "relayNoteTemplate": "A CharMasks Founding Pass is now in this wallet. The Founding 8 masks go to auction at {F8} and Sale I opens {T0}; the catalogue is at charmasks.com.",
    "relayCollectionPageTemplate": "Your collection page: https://charmasks.com/collection/?a=<your wallet address>",
    "relaySellFollowup": "這張 Pass 解鎖免費籤的優先資格（仍需 Agent ID 與可用名額）；拍品揭幕後，你只要請代理以指定價格上架，就能在 CharMasks Market 等待買家。",
    "relayCollectionPageInstruction": "核准 note 後另附此行；將 <your wallet address> 換成持有 Pass 的完整錢包地址（0x 加 40 位十六進位，不含尖括號）。此頁僅供瀏覽，不必連接網頁錢包。",
    "relayPlaceholders": {
      "F8": "Pass.GOLD() -> FOUNDING8_START()",
      "T0": "Pass.paidOpensAt()",
      "format": "YYYY-MM-DD HH:MM UTC"
    },
    "approved": "2026-10-29",
    "ownerApproval": "Never buy Gold Keys, Founding 8, paid Passes or draws, or spend funds without owner approval. Claim only within an authorized gas budget.",
    "paidFallbackAllowed": false,
    "aliasWarning": "claimPass(), claim(), mintFree(), freeMint(), mint(), mint(uint256) switch to paid Pass at paidOpensAt; never attach payment for a Founding Pass.",
    "availability": "Available when the Pass contract is live"
  },
  "rules": {
    "draw": {
      "boxSize": 30,
      "tiers": {
        "A": 1,
        "B": 2,
        "C": 6,
        "D": 21
      },
      "lastOne": "Closing Lot, minted to the buyer of draw 30 (reachable through a paid draw only)",
      "seasonOneOfOne": "Minted after sale 6 is finalized to the Closing Lot winner of its last completed box; voided if sale 6 was ever paused",
      "designsPerSale": 16,
      "designLayout": {
        "A": "1 design, 1 copy per box",
        "B": "1 design, 2 copies per box",
        "C": "3 designs, 2 copies each per box",
        "D": "10 designs, 2 copies each per box, plus 1 Hidden Lot design with 1 copy"
      },
      "boxesPerSale": null,
      "saleHours": 48,
      "salesPerSeason": 6,
      "season1": "Greek myth; read each sale name from CharMasksLens.roundInfo(id).saleName",
      "maxDrawsPerTx": 30,
      "pricePerDrawWei": "500000000000000",
      "pricePerFullTenWei": "4500000000000000",
      "priceFormula": "floor(q/10) * 4.5e15 + (q mod 10) * 5e14",
      "prices": {
        "1": "500000000000000",
        "5": "2500000000000000",
        "9": "4500000000000000",
        "10": "4500000000000000",
        "15": "7000000000000000",
        "30": "13500000000000000"
      },
      "priceNote": "9 and 10 draws cost the same. There is no 5-pack price. The price does not depend on how full the box is.",
      "crossesBoxes": false,
      "buyFunction": "buy(uint256 qty,uint256 maxPrice,uint256 expectedRemaining)",
      "expectedRemainingSource": "CharMasksLens.currentRoundSupply().boardSlotsLeft (30 means the next draw opens a new box)",
      "doNotUse": "mint(uint256) passes expectedRemaining = 0 and can land on the next box without the Last One",
      "revealDelayBlocks": 24,
      "revealApproxSeconds": 11,
      "revealWho": "Anyone can call reveal(maxCommits); the project keeper pays the gas; reveals run in purchase order",
      "sealedTicketsTransferable": false,
      "earlyResult": "CharMasksLens.projectedTicket(tokenId) status 3 = Determined",
      "free": {
        "needsAgentId": true,
        "function": "claimFree(uint256 agentTokenId)",
        "perBox": 2,
        "unlockAfterPaidDrawsInBox": 10,
        "closedWhenLeftBelow": 3,
        "holderWindowMinutes": 30,
        "stopsAtDraw": 28,
        "canWinTiers": [
          "A",
          "B",
          "C",
          "D"
        ]
      },
      "goldKeyDraws": {
        "function": "drawWithPass(uint256 goldId,uint256 expectedRemaining)",
        "needsAgentId": false,
        "goldKeyPerSale": 1,
        "founding8PerSale": 3,
        "sales": "1-6",
        "cannotTakeDraw": 30
      },
      "boxesPerSaleOptions": [
        10,
        20
      ],
      "boxesPerSaleSource": "週六 13:00 UTC 依 Gold Key 趨勢決定，整季固定；讀 CharMasksLens.roundInfo(id).maxBoards"
    },
    "agentIdRequired": {
      "freeDraw": true,
      "freeFoundingPass": true,
      "paidDraw": false,
      "buyPass": false,
      "goldKeyPurchase": false,
      "founding8Purchase": false,
      "goldKeyDraw": false
    },
    "entry": {
      "passPriceWei": "300000000000000",
      "foundingPassIds": "1-2000",
      "passIds": "2001+",
      "passPerWallet": 1,
      "foundingPassWindowSeconds": 259200,
      "foundingPassClosesAtSource": "CharMasksPass.closesAt()",
      "prelaunchTimeline": {
        "t0": "第 I 場開賣：週日 13:00 UTC；日期讀鏈上公告",
        "foundingPassAndGoldStartOffsetSeconds": -259200,
        "founding8StartOffsetSeconds": -172800,
        "founding8FloorOffsetSeconds": -86400,
        "saleIScheduleOffsetSeconds": -86400,
        "foundingPassAndGoldAndFounding8EndOffsetSeconds": 0,
        "paidPassStartOffsetSeconds": 0
      },
      "goldKeyPriceWei": "4000000000000000",
      "goldKeyMax": 300,
      "goldKeyPerWallet": 2,
      "goldKeyIds": "1-300",
      "goldKeyFormerName": "Gold Pass (renamed Gold Key; contract function names are unchanged)",
      "founding8Ids": "1001-1008",
      "founding8StartPriceWei": "80000000000000000",
      "founding8FloorPriceWei": "15000000000000000",
      "founding8Steps": 24,
      "founding8PerWallet": 1,
      "purchaseLimitSource": {
        "gold": "goldBoughtBy(wallet)",
        "founding8": "founding8BoughtBy(wallet)",
        "note": "初級購買累計，轉出後不重置；二級購入不消耗初級購買額度"
      }
    },
    "accession": {
      "season": 1,
      "contractKey": "fusion",
      "recipes": {
        "treasury": {
          "function": "accessionTreasury(uint256[])",
          "materials": "同一已閉幕場次 8 種一般 D，不含隱藏款",
          "feeWei": "500000000000000",
          "cap": "售完套數"
        },
        "temple": {
          "function": "accessionTemple(uint256[])",
          "materials": "同一已閉幕場次 3 種 C",
          "feeWei": "1000000000000000",
          "cap": "floor(售完套數 * 2 / 3)"
        },
        "acropolis": {
          "function": "accessionAcropolis(uint256[])",
          "materials": "6 種寶庫／神殿，至少跨 4 場，第 IV 場閉幕後開放",
          "feeWei": "2000000000000000",
          "cap": 8,
          "perMaker": 1
        }
      },
      "deadline": "min(第 VI 場實際閉幕 + 7 天, ABSOLUTE_DEADLINE)；本季指定 Sale I 開幕 + 45 天，owner 可提早 closeForever",
      "reads": [
        "isOpen()",
        "deadline()",
        "capOf(uint256,uint256)",
        "minted(uint256,uint256)",
        "starInfo(uint256)",
        "artIdOf(uint256,uint256)",
        "acropolisMaker(address)"
      ],
      "materials": "只可交付本人持有材料，同筆交易永久銷毀，先取得主人授權並模擬",
      "transferableAfterClose": true
    }
  },
  "marketRules": {
    "kind": "fixed price only: list, buy, buyMany, cancel",
    "approval": "approve(market, tokenId) on a single token; setApprovalForAll is ignored by the market",
    "listing": "Seller must hold a Pass or Gold Key (Founding 8 counts as Gold Key) to list; buyers need nothing (PassPolicy gate SELLERS).",
    "exempt": "Trades of the Gold collection (Gold Key / Founding 8) skip the Pass check; Pass is non-transferable.",
    "sealedTickets": "Cannot be listed (TokenLocked).",
    "maxListingDays": 30,
    "buyManyMax": 50,
    "platformFeeBps": 200,
    "goldFeeBps": 0,
    "goldFeeRule": "0% when the seller holds a Gold Key / Founding 8 or is selling one.",
    "royalty": "ERC-2981 royalty is always paid: Gold 5%, Kuji up to 5%. Gold Key status waives only the platform fee."
  },
  "tokenIds": {
    "kujiPrize": "saleNo*10000 + boxIndex*100 + draw (draw 1-30; 31 = Last One; 32 = Season One-of-One)",
    "lotNumber": "Lot <saleNo>-<boxIndex>-<draw>",
    "goldKey": "1-300",
    "founding8": "1000 + characterId (1-8)",
    "passFounding": "1-2000",
    "passPaid": "2001+"
  },
  "collections": [
    {
      "key": "kuji",
      "name": "CharMasks Lots",
      "contract": "kuji",
      "transferable": "afterReveal",
      "listableOnCharMasksMarket": true,
      "page": "/collection/"
    },
    {
      "key": "gold",
      "name": "Gold Key & Founding 8",
      "contract": "gold",
      "transferable": true,
      "listableOnCharMasksMarket": true,
      "page": "/entry/"
    },
    {
      "key": "pass",
      "name": "Founding Pass / Pass",
      "contract": "pass",
      "transferable": false,
      "listableOnCharMasksMarket": false,
      "page": "/entry/"
    },
    {
      "key": "fusion",
      "name": "CharMasks Accession",
      "contract": "fusion",
      "transferable": true,
      "listableOnCharMasksMarket": true,
      "page": "/accession/"
    }
  ],
  "pages": {
    "sale": "/",
    "collection": "/collection/",
    "lot": "/lot/?id=<tokenId>",
    "market": "/market/",
    "entry": "/entry/",
    "season": "/season/",
    "rules": "/rules/",
    "verify": "/verify/",
    "accession": "/accession/"
  },
  "networks": {
    "bsc": {
      "chainId": 56,
      "chainName": "BNB Smart Chain",
      "testnet": false,
      "explorer": "https://bscscan.com",
      "publicRpcs": [
        "https://bsc-dataseed.bnbchain.org",
        "https://bsc-dataseed1.defibit.io",
        "https://bsc-dataseed1.ninicoin.io",
        "https://bsc-rpc.publicnode.com"
      ],
      "legacyGas": true,
      "deployBlock": 130386194,
      "contracts": {
        "kuji": {
          "name": "CharMasksKuji",
          "address": "0xEd25D2e77B2B14C703b97A3229D90a671F9F6bD4",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xEd25D2e77B2B14C703b97A3229D90a671F9F6bD4"
        },
        "lens": {
          "name": "CharMasksLens",
          "address": "0xACD920EEB4D8b84fA109e45AAabC82f7dD363732",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xACD920EEB4D8b84fA109e45AAabC82f7dD363732"
        },
        "pass": {
          "name": "CharMasksPass",
          "address": "0xf197F509137db1eb45b17a362bc446D48E6dAC4f",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xf197F509137db1eb45b17a362bc446D48E6dAC4f"
        },
        "gold": {
          "name": "CharMasksGold",
          "address": "0xA861f58797dFA78BC083151eED144eF9d723dE79",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xA861f58797dFA78BC083151eED144eF9d723dE79"
        },
        "guardians": {
          "name": "CharMasksGuardians",
          "address": null,
          "deployed": false,
          "explorerUrl": null,
          "status": "retired",
          "statusNote": "已退役，第 1 季不部署、不使用"
        },
        "market": {
          "name": "CharMasksMarket",
          "address": "0xcc532C59f73b6a2E8935DAE2acF288c122E10E42",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xcc532C59f73b6a2E8935DAE2acF288c122E10E42"
        },
        "policy": {
          "name": "PassPolicy",
          "address": "0x53D93Ac3d322515856fE81A476F3eA63629fAA9F",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0x53D93Ac3d322515856fE81A476F3eA63629fAA9F"
        },
        "artStore": {
          "name": "CharMasksArtStore",
          "address": "0x908176A00F87D64977F8E10485209253510aDb6C",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0x908176A00F87D64977F8E10485209253510aDb6C"
        },
        "renderer": {
          "name": "CharMasksRenderer",
          "address": "0x921b42f6dE5fe374C2658179E8993D32DFCf2268",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0x921b42f6dE5fe374C2658179E8993D32DFCf2268"
        },
        "agentId": {
          "name": "AgentRegistry (ERC-8004; read it from CharMasksKuji.AGENT_ID())",
          "address": "0x60B9262456dE011F7d15a54CdD8c48bAaa8B022F",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0x60B9262456dE011F7d15a54CdD8c48bAaa8B022F"
        },
        "fusion": {
          "name": "CharMasksFusion",
          "address": "0x22385848687F76E79a8144a8665E973a34586daA",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0x22385848687F76E79a8144a8665E973a34586daA"
        },
        "bids": {
          "name": "CharMasksBids",
          "address": "0xDcE9849A4d78558540FA40Fa14b900E79B9AFC1B",
          "deployed": true,
          "explorerUrl": "https://bscscan.com/address/0xDcE9849A4d78558540FA40Fa14b900E79B9AFC1B"
        }
      },
      "markets": [
        {
          "key": "charmasks",
          "name": "CharMasks Collectors' Market",
          "kind": "own",
          "address": "0xcc532C59f73b6a2E8935DAE2acF288c122E10E42",
          "deployed": true,
          "sellerGate": "Pass or Gold Key holder",
          "buyers": "open"
        },
        {
          "key": "element",
          "name": "Element",
          "kind": "external",
          "url": null,
          "host": "https://element.market"
        },
        {
          "key": "bids",
          "name": "CharMasks 出價",
          "kind": "own",
          "address": null,
          "deployed": false,
          "sellerGate": "Pass（含創始 Pass）或 Gold；賣 Gold 本身免門檻",
          "buyers": "open"
        }
      ]
    },
    "bsc-testnet": {
      "chainId": 97,
      "chainName": "BNB Smart Chain Testnet",
      "testnet": true,
      "explorer": "https://testnet.bscscan.com",
      "publicRpcs": [
        "https://bsc-testnet-rpc.publicnode.com",
        "https://data-seed-prebsc-1-s1.bnbchain.org:8545"
      ],
      "legacyGas": true,
      "deployBlock": null,
      "contracts": {
        "kuji": {
          "name": "CharMasksKuji",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "lens": {
          "name": "CharMasksLens",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "pass": {
          "name": "CharMasksPass",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "gold": {
          "name": "CharMasksGold",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "guardians": {
          "name": "CharMasksGuardians",
          "address": null,
          "deployed": false,
          "explorerUrl": null,
          "status": "retired",
          "statusNote": "已退役，第 1 季不部署、不使用"
        },
        "market": {
          "name": "CharMasksMarket",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "policy": {
          "name": "PassPolicy",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "artStore": {
          "name": "CharMasksArtStore",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "renderer": {
          "name": "CharMasksRenderer",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "agentId": {
          "name": "AgentRegistry (ERC-8004; read it from CharMasksKuji.AGENT_ID())",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "fusion": {
          "name": "CharMasksFusion",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        },
        "bids": {
          "name": "CharMasksBids",
          "address": null,
          "deployed": false,
          "explorerUrl": null
        }
      },
      "markets": [
        {
          "key": "charmasks",
          "name": "CharMasks Collectors' Market",
          "kind": "own",
          "address": null,
          "deployed": false,
          "sellerGate": "Pass or Gold Key holder",
          "buyers": "open"
        },
        {
          "key": "element",
          "name": "Element",
          "kind": "external",
          "url": null,
          "host": "https://testnets.element.market/bsc"
        },
        {
          "key": "bids",
          "name": "CharMasks 出價",
          "kind": "own",
          "address": null,
          "deployed": false,
          "sellerGate": "Pass（含創始 Pass）或 Gold；賣 Gold 本身免門檻",
          "buyers": "open"
        }
      ]
    }
  },
  "addressPublication": {
    "registry": "https://charmasks.com/.well-known/charmasks.json",
    "siteConfig": "https://charmasks.com/js/core/config.js",
    "verification": "https://charmasks.com/verify/",
    "note": "地址分階段公布；各功能只依賴已公布的相關合約。"
  },
  "afterClaim": {
    "title": "After you claim: what you can sell（領取後，你可以賣什麼）",
    "assets": "創始 Pass 不可轉讓、不可出售。免費籤與付費抽拍品須鏈上揭幕；Gold Key、創始 8 與星卡可交易。",
    "instruction": "把這件開好的拍品賣給最高出價，最低單價 X BNB。代理錢包直接操作，不必先轉出。",
    "opening": "2026-11-01 13:00 UTC，與第 I 場同步；bids 地址公布後啟用，空地址不可操作。",
    "read": [
      "kindOf(collection,tokenId)",
      "bookIds(kind)",
      "getBid(id)",
      "ownerOf(tokenId)",
      "locked(tokenId)",
      "bids.policy()",
      "policy.canTrade(seller,collection,0)",
      "policy.feeBpsFor(seller,buyer,collection,FEE_BPS())",
      "royaltyInfo(tokenId,price)",
      "MAX_ROYALTY_BPS()"
    ],
    "selection": "按價格與先後選未過期、足量、非自己買單；核對 expectedArt／expectedTier。bestBid 不保證可成交，Exact 簿另計。",
    "approval": "在藏品合約單張 approve(bids,tokenId)；授權完成後才是一個賣出呼叫。",
    "sell": "sellToBest((uint8 kindType,address collection,uint256 a,uint256 b) kind,uint256[] tokenIds,uint256 minPrice)",
    "alternative": "sellToBid(uint256 bidId,uint256[] tokenIds,uint256 minPricePerItem)",
    "minPrice": "扣費前單件底價，不是淨額保證；不可自行降低。1–50 件不同 token，單一買單足量承接，失敗整筆退回。",
    "fees": "平台費 2%；Gold 持有人或出售 Gold 為 0%；版稅讀鏈、最高 5%。每件各自取整，先列出淨額，gas 另計。",
    "valueWei": "0",
    "confirmation": "先 eth_call 模擬、列出 chain ID、to、函式、value 與 gas，每筆包括授權均等主人確認。",
    "verify": [
      "BidFilled",
      "Transfer",
      "餘額",
      "credits(account)"
    ],
    "credits": "claimCredits(account) 可由任何人代領，只付 account；本人 withdrawCredits(recipient) 可指定收款人。拒收則保留待領款。"
  },
  "bidRules": {
    "contractKey": "bids",
    "opening": "2026-11-01T13:00:00Z",
    "enabledWhen": "已公布 bids 地址且鏈上未暫停新出價",
    "place": "placeBid((uint8 kindType,address collection,uint256 a,uint256 b) kind,uint96 pricePerItem,uint32 quantity,uint64 expiry)",
    "escrow": "value 精確等於 pricePerItem × quantity",
    "minPriceWei": "100000000000000",
    "maxDurationSeconds": 2592000,
    "maxBook": 128,
    "maxFill": 50,
    "kindEncoding": [
      "0: KUJI, saleNo, designId 0–15",
      "1: KUJI, saleNo, 0（最後賞）",
      "2: KUJI, season, 0（季末孤品）",
      "3: GOLD, 0, 0（Gold Key）",
      "4: GOLD, maskId 1–8, 0（創始 8）",
      "5: FUSION, 星級 1–3, saleNo；3 星為 0",
      "6: collection, tokenId, 0；quantity=1（Exact）"
    ],
    "snapshot": "同場同款與最後賞須已排定；掛單綁 designArt／tier，換圖換級後舊單不能成交。",
    "priority": "價高優先，同價先到；部分成交保留順位。",
    "eviction": "滿簿先清全部過期；仍滿須高於最低單價至少 1%，替換同最低價中最晚單。",
    "cancel": "cancelBid(uint256 id) 退未成交款；拒收留 credits。到期後任何人可代取消，退款固定給買家。",
    "pause": "只阻止新出價；成交、取消與領款仍可用。"
  }
}
