githubEdit

From EVM to Secret

Learn how to send testnet USDC from EVM to Secret Network using Axelar

Installing the dependencies

Create a new package.json file and install axelarjs

npm init -y && npm i @axelar-network/axelarjs-sdk

Add type "module" to package.json:

{
  "name": "evm-to-secret",
  "type" : "module",
  "version": "1.0.0",
  "main": "evm-to-secret.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "description": "",
  "dependencies": {
    "@axelar-network/axelarjs-sdk": "^0.16.1"
  }
}

Creating the deposit address

Create a new file named evm-to-secret.js (or whatever you would like to name it) and add the following code to create an Axelar deposit addressarrow-up-right:

circle-info

Make sure you have the correct assetarrow-up-right for testnet. You can either send USDC or AXL cross-chain . Also make sure to update destinationAddress with your Secret testnet wallet address πŸ€—

Run node evm-to-secret to execute createDepositAddress:

A deposit address will be returned in your terminal:

Sending USDC from EVM to Secret Network

Add the Sepolia USDC token to your wallet. Sepolia USDC token contract address:

circle-info

See all USDC token addresses in the Axelar docsarrow-up-right.

Fund your wallet with testnet Sepolia USDC by bridging AXL to sepolia USDC.

First, go to the Axelar discord faucet channelarrow-up-right and request testnet tokes from the faucet:

Then, send testnet USDC from your Axelar wallet address to your Sepolia address using Axelar Satelite: arrow-up-right

Now, simply send Sepolia USDC from your wallet to the deposit address that you created earlier!

circle-info

You can track your token transfer's status on Axelarscanarrow-up-right

Summary

Congrats! You've successfully sent cross-chain USDC from Sepolia testnet to Secret Network using Axelarjs! If you have any questions, ping dev-issuesarrow-up-right on Discord and a developer from the Secret community will assist you shortly.

Last updated

Was this helpful?