MCPcopy Create free account
hub / github.com/github/gh-aw / appendBuiltinAllowedTools

Function appendBuiltinAllowedTools

pkg/parser/mcp.go:367–380  ·  view source on GitHub ↗
(config *RegistryMCPServerConfig, toolConfig map[string]any)

Source from the content-addressed store, hash-verified

365}
366
367func appendBuiltinAllowedTools(config *RegistryMCPServerConfig, toolConfig map[string]any) {
368 if toolConfig == nil {
369 return
370 }
371 if allowed, hasAllowed := toolConfig["allowed"]; hasAllowed {
372 if allowedSlice, ok := allowed.([]any); ok {
373 for _, item := range allowedSlice {
374 if str, ok := item.(string); ok {
375 config.Allowed = append(config.Allowed, str)
376 }
377 }
378 }
379 }
380}
381
382func applyGitHubBuiltinOverrides(config *RegistryMCPServerConfig, toolConfig map[string]any) {
383 if toolConfig == nil {

Callers 2

buildGitHubBuiltinConfigFunction · 0.85
ParseMCPConfigFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected