fern: Generate API SDKs and Documentation

Summary
Fern turns API definitions into SDKs and developer documentation through a command-line workflow. It suits teams that want to publish client libraries and API references from OpenAPI and other supported specifications.
At a glance
- Language
- TypeScript
- License
- Apache-2.0
- Stars
- 3.8k
- Forks
- 358
- Added to OSRepos
- March 10, 2026
- Last analyzed
- October 3, 2026
Topics
Click on any tag to explore related repositories
Use at your own risk
OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.
Overview
Fern is a platform and CLI for transforming API definitions into generated SDKs and developer documentation. It aims to reduce the work of maintaining language-specific client libraries and API references separately from the API specification.
It supports OpenAPI, AsyncAPI, Protobuf, and OpenRPC inputs. Fern may fit teams that want a specification-driven workflow for publishing SDKs and docs; generated artifacts and hosted documentation are part of a broader platform, so teams should review its generation and hosting workflows against their needs.
Key Features
- Generate type-safe SDKs for languages including TypeScript, Python, Java, Go, Ruby, PHP, C#, Swift, and Rust.
- Accept API definitions in OpenAPI, AsyncAPI, Protobuf, and OpenRPC formats.
- Provide a CLI for initializing projects, checking definitions, and running generation.
- Generate API documentation and references, with support for additional Markdown pages.
- Offer SDK, CLI, and OpenAPI spec generators.
- Support an interactive documentation UI with search, versioning, dark mode, and customization options.
- Include an AI Search feature described as answering developer questions using documentation, APIs, and SDKs.
Use Cases
- API platform teams can generate and distribute client SDKs for customers across multiple programming languages.
- Developer relations teams can keep API references connected to API definitions while adding hand-written guides in Markdown.
- Teams maintaining REST, WebSocket, gRPC, or JSON-RPC APIs can use Fern to generate SDKs or documentation from supported specifications.
- Organizations that already maintain OpenAPI definitions can evaluate Fern as a way to introduce SDK generation without replacing those definitions.
Project Facts
- Language: TypeScript
- License: Apache-2.0
- Stars: 3.8k
- Forks: 358
- Topics: api, docs-as-code, docs-generator, openapi, sdk-generator
- Archived: false
Getting Started
Install the CLI with Node 18 or later:
npm install -g fern-api
Initialize from an OpenAPI file with fern init --openapi ./path/to/openapi.yml, then run fern generate. See the README for configuration and additional commands.
Considerations
- The CLI requires Node 18 or later.
- Fern's generators cover multiple languages, but each generator is a separate component with its own versions and changelog. Check the relevant generator's support and release details before adopting it.
- The README distinguishes local Docker-based generation for legacy generator groups from remote generation for SDK Config targets, so workflows may differ depending on configuration.
- The repository describes hosted documentation and AI Search as platform capabilities; evaluate those offerings separately if you need them, rather than assuming they are provided solely by the CLI.
Source repository
Open the original repository on GitHub.
21 counted GitHub visits
Related repositories
Similar repositories that may be relevant next.

n8n-sandbox-service: Isolated Execution Environments for Your Applications
September 17, 2026
The n8n-sandbox-service provides isolated, on-demand execution environments, leveraging containers or Firecracker microVMs. It offers a REST API to run commands and handle files within these secure sandboxes, ideal for applications requiring ephemeral execution contexts.

otari: Route LLM Requests Through a Self-Hosted Gateway
September 4, 2026
Otari is a self-hosted, OpenAI-compatible gateway for routing requests to multiple LLM providers through one endpoint. It adds virtual keys, budget controls, routing policies, and usage tracking for teams managing provider access and spend.

OGAD: Run Private AI Models on Your Desktop
September 4, 2026
OGAD is a desktop AI studio and local runtime for running text, vision, image, and speech models on your own hardware. It also provides an OpenAI-compatible local API, with optional Pro features for on-device memory and activity capture.

tunnel-client: Connect Private MCP Servers to OpenAI
September 2, 2026
A Go client that connects private or localhost MCP servers to ChatGPT, Codex, the Responses API, and AgentKit through an OpenAI-hosted tunnel. It is designed for teams that need remote access without exposing MCP servers to the public internet.