TransferRedeemed

### TransferRedeemed

Emitted when a transfer has been redeemed (either minted or unlocked on the recipient chain). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
event TransferRedeemed(bytes32 indexed digest)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the message.


Native Token Transfers Manager Contract (EVM)

TransferSent

### TransferSent

Emitted when a message is sent from the NttManager. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
event TransferSent(
    bytes32 indexed recipient,
    bytes32 indexed refundAddress,
    uint256 amount,
    uint256 fee,
    uint16 recipientChain,
    uint64 msgSequence
)
```

??? interface "Parameters"

    `recipient` ++"bytes32"++

    The recipient of the message.

    ---

    `refundAddress` ++"bytes32"++

    The address on the destination chain to which the refund of unused gas will be paid.

    ---

    `amount` ++"uint256"++

    The amount transferred.

    ---

    `fee` ++"uint256"++

    The amount of ether sent along with the tx to cover the delivery fee.

    ---

    `recipientChain` ++"uint16"++

    The chain ID of the recipient.

    ---

    `msgSequence` ++"uint64"++

    The unique sequence ID of the message.


TransferSent (Digest Version)

### TransferSent (Digest Version)

Emitted when a message is sent from the NttManager (digest version). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
event TransferSent(bytes32 indexed digest)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the message.


Functions

## Functions


attestationReceived

### attestationReceived

Called by transceivers when the attestation is received. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function attestationReceived(
    uint16 sourceChainId,
    bytes32 sourceNttManagerAddress,
    TransceiverStructs.NttManagerMessage memory payload
) external
```

??? interface "Parameters"

    `sourceChainId` ++"uint16"++

    The chain ID of the source.

    ---

    `sourceNttManagerAddress` ++"bytes32"++

    The address of the source NttManager.

    ---

    `payload` ++"TransceiverStructs.NttManagerMessage"++

    The message payload containing transfer details.

    ??? child "`NttManagerMessage` struct"

        `id` ++"bytes32"++

        Unique message identifier (incrementally assigned on EVM chains).

        ---

        `sender` ++"bytes32"++

        Original message sender address.

        ---

        `payload` ++"bytes"++

        Payload that corresponds to the transfer type.

> **Emits**: `MessageAlreadyExecuted` (if the message was already executed), `OutboundTransferCancelled` or `TransferRedeemed` (if the message execution succeeds), `TransferSent` (if the message execution succeeds)


cancelOutboundQueuedTransfer

### cancelOutboundQueuedTransfer

Cancel an outbound transfer that's been queued due to rate limiting. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function cancelOutboundQueuedTransfer(uint64 messageSequence) external
```

??? interface "Parameters"

    `messageSequence` ++"uint64"++

    The sequence number of the queued transfer to cancel.

> **Emits**: `OutboundTransferCancelled`


completeInboundQueuedTransfer

### completeInboundQueuedTransfer

Complete an inbound transfer that's been queued due to rate limiting. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function completeInboundQueuedTransfer(bytes32 digest) external
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the queued transfer.

> **Emits**: `TransferRedeemed`


completeOutboundQueuedTransfer

### completeOutboundQueuedTransfer

Complete an outbound transfer that's been queued due to rate limiting. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function completeOutboundQueuedTransfer(uint64 messageSequence) external payable returns (uint64)
```

??? interface "Parameters"

    `messageSequence` ++"uint64"++

    The sequence number of the queued transfer.

??? interface "Returns"

    `sequence` ++"uint64"++

    The sequence number of the completed transfer.

> **Emits**: `TransferSent` (two variants)


executeMsg

### executeMsg

Execute a message when the threshold is met. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function executeMsg(
    uint16 sourceChainId,
    bytes32 sourceNttManagerAddress,
    TransceiverStructs.NttManagerMessage memory message
) external
```

??? interface "Parameters"

    `sourceChainId` ++"uint16"++

    The chain ID of the source.

    ---

    `sourceNttManagerAddress` ++"bytes32"++

    The address of the source NttManager.

    ---

    `message` ++"TransceiverStructs.NttManagerMessage"++

    The message to execute containing transfer details.

    ??? child "`NttManagerMessage` struct"

        `id` ++"bytes32"++

        Unique message identifier (incrementally assigned on EVM chains).

        ---

        `sender` ++"bytes32"++

        Original message sender address.

        ---

        `payload` ++"bytes"++

        Payload that corresponds to the transfer type.

> **Emits**: `MessageAlreadyExecuted` (if already executed), `OutboundTransferCancelled`, or `TransferRedeemed` (depending on the transfer type)


getCurrentInboundCapacity

### getCurrentInboundCapacity

Returns the currently remaining inbound capacity from a chain. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getCurrentInboundCapacity(uint16 chainId) external view returns (uint256)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to check capacity for.

??? interface "Returns"

    `capacity` ++"uint256"++

    The current available inbound capacity from the specified chain.


getCurrentOutboundCapacity

### getCurrentOutboundCapacity

Returns the currently remaining outbound capacity. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getCurrentOutboundCapacity() public view returns (uint256)
```

??? interface "Returns"

    `capacity` ++"uint256"++

    The current available outbound capacity.


getInboundLimitParams

### getInboundLimitParams

Returns the inbound rate limit parameters for a chain. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getInboundLimitParams(uint16 chainId_) external view returns (RateLimitParams memory)
```

??? interface "Parameters"

    `chainId_` ++"uint16"++

    The chain ID to get parameters for.

??? interface "Returns"

    `params` ++"RateLimitParams struct"++

    The inbound rate limit parameters for the specified chain.

    ??? child "`RateLimitParams` struct"

        `limit` ++"TrimmedAmount"++

        Current rate limit value.

        ---

        `currentCapacity` ++"TrimmedAmount"++

        The current capacity left.

        ---

        `lastTxTimestamp` ++"uint64"++

        Timestamp of when capacity was previously consumed.


getInboundQueuedTransfer

### getInboundQueuedTransfer

Returns queued transfer details for inbound queue. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getInboundQueuedTransfer(bytes32 digest) external view returns (InboundQueuedTransfer memory)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the queued transfer.

??? interface "Returns"

    `transfer` ++"InboundQueuedTransfer struct"++

    The queued transfer details.

    ??? child "`InboundQueuedTransfer` struct"

        `amount` ++"TrimmedAmount"++

        The trimmed amount of the transfer.

        ---

        `txTimestamp` ++"uint64"++

        The timestamp of the transfer.

        ---

        `recipient` ++"address"++

        The recipient of the transfer.


getMode

### getMode

Returns the mode (locking or burning) of the NttManager. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function getMode() public view returns (uint8)
```

??? interface "Returns"

    `mode` ++"uint8"++

    The mode of the NttManager (0 for LOCKING, 1 for BURNING).

    ??? child "`Mode` enum values"

        `LOCKING` ++"0"++

        Tokens are locked on the source chain and unlocked on the destination chain.

        ---

        `BURNING` ++"1"++

        Tokens are burned on the source chain and minted on the destination chain.


getMigratesImmutables

### getMigratesImmutables

Returns whether the contract migrates immutables. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
function getMigratesImmutables() external view returns (bool)
```

??? interface "Returns"

    `migrates` ++"bool"++

    Whether the contract migrates immutables.


getOutboundLimitParams

### getOutboundLimitParams

Returns the outbound rate limit parameters. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getOutboundLimitParams() public pure virtual returns (RateLimitParams memory)
```

??? interface "Returns"

    `params` ++"RateLimitParams struct"++

    The outbound rate limit parameters.

    ??? child "`RateLimitParams` struct"

        `limit` ++"TrimmedAmount"++

        Current rate limit value.

        ---

        `currentCapacity` ++"TrimmedAmount"++

        The current capacity left.

        ---

        `lastTxTimestamp` ++"uint64"++

        Timestamp of when capacity was previously consumed.


getOutboundQueuedTransfer

### getOutboundQueuedTransfer

Returns queued transfer details for outbound queue. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
function getOutboundQueuedTransfer(uint64 queueSequence) external view returns (OutboundQueuedTransfer memory)
```

??? interface "Parameters"

    `queueSequence` ++"uint64"++

    The sequence number of the queued transfer.

??? interface "Returns"

    `transfer` ++"OutboundQueuedTransfer struct"++

    The queued transfer details.

    ??? child "`OutboundQueuedTransfer` struct"

        `recipient` ++"bytes32"++

        The recipient of the transfer.

        ---

        `refundAddress` ++"bytes32"++

        The refund address for unused gas.

        ---

        `amount` ++"TrimmedAmount"++

        The amount of the transfer, trimmed.

        ---

        `txTimestamp` ++"uint64"++

        The timestamp of the transfer.

        ---

        `recipientChain` ++"uint16"++

        The chain of the recipient.

        ---

        `sender` ++"address"++

        The sender of the transfer.

        ---

        `transceiverInstructions` ++"bytes"++

        Additional instructions for the recipient chain.


getPeer

### getPeer

Returns peer information for a given chain ID. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function getPeer(uint16 chainId_) external view returns (NttManagerPeer memory)
```

??? interface "Parameters"

    `chainId_` ++"uint16"++

    The chain ID of the peer.

??? interface "Returns"

    `peer` ++"NttManagerPeer struct"++

    The peer information for the given chain ID.

    ??? child "`NttManagerPeer` struct"

        `peerAddress` ++"bytes32"++

        The address of the peer contract on the remote chain.

        ---

        `tokenDecimals` ++"uint8"++

        The number of decimals for the peer token.


