PHPackages                             foris-master/orange-money-sdk - 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. foris-master/orange-money-sdk

ActiveLibrary[API Development](/categories/api)

foris-master/orange-money-sdk
=============================

This is a php sdk for orange operator mobile money api.

0.8.0(2y ago)173.3k17[5 issues](https://github.com/Foris-master/orange-money-sdk/issues)MITPHPPHP &gt;=5.3.0|^7.4 | ^8.0.2CI failing

Since Apr 25Pushed 2y ago2 watchersCompare

[ Source](https://github.com/Foris-master/orange-money-sdk)[ Packagist](https://packagist.org/packages/foris-master/orange-money-sdk)[ Docs](https://github.com/php-loep/:package_name)[ RSS](/packages/foris-master-orange-money-sdk/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (4)Dependencies (2)Versions (5)Used By (0)

Orange Money Sdk
================

[](#orange-money-sdk)

[![Latest Version](https://camo.githubusercontent.com/5c4ca5cf6f5092e4b8c0af603a6bb2da441afc5f2b36612c30995ff5504f184f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f7468657068706c65616775652f6f72616e67652d6d6f6e65792d73646b2e7376673f7374796c653d666c61742d737175617265)](https://github.com/thephpleague/orange-money-sdk/releases)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/619edecfcf26f3baa0350fc8afab55c871a22f22fd5b1db3130702142059c174/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7468657068706c65616775652f6f72616e67652d6d6f6e65792d73646b2f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/thephpleague/orange-money-sdk)[![Coverage Status](https://camo.githubusercontent.com/48796b25f13b57abe822a20a576aea411f87b0a85767860eb63eb85f542cf557/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f7468657068706c65616775652f6f72616e67652d6d6f6e65792d73646b2e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/thephpleague/orange-money-sdk/code-structure)[![Quality Score](https://camo.githubusercontent.com/685124f23e1c916270ecbb48c3b03e5709548c5643dc5751e6f0672d93c3e42a/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7468657068706c65616775652f6f72616e67652d6d6f6e65792d73646b2e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/thephpleague/orange-money-sdk)[![Total Downloads](https://camo.githubusercontent.com/808190bdbcc44ec4ee5f29b211e223146bf79b4732f8fcfa54134978d4607425/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6c65616775652f6f72616e67652d6d6f6e65792d73646b2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/league/orange-money-sdk)

**Note:** `orange-money-sdk`.

This is a php sdk for orange operator mobile money api.

Install
-------

[](#install)

Via Composer

```
$ composer require foris-master/orange-money-sdk
```

Confing
-------

[](#confing)

```
Set AUTH_HEADER, MERCHANT_KEY,RETURN_URL,CANCEL_URL,NOTIF_URL enviroment variable ( .env file if using dotenv),
you get all related to you console at https://developer.orange.com/

```

Usage
-----

[](#usage)

```
use Foris\OmSdk\OmSdk;

$om = new OmSdk();
// QuickStart
/**
 * You need to set AUTH_HEADER, MERCHANT_KEY,RETURN_URL,CANCEL_URL,NOTIF_URL
 * enviroment variable ( .env file if using dotenv)
 */
$om->webPayment(['amount'=>100]);
// Full Options
$opt=[
        "merchant_key"=> '********',
        "currency"=> "OUV",
        "order_id"=> $id,
        "amount"=> 0,
        "return_url"=> 'http://www.you-site.com/callback/return',
        "cancel_url"=> 'http://www.you-site.com/callback/cancel',
        "notif_url"=>'http://www.you-site.com/callback/notif',
        "lang"=> "fr"
    ];
$om->webPayment($opt);
```

API
---

[](#api)

### Get token

[](#get-token)

```
use Foris\OmSdk\OmSdk;

$om = new OmSdk();

$rep= $om->getToken();
var_dump($rep);
// var_dump result
[
        "token_type"=> 'Bearer',
        "access_token"=> "0213GH123l12kj312k",
        "expires_in"=> "7776000",
];
```

### Web Payment

[](#web-payment)

```
use Foris\OmSdk\OmSdk;

$om = new OmSdk();
$opt = [
               "merchant_key"=> '********',
               "currency"=> "OUV",
               "order_id"=> $id,
               "amount"=> 0,
               "return_url"=> 'http://www.you-site.com/callback/return',
               "cancel_url"=> 'http://www.you-site.com/callback/cancel',
               "notif_url"=>'http://www.you-site.com/callback/notif',
               "lang"=> "fr"
           ];
$rep= $om->webPayment($opt);
var_dump($rep);
// var_dump result
[
        "status"=> 201,
        "message"=> "OK",
        "pay_token"=> "87a9f2f8ebca97sdfdsbb49795f77981f5be1face7b6a543c8a1304d81e4299fd",
        "payment_url"=>"https://webpayment-sb.orange-money.com/payment/pay_token/87a9f2f8ebca97sdfdsbb49795f77981f5be1face7b6a543c8a1304d81e4299fd"
        "notif_token"=> "793d6157d9c7d52ae3920dc596956206"
];
```

#### Note

[](#note)

webPayment method automatically call getToken and set it in request header.

### Transaction Status

[](#transaction-status)

```
use Foris\OmSdk\OmSdk;

$om = new OmSdk();

$rep= $om->checkTransactionStatus($orderId,$amount,$pay_token);
var_dump($rep);
// var_dump result
[
         "status" => "SUCCESS",
         "order_id" => "MY_ORDER_ID_08082105_0023457",
         "txnid" => "MP150709.1341.A00073"
];
```

#### Note

[](#note-1)

The status could take one of the following values: INITIATED; PENDING; EXPIRED; SUCCESS; FAILED

- INITIATED waiting for user entry
- PENDING user has clicked on “Confirmer”, transaction is in progress on Orange side
- EXPIRED user has clicked on “Confirmer” too late (after token’s validity)
- SUCCESS payment is done
- FAILED payment has failed

Production
----------

[](#production)

```
  For production your need to set your target country code in COUNTRY enviroment variable ( .env file if using dotenv)
  example : COUNTRY=cm

```

Testing
-------

[](#testing)

```
$ phpunit
```

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

[](#contributing)

Please see [CONTRIBUTING](https://github.com/thephpleague/:package_name/blob/master/CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- [foris-master](https://github.com/foris-master)
- [All Contributors](https://github.com/thephpleague/:package_name/contributors)
- [Orange dev team](https://developer.orange.com/apis/om-webpay/)

License
-------

[](#license)

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

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance14

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 91.7% 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 ~632 days

Total

4

Last Release

1047d ago

PHP version history (2 changes)0.5.0PHP &gt;=5.3.0

0.8.0PHP &gt;=5.3.0|^7.4 | ^8.0.2

### Community

Maintainers

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

---

Top Contributors

[![Foris-master](https://avatars.githubusercontent.com/u/15254899?v=4)](https://github.com/Foris-master "Foris-master (11 commits)")[![marlinbleriaux](https://avatars.githubusercontent.com/u/80590737?v=4)](https://github.com/marlinbleriaux "marlinbleriaux (1 commits)")

---

Tags

apicomposermobilemoneyorangephpsdkphpmoneysdkorange

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/foris-master-orange-money-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/foris-master-orange-money-sdk/health.svg)](https://phpackages.com/packages/foris-master-orange-money-sdk)
```

###  Alternatives

[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k7.6M74](/packages/openai-php-laravel)[hubspot/api-client

Hubspot API client

23914.2M16](/packages/hubspot-api-client)[php-opencloud/openstack

PHP SDK for OpenStack APIs. Supports BlockStorage, Compute, Identity, Images, Networking and Metric Gnocchi

2292.2M24](/packages/php-opencloud-openstack)[mailchimp/transactional

458.9M16](/packages/mailchimp-transactional)[resend/resend-php

Resend PHP library.

574.7M21](/packages/resend-resend-php)[checkout/checkout-sdk-php

Checkout.com SDK for PHP

553.3M7](/packages/checkout-checkout-sdk-php)

PHPackages © 2026

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