Sorry first time using API to fetch data, I want to get actor or actress image using there name is it possible to do so? if Yes, what would be the link or how the call should be made?
Δεν μπορείτε να βρείτε κάποια ταινία ή σειρά; Συνδεθείτε για να τη δημιουργήσετε.
Θέλετε να αξιολογήσετε ή να προσθέσετε αυτό το στοιχείο σε μια λίστα;
Δεν είσαι μέλος;
Απάντηση από τον/την RichaGupta
στις 26 Μάρτιος 2018 στις 01:12 ΜΜ
Ok as I looked further I found this https://developers.themoviedb.org/3/people/get-person-images there is a way to get an image but it asks for "person_id" where will I find person id?
Απάντηση από τον/την Travis Bell
στις 26 Μάρτιος 2018 στις 03:57 ΜΜ
Hi @RichaGupta,
When you say you want to get the images of a person do you mean their profile images or rather, the backdrops and posters that they appear in?
Απάντηση από τον/την RichaGupta
στις 27 Μάρτιος 2018 στις 07:27 ΕΊΜΑΙ
Hi Travis,
I am trying to get their profile pic, I am able to get to it somehow now but I am confused why there are multiple pics return and which one should be considered? like if I try to find Chris Brown pics there are 5 different images I am getting how would I know which one to pick programmatically?
I first try to get to that person details like this
https://api.themoviedb.org/3/search/person?api_key=XXXXXXXXXXX&language=en-US&query=Chris%20Brown&page=1&include_adult=false
there you can see "profile_path" out of all 39 total results, it has 5 images which one to consider in that case?
https://image.tmdb.org/t/p/w500/mPQkVbV1SBo0d7lE2BlEivCOrs2.jpg https://image.tmdb.org/t/p/w500/4k8sacCMG9jI2jo7x5XVSzq2Mnt.jpg https://image.tmdb.org/t/p/w500/vL805BcPV6xbu2HUZig8ZEvnjJL.jpg https://image.tmdb.org/t/p/w500/7IwyeH44l7MaJ9Fo48CVxj7nyQT.jpg https://image.tmdb.org/t/p/w500/coja80Y3B1XJeCJpW6l1ReCH7Zh.jpg
Thanks Richa
Απάντηση από τον/την Travis Bell
στις 27 Μάρτιος 2018 στις 10:00 ΕΊΜΑΙ
Hi Richa,
Each item in the results array is an object representative of a single person. There is only 1 image per object. I've truncated the results here:
So the 3rd item in the array has a profile image of "/mPQkVbV1SBo0d7lE2BlEivCOrs2.jpg".
Απάντηση από τον/την RichaGupta
στις 27 Μάρτιος 2018 στις 10:20 ΕΊΜΑΙ
ok thanks, I think I am able to figure it out there are some glitches but its working for now :)
Απάντηση από τον/την TohidGazi
στις 13 Νοέμβριος 2023 στις 01:47 ΜΜ
how can we get actors images for each movie
Απάντηση από τον/την ticao2 🇧🇷 pt-BR
στις 13 Νοέμβριος 2023 στις 06:52 ΜΜ
When you make a Movie Details API Request,
https://developer.themoviedb.org/reference/movie-details
and use the "&append_to_response=" resource with "credits",
https://developer.themoviedb.org/docs/append-to-response
it may solve your problem.
For example:
In the response you will receive the cast list.
And in each person in the cast you will find the "profile_path" of the person's default image.
That is, the image presented on the person's home page here on TMDb.