Skip to main content
Glama

get_user_email_count_to_sheet

Retrieve email counts for specific Gmail labels across multiple users and output results to a Google Sheet for analysis.

Instructions

    Retrieves email counts for specific labels across multiple users.
    Uses multiprocess redirect if outputting to a sheet.
    
    Args:
        user_emails: List of user emails to query.
        label: The Gmail label to count (e.g., 'INBOX', 'TRASH').
        output_sheet_id: Optional Sheet ID for output.
        output_sheet_name: Tab name for sheet output.
        
    GAM pattern:
        gam [redirect csv - multiprocess todrive ...]
        user <email1>,<email2> show messages label <label> countsonly
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
labelNoINBOX
user_emailsYes
output_sheet_idNo
output_sheet_nameNoEmail Counts

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions multiprocess redirect for sheet output and shows a GAM command pattern, but lacks details on permissions required, error handling, or side effects. This is minimal transparency for a data retrieval operation.

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?

The description is well-structured: purpose first, then parameter list, then GAM pattern. It is concise with no unnecessary words, though the code block could be slightly trimmed. Front-loads the core action effectively.

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?

Given the tool has 4 parameters (1 required) and no annotations, the description covers all parameters and provides a usage pattern. The output schema exists but return values are not explained, which is acceptable. It lacks error handling or edge cases, but is adequate for the complexity.

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

Parameters4/5

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

With 0% schema description coverage, the description compensates well by explaining all four parameters: user_emails (list), label (default INBOX), output_sheet_id (optional), output_sheet_name (default 'Email Counts'). The GAM pattern also clarifies usage context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Retrieves' and the resource 'email counts for specific labels across multiple users'. It distinguishes this tool from sibling audit and GAM tools by specifying its unique function of counting emails by label for multiple users, optionally outputting to a sheet.

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 provides a GAM pattern and mentions multiprocess redirect, but does not explicitly state when to use this tool versus alternatives. No exclusion criteria or alternative tool references are given, relying on implied context from sibling names.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ktibbs9417/gamcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server