2017 © Pedro Peláez
 

library api-client

Client side API helpers

image

fei/api-client

Client side API helpers

  • Thursday, March 15, 2018
  • by rwellens
  • Repository
  • 7 Watchers
  • 0 Stars
  • 274 Installations
  • PHP
  • 7 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 26 Versions
  • 29 % Grown

The README.md

Api Client

GitHub licensecontinuousphpGitHub issues, (*1)

Low level API client., (*2)

All API client should use this library and extend \Fei\ApiClient\AbstractApiClient abstract class., (*3)

Installation

Use Composer: composer.phar require fei/mailer-client, (*4)

Or add this requirement "fei/api-client": "^1.1.0" to your composer.json file., (*5)

Use the BeanstalkProxyWorker

The BeanstalkProxyWorker is used for consume Beanstalkd messages queue and send them to the targeted api server., (*6)

<?php

require __DIR__ . '/vendor/autoload.php';

use Fei\ApiClient\Transport\BasicTransport;
use Fei\ApiClient\Worker\BeanstalkProxyWorker;
use Pheanstalk\Pheanstalk;
use Pheanstalk\PheanstalkInterface;

$host = "127.0.0.1";
$port = PheanstalkInterface::DEFAULT_PORT;

$worker = new BeanstalkProxyWorker();
$worker->setPheanstalk(new Pheanstalk($host, $port));
$worker->setTransport(new BasicTransport());

$worker->run(BeanstalkProxyWorker::VERBOSE);

This example will consume one message from Beanstakld tube (or queue) and send it to the api server., (*7)

For handle more messages you should create a infinite loop !, (*8)

<?php

require __DIR__ . '/vendor/autoload.php';

use Fei\ApiClient\Transport\BasicTransport;
use Fei\ApiClient\Worker\BeanstalkProxyWorker;
use Pheanstalk\Pheanstalk;
use Pheanstalk\PheanstalkInterface;

$host = "127.0.0.1";
$port = PheanstalkInterface::DEFAULT_PORT;

$worker = new BeanstalkProxyWorker();
$worker->setPheanstalk(new Pheanstalk($host, $port));
$worker->setTransport(new BasicTransport());

while (true) {
    $worker->run(BeanstalkProxyWorker::VERBOSE);
}

For a reliable worker, please use script/api-client-worker.php:, (*9)

api-client-worker.php -h 127.0.0.1 -p 11300 -d 5

The Versions

12/01 2018

v1.2.4

1.2.4.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

10/01 2018

v1.2.3

1.2.3.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

27/11 2017

v1.2.1.x-dev

1.2.1.9999999-dev

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

27/11 2017

v1.2.2

1.2.2.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

31/10 2017

v1.2.1

1.2.1.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

27/10 2017

dev-hotfix/improve_log_upon_filer_upload_failure

dev-hotfix/improve_log_upon_filer_upload_failure

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

27/10 2017

v1.1.9

1.1.9.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

25/10 2017

v1.2.0

1.2.0.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

23/12 2016

v1.1.8

1.1.8.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

23/12 2016

v1.1.7

1.1.7.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

22/12 2016

v1.1.6

1.1.6.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

22/12 2016

v1.1.5

1.1.5.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

21/12 2016

v1.1.4

1.1.4.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

12/09 2016

v1.1.3

1.1.3.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

28/07 2016

v1.1.2

1.1.2.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

27/07 2016

v1.1.1

1.1.1.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

25/07 2016

v1.1.0

1.1.0.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

15/07 2016

v1.0.5

1.0.5.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

15/07 2016

v1.0.4

1.0.4.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

13/07 2016

v1.0.3

1.0.3.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

08/07 2016

v1.0.2

1.0.2.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

07/07 2016

v1.0.1

1.0.1.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires

06/07 2016

v1.0.0

1.0.0.0

FEI client side API helpers

  Sources   Download

proprietary

The Requires

 

The Development Requires