更新主机资源

接口URL

/api/v1/resource/host

请求方式

PUT

Content-Type

application/json

认证方式

Bearer auth

请求Header参数

参数名 示例值 参数类型 是否必填 参数描述
Accept application/json Text -
Content-Type application/json Text -

请求Body参数

{
    "IP": "172.17.0.15",
    "UserName": "root",
    "Password": "******",
    "HostName": "",
    "SSHPort": 22,
    "OS": "CentOS Linux 8",
    "CpuArch": "aarch64",
    "CpuModel": "Kunpeng-920",
    "CpuCores": 64,
    "Memory": 190,
    "Storage": 7375,
    "DiskType": "SSD",
    "Location": "",
    "Tag": "tag1"
}
参数名 示例值 参数类型 是否必填 参数描述
IP 172.17.0.15 String IP 地址
UserName root String 用户名
Password ** String 密码
SSHPort 22 Integer SSH 端口
OS CentOS Linux 8 String 操作系统
CpuArch aarch64 String CPU 架构 [x86_64/aarch64]
CpuModel Kunpeng-920 String CPU 型号
CpuCores 64 Integer CPU 核心数量
Memory 190 Integer 内存容量,单位 GB
Storage 7375 Integer 存储容量,单位 GB
DiskType SSD String 磁盘类型 [HDD/SSD]
Location - String 主机位置
Tag tag1 String 主机标签

成功响应示例

{
    "Data": {
        "ID": 0,
        "CreatedAt": "0001-01-01T00:00:00Z",
        "UpdatedAt": "2023-09-21T12:13:16.554+08:00",
        "DeletedAt": null,
        "IP": "172.17.0.15",
        "UserName": "root",
        "Password": "******",
        "HostName": "",
        "SSHPort": 22,
        "Status": "",
        "OS": "CentOS Linux 8",
        "CpuArch": "aarch64",
        "CpuModel": "Kunpeng-920",
        "CpuCores": 64,
        "Memory": 190,
        "Storage": 7375,
        "DiskType": "SSD",
        "Stat": "",
        "FreeStorage": 0,
        "FreeCpuCores": 0,
        "FreeMemory": 0,
        "ClusterID": "",
        "NodeExporterPort": 0,
        "Location": "",
        "Tag": "tag1",
        "HostType": "",
    },
    "Success": true
}
参数名 示例值 参数类型 参数描述
Data - Object
Data.ID 0 Integer ID 编号
Data.UpdatedAt 2023-09-21T12:13:16.554+08:00 String 更新时间
Data.IP 172.17.0.15 String IP 地址
Data.UserName root String 用户名
Data.Password ** String 密码
Data.SSHPort 22 Integer SSH 端口号
Data.Status - String 主机状态
Data.OS CentOS Linux 8 String 操作系统
Data.CpuArch aarch64 String CPU 架构
Data.CpuModel Kunpeng-920 String CPU 型号
Data.CpuCores 64 Integer CPU 核心数量
Data.Memory 190 Integer 内存大小,单位 GB
Data.Storage 7375 Integer 存储空间,单位 GB
Data.DiskType SSD String 磁盘类型 [HDD/SSD]
Data.Location - String 主机位置
Data.Tag tag1 String 主机标签
Success true Boolean
© 2024 平凯星辰(北京)科技有限公司 all right reserved,powered by GitbookFile Modify: 2024-04-02 15:37:04

results matching ""

    No results matching ""