AsterizmDemo contract
Deployment and Configuration of the Basic Protocol Demo Contract
Last updated
Deployment and Configuration of the Basic Protocol Demo Contract
Last updated
To demonstrate the functionality of our protocol, our team has developed a demo contract that facilitates the transmission of text data between networks. You can find the contract code in our repositories (both the basic and upgradeable versions for EVM and the basic version for TVM networks):
To complete the full configuration, you need to perform the following steps:
Add the obtained addresses to the list of trusted addresses on each network.
Send a message containing text from one network to another.
Here are console commands for simplified deployment
The command accepts the following parameters:
feeTokenAddress - optional parameter: token address for transfer commission payment
Upon successful execution, the command will return a response similar to the following (the address of the demo contract will be displayed under the AsterizmDemo address):
The command accepts the following parameters:
Upon successful execution, the command will return a response similar to the following (the address of the demo contract will be displayed under the AsterizmDemo address):
Coming soon
Build programs:
Deploy demo program:
Initialization client config logic (If successful, the command will not output anything. In case of an error, a log will be displayed):
The command accepts the following parameters:
solanaEndpoint - solana rpc url
Client account creation (If successful, the command will not output anything. In case of an error, a log will be displayed):
The command accepts the following parameters:
solanaEndpoint - solana rpc url
Client sender creation (If successful, the command will not output anything. In case of an error, a log will be displayed), the address created after executing this command will need to be added to the trusted addresses in other networks:
The command accepts the following parameters:
solanaEndpoint - solana rpc url
Client demo program sender creation (If successful, the command will not output anything. In case of an error, a log will be displayed):
The command accepts the following parameters:
solanaEndpoint - solana rpc url
To simplify the process of adding trusted addresses, console commands have been developed.
The command accepts the following parameters:
contractAddress - mandatory parameter: the address of the demo contract in the current network
trustedAddress - mandatory parameter: the address of the trusted demo contract. You will be able to review the list of available external relays later on a dedicated page. Please note that this parameter accepts a uint value, not address. Therefore, you will need to convert the hexadecimal address to decimal
Upon successful execution, the command will return a response similar to the following:
The command accepts the following parameters:
contractAddress - mandatory parameter: the address of the demo contract in the current network
trustedAddress - mandatory parameter: the address of the trusted demo contract. You will be able to review the list of available external relays later on a dedicated page. Please note that this parameter accepts a uint value, not address. Therefore, you will need to convert the hexadecimal address to decimal
Upon successful execution, the command will return a response similar to the following:
The command accepts the following parameters:
trustedAddress - mandatory parameter: the address of the trusted demo contract. You will be able to review the list of available external relays later on a dedicated page. Please note that this parameter accepts a uint value, not address. Therefore, you will need to convert the hexadecimal address to decimal
Upon successful execution, the command will return a response similar to the following:
The command accepts the following parameters:
trustedAddress - mandatory parameter: the address of the trusted demo contract. You will be able to review the list of available external relays later on a dedicated page. Please note that this parameter accepts a uint value, not address. Therefore, you will need to convert the hexadecimal address to decimal
needToRemoveFlag - flag indicating whether to delete the old trusted address of the specified network
solanaEndpoint - solana rpc url
If successful, the command will not output anything. In case of an error, a log will be displayed.
To simplify the process of sending messages to the demo contract, console commands have also been developed.
The command accepts the following parameters:
contractAddress - mandatory parameter: the address of the demo contract in the source network
message - mandatory parameter: the text that will be transmitted from the source network to the destination network
Upon successful execution, the command will return a response similar to the following:
The command accepts the following parameters:
contractAddress - mandatory parameter: the address of the demo contract in the source network
message - mandatory parameter: the text that will be transmitted from the source network to the destination network
Upon successful execution, the command will return a response similar to the following:
Coming soon
The command accepts the following parameters:
amount - mandatory parameter: the value that will be sent to the destination network
srcAddress - mandatory parameter: client sender address in source chain
dstAddress - mandatory parameter: cilent contract address in destination chain
solanaEndpoint - solana RPC URL
If successful, the command will not output anything. In case of an error, a log will be displayed.
Deploy the contracts to the required networks and obtain their addresses. This can be done on both , and
initializerAddress - mandatory parameter: the address of the initializer on the network. You can review the list of available addresses on the respective pages ( or )
relayAddress - optional parameter: the address of an external relay. You will be able to review the list of available external relays on the
networkName - mandatory parameter: the name of the network to which the contract is deployed. You can explore the list of available networks .
initializerAddress - mandatory parameter: the address of the initializer on the network. You can review the list of available addresses on the respective pages ( or )
relayAddress - optional parameter: the address of an external relay. You will be able to review the list of available external relays on the
networkName - mandatory parameter: the name of the network to which the contract is deployed. You can explore the list of available networks
localChainId - mandatory parameter: local chain ID. You can review the list of available networks on the corresponding pages ( or )
trustedChainId - mandatory parameter: the ID of the network of the trusted address. You can review the list of available networks on the corresponding pages ( or )
networkName - mandatory parameter: the name of the source network. You can check the list of available networks .
trustedChainId - mandatory parameter: the ID of the network of the trusted address. You can review the list of available networks on the corresponding pages ( or )
networkName - mandatory parameter: the name of the source network. You can check the list of available networks .
trustedChainId - mandatory parameter: the ID of the network of the trusted address. You can review the list of available networks on the corresponding pages ( or )
trustedChainId - mandatory parameter: the ID of the network of the trusted address. You can review the list of available networks on the corresponding pages ( or )
destinationChainId - mandatory parameter: the ID of the destination network. You can review the list of available networks on the corresponding pages ( or )
networkName - mandatory parameter: the name of the source network. You can check the list of available networks
trustedChainId - mandatory parameter: the ID of the destination network. You can review the list of available networks on the corresponding pages ( or )
networkName - mandatory parameter: the name of the source network. You can check the list of available networks
dstChainId - mandatory parameter: destination chain ID. You can review the list of available networks on the corresponding pages ( or )