googleapis/mcp-toolbox · error

invalid prebuilt config format '%s'. Did you mean '%s/%s'? U

Error message

invalid prebuilt config format '%s'. Did you mean '%s/%s'? Use '/' to specify a toolset

What it means

LoadConfig validates prebuilt config names, which must be of the form '<source>/<toolset>'. If the name contains '.', ':' or '@' but not '/', and the part before the separator is a known prebuilt source, the toolbox guesses you used the wrong separator and throws this hinting error.

Source

Thrown at cmd/internal/options.go:206

	}

	var allConfigs []Config

	// Load Prebuilt Configuration
	if len(opts.PrebuiltConfigs) > 0 {
		slices.Sort(opts.PrebuiltConfigs)
		sourcesList := strings.Join(opts.PrebuiltConfigs, ", ")
		logMsg := fmt.Sprintf("Using prebuilt tool configurations for: %s", sourcesList)
		logger.InfoContext(ctx, logMsg)
		logger.WarnContext(ctx, "These prebuilt configs are intended for 'build-time' use cases, where agents are helping trusted developers build things. They are not secure enough for 'run time' use cases, where the agent will be talking to potentially untrusted developers.")

		for _, configName := range opts.PrebuiltConfigs {
			if !strings.Contains(configName, "/") {
				for _, sep := range []string{".", ":", "@"} {
					if strings.Contains(configName, sep) {
						parts := strings.SplitN(configName, sep, 2)
						if slices.Contains(prebuiltconfigs.GetPrebuiltSources(), parts[0]) {
							errMsg := fmt.Errorf("invalid prebuilt config format '%s'. Did you mean '%s/%s'? Use '/' to specify a toolset", configName, parts[0], parts[1])
							logger.ErrorContext(ctx, errMsg.Error())
							return isCustomConfigured, errMsg
						}
					}
				}
			}

			sourceName, toolsetName, _ := strings.Cut(configName, "/")

			buf, err := prebuiltconfigs.Get(sourceName)
			if err != nil {
				logger.ErrorContext(ctx, err.Error())
				return isCustomConfigured, err
			}

			// Parse into Config struct
			parsed, err := parser.ParseConfig(ctx, buf)
			if err != nil {

View on GitHub (pinned to 8cc6e09de2)

Solutions

  1. Replace the separator with '/': use 'postgres/postgres-sql' instead of 'postgres:postgres-sql' or 'postgres.postgres-sql'
  2. Check the list of valid prebuilt sources (docs / prebuilt-configs) to confirm the source name
  3. If loading a local YAML file, pass a file path rather than a prebuilt config name

Example fix

// before
--prebuilt postgres:postgres-sql
// after
--prebuilt postgres/postgres-sql
Defensive patterns

Strategy: validation

Validate before calling

const configName = "postgres:postgres-sql"
if !strings.Contains(configName, "/") && /[.:@]/.test(configName) {
    throw new Error("prebuilt config must use '/': " + configName.split(/[.:@]/)[0] + "/" + configName.split(/[.:@]/)[1])
}

Prevention

When it happens

Trigger: Passing --prebuilt <name> (or --tools-file style prebuilt) like 'postgres-postgres-sql', 'postgres:postgres-sql', or 'postgres@postgres-sql' instead of 'postgres/postgres-sql'.

Common situations: Copying a config filename like 'postgres.yaml' or using the Docker image tag syntax 'postgres@sha256:...' when intending to select a source toolset.

Related errors


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