功能介紹
查詢(xún) 虛擬私有云 列表。
調(diào)試
您可以在API Explorer中調(diào)試該接口。
URI
GET /v1/{project_id}/vpcs
GET https://{Endpoint}/v1/{project_id}/vpcs?limit=10&marker=13551d6b-755d-4757-b956-536f674975c0
名稱(chēng) |
是否必選 |
參數(shù)類(lèi)型 |
說(shuō)明 |
---|---|---|---|
project_id |
是 |
String |
項(xiàng)目ID,獲取項(xiàng)目ID請(qǐng)參見(jiàn)獲取項(xiàng)目ID。 |
marker |
否 |
String |
分頁(yè)查詢(xún)的起始資源ID,表示從指定資源的下一條記錄開(kāi)始查詢(xún)。 marker需要和limit配合使用:
|
limit |
否 |
Integer |
分頁(yè)查詢(xún)每頁(yè)返回的記錄個(gè)數(shù),取值范圍為0~intmax(2^31-1),默認(rèn)值2000。 limit需要和marker配合使用,詳細(xì)規(guī)則請(qǐng)見(jiàn)marker的參數(shù)說(shuō)明。 |
enterprise_project_id |
否 |
String |
|
請(qǐng)求參數(shù)
無(wú)
請(qǐng)求示例
GET https://{Endpoint}/v1/{project_id}/vpcs
響應(yīng)參數(shù)
名稱(chēng) |
參數(shù)類(lèi)型 |
說(shuō)明 |
---|---|---|
id |
String |
uuid形式的一個(gè)資源標(biāo)識(shí)。 |
name |
String |
|
description |
String |
|
cidr |
String |
|
status |
String |
|
enterprise_project_id |
String |
|
routes |
||
tenant_id |
String |
功能說(shuō)明:項(xiàng)目ID。 |
created_at |
String |
|
updated_at |
String |
|
響應(yīng)示例
{ "vpcs": [ { "id": "13551d6b-755d-4757-b956-536f674975c0", "name": "default", "description": "test", "cidr": "172.16.0.0/16", "status": "OK", "enterprise_project_id": "0", "routes": [], "tenant_id": "087679f0aa80d32a2f4ec0172f5e902b", "created_at": "2022-12-15T02:11:13", "updated_at": "2022-12-15T02:11:13" }, { "id": "3ec3b33f-ac1c-4630-ad1c-7dba1ed79d85", "name": "222", "description": "test", "cidr": "192.168.0.0/16", "status": "OK", "enterprise_project_id": "0635d733-c12d-4308-ba5a-4dc27ec21038", "routes": [], "tenant_id": "087679f0aa80d32a2f4ec0172f5e902b", "created_at": "2022-12-15T04:01:21", "updated_at": "2022-12-15T04:01:21" }, { "id": "99d9d709-8478-4b46-9f3f-2206b1023fd3", "name": "vpc", "description": "test", "cidr": "192.168.0.0/16", "status": "OK", "enterprise_project_id": "0", "routes": [], "tenant_id": "087679f0aa80d32a2f4ec0172f5e902b", "created_at": "2022-12-15T05:36:29", "updated_at": "2022-12-15T05:36:29" } ] }
狀態(tài)碼
請(qǐng)參見(jiàn)狀態(tài)碼。
錯(cuò)誤碼
請(qǐng)參考錯(cuò)誤碼。