Skip to main content
Glama

Messaging: Find chat by user

messaging_find_chat_by_user
Read-onlyIdempotent

Find the existing one-to-one chat for a known LinkedIn, WhatsApp, Instagram or Telegram provider user ID. Use after resolving the user; user_id is not chat_id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_idYesExact provider user ID returned by a profile/contact resolver; never a name or profile URL.
account_idNoOptional Nilyo connection ID (unipile_account_id from list_connected_accounts). Omit when the user has one account for this provider. When several exist, Nilyo never guesses: list them (display name, identifier, provider user ID), choose the one the user named or ask, and pass its ID here.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, covering the safety profile. The description adds the crucial warning that user_id is not chat_id, preventing misuse. It does not mention behavior when no chat exists, but the annotation coverage lowers the bar, and the warning adds meaningful context beyond the schema.

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?

Two sentences with no fluff. The primary purpose is front-loaded, and the usage note is attached at the end. Every word earns its place; it is both concise and structured 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 simple signature (2 params, no output schema, no nesting), the description covers the core purpose, the prerequisite, and a key distinction. It does not describe the return value or the case when no chat exists, which is a minor gap but not critical for a read-only lookup tool. The annotations fill in the safety aspects, so overall it is reasonably complete.

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%, so both parameters are already well documented. The description reiterates the user_id vs chat_id distinction, but the schema's own description of user_id already covers this ('never a name or profile URL'). No additional semantic value beyond what the schema provides, so the baseline of 3 is appropriate.

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 (find), the target (existing one-to-one chat), and the scope (for known LinkedIn, WhatsApp, Instagram, or Telegram provider user IDs). It also clarifies a common confusion ('user_id is not chat_id'), making it unambiguous against sibling tools like messaging_start_chat or message_resolve_chat.

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

Usage Guidelines4/5

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

It explicitly instructs to use after resolving the user, giving a clear precondition. It does not name alternative tools outright, but the phrase 'existing one-to-one chat' implies it is for retrieval rather than creation. Slight gap in not mentioning when NOT to use it (e.g., when you already have the chat_id).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.