How to register crosschain assets
This recipe demonstrates how to register crosschain assets using FT4 admin operations. This is essential for enabling assets from one blockchain to be used on another blockchain within the Chromia ecosystem.
- JS/TS client
Prerequisites
- Chromia CLI
- Docker (for local blockchain)
- Node.js
- FT4 client
- Postchain client
Demo script
Key Features
This recipe includes examples for:
- Admin operations - Using FT4 admin functions to register crosschain assets
- Crosschain asset management - Managing assets across multiple blockchains
- Asset registration - Establishing the connection between origin and target blockchains
- Signature provider setup - Configuring admin signature providers for authorization
Architecture Overview
The recipe includes both server and client components:
Rell Module (Server-side)
- FT4 integration - Uses FT4 library for crosschain asset management
- Admin operations - Implements admin-level asset registration functions
- Test coverage - Unit tests demonstrating registration process
JavaScript Client
- Admin authentication - Uses admin signature provider for authorization
- Asset configuration - Configures asset ID and origin blockchain RID
- Registration execution - Calls the
registerCrosschainAssetfunction
Registration Process
The crosschain asset registration follows this workflow:
- Admin setup - Configure admin private/public key pair for authorization
- Asset identification - Specify the asset ID to be registered
- Origin blockchain - Define the origin blockchain RID where the asset exists
- Registration call - Execute the
registerCrosschainAssetoperation - Verification - Confirm successful registration through queries
Required Information
To register a crosschain asset, you need:
- Admin credentials - Private and public key pair with admin privileges
- Asset ID - The unique identifier of the asset to register
- Origin blockchain RID - The RID of the blockchain where the asset originates
- Target blockchain - The blockchain where you want to register the asset
Administrative Requirements
This operation requires administrative privileges:
- Admin keypair - Must have admin rights on the target blockchain
- Proper authorization - Admin signature provider must be correctly configured
- Network access - Connection to the appropriate network nodes
- Asset validation - The asset must exist on the origin blockchain
Use Cases
Crosschain asset registration is essential for:
- Multi-chain applications - Apps that operate across multiple Chromia blockchains
- Asset bridges - Enabling asset transfers between different chains
- Ecosystem expansion - Growing the available assets on new blockchains
- Interoperability - Creating connections between different blockchain environments
Learn more
- FT4 client documentation — covers FT4 operations and admin functions.
- Asset management — detailed guide on FT4 assets and crosschain functionality.
- JavaScript/TypeScript client — covers setup, connection, and usage patterns.