Elastic Email MCP server for AI agents

Live

API KEY

EMAIL MARKETING

Marketing

Elastic Email gives your agent email marketing and sending: send and verify emails, run campaigns, manage contacts, lists, segments, and templates, and review delivery events, statistics, and suppressions.

  • Per-user credentials: each call uses the actual user's API key, never a shared bot.
  • Encrypted per-tenant vault: AES-256, resolved at request time, never in LLM context.
  • Scoped before every call: pre-call scope check, 90-day SIEM-exportable audit chain.
Elastic Email
agent · Acme Q3
Run
How did the spring sale campaign do?
S
elasticemail_campaign_stats_get
149ms
Email marketing agent
The spring sale campaign delivered 4,820 emails with a 38% open rate and a 4.1% click rate.
Sources: Elastic Email campaign statistics
elasticemail
1 campaign
18:29
Message Claude...

Tools your email marketing agent reaches for on Elastic Email, scoped per user.

CALL ANY TOOL
60 tools for email marketing in Elastic Email: send and verify email, manage campaigns, contacts, lists, segments, and templates, and read events, statistics, and suppressions.
elasticemail_account_get
Get account
Get public information about the Elastic Email account that owns the API key. Returns the account's Identity, Profile, Branding, Usage, Billing, Sending and Features sections. Use elasticemail_account_get to confirm which account the key belongs to.
Parameters
Name
Type
Required
Description
—
No parameters required
elasticemail_automation_trigger
Trigger automation
elasticemail_campaign_create
Create campaign
elasticemail_campaign_delete
Delete campaign
elasticemail_campaign_pause
Pause campaign
elasticemail_campaign_stats_get
Get campaign stats
elasticemail_campaign_stats_list
List campaign stats
elasticemail_campaign_update
Update campaign
elasticemail_channel_events_list
List channel events
elasticemail_contact_delete
Delete contact
elasticemail_contact_get
Get contact
elasticemail_contacts_add
Add contacts
elasticemail_contacts_list
List contacts
elasticemail_email_mergefile_send
Send email mergefile
elasticemail_email_send
Send email
elasticemail_email_status_get
Get email status
elasticemail_email_verify
Verify email
elasticemail_list_contacts_add
Add list contacts
elasticemail_list_contacts_remove
Remove list contacts
elasticemail_list_get
Get list
elasticemail_lists_list
List lists
elasticemail_segment_create
Create segment
elasticemail_segment_delete
Delete segment
elasticemail_segment_update
Update segment
elasticemail_statistics_get
Get statistics
elasticemail_suppression_complaints_add
Add suppression complaints
elasticemail_suppression_complaints_list
List suppression complaints
elasticemail_suppressions_list
List suppressions
elasticemail_template_delete
Delete template
elasticemail_template_get
Get template

For more tools, view docs.

Build your Agent
Same auth pattern across LangChain, OpenAI, Anthropic, and Google ADK.
Python · LlamaIndex
import { ScalekitClient } from "@scalekit-sdk/node";
import { createReactAgent } from "@langchain/langgraph/prebuilt";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

// Elastic Email tools scoped to this user
const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["elasticemail"], toolNames: [
    "elasticemail_contacts_add",
    "elasticemail_campaign_create",
    "elasticemail_campaign_stats_get"] },
  pageSize: 100,
});

const agent = createReactAgent({ llm, tools });
await agent.invoke({ messages: [{ role: "user", content: "Add these contacts to my newsletter list, create a campaign for them, and report its stats tomorrow" }] });
import OpenAI from "openai";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const openai = new OpenAI();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["elasticemail"] }, pageSize: 100,
});

const res = await openai.chat.completions.create({
  model: "gpt-5",
  messages: [{ role: "user", content: "Add these contacts to my newsletter list, create a campaign for them, and report its stats tomorrow" }],
  tools,
});

// Execute the tool call with the user's vaulted Elastic Email API key
await sk.tools.executeTool(res.choices[0].message.tool_calls[0], "user_123");
import Anthropic from "@anthropic-ai/sdk";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const anthropic = new Anthropic();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["elasticemail"] }, pageSize: 100,
});

const msg = await anthropic.messages.create({
  model: "claude-sonnet-5",
  max_tokens: 1024,
  messages: [{ role: "user", content: "Add these contacts to my newsletter list, create a campaign for them, and report its stats tomorrow" }],
  tools,
});

// Tool call runs with the user's vaulted Elastic Email API key
await sk.tools.executeTool(msg.content, "user_123");
import { Agent } from "@google/adk/agents";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["elasticemail"] }, pageSize: 100,
});

const agent = new Agent({
  name: "email_marketing_agent",
  model: "gemini-2.5-pro",
  instruction: "Elastic Email tools scoped to this user",
  tools,
});

