getLoadBalancerRuleList

Prev Next

VPC環境で利用できます。

ロードバランサリスナーに登録されたルールリストを照会します。

リクエスト

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

メソッド URI
GET /getLoadBalancerRuleList

リクエストヘッダ

Load Balancer APIで共通して使用されるヘッダの詳細は、Load Balancerの共通ヘッダをご参照ください。

リクエストクエリパラメータ

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

フィールド タイプ 必須の有無 説明
regionCode String Optional 照会対象のルールリストが登録されたロードバランサリスナーのリージョンコード
  • getRegionList照会結果の最初のリージョン(デフォルト)
  • getRegionListを通じて確認
loadBalancerListenerNo String Required ロードバランサリスナーの番号
responseFormatType String Optional レスポンス結果の形式
  • xml(デフォルト) | json

リクエスト例

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

curl --location 'https://ncloud.apigw.ntruss.com/vloadbalancer/v2/getLoadBalancerRuleList
?regionCode=KR
&loadBalancerListenerNo=******'
--header 'x-ncp-apigw-timestamp: {Timestamp}'
--header 'x-ncp-iam-access-key: {Access Key}'
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}'

レスポンス

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

レスポンスボディ

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

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

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

レスポンス例

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

<getLoadBalancerRuleListResponse>
    <requestId>76f1860a-da5f-4673-8999-3d550cdaee6e</requestId>
    <returnCode>0</returnCode>
    <returnMessage>success</returnMessage>
    <totalRows>1</totalRows>
    <loadBalancerRuleList>
        <loadBalancerRule>
            <loadBalancerListenerNo>******</loadBalancerListenerNo>
            <loadBalancerRuleNo>******</loadBalancerRuleNo>
            <priority>10000</priority>
            <loadBalancerRuleConditionList>
                <loadBalancerRuleCondition>
                    <ruleConditionType>
                        <code>DEFAULT</code>
                        <codeName>Default condition</codeName>
                    </ruleConditionType>
                </loadBalancerRuleCondition>
            </loadBalancerRuleConditionList>
            <loadBalancerRuleActionList>
                <loadBalancerRuleAction>
                    <ruleActionType>
                        <code>TARGET_GROUP</code>
                        <codeName>Target Group action</codeName>
                    </ruleActionType>
                    <targetGroupAction>
                        <targetGroupWeightList>
                            <targetGroupWeight>
                                <targetGroupNo>*******</targetGroupNo>
                                <weight>1</weight>
                            </targetGroupWeight>
                        </targetGroupWeightList>
                        <useStickySession>false</useStickySession>
                    </targetGroupAction>
                </loadBalancerRuleAction>
            </loadBalancerRuleActionList>
        </loadBalancerRule>
    </loadBalancerRuleList>
</getLoadBalancerRuleListResponse>