()
| 45 | call_api(operationId="SQLService/Query", body={"name": "instances/i/databases/db", "statement": "SELECT 1"})` |
| 46 | |
| 47 | func (s *Server) registerCallTool() { |
| 48 | mcp.AddTool(s.mcpServer, &mcp.Tool{ |
| 49 | Name: "call_api", |
| 50 | Description: callAPIDescription, |
| 51 | }, s.handleCallAPI) |
| 52 | } |
| 53 | |
| 54 | func (s *Server) handleCallAPI(ctx context.Context, _ *mcp.CallToolRequest, input CallInput) (*mcp.CallToolResult, any, error) { |
| 55 | // Validate input |