Comment on page
BRC-21 assets are essentially BRC-20 assets, but unlike "created out of thin air" BRC-20 assets, BRC-21 assets are generated by locking assets from a starting chain (such as ETH, DOT, ATOM, DAI, etc.). In other words, the BRC-21 standard provides a possibility to mint BRC-20 versions of assets from other chains on the Bitcoin network.
From a technical perspective, cross-chain functionality for BRC-21 assets can be achieved through three components, enabling complete decentralization:
Starting Chain Smart Contract: Responsible for handling minting and redemption operations on the starting chain.
Custom Indexer: Validates BRC-21 minting, transferring, redemption, and smart contract states on the Bitcoin network.
Bitcoin Relay (BTC-Relay): Acts as a lightweight client on the Bitcoin network to achieve smart contract functionality, verifying transaction inclusion and parsing on the Bitcoin network.
Deploying BRC-21 tokens is similar to deploying BRC-20 tokens, but there are some differences in the details. For example, the "max" field, which is used to define the maximum supply, is no longer mandatory and can be optional because the maximum supply of the underlying asset of BRC-21 is generally defined on the starting chain. The "lim" field, which defined the minting restriction, has been removed because BRC-21 assets must adhere to strict minting and redemption rules, so there is no need to limit how many tokens can be minted in a single transaction. A new field, "src," has been added to specify the starting chain, which can be a string of letters (e.g., Ethereum) or a number (but an additional list must be provided). Another new field, "id," has been added to specify the target token on the starting chain, which can be filled with the contract address of that token.