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

ActiveLibrary[Payment Processing](/categories/payments)

seetolight/payment
==================

012[1 PRs](https://github.com/jzk2008/payment/pulls)PHP

Since Sep 1Pushed 2y ago1 watchersCompare

[ Source](https://github.com/jzk2008/payment)[ Packagist](https://packagist.org/packages/seetolight/payment)[ RSS](/packages/seetolight-payment/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

[!\[Software license\]\[ico-license\]](LICENSE)\[!\[Latest development\]\[ico-version-dev\]\]\[link-packagist\] \[!\[Monthly installs\]\[ico-downloads-monthly\]\]\[link-downloads\]

---

提醒：微信CA证书进行了更新，请更新项目到最新版本。否则5月29日后，将无法支付
----------------------------------------

[](#提醒微信ca证书进行了更新请更新项目到最新版本否则5月29日后将无法支付)

> 官方公告： [https://pay.weixin.qq.com/index.php/public/cms/content\_detail?lang=zh&amp;id=56602](https://pay.weixin.qq.com/index.php/public/cms/content_detail?lang=zh&id=56602)

- [Payment使用文档](https://helei112g1.gitbooks.io/payment-sdk/content/)
- [Payment使用常见问题汇总](https://helei112g1.gitbooks.io/payment-sdk/content/faq.html)

---

Payment 需要 PHP &gt;= 5.6以上的版本，并且同时需要PHP安装以下扩展

```
- cUR extension

- mbstring

- BC Math

- Guzzle

```

guzzle 是一个开源的php http请求lib，[项目地址](https://github.com/guzzle/guzzle)

Payment是什么？
===========

[](#payment是什么)

Payment是一个集成了 **支付宝支付**、**微信支付**、**招商支付**的PHP SDK。服务端开发者将它集成到自己的项目中，可以方便的通过相同的操作方式进行各项支付操作。不再需要开发者去单独了解支付宝、微信、招商的接口文档。以发起支付举例，开发者只需要通过：

```
try {
    $str = Charge::run(支付类型, 配置文件, 支付数据);
} catch (PayException $e) {
    echo $e->errorMessage();
    exit;
}

```

就可以得到支付结果返回数据。关心的核心只需要正确了解如何组装**支付数据**，以及如何正确处理返回后的数据即可。

Payment支持所有的PHP项目，只要求PHP版本大于等于5.6即可。同时支持composer与手动引入两种安装方式。

当前支持的接口
=======

[](#当前支持的接口)

当前sdk仅接入了支付宝支付、微信支付、招商支付（支付、退款）。中国现在电子支付的公司巨多，无法一一接入，欢迎各位发扬自己动手、丰衣足食的光荣传统，提交**PR**给我，代码贡献指南 [看这里](CONTRIBUTING.md)

支付宝接口
-----

[](#支付宝接口)

- **APP支付**（接入支付宝SDK，用户支付时唤起支付宝完成支付）
- **手机网站支付**（移动端唤起支付宝钱包或网页收银台完成支付）
- **电脑网站支付**（用户通过支付宝完成支付，交易款项即时到账）-原即时到账
- **当面付**（商户扫码首款或用户扫码付款）
- **单笔转账到支付宝**（支付宝商户向其它支付宝账户单笔转账）
- **交易支付、转账、退款查询接口**
- **交易退款接口**
- 对账单下载（待开发）
- 交易结算接口（待开发）
- 交易关闭接口（待开发）

微信支付接口
------

[](#微信支付接口)

- **刷卡支付**（用户打开微信钱包的刷卡界面，商户扫码后提交完成交易）
- **公众号支付**（用户在微信内进入商家的H5页面，页面内调用JSSDK完成支付）
- **扫码支付**（用户打开扫一扫，扫码商户二维码完成支付）
- **APP支付**（商户APP中集成微信SDK，用户点击后跳转到微信完成支付）
- **H5支付**（用户在微信以外的浏览器请求微信支付的场景唤起微信支付）
- **小程序支付**（用户在微信小程序中使用微信支付）
- **企业付款**（企业向用户付款）
- **交易支付、转账、退款查询接口**
- **交易退款接口**
- 对账单下载（待开发）
- 现金红包（待开发）
- 代金券或立减优惠券（待开发）

招商支付
----

[](#招商支付)

- **用户签约**（首次使用招商支付的用户完成绑卡操作）
- **招商一网通支付**（发起支付请求，招商支付仅此一个接口）
- **交易退款**
- **查询招商公钥**
- **交易支付、退款查询**
- 查询入账明细（待开发）
- 查询协议（待开发）
- 取消协议（待开发）

安装
--

[](#安装)

通过composer，这是推荐的方式，可以使用composer.json 声明依赖，或者直接运行下面的命令。

```
    composer require seetolight/payment:*"
```

放入composer.json文件中

```
    "require": {
        "seetolight/payment": "*"
    }
```

然后运行

```
composer update

```

---

###  Health Score

14

—

LowBetter than 2% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity23

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.

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

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

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

###  Alternatives

[omnipay/paypal

PayPal gateway for Omnipay payment processing library

3156.8M53](/packages/omnipay-paypal)[eduardokum/laravel-boleto

Biblioteca com boletos para o laravel

626351.9k2](/packages/eduardokum-laravel-boleto)[tbbc/money-bundle

This is a Symfony bundle that integrates moneyphp/money library (Fowler pattern): https://github.com/moneyphp/money.

1961.9M](/packages/tbbc-money-bundle)[2checkout/2checkout-php

2Checkout PHP Library

83740.3k2](/packages/2checkout-2checkout-php)[smhg/sepa-qr-data

Generate QR code data for SEPA payments

61717.2k5](/packages/smhg-sepa-qr-data)[omnipay/dummy

Dummy driver for the Omnipay payment processing library

271.2M33](/packages/omnipay-dummy)

PHPackages © 2026

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