Skip to main content
Glama

untrash_thread

Idempotent

Restore one or more Gmail threads from Trash to their original location, accepting a thread ID or list of up to 100 IDs. Use it to recover accidentally trashed email conversations.

Instructions

Take a whole thread (or a list) out of the trash, back where it was. At most 100 items.

Args: threadId: thread ID, or a list of IDs.

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

Input Schema

NameRequiredDescriptionDefault
threadIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.12.3
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "untrash_threadOutput",
      -  "type": "object"
      -}New value: +null
  2. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare idempotent, non-destructive, and open-world behavior. The description adds useful context beyond annotations: restoration to the original location ('back where it was') and a batch size limit of 100 items. It does not cover permission requirements or behavior for untrashed IDs.

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?

Front-loads the action, then gives the limit and a one-line Args block. No sentence is wasted and the structure is easy to scan.

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 restore mutation with rich annotations and no output schema, the description covers the action, restoration semantics, and batch limit. Minor gaps remain around routing to untrash_message and permission prerequisites.

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?

With 0% schema description coverage, the description carries the burden of explaining threadId. It correctly notes that the parameter accepts a single ID or a list and adds the 100-item cap, but it does not specify ID format or whether the cap applies per list. Adequate but incomplete.

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-resource pair: taking a whole thread (or list) out of the trash. The phrase 'whole thread' implicitly distinguishes it from the sibling untrash_message, but no alternative is explicitly named. Clear without being fully sibling-differentiated.

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 by saying 'out of the trash', so the agent knows it applies to trashed threads. However, it gives no explicit when-to-use vs untrash_message, no prerequisites, and no when-not guidance.

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