Truffle

Create an Ethereum Account​

We recommend using the @truffle/hdwallet-provider package for key management. Instructions can be found here.

Add Networks to truffle-config.js

To deploy and interact with Astar, modify networks in truffle-config.js to include Astar's networks:​

// truffle-config.js
module.exports = {
  networks: {
    // ... any existing networks (development, test, etc.)

    // Lumia faucet: https://testnet-faucet.lumia.org
    lumia-testnet: {
      url: "https://testnet-rpc.lumia.org",
      network_id: 1952959480,
    },
    // ...
  },

  // ...
};

Deploy/Migrate by running truffle migrate --network lumia-testnet, replacing lumia with your chosen network. If --network is not specified, the network values underdevelopment will be used.

Last updated