getThreshold

### getThreshold

Returns the number of transceivers that must attest to a message. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function getThreshold() external view returns (uint8)
```

??? interface "Returns"

    `threshold` ++"uint8"++

    The number of attestations required for a message to be considered valid.


getTransceiverInfo

### getTransceiverInfo

Returns the info for all enabled transceivers. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
function getTransceiverInfo() external view returns (TransceiverInfo[] memory)
```

??? interface "Returns"

    `info` ++"TransceiverInfo[] memory"++

    An array of transceiver information structs.

    ??? child "`TransceiverInfo` struct"

        `registered` ++"bool"++

        Whether this transceiver is registered.

        ---

        `enabled` ++"bool"++

        Whether this transceiver is enabled.

        ---

        `index` ++"uint8"++

        Index of the transceiver.


getTransceivers

### getTransceivers

Returns the enabled Transceiver contracts. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
function getTransceivers() external pure returns (address[] memory result)
```

??? interface "Returns"

    `result` ++"address[] memory"++

    An array of enabled transceiver addresses.


initialize

### initialize

Initializes the contract. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
function initialize() external payable
```


isMessageApproved

### isMessageApproved

Checks if a message has been approved with at least the minimum threshold of attestations from distinct endpoints. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function isMessageApproved(bytes32 digest) external view returns (bool)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The keccak-256 hash of the message.

??? interface "Returns"

    `approved` ++"bool"++

    Whether the message has been approved.


isMessageExecuted

### isMessageExecuted

Checks if a message has been executed. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function isMessageExecuted(bytes32 digest) external view returns (bool)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The keccak-256 hash of the message.

??? interface "Returns"

    `executed` ++"bool"++

    Whether the message has been executed.


isPaused

### isPaused

Returns true if the contract is paused, and false otherwise. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
function isPaused() external view returns (bool)
```

??? interface "Returns"

    `paused` ++"bool"++

    Whether the contract is paused.


messageAttestations

### messageAttestations

Returns the number of attestations for a given message. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function messageAttestations(bytes32 digest) external view returns (uint8)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The keccak-256 hash of the message.

??? interface "Returns"

    `count` ++"uint8"++

    The number of attestations for the message.


migrate

### migrate

Migrates the contract state to a new implementation. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
function migrate() external
```


nextMessageSequence

### nextMessageSequence

Returns the next message sequence. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function nextMessageSequence() external view returns (uint64)
```

??? interface "Returns"

    `sequence` ++"uint64"++

    The next message sequence number.


owner

### owner

Returns the address of the current owner. *(Defined in [OwnableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/OwnableUpgradeable.sol){target=\_blank})*

```sol
function owner() external view returns (address)
```

??? interface "Returns"

    `owner` ++"address"++

    The address of the current owner.


pause

### pause

Pauses the manager. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function pause() external
```

> **Emits**: `Paused`


pauser

### pauser

Returns the current pauser account address. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
function pauser() external view returns (address)
```

??? interface "Returns"

    `pauser` ++"address"++

    The address of the current pauser.


quoteDeliveryPrice

### quoteDeliveryPrice

Fetches the delivery price for a given recipient chain transfer. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function quoteDeliveryPrice(
    uint16 recipientChain,
    bytes memory transceiverInstructions
) public view returns (uint256[] memory, uint256)
```

??? interface "Parameters"

    `recipientChain` ++"uint16"++

    The chain ID of the recipient.

    ---

    `transceiverInstructions` ++"bytes"++

    The transceiver-specific instructions for the transfer.

??? interface "Returns"

    `deliveryQuotes` ++"uint256[] memory"++

    An array of delivery quotes from each transceiver.

    ---

    `totalPrice` ++"uint256"++

    The total price for delivery across all transceivers.


removeTransceiver

### removeTransceiver

Removes/disables a transceiver address in the registry of a given chain. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function removeTransceiver(address transceiver) external
```

??? interface "Parameters"

    `transceiver` ++"address"++

    The address of the transceiver contract to remove.


setInboundLimit

### setInboundLimit

Set the inbound transfer limit for a specific chain. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function setInboundLimit(uint256 limit, uint16 chainId_) external
```

??? interface "Parameters"

    `limit` ++"uint256"++

    The new inbound transfer limit.

    ---

    `chainId_` ++"uint16"++

    The chain ID to set the limit for.


setOutboundLimit

### setOutboundLimit

Set the outbound transfer limit. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function setOutboundLimit(uint256 limit) external
```

??? interface "Parameters"

    `limit` ++"uint256"++

    The new outbound transfer limit.


setPeer

### setPeer

Set peer contract information for a specific chain; this is local manager configuration (no cross-chain message) and must be called on both chains. If either side is unset or mismatched, inbound verification or amount trimming fails ([`InvalidPeer`](/docs/products/token-transfers/native-token-transfers/reference/manager/evm/#invalidpeer), [`InvalidPeerDecimals`](/docs/products/token-transfers/native-token-transfers/reference/manager/evm/#invalidpeerdecimals)). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

!!! tip "Example"
    - **On Chain A**: Register Chain B as a peer with B’s manager address (`peerContract`), B’s token decimals (`decimals`), and the inbound limit from B → A (`inboundLimit`).
    - **On Chain B**: Register Chain A the same way (A’s manager, A’s token decimals, inbound limit from A → B).

```sol
function setPeer(
    uint16 peerChainId,
    bytes32 peerContract,
    uint8 decimals,
    uint256 inboundLimit
) external
```

??? interface "Parameters"

    `peerChainId` ++"uint16"++

    The chain ID of the peer.

    ---

    `peerContract` ++"bytes32"++

    The address of the peer contract.

    ---

    `decimals` ++"uint8"++

    The number of decimals for the peer token.

    ---

    `inboundLimit` ++"uint256"++

    The inbound transfer limit for this peer.

> **Emits**: `PeerUpdated`


setThreshold

### setThreshold

Sets the threshold for the number of attestations required for a message to be considered valid. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function setThreshold(uint8 threshold) external
```

??? interface "Parameters"

    `threshold` ++"uint8"++

    The number of attestations required.

> **Emits**: `ThresholdChanged`


setTransceiver

### setTransceiver

Sets the transceiver for the given chain. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function setTransceiver(address transceiver) external
```

??? interface "Parameters"

    `transceiver` ++"address"++

    The address of the transceiver contract.

> **Emits**: `TransceiverAdded`


tokenDecimals

### tokenDecimals

Returns the number of decimals for the token. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function tokenDecimals() external view returns (uint8)
```

??? interface "Returns"

    `decimals` ++"uint8"++

    The number of decimals for the token.


transceiverAttestedToMessage

### transceiverAttestedToMessage

Returns if the transceiver has attested to the message. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function transceiverAttestedToMessage(bytes32 digest, uint8 index) external view returns (bool)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The keccak-256 hash of the message.

    ---

    `index` ++"uint8"++

    The index of the transceiver.

??? interface "Returns"

    `attested` ++"bool"++

    Whether the transceiver has attested to the message.


transfer (basic)

### transfer (basic)

Transfer tokens (simple version). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function transfer(
    uint256 amount,
    uint16 recipientChain,
    bytes32 recipient
) external payable returns (uint64)
```

??? interface "Parameters"

    `amount` ++"uint256"++

    The amount of tokens to transfer.

    ---

    `recipientChain` ++"uint16"++

    The chain ID of the recipient.

    ---

    `recipient` ++"bytes32"++

    The recipient address on the destination chain.

??? interface "Returns"

    `sequence` ++"uint64"++

    The sequence number of the transfer.

> **Emits**: `OutboundTransferRateLimited` (if rate limited), `TransferSent` (two variants, if successful)


transfer (advanced)

### transfer (advanced)

Transfer tokens (full version with additional parameters). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
function transfer(
    uint256 amount,
    uint16 recipientChain,
    bytes32 recipient,
    bytes32 refundAddress,
    bool shouldQueue,
    bytes memory transceiverInstructions
) external payable returns (uint64)
```

??? interface "Parameters"

    `amount` ++"uint256"++

    The amount of tokens to transfer.

    ---

    `recipientChain` ++"uint16"++

    The chain ID of the recipient.

    ---

    `recipient` ++"bytes32"++

    The recipient address on the destination chain.

    ---

    `refundAddress` ++"bytes32"++

    The address to refund unused gas to.

    ---

    `shouldQueue` ++"bool"++

    Whether to queue the transfer if rate limited.

    ---

    `transceiverInstructions` ++"bytes"++

    Additional instructions for transceivers.

??? interface "Returns"

    `sequence` ++"uint64"++

    The sequence number of the transfer.

> **Emits**: `OutboundTransferRateLimited` (if rate limited), `TransferSent` (two variants, if successful)


transferOwnership

### transferOwnership

