Skip to content

Mailtrap

Mailtrap’s Email Sending rides a single API token for both transports, and its webhooks report delivery events back — confirmed deliveries, bounces, and spam complaints — which powers the delivered state, webhooks like mail.delivered and mail.bounced, and automatic suppressions. The whole delivery-events setup is one form on Mailtrap’s side.

  • A Mailtrap account with Email Sending enabled.
  • Your sender domain verified under Domains (Mailtrap’s stepper walks you through the SPF/DKIM records) — see Deliverability for what each record proves.
  • An API token: Mailtrap sidebar → Settings → API Tokens. Use a token scoped to sending so you can rotate it independently.
  1. Add the provider.

    In the console, open Providers → New provider, pick Mailtrap and paste the token — secrets are encrypted at rest. The one token gives the account both transports: mail that reaches Mailway’s SMTP relay goes on over Mailtrap’s SMTP server (live.smtp.mailtrap.io:465, implicit TLS, as the literal user api), byte-for-byte, and HTTP API and console mail go over Mailtrap’s API.

    While you’re there, set the Free tier field (for example 4000 per month). With free-first routing, providers whose free tier isn’t used up go first, counted approximately, and this field is how Mailway knows Mailtrap’s.

  2. Attach it to a project.

    Open the project, attach the provider, and position it in the failover order. Send something — the provider health panel starts filling in.

Without delivery events, Mailtrap only reports that it accepted the mail. With them, Mailtrap tells Mailway what happened afterwards. Two minutes, once.

  1. Open delivery tracking. In the console, open the provider → Delivery tracking (beside Configure). Mailway creates the provider’s webhook URL and shows it ready to copy. The URL contains a per-provider secret — treat it like a password (regenerating it at the bottom of the dialog revokes the old one instantly).

  2. Create the webhook in Mailtrap. Sidebar → Webhooks → Create New Webhook:

    • Webhook URL: the URL you copied.
    • Payload format: JSON (not JSON Lines).
    • Select area: Email Sending, then your stream (Transactional) and domain.
    • Events: tick Delivery, Soft Bounce, Bounce, Spam Complaint, and Reject. Leave Open, Click, Unsubscribe, and Suspension off — Mailway doesn’t track engagement, so those events are ignored.
  3. Store the signing secret (required). Save the webhook, copy its signing secret from Mailtrap and paste it into the dialog’s Paste the signing secret step. Mailway accepts only events that carry Mailtrap’s valid signature: until the secret is stored, every event sent to the URL is refused.

Mailtrap event Mailway outcome
Delivery The mail turns delivered (confirmed by the provider’s event).
Bounce (hard) The mail turns bounced; the address is auto-suppressed for the project.
Soft Bounce Recorded as soft_bounced (temporary; a later delivery outranks it).
Spam Complaint The mail turns complained; the address is auto-suppressed.
Reject Recorded as dropped: Mailtrap refused the message before sending. The mail keeps its state.
  • Connection check. The provider page’s connection check logs in over SMTP and makes one read-only API call, without sending anything. A token scoped to sending may not be allowed to read account data; the API side then shows as unverifiable, and a test email proves it.
  • Delivery events. Use Mailtrap’s Run Test button next to the webhook: the signed test event arrives at Mailway within seconds, and the Delivery tracking dialog’s last step ticks when it does. After a real send, the mail’s timeline shows the delivered or bounced step with Mailtrap’s own response details attached.

Mailtrap keeps your headers and your text part, but in our test it inserted a 1×1 open-tracking image into the HTML part, which also breaks a DKIM signature your app applied. If you don’t want opens tracked, check the tracking settings for your sender domain in Mailtrap. Tested results: What providers change.

Mailtrap’s free plan includes 4,000 emails a month, at most 150 a day — a natural first entry in a free-first routing chain. Otherwise your Mailtrap plan’s own sending limits apply. Mailway adds none for Mailtrap beyond your Mailway plan’s quotas.