like-a-rocket/hotmart
最新稳定版本:v1.0.0
Composer 安装命令:
composer require like-a-rocket/hotmart
包简介
A PHP wrapper for the Hotmart REST API.
README 文档
README
A PHP wrapper for the Hotmart REST API. Easily interact with the Hotmart REST API securely using this library.
Installation
composer require like-a-rocket/hotmart
Getting started
Generate API credentials (Access Token) following this instructions https://developers.hotmart.com/docs/pt-BR/start/app-auth/. Check out the Hotmart API endpoints and data that can be manipulated in https://developers.hotmart.com/docs/pt-BR/.
Client class
$hotmart = new Client('https://sandbox.hotmart.com', 'wxyz');
Client methods
GET
$hotmart->get($endpoint, $parameters = []);
POST
$hotmart->post($endpoint, $parameters = [], $body = []);
PATCH
$hotmart->patch($endpoint, $parameters = [], $body = []);
Arguments
| Params | Type | Description |
|---|---|---|
endpoint |
string |
Hotmart API endpoint, example: /payments/api/v1/subscriptions |
parameters |
array |
Each array index has a query param, example: status => 'ACTIVE' |
Response
All methods will return array on success or throwing Exception errors on failure.
统计信息
- 总下载量: 8
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-09-08