wefabric/acronis-php
Composer 安装命令:
composer require wefabric/acronis-php
包简介
Simple Acronis PHP SDK
README 文档
README
Simple implementation of the Acronis PHP library
Installation
composer require wefabric/acronis-php
Usage
Register a third-party application as an API client via the management console of the cloud platform in Acronis. Copy the domain, client id and client secret and use as followed.
<?php use Wefabric\Acronis\AcronisClient; use Wefabric\Acronis\Credentials; use Wefabric\Acronis\UrlResolver; require __DIR__."/../vendor/autoload.php"; $domainUrl = '{DOMAIN}'; $clientId = '{CLIENT_ID}'; $clientSecret = '{CLIENT_SECRET}'; $acronis = new AcronisClient(new UrlResolver($domainUrl), new Credentials($clientId, $clientSecret)); $alertsResponse = $acronis->getClient()->get('/api/alert_manager/v1/alerts'); // Retrieve the alerts as decoded Json $alertsResponse->json();
Examples
See for more examples in the 'examples' directory.
License
Wefabric Acronis PHP is open-sourced software licensed under the MIT license.
统计信息
- 总下载量: 54
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-11-13