The MailerSend connector lets your AI agent act in each user's MailerSend account. Each user connects their own MailerSend access token once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 56 tools.
- Tools
- 56
- What they doRead · write · destructive
- 31 · 17 · 831 read17 write8 destructive
- Users sign in with
- Access token
Setup
Install the SDK
Terminal window npm install @scalekit-sdk/node dotenvTerminal window pip install scalekit-sdk-python python-dotenvSet your credentials
Add your Scalekit credentials to your
.envfile. Find values in app.scalekit.com > Developers > API Credentials..env SCALEKIT_ENVIRONMENT_URL=<your-environment-url>SCALEKIT_CLIENT_ID=<your-client-id>SCALEKIT_CLIENT_SECRET=<your-client-secret>Create the MailerSend connection
In AgentKit > Connections, create a MailerSend connection. The name you give it is the
connection_nameyour code passes. See Configure connections.Console steps with screenshots
Register a MailerSend API token with Scalekit so it can call MailerSend on behalf of your users. MailerSend sends the token as a Bearer token. You need a MailerSend account with at least one domain added, because each token is created for a domain.
-
Create a MailerSend API token
- Sign in to MailerSend and go to Developer Tools → API tokens.
- Click Create new token and give it a name, such as
Scalekit. - Select the domain the token is for.
- Set an expiration date. If you leave it empty, MailerSend expires the token after 24 hours.
- Choose the access: Full access, or Custom access with the endpoints your agent uses, such as Email to send and Activity or Analytics to read. A call outside the token’s access fails with
403. - Click Generate token and copy the token. It starts with
mlsn..
See MailerSend’s Managing API tokens for every access option.
-
Create a connection in Scalekit
- In the Scalekit dashboard, go to AgentKit → Connections → Create Connection.
- Search for MailerSend and click Create.
- Note the Connection name. Use it as
connection_namein your code, for examplemailersend.
-
Add a connected account
A connected account links a user ID in your app to a MailerSend API token. Add one in the dashboard to test. In production, each user adds their own through the authorization link: they paste their MailerSend API token on the page it opens.
In the dashboard, to test
- Open the connection and click the Connected Accounts tab → Add account.
- Fill in Your User’s ID and API Token, then click Save.
From your backend, if your app already has the token
For example, when users enter it on a settings page in your app:
import { ConnectorStatus } from '@scalekit-sdk/node'const { connectedAccount } = await scalekit.actions.upsertConnectedAccount({connectionName: 'mailersend',identifier: 'user_123',authorizationDetails: {details: {case: 'staticAuth',value: { details: { token: process.env.USER_MAILERSEND_TOKEN } },},},});console.log(connectedAccount && ConnectorStatus[connectedAccount.status]);response = scalekit_client.actions.upsert_connected_account(connection_name="mailersend",identifier="user_123",authorization_details={"static_auth": {"token": user_mailersend_token}},)print(response.connected_account.status)
-
Authorize a user and make your first call
quickstart.mts import { ScalekitClient } from '@scalekit-sdk/node'import 'dotenv/config'import { createInterface } from 'node:readline/promises'const scalekit = new ScalekitClient(process.env.SCALEKIT_ENVIRONMENT_URL,process.env.SCALEKIT_CLIENT_ID,process.env.SCALEKIT_CLIENT_SECRET,)const actions = scalekit.actionsconst connector = 'mailersend'const identifier = 'user_123'// Generate an authorization link for the userconst { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })console.log('Authorize MailerSend:', link)const rl = createInterface({ input: process.stdin, output: process.stdout })await rl.question('Press Enter after authorizing...')rl.close()// Make your first callconst result = await actions.executeTool({connector,identifier,toolName: 'mailersend_account_get',toolInput: {},})console.log(result)Terminal window npx tsx quickstart.mtsquickstart.py import osfrom scalekit import ScalekitClientfrom dotenv import load_dotenvload_dotenv()scalekit_client = ScalekitClient(env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),client_id=os.getenv("SCALEKIT_CLIENT_ID"),client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),)actions = scalekit_client.actionsconnection_name = "mailersend"identifier = "user_123"# Generate an authorization link for the userlink_response = actions.get_authorization_link(connection_name=connection_name,identifier=identifier,)print("Authorize MailerSend:", link_response.link)input("Press Enter after authorizing...")# Make your first callresult = actions.execute_tool(tool_input={},tool_name="mailersend_account_get",connection_name=connection_name,identifier=identifier,)print(result)Terminal window python quickstart.pyEach user opens the link once and enters their MailerSend credentials there. If your app already has a user's credentials, add the account from your backend instead, as the console steps above show. See Authorize a user for the full flow and statuses.
Tools
Pass the exact name toexecute_toolmailersend_account_getGet the account's plan, email usage, rate limits and resource limits.Read-onlyGet Account
Get the account's plan, email usage, rate limits and resource limits. Returns name, status, plan_type, data_retention_days, emails (sent, received, limit), rate_limits, resources and addons.
Inputs
This tool takes no inputs.
mailersend_activity_listList raw email events (sent, delivered, bounced, opened, clicked, unsubscribed and more) for a domain in a date range.Read-onlyList Email Activity
List raw email events (sent, delivered, bounced, opened, clicked, unsubscribed and more) for a domain in a date range. Returns data, an array of activities with id, type, created_at and the email (from, subject, recipient, status), plus meta and links for paging.
Inputs
date_fromstringrequired- Start of the range: a Unix timestamp, ISO 8601 (2026-11-01T00:00:00Z) or 'YYYY-MM-DD HH:MM:SS', in UTC. Example: 2026-11-01T00:00:00Z
date_tostringrequired- End of the range, in the same formats as date_from; must be later than date_from. Example: 2026-11-13T23:59:59Z
domain_idstringrequired- Domain ID (from mailersend_domains_list) Example: jy7zpl9xqo4l5vx6
eventarray- Only these event types. Example: ["delivered", "hard_bounced"]
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_analytics_by_date_getGet counts of email events per day, week, month or year over a range of up to 183 days.Read-onlyGet Analytics by Date
Get counts of email events per day, week, month or year over a range of up to 183 days. Returns data with date_from, date_to, group_by and stats, an array of buckets with date and a count per requested event. Use mailersend_analytics_opens_by_get for opens by country or email client.
Inputs
date_fromstringrequired- Start of the range: a Unix timestamp, ISO 8601 (2026-11-01T00:00:00Z) or 'YYYY-MM-DD HH:MM:SS', in UTC. Example: 2026-11-01
date_tostringrequired- End of the range, in the same formats as date_from; must be later than date_from (not in the future) Example: 2026-11-13
eventarrayrequired- Events to count. Example: ["sent", "delivered", "opened", "clicked"]
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
group_bystring- Bucket size. Defaults to days. Example: daysone of
daysweeksmonthsyears tagsarray- Only emails with these tags. Example: ["order-shipped"]
mailersend_analytics_opens_by_getGet email opens broken down by recipient country, email client name or client type over a range of up to 183 days.Read-onlyGet Opens by Country or Client
Get email opens broken down by recipient country, email client name or client type over a range of up to 183 days. Returns data with date_from, date_to and stats, an array with name (country code, client or type) and count.
Inputs
date_fromstringrequired- Start of the range: a Unix timestamp, ISO 8601 (2026-11-01T00:00:00Z) or 'YYYY-MM-DD HH:MM:SS', in UTC. Example: 2026-11-01
date_tostringrequired- End of the range, in the same formats as date_from; must be later than date_from (not in the future) Example: 2026-11-13
dimensionstringrequired- Breakdown: country, ua-name (email client name) or ua-type (client type) Example: countryone of
countryua-nameua-type domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
tagsarray- Only emails with these tags. Example: ["order-shipped"]
mailersend_api_quota_getCheck how many API requests remain in the current daily quota.Read-onlyGet API Quota
Check how many API requests remain in the current daily quota. Does not count toward the quota. Returns quota, remaining and reset (when the quota resets).
Inputs
This tool takes no inputs.
mailersend_bulk_email_status_getCheck the progress and result of a bulk email request.Read-onlyGet Bulk Email Status
Check the progress and result of a bulk email request. Returns data with state (queued, processing, completed), total_recipients_count, suppressed_recipients_count, validation_errors_count, messages_id and validation_errors.
Inputs
bulk_email_idstringrequired- Bulk email ID returned by mailersend_bulk_email_send. Example: 614470d1588b866d0454f3e2
mailersend_domain_dns_records_getGet the DNS records (SPF, DKIM, return-path, custom tracking, inbound routing) to publish for a domain.Read-onlyGet Domain DNS Records
Get the DNS records (SPF, DKIM, return-path, custom tracking, inbound routing) to publish for a domain. Returns data with each record's hostname, type, value and status.
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
mailersend_domain_getRetrieve one domain with its verification status and settings.Read-onlyGet Domain
Retrieve one domain with its verification status and settings. Returns data with id, name, dkim, spf, tracking, is_verified, is_dns_active and domain_settings.
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
mailersend_domain_recipients_listList the recipients that have received email from one domain.Read-onlyList Domain Recipients
List the recipients that have received email from one domain. Returns data, an array with id, email, created_at, updated_at and deleted_at, plus meta for paging.
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_domains_listList the sending domains in the account.Read-onlyList Domains
List the sending domains in the account. Returns data, an array with id, name, dkim, spf, tracking, is_verified, is_dns_active, domain_settings and created_at, plus meta for paging. Use this to get a domain_id for other tools.
Inputs
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
verifiedboolean- Only verified (true) or unverified (false) domains. Example: true
mailersend_email_getRetrieve one sent email with its current status and its activity events.Read-onlyGet Email
Retrieve one sent email with its current status and its activity events. Returns data with id, from, subject, status, recipient, tags, created_at and activities (event type and time).
Inputs
email_idstringrequired- Email ID from mailersend_emails_list. Example: 5ee0b166b251345e407c9207
mailersend_emails_listSearch the sending log of one domain: one row per email, filtered by date range, status, interaction, recipient, subject, tag or template.Read-onlyList Emails
Search the sending log of one domain: one row per email, filtered by date range, status, interaction, recipient, subject, tag or template. Returns data, an array of emails with id, from, subject, status, recipient, tags, template_id, created_at and the latest interaction, plus meta and links for paging. Use this to find emails. Use mailersend_email_get for one email's events and mailersend_activity_list for raw events.
Inputs
date_fromstringrequired- Start of the range: a Unix timestamp, ISO 8601 (2026-11-01T00:00:00Z) or 'YYYY-MM-DD HH:MM:SS', in UTC. Example: 2026-11-01 00:00:00
date_tostringrequired- End of the range, in the same formats as date_from; must be later than date_from. Example: 2026-11-13 23:59:59
domain_idstringrequired- Domain ID (from mailersend_domains_list) Example: jy7zpl9xqo4l5vx6
interactionarray- Only emails with these recipient interactions (OR) Example: ["opened"]
limitinteger- Results per page, 10 to 1000. Defaults to 25. Example: 50
message_idstring- Exact message ID. Example: 61487a14608b1d0b4d506633
pageinteger- Page number, 1 to 100. Example: 1
recipient_emailstring- Exact recipient address. Example: jane@example.com
statusarray- Only emails with these statuses (OR) Example: ["delivered"]
subjectstring- Part of the subject (at least 3 characters, case-insensitive) Example: shipped
tagstring- Exact tag. Example: order-shipped
template_idstring- Exact template ID. Example: vywj2lpokkm47oqz
mailersend_identities_listList sender identities (single verified sender addresses), optionally by domain or address.Read-onlyList Sender Identities
List sender identities (single verified sender addresses), optionally by domain or address. Returns data, an array with id, email, name, reply_to_email, reply_to_name, is_verified, resends and domain, plus meta.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
orderstring- Sort direction. Defaults to asc. Example: descone of
ascdesc order_bystring- Sort field. Defaults to created_at. Example: created_atone of
emailcreated_atverified_at pageinteger- Page number to return, starting at 1. Example: 1
querystring- Filter by email address. Example: orders@
mailersend_identity_getRetrieve one sender identity.Read-onlyGet Sender Identity
Retrieve one sender identity. Returns data with id, email, name, reply_to_email, reply_to_name, is_verified and domain.
Inputs
identity_idstringrequired- Sender identity ID. Example: 7z3m5jgrogdpyo6n
mailersend_inbound_route_getRetrieve one inbound route.Read-onlyGet Inbound Route
Retrieve one inbound route. Returns data with id, name, address (the receiving address), domain, enabled, filters, forwards and priority.
Inputs
inbound_idstringrequired- Inbound route ID. Example: vy3j2l1xz8mm97yo
mailersend_inbound_routes_listList inbound routes, which forward received email to addresses or webhooks.Read-onlyList Inbound Routes
List inbound routes, which forward received email to addresses or webhooks. Returns data, an array with id, name, address, domain, enabled, filters, forwards and priority, plus meta.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_message_getRetrieve one message with the emails it produced and their statuses.Read-onlyGet Message
Retrieve one message with the emails it produced and their statuses. Returns data with id, emails (id, from, subject, status, recipient, tags) and domain.
Inputs
message_idstringrequired- Message ID (the X-Message-Id from a send) Example: 5e42957d51f1d94a1070a733
mailersend_messages_listList sent messages (one per send request, which can hold several emails).Read-onlyList Messages
List sent messages (one per send request, which can hold several emails). Returns data, an array with id, created_at and updated_at, plus meta for paging. Use mailersend_message_get for its emails.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_recipient_getRetrieve one recipient with its domain and suppression state.Read-onlyGet Recipient
Retrieve one recipient with its domain and suppression state. Returns data with id, email, created_at, domain, emails, blocklist, hard_bounces, spam_complaints and unsubscribes.
Inputs
recipient_idstringrequired- Recipient ID. Example: 5ee0b174b251345e407c92dc
mailersend_recipients_listList recipients that have received email, optionally for one domain.Read-onlyList Recipients
List recipients that have received email, optionally for one domain. Returns data, an array with id, email, created_at, updated_at and deleted_at, plus meta.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number, 1 to 1000. Example: 1
mailersend_scheduled_message_getRetrieve one scheduled message.Read-onlyGet Scheduled Message
Retrieve one scheduled message. Returns data with message_id, subject, send_at, status, status_message and domain.
Inputs
message_idstringrequired- Message ID of the scheduled send. Example: 61e01c4a2e4b0e6a9f8d4f55
mailersend_scheduled_messages_listList messages scheduled with send_at.Read-onlyList Scheduled Messages
List messages scheduled with send_at. Returns data, an array with message_id, subject, send_at, status (scheduled, sent, error) and status_message, plus meta.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
statusstring- Only scheduled messages with this status. Example: scheduledone of
scheduledsenterror
mailersend_sms_activity_listList SMS delivery events (processed, queued, sent, delivered, failed), optionally by number, date range or status.Read-onlyList SMS Activity
List SMS delivery events (processed, queued, sent, delivered, failed), optionally by number, date range or status. Returns data, an array with from, to, created_at, content, status and sms_message_id, plus meta.
Inputs
date_fromstring- Start of the range: a Unix timestamp, ISO 8601 (2026-11-01T00:00:00Z) or 'YYYY-MM-DD HH:MM:SS', in UTC. Example: 2026-11-01T00:00:00Z
date_tostring- End of the range, in the same formats as date_from; must be later than date_from. Example: 2026-11-13T23:59:59Z
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number, 1 to 1000. Example: 1
sms_number_idstring- Only activity for this phone number ID. Example: 7z3m5jgrogdpyo6n
statusarray- Only these statuses. Example: ["delivered", "failed"]
mailersend_sms_message_getRetrieve one SMS message with its per-recipient deliveries.Read-onlyGet SMS Message
Retrieve one SMS message with its per-recipient deliveries. Returns data with id, from, to, text, paused, created_at and sms (each with status and segment count).
Inputs
sms_message_idstringrequired- SMS message ID. Example: 7z3m5jgrogdpyo6n
mailersend_sms_messages_listList sent SMS messages.Read-onlyList SMS Messages
List sent SMS messages. Returns data, an array with id, from, to, text, paused and created_at, plus meta.
Inputs
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_sms_numbers_listList the SMS phone numbers on the account.Read-onlyList SMS Phone Numbers
List the SMS phone numbers on the account. Returns data, an array with id, telephone_number, paused and created_at, plus meta.
Inputs
limitinteger- Results per page, 10 to 100. Defaults to 15. Example: 15
pageinteger- Page number. Example: 1
pausedboolean- Only paused (true) or active (false) numbers. Example: false
mailersend_suppressions_listList entries on one suppression list: blocklist, hard bounces, spam complaints, unsubscribes or the on-hold list.Read-onlyList Suppressions
List entries on one suppression list: blocklist, hard bounces, spam complaints, unsubscribes or the on-hold list. Returns data, an array of entries (id, recipient or pattern, created_at, and the reason or domain), plus meta for paging.
Inputs
liststringrequired- Suppression list to read. Example: hard-bouncesone of
blocklisthard-bouncesspam-complaintsunsubscribeson-hold-list domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_template_getRetrieve one template with its stats and tags.Read-onlyGet Template
Retrieve one template with its stats and tags. Returns data with id, name, type, image_path, personalization variables, template_stats (total, delivered, opened, clicked) and tags.
Inputs
template_idstringrequired- Template ID. Example: vywj2lpokkm47oqz
mailersend_templates_listList email templates, optionally for one domain.Read-onlyList Templates
List email templates, optionally for one domain. Returns data, an array with id, name, type, image_path and created_at, plus meta for paging.
Inputs
domain_idstring- Domain ID (from mailersend_domains_list); leave empty for all domains. Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_webhook_getRetrieve one webhook.Read-onlyGet Webhook
Retrieve one webhook. Returns data with id, url, events, name, enabled, version, secret (for signature checks) and domain.
Inputs
webhook_idstringrequired- Webhook ID. Example: 2351ndgwr4zqx8ko
mailersend_webhooks_listList the webhooks of a domain.Read-onlyList Webhooks
List the webhooks of a domain. Returns data, an array with id, url, events, name, enabled, version, editable and created_at.
Inputs
domain_idstringrequired- Domain ID (from mailersend_domains_list) Example: jy7zpl9xqo4l5vx6
limitinteger- Results per page, 10 to 100. Defaults to 25. Example: 25
pageinteger- Page number to return, starting at 1. Example: 1
mailersend_blocklist_addBlock sending to specific addresses or to addresses matching patterns.WriteAdd to Blocklist
Block sending to specific addresses or to addresses matching patterns. Returns data, the created blocklist entries with id, type (exact or pattern), pattern and created_at. Use mailersend_suppressions_add for hard bounces, spam complaints or unsubscribes.
Inputs
domain_idstring- Domain ID; leave empty to block for every domain. Example: jy7zpl9xqo4l5vx6
patternsarray- Patterns to block, such as *@example.com. Required unless recipients is set. Example: ["*@spam-domain.example"]
recipientsarray- Email addresses to block. Required unless patterns is set. Example: ["spammer@example.com"]
mailersend_bulk_email_sendQueue up to 500 separate email messages in one asynchronous request.WriteSend Bulk Email
Queue up to 500 separate email messages in one asynchronous request. Returns bulk_email_id and a message; check delivery with mailersend_bulk_email_status_get. Use this for many different messages. Use mailersend_email_send for one message.
Inputs
messagesarrayrequired- Email objects, each with the same fields as a single send: from (email, name), to (email, name), subject, html or text or template_id, and optional personalization, tags, attachments and settings. Example: [{"from": {"email": "orders@example.com"}, "to": [{"email": "jane@example.com"}], "subject": "Hi", "text": "Hello"}]
mailersend_domain_addAdd a sending domain to the account.WriteAdd Domain
Add a sending domain to the account. Returns data with the new domain's id and settings. Next publish its records (mailersend_domain_dns_records_get) and call mailersend_domain_verify.
Inputs
namestringrequired- Domain name, lowercase, not starting with www. Example: mail.example.com
custom_tracking_subdomainstring- Alphanumeric custom tracking subdomain. Example: links
inbound_routing_subdomainstring- Alphanumeric inbound routing subdomain. Example: inbound
return_path_subdomainstring- Alphanumeric return-path subdomain. Example: mta
mailersend_domain_settings_updateChange a domain's sending and tracking settings (pause sending, click/open/content/unsubscribe tracking, custom tracking, precedence bulk).WriteUpdate Domain Settings
Change a domain's sending and tracking settings (pause sending, click/open/content/unsubscribe tracking, custom tracking, precedence bulk). Returns data with the domain and its updated domain_settings.
- Idempotent
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
custom_tracking_enabledboolean- Use the custom tracking subdomain. Example: false
custom_tracking_subdomainstring- Alphanumeric custom tracking subdomain. Example: links
ignore_duplicated_recipientsboolean- Drop duplicate recipients in one send. Example: false
precedence_bulkboolean- Add the Precedence: bulk header. Example: false
send_pausedboolean- Pause all sending from the domain. Example: false
track_clicksboolean- Track clicks. Example: true
track_contentboolean- Keep email content viewable in the dashboard. Example: true
track_opensboolean- Track opens. Example: true
track_unsubscribeboolean- Add an unsubscribe link and track unsubscribes. Example: true
track_unsubscribe_htmlstring- HTML unsubscribe footer; must contain {{unsubscribe}}. Example: <p>Click <a href="{{unsubscribe}}">here</a> to unsubscribe.</p>
track_unsubscribe_html_enabledboolean- Use the HTML unsubscribe footer. Example: true
track_unsubscribe_plainstring- Plain-text unsubscribe footer; must contain {{unsubscribe}}. Example: Unsubscribe: {{unsubscribe}}
track_unsubscribe_plain_enabledboolean- Use the plain-text unsubscribe footer. Example: true
mailersend_domain_verifyCheck a domain's DNS records now and update its verification status.WriteVerify Domain
Check a domain's DNS records now and update its verification status. Returns message and data with dkim, spf, mx, tracking, cname and rp_cname booleans.
- Idempotent
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
mailersend_email_sendSend one email with inline HTML or text, or a MailerSend template, to up to 50 recipients.WriteSend Email
Send one email with inline HTML or text, or a MailerSend template, to up to 50 recipients. Returns 202 Accepted with no body; the message ID is in the X-Message-Id response header (send_at sends return it as well). Use this for a single message. Use mailersend_bulk_email_send for many different messages in one call. Prerequisite: from_email must be on a verified domain (see mailersend_domains_list).
Inputs
toarrayrequired- Recipients, 1 to 50 (1 until the account is approved), each an object with email and an optional name. Example: [{"email": "jane@example.com", "name": "Jane Doe"}]
attachmentsarray- Attachments (25 MB total after decoding), each with filename, content (base64), and optional disposition (attachment or inline) and id (Content-ID for inline images) Example: [{"filename": "invoice.pdf", "content": "JVBERi0xLjQK", "disposition": "attachment"}]
bccarray- BCC recipients (max 10), each with email and optional name. Example: [{"email": "audit@example.com"}]
ccarray- CC recipients (max 10), each with email and optional name. Example: [{"email": "boss@example.com"}]
from_emailstring- Sender email address on a verified domain. Not required when template_id has a default sender. Example: orders@example.com
from_namestring- Sender display name (no < or >) Example: Acme Orders
headersarray- Custom headers (Professional and Enterprise plans), each with name and value. Example: [{"name": "X-Order-ID", "value": "A1001"}]
htmlstring- HTML body (max 2 MB). Provide html, text or template_id. Example: <p>Hi {{name}}, your order shipped.</p>
in_reply_tostring- Message-ID this email replies to (for threading) Example: <abc123@mail.example.com>
languagestring- Language for template translations and unsubscribe text. Example: enone of
deenesfritltnlplpt-BR list_unsubscribestring- List-Unsubscribe header value, RFC 8058 compliant (Professional and Enterprise plans) Example: <mailto:unsubscribe@example.com>
personalizationarray- Per-recipient {{var}} data. Each item has email (one of the to addresses) and data (an object of variable names to values) Example: [{"email": "jane@example.com", "data": {"name": "Jane", "order_id": "A1001"}}]
precedence_bulkboolean- Set the Precedence: bulk header, overriding the domain setting. Example: false
referencesarray- Message-IDs this email references (for threading) Example: ["<abc123@mail.example.com>"]
reply_to_emailstring- Reply-To address. Example: help@example.com
reply_to_namestring- Reply-To display name. Example: Acme Support
send_atinteger- Schedule the send for this Unix timestamp, at most 72 hours ahead. Leave empty to send now. Example: 1794700800
subjectstring- Subject line (max 998 characters). Not required when template_id has a default subject. Supports {{var}} personalization. Example: Your order {{order_id}} has shipped
tagsarray- Up to 5 tags for analytics. Example: ["order-shipped"]
template_idstring- ID of a MailerSend template to use as the content (see mailersend_templates_list) Example: vywj2lpokkm47oqz
textstring- Plain-text body (max 2 MB). Provide html, text or template_id. Example: Hi {{name}}, your order shipped.
track_clicksboolean- Track clicks for this email, overriding the domain setting. Example: true
track_contentboolean- Keep the email content viewable in the dashboard, overriding the domain setting. Example: true
track_opensboolean- Track opens for this email, overriding the domain setting. Example: true
mailersend_email_verifyCheck whether one email address is deliverable.WriteVerify Email Address
Check whether one email address is deliverable. Uses one email verification credit. Returns status, one of valid, catch_all, mailbox_full, role_based, unknown, syntax_error, typo, mailbox_not_found, disposable or mailbox_blocked.
Inputs
emailstringrequired- Address to verify (max 320 characters) Example: jane@example.com
mailersend_identity_createAdd a sender identity on a domain.WriteCreate Sender Identity
Add a sender identity on a domain. MailerSend emails the address a verification link. Returns data with the identity's id, email and is_verified (false until the link is clicked).
Inputs
domain_idstringrequired- Domain ID the address belongs to. Example: jy7zpl9xqo4l5vx6
emailstringrequired- Sender address (max 320 characters, unique per domain) Example: orders@example.com
add_noteboolean- Add personal_note to the verification email. Example: false
namestring- Sender display name. Example: Acme Orders
personal_notestring- Note for the verification email (max 250 characters, no links or addresses) Example: Please confirm so we can send order emails
reply_to_emailstring- Default Reply-To address. Required when reply_to_name is set. Example: help@example.com
reply_to_namestring- Default Reply-To name. Example: Acme Support
mailersend_identity_updateChange a sender identity's name or default Reply-To.WriteUpdate Sender Identity
Change a sender identity's name or default Reply-To. Returns data with the updated identity.
- Idempotent
Inputs
identity_idstringrequired- Sender identity ID. Example: 7z3m5jgrogdpyo6n
add_noteboolean- Add personal_note to the verification email. Example: false
namestring- Sender display name. Example: Acme Orders
personal_notestring- Note for the verification email. Example: Please confirm
reply_to_emailstring- Default Reply-To address. Required when reply_to_name is set. Example: help@example.com
reply_to_namestring- Default Reply-To name. Example: Acme Support
mailersend_inbound_route_createCreate an inbound route that receives email for a domain and forwards it to email addresses or webhook URLs.WriteCreate Inbound Route
Create an inbound route that receives email for a domain and forwards it to email addresses or webhook URLs. Returns data with the route's id and address (the address that receives mail).
Inputs
domain_enabledbooleanrequired- true to receive mail at a custom inbound address on your domain (inbound_domain); false to use the generated MailerSend inbound address. Example: false
domain_idstringrequired- Domain ID the route belongs to. Example: jy7zpl9xqo4l5vx6
forwardsarrayrequired- Where to forward each message (1-5), each with type (email or webhook) and value (an address or URL) Example: [{"type": "webhook", "value": "https://example.com/inbound"}]
match_filterobjectrequired- Which senders to accept: type match_all, match_sender, match_domain or match_header, and for the latter three up to 5 filters with comparer, value and (for headers) key. Example: {"type": "match_all"}
namestringrequired- Route name (max 191 characters) Example: Support inbox
catch_filterobject- Which recipients to catch (required when domain_enabled is true): type catch_all or catch_recipient, and for catch_recipient up to 5 filters, each with a comparer (equal, contains, starts-with, ...) and a value. Example: {"type": "catch_recipient", "filters": [{"comparer": "equal", "value": "support"}]}
catch_typestring- For catch_recipient filters: all filters must match (all) or any one (one). Defaults to all. Example: allone of
allone inbound_domainstring- Custom inbound address domain, ending with your domain name. Required when domain_enabled is true. Example: inbound.example.com
inbound_priorityinteger- Route priority 0-100 (0 runs first), unique per domain. Required when domain_enabled is true. Example: 10
include_attachmentsboolean- Forward attachments. Defaults to true. Example: true
match_typestring- For match filters: all filters must match (all) or any one (one). Defaults to all. Example: allone of
allone
mailersend_inbound_route_updateReplace an inbound route's settings.WriteUpdate Inbound Route
Replace an inbound route's settings. Omitted catch_type and match_type reset to all. Returns data with the updated route.
- Idempotent
Inputs
domain_enabledbooleanrequired- true to receive mail at a custom inbound address on your domain (inbound_domain); false to use the generated MailerSend inbound address. Example: false
forwardsarrayrequired- Where to forward each message (1-5), each with type (email or webhook) and value (an address or URL) Example: [{"type": "webhook", "value": "https://example.com/inbound"}]
inbound_idstringrequired- Inbound route ID. Example: vy3j2l1xz8mm97yo
match_filterobjectrequired- Which senders to accept: type match_all, match_sender, match_domain or match_header, and for the latter three up to 5 filters with comparer, value and (for headers) key. Example: {"type": "match_all"}
namestringrequired- Route name (max 191 characters) Example: Support inbox
catch_filterobject- Which recipients to catch (required when domain_enabled is true): type catch_all or catch_recipient, and for catch_recipient up to 5 filters, each with a comparer (equal, contains, starts-with, ...) and a value. Example: {"type": "catch_recipient", "filters": [{"comparer": "equal", "value": "support"}]}
catch_typestring- For catch_recipient filters: all filters must match (all) or any one (one). Defaults to all. Example: allone of
allone inbound_domainstring- Custom inbound address domain, ending with your domain name. Required when domain_enabled is true. Example: inbound.example.com
inbound_priorityinteger- Route priority 0-100 (0 runs first), unique per domain. Required when domain_enabled is true. Example: 10
include_attachmentsboolean- Forward attachments. Defaults to true. Example: true
match_typestring- For match filters: all filters must match (all) or any one (one). Defaults to all. Example: allone of
allone
mailersend_sms_sendSend an SMS from one of your MailerSend phone numbers to up to 50 US or Canadian numbers.WriteSend SMS
Send an SMS from one of your MailerSend phone numbers to up to 50 US or Canadian numbers. Returns 202 Accepted; the SMS message ID is in the X-SMS-Message-Id response header. Prerequisite: an SMS phone number on the account (see mailersend_sms_numbers_list).
Inputs
fromstringrequired- Your MailerSend phone number, E.164. Example: +18332647501
textstringrequired- Message text (max 2048 characters; ( ) [ ] < > not allowed). Supports {{ var }} personalization. Longer than 160 GSM-7 characters is sent as several segments. Example: Hi {{ name }}, your code is 123456
toarrayrequired- Recipient numbers in E.164 (1-50, US or CA, no duplicates). With a trial number each must be a verified recipient. Example: ["+12065550123"]
personalizationarray- Per-number data for {{ var }}: each item has phone_number (one of to) and data (an object) Example: [{"phone_number": "+12065550123", "data": {"name": "Jane"}}]
mailersend_suppressions_addAdd addresses to the hard-bounce, spam-complaint or unsubscribe list for a domain, so MailerSend stops sending to them.WriteAdd Suppressions
Add addresses to the hard-bounce, spam-complaint or unsubscribe list for a domain, so MailerSend stops sending to them. Returns data, the created entries with id, recipient and created_at.
Inputs
domain_idstringrequired- Domain ID the suppression applies to. Example: jy7zpl9xqo4l5vx6
liststringrequired- Suppression list to add to. Example: unsubscribesone of
hard-bouncesspam-complaintsunsubscribes recipientsarrayrequired- Email addresses to add. Example: ["jane@example.com"]
mailersend_template_createCreate an HTML template.WriteCreate Template
Create an HTML template. Returns data with the new template's id and name. Send with mailersend_email_send template_id.
Inputs
htmlstringrequired- HTML body (max 2 MB). Supports {{var}} personalization. Example: <p>Hi {{name}}, your order {{order_id}} shipped.</p>
textstringrequired- Plain-text body (max 2 MB) Example: Hi {{name}}, your order {{order_id}} shipped.
categoriesarray- Category IDs to assign. Example: ["z86org8wkd4ew13v"]
domain_idstring- Domain ID to attach the template to. Example: jy7zpl9xqo4l5vx6
namestring- Template name (max 50). Defaults to Template. Example: Order shipped
tagsarray- Up to 5 tags. Example: ["orders"]
mailersend_template_updateChange a template's HTML, text, name, domain, categories or tags.WriteUpdate Template
Change a template's HTML, text, name, domain, categories or tags. Returns data with the updated template.
- Idempotent
Inputs
template_idstringrequired- Template ID. Example: vywj2lpokkm47oqz
auto_generateboolean- Generate the text version from the HTML. Example: true
categoriesarray- Category IDs; an empty array removes all. Example: ["z86org8wkd4ew13v"]
domain_idstring- Domain ID to attach the template to. Example: jy7zpl9xqo4l5vx6
htmlstring- New HTML body. Example: <p>Hi {{name}}</p>
namestring- New name (max 50) Example: Order shipped v2
tagsarray- Up to 5 tags. Example: ["orders"]
textstring- New plain-text body. Example: Hi {{name}}
mailersend_webhook_createCreate a webhook that receives email events for a domain.WriteCreate Webhook
Create a webhook that receives email events for a domain. Returns data with the webhook's id, url, events, enabled, version and signing secret.
Inputs
domain_idstringrequired- Domain ID the webhook belongs to. Example: jy7zpl9xqo4l5vx6
eventsarrayrequired- Event types to send. Example: ["activity.delivered", "activity.hard_bounced"]
namestringrequired- Webhook name (max 50) Example: Delivery events
urlstringrequired- Public HTTPS URL that receives events (max 191, unique) Example: https://example.com/mailersend/webhook
enabledboolean- Turn the webhook on. Defaults to true. Example: true
versioninteger- Payload version: 2 (recommended) or 1 (deprecated, stops December 1, 2026). Defaults to 1. Example: 2one of
12
mailersend_webhook_updateChange a webhook's URL, name, events, status or payload version.WriteUpdate Webhook
Change a webhook's URL, name, events, status or payload version. Returns data with the updated webhook.
- Idempotent
Inputs
webhook_idstringrequired- Webhook ID. Example: 2351ndgwr4zqx8ko
enabledboolean- Turn the webhook on or off. Example: false
eventsarray- Event types to send. Example: ["activity.delivered"]
namestring- New name. Example: Delivery events
urlstring- New URL. Example: https://example.com/mailersend/webhook
versioninteger- Payload version (2 cannot go back to 1) Example: 2one of
12
mailersend_domain_deleteDelete a sending domain.DestructiveDelete Domain
Delete a sending domain. Returns no content (204).
- Idempotent
Inputs
domain_idstringrequired- Domain ID. Example: jy7zpl9xqo4l5vx6
mailersend_identity_deleteDelete a sender identity.DestructiveDelete Sender Identity
Delete a sender identity. Returns no content (204).
- Idempotent
Inputs
identity_idstringrequired- Sender identity ID. Example: 7z3m5jgrogdpyo6n
mailersend_inbound_route_deleteDelete an inbound route.DestructiveDelete Inbound Route
Delete an inbound route. Returns no content (204).
- Idempotent
Inputs
inbound_idstringrequired- Inbound route ID. Example: vy3j2l1xz8mm97yo
mailersend_recipient_deleteDelete a recipient record.DestructiveDelete Recipient
Delete a recipient record. Returns no content (204).
- Idempotent
Inputs
recipient_idstringrequired- Recipient ID. Example: 5ee0b174b251345e407c92dc
mailersend_scheduled_message_deleteCancel a scheduled message, up to 10 minutes before its send time.DestructiveCancel Scheduled Message
Cancel a scheduled message, up to 10 minutes before its send time. Returns no content (204).
- Idempotent
Inputs
message_idstringrequired- Message ID of the scheduled send. Example: 61e01c4a2e4b0e6a9f8d4f55
mailersend_suppressions_deleteRemove entries from a suppression list by ID, or clear the whole list.DestructiveDelete Suppressions
Remove entries from a suppression list by ID, or clear the whole list. Returns no content (204).
- Idempotent
Inputs
liststringrequired- Suppression list to delete from. Example: unsubscribesone of
blocklisthard-bouncesspam-complaintsunsubscribeson-hold-list allboolean- true removes every entry on the list. Required unless ids is set. Example: false
domain_idstring- Domain ID; required with all to clear one domain's list. Example: jy7zpl9xqo4l5vx6
idsarray- Entry IDs to remove. Required unless all is true. Example: ["5e42957d51f1d94a1070a733"]
mailersend_template_deleteDelete a template.DestructiveDelete Template
Delete a template. Returns no content (204).
- Idempotent
Inputs
template_idstringrequired- Template ID. Example: vywj2lpokkm47oqz
mailersend_webhook_deleteDelete a webhook.DestructiveDelete Webhook
Delete a webhook. Returns no content (204).
- Idempotent
Inputs
webhook_idstringrequired- Webhook ID. Example: 2351ndgwr4zqx8ko
No tools match.