Bitcoin Forum
April 16, 2024, 02:55:15 PM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Warning: One or more bitcointalk.org users have reported that they strongly believe that the creator of this topic is a scammer. (Login to see the detailed trust ratings.) While the bitcointalk.org administration does not verify such claims, you should proceed with extreme caution.
Pages: [1]
  Print  
Author Topic: blockchain.info Payment API  (Read 847 times)
richiela (OP)
Hero Member
*****
Offline Offline

Activity: 937
Merit: 1000


View Profile
November 28, 2013, 04:58:18 AM
 #1

Can anyone help me understand how their payment API works at a bitcoind rpc level?  As far as I can tell, there is no way to see what the balance of an address is, only the number of bitcoins that address has received along with the confirmations for it.

If I were to replicate the blockchain API, i would have to:

* create an address and associated it to an account (destination address)
* check the balance of all accounts
* get a list of all addresses in that account
* check all the addresses looking for the lowest confirmations
    - if value < balance loop back to ensure to check other addresses
* locate callback and call that
* move btcs from account to destination address
* repeat

Is it really that convoluted or am I missing something much simpler?  I currently run a website that processes BTC payments but i'd like to move away from relying on blockchain.info.

Thanks

Looking for the best exchange? -> https://bittrex.com
1713279315
Hero Member
*
Offline Offline

Posts: 1713279315

View Profile Personal Message (Offline)

Ignore
1713279315
Reply with quote  #2

1713279315
Report to moderator
1713279315
Hero Member
*
Offline Offline

Posts: 1713279315

View Profile Personal Message (Offline)

Ignore
1713279315
Reply with quote  #2

1713279315
Report to moderator
1713279315
Hero Member
*
Offline Offline

Posts: 1713279315

View Profile Personal Message (Offline)

Ignore
1713279315
Reply with quote  #2

1713279315
Report to moderator
Activity + Trust + Earned Merit == The Most Recognized Users on Bitcointalk
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1713279315
Hero Member
*
Offline Offline

Posts: 1713279315

View Profile Personal Message (Offline)

Ignore
1713279315
Reply with quote  #2

1713279315
Report to moderator
1713279315
Hero Member
*
Offline Offline

Posts: 1713279315

View Profile Personal Message (Offline)

Ignore
1713279315
Reply with quote  #2

1713279315
Report to moderator
doof
Hero Member
*****
Offline Offline

Activity: 765
Merit: 503


View Profile WWW
November 28, 2013, 11:20:23 PM
 #2

The simple address method shows you final balance (final_balance) property

http://blockchain.info/address/$bitcoin_address?format=json

Eg http://blockchain.info/address/1Cvy1Exv3y6FT6oLp7va6jmEVqBsM3fTPw?format=json should yield 0.0021

richiela (OP)
Hero Member
*****
Offline Offline

Activity: 937
Merit: 1000


View Profile
November 29, 2013, 03:29:12 AM
 #3

The simple address method shows you final balance (final_balance) property

http://blockchain.info/address/$bitcoin_address?format=json

Eg http://blockchain.info/address/1Cvy1Exv3y6FT6oLp7va6jmEVqBsM3fTPw?format=json should yield 0.0021



Yup I understand that, but how do I get that same info using JSON-RPC to the bitcoind daemon?  Does blockchain actually keep tracking of every transaction? 

Looking for the best exchange? -> https://bittrex.com
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!