shopper – Bitpay check account Java SDK integration: Inadequate steadiness error when paying bill

0
27


Downside
I arrange a Bitpay check account and loaded my Bitpay pockets with testnet BTC. Nonetheless I am seeing an in an "Inadequate funds for payment" error when paying an bill with the Bitpay Java SDK. Double checked the BTC quantity in my pockets and it is lower than the complete whole (together with the payment) and even tried manually setting the miner payment to 0 from the Bill object.

Anticipated Conduct
Consumer mustn’t obtain “Inadequate funds for payment” error when opening the URL generated by the Bill.

Code

// Config file
{
  "BitPayConfiguration" : {
    "Atmosphere" : "Take a look at",
    "EnvConfig" : {
      "Take a look at" : {
        "PrivateKeyPath" : "",
        "PrivateKey" : "xxx",
        "ApiTokens" : {
          "payout" : "yyy",
          "service provider" : "zzz"
        }
      }
    }
  }
}


// app code
    enjoyable createClient() {
        val configFilePath = ConfigFilePath("src/major/assets/BitPay.config.json")
       bitpayClient = Consumer.createClientByConfigFilePath(configFilePath)
    }


enjoyable createInvoice(bitpayClient: Consumer) {
    var bill = Bill(0.00002, Foreign money.BTC)
    bill.autoRedirect = true
    bill = bitpayClient.createInvoice(bill)
    bill.merchantName = null
    bill.minerFees.btc.satoshisPerByte = 0.0
    bill.minerFees.btc.totalFee = 0

    val end result: Bill = bitpayClient.createInvoice(bill)
}

Balances and whole due

  • testnet BTC steadiness: 0.00033
  • whole due (BTC): 0.00017439

enter image description here

LEAVE A REPLY

Please enter your comment!
Please enter your name here