[REL] IMDB ( via API )

If you made a script you can offer it to the others here, or ask help to improve it. You can also report here bugs & problems with existing scripts.
Post Reply
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

[REL] IMDB ( via API )

Post by Munkey »

Alternative IMDb script to get info from original API. Aims to be simpler, faster & reliable.

Download from: https://github.com/Purfview/IMDB_ALT

Version Log:

Code: Select all

1.0.5 - (2025/06/29) - Added support for "My ratings" field. [IMDB_userID must be set]
                     - Added CreditsLimit option.
                     - Reworked Director/Writer/Actors.
                     - Fixed country errors: 'West Germany','East Germany','Soviet Union','Czechoslovakia',
                                             'Yugoslavia','Zaire','Serbia and Montenegro','Burma'.
                     - Fixed country names: 'Vietnam', 'Czech Republic'.
                     - Fixed: The title search didn't include the adult titles.
                     - Fixed few other bugs.
                     
1.0.4 - (2025/06/29) - Added support for Producer & Composer fields.
                     - Fixed few bugs.
                     
1.0.3 - (2025/06/27) - Fixed: BatchMode 1/2 wasn't working properly.
                     - Auto-remove dots from the titles as IMDb's advanced search doesn't like them
                     - Removed unneeded scripts from "uses".
                     
1.0.2 - (2025/06/27) - Fixed few country names
                     - Remove the escapes from Comment

1.0.1 - (2025/06/27) - File changed to UTF8 [note: AMC does not support UTF8, use UTF8Decode]
                     - The scripts title changed to "IMDB ( via API )"

1.0.0 - (2025/06/26) - The first public release.
Notes:
The search is not fuzzy! (but still search works in cases like "Schindlers List")
Can search by year, add it at the end of a title, for example: The.Platform.2.2024

What is missing?
Please report if something doesn't work.
Last edited by Munkey on 2025-06-29 20:09:20, edited 10 times in total.
Lemaireus
Posts: 103
Joined: 2014-02-14 10:18:14

Re: [REL] IMDB ( Alt )

Post by Lemaireus »

Munkey wrote: 2025-06-27 00:31:47 What is missing:
Support for Producer and Composer fields is missing, does anyone need them?
Yes, please. A fully functional script should be able to import all the fields. Will give this one a run through once it covers all the fields.

Thank you very much for your work.
antp
Site Admin
Posts: 9711
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Re: [REL] IMDB ( Alt )

Post by antp »

Thanks :)
It is indeed much simplier than parsing the pages. We'll see how long this API stays available.
I would change the title to "IMDb (via API)" or something like that.
I also included the licence text directly in the script's Licence property, rather than just "MIT".
I've included it on https://update.antp.be/amc/scripts/
I'll try to update these two properties on Github too.
antp
Site Admin
Posts: 9711
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Re: [REL] IMDB ( Alt )

Post by antp »

The time I create a github account and install software locally I see you already changed it on the server :D
I would remove the spaces inside parenthesis though, as otherwise it clashes with the existing "IMDB (Actor images)" script.
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

Re: [REL] IMDB ( Alt )

Post by Munkey »

antp wrote: 2025-06-27 06:23:35 Thanks :)
It is indeed much simplier than parsing the pages. We'll see how long this API stays available.
You are welcome!
It's up for few years, so I hope they will not obfuscate access to it.
antp wrote: 2025-06-27 06:36:14 The time I create a github account and install software locally I see you already changed it on the server :D
Yeah I updated it (changed the file to UTF8 too), you don't need to install Git, I just edit it directly in the website if it's quick edit, or just drag and drop whole edited file there, Git is just too much to bother with small projects.
antp wrote: 2025-06-27 06:36:14 I would remove the spaces inside parenthesis though, as otherwise it clashes with the existing "IMDB (Actor images)" script.
How and why it clashes?
Lemaireus wrote: 2025-06-27 06:10:42 Yes, please. A fully functional script should be able to import all the fields.
OK, I'll check if I can find the endpoints for that info, IMDb's API isn't publicly documented.
antp
Site Admin
Posts: 9711
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Re: [REL] IMDB ( Alt )

