@croptop/core-v6
v0.0.55
Published
Croptop turns a Juicebox project with a 721 hook into a permissioned publishing marketplace. Project owners define posting rules, then anyone who meets those rules can publish new NFT tiers and mint the first copy of each post.
Downloads
5,323
Readme
Croptop Core
Croptop turns a Juicebox project with a 721 hook into a permissioned publishing marketplace. Project owners define posting rules, then anyone who meets those rules can publish new NFT tiers and mint the first copy of each post.
Docs: https://docs.juicebox.money
Site: https://croptop.eth.limo
Architecture: ARCHITECTURE.md
User journeys: USER_JOURNEYS.md
Skills: SKILLS.md
Risks: RISKS.md
Administration: ADMINISTRATION.md
Audit instructions: AUDIT_INSTRUCTIONS.md
Overview
Croptop is built around three ideas:
- project owners set category-level posting rules such as price floors, supply bounds, split limits, and optional allowlists
- publishers call
mintFromto create or reuse 721 tiers that represent their post - a one-click deployer can create a full Juicebox project, its 721 hook config, and its posting rules in one transaction
Every mint collects a 5% Croptop fee unless the target project is itself the fee project. If the fee terminal rejects that fee payment, Croptop refunds the fee portion to _msgSender() and still lets the publish continue. If _msgSender() cannot receive ETH, the mint reverts.
Use this repo when the product is permissioned publishing on top of a Juicebox project. Do not use it for plain 721 tier sales.
Key Contracts
| Contract | Role |
| --- | --- |
| CTPublisher | Validates posts, adjusts 721 tiers, mints the first copy, and routes protocol and project payments. |
| CTDeployer | Launches a project, configures Croptop posting rules, and can wire in omnichain sucker deployments. |
| CTProjectOwner | Ownership sink that can permanently hold a project NFT while still delegating the posting permissions Croptop needs. |
Mental Model
There are two separate concerns here:
CTPublisherdecides whether a post is allowed and how it becomes a tierCTDeployerdecides how a Croptop-flavored project is packaged and launched
Many Croptop bugs are really deployment-shape bugs or posting-policy bugs, not generic 721 bugs.
Read These Files First
src/CTPublisher.solsrc/CTDeployer.solsrc/CTProjectOwner.soltest/CTPublisher.t.soltest/ClaimCollectionOwnership.t.sol
High-Signal Tests
test/CTPublisher.t.soltest/CTDeployer.t.soltest/ClaimCollectionOwnership.t.soltest/regression/FeeFallbackBlackhole.t.soltest/regression/DuplicateUriFeeEvasion.t.sol
Integration Traps
- Croptop publishing policy is separate from ordinary 721 tier issuance
- fee routing is part of the publish path and its fallback behavior matters
CTProjectOwnerintentionally changes the ownership model and should be reviewed as part of the trust model- duplicate-content, stale-tier, and fee-evasion edge cases are runtime behavior, not just UI concerns
Where State Lives
- posting criteria and publish-side enforcement live in
CTPublisher - deployment-time project wiring lives in
CTDeployer - ownership-sink behavior lives in
CTProjectOwner - actual tier issuance and treasury accounting still live in sibling Juicebox repos
Install
npm install @croptop/core-v6Development
npm install
forge build --deny notes
forge test --deny notes --fail-fast --summary --detailed --skip "*/script/**"Useful scripts:
npm run deploy:mainnetsnpm run deploy:testnetsnpm run deploy:mainnets:projectnpm run deploy:testnets:project
Deployment Notes
Deployments are handled through Sphinx. CTDeployer can also compose cross-chain sucker deployments when a nonzero sucker configuration is supplied. The deploy script expects an explicit nonzero FEE_PROJECT_ID for production-style deployments.
Repository Layout
src/
CTPublisher.sol
CTDeployer.sol
CTProjectOwner.sol
interfaces/
structs/
test/
publisher, deployer, fork, attack, review, metadata, and regression coverage
script/
Deploy.s.sol
ConfigureFeeProject.s.sol
helpers/Risks And Notes
- posting criteria are only as safe as the project owner configures them
- fee routing depends on the fee project staying correctly configured
- parking a project in
CTProjectOwneris effectively irreversible - after routing ownership into
CTProjectOwner, the old owner no longer holds the project NFT directly - duplicate-content and stale-tier edge cases are economically relevant, not cosmetic
For AI Agents
- Do not describe Croptop as a generic 721 marketplace.
- Read
CTPublisherbeforeCTDeployerwhen the question is about publish eligibility or fee behavior. - If the issue is basic tier minting or accounting, move to
nana-721-hook-v6ornana-core-v6.
