processBuiltinMCPTool handles built-in MCP tools (github and playwright)
(toolName string, toolValue any, serverFilter string)
| 257 | |
| 258 | // processBuiltinMCPTool handles built-in MCP tools (github and playwright) |
| 259 | func processBuiltinMCPTool(toolName string, toolValue any, serverFilter string) (*RegistryMCPServerConfig, error) { |
| 260 | if serverFilter != "" && !strings.Contains(strings.ToLower(toolName), strings.ToLower(serverFilter)) { |
| 261 | return nil, nil |
| 262 | } |
| 263 | |
| 264 | if toolName == "github" { |
| 265 | config := buildGitHubBuiltinConfig(toolValue) |
| 266 | return &config, nil |
| 267 | } |
| 268 | if toolName == "playwright" { |
| 269 | config := buildPlaywrightBuiltinConfig(toolValue) |
| 270 | return &config, nil |
| 271 | } |
| 272 | |
| 273 | return nil, nil |
| 274 | } |
| 275 | |
| 276 | func buildGitHubBuiltinConfig(toolValue any) RegistryMCPServerConfig { |
| 277 | useRemote, customToken, toolConfig := githubBuiltinMode(toolValue) |
no test coverage detected