@quickql/server
v1.0.5
Published
Enterprise-grade QuickQL server engine with advanced security and performance.
Readme
@quickql/server
A high-performance, schema-driven API engine with native relational mapping and enterprise security by Udinmo Inc.
Features
- 🚀 Ultra-Fast Relations: Native $O(N+M)$ relation resolver that eliminates the N+1 problem without DataLoaders.
- 🔐 Enterprise Security: Integrated RBAC (Role-Based Access Control), depth limiting, and complexity scoring.
- 🛠️ Zero-Boilerplate: Fully automated resolver mapping for Prisma and other standard ORMs.
- 📦 Multi-Strategy Auth: Built-in hooks for JWT, API Keys, and custom authentication.
- 🎨 Supreme Console: A premium browser IDE for exploring your schema, traversing data relations, and testing queries.
- ⚡ Atomic Transactions: Native support for batch mutation transactions at the engine level.
Getting Started
Installation
npm install @quickql/serverBasic Server Initialization
import { createServer } from '@quickql/server';
import { PrismaClient } from '@prisma/client';
const orm = new PrismaClient();
const server = createServer({
orm,
schema: {
users: {
model: 'User',
fields: ['id', 'email', 'name'],
relations: {
posts: { type: 'many', model: 'Post', foreignKey: 'userId' }
}
}
},
auth: {
secret: 'udinmo-secret-123'
},
rbac: {
roles: {
'admin': { can: ['*'], write: ['*'] },
'user': { can: ['users', 'posts'] }
}
}
});
// Use it with any HTTP framework (e.g. Express)
app.post('/quickql', async (req, res) => {
const result = await server.handleRequest(req.body, { ip: req.ip });
res.json(result);
});Advanced Customization
Directives
Extend the query language with custom @tags:
const server = createServer({
directives: [
{
name: 'upper',
handler: (results) => results.map(row => ({ ...row, name: row.name?.toUpperCase() }))
}
]
});Lifecycle Hooks (Plugins)
Intercept any part of the execution flow:
server.use({
name: 'audit-plugin',
onMutation: async (m, ctx) => {
console.log(`[AUDIT] Created ${m.collection} by ${ctx.user.id}`);
}
});License
(c) 2024-2026 Udinmo Inc. All rights reserved. MIT Licensed — see LICENSE for details. Author: Udinmo Inc.
