obsh / sse-client
Server Sent Event client implementation
0.1.3
2015-10-29 14:56 UTC
Requires
- php: >=5.5.0
- guzzlehttp/guzzle: ^6.1@dev
Requires (Dev)
- phpunit/phpunit: ~4
This package is auto-updated.
Last update: 2026-03-19 12:35:56 UTC
README
#PHP SSE Client
(ported from Python SSE client: https://bitbucket.org/btubbs/sseclient/)
This is a PHP client library for iterating over http Server Sent Event (SSE) streams (also known as EventSource, after the name of the Javascript interface inside browsers).
Example usage:
$client = new SseClient\Client('https://eventsource.firebaseio-demo.com/.json'); // returns generator $events = $client->getEvents(); // blocks until new event arrive foreach ($events as $event) { print_r($event); }