Forum rules
Under no circumstances is spamming or advertising of any kind allowed. Do not post any abusive, obscene, vulgar, slanderous, hateful, threatening, sexually-orientated or any other material that may violate others security. Profanity or any kind of insolent behavior to other members (regardless of rank) will not be tolerated. Remember, what you don’t find offensive can be offensive to other members. Please treat each other with the kind of reverence you’d expect from other members.
Failure to comply with any of the above will result in users being banned without notice. If any further details are needed, contact: “The team” using the link at the bottom of the forum page. Thank you.
mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Sat Jul 21, 2018 12:17 am

Is there a way to pass the year field on this new api like on the old one?

Is it really necessary to pass file size and hash together? can I just pass file size?

Thanks.

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Sat Jul 21, 2018 12:31 pm

Hi, it should work same as for xml-rpc SearchSubtitles(). If I am not mistaken, over there is also not allowed using filesize only function, it is because how the indexes in db are made, it is slower than using hash. MovieYear is also not accepted.

mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Thu Aug 09, 2018 4:11 am

Is it possible to perform a search with movie name, hash and file size and have it return everything not just the ones that match file size and hash?

Thanks.

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Tue Aug 21, 2018 12:24 pm

Hi,

you have to search by moviename (1st query) and then hash and filesize (2nd query)

mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Tue Aug 21, 2018 6:41 pm

Hi,

you have to search by moviename (1st query) and then hash and filesize (2nd query)
Will try it. Thanks.

mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Tue Aug 21, 2018 7:03 pm

Hi,

you have to search by moviename (1st query) and then hash and filesize (2nd query)
Just to be clear, are you suggesting I make two searches or that I rearrange the search parameters?

For example on this search:

https://rest.opensubtitles.org/search/m ... uageid-eng

only gives me results with the exact hash, but this other search fails:

https://rest.opensubtitles.org/search/q ... uageid-eng

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Tue Aug 21, 2018 11:15 pm

Hi

the best is to make two separate requests. To be clear:
https://rest.opensubtitles.org/search/m ... uageid-eng
is redirecting to
https://rest.opensubtitles.org/search/m ... uageid-eng

https://rest.opensubtitles.org/search/q ... uageid-eng
is redirecting to
https://rest.opensubtitles.org/search/m ... uageid-eng

so as you can see query is totally ignored when there is moviehash and moviebytesize, the best is "sort" parameters in URL as written in first message in this topic.

so 2nd query would be:
https://rest.opensubtitles.org/search/q ... uageid-eng

mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Wed Aug 22, 2018 1:33 am

Hi

the best is to make two separate requests. To be clear:
https://rest.opensubtitles.org/search/m ... uageid-eng
is redirecting to
https://rest.opensubtitles.org/search/m ... uageid-eng

https://rest.opensubtitles.org/search/q ... uageid-eng
is redirecting to
https://rest.opensubtitles.org/search/m ... uageid-eng

so as you can see query is totally ignored when there is moviehash and moviebytesize, the best is "sort" parameters in URL as written in first message in this topic.

so 2nd query would be:
https://rest.opensubtitles.org/search/q ... uageid-eng
Ok, two separate queries is how we have it implemented now, just wanted to make sure that was ok and there was no better way.

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Wed Aug 22, 2018 8:57 am

basically, the best is moviehash and size search, if that will bring no desired results, query is the last best option.

mntgoat
Posts: 47
Joined: Thu Sep 24, 2015 10:41 pm

Re: [NEW] REST search, JSON results

Wed Aug 22, 2018 5:21 pm

basically, the best is moviehash and size search, if that will bring no desired results, query is the last best option.
Yeah that is exactly how we are doing it, second query if the first was empty. Thanks.

habibkazemi
Posts: 1
Joined: Sun Sep 02, 2018 9:46 am

Re: [NEW] REST search, JSON results

Sun Sep 02, 2018 9:55 am

What happens when using both imdbid and hash and bytesize,for example the below sample.
seems that it ignores the imdbid, the result with and without that is same
also episode and season seems useless when using size and hash.

https://rest.opensubtitles.org/search/e ... uageid-eng

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Mon Sep 03, 2018 11:32 am

yeah, thats right. If you search by hash and bytesize the results should be already good enough to have more filtering.

slingdev
Posts: 1
Joined: Tue Sep 11, 2018 5:14 pm

Re: [NEW] REST search, JSON results

Tue Sep 11, 2018 5:19 pm

Hi, I am new to opensubtitles and wanted to try out the search API, but I keep getting the following error "http useragent is not valid". I am using Postman with the following header :
GET /search/moviebytesize-750005572/moviehash-319b23c54e9cf314 HTTP/1.1
Host: rest.opensubtitles.org
Content-Type: application/json
User-Agent: "TemporaryUserAgent"
Cache-Control: no-cache

Please help...

User avatar
oss
Site Admin
Posts: 5879
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: [NEW] REST search, JSON results

Mon Sep 17, 2018 10:31 am

Hi, it works here, try:

Code: Select all

curl -A 'TemporaryUserAgent' https://rest.opensubtitles.org/search/moviebytesize-750005572/moviehash-319b23c54e9cf314

muven89
Posts: 2
Joined: Sat Jan 05, 2019 10:12 pm

Re: [NEW] REST search, JSON results

Sat Jan 05, 2019 10:35 pm

Can you share REST documentation link ?

How many ways are there to query ?

1. query by movie name
2. query by series season and episode name
3. add language selection in the query

ple help me to understand these queries. Thanks,

Return to “Developing”

Who is online

Users browsing this forum: No registered users and 20 guests