名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 |
curl -i -X POST https://api3.verycloud.cn/API/instance/nodeList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60"}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "123456789",
"areaname": "北京1区",
"status": "1"
},
{
"id": "987654321",
"areaname": "上海1区",
"status": "1"
}
]
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 |
curl -i -X POST https://api3.verycloud.cn/API/instance/cpuResourceList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60"}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "9876543210",
"volume": "1",
"status": "1"
},
{
"id": "1234567890",
"volume": "2",
"status": "1"
},
{
"id": "3201258697",
"volume": "4",
"status": "1"
},
{
"id": "5421236986",
"volume": "8",
"status": "1"
}
]
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 |
curl -i -X POST https://api3.verycloud.cn/API/instance/memResourceList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60"}'
{
"code": 1,
"message": "操作成功",
"result": [
{
"id": "1234567890",
"volume": "512",
"status": "1"
},
{
"id": "9876543210",
"volume": "1024",
"status": "1"
}
]
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
nodeid | int | 数据中心ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/networkResourceList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "nodeid": 1234567890}'
{
"code": 1,
"message": "操作成功",
"result": [
{
"id": "1234567890",
"linetype": "1",
"node": {
"id": "1234567890",
"areaname": "上海1区",
"status": "0"
},
"status": "1"
},
{
"id": "9876543210",
"linetype": "2",
"node": {
"id": "9876543210",
"areaname": "上海1区",
"status": "0"
},
"status": "1"
}
]
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 |
curl -i -X POST https://api3.verycloud.cn/API/instance/imageList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60"}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "123456789",
"image_id": "img-ntx0p5rk",
"osname": "Ubuntu-14.04-x64",
"ostype": "1",
"osdigit": "64",
"status": "1"
},
{
"id": "9876543210",
"image_id": "img-jue0tqfu",
"osname": "Ubuntu-14.10-x64",
"ostype": "1",
"osdigit": "64",
"status": "1"
},
]
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
nodeid | int | 云节点ID | |
imageid | int | 镜像ID | |
status | int | 状态 0创建中 1运行 2暂停 3异常 4重装中 5限制 6维护 7删除中 8队列 9回收站 | |
mark | int | 星标 0否 1是 | |
limit | int | 每页数量 | |
page | int | 页码 |
curl -i -X POST https://api3.verycloud.cn/API/instance/list -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "limit": 30, "page": 1}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "1718856450",
"instance_id": "i-xiexasa5",
"name": "test name",
"cpu": {
"id": "1",
"volume": "1"
},
"mem": {
"id": "2",
"volume": "1024"
},
"image": {
"id": "9",
"osname": "Ubuntu-14.04-x64"
},
"network": {
"id": "9",
"line": "1"
},
"networkvalue": "0",
"diskvalue": "30",
"ips": [
"10.0.0.1"
],
"firewall": {
"id": "59",
"firewall_id": "sg_lqytc5ga"
},
"net": {
"id": "93",
"vxnet_id": "vxnet-vxrxjskh"
},
"status": "1",
"paytype": "1",
"innerip": "172.16.1.11",
"mac": "0E:E0:9F:C6:E3:48",
"createtime": "2015-03-11 8:57",
"createtime_ago": "5天前",
"nodeid": "3",
"nodename": "t1",
"node_zh": "江阴1区",
"note": "test note",
"instanceid": "111",
"mark": "1",
"suspend_note": "欠费"
}
],
"limit": 30,
"page": 1,
"total": 1,
"totalpage": 1
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
name | string | 云主机名称 | |
nodeid | int | 数据中心ID | |
type | int | 计费方式 1按需 2包月 3包年 | |
cpuid | int | CPU套餐ID | |
memid | int | 内存套餐ID | |
imageid | int | 镜像ID | |
networkid | int | 线路ID 1内网线路 2电信线路 3联通线路 4 移动线路 5 BGP线路 6双线 | |
networkvalue | int | 带宽值 如果是公网线路 则必须 | |
diskvalue | int | 硬盘大小 | |
pass | string | 管理员密码 | |
num | int | 申请数量 | |
couponprice | decimal | 代金券支付金额 只有包年、包月才能使用代金券 | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/create -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "name": "测试", "nodeid": 9876543210, "type": 1, "cpuid": 9876543210, "memid": 9876543210, "imageid": 9876543210, "networkid": 1, "networkvalue": 0, "diskvalue": 30, "pass": "example", "num": 1, "couponprice": 0, "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"data": {
"instance_id": "i-230x2mmn"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
is_change_pass | int | 是否修改密码 1修改 0 不修改 | |
password | string | 新密码,当is_change_pass为1时,必选 |
curl -i -X POST https://api3.verycloud.cn/API/instance/restore -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60","id": 1234567890, "is_change_pass": 1, "password": "example"}'
{
"code": 1,
"message": "操作成功",
"data": {
"instance_id": "i-230x2mmn",
"name": ""
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | string | 云主机ID,多个用“,”隔开 |
curl -i -X POST https://api3.verycloud.cn/API/instance/delete -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": "1234567890,9876543210"}'
{
"code": 1,
"message": "云主机已放入回收站,将为您保留2小时",
"data": {
"instance_id": "i-230x2mmn",
"name": ""
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
paytype | int | 计费方式 1按需 2包月 3包年 | |
cpuid | int | CPU套餐ID | |
memid | int | 内存套餐ID | |
networkvalue | int | 带宽值 | |
diskresize | string | 硬盘扩容大小,格式:硬盘ID和硬盘容量用“,”隔开,多块硬盘用“;”隔开,如:1,100;2,50;3,150表示三块硬盘ID分别是1、2、3,分别扩容100G、50G、150G |
curl -i -X POST https://api3.verycloud.cn/API/instance/upgrade -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60","id": 1234567890, "paytype": 2, "cpuid": 1234567890, "memid": 1234567890, "networkvalue": 0, "diskresize": "1,100;2,200"}'
{
"code": 1,
"message": "操作完成",
"data": {
"instance_id": "i-230x2mmn",
"name": ""
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
name | string | 名称 | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/updateBasicinfo -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "name": "测试", "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"data": {
"instance_id": "i-230x2mmn",
"name": "测试",
"note": "备注"
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | string | 云主机ID,多个用“,”隔开 | |
op | string | 操作 start开机 stop关机 reset重启 |
curl -i -X POST https://api3.verycloud.cn/API/instance/update -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": "1234567890,9876543210", "op": "start"}'
{
"code": 1,
"message": "操作完成",
"data": {
"instance_id": "i-230x2mmn",
"name": "",
"status": 1
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
mark | int | 星标状态 0 取消星标 1 设置星标 默认为0 |
curl -i -X POST https://api3.verycloud.cn/API/instance/mark -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "mark": 1}'
{
"code": 1,
"message": "操作完成",
"data": {
"instance_id": "i-230x2mmn",
"name": "",
"mark": 1
},
"created": "2015-10-25 12:20:36"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/vncproxy -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890}'
{
"code": 1,
"message": "操作成功",
"created": "2015年03月18日 15:04:28",
"data": {
"host": "58.215.133.195",
"port": "5900",
"ticket": "PVEVNC:5509237C::f9NZ74LkxGYOcIp7oUKyM6gZfbq1yT9/4ezgiMGwHQKuOKAruNxAWmDlq5MGKxyvS23LuvkZjlbkYzJk9nVNAbwV2q4K8QMMYc6cUJbS1yH/apxB5qT/uKQPJ9EXGqcvMCnbnX3+75gLG5BEWwOryIfrJdJKTsYnKuhwsLf+UCE+ntIf3M0Xp/5JxQ2wFd0Y54RW7kiACmqHWllv7AIC9p5mPy1KNVFai8FyCbaYLGzC5vI2Wl/rVVc4Yn+6DrzR+vwLtZvfp4tElMKuNoYyLDiLIHgXAACgJvOwP49wCpFXr4ZZmIpI4WDQupidLXLnSZFAZqM3PYz4rPSMpfTTtg==",
"verytoken": "5509237C:NzU5NWM5ZDViM2YyZGU5MjIyYjU4YTkwYzlkM2Y4YjA="
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
key | string | 组合键 |
curl -i -X POST https://api3.verycloud.cn/API/instance/sendkey -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "key": "tab"}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 15:08:54"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 云主机ID | |
type | string | 监控类型,hour小时, day天,week周,month月,year年,如果该参数不传,则默认为hour | |
resultType | int | 是否格式化输出,1格式化,如果不传或者为0,则不格式化输出 |
curl -i -X POST https://api3.verycloud.cn/API/instance/monitor -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "type": "hour"}'
{
"code": 1,
"message": "操作成功",
"created": "2015年03月18日 15:13:19",
"data": {
"cpu": [
[
1426658640000,
0.13
],
[
1426658640000,
0.13
]
]
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
iid | int | 云主机ID | |
status | int | 状态 0已绑定 1可用 2回收站 | |
page | int | 页码 默认 1 | |
limit | int | 每页条数 默认 30 |
curl -i -X POST https://api3.verycloud.cn/API/instance/diskList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "iid": 1234567890}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "1234562500",
"iid": "1565052536",
"type": "1",
"disk_id": "loc-3ziytvyi",
"disk_name": "",
"value": "30",
"createtime": "2015/03/18 12:56",
"createtime_ago": "2小时前",
"updatetime": "2015/03/18 12:56",
"updatetime_ago": "2小时前"
}
],
"limit": 30,
"page": 1,
"totalpage": 1,
"total": 1,
"created": "2015年03月18日 15:35:38"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 硬盘ID | |
value | int | 硬盘大小 |
curl -i -X POST https://api3.verycloud.cn/API/instance/diskResize -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "value": 80}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 15:31:16",
"data": {
"iid": "1564881245",
"instance_id": "i-sxri5gl4",
"disk_id": "vol-iwuk0ogn",
"value": 80
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
iid | int | 云主机ID | |
status | int | 状态 0备份中 1备份完成 2备份失败 3欠费 4回收站 | |
page | int | 页码 | |
limit | int | 每页数量 |
curl -i -X POST https://api3.verycloud.cn/API/instance/backupList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "limit": 30, "page": 1}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "123456789",
"backup_id": "b_np3kmqdv",
"instance": {
"id": "1564431234",
"instance_id": "i-jnxhz2v5",
"name": "test2-2",
"status": "1"
},
"name": "asdfadsf",
"backup_type": "1",
"value": "0.33",
"status": "1",
"progress": "",
"note": "asdfadf",
"createtime": "2015/03/17 14:27",
"createtime_ago": "1天前"
}
],
"limit": 30,
"page": 1,
"totalpage": 1,
"total": 1,
"created": "2015年03月18日 16:57:11"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
iid | int | 云主机ID | |
name | string | 名称 | |
backup_type | int | 备份类型 1系统备份 2系统和数据备份 | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/backupAdd -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "iid": 1234567890, "name": "测试", "backup_type": 1, "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 16:41:19",
"data": {
"instance_id": "i-nh0qseft",
"name": "",
"backup_id": "ss_o1krhmyc",
"snaphsot_name": "测试",
"note": "备注"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 备份ID | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/backupUpdate -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 17:02:26",
"data": {
"instance_id": "i-jnxhz2v5",
"backup_id": "b_np3kmqdv",
"name": "测试",
"note": "测试"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 备份ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/backupDelete -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890}'
{
"code": 1,
"message": "备份已放入回收站,将为您保留2小时",
"created": "2015年03月18日 17:09:12",
"data": {
"instance_id": "i-jnxhz2v5",
"name": "测试",
"backup_id": "b_np3kmqdv"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 备份ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/backupRestore -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 17:06:12",
"data": {
"instance_id": "i-jnxhz2v5",
"backup_id": "b_np3kmqdv",
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
iid | int | 云主机ID | |
page | int | 页码 | |
limit | int | 每页数量 |
curl -i -X POST https://api3.verycloud.cn/API/instance/snapshotList -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "limit": 30, "page": 1}'
{
"code": 1,
"message": "操作完成",
"data": [
{
"id": "1234567890",
"snapshot_id": "ss_ohsgxaoe",
"instance": {
"id": "9876543210",
"instance_id": "i-nh0qseft",
"name": "",
"status": "1"
},
"name": "dfgsdfgdfg",
"status": "1",
"note": "",
"createtime": "2015/03/18 16:33",
"createtime_ago": "8秒前",
"updatetime": "2015/03/18 16:33"
}
],
"limit": 30,
"page": 1,
"totalpage": 1,
"total": 1,
"created": "2015年03月18日 16:34:05"
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
iid | int | 云主机ID | |
name | string | 名称 | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/snapshotAdd -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "iid": 1234567890, "name": "测试", "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 16:41:19",
"data": {
"instance_id": "i-nh0qseft",
"name": "",
"snapshot_id": "ss_o1krhmyc",
"snaphsot_name": "测试",
"note": "备注"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 快照ID | |
note | string | 备注 |
curl -i -X POST https://api3.verycloud.cn/API/instance/snapshotUpdate -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890, "note": "备注"}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 16:44:29",
"data": {
"instance_id": "i-nh0qseft",
"snapshot_id": "ss_o1krhmyc",
"name": "测试",
"note": "备注修改"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 快照ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/snapshotDelete -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 16:48:28",
"data": {
"instance_id": "i-nh0qseft",
"snapshot_id": "ss_ohsgxaoe",
"name": "dfgsdfgdfg"
}
}
名称 | 类型 | 必须 | 说明 |
---|---|---|---|
token | string | 密钥 | |
id | int | 快照ID |
curl -i -X POST https://api3.verycloud.cn/API/instance/snapshotRollback -H "Accept: application/json" -H "Content-Type: application/json; charset=utf-8" -d '{"token": "5d8531de68ae272eacb8670afe084d60", "id": 1234567890}'
{
"code": 1,
"message": "操作完成",
"created": "2015年03月18日 16:50:34",
"data": {
"instance_id": "i-nh0qseft",
"snapshot_id": "ss_o1krhmyc",
"name": "测试"
}
}