SendGrid
Send transactional and marketing emails via SendGrid's v3 API from any AI agent. 14 tools covering send, templates, stats, suppressions, contacts and marketing lists. Bearer-token auth, EU + Global datacenter support.
7 天免费 · 无需信用卡 · EU 托管
问 SendGrid 任何事
通过 AnythingMCP 对 SendGrid 试一个真实提示 — Claude 调用工具并返回答案。在你的消息上按 Enter 即可在 Cloud 安装。
在 Cloud 上安装 SendGridClaude 是 AI,可能会出错。请核对回答。
2 分钟设置
- 1在 cloud.anythingmcp.com 开始免费试用。
- 2在连接器商店点击 SendGrid。提示时粘贴凭据。
- 3生成 MCP API 密钥,将 AI 客户端指向生成的 MCP URL。
SendGrid 指南
面向主流 AI 客户端的逐步设置。
配置 SendGrid
直接来自连接器定义:在哪里获取凭据、需要哪些权限,以及该适配器调用的是哪个 API。 由连接器作者以英文提供。
This connector uses the SendGrid v3 REST API.
Setup:
- Sign in to SendGrid (or via Twilio's console — SendGrid is part of Twilio since 2019) → Settings → API Keys → Create API Key.
- Pick Restricted Access and grant at least: Mail Send (Full Access), Template Engine (Read), Stats (Read), Suppressions (Read), Marketing > Contacts (Read+Write), Marketing > Lists (Read+Write). Full Access also works but follows least-privilege poorly.
- Copy the key — it's shown ONCE. Set
SENDGRID_API_KEYto it. - (Optional) If your account is on the EU datacenter (GDPR data residency), set
SENDGRID_BASE_URLtohttps://api.eu.sendgrid.com. Default is the globalhttps://api.sendgrid.com.
Authentication: Bearer token (Authorization: Bearer ${SENDGRID_API_KEY}).
Sender authentication first! SendGrid will silently quarantine emails from un-verified senders. Before sending production mail, verify either:
- Single Sender (quick, for low volume): Settings → Sender Authentication → Verify a Single Sender. SendGrid emails a verification link.
- Domain Authentication (recommended for any real volume): Settings → Sender Authentication → Authenticate Your Domain. Adds CNAME records to your DNS.
The
from.emailinsendgrid_send_mailmust match an authenticated sender, otherwise emails will be silently rejected or marked as spam.
Mail send body model: SendGrid uses a message-level + per-recipient model. The personalizations array lets you send N customized versions in one API call (each with its own to, subject, substitutions). For a simple 'send the same email to one person' call, use a single personalization with one to.
Content order matters: when sending both plain-text and HTML, list text/plain BEFORE text/html in the content array per RFC 2046.
Templates (dynamic): SendGrid's modern templates are Dynamic Templates (Handlebars-based). To send one, omit subject/content, set template_id at the message level, and pass dynamic_template_data per personalization. The legacy Transactional Templates use substitutions and are still supported but deprecated.
Categories (≤10 per email, alphanumeric + underscore): tag your sends to group them in Stats. The adapter accepts categories at the top of sendgrid_send_mail.
Suppression precedence: bounces, blocks, invalid emails, spam reports, and unsubscribes all live in the suppression group. Even a perfectly authenticated message to a suppressed address won't deliver. Use sendgrid_list_bounces and remove with sendgrid_delete_bounce (not exposed here — bounce removal must be explicit and is GDPR-sensitive, do it via the SendGrid UI).
Marketing Contacts: contacts are NOT the same as suppression list. The Marketing API (/v3/marketing/contacts) is for the Marketing Campaigns product (newsletters), separate from transactional Mail Send. Adding a contact to Marketing does NOT affect deliverability of transactional mail to that address.
Rate limits: Mail Send caps depend on plan (Essentials: 100k/month; Pro: 1.5M/month, etc.). Burst limits ~600 req/min for transactional, higher with dedicated IPs. On 429, back off.
Webhooks (Event Webhook) out of scope for this connector — host your own receiver to ingest delivery/bounce/open/click events.
Out of scope here: subuser management, IP warmup, A/B testing, single sends, designs, and the legacy Web v2 API.