JuliusBrussee/caveman · error
bedrock endpoint host %q does not match endpoint kind %q
Error message
bedrock endpoint host %q does not match endpoint kind %q
What it means
Error "bedrock endpoint host %q does not match endpoint kind %q" thrown in JuliusBrussee/caveman.
Source
Thrown at proxy/providers/bedrock/routing.go:207
return nil, fmt.Errorf("bedrock Mantle path %q is not allowed", req.URL.Path)
}
base, err = resolveMantleBase(base, region)
if err != nil {
return nil, err
}
base.Path = strings.TrimRight(base.Path, "/") + strings.TrimPrefix(req.URL.Path, "/bedrock")
default:
return nil, fmt.Errorf("bedrock request path %q is not allowed", req.URL.Path)
}
base.RawQuery = req.URL.RawQuery
if env.IsProduction() {
if err := ssrf.ValidateURL(ctx, base.String(), ssrf.ManagedConfig()); err != nil {
return nil, err
}
hostKind, _, ok := bedrockHostKind(base.Hostname())
if !ok || hostKind != kind {
return nil, fmt.Errorf("bedrock endpoint host %q does not match endpoint kind %q", base.Hostname(), kind)
}
}
return base, nil
}
func endpointKindForPath(path string) string {
switch {
case strings.HasPrefix(path, "/bedrock/model/"):
return endpointRuntime
case strings.HasPrefix(path, "/bedrock/anthropic/"):
return endpointMantle
default:
return ""
}
}
func mantleActionAllowed(path string) bool {
switch path {View on GitHub (pinned to 27d5a3981a)
Solutions
- Use an endpoint host matching the configured endpoint kind.
When it happens
Trigger: Thrown at proxy/providers/bedrock/routing.go:207 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of JuliusBrussee/caveman@27d5a3981a (2026-08-15).
Data as JSON: /api/errors/3f12b5ae65c7ba57.
Report an issue: GitHub.