Email marketing platform
MailerLite logo

MailerLite API + MCP (2026): Marketing v2 + MailerSend MCP for Transactional

MailerLite’s API story is a two-part answer. For marketing operations (subscribers, campaigns, automations, forms) you use the MailerLite API v2 at connect.mailerlite.com/api — stable since 2022, 5 official SDKs, generous 120 req/min rate limit. For transactional email operations (send, templates, webhooks, delivery tracking) you route to MailerLite’s companion product MailerSend, which ships an official MCP server BETA at mcp.mailersend.com/mcp. Single sign-on links both accounts, so you can operate the marketing + transactional split from one login. This tab inventories both surfaces and the MCP capabilities a buyer needs to evaluate before committing.

At a glance

v2
Current Marketing API
Classic v1 still supported at developers-classic
5
Official SDKs
PHP, Go, Node.js, Python, Ruby
1
MCP server (via MailerSend)
BETA, hosted HTTP, wide tool coverage

MCP integration in 2026

Model Context Protocol is the emerging standard for connecting LLM agents to external tools. MailerLite’s MCP story splits: no official MCP for the Marketing API (yet), but its companion transactional product MailerSend ships a hosted MCP server in BETA that covers the transactional email surface plus SMS.

MailerSend ships an official MCP server (BETA) — hosted, HTTP transport

The MailerSend MCP Server is hosted at mcp.mailersend.com/mcp and speaks HTTP transport (aligned with the Model Context Protocol 2026-07-28 spec). Coverage is unusually wide for a BETA: email send + bulk send + status tracking, domains, SMTP config, templates, webhooks, inbound routing, recipient/suppression management, analytics, activity logs, email verification, DMARC and blocklist monitoring, token/user management, plus full SMS operations. Compatible with Claude Desktop / Claude web / Claude Code, Gemini CLI, VSCode, Cursor, and ChatGPT (Pro/Plus in beta).

Available MCP servers for MailerLite + MailerSend

Three ways to reach the MailerLite ecosystem from an AI agent as of August 2026, ordered by maturity. Only one is first-party.

Why the split: MailerLite Marketing vs MailerSend transactional. MailerLite intentionally separates marketing (broadcasts, newsletters, automations) from transactional (order confirmations, password resets, receipts). Each product has its own optimized infrastructure, deliverability profile, and pricing model. MCP follows the same split: MailerSend has the MCP server for transactional; the MailerLite Marketing API + native Claude/ChatGPT integrations cover marketing.

Marketing API v2 essentials

The MailerLite API v2 follows REST conventions with clean JSON payloads and predictable pagination. Scope covers everything you can do in the MailerLite UI plus a few developer-only endpoints (batching, webhooks).

Base URLhttps://connect.mailerlite.com/api
Response formatJSON only
Version pinningOptional X-Version header (date format); defaults to latest
AuthenticationBearer token: Authorization: Bearer YOUR_API_KEY
General rate limit120 requests per minute
Import rate limit5 requests per minute (batch upserts + subscriber imports)
Standard HTTP codes200, 201, 202, 204, 400, 401, 403, 404, 422, 429, 5xx
Classic API v1Still supported at developers-classic.mailerlite.com — use v2 for new work
Batching endpointYes — execute multiple operations in one request
WebhooksConfigurable events (subscribe, unsubscribe, bounce, complaint, campaign sent)

API v2 is the current focus. Classic v1 remains available for legacy integrations that have not migrated, but new development should target v2. The migration path from v1 to v2 is documented but not zero-effort (endpoint paths and response shapes changed).

Authentication methods

Single mechanism, straightforward setup.

Bearer token (API key)

Generate an API key under Integrations › API in the MailerLite UI. Send it in the Authorization header on every request:

Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Accept: application/json

API keys are account-scoped and inherit the permission set of the user who created them. There is no granular scope system (no “read-only” or “campaigns-only” tokens). To limit blast radius of a leaked token, best practice is to generate per-integration keys and revoke individually when unused.

Permission scope caveat. Like most ESP APIs, MailerLite tokens do not have granular scopes. A token can do anything the account allows: read subscribers, send campaigns, delete audiences. If you need finer-grained access (e.g., a token for a third-party integration that should not send campaigns), the only workaround is careful key rotation and integration isolation. MailerLite has not signaled scoped tokens on their public roadmap as of 2026.

Rate limits

LimitValueNotes
General requests120 per minuteApplies to most GET, POST, PATCH, DELETE operations. Enforced per API key.
Import operations5 per minuteBatch subscriber imports and batch upserts have a separate, much stricter throttle.
Response on exceedHTTP 429Too Many Requests. Implement exponential backoff. Standard Retry-After header may be present.
Batch endpointAvailableExecute multiple operations in a single HTTP request to reduce per-call overhead.
Webhook payload sizeNot disclosedStandard SaaS webhook conventions apply. Test with your endpoint.

