Mizzle is a light and type-safe ORM for DynamoDB built with TypeScript. It is designed to provide a "Drizzle-like" developer experience, simplifying your interactions with DynamoDB through a fluid, intuitive API while handling the complexities of Single-Table Design.
Mizzle aims to minimize boilerplate and maximize developer velocity. It abstracts away the raw DynamoDB JSON structures and key management, allowing you to define your data models using familiar TypeScript schemas and interact with them using a SQL-like query builder.
Mizzle separates the concept of the Physical Table (the actual DynamoDB table) from the Entity (the logical data model). This approach is tailored for DynamoDB's Single-Table Design patterns.
- Physical Table: Defines the partition key (PK), sort key (SK), and global secondary indexes (GSIs) of your DynamoDB table.
- Entity: Defines the schema of your data (users, posts, orders) and maps it to the physical table using Key Strategies.
Key Strategies (like prefixKey) automatically handle the construction of PK/SK values based on your data, so you don't have to manually string-concatenate "USER#123" every time.
This is a monorepo, if you want to you can read each individual package's README for more details:
Or better yet, visit the documentation
Contributions are welcome! Please open an problem or submit a pr ;).
MIT