Download the PHP package tinymeng/pay-sdk without Composer

On this page you can find all versions of the php package tinymeng/pay-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package pay-sdk

Alipay SDK for PHP

支付宝、微信、QQ、等支付开放平台第三方 PHP SDK,基于官方最新版本。

功能特点

环境要求

PHP >= 7.1

使用方法

  1. Composer 安装。

类库使用的命名空间为\tinymeng\pay

支付宝支付

  1. 创建配置文件 config.php,填写配置信息。

  2. 引入配置文件,构造请求参数,调用AlipayTradeService中的方法发起请求,参考 examples/qrpay.php

  3. 更多实例,请移步 examples 目录。

  4. AlipayService实现类功能说明

    类名 说明
    AlipayTradeService 支付宝交易功能,基本上所有支付产品都用这个
    AlipayOauthService 支付宝快捷登录功能,用于JS支付快捷登录以及第三方应用授权
    AlipaySettleService 支付宝分账功能
    AlipayTransferService 支付宝转账功能
    AlipayComplainService 支付宝交易投诉处理
    AlipayCertifyService 支付宝身份认证
    AlipayCertdocService 支付宝实名证件信息比对验证
    AlipayBillService 支付宝账单功能
  5. 要对接的API在AlipayService实现类中没有,可根据支付宝官方的文档,使用AlipayService类中的aopExecute方法直接调用接口,参考 examples/other.php

微信支付

  1. 创建APIv2配置文件 config.php,填写微信支付商户信息。

  2. 引入配置文件,构造请求参数,调用PaymentService中的方法发起请求,APIv2参考 examples/V3/qrpay.php

  3. 更多实例,请移步 examples 目录。

  4. 类功能说明

    类名 说明
    PaymentService 基础支付服务类,所有支付功能都用这个
    JsApiTool JSAPI支付工具类,用于公众号、小程序登录获取Openid
    TransferService 微信支付商家转账功能
    ProfitsharingService 微信支付分账功能
    ComplainService 消费者投诉处理功能
    PartnerPaymentService 服务商基础支付服务类,APIv3服务商调用支付功能使用
  5. 要对接的API在以上实现类中没有,可根据微信支付官方的文档,使用BaseService类中的execute方法直接调用接口,参考 examples/V3/other.php

QQ支付

  1. 创建配置文件 config.php,填写QQ钱包支付商户信息。

  2. 引入配置文件,构造请求参数,调用PaymentService中的方法发起请求,参考 examples/qrpay.php

  3. 更多实例,请移步 examples 目录。

  4. 类功能说明

    类名 说明
    PaymentService 基础支付服务类,所有支付功能都用这个
    TransferService QQ钱包企业付款功能
  5. 要对接的API在以上实现类中没有,可根据QQ钱包官方的文档,使用BaseService类中的execute方法直接调用接口。

All versions of pay-sdk with dependencies

PHP Build Version
Package Version
Requires php Version >=7.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package tinymeng/pay-sdk contains the following files

Loading the files please wait ....