RuudBurger/CouchPotatoServer — pull request #4256 by bhaap (2014-11-27 06:44:22+00:00)
Title: omgwtfnzbs is on the wrong adress?

I find it wierd that CP is using rss site when they have a seperate api site for api calls.
here is their info about api from their website (using the api.omgwtfnzbs.org adress)

Application Programming Interface.
Information
These notes relate to v2.0 of our API

To access the API you will need an API Key.

You should use the HTTPS GET method for sending queries to the sever. POST method is not supported.
ANY Abuse of the API will result in an API ban, and or further restrictions.
We reserve the right to ban any user(s), IP(s) etc without notice, if in breach of the above.

API Rate Limits: (Updated 11th October 2014)
We do have a "Requests" limit.

The current rate limits are as follows:
REQUESTS LIMITATION: 1 request every 15 seconds (Disabled)

JSON Search API
url to use:

https://api.omgwtfnzbs.org/json/?search={some search term}&user={username}&api={apikey}

variables:

?search=something = No terms no search!
&user={username} = Your account username.
&api={apikey} = Your API Key.
&catid=1,2,3 ect = Optional, search multiple categorys.
&retention={days} = Optional, limit the search to X amount of days ago.
&eng=1 = Optional, return only english/unknown posts.
example api Call:

https://api.omgwtfnzbs.org/json/?search ... ention=500
this would search for bones.s08 in tvsd,tvhd with a max age of 500 days.

sample output:
[ { nzbid: "100677", release: "Some.Movie.Title-GRP", group: "alt.binaries.moovee", sizebytes: "1601590891", usenetage: "1317286337", categoryid: "15", cattext: "movies.sd", language: "11", weblink: "http://example.com/", details: "https://omgwtfnzbs.org/details.php?id={nzbid}", getnzb: "https://api.omgwtfnzbs.org/sn.php?id={nzbid}&user={username}&api={apikey}" } ]
If your request was successful you will get upto 500 results listed in JSON format

other responses:

{"notice":"applying some updates please try again later."} = Applying some updates to the code
{"notice":"no search no results"} = Search term is required
{"notice":"0 results matched your terms"} = No results for your query were found
{"notice":"search to short"} = min term must be 3 characters or more ([a-Z0-9]) any other characters will be ignored
{"notice":"your user or api information is incorrect.. check and try again"} = Bad/Incorrect api auth details
XML Search API: (updated 9th March 2013)
url to use:
https://api.omgwtfnzbs.org/xml/?search={some search term}&user={username}&api={apikey}

variables:

?search=something = string to search for (also see special features)
&username={username} = Your account username.
&api={apikey} = Your API Key.
&catid=1,2,3 ect = Optional, search multiple categorys.
&eng=1 = Optional, return only english/unknown posts.
&retention={days} = Optional, limit the search to X amount of days ago.
&page={#} = go to the next page of results if there is any.
If your request was successful you will get upto 500 results per page listed in xml format

special features:

?search= Sending a request with a blank search term will return results from the last 7 days &retention= will have no effect on your query
?search=tt1234567 = Search using the IMDB id. (if included at time of index)
sample output:
100 2 1 server time request was published Some.FLAC.Release.Name-INFO alt.binaries.sounds.flac 286396335 1338679302 22 music.flac 0 https://if-added.jpg http://weblink.net https://omgwtfnzbs.org/details.php?id={nzbid} https://api.omgwtfnzbs.org/nfo/?id={nzbid}&user={username}&api={apikey}/getnfo> https://api.omgwtfnzbs.org/sn.php?id={nzbid}&user={username}&api={apikey}
Notice:
All requests are cached for 10 minutes to reduce the load on the server.

other responses:

{no search no xml} = Search term is required
{invalid search terms} = Invalid search term
{0 results found} = No results for your query were found
{search to short} = min term must be 3 characters or more.
{your user/api information is incorrect.. check and try again} = Bad/Incorrect api auth details
Direct Download API: (updated 7th October 2014)
No HTML output is generated and the NZB is sent directly to your software/browser etc.

url to use:
https://api.omgwtfnzbs.org/nzb/?id={nzbid#}&user={username}&api={apikey}

variables:

?id={nzbid#} = taken from omgwtfnzbs.org
&user={username} = Your account username.
&api={apikey} = Your API Key.
output results:
If your request was successful the NZB will be sent directly to your browser/software.

If there was a problem with your request one the following responses will be output.

{"notice":"applying some updates please try again later."} = Applying some updates to the code
{"notice":"you have made too many nzb-api requests recently. nzb-api requests are limited to once every 15 seconds."}
{"notice":"your user or api information is incorrect.. check and try again"} = Bad/Incorrect api auth details
{"notice":"NZB has been removed from our index (cached result)"} = Just what it says
{"notice":"no nzb found"} = Found the info but cant make the nzb
{"notice":"bad nzbid#"} = Invalid nzbid#.
notes:
Only full posts can be retrieved, there is no support for partial posts.
Only one post can be downloaded per request.

GET NFO API: (updated 7th October 2014)
url to use:
https://api.omgwtfnzbs.org/nfo/?id={NZBID}&user={username}&api={apikey}

variables:

?id={nzbid#} = taken from omgwtfnzbs.org
&user={username} = Your account username.
&api={apikey} = Your API Key.
&send=1 = No HTML output is generated and the NFO is sent directly to your software/browser etc.
output results:
If your request was successful the NFO will be displayed in your browser/software.

If there was a problem with your request one the following responses will be output.

{"notice":"applying some updates please try again later."} = Applying some updates to the code
{"notice":"you have made too many nfo-api requests recently. nfo-api requests are limited to once every 15 seconds."}
{"notice":"your user or api information is incorrect.. check and try again"} = Bad/Incorrect api auth details
{"notice":"nfo unavailable/removed"}
notes:
Only one NFO can be viewed per request.