Skip to main content

npm npm:

npm i @lavanet/lava-cosmjs
const { Tendermint37Client } = require("@cosmjs/tendermint-rpc");
const { LavaCosmJsRPCClient } = require("@lavanet/lava-cosmjs");

async function getAbciInfo() {

//LavaCosmJsRPCClient is initialized upon calling create()
const client = await LavaCosmJsRPCClient.create({
// privatekey or badge must be supplied
badge: {
badgeServerAddress: "https://badges.lavanet.xyz",
projectId: "//" //login to gateway.lavanet.xyz to get a projectId!
},
chainIds: "LAV1",
lavaChainId: "lava-testnet-2",
geolocation: "1", //optional
})

const client = await Tendermint37Client.create(client);

console.log(client.abciInfo());
}

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