Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fullpipe/biglion-client
Biglion Api Client
https://github.com/fullpipe/biglion-client
Last synced: about 4 hours ago
JSON representation
Biglion Api Client
- Host: GitHub
- URL: https://github.com/fullpipe/biglion-client
- Owner: fullpipe
- License: mit
- Created: 2015-06-23T12:02:12.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-07-18T06:47:53.000Z (over 7 years ago)
- Last Synced: 2024-10-20T14:44:22.424Z (about 1 month ago)
- Language: PHP
- Homepage:
- Size: 8.79 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Simple Biglion Api Client
## Usage
```php
$bc = new \Fullpipe\Biglion\Client('[email protected]', 'password');try {
var_dump($bc->getCouponInfo('012345-0000-0001'));
var_dump($bc->redeemCoupon('012345-0000-0001', '1234'));
var_dump($bc->reserveCoupon('012345-0000-0001', '387'));
} catch (\Fullpipe\Biglion\BiglionException $e) {
echo $e->getMessage();
}try {
var_dump($bc->getCouponInfo('012345-0000-0002'));
var_dump($bc->redeemCoupon('012345-0000-0002', '1234'));
var_dump($bc->reserveCoupon('012345-0000-0002', '387'));
} catch (\Fullpipe\Biglion\BiglionException $e) {
echo $e->getMessage();
}try {
var_dump($bc->getCouponInfo('012345-0000-0003'));
var_dump($bc->redeemCoupon('012345-0000-0003', '1234'));
var_dump($bc->reserveCoupon('012345-0000-0003', '387'));
} catch (\Fullpipe\Biglion\BiglionException $e) {
echo $e->getMessage();
}
```## Test
```
composer install --dev
[email protected] BIGLION_PASSWORD=password vendor/bin/phpunit
```