payson/paysonpayments
最新稳定版本:2.1.2
Composer 安装命令:
composer require payson/paysonpayments
包简介
Payson Recurring Payments and Payson Checkout API client for PHP
README 文档
README
Payson Recurring Payments and Payson Checkout API client for PHP
Setup using Composer
composer require payson/paysonpayments
Setup using include
require_once 'include.php';
Create connector
// Include library (without composer) require_once 'include.php'; // Connect to test environment $agentId = '4'; $apiKey = '2acab30d-fe50-426f-90d7-8c60a7eb31d4'; $apiUrl = \Payson\Payments\Transport\Connector::TEST_BASE_URL; $connector = \Payson\Payments\Transport\Connector::init($agentId, $apiKey, $apiUrl);
Create Payson Checkout client
$checkoutClient = new \Payson\Payments\CheckoutClient($connector);
Create Recurring Subscription client
$recurringSubscriptionClient = new \Payson\Payments\RecurringSubscriptionClient($connector);
Create Recurring Payment client
$recurringPaymentClient = new \Payson\Payments\RecurringPaymentClient($connector);
Example method: getAccountInfo()
// getAccountInfo() can be used with all three clients $accountInformation = $checkoutClient->getAccountInfo(); // Print the result print('<pre>' . print_r($accountInformation, true) . '</pre>');
Methods
Payson Checkout (\Payson\Payments\CheckoutClient)
- getAccountInfo()
- create()
- get()
- update()
- listCheckouts()
Payson Recurring Subscription (\Payson\Payments\RecurringSubscriptionClient)
- getAccountInfo()
- create()
- get()
- update()
- listRecurringSubscriptions()
Payson Recurring Payment (\Payson\Payments\RecurringPaymentClient)
- getAccountInfo()
- create()
- get()
- update()
- listRecurringPayments()
Examples
See files in the examples folder for examples of all methods.
Documentation
Use Payson Checkout REST API or Payson Recurring Payments REST API for more information about available parameters.
Test credentials
For instant access to our test environment simply create a Payson TestAccount to get your own Agent ID and API Key.
Requirements
cURL PHP >= 7.0
统计信息
- 总下载量: 916
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: UNLICENSE
- 更新时间: 2021-03-30