Open Context Protocol is live! 🚀 Read the launch post
createReservedIp

createReservedIp

Create Reserved IP

Details

  • Method: POST
  • Path: /reserved-ips
  • Operation ID: create-reserved-ip

Parameters

{
  "region": {
    "description": "The [Region id](#operation/list-regions) where the Reserved IP will be created.",
    "required": true,
    "location": "body",
    "type": "string"
  },
  "ip_type": {
    "description": "The type of IP address.\n\n* v4\n* v6",
    "required": true,
    "location": "body",
    "type": "string"
  },
  "label": {
    "description": "The user-supplied label.",
    "required": false,
    "location": "body",
    "type": "string"
  }
}

Response Schema

{
  "type": "object",
  "properties": {
    "reserved_ip": {
      "title": "reserved-ip",
      "type": "object",
      "x-examples": {
        "reserved ip": {
          "id": "cb676a46-66fd-4dfb-b839-443f2e6c0b60",
          "region": "ewr",
          "ip_type": "v6",
          "subnet": "2001:db8:9999::",
          "subnet_size": 64,
          "label": "Example Reserved IPv6",
          "instance_id": "cb676a46-66fd-4dfb-b839-443f2e6c0b60"
        }
      },
      "description": "Reserved IP information.",
      "properties": {
        "id": {
          "type": "string",
          "description": "A unique ID for the Reserved IP."
        },
        "region": {
          "type": "string",
          "description": "The [Region id](#operation/list-regions) where the Reserved IP is located."
        },
        "ip_type": {
          "type": "string",
          "description": "The type of IP address.\n\n* v4\n* v6"
        },
        "subnet": {
          "type": "string",
          "description": "The IP subnet."
        },
        "subnet_size": {
          "type": "integer",
          "description": "The IP network size in bits."
        },
        "label": {
          "type": "string",
          "description": "The user-supplied label."
        },
        "instance_id": {
          "type": "string",
          "description": "The [Instance id](#operation/list-instances) attached to this Reserved IP."
        }
      }
    }
  }
}

Usage

from ocp_agent import OCPAgent

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

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