constWeb3=require("web3");asyncfunctionmain() {constWeb3=require('web3')constrpcURL='1DLT-IP-ADDRESS'// Your RPC URL goes hereconstweb3=newWeb3(rpcURL)// Query the blockchain (replace example parameters)constid=awaitweb3.eth.net_version(); // Print the output to consoleconsole.log(id); }main();
const { ethers } =require("ethers");asyncfunctionmain() {// Initialize an ethers instanceconstprovider=newethers.providers.JsonRpcProvider("1DLT-IP-ADDRESS");// Query the blockchain (replace example parameters)constid=awaitprovider.net_version(); // Print the output to consoleconsole.log(id); }main()
curl1DLT-IP-ADDRESS \-X POST \-H "Content-Type: application/json" \-d '{"jsonrpc":"2.0","method":"net_version","params":[],"id":67}'