Get Litecoin address transaction updates via websockets

node v10.22.1
version: 3.0.0
endpointsharetweet
const Web3Data = require("web3data-js@0.6.1") const w3d = new Web3Data('YOUR_API_KEY', { blockchainId: 'f94be61fd9f4fa684f992ddfd4e92272' }) // Initialize the connection w3d.connect() // Subscribes to address transaction events // https://docs.amberdata.io/reference#ws-address-pending-transactions w3d.on({eventName: 'address:transactions', filters: {address: "LMo6GEXpE3wzp743Q2Uu8czmqwUhBAF9Pm"}}, transaction => { console.log(transaction) }) w3d.on({eventName: 'address:pending_transactions', filters: {address: "LMo6GEXpE3wzp743Q2Uu8czmqwUhBAF9Pm"}}, pdtxn => { console.log('address:pending_transactions', pdtxn) }) // https://docs.amberdata.io/reference#ws-pending-transaction w3d.on({eventName: 'pending_transaction'}, pdtxn => { console.log('pending_transaction', pdtxn) })
Loading…

no comments

    sign in to comment