Mcp constructor
const
Mcp({})
Creates an MCP configuration annotation.
transport determines the communication protocol (stdio or HTTP).
generateJson controls whether to generate additional JSON metadata.
port specifies the HTTP server port (default: 3000).
address specifies the HTTP bind address (default: '127.0.0.1').
toolPrefix adds a prefix to all tool names in this scope.
autoClassPrefix automatically prefixes tool names with class name.
generateOpenApi controls whether to generate OpenAPI specification.
Implementation
const Mcp({
this.transport = McpTransport.stdio,
this.generateJson = false,
this.port = 3000,
this.address = '127.0.0.1',
this.toolPrefix,
this.autoClassPrefix = false,
this.generateOpenApi = false,
});