PHP library retrieving publish (SSE) events

Hi there,

I’ve made a PHP library for catching the ‘spark.publish’ events sent from your sparkcore. With this you’ll be able to store those in a database or simply have more use with them from within PHP.

If you’re familiar with Composer you can install it via
https://packagist.org/packages/evertharmeling/sparkcore

Or else just download the code from GitHub

Hopefully it’s useful for others too. It’s the first version, so feel free to contribute, create issues or ask questions!

Evert

5 Likes

Awesome, Thanks for sharing! :slight_smile:

1 Like

@evertharmeling thanks a lot for building this…I am going to use it in a PHP API which we are going to serve customers on.

Do you have a sample code which denotes the best practices that describe in code the Collection and Processing aspects? In our scenario the client would be the PHP API itself which will listen to events from the spark and then push the received response to the client.