

Doc AWS SDK 예제 GitHub 리포지토리에서 더 많은 SDK 예제를 사용할 수 있습니다. [AWS](https://github.com/awsdocs/aws-doc-sdk-examples) 

기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.

# AWS IoT Things Graph 를 사용한 예제 AWS CLI
<a name="cli_2_iotthingsgraph_code_examples"></a>

다음 코드 예제에서는와 AWS Command Line Interface 함께를 사용하여 작업을 수행하고 일반적인 시나리오를 구현하는 방법을 보여줍니다 AWS IoT Things Graph.

*작업*은 대규모 프로그램에서 발췌한 코드이며 컨텍스트에 맞춰 실행해야 합니다. 작업은 개별 서비스 함수를 직접적으로 호출하는 방법을 보여주며 관련 시나리오의 컨텍스트에 맞는 작업을 볼 수 있습니다.

각 예시에는 전체 소스 코드에 대한 링크가 포함되어 있으며, 여기에서 컨텍스트에 맞춰 코드를 설정하고 실행하는 방법에 대한 지침을 찾을 수 있습니다.

**Topics**
+ [작업](#actions)

## 작업
<a name="actions"></a>

### `associate-entity-to-thing`
<a name="iotthingsgraph_AssociateEntityToThing_cli_2_topic"></a>

다음 코드 예시에서는 `associate-entity-to-thing` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**사물을 디바이스와 연결하는 방법**  
다음 `associate-entity-to-thing` 예시에서는 사물을 디바이스와 연결합니다. 이 예시에서는 퍼블릭 네임스페이스에 있는 모션 센서 디바이스를 사용합니다.  

```
aws iotthingsgraph associate-entity-to-thing \
    --thing-name "MotionSensorName" \
    --entity-id "urn:tdm:aws/examples:Device:HCSR501MotionSensor"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating and Uploading Models](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-models-gs.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [AssociateEntityToThing](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/associate-entity-to-thing.html) 섹션을 참조하세요.

### `create-flow-template`
<a name="iotthingsgraph_CreateFlowTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `create-flow-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름 생성**  
다음 `create-flow-template` 예시에서는 흐름(워크플로)을 생성합니다. `MyFlowDefinition`의 값은 흐름을 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph create-flow-template \
    --definition language=GRAPHQL,text="MyFlowDefinition"
```
출력:  

```
{
    "summary": {
        "createdAt": 1559248067.545,
        "id": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
        "revisionNumber": 1
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [CreateFlowTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/create-flow-template.html) 섹션을 참조하세요.

### `create-system-instance`
<a name="iotthingsgraph_CreateSystemInstance_cli_2_topic"></a>

다음 코드 예시에서는 `create-system-instance` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 인스턴스 생성**  
다음 `create-system-instance` 예시에서는 시스템 인스턴스를 생성합니다. `MySystemInstanceDefinition`의 값은 시스템 인스턴스를 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph create-system-instance -\
    -definition language=GRAPHQL,text="MySystemInstanceDefinition" \
    --target CLOUD \
    --flow-actions-role-arn myRoleARN
```
출력:  

```
{
    "summary": {
        "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room218",
        "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218",
        "status": "NOT_DEPLOYED",
        "target": "CLOUD",
        "createdAt": 1559249315.208,
        "updatedAt": 1559249315.208
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [CreateSystemInstance](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/create-system-instance.html) 섹션을 참조하세요.

### `create-system-template`
<a name="iotthingsgraph_CreateSystemTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `create-system-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 생성**  
다음 `create-system-template` 예시에서는 시스템을 생성합니다. MySystemDefinition의 값은 시스템을 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph create-system-template \
    --definition language=GRAPHQL,text="MySystemDefinition"
```
출력:  

```
{
    "summary": {
        "createdAt": 1559249776.254,
        "id": "urn:tdm:us-west-2/123456789012/default:System:MySystem",
        "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:System/default/MySystem",
        "revisionNumber": 1
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating Systems](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy-systems.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [CreateSystemTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/create-system-template.html) 섹션을 참조하세요.

### `delete-flow-template`
<a name="iotthingsgraph_DeleteFlowTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `delete-flow-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름을 삭제하는 방법**  
다음 `delete-flow-template` 예시에서는 흐름(워크플로)을 삭제합니다.  

```
aws iotthingsgraph delete-flow-template \
    --id "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포에 대한 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeleteFlowTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/delete-flow-template.html) 섹션을 참조하세요.

### `delete-namespace`
<a name="iotthingsgraph_DeleteNamespace_cli_2_topic"></a>

다음 코드 예시에서는 `delete-namespace` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**네임스페이스 삭제**  
다음 `delete-namespace` 예시에서는 네임스페이스를 삭제합니다.  

```
aws iotthingsgraph delete-namespace
```
출력:  

```
{
   "namespaceArn": "arn:aws:iotthingsgraph:us-west-2:123456789012",
   "namespaceName": "us-west-2/123456789012/default"
}
```
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포의 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeleteNamespace](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/delete-namespace.html) 섹션을 참조하세요.

### `delete-system-instance`
<a name="iotthingsgraph_DeleteSystemInstance_cli_2_topic"></a>

다음 코드 예시에서는 `delete-system-instance` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 인스턴스 삭제**  
다음 `delete-system-instance` 예시에서는 시스템 인스턴스를 삭제합니다.  

```
aws iotthingsgraph delete-system-instance \
    --id "urn:tdm:us-west-2/123456789012/default:Deployment:Room218"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포에 대한 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeleteSystemInstance](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/delete-system-instance.html) 섹션을 참조하세요.

### `delete-system-template`
<a name="iotthingsgraph_DeleteSystemTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `delete-system-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 삭제**  
다음 `delete-system-template` 예시에서는 시스템을 삭제합니다.  

```
aws iotthingsgraph delete-system-template \
    --id "urn:tdm:us-west-2/123456789012/default:System:MySystem"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포의 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeleteSystemTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/delete-system-template.html) 섹션을 참조하세요.

### `deploy-system-instance`
<a name="iotthingsgraph_DeploySystemInstance_cli_2_topic"></a>

다음 코드 예시에서는 `deploy-system-instance` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 인스턴스를 배포하는 방법**  
다음 `delete-system-template` 예시에서는 시스템 인스턴스를 배포합니다.  

```
aws iotthingsgraph deploy-system-instance \
    --id "urn:tdm:us-west-2/123456789012/default:Deployment:Room218"
```
출력:  

```
{
   "summary": {
      "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment:Room218",
      "createdAt": 1559249776.254,
      "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room218",
      "status": "DEPLOYED_IN_TARGET",
      "target": "CLOUD",
      "updatedAt": 1559249776.254
   }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeploySystemInstance](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/deploy-system-instance.html) 섹션을 참조하세요.

### `deprecate-flow-template`
<a name="iotthingsgraph_DeprecateFlowTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `deprecate-flow-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름 사용을 중단하는 방법**  
다음 `deprecate-flow-template` 예시에서는 흐름(워크플로) 사용을 중지합니다.  

```
aws iotthingsgraph deprecate-flow-template \
    --id "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포에 대한 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeprecateFlowTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/deprecate-flow-template.html) 섹션을 참조하세요.

### `deprecate-system-template`
<a name="iotthingsgraph_DeprecateSystemTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `deprecate-system-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 사용을 중단하는 방법**  
다음 `deprecate-system-template` 예시에서는 시스템 사용을 중지합니다.  

```
aws iotthingsgraph deprecate-system-template \
    --id "urn:tdm:us-west-2/123456789012/default:System:MySystem"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포에 대한 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DeprecateSystemTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/deprecate-system-template.html) 섹션을 참조하세요.

### `describe-namespace`
<a name="iotthingsgraph_DescribeNamespace_cli_2_topic"></a>

다음 코드 예시에서는 `describe-namespace` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**네임스페이스에 대한 설명을 가져오는 방법**  
다음 `describe-namespace` 예시에서는 네임스페이스 설명을 가져옵니다.  

```
aws iotthingsgraph describe-namespace
```
출력:  

```
{
    "namespaceName": "us-west-2/123456789012/default",
    "trackingNamespaceName": "aws",
    "trackingNamespaceVersion": 1,
    "namespaceVersion": 5
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Namespaces](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-whatis-namespace.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DescribeNamespace](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/describe-namespace.html) 섹션을 참조하세요.

### `dissociate-entity-from-thing`
<a name="iotthingsgraph_DissociateEntityFromThing_cli_2_topic"></a>

다음 코드 예시에서는 `dissociate-entity-from-thing` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**디바이스에서 사물을 연결 해제하는 방법**  
다음 `dissociate-entity-from-thing` 예시에서는 디바이스에서 사물을 연결 해제합니다.  

```
aws iotthingsgraph dissociate-entity-from-thing \
    --thing-name "MotionSensorName" \
    --entity-type "DEVICE"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating and Uploading Models](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-models-gs.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [DissociateEntityFromThing](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/dissociate-entity-from-thing.html) 섹션을 참조하세요.

### `get-entities`
<a name="iotthingsgraph_GetEntities_cli_2_topic"></a>

다음 코드 예시에서는 `get-entities` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**엔터티에 대한 정의를 가져오는 방법**  
다음 `get-entities` 예시에서는 디바이스 모델의 정의를 가져옵니다.  

```
aws iotthingsgraph get-entities \
    --ids "urn:tdm:aws/examples:DeviceModel:MotionSensor"
```
출력:  

```
{
    "descriptions": [
        {
            "id": "urn:tdm:aws/examples:DeviceModel:MotionSensor",
            "type": "DEVICE_MODEL",
            "createdAt": 1559256190.599,
            "definition": {
                "language": "GRAPHQL",
                "text": "##\n# Specification of motion sensor devices interface.\n##\ntype MotionSensor @deviceModel(id: \"urn:tdm:aws/examples:deviceModel:MotionSensor\",\n        capability: \"urn:tdm:aws/examples:capability:MotionSensorCapability\") {ignore:void}"
            }
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating and Uploading Models](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-models-gs.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetEntities](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-entities.html) 섹션을 참조하세요.

### `get-flow-template-revisions`
<a name="iotthingsgraph_GetFlowTemplateRevisions_cli_2_topic"></a>

다음 코드 예시에서는 `get-flow-template-revisions` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름에 대한 개정 정보를 가져오는 방법**  
다음 `get-flow-template-revisions` 예시에서는 흐름(워크플로)의 개정 정보를 가져옵니다.  

```
aws iotthingsgraph get-flow-template-revisions \
    --id urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow
```
출력:  

```
{
    "summaries": [
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
            "revisionNumber": 1,
            "createdAt": 1559247540.292
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetFlowTemplateRevisions](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-flow-template-revisions.html) 섹션을 참조하세요.

### `get-flow-template`
<a name="iotthingsgraph_GetFlowTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `get-flow-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름 정의 가져오기**  
다음 `get-flow-template` 예시에서는 흐름(워크플로) 정의를 가져옵니다.  

```
aws iotthingsgraph get-flow-template \
    --id "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow"
```
출력:  

```
{
    "description": {
        "summary": {
            "id": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
            "revisionNumber": 1,
            "createdAt": 1559247540.292
        },
        "definition": {
            "language": "GRAPHQL",
            "text": "{\nquery MyFlow($camera: string!, $screen: string!) @workflowType(id: \"urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow\") @annotation(type: \"tgc:FlowEvent\", id: \"sledged790c1b2bcd949e09da0c9bfc077f79d\", x: 1586, y: 653) @triggers(definition: \"{MotionSensor(description: \\\"\\\") @position(x: 1045, y: 635.6666564941406) {\\n  condition(expr: \\\"devices[name == \\\\\\\"motionSensor\\\\\\\"].events[name == \\\\\\\"StateChanged\\\\\\\"].lastEvent\\\")\\n  action(expr: \\\"\\\")\\n}}\") {\n  variables {\n    cameraResult @property(id: \"urn:tdm:aws/examples:property:CameraStateProperty\")\n  }\n  steps {\n    step(name: \"Camera\", outEvent: [\"sledged790c1b2bcd949e09da0c9bfc077f79d\"]) @position(x: 1377, y: 638.6666564941406) {\n      DeviceActivity(deviceModel: \"urn:tdm:aws/examples:deviceModel:Camera\", out: \"cameraResult\", deviceId: \"${camera}\") {\n        capture\n      }\n    }\n    step(name: \"Screen\", inEvent: [\"sledged790c1b2bcd949e09da0c9bfc077f79d\"]) @position(x: 1675.6666870117188, y: 637.9999847412109) {\n      DeviceActivity(deviceModel: \"urn:tdm:aws/examples:deviceModel:Screen\", deviceId: \"${screen}\") {\n        display(imageUrl: \"${cameraResult.lastClickedImage}\")\n      }\n    }\n  }\n}\n}"
        },
        "validatedNamespaceVersion": 5
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetFlowTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-flow-template.html) 섹션을 참조하세요.

### `get-namespace-deletion-status`
<a name="iotthingsgraph_GetNamespaceDeletionStatus_cli_2_topic"></a>

다음 코드 예시에서는 `get-namespace-deletion-status` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**네임스페이스 삭제 태스크의 상태를 가져오기**  
다음 `get-namespace-deletion-status` 예시에서는 네임스페이스 삭제 태스크의 상태를 가져옵니다.  

```
aws iotthingsgraph get-namespace-deletion-status
```
출력:  

```
{
   "namespaceArn": "arn:aws:iotthingsgraph:us-west-2:123456789012",
   "namespaceName": "us-west-2/123456789012/default"
   "status": "SUCCEEDED "
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Namespaces](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-whatis-namespace.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetNamespaceDeletionStatus](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-namespace-deletion-status.html) 섹션을 참조하세요.

### `get-system-instance`
<a name="iotthingsgraph_GetSystemInstance_cli_2_topic"></a>

다음 코드 예시에서는 `get-system-instance` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 인스턴스 가져오기**  
다음 `get-system-instance` 예시에서는 시스템 인스턴스의 정의를 가져옵니다.  

```
aws iotthingsgraph get-system-instance \
    --id "urn:tdm:us-west-2/123456789012/default:Deployment:Room218"
```
출력:  

```
{
    "description": {
        "summary": {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room218",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218",
            "status": "NOT_DEPLOYED",
            "target": "CLOUD",
            "createdAt": 1559249315.208,
            "updatedAt": 1559249315.208
        },
        "definition": {
            "language": "GRAPHQL",
            "text": "{\r\nquery Room218 @deployment(id: \"urn:tdm:us-west-2/123456789012/default:Deployment:Room218\", systemId: \"urn:tdm:us-west-2/123456789012/default:System:SecurityFlow\") {\r\n    motionSensor(deviceId: \"MotionSensorName\")\r\n    screen(deviceId: \"ScreenName\")\r\n    camera(deviceId: \"CameraName\") \r\n    triggers {MotionEventTrigger(description: \"a trigger\") {  \r\n    condition(expr: \"devices[name == 'motionSensor'].events[name == 'StateChanged'].lastEvent\") \r\n    action(expr: \"ThingsGraph.startFlow('SecurityFlow', bindings[name == 'camera'].deviceId, bindings[name == 'screen'].deviceId)\")\r\n    }\r\n   }\r\n  }\r\n  }"
        },
        "metricsConfiguration": {
            "cloudMetricEnabled": false
        },
        "validatedNamespaceVersion": 5,
        "flowActionsRoleArn": "arn:aws:iam::123456789012:role/ThingsGraphRole"
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetSystemInstance](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-system-instance.html) 섹션을 참조하세요.

### `get-system-template-revisions`
<a name="iotthingsgraph_GetSystemTemplateRevisions_cli_2_topic"></a>

다음 코드 예시에서는 `get-system-template-revisions` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템에 대한 개정 정보를 가져오는 방법**  
다음 `get-system-template-revisions` 예시에서는 시스템의 개정 정보를 가져옵니다.  

```
aws iotthingsgraph get-system-template-revisions \
    --id "urn:tdm:us-west-2/123456789012/default:System:MySystem"
```
출력:  

```
{
    "summaries": [
        {
            "id": "urn:tdm:us-west-2/123456789012/default:System:MySystem",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:System/default/MySystem",
            "revisionNumber": 1,
            "createdAt": 1559247540.656
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetSystemTemplateRevisions](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-system-template-revisions.html) 섹션을 참조하세요.

### `get-system-template`
<a name="iotthingsgraph_GetSystemTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `get-system-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템을 가져오는 방법**  
다음 `get-system-template` 예시에서는 시스템 정의를 가져옵니다.  

```
aws iotthingsgraph get-system-template \
    --id "urn:tdm:us-west-2/123456789012/default:System:MySystem"
```
출력:  

```
{
    "description": {
        "summary": {
            "id": "urn:tdm:us-west-2/123456789012/default:System:MySystem",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:System/default/MyFlow",
            "revisionNumber": 1,
            "createdAt": 1559247540.656
        },
        "definition": {
            "language": "GRAPHQL",
            "text": "{\ntype MySystem @systemType(id: \"urn:tdm:us-west-2/123456789012/default:System:MySystem\", description: \"\") {\n  camera: Camera @thing(id: \"urn:tdm:aws/examples:deviceModel:Camera\")\n  screen: Screen @thing(id: \"urn:tdm:aws/examples:deviceModel:Screen\")\n  motionSensor: MotionSensor @thing(id: \"urn:tdm:aws/examples:deviceModel:MotionSensor\")\n  MyFlow: MyFlow @workflow(id: \"urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow\")\n}\n}"
        },
        "validatedNamespaceVersion": 5
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetSystemTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-system-template.html) 섹션을 참조하세요.

### `get-upload-status`
<a name="iotthingsgraph_GetUploadStatus_cli_2_topic"></a>

다음 코드 예시에서는 `get-upload-status` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**엔터티 업로드 상태를 가져오는 방법**  
다음 `get-upload-status` 예시에서는 엔터티 업로드 작업의 상태를 가져옵니다. `MyUploadId`의 값은 `upload-entity-definitions` 작업에서 반환되는 ID 값입니다.  

```
aws iotthingsgraph get-upload-status \
    --upload-id "MyUploadId"
```
출력:  

```
{
    "namespaceName": "us-west-2/123456789012/default",
    "namespaceVersion": 5,
    "uploadId": "f6294f1e-b109-4bbe-9073-f451a2dda2da",
    "uploadStatus": "SUCCEEDED"
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Modeling Entities](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-modelmanagement.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [GetUploadStatus](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/get-upload-status.html) 섹션을 참조하세요.

### `list-flow-execution-messages`
<a name="iotthingsgraph_ListFlowExecutionMessages_cli_2_topic"></a>

다음 코드 예시에서는 `list-flow-execution-messages` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름 실행의 이벤트에 대한 정보를 가져오는 방법**  
다음 `list-flow-execution-messages` 예시에서는 흐름 실행의 이벤트 정보를 가져옵니다.  

```
aws iotthingsgraph list-flow-execution-messages \
    --flow-execution-id "urn:tdm:us-west-2/123456789012/default:Workflow:SecurityFlow_2019-05-11T19:39:55.317Z_MotionSensor_69b151ad-a611-42f5-ac21-fe537f9868ad"
```
출력:  

```
{
    "messages": [
        {
         "eventType": "EXECUTION_STARTED",
         "messageId": "f6294f1e-b109-4bbe-9073-f451a2dda2da",
         "payload": "Flow execution started",
         "timestamp": 1559247540.656
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [ListFlowExecutionMessages](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/list-flow-execution-messages.html)를 참조하세요.

### `list-tags-for-resource`
<a name="iotthingsgraph_ListTagsForResource_cli_2_topic"></a>

다음 코드 예시에서는 `list-tags-for-resource` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**리소스의 모든 태그 나열**  
다음 `list-tags-for-resource` 예시에서는 AWS IoT Things Graph 리소스의 모든 태그를 나열합니다.  

```
aws iotthingsgraph list-tags-for-resource \
    --resource-arn "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218"
```
출력:  

```
{
   "tags": [
      {
         "key": "Type",
         "value": "Residential"
      }
   ]
}
```
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 리소스 태그 지정을 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/tagging-tg.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [ListTagsForResource](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/list-tags-for-resource.html)를 참조하세요.

### `search-entities`
<a name="iotthingsgraph_SearchEntities_cli_2_topic"></a>

다음 코드 예시에서는 `search-entities` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**엔터티를 검색하는 방법**  
다음 `search-entities` 예시에서는 유형 `EVENT`의 모든 엔터티를 검색합니다.  

```
aws iotthingsgraph search-entities \
    --entity-types "EVENT"
```
출력:  

```
{
    "descriptions": [
        {
            "id": "urn:tdm:aws/examples:Event:MotionSensorEvent",
            "type": "EVENT",
            "definition": {
                "language": "GRAPHQL",
                "text": "##\n# Description of events emitted by motion sensor.\n##\ntype MotionSensorEvent @eventType(id: \"urn:tdm:aws/examples:event:MotionSensorEvent\",\n            payload: \"urn:tdm:aws/examples:property:MotionSensorStateProperty\") {ignore:void}"
            }
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Event:CameraClickedEventV2",
            "type": "EVENT",
            "definition": {
                "language": "GRAPHQL",
                "text": "type CameraClickedEventV2 @eventType(id: \"urn:tdm:us-west-2/123456789012/default:event:CameraClickedEventV2\",\r\npayload: \"urn:tdm:aws:Property:Boolean\"){ignore:void}"
            }
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Event:MotionSensorEventV2",
            "type": "EVENT",
            "definition": {
                "language": "GRAPHQL",
                "text": "# Event emitted by the motion sensor.\r\ntype MotionSensorEventV2 @eventType(id: \"urn:tdm:us-west-2/123456789012/default:event:MotionSensorEventV2\",\r\npayload: \"urn:tdm:us-west-2/123456789012/default:property:MotionSensorStateProperty2\") {ignore:void}"
            }
        }
    ],
    "nextToken": "urn:tdm:us-west-2/123456789012/default:Event:MotionSensorEventV2"
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [AWS IoT Things Graph Data Model Reference](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-models.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchEntities](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-entities.html) 섹션을 참조하세요.

### `search-flow-executions`
<a name="iotthingsgraph_SearchFlowExecutions_cli_2_topic"></a>

다음 코드 예시에서는 `search-flow-executions` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름 실행을 검색하는 방법**  
다음 `search-flow-executions` 예시에서는 지정된 시스템 인스턴스에서 흐름의 모든 실행을 검색합니다.  

```
aws iotthingsgraph search-flow-executions \
    --system-instance-id "urn:tdm:us-west-2/123456789012/default:Deployment:Room218"
```
출력:  

```
{
   "summaries": [
      {
         "createdAt": 1559247540.656,
         "flowExecutionId": "f6294f1e-b109-4bbe-9073-f451a2dda2da",
         "flowTemplateId": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
         "status": "RUNNING ",
         "systemInstanceId": "urn:tdm:us-west-2/123456789012/default:System:MySystem",
         "updatedAt": 1559247540.656
      }
   ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchFlowExecutions](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-flow-executions.html) 섹션을 참조하세요.

### `search-flow-templates`
<a name="iotthingsgraph_SearchFlowTemplates_cli_2_topic"></a>

다음 코드 예시에서는 `search-flow-templates` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름(또는 워크플로)을 검색하는 방법**  
다음 `search-flow-templates` 예시에서는 카메라 디바이스 모델을 포함하는 모든 흐름(워크플로)을 검색합니다.  

```
aws iotthingsgraph search-flow-templates \
    --filters name="DEVICE_MODEL_ID",value="urn:tdm:aws/examples:DeviceModel:Camera"
```
출력:  

```
{
    "summaries": [
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
            "revisionNumber": 1,
            "createdAt": 1559247540.292
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Workflow:SecurityFlow",
            "revisionNumber": 3,
            "createdAt": 1548283099.27
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchFlowTemplates](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-flow-templates.html) 섹션을 참조하세요.

### `search-system-instances`
<a name="iotthingsgraph_SearchSystemInstances_cli_2_topic"></a>

다음 코드 예시에서는 `search-system-instances` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 인스턴스를 검색하는 방법**  
다음 `search-system-instances` 예시에서는 지정된 흐름을 포함하는 모든 시스템을 검색합니다.  

```
aws iotthingsgraph search-system-instances \
    --filters name="SYSTEM_TEMPLATE_ID",value="urn:tdm:us-west-2/123456789012/default:System:SecurityFlow"
```
출력:  

```
{
    "summaries": [
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:DeploymentForSample",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/DeploymentForSample",
            "status": "NOT_DEPLOYED",
            "target": "GREENGRASS",
            "greengrassGroupName": "ThingsGraphGrnGr",
            "createdAt": 1555716314.707,
            "updatedAt": 1555716314.707
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:MockDeployment",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/MockDeployment",
            "status": "DELETED_IN_TARGET",
            "target": "GREENGRASS",
            "greengrassGroupName": "ThingsGraphGrnGr",
            "createdAt": 1549416462.049,
            "updatedAt": 1549416722.361,
            "greengrassGroupId": "01d04b07-2a51-467f-9d03-0c90b3cdcaaf",
            "greengrassGroupVersionId": "7365aed7-2d3e-4d13-aad8-75443d45eb05"
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:MockDeployment2",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/MockDeployment2",
            "status": "DEPLOYED_IN_TARGET",
            "target": "GREENGRASS",
            "greengrassGroupName": "ThingsGraphGrnGr",
            "createdAt": 1549572385.774,
            "updatedAt": 1549572418.408,
            "greengrassGroupId": "01d04b07-2a51-467f-9d03-0c90b3cdcaaf",
            "greengrassGroupVersionId": "bfa70ab3-2bf7-409c-a4d4-bc8328ae5b86"
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room215",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room215",
            "status": "NOT_DEPLOYED",
            "target": "GREENGRASS",
            "greengrassGroupName": "ThingsGraphGG",
            "createdAt": 1547056918.413,
            "updatedAt": 1547056918.413
        },
        {
            "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room218",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218",
            "status": "NOT_DEPLOYED",
            "target": "CLOUD",
            "createdAt": 1559249315.208,
            "updatedAt": 1559249315.208
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Systems and Flow Configurations](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchSystemInstances](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-system-instances.html) 섹션을 참조하세요.

### `search-system-templates`
<a name="iotthingsgraph_SearchSystemTemplates_cli_2_topic"></a>

다음 코드 예시에서는 `search-system-templates` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템 검색**  
다음 `search-system-templates` 예시에서는 지정된 흐름이 포함된 모든 시스템을 검색합니다.  

```
aws iotthingsgraph search-system-templates \
    --filters name="FLOW_TEMPLATE_ID",value="urn:tdm:us-west-2/123456789012/default:Workflow:SecurityFlow"
```
출력:  

```
{
    "summaries": [
        {
            "id": "urn:tdm:us-west-2/123456789012/default:System:SecurityFlow",
            "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:System/default/SecurityFlow",
            "revisionNumber": 1,
            "createdAt": 1548283099.433
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchSystemTemplates](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-system-templates.html) 섹션을 참조하세요.

### `search-things`
<a name="iotthingsgraph_SearchThings_cli_2_topic"></a>

다음 코드 예시에서는 `search-things` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**디바이스 및 디바이스 모델과 연결된 사물을 검색하는 방법**  
다음 `search-things` 예시에서는 HCSR501MotionSensor 디바이스에 연결된 모든 사물을 검색합니다.  

```
aws iotthingsgraph search-things \
    --entity-id "urn:tdm:aws/examples:Device:HCSR501MotionSensor"
```
출력:  

```
{
    "things": [
        {
            "thingArn": "arn:aws:iot:us-west-2:123456789012:thing/MotionSensor1",
            "thingName": "MotionSensor1"
        },
        {
            "thingArn": "arn:aws:iot:us-west-2:123456789012:thing/TG_MS",
            "thingName": "TG_MS"
        }
    ]
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating and Uploading Models](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-models-gs.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [SearchThings](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/search-things.html) 섹션을 참조하세요.

### `tag-resource`
<a name="iotthingsgraph_TagResource_cli_2_topic"></a>

다음 코드 예시에서는 `tag-resource` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**리소스의 태그 생성**  
다음 `tag-resource` 예시에서는 지정된 리소스에 대한 태그를 만듭니다.  

```
aws iotthingsgraph tag-resource \
    --resource-arn "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218" \
    --tags key="Type",value="Residential"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 리소스 태그 지정을 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/tagging-tg.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [TagResource](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/tag-resource.html)를 참조하세요.

### `undeploy-system-instance`
<a name="iotthingsgraph_UndeploySystemInstance_cli_2_topic"></a>

다음 코드 예시에서는 `undeploy-system-instance` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**대상에서 시스템 인스턴스를 배포 취소하는 방법**  
다음 `undeploy-system-instance` 예시에서는 대상에서 시스템 인스턴스를 제거합니다.  

```
aws iotthingsgraph undeploy-system-instance \
    --id "urn:tdm:us-west-2/123456789012/default:Deployment:Room215"
```
출력:  

```
{
    "summary": {
        "id": "urn:tdm:us-west-2/123456789012/default:Deployment:Room215",
        "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room215",
        "status": "PENDING_DELETE",
        "target": "GREENGRASS",
        "greengrassGroupName": "ThingsGraphGrnGr",
        "createdAt": 1553189694.255,
        "updatedAt": 1559344549.601,
        "greengrassGroupId": "01d04b07-2a51-467f-9d03-0c90b3cdcaaf",
        "greengrassGroupVersionId": "731b371d-d644-4b67-ac64-3934e99b75d7"
    }
}
```
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 개체, 흐름, 시스템 및 배포에 대한 수명 주기 관리를 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-lifecycle.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [UndeploySystemInstance](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/undeploy-system-instance.html) 섹션을 참조하세요.

### `untag-resource`
<a name="iotthingsgraph_UntagResource_cli_2_topic"></a>

다음 코드 예시에서는 `untag-resource` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**리소스의 태그 제거**  
다음 `untag-resource` 예시에서는 지정된 리소스의 태그를 제거합니다.  

```
aws iotthingsgraph untag-resource \
    --resource-arn "arn:aws:iotthingsgraph:us-west-2:123456789012:Deployment/default/Room218" \
    --tag-keys "Type"
```
이 명령은 출력을 생성하지 않습니다.  
자세한 내용은 [AWS IoT Things Graph 사용 설명서의 IoT Things Graph 리소스 태그 지정을 참조하세요](https://docs.aws.amazon.com/thingsgraph/latest/ug/tagging-tg.html). *AWS IoT *  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [UntagResource](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/untag-resource.html)를 참조하세요.

### `update-flow-template`
<a name="iotthingsgraph_UpdateFlowTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `update-flow-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**흐름을 업데이트하는 방법**  
다음 `update-flow-template` 예시에서는 흐름(워크플로)을 업데이트합니다. `MyFlowDefinition`의 값은 흐름을 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph update-flow-template \
    --id "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow" \
    --definition language=GRAPHQL,text="MyFlowDefinition"
```
출력:  

```
{
    "summary": {
        "createdAt": 1559248067.545,
        "id": "urn:tdm:us-west-2/123456789012/default:Workflow:MyFlow",
        "revisionNumber": 2
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Working with Flows](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-workflows.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [UpdateFlowTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/update-flow-template.html) 섹션을 참조하세요.

### `update-system-template`
<a name="iotthingsgraph_UpdateSystemTemplate_cli_2_topic"></a>

다음 코드 예시에서는 `update-system-template` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**시스템을 업데이트하는 방법**  
다음 `update-system-template` 예시에서는 시스템을 업데이트합니다. `MySystemDefinition`의 값은 시스템을 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph update-system-template \
    --id "urn:tdm:us-west-2/123456789012/default:System:MySystem" \
    --definition language=GRAPHQL,text="MySystemDefinition"
```
출력:  

```
{
    "summary": {
        "createdAt": 1559249776.254,
        "id": "urn:tdm:us-west-2/123456789012/default:System:MySystem",
        "arn": "arn:aws:iotthingsgraph:us-west-2:123456789012:System/default/MySystem",
        "revisionNumber": 2
    }
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Creating Systems](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-sysdeploy-systems.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [UpdateSystemTemplate](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/update-system-template.html) 섹션을 참조하세요.

### `upload-entity-definitions`
<a name="iotthingsgraph_UploadEntityDefinitions_cli_2_topic"></a>

다음 코드 예시에서는 `upload-entity-definitions` 코드를 사용하는 방법을 보여줍니다.

**AWS CLI**  
**개체 정의를 업로드하는 방법**  
다음 `upload-entity-definitions` 예시에서는 네임스페이스에 엔터티 정의를 업로드합니다. `MyEntityDefinitions`의 값은 엔터티를 모델링하는 GraphQL입니다.  

```
aws iotthingsgraph upload-entity-definitions \
    --document language=GRAPHQL,text="MyEntityDefinitions"
```
출력:  

```
{
    "uploadId": "f6294f1e-b109-4bbe-9073-f451a2dda2da"
}
```
자세한 내용은 *AWS IoT 사물 그래프 사용자 안내서*의 [Modeling Entities](https://docs.aws.amazon.com/thingsgraph/latest/ug/iot-tg-modelmanagement.html)를 참조하세요.  
+  API 세부 정보는 *AWS CLI 명령 참조*의 [UploadEntityDefinitions](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iotthingsgraph/upload-entity-definitions.html) 섹션을 참조하세요.