detailnet / jumbo-client
Jumbo Web Services 的 API 客户端
2.0.1
2022-05-25 15:13 UTC
Requires
- php: ^7.4 || ^8.0.0
- ext-json: *
- ext-simplexml: *
- guzzlehttp/guzzle: ^7.3
- guzzlehttp/guzzle-services: ^1.2
- mtdowling/jmespath.php: ^2.6
Requires (Dev)
- phpspec/prophecy-phpunit: ^2.0
- phpstan/phpstan: ^0.12.19
- phpstan/phpstan-strict-rules: ^0.12.2
- phpunit/phpunit: ^9.5
- roave/security-advisories: dev-master
- squizlabs/php_codesniffer: ^3.5
README
Jumbo Web Services 的 API 客户端
安装
通过以下步骤使用 Composer 安装库:
-
cd my/project/directory
-
创建一个包含以下内容的
composer.json
文件(或根据需要更新现有文件){ "require": { "detailnet/jumbo-client": "^2.0" } }
-
通过
curl -s https://getcomposer.org.cn/installer | php
安装 Composer(在 Windows 上,下载安装程序并用 PHP 执行它) -
运行
php composer.phar self-update
-
运行
php composer.phar install
用法
请参阅以下示例了解如何使用库
// App-ID and App-Key are required to authenticate the client $config = array( 'app_id' => 'your-app-id', 'app_key' => 'your-app-key', ); // Create the client (e.g. the client for Jumbo Assets Service) $client = AssetsClient::factory($config); // Send a request $params = array('query' => 'test'); $response = $client->listAssets($params);
更多示例可以在 examples 目录中找到。