Pushover: "application token is invalid" for working API token

Hey folks. Long-time HomeSeer turned-convert to Hubitat (shout-out to @adamkempenich for the nudge!).

While I'm slowly getting the hang of things and getting my devices migrated over, one thing is having a decent issue: Pushover notifications.

ASK: Is there any further debug info that can be gleaned from the Pushover integration? Hubitat throws errors that my API key is invalid, though the same key works with curl, etc. I've checked for trailing spaces, pasted into Notepad++ looking for foreign/hidden characters - nothing seems to work.

Details

First off, hardware:

  • Hubitat Elevation® Platform Version: 2.2.5.126
  • Hardware Version: Rev C-7

Following the doc: Pushover (Hubitat Docs), I've added my virtual device, and migrated over my user and app key from my HomeSeer Pushover application. Note that I've been using these tokens for literal years, so there's no ambiguity on if they've worked in the past, etc (I've averaged 200-400 messages/month using this user/key combo in 2020).

Also note that I've tried a fresh API key on the same account, with the same result. For whatever reason, Hubitat just isn't taking the keys:

dev:282021-02-03 17:54:54.869 errorgetValidated error:[token:invalid, errors:[application token is invalid], status:0, <guid>]

I can confirm that the keys are perfectly valid, using curl:

ryanb@ryanb-x1:~$ curl -s \
>   --form-string "token=ae7yto2aq4g6[redacted]" \
>   --form-string "user=utgGox1grgCURe[redacted]" \
>   --form-string "message=hello world" \
>   https://api.pushover.net/1/messages.json
{"status":1,"request":"<guid>"}

Here's confirmation that the user key is in fact the correct user key (pulled from the Pushover site, just truncated the screenshot to ensure the token wasn't fully visible):

Screenshot from 2021-02-03 18-01-40

And this matches my user key in Hubitat:

Same with the app key:

Screenshot from 2021-02-03 18-03-55

Thanks for the assistance!

Ryan

2 Likes

Ayyy! Welcome to the forums, Ryan!

@bobbyD ... know anything about this implementation?

1 Like

I think you need to create a separate API key for each application. I have one for ST and one for HE. The API token key is different.

You do get one API key per application, but you are certainly able to use your same API key in multiple apps.

That being said, I did try a fresh API key, just in case there was some issue with the existing one. But no change.

After looking back, it had been awhile since I set it up, I wondered if it really made a difference. All I can say is it works for me, but I am using a "slightly enhanced" version of the pushover driver and not the official one.

3 Likes

I’m using the enhanced driver as well.

1 Like

Well.... Not entirely sure what's up here, but I deleted and re-created the virtual device with the same values (but new GUID as the Device Network ID), and it seems to have resolved the issue.

Thanks for the help, all!

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.