Skip to content

What the x/tokenization module is, how its pieces fit together, and the order to read this tab in.

x/tokenization is the Cosmos SDK module that defines BitBadges tokens. Read this tab if you build against the chain directly or need to understand the rules an application enforces on your behalf.

What the Module Does

A collection is an on-chain object that holds tokens with numeric IDs. Every transfer of those tokens runs through an approval engine that checks three layers of rules: the collection's rules, the sender's rules, and the recipient's rules. The manager configures the collection's rules and locks them with permissions. Nothing runs in a smart contract; the module enforces every rule on every transfer.

bash
bb query tokenization get-collection 1

Main properties:

  • No code and no smart contracts. Everything is module state and Cosmos messages.
  • Three approval levels (collection, outgoing, incoming) that a transfer must satisfy.
  • Approval criteria that gate transfers on payments, proofs, votes, token ownership, dynamic stores, EVM queries, and time.
  • Any IBC coin can be attached to a transfer as a payment.
  • Tokens can be wrapped into x/bank denoms for IBC and for the DEX.
  • Extendable with the EVM precompiles and the extension hooks.

Module Map

AreaWhat it coversRead when
ConceptsThe data model: ranges, balances, collections, address lists, approvals, permissionsFirst. Everything else assumes it.
Approval CriteriaEvery field of approvalCriteria and how each one is enforcedDesigning transferability
MessagesOne page per transaction messageBuilding a transaction
QueriesOne page per queryReading chain state
IBC and wrappingAlias denoms, wrapper paths, backed minting, transfer hooksMoving tokens across chains or into the DEX
IntegrateStandards, extension hooks, ante handler gatesExtending the chain itself
BB-402Payment-required protocol built on approvalsCharging for access
Chain tabThe other modules (x/gamm, x/managersplitter, ...), EVM precompiles, endpoints, nodesAnything about the chain around the module

Reading Order

  1. Concepts, in the order that page lists.
  2. Approval Criteria once you know what an approval is.
  3. Messages and Queries as reference while you build.

Most application developers do not need this tab. The BitBadges API returns balances and metadata, and the bb CLI and MCP builder tools generate valid transactions without hand-writing the structures described here.

Edit this page on GitHub