Hats Protocol Docs
hatsprotocol.xyzGithub
  • πŸ‘‹Welcome to Hats Protocol
  • 🧒Getting Started with Hats
  • ⭐Quick Start
  • Using The Hats App
    • 🀠Essentials For Hat Wearers
    • 🎩Creating My First Hat
    • πŸ§™Admins: Creating, Issuing, and Revising Hats
    • πŸ‘₯What Hats Do I Need?
    • 🌳Drafting, Exporting, and Deploying Tree Changes
    • πŸ—οΈSetting a Hat's Basic Properties
    • πŸ₯³Adding Wearers
    • πŸ”Connecting Hats w/ Permissions & Authorities
      • Types of Hat-Powered Authorities
      • Connecting Hats to Token Gates
        • Hats Protocol Contract Addresses
        • Finding a Hat's Token ID
      • Documenting Hat Powers & Responsibilities
    • 🌟Revocation & Eligibility: Requirements for Wearers
    • ⚑Deactivating & Reactivating Hats
    • βœ…Making Hats Claimable
    • πŸ”—Linking Trees Together
    • ⛓️Hats Protocol Supported Chains
    • ❓Glossary & FAQ
  • Hats Integrations
    • πŸ”Permissions & Authorities
      • Coordinape
      • Council Voting Vault
      • Charmverse
      • Discord
        • Collab.Land --> Discord
        • Guild.xyz --> Discord
      • Farcaster Casting Rights
      • Fileverse
      • Google Workspace
      • Hats Account
      • Role-Based Compensation
      • Safe Multisig Signing Authority
      • Telegram
        • Collab.Land --> Telegram
        • Guild.xyz --> Telegram
      • Snapshot: Voting, Weight & Proposal Creation
      • Wonderverse
    • 🌟Eligibility & Accountability Criteria
      • Agreement Eligibility
      • Allow-List Eligibility
      • CoLinks Eligibility
      • ERC20 Eligibility
      • ERC721 Eligibility
      • ERC1155 Eligibility
      • Hat-Wearing Eligibility
      • Hats Election Eligibility
      • JokeRace Eligibility
      • Pass-Through (Hat-Based) Eligibility
      • Staking Eligibility
      • Subscription or Membership Fee (Unlock Protocol)
      • Gitcoin Passport Eligibility
    • ⚑Activation & Deactivation Criteria
      • Seasonal/ Time-Expiry Toggle
      • Pass-Through (Hat-Based) Toggle
    • πŸ‘·Hatter Modules
      • Multi Claims Hatter
      • DAOhaus Moloch v3 Membership & Share Allocation
  • For Developers
    • πŸ‘·Hats Protocol, for Developers
      • Hat Properties
      • Wearing a Hat
      • Hat Admins & Hatter Contracts
      • Hats Trees
      • Hat IDs
      • Linking Hats Trees
      • Eligibility Modules
      • Toggle Modules
      • Hat Mutability and Editing
      • Creating Hats
      • Minting Hats
      • Transfering Hats
      • Renouncing Hats
      • Batch Actions
      • Hat Image URIs
      • ERC1155 Compatibility
      • ⛓️Supported Chains
    • πŸ€–v1 Protocol Spec
      • Hats.sol
      • HatsEvents.sol
      • HatsErrors.sol
      • HatsIdUtilities.sol
      • Interfaces
        • IHats.sol
        • IHatsIdUtilities.sol
        • IHatsEligibility.sol
        • IHatsToggle.sol
    • πŸ–₯️v1 SDK
      • Core
        • Getting Started
        • Onchain Reads
        • Onchain Writes
        • Multicall
        • Claiming Hats
        • Utilities
      • Subgraph
        • Getting Started
        • Fetching Hats
        • Fetching Wearers
        • Fetching Trees
        • Misc
        • Types
      • Hat Details
        • Getting Started
        • Usage
    • πŸ”­v1 Subgraphs
    • 🧩Hats Modules
      • πŸ”ŒModules SDK
        • Getting Started
        • Get Available Modules
        • Create New Instance/s
        • Composing Modules
        • Interact With Instances
        • Utilities
        • Types
      • βš’οΈBuilding Hats Modules
        • Inside a Hats Module
          • Immutable Arguments
          • Module Setup
          • Versioning
        • Creating New Modules
        • How Module Instances Are Deployed
        • Modules Registry
        • About Module Chains
    • πŸ”Hats Signer Gate v2
    • πŸ‘’Hats Signer Gate SDK
      • Getting Started
      • Creating New Instances
      • Hats Signer Gate
      • Multi Hats Signer Gate
      • HSG & MHSG Handlers
    • πŸ’ΌHats Account SDK
      • 1 of N Hats Account
        • Getting Started
        • Creating New Instances
        • Executing From An Instance
        • Constants
        • Types
    • 🌐Hats Security Audits
  • Legal
    • Terms
      • Terms of Service
      • Acceptable Use
      • Privacy Policy
      • Cookie Policy
      • Attribution
Powered by GitBook
On this page
  • Transitive Admin Powers
  • Separation of Powers over Hats
  • Hatter Contracts
  1. For Developers
  2. Hats Protocol, for Developers

Hat Admins & Hatter Contracts

The admin of every hat is another hat. This means that the authority to perform admin functions for a given hat is assigned to the wearer of its admin hat.

The scope of authority for a hat's admin is to determine who can wear it. This is reflected in the ability to create the hat and to mint or (for mutable hats) transfer the hat's token.

Transitive Admin Powers

In Hats Protocol v1, admin powers are transitive. All of a hat's ancestors β€” its direct admin, its admin's admin, etc β€” can serve as its admin.

Separation of Powers over Hats

In most contexts, an "admin" role has broad, generalized control over the entity it administers. Hats Protocol is different. The generalized control over a given hat is separated into three distinct roles:

Role
Powers

Admin

  • Create new hat

  • Issue hat to wearer(s), aka β€œmint”

  • Edit hat properties (while mutable)

  • Transfer hat (while mutable)

  • Prevent ineligible addresses from wearing hat

  • Revoke hat from specific wearer(s)

  • Activate / de-active hat β‡’ all wearers lose the hat

Hatter Contracts

Logic contracts that serve as admins are informally known as "hatter" contracts. These are contracts that implement specific logic or rules. The admin of a hatter contract is the true admin, but has delegated said admin authority to the logic embedded in the hatter.

Hatter contract logic is a wide design space for DAOs. Here are some examples of hatter logic:

Hat creation

Allow certain addresses -- such as members of a DAO -- to create hats that are then admin'd by the DAO.

Hat minting

Allow certain addresses -- such as members of a DAO -- to mint hat tokens. Together with the above, a DAO could in this way enable its members to create and wear a certain type of hat permissionlessly. This would be especially if using hats to facilitate role clarity and legibility.

Wearer eligibility

Enforce certain requirements that prospective wearers must meet in order to wear a given hat, such as membership in a DAO or holding some token(s). Note that this is often more effectively implemented as an eligibility module.

Wearer staking

One particularly important type of eligibility requirement is staking tokens, DAO shares, or some other asset as a bond that could be slashed if the wearer is not a good steward of the accountabilities associated with the hat, or does not follow through on its associated responsibilities. Note that this is often more effectively implemented as an eligibility module.

PreviousWearing a HatNextHats Trees

Last updated 1 year ago

πŸ‘·
Eligibility Module
Toggle Module