This is basic PHP library for CoinPayments API. It's written without any external dependencies and it allows you to add your own HTTP agents like Guzzle. CoinPayments is one of the largest cryptocurrency payment processors. They support over few hundred cryptocurrencies. Amongst those are better known Bitcoin, Litecoin, Ethereum, Monero... some lesser known/used coins like Ubiq, Peercoin, GameCredits and they even support shitcoins like Ripple.
use Sigismund\CoinPayments;
$coinPaymentsAPI = new CoinPayments($merchantID, $publicKey, $privateKey, $ipnSecret);
// Get conversion rates for all supported currencies
$rates = $coinPaymentsAPI->getRates();
// Sample transaction for 16$
$coinPaymentsAPI->createTransaction(16, 'USD', 'BTC', $additional = []);
- PHP >= 7.0
This library does not have any external dependencies.
The recommended way to install this library is through Composer.
# Install Composer
curl -sS https://getcomposer.org/installer | php
Next, run the Composer command to install the latest stable version of CoinPayments PHP library:
composer require sigismund/coinpayments
After installing, you need to require Composer's autoloader:
require 'vendor/autoload.php';
You can then later update library using composer:
composer.phar update
... all pull requests are welcome ;)
Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.
We use SemVer for versioning. For the versions available, see the tags on this repository.
- Žiga Drnovšček - Initial work - Sigismund
See also the list of contributors who participated in this project.
This project is licensed under the MIT License - see the LICENSE file for details
- Hat tip to anyone who's code was used
- Inspiration
- etc