Page 2 of 3
Re: iPhone notification via Prowl [Windows script]
Posted: September 25th, 2011, 1:28 pm
by relman
Hi Sorry for the late reply, should have PM'ed me.
try this
Code: Select all
set API="79c7bb8e283752fbc0f4b5b0fceXXXXXX"
set priority=2
set desc=%3
cscript E:\usenet\scripts\prowl.vbs %API% %priority% %desc%
change the last bit to point to the vbs file. I think the code to script out non standard characters is messing up as you are using german OS
Re: iPhone notification via Prowl [Windows script]
Posted: November 4th, 2011, 3:04 pm
by idmanager
anybody running a qnap server with python here is a script i run
just add your api key
Code: Select all
#!/usr/bin/env python
import sys,urllib
# Get clean NZB name
job_name = sys.argv[3]
# Prowl API settings - http://prowl.weks.net/api.php
# Set Prowl API
API = "enter the prowl api key here "
# Set Prowl priority. 0 - Normal, 2 - Emergency, -2 - Very Low
priority = "0"
# Set job title/event name
job_title = "Download%20Complete"
# Get current date/time and strip spaces
from time import gmtime, strftime
event_time = strftime("%d/%m/%y %H:%M")
event_time=event_time.replace(' ', '%20')
# URL encode chars from NZB name that cause issues
job_name=job_name.replace(' ', '%20')
job_name=job_name.replace('_', '%20')
job_name=job_name.replace('.', '%20')
# Send download complete notification to iPhone - swap 'job_title' for 'event_time' if completion time is required instead of 'Download Complete'
urllib.urlopen("https://prowl.weks.net/publicapi/add?apikey=" + API + "&priority=" + priority + "&application=SABnzbd&event=" + job_title + "&description=" + job_name)
Re: iPhone notification via Prowl [Windows script]
Posted: January 19th, 2012, 10:36 pm
by SplitFire
Would anyone know why I get this error when trying to run the windows prowl script?
msxml3.dll: Access is denied
Thanks!
I got the issue figured out and have rewritten the script. The following code should work for everyone...
prowl.cmd
Code: Select all
set API="xxxxxxxxxxxxxxxxx"
Set Item=%3
setlocal enableextensions
set var_=%Item%
endlocal & set FileName=%var_%
Set desc="%FileName%"
set priority=0
cscript C:\prowl.vbs %API% %priority% %desc%
prowl.vbs
Code: Select all
API = WScript.Arguments.Item(0)
priority = WScript.Arguments.Item(1)
desc = WScript.Arguments.Item(2)
set oHTTP = CreateObject("MSXML2.ServerXMLHTTP.6.0")
oHTTP.open "Get", "https://api.prowlapp.com/publicapi/add?" & "apikey=" & API & "&priority=" & priority & "&application=SABnzbd File Downloaded&event=" & Date() & " " & Time() & "&description=" & desc ,false
oHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
oHTTP.send
HTTPPost = oHTTP.responseText
Re: iPhone notification via Prowl [Windows script]
Posted: January 31st, 2012, 4:56 pm
by daven1985
Morning,
I am very new to using SABnzbd and so far don't know why I bothered with sites like Fileserve and the like.
However I can't seem to figure out how I actually load a script into SABnzbd. Is they a guide to show me how to do this.
Re: iPhone notification via Prowl [Windows script]
Posted: January 31st, 2012, 5:38 pm
by shypike
Re: iPhone notification via Prowl [Windows script]
Posted: February 1st, 2012, 3:37 am
by daven1985
I went through that, I still can't figure what I need to do.
Sorry people, I am a complete novice with this and while I know how to look at scripts and have it working in terms of sending a test alert manually, I don't know how to load it into sabnzbd.
Thanks.
Re: iPhone notification via Prowl [Windows script]
Posted: February 1st, 2012, 11:08 am
by shypike
You don't "load it into" SABnzbd.
Make sure you set up a scripts folder in Config->Folders and put all the scripts in that folder.
Then SABnzbd will show a scripts column in queue, RSS and categories.
Only script that are executable (OSX, Linux) or have registered executable extensions (Windows: cmd, bat, exe etc.) will be shown.
Re: iPhone notification via Prowl [Windows script]
Posted: February 1st, 2012, 6:37 pm
by daven1985
skypike,
Thank you. That was exactly what I needed to hear and it is working.
However the only issue I have is that all of the prowl's just come up as t= (t is curvy). it doesn't put the name of the file into the prowl. Am I missing something.
Thanks for everyones help so far.
Re: iPhone notification via Prowl [Windows script]
Posted: February 20th, 2012, 4:16 am
by daven1985
Any thoughts
?? above post.
Re: iPhone notification via Prowl [Windows script]
Posted: February 20th, 2012, 5:43 pm
by shypike
Is this with non plain ASCII characters?
Like é, é etc.
Re: iPhone notification via Prowl [Windows script]
Posted: February 21st, 2012, 3:19 pm
by dubud
Anyone know how I can send notification to more of one Prowl API ?
Thx
Re: iPhone notification via Prowl [Windows script]
Posted: February 21st, 2012, 9:24 pm
by daven1985
Morning,
I have attached a screenshot of the prowl's on my iPhone.
Re: iPhone notification via Prowl [Windows script]
Posted: March 30th, 2012, 3:50 pm
by TannerG
SplitFire wrote:Would anyone know why I get this error when trying to run the windows prowl script?
msxml3.dll: Access is denied
Thanks!
I got the issue figured out and have rewritten the script. The following code should work for everyone...
prowl.cmd
Code: Select all
set API="xxxxxxxxxxxxxxxxx"
Set Item=%3
setlocal enableextensions
set var_=%Item%
endlocal & set FileName=%var_%
Set desc="%FileName%"
set priority=0
cscript C:\prowl.vbs %API% %priority% %desc%
prowl.vbs
Code: Select all
API = WScript.Arguments.Item(0)
priority = WScript.Arguments.Item(1)
desc = WScript.Arguments.Item(2)
set oHTTP = CreateObject("MSXML2.ServerXMLHTTP.6.0")
oHTTP.open "Get", "https://api.prowlapp.com/publicapi/add?" & "apikey=" & API & "&priority=" & priority & "&application=SABnzbd File Downloaded&event=" & Date() & " " & Time() & "&description=" & desc ,false
oHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
oHTTP.send
HTTPPost = oHTTP.responseText
I got this to work, but the file names are incomplete. ie if the name of the download was "How I Met Your Mother", prowl will only show "How". So it only shows the first word.
Anyone know what I can do to fix this?
Re: iPhone notification via Prowl [Windows script]
Posted: April 2nd, 2012, 6:51 am
by JohnSCS
TannerG,
You need to make the desc URL encoded. It's seeing spaces as another parameter.
ie %20 for a space. Look at the original python script.
Dubud,
Add more APIs to the set API string separated by commas.
Ie, set API="API1,API2,API3"
Re: iPhone notification via Prowl [Windows script]
Posted: July 18th, 2012, 1:24 am
by solonvault
First of all great work on this script!
Is there a way to add the remaining Harddrive space to the notification ?
Thanks!