Skip to content

Blockwise Ethereum transaction monitor API for React and Javascript applications to track transaction status in certain block number.

License

Notifications You must be signed in to change notification settings

dsuthardeqode/txn-monitor

Repository files navigation

Transaction Monitor API

Simple Ethereum transaction monitor for transaction status polling. Blockwise Ethereum transaction monitor API for React and Javascript applications to track transaction status in certain block number.

Use case

import checkTransactionStatus from "@0xdeepak/transaction-monitor"

// OR

const checkTransactionStatus = require("@0xdeepak/transaction-monitor")

async function checkStatus() {
    // add your transaction hash
    const res = await checkTransactionStatus({txnHash:'0x......',chainId:137,maxConfirmationBlocks?:50})

    // res

    {
        status: "txConfirmed" | "txRequested" | "txFailed",
        message: "Transaction is pending",
        receipt?: Object
    }
}

APIs

checkTransactionStatus()

Paramter Type Description
txnHash string Transaction has to be tracked.
chainId number Transaction chain id
maxConfirmationBlocks number It is option field, default value is 50 blocks.

About

Blockwise Ethereum transaction monitor API for React and Javascript applications to track transaction status in certain block number.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published