googleapis/mcp-toolbox · error
description is required for tool %q
Error message
description is required for tool %q
What it means
Config.Initialize for clickhouse-list-tables requires a non-empty `description`; the toolbox surfaces tool descriptions to MCP/LLM clients, so an empty one is rejected at load time. This is config validation, not a runtime failure.
Source
Thrown at internal/tools/clickhouse/clickhouselisttables/clickhouselisttables.go:75
}
type Config struct {
tools.ConfigBase `yaml:",inline"`
Type string `yaml:"type" validate:"required"`
Source string `yaml:"source" validate:"required"`
Parameters parameters.Parameters `yaml:"parameters"`
Annotations *tools.ToolAnnotations `yaml:"annotations,omitempty"`
}
var _ tools.ToolConfig = Config{}
func (cfg Config) ToolConfigType() string {
return listTablesType
}
func (cfg Config) Initialize(context.Context) (tools.Tool, error) {
if cfg.Description == "" {
return nil, fmt.Errorf("description is required for tool %q", cfg.Name)
}
databaseParameter := parameters.NewStringParameter(databaseKey, "The database to list tables from.")
params := parameters.Parameters{databaseParameter}
allParameters, paramManifest, err := parameters.ProcessParameters(nil, params)
if err != nil {
return nil, err
}
return Tool{
BaseTool: tools.NewBaseTool(
cfg,
tools.GetAnnotationsOrDefault(cfg.Annotations, tools.NewReadOnlyAnnotations),
tools.Manifest{Description: cfg.Description, Parameters: paramManifest, AuthRequired: cfg.AuthRequired},
allParameters,
),
}, nilView on GitHub (pinned to 8cc6e09de2)
Solutions
- Add a meaningful `description` to the tool definition in YAML.
- Verify the description key is correctly indented under the right tool.
- Set cfg.Description before Initialize when constructing Config in code.
Example fix
// before
tools:
list_tables:
source: ch
// after
tools:
list_tables:
source: ch
description: List tables in a ClickHouse database. Defensive patterns
Strategy: validation
Validate before calling
// Go
if cfg.Name == "" || cfg.Description == "" {
return errors.New("clickhouse-list-tables needs name and description")
}
_, err := cfg.Initialize(context.Background()) Prevention
- Use a config template that includes description for every tool.
- Verify YAML indentation places description inside the intended tool block.
- Run config-load smoke tests in CI.
When it happens
Trigger: A `clickhouse-list-tables` tool entry in YAML without a `description` (or with an empty/misspelled key), or a Config literal with Description unset passed to Initialize in Go tests.
Common situations: Trimming configs for brevity and dropping the description; YAML indentation putting the description under the wrong tool; renaming keys during upgrades.
Understand the failure class
Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.
Related errors
- description is required for tool %q
- description is required for tool %q
- description is required for tool %q
- description is required for tool %q
- description is required for tool %q
AI-assisted analysis of googleapis/mcp-toolbox@8cc6e09de2 (2026-09-05).
Data as JSON: /api/errors/b2f36d774b59fdfc.
Report an issue: GitHub.