diff --git a/CHANGELOG.md b/CHANGELOG.md index e2258c2..533f2d9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +### 1.1.0 +**2015-12-22** + +* Add methods for products api endpoint +* Fix readme links +* Allow parameters for items methods + ### 1.0.1 **2015-12-21** diff --git a/README.md b/README.md index 8907838..bae692d 100755 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ You can install the bindings via [Composer](http://getcomposer.org/). Add this t ```json { "require": { - "vhx/vhx-php": "1.0.*" + "vhx/vhx-php": "1.1.*" } } ``` @@ -63,24 +63,27 @@ $customer = \VHX\Customers::create(array( ### Resources & methods +products + * [`retrieve`](http://dev.vhx.tv/docs/api/?php#product-retrieve) + * [`all`](http://dev.vhx.tv/docs/api/?php#product-list) + +customers + * [`create`](http://dev.vhx.tv/docs/api/?php#customer-create) + * [`retrieve`](http://dev.vhx.tv/docs/api/?php#customer-retrieve) + * [`all`](http://dev.vhx.tv/docs/api/?php#customer-list) + videos - * [`create`](http://dev.vhx.tv/docs/api?php#create_customer) - * [`update`](http://dev.vhx.tv/docs/api?php#update_customer) - * [`retrieve`](http://dev.vhx.tv/docs/api?php#retrieve_customer) - * [`all`](http://dev.vhx.tv/docs/api?php#list_customers) + * [`create`](http://dev.vhx.tv/docs/api/?php#videos-create) + * [`retrieve`](http://dev.vhx.tv/docs/api/?php#videos-get) + * [`all`](http://dev.vhx.tv/docs/api/?php#videos-list) + * [`files`](http://dev.vhx.tv/docs/api/?php#videos-list-files) collections - * [`create`](http://dev.vhx.tv/docs/api?php#create_collection) - * [`update`](http://dev.vhx.tv/docs/api?php#update_collection) - * [`retrieve`](http://dev.vhx.tv/docs/api?php#retrieve_collection) - * [`all`](http://dev.vhx.tv/docs/api?php#list_collections) - * [`items`](http://dev.vhx.tv/docs/api?php#list_collection_items) - -customers - * [`create`](http://dev.vhx.tv/docs/api?php#create_customer) - * [`update`](http://dev.vhx.tv/docs/api?php#update_customer) - * [`retrieve`](http://dev.vhx.tv/docs/api?php#retrieve_customer) - * [`all`](http://dev.vhx.tv/docs/api?php#list_customers) + * [`create`](http://dev.vhx.tv/docs/api/?php#collections-create) + * [`update`](http://dev.vhx.tv/docs/api/?php#collections-update) + * [`retrieve`](http://dev.vhx.tv/docs/api/?php#collections-retrieve) + * [`all`](http://dev.vhx.tv/docs/api/?php#collections-list) + * [`items`](http://dev.vhx.tv/docs/api/?php#collection-items-list) authorizations - * [`create`](http://dev.vhx.tv/docs/api?php#create_authorization) + * [`create`](http://dev.vhx.tv/docs/api/?php#authorizations-create) diff --git a/VERSION b/VERSION index 7dea76e..9084fa2 100755 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.0.1 +1.1.0 diff --git a/composer.json b/composer.json index a1841cd..5bdf13c 100755 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "vhx/vhx-php", - "version": "1.0.1", + "version": "1.1.0", "description": "VHX PHP API Wrapper", "keywords": [ "vhx", diff --git a/init.php b/init.php index 0e4e443..4fac4be 100755 --- a/init.php +++ b/init.php @@ -8,6 +8,7 @@ require(dirname(__FILE__) . '/lib/Authorizations.php'); require(dirname(__FILE__) . '/lib/Collections.php'); require(dirname(__FILE__) . '/lib/Customers.php'); +require(dirname(__FILE__) . '/lib/Products.php'); require(dirname(__FILE__) . '/lib/Videos.php'); // Errors diff --git a/lib/Api.php b/lib/Api.php index 16ef6ba..38cea2a 100644 --- a/lib/Api.php +++ b/lib/Api.php @@ -7,7 +7,7 @@ class Api public static $key; const HOST = 'api.vhx.tv'; const PROTOCOL = 'https://'; - const VERSION = '1.0.1'; + const VERSION = '1.1.0'; public static function setKey($api_key) { self::$key = $api_key; diff --git a/lib/Collections.php b/lib/Collections.php index eafc931..c07eec9 100644 --- a/lib/Collections.php +++ b/lib/Collections.php @@ -15,7 +15,7 @@ public static function create($params = array()) { public static function update($id = null, $params = array()) { return self::_update($id, $params); } - public static function items($id = null) { - return self::_update($id); + public static function items($id = null, $params = array()) { + return self::_update($id, $params); } } diff --git a/lib/Customers.php b/lib/Customers.php index 4d6d657..d2b2237 100644 --- a/lib/Customers.php +++ b/lib/Customers.php @@ -12,7 +12,4 @@ public static function retrieve($id = null) { public static function create($params = array()) { return self::_create($params); } - public static function update($id = null, $params = array()) { - return self::_update($id, $params); - } } diff --git a/lib/Products.php b/lib/Products.php new file mode 100644 index 0000000..453519b --- /dev/null +++ b/lib/Products.php @@ -0,0 +1,12 @@ +