Skip to main content
Glama

upsert_collection

Create or update a collection of IPs, CIDRs, and DNS names for use in resources and route exclusions; changes are staged until apply_change.

Instructions

Create or update a collection. Collections group network locations (IPs, CIDRs, DNS names) for use in resources and route exclusions. Returns a change_id; nothing changes until apply_change.

Args: name: Human-readable collection name. description: Optional description. collection_id: UUID to update existing; omit to create new.

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": {
      "name": "<name>"
    },
    "name": "upsert_collection"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
descriptionNo
collection_idNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.8/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 behavioral burden and delivers the most important trait: this is a staged/pending mutation that returns a change_id and has no effect until apply_change is called. It does not cover authorization requirements, uniqueness/collision handling for name, or whether omitted fields are cleared on update, so it is good but not complete for a mutation tool.

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?

Two sentences front-load the purpose and the staged-apply warning, followed by a tight Args block. Nothing is padded; the create-vs-update rule appears where an agent will look for it.

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?

An output schema exists and the description still names the key return value (change_id), and the apply_change dependency – the biggest correctness risk – is disclosed. Remaining gaps around update semantics (partial vs full replacement) and permission prerequisites keep it short of a 5.

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 0%, so the Args block does real work: it explains that collection_id's presence flips the operation from create to update, which no schema field conveys. However, name and description get only tautological one-liners ("Human-readable collection name", "Optional description") with no format, uniqueness, or length constraints, so the schema's real gaps are only partially filled.

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 gives a specific verb pair and resource ("Create or update a collection") and adds domain meaning by explaining that collections group IPs, CIDRs, and DNS names for resources and route exclusions. That implicitly separates it from get_collection, delete_collection, and add_collection_members, though 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 Guidelines4/5

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

It clearly states the mode-selection rule: supply collection_id to update, omit it to create. It also flags the critical workflow constraint that nothing takes effect until apply_change, which routes the agent to the correct follow-up sibling. No explicit when-not guidance, but the create/update split covers the main decision.

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