PHPackages                             cviebrock/laravel-mangopay - 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. [Payment Processing](/categories/payments)
4. /
5. cviebrock/laravel-mangopay

ActiveLibrary[Payment Processing](/categories/payments)

cviebrock/laravel-mangopay
==========================

Laravel/Lumen wrapper for the office Mangopay SDK library

9.0.0(3y ago)1971.8k↑13.2%8MITPHPPHP ^7.3|^8.0

Since Apr 14Pushed 3y ago2 watchersCompare

[ Source](https://github.com/cviebrock/laravel-mangopay)[ Packagist](https://packagist.org/packages/cviebrock/laravel-mangopay)[ RSS](/packages/cviebrock-laravel-mangopay/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (5)Versions (12)Used By (0)

Laravel-Mangopay Integration
============================

[](#laravel-mangopay-integration)

This package makes it easier (hopefully!) to integrate the official [Mangopay SDK](https://github.com/Mangopay/mangopay2-php-sdk) into your Laravel and Lumen applications.

> ## ⚠️ This Package Will Be Abandoned
>
> [](#️-this-package-will-be-abandoned)
>
> Due to several factors, including the fact that I no longer use Mangopay, I will be ceasing development on this package. If you are interested in taking over this project, please reach out to me here in the Issues board.

[![Build Status](https://camo.githubusercontent.com/3df05220c6935bbb00af820f8e1ed3941097b6a17ff70f154a0c70ae353e9031/68747470733a2f2f7472617669732d63692e6f72672f6376696562726f636b2f6c61726176656c2d6d616e676f7061792e7376673f6272616e63683d6d617374657226666f726d61743d666c6174)](https://travis-ci.org/cviebrock/laravel-mangopay)[![Total Downloads](https://camo.githubusercontent.com/bb168d213ccc6598c826be99a604f1a1c912f34cb06a660fa25d8b038f2c0518/68747470733a2f2f706f7365722e707567782e6f72672f6376696562726f636b2f6c61726176656c2d6d616e676f7061792f646f776e6c6f6164733f666f726d61743d666c6174)](https://packagist.org/packages/cviebrock/laravel-mangopay)[![Latest Stable Version](https://camo.githubusercontent.com/7af19b9f8703aba3134c0299e95d90c58aaddebb4457656993c4df27f1812b48/68747470733a2f2f706f7365722e707567782e6f72672f6376696562726f636b2f6c61726176656c2d6d616e676f7061792f762f737461626c653f666f726d61743d666c6174)](https://packagist.org/packages/cviebrock/laravel-mangopay)[![Latest Unstable Version](https://camo.githubusercontent.com/55b3692512af4641e4d71e0cd9edc4741210c1ab4b1f4d5447f9777a0e44cded/68747470733a2f2f706f7365722e707567782e6f72672f6376696562726f636b2f6c61726176656c2d6d616e676f7061792f762f756e737461626c653f666f726d61743d666c6174)](https://packagist.org/packages/cviebrock/laravel-mangopay)[![License](https://camo.githubusercontent.com/efbddd37dce3b02ad295e9055341709f9234443b570cd83dcaa37538c0edeb17/68747470733a2f2f706f7365722e707567782e6f72672f6376696562726f636b2f6c61726176656c2d6d616e676f7061792f6c6963656e73653f666f726d61743d666c6174)](https://packagist.org/packages/cviebrock/laravel-mangopay)

- [Installation](#installation)
    - [Laravel](#laravel)
    - [Lumen](#lumen)
- [Configuration](#configuration)
- [Usage](#usage)
- [Bugs, Suggestions and Contributions](#bugs-suggestions-and-contributions)
- [Copyright and License](#copyright-and-license)

---

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

[](#installation)

Depending on your version of Laravel, you should install a different version of the package. NOTE: As of version 6.0, the package's version should match the Laravel version.

Laravel VersionPackage Version9.0^9.08.0^8.07.0^7.06.0^6.05.\*^0.9### Laravel

[](#laravel)

1. Install the package via composer:

    ```
    composer require cviebrock/laravel-mangopay
    ```

    After updating composer, the package will automatically register its service provider.
2. Publish the configuration file:

    ```
    php artisan vendor:publish --provider="Cviebrock\LaravelMangopay\ServiceProvider"
    ```
3. Finally, generate the required temporary directories:

    ```
    php artisan mangopay:mkdir
    ```

### Lumen

[](#lumen)

1. Install the package via composer:

    ```
    composer require cviebrock/laravel-mangopay:^6.0
    ```
2. Copy the configuration file to your `config` folder and enable everything in `bootstrap/app.php`:

    ```
    $app->configure('mangopay');

    $app->register(Cviebrock\LaravelMangopay\ServiceProvider::class);
    ```
3. Generate the required temporary directories:

    ```
    php artisan mangopay:mkdir
    ```

Configuration
-------------

[](#configuration)

This package supports authentication configuration through the services configuration file located in `config/services.php`. Add the following block to that file, and set the appropriate values in your `.env` file:

```
'mangopay' => [
    'env'    => env('MANGOPAY_ENV', 'sandbox'),  // or "production"
    'key'    => env('MANGOPAY_KEY'),             // your Mangopay client ID
    'secret' => env('MANGOPAY_SECRET'),          // your Mangopay client password
],
```

The configuration file you can publish to `config/mangopay.php` provides additional properties that can be passed to the MangopayAPI object when it is instantiated. In most cases, you won't need to change anything here, so you can choose to not publish this configuration, or have it simply return an empty array.

If you do use this file, see the SDK documentation for the various properties that can be set (basically any public property on the `MangoPay\Libraries\Configuration` class).

Usage
-----

[](#usage)

All this package really does is make instantiating the `MangopayAPI` easy by putting the configuration into Laravel/Lumen's config system.

Using it is now as easy as injecting Mangopay into your controller, and then using it the same way you would use the `MangopayAPI` class:

```
class MyController extends Illuminate\Routing\Controller
{

    /**
     * @var \MangoPay\MangoPayApi
     */
    private $mangopay;

    public function __construct(\MangoPay\MangoPayApi $mangopay) {
        $this->mangopay = $mangopay;
    }

    public function doStuff($someId)
    {
        // get some user by id
        $john = $this->mangopay->Users->Get($someId);

        // change and update some of his data
        $john->LastName .= " - CHANGED";
        $this->mangopay->Users->Update($john);

        // get his bank accounts
        $pagination = new MangoPay\Pagination(1, 10); // get 1st page, 10 items per page
        $accounts = $this->mangopay->Users->GetBankAccounts($john->Id, $pagination);

        // etc.
    }
}
```

Bugs, Suggestions and Contributions
-----------------------------------

[](#bugs-suggestions-and-contributions)

Thanks to [everyone](/cviebrock/laravel-mangopay/graphs/contributors) who has contributed to this project! Special thanks to [JetBrains](https://www.jetbrains.com/?from=cviebrock/laravel-mangopay) for their Open Source License Program ... and the excellent PHPStorm IDE, of course!

[![JetBrains](./.github/jetbrains.svg)](https://www.jetbrains.com/?from=cviebrock/laravel-mangopay)

Please use [Github](https://github.com/cviebrock/laravel-mangopay) for reporting bugs, and making comments or suggestions.

See [CONTRIBUTING.md](CONTRIBUTING.md) for how to contribute changes.

Copyright and License
---------------------

[](#copyright-and-license)

laravel-mangopay was written by Colin Viebrock and released under the MIT License. See [LICENSE.md](LICENSE.md) file for details.

Copyright (c) 2016 Colin Viebrock

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity40

Moderate usage in the ecosystem

Community17

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~230 days

Recently: every ~262 days

Total

11

Last Release

1382d ago

Major Versions

0.9.5 → 6.0.02019-09-21

6.0.0 → 7.0.02020-07-02

7.0.0 → 8.0.02020-09-30

8.0.1 → 9.0.02022-08-05

PHP version history (4 changes)0.9.0PHP &gt;=5.6.0

6.0.0PHP ^7.2

8.0.0PHP ^7.3

8.0.1PHP ^7.3|^8.0

### Community

Maintainers

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

---

Top Contributors

[![cviebrock](https://avatars.githubusercontent.com/u/166810?v=4)](https://github.com/cviebrock "cviebrock (6 commits)")[![AlexisReverte](https://avatars.githubusercontent.com/u/6009041?v=4)](https://github.com/AlexisReverte "AlexisReverte (4 commits)")[![brayniverse](https://avatars.githubusercontent.com/u/945367?v=4)](https://github.com/brayniverse "brayniverse (4 commits)")[![gpanos](https://avatars.githubusercontent.com/u/12728267?v=4)](https://github.com/gpanos "gpanos (1 commits)")[![sempixel](https://avatars.githubusercontent.com/u/1658628?v=4)](https://github.com/sempixel "sempixel (1 commits)")

---

Tags

laravellumenpaymentsmangopay

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/cviebrock-laravel-mangopay/health.svg)

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

###  Alternatives

[mollie/laravel-mollie

Mollie API client wrapper for Laravel &amp; Mollie Connect provider for Laravel Socialite

3624.1M28](/packages/mollie-laravel-mollie)[musahmusah/laravel-multipayment-gateways

A Laravel Package that makes implementation of multiple payment Gateways endpoints and webhooks seamless

852.2k1](/packages/musahmusah-laravel-multipayment-gateways)[a17mad/laravel-cybersource

This package wraps the Cybersource SOAP API in a convenient, easy to use package for Laravel.

136.8k](/packages/a17mad-laravel-cybersource)[itsmurumba/laravel-mpesa

Laravel Package for Mpesa Daraja API

191.6k](/packages/itsmurumba-laravel-mpesa)[threesquared/laravel-paymill

Laravel wrapper for the Paymill API

121.3k](/packages/threesquared-laravel-paymill)

PHPackages © 2026

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