Blockchain for Laravelists! Create & manage wallets, send funds and generate payment gateways.

dev-master 2014-10-22 06:52 UTC


A fully-featured API to make use of API.


Just add the package to your composer.json

"maurocasas/blockchain": "*"

And then run in your Laravel root directory

composer update

Open up app/config/app.php and under $providers array() register the package provider


This will also register the facade for you to use, for example


If you're going to create wallets, and send funds using this package, you need to register an API key from or you'll get rejected.

You can request an API Key at (Usually takes a day or two)


Create Wallets

Create Wallets API Documentation

To create wallets you'll need an API key, yes or yes.

Blockchain::createWallet('MAIN PASSWORD', 'PRIVATE KEY', 'LABEL', 'EMAIL ADDRESS')

Only Main Password is mandatory, you can ommit the rest if you want.

Query API

Query API Documentation

You can use any function in the documentation with the exact same name, so for example I could do


If you want to use any function which requires a parameter, just send it in the function, for example:

Blockchain::getsentbyaddress('PUBLIC KEY')

Exchange Rates

Charts & Statistics API Documentation



You can look at all the available charts over here The URL slug for the chart is needed here.

Just use the total-bitcoins part. All charts are available.


Returns all Blockchain statistics


Exchange Rates API

Exchange Rates API Documentation



Convert currencies to BTC

Blockchain::toBTC(500, 'JPY')

Currencies allowed

  • USD (by default)
  • ISK
  • HKD
  • TWD
  • CHF
  • EUR
  • DKK
  • CLP
  • CAD
  • CNY
  • THB
  • AUD
  • SGD
  • KRW
  • JPY
  • PLN
  • GBP
  • SEK
  • NZD
  • BRL
  • RUB