[Transfer ownership](/docs/products/token-transfers/native-token-transfers/guides/transfer-ownership/#evm){target=\_blank} of the Manager and all Transceiver contracts. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function transferOwnership(address newOwner) external
```

??? interface "Parameters"

    `newOwner` ++"address"++

    The address of the new owner.

> **Emits**: `OwnershipTransferred`


transferPauserCapability

### transferPauserCapability

Transfers the ability to pause to a new account. *(Defined in [PausableOwnable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableOwnable.sol){target=\_blank})*

```sol
function transferPauserCapability(address newPauser) external
```

??? interface "Parameters"

    `newPauser` ++"address"++

    The address of the new pauser.

> **Emits**: `PauserTransferred`


upgrade

### upgrade

Upgrades to a new manager implementation. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function upgrade(address newImplementation) external
```

??? interface "Parameters"

    `newImplementation` ++"address"++

    The address of the new implementation contract.


unpause

### unpause

Unpauses the manager. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
function unpause() external
```

> **Emits**: `NotPaused`


Errors

## Errors


BurnAmountDifferentThanBalanceDiff

### BurnAmountDifferentThanBalanceDiff

Error when the burn amount differs from the balance difference. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error BurnAmountDifferentThanBalanceDiff(uint256 burnAmount, uint256 balanceDiff);
```

??? interface "Parameters"

    `burnAmount` ++"uint256"++

    The amount that was burned.

    ---

    `balanceDiff` ++"uint256"++

    The actual balance difference.


CallerNotTransceiver

### CallerNotTransceiver

Error when the caller is not the transceiver. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error CallerNotTransceiver(address caller);
```

??? interface "Parameters"

    `caller` ++"address"++

    The address that is not a transceiver.


CancellerNotSender

### CancellerNotSender

Error when someone other than the original sender tries to cancel a queued outbound transfer. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error CancellerNotSender(address canceller, address sender);
```

??? interface "Parameters"

    `canceller` ++"address"++

    The address attempting to cancel.

    ---

    `sender` ++"address"++

    The original sender's address.


CapacityCannotExceedLimit

### CapacityCannotExceedLimit

The new capacity cannot exceed the limit. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error CapacityCannotExceedLimit(TrimmedAmount newCurrentCapacity, TrimmedAmount newLimit);
```

??? interface "Parameters"

    `newCurrentCapacity` ++"TrimmedAmount"++

    The new current capacity value.

    ??? child "`TrimmedAmount` type"

        `amount` ++"uint64"++

        The amount value (64 bits).

        ---

        `decimals` ++"uint8"++

        The number of decimals (8 bits).

    ---

    `newLimit` ++"TrimmedAmount"++

    The new limit value.

    ??? child "`TrimmedAmount` type"

        `amount` ++"uint64"++

        The amount value (64 bits).

        ---

        `decimals` ++"uint8"++

        The number of decimals (8 bits).


DeliveryPaymentTooLow

### DeliveryPaymentTooLow

Payment for a transfer is too low. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error DeliveryPaymentTooLow(uint256 requiredPayment, uint256 providedPayment);
```

??? interface "Parameters"

    `requiredPayment` ++"uint256"++

    The required payment amount.

    ---

    `providedPayment` ++"uint256"++

    The payment amount that was provided.


DisabledTransceiver

### DisabledTransceiver

Error when the transceiver is disabled. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error DisabledTransceiver(address transceiver);
```

??? interface "Parameters"

    `transceiver` ++"address"++

    The disabled transceiver address.


InboundQueuedTransferNotFound

### InboundQueuedTransferNotFound

The inbound transfer is no longer queued. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error InboundQueuedTransferNotFound(bytes32 digest);
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the queued transfer.


InboundQueuedTransferStillQueued

### InboundQueuedTransferStillQueued

The transfer is still queued. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error InboundQueuedTransferStillQueued(bytes32 digest, uint256 transferTimestamp);
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the queued transfer.

    ---

    `transferTimestamp` ++"uint256"++

    The timestamp of the transfer.


InvalidInitialization

### InvalidInitialization

Error when the contract is in an invalid initialization state. *(Defined in [Initializable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/Initializable.sol){target=\_blank})*

```sol
error InvalidInitialization();
```


InvalidMode

### InvalidMode

The mode is invalid (neither LOCKING nor BURNING). *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidMode(uint8 mode);
```

??? interface "Parameters"

    `mode` ++"uint8"++

    The invalid mode value.


InvalidPauser

### InvalidPauser

Error when the pauser is not a valid pauser account. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
error InvalidPauser(address account);
```

??? interface "Parameters"

    `account` ++"address"++

    The invalid pauser account address.


InvalidPeer

### InvalidPeer

The peer for the chain does not match the configuration. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidPeer(uint16 chainId, bytes32 peerAddress);
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID of the peer.

    ---

    `peerAddress` ++"bytes32"++

    The peer address that doesn't match.


InvalidPeerChainIdZero

### InvalidPeerChainIdZero

The peer chain ID cannot be zero. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidPeerChainIdZero();
```


InvalidPeerDecimals

### InvalidPeerDecimals

The peer cannot have zero decimals. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidPeerDecimals();
```


InvalidPeerSameChainId

### InvalidPeerSameChainId

The peer cannot be on the same chain. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidPeerSameChainId();
```


InvalidPeerZeroAddress

### InvalidPeerZeroAddress

The peer cannot be the zero address. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidPeerZeroAddress();
```


InvalidRecipient

### InvalidRecipient

Error when the recipient is invalid. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidRecipient();
```


InvalidRefundAddress

### InvalidRefundAddress

Error when the refund address is invalid. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidRefundAddress();
```


InvalidTargetChain

### InvalidTargetChain

Error when trying to execute a message on an unintended target chain. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error InvalidTargetChain(uint16 targetChain, uint16 thisChain);
```

??? interface "Parameters"

    `targetChain` ++"uint16"++

    The target chain ID from the message.

    ---

    `thisChain` ++"uint16"++

    The current chain ID.


InvalidTransceiverZeroAddress

### InvalidTransceiverZeroAddress

Error when the transceiver is the zero address. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error InvalidTransceiverZeroAddress();
```


MessageNotApproved

### MessageNotApproved

Error when the message is not approved. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error MessageNotApproved(bytes32 msgHash);
```

??? interface "Parameters"

    `msgHash` ++"bytes32"++

    The hash of the message that is not approved.


NoEnabledTransceivers

### NoEnabledTransceivers

There are no transceivers enabled with the Manager. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error NoEnabledTransceivers();
```


NonRegisteredTransceiver

### NonRegisteredTransceiver

Error when attempting to remove a transceiver that is not registered. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error NonRegisteredTransceiver(address transceiver);
```

??? interface "Parameters"

    `transceiver` ++"address"++

    The non-registered transceiver address.


NotEnoughCapacity

### NotEnoughCapacity

Not enough capacity to send the transfer. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error NotEnoughCapacity(uint256 currentCapacity, uint256 amount);
```

??? interface "Parameters"

    `currentCapacity` ++"uint256"++

    The current available capacity.

    ---

    `amount` ++"uint256"++

    The requested transfer amount.


NotInitializing

### NotInitializing

Error when a function can only be called during initialization. *(Defined in [Initializable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/Initializable.sol){target=\_blank})*

```sol
error NotInitializing();
```


NotMigrating

### NotMigrating

Error when a function can only be called during migration. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
error NotMigrating();
```


NotImplemented

### NotImplemented

Feature is not implemented. *(Defined in INttManager.sol)*

```sol
error NotImplemented();
```


OnlyDelegateCall

### OnlyDelegateCall

Error when a function can only be called via delegate call. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
error OnlyDelegateCall();
```


OwnableInvalidOwner

### OwnableInvalidOwner

Error when the owner is not a valid owner account. *(Defined in [OwnableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/OwnableUpgradeable.sol){target=\_blank})*

```sol
error OwnableInvalidOwner(address owner);
```

??? interface "Parameters"

    `owner` ++"address"++

    The invalid owner address.


OwnableUnauthorizedAccount

### OwnableUnauthorizedAccount

Error when the caller account is not authorized to perform an operation. *(Defined in [OwnableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/OwnableUpgradeable.sol){target=\_blank})*

```sol
error OwnableUnauthorizedAccount(address account);
```

??? interface "Parameters"

    `account` ++"address"++

    The unauthorized account address.


OutboundQueuedTransferNotFound

### OutboundQueuedTransferNotFound

Outbound transfer is no longer queued. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error OutboundQueuedTransferNotFound(uint64 queueSequence);
```

??? interface "Parameters"

    `queueSequence` ++"uint64"++

    The sequence number of the queued transfer.


OutboundQueuedTransferStillQueued

### OutboundQueuedTransferStillQueued

Cannot complete the outbound transfer. The transfer is still queued. *(Defined in [RateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/RateLimiter.sol){target=\_blank})*

```sol
error OutboundQueuedTransferStillQueued(uint64 queueSequence, uint256 transferTimestamp);
```

??? interface "Parameters"

    `queueSequence` ++"uint64"++

    The sequence number of the queued transfer.

    ---

    `transferTimestamp` ++"uint256"++

    The timestamp of the transfer.


PeerNotRegistered

### PeerNotRegistered

Error when the manager doesn't have a peer registered for the destination chain. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error PeerNotRegistered(uint16 chainId);
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID for which no peer is registered.


RefundFailed

### RefundFailed

Error when the refund to the sender fails. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error RefundFailed(uint256 refundAmount);
```

??? interface "Parameters"

    `refundAmount` ++"uint256"++

    The amount that failed to be refunded.


RequireContractIsNotPaused

### RequireContractIsNotPaused

Error when a function requires the contract to not be paused. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
error RequireContractIsNotPaused();
```


RequireContractIsPaused

### RequireContractIsPaused

Error when a function requires the contract to be paused. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
error RequireContractIsPaused();
```


### RetrievedIncorrectRegisteredTransceivers

Retrieved an incorrect number of registered transceivers. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error RetrievedIncorrectRegisteredTransceivers(uint256 retrieved, uint256 registered);
```

??? interface "Parameters"

    `retrieved` ++"uint256"++

    The number of transceivers retrieved.

    ---

    `registered` ++"uint256"++

    The number of transceivers that should be registered.


StaticcallFailed

### StaticcallFailed

Staticcall reverted. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error StaticcallFailed();
```


ThresholdTooHigh

### ThresholdTooHigh

The threshold for transceiver attestations is too high. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error ThresholdTooHigh(uint256 threshold, uint256 transceivers);
```

??? interface "Parameters"

    `threshold` ++"uint256"++

    The requested threshold value.

    ---

    `transceivers` ++"uint256"++

    The number of available transceivers.


TooManyTransceivers

### TooManyTransceivers

Error when the number of registered transceivers exceeds 64. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error TooManyTransceivers();
```


TransceiverAlreadyAttestedToMessage

### TransceiverAlreadyAttestedToMessage

Error when the transceiver already attested to the message. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error TransceiverAlreadyAttestedToMessage(bytes32 nttManagerMessageHash);
```

??? interface "Parameters"

    `nttManagerMessageHash` ++"bytes32"++

    The hash of the NTT Manager message.


TransceiverAlreadyEnabled

### TransceiverAlreadyEnabled

Error when attempting to enable a transceiver that is already enabled. *(Defined in [TransceiverRegistry.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/TransceiverRegistry.sol){target=\_blank})*

```sol
error TransceiverAlreadyEnabled(address transceiver);
```

??? interface "Parameters"

    `transceiver` ++"address"++

    The already enabled transceiver address.


TransferAmountHasDust

### TransferAmountHasDust

The transfer has some dust. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error TransferAmountHasDust(uint256 amount, uint256 dust);
```

??? interface "Parameters"

    `amount` ++"uint256"++

    The transfer amount.

    ---

    `dust` ++"uint256"++

    The dust amount.


UndefinedRateLimiting

### UndefinedRateLimiting

If the rate limiting behavior isn't explicitly defined in the constructor. *(Defined in [IRateLimiter.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IRateLimiter.sol){target=\_blank})*

```sol
error UndefinedRateLimiting();
```


UnexpectedDeployer

### UnexpectedDeployer

The caller is not the deployer. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error UnexpectedDeployer(address expectedOwner, address owner);
```

??? interface "Parameters"

    `expectedOwner` ++"address"++

    The expected owner address.

    ---

    `owner` ++"address"++

    The actual owner address.


UnexpectedMsgValue

### UnexpectedMsgValue

An unexpected msg.value was passed with the call. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error UnexpectedMsgValue();
```


ZeroAmount

### ZeroAmount

Error when the transfer amount is zero. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error ZeroAmount();
```


ZeroThreshold

### ZeroThreshold

The number of thresholds should not be zero. *(Defined in [ManagerBase.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/ManagerBase.sol){target=\_blank})*

```sol
error ZeroThreshold();
```


TransferAlreadyCompleted

### TransferAlreadyCompleted

Thrown when trying to complete an inbound transfer that was already processed. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error TransferAlreadyCompleted(bytes32 digest);
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the transfer message that has already been completed.


UnexpectedRecipientNttManagerAddress

### UnexpectedRecipientNttManagerAddress

Thrown when the recipient NTT Manager address in the message does not match this contract. *(Defined in [NttManager.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/NttManager/NttManager.sol){target=\_blank})*

```sol
error UnexpectedRecipientNttManagerAddress(bytes32 recipientNttManagerAddress);
```

??? interface "Parameters"

    `recipientNttManagerAddress` ++"bytes32"++

    The unexpected NTT Manager address from the message.


Native Token Transfers Manager Program (Solana)

Structure Overview

## Structure Overview

The NTT Manager system on Solana is implemented as a single Anchor program. The program provides comprehensive token transfer management capabilities, supports both burning and locking modes, integrates with Solana's Token Program (including Token-2022), and provides rate limiting and security features.

```text
NTT Manager Program
├── Core Instructions
├── Administrative Instructions
├── Rate Limiting
├── Transceiver Management
├── Peer Management
└── Wormhole Integration
```

**Key Components:**

- **NttManager Program**: The primary Solana program that coordinates token transfers, transceiver interactions, and peer communication for the NTT protocol.
- **Core Instructions**: Handles token transfer instructions like transfer, redeem, and release.
- **Administrative Instructions**: Manages ownership, configuration updates, and emergency pause functionality.
- **Rate Limiting**: Implements configurable inbound and outbound transfer limits with time-based capacity replenishment.
- **Transceiver Management**: Maintains a registry of enabled transceivers and allows dynamic registration/deregistration.
- **Peer Management**: Manages authorized cross-chain peers.
- **Wormhole Integration**: Built-in transceiver that connects the program to Wormhole's messaging layer.


State Accounts

## State Accounts


Core Configuration

### Core Configuration

- `Config` ++"account (PDA: 'config')"++: Primary program configuration: owner/pending_owner, managed `mint`, `token_program` (SPL Token or Token-2022), mode (burn vs. lock), chain_id, `next_transceiver_id`, attestation `threshold`, `enabled_transceivers` bitmap, `paused`, and `custody` (lock mode).


### Cross-chain Peers and Governance Thresholds

- `NttManagerPeer` ++"account (PDA: 'peer')"++: Per-chain peer manager metadata—`address` (wormhole-formatted) and `token_decimals`. Stored in a PDA seeded by chain id.
- `ValidatedTransceiverMessage` ++"account (PDA: 'transceiver_message')"++: Validated inbound transceiver message container (`from_chain`, `message`), with helpers for discriminator checks and parsing.


Rate Limiting and Queues

### Rate Limiting and Queues

- `InboxRateLimit` ++"account (PDA: 'inbox_rate_limit')"++: Inbound rate-limit state (per peer chain), wrapping `RateLimitState` (`limit`, `capacity_at_last_tx`, `last_tx_timestamp`).
- `OutboxRateLimit` ++"account (PDA: 'outbox_rate_limit')"++: Global outbound rate-limit state, wrapping `RateLimitState` (`limit`, `capacity_at_last_tx`, `last_tx_timestamp`).
- `InboxItem` ++"account (PDA: 'inbox_item')"++: Per-inbound message item with `amount`, `recipient_address`, `votes` (bitmap), and `release_status` state machine (`NotApproved` → `ReleaseAfter(ts)` → `Released`).
- `OutboxItem` ++"account (PDA: 'outbox_item')"++: Per-outbound transfer item tracking delivery/release state (`amount`, `sender`, `recipient` fields and release metadata).


Authority and Admin Flow

### Authority and Admin Flow

- `PendingTokenAuthority` ++"account (PDA: 'pending_token_authority')"++: Tracks pending mint authority transitions and the `rent_payer`.


PDAs

### PDAs

- `TOKEN_AUTHORITY` ++"PDA (seed: 'token_authority')"++: Program-derived token authority used by the burn/lock flows. (PDA seed constant in `lib.rs`.)
- `SESSION_AUTHORITY` ++"PDA (seed: 'session_authority')"++: Per-transfer session authority used by `transfer_*` instructions (user approves this PDA to spend, then it burns/locks). (Seed constant and rationale in `lib.rs` comments.)


Instructions

## Instructions


accept_token_authority

### accept_token_authority

Accepts token authority from a pending token authority transfer. *(Defined in NTT Manager)*

```rust
pub fn accept_token_authority(ctx: Context<AcceptTokenAuthority>) -> Result<()>
```

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `token_authority` ++"Signer"++

    The new token authority accepting the transfer.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


accept_token_authority_from_multisig

### accept_token_authority_from_multisig

Accepts token authority from a multisig pending token authority transfer. *(Defined in NTT Manager)*

```rust
pub fn accept_token_authority_from_multisig(
    ctx: Context<AcceptTokenAuthorityFromMultisig>
) -> Result<()>
```

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `multisig` ++"Account<Multisig>"++

    The multisig account acting as the new token authority.

    ---

    `transaction` ++"Account<Transaction>"++

    The multisig transaction account.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


broadcast_wormhole_id

### broadcast_wormhole_id

Broadcasts the NTT Manager ID via Wormhole. *(Defined in example-native-token-transfers)*

```rust
pub fn broadcast_wormhole_id(ctx: Context<BroadcastId>) -> Result<()>
```

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for transaction fees.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `wormhole_bridge` ++"mut Account<BridgeData>"++

    The Wormhole bridge data account.

    ---

    `wormhole_message` ++"mut Signer"++

    The Wormhole message account.

    ---

    `wormhole_emitter` ++"Account<EmitterData>"++

    The Wormhole emitter account.

    ---

    `wormhole_sequence` ++"mut Account<SequenceData>"++

    The Wormhole sequence account.

    ---

    `wormhole_fee_collector` ++"mut Account<FeeCollectorData>"++

    The Wormhole fee collector account.

    ---

    `clock` ++"Sysvar<Clock>"++

    The clock sysvar.

    ---

    `rent` ++"Sysvar<Rent>"++

    The rent sysvar.

    ---

    `system_program` ++"Program<System>"++

    The system program.

    ---

    `wormhole_program` ++"Program<WormholeCoreBridge>"++

    The Wormhole core bridge program.


broadcast_wormhole_peer

### broadcast_wormhole_peer

Broadcasts peer information via Wormhole. *(Defined in example-native-token-transfers)*

```rust
pub fn broadcast_wormhole_peer(
    ctx: Context<BroadcastPeer>,
    args: BroadcastPeerArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"BroadcastPeerArgs"++

    The broadcast peer arguments.

    ??? child "`BroadcastPeerArgs` type"

        `chain_id` ++"ChainId"++

        The chain ID to broadcast peer information for.

??? interface "Accounts"

    Similar to `broadcast_wormhole_id` with additional peer-specific accounts.


claim_ownership

### claim_ownership

Claims ownership of the NTT Manager after a transfer has been initiated. *(Defined in example-native-token-transfers)*

```rust
pub fn claim_ownership(ctx: Context<ClaimOwnership>) -> Result<()>
```

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `new_owner` ++"Signer"++

    The new owner claiming ownership.


claim_token_authority

### claim_token_authority

Claims token authority after a transfer has been initiated. *(Defined in example-native-token-transfers)*

```rust
pub fn claim_token_authority(ctx: Context<ClaimTokenAuthority>) -> Result<()>
```

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `token_authority` ++"Signer"++

    The new token authority claiming authority.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


claim_token_authority_to_multisig

### claim_token_authority_to_multisig

Claims token authority to a multisig account. *(Defined in example-native-token-transfers)*

```rust
pub fn claim_token_authority_to_multisig(
    ctx: Context<ClaimTokenAuthorityToMultisig>
) -> Result<()>
```

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `multisig` ++"Account<Multisig>"++

    The multisig account claiming token authority.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


deregister_transceiver

### deregister_transceiver

Removes a transceiver from the enabled set. *(Defined in example-native-token-transfers)*

```rust
pub fn deregister_transceiver(ctx: Context<DeregisterTransceiver>) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `registered_transceiver` ++"mut Account<RegisteredTransceiver>"++

    The registered transceiver account to deregister.


initialize

### initialize

Initializes the NTT Manager program with configuration parameters. *(Defined in example-native-token-transfers)*

```rust
pub fn initialize(ctx: Context<Initialize>, args: InitializeArgs) -> Result<()>
```

??? interface "Parameters"

    `args` ++"InitializeArgs"++

    The initialization arguments.

    ??? child "`InitializeArgs` type"

        `chain_id` ++"u16"++

        The chain ID for this deployment.

        ---

        `limit` ++"u64"++

        The initial rate limit for transfers.

        ---

        `mode` ++"Mode"++

        The mode (Burning or Locking) for token handling.

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for initialization.

    ---

    `deployer` ++"Signer"++

    The program deployer (must be upgrade authority).

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account to initialize.

    ---

    `mint` ++"InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `rate_limit` ++"mut Account<OutboxRateLimit>"++

    The outbound rate limit account.

    ---

    `token_authority` ++"UncheckedAccount"++

    The token authority account.

    ---

    `custody` ++"mut InterfaceAccount<TokenAccount>"++

    The custody account (for locking mode).

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.

    ---

    `associated_token_program` ++"Program<AssociatedToken>"++

    The associated token program.

    ---

    `system_program` ++"Program<System>"++

    The system program.


initialize_lut

### initialize_lut

Initializes a lookup table for the program. *(Defined in example-native-token-transfers)*

```rust
pub fn initialize_lut(ctx: Context<InitializeLUT>, recent_slot: u64) -> Result<()>
```

??? interface "Parameters"

    `recent_slot` ++"u64"++

    A recent slot number for lookup table initialization.

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for lookup table creation.

    ---

    `lut` ++"mut UncheckedAccount"++

    The lookup table account to initialize.

    ---

    `lut_authority` ++"UncheckedAccount"++

    The lookup table authority.

    ---

    `address_lookup_table_program` ++"Program<AddressLookupTableProgram>"++

    The address lookup table program.

    ---

    `system_program` ++"Program<System>"++

    The system program.


mark_outbox_item_as_released

### mark_outbox_item_as_released

Marks an outbox item as released by a specific transceiver. *(Defined in example-native-token-transfers)*

```rust
pub fn mark_outbox_item_as_released(ctx: Context<MarkOutboxItemAsReleased>) -> Result<bool>
```

??? interface "Returns"

    `released` ++"bool"++

    Whether the item was successfully marked as released.

??? interface "Accounts"

    `transceiver` ++"Signer"++

    The transceiver marking the item as released.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `outbox_item` ++"mut Account<OutboxItem>"++

    The outbox item to mark as released.

    ---

    `registered_transceiver` ++"Account<RegisteredTransceiver>"++

    The registered transceiver account.


receive_wormhole_message

### receive_wormhole_message

Receives and processes a message from Wormhole. *(Defined in example-native-token-transfers)*

```rust
pub fn receive_wormhole_message(ctx: Context<ReceiveMessage>) -> Result<()>
```

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for message processing.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `peer` ++"Account<NttManagerPeer>"++

    The peer account for the sending chain.

    ---

    `inbox_item` ++"mut Account<InboxItem>"++

    The inbox item account to create.

    ---

    `inbox_rate_limit` ++"mut Account<InboxRateLimit>"++

    The inbound rate limit account.

    ---

    `vaa` ++"Account<PostedVaa<TransceiverMessage>>"++

    The verified VAA containing the message.

    ---

    `transceiver_message` ++"mut UncheckedAccount"++

    The transceiver message account.

    ---

    `system_program` ++"Program<System>"++

    The system program.


redeem

### redeem

Redeems a transfer by consuming a verified message. *(Defined in example-native-token-transfers)*

```rust
pub fn redeem(ctx: Context<Redeem>, args: RedeemArgs) -> Result<()>
```

??? interface "Parameters"

    `args` ++"RedeemArgs"++

    The redeem arguments (currently empty struct).

??? interface "Accounts"

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `transceiver_message` ++"Account<ValidatedTransceiverMessage<NativeTokenTransfer>>"++

    The validated transceiver message.

    ---

    `inbox_item` ++"mut Account<InboxItem>"++

    The inbox item being redeemed.


register_transceiver

### register_transceiver

Registers a new transceiver with the NTT Manager. *(Defined in example-native-token-transfers)*

```rust
pub fn register_transceiver(ctx: Context<RegisterTransceiver>) -> Result<()>
```

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for registration.

    ---

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `registered_transceiver` ++"mut Account<RegisteredTransceiver>"++

    The registered transceiver account to create.

    ---

    `transceiver` ++"UncheckedAccount"++

    The transceiver program to register.

    ---

    `system_program` ++"Program<System>"++

    The system program.


release_inbound_mint

### release_inbound_mint

Releases an inbound transfer by minting tokens to the recipient. *(Defined in example-native-token-transfers)*

```rust
pub fn release_inbound_mint(
    ctx: Context<ReleaseInboundMint>,
    args: ReleaseInboundArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"ReleaseInboundArgs"++

    The release arguments.

    ??? child "`ReleaseInboundArgs` type"

        `revert_on_delay` ++"bool"++

        Whether to revert if the transfer is still in delay.

??? interface "Accounts"

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `inbox_item` ++"mut Account<InboxItem>"++

    The inbox item to release.

    ---

    `inbox_rate_limit` ++"mut Account<InboxRateLimit>"++

    The inbound rate limit account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `recipient_token` ++"mut InterfaceAccount<TokenAccount>"++

    The recipient's token account.

    ---

    `token_authority` ++"UncheckedAccount"++

    The token authority account.

    ---

    `custody` ++"mut InterfaceAccount<TokenAccount>"++

    The custody account.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


release_inbound_unlock

### release_inbound_unlock

Releases an inbound transfer by unlocking tokens from custody. *(Defined in example-native-token-transfers)*

```rust
pub fn release_inbound_unlock(
    ctx: Context<ReleaseInboundUnlock>,
    args: ReleaseInboundArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"ReleaseInboundArgs"++

    The release arguments.

    ??? child "`ReleaseInboundArgs` type"

        `revert_on_delay` ++"bool"++

        Whether to revert if the transfer is still in delay.

??? interface "Accounts"

    Similar to `release_inbound_mint` but unlocks tokens from custody instead of minting.


release_wormhole_outbound

### release_wormhole_outbound

Releases an outbound transfer via Wormhole. *(Defined in example-native-token-transfers)*

```rust
pub fn release_wormhole_outbound(
    ctx: Context<ReleaseOutbound>,
    args: ReleaseOutboundArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"ReleaseOutboundArgs"++

    The release outbound arguments.

    ??? child "`ReleaseOutboundArgs` type"

        `revert_on_delay` ++"bool"++

        If `true`, revert when the rate limiter would delay release; if `false`, return early without error.

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The fee payer.

    ---

    `config` ++"NotPausedConfig"++

    Wrapper enforcing the Manager is not paused; derefs to `Account<Config>`.

    ---

    `outbox_item` ++"mut Account<OutboxItem>"++

    The outbound item to release; must not already be marked released by this transceiver.

    ---

    `transceiver` ++"Account<RegisteredTransceiver>"++

    Must match this program ID and be enabled in `config`.

    ---

    `wormhole_message` ++"mut UncheckedAccount"++

    PDA seeded as `[b"message", outbox_item.key()]`; initialized/written by Wormhole Core.

    ---

    `emitter` ++"UncheckedAccount"++

    PDA seeded as `[b"emitter"]`; used as the Wormhole emitter.

    ---

    `wormhole` ++"WormholeAccounts"++

    Bundle of Wormhole Core accounts:

     - `bridge: Account<wormhole::BridgeData>`
     - `fee_collector: UncheckedAccount`
     - `sequence: UncheckedAccount`
     - `program: Program<wormhole::program::Wormhole>`
     - `system_program: Program<System>`
     - `clock: Sysvar<Clock>`
     - `rent: Sysvar<Rent>`


revert_token_authority

### revert_token_authority

Reverts a pending token authority change. *(Defined in example-native-token-transfers)*

```rust
pub fn revert_token_authority(ctx: Context<RevertTokenAuthority>) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.


set_inbound_limit

### set_inbound_limit

Sets the inbound transfer rate limit. *(Defined in example-native-token-transfers)*

```rust
pub fn set_inbound_limit(
    ctx: Context<SetInboundLimit>,
    args: SetInboundLimitArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"SetInboundLimitArgs"++

    The inbound limit arguments.

    ??? child "`SetInboundLimitArgs` type"

        `limit` ++"u64"++

        The new inbound rate limit.

        ---

        `chain_id` ++"ChainId"++

        The chain ID to set the limit for.

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `rate_limit` ++"mut Account<InboxRateLimit>"++

    The inbound rate limit account.


set_outbound_limit

### set_outbound_limit

Sets the outbound transfer rate limit. *(Defined in example-native-token-transfers)*

```rust
pub fn set_outbound_limit(
    ctx: Context<SetOutboundLimit>,
    args: SetOutboundLimitArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"SetOutboundLimitArgs"++

    The outbound limit arguments.

    ??? child "`SetOutboundLimitArgs` type"

        `limit` ++"u64"++

        The new outbound rate limit.

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `rate_limit` ++"mut Account<OutboxRateLimit>"++

    The outbound rate limit account.


set_paused

### set_paused

Sets the pause state of the program. *(Defined in example-native-token-transfers)*

```rust
pub fn set_paused(ctx: Context<SetPaused>, pause: bool) -> Result<()>
```

??? interface "Parameters"

    `pause` ++"bool"++

    Whether to pause or unpause the program.

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.


set_peer

### set_peer

Sets a peer NTT Manager on another chain; this is local program configuration (no cross-chain message) and must be executed on both chains. If either side is unset or mismatched, messages from that peer will fail verification on receive. *(Defined in example-native-token-transfers)*

!!! tip "Example"
    - **On Chain A**: Register Chain B with B’s manager address (address); this creates/updates the peer account (PDA "peer") and the inbound rate-limit account for B.
    - **On Chain B**: Register Chain A the same way.

```rust
pub fn set_peer(ctx: Context<SetPeer>, args: SetPeerArgs) -> Result<()>
```

??? interface "Parameters"

    `args` ++"SetPeerArgs"++

    The peer arguments.

    ??? child "`SetPeerArgs` type"

        `chain_id` ++"ChainId"++

        The chain ID of the peer.

        ---

        `address` ++"[u8; 32]"++

        The address of the peer NTT Manager.

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for peer registration.

    ---

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `peer` ++"mut Account<NttManagerPeer>"++

    The peer account to create or update.

    ---

    `inbox_rate_limit` ++"mut Account<InboxRateLimit>"++

    The inbound rate limit account for the peer.

    ---

    `system_program` ++"Program<System>"++

    The system program.


set_threshold

### set_threshold

Sets the threshold number of transceivers required for message approval. *(Defined in example-native-token-transfers)*

```rust
pub fn set_threshold(ctx: Context<SetThreshold>, threshold: u8) -> Result<()>
```

??? interface "Parameters"

    `threshold` ++"u8"++

    The new threshold value.

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.


set_token_authority

### set_token_authority

Sets the token authority using a checked transfer process. *(Defined in example-native-token-transfers)*

```rust
pub fn set_token_authority(ctx: Context<SetTokenAuthorityChecked>) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `new_token_authority` ++"UncheckedAccount"++

    The new token authority account.


set_token_authority_one_step_unchecked

### set_token_authority_one_step_unchecked

Sets the token authority in a single step without checks. *(Defined in example-native-token-transfers)*

```rust
pub fn set_token_authority_one_step_unchecked(
    ctx: Context<SetTokenAuthorityUnchecked>
) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `new_token_authority` ++"UncheckedAccount"++

    The new token authority account.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.


set_wormhole_peer

### set_wormhole_peer

Sets a Wormhole transceiver peer on another chain. *(Defined in example-native-token-transfers)*

```rust
pub fn set_wormhole_peer(
    ctx: Context<SetTransceiverPeer>,
    args: SetTransceiverPeerArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"SetTransceiverPeerArgs"++

    The transceiver peer arguments.

    ??? child "`SetTransceiverPeerArgs` type"

        `chain_id` ++"ChainId"++

        The chain ID of the peer.

        ---

        `address` ++"[u8; 32]"++

        The address of the peer transceiver.

??? interface "Accounts"

    `owner` ++"Signer"++

    The program owner.

    ---

    `config` ++"Account<Config>"++

    The program configuration account.

    ---

    `peer` ++"mut Account<WormholeTransceiverPeer>"++

    The Wormhole transceiver peer account.

    ---

    `system_program` ++"Program<System>"++

    The system program.


transfer_burn

### transfer_burn

Initiates an outbound transfer by burning tokens. *(Defined in example-native-token-transfers)*

```rust
pub fn transfer_burn(
    ctx: Context<TransferBurn>,
    args: TransferArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"TransferArgs"++

    The transfer arguments.

    ??? child "`TransferArgs` type"

        `amount` ++"u64"++

        The amount of tokens to transfer.

        ---

        `recipient_chain` ++"ChainId"++

        The recipient chain ID.

        ---

        `recipient_address` ++"[u8; 32]"++

        The recipient address on the target chain.

        ---

        `should_queue` ++"bool"++

        Whether to queue the transfer if rate limited.

??? interface "Accounts"

    `payer` ++"mut Signer"++

    The account paying for the transfer.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `from` ++"mut InterfaceAccount<TokenAccount>"++

    The sender's token account.

    ---

    `mint` ++"mut InterfaceAccount<Mint>"++

    The mint account for the managed token.

    ---

    `outbox_item` ++"mut Account<OutboxItem>"++

    The outbox item account to create.

    ---

    `outbox_rate_limit` ++"mut Account<OutboxRateLimit>"++

    The outbound rate limit account.

    ---

    `session_authority` ++"UncheckedAccount"++

    The session authority for the transfer.

    ---

    `token_authority` ++"UncheckedAccount"++

    The token authority account.

    ---

    `token_program` ++"Interface<TokenInterface>"++

    The token program interface.

    ---

    `system_program` ++"Program<System>"++

    The system program.


transfer_lock

### transfer_lock

Initiates an outbound transfer by locking tokens in custody. *(Defined in example-native-token-transfers)*

```rust
pub fn transfer_lock(
    ctx: Context<TransferLock>,
    args: TransferArgs
) -> Result<()>
```

??? interface "Parameters"

    `args` ++"TransferArgs"++

    The transfer arguments.

    ??? child "`TransferArgs` type"

        `amount` ++"u64"++

        The amount of tokens to transfer.

        ---

        `recipient_chain` ++"ChainId"++

        The recipient chain ID.

        ---

        `recipient_address` ++"[u8; 32]"++

        The recipient address on the target chain.

        ---

        `should_queue` ++"bool"++

        Whether to queue the transfer if rate limited.

??? interface "Accounts"

    Similar to `transfer_burn` but locks tokens in custody instead of burning.


transfer_ownership

### transfer_ownership

Initiates a two-step [ownership transfer](/docs/products/token-transfers/native-token-transfers/guides/transfer-ownership/#solana){target=\_blank} process. *(Defined in example-native-token-transfers)*

```rust
pub fn transfer_ownership(ctx: Context<TransferOwnership>) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The current program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `new_owner` ++"UncheckedAccount"++

    The proposed new owner.


transfer_ownership_one_step_unchecked

### transfer_ownership_one_step_unchecked

Transfers ownership in a single step without verification. *(Defined in example-native-token-transfers)*

```rust
pub fn transfer_ownership_one_step_unchecked(ctx: Context<TransferOwnership>) -> Result<()>
```

??? interface "Accounts"

    `owner` ++"Signer"++

    The current program owner.

    ---

    `config` ++"mut Account<Config>"++

    The program configuration account.

    ---

    `new_owner` ++"UncheckedAccount"++

    The new owner.


version

### version

Returns the program version string. *(Defined in example-native-token-transfers)*

```rust
pub fn version(_ctx: Context<Version>) -> Result<String>
```

??? interface "Returns"

    `version` ++"String"++

    The version string ("3.0.0").


Data Structures

## Data Structures


Config

### Config

The main program configuration account. *(Defined in config.rs)*

```rust
pub struct Config {
    pub bump: u8,
    pub owner: Pubkey,
    pub pending_owner: Option<Pubkey>,
    pub mint: Pubkey,
    pub token_program: Pubkey,
    pub mode: Mode,
    pub chain_id: ChainId,
    pub next_transceiver_id: u8,
    pub threshold: u8,
    pub enabled_transceivers: Bitmap,
    pub paused: bool,
    pub custody: Pubkey,
}
```

??? interface "Fields"

    `bump` ++"u8"++

    The canonical bump for the config account.

    ---

    `owner` ++"Pubkey"++

    The owner of the program.

    ---

    `pending_owner` ++"Option<Pubkey>"++

    The pending owner (before claiming ownership).

    ---

    `mint` ++"Pubkey"++

    The mint address of the token managed by this program.

    ---

    `token_program` ++"Pubkey"++

    The address of the token program (Token or Token-2022).

    ---

    `mode` ++"Mode"++

    The mode that this program is running in (Burning or Locking).

    ---

    `chain_id` ++"ChainId"++

    The chain ID of the chain that this program is running on.

    ---

    `next_transceiver_id` ++"u8"++

    The next transceiver ID to use when registering a transceiver.

    ---

    `threshold` ++"u8"++

    The number of transceivers that must attest to a transfer.

    ---

    `enabled_transceivers` ++"Bitmap"++

    Bitmap of enabled transceivers.

    ---

    `paused` ++"bool"++

    Whether the program is paused.

    ---

    `custody` ++"Pubkey"++

    The custody account that holds tokens in locking mode.


Mode

### Mode

The operating mode of the NTT Manager. *(Defined in ntt-messages)*

```rust
pub enum Mode {
    Locking,
    Burning,
}
```

??? interface "Variants"

    `Locking`

    Tokens are locked in custody and unlocked on release.

    ---

    `Burning`

    Tokens are burned on transfer and minted on release.


ChainId

### ChainId

A Wormhole chain identifier. *(Defined in ntt-messages)*

```rust
pub struct ChainId {
    pub id: u16,
}
```

??? interface "Fields"

    `id` ++"u16"++

    The numeric chain ID.


Errors

## Errors


BadAmountAfterBurn

### BadAmountAfterBurn

Error when the amount after burning doesn't match expected. *(Defined in error.rs)*

```rust
BadAmountAfterBurn
```


BadAmountAfterTransfer

### BadAmountAfterTransfer

Error when the amount after transfer doesn't match expected. *(Defined in error.rs)*

```rust
BadAmountAfterTransfer
```


BitmapIndexOutOfBounds

### BitmapIndexOutOfBounds

Error when bitmap index is out of bounds. *(Defined in error.rs)*

```rust
BitmapIndexOutOfBounds
```


CantReleaseYet

### CantReleaseYet

Error when trying to release a transfer that is still in delay. *(Defined in error.rs)*

```rust
CantReleaseYet
```


DisabledTransceiver

### DisabledTransceiver

Error when attempting to use a disabled transceiver. *(Defined in error.rs)*

```rust
DisabledTransceiver
```


IncorrectRentPayer

### IncorrectRentPayer

Error when the rent payer is incorrect. *(Defined in error.rs)*

```rust
IncorrectRentPayer
```


InvalidChainId

### InvalidChainId

Error when an invalid chain ID is provided. *(Defined in error.rs)*

```rust
InvalidChainId
```


InvalidDeployer

### InvalidDeployer

Error when the deployer is not authorized. *(Defined in error.rs)*

```rust
InvalidDeployer
```


InvalidMintAuthority

### InvalidMintAuthority

Error when the mint authority is invalid. *(Defined in error.rs)*

```rust
InvalidMintAuthority
```


InvalidMode

### InvalidMode

Error when an invalid mode is specified. *(Defined in error.rs)*

```rust
InvalidMode
```


InvalidMultisig

### InvalidMultisig

Error when a multisig account is invalid. *(Defined in error.rs)*

```rust
InvalidMultisig
```


InvalidNttManagerPeer

### InvalidNttManagerPeer

Error when the NTT Manager peer is invalid. *(Defined in error.rs)*

```rust
InvalidNttManagerPeer
```


InvalidPendingOwner

### InvalidPendingOwner

Error when the pending owner is invalid. *(Defined in error.rs)*

```rust
InvalidPendingOwner
```


InvalidPendingTokenAuthority

### InvalidPendingTokenAuthority

Error when the pending token authority is invalid. *(Defined in error.rs)*

```rust
InvalidPendingTokenAuthority
```


InvalidRecipientAddress

### InvalidRecipientAddress

Error when the recipient address is invalid. *(Defined in error.rs)*

```rust
InvalidRecipientAddress
```


InvalidTransceiverPeer

### InvalidTransceiverPeer

Error when the transceiver peer is invalid. *(Defined in error.rs)*

```rust
InvalidTransceiverPeer
```


InvalidTransceiverProgram

### InvalidTransceiverProgram

Error when the transceiver program is invalid. *(Defined in error.rs)*

```rust
InvalidTransceiverProgram
```


MessageAlreadySent

### MessageAlreadySent

Error when attempting to send a message that has already been sent. *(Defined in error.rs)*

```rust
MessageAlreadySent
```


NoRegisteredTransceivers

### NoRegisteredTransceivers

Error when no transceivers are registered. *(Defined in error.rs)*

```rust
NoRegisteredTransceivers
```


NotPaused

### NotPaused

Error when expecting the program to be paused but it's not. *(Defined in error.rs)*

```rust
NotPaused
```


OverflowExponent

### OverflowExponent

Error when there's an overflow in exponent calculation. *(Defined in error.rs)*

```rust
OverflowExponent
```


OverflowScaledAmount

### OverflowScaledAmount

Error when there's an overflow in scaled amount calculation. *(Defined in error.rs)*

```rust
OverflowScaledAmount
```


Paused

### Paused

Error when the program is paused and operation is not allowed. *(Defined in error.rs)*

```rust
Paused
```


ThresholdTooHigh

### ThresholdTooHigh

Error when the threshold is set too high. *(Defined in error.rs)*

```rust
ThresholdTooHigh
```


TransferAlreadyRedeemed

### TransferAlreadyRedeemed

Error when attempting to redeem a transfer that has already been redeemed. *(Defined in error.rs)*

```rust
TransferAlreadyRedeemed
```


TransferCannotBeRedeemed

### TransferCannotBeRedeemed

Error when a transfer cannot be redeemed. *(Defined in error.rs)*

```rust
TransferCannotBeRedeemed
```


TransferExceedsRateLimit

### TransferExceedsRateLimit

Error when a transfer exceeds the rate limit. *(Defined in error.rs)*

```rust
TransferExceedsRateLimit
```


TransferNotApproved

### TransferNotApproved

Error when a transfer has not been approved by enough transceivers. *(Defined in error.rs)*

```rust
TransferNotApproved
```


ZeroThreshold

### ZeroThreshold

Error when the threshold is set to zero. *(Defined in error.rs)*

```rust
ZeroThreshold
```


Native Token Transfers Transceivers Contracts (EVM)

Structure Overview

## Structure Overview

The NTT Transceiver system is built using a layered inheritance structure with the base [`Transceiver`](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/Transceiver.sol){target=\_blank} contract providing common functionality and specific implementations like [`WormholeTransceiver`](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/WormholeTransceiver/WormholeTransceiver.sol){target=\_blank} adding protocol-specific features.

```text
WormholeTransceiver.sol
├── IWormholeTransceiver.sol
├── IWormholeReceiver.sol
└── WormholeTransceiverState.sol
    ├── IWormholeTransceiverState.sol
    └── Transceiver.sol
        ├── ITransceiver.sol
        ├── PausableOwnable.sol
        ├── ReentrancyGuardUpgradeable.sol
        └── Implementation.sol
```

**Key Components:**

- **`Transceiver.sol`**: Base abstract contract providing common transceiver functionality including message transmission, ownership management, and upgrade capabilities.
- **`WormholeTransceiver.sol`**: Concrete implementation for Wormhole protocol, handling message verification through Wormhole Core and supporting multiple delivery methods (standard relaying, custom relaying, manual).
- **`WormholeTransceiverState.sol`**: State management contract for Wormhole-specific storage including peer registration, relaying configuration, and VAA consumption tracking.
- **`PausableOwnable.sol`**: Provides ownership and emergency pause functionality.
- **`ReentrancyGuardUpgradeable.sol`**: Protects against reentrancy attacks in an upgradeable context.
- **`Implementation.sol`**: Handles proxy implementation logic for upgradeable contracts.


State Variables

## State Variables


Core Identification

### Core Identification

- `nttManager` ++"address"++: Immutable address of the NTT Manager that this transceiver is tied to.
- `nttManagerToken` ++"address"++: Immutable address of the token associated with the NTT deployment.
- `deployer` ++"address"++: Immutable address of the contract deployer.


Version

### Version

- `WORMHOLE_TRANSCEIVER_VERSION` ++"string"++: Version string of the WormholeTransceiver implementation.


Messaging and Relaying Configuration

### Messaging and Relaying Configuration

- `consistencyLevel` ++"uint8"++: Immutable Wormhole consistency level for message finality.
- `wormhole` ++"IWormhole"++: Immutable reference to the Wormhole Core bridge contract.
- `wormholeRelayer` ++"IWormholeRelayer"++: Immutable reference to the relayer contract.
- `specialRelayer` ++"ISpecialRelayer"++: Immutable reference to a custom relayer contract.
- `gasLimit` ++"uint256"++: Immutable gas limit for cross-chain message delivery.


### Peer Configuration and Replay Protection

- `WORMHOLE_CONSUMED_VAAS_SLOT` ++"mapping(bytes32 ⇒ bool)"++: Tracks consumed VAA hashes for replay protection. Exposed via isVAAConsumed.
- `WORMHOLE_PEERS_SLOT` ++"mapping(uint16 ⇒ bytes32)"++: Wormhole chain ID → peer transceiver address. Exposed via getWormholePeer.
- `WORMHOLE_RELAYING_ENABLED_CHAINS_SLOT` ++"mapping(uint16 ⇒ BooleanFlag)"++: Per-chain flag for enabling standard relaying. Exposed via isWormholeRelayingEnabled.
- `SPECIAL_RELAYING_ENABLED_CHAINS_SLOT` ++"mapping(uint16 ⇒ BooleanFlag)"++: Per-chain flag for enabling special relaying. Exposed via isSpecialRelayingEnabled.
- `WORMHOLE_EVM_CHAIN_IDS` ++"mapping(uint16 ⇒ BooleanFlag)"++: Per-chain EVM-compatibility flag used to choose the relaying path. Exposed via isWormholeEvmChain.


Events

## Events


NotPaused

### NotPaused

Emitted when the contract is unpaused. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
event NotPaused(bool notPaused)
```

??? interface "Parameters"

    `notPaused` ++"bool"++

    Whether the contract is not paused.


OwnershipTransferred

### OwnershipTransferred

Emitted when ownership is transferred. *(Defined in [OwnableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/external/OwnableUpgradeable.sol){target=\_blank})*

```sol
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
```

??? interface "Parameters"

    `previousOwner` ++"address"++

    The address of the previous owner.

    ---

    `newOwner` ++"address"++

    The address of the new owner.


Paused

### Paused

Emitted when the contract is paused. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
event Paused(bool paused)
```

??? interface "Parameters"

    `paused` ++"bool"++

    Whether the contract is paused.


PauserTransferred

### PauserTransferred

Emitted when the pauser capability is transferred. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
event PauserTransferred(address indexed oldPauser, address indexed newPauser)
```

??? interface "Parameters"

    `oldPauser` ++"address"++

    The address of the previous pauser.

    ---

    `newPauser` ++"address"++

    The address of the new pauser.


ReceivedMessage

### ReceivedMessage

Emitted when a message is received. *(Defined in [IWormholeTransceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiver.sol){target=\_blank})*

```sol
event ReceivedMessage(
    bytes32 digest,
    uint16 emitterChainId,
    bytes32 emitterAddress,
    uint64 sequence
)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the message.

    ---

    `emitterChainId` ++"uint16"++

    The chain ID of the emitter.

    ---

    `emitterAddress` ++"bytes32"++

    The address of the emitter.

    ---

    `sequence` ++"uint64"++

    The sequence of the message.


ReceivedRelayedMessage

### ReceivedRelayedMessage

Emitted when a relayed message is received. *(Defined in [IWormholeTransceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiver.sol){target=\_blank})*

```sol
event ReceivedRelayedMessage(
    bytes32 digest,
    uint16 emitterChainId,
    bytes32 emitterAddress
)
```

??? interface "Parameters"

    `digest` ++"bytes32"++

    The digest of the message.

    ---

    `emitterChainId` ++"uint16"++

    The chain ID of the emitter.

    ---

    `emitterAddress` ++"bytes32"++

    The address of the emitter.


RelayingInfo

### RelayingInfo

Emitted when a message is sent from the transceiver. *(Defined in [IWormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiverState.sol){target=\_blank})*

```sol
event RelayingInfo(
    uint8 relayingType,
    bytes32 refundAddress,
    uint256 deliveryPayment
)
```

??? interface "Parameters"

    `relayingType` ++"uint8"++

    The type of relaying.

    ---

    `refundAddress` ++"bytes32"++

    The refund address for unused gas.

    ---

    `deliveryPayment` ++"uint256"++

    The amount of ether sent along with the tx to cover the delivery fee.


SendTransceiverMessage

### SendTransceiverMessage

Emitted when a message is sent from the transceiver. *(Defined in [IWormholeTransceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiver.sol){target=\_blank})*

```sol
event SendTransceiverMessage(
    uint16 recipientChain,
    TransceiverStructs.TransceiverMessage message
)
```

??? interface "Parameters"

    `recipientChain` ++"uint16"++

    The chain ID of the recipient.

    ---

    `message` ++"TransceiverStructs.TransceiverMessage"++

    The message.

    ??? child "`TransceiverMessage` type"

        `sourceNttManagerAddress` ++"bytes32"++

        The address of the source NTT Manager.

        ---

        `recipientNttManagerAddress` ++"bytes32"++

        The address of the recipient NTT Manager.

        ---

        `nttManagerPayload` ++"bytes"++

        The NTT Manager payload.

        ---

        `transceiverPayload` ++"bytes"++

        The transceiver-specific payload.


SetIsSpecialRelayingEnabled

### SetIsSpecialRelayingEnabled

Emitted when special relaying is enabled for the given chain. *(Defined in [IWormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiverState.sol){target=\_blank})*

```sol
event SetIsSpecialRelayingEnabled(uint16 chainId, bool isRelayingEnabled)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to set.

    ---

    `isRelayingEnabled` ++"bool"++

    A boolean indicating whether special relaying is enabled.


SetIsWormholeEvmChain

### SetIsWormholeEvmChain

Emitted when the EVM-compatibility flag is set for a chain. *(Defined in [IWormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiverState.sol){target=\_blank})*

```sol
event SetIsWormholeEvmChain(uint16 chainId, bool isEvm)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to set.

    ---

    `isEvm` ++"bool"++

    A boolean indicating whether relaying is enabled.


SetIsWormholeRelayingEnabled

### SetIsWormholeRelayingEnabled

Emitted when relaying is enabled for the given chain. *(Defined in [IWormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiverState.sol){target=\_blank})*

```sol
event SetIsWormholeRelayingEnabled(uint16 chainId, bool isRelayingEnabled)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to set.

    ---

    `isRelayingEnabled` ++"bool"++

    A boolean indicating whether relaying is enabled.


SetWormholePeer

### SetWormholePeer

Emitted when a peer transceiver is set. *(Defined in [IWormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/interfaces/IWormholeTransceiverState.sol){target=\_blank})*

```sol
event SetWormholePeer(uint16 chainId, bytes32 peerContract)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID of the peer.

    ---

    `peerContract` ++"bytes32"++

    The address of the peer contract.


Functions

## Functions


encodeWormholeTransceiverInstruction

### encodeWormholeTransceiverInstruction

Encodes the `WormholeTransceiverInstruction` into a byte array. *(Defined in [WormholeTransceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/WormholeTransceiver/WormholeTransceiver.sol){target=\_blank})*

```sol
function encodeWormholeTransceiverInstruction(
    WormholeTransceiverInstruction memory instruction
) public pure returns (bytes memory)
```

??? interface "Parameters"

    `instruction` ++"WormholeTransceiverInstruction"++

    The `WormholeTransceiverInstruction` to encode.

    ??? child "`WormholeTransceiverInstruction` type"

        `shouldSkipRelayerSend` ++"bool"++

        Whether to skip delivery via the relayer.

??? interface "Returns"

    `encoded` ++"bytes"++

    The encoded instruction.


getMigratesImmutables

### getMigratesImmutables

Returns whether the contract migrates immutables during upgrades. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
function getMigratesImmutables() public view returns (bool)
```

??? interface "Returns"

    `migratesImmutables` ++"bool"++

    Whether the contract migrates immutables.


getNttManagerOwner

### getNttManagerOwner

Returns the owner address of the NTT Manager that this transceiver is related to. *(Defined in [Transceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/Transceiver.sol){target=\_blank})*

```sol
function getNttManagerOwner() public view returns (address)
```

??? interface "Returns"

    `owner` ++"address"++

    The owner address of the NTT Manager.


getNttManagerToken

### getNttManagerToken

Returns the address of the token associated with this NTT deployment. *(Defined in [Transceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/Transceiver.sol){target=\_blank})*

```sol
function getNttManagerToken() public view virtual returns (address)
```

??? interface "Returns"

    `token` ++"address"++

    The address of the token.


getTransceiverType

### getTransceiverType

Returns the string type of the transceiver. *(Defined in [WormholeTransceiver.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/WormholeTransceiver/WormholeTransceiver.sol){target=\_blank})*

```sol
function getTransceiverType() external pure returns (string memory)
```

??? interface "Returns"

    `transceiverType` ++"string"++

    The type of the transceiver (e.g., "wormhole").


getWormholePeer

### getWormholePeer

Returns the peer contract address for a given chain. *(Defined in [WormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/WormholeTransceiver/WormholeTransceiverState.sol){target=\_blank})*

```sol
function getWormholePeer(uint16 chainId) public view returns (bytes32)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to query.

??? interface "Returns"

    `peerContract` ++"bytes32"++

    The address of the peer contract on the given chain.


initialize

### initialize

Initializes the contract implementation. Only callable through a delegate call. *(Defined in [Implementation.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/Implementation.sol){target=\_blank})*

```sol
function initialize() external payable
```


isPaused

### isPaused

Returns whether the contract is currently paused. *(Defined in [PausableUpgradeable.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/libraries/PausableUpgradeable.sol){target=\_blank})*

```sol
function isPaused() public view returns (bool)
```

??? interface "Returns"

    `paused` ++"bool"++

    Whether the contract is paused.


isSpecialRelayingEnabled

### isSpecialRelayingEnabled

Returns whether special relaying is enabled for a given chain. *(Defined in [WormholeTransceiverState.sol](https://github.com/wormhole-foundation/native-token-transfers/blob/main/evm/src/Transceiver/WormholeTransceiver/WormholeTransceiverState.sol){target=\_blank})*

```sol
function isSpecialRelayingEnabled(uint16 chainId) public view returns (bool)
```

??? interface "Parameters"

    `chainId` ++"uint16"++

    The chain ID to query.

??? interface "Returns"

    `isEnabled` ++"bool"++

    Whether special relaying is enabled.