zqhong / omnipay-qpay
A QPay driver for the Omnipay PHP payment processing library.
Installs: 45
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/zqhong/omnipay-qpay
Requires
- omnipay/common: ~2.0
Requires (Dev)
- omnipay/tests: ~2.0
This package is not auto-updated.
Last update: 2025-10-04 00:17:56 UTC
README
安装
$ composer require -vvv zqhong/omnipay-qpay
使用
<?php include __DIR__ . '/vendor/autoload.php'; use Omnipay\Omnipay; $gateway = Omnipay::getFactory()->create("QPay") ->setMchId('') ->setMchKey('') ->setCertFilePath('') ->setKeyFilePath('') ->setNotifyUrl('') ->setOpUserPasswd(''); // 订单查询 // 参数请参考:https://qpay.qq.com/qpaywiki/showdocument.php?pid=1&docid=5 $queryOrderRequest = $gateway->queryOrder([ 'transaction_id' => '', ]); $queryOrderResponse = $queryOrderRequest->send(); if ($queryOrderResponse->isSuccessful()) { // 订单查询成功操作 }