PHPackages                             canaltp/tyr-component - 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. canaltp/tyr-component

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

canaltp/tyr-component
=====================

PHP library which makes curl calls to Tyr API.

1.3.2(9y ago)15.0k51GPL-3.0PHPPHP &gt;=5.2CI passing

Since Jul 28Pushed 5y ago29 watchersCompare

[ Source](https://github.com/CanalTP/TyrComponent)[ Packagist](https://packagist.org/packages/canaltp/tyr-component)[ Docs](https://github.com/CanalTP/TyrComponent)[ RSS](/packages/canaltp-tyr-component/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (2)Versions (20)Used By (1)

Tyr Component
=============

[](#tyr-component)

PHP library which makes curl calls to Tyr API.

Supports Guzzle3 and Guzzle5 since version `1.2`.

Composer
--------

[](#composer)

Install via composer

```
{
    "require": {
        "canaltp/tyr-component": "~1.2"
    }
}
```

Usage
-----

[](#usage)

Instanciate TyrService as a plain PHP object:

```
$tyrUrl = 'http://tyr.dev.canaltp.fr/v0/';
$endPointId = 2;

// Instanciating api
$tyrApi = new CanalTP\TyrComponent\TyrService($tyrUrl, $endPointId); // For Guzzle5
$tyrApi = new CanalTP\TyrComponent\Guzzle3\TyrService($tyrUrl, $endPointId); // For Guzzle3

// Creating request
$user = $tyrApi->createUser('email', 'login');

// Get last Guzzle response instance (usefull to get status code...)
$response = $tyrApi->getLastResponse();
$statusCode = $response->getStatusCode();
```

See [full Tyr class](src/TyrService.php).

### Testing

[](#testing)

Mock Guzzle client:

```
$tyrUrl = 'http://tyr.dev.canaltp.fr/v0/';
$endPointId = 2;

$tyrApi = new CanalTP\TyrComponent\TyrService($tyrUrl, $endPointId); // For Guzzle5
$tyrApi = new CanalTP\TyrComponent\Guzzle3\TyrService($tyrUrl, $endPointId); // For Guzzle3

// Creating GuzzleHttp\Client mock...

$tyrApi->setClient($mockedClient);
```

License
-------

[](#license)

This project is under [GPL-3.0 License](LICENSE).

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community25

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 55% 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 ~31 days

Recently: every ~90 days

Total

19

Last Release

3365d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7a2e84adf3e1bbfcc1c525e8875141708cf5f34a58676c5389c951016a632fb3?d=identicon)[packagistctp](/maintainers/packagistctp)

![](https://www.gravatar.com/avatar/dda7e458a209d5394bcf3015ddc298b49dd8cae89304ac89b3ec0f0ead48b1d6?d=identicon)[packagist-kisio-bot](/maintainers/packagist-kisio-bot)

![](https://www.gravatar.com/avatar/a5e67e1f06fb3d5106ecddbcd94b1f8b3d6f0554e519f0687c42bac60a318e22?d=identicon)[remy](/maintainers/remy)

---

Top Contributors

[![alcalyn](https://avatars.githubusercontent.com/u/1588144?v=4)](https://github.com/alcalyn "alcalyn (44 commits)")[![lrocheWB](https://avatars.githubusercontent.com/u/10560073?v=4)](https://github.com/lrocheWB "lrocheWB (18 commits)")[![Netmisa](https://avatars.githubusercontent.com/u/1167753?v=4)](https://github.com/Netmisa "Netmisa (11 commits)")[![is06](https://avatars.githubusercontent.com/u/631559?v=4)](https://github.com/is06 "is06 (5 commits)")[![rchoquet](https://avatars.githubusercontent.com/u/2551773?v=4)](https://github.com/rchoquet "rchoquet (1 commits)")[![vchabot](https://avatars.githubusercontent.com/u/715331?v=4)](https://github.com/vchabot "vchabot (1 commits)")

---

Tags

phptyr

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/canaltp-tyr-component/health.svg)

```
[![Health](https://phpackages.com/badges/canaltp-tyr-component/health.svg)](https://phpackages.com/packages/canaltp-tyr-component)
```

###  Alternatives

[hannesvdvreken/guzzle-debugbar

A Guzzle middleware that logs requests to debugbar's timeline

76410.4k1](/packages/hannesvdvreken-guzzle-debugbar)

PHPackages © 2026

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