PHPackages                             husail/paystore-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. [Payment Processing](/categories/payments)
4. /
5. husail/paystore-sdk

ActiveLibrary[Payment Processing](/categories/payments)

husail/paystore-sdk
===================

PayStore PHP SDK

v1.0.0-alpha(1y ago)125MITPHPPHP ^8.1

Since Jul 3Pushed 1y agoCompare

[ Source](https://github.com/husail/paystore-sdk)[ Packagist](https://packagist.org/packages/husail/paystore-sdk)[ Docs](https://github.com/husail/paystore-sdk)[ RSS](/packages/husail-paystore-sdk/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (14)Versions (2)Used By (0)

PayStore PHP SDK
================

[](#paystore-php-sdk)

The **PayStore PHP SDK** allows integration with the PayStore API in **any PHP project**. It also provides **Facades** and a **Service Provider** for enhanced **Laravel** integration.

---

📦 Installation
--------------

[](#-installation)

```
composer require husail/paystore-sdk
```

---

🔧 Usage Example
---------------

[](#-usage-example)

### **For Non-Laravel PHP Projects:**

[](#for-non-laravel-php-projects)

**Basic Usage:**

```
require 'vendor/autoload.php';

use Husail\PayStore\Client;
use Husail\PayStore\Authentication;

$client = new Client(
    new Authentication(token: 'your-token')
);

$response = $client->merchant->all();
if ($response->successful()) {
    // Handle the response
}
```

**With Logging:**

```
require 'vendor/autoload.php';

use Monolog\Logger;
use Husail\PayStore\Client;
use Monolog\Handler\StreamHandler;
use Husail\PayStore\Authentication;
use Husail\PayStore\HttpClient\Message\Formatter\SimpleFormatter;

$logger = new Logger('my_logger');
$logger->pushHandler(new StreamHandler(__DIR__ . '/paystore.log'));

$client = new Client(
    new Authentication(token: 'your-token'),
    logger: $logger,
    formatter: new SimpleFormatter(true) // 'true' enables pretty-printed JSON logs
);

$response = $client->merchant->all();
if ($response->successful()) {
    // Handle the response
}
```

---

### **For Laravel:**

[](#for-laravel)

1. **Publish the configuration**:

    ```
    php artisan vendor:publish --provider="Husail\PayStore\PayStoreServiceProvider"
    ```
2. **Add environment variables** in your `.env` file:

    ```
    PAYSTORE_TOKEN=your-token

    # Optional logging settings:
    PAYSTORE_LOG_ENABLED=false             # Enable or disable request/response logging
    PAYSTORE_LOG_FORMATTER_EXPANDED=false  # Pretty-print JSON in logs if enabled
    ```
3. **Use the Facade to interact with the API:**

```
use PayStore;

$response = PayStore::client()->merchant->all();
if ($response->successful()) {
    // Handle the response
}
```

4. **Configure Logging**

    When `PAYSTORE_LOG_ENABLED` is set to `true`, the SDK logs request and response details via Laravel's default logging channel. By default, logs output compact JSON. If you want the JSON output to be more readable (pretty-printed), set `PAYSTORE_LOG_FORMATTER_EXPANDED` to `true`.

---

🤝 Contributing
--------------

[](#-contributing)

We welcome contributions! Feel free to submit issues or pull requests to help improve the SDK.

---

📜 License
---------

[](#-license)

Licensed under the [MIT License](LICENSE.md).

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance50

Moderate activity, may be stable

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity31

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

366d ago

### Community

Maintainers

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

---

Top Contributors

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

---

Tags

paystorepaystore-sdk

###  Code Quality

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/husail-paystore-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/husail-paystore-sdk/health.svg)](https://phpackages.com/packages/husail-paystore-sdk)
```

###  Alternatives

[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

85036.3k](/packages/flow-php-flow)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[telnyx/telnyx-php

Official Telnyx PHP SDK — APIs for Voice, SMS, MMS, WhatsApp, Fax, SIP Trunking, Wireless IoT, Call Control, and more. Build global communications on Telnyx's private carrier-grade network.

35789.4k2](/packages/telnyx-telnyx-php)[cakephp/cakephp

The CakePHP framework

8.9k19.5M1.8k](/packages/cakephp-cakephp)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.5k5.9M739](/packages/sylius-sylius)[typo3/cms

TYPO3 CMS is a free open source Content Management Framework initially created by Kasper Skaarhoj and licensed under GNU/GPL.

1.2k1.9M122](/packages/typo3-cms)

PHPackages © 2026

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