list_single_sends
Retrieve all single sends from your SendGrid account to view and manage email campaigns.
Instructions
List all single sends in your SendGrid account
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/index.ts:539-551 (handler)The handler logic for the 'list_single_sends' tool call. It invokes the SendGridService.listSingleSends() method and returns a formatted JSON response containing id, name, status, and send_at for each single send.case 'list_single_sends': const allSingleSends = await service.listSingleSends(); return { content: [{ type: 'text', text: JSON.stringify(allSingleSends.map((s: SendGridSingleSend) => ({ id: s.id, name: s.name, status: s.status, send_at: s.send_at })), null, 2) }] };
- src/tools/index.ts:347-351 (schema)Input schema for the 'list_single_sends' tool, which requires no parameters.inputSchema: { type: 'object', properties: {}, required: [] }
- src/tools/index.ts:344-352 (registration)Registration of the 'list_single_sends' tool in the getToolDefinitions array, including name, description, and schema.{ name: 'list_single_sends', description: 'List all single sends in your SendGrid account', inputSchema: { type: 'object', properties: {}, required: [] } },
- src/services/sendgrid.ts:294-300 (helper)Helper method in SendGridService that performs the actual API call to list all single sends from SendGrid.async listSingleSends(): Promise<SendGridSingleSend[]> { const [response] = await this.client.request({ method: 'GET', url: '/v3/marketing/singlesends' }); return (response.body as { result: SendGridSingleSend[] }).result || []; }