Hello there! I am trying to get the details for all the different genres and their associated id's for my application but the couple of requests that I have done have returned null for all the fields. I tried it on the API Reference as well and am getting the same results. Is there something I am missing? (kept my api_key out of this code segment)
import requests
url = "https://api.themoviedb.org/3/genre/movie/list?language=en"
headers = {
"accept": "application/json",
"Authorization": "Bearer MY_API_KEY"
}
response = requests.get(url, headers=headers)
print(response.text)
{
"genres": [
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null
]
}
找不到电影或节目?登录并创建它吧。
Travis Bell 的回复
于 2023 年 11 月 16 日 9:14下午
See my reply here: https://www.themoviedb.org/talk/6556ab3ab5400214d82be7c9#6556cc63d4fe0400e1b3d1a9
dfishbein 的回复
于 2023 年 11 月 16 日 11:22下午
Oh good thank you for that!