Soporte de The Movie Database

Hi, I try to add movie with id 767 (Harry Potter) to user's list. But I get an error with code 34. What is media_type and media_id?

My request:
curl --request POST \ --url https://api.themoviedb.org/4/{USER_LIST_ID}/items \ --header 'Authorization: Bearer {JWT_USER_TOKEN}' \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --data ' { "items": [ { "media_type": "movie", "media_id": 767 } ] } '

Thanks

1 respuesta (en la página 1 de 1)

Jump to last post

@egdevelop said:
how to use add items to list? API v4
Hi, I try to add movie with id 767 (Harry Potter) to user's list.
But I get an error with code 34.
What is media_type and media_id?

My request:
curl --request POST \ --url https://api.themoviedb.org/4/{USER_LIST_ID}/items \ --header 'Authorization: Bearer {JWT_USER_TOKEN}' \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --data ' { "items": [ { "media_type": "movie", "media_id": 767 } ] } '

Thanks

I do not master the use of TOKEN or v4.
But I can clarify two things.

Error 34:

34  401     The resource you requested could not be found.

See here: https://developer.themoviedb.org/docs/errors
Apparently he couldn't find his list.
Probably your USER_LIST_ID has some error.

media_type
It can be movie type or tv type (TV Show)

media_id
In this case, this TMDb ID 767 is the movie ID
Harry Potter and the Half-Blood Prince (2009)
See the 767 in the movie's URL:

https://www.themoviedb.org/movie/767-harry-potter-and-the-half-blood-prince

¿No encuentras una película o serie? Inicia sesión para crearla:

Global

s centrar la barra de búsqueda
p abrir menú de perfil
esc cierra una ventana abierta
? abrir la ventana de atajos del teclado

En las páginas multimedia

b retrocede (o a padre cuando sea aplicable)
e ir a la página de edición

En las páginas de temporada de televisión

(flecha derecha) ir a la temporada siguiente
(flecha izquierda) ir a la temporada anterior

En las páginas de episodio de televisión

(flecha derecha) ir al episodio siguiente
(flecha izquierda) ir al episodio anterior

En todas las páginas de imágenes

a abrir la ventana de añadir imagen

En todas las páginas de edición

t abrir la sección de traducción
ctrl+ s enviar formulario

En las páginas de debate

n crear nuevo debate
w cambiar el estado de visualización
p cambiar público/privado
c cambiar cerrar/abrir
a abrir actividad
r responder al debate
l ir a la última respuesta
ctrl+ enter enviar tu mensaje
(flecha derecha) página siguiente
(flecha izquierda) página anterior

Configuraciones

¿Quieres puntuar o añadir este elemento a una lista?

Iniciar sesión