WithMcpServer
Method
func (ResourceWithEndpoints) WithMcpServer(options ...*WithMcpServerOptions) ResourceWithEndpointsSignature
method
WithMcpServer builderMarks the resource as hosting a Model Context Protocol (MCP) server on the specified endpoint.
WithMcpServer(options ...*WithMcpServerOptions) ResourceWithEndpointsParameters
options...*WithMcpServerOptions Optional settings, described under Options.Options
Optional parameters are passed in a trailing options ...*WithMcpServerOptions argument.
Path*stringAn optional path to append to the endpoint URL when forming the MCP server address. Defaults to "/mcp". A leading slash is added if missing. A null or empty value uses the endpoint URL without an additional path.EndpointName *stringAn optional name of the endpoint that hosts the MCP server. If not specified, selects the endpoint named https, falling back to the endpoint named http. Names are matched case-insensitively; endpoints with other names must be selected explicitly, regardless of their URI scheme.Returns
ResourceWithEndpoints The resource builder.
Returns a handle; failures surface later via Err().
Applies to
This method applies to the following types: