Bitcoin Forum

Bitcoin => Project Development => Topic started by: coinerd on June 26, 2013, 09:51:12 PM



Title: Block Crawler - Portable Block Explorer
Post by: coinerd on June 26, 2013, 09:51:12 PM
Hello hello!

Today I am releasing my first Open Source / Github project.

What Is Block Crawler?
Block Crawler is a block chain viewer for Bit Coin-derived block chains.

What does that mean?
Block Crawler connects to a Bit Coin daemon using JSON-RPC via php.
It then uses HTML and CSS to display the data for the user.

What makes Block Crawler "portable"?
Block Crawler does not use a database.  The information is retrieved real time directly from the daemon.  This means that you can quickly add the files to any web server with PHP and cURL support and begin viewing the designated block chain immediately.

What currencies Does Block Crawler Support?
At this time I have not found a Bit Coin derived daemon that is incompatible with Block Crawler.

Does Block Crawler support <insert BBE or ABE feature name>?
If you're asking, probably not.  In order to retain it's portable nature and work without a database, Block Crawler is unable to search the block chain, or display information that is not included within the block itself. This means that it will also be unable to track individual addresses, or provide account specific information.

Well what does it do then?
Block crawler provides a friendly interface for viewing information contained in the block chain. It allows you to view a block by it's block height, to view a block by it's block hash, and to view transaction details in both native hex format and formatted into HTML.

Why would I use Block Crawler?
Perhaps you would like to view details in a block chain with no public block explorer.  
Perhaps you would like to view certain details in private ;)
Perhaps you're looking for some well-commented tutorial code on communicating with a wallet in procedural PHP
    (Block Explorer uses JSON-RPC calls with 0,1,and 2 parameters via cURL to communicate with the daemon)
Perhaps you would like a tool to load block chain data into a database, so that you can research or review it more thoroughly.
I'm sure that someone will find something else to do with it, as well.

How Is Block Crawler licensed?
I am releasing this code into the public domain. I hope it gets used and I have no desire to stop you from integrating it into your projects, commercial or otherwise. Have Fun!

Will new features be added to Block Crawler?
There is currently no road map for adding features to this script.

Does Block Crawler support non-Bit Coin derived features?
At this time, the release version includes handling and display of the FLO (Florin Coin) tx-comment field. If there are other block formats or additions to daemons in the future, I will attempt to add support to Block Crawler.

Is Block Crawler compatible with RPCSSL protected daemons:
It sure is!

Is there a place where I can see Block Crawler in action?
Yes, there is. Visit The Florin Coin Block Explorer (http://lotto.coinworld.us/FLO/bc/) This page has an earlier version of the included CSS, some of the "blocks" in the Florin Coin Explorer are missing from the Block Crawler distribution, notably the gray box in the header, and the empty footer box.

Troubleshooting Tips:
If you are unable to view transactions that you see listed in blocks, you may need to stop your daemon, add the line "txindex=1" to your .conf file, and restart the daemon using the -rescan command line switch.

Where Can I Download Block Crawler?
https://github.com/CallMeJake/BlockCrawler


Questions, Feedback, and Donations are all 100% welcome. This is my first project ever on GitHub I'm learning how it works, so let me know how it goes if you check it out.


Title: Re: Block Crawler - Portable Block Explorer
Post by: Cyberdyne on June 26, 2013, 11:29:56 PM
Where Is a link to Block Crawler / How do I download it?
I have no idea.


Title: Re: Block Crawler - Portable Block Explorer
Post by: Carsen on June 27, 2013, 12:48:05 AM
Yea...Link to github page? Or site? More information?


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on June 27, 2013, 01:39:25 AM
 :-X

OP updated

Sorry guys.


Title: Re: Block Crawler - Portable Block Explorer
Post by: Lauda on June 27, 2013, 09:19:46 AM
Nice release!


Title: Re: Block Crawler - Portable Block Explorer
Post by: d2.cc on June 27, 2013, 09:50:22 AM
A nice contribution to the community for sure. I think something may be wrong with your demo though as searching for any block index yields error:

Quote
Transactions In This Block

Warning: Invalid argument supplied for foreach() in /mounted-storage/home108b/sub003/sc19442-IBAS/coinworld/lotto/FLO/bc/bc_layout.php on line 190


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on June 27, 2013, 04:23:57 PM
A nice contribution to the community for sure. I think something may be wrong with your demo though as searching for any block index yields error:

Quote
Transactions In This Block

Warning: Invalid argument supplied for foreach() in /mounted-storage/home108b/sub003/sc19442-IBAS/coinworld/lotto/FLO/bc/bc_layout.php on line 190

Apparently there's a problem at the server.

Its a busy, busy box and at this moment the FLO wallet is down.

Just got out of bed and I hope this is straight really quick, I apologize for the non-functioning demo. Looking at the timing of you r post I hope it hasn't been down 7 hours  :(


Title: Re: Block Crawler - Portable Block Explorer
Post by: Petr1fied on July 01, 2013, 07:22:00 PM
Thanks for the script, I'm currently testing it on my 3 coin faucets to show proof of payment:

http://doubloons.kicks-ass.net
http://bottlecaps.kicks-ass.net
http://krugercoin.kicks-ass.net

It's really easy to add and I don't need to rely on public block explorers which are sometimes only up for a few hours a day. Good work.


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on July 03, 2013, 03:57:30 AM
Thanks for the script, I'm currently testing it on my 3 coin faucets to show proof of payment:

http://doubloons.kicks-ass.net
http://bottlecaps.kicks-ass.net
http://krugercoin.kicks-ass.net

It's really easy to add and I don't need to rely on public block explorers which are sometimes only up for a few hours a day. Good work.

Glad to know it's seeing use.

I put some bottlecaps in, and requested some doubloons out.


Title: Re: Block Crawler - Portable Block Explorer
Post by: Petr1fied on July 04, 2013, 05:59:46 PM
It's a nice script. I've made a few tweaks of my own. ;)


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on July 04, 2013, 06:36:33 PM
It's a nice script. I've made a few tweaks of my own. ;)

