/altcoin-bitcoin-explorer

PHP Altcoin/Bitcoin Data Explorer

Primary LanguagePHPMIT LicenseMIT

Altcoin/Bitcoin Data Explorer

Build Status SensioLabs Insight License Latest Stable Version

PHP Altcoin/Bitcoin data Explorer

This package can get transaction information with Bitcoin protocol.

It can send HTTP requests to a Bitcoin peer server to perform several operations.

Currently it can get transaction details, get peer information, get mining information, get network hashes, get block chains, etc..

Installation

You can install this library by using [Composer]. You can also view more info about this on [Packagist].

Add this to the require section in your composer.json file.

{
    "require": {
        "arzzen/altcoin-bitcoin-explorer": "1.1.*"
    }
}

Usage

use BlockExplorer\BlockChain;

$block = new BlockChain($ip, $port, $username, $password);

$blockInfoFromHash = $block->getBlock('000000000000000007c4695c756bb944cf31f1f20487a32375d9d4c61dfd6349');
$blockInfoFromHeight = $block->getBlockHash('308788');

var_dump($blockInfoFromHash, $blockInfoFromHeight);

Award

Class won "PHP Programming Innovation Award" on phpclasses.org (August 2014). Link.