await agent.run("Add these contacts to my newsletter list, create a campaign for them, and report its stats tomorrow");
Try these prompts
Copy any prompt into your agent. Each maps directly to a Elastic Email tool. Click to copy, paste into your agent, done.
Campaigns and sends
Copy the prompt
Copied
List my campaigns and show the stats for the latest one.
Copy the prompt
Copied
Send this email to these 3 recipients.
Copy the prompt
Copied
Pause the campaign that is still sending.
Contacts and lists
Copy the prompt
Copied
Add these 200 contacts to my newsletter list.
Copy the prompt
Copied
Create a segment of contacts who opened in the last 30 days.
Copy the prompt
Copied
Export my contacts to a downloadable file.
Deliverability
Copy the prompt
Copied
Show delivery events for this transaction ID.
Copy the prompt
Copied
List the addresses on my bounces suppression list.
Copy the prompt
Copied
Verify this email address before I add it.
SEE HOW AUTH WORKS
Each user connects their own Elastic Email API key once, and Scalekit sends it with every call. Keys stay vaulted, every call is scope checked, and every action is logged.
1
Authorize
Your user connects
Elastic Email
once. We tie it to their identity and the access they approved, with no shared bot account and no org-wide access
Who:
user ‘A’
when:
Once per user
access:
Limited to user
2
Store
Their
Elastic Email
credential lives in a vault scoped to them. User A's data is never reachable by an agent acting for user B, even on the same connection
vault:
encrypted
scope:
per-user
tenants:
isolated
3
Resolve
When your agent calls a
Elastic Email
tool, we fetch the right credential server-side. It never touches your agent, never appears in the LLM context, never shows up in your logs
speed:
~40ms
check:
before every call
seen by:
nobody
4
Audit
Every
Elastic Email
tool call is logged: who triggered it, which tool ran, what came back. 90 days of history, tied to the user who authorized it
history:
90 days
export:
SIEM-ready
logged:
every call
Test other agents
See the same per-user auth pattern across other marketing and communication connectors.
GTM and RevOps Teams
Outbound prospecting agent
Searches Apollo for prospects matching your ICP, scores and ranks them, drafts personalized outreach in Gmail, and logs every send to Google Sheets. Mail goes out as the rep, not from a shared inbox.
Test other agents
See the same per-user auth pattern across other marketing and communication connectors.
SALES
Outbound prospecting agent
Search Apollo for ICP matches, rank them, draft personalised Gmail outreach, and log every send to Google Sheets.
Why Scalekit
Secure your agent's access. Connectors ship in minutes
01.
Shared tokens break per-user analytics
A shared Elastic Email API key looks fine in a demo. In production every email send and campaign change looks like one service account, and you cannot tell which user triggered it. Scalekit resolves the credential of the actual user who triggered the agent, never a shared bot.
// shared key
audit → bot_service_account

// scalekit
audit → user_abc ✓
02.
Authentication is not authorization
03.
Multi-tenancy is architectural
04.
Elastic Email today. Ten connectors tomorrow.
“Our agents act across Salesforce, Gong, Google Drive, and more, on behalf of every customer. Scalekit behind the scenes meant we can keep adding tools without ever rebuilding how credentials or tool calling work.”
Venu Madhav Kattagoni
Head of Engineering / Von
FAQs
Frequently Asked Questions
Does the agent access Elastic Email as the user or through a shared key?
As the user. Each user connects their own Elastic Email API key once, and Scalekit sends it with every call. Audit logs attribute every send, campaign change, and delete to that user, not a shared service account.
Where is the Elastic Email API key stored?
In Scalekit's managed AES-256 token vault, namespaced per tenant. To rotate it, the user reconnects with a new API key. Revocation is a single dashboard action. Credentials never appear in prompts, logs, or LLM context.
Can I limit what the agent does in Elastic Email?
Yes. Filter by tool name in listScopedTools to expose only what you want, for example the list, get, and statistics tools without elasticemail_email_send, elasticemail_campaign_delete, or elasticemail_contacts_delete. Scalekit also enforces scope checks before every API call.
What happens when a user revokes Elastic Email access?
The connection is invalidated on the next tool call. Subsequent requests for that user fail closed with a clear error. Other users in the tenant remain unaffected. The event is logged for audit.
Can the agent send transactional email in Elastic Email?
Yes. elasticemail_email_transactional_send sends one email to To, CC, and BCC recipients, and elasticemail_email_send sends a copy to each recipient. elasticemail_email_status_get then reports the delivery status by transaction ID.
Start in your coding agent
Up and running in one command
Install the Scalekit skill in your editor of choice. Connector, auth, tools, prompt, all wired up
Claude Code REPL
/plugin marketplace add scalekit-inc/claude-code-authstack
/plugin install agentkit@scalekit-auth-stack
Cursor Code REPL
# ~/.cursor/mcp.json
{
""mcpServers"": {
""elasticemail"": {
""url"": ""https://mcp.scalekit.com/elasticemail"",
""headers"": { ""Authorization"": ""Bearer $SCALEKIT_TOKEN"" }
}
}
}
Codex Code REPL
# ~/.codex/config.toml
[mcp_servers.elasticemail]
url = ""https://mcp.scalekit.com/elasticemail""
auth_env = ""SCALEKIT_TOKEN""
Copilot Code REPL
# .vscode/mcp.json
{
""servers"": {
""elasticemail"": {
""url"": ""https://mcp.scalekit.com/elasticemail"",
""type"": ""http""
}
}
}