How the ICM Registry works
Learn about the different functionality available in the Interchain Messaging Registry.
TeleporterRegistry keeps track of TeleporterMessenger contract versions. Cross-Avalanche L1 dApps can request the latest or a specific version of the TeleporterMessenger:

Internally the TeleporterRegistry maintains a mapping of TeleporterMessenger contract versions to their addresses.

Each registry's mapping of version to contract address is independent of registries on other blockchains, and chains can decide on their own registry mapping entries. So the contract of version 4 on one chain does not have to be equal to that version on another chain.
If a cross-Avalanche L1 dApps prefers a specific version, it can also call directly the getAddressFromVersion function:
If you are interested in the entire implementation, check it out here.