Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/tempo-burn-at-role.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"ox": patch
---

Added the TIP-1006 `burnAt` role (`BURN_AT_ROLE`) to `TokenRole`.
5 changes: 4 additions & 1 deletion src/tempo/TokenRole.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export const roles = [
'unpause',
'issuer',
'burnBlocked',
'burnAt',
] as const
export type TokenRole = (typeof roles)[number]

Expand All @@ -16,13 +17,15 @@ export const toPreHashed = {
unpause: 'UNPAUSE_ROLE',
issuer: 'ISSUER_ROLE',
burnBlocked: 'BURN_BLOCKED_ROLE',
burnAt: 'BURN_AT_ROLE',
} as const satisfies Record<TokenRole, string>

/**
* Serializes a token role to its keccak256 hash representation.
*
* 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).
* `PAUSE_ROLE`/`UNPAUSE_ROLE` (emergency controls), `BURN_BLOCKED_ROLE` (compliance), and
* `BURN_AT_ROLE` (burn from any unprotected account, T12+).
*
* [TIP-20 RBAC](https://docs.tempo.xyz/protocol/tip20/overview#role-based-access-control-rbac)
*
Expand Down
Loading