Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientFunc ¶
ClientFunc returns the HTTP client to use for an operation. req is the original incoming MCP call — inspect req.Extra.Header for inbound auth tokens or other headers to forward to the upstream service.
type Dispatcher ¶
type Dispatcher struct {
// contains filtered or unexported fields
}
Dispatcher reads the OpenAPI spec, generates MCP tools for the same. The tool handler function also validates the incoming schema spec, and calls the upstream endpoint.
func NewDispatcher ¶
func NewDispatcher(baseURL string, clientFunc ClientFunc) *Dispatcher
NewDispatcher is used to create a new Dispatcher.
func (*Dispatcher) Handler ¶
func (d *Dispatcher) Handler(ctx context.Context, req *mcp.CallToolRequest, input any) ( *mcp.CallToolResult, any, error, )
func (*Dispatcher) LoadSpec ¶
func (d *Dispatcher) LoadSpec(specData string) error
Click to show internal directories.
Click to hide internal directories.