Automated Action 7a428ef859 Update Pydantic schemas to support enhanced todo features
- Add comprehensive user schemas with email validation
- Implement enhanced todo schemas with priority levels, tags, due dates, and subtasks
- Add support for recurring todos with pattern validation
- Include sharing schemas for collaborative features
- Add proper validation rules and field constraints
- Create response schemas for API pagination and collections
- Include authentication and API response schemas
- Add comprehensive documentation strings for all schema classes
2025-06-19 12:50:08 +00:00
2025-06-19 12:05:38 +00:00

Todo App Backend

A simple todo application backend built with FastAPI and SQLite.

Features

  • Create, read, update, and delete todos
  • RESTful API endpoints
  • SQLite database with SQLAlchemy ORM
  • Database migrations with Alembic
  • Automatic API documentation with Swagger UI
  • CORS support for cross-origin requests

API Endpoints

  • GET / - Root endpoint with API information
  • GET /health - Health check endpoint
  • POST /todos/ - Create a new todo
  • GET /todos/ - Get all todos (with pagination)
  • GET /todos/{todo_id} - Get a specific todo
  • PUT /todos/{todo_id} - Update a todo
  • DELETE /todos/{todo_id} - Delete a todo

Installation

  1. Install dependencies:
pip install -r requirements.txt
  1. The application will automatically create the database tables when started.

Usage

Start the application:

uvicorn main:app --reload

The API will be available at:

Database

The application uses SQLite database stored at /app/storage/db/db.sqlite. The database schema is managed with Alembic migrations.

Todo Schema

Each todo has the following fields:

  • id: Unique identifier
  • title: Todo title (required)
  • description: Optional description
  • completed: Boolean status (default: false)
  • created_at: Creation timestamp
  • updated_at: Last update timestamp
Description
Project: Todo App Backend
Readme 44 KiB
Languages
Python 97.7%
Mako 2.3%