gfke / urm-helper
utility to work with gfke urm.
0.1.1
2017-02-03 15:13 UTC
Requires
- php: >=5.6
- guzzlehttp/guzzle: ^6.2
- guzzlehttp/promises: ^1.3
- wisembly/elephant.io: ~3.0
Requires (Dev)
- phpunit/phpunit: ^5.1
- satooshi/php-coveralls: ^1.0
This package is not auto-updated.
Last update: 2024-04-22 13:25:30 UTC
README
utility to work with gfke urm
Installation
$ composer require gfke/urm-helper
Usage
URM Rest Endpoints
$urm = new URM(URM_URL); $res = $urm->query('event', [ 'key' => 'value' ]); var_dump($res['data']);
URM Socket Endpoints
$urmSocket = new URMSocket( URM_SOCKET_URL, URM_SOCKET_BASE_EVENT ); $res = $urmSocket->emit('event1', [ 'key' => 'value' ]); var_dump($res['data']); $res = $urmSocket->emit('event2', [ 'key' => 'value' ]); var_dump($res['data']); $urmSocket->disconnect();
Testing
$ ./vendor/bin/phpunit tests/ --colors