Skip to main content
Glama
J-MaFf

s2-netbox-mcp

by J-MaFf

get_locations

Read-only

List the locations configured in NetBox and their parent-child hierarchy to retrieve LOCATIONKEY values used by access-control tasks such as portal status checks and threat-level updates.

Instructions

Lists the locations configured on the NetBox system (wraps NBAPI GetLocations). Each record carries LOCATIONKEY, PARTITIONKEY and a nested PARENTLOCATION { PARENTKEY, NAME } block, so the result describes a location tree. LOCATIONKEY values feed get_portal_statuses and set_threat_level.

Input Schema

NameRequiredDescriptionDefault
STARTFROMKEYNoOptional. Pagination cursor to continue listing from a previous call. (Not in the guide's Calling Parameters list, but its documented FAIL messages include "Invalid STARTFROMKEY".)
ALLPARTITIONSNoOptional. "TRUE" to list locations across all partitions.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.4.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, so the safety profile is covered. The description goes further and discloses the concrete record shape (LOCATIONKEY, PARTITIONKEY, nested PARENTLOCATION block implying a tree), which is real behavioral context, though it says nothing about pagination behavior or ordering.

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

Conciseness4/5

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

Three front-loaded sentences with no filler; purpose comes first, then return shape, then downstream consumers. The parenthetical 'wraps NBAPI GetLocations' is the only marginally expendable content, so not quite a 5.

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?

With no output schema, the description usefully carries the return-value burden by describing record fields and the location-tree structure. Pagination and partition-scoping behavior are left to the schema, but nothing needed to call the tool correctly is missing.

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

Parameters3/5

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

Schema description coverage is 100%, so both parameters (STARTFROMKEY cursor, ALLPARTITIONS enum) are already documented in the schema. The description adds no syntax or semantics beyond that, so the baseline 3 applies.

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 ('Lists the locations configured on the NetBox system') and adds the underlying API call (NBAPI GetLocations) for traceability. It is clearly distinguishable from sibling list tools like get_portals or get_partitions, though it never explicitly names what it is not.

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?

It hints at downstream use by noting that LOCATIONKEY values feed get_portal_statuses and set_threat_level, which implies a reason to call it. However, it gives no when-to-use/when-not guidance, no prerequisites, and no comparison against alternatives such as get_partitions or get_floors.

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