jlorente / zadarma-php-sdk
A PHP package to access the Zadarma API by a comprehensive way.
Installs: 9 299
Dependents: 1
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 1
Open Issues: 3
Requires
- php: >=5.6
- guzzlehttp/guzzle: >=6.0
This package is auto-updated.
Last update: 2024-11-21 19:53:52 UTC
README
A PHP package to access the Zadarma API by a comprehensive way.
Installation
The preferred way to install this extension is through composer.
With Composer installed, you can then install the extension using the following commands:
$ php composer.phar require jlorente/zadarma-php-sdk
or add
... "require": { "jlorente/zadarma-php-sdk": "*" }
to the require
section of your composer.json
file.
Configuration
You can set the api keys as environment variables or add them later on Zadarma class instantiation.
The name of the environment variables are ZADARMA_API_KEY and ZADARMA_API_SECRET.
Usage
Endpoints calls must done through the Zadarma class.
If you haven't set the environment variables previously, remember to provide them on instantiation.
$zadarma = new \Jlorente\Zadarma\Zadarma($apiKey, $apiSecret); $zadarma->api()->getBalance();
All the API methods are well documented in the Jlorente\Zadarma\Api class.
License
Copyright © 2019 José Lorente Martín jose.lorente.martin@gmail.com.
Licensed under the BSD 3-Clause License. See LICENSE.txt for details.