Full API documentation is auto-generated using TypeDoc. To generate and view docs locally:
npm run docs
open docs/index.htmlInline code is documented with JSDoc comments for clarity and IDE support.
We welcome contributions! Please see CONTRIBUTING.md for guidelines, and use the provided issue and pull request templates. All contributors must follow our Code of Conduct.
Enterprise-grade TypeScript SDK and open source backend SDK for SereniBase platform integration. A comprehensive developer toolkit and API integration SDK providing type-safe API communication, authentication management, and complete service layer for workspace, database, and data operations.
Base SDK is an open-source SDK for backend integration that helps developers easily connect APIs, manage services, and build scalable applications faster. It’s designed to reduce complexity and improve development efficiency. Whether you're looking to build apps with SDK integrations, connect multiple APIs, or create scalable backend workflows, Sereni Base SDK provides a reliable foundation for modern development.
- Type-Safe API Client: Full TypeScript support with comprehensive type definitions
- Authentication Management: Secure session handling with automatic token refresh
- Database Operations: Complete CRUD operations for workspaces, bases, tables, and records
- Error Handling: Comprehensive error management with detailed error types
- Event System: Real-time event handling for collaborative features
- Optimized for Production: Built specifically for SereniBase UI integration
- Modern TypeScript codebase
- Axios-based HTTP client
- Event-driven extensibility
npm install serenibase-sdkSee .env.example for environment variables and configuration options.
import { SereniBaseClient } from 'serenibase-sdk';
// Initialize client
const client = new SereniBaseClient({
baseURL: 'https://api.serenibase.com',
auth: {
type: 'bearer',
token: 'your-api-token'
}
});
// Authenticate user
const authResult = await client.auth.login({
email: 'user@example.com',
password: 'secure-password'
});
// Create a new workspace
const workspace = await client.workspace.create({
name: 'My Project',
description: 'Project workspace'
});
// Create a base within the workspace
const base = await client.baseService.create({
title: 'Customer Database',
description: 'Customer management system',
workspace_id: workspace.id
});
// Add a table to the base
const table = await client.tableService.create(base.id, {
name: 'customers',
fields: [
{ name: 'name', type: 'text', required: true },
{ name: 'email', type: 'email', required: true },
{ name: 'created_at', type: 'datetime', defaultValue: 'now()' }
]
});
console.log('Setup complete:', { workspace, base, table });# Clone the repository
git clone https://github.com/aptlogica/base-sdk.git
cd base-sdk
# Install dependencies
npm install
# Set up environment
cp .env.example .env
# Configure API endpoints and keys
# Run in development mode
npm run dev
# Build for production
npm run buildSERENIBASE_BASE_URL=http://localhost:8080
SERENIBASE_API_TOKEN=replace-me
SERENIBASE_TIMEOUT_MS=30000# Run unit tests
npm test
# Run tests with coverage
npm run test:coverage
# View coverage report
open coverage/lcov-report/index.html
# Run integration tests
npm run test:integrationSee SECURITY.md for reporting vulnerabilities.
MIT License. Copyright (c) 2026 Aptlogica Technologies.