nrbsolution/nagad_payment_gateway

dev-main 2023-02-02 10:35 UTC

This package is not auto-updated.

Last update: 2024-09-27 16:33:08 UTC


README

Nagad是由孟加拉国邮政局提供的一种支付网关服务。它使商家能够以安全便捷的方式接受客户的在线支付。Nagad提供了一系列功能,包括24/7接收支付、实时支付跟踪以及对多种支付方式的支持,如移动银行。有了Nagad,商家可以轻松管理他们的在线交易并扩大业务。

安装

运行以下命令通过Composer安装:

composer require nrbsolution/nagad_payment_gateway

入门

Nagad Payment Gateway 需要修改你的 composer.json 文件

 "minimum-stability": "stable",

为:

 "minimum-stability": "dev",

Nagad Payment Gateway 需要添加到你的 env 文件中

NAGAD_SANDBOX=true // true only sandbox testing purpose or main api work only NAGAD_SANDBOX=false
NAGAD_MERCHANT_ID= //Your NAGAD_MERCHANT_ID
NAGAD_MERCHANT_NUMBER= // Your NAGAD_MERCHANT_NUMBER
NAGAD_PUBLIC_KEY= // Your NAGAD_PUBLIC_KEY
NAGAD_PRIVATE_KEY= // Your NAGAD_PRIVATE_KEY
NAGAD_ORDER_ID_PREFIX= // You can change your order id prefix 
NAGAD_LOGO=// Your logo url

// if you  controls the response type callback 
//You need change to your config/nagad_payment_gateway.php file 
//  Supported: "json", "html",

"response_type"   => "html" 
// You need to publish this package 
php artisan vendor:publish --provider="App\Providers\NagadPaymentGatewaySerivceProvider"

使用说明

Route: 
http://{Your Host address}/nagad/{reference_id}/{amount}
// Example:
http://127.0.0.1:8000/nagad/pid_234234234/3000

许可证

此代码附带MIT许可证发布。