I am currently using BlockChain.info's API to do payment verification with, but have a few questions.
How I am using it (I think I am using it in the right way....):
- I am issuing a new/clean address to for each sale.
- I am then checking the balance of the address and the transactions (tx->out) to get the time of the transaction, the value and the block height (of which I am using to get the confirmed count from)
- I then add the transaction details to my database/System and display the relevant message to the user.
- An automated script then runs to collect/update the confirmed count (and updates this info into my database).
I have been building this by making bitcoin transactions to myself, but of course all my test transactions are genuine, so I don't know how "bad" transactions will be represented!
What I am unsure on, is how will double spends (or dropped transactions/spends/fraud) be represented? Will the transaction simply disappear? And will this then effect the balance shown against the address? Or will the block height simply change to 0/NULL?
Any advice on this would be greatly welcomed!