Home/Integrations/Custom SMTP

Use Custom SMTP with GetFluxly

Connect any SMTP relay to GetFluxly and run behavior-triggered lifecycle email through the sending path your team already operates. The Custom SMTP connector is provider-agnostic. It works with Postmark, SendGrid, Brevo, Mailtrap, an in-house Postfix relay, even localhost:25 for staging. GetFluxly captures product events, builds unified customer profiles, and triggers automations on your rules; your relay does the actual delivery.

What you ship after this guide. A verified sending domain at your relay provider with SPF, DKIM, and DMARC, send-scoped SMTP credentials, the right TLS mode for the relay you picked, and a working test send.

When to use Custom SMTP

Pick Custom SMTP when your relay doesn't have a dedicated connector yet, when network policy mandates SMTP, or when you want a single SMTP transport across many environments. It's also the right pick for one-off relays, staging Postfix, an internal transactional relay behind your VPC, an enterprise mailrelay your ops team already runs.

For a richer dispatcher experience, see Amazon SES, Resend, Mailgun, or SMTP2GO.

Requirements before connecting

An SMTP relay you can authenticate against, a verified sending domain at that relay, and SMTP credentials with the send scope. On the GetFluxly side: a project, a workspace API key (gf_live_…), and access to Settings → Email providers.

Verify your sending domain

Most SMTP relays require domain verification before they sign DKIM on outgoing messages. Add the DNS records your provider issues the exact set varies, and wait for the domain status to flip to verified. If you're running an in-house relay (Postfix, Haraka, etc.), you own the DKIM signing keys directly and the verification step is whatever you do internally.

Add SPF, DKIM, and DMARC

These records live on your domain's DNS, not on GetFluxly. They tell receiving mailboxes that your SMTP relay is allowed to send on your behalf and what to do when alignment fails.

SPF

Add an include: for whichever relay you picked. The include string is published in your relay's setup docs, for Postmark it's spf.mtasv.net, for SendGrid it's sendgrid.net, for Brevo it's spf.brevo.com, and so on. If you already have an SPF record, merge the include rather than publishing two SPF records on the same name.

Type:   TXT
Host:   yourdomain.com
Value:  v=spf1 include:<your-relay-spf-include> -all

DKIM

DKIM is whatever your relay provider issues. Most relays publish two CNAME records under the _domainkey subdomain or a single long TXT record with the public key. Copy the host and value pairs exactly as the provider displays them.

DMARC

Type:   TXT
Host:   _dmarc.yourdomain.com
Value:  v=DMARC1; p=none; rua=mailto:dmarc@yourdomain.com; fo=1
These records protect your domain. Publish them at the DNS for the domain you send from. Nothing goes on getfluxly.com. GetFluxly never appears in your From: header.

Get SMTP credentials

Create a send-scoped SMTP user at your relay. The exact path varies by provider, for example, Postmark uses the server token as both the SMTP username and password, SendGrid uses an API key as the password against the literal username apikey, Brevo generates a master SMTP key in SMTP & API. Check your relay's SMTP docs for the right pattern.

Pick a TLS mode

starttls, connect plaintext on the port and upgrade with STARTTLS. The standard for port 587 and the right default for almost every public relay.

ssl. TLS from the first byte. Use this for port 465 or any relay that explicitly advertises implicit TLS instead of STARTTLS.

none, no TLS. Only valid for in-house relays on a trusted network. Public providers will refuse the connection.

Connect Custom SMTP in GetFluxly

Open Settings → Email providers, click Add provider, and choose Custom SMTP. GetFluxly connects to the host with your selected TLS mode, runs EHLO + AUTH, and bounces on the first error so you find out before the message is queued.

