Who Is This Framework For
Productivity-Focused Developers
Those who want to focus on business logic without wasting time on repetitive tasks
Teams That Trust Type Safety
Teams that prefer compile errors over runtime errors and maximize IDE assistance
Backend Developers Collaborating with Frontend
Those who want to escape the dual work of API spec documentation and client writing
Startups Needing Rapid Prototyping
Teams that want to build MVPs quickly while minimizing technical debt
Core Philosophy: Single Source of Truth
Define one Entity, and TypeScript handles the rest.Backend and Frontend Type Synchronization
Typically, when building backend APIs and using them on the frontend, type synchronization is difficult. With Sonamu, backend changes are immediately reflected on the frontend, catching errors at compile time.- Manual Approach
- Sonamu Approach

Fully Type-safe Query Builder: Puri
Sonamu provides Puri, a type-safe query builder based on Knex. Table names, column names, and relationships are all type-checked.- ✅ Types auto-extracted from Entity definition
- ✅ Autocomplete for table names, column names, and relationships
- ✅ Wrong column names cause compile errors
- ✅ All Knex features supported
Puri Guide
Write type-safe queries
Frontend Integration
When you define a backend API, frontend Services and TanStack Query Hooks are automatically generated.Optimization with Subsets
Query only the fields you need to reduce network costs and improve performance. Exact TypeScript types are automatically generated for each Subset.SSR
Supports server-side rendering based on Vite + React. Register SSR routes withregisterSSR and preload necessary data on the server with the preload callback.
- ✅ Backend changes detected immediately via compile errors
- ✅ Clean structure with Namespace-based organization
- ✅ TanStack Query auto-integration (caching, revalidation, optimistic updates)
- ✅ Accurate type inference per Subset
- ✅ SSR support for SEO optimization
Using Services
Leverage auto-generated Services
TanStack Query
Data fetching with React Hooks
SSR
Server-side rendering
Testing
Sonamu includes powerful built-in tools for testing.Fixture System
Easily load pre-seeded test data from Fixture DB withcreateFixtureLoader.
Naite: Test Data Tracking & Visualization
Track and visualize all data changes during test execution. Debugging becomes much easier.Automatic Transaction Rollback
Each test runs in an isolated Transaction and automatically rolls back. Test isolation is guaranteed and no data cleanup is needed.- ✅ Reuse test data with Fixtures
- ✅ Visualize data changes with Naite
- ✅ Isolated tests with automatic Transaction rollback
AI Ready
Sonamu natively supports features for the AI era.Vector Search (pgvector)
Define AI embedding search as an Entity field and you’re done. Native support for pgvector.AI SDK Integration
Seamlessly integrates with Vercel AI SDK. Streaming responses are simple.SSE (Server-Sent Events)
Easily use SSE for real-time streaming with the@stream decorator.
AI Agent Integration
Create Entities in natural language using AI chat in Sonamu UI.- ✅ Native pgvector support (vector search)
- ✅ Seamless AI SDK integration (streaming)
- ✅ Real-time events with SSE
- ✅ Auto-generate Entities with AI Agent
Seamless DX
Sonamu is designed with developer experience as the top priority.HMR (Hot Module Replacement)
When you modify code, it’s instantly reflected without server restart. Whether you modify Entity, Model, or API, 2 seconds is all you need.Sonamu UI
Define Entities, manage Subsets, and run Migrations directly in the web UI. No need to edit JSON manually.Fast Feedback Loop
Entity change → Auto-generate types/schemas → Re-register APIs → Update frontend Services — everything is automatic. Key Features:- ✅ Develop without server restart using HMR
- ✅ Visual Entity management with Sonamu UI
- ✅ Syncer auto-synchronizes all code
- ✅ Detect type errors immediately on change
Production Ready
Sonamu includes powerful features built for production environments.BentoCache: Multi-Layer Caching
Easily use memory + Redis multi-layer caching.Cache-Control: Response Caching
Set HTTP response caching strategies simply with decorators.i18n: Type-Safe Internationalization
Entity title, prop.desc, and enumLabels are automatically extracted to the dictionary. Manage translations with the type-safeSD() function, and non-existent keys are caught at compile time.
Workflow: Complex Business Logic Management
Systematically manage complex multi-step business logic.Built-in Performance Optimization
N+1 problem auto-resolution and query optimization are provided by default.- ✅ Multi-layer caching with BentoCache (memory + Redis)
- ✅ HTTP response caching with Cache-Control
- ✅ Type-safe internationalization with i18n
- ✅ Complex business logic management with Workflow
- ✅ N+1 problem auto-resolution
Simple Example
The complete flow from defining an Entity to using it.Note: Auto-generated files
api/src/application/sonamu.generated.ts- All types, schemas, Enumsweb/src/services/sonamu.generated.ts- Frontend types (synchronized)web/src/services/services.generated.ts- All Service methodsweb/src/services/{entity}/{entity}.types.ts- Custom types (manually written)
1. Define Entity
2. Run Migration and Sync
Save Entity → Run Migration →pnpm sync:
✅ TypeScript types (sonamu.generated.ts)✅ Zod schemas (BaseSchema, BaseListParams)
✅ DB migrations
✅ Frontend Service (
services.generated.ts)✅ TanStack Query Hooks
3. Write Business Logic in Model
4. Use Immediately in React
Getting Started
3 minutes is all you need.Quick Start
Create your first API in 5 minutes
Installation
Detailed installation guide
Core Concepts
Understand how Sonamu works
Development Workflow
Learn the development workflow
Community
GitHub
Issue reports and contributions
With Sonamu, developing in TypeScript becomes enjoyable.