APIBridge MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@APIBridge MCP Server run a CRUD test suite on the products API and summarize any failures"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
APIBridge MCP Server
An open-source Model Context Protocol server for dynamic API testing and validation powered by OpenAPI specifications.
APIBridge automatically generates MCP tools from your OpenAPI (Swagger) specification, allowing you to interact with, test, and validate your APIs using natural language. Simply provide an OpenAPI YAML or JSON file, and APIBridge creates a complete testing suite with zero configuration.
šļø Foundation-First Design Philosophy: APIBridge is architected as a foundational platform that provides base workflows and core tools which you can extend, customize, and enhance. Rather than being a rigid solution, it serves as extensible building blocks for your specific API integration needs.
Quick Start
Install dependencies:
npm install
Start the demo API server:
cd demo-api ./demo.sh
Run MCP of the demo API:
node index.js demo-api/sample-api.yml
Add the MCP server to VS Code (Example)
You can quickly add the MCP server to VS Code:
Press Cmd+Cmd+Shift+P (or Ctrl+Shift+P on Windows/Linux) to open the Command Palette.
Type
MCP: Open User Configurationand select it.Add your MCP configuration as shown below.
Save the file.
Click on Start
The foundation workflows will be automatically generated and ready for extension!
š For the full MCP config JSON example, see the VS Code Configuration section below.

Related MCP server: Swagger to MCP
MCP in Action
Once your APIBridge MCP Server is running, you can connect to it from any compatible client (like VS Code or Claude Desktop) to interact with your API using natural language. The video below demonstrates how APIBridge can run a comprehensive suite of tests against a demo API, from checking the API health and metrics to validating CRUD operations for different endpoints. It intelligently identifies issues, such as a failing create_product operation, and then automatically generates a detailed report in Markdown format, summarizing the status of the entire system. This entire workflow is executed through a series of simple, conversational prompts, showcasing the power of using a 100% local, open-source MCP server to streamline API testing and validation.

