This is a PHP client library for Talis Echo, allowing you to submit events.
Install the module via composer, by adding the following to your projects composer.json
{
"repositories":[
{
"type": "vcs",
"url": "https://github.com/talis/echo-php-client"
},
],
"require" :{
"talis/echo-php-client": "~0.2"
}
}
then update composer:
$ php composer.phar update
In your code, do the following to create events:
$echoClient = new \echoClient\EchoClient(); // see constructor for mandatory constants
$echoClient->createEvent(
"event.class",
"event.source",
array('some'=>'props')
);
A Dockerfile is provided to make it easy to get a local development environment up and running to develop and test changes. Follow these steps:
# Build the development image
git clone https://github.com/talis/echo-php-client.git
cd echo-php-client
docker build -t "echo-php-client:dev" --build-arg git_oauth_token=<yout github oauth token> .
# When the above has built successfully you can run and connect to the container
docker run -v /path/on/host/machine/to/echo-php-client:/var/echo-php-client -i -t echo-php-client:dev /bin/bash
# Then inside the container
ant init
ant test