https://github.com/adamhebby/glimeshclient
PHP Client for [Glimesh](https://glimesh.tv/)
https://github.com/adamhebby/glimeshclient
client-library glimesh oauth2-client php php7
Last synced: 5 months ago
JSON representation
PHP Client for [Glimesh](https://glimesh.tv/)
- Host: GitHub
- URL: https://github.com/adamhebby/glimeshclient
- Owner: AdamHebby
- License: gpl-3.0
- Archived: true
- Created: 2021-04-16T23:43:40.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2023-08-19T20:48:18.000Z (almost 2 years ago)
- Last Synced: 2024-12-01T05:49:45.094Z (6 months ago)
- Topics: client-library, glimesh, oauth2-client, php, php7
- Language: PHP
- Homepage:
- Size: 168 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ARCHIVED - glimesh.tv has shut down
# PHP GlimeshClient
This Library aims to provide a fully working Glimesh Client, all objects and interfaces used by the API are auto-generated by the API specification.
## Installation
`composer require adamhebby/glimeshclient`
## Usage
```php
load(__DIR__ . '/../.env');$logger = new \Monolog\Logger("log");
$logger->pushHandler(new \Monolog\Handler\ErrorLogHandler());$guzzle = new GuzzleHttpClient(['http_errors' => true, 'allow_redirects' => true]);
$client = new Client(
$guzzle,
new OAuthFileAdapter(
$_ENV['CLIENT_ID'],
$_ENV['CLIENT_SECRET'],
'/tmp/auth.json'
),
$logger
);$object = $client->makeRequest(
(new Query('channels'))->setSelectionSet([
'id',
(new Query('stream'))->setSelectionSet([
'thumbnail',
]),
])->setArguments(['status' => 'ENUM:' . ChannelStatus::LIVE])
);var_dump($object);
```