Download the PHP package peterfox/bitpayclient without Composer

On this page you can find all versions of the php package peterfox/bitpayclient. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package bitpayclient

BitPayClient

The purpose of this library is to be an object orientated alternative to the official BitPay PHP library.

The library is designed to make it easier to integrate BitPay in to more heavy PHP frameworks that use composer as a package manager such as Symfony2 and Laravel.

The library is written by myself, Peter Fox.

Version

1.1.0 - 16th March 2014 - Allows for throwing exception when an error api response is returned 1.0.0 - 5th Feburary 2014

Installation

Add to your projects composer.json

Then run composer install or composer update to install this package.

Usage

The most basic use is as follows:

You can supply further parameters for creating an invoice via a third array parameter (to see all possible parameters read the BitPay API):

You can also supply a PosData value as an array and it will be sent as a Base64 encoded string (please note that other data will be modified to be base64 as well):

The library also allows for making responses from Array (like from a $_POST):

There's also the functionality of getting an invoice from BitPay's API if you so wish:

Testing

After cloning and installing this repo you can run /vendor/bin/phpunit in the root of the project and test it.

You will have to create a file called apikey.txt in the root directory of the project containing your api to actually run these tests.

The testing of this project uses PHP-VCR which is useful for running the tests multiple times as testCreateInvoice_LimitExceeded() test will cause BitPay to send you an email as a warning which can be a bit tedious. The fixtures are all stored in test/fixtures/.

License

GNU GPL Version 3


All versions of bitpayclient with dependencies

PHP Build Version
Package Version
Requires php Version >=5.4.0
guzzle/guzzle Version ~3.8
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package peterfox/bitpayclient contains the following files

Loading the files please wait ....