getCloudPostgresqlInstanceList

Prev Next

VPC環境で利用できます。

Cloud DB for PostgreSQLインスタンスリストを照会します。

リクエスト

リクエスト形式を説明します。リクエスト形式は次の通りです。

メソッド URI
GET, POST /getCloudPostgresqlInstanceList

リクエストヘッダ

Cloud DB for PostgreSQL (VPC) APIで共通して使用されるヘッダの詳細は、Cloud DB for PostgreSQL (VPC)のリクエストヘッダをご参照ください。

リクエストパラメータ

パラメータの説明は次の通りです。

フィールド タイプ 必須の有無 説明
regionCode String Optional リージョンコード
  • 照会対象の Cloud DB for PostgreSQLインスタンスのリージョンコード
  • getRegionListを通じて確認
  • getRegionList照会結果の最初のリージョン(デフォルト)
zoneCode String Optional ゾーンコードでフィルタリング
vpcNo String Optional VPC番号でフィルタリング
subnetNo String Optional Subnet番号でフィルタリング
cloudPostgresqlServiceName String Optional Cloud DB for PostgreSQLサービス名でフィルタリング
cloudPostgresqlInstanceNoList.N List<String> Optional Cloud DB for PostgreSQLインスタンス番号リスト
  • Cloud DB for PostgreSQLインスタンス番号でフィルタリング
  • getCloudPostgresqlInstanceListを通じて確認
  • <例> cloudPostgresqlInstanceNoList.1=1234&cloudPostgresqlInstanceNoList.2=2345
cloudPostgresqlServerName String Optional Cloud DB for PostgreSQLサーバ名でフィルタリング
cloudPostgresqlServerInstanceNoList.N List<String> Optional Cloud DB for PostgreSQLサーバインスタンス番号リスト
  • Cloud DB for PostgreSQLサーバインスタンス番号でフィルタリング
  • getCloudPostgresqlInstanceListを通じて確認
  • <例> cloudPostgresqlServerInstanceNoList.1=1234&cloudPostgresqlServerInstanceNoList.2=2345
pageNo Integer Optional ページングされた結果のページ番号
  • pageNopageSizeを利用してページング処理
  • 0 (最小)
pageSize Integer Conditional ページごとに表示する結果数
  • pageNopageSizeを利用してページング処理
  • pageNo入力時、必須
  • 1 (最小)
responseFormatType String Optional レスポンス結果の形式
  • xml(デフォルト) | json

リクエスト例

リクエストのサンプルコードは次の通りです。

curl --location --request GET 'https://ncloud.apigw.ntruss.com/vpostgresql/v2/getCloudPostgresqlInstanceList
?regionCode=KR' 
--header 'x-ncp-apigw-timestamp: {Timestamp}' 
--header 'x-ncp-iam-access-key: {Access Key}' 
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}'

レスポンス

レスポンス形式を説明します。

レスポンスボディ

レスポンスボディの詳細は、CloudPostgresqlInstanceListをご参照ください。

レスポンスステータスコード

NAVERクラウドプラットフォームでで共通して使用されるレスポンスステータスコードの詳細は、Ncloud APIのレスポンスステータスコードをご参照ください。

レスポンス例

レスポンスのサンプルコードは次の通りです。

  • responseFormatType=jsonの場合
{
    "getCloudPostgresqlInstanceListResponse": {
        "totalRows": 1,
        "cloudPostgresqlInstanceList": [
            {
                "cloudPostgresqlInstanceNo": "****925",
                "cloudPostgresqlServiceName": "test-****",
                "cloudPostgresqlInstanceStatusName": "running",
                "cloudPostgresqlInstanceStatus": {
                    "code": "CREAT",
                    "codeName": "CLOUD DATABASE(VPC) Created State"
                },
                "cloudPostgresqlInstanceOperation": {
                    "code": "NULL",
                    "codeName": "CLOUD DATABASE(VPC) Null OP"
                },
                "isHa": true,
                "isMultiZone": true,
                "cloudPostgresqlConfigList": [
                    "sample_config=sample_value"
                ],
                "cloudPostgresqlServerInstanceList": [
                    {
                        "cloudPostgresqlServerInstanceNo": "****926",
                        "cloudPostgresqlServerName": "test-****-001-523a",
                        "cloudPostgresqlServerRole": {
                            "code": "M",
                            "codeName": "Primary"
                        },
                        "cloudPostgresqlServerInstanceStatusName": "running",
                        "cloudPostgresqlServerInstanceStatus": {
                            "code": "RUN",
                            "codeName": "CLOUD DATABASE(VPC) Server Running State"
                        },
                        "cloudPostgresqlServerInstanceOperation": {
                            "code": "NOOP",
                            "codeName": "CLOUD DATABASE(VPC) Server Null OP"
                        },
                        "regionCode": "KR",
                        "zoneCode": "KR-1",
                        "vpcNo": "****87",
                        "subnetNo": "****49",
                        "dataStorageSize": 10737418240,
                        "cpuCount": 2,
                        "memorySize": 8589934592
                    },
                    {
                        "cloudPostgresqlServerInstanceNo": "****932",
                        "cloudPostgresqlServerName": "test-****-002-523b",
                        "cloudPostgresqlServerRole": {
                            "code": "H",
                            "codeName": "Secondary"
                        },
                        "cloudPostgresqlServerInstanceStatusName": "running",
                        "cloudPostgresqlServerInstanceStatus": {
                            "code": "RUN",
                            "codeName": "CLOUD DATABASE(VPC) Server Running State"
                        },
                        "cloudPostgresqlServerInstanceOperation": {
                            "code": "NOOP",
                            "codeName": "CLOUD DATABASE(VPC) Server Null OP"
                        },
                        "regionCode": "KR",
                        "zoneCode": "KR-2",
                        "vpcNo": "****87",
                        "subnetNo": "****51",
                        "dataStorageSize": 10737418240,
                        "cpuCount": 2,
                        "memorySize": 8589934592
                    }
                ]
            }
        ],
        "requestId": "5092443c-****-****-****-7e916678d405",
        "returnCode": "0",
        "returnMessage": "success"
    }
}
  • responseFormatType=xml(デフォルト)の場合