Getting Started
1. Prerequisites
2. Installation
Clone or download the project files, then install the required dependencies:
npm install3. Usage
The server can be used in several ways:
With OpenAPI Specification (Recommended):
# Using OpenAPI YAML file
node index.js demo-api/sample-api.yml
# With custom base URL
node index.js demo-api/sample-api.yml --base-url http://localhost:8080/api
# With API key authentication
node index.js demo-api/sample-api.yml --api-key your-api-key-here
# Enable verbose logging
node index.js demo-api/sample-api.yml --verboseWith Configuration File:
# Use custom configuration file
node index.js --config apibridge.config.json
# Combine with OpenAPI spec
node index.js api.yml --config apibridge.config.jsonCommand Line Options:
--openapi, -o: OpenAPI specification file (YAML or JSON)--config, -c: Configuration file (default: apibridge.config.json)--base-url, -b: Base URL for the API--api-key, -k: API key for authentication--verbose, -v: Enable verbose logging--help, -h: Show help message
4. Quick Demo Setup
For a complete demo with a working API backend:
# Run the demo script (starts demo API server + shows instructions)
cd demo-api
./demo.shOr manually:
# Terminal 1: Start the demo API server
cd demo-api
npm install
npm start
# Terminal 2: Start the MCP server
node index.js demo-api/sample-api.yml5. Running the Server
To start the MCP server, run:
node index.js demo-api/sample-api.ymlThe server will start and listen for requests from an MCP client on stdio.
Features
OpenAPI-Powered: Automatically generates tools from OpenAPI/Swagger specifications (YAML or JSON).
Zero Configuration: Just provide your OpenAPI spec and start testing immediately.
Foundation Workflows: Provides base CRUD workflows that can be extended and enhanced for specific use cases.
Dynamic Tool Generation: Automatically creates tools like
create_user,list_users, etc., from your API endpoint configuration.Extensible Architecture: Built-to-be-extended design allows customization of workflows, authentication, and tool generation.
Smart Relationship Detection: Automatically detects and handles foreign key relationships between API resources.
Real-time Validation: Includes built-in tools to ping API health (
ping_api) and run comprehensive validation tests (validate_api).Context-Aware Testing: Save responses and use them in subsequent requests for complex testing scenarios.
Built-in Metrics: Get server uptime, request counts, and average response times with the
get_metricstool.
Project Structure
/your-project
āāā index.js # The main server entry point
āāā package.json # Project definition and dependencies
āāā README.md # This file
āāā LICENSE # The MIT License with Commercial Enterprise Addendum
āāā /src/ # Source code directory
ā āāā /api/ # Main server implementation
ā āāā /auth/ # Authentication utilities
ā āāā /config/ # Configuration management
ā āāā /docs/ # Documentation utilities
ā āāā /services/ # Core services (OpenAPI parser, etc.)
ā āāā /tools/ # Tool management and generation
ā āāā /utils/ # Utility functions
āāā /test/ # Test files
ā āāā workflow-generator.test.js # Main test file
āāā /demo-api/ # Demo API server with sample OpenAPI spec
ā āāā server.js # Express server implementing sample-api.yml
ā āāā package.json # Demo API dependencies
ā āāā sample-api.yml # Example OpenAPI specification
ā āāā demo.sh # Demo script for this API server
ā āāā README.md # Demo API documentation
āāā /logs/ # (Auto-generated) For log filesTesting and Validation
APIBridge includes a comprehensive test suite with sample APIs from different domains to validate workflow generation.
Testing Your OpenAPI Specification
Before starting the MCP server, you can validate your OpenAPI specification to ensure it is correctly formatted and will generate the expected workflows. We have included a test script that you can run from the command line.
To test your OpenAPI file, run the following command:
npm test -- /path/to/your/openapi.ymlReplace /path/to/your/openapi.yml with the actual path to your OpenAPI specification file. The script will parse the file, generate the endpoints and workflows, and report any errors it finds.
If the script runs successfully, you will see a confirmation message indicating that your OpenAPI specification is valid and ready to be used with the APIBridge MCP Server.
Running the Full Test Suite
# Run the full test suite
node test/workflow-generator.test.js
# Test specific API domains
node test/workflow-generator.test.js test/sample-ecommerce-api.yml
node test/workflow-generator.test.js test/sample-library-api.yml
node test/workflow-generator.test.js test/sample-healthcare-api.yml
# Test your own API
node test/workflow-generator.test.js path/to/your-api.ymlAvailable Test APIs:
E-commerce: Complex inventory, orders, payments, and analytics
Library Management: Books, authors, borrowers, and loan workflows
Healthcare: Patient records, appointments, and medical data
Demo API: Users, posts, and products with foreign key relationships
For detailed testing documentation, see test/README.md.
Configuration
Configuration File: apibridge.config.json
The apibridge.config.json file is used to configure the APIBridge MCP Server. It allows you to specify settings such as:
apiBaseUrl: The base URL of the API to connect toname/version: Server name and versiontimeout,retryAttempts: Request timeout and retry settingsenableLogging,enableMetrics: Enable/disable logging and metricsendpoints,workflows: Custom endpoints and workflows (optional)
This file makes it easy to change server behavior, API targets, and workflow definitions without modifying code. It is especially useful for demos, CI/CD, or switching between different API environments.
Example:
{
"name": "APIBridge Demo MCP Server",
"version": "1.0.0",
"apiBaseUrl": "http://localhost:3000/api",
"timeout": 10000,
"retryAttempts": 3,
"enableLogging": true,
"enableMetrics": true,
"endpoints": {},
"workflows": {}
}You can specify a custom config file with:
node index.js --config apibridge.config.jsonConfiguring MCP Clients
To use this server with MCP clients like Claude Desktop or VS Code, you need to configure the client to recognize and connect to your APIBridge server.
Claude Desktop Configuration
Locate your Claude Desktop configuration file:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.jsonLinux:
~/.config/claude/claude_desktop_config.json
Add the APIBridge server to your configuration:
{ "mcpServers": { "apibridge": { "command": "node", "args": ["/path/to/your/api-bridge-mcp-server/index.js", "demo-api/sample-api.yml"], "env": { "NODE_ENV": "production" } } } }For a more advanced configuration with a custom API:
{ "mcpServers": { "my-api-bridge": { "command": "node", "args": [ "/path/to/your/api-bridge-mcp-server/index.js", "/path/to/your/openapi-spec.yml", "--base-url", "https://api.yourcompany.com", "--api-key", "your-api-key-here" ], "env": { "NODE_ENV": "production" } } } }Restart Claude Desktop for the changes to take effect.
VS Code Configuration
š See Quick Start Step 4 above for a fast walkthrough of adding the MCP server to VS Code.
You can add the MCP server to VS Code in just a few steps:
Press Cmd+Cmd+Shift+P (or Ctrl+Shift+P on Windows/Linux) to open the Command Palette.
Type
MCP: Open User Configurationand select it.Add your MCP configuration as shown below and save the file:
{ "inputs": [ { "type": "promptString", "id": "api-base-url", "description": "API Base URL (optional)", "default": "http://localhost:3000/api" }, { "type": "promptString", "id": "api-key", "description": "API Key (optional)", "password": true } ], "servers": { "apibridge": { "type": "stdio", "command": "node", "args": ["/path/to/your/api-bridge-mcp-server/index.js", "demo-api/sample-api.yml"], "cwd": "/path/to/your/api-bridge-mcp-server", "env": { "API_BASE_URL": "${input:api-base-url}", "API_KEY": "${input:api-key}" } } } }You will see your tools in the available tools panel:

