Axuda de The Movie Database

The documentation doesn't specify. It only says json. I assumed it was the id of the movie or TV series but that didn't work. Here is what I tried {"id": 12}. I even tried adding quotations marks around the numbers without success. That id exists, it leads to Finding Nemo. However it doesn't work.

2 respostas (na páxina 1 de 1)

Jump to last post

@HelloUser000 said:

Here is what I tried {"id": 12}.

You need three key-value pair element,

{
   media_type: 'movie', 
   media_id: 11, 
   watchlist: true
}

To get request JSON body follow this steps:

  1. Go to (click this)
  2. On right side, select your perefered language programming
  3. On dropdown REQUEST EXAMPLE just click REQUEST EXAMPLE
  4. For example I choose Node and using FETCH REQUEST, the output on the box area will be
const url = 'https://api.themoviedb.org/3/account/21457174/watchlist';
const options = {
  method: 'POST',
  headers: {
    accept: 'application/json',
    'content-type': 'application/json',
    Authorization: 'Bearer {{YOUR_API_READ_ACCESS_TOKEN}}'
  },
  body: JSON.stringify({media_type: 'movie', media_id: 11, watchlist: true})
};
fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));

you can see the json body is:

...
body: JSON.stringify({media_type: 'movie', media_id: 11, watchlist: true})
...

Thanks

Non podes atopar unha película ou serie? Inicia sesión para creala.

Global

s amosar a barra de procura
p abrir menú do perfil
esc pechar e abrir xanela
? abrir xanela de atallos do teclado

En páxinas de medios

b atrás (ou á principal se aplica)
e ir a editar páxina

En páxinas de tempadas de televisión

(flecha dereita) ir á tempada seguinte
(flecha esquerda) ir á tempada anterior

En páxinas de episodios de televisión

(flecha dereita) ir ao episodio seguinte
(flecha esquerda) ir ao episodio anterior

En todas as páxinas de imaxe

a abrir a xanela de engadir imaxe

En todas as páxinas de edición

t abrir selector de traducións
ctrl+ s enviar formulario

Nas páxinas de debate

n crear un novo debate
w amosar o estado do seguimento
p mudar público/privado
c mudar abrir/pechar
a abrir actividade
r responder no debate
l ir á última resposta
ctrl+ enter eviar a túa mensaxe
(flecha dereita) páxina seguinte
(flecha esquerda) ir á páxina anterior

Configuración

Queres valorar ou engadir o elemento a unha listaxe?

Iniciar sesión