GraphQL is a query language for APIs that queries the server and provides the client only the data that is requested by the client. GraphQL enables you to fetch data from multiple APIs in a single query thus helping you build better-performing applications.
GraphQL
tab in the left sidebar.
The GraphQL platform has the following features:
query
builder assists you in designing queries to fetch the data that you require and run it.
You can also add dynamic behavior to your queries by defining variables
, headers
, and authorization
.
Laptop
and Maker
. The Laptop
type has two fields model
and maker
. The Maker
type has two fields name
and laptops
. The laptops
field in the Maker
type is an array of the Laptop
type.
GraphQL queries are written in the GraphQL query language. Given below is an example of a GraphQL query.
name
and laptops
of the Maker
with the name Apple
.
GraphQL queries can be executed using a GraphQL client. Postdata has a built-in GraphQL client that can be used to execute GraphQL queries.