smartlead_get_ip_details
Retrieve IP blacklist details for specific email campaigns to identify deliverability issues and monitor sender reputation.
Instructions
Get the list of all blacklists per IP for a specific email.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| reply_id | Yes | ID of the email received by the seed account | |
| spam_test_id | Yes | ID of the spam test |
Implementation Reference
- src/handlers/smartDelivery.ts:961-1000 (handler)The core handler function that validates input using isIpDetailsParams, creates a SmartDelivery API client, makes a GET request to retrieve IP details for the specified spam_test_id and reply_id, and returns the JSON response or error.async function handleGetIpDetails( args: unknown, apiClient: AxiosInstance, withRetry: <T>(operation: () => Promise<T>, context: string) => Promise<T> ) { if (!isIpDetailsParams(args)) { throw new McpError( ErrorCode.InvalidParams, 'Invalid arguments for smartlead_get_ip_details' ); } try { const smartDeliveryClient = createSmartDeliveryClient(apiClient); const { spam_test_id, reply_id } = args; const response = await withRetry( async () => smartDeliveryClient.get(`/spam-test/report/${spam_test_id}/sender-account-wise/${reply_id}/ip-details`), 'get IP details' ); return { content: [ { type: 'text', text: JSON.stringify(response.data, null, 2), }, ], isError: false, }; } catch (error: any) { return { content: [{ type: 'text', text: `API Error: ${error.response?.data?.message || error.message}` }], isError: true, }; } }
- src/tools/smartDelivery.ts:460-478 (schema)Tool schema definition with input validation requiring spam_test_id and reply_id integers.export const GET_IP_DETAILS_TOOL: CategoryTool = { name: 'smartlead_get_ip_details', description: 'Get the list of all blacklists per IP for a specific email.', category: ToolCategory.SMART_DELIVERY, inputSchema: { type: 'object', properties: { spam_test_id: { type: 'integer', description: 'ID of the spam test', }, reply_id: { type: 'integer', description: 'ID of the email received by the seed account', }, }, required: ['spam_test_id', 'reply_id'], }, };
- src/index.ts:217-219 (registration)Registration of all smartDeliveryTools (including smartlead_get_ip_details) to the toolRegistry if smartDelivery category is enabled.if (enabledCategories.smartDelivery) { toolRegistry.registerMany(smartDeliveryTools); }
- src/handlers/smartDelivery.ts:104-106 (registration)Dispatcher switch case that routes 'smartlead_get_ip_details' calls to the specific handleGetIpDetails function.case 'smartlead_get_ip_details': { return handleGetIpDetails(args, apiClient, withRetry); }
- src/index.ts:354-355 (registration)Main tool call dispatcher in index.ts that routes SMART_DELIVERY category tools to handleSmartDeliveryTool.case ToolCategory.SMART_DELIVERY: return await handleSmartDeliveryTool(name, toolArgs, apiClient, withRetry);