Developer Guide

Extending AcelleMail Source Code

January 11, 2026 1 min read Guide

Project Structure

AcelleMail is built on Laravel. Key directories:

app/
  Models/       — Eloquent models (MailList, Campaign, Subscriber...)
  Http/
    Controllers/Api/  — REST API controllers
    Controllers/Web/  — Web UI controllers
  Jobs/         — Queue jobs (SendEmail, TrackOpen...)
  Services/     — Business logic (MailService, SegmentService...)
resources/views/ — Blade templates
routes/
  api.php       — API routes
  web.php       — Web routes

Adding a Custom Field to Subscribers

  1. Create a migration: php artisan make:migration add_phone_to_subscribers
  2. Add the column and update $fillable in app/Models/Subscriber.php
  3. Expose via API by editing SubscriberController@store

Custom Mail Provider

Implement the MailClientInterface in a new class under app/Services/MailProviders/, then register it in config/mail_providers.php. The interface requires send(), verify(), and getQuota() methods.

Hooks and Events

AcelleMail dispatches Laravel events you can listen to without modifying core files:

// In a Service Provider boot()
Event::listen(\App\Events\CampaignSent::class, function($event) {
    // Custom post-send logic
    Log::info('Campaign sent: ' . $event->campaign->name);
});

Upgrade Safety

Keep customisations in separate Service Providers and avoid editing vendor or core model files directly. Use extends when possible. Document every change so upgrades are predictable.

AcelleMail Team

Verified author
Email marketing experts · AcelleMail.com

Engineers and marketers behind AcelleMail — the self-hosted email platform powering thousands of senders. We share what we learn shipping deliverability infrastructure, automation, and analytics so you can own every step of your email program.

Related Articles

More in Developer Guide

View all →

Ready to start sending?

AcelleMail is the self-hosted email marketing platform you control end-to-end.

View Pricing