Skip to main content
Glama

mark_unread

Mark email as unread to remove the seen flag and maintain message visibility in your inbox.

Instructions

Mark email as unread (remove seen flag)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
folderNoFolder containing the email (default: INBOX)INBOX
message_idNoMessage ID (sequence number)
uidNoUnique ID of the message

Implementation Reference

  • The actual implementation of mark_unread logic in the EmailFlags class which interacts with the IMAP connection.
    def mark_unread(self, folder: str, uids: int | list[int]) -> bool:
        """
        Mark emails as unread (remove \\Seen flag).
    
        Args:
            folder: Folder containing the emails
            uids: Email UID or list of UIDs
    
        Returns:
            True if successful
    
        Raises:
            EmailFlagsError: If operation fails
        """
        return self._store_flags(folder, uids, "-FLAGS", self.FLAG_SEEN)
Behavior3/5

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

With no annotations provided, the description carries the full burden. It adds valuable behavioral context by specifying the mechanism ('remove seen flag'), revealing this is an IMAP flag operation. However, it omits safety-critical details like whether the operation is idempotent, reversible (via mark_read), or if it triggers notifications.

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?

Extremely concise at 6 words. Front-loaded with the action verb, zero redundancy, and the parenthetical technical detail earns its place by clarifying the underlying protocol mechanism without bloating the text.

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?

Adequate for a simple state-toggle tool with complete parameter documentation. The description covers the core action and mechanism. Missing minor context like relationship to mark_read or output behavior, but sufficient given the low complexity and rich input schema.

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 100%, documenting folder, message_id, and uid. The description adds no parameter-specific guidance beyond the schema (e.g., no explanation of when to use message_id vs uid), earning the baseline score for high-coverage schemas.

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?

Clear verb ('Mark') and resource ('email') with specific state ('unread'). The parenthetical '(remove seen flag)' provides technical precision that distinguishes this from sibling flag operations like mark_flagged. However, it does not explicitly differentiate from mark_read (the inverse operation), relying on the tool name for that contrast.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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

No guidance on when to use this tool versus alternatives. It does not indicate typical workflows (e.g., 'use to undo a mistaken mark_read' or 'use to remind yourself to follow up later'). The description only states what the tool does, not when to choose it.

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/AdJIa/mail-mcp-server'

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