Skip to main content
Glama

list-ingresses

Retrieve Kubernetes ingress configurations from a specified namespace to manage network routing and access rules for applications.

Instructions

List Kubernetes ingresses in a namespace

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
namespaceNoThe namespace to list ingresses from (optional, defaults to current context namespace)

Implementation Reference

  • Handler function that executes the kubectl command to list Kubernetes ingresses in the specified or default namespace, returning the output.
    case "list-ingresses": {
      const { namespace } = args || {};
      const nsArg = namespace ? `-n ${namespace}` : "";
      const cmd = `kubectl get ingresses ${nsArg} -o wide`;
      const { stdout } = await execAsync(cmd);
      return {
        content: [{ type: "text", text: stdout || "No ingresses found" }]
      };
    }
  • Schema definition for the list-ingresses tool, specifying the optional namespace parameter.
    {
      name: "list-ingresses",
      description: "List Kubernetes ingresses in a namespace",
      inputSchema: {
        type: "object",
        properties: {
          namespace: { 
            type: "string",
            description: "The namespace to list ingresses from (optional, defaults to current context namespace)"
          }
        }
      }
  • server.js:1392-1394 (registration)
    Registration of the tools list handler, which includes the list-ingresses tool in the returned tools array for tool discovery.
    server.setRequestHandler(ListToolsRequestSchema, async () => {
      return { tools };
    });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/thekaranpargaie/kube-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server