--- eip: 8041 title: Fixed-Supply Agent NFT Collections description: Create fixed-supply collections of ERC-8004 Agent NFTs with mint number tracking author: Prem Makeig (@nxt3d) discussions-to: https://ethereum-magicians.org/t/erc-8041-fixed-supply-agent-nft-collections/25656 status: Draft type: Standards Track category: ERC created: 2025-10-11 requires: 7572, 8004, 8119 --- ## Abstract An interface for creating fixed-supply collections of Agent NFTs that are registered in an [ERC-8004](./eip-8004.md) Agent Registry. While [ERC-8004](./eip-8004.md) provides an unlimited mint registry for agent identities, many use cases require limited collections. Collections can be created with fixed supply limits while maintaining the association between agents and their collection through onchain metadata and mint number tracking. ## Motivation [ERC-8004](./eip-8004.md) establishes a singleton registry for AI Agent identity tokens with unlimited minting capability. This open registration model serves many use cases, but there is a clear need for: 1. **Fixed-supply collections**: Ability to create limited editions (e.g., "Genesis 100", "Season 1") 2. **Multiple collections per agent**: Agents may belong to multiple named collections (e.g., `agent-collection:dev-team`, `agent-collection/dev-team`, or `agent-collection[dev-team]`) using [ERC-8119](./eip-8119.md) parameterized keys 3. **Collection metadata**: Associate agents with specific collections and track their provenance 4. **Mint number tracking**: Permanent record of each agent's position in the collection (#1 of 1000) 5. **Time-gated releases**: Collections that activate at specific block numbers 6. **Curated drops**: Controlled minting by collection creators rather than open registration This standard enables these use cases while leveraging the existing [ERC-8004](./eip-8004.md) registry infrastructure. ## Specification The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC 2119](https://www.rfc-editor.org/rfc/rfc2119.html) and [RFC 8174](https://www.rfc-editor.org/rfc/rfc8174.html). ### Collection Structure Every compliant collection contract MUST maintain the following collection properties: - `maxSupply`: Maximum number of agents that can exist in the collection - `currentSupply`: Current number of agents minted in the collection - `startBlock`: Block number when minting becomes available - `open`: Boolean indicating if the collection is currently accepting mints ### Core Interface Compliant collection contracts MUST implement the `IERC8041Collection` interface: ```solidity pragma solidity ^0.8.25; interface IERC8041Collection { /// @notice Emitted when the collection is created or updated /// @param maxSupply Maximum number of agents in the collection /// @param startBlock Block number when minting becomes available /// @param open Whether the collection is open for minting event CollectionUpdated(uint256 maxSupply, uint256 startBlock, bool open); /// @notice Emitted when an agent is minted in the collection /// @param agentId The ERC-8004 token ID of the agent in the registry /// @param mintNumber The agent's position in the collection (1-indexed) /// @param owner The address that received the agent event AgentMinted(uint256 indexed agentId, uint256 mintNumber, address indexed owner); /// @notice Get the mint number for a specific agent /// @param agentId The ERC-8004 token ID of the agent /// @return mintNumber The agent's position in the collection (1-indexed, e.g., "5 of 1000") /// Returns 0 if the agent was not minted through this collection function getAgentMintNumber(uint256 agentId) external view returns (uint256 mintNumber); /// @notice Get the current supply of the collection /// @return currentSupply Current number of agents minted function getCollectionSupply() external view returns (uint256 currentSupply); } ``` ### Required Functions Every compliant collection contract MUST implement the following functions: - `function getAgentMintNumber(uint256 agentId) external view returns (uint256 mintNumber)` - Returns the mint number for a given agent ID (0 if not in collection) - `function getCollectionSupply() external view returns (uint256 currentSupply)` - Returns the current supply of the collection ### Required Events Every compliant collection contract MUST emit the following events: - `event CollectionUpdated(uint256 maxSupply, uint256 startBlock, bool open)` - MUST be emitted when the collection is created and whenever collection details are changed - `event AgentMinted(uint256 indexed agentId, uint256 mintNumber, address indexed owner)` - MUST be emitted when an agent is added to the collection ### Required Behavior #### Collection Association When an agent is minted through a collection contract, the contract MUST: 1. Register the agent in the [ERC-8004](./eip-8004.md) registry 2. Assign a sequential mint number starting from 1 3. Store the agent's mint number internally 4. Write collection metadata to the agent's Onchain Metadata using a key that identifies the collection 5. Emit an `AgentMinted` event The metadata key is either the default or a parameterized form: - **`agent-collection`** (no parameter, default): For the default or primary collection. This is the only case that does not use a parameterized key. Discoverable without indexing. - **Parameterized form**: For additional collections per agent, the key MUST follow [ERC-8119](./eip-8119.md) parameterized key format. The label identifies the collection. All ERC-8119 forms are acceptable: `agent-collection: