华为云用户手册

  • 响应示例 返回状态码为200:删除成功,响应体参考AddressSetResponse。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "success" : [ { "id" : "000000-0000-0000-0000-000000000000", "name" : "test_1", "description" : "XXX", "priority" : 50, "attackDefenseEnable" : false, "isDefault" : false } ], "fail" : [ { "errcode" : "0x00c8000c", "errmsg" : "The parameter is invalid.", "data" : { "id" : "000000-0000-0000-0000-000000000000", "name" : "test_1", "description" : "XXX", "priority" : 50, "attackDefenseEnable" : false, "isDefault" : false } } ] } 返回状态码为400:请求参数错误。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:内部错误。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 PUT /restconf/v2/data/huawei-ac-nes-device:nes/ne/00000000-0000-0000-0000-000000000000/huawei-nce-e-cli:command-aliases/command-alias HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-AC CES S-TOKEN: x-yyyyyy restconf-transaction-id: "00000000-0000-0000-0000-000000000000" { "huawei-nce-e-cli:command-alias" : [ { "alias" : "test1", "command" : "test2", "parameter" : "$test3" } ] }
  • 响应示例 返回状态码为200:操作成功。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为400:请求参数错误。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:内部错误。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • URI /restconf/v2/data/huawei-ac-nes-device:nes/ne/{id}/huawei-nce-e-cli:command-aliases/command-alias 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 id 是 string 36个字符。满足正则表达[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}。 - 设备ID。 "00000000-0000-0000-0000-000000000000"
  • 请求参数 表2 header参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 restconf-transaction-id 否 string - - 事务ID。 "00000000-0000-0000-0000-000000000000" 表3 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 command-alias 是 REFERENCE 详细请参见表4。 别名实例。 - 表4 command-aliases-exactProperties-command-alias-augment对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 huawei-nce-e-cli:command-alias 否 ARRAY_REFERENCE 详细请参见表5。 别名实例。 - 表5 command-aliases-exactProperties-command-alias对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 alias 否 string 1~63个字符。满足正则表达[a-zA-Z][a-zA-Z0-9-]*。 - 指定别名。必填,支持大、小写字母,数字及连字符"-",字母开头,不区分大小写,字符间不能有空格。别名定义出现循环嵌套或嵌套层次超过16层时,该别名节点无效,不会用于进行字符串替换。单一主键字段。 "test1" command 是 string 1~511个字符。满足正则表达[^?]+。 - 指定别名命令行。必填,不支持英文问号,如果字符之间有空格,则字符串外必须使用双引号。指定别名参数配置后,必须在指定别名命令行里面包含进去。例如参数包含$a,则命令行格式应该为$a,"$a","xxx $a","xxx $a $xx"这样的形式。多个$参数必须连续保持在最后。 "test2" parameter 否 string 2~511个字符。 - 指定别名参数。支持大、小写字母,数字及连字符"-",必须以"$"符号开头,不区分大小写,取值范围是2~63,最多支持32个参数,参数之间以空格进行分隔。指定别名命令行配置后,必须在指定别名参数里面定义。例如命令行格式为$a,"$a","xxx $a","xxx $a $xx"这样的形式,则指定别名参数必须包含$a。 "$test3"
  • 响应示例 返回状态码为200:修改的防火墙设备静态路由配置。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "data" : { "mask" : 22, "destinationPrefixIp" : "10.20.0.0", "nextHopAddress" : "10.20.0.10", "nextInterface" : "GigabitEthernet0/0/4", "trackIplinkId" : "ae5813f8ff1e41f5ba9c324da70b49ca", "preference" : 5, "id" : "de5813f8ff1e41f5ba9c324da70b49ed" } } 返回状态码为400:校验失败信息。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 PUT /controller/campus/v1/networkservice/networkconfig/net/fwstaticroute/devices/fbb684c8-0d37-496f-bafa-4b06d5151e2e/staticroute HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "mask" : 22, "destinationPrefixIp" : "10.20.0.0", "nextHopAddress" : "10.20.0.10", "nextInterface" : "GigabitEthernet0/0/4", "trackIplinkId" : "ae5813f8ff1e41f5ba9c324da70b49ca", "preference" : 5, "id" : "de5813f8ff1e41f5ba9c324da70b49ed" }
  • 请求参数 表2 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 deviceFwStaticRouteInfoDto 是 REFERENCE 详细请参见表3。 修改的防火墙设备静态路由配置。 - 表3 DeviceFwStaticRouteInfoDto对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 mask 是 integer [0-32] - 掩码,不允许修改。 22 destinationPrefixIp 否 string 1~15个字符。 - 目的地址,必填。必须是合法的IPv4地址,以127或者224~255开头的IP地址为非法IP地址,不允许修改。 "10.20.0.0" nextHopAddress 否 string 0~15个字符。 - 下一跳地址,必须是合法的IPv4地址,以127或者224~255开头的IP地址为非法IP地址。当nextInterface为空时,nextHopAddress必填。 "10.20.0.10" nextInterface 否 string 0~32个字符。 - 设备出接口。当nextHopAddress为空时,nextInterface必填。 "GigabitEthernet0/0/4" trackIplinkId 否 string 0~32个字符。 - IP链接ID。 "ae5813f8ff1e41f5ba9c324da70b49ca" preference 否 integer [1-255] - 优先级。取值越小,优先等级越高,不填时默认为60。 5 id 是 string 0~32个字符。 - 防火墙静态路由ID。 "de5813f8ff1e41f5ba9c324da70b49ed"
  • URI /controller/campus/v1/networkservice/networkconfig/net/fwstaticroute/devices/{deviceId}/staticroute 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 deviceId 是 string 36个字符。 - 设备标识,UUID格式。 "fbb684c8-0d37-496f-bafa-4b06d5151e2e"
  • 请求参数 表2 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 requestDto 是 REFERENCE 详细请参见表3。 请求Dto - 表3 LedConfigRequest对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 ledOffEnable 是 boolean true false true 闪灯关闭配置开关参数,默认值为:true。 true timeTplEnable 是 boolean true false true 闪灯时间模板配置开关参数,默认值为:true。 true timeTplId 否 string 1~64个字符。 - 闪灯时间模板id,UUID格式。 "ea25fdbf-8dee-4823-bac2-5bfe8e3359ca"
  • 请求示例 HTTP的示例 PUT /v1/oam/config/sites/fbde1c5d-5b94-49e3-a912-48641015e45c/ledconfig HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "ledOffEnable" : true, "timeTplEnable" : true, "timeTplId" : "ea25fdbf-8dee-4823-bac2-5bfe8e3359ca" }
  • 响应参数 返回状态码为200:返回下发站点闪灯配置结果。 表4 LedConfigResult对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 0~64个字符。 - 错误码。 "0" errmsg string 0~256个字符。 - 错误信息。 "" 返回状态码为400:接口入参非法的返回体。 详细信息请参见实际响应消息体。 返回状态码为500:接口发生内部错误后的返回体。 详细信息请参见实际响应消息体。
  • 响应示例 返回状态码为200:返回下发站点闪灯配置结果。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "" } 返回状态码为400:接口入参非法的返回体。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:接口发生内部错误后的返回体。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 PUT /controller/campus/v1/networkservice/networkconfig/net/bootrom/site-templates/fbb684c8-0d37-496f-bafa-4b06d5151e2e/bootrom HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "passwd" : "Iam@example1", "oldPasswd" : "Iam@example1" }
  • 响应示例 返回状态码为200:配置的设备BootROM密码。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "" }
  • 请求参数 表2 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 bootRomDto 是 REFERENCE 详细请参见表3。 配置的设备BootROM密码。 - 表3 BootRomDto对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 passwd 否 password 8~255个字符。 - 该字段可能包含敏感信息和个人数据,请妥善做好保护。 V200版本的LSW设备新密码必须包含如下规则: 1.密码长度必须在8-80位。 2.密码必须满足复杂度,即至少包含英文大写字母(A~Z)、英文小写字母(a~z)、数字(0~9)、特殊字符(如!、@、#、$、%)等中的三种,不允许包含'、?和空格。 3.密码中不能包含两个以上连续的相同字符。 V600版本的LSW设备新密码必须包含如下规则: 1、长度限制 8~255 2、新旧密码不能相同 3、密码不包含空格 4、密码复杂度校验 小写字母 大写字母 数字 特殊字符至少包含两种 "Iam@example1" oldPasswd 否 password 8~255个字符。 - 该字段可能包含敏感信息和个人数据,请妥善做好保护。 V200版本的LSW设备不需要此字段,V600版本的LSW设备旧密码必须包含如下规则: 1、长度限制 8~255 2、新旧密码不能相同 3、密码不包含空格 4、密码复杂度校验 小写字母 大写字母 数字 特殊字符至少包含两种 "Iam@example1"
  • URI /controller/campus/v1/networkservice/networkconfig/net/bootrom/site-templates/{siteTemplateId}/bootrom 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 siteTemplateId 是 string 36个字符。 - 站点模板标识,UUID格式。 "fbb684c8-0d37-496f-bafa-4b06d5151e2e"
  • 请求示例 HTTP的示例 GET /v1/networkservice/hierarchy-template/template-groups/00000000-0000-0000-0000-000000000000/export HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json,application/octet-stream Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy
  • 响应示例 返回状态码为200:导出模板组成功。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json,application/octet-stream;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json,application/octet-stream;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "" } 返回状态码为500:内部错误。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json,application/octet-stream;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "" }
  • 请求示例 HTTP的示例 GET /controller/campus/v3/networkconfig/site-templates/fbde1c5d-5b94-49e3-a912-48641015e45c/snmp HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy
  • URI /controller/campus/v3/networkconfig/site-templates/{siteTemplateId}/snmp 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 siteTemplateId 是 string - - 站点模板标识,UUID格式。 "fbde1c5d-5b94-49e3-a912-48641015e45c"
  • 响应示例 返回状态码为200:站点模板SNMP配置结果,返回结构体参见SiteTemplateSnmpResponseDto。 HTTP/1.1 200 OK Date: Thu,13 Sep 2018 10:00:00 GMT Server: example-server Content-Type: application/json { "errcode" : "0", "errmsg" : "", "data" : { "snmpEnable" : true, "protocolVersion" : "V3", "groupName" : null, "userInfos" : [ { "snmpUserName" : "Huawei-Guest", "snmpPasswd" : "********", "snmpAuth":"********" } ], "aclIps" : [ "192.168.1.1" ], "trapEnable" : true, "targetHosts" : [ { "hostIp" : "192.168.2.2", "hostName" : "Huawei-Guest" } ], "updownTrapEnable" : true } } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:内部服务错误。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应示例 返回状态码为200:配置成功,响应体参考ConfigPolicyResponse。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "1", "errmsg" : "error", "success" : [ { "siteId" : "356da474-d2da-4a90-a119-e07408684e97" } ], "fail" : [ { "errcode" : "1", "errmsg" : "", "siteId" : "356da474-d2da-4a90-a119-e07408684e97" } ] } 返回状态码为400:请求参数错误,无响应体。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:服务内部错误,无响应体。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应参数 返回状态码为200:配置成功,响应体参考ConfigPolicyResponse。 表4 ConfigPolicyResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 0~10个字符。 - 错误码。 "1" errmsg string - - 错误信息。 "error" success ARRAY_REFERENCE 1-10个列表项,详细请参见表5。 策略下发成功的站点的信息列表。 - fail ARRAY_REFERENCE 1-10个列表项,详细请参见表6。 策略下发失败的站点的信息列表。 - 表5 SuccessBean对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 siteId string 36个字符。 - 站点标识,UUID格式。 "356da474-d2da-4a90-a119-e07408684e97" 表6 FailBean对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 0~10个字符。 - 错误码。 "1" errmsg string - - 错误信息。 "" siteId string 36个字符。 - 站点标识,UUID格式。 "356da474-d2da-4a90-a119-e07408684e97" 返回状态码为400:请求参数错误,无响应体。 详细信息请参见实际响应消息体。 返回状态码为500:服务内部错误,无响应体。 详细信息请参见实际响应消息体。
  • 请求示例 HTTP的示例 POST /controller/campus/v1/oamservice/saupgrade/sites HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "configUpgradePolicyDto" : [ { "siteId" : "356da474-d2da-4a90-a119-e07408684e97", "upgradeRegularly" : true, "upgradeImmediately" : false, "upgradeDay" : "Sunday", "upgradeTime" : "00:00", "signatureDatabaseTypes" : ["ip-reputation","antivirus"] } ] }
  • 响应示例 返回状态码为200:查询随流检测支持设备数据成功后的状态返回码。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "Success", "total" : 0, "deviceInfos" : [ { "deviceId" : "9a157da3-9e59-41c9-8312-254a38a3b275", "deviceName" : "设备名称", "deviceType" : "AR", "esn" : "9a157da3-9e59-41c9-8312-254a38a3b275", "siteId" : "9a157da3-9e59-41c9-8312-254a38a3b276", "siteName" : "name" } ] } 返回状态码为400:查询随流检测支持设备数据失败后的状态返回码。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:接口发生内部错误后的状态返回码。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 POST /v1/performanceservice/flow/support-devices HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "siteId" : "9a157da3-9e59-41c9-8312-254a38a3b276", "pageIndex" : 0, "pageSize" : 5, "keyword" : "test" }
  • 响应参数 返回状态码为200:查询随流检测支持设备数据成功后的状态返回码。 表3 SupportInfoOutput对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 0~64个字符。 - 错误码。 "0" errmsg string 0~256个字符。 - 错误信息。 "Success" total int32 - 0 设备总数 0 deviceInfos ARRAY_REFERENCE 0-20000个列表项,详细请参见表4。 设备信息 - 表4 DeviceInfoData对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 deviceId string 0~36个字符。 - 设备id "9a157da3-9e59-41c9-8312-254a38a3b275" deviceName string 0~256个字符。 - 设备名称 "设备名称" deviceType string 0~4个字符。 - 设备款型 "AR" esn string 0~64个字符。 - 设备esn "9a157da3-9e59-41c9-8312-254a38a3b275" siteId string 0~36个字符。 - 站点id "9a157da3-9e59-41c9-8312-254a38a3b276" siteName string 0~256个字符。 - 站点名称 "name" 返回状态码为400:查询随流检测支持设备数据失败后的状态返回码。 详细信息请参见实际响应消息体。 返回状态码为500:接口发生内部错误后的状态返回码。 详细信息请参见实际响应消息体。
  • 请求参数 表1 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 supportDeviceInput 否 REFERENCE 详细请参见表2。 随流检测支持设备查询 - 表2 SupportDeviceInput对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 siteId 否 string 0~36个字符。 - 站点id "9a157da3-9e59-41c9-8312-254a38a3b276" pageIndex 否 int32 [0-10000] 1 页数 0 pageSize 否 int32 [5-200] 5 当前页展示条数 5 keyword 否 string 0~512个字符。 - 查询关键字, 譬如设备名称 "test"
  • URI /restconf/v2/data/huawei-ac-nes-device:nes/ne/{id}/huawei-nce-e-nvo3:nvo3/{source-nve} 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 id 是 string 36个字符。满足正则表达[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}。 - 设备ID。 "00000000-0000-0000-0000-000000000000" source-nve 是 string 1~63个字符。 - 源端接口,仅支持NVE口,单一主键字段。 "Nve1"
共100000条