GraphQL MCQ Questions And Answers
GraphQL MCQs : This section focuses on "Basics" of GraphQL. These Multiple Choice Questions (MCQ) should be practiced to improve the GraphQL skills required for various interviews (campus interviews, walk-in interviews, company interviews), placements, entrance exams and other competitive examinations.
1. GraphQL is ?
A. open source
B. server-side technology
C. Both A and B
D. None of the above
View Answer
Ans : C
Explanation: GraphQL is an open source server-side technology to optimize RESTful API calls. It is an execution engine and a data query language.
2. GraphQL is an open source server-side technology which was developed by?
A. Google
B. Facebook
C. Amazon
D. Microsoft
View Answer
Ans : B
Explanation: GraphQL is an open source server-side technology which was developed by Facebook.
3. GraphQL Server can be deployed by using any of the _______ methods.
A. 1
B. 2
C. 3
D. 4
View Answer
Ans : C
Explanation: GraphQL Server can be deployed by using any of the three methods : GraphQL server with connected database , GraphQL server that integrates existing systems and Hybrid approach .
4. Which approach is helpful for companies which have legacy infrastructure and different APIs?
A. GraphQL server with connected database
B. GraphQL server that integrates existing systems
C. Hybrid approach
D. None of the above
View Answer
Ans : B
Explanation: GraphQL Server Integrating Existing Systems : This approach is helpful for companies which have legacy infrastructure and different APIs. GraphQL can be used to unify microservices, legacy infrastructure and third-party APIs in the existing system.
5. A ____________ is the client application request to retrieve data from database or legacy API's.
A. GraphQL schema
B. GraphQL resolvers
C. Both A and B
D. GraphQL query
View Answer
Ans : D
Explanation: A GraphQL query is the client application request to retrieve data from database or legacy API's.
6. Resolvers provide the instructions for turning a GraphQL operation into data.
A. TRUE
B. FALSE
C. Can be true or false
D. Can not say
View Answer
Ans : A
Explanation: True, Resolvers provide the instructions for turning a GraphQL operation into data.
7. Mutations are operations sent to the server to ___________ data.
A. create
B. delete
C. update
D. create, update or delete
View Answer
Ans : D
Explanation: Mutations are operations sent to the server to create, update or delete data.
8. Which of the following is an optional argument and can be used to print errors to the server console?
A. typeDefs
B. Resolvers
C. logger
D. parseOptions
View Answer
Ans : C
Explanation: Logger : This is an optional argument and can be used to print errors to the server console.
9. The makeExecutableSchema function takes a single argument {} of Object type.
A. TRUE
B. FALSE
C. Can be true or false
D. Can not say
View Answer
Ans : A
Explanation: True, The makeExecutableSchema function takes a single argument {} of Object type.
10. GraphQL is a strongly typed language.
A. Yes
B. No
C. Can be yes or no
D. Can not say
View Answer
Ans : A
Explanation: Yes, GraphQL is a strongly typed language.
Discussion