Skip to content

Commit

Permalink
Merge branch 'main' into eshaben/v1.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
martin0995 authored Jan 13, 2025
2 parents d3586ff + cebe262 commit f4c5e32
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,3 +138,6 @@ The final step in the deployment process is to set the NTT Manager as a minter o
- If you have a custom process to manage token minters, you should now follow that process to add the corresponding NTT Manager as a minter

By default, NTT transfers to EVM blockchains support automatic relaying via the Wormhole relayer, which doesn't require the user to perform a transaction on the destination chain to complete the transfer.

!!!important
To proceed with testing and find integration examples, check out the [NTT Post Deployment](/docs/build/contract-integrations/native-token-transfers/deployment-process/post-deployment/){target=\_blank} page.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Initialize a new `deployment.json` file specifying the network:
cargo install spl-token-cli
```

6. Create a new token with the SPL Token CLI:
6. Create a new token with the SPL Token CLI (make sure you have enough balance to pay for the transaction):
```bash
spl-token create-token
```
Expand All @@ -86,17 +86,18 @@ Initialize a new `deployment.json` file specifying the network:
!!! note
NTT versions `>=v2.0.0+solana` support SPL tokens with transfer hooks.

### Hub Chain Requirements
### Deployment Mode Requirements

For hub chain deployments on Solana, the token can be either an SPL or Token2022. Hub chain tokens do not require additional configuration, such as setting the mint authority.
The NTT CLI supports two deployment models: **Hub-and-Spoke** and **Burn-and-Mint**.
For a detailed explanation of these models, see the [Deployment Models](/docs/learn/messaging/native-token-transfers/deployment/){target=\_blank} page.

For more detailed information, see the [Deployment Models](/docs/learn/messaging/native-token-transfers/deployment/){target=\_blank} page.
#### Hub-and-Spoke

### Burning Mode Requirements
No additional configuration is required for hub-and-spoke deployments. Tokens retain their original mint authority, so the steps below are not necessary. You can [generate a new NTT program key pair](/docs/build/contract-integrations/native-token-transfers/deployment-process/deploy-to-solana/#generate-ntt-program-key-pair) and [deploy the NTT program](/docs/build/contract-integrations/native-token-transfers/deployment-process/deploy-to-solana/#__tabbed_2_2) directly.

In burning mode, tokens require their mint authority to be assigned to the NTT program. This allows the NTT Manager to mint and burn tokens as needed during cross-chain transfers.
#### Burn-and-Mint

All necessary steps for configuring burning mode, including mint authority setup, are explained in the sections below.
For burn-and-mint deployments, you must configure the token's mint authority to enable cross-chain transfers. To complete the required setup, follow the steps in the following sections.

## Configuration and Deployment

Expand Down Expand Up @@ -136,9 +137,17 @@ spl-token authorize INSERT_TOKEN_ADDRESS mint INSERT_DERIVED_PDA

Generate or export your payer key pair, then run:

```bash
ntt add-chain Solana --latest --mode burning --token INSERT_TOKEN_ADDRESS --payer INSERT_YOUR_KEYPAIR_JSON --program-key INSERT_YOUR_NTT_PROGRAM_KEYPAIR_JSON
```
=== "Burn-and-Mint"

```bash
ntt add-chain Solana --latest --mode burning --token INSERT_TOKEN_ADDRESS --payer INSERT_YOUR_KEYPAIR_JSON --program-key INSERT_YOUR_NTT_PROGRAM_KEYPAIR_JSON
```

=== "Hub-and-Spoke"

```bash
ntt add-chain Solana --latest --mode locking --token INSERT_TOKEN_ADDRESS --payer INSERT_YOUR_KEYPAIR_JSON --program-key INSERT_YOUR_NTT_PROGRAM_KEYPAIR_JSON
```

!!! note
The `add-chain` command accepts an optional `--solana-priority-fee` flag, which sets the priority fee in microlamports. The default is `50000`.
Expand Down Expand Up @@ -177,3 +186,6 @@ ntt push --payer INSERT_YOUR_KEYPAIR_JSON
```

By default, NTT transfers to Solana support manual relaying, which requires the user to perform a transaction on Solana to complete the transfer. UI components such as Wormhole Connect support this out of the box. For automatic Wormhole relaying support on Solana, [contact](https://forms.clickup.com/45049775/f/1aytxf-10244/JKYWRUQ70AUI99F32Q){target=\_blank} Wormhole contributors.

!!!important
To proceed with testing and find integration examples, check out the [NTT Post Deployment](/docs/build/contract-integrations/native-token-transfers/deployment-process/post-deployment/){target=\_blank} page.
6 changes: 6 additions & 0 deletions learn/messaging/native-token-transfers/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ description: Explore Wormhole's Native Token Transfers for flexible cross-chain

# Native Token Transfers

!!!tip "Looking to deploy NTT?"
If you're ready to deploy NTT or access the CLI, follow the detailed [NTT Deployment Section](/docs/build/contract-integrations/native-token-transfers/deployment-process/){target=\_blank}.

- For deployment steps on EVM, visit the [Deploy to EVM page](/docs/build/contract-integrations/native-token-transfers/deployment-process/deploy-to-evm/){target=\_blank}
- For deployment steps on Solana, visit the [Deploy to Solana page](/docs/learn/messaging/native-token-transfers/overview/){target=\_blank}

## Introduction

Wormhole's Native Token Transfers (NTT) is an open source, flexible, and composable framework for transferring tokens across blockchains. Integrators have complete control over how their tokens that use NTT behave on each chain, including the token standard, metadata, ownership, upgradeability, and custom features.
Expand Down

0 comments on commit f4c5e32

Please sign in to comment.