Skip to main content
Glama

hatch_verify_email

Check email address validity and activity to confirm contact information accuracy.

Instructions

Verify if an email address is valid and active.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
emailYesEmail address to verify

Implementation Reference

  • The main handler logic for the 'hatch_verify_email' tool within the CallToolRequestSchema switch statement. It validates input using isVerifyEmailParams, makes an API call to '/v1/verifyEmail' with retry logic, and returns the JSON response or an error message.
    case 'hatch_verify_email': { if (!isVerifyEmailParams(args)) { throw new McpError( ErrorCode.InvalidParams, 'Invalid arguments for hatch_verify_email' ); } try { const response = await withRetry( async () => apiClient.post('/v1/verifyEmail', args), 'verify email' ); 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, }; } }
  • Tool schema definition for 'hatch_verify_email', including name, description, and inputSchema specifying the required 'email' string parameter.
    const VERIFY_EMAIL_TOOL: Tool = { name: 'hatch_verify_email', description: 'Verify if an email address is valid and active.', inputSchema: { type: 'object', properties: { email: { type: 'string', description: 'Email address to verify', }, }, required: ['email'], }, };
  • src/index.ts:312-320 (registration)
    Registration of the 'hatch_verify_email' tool (as VERIFY_EMAIL_TOOL) in the list of available tools returned by ListToolsRequestSchema handler.
    server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: [ FIND_EMAIL_TOOL, FIND_PHONE_TOOL, VERIFY_EMAIL_TOOL, FIND_COMPANY_DATA_TOOL, GET_LINKEDIN_URL_TOOL, ], }));
  • Type guard helper function to validate input arguments for the 'hatch_verify_email' tool, ensuring 'email' is a string.
    function isVerifyEmailParams(args: unknown): args is VerifyEmailParams { return ( typeof args === 'object' && args !== null && 'email' in args && typeof (args as { email: unknown }).email === 'string' ); }

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