云服务器内容精选

  • 请求示例 HTTP的示例 DELETE /controller/sdwan/v1/naas/device 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 { "naasNetworkId" : "00000000-0000-0000-0000-000000000000", "deviceId" : "00000000-0000-0000-0000-000000000000" }
  • 响应示例 返回状态码为201:创建成功返回。 HTTP/1.1 201 Created 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
  • 响应示例 返回状态码为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" : "", "pageIndex" : "", "pageSize" : "", "totalRecords" : "", "data" : [ { "siteId" : "00000000-0000-0000-0000-000000000000", "siteName" : "site1", "siteRole" : "Interworking Gateway", "deviceId" : "00000000-0000-0000-0000-000000000000", "deviceName" : "Template1", "deviceModel" : "AR6700V", "naasNetworkId" : "00000000-0000-0000-0000-000000000000", "naasNetworkName" : "Template1", "deployStatus" : "ready", "deviceStatus" : "0" } ] } 返回状态码为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的示例 GET /controller/sdwan/v1/naas/device/all?deviceName=device&pageIndex=1&pageSize=10 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:查询成功返回。 表2 NaasNetworkDeviceListResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string - - 错误码。 "0" errmsg string - - 错误信息。 "" pageIndex int32 [1-100] - 分页索引 - pageSize int32 [1-100] - 分页大小。 - totalRecords int32 [0-1000] - 总数。 - data ARRAY_REFERENCE 0-2000个列表项,详细请参见表3。 NaasNetwork设备列表。 - 表3 NaasNetworkDeviceInfo对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 siteId string 0~64个字符。 - 站点ID。 "00000000-0000-0000-0000-000000000000" siteName string 0~64个字符。 - 服务链名称。 "site1" siteRole string 0~64个字符。 - 站点角色,仅支持Interworking Gateway。 "Interworking Gateway" deviceId string 0~64个字符。 - 设备ID。 "00000000-0000-0000-0000-000000000000" deviceName string 0~64个字符。 - 设备名称。 "Template1" deviceModel string 0~64个字符。 - 设备类型。 "AR6700V" naasNetworkId string 0~64个字符。 - 服务链ID。 "00000000-0000-0000-0000-000000000000" naasNetworkName string 0~64个字符。 - 服务链名称。 "Template1" deployStatus string 0~21个字符。 - 部署状态。creating:创建中, ready:已就绪, unknown:未知, error:故障, configured:已配置。 "ready" deviceStatus string 0~64个字符。 - 设备状态 0 正常 1 告警 2 故障 3 离线 4 未注册。 "0" 返回状态码为400:校验异常。 详细信息请参见实际响应消息体。 返回状态码为500:内部错误。 详细信息请参见实际响应消息体。
  • URI /controller/sdwan/v1/naas/device/all 表1 query参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 deviceName 否 string 0~128个字符。 - 设备名称。 "device" pageIndex 否 int32 [1-100] - 页面索引,不填时默认值为1。 "1" pageSize 否 int32 [1-20] - 页面大小,不填时默认值是5。 "10"
  • 响应示例 返回状态码为201:创建成功返回。 HTTP/1.1 201 Created 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
  • 请求参数 表1 body参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 naasNetworkDevice 是 REFERENCE 详细请参见表2。 设备部署NaasNetwork信息。 - 表2 NaasNetworkDeployDeviceRequest对象的参数列表 参数名称 必选 类型 参数值域 默认值 参数说明 参数示例 naasNetworkId 是 string 1~64个字符。 - 模板ID,格式UUID。 "00000000-0000-0000-0000-000000000000" deviceId 是 string 1~64个字符。 - 设备ID,格式UUID。 "00000000-0000-0000-0000-000000000000"
  • 请求示例 HTTP的示例 POST /controller/sdwan/v1/naas/device 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 { "naasNetworkId" : "00000000-0000-0000-0000-000000000000", "deviceId" : "00000000-0000-0000-0000-000000000000" }
  • 响应参数 返回状态码为201:创建成功返回。 表3 NaasNetworkDeployDeviceResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string - - 状态码,0:请求成功。 "0" errmsg string - - 接口调用的错误信息。 "" 返回状态码为400:校验异常。 详细信息请参见实际响应消息体。 返回状态码为500:内部错误。 详细信息请参见实际响应消息体。
  • 请求示例 HTTP的示例 GET /controller/sdwan/v1/naas/device?deviceId=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
  • 响应参数 返回状态码为200:查询成功返回。 表2 NaasNetworkDeployStatusResponse对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string - - 状态码,0:请求成功。 "0" errmsg string - - 接口调用的错误信息。 "" status string - - 部署状态。creating:创建中, ready:已就绪, unknown:未知, error:故障, configured:已配置。 "" 返回状态码为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" : "", "status" : "" } 返回状态码为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:查询成功返回。 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" : "", "networkResources" : [ { "hostUnitType" : "director", "number" : 24, "allocNumber" : 24 } ] } 返回状态码为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的示例 GET /controller/sdwan/v1/naas/device/resource?deviceId=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