2017 © Pedro Peláez
 

library twitch-api-php

A Twitch API client for PHP.

image

laahudra/twitch-api-php

A Twitch API client for PHP.

  • Sunday, August 27, 2017
  • by LaaHudra
  • Repository
  • 1 Watchers
  • 0 Stars
  • 7 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 9 Forks
  • 0 Open issues
  • 10 Versions
  • 0 % Grown

The README.md

twitch-api-php

A Twitch API client for PHP., (*1)

Build Status, (*2)

Supported APIs

This library aims to support v3, v4 and v5 of the Twitch API until each one becomes deprecated. If an API version is not specified, v5 will be used as the default., (*3)

Features Completed

Main API Endpoints: - [x] Authentication - [x] Bits - [x] Channel Feed - [x] Channels - [x] Chat - [x] Clips - [x] Collections - [x] Communities - [x] Games - [x] Ingests - [x] Search - [x] Streams - [x] Teams - [x] Users - [x] Videos, (*4)

Any endpoints missing? Open an issue here., (*5)

Other Features: - [ ] IRC Client - [ ] Pub/Sub (ie. Bits & Whispers) - [ ] Video Upload, (*6)

Additional Integrations: - [ ] StreamsLabs: - [ ] Alerts - [ ] Authentication - [ ] Donations - [ ] Users, (*7)

Basic Example

$options = [
    'client_id' => 'YOUR-CLIENT-ID',
];

$twitchApi = new \TwitchApi\TwitchApi($options);
$user = $twitchApi->getUser(26490481);

// By default API responses are returned as an array, but if you want the raw JSON instead:
$twitchApi->setReturnJson(true);
$user = $twitchApi->getUser(26490481);

// If you want to switch between API versions on the fly:
$twitchApi->setApiVersion(3);
$user = $twitchApi->getUser('summit1g');

See the examples directory for more common use cases., (*8)

Requirements

PHP 5.6 or higher is required., (*9)

Installation

Either pull in the library via composer:, (*10)

$ composer require nicklaw5/twitch-api-php

or add the following dependency to your composer.json file and run composer install:, (*11)

"nicklaw5/twitch-api-php": "0.1.*"

Tests

All unit tests can be run with the following command:, (*12)

$ vendor/bin/phpunit # or simply "phpunit" if you have it installed globally

Documentation

The Twitch API docs can be found here., (*13)

As for the documentation of this library, that is still on the to-do list. In the meantime, most modern IDEs by default, or through the use of plugins, will provide class property and method auto-completion. Or you can simple look through the source code., (*14)

License

Distributed under the MIT license., (*15)

The Versions

27/08 2017

dev-master

9999999-dev http://github.com/laahudra/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

  • php >=5.6.0

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

27/08 2017

v0.1.7

0.1.7.0 http://github.com/laahudra/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

  • php >=5.6.0

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

27/08 2017

v0.1.6

0.1.6.0 http://github.com/laahudra/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

26/04 2017

v0.1.5

0.1.5.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

26/04 2017

dev-docs

dev-docs http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

02/04 2017

v0.1.4

0.1.4.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

02/04 2017

v0.1.3

0.1.3.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

31/03 2017

v0.1.2

0.1.2.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

22/02 2017

v0.1.1

0.1.1.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch twitch.tv twitch-tv twitch-api

21/02 2017

v0.1.0

0.1.0.0 http://github.com/nicklaw5/twitch-api-php

A Twitch API client for PHP.

  Sources   Download

MIT

The Requires

 

The Development Requires

api twitch