The Movie Database -tuki

Hi, I'm trying to use the Google sheet function IMPORTDATA to get some specific data to sheets:

IMPORTDATA("https://api.themoviedb.org/3/movie/"&A2&"&apikey=MYAPYKEY") (the idea is that formula put in B1 picks up movie ID from the cell A1)

but it's not working , error reported - "Could not fetch url: https://api.themoviedb.org/3/movie/1184918?&apikey=...."

What did I miss? In API connector extension, URL works fine, but I need that formula to pull the movie ID from the previous cell (A column) in every row

For OMDB, the same formula works fine - pulls the data with no problem: IMPORTDATA("https://omdbapi.com/?i="&A1&"&apikey=MYAPIKEY")

5 vastausta (sivulla 1, sivuja yhteensä 1)

Jump to last post

I didn't check if IMPORTDATA is working, but your query should use "?" instead of "&".

Do you mean in A1 part where the previous cell is called, like this - "?A1?" instead of "&A1&" ?

=IMPORTDATA("https://api.themoviedb.org/3/movie/"?A1?"&apikey=MYAPYKEY")

Doesn't work either way (same if I change & to ? , before the apikey= part). I also tried with API KEY and with API Read Access Token, no success

It doesn't work even with static movie ID. like this (with or without my API key added):

=IMPORTDATA("https://api.themoviedb.org/3/movie/343611&apikey=MYAPIKEY")

Is there any other function that should be called instead to pull the data in the cell, - IMPORTXML, IMPORTHTML or what? or some parameters have to be added / changed in IMPORTDATA?

Any help highly appreciated.

No. I mean before the API key.

  • "?" should be used before the parameters
  • "&" should be used to separate the parameters.

In this case, there is only one parameter (the API key), so you should use "?" in front of it.

Also, the API key parameter is called "api_key", not "apikey".

Yes, that's it. I don't know how I missed it; should've drink the coffee first, wouldn't mess the syntax :)

It works now: =IMPORTDATA("https://api.themoviedb.org/3/movie/"&A2&"?api_key=MYAPIKEY")

Is there a way to add parameters to the function to return / call only these:

  • videos.results.1.key
  • backdrop_path
  • tagline

@vedranst said:

Is there a way to add parameters to the function to return / call only these:

  • videos.results.1.key
  • backdrop_path
  • tagline

No.

Etkö löydä elokuvaa tai TV-ohjelmaa? Kirjaudu sisään lisätäksesi se.

Koko sivustolla

s keskitä hakukenttään
p avaa profiilivalikko
esc sulje avoin ikkuna
? avaa pikanäppäinikkuna

Mediasivuilla

b palaa takaisin (tai hakemistoon mikäli mahdollista)
e siirry editoimaan sivua

TV-sarjan kausien sivuilla

(oikea nuolinäppäin) siirry seuraavaan kauteen
(vasen nuolinäppäin) siirry edelliseen kauteen

TV-sarjan jaksojen sivuilla

(oikea nuolinäppäin) siirry seuraavaan jaksoon
(vasen nuolinäppäin) siirry edelliseen jaksoon

Kaikilla kuvasivustoilla

a avaa "lisää kuva" ikkuna

Kaikilla muokkaus-sivuilla

t avaa kielivalinta
ctrl+ s Lähetä lomake

Keskustelu sivuilla

n luo uusi keskustelu
w vaihda seurannan asetus
p vaihda julkinen/yksityinen asetus
c vaihda avaa/sulje asetus
a avaa viimeaikainen toiminta
r vastaa keskusteluun
l siirry viimeisimpään vastaukseen
ctrl+ enter Lähetä viesti
(oikea nuolinäppäin) seuraava sivu
(vasen nuolinäppäin) edellinen sivu

Asetukset

Haluatko pisteyttää vai lisätä tämän nimikkeen listaan?

Kirjaudu

Ei rekisteröitynyt jäsen?

Rekisteröidy ja liity mukaan yhteisöön