규칙 조회
    • PDF

    규칙 조회

    • PDF

    Article Summary

    개요

    규칙을 조회합니다

    요청

    요청 URL

    GET {CLOUD_IOT_CORE_API_URL}/rules/{ruleName}
    
    Content-Type: application/json; charset=utf-8
    x-ncp-apigw-timestamp: {Timestamp}
    x-ncp-iam-access-key: {Sub Account Access Key}
    x-ncp-apigw-signature-v2: {API Gateway Signature}
    

    Path Variables

    항목필수 여부타입설명
    ruleNameYesstring규칙 이름

    응답

    응답 바디

    {
        "status": "string",
        "body": {
            "rule": {
                "name": "string",
                "description": "string",
                "status": "string",
                "query": "string",
                "modifyTime": "localDateTime",
                "registerTime": "localDateTime",
                "filterTopic": "string"
            },
            "actions": {
                "matchActionList": [
                    {
                        "type": "string",
                        "relatedProduct": "string",
                        "displayName": "string",
                        "modifyTime": "localDateTime",
                        "registerTime": "localDateTime",
                        "relatedProductAction": "json"
                    }
                ],
                "errorAction": {
                    "type": "string",
                    "relatedProduct": "string",
                    "displayName": "string",
                    "modifyTime": "localDateTime",
                    "registerTime": "localDateTime",
                    "relatedProductAction": "json"
                }
            }
        }
    }
    
    항목타입설명
    statusstring응답 성공 여부
    body.content[].rule.namestring규칙 이름
    body.content[].rule.descriptionstring규칙 설명
    body.content[].rule.statusstring규칙 상태
    body.content[].rule.querystring규칙 쿼리
    body.content[].rule.modifyTimelocalDateTime최근 수정날짜
    body.content[].rule.registerTimelocalDateTime규칙 생성날짜
    body.content[].rule.filterTopicstring규칙 토픽
    body.content[].actions.matchActionList[].typestring액션 역할 (M: matchedAction, E: errorAction)
    body.content[].actions.matchActionList[].relatedProductstring액션 종류
    body.content[].actions.matchActionList[].displayNamestring액션 대표 이름
    body.content[].actions.matchActionList[].modifyTimestring액션 최근 수정날짜
    body.content[].actions.matchActionList[].registerTimestring액션 생성날짜
    body.content[].actions.matchActionList[].relatedProductActionjson액션 상세
    body.content[].actions.errorAction.typestring액션 역할 (M: matchedAction, E: errorAction)
    body.content[].actions.errorAction.relatedProductstring에러 액션 종류
    body.content[].actions.errorAction.displayNamestring에러 액션 대표 이름
    body.content[].actions.errorAction.modifyTimestring에러 액션 최근 수정날짜
    body.content[].actions.errorAction.registerTimestring에러 액션 생성날짜
    body.content[].actions.errorAction.relatedProductActionjson에러 액션 상세

    응답 예시

    {
        "status": "SUCCESS",
        "body": {
            "rule": {
                "name": "lux",
                "description": "turn off",
                "status": "ENABLE",
                "query": "select lux, bulb_id from \"myhome100/abc/+/abc\" where lux > -1",
                "modifyTime": "2020-09-27 12:52:08",
                "registerTime": "2020-09-27 12:52:08",
                "filterTopic": "myhome100/abc/+/abc"
            },
            "actions": {
                "matchActionList": [
                    {
                        "type": "M",
                        "relatedProduct": "REPUBLISH",
                        "displayName": "republish_a",
                        "modifyTime": "2020-09-27 12:52:08",
                        "registerTime": "2020-09-27 12:52:08",
                        "relatedProductAction": {
                            "topic": "republish_a",
                            "version": 1
                        }
                    }
                ],
                "errorAction": {
                    "type": "E",
                    "relatedProduct": "REPUBLISH",
                    "displayName": "republish_a",
                    "modifyTime": "2020-09-27 12:52:08",
                    "registerTime": "2020-09-27 12:52:08",
                    "relatedProductAction": {
                        "topic": "republish_a",
                        "version": 1
                    }
                }
            }
        }
    }
    

    이 문서가 도움이 되었습니까?

    What's Next
    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.