PHPackages                             credopay/paymentgateway - 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. credopay/paymentgateway

ActiveLibrary[Payment Processing](/categories/payments)

credopay/paymentgateway
=======================

A PHP library for integrating with the CredoPay payment gateway to process online payments.

v1.0.0(11mo ago)05MITPHPPHP &gt;=7.4

Since Jun 11Pushed 10mo agoCompare

[ Source](https://github.com/TransTracCPBS/centerfirst-pg-sdk)[ Packagist](https://packagist.org/packages/credopay/paymentgateway)[ RSS](/packages/credopay-paymentgateway/feed)WikiDiscussions main Synced 1mo ago

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

CredoPay Payment Gateway
========================

[](#credopay-payment-gateway)

CredoPay Payment Gateway is a PHP library that provides an easy-to-use interface for interacting with the CredoPay payment gateway API. This library allows you to create orders, check order statuses, and manage transactions securely and efficiently.

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

[](#installation)

You can install the package via Composer. Run the following command:

```
composer require credopay/paymentgateway
```

Features
--------

[](#features)

- **Order Management**: Create and manage orders through CredoPay.
- **Transaction Management**: Handle transactions with ease.
- **Secure Authentication**: Uses secure basic authentication for API requests.
- **System Information**: Attaches system and server information to each request for better tracking and security.

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

[](#requirements)

```
- PHP 8.2 or higher
- Composer
- cURL extension enabled
- CredoPay API credentials (Client ID and Client Secret)

```

Usage
-----

[](#usage)

Initialization
--------------

[](#initialization)

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

use CredoPay\CredoPayPaymentGateway;
use CredoPay\Resources\OrderAPI;

// Initialize the payment gateway
$clientId = 'your-client-id';
$clientSecret = 'your-client-secret';
$gateway = new CredoPayPaymentGateway($clientId, $clientSecret);

// Initialize the OrderAPI
$orderAPI = new OrderAPI($gateway);
```

Creating an Order
-----------------

[](#creating-an-order)

```
$orderData = [
    'receiptId' => 'RE_YOURRECEIPT123',
    'amount' => 500, // Amount in smallest currency unit
    'currency' => 'INR',
    'description' => 'Test Payment',
    'customerFields' => [
        'name' => 'John Doe',
        'email' => 'john.doe@example.com',
        'phone' => '9876543210'
    ],
    'uiMode' => 'checkout'
];

try {
    $orderResponse = $orderAPI->createOrder($orderData);
    echo "Order Response: " . $orderResponse;
} catch (Exception $e) {
    echo "Error: " . $e->getMessage();
}
```

Checking Order Status
---------------------

[](#checking-order-status)

```
try {
    $orderId = 'your-order-id'; // Replace with an actual order ID
    $statusResponse = $orderAPI->checkStatus($orderId);
    echo "Order Status: " . $statusResponse;
} catch (Exception $e) {
    echo "Error: " . $e->getMessage();
}
```

API Endpoints
-------------

[](#api-endpoints)

```
- Create Order: POST https://api.thecenterfirst.com/nac/api/v1/pg/orders/create-checkout

- Check Order Status: GET https://api.thecenterfirst.com/nac/api/v1/pg/orders/check-status

```

Project Structure
-----------------

[](#project-structure)

```
src/
├── Config.php            # Contains API endpoints and configurations
├── CredoPayPaymentGateway.php  # Handles HTTP requests
└── resources/
    ├── OrderAPI.php      # Methods for order operations
    └── TransactionAPI.php # Placeholder for future enhancements
```

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

[](#contributing)

Contributions are welcome! Feel free to submit issues or pull requests to enhance the library.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance52

Moderate activity, may be stable

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

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

333d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6351220bc76585cb102f2044c135f26b0b6b63accfe21cdc92f595869d2020ab?d=identicon)[credopay](/maintainers/credopay)

---

Top Contributors

[![balajie-credopay](https://avatars.githubusercontent.com/u/214964307?v=4)](https://github.com/balajie-credopay "balajie-credopay (2 commits)")

---

Tags

paymentgatewaycredopay

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/credopay-paymentgateway/health.svg)

```
[![Health](https://phpackages.com/badges/credopay-paymentgateway/health.svg)](https://phpackages.com/packages/credopay-paymentgateway)
```

###  Alternatives

[lokielse/omnipay-alipay

Alipay gateway for Omnipay payment processing library

587421.0k11](/packages/lokielse-omnipay-alipay)[sudiptpa/omnipay-nabtransact

National Australia Bank (NAB) Transact driver for the Omnipay payment processing library.

1017.2k](/packages/sudiptpa-omnipay-nabtransact)[baklysystems/laravel-paymob

Laravel PayMob online payment gateway package

282.4k](/packages/baklysystems-laravel-paymob)[lucassmacedo/omnipay-mercadopago

MercadoPago gateway for OmniPay

154.6k](/packages/lucassmacedo-omnipay-mercadopago)

PHPackages © 2026

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