PHPackages                             loki1729/laravel-thepeer - 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. loki1729/laravel-thepeer

ActiveLibrary

loki1729/laravel-thepeer
========================

Laravel Package for easy integration of ThePeer APIs.

316PHP

Since Aug 6Pushed 3y ago1 watchersCompare

[ Source](https://github.com/Lowkey1729/laravel-thepeer)[ Packagist](https://packagist.org/packages/loki1729/laravel-thepeer)[ RSS](/packages/loki1729-laravel-thepeer/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel ThePeer
===============

[](#laravel-thepeer)

- [Documentation](#introduction)
- [Usage](#usage)
- [Support](#support)

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

[](#installation)

```
composer require loki1729/laravel-thepeer
```

Usage
-----

[](#usage)

Following are some ways through which you can access the ThePeer provider:

```
// Import the class namespaces first, before using it directly
use \Loki1729\LaravelThePeer\Services\ThePeer as ThePeerClient;

$the_peer_service = new ThePeerClient;
```

Publish Config Folder
---------------------

[](#publish-config-folder)

```
 php artisan vendor:publish --provider "Loki1729\LaravelThePeer\ServiceProviders\ThePeerServiceProvider"
```

Configuration File
------------------

[](#configuration-file)

The configuration file **loki\_the\_peer.php** is located in the **config** folder. Following are its contents when published:

```
return [
    'mode' => env('THE_PEER_MODE', 'sandbox'), // Can only be 'sandbox' Or 'live'. If empty or invalid, 'live' will be used.
    'sandbox' => [
        'public_key' => env('THE_PEER_TEST_PUBLIC_KEY', ''),
        'secret_key' => env('THE_PEER_TEST_SECRET_KEY', ''),
    ],
    'live' => [
        'public_key' => env('THE_PEER_LIVE_PUBLIC_KEY', ''),
        'secret_key' => env('THE_PEER_LIVE_SECRET_KEY', ''),
    ],

];
```

Configuration Options
=====================

[](#configuration-options)

You can either use the env to set your keys or use your keys as shown in the example below:

```
     $the_peer_service = new ThePeerClient($mode, $secret_key);

    For local testing, the "mode" is set to "sandbox";

    $the_peer_service = new ThePeerClient('sandbox', 'secret-key');

    For Live testing, the "mode" is set to "live";

    $the_peer_service = new ThePeerClient('live', 'secret-key');
```

Index User
==========

[](#index-user)

```
  $the_peer_service->indexUser(string $name, string $email, string $identifier);
```

All Users
---------

[](#all-users)

```
$the_peer_service->allUsers(int $page = null, int $perPage = null);
```

Update User
-----------

[](#update-user)

```
$the_peer_service->updateUser(string $userReference, string $identifier);
```

Delete User
-----------

[](#delete-user)

```
$the_peer_service->deleteUSer(string $userReference);
```

Get User Link
-------------

[](#get-user-link)

```
$the_peer_service->getUserLink(string $userReference);
```

Get Transaction
---------------

[](#get-transaction)

```
$the_peer_service->getTransaction(string $transactionId);
```

Refund Transaction
------------------

[](#refund-transaction)

```
$the_peer_service->refundTransaction(string $transactionId, string $reason);
```

Get Link
--------

[](#get-link)

```
$the_peer_service->getLink(string $linkId);
```

Charge Link
-----------

[](#charge-link)

```
$the_peer_service->chargeLink(string $linkId, float $amount, string $remark);
```

Test Credit
-----------

[](#test-credit)

```
$the_peer_service->testCredit(float $amount, string $currency, string $user_reference);
```

Test Charge
-----------

[](#test-charge)

```
$the_peer_service->testCharge(float $amount, string $from, string $to, string $currency, string $remark, string $channel);
```

###  Health Score

16

—

LowBetter than 5% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity25

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/5ea5743e2319887e9d2414cb64e8e7f66e67151de7ee1c641327f7144c32bb4c?d=identicon)[Lowkey1729](/maintainers/Lowkey1729)

---

Top Contributors

[![Lowkey1729](https://avatars.githubusercontent.com/u/53194190?v=4)](https://github.com/Lowkey1729 "Lowkey1729 (23 commits)")

### Embed Badge

![Health badge](/badges/loki1729-laravel-thepeer/health.svg)

```
[![Health](https://phpackages.com/badges/loki1729-laravel-thepeer/health.svg)](https://phpackages.com/packages/loki1729-laravel-thepeer)
```

PHPackages © 2026

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