2

I was wondering if anyone know a testnet version of Insight API for Bitcoin Cash?

For mainnet there are those:

But I cannot find one for testnet.

Thank you very much.

  • Murch has voted to delete my answer but on the same link (blockdozer) which I mentioned in answer has option for bitcoin cash test network by clicking on ecurrency – rahul Sep 27 '17 at 6:00
3

With a trial & error procedure I've found this one :-)

Prefix for APIs is https://test-bch-insight.bitpay.com/api

For example: https://test-bch-insight.bitpay.com/api/addrs/2MzrMhMEPN9KYsZHgijMqekPa8kmvwsuEVm,2N1w811DgtWzjHdwtP1zzbXqJdh9vNK3sk9,2N3rs2KJBYxZQifg5TY6Bjb8CGcvmYTppsG/utxo

  • Returns 404. The root works but not the /api – arshbot Apr 10 '18 at 21:14
  • That's only the base url, full api call works, I've edited comment adding one example – Alessandro Polverini Apr 11 '18 at 5:06
0

Bitpay did a large refactor of Insight/Bitcore so both BTC and BCH run off the same backend. The new URLs are:

Example: get UTXOs for some random address I grabbed out of a recent block:

$ curl -s https://api.bitcore.io/api/BCH/mainnet/address/qz09ljd3fthvuuasw3tchnhm8a5z5ppm9vc4t6s5pe/?unspent=true | jq

[
  {
    "_id": "5cae0b7912025b0a3983bf75",
    "chain": "BCH",
    "network": "mainnet",
    "coinbase": false,
    "mintIndex": 2,
    "spentTxid": "",
    "mintTxid": "81d1e58956eb5ba269ad3ac6394382825bd9d9b4d3a22eca03133eef19446b72",
    "mintHeight": 577661,
    "spentHeight": -2,
    "address": "qz09ljd3fthvuuasw3tchnhm8a5z5ppm9vc4t6s5pe",
    "script": "76a9149e5fc9b14aeece73b074578bcefb3f682a043b2b88ac",
    "value": 7000000,
    "confirmations": -1
  },
  {
    "_id": "5cae0f6212025b0a3988a698",
    "chain": "BCH",
    "network": "mainnet",
    "coinbase": false,
    "mintIndex": 0,
    "spentTxid": "",
    "mintTxid": "b8b72fa7defb89824f9c31d6294e3764c4675ac085668604113f4b6394d8cdde",
    "mintHeight": 577664,
    "spentHeight": -2,
    "address": "qz09ljd3fthvuuasw3tchnhm8a5z5ppm9vc4t6s5pe",
    "script": "76a9149e5fc9b14aeece73b074578bcefb3f682a043b2b88ac",
    "value": 1111,
    "confirmations": -1
  }
]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.