Documentation

Introduction

Basilic - A TypeScript-first monorepo template for projects that need to publish SDKs, develop modular services with code reuse, and leverage AI-friendly documentation.

Perfect For

This boilerplate is specially targeted for projects that:

  • Need to publish SDKs - Generate multi-language SDKs from OpenAPI specs
  • Want modular architecture - Develop multiple services while reusing software
  • Value separation of concerns - Clear package boundaries (types → contracts → core → react)
  • Prefer TypeScript-first - Full type safety with automatic SDK generation for other languages

SDK Publishing Strategy

TypeScript: Generated type-safe clients via @hey-api/openapi-ts from OpenAPI specs. Other languages: Generate SDKs from the same OpenAPI specs using standard tools (openapi-generator, oapi-codegen, progenitor).

AI-Friendly Documentation

MDX files designed for both humans and AI workflows—use directly in prompts as reference. Includes Cursor rules and MCP server integration.

Who is this for?

🚀 Builders

Starting a TypeScript project that needs SDKs or modular services? Get:

  • Code-first API development (OpenAPI + hey-api)
  • Multi-language SDK generation from OpenAPI specs
  • Type-safe frontend-backend communication
  • Shared component library
  • Testing and linting configured
  • AI-friendly documentation

🔧 Contributors

Want to customize or extend? You'll find:

  • Clear architecture decisions (ADRs)
  • Documented patterns and conventions
  • Portable design (easy to swap services)

🎯 Evaluators

Deciding if this fits? Review:

  • Tech stack decisions and rationale
  • Migration paths and exit strategies
  • Real examples of monorepo patterns

What problems does this solve?

Problem 1: Type Safety Across Boundaries

Solution: OpenAPI specs with hey-api-generated clients ensure end-to-end type safety

Problem 2: Monorepo Package Management

Solution: Clear package boundaries (types → core → react) with OpenAPI as the contract source, enabling service reuse and separation of concerns

Problem 3: Vendor Lock-in

Solution: Portable-by-default architecture

Problem 4: Multi-Language SDK Needs

Solution: TypeScript-first with OpenAPI generation for other languages

Basilic has different parts:

🏗️

Architecture

Monorepo architecture with Turborepo, code-first API development, and portable-by-default design.

Development

Type-safe full-stack TypeScript, AI-assisted workflows with MCP servers, and modern tooling.

🚀

Deployment

Zero vendor lock-in architecture with migration paths from Vercel to GCP/AWS for production security.

📦

Packages

Shared packages for types, contracts, core API client, React hooks, and UI components.

Next Steps

On this page