googleapis/mcp-toolbox · error

description is required for tool %q

Error message

description is required for tool %q

What it means

LookerGetProjects.Config.Initialize requires a non-empty Description because it is used in the tool's manifest shown to LLM clients. An empty Description makes Initialize return this error and abort tool creation. This is a load-time config validation error.

Source

Thrown at internal/tools/looker/lookergetprojects/lookergetprojects.go:71

}

type Config struct {
	tools.ConfigBase `yaml:",inline"`
	Type             string                 `yaml:"type" validate:"required"`
	Source           string                 `yaml:"source" validate:"required"`
	Annotations      *tools.ToolAnnotations `yaml:"annotations,omitempty"`
}

// validate interface
var _ tools.ToolConfig = Config{}

func (cfg Config) ToolConfigType() string {
	return resourceType
}

func (cfg Config) Initialize(context.Context) (tools.Tool, error) {
	if cfg.Description == "" {
		return nil, fmt.Errorf("description is required for tool %q", cfg.Name)
	}

	allParameters := parameters.Parameters{}

	// finish tool setup
	return Tool{
		BaseTool: tools.NewBaseTool(
			cfg,
			tools.GetAnnotationsOrDefault(cfg.Annotations, tools.NewReadOnlyAnnotations),
			tools.Manifest{Description: cfg.Description, Parameters: allParameters.Manifest(), AuthRequired: cfg.AuthRequired},
			allParameters,
		),
	}, nil
}

// validate interface
var _ tools.Tool = Tool{}

View on GitHub (pinned to 8cc6e09de2)

Solutions

  1. Add a meaningful `description:` to the looker-get-projects tool entry.
  2. Keep descriptions non-empty for all looker-* tools; consider linting your YAML for this.
  3. Reload the toolbox and verify the tool appears in the /mcp manifest.

Example fix

// before
tools:
  get-projects:
    kind: looker-get-projects
    source: my-looker
// after
tools:
  get-projects:
    kind: looker-get-projects
    source: my-looker
    description: Lists all Looker projects visible to the authenticated user
Defensive patterns

Strategy: validation

Validate before calling

// Assert every looker-get-projects entry has a description before boot
for name, t := range toolsRaw {
    if t["kind"] == "looker-get-projects" && strings.TrimSpace(t["description"].(string)) == "" {
        return fmt.Errorf("tool %q must define a non-empty description", name)
    }
}

Try / catch

tool, err := cfg.Initialize(ctx)
if err != nil && strings.Contains(err.Error(), "description is required") {
    return fmt.Errorf("supply 'description:' for tool %q in tools.yaml: %w", cfg.Name, err)
}

Prevention

When it happens

Trigger: A tools.yaml entry of kind looker-get-projects is defined without a `description:` field or with an empty string, failing Config.Initialize when the toolbox loads its configuration.

Common situations: Omitting description when hand-authoring configs; scripts generating YAML that skip empty fields; copy-pasted entries where the description was accidentally deleted.

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


AI-assisted analysis of googleapis/mcp-toolbox@8cc6e09de2 (2026-09-05). Data as JSON: /api/errors/dd62d3e62f10d0b0. Report an issue: GitHub.