PHPackages                             dmt-software/oauth2-trustpilot - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. dmt-software/oauth2-trustpilot

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

dmt-software/oauth2-trustpilot
==============================

A Trustpilot Client Provider for The PHP League OAuth2-Client

v1.0.1(4y ago)019.6k↑33.3%MITPHP

Since Apr 12Pushed 4y ago1 watchersCompare

[ Source](https://github.com/dmt-software/oauth2-trustpilot)[ Packagist](https://packagist.org/packages/dmt-software/oauth2-trustpilot)[ RSS](/packages/dmt-software-oauth2-trustpilot/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (2)Versions (3)Used By (0)

Trustpilot Provider for OAuth 2.0 Client
========================================

[](#trustpilot-provider-for-oauth-20-client)

Install
-------

[](#install)

`composer require dmt-software/oauth2-trustpilot`

Usage
-----

[](#usage)

```
use DMT\OAuth2\Client\Provider\Trustpilot;
use League\OAuth2\Client\Provider\Exception\IdentityProviderException;

$provider = new Trustpilot([
    'clientId' => '{ your_client_id }',
    'clientSecret' => '{ your_client_secret }',
]);

try {
    $accessToken = $provider->getAccessToken(
        'password', [
            'username' => '{ your_username }',
            'password' => '{ your_password }'
        ]
    );
} catch (IdentityProviderException $exception) {
    if ($exception->getCode() === 401) {
        // token is expired
    }
    if ($exception->getCode() === 429) {
        // too many requests
    }
}
```

> see more examples on [league/oauth2-client](https://oauth2-client.thephpleague.com/usage/)

Error handling
--------------

[](#error-handling)

Unfortunately the response body in case of an error is not consistent. To better understand the reason a request is failed call the `IdentityProviderException::getResponseBody` method.

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

1497d ago

### Community

Maintainers

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

---

Top Contributors

[![proggeler](https://avatars.githubusercontent.com/u/18281353?v=4)](https://github.com/proggeler "proggeler (6 commits)")

---

Tags

clientoauthoauth2authorizationTrustpilot

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/dmt-software-oauth2-trustpilot/health.svg)

```
[![Health](https://phpackages.com/badges/dmt-software-oauth2-trustpilot/health.svg)](https://phpackages.com/packages/dmt-software-oauth2-trustpilot)
```

###  Alternatives

[league/oauth2-google

Google OAuth 2.0 Client Provider for The PHP League OAuth2-Client

42121.2M118](/packages/league-oauth2-google)[thenetworg/oauth2-azure

Azure Active Directory OAuth 2.0 Client Provider for The PHP League OAuth2-Client

2509.6M48](/packages/thenetworg-oauth2-azure)[stevenmaguire/oauth2-keycloak

Keycloak OAuth 2.0 Client Provider for The PHP League OAuth2-Client

2275.9M27](/packages/stevenmaguire-oauth2-keycloak)[patrickbussmann/oauth2-apple

Sign in with Apple OAuth 2.0 Client Provider for The PHP League OAuth2-Client

1132.5M6](/packages/patrickbussmann-oauth2-apple)[mollie/oauth2-mollie-php

Mollie Provider for OAuth 2.0 Client

251.7M1](/packages/mollie-oauth2-mollie-php)[omines/oauth2-gitlab

GitLab OAuth 2.0 Client Provider for The PHP League OAuth2-Client

36721.5k13](/packages/omines-oauth2-gitlab)

PHPackages © 2026

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