Is there any web service anywhere that allows me to push raw transactions to the network via an ajax call? Blockchain's pushtx only works if you copy/paste so I can't build around it.
-
If you are building a service you need to make your own endpoint. Relying on anyone elses has privacy implications, and opens them to censoring you at their leisure.– ClarisJun 17, 2015 at 20:21
-
I agree, but I'm not able to deal with the legal implications of running my own service =(– A FJun 17, 2015 at 20:22
2 Answers
Looks like the premise of this question was wrong. Blockchain.info DOES support raw transactions via ajax however you have to include ?cors=true
to the end.
Note they also require application/x-www-form-urlencoded
data. Here's what my request looked like in angular
$http({
method: 'POST'
,url: 'https://blockchain.info/pushtx?cors=true'
,data: $.param({tx:txHex})
,headers:{
"Content-Type":"application/x-www-form-urlencoded"
}
})
There are like a million services that will let you do this.
LuxStack - https://luxstack.com/docs (Ctrl-F "pushTransaction")
Chain.com - https://chain.com/docs#bitcoin-transaction-send
Any BitcoinJS exit node - https://github.com/bitcoinjs/node-bitcoin-exit/wiki/REST-API
Blocktrail.com - https://www.blocktrail.com/api/docs#sending_transactions
I'm sure there's more I'm forgetting.
-
Heads up, helloblock will be shutting down soon (it officially suspended on apr 1 2015). I'll check out the others. Thanks!~– A FJun 17, 2015 at 20:46
-
So it looks like all the services you listed require API Keys, which may not work in my use case. And the "permanent" exit node listed on the bitcoinjs repo is down so its probably safe to consider the project dead.– A FJun 17, 2015 at 21:06
-