HTTP request builder
Choose a method, a path and a body, and see the exact request text and the response a pretend Go server would send.
A web server answers requests. A request has a method (GET to read, POST to send data, DELETE to remove), a path, and sometimes a body. The response has a status code that says how it went: 200 OK, 201 Created, 400 Bad Request, 404 Not Found.
This is a pretend server with three tasks. Nothing goes over the network: the page just shows what a Go server like the one in the lessons would answer.
Things to try
- Click List the tasks. What is the status code, and what does the body look like?
- Add a task, then try Add an empty task. Which status code does the server use for a bad request?
- Delete task 2, then change the number to 99. What changes?
- Try a POST to / and a GET with a body. What does 405 Method Not Allowed mean?