home-assistant.io/source/_components/google_maps.markdown
Franck Nijhof c464056402
Making our website faster, cleaner and prettier (#9853)
* 🔥 Removes octopress.js

* 🔥 Removes use of root_url var

* 🔥 Removes Octopress generator reference from feed

* 🔥 Removes delicious support

* 🔥 Removes support for Pinboard

* 🔥 Removes support for Disqus

* 🔥 Removes support for Google Plus

* ↩️ Migrate custom after_footer to default template

* ↩️ Migrate custom footer to default template

* ↩️ Migrate custom header to default template

* 🔥 Removes unused template files

* 🚀 Places time to read directly in post template

* 🚀 Removes unneeded capture from archive_post.html template

* 🔥 🚀 Removes unused, but heaving sorting call in component page

* 🚀 Merged javascripts into a single file

* 🔥 Removes more uses of root_url

* 🚀 Removal of unneeded captures from head

* 🔥 🚀 Removal of expensive liquid HTML compressor

* 🔥 Removes unneeded templates

* 🚀 Replaces kramdown with GitHub's CommonMark 🚀

* 💄 Adds Prism code syntax highlighting

*  Adds support for redirect in Netlify

* ↩️ 🔥 Let Netlify handle all developer doc redirects

* ✏️ Fixes typo in redirects file: Netify -> Netlify

* 🔥 Removes unused .themes folder

* 🔥 Removes unused aside.html template

* 🔥 Removes Disqus config leftover

* 🔥 Removes rouge highlighter config

* 🔥 Removes Octopress 🎉

* 💄 Adjust code block font size and adds soft wraps

* 💄 Adds styling for inline code blocks

* 💄 Improve styling of note/warning/info boxes + div support

* 🔨 Rewrites all note/warning/info boxes
2019-07-15 22:17:54 +02:00

2.3 KiB

title, description, logo, ha_release, ha_category, ha_iot_class, redirect_from
title description logo ha_release ha_category ha_iot_class redirect_from
Google Maps Location Sharing Instructions how to use Google Maps Location Sharing to track devices in Home Assistant. google_maps.png 0.67
Presence Detection
Cloud Polling
/components/device_tracker.google_maps/

The google_maps platform allows you to detect presence using the unofficial API of Google Maps Location Sharing.

Configuration

You first need to create an additional Google account and share your location with that account. This platform will use that account to fetch the location of your device(s). You have to setup sharing through the Google Maps app on your mobile phone. You can find more information here.

This platform will create a file named .google_maps_location_sharing.cookies extended with the slugified username where it caches your login session.

Since this platform is using an unofficial API with the help of locationsharinglib, Google seems to block access to your data the first time you've logged in with this platform. This issue can be fixed by logging in with your new account and approving your login on the Device Activity page.

To integrate Google Maps Location Sharing in Home Assistant, add the following section to your configuration.yaml file:

# Example configuration.yaml entry
device_tracker:
  - platform: google_maps
    username: YOUR_USERNAME
    password: YOUR_PASSWORD

{% configuration %} username: description: The email address for the Google account that has access to your shared location. required: true type: string password: description: The password for your given username. required: true type: string max_gps_accuracy: description: Sometimes Google Maps can report GPS locations with a very low accuracy (few kilometers). That can trigger false zoning. Using this parameter, you can filter these false GPS reports. The number has to be in meters. For example, if you put 200 only GPS reports with an accuracy under 200 will be taken into account - Defaults to 100km if not specified. required: false type: float {% endconfiguration %}