A PHP-Wrapper for the Twitch API (Kraken)
Kamui is a complete Wrapper for the Twitch API which allows you to easily use it. Currently it's supporting the most up to date version of the API (v5).
The best way to install Kamui is using Composer:
composer require prefixaut/kamui
Using the API is really easy as it orientates a lot on the structure of the Original API. Example usage:
use Kamui\API;
$api = new API($my_twitch_token);
$api->users->follows('prefixaut'); // Will give you a List of all Channels I follow
Every function simply returns the original content of the Resource as Objects. If any error occurs, it'll simply return false to prevent accidental breaks. You can also use all Objects however you like them within the API like so:
$cool_dude = $api->users->get('prefixaut');
$api->users->follows($cool_dude);
$api->users->follows($cool_dude->_id);
The follows
-Function would return the exact same thing since it's still the same user.
This allows you to easily drop in whatever you want and focus on more important stuff.
Kamui is using PHPUnit-Tests.
The best way to run them is to install it along with Composer.
When it's setup, run phpunit
on the root of the Project.
This Project is using the API from Twitch-Emotes to allow you an easier usage of them. Example use of them is:
$api->feed->reactToPost($user, $post, 'Kappa');
This Project is licensed under the MIT-License. Read the LICENSE-File inside this Project for more information.
Sidenote: The Projects name comes from 'Akkorokamui'. Google it up, too lazy to explain stuff