Documentation Index
Fetch the complete documentation index at: https://docs.getmaito.com/llms.txt
Use this file to discover all available pages before exploring further.
Architecture
Maito is split by surface and responsibility. Preserve this split when adding features.Surfaces
| Path | Responsibility |
|---|---|
apps/app | Product UI, page routes, client state, SDK usage, and thin browser-facing social callback shells. |
apps/web | Public website, blog, public tools, SEO pages, and marketing routes. |
apps/api | REST routes, webhook routes, auth middleware, HTTP validation, and route adapters. |
apps/mcp | MCP transport, OAuth protected-resource metadata, tool registration, and MCP adapters. |
apps/schedule-worker | Background execution using backend/domain packages. |
packages/backend | Product behavior, domain services, orchestration, and application rules. |
packages/db | Schema, migrations, repositories, and persistence models. |
packages/contracts | Zod schemas, response envelopes, shared public request/response types. |
packages/sdk | Typed API client methods and browser-safe request logic. |
packages/cli | CLI client that calls the backend API. |
Feature Flow
New browser-accessible backend functionality should usually move through the layers in this order:- Define or update contracts in
packages/contracts. - Implement domain logic in
packages/backend. - Expose an HTTP route in
apps/api. - Add typed client support in
packages/sdk. - Consume it from
apps/app.
App Boundaries
Do not add the following toapps/app:
- Business logic for documents, drafts, publishing, queues, or newsletters.
- New generic
/api/*proxy routes. - MCP endpoints.
- OAuth well-known metadata endpoints.
- Backend service containers or runtime composition.
- Direct database access.
- Direct imports from
packages/backendfor domain behavior.
apps/app is social
connect/callback routing. Those routes should call backend begin/complete
endpoints and redirect the browser.
Document Model
The system is document-first:- Canonical primitive:
document - Canonical address:
path - Public mental model: files/documents
- Retrieval model: document search/context over stored files