Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

generate-mcp-server

Skill by trycompai

Generates a TypeScript Model Context Protocol server from an OpenAPI spec using Speakeasy. Each API operation becomes a tool that AI assistants like Claude can call. Aimed at developers who want to give AI assistants access to their API.

  • Score 81
  • 2.2k stars
  • AGPL-3.0
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install generate-mcp-server

Built from the published package, never by AI.

git clone --depth 1 https://github.com/trycompai/comp /tmp/comp && mkdir -p ~/.claude/skills && cp -r /tmp/comp/.agents/skills/generate-mcp-server ~/.claude/skills/generate-mcp-server

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install generate-mcp-server in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

This skill walks an AI assistant through generating a Model Context Protocol (MCP) server from an OpenAPI spec with Speakeasy. The workflow uses a scopes overlay, a workflow.yaml file that sets the mcp-typescript target, and a gen.yaml file, then runs speakeasy run. The generated TypeScript server exposes one tool per API operation. Read operations get the read scope and write operations get the write scope by default.

The generated CLI supports stdio and SSE transports, scope and tool filtering, and bearer auth flags. The output also includes a Dockerfile and docker-compose config, and the source shows setup for Claude Desktop and Claude Code. The skill is for developers who want AI assistants like Claude to call their API.

Written from the project's SKILL.md and checked against it.

What it can do

  • MCP server generationCreates a TypeScript MCP server with one tool per API operation from an OpenAPI spec.
  • Scopes overlayMaps GET and HEAD operations to read and other methods to write, with optional disabling of sensitive endpoints.
  • stdio and SSE transportsThe generated CLI can run with stdio, the default, or with SSE on a chosen port.
  • Scope and tool filteringThe --scope and --tool flags limit which operations are exposed at runtime.
  • Claude configuration examplesShows how to add the generated server to Claude Desktop and Claude Code config files.
  • Docker deploymentIncludes a Dockerfile and docker-compose config for running the SSE server in a container.

What you need

  • Speakeasy CLI with an account or SPEAKEASY_API_KEY
  • Node.js 20 or later
  • OpenAPI spec in version 3.0 or 3.1
  • Docker, for the containerized deployment

Try asking

  • Generate an MCP server from my OpenAPI spec using Speakeasy
  • Create a scopes overlay that exposes only read operations
  • Show me how to add my generated MCP server to Claude Desktop

Good to know

  • The enableMCPServer flag in gen.yaml is deprecated; use the mcp-typescript target instead.
  • The generated MCP server is built for AI assistant use and is not meant as a general SDK.
  • Operations should be reviewed before exposure, and sensitive admin endpoints disabled.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: .agents/skills/generate-mcp-server/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Inside the skill

  • SKILL.md11 KB

Alternatives to generate-mcp-server

All alternatives →
openclaw-github-repo-commandersickn33
94

Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.

AAA Skill 50k
gradiogradio-app
94

Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.

AAA Skill 44k
hig-components-menussickn33
94

Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.

AAA Skill 50k
fastapi-templateswshobson
94

Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.

AAA Skill 43k
appfunctionsandroid
94

Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.

AAA Skill 11k
agent-qa-authoringsickn33
94

Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.

AAA Skill 50k

Compare with openclaw-github-repo-commander, gradio or hig-components-menus

generate-mcp-server: common questions

How do I authenticate with Speakeasy?

Run speakeasy auth login to authenticate interactively, or set the SPEAKEASY_API_KEY environment variable for CI or AI agents.

Which transports does the generated server support?

It supports stdio, which is the default, and SSE. The --transport flag selects between them, and --port sets the port for SSE.

Why do my MCP tools not appear in the assistant?

The source says this usually means the scopes overlay is not listed under overlays in workflow.yaml, or all operations are disabled.

How do I install generate-mcp-server?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is generate-mcp-server free?

The code is published under the AGPL-3.0 licence. The service it connects to may have its own pricing.

Is generate-mcp-server safe to use?

It scores 81 of 100. Grades: maintenance A, licence C, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to generate-mcp-server?

Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.

generate-mcp-server Install

Add to stack

Loading.