CCIP v2.0.0 TokenAdminRegistry API Reference
TokenAdminRegistry is the control plane for CCIP token configuration.
It defines:
- which pool is responsible for each token
- which address controls configuration for each token
This registry is the canonical source of truth for token onboarding and pool assignment within CCIP.
If you use this contract, all routing and token behavior depends on the mappings and administrators defined here.
Usage Boundary
You interact with this contract only for configuration and administration.
- CCIP infrastructure reads from this registry to resolve token → pool mappings.
- Token administrators update pool assignments and manage configuration.
- Registry modules and the owner can onboard new tokens and assign administrators.
- You are responsible for ensuring mappings and admin roles are correct before enabling transfers.
Contract
tokenAdminRegistry/TokenAdminRegistry.sol
Import
import {TokenAdminRegistry} from "chainlink-ccip/tokenAdminRegistry/TokenAdminRegistry.sol";
If you have not installed the package:
npm install @chainlink/contracts-ccip@2.0.0
Inheritance
ITokenAdminRegistryITypeAndVersionOwnable2StepMsgSender
External API
getPools
function getPools(address[] calldata tokens) external view returns (address[] memory)
| Parameter | Type | Description |
|---|---|---|
tokens | address[] calldata | Tokens to query. |
Returns:
| Type | Description |
|---|---|
address[] memory | Pools corresponding to the input tokens (may contain zero addresses). |
getPool
function getPool(address token) external view returns (address)
Returns the pool associated with a token.
| Parameter | Type | Description |
|---|---|---|
token | address | Token address to query. |
Returns:
| Type | Description |
|---|---|
address | Pool responsible for handling the token. |
getTokenConfig
function getTokenConfig(address token) external view returns (TokenConfig memory)
Returns full configuration for a token.
getAllConfiguredTokens
function getAllConfiguredTokens(uint64 startIndex, uint64 maxCount) external view returns (address[] memory tokens)
Returns paginated list of configured tokens.
setPool
function setPool(address localToken, address pool) external onlyTokenAdmin(localToken)
Sets or updates the pool responsible for handling a token. Can only be called by the token’s administrator.
proposeAdministrator
function proposeAdministrator(address localToken, address administrator) external
Proposes an administrator for a token. Used when onboarding or reassigning control.
acceptAdminRole
function acceptAdminRole(address localToken) external
Accepts the administrator role. Can only be called by the proposed administrator.
transferAdminRole
function transferAdminRole(address localToken, address newAdmin) external onlyTokenAdmin(localToken)
Initiates transfer of the administrator role for a token.
isAdministrator
function isAdministrator(address localToken, address administrator) external view returns (bool)
Checks if an address is the current administrator for a token.
isRegistryModule
function isRegistryModule(address module) public view returns (bool)
Checks whether an address is an authorized registry module.
addRegistryModule
function addRegistryModule(address module) external onlyOwner
Adds a registry module.
removeRegistryModule
function removeRegistryModule(address module) external onlyOwner
Removes a registry module.
Administrator Lifecycle
- A registry module or owner proposes an administrator (
proposeAdministrator) - The proposed administrator accepts (
acceptAdminRole) - The administrator configures the pool (
setPool) - The administrator may transfer control (
transferAdminRole→acceptAdminRole)
Notes
- Each token has exactly one active administrator at a time.
- This registry defines the source of truth for token-to-pool mappings.
- All CCIP routing for a token depends on the pool configured in this registry.
- Registry modules are privileged onboarding components and should be granted access carefully.
- If a token is mapped to an incorrect pool, transfers may fail or route incorrectly.
- If no pool is configured, transfers involving that token will fail.
- Incorrect administrator assignment may grant control to unintended parties.
Structs
struct TokenConfig {
address administrator;
address pendingAdministrator;
address tokenPool;
}
Internal Functions
onlyTokenAdmin
modifier onlyTokenAdmin(address token)
Restricts access to the token administrator.
Reverts if the caller is not the configured administrator.
Events
event PoolSet(address indexed token, address indexed previousPool, address indexed newPool)event AdministratorTransferRequested(address indexed token, address indexed currentAdmin, address indexed newAdmin)event AdministratorTransferred(address indexed token, address indexed newAdmin)event RegistryModuleAdded(address module)event RegistryModuleRemoved(address indexed module)
For a cross-contract event index, see Events.
Errors
error OnlyRegistryModuleOrOwner(address sender)error OnlyAdministrator(address sender, address token)error OnlyPendingAdministrator(address sender, address token)error AlreadyRegistered(address token)error ZeroAddress()error InvalidTokenPoolToken(address token)
For a cross-contract error index, see Errors.
Security model
- Owner controls registry modules.
- Registry modules and owner can assign initial administrators.
- Token administrators control pool configuration.
- Administrator changes require explicit acceptance.
- All token routing depends on correct registry configuration.