Key Features:
Secure input prompts for credentials
Environment variables for API settings
Flexible and type-safe configuration
Other MCP Clients
For other MCP-compatible clients, the general pattern is:
Command:
nodeArguments:
["/path/to/api-bridge-mcp-server/index.js", "your-openapi-spec.yml"]Working Directory:
/path/to/api-bridge-mcp-serverProtocol: stdio
Verification
Once configured, you should be able to:
See the APIBridge tools available in your MCP client.
Use tools like
ping_api,validate_api, and dynamically generated endpoint tools.Test your APIs through natural language interactions.
Example tools you'll see:
ping_api- Check API healthvalidate_api- Run comprehensive API testslist_users- Get all users (if your API has this endpoint)create_user- Create a new userget_metrics- View server statistics
Extensibility Guide
APIBridge is designed as a foundational platform that provides base workflows and core functionality that you can build upon. The architecture embraces extensibility at every level, allowing you to customize and enhance the system to meet your specific requirements.
Foundation Concept
APIBridge provides these base building blocks:
Core CRUD Workflows: Basic Create, Read, Update, Delete operations that can be enhanced.
Base Tool Generation: Foundational tool creation from OpenAPI specs that can be customized.
Authentication Framework: Basic auth support that can be extended for complex scenarios.
Relationship Detection: Smart foreign key handling that can be enhanced for complex data relationships.
Testing Infrastructure: Basic validation tools that can be extended for comprehensive testing suites.
Extensibility Philosophy:
Start with the foundation ā Use base workflows as-is for rapid prototyping.
Extend selectively ā Add only the customizations you need.
Build incrementally ā Layer additional functionality on top of base workflows.
Share enhancements ā Contribute back to the community.
1. Adding New Core Tools
Core tools are custom tools that are not generated from an OpenAPI specification. You can add your own tools by following these steps:
Open
src/tools/tool-manager.js.In the
setupCoreToolsmethod, add a new entry to thethis.coreToolsmap.this.coreTools.set('my_custom_tool', { name: 'my_custom_tool', description: 'A new tool that does something awesome.', inputSchema: { type: 'object', properties: { my_arg: { type: 'string', description: 'An argument for my tool' } } }, handler: this.handleMyCustomTool.bind(this) });Add the handler method to the
ToolManagerclass.async handleMyCustomTool(args, testContext, metrics) { // Your tool's logic here const myArg = args.my_arg; // ... return { content: [{ type: 'text', text: `My custom tool ran with arg: ${myArg}` }] }; }
2. Extending Base Workflows
The generated workflows serve as foundational building blocks that you can extend and enhance:
Base Workflow Examples:
users_crud_workflow- Basic user management operationsposts_crud_workflow- Basic post content operationsproducts_crud_workflow- Basic product catalog operations
Extension Strategies:
Add Pre/Post Processing Steps:
// In src/services/openapi-parser.js generateWorkflows() { const baseWorkflows = this.generateBaseWorkflows(); // Extend workflows with custom steps baseWorkflows.users_crud_workflow.steps.unshift({ action: 'validate_user_permissions', // ... custom validation logic }); return baseWorkflows; }Create Composite Workflows:
// Combine base workflows for complex operations const complexWorkflow = { name: 'user_onboarding_workflow', steps: [ ...baseWorkflows.users_crud_workflow.steps, { action: 'send_welcome_email' }, { action: 'setup_default_preferences' }, { action: 'assign_default_role' } ] };Domain-Specific Extensions:
// Extend for e-commerce scenarios const ecommerceWorkflows = { ...baseWorkflows, order_fulfillment_workflow: { steps: [ { action: 'validate_inventory' }, ...baseWorkflows.products_crud_workflow.steps, { action: 'process_payment' }, { action: 'schedule_shipping' } ] } };
Workflow Extension Guidelines:
Build on base workflows rather than replacing them entirely.
Maintain backward compatibility when possible.
Document your extensions for team collaboration.
Test extended workflows thoroughly.
Consider contributing useful extensions back to the project.
3. Customizing Authentication
The server's authentication logic is centralized in src/utils/http-client.js. You can easily modify this file to support different authentication schemes.
Bearer Token: Supported by default via the
--api-keyflag orAPI_KEYenvironment variable.Custom Headers & OAuth 2.0: We have provided examples in
src/auth/auth-examples.js. You can import and use these functions insrc/utils/http-client.jsto extend the authentication capabilities.
Example: Implementing Custom Header Auth
In src/utils/http-client.js:
import { setupCustomHeaderAuth } from '../auth/auth-examples.js';
// ... inside the HttpClient class, in the initialize() method
// Add this line to use a custom header
setupCustomHeaderAuth(this.client, config.apiKey, 'X-My-Custom-Header');4. Customizing OpenAPI Tool Generation
You can change how tools are generated from an OpenAPI specification by modifying the following files:
src/services/openapi-parser.js: Modify this file to change how the OpenAPI specification is parsed and interpreted. For example, you could change how endpoint names are extracted or how test data is generated.src/tools/tool-manager.js: Modify thegenerateToolName,generateToolDescription, orgenerateToolSchemamethods to change how the parsed OpenAPI data is converted into MCP tools.
Building on the Foundation
APIBridge is intentionally designed as a foundation rather than a complete solution. This approach provides several benefits:
Foundation Benefits
Rapid Prototyping: Use base workflows to quickly test API concepts.
Incremental Enhancement: Add complexity only where needed.
Consistent Base: Standard CRUD operations work the same across different APIs.
Extensibility: Build sophisticated workflows on proven foundations.
Community Growth: Share and reuse workflow extensions.
Common Extension Patterns
Pattern 1: Industry-Specific Workflows
# Start with base
node index.js your-api.yml
# Extend for healthcare, e-commerce, finance, etc.
# Add domain-specific validation, compliance, workflowsPattern 2: Integration Workflows
# Combine multiple APIs using base workflows
# Add orchestration between different services
# Create composite operations across systemsPattern 3: Advanced Testing Workflows
# Build on base validation tools
# Add performance testing, load testing
# Create comprehensive test suitesContributing Back
We encourage users to:
Share useful workflow extensions with the community.
Contribute authentication adapters for different services.
Submit OpenAPI parsing improvements for edge cases.
Document extension patterns for others to learn from.
The goal is to build a rich ecosystem of extensions while maintaining a solid, reliable foundation that works consistently across different use cases.
Getting Started with Extensions
Start Simple: Use base workflows as-is to understand the foundation.
Identify Gaps: Note where your specific use case needs enhancement.
Extend Incrementally: Add one enhancement at a time.
Test Thoroughly: Ensure extensions don't break base functionality.
Document Well: Help others understand your extensions.
Share Value: Consider contributing useful patterns back.
Remember: The foundation is designed to handle the common cases well, while giving you the flexibility to handle the unique aspects of your specific requirements.
Troubleshooting
Server not appearing: Check that the file paths in your configuration are absolute and correct.
Permission errors: Ensure the MCP client has permission to execute Node.js and access your files.
API connection issues: Verify your API base URL and authentication credentials are correct.
Logs: Check the
logsdirectory for detailed error information.Workflow generation issues: Use the test suite to validate your API follows expected patterns.
Available Tools
18 toolscreate_postC
Create a new post
Inputs: data, title, content, authorId, +3 more.
create_productC
Create a new product
Inputs: sku, data, name, tags, +5 more.
create_userD
Create a new user
Inputs: data, email, lastName, password, +5 more.
delete_postC
Delete a post
Inputs: id, fromContext, queryParams, saveToContext.
delete_productC
Delete a product
Inputs: id, fromContext, queryParams, saveToContext.
delete_userC
Delete a user
Inputs: id, fromContext, queryParams, saveToContext.
get_metricsC
Get server metrics and performance statistics
Inputs: format.
get_postC
Get a post by ID
Inputs: id, fromContext, queryParams, saveToContext.
get_productC
Get a product by ID
Inputs: id, fromContext, queryParams, saveToContext.
get_userC
Get a user by ID
Inputs: id, fromContext, queryParams, saveToContext.
list_postsC
List all posts
Inputs: fromContext, queryParams, saveToContext.
list_productsC
List all products
Inputs: fromContext, queryParams, saveToContext.
list_usersC
List all users
Inputs: fromContext, queryParams, saveToContext.
ping_apiC
Check API health and connectivity
Inputs: detailed, endpoint.
run_workflowC
Execute a pre-defined test workflow
Inputs: workflow (required), saveResults, stopOnError.
update_productD
Update a product
Inputs: id, sku, data, name, +6 more.
update_userD
Update a user
Inputs: id, data, email, lastName, +6 more.
validate_apiD
Comprehensive API validation
Inputs: endpoints, generateReport, includeEdgeCases.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogā¦
TDQS
Scored across 18 tools
Most tools target distinct resource/action pairs, and the CRUD tools for users, posts, and products are easy to distinguish. The only mild ambiguity is between generic operations like ping_api, validate_api, and run_workflow, whose boundaries are plausible but could overlap in practice.
Every tool follows a consistent snake_case verb_noun pattern such as list_users, create_post, and delete_product. The generic tools use the same convention, so naming is highly predictable.
With 18 tools, the server is slightly above the ideal range, but the count is justified by covering CRUD-style operations across three resources plus a few generic API utilities. It does not feel bloated for the stated scope.
Users and products have full CRUD coverage, and posts have list/create/get/delete. The main gap is the missing update_post operation, which is a minor but noticeable lifecycle omission.
Maintenance
Related MCP Connectors
Build and run AI workflows, agents, data tables and 1000+ API integrations from any MCP client.
MCP server for AI access to Swagger by SmartBear.
Generate a typed SDK, CLI, and MCP server from any OpenAPI or GraphQL spec, and keep them current.
Build, validate, deploy ā HTTP APIs, cron jobs, webhooks and MCP tools ā from your AI client.
Related MCP Servers
- -licenseNot gradedqualityNot gradedmaintenanceDynamically generates MCP tools from Swagger/OpenAPI specifications by extracting swagger.json files at runtime. Enables natural language interaction with any REST API that has Swagger documentation.-
- AlicenseNot gradedqualityNot gradedmaintenanceAutomatically converts Swagger/OpenAPI specifications into dynamic MCP tools, enabling interaction with any REST API through natural language by loading specs from local files or URLs.-
- AlicenseAqualityDmaintenanceConverts any OpenAPI/REST API into MCP tools with dynamic server switching, variable substitution, and runtime configuration. Enables seamless interaction with multiple API environments through natural language without pre-configuration.125MIT
- AlicenseNot gradedqualityDmaintenanceAuto-generates MCP tools from your OpenAPI spec, allowing natural language interaction with any API via configurable headers and serverless deployment.MIT