<?xml version="1.0" encoding="UTF-8"?>
<getCloudPostgresqlInstanceListResponse>
    <requestId>5092443c-****-****-****-7e916678d405</requestId>
    <returnCode>0</returnCode>
    <returnMessage>success</returnMessage>
    <totalRows>1</totalRows>
    <cloudPostgresqlInstanceList>
        <cloudPostgresqlInstance>
            <cloudPostgresqlInstanceNo>****925</cloudPostgresqlInstanceNo>
            <cloudPostgresqlServiceName>test-****</cloudPostgresqlServiceName>
            <cloudPostgresqlInstanceStatusName>running</cloudPostgresqlInstanceStatusName>
            <cloudPostgresqlInstanceStatus>
                <code>CREAT</code>
                <codeName>CLOUD DATABASE(VPC) Created State</codeName>
            </cloudPostgresqlInstanceStatus>
            <cloudPostgresqlInstanceOperation>
                <code>NULL</code>
                <codeName>CLOUD DATABASE(VPC) Null OP</codeName>
            </cloudPostgresqlInstanceOperation>
            <isHa>true</isHa>
            <isMultiZone>true</isMultiZone>
            <cloudPostgresqlConfigList>
                <cloudPostgresqlConfig>sample_config=sample_value</cloudPostgresqlConfig>
            </cloudPostgresqlConfigList>
            <cloudPostgresqlServerInstanceList>
                <cloudPostgresqlServerInstance>
                    <cloudPostgresqlServerInstanceNo>****926</cloudPostgresqlServerInstanceNo>
                    <cloudPostgresqlServerName>test-****-001-523a</cloudPostgresqlServerName>
                    <cloudPostgresqlServerRole>
                        <code>M</code>
                        <codeName>Primary</codeName>
                    </cloudPostgresqlServerRole>
                    <cloudPostgresqlServerInstanceStatusName>running</cloudPostgresqlServerInstanceStatusName>
                    <cloudPostgresqlServerInstanceStatus>
                        <code>RUN</code>
                        <codeName>CLOUD DATABASE(VPC) Server Running State</codeName>
                    </cloudPostgresqlServerInstanceStatus>
                    <cloudPostgresqlServerInstanceOperation>
                        <code>NOOP</code>
                        <codeName>CLOUD DATABASE(VPC) Server Null OP</codeName>
                    </cloudPostgresqlServerInstanceOperation>
                    <regionCode>KR</regionCode>
                    <zoneCode>KR-1</zoneCode>
                    <vpcNo>****87</vpcNo>
                    <subnetNo>****49</subnetNo>
                    <dataStorageSize>10737418240</dataStorageSize>
                    <cpuCount>2</cpuCount>
                    <memorySize>8589934592</memorySize>
                </cloudPostgresqlServerInstance>
                <cloudPostgresqlServerInstance>
                    <cloudPostgresqlServerInstanceNo>****932</cloudPostgresqlServerInstanceNo>
                    <cloudPostgresqlServerName>test-****-002-523b</cloudPostgresqlServerName>
                    <cloudPostgresqlServerRole>
                        <code>H</code>
                        <codeName>Secondary</codeName>
                    </cloudPostgresqlServerRole>
                    <cloudPostgresqlServerInstanceStatusName>running</cloudPostgresqlServerInstanceStatusName>
                    <cloudPostgresqlServerInstanceStatus>
                        <code>RUN</code>
                        <codeName>CLOUD DATABASE(VPC) Server Running State</codeName>
                    </cloudPostgresqlServerInstanceStatus>
                    <cloudPostgresqlServerInstanceOperation>
                        <code>NOOP</code>
                        <codeName>CLOUD DATABASE(VPC) Server Null OP</codeName>
                    </cloudPostgresqlServerInstanceOperation>
                    <regionCode>KR</regionCode>
                    <zoneCode>KR-2</zoneCode>
                    <vpcNo>****87</vpcNo>
                    <subnetNo>****51</subnetNo>
                    <dataStorageSize>10737418240</dataStorageSize>
                    <cpuCount>2</cpuCount>
                    <memorySize>8589934592</memorySize>
                </cloudPostgresqlServerInstance>
            </cloudPostgresqlServerInstanceList>
        </cloudPostgresqlInstance>
    </cloudPostgresqlInstanceList>
</getCloudPostgresqlInstanceListResponse>