Skip to main content
Glama

list_subnets

Retrieve all subnets in an Oracle Cloud Infrastructure compartment, with optional filtering by Virtual Cloud Network to identify network configurations and routing details.

Instructions

List all subnets in a compartment, optionally filtered by VCN.

Args:
    compartment_id: OCID of the compartment to list subnets from
    vcn_id: Optional OCID of the VCN to filter subnets

Returns:
    List of subnets with CIDR blocks, security lists, and routing information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
compartment_idYes
vcn_idNo
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It describes the action as a list operation (implying read-only, non-destructive behavior) and specifies the return content (CIDR blocks, security lists, routing information), which adds useful context. However, it doesn't cover potential behaviors like pagination, rate limits, authentication needs, or error conditions, leaving gaps for a tool with no annotation support.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured and concise, with a clear purpose statement followed by dedicated sections for Args and Returns. Each sentence earns its place by providing essential information without redundancy, and it's front-loaded with the core functionality. The formatting enhances readability without unnecessary verbosity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (2 parameters, no annotations, no output schema), the description is reasonably complete. It covers the purpose, parameters, and return content adequately. However, it lacks details on behavioral aspects like pagination or error handling, and without an output schema, the return value description is somewhat vague (e.g., no mention of data structure or fields beyond a high-level list).

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds significant semantic value beyond the input schema, which has 0% description coverage. It explains that 'compartment_id' is the OCID of the compartment to list subnets from and 'vcn_id' is an optional OCID for filtering by VCN, clarifying the purpose and format of both parameters. This compensates well for the schema's lack of descriptions, though it doesn't detail OCID format or constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose as 'List all subnets in a compartment, optionally filtered by VCN.' This specifies the verb ('list'), resource ('subnets'), and scope ('compartment'), distinguishing it from sibling tools like 'get_subnet' (singular retrieval) and 'list_vcns' (different resource). However, it doesn't explicitly differentiate from other list tools beyond the resource type.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context through the optional 'vcn_id' parameter for filtering, suggesting this tool is for listing subnets within a compartment, with VCN filtering as an option. However, it doesn't provide explicit guidance on when to use this versus alternatives like 'get_subnet' for specific subnet retrieval or 'list_vcns' for VCN listing, nor does it mention prerequisites or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/jopsis/mcp-server-oci'

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