In this course, we’ll build the backend API for an e-commerce application. Specifically, we’ll expose the following routes:
| Endpoint | Method | Description |
|---|---|---|
/products | GET | Get all products |
/products/:id | GET | Get a single product |
/products/search?q=...&limit=...&skip=... | GET | Search products |
/carts/:id | GET | Get a cart |
/carts/add | POST | Create a new cart |
/carts/:id | PUT | Update a cart |
/carts/:id | DELETE | Delete a cart |
The cart routes will be protected, while the product routes will be publicly accessible.
For the data, we will use DummyJSON, a free online REST API that provides realistic placeholder data. DummyJSON lets us skip the complexity of setting up a database and instead focus entirely on learning how to build APIs with Effect.