Post by antp »

Munkey wrote: 2025-06-27 06:56:51 How and why it clashes?
Visually, having in the list:

IMDB
IMDB (Actor images)
IMDB ( via API )

together looks strange, but I'm maybe a typography maniac/nerd :D
Munkey wrote: 2025-06-27 06:56:51 Yeah I updated it (changed the file to UTF8 too), you don't need to install Git, I just edit it directly in the website if it's quick edit, or just drag and drop whole edited file there, Git is just too much to bother with small projects.
Good to know :)
About the UTF8 conversion, AMC does not support it, so you get non-decoded UTF8 country names then :/ (could be converted with UTF8Decode when retrieving the value from ExpandCountryCode)
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

Re: [REL] IMDB ( Alt )

Post by Munkey »

antp wrote: 2025-06-27 07:00:25 together looks strange, but I'm maybe a typography maniac/nerd :D
Looks OK for me as it is. :)
antp wrote: 2025-06-27 07:00:25 About the UTF8 conversion, AMC does not support it...
Thanks for info, fixed those few country names in v1.0.2
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

Re: [REL] IMDB ( Alt )

Post by Munkey »

Lemaireus wrote: 2025-06-27 06:10:42 Yes, please. A fully functional script should be able to import all the fields. Will give this one a run through once it covers all the fields.
v1.0.4 should support all fields. Please report if something is not working.
Lemaireus
Posts: 103
Joined: 2014-02-14 10:18:14

Re: [REL] IMDB ( Alt )

Post by Lemaireus »

Munkey wrote: 2025-06-28 23:36:31 v1.0.4 should support all fields. Please report if something is not working.
Works like lightning! The script is fast as well as accurate. It imports both the producer as well as the composer fields as also all the others.

