Skip to content

TokenRole

Token role utilities for serializing role identifiers to keccak256 hashes.

TIP-20 includes a built-in RBAC system with roles like ISSUER_ROLE (mint/burn), PAUSE_ROLE/UNPAUSE_ROLE (emergency controls), and BURN_BLOCKED_ROLE (compliance).

TIP-20 RBAC

Examples

import { TokenRole } from 'ox/tempo'
 
const hash = TokenRole.serialize('issuer')

Functions

NameDescription
TokenRole.serializeSerializes a token role to its keccak256 hash representation.

Types

NameDescription
TokenRole.TokenRole