This guide helps you fully configure and run a script to send IBC messages from Xion Testnet to Sei Testnet using Union’s CosmWasm contract.
sudo apt update && sudo apt install -y wget curl git nano tar jqwget https://go.dev/dl/go1.22.2.linux-amd64.tar.gz
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf go1.22.2.linux-amd64.tar.gz
echo 'export PATH=$PATH:/usr/local/go/bin' >> ~/.bashrc
source ~/.bashrc
go versiongit clone https://github.com/burnt-labs/xion
cd xion
make install
xiond version# Create a new wallet (or restore with your mnemonic)
xiond keys add wallet --keyring-backend test
# OR
# xiond keys add wallet --recover --keyring-backend test
# Check address & balance
xiond keys show wallet -a --keyring-backend test
xiond q bank balances $(xiond keys show wallet -a --keyring-backend test) --node https://rpc.xion-testnet-2.burnt.com:443git clone https://github.com/ShinosukaGG/Union-Sei-Script-Guide.git
cd Union-Sei-Script-Guidenano instruction.hexPaste the correct 0x... hex instruction string from Union dashboard or manually constructed. Go to https://app.union.build/ and perform a Xion -> Sei transaction. Visit the block explorer and copy the instruction as show below (add 0x in start):
chmod +x xion_to_sei.sh && ./xion_to_sei.sh- The
instruction.hexfile must contain a valid Union instruction (starting with0x). - Script uses
xion-testnet-2and correct Union contract for sending from Xion to Sei. - Make sure the source wallet has enough
uxionbalance to cover multiple sends.
Add a different wallet:
xiond keys add wallet --recover --keyring-backend testCheck balance:
xiond q bank balances $(xiond keys show wallet -a --keyring-backend test) --node https://rpc.xion-testnet-2.burnt.com:443Reopen instruction:
nano instruction.hexTerminate script:
Ctrl + CIf any error/feedback dm me @Shinosuka_eth on Telegram, Twitter or Discord
