Registering a token within a Private Network

Overview

Before a token can be teleported between institutions in the Rayls ecosystem, it must be registered in the Rayls Private Network. This guide sets out the process for registering a token, so that it is approved and ready for teleport transactions.

Pre-requisites

Before starting the token registration process, ensure that the token is deployed and minted in your Rayls Sovereign ledger.


Step-by-Step

1. Request Token Registration

After deploying and minting your token in the Rayls Sovereign ledger:

Initiate Registration Request:

As the Rayls Sovereign owner, use the Rayls CLI command below to request the token's registration in the Rayls Private Network.

Example:

npx hardhat deployToken --pl <your-PL> --symbol <your-symbol>

This command submits a registration request to the Private Network Operator.

Response

Deploying token on <privacy-ledger-name>...  
Token Deployed At Address <token-contract-address>  
Token Registration Submitted, wait until relayer retrieves the generated resource

To check if it's registered, please use the following command:  
npx hardhat checkTokenResourceId --pl <your-PL> --token-address <token-contract-address>

2. Private Network Operator Approval

Review and Approve:

The Private Network Operator reviews the registration request and confirms that the token complies with the Rayls Private Network's governance rules and meets all required criteria.

Once the review is complete, the Private Network Operator approves the token registration, adds the token (ID, info) to the Token Registry on the Private Network Hub, and marks it as active. The registry entry is then replicated to each participating institution, into the TokenRegistryReplicaV1 contract in its Sovereign ledger, which is what lets the Sovereign ledgers of other participating institutions validate the token locally and receive it.

Read more about the token approval process in the Approving Token Registrations page.

3. Token Registered

Confirmation of Registration:

Once registered, the token receives a resourceID, which is the universal identity of a token within the Rayls Private Network. After a resourceID is assigned, the token becomes visible to every participating institution in the Rayls Private Network via the Token Registry on the Private Network Hub. The registry holds information such as:

  • Token ID (resourceID)
  • Token Status (e.g., active)
  • Contract Code

Querying the Registered Token:

Once registered, the token can be queried via the CLI. Use the following Rayls CLI command to check the resourceID assignment:

Example:

npx hardhat checkTokenResourceId --pl <your-PL> --token-address <token-contract-address>

This command allows the Rayls Sovereign owner to check the registration status through the resourceID assignment of its tokens.

Response:

# IF TOKEN APPROVED
Resource id is: <resource-id>

# IF TOKEN APPROVAL PENDING
No resource id generated! Wait until Ven Operator approves the token.

Post-Registration:

Once the token is registered:

  • Teleport Transactions: The token can now be used in teleport transactions between institutions in the Rayls Private Network.
  • Only tokens that have been registered and approved in the Rayls Private Network are eligible for teleport transactions. If an unapproved token is used in a teleport transaction, the cross-chain process will fail at the initiation stage in the sender's Rayls Sovereign ledger, returning the following error message:
Token not registered.

Token registration is the first step in enabling the secure transfer of digital assets between institutions in the Rayls ecosystem. Following this guide ensures that your tokens are properly registered and compliant with Rayls Private Network governance rules, which is what makes teleport transactions available to you.


Did this page help you?