The joys of open source!

After I've had a chance to put some instructions in and test it with the release code I'll add the feeds I wrote for the FLO version later today or tomorrow.

I think this script should be very simple to understand and modify, even for a "Beginner" php developer. No one else has reported using it, but I saw some screencaps yesterday from a site I didn't know about.

Makes me happy  ;D


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on July 09, 2013, 05:02:33 AM
OK-

I have too many irons in the fire, this update has been delayed however it is here now and better than originally planned.

I have added the API for Block Crawler to the repository.  Unlike my original work for FLO, this is a pass-through API which takes standard JSON-RPC method requests directly. In most cases the information is returned in a JSON wrapper however int he case of calls which return a single value from the daemon, the API returns a single value as well.

This means that you get a JSON object if you request "getinfo" but you just get an integer response if you request "getnetworkhashps".

This means that this API will also return previously unknown methods such as "getprimespersec".

It also includes several blocks, as the pass-through would allow malicious access to some commands such as "stop" ;)

I also blocked balance requests, peer detail requests, transaction lists, and account lists. Duplicating these blocks in the code should be very simple if you wish to limit the API functionality further for your installation.

Requests which require one or more parameters are unsupported, the method will be allowed but the daemon will simple return an error message which the API will return to the user.

Some sample URLS for the FLO endpoint:

        http://lotto.coinworld.us/FLO/bc/bc_api.php?request=getinfo

        http://lotto.coinworld.us/FLO/bc/bc_api.php?request=getnetworkhashps
 
       http://lotto.coinworld.us/FLO/bc/bc_api.php?request=getconnectioncount

Unsupported method (requires parameter):

        http://lotto.coinworld.us/FLO/bc/bc_api.php?request=sendtoaddress+1234faerAFf314f4f3c34df314DD

Blocked methods:

       http://lotto.coinworld.us/FLO/bc/bc_api.php?request=stop

       http://lotto.coinworld.us/FLO/bc/bc_api.php?request=getbalance

This should allow you to create status panels, feed other web services, and generally make casual requests to the daemon behind your Block Crawler.

Enjoy!


Title: Re: Block Crawler - Portable Block Explorer
Post by: 🏰 TradeFortress 🏰 on July 09, 2013, 05:43:26 AM
That's nice, except I can see your balance anyway.

http://lotto.coinworld.us/FLO/bc/bc_api.php?request=listreceivedbyaddress


Title: Re: Block Crawler - Portable Block Explorer
Post by: coinerd on July 09, 2013, 07:20:16 AM
That's nice, except I can see your balance anyway.

http://lotto.coinworld.us/FLO/bc/bc_api.php?request=listreceivedbyaddress

Thanks for reporting this.

I suppose I'll have to run through every command and see which ones have parameters but will respond to a 0 parameter request.

That's work for tomorrow.  The fix for listreceivedbyaddress is committed to the repo.


Title: Re: Block Crawler - Portable Block Explorer
Post by: wanghaoqd on September 18, 2013, 09:39:48 AM
Thank you for this awesome little thing~!


Title: Re: Block Crawler - Portable Block Explorer
Post by: vual on September 29, 2013, 02:04:08 PM
Could a confirmation count be retrieved on transaction using this api ?


Title: Re: Block Crawler - Portable Block Explorer
Post by: smeagol on October 19, 2013, 11:25:15 PM
How can I get data from here: http://primecoin.21stcenturymoneytalk.org/


Title: Re: Block Crawler - Portable Block Explorer
Post by: gatra on March 06, 2014, 07:43:03 PM
used it for Riecoin, http://riecoin.biz/explorer/block_crawler.php and it works!
Thanks!



Title: Re: Block Crawler - Portable Block Explorer
Post by: Dimelord on April 15, 2014, 03:10:22 PM
This is a beautiful piece of software


Title: Re: Block Crawler - Portable Block Explorer
Post by: Dimelord on April 15, 2014, 03:18:24 PM
This is a beautiful piece of software
Could I embed this in a google sites page?


Title: Re: Block Crawler - Portable Block Explorer
Post by: wheetap on April 15, 2014, 08:36:46 PM
Very nice, thanks for sharing. Definitely gonna share this to a friend, he's NUTS about open source. (plus, it's about Bitcoin, and he got into that when it was worth about 10€)