Skip to main content
Glama

netbox_get_object_by_id

Retrieve detailed NetBox object data by object type and ID, with optional field filtering or brief output to reduce token usage.

Instructions

Get detailed information about a specific NetBox object by its ID.

Args: object_type: String representing the NetBox object type (e.g. "dcim.device", "ipam.ipaddress") object_id: The numeric ID of the object fields: Optional list of specific fields to return IMPORTANT: ALWAYS USE THIS PARAMETER TO MINIMIZE TOKEN USAGE Field filtering reduces response payload by 80-90% and is critical for performance.

        - None or [] = returns all fields (NOT RECOMMENDED - use only when you need complete objects)
        - ['id', 'name'] = returns only specified fields (RECOMMENDED)

        Examples:
        - For basic info: ['id', 'name', 'status']
        - For devices: ['id', 'name', 'status', 'site']
        - For IP addresses: ['address', 'dns_name', 'vrf', 'status']

        Uses NetBox's native field filtering via ?fields= parameter.
        **Always specify only the fields you actually need.**
brief: returns only a minimal representation of the object in the response.
       This is useful when you need only a summary of the object without any related data.

Returns: Object dict (complete or with only requested fields based on fields parameter)

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "object_type": "<object_type>",
      "object_id": "<object_id>"
    },
    "name": "netbox_get_object_by_id"
  }
}

Input Schema

NameRequiredDescriptionDefault
briefNo
fieldsNo
object_idYes
object_typeYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose return shape ('Object dict'), the backend mechanism ('NetBox's native field filtering via ?fields='), the payload reduction (80-90%), and what 'brief' does. It says nothing about failure modes when the ID doesn't exist, permission/auth requirements, or whether field names invalid to the type cause an error.

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

Conciseness3/5

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

Purpose and Args are front-loaded and readable, but the fields section repeats the same instruction three times ('ALWAYS USE THIS PARAMETER', 'critical for performance', '**Always specify only the fields you actually need.**'), plus a redundant bullet explaining [] means all fields. The emphasis bloats a four-parameter tool's docs.

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?

For a four-parameter read tool with no annotations and no output schema, the description covers every argument and gives a short but adequate return statement. The remaining gap is error/not-found behavior, which matters but is secondary for a read operation.

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

Parameters5/5

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

Schema coverage is 0%, yet all four parameters are documented with real meaning: object_type includes concrete examples ('dcim.device', 'ipam.ipaddress'), object_id is declared numeric, fields spells out []/None vs a list with per-domain examples, and brief is explained as a minimal representation. This fully compensates for the empty schema descriptions.

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?

States a specific verb and resource: 'Get detailed information about a specific NetBox object by its ID.' The 'specific ... by its ID' phrasing implicitly separates it from list/search siblings like netbox_get_objects and netbox_search_objects, but no sibling is named explicitly.

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?

Usage is only implied: an agent infers this tool applies when it already knows the object type and numeric ID, versus browsing via get_objects or searching via search_objects. The bulk of the guidance concerns the fields parameter (use it, don't omit it) rather than when to choose this tool over an alternative.

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