Skip to main content

npm npm:

npm i @lavanet/lava-web3
import Web3 from "web3";
import { LavaWeb3Provider } from "@lavanet/lava-web3";

async function createWeb3Instance {
// the provider will be initialized automatically by the create() command
const provider = await LavaWeb3Provider.create({
badge: {
badgeServerAddress: "",
projectId: "//" //login to to get a projectId!
chainIds: "ETH1",
geolocation: "1" //optional

return new Web3(provider);

❓ Looking for more examples? Check out the examples folder on our repository.