PHPackages                             argezeit/apigility-client - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [HTTP &amp; Networking](/categories/http)
4. /
5. argezeit/apigility-client

ActiveLibrary[HTTP &amp; Networking](/categories/http)

argezeit/apigility-client
=========================

Client for REST and RPC webservices

0.1.4(10y ago)031MITPHPPHP &gt;=5.5

Since Mar 4Pushed 9y ago1 watchersCompare

[ Source](https://github.com/argezeit/apigility-client)[ Packagist](https://packagist.org/packages/argezeit/apigility-client)[ Docs](https://github.com/jolicht/apigility-client)[ RSS](/packages/argezeit-apigility-client/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (4)Versions (6)Used By (0)

Client for Apigility REST and RPC webservices
=============================================

[](#client-for-apigility-rest-and-rpc-webservices)

Installation
------------

[](#installation)

`composer require jolicht/apigility-client`

Configuration for Zend Framework 2
----------------------------------

[](#configuration-for-zend-framework-2)

### Register Abstract Service Factory

[](#register-abstract-service-factory)

Register `Jolicht\\ApigilityClient\\ClientAbstractServiceFactory` as abstract service in service manager:

```
'service_manager' => [
    'abstract_factories' => [
        'Jolicht\\ApigilityClient\\ClientAbstractServiceFactory'
    ]
],

```

### Configure Apigility Http Client

[](#configure-apigility-http-client)

Add config key `apigility_http_client` to your prefered config file. (Applicaction Level e.g.: 'config/autoload/global.php; Module level e.g.: config/module.config.php

```
'apigility_http_client' => [
    'NameOfFirstClient' => [
        'base_uri' => 'http://your-apigility-service-uri.dev',
            'default_headers' => [
                'Accept' => 'application/json',
                'Content-Type' => 'application/json'
            ],
            'http_client_options' => [
                'timeout' => 42
            ],
            'throw_exceptions' => false,
        ]
    ],
    'NameOfSecondClient' => [
        'base_uri' => 'http://your-second-apigility-service-uri.dev',
            'default_headers' => [
                'Accept' => 'application/json',
                'Content-Type' => 'application/json'
            ],
            'http_client_options' => [
                'timeout' => 10
            ],
        ]
    ],
],

```

Always set `default_headers` `Accept` and `Content-Type` to prevent content type errors. If `throw_exceptions` is `true` exception is thrown on invalid response status code.

Usage
-----

[](#usage)

### Get Apigility http client instance

[](#get-apigility-http-client-instance)

Call `ServiceManager::get` or `ServiceLocator::get` with configured Service Name as param:

```
$firstClient = $serviceManager->get('NameOfFirstClient');
$secondClient = $serviceManager->get('NameOfSecondClient');

```

### Operations

[](#operations)

Create:

```
$response = $client->create('/api-route', $data);

```

Fetch:

```
$response = $client->fetch('/api-route', 17);

```

FetchAll:

```
$response =  $client->fetchAll('/api-route'); // without query data
$response =  $client->fetchAll('/api-route', $queryData); // with query data

```

Patch:

```
$response = $client->patch('/api-route', 17, $data);

```

Update:

```
$response = $client->update('/api-route', 17, $data);

```

Call any Http Method:

```
$response = $client->call('/api-route'); // HTTP GET
$response = $client->call('/api-route/3'); // HTTP GET
$response = $client->call('/api-route', 'GET', $data); // HTTP GET with query parameters
$response = $client->call('/api-route', 'POST', $data); // HTTP POST with content data

```

Not yet implemented:

- delete
- deleteList
- replaceList

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 90% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~22 days

Total

5

Last Release

3677d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/15995736?v=4)[argezeit](/maintainers/argezeit)[@argezeit](https://github.com/argezeit)

---

Top Contributors

[![jolicht](https://avatars.githubusercontent.com/u/14368638?v=4)](https://github.com/jolicht "jolicht (9 commits)")[![argezeit](https://avatars.githubusercontent.com/u/15995736?v=4)](https://github.com/argezeit "argezeit (1 commits)")

---

Tags

restzf2apigility

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/argezeit-apigility-client/health.svg)

```
[![Health](https://phpackages.com/badges/argezeit-apigility-client/health.svg)](https://phpackages.com/packages/argezeit-apigility-client)
```

###  Alternatives

[zfr/zfr-cors

Zend Framework module that let you deal with CORS requests

601.3M3](/packages/zfr-zfr-cors)[zfr/zfr-rest

Zend Framework 2 REST Module.

8120.7k](/packages/zfr-zfr-rest)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
