Dart backend development
Build a REST API with Shelf, validate requests and plan authentication, persistence and deployment.
Start with one Shelf endpoint, then work through the task API contract. The downloadable project needs no database to run locally; later lessons explain the production identity, persistence and hosting work.
Your lessons
One clear step at a time- 01Dart backend architecture: request, service and repositoryChoose a server approach and separate transport, domain behavior and persistence.2 min
- 02Dart Shelf server tutorial: your first JSON endpointCreate a local HTTP server, return JSON and verify the endpoint with a real request.2 min
- 03Dart REST API routes: CRUD, status codes and paginationDesign predictable resource endpoints and verify successful and missing-resource behavior.2 min
- 04Dart API request validation: JSON, schemas and body limitsValidate representation, shape and domain rules before mutating stored data.2 min
- 05Dart Shelf middleware and CORS: handle cross-cutting behaviorCompose request handling while keeping cross-origin browser policy separate from authorization.2 min
- 06Dart backend authentication and authorization: verify identity and ownershipVerify a trusted identity and enforce resource ownership instead of trusting client-supplied user IDs.2 min
- 07Dart PostgreSQL tutorial: parameterized queries and transactionsReplace ephemeral storage with a deliberate schema, parameterized access and transaction boundaries.2 min
- 08Dart WebSockets and background jobs: manage long-lived workDefine connection and job lifecycles without assuming an HTTP request owns every ongoing task.2 min
- 09Deploy a Dart backend: runtime, containers and production checksRun a persistent Dart service separately from static shared-hosting tutorial files.2 min