Kalendis MCP Server: TypeScript Clients & API Routes
Generate TypeScript clients and API routes with an MCP server for Kalendis scheduling, streamlining availability and booking across popular frameworks.
npx -y @kalendis-dev/kalendis-mcpOverview
The Kalendis MCP Server is a Model Context Protocol (MCP) tool that exposes Kalendis scheduling API functionality as reusable tools for AI agents and generates TypeScript clients and server route scaffolding. It streamlines integrating availability, recurring availability, exceptions, bookings, and account operations into frontend and backend projects by producing type-safe clients and ready-to-drop API route handlers for popular frameworks.
For developers building scheduling features — from simple availability lookups to complex booking flows — this tool reduces boilerplate, enforces consistent authentication, and provides strong TypeScript typings so you can call Kalendis endpoints with confidence.
Features
- MCP server that exposes Kalendis API tools for AI assistants (Claude, Cursor, etc.)
- TypeScript client generator for backend and frontend usage
- API route generator scaffolding for Next.js (App Router), Express, Fastify, and NestJS
- Full TypeScript typings for all Kalendis endpoints
- Environment-driven configuration for sandbox and production endpoints
- Secure API key management via environment variables
- Tooling to list available endpoints and generate custom code per project
Installation / Configuration
Install the package via npm:
Add the MCP server to your MCP configuration (example):
Environment config — supported hosts:
# development
KALENDIS_BASE_URL=https://sandbox.api.kalendis.dev
# production
# KALENDIS_BASE_URL=https://api.kalendis.dev
# API key used by generated clients
KALENDIS_API_KEY=sk_XXXXXXXXXXXX
Authentication: all requests to Kalendis require the x-api-key header. Generated clients accept an apiKey option and will set this header automatically.
Available Tools
The MCP server exposes a set of tools (actions) you can call programmatically or via an AI agent:
- generate-backend-client — produces a TypeScript client that calls Kalendis API directly
- generate-frontend-client — produces a client that calls your backend endpoints
- generate-api-routes — scaffolds API routes for Next.js, Express, Fastify, or NestJS
- list-endpoints — lists supported Kalendis API endpoints and schemas
Quick examples
Backend client usage (generated):
;
;
;
;
Frontend client (calls your backend):
;
// Calls your backend proxy endpoints like /api/kalendis/users
;
Next.js (App Router) route example:
// app/api/kalendis/users/route.ts
;
;
;
Express route example:
// routes/kalendis.ts
;
;
;
;
'/api/users', ;
;
Fastify route example:
// routes/kalendis.ts
Use Cases
- Build a scheduling UI that queries calculated availability and creates bookings without writing repetitive network code.
- Generate a secure backend client for server-side operations (webhooks, batch syncs, admin tooling).
- Scaffold API routes for serverless deployments (Next.js App Router) to keep your frontend free of direct Kalendis keys.
- Let an AI agent use Kalendis tools (via MCP) to automate availability checks, suggest meeting slots, or provision bookings programmatically.
- Integrate with NestJS or Fastify backends quickly with generated controllers and services that wrap Kalendis calls.
API Coverage & Resources
The generator covers all Kalendis endpoints for users, availability, recurring availability, availability exceptions, bookings, and account management. Use the list-endpoints tool to fetch the full endpoint list and JSON schemas before generating clients or routes.
Repository: https://github.com/kalendis-dev/kalendis-mcp
If you need further examples for a specific framework or to customize generated types and route handlers, consult the repository README and the generated code as a starting point.