mirror of
https://github.com/d3vyce/fastapi-toolsets.git
synced 2026-03-01 17:00:48 +01:00
9b75cc7dfc0de202cf73ee90d60b2511c861fc08
Bumps [ty](https://github.com/astral-sh/ty) from 0.0.17 to 0.0.18. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.17...0.0.18) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.18 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
FastAPI Toolsets
A modular collection of production-ready utilities for FastAPI. Install only what you need — from async CRUD and database helpers to CLI tooling, Prometheus metrics, and pytest fixtures. Each module is independently installable via optional extras, keeping your dependency footprint minimal.
Documentation: https://fastapi-toolsets.d3vyce.fr
Source Code: https://github.com/d3vyce/fastapi-toolsets
Installation
The base package includes the core modules (CRUD, database, schemas, exceptions, fixtures, dependencies, logging):
uv add fastapi-toolsets
Install only the extras you need:
uv add "fastapi-toolsets[cli]" # CLI (typer)
uv add "fastapi-toolsets[metrics]" # Prometheus metrics (prometheus_client)
uv add "fastapi-toolsets[pytest]" # Pytest helpers (httpx, pytest-xdist)
Or install everything:
uv add "fastapi-toolsets[all]"
Features
Core
- CRUD: Generic async CRUD operations with
CrudFactory, built-in search with relationship traversal - Database: Session management, transaction helpers, table locking, and polling-based row change detection
- Dependencies: FastAPI dependency factories (
PathDependency,BodyDependency) for automatic DB lookups from path or body parameters - Fixtures: Fixture system with dependency management, context support, and pytest integration
- Standardized API Responses: Consistent response format with
Response,PaginatedResponse, andPydanticBase - Exception Handling: Structured error responses with automatic OpenAPI documentation
- Logging: Logging configuration with uvicorn integration via
configure_loggingandget_logger
Optional
- CLI: Django-like command-line interface with fixture management and custom commands support
- Metrics: Prometheus metrics endpoint with provider/collector registry
- Pytest Helpers: Async test client, database session management,
pytest-xdistsupport, and table cleanup utilities
License
MIT License - see LICENSE for details.
Contributing
Contributions are welcome! Please feel free to submit issues and pull requests.
Languages
Python
100%