Skip to main content
Glama
Meerkats-Ai

Hatch MCP Server

by Meerkats-Ai

hatch_find_phone

Extract phone numbers from LinkedIn profiles to connect with professionals using their profile URL.

Instructions

Find a phone number using LinkedIn profile URL.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
linkedInUrlYesLinkedIn profile URL of the person

Implementation Reference

  • Handler for the hatch_find_phone tool: validates arguments using isFindPhoneParams type guard, calls the Hatch API endpoint '/v1/findPhone' with retry logic, returns the JSON response or an error message.
    case 'hatch_find_phone': {
      if (!isFindPhoneParams(args)) {
        throw new McpError(
          ErrorCode.InvalidParams,
          'Invalid arguments for hatch_find_phone'
        );
      }
    
      try {
        const response = await withRetry(
          async () => apiClient.post('/v1/findPhone', args),
          'find phone'
        );
    
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(response.data, null, 2),
            },
          ],
          isError: false,
        };
      } catch (error) {
        const errorMessage = axios.isAxiosError(error)
          ? `API Error: ${error.response?.data?.message || error.message}`
          : `Error: ${error instanceof Error ? error.message : String(error)}`;
    
        return {
          content: [{ type: 'text', text: errorMessage }],
          isError: true,
        };
      }
    }
  • Input schema and metadata definition for the hatch_find_phone tool, specifying the required 'linkedInUrl' parameter.
    const FIND_PHONE_TOOL: Tool = {
      name: 'hatch_find_phone',
      description: 'Find a phone number using LinkedIn profile URL.',
      inputSchema: {
        type: 'object',
        properties: {
          linkedInUrl: {
            type: 'string',
            description: 'LinkedIn profile URL of the person',
          },
        },
        required: ['linkedInUrl'],
      },
    };
  • src/index.ts:312-320 (registration)
    Tool registration via the ListToolsRequestSchema handler, which advertises the hatch_find_phone tool among others.
    server.setRequestHandler(ListToolsRequestSchema, async () => ({
      tools: [
        FIND_EMAIL_TOOL,
        FIND_PHONE_TOOL,
        VERIFY_EMAIL_TOOL,
        FIND_COMPANY_DATA_TOOL,
        GET_LINKEDIN_URL_TOOL,
      ],
    }));
  • Type guard function to validate that tool arguments match the expected FindPhoneParams shape for hatch_find_phone.
    function isFindPhoneParams(args: unknown): args is FindPhoneParams {
      return (
        typeof args === 'object' &&
        args !== null &&
        'linkedInUrl' in args &&
        typeof (args as { linkedInUrl: unknown }).linkedInUrl === 'string'
      );
    }
  • TypeScript interface defining the input parameters for the hatch_find_phone tool.
    interface FindPhoneParams {
      linkedInUrl: string;
    }
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 of behavioral disclosure. It states the tool's purpose but lacks details on behavioral traits like rate limits, authentication needs, data sources, or what happens if the phone number is not found, leaving significant 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 a single, clear sentence that directly states the tool's purpose without unnecessary words, making it appropriately sized and front-loaded for quick understanding.

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 no annotations and no output schema, the description is incomplete. It does not explain what the tool returns (e.g., phone number format, error handling), behavioral aspects like rate limits, or usage context, which are critical for an agent to use it effectively.

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 'linkedInUrl' documented as 'LinkedIn profile URL of the person'. The description adds no additional meaning beyond this, such as URL format examples or validation rules, so it meets the baseline for high schema coverage.

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 specific action ('Find a phone number') and the resource used ('using LinkedIn profile URL'), distinguishing it from sibling tools like hatch_find_email or hatch_get_linkedin_url by focusing on phone number retrieval rather than email or URL fetching.

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?

The description provides no guidance on when to use this tool versus alternatives, such as hatch_find_email for email retrieval or hatch_get_linkedin_url for URL fetching, nor does it mention any prerequisites or exclusions for its use.

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/Meerkats-Ai/hatch-mcp-server'

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