bsv-pay

    0.0.10 • Public • Published

    bsv-pay

    NPM Package

    Broadcast bitcoin transactions to miners

    Current supported services:

    • mattercloud
    • matterpool
    • mempool
    • taal
    • whatsonchain

    Use

    npm install bsv-pay

    const BsvPay = require('bsv-pay')
    
    const pay = new BsvPay({
        fetchFunc: require('node-fetch'),  // Node.js
        // fetchFunc: fetch, // Browser
        mattercloud: {
            api_key: ''
        },
        mempool: {
            token: ''
        },
        // whatsonchain: false // To disable specific service
    })
    const { txid } = await pay.broadcast({ tx, verbose: false })
    const { valid } = await pay.status({ txid, verbose: true })
    pay.feePerKb()
    

    Tests

    npm run test

    Install

    npm i bsv-pay

    DownloadsWeekly Downloads

    9

    Version

    0.0.10

    License

    MIT

    Unpacked Size

    11.5 kB

    Total Files

    14

    Last publish

    Collaborators

    • kevinejohn