Skip to main content
Glama
seandkendall

productivity-mcp

by seandkendall

bulk_set_read

Mark multiple emails as read or unread in one call. Specify message IDs, account, and folder to update email states.

Instructions

Mark many emails read/unread in one call. Returns counts of successes and failures. Rate-limited.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
message_idsYes
readNo
accountNo
folderNoINBOX

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The tool handler for 'bulk_set_read' — iterates over message_ids, calls provider.set_read() for each, and returns counts of successes/failures with up to 5 error details.
    ) -> dict[str, Any]:
        """Mark many emails read/unread in one call. Returns counts of successes
        and failures. Rate-limited."""
        provider = _email(account)
        ok, failed = 0, 0
        errors: list[str] = []
        for mid in message_ids:
            try:
                provider.set_read(mid, read, folder=folder)
                ok += 1
            except Exception as exc:
                failed += 1
                if len(errors) < 5:
                    errors.append(f"{mid}: {exc}")
        return {"ok": ok, "failed": failed, "errors": errors}
  • Function signature defining the tool's input schema: message_ids (list[str]), read (bool, default True), account (str|None), folder (str, default 'INBOX'). The decorator @mcp.tool() exposes this schema to MCP.
    def bulk_set_read(
        message_ids: list[str],
        read: bool = True,
        account: str | None = None,
        folder: str = "INBOX",
    ) -> dict[str, Any]:
  • Tool registration via the @mcp.tool() decorator at line 802. The @_logged wrapper also registers it with the rate limiter.
    @mcp.tool()
    @_logged
    def bulk_set_read(
        message_ids: list[str],
        read: bool = True,
        account: str | None = None,
        folder: str = "INBOX",
    ) -> dict[str, Any]:
  • Rate limit configuration: 10 calls per 60 seconds for 'bulk_set_read'.
    "bulk_set_read": (10, 60.0),
Behavior3/5

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

The description discloses that it returns counts of successes and failures and is rate-limited, which are useful behavioral traits. However, with no annotations provided, it omits details like authentication requirements, atomicity, or partial failure behavior, leaving gaps for an agent.

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?

The description is extremely concise with three short sentences that convey the core function, return type, and a constraint. No unnecessary words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has four parameters with no schema descriptions and an output schema, the description is insufficient. It does not detail the format of message_ids, the meaning of account or folder parameters, or error conditions, leaving significant gaps for correct invocation.

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

Parameters2/5

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

The description adds minimal parameter meaning: it implies that the 'read' boolean controls read/unread status, but it does not explain 'account' or 'folder' parameters. Since schema description coverage is 0%, the description should do more to compensate.

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 action ('Mark many emails read/unread') and the resource ('many emails'). It distinguishes itself from siblings like 'set_email_read' (singular) and other bulk actions like 'bulk_delete_emails'.

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 bulk usage ('in one call') and mentions rate-limiting, but it does not explicitly contrast with alternatives such as 'set_email_read' for single emails or provide conditions for when to use this tool over others.

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/seandkendall/productivity-mcp'

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