Get to know the fundamentals of GraphQL: understand the query language and its runtime. Design and implement a GraphQL API, and learn the differences between it and REST.
Examples
Exercises
Context
In a distributed system, multiple systems must communicate with one another. On the web, a client (e.g. a browser or a server) wants to communicate with a server (e.g. a web service). To facilitate this, the server provides an application programming interface (API). These APIs can be implemented using various architectural styles and technologies.
The Request-Response Pattern is a communication pattern between two systems, where one system (the client) sends a request to the other system (the server) and the server responds with a response. This pattern is the basis for communication between a client and a server in a distributed system. The request contains information about the operation that should be performed and the parameters for the operation. The response contains the result of the operation. The request-response pattern is synchronous, which means that the client blocks until the server sends a response.
In this topic**,** we will create a GraphQL service that manages tasks for projects. For this, we use the Hasura Platform to quickly map a Postgres database schema to a GraphQL API.

Instant GraphQL APIs on your data | Built-in Authz & Caching
Next, we start the Hasura stack. This will run a server at [http://localhost:8](<http://localhost:8080>)888
docker compose up
Now, we create a projects table with an id and a name column:

Additionally, we create a tasks table with an id, a foreign-key to the project_id , a name and a done column:
