CreateRuleDirectly
    • PDF

    CreateRuleDirectly

    • PDF

    Article Summary

    概要

    監視対象グループと監視項目グループを作成せずに、監視対象と監視項目を指定して直接Event Ruleを作成します。

    リクエスト

    API URL

    URL: https://cw.apigw.ntruss.com/cw_fea/real/cw/api/rule/group/ruleGrp/createDirectly
    Method: POST
    

    リクエストヘッダ

    共通設定に明示されたリクエストヘッダが必要です。

    Content-Type: application/json
    x-ncp-apigw-signature-v2: {generated signature}
    x-ncp-apigw-timestamp: {current timestamp}
    x-ncp-iam-access-key: {your iam access key}
    

    リクエストボディ

    DirectRuleGroupCreateDto

    リクエスト例

    POST /cw_fea/real/cw/api/rule/group/ruleGrp/createDirectly
    Host: cw.apigw.ntruss.com
    Content-Type: application/json
    x-ncp-apigw-signature-v2: {generated signature}
    x-ncp-apigw-timestamp: {current timestamp}
    x-ncp-iam-access-key: {your iam access key}
    
    Payload:
    {
        "groupDesc": "新しいEvent Ruleを直接作成します。",
        "groupName": "eventRuleDirect001",
        "metricsGroup": {
            "groupDesc": "監視項目グループを直接作成します。",
            "groupName": "metricsGroup001",
            "metricsGroupItems": [
                {
                    "calculation": "COUNT",
                    "condition": "GT",
                    "desc": "string",
                    "dimensions": [
                        {
                            "dim": "type",
                            "val": "svr"
                        }
                    ],
                    "duration": 1,
                    "eventLevel": "INFO",
                    "metric": "avg_write_cnt",
                    "threshold": 0.7
                }
            ],
            "prodKey": "xxxxxxxxxxxxxxxxxx",
            "temporaryGroup": true
        },
        "monitorGroup": {
            "groupDesc": "監視対象グループを直接作成します。",
            "groupName": "monitorGroup001",
            "monitorGroupItemList": [
                {
                    "resourceId": "resourceId001"
                }
            ],
            "prodKey": "xxxxxxxxxxxxxxxxxx",
            "temporaryGroup": true
        },
        "prodKey": "xxxxxxxxxxxxxxxxxx",
        "recipientNotifications": [
            {
                "groupName": "通知対象者グループ001",
                "groupNum": xx,
                "notifyTypes": [
                    "SMS",
                    "EMAIL"
                ]
            }
        ]
    }
    
    

    レスポンス例

    エラーなしに作成が完了した場合、HTTP code 200と作成されたEvent Ruleのidがレスポンスとしてリターンされます。

    "xxxxxxxxxxxxxxxxxx"
    

    この記事は役に立ちましたか?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.