CH

May 17, 2015

how to process bitcoin transactions for your webapp (or: the ghetto watch-only-wallet)

Filed under: Uncategorized — @ 12:00 a.m.
how to process bitcoin transactions for your webapp (or: the ghetto watch-only-wallet)

(This post hardly deserves to be written. However, I've had to explain this to people several times now, so here we are.)

If you're going to build a webapp that has something to do with Bitcoin, you've got no excuse but ignorance and poverty for not running your own node. No APIs, no external parties! Your app - your payment processing. Do it right!

  1. Pick a bitcoind to run.

    While this will take you the most time, it is probably the least important part of the project. Don't use any post-0.8.6 releases of the mainstream client, 0.7.3 is entirely adequate. The Go implementation by Conformal is solid and well-tested and I've read at least some of its source and tests without my eyes bleeding and falling out of my skull (hey I have to earn my negrating!). Again, you'll spend a lot of time on this, and it ultimately doesn't matter.

  2. Turn it on and let it sync.

    This will feel interminable. Come hang out in #bitcoin-assets and complain about life with the rest of us.

  3. Implement logic in $blub
    • ask your node for the latest block
    • look for transactions to addresses of interest
    • diddle your database appropriately

And you're done! If you want to get fancy, run multiple nodes in tandem and compare their results.

No Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URL

Reply

« veh patch: overall improvements --- CORRECTION: multiple channel patches for irc/logbot »