Skip to main content
Glama
bhoggard

SendGrid MCP Server

by bhoggard

SendGrid MCP Server

Сервер Python MCP (Model Context Protocol), который позволяет ИИ-ассистенту отправлять электронные письма и управлять контактами через Web API v3 сервиса SendGrid.

Tools

Tool

Description

send_email

Отправить простое/HTML-письмо одному или нескольким получателям

get_template_info

Просмотреть структуру динамического шаблона

send_template_email

Отправить через динамический шаблон с данными подстановки

add_contact

Добавить/обновить маркетинговый контакт (обрабатывается асинхронно SendGrid)

search_contacts

Поиск контактов с ограниченным запросом SGQL

get_contact_lists

Список именованных списков маркетинговых контактов

authenticate_domain

Начать аутентификацию домена для нового домена отправки, возвращает DNS-записи для добавления

list_domain_authentications

Список доменов и их статус проверки

validate_domain_authentication

Повторная проверка DNS после добавления записей

delete_domain_authentication

Удалить аутентификацию домена

Setup

  1. Создайте виртуальное окружение и установите зависимости:

    python -m venv venv
    source venv/bin/activate   # Windows: venv\Scripts\activate
    pip install -r requirements.txt
  2. Скопируйте .env.example в .env и укажите ваш API-ключ SendGrid (Settings > API Keys в панели управления SendGrid) и отправителя по умолчанию:

    cp .env.example .env
  3. Проверьте ваш адрес отправителя в разделе Settings > Sender Authentication в SendGrid перед отправкой — непроверенные отправители будут отклонены.

  4. (Необязательно) Создайте динамический шаблон в разделе Email API > Dynamic Templates и укажите DEFAULT_TEMPLATE_ID в .env.

Running

python main.py

Это запускает сервер через stdio — транспорт, который ожидают MCP-клиенты, такие как Claude Desktop, для локального подпроцесса.

Verifying it works

python smoke_test.py

Выводит список зарегистрированных инструментов и выполняет один реальный вызов к вашему аккаунту SendGrid. Для интерактивного просмотра схемы/инструментов:

npx @modelcontextprotocol/inspector python main.py

Connecting to Claude Desktop

Добавьте в claude_desktop_config.json:

{
  "mcpServers": {
    "sendgrid-mcp": {
      "command": "python",
      "args": ["/path/to/twilio-sendgrid-mcp/main.py"],
      "cwd": "/path/to/twilio-sendgrid-mcp",
      "env": {
        "SENDGRID_API_KEY": "SG.your-actual-api-key-here"
      }
    }
  }
}

После этого перезапустите Claude Desktop. Если вызов инструмента завершится ошибкой, проверьте ~/Library/Logs/Claude/mcp*.log (macOS) для вывода stderr сервера.

-
license - not tested
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

  • Email for AI agents: send mail, manage contacts, automations & webhooks. Zero-DNS first send.

  • Email for AI agents — send, receive as a webhook, manage domains, templates, routing.

  • Send transactional email, run campaigns, manage contacts and automations, audit deliverability.

View all MCP Connectors

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/bhoggard/twilio-sendgrid-mcp'

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