Skip to main content
Glama
DimitrisPasakaleris

WhatsApp MCP Server

get_last_interaction

Fetch the last WhatsApp message involving a specified contact using their JID. Use it to review conversation context or confirm prior contact.

Instructions

Get the most recent WhatsApp message involving the contact.

Args: jid: The JID of the contact to search for

Returns: Message dictionary with id, timestamp, sender, content, etc. or empty dict if not found.

Input Schema

NameRequiredDescriptionDefault
jidYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations provided, the description carries the full behavioral burden. It does disclose a useful edge case ('empty dict if not found'), implying a read-only lookup, but it says nothing about permissions, whether sent and received messages are both considered, or how media-only messages are handled.

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 core purpose is front-loaded in the first sentence, followed by a conventional Args/Returns block. The structure is efficient, though slightly verbose for a one-parameter tool.

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

Completeness3/5

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

An output schema already exists, so the description's Returns block is largely redundant, and the remaining gaps are behavioral: nothing about ordering semantics, whether outgoing messages count, or authorization requirements. Adequate to invoke, but incomplete for a no-annotation tool.

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?

The single parameter is at 0% schema description coverage, so the description must compensate. It states jid is 'the JID of the contact to search for,' which gives meaning but no format guidance (e.g., a phone-number-based JID or group JID) to help the agent construct a valid value.

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?

The description opens with a specific verb and resource: 'Get the most recent WhatsApp message involving the contact.' This clearly delimits the result to a single, newest message, distinguishing it from list-style siblings like list_messages. It does not explicitly name an alternative, but the singleton scope makes the intent unambiguous.

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?

Usage is implied rather than stated — an agent can infer this is a quick 'latest message' lookup rather than a search or history tool. There is no explicit guidance on when to prefer it over list_messages or get_message_context, and no prerequisites or exclusions are given.

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