OwnTracks HTTP error 400

I updated HA to .83 and cannot get OwnTracks HTTP to work. In the app settings, I entered the Webhook URL from HA Integrations page, turned on authentication and entered a user ID. I left password and secret blank (also tried entering the secret as well).

The status in the app shows: error The operation couldn’t be completed. (HTTP Response error 400.) { }

In HA, it shows error: Set a username in Connection > Identification

No idea what I’m doing wrong. It sounds like the OwnTracks app is not sending the userid field (is that what the error in HA means)?

For sure an issue. I am able to get everything working fine on my Android device which allows me to specific the device id. On iOS (my wife’s iPhone) I get the 400 error you are getting and I can’t set the device id. I assume you are using iOS?

Yep, using the iOS app.

I think you and a lot of people are having issues. 0.83 created a breaking change in owntracks. i haven’t messed with it but it’s all over the boards.

  • OwnTracks is now using config entries. To set it up, go to the configuration panel and configure it there. When configured and MQTT is available, will automatically listen there too. (@kirichkov - #17034) (@balloob - #18759) (owntracks docs) (breaking change)

I’m referring specifically to this new configuration. It appears to be broken for iOS users.

Had the same issue.

Uninstalling and installing the Owntracks app on my iPhone solved the problem. Just used the username and api/webhook url in the settings and put authentication on true.

Can you elaborate a bit?

I’ve also tried re-installing OwnTracks on my iPhone and still getting the same error

1 Like

I tried the same and it didn’t help me.

Same issue here

HomeAssistant 0.83.2
iPhone 7 plus, with IOS 12.1

api/owntracks 404 error
api/webhook also 404 error

Please help me out.

Opened an issue https://github.com/home-assistant/home-assistant/issues/18927

Same problem here. I played around with it and I put my username at the end of the URL after the @ symbol. This seemed to work:

https://my IP address*:8123/api/webhook/ my key@paul

Might have spoke too soon. Seeing this in the log after I made that change:

[homeassistant.components.webhook] Received message for unregistered webhook xxxxxxxxxxxxxxxxx@paul

give this solution a try:

How to get it to work? trackerID=UserID

Works like a charm (but you only have 2 letters)

give it some time. It took 45 minutes for it to start working without error for me. some things to try, toggle Auth on and off, change the webhook to an invalid address(add a letter) and then change it back. seems like the settings take a while to take affect in the owntracks app.

I see the requests on the log so they are there, simply not showing :frowning:

I already reverted back HA. Did you try manually adding the device to known_devices.yaml? I had to do that with the old OwnTracks integration because it wasn’t adding it automatically.

I had onwtracks working for a few years now, so yes devices are already there, it seams lately that people don’t know what to do on HA so they are “innovating” but on the wrong side.

Every new release is like rolling a dice to see what stops working,

1 Like

These webhook tokens are they supposed to work even to a hassio instance on localhost? I can’t figure this out, because it works as long as I’m on my local network and stops when I’m out of wifi-range. Can someone please confirm this?

Your HA instance needs to be accessible from the internet.

So, I did too and the devices didn’t update until I added new ones and changed the names in the OwnTracks app.