generate-mcp-server
Use when generating an MCP server from an OpenAPI spec with Speakeasy.
Skill by speakeasy-api
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/speakeasy-api-generate-mcp-server
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: backend, agent-building
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/generate-mcp-server
What's inside
- Skill name
generate-mcp-server- Description
- Use when generating an MCP server from an OpenAPI spec with Speakeasy. Triggers on "generate MCP server", "MCP server", "Model Context Protocol", "AI assistant tools", "Claude tools", "speakeasy MCP", "mcp-typescript"
- License
- Apache-2.0
- Instructions
- 387 lines in SKILL.md · view on GitHub
Files (1)
- SKILL.md
SKILL.md (first lines)
# generate-mcp-server
Generate a Model Context Protocol (MCP) server from an OpenAPI spec using Speakeasy. The MCP server exposes API operations as tools that AI assistants like Claude can call directly.
## When to Use
- User wants to create an MCP server from their API
- User asks about Model Context Protocol integration
- User wants AI assistants to interact with their API
- User says: "generate MCP server", "create MCP server", "speakeasy MCP"
- User asks: "How do I make my API available to Claude?"
- User mentions: "mcp-typescript", "AI assistant tools", "Claude tools"
## Inputs
| Input | Required | Description |
|-------|----------|-------------|
| OpenAPI spec | Yes | Path or URL to the OpenAPI specification |
| Package name | Yes | npm package name for the MCP server (e.g., `my-api-mcp`) |
| Auth method | Yes | How the API authenticates (bearer token, API key, etc.) |
| Env var prefix | No | Prefix for environment variables (e.g., `MYAPI`) |
| Scope strategy | No | How to map operations to scopes (default: read/write by HTTP method) |
## Outputs
| Output | Description |
|--------|-------------|
| MCP server | TypeScript MCP server with one tool per API operation |
| CLI entry point | Command-line interface with stdio and SSE transports |
| Scope definitions | Scope-based access control for filtering tools |
| Docker support | Dockerfile and compose config for containerized deployment |
| Workflow config | `.speakeasy/workflow.yaml` configured for MCP generation |
## Prerequisites
1. Speakeasy CLI installed and authenticated:
```bash
speakeasy auth login
# Or for CI/AI agents:
export SPEAKEASY_API_KEY="<your-api-key>"
```
2. Node.js 20+ installed (for the generated MCP server).
3. A valid OpenAPI spec (3.0 or 3.1). Validate first:
```bash
speakeasy lint openapi --non-interactive -s ./openapi.yaml
```
Run `speakeasy auth login` to authenticate interactively, or set the `SPEAKEASY_API_KEY` environment variable.
## Command
The generation uses `speakeasy run` after configuring the workflow, overlays, and gen.yaml. There is no single command -- follow the step-by-step workflow below.
```bash
# After all config files are in place:
speakeasy run
```
## Step-by-Step Workflow
### Step 1: Create the Scopes Overlay
Create `mcp-scopes-overlay.yaml` in the project root. This controls which API operations become MCP tools and what scopes they require:
```yaml
# mcp-scopes-overlay.yaml
openapi: 3.1.0
overlay: 1.0.0
info:
title: Add MCP scopes
version: 0.0.0
actions:
# Enable read operations
- target: $.paths.*["get","head"]
update:
x-speakeasy-mcp:
scopes: [read]
disabled: false
# Enable write operations
- target: $.paths.*["post","put","delete","patch"]
update:
x-speakeasy-mcp:
scopes: [write]
disabled: false
# Disable specific sensitive endpoints (customize as needed)
# - target: $.paths["/admin/danger-zone"]["delete"]
# update:
# x-speakeasy-mcp:
# disabled: true
```
### Step 2: Create the Workflow Configuration
Create `.speakeasy/workflow.yaml`:
```yaml
# .speakeasy/workflow.yaml
workflowVersion: 1.0.0
speakeasyVersion: latest
sources:
My-API:
inputs:
- location: ./openapi.yaml
overlays:
- location: mcp-scopes-overlay.yaml
output: openapi.yaml
targets:
mcp-server:
target: mcp-typescript
source: My-API
```
Replace `./openapi.yaml` with the actual spec path or URL.
> **Important:** Use the standalone `mcp-typescript` target, not `typescript` with `enableMCPServer: true`. The embedded approach (`enableMCPServer` flag) is deprecated.From speakeasy-api/sdk-generation-skills, Apache-2.0.
More from speakeasy-api/sdk-generation-skills
- 0.487score
writing-openapi-specs
speakeasy-api
Reference guide for OpenAPI specification best practices, naming conventions, and expressing complex REST API patterns like polymorphism, enums, file uploads…
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
configure-sdk-options
speakeasy-api
Use when CONFIGURING an existing SDK - NOT for initial generation.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
customize-sdk-hooks
speakeasy-api
Use when implementing SDK code hooks for custom logic (not spec configuration or runtime overrides).
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
diagnose-generation-failure
speakeasy-api
Use when SDK generation failed or seeing errors.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
extract-openapi-from-code
speakeasy-api
Use when extracting or generating an OpenAPI spec from existing API code.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
generate-terraform-provider
speakeasy-api
Use when generating a Terraform provider from an OpenAPI spec with Speakeasy.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
improve-sdk-naming
speakeasy-api
Use when you want AI-powered suggestions for SDK naming improvements via the `speakeasy suggest` command (not manual overlay creation).
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
manage-openapi-overlays
speakeasy-api
Use when creating, applying, or validating overlay files including x-speakeasy extensions.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
orchestrate-multi-repo-sdks
speakeasy-api
Use when each language SDK lives in a separate repository.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
orchestrate-multi-target-sdks
speakeasy-api
Use when generating SDKs for multiple languages from a single OpenAPI spec, or multiple SDK variants from different sources.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
setup-sdk-testing
speakeasy-api
Use when setting up SDK testing, configuring contract tests, writing Arazzo test workflows, or running integration tests.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
start-new-sdk-project
speakeasy-api
Use when generating a new SDK from an OpenAPI spec.
SkillDFreshness: D★ 18Claude Code +9
Signals
- Stars
- 18
- Forks
- 6
- Open issues
- 0
- Last commit (this folder)
- Feb 7, 2026 (8 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- Apache-2.0
- Website
- www.speakeasy.com/docs
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from speakeasy-api
- 0.487score
configure-sdk-options
speakeasy-api
Use when CONFIGURING an existing SDK - NOT for initial generation.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
customize-sdk-hooks
speakeasy-api
Use when implementing SDK code hooks for custom logic (not spec configuration or runtime overrides).
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
diagnose-generation-failure
speakeasy-api
Use when SDK generation failed or seeing errors.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
extract-openapi-from-code
speakeasy-api
Use when extracting or generating an OpenAPI spec from existing API code.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
generate-terraform-provider
speakeasy-api
Use when generating a Terraform provider from an OpenAPI spec with Speakeasy.
SkillDFreshness: D★ 18Claude Code +9 - 0.487score
setup-sdk-testing
speakeasy-api
Use when setting up SDK testing, configuring contract tests, writing Arazzo test workflows, or running integration tests.
SkillDFreshness: D★ 18Claude Code +9
Cite this page
generate-mcp-server skill. Agent Mart. https://agentmart.dev/skills/speakeasy-api-generate-mcp-server (last updated 2026-10-24)