FieldRequiredNotes
display_nameyesFree-form. Shown in the provider list.
from_emailyesUsed as the envelope-from address.
from_namenoOptional friendly name.
reply_tonoOptional reply-to header.
smtp_hostyese.g. smtp.postmarkapp.com
smtp_portyes1–65535. Common values: 25, 465, 587, 2525.
smtp_secureyesOne of starttls, ssl, none.
usernameyesSMTP login.
passwordyesEncrypted with AES-GCM before storage.
curl -X POST https://api.getfluxly.com/v1/projects/PROJECT_ID/email-providers \
  -H "Authorization: Bearer gf_live_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{
    "provider": "smtp",
    "display_name": "Postmark Production",
    "from_email": "hello@yourdomain.com",
    "from_name": "Acme",
    "smtp_host": "smtp.postmarkapp.com",
    "smtp_port": 587,
    "smtp_secure": "starttls",
    "username": "POSTMARK_SERVER_TOKEN",
    "password": "POSTMARK_SERVER_TOKEN"
  }'
Postmark trick: Postmark uses the same value for username and password, your server token. SendGrid uses the literal username apikey with your API key as the password. Other providers usually split them.

Handle bounces and complaints

Bounce and complaint feedback comes from your relay provider, not from SMTP itself. Configure a webhook in your relay's dashboard pointing at the GetFluxly per-project webhook URL, the slug matches the relay name (for example /webhooks/postmark/<project_id>). For relays without a dedicated webhook adapter, GetFluxly accepts a generic schema at /webhooks/smtp/<project_id>.

Test your first lifecycle email

curl -X POST https://api.getfluxly.com/v1/email-providers/PROVIDER_ID/test \
  -H "Authorization: Bearer gf_live_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{ "to": "you@yourdomain.com" }'

Common errors

Connection refused. Almost always wrong host or port, occasionally a network egress firewall. Try 2525 if your provider supports it; some hosting platforms block 25 and 587 outbound by default.

Authentication failed. Some providers require an app-specific password rather than your account password. Check your provider's SMTP docs for whether the password you copied from the dashboard is the right one.

STARTTLS not advertised. Switch the secure mode to ssl and try the port that's usually paired with implicit TLS (typically 465).

Mail going to spam. Recipients still check SPF, DKIM, and DMARC for the sending domain. Make sure the relay you connect can sign DKIM for the domain on from_emailif it can't, your messages will land in spam regardless of how healthy your content score is.

FAQ

Does GetFluxly charge extra to send through a custom SMTP relay?

No. GetFluxly does not bill per email. The relay you connect (Postmark, SendGrid, Brevo, an in-house Postfix server, or anything else) handles delivery on its existing pricing. GetFluxly handles segmentation, automation, profiles, and tracking on top of that send path with no per-message markup.

Which SMTP relays does the Custom SMTP connector work with?

Anything that implements SMTP and accepts AUTH PLAIN or AUTH LOGIN over STARTTLS or implicit TLS. That covers Postmark, SendGrid, Brevo (formerly Sendinblue), Mailtrap, Mailgun, Amazon SES SMTP, an in-house Postfix relay, and most legacy enterprise relays.

Why use Custom SMTP instead of a native connector?

Pick Custom SMTP when your relay doesn't have a dedicated GetFluxly connector yet, when your network policy mandates SMTP, or when you want a single SMTP transport across multiple environments. The native connectors give richer features (batch sends, per-message tagging) where they exist; Custom SMTP is the universal fallback.

Can I use port 465 with implicit TLS instead of 587?

Yes. Set the GetFluxly TLS mode to ssl and the port to 465. STARTTLS on 587 is more common, but implicit TLS on 465 is fully supported and is required by some relays that don't advertise the STARTTLS extension.

How do I track bounces and complaints when sending over Custom SMTP?

Bounce and complaint feedback comes from your relay provider, not from SMTP itself. Configure a webhook in your relay's dashboard pointing at the GetFluxly per-project webhook URL (the slug matches the relay's name, for example /webhooks/postmark/<project_id>). For relays without a dedicated webhook adapter, GetFluxly accepts a generic schema at /webhooks/smtp/<project_id>.

Is plaintext SMTP (no TLS) supported?

Only for in-house relays on a trusted network. GetFluxly supports a none TLS mode for that case. Public relays will refuse a plaintext SMTP session, and even on a trusted network we recommend STARTTLS or implicit TLS.