Hey I am using trying to use Tasker to mimic GPSLogger to send location data back to HA with HTTP Post command: Tasker HTTP POST Command Server:Port = https://ha.url.com Path = /api/webhook/xxxxxxxxxxxxxxxxxxxxxx Data/File = latitude=%allatitude&longitude=%allongitude&device=pixel3&battery=%BATT Content Type = application/x-www-form-urlencoded
Dont take this the wrong way but I dont understand the reasoning behind MQTT. It dosen’t make sense to me to use a Sensor->Broker->HA when I can just go Sensor->HA. I have really never understood the benefits to using a MQTT broker.? I try to keep it KISS
Tasker’s HTTP Post seems to be having some issues with handling responses, I have used RESTtask for Tasker plugin and it works. I’m on the cloud and it also works fine with GPSLogger webhook.
I’m not really tracking my location and I do not have any location/zone based automations yet, so I cannot say how accurate is tasker as compared to GPSLogger app.
Create an Owntracks integration - past the webhook ID to <Str sr="arg1" ve="3">/api/webhook/ and you can change the "topic":"owntracks/USER/NAME"} part.
Now I only need a nice trigger.
Your task looks almost the same as mine. However, it looks that you are using GPS as source in “Get Location”. I think the you should then get the coordinates from %LOC variable (as %LOCN stands for network location).
I have set Tasker to run this task whenever I enter or leave my home (Event: Wifi Connected), area around my home or work (Cell Near) and my car (BT Connected).
I used RESTask for Tasker for a while but had problems with it. Sometimes it stopped working and wouldn’t send any requests until Tasker had been restarted. I couldn’t figure out what was causing this. But it seems that the plugin has not been updated since 2015.
Sorry, I’ve been away for some time… I have noticed the same problem with RESTask but since it is not a top priority for me I did not really looked into it - maybe another tasker automation that would kill it and restart (if that’s possible) every hour or so would make it more reliable?
I’m not able to get this to work for some reason - I get a device_tracker set up in Hassio but only the gps flag comes through and none of the data, so the location isn’t correctly reported. It looks like all the variables are set correctly (I adjusted a few to integers as indicated by the Owntracks documentation but this didn’t help). Any idea what I might be doing incorrectly?