Open Context Protocol is live! 🚀 Read the launch post

getNodepools

List NodePools

Details

  • Method: GET
  • Path: /kubernetes/clusters/{vke-id}/node-pools
  • Operation ID: get-nodepools

Parameters

{}

Response Schema

{
  "type": "object",
  "properties": {
    "node_pools": {
      "type": "array",
      "items": {
        "title": "nodepools",
        "type": "object",
        "x-examples": {
          "example nodepool": {
            "id": "11e4443a-f92a-46d6-94c8-61c1a1a7514e",
            "date_created": "2021-07-07T22:57:01+00:00",
            "label": "my-label",
            "tag": "my-tag",
            "plan": "vc2-1c-2gb",
            "status": "pending",
            "node_quantity": 2,
            "min_nodes": 2,
            "max_nodes": 5,
            "auto_scaler": true,
            "nodes": [
              {
                "id": "43eda5c8-67f7-4c63-88bc-2f568b48b2b0",
                "label": "my-label-48770259-6ac60e6313dd1",
                "date_created": "2021-07-07T22:57:01+00:00",
                "status": "pending"
              },
              {
                "id": "15a7893d-d584-45d5-a74c-d9f46866aa3c",
                "label": "my-label-48770259-6ac60e6313ddc",
                "date_created": "2021-07-07T22:57:01+00:00",
                "status": "pending"
              }
            ]
          }
        },
        "description": "NodePool",
        "x-tags": [
          "kubernetes"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "The [NodePool ID](#operation/get-nodepools)."
          },
          "date_created": {
            "type": "string",
            "description": "Date of creation"
          },
          "label": {
            "type": "string",
            "description": "Label for nodepool"
          },
          "tag": {
            "type": "string",
            "description": "Tag for node pool"
          },
          "plan": {
            "type": "string",
            "description": "Plan used for nodepool"
          },
          "status": {
            "type": "string",
            "description": "Status for nodepool"
          },
          "node_quantity": {
            "type": "integer",
            "description": "Number of nodes in nodepool"
          },
          "nodes": {
            "type": "array",
            "items": {
              "title": "nodepool-instances",
              "type": "object",
              "description": "Instance that belongs to a nodepool",
              "x-examples": {
                "example nodepool": {
                  "id": "43eda5c8-67f7-4c63-88bc-2f568b48b2b0",
                  "label": "my-label-48770259-6ac60e6313dd1",
                  "date_created": "2021-07-07T22:57:01+00:00",
                  "status": "pending"
                }
              },
              "properties": {
                "id": {
                  "type": "string",
                  "description": "ID of the nodepool instance"
                },
                "label": {
                  "type": "string",
                  "description": "Label of the nodepool instance"
                },
                "date_created": {
                  "type": "string",
                  "description": "Date of creation"
                }
              }
            }
          },
          "date_updated": {
            "type": "string",
            "description": "Date the nodepool was updated."
          },
          "auto_scaler": {
            "type": "boolean",
            "description": "Displays if the auto scaler is enabled or disabled for your cluster."
          },
          "min_nodes": {
            "type": "integer",
            "description": "Auto scaler field that displays the minimum nodes you want for your cluster."
          },
          "max_nodes": {
            "description": "Auto scaler field that displays the maximum nodes you want for your cluster.",
            "type": "integer"
          }
        }
      }
    }
  }
}

Usage

from ocp_agent import OCPAgent

agent = OCPAgent()
await agent.register_api('vultr')

# Call this tool
result = await agent.call_tool('getNodepools', {
    # Add required parameters here
})