The only bit missing for me now is:
1. The script imports only four actors. It would be great to have the option/s to import ten, or fifteen, or all, as one could in the earlier IMDB script.
2. The earlier IMDB script also allows us to import the names of the characters along with the actors in the following format. For example, for the film 'Zulu' (https://www.imdb.com/title/tt0058777):

Stanley Baker ... Lt. John Chard
Jack Hawkins ... Rev. Otto Witt
Ulla Jacobsson ... Margareta Witt
James Booth ... Pvt. Henry Hook
Michael Caine ... Lt. Gonville Bromhead
Nigel Green ... Color Sgt. Bourne
Ivor Emmanuel ... Pvt. Owen
Paul Daneman ... Sgt. Maxfield
Glynn Edwards ... Cpl. Allen
Neil McCarthy ... Pvt. Thomas

It would be great to have the option to have (I'm quoting from the earlier script option): "4-> Actor names like on IMDB page, with "..." between names and roles, and separated by line breaks". Please take a look at the "ActorsLayout" and "AllActors" options of the earlier IMDB script and you'll be able to see the options that I am referring to.

Also, it'll be great to have the option to import the tag line before the description in the 'description' field.

All the other elements in the script work exactly as they should and, I repeat, the script is blazingly fast. :clapping:
Dorohedoro
Posts: 61
Joined: 2016-12-13 00:45:45

Re: [REL] IMDB ( via API )

Post by Dorohedoro »

Nice project thanks!. If you could add the option to import user votes for the ratings please!

I'm doing it with a personal script based on the official imdb script (on the subtitle field) and the result is like this:

Image

for me user votes are really important!
Lemaireus
Posts: 103
Joined: 2014-02-14 10:18:14

Re: [REL] IMDB ( via API )

Post by Lemaireus »

Got one error today on importing from https://www.imdb.com/title/tt0067778/. The third country, which should have been West Germany, was imported as 'XWG', and the script said, "Error: Unknown country code! Please report the error."
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

Re: [REL] IMDB ( via API )

Post by Munkey »

New version:

Code: Select all

1.0.5 - (2025/06/29) - Added support for "My ratings" field. [IMDB_userID must be set]
                     - Added CreditsLimit option.
                     - Reworked Director/Writer/Actors.
                     - Fixed country errors: 'West Germany','East Germany','Soviet Union','Czechoslovakia',
                                             'Yugoslavia','Zaire','Serbia and Montenegro','Burma'.
                     - Fixed country names: 'Vietnam', 'Czech Republic'.
                     - Fixed: The title search didn't include the adult titles.
                     - Fixed few other bugs.
Interestingly, when I was repeatedly running various tests I was temp banned from API on these titles (Only on those IDs, else still works!):
https://www.imdb.com/title/tt2306299/ - Vikings
https://www.imdb.com/title/tt0944947/ - Game of Thrones

Still no idea why and how, I tried to reproduce ban by removing all ratelimits on other IDs but I couldn't reproduce it.
So, can anyone try these IDs like 3 times or more in row with BatchMode > 0 and enabled IMDB_userID (your personal ratings), report the outcome.

Temp ban indicator -> you get 504 "Timeout" error.

Lemaireus wrote: 2025-06-29 15:47:11 Got one error today on importing from https://www.imdb.com/title/tt0067778/. The third country, which should have been West Germany, was imported as 'XWG', and the script said, "Error: Unknown country code! Please report the error."
Fixed in v1.0.5, thanks for the report.
Lemaireus wrote: 2025-06-29 05:36:08 The only bit missing for me now is:
1. The script imports only four actors. It would be great to have the option/s to import ten, or fifteen, or all, as one could in the earlier IMDB script.
2. The earlier IMDB script also allows us to import the names of the characters along with the actors in the following format.
1) Added CreditsLimit option in v1.0.5.
2) I'll think about it.
Lemaireus wrote: 2025-06-29 05:36:08 Also, it'll be great to have the option to import the tag line before the description in the 'description' field.
Probably I'll add it to the next version.
Dorohedoro wrote: 2025-06-29 06:57:08 Nice project thanks!. If you could add the option to import user votes for the ratings please!
Added support for it in v1.0.5.
Lemaireus
Posts: 103
Joined: 2014-02-14 10:18:14

Re: [REL] IMDB ( via API )

Post by Lemaireus »

Munkey wrote: 2025-06-29 19:53:13 So, can anyone try these IDs like 3 times or more in row with BatchMode > 0 and enabled IMDB_userID (your personal ratings), report the outcome.

Temp ban indicator -> you get 504 "Timeout" error.
I am not registered on IMDB so I did not enable the user ID, but my batchmode is set to 0 and I got the 504 gateway time-out error on both the titles that you referred to the very first time I tried importing information for them. Other titles continue to work fine.

I was about to suggest adding another function to the script--importing information by supplying the IMDB URL to the script, which can be useful in cases in which the script might have a hard time finding a specific title--but I see that the script already successfully imports all the information when one supplies it with the URL of a title.

Waiting for the [actor ... character] format and the tagline import now. All else is in order for me (and the mystery of the 'Vikings' and the 'Game of Thrones' titles remains).

Once again, thank you for some wonderful work.
Munkey
Posts: 13
Joined: 2025-06-19 04:55:29

Re: [REL] IMDB ( via API )

Post by Munkey »

Lemaireus wrote: 2025-06-30 07:34:54 I am not registered on IMDB so I did not enable the user ID, but my batchmode is set to 0 and I got the 504 gateway time-out error on both the titles that you referred to the very first time I tried importing information for them. Other titles continue to work fine.
Thanks for the test, that tells me a lot, I was wrong about "ban" because at first I got response from Vikings...
It looks like Cloudflare misconfiguration, if it doesn't get response from server in 16s then it produces the timeout error.
These titles have huge cast (that's why I tested them), so API server spends more time processing it, I'll think about implementing some fallback in such case.
Post Reply