HAPI MCP Server

Official registry Developer tools

HAPI MCP server: Dynamically exposes OpenAPI REST APIs as MCP tools for AI assistants

Install

Add this to your client's MCP configuration (Claude Desktop: claude_desktop_config.json; Cursor: .cursor/mcp.json; VS Code and others use the same "mcpServers" shape).

Remote (streamable-http)
Claude Code
claude mcp add --transport http hapi-mcp-server 'https://{HAPI_FQDN}:{HAPI_PORT}/mcp'
JSON configuration (Claude Desktop, Cursor, VS Code)
{
    "mcpServers": {
        "hapi-mcp-server": {
            "type": "http",
            "url": "https://{HAPI_FQDN}:{HAPI_PORT}/mcp"
        }
    }
}
OCI package docker.io/hapimcp/hapi-cli:0.6.0
Claude Code
claude mcp add hapi-mcp-server -e 'HAPI_FQDN=localhost' -e 'HAPI_HOME=/app/.hapi' -e 'PROJECT_NAME=<PROJECT_NAME>' -e 'HAPI_OPENAPI=<HAPI_OPENAPI>' -e 'HAPI_URL=<HAPI_URL>' -e 'HAPI_PORT=3030' -e 'HAPI_HEADLESS=true' -e 'HAPI_MCP=true' -e 'HAPI_DEV=<HAPI_DEV>' -e 'HAPI_CORS=<HAPI_CORS>' -e 'HAPI_CONFIG_FILES=<HAPI_CONFIG_FILES>' -e 'NODE_ENV=production' -- docker run -i --rm docker.io/hapimcp/hapi-cli:0.6.0 '<serve>' '<petstore>' --port '<port>' --headless --mcp --dev --url '<url>' --openapi '<openapi>' --cors '<origins>' --filename '<files>' --cert '<path>' --key '<path>'
JSON configuration (Claude Desktop, Cursor, VS Code)
{
    "mcpServers": {
        "hapi-mcp-server": {
            "command": "docker",
            "args": [
                "run",
                "-i",
                "--rm",
                "docker.io/hapimcp/hapi-cli:0.6.0",
                "<serve>",
                "<petstore>",
                "--port",
                "<port>",
                "--headless",
                "--mcp",
                "--dev",
                "--url",
                "<url>",
                "--openapi",
                "<openapi>",
                "--cors",
                "<origins>",
                "--filename",
                "<files>",
                "--cert",
                "<path>",
                "--key",
                "<path>"
            ],
            "env": {
                "HAPI_FQDN": "localhost",
                "HAPI_HOME": "/app/.hapi",
                "PROJECT_NAME": "<PROJECT_NAME>",
                "HAPI_OPENAPI": "<HAPI_OPENAPI>",
                "HAPI_URL": "<HAPI_URL>",
                "HAPI_PORT": "3030",
                "HAPI_HEADLESS": "true",
                "HAPI_MCP": "true",
                "HAPI_DEV": "<HAPI_DEV>",
                "HAPI_CORS": "<HAPI_CORS>",
                "HAPI_CONFIG_FILES": "<HAPI_CONFIG_FILES>",
                "NODE_ENV": "production"
            }
        }
    }
}

Environment variables

  • HAPI_FQDN Fully Qualified Domain Name for the HAPI server (used in MCP tool URLs)
  • HAPI_HOME Directory path for HAPI configuration and specs. Should be mounted as a volume in Docker
  • PROJECT_NAME The name of the project/API (alternative to positional argument)
  • HAPI_OPENAPI OpenAPI spec URL or path (alternative to --openapi flag)
  • HAPI_URL Backend API base URL (alternative to --url flag)
  • HAPI_PORT Server port (alternative to --port flag) - this is the internal container port
  • HAPI_HEADLESS Enable headless mode (alternative to --headless flag)
  • HAPI_MCP Enable MCP mode (alternative to --mcp flag)
  • HAPI_DEV Enable development mode (alternative to --dev flag)
  • HAPI_CORS Comma-separated allowed CORS origins (alternative to --cors flag)
  • HAPI_CONFIG_FILES Comma-separated configuration files (alternative to --filename flag)
  • NODE_ENV Node environment (development, production). 'development' enables verbose logging and debugging features.

Frequently asked questions

What is HAPI MCP Server?

HAPI MCP server: Dynamically exposes OpenAPI REST APIs as MCP tools for AI assistants

How do I install HAPI MCP Server?

It runs as a remote server. In Claude Code: claude mcp add --transport http hapi-mcp-server 'https://{HAPI_FQDN}:{HAPI_PORT}/mcp'. For other clients, paste the JSON configuration from this page into their MCP settings.

Does HAPI MCP Server need an API key?

Its registry entry lists no required key or secret. Some features may still need an account with the service it connects to.

Is HAPI MCP Server open source?

Its code is public on GitHub, but the repository does not declare a standard license.

Who maintains HAPI MCP Server?

It is published by larebelion. AI.tn lists it but does not maintain or endorse it.

From the official MCP Registry. Listing is not an endorsement: review a server's code and permissions before giving it access to your data.