Error message : Cannot read property 'launchAPI' of undefined in Apollo Graphql Studio. How to fix this error

Hi, there.
I’m trying the following query in Apollo Graphql Studio while checking the tutorial.

query GetLaunches {
  launches {
    id
    mission {
      name
    }
  }
}

However, It then indicates the error message, “Cannot read property ‘launchAPI’ of undefined”, on the right side of the screen when I click “Get launch”.

I want to display the server response based on the query, “GetLaunches”. What and how should I fix to display the data?

In addition, in order to execute the query, I have already done and uploaded the programming based on the tutorial on GitHub.

Thank you.

Same story, fighting this for a month!
Do you find the solution?
Thanks:)

Hi!
I have yet to find the solution.
So I’m trying Odyssey, instead of the tutorial.
In Odyssey, you might be able to check the apollo-graphql’s action.
Thank you.

1 Like

Thank you!
For the last month I went through another video-tutorial but got this error over and over again. I read all the forums I could find, but none of the solutions helped.

Finally, I found the solution myself. I’m a newbie, so I didn’t understand how it works, also I didn’t find anything about it in the Apollo documentation. I know we can have completely different situations, but adding the line “_root: undefined” solves the problem for me. Without it, it’s an error.

Also, in my case it must be passed in second place, after the line “parent: Parent”, otherwise there will be an error with searching in MongoDB lately.
Снимок экрана 2021-12-28 в 03.41.19

I guess it’s not a robust solution, just a kludge, but i get the same result, as in tutorial. Also it seems strange to me why in the tutorial everything worked without it (also i checked versions in package.json several times and made them identically)

1 Like