miralsoft/weclapp-api
最新稳定版本:v1.1.2
Composer 安装命令:
composer require miralsoft/weclapp-api
包简介
The api functions from weclapp in php.
README 文档
README
This Project is to use the weclapp API with PHP.
How to use
You can download the Package over composer with following line in composer File:
"require": {
"php": ">=7.4.0",<br>
"miralsoft/weclapp-api": ">=v1"
}
Configuration
The configuration have to been set in your PHP-Project. You must define 2 constants like this:
use miralsoft\weclapp\api\Config;
Config::$URI = 'https://xxx.weclapp.com/webapp/api/v1/';
Config::$TOKEN = 'xxx';
Replace the xxx with your own data.
Full example
To get a list of customers, here is a example:
use miralsoft\weclapp\api\Customer;
use miralsoft\weclapp\api\Config;
Config::$URI = 'https://xxx.weclapp.com/webapp/api/v1/';
Config::$TOKEN = 'xxx';
$customer = new Customer();
$result = $customer->get(1, 100, 'customerNumber');
if (is_array($result)) {
echo 'Count results: ' . count($result);
}
echo '<br><br>';
print_r($result);
You get a list of first 100 customers and can use it in any way.
统计信息
- 总下载量: 241
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 2
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: proprietary
- 更新时间: 2021-04-10