Documentation
¶
Overview ¶
Package tools is the central registry for every tool instance wick will mount. Downstream apps append to it via app.RegisterTool, and server.go walks All() at boot to validate, wire routes, and seed config rows.
Three seed paths exist:
- init() seeds core tools that ship with every consumer (currently encfields, since the MCP encrypt/decrypt redirects depend on it).
- RegisterBuiltins() seeds the in-house tools every downstream wick app gets by default — currently the agents session manager. Called from server.go / worker.go boot, before tools.All().
- RegisterLabSamples() seeds demo-only tools used by cmd/lab — convert-text variants and the external-links grid. Downstream apps never see these.
To add a tool here:
- Create internal/tools/<name>/ with a Register(r tool.Router) func and, if the tool has runtime-editable config, a Config struct.
- Append app.RegisterTool calls to RegisterBuiltins (default-on for every wick app) or RegisterLabSamples (lab binary only).
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Register ¶
Register appends a fully-resolved Module record to the registry. Called from app.RegisterTool / app.RegisterToolNoConfig; do not call directly from app code.
func RegisterBuiltins ¶
func RegisterBuiltins()
RegisterBuiltins seeds in-house tools every downstream wick app gets by default. Called from internal/pkg/api/server.go (web) and internal/pkg/worker/server.go (worker) at boot, before tools.All().
Idempotent on Meta.Key: re-calling appends nothing if the key was already registered (downstream main.go can also explicitly call app.RegisterTool with the same key without producing duplicates).
func RegisterLabSamples ¶ added in v0.9.0
func RegisterLabSamples()
RegisterLabSamples seeds demo-only tools shipped with the cmd/lab binary — convert-text and the external-links grid. Downstream wick apps do not call this; their main.go registers the tools they need.
func Unregister ¶ added in v1.2.9
Unregister drops the tool registered under key, if any. Used when a plugin declares it replaces that key (tool.Tool.Replaces): the plugin wins and the old tool gets no routes, card or config rows. Reports whether a tool was removed.
Types ¶
This section is empty.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package agents backs /tools/agents — the Agents UI Manager.
|
Package agents backs /tools/agents — the Agents UI Manager. |
|
view/workflow
Package workflow holds the templ components for /tools/agents/workflows.
|
Package workflow holds the templ components for /tools/agents/workflows. |
|
Package converttext is a stateless text-conversion tool.
|
Package converttext is a stateless text-conversion tool. |
|
Package encfields backs /tools/encfields — the in-app form for minting and reversing wick_enc_ tokens.
|
Package encfields backs /tools/encfields — the in-app form for minting and reversing wick_enc_ tokens. |
|
Package external wraps third-party links as tool.Module entries so they show up on the home grid and palette alongside in-app tools.
|
Package external wraps third-party links as tool.Module entries so they show up on the home grid and palette alongside in-app tools. |
|
Package plugin is the host side of tool plugins: a kind=tool binary under plugins/tools/<key>/ registers as an ordinary tool (grid, palette, access rules, config page) whose routes reverse-proxy to the plugin's HTTP server on a unix socket.
|
Package plugin is the host side of tool plugins: a kind=tool binary under plugins/tools/<key>/ registers as an ordinary tool (grid, palette, access rules, config page) whose routes reverse-proxy to the plugin's HTTP server on a unix socket. |
|
Package providerstorage mounts a Provider Storage Manager UI under /tools/provider-storage.
|
Package providerstorage mounts a Provider Storage Manager UI under /tools/provider-storage. |
|
Package webtty mounts a browser-based terminal under /tools/webtty.
|
Package webtty mounts a browser-based terminal under /tools/webtty. |