Configuration

Command Line Interface

OpenAPI

  • --openapi-spec - path to OpenAPI spec file (YAML or JSON formats are both supported)
  • --openapi-server-index - server index (0 by default) to use from OpenAPI spec file
  • --openapi-server - usually not required, name of the server to overwrite OpenAPI spec value or specify if spec is not providing server name (must contain schema, e.g. https://hostname.com)
  • --openapi-auth-token - specifies auth-token in case the OpenAPI spec requires HTTP bearer security scheme. This CLI-parameter overwrites the env-var MCP_BUS_OPENAPI_AUTH_TOKEN (if set)
  • --openapi-auth-user - specifies HTTP basic auth username in case The OpenAPI spec requires HTTP basic security scheme. This CLI-parameter overwrites the env-var MCP_BUS_OPENAPI_AUTH_USER (if set)
  • --openapi-auth-pass - specifies HTTP basic auth password in case The OpenAPI spec requires HTTP basic security scheme. This CLI-parameter overwrites the env-var MCP_BUS_OPENAPI_AUTH_PASS (if set)
  • --openapi-auth-api-key - specifies auth api-key value in case the OpenAPI spec requires apiKey security scheme. This CLI-parameter overwrites the env-var MCP_BUS_OPENAPI_AUTH_API_KEY (if set)
  • --openapi-allow-destructive - boolean (true/false) parameter which allows generating MCP-tools for potentially destructive OpenAPI endpoints with PUT, DELETE, PATCH operations (false by default)
  • --openapi-endpoints-include - comma separated list of OpenAPI endpoints to include in MCP-tools (empty by default), parameter's value format "method:endpoint1,method:endpoint2" (e.g. --openapi-endpoints-include=GET:/customers/{customerId},POST:/customers)
  • --openapi-endpoints-exclude - comma separated list of OpenAPI endpoints to exclude from MCP-tools (empty by default), parameter's value format "method:endpoint1,method:endpoint2" (e.g. --openapi-endpoints-include=DELETE:/customers/{customerId},POST:/customers)

Context bloat control


HTTP server

The MCPBus HTTP server listener can be configured with these CLI parameters:

  • --hostname - configures the host name which appears in MCP-endpoint (localhost by default)
  • --addr - configures the network address to start HTTP listener on (localhost by default)
  • --port - specifies the TCP-port to start HTTP-listener on (8080 by default)

Authentication

  • --allowed-origins - comma separated list of allowed origins for MCP-server connections CORS policy (empty by default). It is not required in most use-cases. It will be needed if AI-agent application connects to MCPBus directly from your Web-browser UI.
  • --auth-token - MCP server authentication bearer token, no auth by default. This CLI-parameter overwrites the env-var MCP_BUS_AUTH_TOKEN (if set). If you configure auth-token, don't forget to configure MCP-clients with it, e.g. Claude Desktop config file would look like:
    {
      "mcpServers": {
        "My MCP server": {
          "command": "/usr/local/bin/npx",
          "args": [
            "mcp-remote",
            "http://localhost:8080/mcp",
            "--transport",
            "http-first",
            "--header",
            "Authorization: Bearer AUTH_TOKEN_HERE",
            "--debug"
          ]
        }
      }
    }
    

Logging

  • --loglevel - log level, one of: trace, debug, info, warn, error, fatal, panic (info by default)
  • --structured-log - enables structured log output in a JSON format, true/false (false by default)

Other

  • --licenses - shows open-source third-party licenses used in MCPBus
Previous
3. Configure AI-agent