Purpose

To facilitate seamless interactions between blockchains operating on different types of Virtual Machines (VMs), Skate employs a central Wallet Registry at the Kernel level. This ensures that users can use various wallets across VMs while maintaining a consistent shared state. The AccountRegistry will be maintained by the Skate team, however the account states can be freely used by any Stateless app looking to deploy across supported VMs.

Interaction flow

The flow for syncing wallets is outlined as follows:

  1. Users initiate requests from different virtual machines (VMs).
  2. The intents are collected by the Skate Infrastructure, where they are matched through a 2-way handshake—users must prove ownership of both the VM1 and VM2 wallets to sync them.
  3. The executor submits the signature pairs to update the Wallet Registry on the Kernel.

The diagram below illustrates an example interaction between EVM, Solana, and TON. This flow can be generalized to support interactions across N-many VMs.

Sync Wallet between different VMs

How to sync wallets?

Coming soon…

How do we integrate this information in our Stateless apps?

Here are the key helper functions on AccountRegistry on Kernel to facilitate syncing wallets and retrieving wallet related information.

/**
     * @notice gets all accounts binded across all VMs given chainType and the corresponding address for that chainType
     * @param vmType the chain type for user
     * @param user the user address
     * @return wallets returns a bytes32 array containing all addresses across all vm types.
     * The addresses are arranged in accordance to how it is in the ordered registered on AccountStorage
     * It also returns bytes32(0) if there is no such record.
     */
    function getWallets(
        uint256 vmType,
        bytes32 user
    ) external view returns (bytes32[] memory wallets);

    /**
     * @notice retrieves account number tagged to a user
     * @param vmType the chain type for user
     * @param user the user address
     * @return number returns a uint256 number that represents a binded identity for all tagged wallets across different VMs.
     */
    function getAccountNumber(
        uint256 vmType,
        bytes32 user
    ) external view returns (uint256 number);

    /**
     * @notice gets wallet binding status for the two provided wallets
     * @param vmType the chain type for wallet 1
     * @param user the user address for wallet 1
     * @param vmType the chain type for wallet 2
     * @param user2 the user address for wallet 2    
     * @return status returns a boolean that represents whether the 2 provided wallets are binded 
     */
    function getWalletBindingStatus(
        uint256 vmType,
        bytes32 user,
        uint256 vmType2,
        bytes32 user2
    ) external view returns (bool status);

These functions will provide by the necessary account information needed to write custom logic tailored to the needs of your Stateless app.