华为云用户手册

  • 响应示例 返回状态码为200:成功查询PortalServer信息。 HTTP/1.1 200 OK Date: Sun,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "pageIndex" : 1, "pageSize" : 20, "totalRecords" : 1, "errcode" : "0", "errmsg" : "", "data" : [ { "id" : "39c9700f-b765-4bfd-956d-3331bccab1b2", "tenantId" : "39c9700f-b765-4bfd-956d-3331bccab1b2", "name" : "portal-server", "description" : "portal server描述。", "ip" : "192.168.1.1", "port" : 22, "url" : "https://www.example.com", "sharedKey" : "", "urlTemplateId" : "39c9700f-b765-4bfd-956d-3331bccab1b2", "builtInServerEnable" : true, "iaeId" : "39c9700f-b765-4bfd-956d-3331bccab1b2", "iaeName" : "iae名称", "iaeIp" : "192.168.1.1", "iaeAd" : "iae-ad", "iaeIpv6" : "fc00::/64", "iaeDomain" : "iae", "portalUserSyncEnable" : true, "portalUserSyncPeriod" : 100, "portalUserSyncMaxTimes" : 10, "pushProtocol" : "protocol", "authRedirectUrlCarryEnable" : true, "sourceIpEnable" : true, "protocol" : "portal", "getMethodEnable" : false, "passwordEncrypt" : "none", "redirectType" : "static", "initUrlKey" : "key", "redirectUrl" : "https://www.example.com", "certificate" : "cloudwifi" } ] } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应参数 返回状态码为200:成功查询PortalServer信息。 表2 QueryPortalServerResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 pageIndex int32 [0-100] - 页码。 1 pageSize int32 [1-100] - 每页大小。 20 totalRecords int32 [0-500] - 总数。 1 errcode string 0~64个字符。 - 错误码。 "0" errmsg string 0~256个字符。 - 错误信息。 "" data ARRAY_REFERENCE 0-500个列表项,详细请参见表3。 portal服务器模板数据集合。 - 表3 PortalServerDto对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 id string 32~36个字符。 - portal server唯一标识。 "39c9700f-b765-4bfd-956d-3331bccab1b2" tenantId string 32~36个字符。 - 租户ID。 "39c9700f-b765-4bfd-956d-3331bccab1b2" name string 1~32个字符。 - portal server名称。 "portal-server" description string 0~256个字符。 - 描述 "portal server描述。" ip string 0~256个字符。 - IP地址。 "192.168.1.1" port int32 [1-65535] - 端口。 22 url string 1~200个字符。 - 统一资源定位符。 "https://www.example.com" sharedKey password 8~16个字符。 - 该字段可能包含敏感信息和个人数据,请妥善做好保护。 共享秘钥。 "" urlTemplateId string 32~36个字符。 - URL模板ID。 "39c9700f-b765-4bfd-956d-3331bccab1b2" builtInServerEnable boolean true false false 使能内置服务器。 true iaeId string 32~36个字符。 - IAE唯一标识。 "39c9700f-b765-4bfd-956d-3331bccab1b2" iaeName string 0~256个字符。 - IAE名称。 "iae名称" iaeIp string 0~256个字符。 - IAE所属IP地址。 "192.168.1.1" iaeAd string 0~256个字符。 - IAE所属Ad服务器。 "iae-ad" iaeIpv6 string 0~256个字符。 - IAE所属IPV6地址。 "fc00::/64" iaeDomain string 0~256个字符。 - IAE域。 "iae" portalUserSyncEnable boolean true false false 使能Portal用户同步。 true portalUserSyncPeriod int32 [30-65535] - Portal用户同步周期(秒)。 100 portalUserSyncMaxTimes int32 [2-255] - Portal用户同步最大失败次数。 10 pushProtocol string 0~256个字符。 - 推送协议。 "protocol" authRedirectUrlCarryEnable boolean true false false 使能重定向。 true sourceIpEnable boolean true false false 源IP配置使能 true protocol string 0~256个字符。 - 认证协议,portal和http "portal" getMethodEnable boolean true false false 提交方式(true:get,false:post,当protocol为http时生效)。 false passwordEncrypt string 0~256个字符。 - 密码编码方式(none,uam,当protocol为http时生效)。 "none" redirectType string 0~16个字符。 - 重定向类型,分静态,动态或者为空值,保持兼容性。 "static" initUrlKey string 0~32个字符。 - 动态重定向初始url的key值。 "key" redirectUrl string 0~256个字符。 - 静态重定向url值。 "https://www.example.com" certificate string 0~64个字符。 - 证书域(cloudwifi,default) "cloudwifi" 返回状态码为400:校验异常。 详细信息请参见实际响应消息体。 返回状态码为500:内部服务错误。 详细信息请参见实际响应消息体。
  • URI /controller/campus/v1/networkservice/networkconfig/profile/portal-server 表1 query参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 pageSize 否 int32 [1-100] - 每页大小。 20 pageIndex 否 int32 [1-100] - 页码。 1 name 否 string 1~32个字符。 - 服务器名称。 "portal-server"
  • 请求示例 HTTP的示例 GET /controller/campus/v1/networkservice/networkconfig/profile/portal-server?pageSize=20&pageIndex=1&name=portal-server 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
  • 请求示例 HTTP的示例 PUT /controller/campus/v1/sdwan/snmp/trap/00000000-0000-0000-0000-000000000000 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 { "config-status" : "reserved", "errorInfo" : "", "trapSwitch" : true, "trapQueueSize" : 1000, "trapSourceInterfaceName" : "GE0/0/0", "serverSource" : "192.168.1.1", "targetHosts" : { "targetHost" : [ { "name" : "hostName", "address" : "192.168.2.1", "isPublicNet" : false, "notifyType" : "trap", "portNumber" : 162, "vpnInstanceName" : "underlay_1", "interfaceName" : "GE0/0/1", "userName" : "user", "securityLevel" : "privacy" } ] }, "traps" : { "trap" : [ { "featureName" : "IFNET", "trapName" : "linkdown" } ] } }
  • 响应示例 返回状态码为200:配置成功,响应体参考SnmpResponse。 HTTP/1.1 200 OK Date: Sun,11 May 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" : { "config-status" : "reserved", "errorInfo" : "", "trapSwitch" : true, "trapQueueSize" : 1000, "trapSourceInterfaceName" : "GE0/0/0", "serverSource" : "192.168.1.1", "targetHosts" : { "targetHost" : [ { "name" : "hostName", "address" : "192.168.2.1", "isPublicNet" : false, "notifyType" : "trap", "portNumber" : 162, "vpnInstanceName" : "underlay_1", "interfaceName" : "GE0/0/1", "userName" : "user", "securityLevel" : "privacy" } ] }, "traps" : { "trap" : [ { "featureName" : "IFNET", "trapName" : "linkdown" } ] } } } 返回状态码为400:请求参数错误。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 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/sdwan/netstream/00000000-0000-0000-0000-000000000000/interface 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 { "netstreamIf" : [ { "ifName" : "GE0/0/0", "netstreamIf" : { "config-status" : "", "errorInfo" : "", "flowType" : "IPv4", "samplerRates" : [ { "direction" : "inbound", "fixPacketsValue" : 1 } ], "samplerEnables" : [ { "direction" : "inbound" } ], "applyFlexFlowRecordNames" : [ "record1" ], "exportTnpFlag" : false, "afterDecapFlag" : false } } ] }
  • 响应示例 返回状态码为200:配置成功,响应体参考netstreamIfListResponse。 HTTP/1.1 200 OK Date: Sun,11 May 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" : { "netstreamIf" : [ { "ifName" : "GE0/0/0", "netstreamIf" : { "config-status" : "", "errorInfo" : "", "flowType" : "IPv4", "samplerRates" : [ { "direction" : "inbound", "fixPacketsValue" : 1 } ], "samplerEnables" : [ { "direction" : "inbound" } ], "applyFlexFlowRecordNames" : [ "record1" ], "exportTnpFlag" : false, "afterDecapFlag" : false } } ] } } 返回状态码为400:请求参数错误。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应示例 返回状态码为200:查询成功,返回设备所有子网配置信息。 HTTP/1.1 200 OK Date: Sun,11 May 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" : { "pageIndex" : 1, "pageSize" : 20, "totalRecords" : 10, "subnetList" : [ { "name" : "subnet1", "vlanId" : 100, "ipv4poolOrNot" : 0, "ipAddress" : "192.168.12.12", "maskAddress" : 24, "subIpList" : [ { "subIpAddress" : "192.168.13.13", "subMaskAddress" : 24 } ], "arpEnable" : false, "mtu" : 1500, "dhcpEnable" : true, "icmpRedirectSendEnable" : true, "dhcpConfig" : { "dhcpMode" : "server", "relayServerIps" : [ "10.122.12.1" ], "dhcpServerConfig" : { "dnsConfig" : { "dnsServerMode" : "custom", "priorDnsServer" : "10.15.15.15", "standbyDnsServer" : "10.15.15.16" }, "domainSuffix" : "com", "manegeNetworkEnable" : true, "exceptFitAp" : "CloudAP", "option148" : false, "acAddressType" : "IP", "option43" : false, "wacAddress" : [ "10.122.12.1" ], "dhcpServerLogging" : false, "dhcpServerOptions" : [ { "code" : 26, "subCode" : 5, "optionType" : "hex", "optionValue" : "2e" } ], "leasesConfig" : { "unlimit" : false, "day" : 1, "hour" : 0, "minute" : 0 }, "excludedAddresses" : [ { "startIpAddress" : "192.168.12.13", "endIpAddress" : "192.168.12.13" } ], "fixIpEnable" : false, "fixedIpRange" : [ { "startIpAddress" : "192.168.12.13", "endIpAddress" : "192.168.12.13" } ], "staticBindings" : [ { "staticIpAddress" : "192.168.12.14", "staticMacAddress" : "XX:XX:XX:XX:XX:XX" } ] } }, "id" : "30a51c112787470f81045d60ccf3995f" } ] } } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 GET /controller/campus/v1/networkservice/networkconfig/net/lswsubnet/devices/fbb684c8-0d37-496f-bafa-4b06d5151e2e/subnet?pageIndex=1&pageSize=20 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/v1/networkservice/networkconfig/net/lswsubnet/devices/{deviceId}/subnet 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 deviceId 是 string - - 设备ID,UUID格式。 "fbb684c8-0d37-496f-bafa-4b06d5151e2e" 表2 query参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 pageIndex 是 integer [1-4096] - 页面索引,支持子网列表分页。 1 pageSize 是 integer [1-1000] - 每页显示记录数,支持子网列表分页。 20
  • 响应参数 返回状态码为200:查询成功,返回设备所有子网配置信息。 表3 GetSubnetInfoResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 0~64个字符。 - 错误码。 "0" errmsg string 0~256个字符。 - 错误信息。 "" data REFERENCE 详细请参见表4。 - - 表4 GetSubnetInfo对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 pageIndex integer [1-4096] - 页面索引。 1 pageSize integer [1-1000] - 每页显示记录数。 20 totalRecords integer [1-4096] - 总记录数。 10 subnetList ARRAY_REFERENCE 0-1000个列表项,详细请参见表13。 - - 返回状态码为400:校验异常。 详细信息请参见实际响应消息体。
  • 响应示例 返回状态码为200:操作成功。 HTTP/1.1 200 OK Date: Sun,11 May 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,11 May 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,11 May 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-bgp:bgp 表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"
  • 接口约束 该接口支持msp视图下,角色为“Open Api Operator”的用户访问,必须在用户会话建立后使用,且仅支持AR6700V和AR6700V子设备; 或者支持租户视图或msp代维视图下,角色为“Open Api Operator”的用户访问,必须在用户会话建立后使用,且仅支持AR6700V-L款型。 该API可能会直接或间接影响现网业务运行,导致业务中断、关键数据丢失等,请谨慎操作!
  • 请求示例 HTTP的示例 DELETE /restconf/v2/data/huawei-ac-nes-device:nes/ne/00000000-0000-0000-0000-000000000000/huawei-nce-e-bgp:bgp 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 restconf-transaction-id: "00000000-0000-0000-0000-000000000000"
  • 请求示例 HTTP的示例 PUT /restconf/v2/data/huawei-ac-nes-device:nes/ne/00000000-0000-0000-0000-000000000000/huawei-nce-e-syslog:syslog-config 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 restconf-transaction-id: "00000000-0000-0000-0000-000000000000" { "huawei-nce-e-syslog:syslog-config" : { "config-status" : "configured-database-success", "last-committed-time" : "2022-01-01 00:00:00", "related-pkg-version" : "1.0.1", "edit-state" : "RUNNING", "global-parameter" : { "interface-name" : "1", "buffer-size" : 1, "log-timestamp" : "date-boot", "log-timezone" : true, "debug-timestamp" : "date-boot", "debug-timezone" : true, "trap-timestamp" : "date-boot", "trap-timezone" : true, "statistic-suppress" : true }, "server" : [ { "ipaddress" : "E2:1:1:1:1:1:1:1", "vrf-name" : "_public_", "port" : 453, "transport-mode" : "tcp", "channel-id" : 5, "facility" : "local7", "ssl-policy-name" : "default" } ], "info-center-source" : [ { "module-name" : "default", "channel-id" : 5, "enable-log" : "", "enable-log-level" : "", "enable-trap" : "", "enable-trap-level" : "" } ] } }
  • 响应示例 返回状态码为200:操作成功。 HTTP/1.1 200 OK Date: Sun,11 May 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,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求参数 表2 header参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 restconf-transaction-id 是 string - - 事务ID。 "00000000-0000-0000-0000-000000000000" 表3 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 huawei-nce-e-syslog:syslog-config 是 REFERENCE 详细请参见表4。 syslog配置 - 表4 syslog-config-augment对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 huawei-nce-e-syslog:syslog-config 否 REFERENCE 详细请参见表5。 syslog配置 - 表5 syslog-config对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 config-status 否 string reserved initial configuring-database configured-database-success configured-database-failed configuring-device configured-device-success configured-device-failed reserved 配置状态,对应保留未用状态、初始状态、数据库存储中状态、预配置状态、数据库存储失败状态、部署中状态、成功状态、失败状态;不支持编辑,仅查询返回。 "configured-database-success" last-committed-time 否 string 0~255个字符。 - 最后提交时间,该特性最后提交时间;不支持编辑,仅查询返回。 "2022-01-01 00:00:00" related-pkg-version 否 string 0~255个字符。 - 包版本,插件包版本;不支持编辑,仅查询返回。 "1.0.1" edit-state 否 string RUNNING CANDIDATE UNDEPLOYING UNDEPLOYED - 编辑状态,对应运行状态、候选状态、取消部署状态、未部署状态;不支持编辑,仅查询返回。 "RUNNING" global-parameter 否 REFERENCE 详细请参见表6。 全局配置 - server 否 ARRAY_REFERENCE 0-8个列表项,详细请参见表7。 服务 - info-center-source 否 ARRAY_REFERENCE 0-1000个列表项,详细请参见表8。 信息通道 - 表6 global-parameter对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 interface-name 否 string 1~63个字符。 - 接口名称,1-63字符,需要和设备上的接口名称保持一致。 "1" buffer-size 否 int32 [0-10240] - 日志条数, "合法范围1..10240,其中V200交换机合法范围0..1024" 1 log-timestamp 否 string date-boot date-second date-tenthsecond date-millisecond shortdate-second shortdate-tenthsecond shortdate-millisecond formatdate-second formatdate-tenthsecond formatdate-millisecond - 日志时间类型-boot型,date型,short-date型,format-date型 "date-boot" log-timezone 否 boolean true false true 日志时区 true debug-timestamp 否 string date-boot date-second date-tenthsecond date-millisecond shortdate-second shortdate-tenthsecond shortdate-millisecond formatdate-second formatdate-tenthsecond formatdate-millisecond - debug时间类型-boot型,date型,short-date型,format-date型 "date-boot" debug-timezone 否 boolean true false true debug时区 true trap-timestamp 否 string date-boot date-second date-tenthsecond date-millisecond shortdate-second shortdate-tenthsecond shortdate-millisecond formatdate-second formatdate-tenthsecond formatdate-millisecond - trap时间类型-boot型,date型,short-date型,format-date型 "date-boot" trap-timezone 否 boolean true false true trap时区 true statistic-suppress 否 boolean true false - 连续重复日志的统计抑制功能 true 表7 syslog-config-server对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 ipaddress 否 string - - IP地址 "E2:1:1:1:1:1:1:1" vrf-name 否 string 1~31个字符。 _public_ VPN名称,默认为__public__ "_public_" port 否 int64 [1-65535] - 端口 453 transport-mode 否 string udp tcp udp 传输模式 "tcp" channel-id 否 int64 [0-9] - 通道ID 5 facility 否 string local0 local1 local2 local3 local4 local5 local6 local7 local7 设施,枚举值,默认为local7 "local7" ssl-policy-name 否 string 1~23个字符。满足正则表达[a-z0-9_]*。 - ssl策略名称 "default" 表8 syslog-config-info-center-source对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 module-name 否 string 1~31个字符。满足正则表达[^A-Z]*。 - 模块名称."1-31位小写字母或数字,如a-z或0-9,例如:default,其他特性在设备产品文档"日志参考"中可以查到设备当前支持的所有模块名称,如aaa、am,具体以设备产品文档为准。" "default" channel-id 否 int64 [0-9] - 通道ID 5 enable-log 否 boolean true false - 使能日志 - enable-log-level 否 string emergencies alert critical error warning notification informational debugging - 使能日志级别 - enable-trap 否 boolean true false - 使能Trap - enable-trap-level 否 string emergencies alert critical error warning notification informational debugging debugging 使能Trap级别 -
  • URI /restconf/v2/data/huawei-ac-nes-device:nes/ne/{id}/huawei-nce-e-syslog:syslog-config 表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"
  • 请求示例 HTTP的示例 PUT /controller/campus/v1/lanwan/interconnection/route/static 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 { "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "coreStaticInfoList" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ], "gatewayStaticInfoList" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ] }
  • 响应示例 返回状态码为200:更新IPv4静态路由返回参数。 HTTP/1.1 200 OK Date: Sun,11 May 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" : { "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "coreStaticInfoList" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ], "gatewayStaticInfoList" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ] }, "fail" : { "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "failCoreRouteStaticList" : { "errcode" : "0", "errmsg" : "", "routeInfo" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ] }, "failGatewayRouteStaticList" : { "errcode" : "0", "errmsg" : "", "routeInfo" : [ { "id" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "linkName" : "ConnectLink", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "deviceName" : "Core-1", "deviceType" : "LSW", "platform" : "platform", "priority" : 120, "destIp" : "192.168.10.0/24", "nextHopType" : "ip-address", "nextHopIpAddress" : "192.168.10.1", "isTracked" : false, "trackTargetIpAddress" : "192.168.10.1", "configSource" : "LANWAN" } ] } } } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 GET /controller/campus/api/v1/networkconfig/apvpn/site/fbb684c8-0d37-496f-bafa-4b06d5151e2e/apvpn?pageIndex=1&pageSize=1 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
  • 响应示例 返回状态码为200:查询AP VPN成功,响应体参考GetApVpnResponseDto。 HTTP/1.1 200 OK Date: Sun,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "vpnList" : [ { "id" : "e4d2b0e95bb94ef0a75b6a530d0b41be", "ipsecConnectionName" : "vpn1", "deviceName" : "AirEngine6760R-51_FBF792C3", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d5151e2e", "peerAddress" : "192.168.1.1" , "localIdType" : "ip", "localIdValue" : "myhost.example.com", "refinedAcl" : [ { "priority" : 1, "action" : true, "protocol" : "tcp", "sourceIp" : "192.168.1.0/24", "sourceIpPort" : "1000", "desIp" : "192.168.1.0/24", "port" : "1000", "description" : "acl信息" } ], "filterAcl" : [ { "priority" : 1, "action" : true, "protocol" : "tcp", "sourceIp" : "192.168.1.0/24", "sourceIpPort" : "1000", "desIp" : "192.168.1.0/24", "port" : "1000", "description" : "acl信息" } ], "ipsecTemplateId" : "f285e423-492a-41ef-a4b8-5a687fc6832a", "preSharedKey" : "IAm@example" } ], "pageIndex" : 1, "pageSize" : 1, "total" : 1 } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • URI /controller/campus/api/v1/networkconfig/apvpn/site/{siteId}/apvpn 表1 path参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 siteId 是 string 36个字符。 - 站点ID。 "fbb684c8-0d37-496f-bafa-4b06d5151e2e" 表2 query参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 pageIndex 否 int32 [1-100] 1 第几页的数据。 1 pageSize 否 int32 [1-100] 20 一页多少条数据。 1
  • 响应示例 返回状态码为200:查询成功,响应体参考QueryPredefinedIPSProfilesResponse。 HTTP/1.1 200 OK Date: Sun,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "totalRecords" : 1, "pageSize" : 10, "pageIndex" : 1, "data" : [ { "name" : "templateName", "action" : "block", "target" : "both", "serverity" : [ "Low" ], "operationSystem" : [ "unix-like" ], "protocol" : [ "DNS" ], "threatType" : [ "all" ] } ] } 返回状态码为400:请求参数错误。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 请求示例 HTTP的示例 GET /controller/campus/v1/sdwan/policy/security/IPS-profiles 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
  • 请求示例 HTTP的示例 POST /controller/campus/v1/sdwan/policy/traffic/nat/staticnat-batch-delete 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 { "vpnId" : "00000000-0000-0000-0000-000000000000", "siteId" : "00000000-0000-0000-0000-000000000000", "policyIds" : ["00000000-0000-0000-0000-000000000000","00000000-0000-0000-0000-000000000001"] }
  • 响应示例 返回状态码为200:删除成功,响应体参考NatResponse。 HTTP/1.1 200 OK Date: Sun,11 May 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" : { "dynamicNatInfo" : [ { "policyId" : "00000000-0000-0000-0000-000000000000", "isOverlay" : true, "vpnId" : "00000000-0000-0000-0000-000000000000", "siteId" : "00000000-0000-0000-0000-000000000000", "deviceId" : "00000000-0000-0000-0000-000000000000", "policyName" : "policyName", "linkId" : "00000000-0000-0000-0000-000000000000", "interfaceName" : "GE0/0/8", "natMode" : "EASY_IP", "startAddress" : "192.168.1.1", "endAddress" : "192.168.1.2", "natRuleInfos" : [ { "ruleId" : "00000000-0000-0000-0000-000000000000", "priority" : 1, "action" : "permit", "protocol" : 6, "sourceIp" : "10.1.0.1/16", "destinationIp" : "10.2.0.1/16", "sourcePort" : 1, "destinationPort" : 1 } ] } ], "staticNatInfo" : [ { "policyId" : "00000000-0000-0000-0000-000000000000", "isOverlay" : true, "vpnId" : "00000000-0000-0000-0000-000000000000", "siteId" : "00000000-0000-0000-0000-000000000000", "deviceId" : "00000000-0000-0000-0000-000000000000", "policyName" : "policyName", "linkId" : "00000000-0000-0000-0000-000000000000", "interfaceName" : "GE0/0/8", "isUserDefined" : true, "externalIp" : "10.2.0.1", "internalIp" : "10.1.0.1", "translationType" : 1, "protocol" : "1", "externalPort" : 90, "internalPort" : 90, "addressMask" : 30, "advanceSetEnable" : false, "direction" : 1, "natRuleInfos" : [ { "ruleId" : "00000000-0000-0000-0000-000000000000", "priority" : 1, "action" : "permit", "protocol" : 6, "sourceIp" : "10.1.0.1/16", "destinationIp" : "10.2.0.1/16", "sourcePort" : 1, "destinationPort" : 1 } ] } ] } }
  • 响应示例 返回状态码为200:接口调用成功,响应体参考QueryIPSubnetResponse。 HTTP/1.1 200 OK Date: Sun,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "totalRecords" : 200, "pageSize" : 20, "pageIndex" : 1, "data" : [ { "vpnId" : "fbb684c8-0d37-496f-bafa-4b06d515j7l6", "siteId" : "fbb684c8-0d37-496f-bafa-4b06d515j7l6", "deviceId" : "fbb684c8-0d37-496f-bafa-4b06d515j7l6", "id" : "fbb684c8-0d37-496f-bafa-4b06d515j7l6", "interfaceType" : "interface", "interfaceName" : "vlanif20", "portLagFlag" : false, "portId" : "fbb684c8-0d37-496f-bafa-4b06d515j7l6", "vlanId" : 1, "subInterfaceName" : "GE0/0/0.1", "trustEnable" : false, "trust" : "dscp", "ipAddress" : "192.168.1.1", "prefixLength" : 24, "secondaryIP" : ["10.10.10.2/24","10.10.11.2/24"], "siteName" : "site", "deviceName" : "device", "vrrp" : { "enable" : true, "vrrpId" : 1, "virtualIpAddress" : "10.1.1.1;10.1.2.1", "defaultRole" : "master", "preemptDelay" : 0, "priority" : 1, "track" : [ { "bfdSession" : { "localDiscriminator" : 1, "remoteDiscriminator" : 1, "sourceIp" : "192.168.1.1", "peerIp" : "192.168.1.1", "interval" : 10 }, "interfaceName" : "GE0/0/1", "addOrReduce" : "reduce", "value" : 1, "type" : "ipv4" } ], "vrrpList" : [ { "vrrpId" : 1, "virtualIpAddress" : "10.1.1.1;10.1.2.1", "defaultRole" : "master", "preemptDelay" : 0, "priority" : 1, "authMode" : 0, "authKey" : "", "track" : [ { "bfdSession" : { "localDiscriminator" : 1, "remoteDiscriminator" : 1, "sourceIp" : "192.168.1.1", "peerIp" : "192.168.1.1", "interval" : 10 }, "interfaceName" : "GE0/0/1", "addOrReduce" : "reduce", "value" : 1, "type" : "ipv4" } ] } ] }, "dhcp" : { "enable" : false, "dhcpServiceType" : "server", "dhcpServer" : { "excludeIpGroups" : [ { "startAddress" : "192.168.1.2", "endAddress" : "192.168.1.3" } ], "leaseTime" : { "day" : 0, "hour" : 0, "minute" : 0 }, "voiceOption" : { "asIp" : "192.168.1.10", "ncpIp" : "192.168.1.10", "voiceVlan" : 3, "failOver" : { "ipAddress" : "192.168.1.10", "dialerString" : "12345678" }, "description" : "description" }, "dhcpOption" : [ { "code" : 44, "type" : "ascii", "description" : "Wins/Netbios server", "value" : "192.168.1.1" } ], "dhcpStatic" : [ { "ipAddress" : "192.168.1.10", "macAddress" : "xxxx-xxxx-xxxx" } ], "dns" : ["8.8.8.8","114.114.114.114"], "domainName" : "example.com", "useSecondaryIP" : false }, "dhcpRelay" : { "serverIps" : ["192.168.1.1"], "sourceAddress" : "10.10.10.2", "gatewayAddress" : "10.10.10.3", "dhcpRelayOption82" : { "function" : 0, "vlanId" : 1, "subOption" : [ { "subOptionCode" : 0, "isUserDefined" : true, "value" : "\"ZID023301\"" } ] }, "linkSelectionEnable" : true, "linkSelectionAddress" : "10.10.10.1" } }, "securityZone" : "trust", "proxyArp" : false, "innerProxyArp" : false, "attributes" : { "mtu" : 1500, "TCPmss" : 1200 }, "description" : "description", "toVasEnable" : false, "enableIpv4" : true, "enableIpv6" : false, "ipv6Info" : { "ipv6Address" : "fc00:3::1", "ipv6PrefixLength" : 64, "dhcpV6Enable" : true, "dhcpV6" : { "dhcpv6ServiceType" : "server", "dhcpv6Server" : { "addressPrefix" : "fc00:3::/64", "addressPrefixLeaseTime" : { "day" : 0, "hour" : 0, "minute" : 0 }, "delegationPrefix" : "fc00:3::/64", "delegationPrefixAssignLength" : 64, "delegationPrefixLeaseTime" : { "day" : 0, "hour" : 0, "minute" : 0 }, "excludeIpGroups" : [ { "startAddress" : "fc00:1::1", "endAddress" : "fc00:1::10" } ], "firstDnsServer" : "fc00:3::1", "secondDnsServer" : "fc00:3::2", "domainName" : "0" }, "dhcpv6Relay" : { "serverIps" : ["fc00::1"] } }, "vrrp6Enable" : true, "vrrp6" : { "vrrp6Id" : 1, "virtualIpv6AddressLinkLocal" : "fe80::7", "virtualIpv6Address" : "fc00:3::10;fc00:3::11", "preemptDelay" : 0, "priority" : 1, "trackEnable" : true, "track" : [ { "bfdSession" : { "localDiscriminator" : 1, "remoteDiscriminator" : 1, "sourceIp" : "192.168.1.1", "peerIp" : "192.168.1.1", "interval" : 10 }, "interfaceName" : "GE0/0/1", "addOrReduce" : "reduce", "value" : 1, "type" : "ipv4" } ], "vrrp6Role" : "" }, "ipv6NtpDisable" : false, "raHaltEnable" : false, "managedAddressFlagEnable" : false }, "configSource" : "Wan", "ntpDisable" : false, "unrHostRouteAdvertiseEnable" : false, "dhcpTriggerEnable" : false, "unrRoutesLimitEnable" : false, "unrRoutesLimit" : 24 } ] } 返回状态码为400:校验异常。 HTTP/1.1 400 Bad Request Date: Sun,11 May 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,11 May 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
共100000条
提示

您即将访问非华为云网站,请注意账号财产安全