PHPackages                             yogigr/payment-gateway - 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. yogigr/payment-gateway

ActiveLibrary[Payment Processing](/categories/payments)

yogigr/payment-gateway
======================

A simple and versatile Laravel package for integrating multiple payment providers. Easily manage and process payments from various gateways with a unified API.

1.0.1(1y ago)011MITPHP

Since Aug 23Pushed 1y ago1 watchersCompare

[ Source](https://github.com/yogigr/payment-gateway)[ Packagist](https://packagist.org/packages/yogigr/payment-gateway)[ RSS](/packages/yogigr-payment-gateway/feed)WikiDiscussions main Synced yesterday

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

payment-gateway
===============

[](#payment-gateway)

A simple and versatile Laravel package for integrating multiple payment providers. Easily manage and process payments from various gateways with a unified API.

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

[](#installation)

To install the `PaymentGateway` package, follow these steps:

1. **Require the Package via Composer**

    Run the following command in your Laravel project directory:

    ```
    composer require yogigr/payment-gateway
    ```
2. **Publish the Configuration File**

    Publish the configuration file using the following command:

    ```
    php artisan vendor:publish --provider="yogigr\PaymentGateway\PaymentGatewayServiceProvider" --tag="config"
    ```
3. **Set Up Environment Variables**

    your .env file:

    ```
     PAYMENT_GATEWAY=duitku
     PAYMENT_CALLBACK_DOMAIN=https://example.app
     PAYMENT_RETURN_DOMAIN=https://example.app

     DUITKU_MERCHANT_CODE=duitku-merchant-code
     DUITKU_MERCHANT_KEY=duitku-merchant-key
     DUITKU_SANDBOX_MODE=true
     DUITKU_SANITIZED_MODE=false
     DUITKU_LOGS=true
     DUITKU_PAYMENT_URL=https://sandbox.duitku.com/TopUp/v2/DuitkuNotification.aspx

     FINPAY_MERCHANT_CODE=finpay-merchant-id
     FINPAY_MERCHANT_KEY=finpay-merchant-key
     FINPAY_PAYMENT_URL=https://devo.finnet.co.id
    ```

Usage
-----

[](#usage)

After installation, you can use the package via the provided Facade. Below are examples of how to fetch categories and items.

### Show Payment Methods

[](#show-payment-methods)

```
use yogigr\PaymentGateway\Facades\PaymentGateway;

$methods = PaymentGateway::getPaymentMethodOptions();
```

### Create Invoice

[](#create-invoice)

```
use yogigr\PaymentGateway\Facades\PaymentGateway;

$data = [
    'amount' => 100000,
    'email' => 'customer@email.com',
    'phone' => '628100000000',
    'product_details' => 'Product details',
    'merchant_order_id' => 'order id / kode',
    'invoice_id' => 'Invoice id',
    'merchant_user_info' => 'Customer info / user id', // (opsional)
    'customer_name' => 'Customer name',
    'callback_path' => '/payment/callback',
    'return_path' => '/invoices',
    'success_path' => '/invoices?status=success',
    'expiry_period' => 60,
    'address' => 'Customer address',
    'city' => 'Customer city',
    'postal_code' => 'Postal code',
    'country_code' => 'ID'
];

$paymentMethod = 'credit_card';

$response = PaymentGateway::createInvoice($data, $paymentMethod);

if ($response->statusCode == '00') {
    redirect($response->paymentUrl);
}
```

### Callback

[](#callback)

```
use yogigr\PaymentGateway\Facades\PaymentGateway;
use Illuminate\Http\Request;

class CallbackController extends Controller
{
    public function callback(Request $request)
    {
        $result = PaymentGateway::callback($request);

        if ($result['resultCode'] === '00') { // success
            // actions if success
        }
    }
}
```

### Check transaction

[](#check-transaction)

```
use yogigr\PaymentGateway\Facades\PaymentGateway;

$transaction = PaymentGateway::checkTransaction($merchantOrderId);

dd($transaction);
```

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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

Every ~57 days

Total

2

Last Release

621d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/13002716?v=4)[Yogi Gilang Ramadhan](/maintainers/yogigr)[@yogigr](https://github.com/yogigr)

---

Top Contributors

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

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/yogigr-payment-gateway/health.svg)

```
[![Health](https://phpackages.com/badges/yogigr-payment-gateway/health.svg)](https://phpackages.com/packages/yogigr-payment-gateway)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.3k543.5M2.6k](/packages/aws-aws-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k38](/packages/neuron-core-neuron-ai)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M47](/packages/tencentcloud-tencentcloud-sdk-php)[chargebee/chargebee-php

ChargeBee API client implementation for PHP

758.5M9](/packages/chargebee-chargebee-php)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[imdhemy/google-play-billing

Google Play Billing

491.5M5](/packages/imdhemy-google-play-billing)

PHPackages © 2026

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