Skip to main content
Glama

Label a file

set_file_label
DestructiveIdempotent

Add a label to a file or folder, or remove it. Label ids come from list_labels.

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": {
      "fileId": "<fileId>",
      "labelId": "<labelId>",
      "assigned": "<assigned>"
    },
    "name": "set_file_label"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileIdYesThe file id
labelIdYesThe label id
assignedYestrue adds the label, false removes it

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true and idempotentHint=true, so the safety profile is covered structurally. The description adds that the target may be a file or a folder and that the same parameter both adds and removes, which is useful behavioral context, but it says nothing about permissions, what happens when the label is already present, or failure modes.

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 short sentences with no waste; the dual add/remove capability is front-loaded and the id-sourcing note follows. Nothing is redundant with the title or annotations.

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 simple three-parameter mutation with full schema coverage, rich annotations, and no output schema, the description covers what the agent needs to invoke it. Only edge-case behavior (already-assigned labels, permission requirements) is unaddressed, which is minor at this complexity.

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 coverage is 100%, with each parameter self-documented, including the true-adds/false-removes semantics of 'assigned'. The description's only addition is provenance for labelId (list_labels), which is genuinely helpful but does not extend to the other two parameters.

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 ('Add a label to a file or folder, or remove it'), and makes clear the tool handles both assignment and removal through one entry point. It is clear enough to act on, though it does not distinguish itself from any sibling beyond pointing at list_labels.

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?

'Label ids come from list_labels' gives an explicit prerequisite and routes the agent to the correct sibling for obtaining ids. It stops short of stating when-not to use this versus related tools, but the usage context is clear.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources