https://api.themoviedb.org/4/list/118015?page=2&api_key=[your_key]&sort_by=release_date.desc
That's just one example but seems all my lists the sort_by=release_date.asc works but sort_by=release_date.desc does not. In the example I gave it gets progressively worse. Pay attention to the end of page1...then flip to page2 and it's grossly off. The apis order does not match the web site, which seems to sort it fine. 118015
Un film, une émission télévisée ou un artiste est introuvable ? Connectez-vous afin de créer une nouvelle fiche.
Vous souhaitez évaluer ou ajouter cet élément à une liste ?
Pas encore membre ?
Réponse de Travis Bell
le 3 août 2021 à 16h26
Hi @Ken62465,
Sorting by
release_date.desc
without aregion
filter, will use the earliest date added to a movie. So just as an example, if you look at the second item in your list, Raging Fire, you can see there is a date added for2021-07-30
. But, if you update your query to:You'll see the returned date as
2021-08-13
which is more accurate. Keep in mind though, I am only using US as an example and not every movie will have a US release date, so in those cases the filter will still fallback to the earliest available.Réponse de Ken62465
le 3 août 2021 à 18h30
I had no idea it allowed a region query param. It was not listed here https://developers.themoviedb.org/4/list/get-list nor can you add the param. I didn't think to try that param in a browser but should of been obvious to me I guess.
So I just tested that. Still a no go as it now drops 9 titles and a few are still out of order, but close enough to live with I guess. The dropped 9 titles I can't live with so I'm stuck with using
.asc
sort for now. Did you notice the 9 dropped titles using the®ion=US
? Should return 32 total items like the web site shows, which sorts .desc fine there. If you compare howsort_by=release_date.asc
works it's fine there in the json response also. Wonder if this is related to that same issue I had with lists dropping titles on me a year ago..like you remember talking to me back then..lol. You fixed the problem though, this just looks strangely familiar to that.Thanks for looking into this Travis..appreciate all you do!!!!
Réponse de Ken62465
le 5 août 2021 à 23h00
This did the trick. It sorted exactly as the web site does and region was not required.
Réponse de savithaparmar
le 8 août 2021 à 03h37
Can I change API information details because by mistake I have selected app instead of website
Réponse de ticao2 🇧🇷 pt-BR
le 8 août 2021 à 09h37
Your question has been answered here.
https://www.themoviedb.org/talk/610f7edb960cde0072c1ff65