This is an experimental release of converted PHP version of Peakium Ruby bindings.
1. Add peakium-php to your application's composer.json. { // ... "require": { "peakium/peakium-php": "dev-master" }, // ... } 2. Run composer intall
Set API key:
\Peakium::$api_key = "you_secret_api_key";
Retrieve a customer:
$customer = \Peakium\Customer::retrieve("test_customer");
Create a submission form:
$submission_form = \Peakium\SubmissionForm::build('create-subscription', $args);
Cancel a subscription:
$customer->cancel_subscription("test_subscription");
The library will throw exceptions when errors are encountered, e.g. if a resource doesn’t exist.
-
php 5.2
-
php_curl extension
-
php_json extension