Download the PHP package arodygin/linode-api-php without Composer
On this page you can find all versions of the php package arodygin/linode-api-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download arodygin/linode-api-php
More information about arodygin/linode-api-php
Files in arodygin/linode-api-php
Package linode-api-php
Short Description Linode API v3 Client Library for PHP
License MIT
Homepage https://github.com/webinarium/linode-api3
Informations about the package linode-api-php
Linode API v3 Client Library for PHP
This library implements full spec of Linode API v3 (in accordance with https://www.linode.com/api/utility/api.spec), including functions which are not described at the Linode's site yet (the documentation seems to be slightly outdated at the moment).
The library wasn't actually implemented, but autogenerated from the spec. This approach provides several advantages as:
- we can be sure that nothing from the spec is missed,
- no implementation errors which could be caused by human factor,
- in case of the spec extension it's fast and easy to update the library's code.
Also please note that "test.echo" is skipped from the implementation.
Warning
The library addresses Linode's legacy API. For most recent API please refer to this library.
Requirements
PHP needs to be a minimum version of PHP 5.6.
Installation
The recommended way to install is via Composer:
Usage Example
Below is a complete example of how to create a new Linode host using the library:
Batching Requests
The Linode API also supports a batched mode, whereby you supply multiple request sets and receive back an array of responses. Example batch request using the library:
Tests
Almost all tests are mocked so you don't have to use a real API key and no real linodes are affected.
The only tests which make a complete API call are TestTest
(for "test.echo") and ApiTest
(for "api.spec"):
Library regeneration
If you would like to regenerate the library code, you can do it with two simple steps:
All versions of linode-api-php with dependencies
ext-curl Version *
ext-json Version *