PHPackages                             thearyanahmed/ppp - 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. [API Development](/categories/api)
4. /
5. thearyanahmed/ppp

ActiveLibrary[API Development](/categories/api)

thearyanahmed/ppp
=================

Integrate the Purchasing Power Parity API into your online products and services, enabling you to offer affordable pricing globally.

v0.1(2y ago)06MITPHPPHP ^7.4|^8.0

Since Aug 22Pushed 2y ago1 watchersCompare

[ Source](https://github.com/thearyanahmed/ppp)[ Packagist](https://packagist.org/packages/thearyanahmed/ppp)[ Docs](https://github.com/thearyanahmed/ppp)[ RSS](/packages/thearyanahmed-ppp/feed)WikiDiscussions master Synced yesterday

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

Purchase Power Parity
=====================

[](#purchase-power-parity)

[![Latest Version on Packagist](https://camo.githubusercontent.com/a9cf51577df3f223b6165e46958eeb7247714a40090c77a8c78fb54df61810b5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f746865617279616e61686d65642f7070702e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/thearyanahmed/ppp)

Implementation of [https://purchasing-power-parity.com](https://purchasing-power-parity.com/) using PHP.

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

[](#installation)

You can install the package via composer:

```
composer require thearyanahmed/ppp
```

Usage
-----

[](#usage)

```
use Thearyanahmed\Ppp\Request;
$response = (new Request)->fetchPPP('DE');
```

The response can be either `SuccessfulResponse` or `ErrorResponse`. The `SuccessResponse` contains the fields with getter methods. Eg: `pppConversionFactor` can be accessed via `getPppConversionFactor()`.

Available methods

```
# SuccessResponse
    public function getCountryCodeAlpha2() : string
    public function getCountryCodeAlpha3() : string
    public function getMainCurrencyName() : string
    public function getMainCurrencySymbol() : string
    public function getPppConversionFactor() : float
    public function getPPP() : float
    public function isSuccessful() : bool # will always return true

# ErrorResponse
    public function getMessage() : string
    public function isSuccessful() : bool # will always return false
```

If it's not a HTTP 200 request,\*\*\*\* it'll throw an generic exception.

Usage
-----

[](#usage-1)

```
   $response = (new Request)->fetchPPP('DE');

   if($response->isSuccessful()) {
        $discountPrice = $response->getPppConversionFactor() * $originalPrice;
   }
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Aryan Ahmed](https://github.com/thearyanahmed)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

PHP Package Boilerplate
-----------------------

[](#php-package-boilerplate)

This package was generated using the [PHP Package Boilerplate](https://laravelpackageboilerplate.com) by [Beyond Code](http://beyondco.de/).

###  Health Score

19

—

LowBetter than 9% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 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

Unknown

Total

1

Last Release

1046d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/20617352?v=4)[Aryan Ahmed](/maintainers/thearyanahmed)[@thearyanahmed](https://github.com/thearyanahmed)

---

Top Contributors

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

---

Tags

pppthearyanahmed

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/thearyanahmed-ppp/health.svg)

```
[![Health](https://phpackages.com/badges/thearyanahmed-ppp/health.svg)](https://phpackages.com/packages/thearyanahmed-ppp)
```

###  Alternatives

[statamic/cms

The Statamic CMS Core Package

4.8k3.6M985](/packages/statamic-cms)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k38](/packages/neuron-core-neuron-ai)[avalara/avataxclient

Client library for Avalara's AvaTax suite of business tax calculation and processing services. Uses the REST v2 API.

528.5M7](/packages/avalara-avataxclient)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

273.0k](/packages/eslazarev-wildberries-sdk)[files.com/files-php-sdk

Files.com PHP SDK

2481.1k](/packages/filescom-files-php-sdk)

PHPackages © 2026

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