Hi,
Had a couple of questions for my usecase. Firstly wanted to say love the support and the API, really appreciative to the amazing developers and community contributors!!!
Context:
Building a website with rows of content from discover endpoint and each row has poster.
Calling discover endpoint for each row.
I need to call details endpoint for each poster in the row for following parameters:
english_backdrop: Since the posters are horizontal with no embedded title, I need the English backdrop for each poster. I append to response the image endpoint
Runtime: On hover for movies I show runtime
Seasons: On hover for shows I show seasons
Genre / Date are also shown on hover but I can get from initial discover response.
Issues / Questions: I have roughly 25 rows with 20 posters each - so total of 25 discover + (25 * 20 details) = 525 requests per page per user. This is obviously higher than the limit of 50 requests per second.
Can I rely on the rate issue 525 error to wait? So for each of my posters I call details endpoint and if I get a 425 wait 1 seconds, keep doing this until I get response or error.
Secondly, seems like the API rate limits are per IP address. But my requests are sent via cloud functions to prevent users from seeing my API key. Wouldn't that mean that there's only 1 IP address, my server IP?
Suggestions / Feature Requests:
Thank you!
Es fehlt ein Film oder eine Serie? Logge dich ein zum Ergänzen.
Diesen Eintrag bewerten oder zu einer Liste hinzufügen?
Kein Mitglied?
Antwort von ticao2 🇧🇷 pt-BR
am 7. Dezember 2023 um 07:58
A reminder.
In a standard Discover response, you already receive the film's Poster and Backdrop, in the specified language.
Maybe it will help to reduce the number of Requests.
I leave your other questions to someone with more knowledge to answer.
Antwort von Respearme
am 7. Dezember 2023 um 08:13
Yes that makes sense but most of the time its no language - I think it just gets the most popular. I have to make sure that its English because I am not showing the content title in my poster.
So what I'm doing now is appending images to details endpoint and filtering all backdrops to only ones with english
but this requires details endpoint
Antwort von ticao2 🇧🇷 pt-BR
am 7. Dezember 2023 um 08:15
It may be best to specify in detail what data you need that is not in the initial Discover API Request.
If possible, separate the list for film and series.
Untitled Poster
Untitled Backdrop (usually they are already untitled)
Duration
ETC...
Antwort von Respearme
am 7. Dezember 2023 um 08:21
Here is the data I need for initial Discover endpoint:
Both Movies and Shows: Backdrop - English if available, if not then untitled (Right now Discover doesn't give this so I need to call details endpoint)
Movies: Runtime
Shows: Seasons count
Antwort von ticao2 🇧🇷 pt-BR
am 7. Dezember 2023 um 08:33
Movies
I'm not entirely sure, but I believe that in the case of Backdrop, the response prefers the one with a title in the specified language and, if it doesn't exist, it sends the one without a title.
TV Show
I do not remember. But probably the same rule.
I would need to take a test. Or you do it yourself.
Need Details.
Need Details.
Antwort von Respearme
am 7. Dezember 2023 um 08:50
Yes I've tested everything and need details for it all. That's why I asked the 2 questions above about workarounds / solutions.
Also would love some sort of batch send / append to response solution to greatly reduce payload + number of requests.