A utility script for transferring token mint authority out of NTT.
- Clone the Repository:
git clone https://github.com/wormhole-foundation/demo-ntt-token-mint-authority-transfer
cd demo-ntt-token-mint-authority-transfer- Install Dependencies:
npm install-
Replace
<TODO>'s and verify the following in thetransfer-mint-authority.tsscript: You will find most of the needed info in yourdeployment.jsonfile.- Keypair Path Config
- Network Config
- SPL Token Config
- NTT Config
-
Ensure NTT is paused:
-
If using the NTT CLI, this can be done as follows:
- Set
pausedfor theSolanachain totruein thedeployment.jsonfile:
{ "network": "", "chains": { "Solana": { "version": "3.x.x", - "paused": false, + "paused": true, ... } }- Run
ntt pushto sync the changes on-chain.
- Set
-
Via TS script, this can be done as follows:
const pauseTxs = ntt.pause(sender);
-
npm run transfer <NEW_AUTHORITY>Note
The above only executes the first step of the transfer. Run npm run claim <NEW_AUTHORITY> to complete the transfer.
npm run claim <NEW_AUTHORITY>Note
In case of claiming via SPL Multisig with m > 1, make sure ADDITIONAL_SIGNER_KEYPAIR_PATHS (Keypair Path Config) in the transfer-mint-authority.ts script is correct.