پشتیبانی پایگاه داده‌ فیلم

Hey there! Longtime user, first time poster. Big fan.

I was doing some organizing tonight and noticed the release date for Black Panther returned from the API (under release_date, see here) is 2018-02-13. On the site page, it's correctly listed as 2018-02-16. I checked for a number of upcoming movies (mostly Marvel) and the same 2-5 day drift is there on the other API results.

Is there a reason the API is different from the site and is there a way to fix it?

3 پاسخ (در صفحه 1 از 1)

Jump to last post

Hi @xavdid,

Hey there! Longtime user, first time poster. Big fan.

Thanks for kind words grinning

That would because on the API, without a region, the first theatrical release is being used. On the website, you're probably seeing the U.S. release date.

So for the upcoming call, you could do this:

https://api.themoviedb.org/3/movie/upcoming?api_key=###&language=en-US&region=US

Please note, that due to a bug with the way release dates are calculated you might not see Black Panther on the list. Refresh it and the dates will change and you'll see it. I really need to fix this!

When you see Black Panther, you'll see that the release date is Feb. 16. You can read more about regions here.

Ah, got it. The page I'm using (almost exclusively) is the /movie/{id} page described here. That page doesn't seem to take a region param, but with append_to_request and some extra parsing, I should be able to get what I need.

Does the release_date pull from a specific region? It seems like it pulls from GB (that's the only date that matches up). Or is it just pulling the earliest type == 3 release?

Either way, thanks again for a great product!

Does the release_date pull from a specific region? It seems like it pulls from GB (that's the only date that matches up). Or is it just pulling the earliest type == 3 release?

On the website it's pulling 2 & 3 I believe. Order matters on discover, so you can build a query like this:

https://api.themoviedb.org/3/discover/movie?api_key=###&release_date.gte=2018-02-21&release_date.lte=2018-03-15&region=GB|US&with_release_type=3|2

So this is looking for movies within the specified release range in GB and the US, and that have either a limited theatrical or wide theatrical release. If you want GB only, change region to just 'US'.

فیلم و نمایش تلویزیونی را نمی‌توانید پیدا کنید؟ به سیستم وارد شوید تا آن را ایجاد کنید.

Global

s تمرکز بر منوی جستجو
p منوی پروفایل باز شود
esc بستن پنجره باز
? پنجره میانبرهای صفحه‌کلید باز شود

در صفحات مدیا

b بازگشت به عقب (یا در صورت لزوم به منشا)
e برو به صفحه ویرایش

در صفحات فصل تلویزیونی

(فلش سمت راست) برو به فصل بعد
(پیکان سمت چپ) برو به نشست قبلی

در صفحات قسمت تلویزیونی

(فلش سمت راست) برو به قسمت بعد
(پیکان سمت چپ) برو به قسمت قبلی

در تمام صفحات تصویر

a پنجره افزودن تصویر باز شود

در تمام صفحات ویرایش

t انتخابگر ترجمه باز شود
ctrl+ s ثبت از

در صفحات بحث

n ایجاد بحث جدید
w تغییر وضعیت وضعیت تماشا
p تغییر وضعیت عمومی/خصوصی
c تغییر وضعیت بسته/باز
a گشایش صفحه فعالیت
r پاسخ به بحث
l برو به آخرین پاسخ
ctrl+ enter پیام خود را ثبت کنید
(فلش سمت راست) صفحه بعد
(پیکان سمت چپ) صفحه قبلی

تنظیمات

آیا می‌خواهید به این مورد امتیاز دهید یا به فهرست اضافه کنید؟

ورود