diff --git a/source/_integrations/icloud.markdown b/source/_integrations/icloud.markdown index d70e5aa4a1d..609c633bdea 100644 --- a/source/_integrations/icloud.markdown +++ b/source/_integrations/icloud.markdown @@ -7,44 +7,58 @@ ha_category: ha_release: "0.10" --- - -The `icloud` platform allows you to detect presence using the [iCloud](https://www.icloud.com/) service. iCloud allows users to track their location on iOS devices. +The `icloud` integration allows you to detect presence using the [iCloud](https://www.icloud.com/) service. iCloud allows users to track their location on iOS devices. It does require that your device is registered with "Find My iPhone". -To integrate iCloud in Home Assistant, add the following section to your `configuration.yaml` file: +## Setup the integration + +There is two ways to integrate iCloud in Home Assistant + +### Via the frontend + +Menu: *Configuration* -> *Integrations*. Search for "iCloud", add your credentials, click submit. + +If you add the integration for the first time for an account: +1. Choose a trusted device from the list and submit. +2. It will send you a text message on your trusted device, add the received code to the next form and submit (if you missed the right code, you will be back to the previous step, and retry). +3. You are done! + +If you already added the integration before, you are done! + +### Via the configuration file + +Add the following section to your `configuration.yaml` file: ```yaml # Example configuration.yaml entry -device_tracker: - - platform: icloud - username: USERNAME +icloud: + - username: USERNAME password: PASSWORD - account_name: accountname ``` {% configuration %} username: - description: The username for the iCloud account. + description: Your iCloud account email. required: true type: string password: - description: The password for your given username. + description: Your iCloud account password. required: true type: string account_name: - description: The friendly name for the account_name. If this isn't given, it will use the account_name of the username (so the part before the `@` in the email address). + description: A friendly name for your iCloud account. If this isn't given, it will use the part before the `@` of the username. required: false type: string max_interval: - description: Maximum interval in minutes between subsequent location upates. This tracker uses dynamic intervals for requesting location updates. When iphone is stationary, interval will eventually be set to `max_interval` to save battery. When iphone starts moving again interval will be dynamically updated to 1 min. Note that updating interval to 1 min might be delayed by maximum `max_interval` minutes. Minimum value is 1 min. + description: Maximum interval in minutes between subsequent location updates. This tracker uses dynamic intervals for requesting location updates. When the iPhone is stationary, the interval will eventually be set to `max_interval` to save battery. When the iPhone starts moving again, the interval will be dynamically updated to 1 min. Note that updating interval to 1 min might be delayed by maximum `max_interval` minutes. Minimum value is 1 min. required: false default: 30 type: integer gps_accuracy_threshold: - description: iCloud location updates come with some gps_accuracy varying from 10 to 5000 meters. This setting defines the accuracy threshold in meters for a location update. Less accurate updates will be discarded by this tracker. This allows more precise location monitoring and fewer false positive zone changes. + description: iCloud location updates come with some gps_accuracy varying from 10 to 5000 meters. This setting defines the accuracy threshold in meters for a location update. Less accurate updates will be discarded by this tracker. This allows for more precise location monitoring and fewer false-positive zone changes. required: false - default: 1000 + default: 500 type: integer {% endconfiguration %} @@ -55,16 +69,26 @@ Low `max_interval` may cause battery drainage as it wakes up your device to get