PHPackages                             anchnet/anchcloud-sdk-php - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. anchnet/anchcloud-sdk-php

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

anchnet/anchcloud-sdk-php
=========================

Anchcloud SDK for php

18PHP

Since Nov 23Pushed 8y ago6 watchersCompare

[ Source](https://github.com/anchnet/anchcloud-sdk-php)[ Packagist](https://packagist.org/packages/anchnet/anchcloud-sdk-php)[ RSS](/packages/anchnet-anchcloud-sdk-php/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (1)Used By (0)

Anchcloud SDK for PHP
=====================

[](#anchcloud-sdk-for-php)

**SDK 处于开发阶段，请勿用于生产环境！！**

首先在云平台获取 Client Key 和秘钥

- 基础认证
- 主机实例
- 磁盘
- 快照备份
- 公网 IP
- 私有网络
- 云路由器
- 云负载均衡器
- 云数据库
- 云防火墙
- SSH 秘钥
- 系统镜像
- 回收站
- 用户信息管理

Use Composer
------------

[](#use-composer)

[Packagist](https://packagist.org/packages/51idc/anchcloud-sdk-php)

```
composer require 51idc/anchcloud-sdk-php:dev-master

```

Single File
-----------

[](#single-file)

```
# Clone source code
git clone https://github.com/51idc/anchcloud-sdk-php.git

```

```
require __SDK_DIR__ . '/vendor/autoload.php';
```

Usage
-----

[](#usage)

```
// require __DIR__ . '/vendor/autoload.php';

$instanceClient = new InstancesClient($clientId, $secretKey, [
    'timeout' => 3,
    //'proxy'   => 'socks5://127.0.0.1:1080',
]);

// 查询主机列表
$data = $instanceClient->describeInstances(\Anchcloud\Iaas\Constants::ZONE_AC1);
var_dump($data);

// 开通主机
$job = $instanceClient->runInstances(\Anchcloud\Iaas\Constants::ZONE_AC1, [
    'instance' => [
        "image_id"       => "centos65x64e",
        "instance_type"  => \Anchcloud\Iaas\Instances\Constants::PERFORMANCE_INSTANCE,
        "cpu"            => 1,
        "memory"         => 1024,
        "count"          => 1,
        "instance_name"  => "Test-INSTANCE",
        "login_mode"     => \Anchcloud\Iaas\Instances\Constants::LOGIN_MODE_KEYPAIR,
        "login_keypair"  => "kp-E850VXZN",
        "security_group" => "sg-TS5D1JXN",
    ],
    "order"    => [
        "payment_type" => "POSTPAY"
    ],
]);

var_dump($job);
```

Run test case
-------------

[](#run-test-case)

```
clientId=your_client_id \
clientSecret=your_client_secret \
phpunit --bootstrap vendor/autoload.php tests/
```

License
-------

[](#license)

This project is licensed under the Apache License, Version 2.0.

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/cd199c56a42f6e0591d1f9036143fcd8c8e5b47a9a2a262db8321d4cf20755a7?d=identicon)[eaglewu](/maintainers/eaglewu)

---

Tags

51idcanchcloudcloudphpsdk

### Embed Badge

![Health badge](/badges/anchnet-anchcloud-sdk-php/health.svg)

```
[![Health](https://phpackages.com/badges/anchnet-anchcloud-sdk-php/health.svg)](https://phpackages.com/packages/anchnet-anchcloud-sdk-php)
```

###  Alternatives

[bitpoke/stack-mu-plugin

WordPress must-use plugin for Stack

1219.5k](/packages/bitpoke-stack-mu-plugin)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
