Welcome to Tatami! πΒΆ
Tatami is a modern Python web framework built on Starlette that makes building APIs a joy. With class-based routers, automatic dependency injection, and convention-based project structure, you can focus on what matters: your business logic.
Important
π Documentation Notice: This documentation has been generated by Claude Sonnet 4 (AI) and is currently under human review. While the content aims to be accurate and helpful, there may be errors or inconsistencies.
I (the maintainer) am carefully reviewing all pages, but since documenting code is what most developers are lazy about π , this process will take some time.
Found an error? Please report it via GitHub Issues or submit a PR - your contributions are very welcome! π
Like traditional Japanese tatami mats that create order and harmony in a room, Tatami helps you structure your web applications with clean, modular design patterns.
Why Choose Tatami? πΒΆ
β¨ Clean & Organized: Class-based routers keep your code tidy and maintainable
π Fast Development: CLI tools get you up and running in seconds
π Auto Documentation: OpenAPI/Swagger docs generated automatically
π§© Modular Design: Separation of concerns through clear project structure
π§ Developer Experience: Great IDE support with type hints and autocomplete
β‘ Convention over Configuration: Smart defaults, but youβre always in control
Important
π§ Early Stage: Tatami is experimental and evolving rapidly. Perfect for new projects and learning, but check back regularly for updates!
Quick Taste π¨βπ³ΒΆ
Hereβs what a simple Tatami API looks like:
# routers/users.py
from tatami import router, get, post
from pydantic import BaseModel
class User(BaseModel):
name: str
email: str
class Users(router('/users')):
@get('/{user_id}')
def get_user(self, user_id: int):
return {"id": user_id, "name": "Alice"}
@post('/')
def create_user(self, user: User):
return {"message": f"Created {user.name}"}
Run it with:
tatami run myproject
And you get automatic API docs at /docs/ (landing page) and /docs/swagger (interactive UI) plus a clean, testable codebase!
Philosophy: Explicit Routes, Smart Structure π§ ΒΆ
Tatami believes in explicit routing (clear, obvious API definitions) combined with smart conventions (automatic discovery of services, middleware, and static files).
This means: - Your API routes are crystal clear and IDE-friendly - Your project structure follows sensible conventions - Less boilerplate, more focus on business logic - Easy to understand for new team members
Learn Tatami Step by Step
CLI & Tools
Migration Guides
Advanced Topics
Reference
Need Help? π€ΒΆ
π Documentation: Youβre reading it!
π Issues: GitHub Issues
π¬ Discussions: GitHub Discussions
π§ Email: ibonescartin@gmail.com