Documentation
¶
Overview ¶
Package server wires the MCP SDK to the Pipedrive client. It does not own the lifetime of either; cmd/pipedrive-mcp/main.go does. This package only provides the constructor that returns a server with every tool package's Register function called.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New(ctx context.Context, name, version string, client *pipedrive.Client, domain string, opts tools.RegisterOptions) *mcp.Server
New constructs an MCP server with every tool package wired up. The client may be nil (used by the --dump-schemas path, where tool handlers never execute — only their schemas are dumped). domain is used for URL injection in tool outputs.
opts.DryRun mirrors PIPEDRIVE_DRY_RUN; opts.EnableDestructive mirrors PIPEDRIVE_ENABLE_DESTRUCTIVE — see the RegisterOptions godoc for details.
The parent ctx governs the cache-warm goroutine's lifetime. When it cancels (e.g. SIGTERM), the warm-up's in-flight HTTP requests cancel cleanly instead of running orphaned to completion.
Types ¶
This section is empty.