PHPackages                             moneymour/api-client-php - 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. moneymour/api-client-php

ActiveLibrary[Payment Processing](/categories/payments)

moneymour/api-client-php
========================

The library offers easy access to Moneymour APIs

1.5.0(7y ago)029[1 PRs](https://github.com/moneymour/api-client-php/pulls)Apache-2.0PHPCI passing

Since Feb 15Pushed 3w ago2 watchersCompare

[ Source](https://github.com/moneymour/api-client-php)[ Packagist](https://packagist.org/packages/moneymour/api-client-php)[ Docs](https://github.com/moneymour/api-client-php)[ RSS](/packages/moneymour-api-client-php/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (1)Versions (13)Used By (0)

api-client-php
==============

[](#api-client-php)

The library offers easy access to Moneymour APIs

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

[](#installation)

A composer package is available on Packagist

```
$ composer install moneymour/api-client-php
```

Usage
-----

[](#usage)

```
use Moneymour\ApiClient as MoneymourApiClient;

class ApiClient {

  // Get the following information from https://merchant.sandbox.moneymour.com
  // For production: https://merchant.moneymour.com
  const PRIVATE_KEY = '';
  const MERCHANT_ID = '';
  const MERCHANT_SECRET = '';

  // Build the client
  $signatureFactory = new SignatureFactory(self::PRIVATE_KEY);
  $client = new MoneymourApiClient(
    self::MERCHANT_ID,
    self::MERCHANT_SECRET,
    $signatureFactory,
    MoneymourApiClient::ENVIRONMENT_SANDBOX  // or ENVIRONMENT_PRODUCTION when you get ready
  );

  // Request payload
  $payload = [
    'orderId' => '123456', // the order id in your system
    'amount' => '1080', // must be >= 300 and  'customer@merchant.com',
    'phoneNumber' => '+393334444555', // must include +39
    'products' => [ // the list of products in the cart
      [
        'name' => 'iPhone 7',
        'type' => 'Electronics',
        'price' => '500',
        'quantity' => 2,
        'discount' => 0
      ],
      [
        'name' => 'MacBook Pro Charger',
        'type' => 'Electronics',
        'price' => '80',
        'quantity' => 1,
        'discount' => 0
      ]
    ]
  ];

  // Perform the request
  $response = $client->request($payload);

  // Output example in JSON format
  print json_encode($res, JSON_PRETTY_PRINT|JSON_UNESCAPED_UNICODE) . "\n";

  /*
  {
    "status": "accepted",
    "amount": 1080,
    "phoneNumber": "+393334444555",
    "orderId": "123456",
    "products": [
        {
            "name": "iPhone 7",
            "type": "Electronics",
            "price": "500",
            "price": "2",
            "discount": 0
        },
        {
            "name": "MacBook Pro Charger",
            "type": "Electronics",
            "price": "80",
            "price": "1",
            "discount": 0
        }
    ]
  }
  */
}
```

Gotchas
-------

[](#gotchas)

Moneymour APIs allow only one pending request at a time. If you get a **403 error** having message **Duplicated request** please cancel the current pending request using the Moneymour app for iOS or Android.

Verify signature in your webhook
--------------------------------

[](#verify-signature-in-your-webhook)

```
$factory = new SignatureFactory(self::PRIVATE_KEY);
$factory->verify(
  $signature, // http request header "Signature"
  $expiresAt, // http request header "Expires-at"
  $body, // http request body
  MoneymourApiClient::ENVIRONMENT_SANDBOX  // or ENVIRONMENT_PRODUCTION when you get ready
); // return true or false
```

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance62

Regular maintenance activity

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity67

Established project with proven stability

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

Total

9

Last Release

2598d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1b083e089f0bf1c728212aefce4ab06f2fb99fcb066aba24b7aa8f4e9034bbc1?d=identicon)[moneymour](/maintainers/moneymour)

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

---

Top Contributors

[![TwistedLogic](https://avatars.githubusercontent.com/u/105908?v=4)](https://github.com/TwistedLogic "TwistedLogic (20 commits)")

---

Tags

paymentpaymentse-commercepayment methodloanloansmoneymour

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/moneymour-api-client-php/health.svg)

```
[![Health](https://phpackages.com/badges/moneymour-api-client-php/health.svg)](https://phpackages.com/packages/moneymour-api-client-php)
```

###  Alternatives

[amzn/amazon-pay-sdk-php

Amazon Pay SDK (PHP)

20512.1M3](/packages/amzn-amazon-pay-sdk-php)[amzn/amazon-pay-api-sdk-php

Amazon Pay API SDK (PHP)

505.1M9](/packages/amzn-amazon-pay-api-sdk-php)[cybersource/rest-client-php

Client SDK for CyberSource REST APIs

39881.3k6](/packages/cybersource-rest-client-php)[enupal/stripe

Allows customers sign up for recurring and one-time payments with Stripe, perfect for orders, donations, subscriptions, and events. Create simple payment forms in seconds easily without coding. For Craft CMS 3.x

3416.5k1](/packages/enupal-stripe)[hipay/hipay-fullservice-sdk-php

The HiPay Enterprise SDK for PHP is a library for developers who want to integrate HiPay Enterprise payment methods to any PHP platform.

111.2M4](/packages/hipay-hipay-fullservice-sdk-php)[sylius/payment-bundle

Flexible payments system for Symfony e-commerce applications.

22268.0k5](/packages/sylius-payment-bundle)

PHPackages © 2026

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