Skip to content
    hazBasehazBaseDocs
    SMART CONTRACTS
    Contract catalog

    PrivilegeEdition

    Manage access passes and benefits by type and quantity.

    Tokens & rightsPrivilegeEdition.sol@hazbase/kit@0.9.0

    Role and use

    Use for multiple copies of a pass or different benefit tiers.

    Integration considerationsSet supply limits per tokenId and redemption conditions. Reconcile application usage records with confirmed redeem results.

    Key SDK operations

    These operations are exposed by PrivilegeEditionHelper in @hazbase/kit@0.9.0. The signatures below are type definitions; see the SDK reference for parameter structures and the complete interface.

    typescript
    import { PrivilegeEditionHelper } from '@hazbase/kit';

    setTier

    typescript
    async setTier(id: bigint | number, newTier: number): Promise<TransactionReceipt>

    mint

    typescript
    async mint(
        to: Address,
        id: bigint | number,
        amt: bigint | number,
        uri: string,
        tier: number,
        exp: bigint | number,
        rType: bigint | number
      ): Promise<TransactionReceipt>

    redeem

    typescript
    async redeem(from: Address, id: bigint | number, amount: bigint | number): Promise<TransactionReceipt>

    totalSupply

    typescript
    async totalSupply(id: bigint | number): Promise<bigint>
    View parameters, return types and all methods

    Related contracts

    Put it into practice

    Access & membership

    See the data model, processing sequence and SDK code for an application-level implementation.

    Read the implementation pattern

    Specification and source

    The Solidity source is pinned to the revision below. Match it with the SDK version and your network’s implementation address and ABI.

    privilege-edition/contracts/PrivilegeEdition.sol

    Source revision: b53a5b5