跳至内容
景安API接口wiki
用户工具
注册
登录
站点工具
工具
显示页面
修订记录
最近更改
媒体管理器
网站地图
登录
注册
最近更改
媒体管理器
网站地图
您的足迹:
start:aliyunhost
本页面只读。您可以查看源文件,但不能更改它。如果您觉得这是系统错误,请联系管理员。
======阿里云服务器接口====== =====1、购买阿里云服务器===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost(必填)|产品类型| |tid|int|1(购买)(必填)|交易id| |region|string|例:cn-hangzhou等(必填)|地域| |zone|string|例:cn-hangzhou-i等(可通过tid=75接口获取zoneId)(必填)|地区| |zoneName|string|例:华东1可用区等(可通过tid=75接口获取localName)(必填)|地区名称| |instanceType|string|例:ecs.c6.large等(可通过tid=77接口获取instanceTypeId)(必填)|实例机型| |instanceModel|string|例:ecs.c6等(可通过tid=77接口获取instanceTypeFamily)(必填)|实例类型| |imageName|string|例:CentOS 7.7 64位等(可通过tid=78接口获取OSName)(必填)|系统名称| |imageId|string|例:centos_7_7_x64_20G_alibase_20200426.vhd等(可通过tid=78接口获取imageId)(必填)|系统镜像ID| |cpucount|int|1,2,4,8,16等(必填)|cpu数量(tid=77里的cpuCoreCount)| |memory|int|1,2,4,8,12等(必填)|内存大小G(tid=77里的memorySize)| |systemDiskType|string|cloud_efficiency:高效云盘。\\ cloud_ssd:SSD云盘。\\ cloud_essd:ESSD云盘。\\ cloud:普通云盘。\\ (必填)|系统盘类型| |sysdisk|int|20 - 500(必填)|系统盘大小(G)| |dataDiskType|string|cloud_efficiency:高效云盘。\\ cloud_ssd:SSD云盘。\\ ephemeral_ssd:本地SSD盘。\\ cloud_essd:ESSD云盘。\\ cloud:普通云盘。\\ (必填)|数据盘类型| |disk|int|cloud_efficiency:20~32768。\\ cloud_ssd:20~32768。\\ cloud_essd:20~32768。\\ ephemeral_ssd:5~800。\\ cloud:5~2000。\\ (必填)|数据盘大小(G)| |bandwidth|int|0-100(每次递增单位:1M)(必填)|网络带宽(Mbps)| |priceUnit|string|Week:周 Month:月 Year:年(必填)|时间单位| |yid|int|Week时:1 Month时:1,2,3,6 Year时:1(必填)|购买时长| |password|string|至少包含三个数字三个大写字母三个小写字母(必填)|系统密码| |email|string|符合邮箱格式|邮箱| ===XML返回值格式=== <file> <? XML version="1.0" encoding="UTF-8" ?> <result> <code>0</code> <info> <ywddh>业务订单号</ywddh> </info> </result> </file> ===JSON返回值格式=== <file> { "code":"0" , "info": { "ywddh": 订单编号 } } </file> 备注: 地域region取值:\\ cn-hangzhou:华东 1(杭州)\\ cn-qingdao:华北 1(青岛)\\ cn-beijing:华北 2(北京)\\ cn-zhangjiakou:华北 3(张家口)\\ cn-huhehaote:华北 5(呼和浩特)\\ cn-shanghai:华东 2(上海)\\ cn-shenzhen:华南 1(深圳)\\ cn-heyuan:华南 2(河源)\\ cn-chengdu:西南 1(成都)\\ cn-hongkong:中国(香港)\\ ap-southeast-1:新加坡\\ ap-southeast-2:澳大利亚(悉尼)\\ ap-southeast-3:马来西亚(吉隆坡)\\ ap-southeast-5:印度尼西亚(雅加达)\\ ap-northeast-1:日本(东京)\\ us-west-1:美国(硅谷)\\ us-east-1:美国(弗吉尼亚)\\ eu-central-1:德国(法兰克福)\\ eu-west-1:英国(伦敦)\\ me-east-1:阿联酋(迪拜)\\ ap-south-1:印度(孟买)\\ =====2、开通阿里云服务器===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost(必填)|产品类型| |tid|int|2(开通)(必填)|交易id| |did|int| 123456(必填)|订单编号| ===XML返回值格式=== <file> <?xml version="1.0" encoding="UTF-8" ?> <result> <code>0</code> <info> <overDate>2017-05-25 22:14:46</overDate> <pwd>GaintUI0903</pwd> <createDate>2017-05-23 22:14:46</createDate> <user>administrator</user> <bid>12345</bid> <slid>i-bp1381lqprzs2r...</slid> </info> </result> </file> ===JSON返回值格式=== <file> { "code":0, "info":{"overDate":"2017-05-25 22:14:46","pwd":"GaintUI0903","createDate":"2017-05-23 22:14:46","user":"administrator","bid":12345,"slid":"i-bp1381lqprzs2r..."} } </file> =====3、根据地域获取可用地区===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost(必填)|产品类型| |tid|int|75|交易id(必填)| |region|string|cn-hangzhou等(必填) |地域| ===XML返回值格式=== <file> <? XML version="1.0" encoding="UTF-8" ?> <result> <code>0</code> <info> <localName>华东 1 可用区</localName> <zoneId>cn-hangzhou-i</zoneId> </info> </result> </file> ===JSON返回值格式=== <file> { "code":"0", "info":[{"localName":"华东 1 可用区","zoneId":"cn-hangzhou-i"}] } </file> =====4、根据地域获取实力机型===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost(必填)|产品类型| |tid|int|77|交易id(必填)| |region|string|cn-hangzhou等(必填) |地域| ===XML返回值格式=== <file> <? XML version="1.0" encoding="UTF-8" ?> <result> <code>0</code> <info> <cpuCoreCount>2</cpuCoreCount> <memorySize>4</memorySize> <instanceTypeFamily>ecs.s2</instanceTypeFamily> <instanceTypeId>ecs.s2.large</instanceTypeId> </info> </result> </file> ===JSON返回值格式=== <file> { "code":"0", "info":[{ "cpuCoreCount":"2", "memorySize":"4", "instanceTypeFamily":"ecs.s2", "instanceTypeId":"ecs.s2.large" }] } </file> =====5、根据实例机型获取可用镜像===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost|产品类型| |tid|int|78|交易id| |region|string|cn-hangzhou等 |地域| |instanceType|string|ecs.s2.large等 |实例机型| ===JSON返回值格式=== <file> { "code":"0", "info": [{"platform":"CentOS","imageArray":[{"OSName":"CentOS 7.7 64位","OSNameEn":"CentOS 7.7 64 bit","OSType":"linux","architecture":"x86_64","creationTime":"2020-04-27T15:58:18Z","description":"","diskDeviceMappings":[],"imageId":"centos_7_7_x64_20G_alibase_20200426.vhd","imageName":"centos_7_7_x64_20G_alibase_20200426.vhd","imageOwnerAlias":"system","imageVersion":"","isCopied":false,"isSelfShared":"","isSubscribed":false,"isSupportCloudinit":true,"isSupportIoOptimized":true,"platform":"CentOS","productCode":"","progress":"100%","resourceGroupId":"","size":20,"status":"Available","tags":[],"usage":"instance"}}] }] } </file> =====6、根据配置获取价格===== ^参数^参数类型^参数值^参数描述^ |ptype|string|aliyunhost(必填)|产品类型| |tid|int|33|交易id(必填)| |region|string|cn-hangzhou等 (必填)|地域| |instanceType|string|ecs.s2.large等(必填) |实例机型| |imageId|string|例:centos_7_7_x64_20G_alibase_20200426.vhd等(可通过tid=78接口获取imageId)(必填)|系统镜像ID| |systemDiskType|string|cloud_efficiency:高效云盘。\\ cloud_ssd:SSD云盘。\\ cloud_essd:ESSD云盘。\\ cloud:普通云盘。\\ (必填)|系统盘类型| |sysdisk|int|20 - 500(必填)|系统盘大小(G)| |dataDiskType|string|cloud_efficiency:高效云盘。\\ cloud_ssd:SSD云盘。\\ ephemeral_ssd:本地SSD盘。\\ cloud_essd:ESSD云盘。\\ cloud:普通云盘。\\ (必填)|数据盘类型| |disk|int|cloud_efficiency:20~32768。\\ cloud_ssd:20~32768。\\ cloud_essd:20~32768。\\ ephemeral_ssd:5~800。\\ cloud:5~2000。\\ (必填)|数据盘大小(G)| |bandwidth|int|0-100(每次递增单位:1M)(必填)|网络带宽(Mbps)| |priceUnit|string|Week:周 Month:月 Year:年(必填)|时间单位| |yid|int|Week时:1 Month时:1,2,3,6 Year时:1(必填)|购买时长| ===XML返回值格式=== <file> <? XML version="1.0" encoding="UTF-8" ?> <result> <code>0</code> <info> 231.0 </info> </result> </file> ===JSON返回值格式=== <file> { "code":"0", "info": { 231.0 } } </file>
start/aliyunhost.txt
· 最后更改: 2020/05/26 10:49 (外部编辑)
页面工具
显示页面
修订记录
回到顶部