

# Using Amazon IoT Device Defender with other Amazon services
<a name="dd-integration"></a>

## Using Amazon IoT Device Defender with devices running Amazon IoT Greengrass
<a name="dd-gg-integration"></a>

Amazon IoT Greengrass provides pre-built integration with Amazon IoT Device Defender to monitor device behaviors on an ongoing basis.
+ [Integrate Device Defender with Amazon IoT Greengrass V1](https://docs.amazonaws.cn//greengrass/v1/developerguide/device-defender-connector.html)
+ [Integrate Device Defender with Amazon IoT Greengrass V2](https://docs.amazonaws.cn//greengrass/v2/developerguide/device-defender-component.html)

## Using Amazon IoT Device Defender with FreeRTOS and embedded devices
<a name="dd-integration-FreeRTOS"></a>

To use Amazon IoT Device Defender on a FreeRTOS device, your device must have the [FreeRTOS Embedded C SDK](https://github.com/aws/amazon-freertos) or the [Amazon IoT Device Defender library](https://docs.amazonaws.cn//embedded-csdk/latest/lib-ref/libraries/aws/device-defender-for-aws-iot-embedded-sdk/docs/doxygen/output/html/index.html) installed. The FreeRTOS Embedded C SDK includes the Amazon IoT Device Defender library. For information about how to integrate Amazon IoT Device Defender with your FreeRTOS devices, see the following demos:


+ [Amazon IoT Device Defender for FreeRTOS standard metrics and custom metrics demos](https://freertos.org/iot-device-defender-demo.html)
+ [Using MQTT agent to submit metrics to Amazon IoT Device Defender](https://freertos.org/iot-device-defender/demo-with-mqtt-agent.html)
+ [Using the MQTT core library to submit metrics to Amazon IoT Device Defender](https://docs.amazonaws.cn//freertos/latest/userguide/dd-demo.html)

To use Amazon IoT Device Defender on an embedded device without FreeRTOS, your device must have the [Amazon IoT Embedded C SDK](https://docs.amazonaws.cn//iot/latest/developerguide/iot-embedded-c-sdk.html) or [Amazon IoT Device Defender library](https://docs.amazonaws.cn//embedded-csdk/latest/lib-ref/libraries/aws/device-defender-for-aws-iot-embedded-sdk/docs/doxygen/output/html/index.html). The Amazon IoT Embedded C SDK includes the Amazon IoT Device Defender library. For information about how to integrate Amazon IoT Device Defender with your embedded devices, see the following demos, [Amazon IoT Device Defender for Amazon IoT Embedded SDK standard and custom metrics demos](https://github.com/aws/aws-iot-device-sdk-embedded-C/blob/main/docs/doxygen/demos/defender_demo.dox).

## Using Amazon IoT Device Defender with Amazon IoT Device Management
<a name="dd-integration-device-management"></a>

You can use Amazon IoT Device Management fleet indexing to index, search, and aggregate your Amazon IoT Device Defender detect violations.

**Note**  
The fleet indexing feature to support indexing Amazon IoT Device Defender violations data is in preview release for Amazon IoT Device Management and is subject to change.
+ [Managing fleet indexing](https://docs.amazonaws.cn//iot/latest/developerguide/managing-fleet-index.html)
+ [Query syntax](https://docs.amazonaws.cn//iot/latest/developerguide/query-syntax.html)