iOS push Map notification

I am on HA 0.92.2 and running the latest version of the production iOS app (not Beta).

I am trying to set up a notification that sends a map thumbnail of the GPS coordinates.

The JSON in the Dev Tools/Services under the Service of notify.ios_mark_iphone_8_plus I am using is:

{
	"title": "Mark Location",
	"message": "Mark is here",
	"data": {
		"url": "",
		"push": {
			"category": "map",
			"action_data": {
				"latitude": "xxxxxxxx",
				"longitude": "xxxxxxxx"
				             }    
			 }
		 }
	}

(I am susbstituting the “xxxxx” in the JSON with my long/lat)

However, all I get is the below:

Any ideas where I am going wrong? I saw a similar thread here that said to make it a data_template but that doesn’t work either.

Thanks

mb

EDIT:

Also tried

{
	"title": "Mark Location",
	"message": "Mark is here",
	"data": {
		"push": {
			"category": "map",
			"action_data": {
				"latitude": "xxxxxxxx",
				"longitude": "xxxxxxxx"
				             }    
			 }
		 }
	}

Your JSON payload is a tiny bit off, specifically around the "category": "map" area.

This works for me in both the old and new app.

{
  "title": "Mark Location",
  "message": "Mark is here",
  "data": {
    "push": {
      "category": "map"
    },
    "action_data": {
      "latitude": "40.7484",
      "longitude": "-73.9857"
    }
  }
}

As mentioned in that linked thread though, if using a device_tracker or anything dynamic in the latitude/longitude you will need to use data_template instead of data.

1 Like

Thank you! You are a genius :slight_smile: