Exercise: Explore Exoplanets
🎯 Goal: Use a GraphQL mutation to choose your favorite interstellar destination to visit.
Navigate to the workshop's graph in GraphOS Studio.
Open up the Explorer by clicking on
Explorer
in the left-hand menu.Using the built-in documentation or Operation Collections, query the API to learn about some of the exoplanets we might one day visit.
Navigate to some of the NASA URLs you find to get a better idea what it might be like to go there.
Build and run a mutation to submit your favorite destination.
💠Hints
✅ Solution
Explore the interstellar experiences:
query AllExperiencesQuery {experiences {namedescriptionnasaPosterUrl # visit links in your browser!destination {namestarSystemnasaTravelGuideUrl # visit links in your browser!}}}
Then submit your destination:
mutation SubmitFavoriteDestination($destination: TopDestination!) {submitFavoriteDestination(destination: $destination)}
Using variables:
{"destination": "EXOPLANET_TRAPPIST_1E"}
Share your questions and comments about this lesson
Your feedback helps us improve! If you're stuck or confused, let us know and we'll help you out. All comments are public and must follow the Apollo Code of Conduct. Note that comments that have been resolved or addressed may be removed.
You'll need a GitHub account to post below. Don't have one? Post in our Odyssey forum instead.