Skip to content

Commit c91c247

Browse files
k4m4isi8787
andauthored
chore(xrpl): remove token instance registration script & update guides (#1064)
Co-authored-by: isi8787 <[email protected]>
1 parent 59c3e26 commit c91c247

File tree

5 files changed

+3
-103
lines changed

5 files changed

+3
-103
lines changed

xrpl/README.md

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -474,20 +474,6 @@ Here's an example:
474474
ts-node xrpl/register-remote-token.js -e devnet-amplifier -n xrpl-dev --tokenId d059cbf3cf520f4d96064e094cb5e8fbb501bc4744034a5ca840dc2beb658aaa --currency FOO
475475
```
476476

477-
### Register Token Instance
478-
479-
Add support for bridging a token from/to some remote chain. Decimals should be set to the decimal representation of the relevant token on the given remote chain.
480-
481-
```bash
482-
ts-node xrpl/register-token-instance.js -e <env> -n <chain-name> --tokenId <token-id> --sourceChain <source-chain> --decimals <token-decimals>
483-
```
484-
485-
Here's an example:
486-
487-
```bash
488-
ts-node xrpl/register-token-instance.js -e devnet-amplifier -n xrpl-dev --tokenId fc00a5a83e7c6814a85ba59222e35a15a3c2b45b318b3c837e5c4aafc0b301ca --sourceChain xrpl-evm-devnet --decimals 6
489-
```
490-
491477
### Register Token Metadata
492478

493479
Register an XRPL token's metadata on ITS Hub.

xrpl/docs/deploy-local-token.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -144,17 +144,7 @@ Note that manual executation of the proof might be necessary if relayer fails to
144144
ts-node evm/gateway.js -n <destination chain> --action execute --messageId $MESSAGE_ID --sourceChain axelar --sourceAddress <itsHubAddress> --destination <destination gateway contract address> --payload 0x$PAYLOAD
145145
```
146146

147-
### 8. Token Instance Registration
148-
149-
Once both legs of the remote token deployment have succeeded, register the token instance
150-
to enable bridging this newly-deployed token between XRPL and the remote destination chain.
151-
Note that XRPL tokens are always deployed to remote chains with `15` decimals of precision.
152-
153-
```bash
154-
ts-node xrpl/register-token-instance.js --tokenId $TOKEN_ID --sourceChain $DESTINATION_CHAIN --decimals 15
155-
```
156-
157-
Repeat steps 4-8 for every `DESTINATION_CHAIN` that you want the XRPL token to be deployed to.
147+
Repeat steps 4-7 for every `DESTINATION_CHAIN` that you want the XRPL token to be deployed to.
158148

159149
## Cross-Chain Transfer Testing
160150

xrpl/docs/deploy-remote-token.md

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -80,17 +80,6 @@ Once the first leg of the remote token deployment has succeeded, register the re
8080
ts-node xrpl/register-remote-token.js -n $DESTINATION_CHAIN --tokenId $TOKEN_ID --currency $XRPL_CURRENCY_CODE
8181
```
8282

83-
### 3. XRPL Token Instance Registration
84-
85-
Finally, register the token instance on the `XRPLGateway` contract to enable transferring this newly-deployed token between the remote source chain and XRPL.
86-
87-
```bash
88-
ts-node xrpl/register-token-instance.js -n $DESTINATION_CHAIN --tokenId $TOKEN_ID --sourceChain $SOURCE_CHAIN --decimals $DECIMALS
89-
```
90-
91-
To be able to transfer this token from the XRPL directly to other chains where the token has been deployed to,
92-
re-run the token instance registration script, passing the relevant chain as source chain and the decimals that the token has been deployed with on that chain.
93-
9483
## Cross-Chain Transfer Testing
9584

9685
To test the newly deployed token, refer to [2025-02-v.1.0.0.md](../../releases/xrpl/2025-02-v.1.0.0.md).

xrpl/docs/link-token.md

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -142,22 +142,13 @@ GAS_FEE=
142142
ts-node evm/interchainTokenFactory.js -n $SOURCE_CHAIN --action linkToken --destinationChain $DESTINATION_CHAIN --destinationTokenAddress $XRPL_TOKEN_ADDRESS --tokenManagerType $TOKEN_MANAGER_TYPE --linkParams $OPERATOR --salt $SALT --gasValue $GAS_FEE
143143
```
144144

145-
### 6. XRPL Token Instance Registration
146-
147-
**_NOTE:_**
148-
The decimal precision of `15` is hardcoded to avoid double scaling between the XRPL contracts and ITS Hub. Future release of XRPL contracts will use the ITS Hub instance directly.
149-
150-
```bash
151-
ts-node xrpl/register-token-instance.js -n $DESTINATION_CHAIN --tokenId $TOKEN_ID --sourceChain $SOURCE_CHAIN --decimals 15
152-
```
153-
154-
### 7. XRPL Remote Token Registration
145+
### 6. XRPL Remote Token Registration
155146

156147
```bash
157148
ts-node xrpl/register-remote-token.js -n $DESTINATION_CHAIN --tokenId $TOKEN_ID --currency $XRPL_CURRENCY_CODE
158149
```
159150

160-
## 8. Grant Mint Role to Token Manager
151+
## 7. Grant Mint Role to Token Manager
161152

162153
After linking is complete, if you selected the `MintBurn` token manager type, then it is necessary to
163154
grant the token manager minting and burning permissions. Since this logic is token-specific, you'll need to determine the right method to execute for your token.

xrpl/register-token-instance.js

Lines changed: 0 additions & 56 deletions
This file was deleted.

0 commit comments

Comments
 (0)