Send Pushover notifications with pictures and hyperlinks

dohat leku

Getting the hang of it
Joined
May 19, 2018
Messages
336
Reaction score
35
Location
usa
Got it, btw what's the reason one has to click on a notification for the image to appear. Why not appear immediately? Is that a pushover limitation?
 

jaydeel

BIT Beta Team
Joined
Nov 9, 2016
Messages
1,202
Reaction score
1,280
Location
SF Bay Area
Last edited:

dohat leku

Getting the hang of it
Joined
May 19, 2018
Messages
336
Reaction score
35
Location
usa
I put the priority=1 syntax in but messages are still being delivered as normal priority.
Code:
https://api.pushover.net/1/messages.json -s --form-string "token=%996" --form-string "user=%997" --form-string "message=<b>&CAM</b> &MEMO" -F "attachment=@C:\BlueIris\Alerts\&ALERT_PATH" <a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>" --form-string "html=1" --form-string "device=%998" --form-string "priority=1"
How I tested: Put iphone in sleep mode, did a manual priority 1 push from pushover's website and my phone does beep and shows a time sensisitive notification. Then I walk near the camera and no beep but I do see the pushover notification under 'While in sleep focus'. In pushover's guide, it says High-priority messages are highlighted in red in the device clients and it's not red in the pushover app
 

jaydeel

BIT Beta Team
Joined
Nov 9, 2016
Messages
1,202
Reaction score
1,280
Location
SF Bay Area
I put the priority=1 syntax in but messages are still being delivered as normal priority.
Code:
https://api.pushover.net/1/messages.json -s --form-string "token=%996" --form-string "user=%997" --form-string "message=<b>&CAM</b> &MEMO" -F "attachment=@C:\BlueIris\Alerts\&ALERT_PATH" <a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>" --form-string "html=1" --form-string "device=%998" --form-string "priority=1"
How I tested: Put iphone in sleep mode, did a manual priority 1 push from pushover's website and my phone does beep and shows a time sensisitive notification. Then I walk near the camera and no beep but I do see the pushover notification under 'While in sleep focus'. In pushover's guide, it says High-priority messages are highlighted in red in the device clients and it's not red in the pushover app
Suggestions:
1. iPhone Settings > Notifications > Pushover > Enable ‘Time Sensitive Notifications’
2. Pushover App > Settings (gear icon) > ‘Quiet Hours’ …. review settings

Other users may have better suggestions (I don’t use an iPhone routinely but have one for testing).
 

dohat leku

Getting the hang of it
Joined
May 19, 2018
Messages
336
Reaction score
35
Location
usa
checked all those settings and also enabled 'critical alerts for high-priorioty'. How do I check if curl is actually generating a priority 1 alert?
Also is it worthwhile moving --form-string "priority=1" to earlier in the syntax or the order doesn't matter?
 

jaydeel

BIT Beta Team
Joined
Nov 9, 2016
Messages
1,202
Reaction score
1,280
Location
SF Bay Area
checked all those settings and also enabled 'critical alerts for high-priorioty'. How do I check if curl is actually generating a priority 1 alert?
Also is it worthwhile moving --form-string "priority=1" to earlier in the syntax or the order doesn't matter?
Parameter order should not matter.

I've previously suggested how you can capture the exact syntax that was sent by Blue Iris to the Pushover API (example). See also post #1 section 'Debugging'. It's not as much work as it may first appear.

To examine the Pushover API's response from this captured syntax, see post #1 section 'Testing using the Windows Command Prompt'.
 
Last edited:

dohat leku

Getting the hang of it
Joined
May 19, 2018
Messages
336
Reaction score
35
Location
usa
Was really hoping this would be the case but unfortunately not, stil have that issue. I have to try the other troubleshooting steps jaydeel laid out. My pushover app and the pushover service and the phone settings are all correct because when I do a priority 1 alert from their website, it comes through consistently. So it's something at the blue iris or curl end
 

dohat leku

Getting the hang of it
Joined
May 19, 2018
Messages
336
Reaction score
35
Location
usa
ye!!! got it working, All i did was move this to the beginning- --form-string "priority=1" instead of the end
Here's the syntax that's working well now and it's showing the alert with a red box around it on the app
Code:
https://api.pushover.net/1/messages.json -s  --form-string "priority=1" --form-string "token=%996" --form-string "user=%997" --form-string "message=<b>&CAM</b> &MEMO" -F "attachment=@C:\BlueIris\Alerts\&ALERT_PATH" <a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>" --form-string "html=1" --form-string "device=%998"
 

jaydeel

BIT Beta Team
Joined
Nov 9, 2016
Messages
1,202
Reaction score
1,280
Location
SF Bay Area
ye!!! got it working, All i did was move this to the beginning- --form-string "priority=1" instead of the end
Here's the syntax that's working well now and it's showing the alert with a red box around it on the app
Code:
https://api.pushover.net/1/messages.json -s  --form-string "priority=1" --form-string "token=%996" --form-string "user=%997" --form-string "message=<b>&CAM</b> &MEMO" -F "attachment=@C:\BlueIris\Alerts\&ALERT_PATH" <a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>" --form-string "html=1" --form-string "device=%998"
It only works because the priority parameter was re-positioned prior to a syntax error.

The syntax is easier to debug if you copy the code to a text editor and insert new lines before each parameter, like this...
Code:
https://api.pushover.net/1/messages.json -s
--form-string "priority=1"
--form-string "token=%996" --form-string "user=%997"
--form-string "message=<b>&CAM</b> &MEMO"
-F "attachment=@C:\BlueIris\Alerts\&ALERT_PATH"
<a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>"
--form-string "html=1"
--form-string "device=%998"
Note that once again, the hyperlink code bits are orphaned (<a href='...'</a>) from the message parameter. And there exists a stray double-quote after the existing hyperlink code that must be deleted.

The code in the 3rd-to-last line, excluding the terminating double-quote, <a href='&WAN/alerts/&ALERT_DB?fulljpeg'>Hi-Res</a> <a href='&WAN/ui3.htm?rec=&ALERT_DB'>UI3</a>, must be relocated to the end of the message parameter (before the terminating double-quote).

Pay attention to syntax! If something's not working, trying breaking it down to smaller, easier to inspect pieces.
 
Last edited:
Top