PHPackages                             9pay/wallet - 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. 9pay/wallet

ActiveLibrary[API Development](/categories/api)

9pay/wallet
===========

Library for use for connect with wallet 9pay

1.0.0(7y ago)022MITPHPPHP &gt;=5.3.0

Since Nov 29Pushed 7y ago2 watchersCompare

[ Source](https://github.com/boydepdai92/9pay-wallet)[ Packagist](https://packagist.org/packages/9pay/wallet)[ Docs](https://9pay.vn)[ RSS](/packages/9pay-wallet/feed)WikiDiscussions master Synced 1w ago

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

9pay Wallet
===========

[](#9pay-wallet)

9pay Wallet is a library connected to the payment system through **9pay wallet** for merchants

Requirements
------------

[](#requirements)

- PHP &gt;= 5.3

Getting started
---------------

[](#getting-started)

### Installation

[](#installation)

Use [Composer](https://getcomposer.org/) to install Just add the packagist dependecy:

```
    "require": {
        // ...
        "9pay/wallet": ">=1.0.0"
    }
```

Or, if you want to get it directly from github, adding this to your composer.json should be enough:

```
    "require": {
    	// ...
        "9pay/wallet": "dev-master"
    }
```

If you don't have composer.json file, use this:

```
    composer require 9pay/wallet
```

### Usage

[](#usage)

#### Config

[](#config)

The support library uses two types of config files or arrays.

- File config:

```
   $path = '/app/config';
```

You need to create config file with name is environment you will use. Examples of files with application configuration options:

sand.php

```
return array(
    'url'     => 'https://example.com',
    'api_key' => 'api_key',
    'version' => '2.1'
);
```

production.php

```
return array(
    'url'     => 'https://example.com',
    'api_key' => 'api_key',
    'version' => '2.1'
);
```

- Array config:

You can use an array config direct. Example:

```
$config = array(
   'url'     => 'https://example.com',
   'api_key' => 'api_key',
   'version' => '2.1'
);
```

#### Method

[](#method)

- create: create a payment in 9pay wallet
- query: get info a payment in 9pay wallet

#### Example Code:

[](#example-code)

```
use Ninepay\Api\Wallet;

$config = array(
    'url'     => 'https://example.com',
    'api_key' => 'api_key',
    'version' => '2.1'
);

$wallet = new Wallet($config);

$attr = array(
    'payment_no'  => '123456',
    'amount'      => '10000',
    'description' => 'This is test order',
    'return_url'  => 'https://example.com'
);

$res = $wallet->create($attr);
```

If you use array config, you don't set environment. If you use file config, you can set environment to use by:

```
  $wallet = new Wallet($path, 'sand');
```

If you don't set environment, library will get `sand` is default.

License
-------

[](#license)

[MIT](https://choosealicense.com/licenses/mit/)

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 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

2727d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7631aab95a313ecb1b2e0a0fee5303acbe4bcbee49c5702dd21e9bc88ca7fb90?d=identicon)[boydepdai92](/maintainers/boydepdai92)

---

Top Contributors

[![boydepdai92](https://avatars.githubusercontent.com/u/10055241?v=4)](https://github.com/boydepdai92 "boydepdai92 (5 commits)")

---

Tags

9pay9pay wallet

### Embed Badge

![Health badge](/badges/9pay-wallet/health.svg)

```
[![Health](https://phpackages.com/badges/9pay-wallet/health.svg)](https://phpackages.com/packages/9pay-wallet)
```

###  Alternatives

[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3731.2M42](/packages/tencentcloud-tencentcloud-sdk-php)[convertkit/convertkitapi

Kit PHP SDK for the Kit API

2167.1k1](/packages/convertkit-convertkitapi)[mapado/rest-client-sdk

Rest Client SDK for hydra API

1125.9k2](/packages/mapado-rest-client-sdk)

PHPackages © 2026

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