技術(shù)員聯(lián)盟提供win764位系統(tǒng)下載,win10,win7,xp,裝機(jī)純凈版,64位旗艦版,綠色軟件,免費(fèi)軟件下載基地!

當(dāng)前位置:主頁 > 教程 > 服務(wù)器類 >

阿里云如何使用查詢交換機(jī)列表接口

來源:技術(shù)員聯(lián)盟┆發(fā)布時間:2017-11-29 00:33┆點(diǎn)擊:

  查詢交換機(jī)列表

  描述

  查詢用戶的 VSwitch 列表。此接口支持分頁查詢,每頁的數(shù)量默認(rèn)為 10 條。

  該接口只會校驗(yàn)參數(shù)的合法性,不會校驗(yàn)參數(shù)之間的依賴關(guān)系,返回結(jié)果是所有條件的“交集”。

  請求參數(shù)

名稱 類型 是否必須 描述
Action   String     系統(tǒng)規(guī)定參數(shù),取值:DescribeVSwitches  
VpcId   String     VpcId  
VSwitchId   String     需要查詢的 VSwitch 的 Id  
ZoneId   String     可用區(qū) Id  
IsDefault   Boolean     是否為所屬可用區(qū)下的默認(rèn)交換機(jī),可選值:
true ——是
false ——否
不填寫該參數(shù)時返回所有交換機(jī)Id
 
PageNumber   Integer     實(shí)例狀態(tài)列表的頁碼,起始值為 1,默認(rèn)值為 1  
PageSize   Integer     分頁查詢時設(shè)置的每頁行數(shù),最大值 50 行,默認(rèn)為 10  

  返回參數(shù)

名稱 類型 描述
VSwitches   VSwitchType   VSwitch 詳情 VSwitchSetType 組成的集合  
TotalCount   Integer   列表?xiàng)l條目數(shù)  
PageNumber   Integer   當(dāng)前頁碼  
PageSize   Integer   當(dāng)前分頁包含多少條目  

  錯誤碼

錯誤代碼 描述 Http 狀態(tài)碼 語義
Forbidden.VpcNotFound   Specified VPC is not found during access authentication.   404   指定的 VPC 不存在  

  示例

  請求示例

24.png

  https://ecs.aliyuncs.com/?Action=DescribeVSwitches

  &VpcId=vpc-25eq58pl3

  &<公共請求參數(shù)>

  返回示例

  JSON格式

  {

  "PageNumber": 1,

  "PageSize": 10,

  "RequestId": "9A572171-4E27-40D1-BD36-D26C9E71E29E",

  "TotalCount": 1,

  "VSwitches": {

  "VSwitch": [

  {

  "AvailableIpAddressCount": 246,

  "CidrBlock": "172.16.1.0/24",

  "CreationTime": "2014-10-29T15:21:02Z",

  "Description": "",

  "Status": "Available",

  "VSwitchId": "vsw-25b7pv15t",

  "VSwitchName": "",

  "VpcId": "vpc-257gq642n",

  "ZoneId": "cn-beijing-a"