0
0
GraphQLquery~10 mins

First GraphQL query - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to query the name of a user.

GraphQL
{ user { [1] } }
Drag options to blanks, or click blank then click option'
Aage
Bname
Cemail
Did
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing a field that does not exist in the user type.
Forgetting to specify a field inside the user braces.
2fill in blank
medium

Complete the code to query the user's email.

GraphQL
{ user { [1] } }
Drag options to blanks, or click blank then click option'
Aname
Busername
Cemail
Dpassword
Attempts:
3 left
💡 Hint
Common Mistakes
Using a field that is not part of the user type.
Using a sensitive field like password which is usually not queryable.
3fill in blank
hard

Fix the error in the query to get the user's id.

GraphQL
{ user { [1] } }
Drag options to blanks, or click blank then click option'
AID
BId
CuserId
Did
Attempts:
3 left
💡 Hint
Common Mistakes
Using uppercase or camel case for field names incorrectly.
Using a field name that does not exist.
4fill in blank
hard

Fill both blanks to query user's name and email.

GraphQL
{ user { [1] [2] } }
Drag options to blanks, or click blank then click option'
Aname
Bemail
Cage
Dpassword
Attempts:
3 left
💡 Hint
Common Mistakes
Including fields that are not part of the user type.
Forgetting to separate fields with space.
5fill in blank
hard

Fill all three blanks to query user's id, name, and email.

GraphQL
{ user { [1] [2] [3] } }
Drag options to blanks, or click blank then click option'
Aid
Bname
Cemail
Dpassword
Attempts:
3 left
💡 Hint
Common Mistakes
Including sensitive or invalid fields like password.
Using incorrect field names or casing.