Examples
The repository examples/ directory is the executable counterpart of these
docs. Each package is a workspace member.
| Package | Shows | Needs |
|---|---|---|
hello_world |
Routes, path/query extractors, JSON validation, OpenAPI | nothing |
todo_sqlite |
#[derive(Model)], CRUD, ForeignKey, TestClient |
SQLite (default) |
blog_postgres |
AppCli, migrations, OAuth2 password flow, signals, pagination |
DATABASE_URL (or in-memory SQLite for tests) |
polyglot |
Two databases, DatabaseRouter, cross-db rejection |
optional USERS_DATABASE_URL / ANALYTICS_DATABASE_URL |
todo_mongo |
Same handlers as the SQLite todo on MongoDB | MONGODB_URL |
cd examples/hello_world && siderite runcd examples/todo_sqlite && siderite runWalkthroughs:
Live databases for the PostgreSQL, MySQL, MongoDB, and Redis suites start
from the root docker-compose.yml. See Testing.