Skip to Content
API Reference

API Reference

The Mailpulse API allows you to retrieve tracking statistics and manage your email campaigns programmatically.

Authentication

All API endpoints require authentication via an API key. Include your API key in the x-api-key header:

curl -X GET NEXT_PUBLIC_BASE_URL/api/stats \ -H "x-api-key: your-api-key"

You can generate an API key from your Mailpulse dashboard under Settings > API Keys.

Base URL

The base URL for all API endpoints is:

https://mailpulse-io.lyten.agency/api

For self-hosted instances, replace with your own domain.

Response Format

All responses are returned in JSON format. Successful responses return the requested data, while error responses include an error field:

{ "error": "Campaign not found" }

Rate Limits

API requests are rate-limited to ensure fair usage. If you exceed the rate limit, you’ll receive a 429 Too Many Requests response.

Available Endpoints

Statistics

  • GET /api/stats - Global Stats - Get overall tracking statistics for your organization

Email Sending

  • POST /api/send - Send Email - Send an email with automatic tracking

Sending Domains

  • GET /api/sending-domains - List Domains - List your sending domains
  • POST /api/sending-domains - Add a new sending domain
  • POST /api/sending-domains/verify - Verify domain DNS records
  • DELETE /api/sending-domains/:id - Remove a sending domain

Campaigns

  • GET /api/campaigns - List Campaigns - List all campaigns
  • GET /api/campaigns/:id - Get campaign details with email list
  • GET /api/campaigns/:id/stats - Campaign Stats - Get detailed analytics for a campaign
Last updated on
Mailpulse Documentation