Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: init1 on July 02, 2015, 05:35:24 AM



Title: get TXID by address or redeemScript
Post by: init1 on July 02, 2015, 05:35:24 AM
Hello!

Do we have any chance to get 'txid' by address or redeemScript into console command ?

BR!


Title: Re: get TXID by address or redeemScript
Post by: mezzomix on July 02, 2015, 06:31:23 AM
You can calculate the P2SH address from a redeem script. There is a JavaScript implementation at https://coinb.in/ (https://coinb.in/) and https://multisig.btcnet.eu/ (https://multisig.btcnet.eu/). You are able to use this code with node.js to execute the code from the command line.

To get the transaction identifiers for a certain address you need a blockexplorer or a Bitcoin client with addressindex patch. There might be multiple transactions per address.


Title: Re: get TXID by address or redeemScript
Post by: init1 on July 02, 2015, 08:25:34 AM
Thank you,
Can you advice block-chain explorer like bitcoind or online service with open API ?


Title: Re: get TXID by address or redeemScript
Post by: neutraLTC on July 02, 2015, 08:57:51 AM
Thank you,
Can you advice block-chain explorer like bitcoind or online service with open API ?


Check out BlockTrail's Block Explorer here (http://www.blocktrail.com/BTC).

We also provide a wide range of API's for your app, you can find more information on that here (https://www.blocktrail.com/api/docs) and a technical blog post about with all we offer here (https://blog.blocktrail.com/2015/06/blocktrails-developer-platform/).

Oh and btw, we have a fair usage policy in place for our API's and SDK's, so you can have peace-of-mind that you won't ever need to pay for our services.

Let me know if you need some assistance in anything  :)


Title: Re: get TXID by address or redeemScript
Post by: mezzomix on July 02, 2015, 10:51:05 AM
Can you advice block-chain explorer like bitcoind or online service with open API ?

There is an address index patche for bitcoin-core. blockchain.info has an API that returns all unspent outputs for an address.


Title: Re: get TXID by address or redeemScript
Post by: fbueller on July 02, 2015, 02:25:27 PM
Blockchain.info's API isn't as capable as it should be.. I've also found it unreliable at times. Blocktrail are probably the better bet, since you can push webhooks to subscribe to new events (like receipt of funds on a new address).