Skip to main content
Glama

getContact

Retrieve comprehensive contact details including emails, phone numbers, social links, and notes by inputting a contact ID using Clay's MCP server tools.

Instructions

Get details for a contact by id, including emails, social links, phone numbers, and notes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
contact_idYesThe ID of the contact to get details for.

Implementation Reference

  • index.js:187-197 (registration)
    Registration of the MCP tool 'getContact' including name, description, input schema, and execute handler that proxies to external API.
    server.addTool({
      name: "getContact",
      description:
        "Get details for a contact by id, including emails, social links, phone numbers, and notes.",
      parameters: z.object({
        contact_id: z
          .number()
          .describe("The ID of the contact to get details for."),
      }),
      execute: async (params, { session }) => callTool("/get-contact", params, session),
    });
  • Input schema for 'getContact' tool using Zod: requires contact_id as number.
    parameters: z.object({
      contact_id: z
        .number()
        .describe("The ID of the contact to get details for."),
    }),
  • Handler (execute function) for 'getContact' tool: forwards params to external endpoint '/get-contact' via callTool helper.
    execute: async (params, { session }) => callTool("/get-contact", params, session),
  • Utility function used by getContact handler to make authenticated HTTP POST request to Clay's external API.
    async function callTool(path, params, session) {
      console.log('Calling tool', path, session)
      return fetch(`https://nexum.clay.earth/tools${path}`, {
        body: JSON.stringify(params),
        headers: {
          Authorization: `ApiKey ${session.apiKey}`,
          "Content-Type": "application/json",
        },
        method: "POST",
      }).then((res) => res.text());
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states it 'gets details' which implies a read-only operation, but doesn't disclose behavioral traits such as authentication requirements, rate limits, error handling (e.g., what happens if the contact_id is invalid), or whether the data is real-time or cached. This is a significant gap for a tool with no annotation coverage.

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 a single, efficient sentence that front-loads the core purpose ('Get details for a contact by id') and adds useful specifics ('including emails, social links, phone numbers, and notes'). There is no wasted verbiage, and every word earns its place in clarifying the tool's function.

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's complexity (a read operation with one parameter), lack of annotations, and no output schema, the description is incomplete. It doesn't explain what the return values look like (e.g., structure of the contact details), error conditions, or any prerequisites. For a tool with no structured support, more context is needed to be fully helpful.

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 input schema has 100% description coverage, with the parameter 'contact_id' clearly documented as 'The ID of the contact to get details for.' The description adds no additional meaning beyond this, such as format examples or constraints. With high schema coverage, the baseline score of 3 is appropriate as the schema does the heavy lifting.

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 clearly states the verb ('Get details') and resource ('for a contact'), specifying what information is retrieved (emails, social links, phone numbers, notes). It distinguishes from siblings like searchContacts (which finds contacts) and createContact (which creates new ones), but doesn't explicitly contrast with getNotes or getEvents which retrieve related but different data.

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 usage when you need details for a specific contact by ID, suggesting an alternative to searchContacts for when you already have the ID. However, it doesn't explicitly state when NOT to use it or provide clear alternatives among siblings like getNotes (which might retrieve notes for a contact) or getEvents (which might retrieve events for a contact).

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

Related 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/clay-inc/clay-mcp'

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