Collaborative NFT creator guild with on-chain royalty splitting on Stacks
nftguild is a collaborative NFT protocol on Stacks that lets artists, developers, and creators form on-chain guilds, co-create NFT collections, and automatically split royalties — forever, on-chain, with no middlemen.
Whether you're an artist teaming up with a developer, a music producer collaborating with a visual artist, or a DAO launching a community collection, nftguild handles the coordination, minting, and revenue sharing transparently on Bitcoin L2.
- Guild Formation — create a named guild with multiple collaborators and configurable split percentages
- Co-Minting — mint SIP-009 NFT collections under a shared guild identity
- Automatic Royalty Splits — every secondary sale royalty is split on-chain between guild members instantly
- Trait-Based Rarity — upload trait layers and generate rarity-weighted collections
- Allowlist & Presale — built-in allowlist management and tiered presale phases
- Reveal Mechanism — delayed metadata reveal with on-chain randomness
- Guild Treasury — shared treasury for guild expenses and reinvestment
- Member Governance — vote to add/remove members or adjust splits
- Marketplace Ready — compatible with Gamma, Byzantion, and any SIP-009 marketplace
| Layer | Technology |
|---|---|
| Smart Contracts | Clarity (Stacks) |
| NFT Standard | SIP-009 |
| Royalty Standard | SIP-012 (Royalties) |
| Frontend | Next.js 14 + TypeScript |
| Metadata Storage | IPFS via nft.storage |
| Image Generation | Sharp + custom trait engine |
| SDK | Stacks.js |
| Testing | Clarinet + Vitest |
nftguild/
├── contracts/
│ ├── nftguild-core.clar # Guild registry and management
│ ├── nftguild-collection.clar # SIP-009 NFT collection logic
│ ├── nftguild-royalties.clar # Automatic royalty splitting
│ ├── nftguild-treasury.clar # Guild shared treasury
│ ├── nftguild-allowlist.clar # Presale and allowlist management
│ └── traits/
│ ├── nft-trait.clar # SIP-009 trait
│ └── royalty-trait.clar # SIP-012 trait
├── generator/
│ ├── traits/ # Art layer assets
│ ├── config.json # Rarity and layer config
│ └── generate.ts # Collection generator script
├── frontend/
│ ├── app/
│ │ ├── guilds/ # Guild browser
│ │ ├── mint/ # Minting interface
│ │ └── my-nfts/ # User collection viewer
│ └── components/
├── scripts/
│ ├── create-guild.ts
│ ├── deploy-collection.ts
│ └── upload-metadata.ts
└── tests/
├── guild.test.ts
├── collection.test.ts
└── royalties.test.ts
(contract-call? .nftguild-core create-guild
"Pixel Prophets" ;; guild name
(list
{ member: 'SP1ABC...XYZ, share: u60 } ;; artist: 60%
{ member: 'SP2DEF...UVW, share: u30 } ;; developer: 30%
{ member: 'SP3GHI...RST, share: u10 } ;; community treasury: 10%
)
)(contract-call? .nftguild-core deploy-collection
u1 ;; guild-id
"Pixel Prophets Genesis" ;; collection name
"PPG" ;; symbol
u5555 ;; max supply
u10000000 ;; mint price (in uSTX)
0x... ;; base URI (IPFS CID)
)(contract-call? .nftguild-collection mint u1)
;; Mints next available token, sends royalty split to guild treasury(contract-call? .nftguild-royalties claim-share u1)
;; Claims your portion of accumulated royalties for guild #1# Configure your trait layers
cp generator/config.example.json generator/config.json
# Edit config.json with your layer names and rarity weights
# Add trait images to generator/traits/<layer-name>/
# Generate collection
npx ts-node generator/generate.ts --count 5555 --output ./output
# Upload to IPFS
npx ts-node scripts/upload-metadata.ts --dir ./output
# Deploy collection contract
npx ts-node scripts/deploy-collection.ts --guild 1 --uri ipfs://Qm...{
"layers": [
{
"name": "Background",
"values": [
{ "name": "Cosmic Blue", "weight": 30, "file": "bg_cosmic_blue.png" },
{ "name": "Golden Hour", "weight": 10, "file": "bg_golden_hour.png" },
{ "name": "Void", "weight": 5, "file": "bg_void.png" }
]
},
{
"name": "Body",
"values": [
{ "name": "Prophet Robes", "weight": 40, "file": "body_robes.png" },
{ "name": "Cyber Armor", "weight": 20, "file": "body_cyber.png" }
]
}
]
}Secondary Sale on Marketplace
│
▼
nftguild-royalties.clar
│
┌──────┴──────┐
▼ ▼
Member A (60%) Member B (30%) Treasury (10%)
auto-split auto-split auto-split
Royalties are distributed atomically in the same transaction as the sale — no manual claiming or trust required.
| Phase | Access | Price |
|---|---|---|
| Team Mint | Guild members only | Free |
| Allowlist | Whitelisted wallets | 0.8x public price |
| Public Mint | Anyone | Full price |
| Reveal | Automatic after sellout | — |
git clone https://github.com/thewealthyplace/nftguild
cd nftguild
npm install
# Start devnet
clarinet devnet start
# Run tests
clarinet test
# Start frontend
cd frontend && npm run dev- Guild registry and management contracts
- SIP-009 collection with royalty splits
- IPFS metadata upload tooling
- Trait generator UI (drag-and-drop)
- Marketplace aggregator view
- Guild reputation and badge system
- Cross-guild collaboration (multi-guild collections)
- Mobile mint experience
git clone https://github.com/thewealthyplace/nftguild
npm install
clarinet check && clarinet testMIT © thewealthyplace