Description

サブネットの一覧を取得します。

Request URL

Network API

GET /v2.0/subnets

Request Json

This operation does not accept a request body.

Request Parameters

Parameter Value Style Description
X-Auth-Token トークンID header トークンIDを指定します。

Response Code

Success

200

Example

Request

curl -i -X GET \
-H "Accept: application/json" \
-H "X-Auth-Token: トークンID" \
https://networking.tyo1.conoha.io/v2.0/subnets

Response

HTTP/1.1 200 OK
Server: openresty/1.7.10.1
Date: Fri, 08 May 2015 08:26:42 GMT
Content-Type: application/json
Content-Length: 5709
Connection: keep-alive

{
    "subnets": [
        {
            "name": "ext-133-130-48-0-23",
            "enable_dhcp": true,
            "network_id": "d3ae282c-3c79-4bb6-ae9d-40318bc1059e",
            "tenant_id": "647dcc7827f24909a096147ea4a4ccca",
            "dns_nameservers": [
                "157.7.180.133",
                "210.157.3.4"
            ],
            "gateway_ip": "133.130.48.1",
            "ipv6_ra_mode": null,
            "allocation_pools": [
                {
                    "start": "133.130.48.16",
                    "end": "133.130.49.240"
                }
            ],
            "host_routes": [],
            "ip_version": 4,
            "ipv6_address_mode": null,
            "cidr": "133.130.48.0/23",
            "id": "0569c47a-d349-4a23-a45b-ae9a50d9d847"
        },
        {
            "name": "add-157-7-110-18-31",
            "enable_dhcp": false,
            "network_id": "4f1733ec-daa5-4969-bf99-cf248151a40a",
            "tenant_id": "22394afc818d471ca2f0308c06ae7460",
            "dns_nameservers": [],
            "gateway_ip": "157.7.110.1",
            "ipv6_ra_mode": null,
            "allocation_pools": [
                {
                    "start": "157.7.110.18",
                    "end": "157.7.110.19"
                }
            ],
            "host_routes": [],
            "ip_version": 4,
            "ipv6_address_mode": null,
            "cidr": "157.7.110.18/31",
            "id": "fd5b6a8e-6a4e-49e8-9dc6-79b7c6033f58"
        }
    ]
}

ConoHaにて提供しておりますAPIにつきましては、クラウド基盤として採用しておりますOpenStackの機能にて実装しておりますので、詳細な情報や使い方はOpenStackのドキュメントにてご確認ください。