智简魔方文档

PUT 保存设置

接口概览

项目内容
文档类型后台接口
请求方式PUT
接口地址/DIR_ADMIN/v1/mf_cloud/config
所属业务模块
来源模块/系统魔方云(自定义配置)
认证方式Bearer Token(管理员令牌)

完整请求

请求

bash
正在加载示例…

失败请求

bash
正在加载示例…

接口说明

保存设置

请求体

json
正在加载示例…

请求参数

名称位置类型必选说明
bodybodyobject是—
product_idbodyinteger(int32)是商品 ID
typebodystring是类型(host=KVM加强版,lightHost=KVM轻量版,hyperv=Hyper-V)
node_prioritybodyinteger(int32)是开通平衡规则(1=数量平均,2=负载最低,3=内存最低,4=填满一个)
ip_mac_bindbodyinteger(int32)否嵌套虚拟化(0=关闭,1=开启)
support_ssh_keybodyinteger(int32)否是否支持SSH密钥(0=关闭,1=开启)
rand_ssh_portbodyinteger(int32)是SSH端口设置(0=默认,1=随机端口,2=指定端口,3=用户自定义)
support_normal_networkbodyinteger(int32)否经典网络(0=不支持,1=支持)
support_vpc_networkbodyinteger(int32)否VPC网络(0=不支持,1=支持)
support_public_ipbodyinteger(int32)否是否允许公网 IP(0=不支持,1=支持)
backup_enablebodyinteger(int32)是是否启用备份(0=不启用,1=启用)
snap_enablebodyinteger(int32)否是否启用快照(0=不启用,1=启用)
reinstall_sms_verifybodyinteger(int32)是重装短信验证(0=不启用,1=启用)
reset_password_sms_verifybodyinteger(int32)是重置密码短信验证(0=不启用,1=启用)
niccardbodyinteger(int32)否网卡驱动(0=默认,1=Realtek 8139,2=Intel PRO/1000,3=Virtio)
cpu_modelbodyinteger(int32)否CPU模式(0=默认,1=host-passthrough,2=host-model,3=custom)
ipv6_numbodystring否IPV6 数量
nat_acl_limitbodystring否NAT转发限制
nat_web_limitbodystring否NAT建站限制
default_nat_aclbodyinteger(int32)否默认NAT转发(0=关闭,1=开启)
default_nat_webbodyinteger(int32)否默认NAT建站(0=关闭,1=开启)
backup_databody[object]否允许备份数量数据
backup_data.numbodyinteger(int32)否数量
backup_data.pricebodynumber(double)否价格
backup_data.on_demand_pricebodynumber(double)否按需价格
snap_databody[object]否允许快照数量数据
snap_data.numbodyinteger(int32)否数量
snap_data.pricebodynumber(double)否价格
snap_data.on_demand_pricebodynumber(double)否按需价格
resource_packagebody[object]否资源包数据
resource_package.ridbodyinteger(int32)否魔方云资源包 ID
resource_package.namebodystring否资源包名称
rand_ssh_port_startbodystring否随机端口开始端口,rand_ssh_port=1时必填
rand_ssh_port_endbodystring否随机端口结束端口,rand_ssh_port=1时必填
rand_ssh_port_windowsbodystring否指定端口Windows,rand_ssh_port=2时必填
rand_ssh_port_linuxbodystring否指定端口Linux,rand_ssh_port=2时必填
default_one_ipv4bodyinteger(int32)是默认携带 IPV4(0=关闭,1=开启)
manual_managebodyinteger(int32)是手动管理商品(0=关闭,1=开启)
duration_idbody[integer]否不允许申请停用周期 ID
custom_rand_password_rulebodystring否自定义随机密码位数(0=关闭,1=开启)
default_password_lengthbodystring否默认密码长度
level_discount_cpu_orderbodyinteger(int32)是CPU是否应用等级优惠订购(0=不启用,1=启用)
level_discount_cpu_upgradebodyinteger(int32)是CPU是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_cpu_renewbodyinteger(int32)是CPU是否应用等级优惠续费(0=不启用,1=启用)
level_discount_memory_orderbodyinteger(int32)是内存是否应用等级优惠订购(0=不启用,1=启用)
level_discount_memory_upgradebodyinteger(int32)是内存是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_memory_renewbodyinteger(int32)是内存是否应用等级优惠续费(0=不启用,1=启用)
level_discount_bw_orderbodyinteger(int32)是带宽是否应用等级优惠订购(0=不启用,1=启用)
level_discount_bw_upgradebodyinteger(int32)是带宽是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_bw_renewbodyinteger(int32)是带宽是否应用等级优惠续费(0=不启用,1=启用)
level_discount_ipv4_orderbodyinteger(int32)是IPV4 是否应用等级优惠订购(0=不启用,1=启用)
level_discount_ipv4_upgradebodyinteger(int32)是IPV4 是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_ipv4_renewbodyinteger(int32)是IPV4 是否应用等级优惠续费(0=不启用,1=启用)
level_discount_ipv6_orderbodyinteger(int32)是IPV6 是否应用等级优惠订购(0=不启用,1=启用)
level_discount_ipv6_upgradebodyinteger(int32)是IPV6 是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_ipv6_renewbodyinteger(int32)是IPV6 是否应用等级优惠续费(0=不启用,1=启用)
level_discount_system_disk_orderbodyinteger(int32)是系统盘是否应用等级优惠订购(0=不启用,1=启用)
level_discount_system_disk_upgradebodyinteger(int32)是系统盘是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_system_disk_renewbodyinteger(int32)是系统盘是否应用等级优惠续费(0=不启用,1=启用)
level_discount_data_disk_orderbodyinteger(int32)是数据盘是否应用等级优惠订购(0=不启用,1=启用)
level_discount_data_disk_upgradebodyinteger(int32)是数据盘是否应用等级优惠升降级(0=不启用,1=启用)
level_discount_data_disk_renewbodyinteger(int32)是数据盘是否应用等级优惠续费(0=不启用,1=启用)
simulate_physical_machine_enablebodyinteger(int32)是模拟物理机运行(0=关闭,1=开启)
show_panel_password_enablebodyinteger(int32)是前台显示面板密码(0=关闭,1=开启)
network_orderbodyinteger(int32)否网络排序(0=先经典网络后VPC网络,1=先VPC网络后经典网络)

成功响应

json
正在加载示例…

失败响应 400:请求参数或业务校验失败

json
正在加载示例…

失败响应 401:未认证或登录已失效

json
正在加载示例…

失败响应 403:无权执行当前操作

json
正在加载示例…

失败响应 404:接口或业务资源不存在

json
正在加载示例…

失败响应 500:服务器内部错误

json
正在加载示例…

响应状态

状态码状态码含义说明数据模型
200OK成功响应内联对象
400Bad Request请求参数或业务校验失败内联对象
401Unauthorized未认证或登录已失效内联对象
403Forbidden无权执行当前操作内联对象
404Not Found接口或业务资源不存在内联对象
500Internal Server Error服务器内部错误内联对象

响应参数

状态码 200

名称类型必选约束说明
statusinteger(int32)否—状态码
msgstring否—提示信息
dataobject否——
data.level_discount_gpu_orderinteger(int32)否—GPU是否应用等级优惠订购(0=不启用,1=启用)
data.level_discount_gpu_upgradeinteger(int32)否—GPU是否应用等级优惠升降级(0=不启用,1=启用)

失败状态码 400、401、403、404、500 共用以下结构:

名称类型必选约束说明
statusinteger(int32)是—错误状态码
msgstring是—错误提示