Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MCPServer ¶
type MCPServer struct {
// contains filtered or unexported fields
}
MCPServer wraps the mcp-go server with Faucet-specific tool and resource registrations. It exposes database services as MCP tools so AI agents can discover schemas, query data, and perform CRUD operations.
func NewMCPServer ¶
func NewMCPServer(registry *connector.Registry, store *config.Store, logger *slog.Logger) *MCPServer
NewMCPServer creates an MCPServer pre-loaded with all Faucet tools and resources. The returned server is ready to serve over stdio or HTTP.
func (*MCPServer) HTTPHandler ¶
HTTPHandler returns an http.Handler implementing the Streamable HTTP MCP transport. This is suitable for mounting on an existing HTTP server/router so the MCP endpoint runs alongside the REST API on the same port.
func (*MCPServer) ServeHTTP ¶
ServeHTTP starts the MCP server in Streamable HTTP mode, listening on the given address (e.g. ":3001"). This is suitable for remote MCP clients.
func (*MCPServer) ServeStdio ¶
ServeStdio starts the MCP server in stdio mode. This is the primary integration path for Claude Code, Claude Desktop, and other MCP clients that launch the server as a subprocess.