The 120 req/min general ceiling is generous for interactive dashboards and low-volume automation. The 5 req/min import ceiling catches teams off guard when migrating large subscriber lists — use the batch endpoint with large payloads instead of looping single-add calls. For genuinely high-volume operations (>10K subscribers/minute processing), reach out to MailerLite support to discuss dedicated infrastructure options.

Official SDKs

Five official client libraries for the Marketing API v2. All maintained by MailerLite.

LanguagePackageInstallRepo
PHPmailerlite/mailerlite-api-v2-php-sdkcomposer requireGitHub
Node.js@mailerlite/mailerlite-nodejsnpm installGitHub
Pythonmailerlitepip install mailerliteGitHub
Rubymailerlite-rubygem install mailerlite-rubyGitHub
Gogithub.com/mailerlite/mailerlite-gogo getGitHub

No official .NET, Java, or Rust SDKs. Community wrappers exist for .NET; teams building in Java or Rust typically call the API directly with their language’s standard HTTP client. For AI-agent access via natural language, the native Claude integration and ChatGPT integration cover most operational asks without writing code.

Endpoints reference

The endpoint groups you will actually use in production. Full reference at developers.mailerlite.com/docs.

ResourceHTTP methodsDescription
Subscribers
/subscribers
GET, POST, PUT, DELETEFull CRUD on subscribers. Bulk operations via batch endpoint.
Groups
/groups
GET, POST, PATCH, DELETEManage subscriber groups (equivalent to Mailchimp lists). Add/remove members.
Segments
/segments
GETRead dynamic segments defined in the UI. Segments are UI-managed, not API-created.
Fields
/fields
GET, POST, PATCH, DELETECustom subscriber fields (name, phone, custom text/number/date/boolean).
Campaigns
/campaigns
GET, POST, PUT, DELETEFull CRUD on campaigns. Schedule, cancel, get reports.
Automations
/automations
GET, PATCHList automations, activate/deactivate, view subscriber activity. Automation creation is UI-only.
Forms
/forms
GET, POST, PATCH, DELETESignup forms, popups, embedded forms. Manage and retrieve submissions.
Webhooks
/webhooks
GET, POST, PUT, DELETEConfigure webhooks for subscribe/unsubscribe/bounce/complaint/campaign-sent events.
Batching
/batch
POSTExecute multiple API operations in a single request. Recommended for imports and bulk updates.
Ecommerce (shops)
/ecommerce/shops
GET, POST, PATCH, DELETEManage shop metadata. Foundation for ecommerce integrations (Shopify, WooCommerce sync).
Ecommerce (carts / products / orders)
/ecommerce/{shop_id}/*
GET, POST, PATCH, DELETEFull ecommerce primitives: carts (for abandoned-cart flows), products, orders, customers, categories.

Code examples

Two representative snippets covering the most common first-day tasks: add a subscriber, then send a campaign to a group.

Node.js: add or update a subscriber

const MailerLite = require('@mailerlite/mailerlite-nodejs').default;

const mailerlite = new MailerLite({ api_key: 'YOUR_API_KEY' });

const params = {
  email: 'subscriber@example.com',
  fields: {
    name: 'Alaa',
    last_name: 'Touil'
  },
  groups: ['GROUP_ID_HERE'],
  status: 'active'
};

mailerlite.subscribers.createOrUpdate(params)
  .then(response => {
    console.log('Subscriber upserted:', response.data.data.id);
  })
  .catch(error => {
    console.error('Error:', error.response?.data || error.message);
  });

Python: create and send a campaign

from mailerlite import Client

client = Client({'api_key': 'YOUR_API_KEY'})

# 1. Create the campaign
campaign = client.campaigns.create({
    'name': 'Weekly Newsletter',
    'type': 'regular',
    'emails': [{
        'subject': 'Test from the API',
        'from_name': 'SMTPedia',
        'from': 'hello@smtpedia.com',
        'content': '<h1>Hello</h1><p>This is a test.</p>'
    }],
    'groups': ['GROUP_ID_HERE']
})

# 2. Schedule immediate delivery
client.campaigns.schedule(
    campaign_id=campaign['data']['id'],
    delivery='instant'
)

print(f"Campaign {campaign['data']['id']} scheduled")

Common gotchas

Marketing API cannot send transactional emails — use MailerSend

The MailerLite Marketing API v2 is for broadcasts and automations only. There is no POST /email/send equivalent for triggered transactional messages (order confirmations, password resets). For that you use MailerSend at developers.mailersend.com. Different API keys, different rate limits, different pricing. SSO links the two accounts so you can operate both from one login.

Import rate limit is 5 req/min, not 120

The general rate limit is 120 requests per minute, but subscriber imports and batch upserts have their own separate 5 requests per minute throttle. Migrating a large list one-subscriber-at-a-time hits this cap fast. Use the batch endpoint with large payloads (up to hundreds of subscribers per call) instead of looping single-add operations.

Segments are read-only from the API

You can read dynamic segments via the API (GET /segments) but you cannot create or modify them programmatically — segments are UI-managed. If you need to build subscriber-selection logic in code, use /groups instead (fully CRUD-able) and treat groups as static segments.

Automations creation is UI-only

The /automations endpoint lets you list, activate, and deactivate automations, and view subscriber-level activity. You cannot create a new automation via the API — the flow builder is UI-only. Similar to Mailchimp’s Customer Journey Builder gap. Plan around this: create your automation templates in the UI, then use the API to bulk-add subscribers or trigger enrollment.

Tokens do not have granular scopes

A MailerLite API key can do anything the account allows. There is no read-only or campaigns-only scope. To limit blast radius of a leaked token, generate per-integration keys and revoke individually. Best practice: dedicated service-account user with per-integration tokens, rotated on staff turnover.

Deprecations and changelog

MailerLite maintains a changelog on the developers portal at developers.mailerlite.com. Key items to know:

  • API v2 is current. Stable since 2022. Focus of all new SDK work and documentation.
  • Classic API v1 is still supported at developers-classic.mailerlite.com. No formal deprecation date announced, but new integrations should target v2.
  • MailerSend MCP Server released in BETA late 2025 / early 2026 with wide tool coverage from launch (email, SMTP, templates, webhooks, analytics, SMS).
  • Native Claude and ChatGPT integrations shipped 2026 for the Marketing API side — unusually early for an ESP at MailerLite’s price point.
  • Multi-user token management introduced 2024 for team accounts (previously all tokens were account-owner scoped).

Frequently asked questions

Does MailerLite have an official MCP server for AI agents?

Yes, via its transactional companion MailerSend. The MailerSend MCP Server is hosted at mcp.mailersend.com/mcp in BETA, HTTP transport, aligned with the MCP 2026-07-28 spec. Wide coverage: email send/bulk/status, SMTP config, templates, webhooks, inbound, analytics, activity logs, SMS. Compatible with Claude Desktop/web/Code, Gemini CLI, VSCode, Cursor, and ChatGPT (Pro/Plus beta). For the Marketing API side (broadcasts, automations, subscribers), there is no MCP server yet but MailerLite ships native Claude and ChatGPT integrations for natural-language operations.

Which programming languages have official MailerLite SDKs?

Five official SDKs for the Marketing API v2: PHP, Node.js, Python, Ruby, Go. No official .NET, Java, Rust, Kotlin, or Swift SDK. Community wrappers exist for .NET. For unsupported languages, call the API directly with your language’s HTTP client — the JSON payloads are straightforward.

What is the MailerLite API rate limit?

Two tiers. General requests are limited to 120 per minute per API key. Import operations (batch subscriber upserts and imports) have a stricter 5 requests per minute throttle. Exceeding either returns HTTP 429. Use the batch endpoint for bulk operations to reduce per-call overhead and stay under both ceilings.

How do I authenticate with the MailerLite Marketing API?

Bearer token authentication. Generate an API key under Integrations › API in the MailerLite UI, then send it in the Authorization header: Authorization: Bearer YOUR_API_KEY. Tokens are account-scoped and inherit the permissions of the user who created them. No granular scopes — a token can do anything the account allows.

What is the difference between MailerLite Marketing API and MailerSend?

Different products for different jobs. MailerLite Marketing API v2 handles broadcasts, newsletters, automations, subscribers, forms, campaigns, and ecommerce integration. MailerSend handles transactional email (order confirmations, password resets, receipts) plus SMS. Different API keys, different rate limits, different pricing, different SDKs. SSO links the two accounts so you can operate both from one login. MailerSend has an official MCP server; the Marketing API does not (yet).

Can I send emails through MailerLite from Claude Desktop or Cursor?

Two paths. For transactional email: connect the MailerSend MCP Server (mcp.mailersend.com/mcp) — hosted, HTTP transport, compatible with Claude Desktop/web/Code, Cursor, VSCode, ChatGPT. For marketing operations (drafting campaigns, analyzing open rates, managing subscribers): use MailerLite’s native Claude integration from the integrations directory — not an MCP server per se, but a first-party Claude connector for the Marketing API.

Is MailerLite Classic API v1 deprecated?

Not formally deprecated but no longer the recommended target. Classic API v1 remains available at developers-classic.mailerlite.com for legacy integrations. New development should target the current v2 at connect.mailerlite.com/api. MailerLite has not announced a v1 shutoff date, but the v2 documentation and SDKs receive all new feature work.

Changelog (recent)

  • 2026-08-18 API + MCP tab published on SMTPedia. First profile to document MailerLite Marketing API v2 alongside MailerSend MCP BETA for transactional AI-agent operations.
  • 2026-07-28 MCP specification 2026-07-28 released. Stateless HTTP transport becomes default. MailerSend MCP already aligned with HTTP transport from launch.
  • 2026 Native Claude and ChatGPT integrations shipped for MailerLite Marketing API. First-party AI connectors, unusually early for an ESP at MailerLite's price point.
AAlaa Touil RRabeb How we test →

This review follows our email infrastructure testing methodology. We disclose affiliate relationships in our editorial independence policy.