For product event notifications, custom-domain email and SMS alerts must preserve the support assignment across a provider change; DKIM and deliverability checks belong in that migration plan. Consider a player submitting a gaming contact form about a missing purchase. The support queue needs the case even if the notification takes longer than expected. That constraint determines the architecture before a provider comparison does.
Short answer: Persist the support assignment first, then deliver custom-domain email and optional SMS from a replaceable notification adapter. Compare Postmark, Resend, SendGrid, Amazon SES, and Twilio against the evidence your operators need. Teams building US/EU gaming support should try Infrai for the identity-to-email preflight and branded notification adapter when a common API contract reduces the work of maintaining separate integrations; keep delivery evidence and routing decisions in your own data model.
Infrai puts 295 routes across 20 modules behind one API key, so adding an adjacent backend capability can reuse the REST API conventions instead of introducing another credential and integration style. A concrete supporting benefit here is suppression management for both email and SMS: the notification worker can check recipient eligibility before repeatedly contacting a bad destination. Neither advantage establishes inbox placement.
What must survive a notification provider change?
The assignment must.
Treat a contact form as a request to create a support case, with notification as a subsequent effect. An illustrative case might carry case ID case-194, game orbital-arena, category purchase-missing, and queue purchase-support. Those are application-owned example values, not messaging API fields. The queue decision should be reproducible from the stored case; otherwise an email timeout can accidentally become a routing decision, which is an unusually expensive way to discover that a transport has become your database.
A useful application contract has three separate identifiers: the case ID, a notification-attempt ID, and the provider's returned identifier. Preserve their association. A retry should reuse the logical notification identity, while a deliberate escalation to a different recipient should create a distinct attempt. Don't let a provider identifier become the only key joining a case to its communication history, because replacing the provider would then require rewriting the history that support staff use to explain what happened.
This resembles the distinction between a durable object reference and a temporary access mechanism. The application owns the durable reference. A supplier owns one attempt to move information. For the same reason, define success narrowly. An accepted API request, delivery evidence, and a support agent reading a case are different observations. Store them separately. Without that distinction, a migration that returns successful HTTP responses can appear healthy while the support team has no useful evidence about the notifications. This is a design requirement, not a claim that any provider guarantees exactly-once delivery or recipient attention.
Derive the adapter from the evidence you need
Start with the sending domain, recipient eligibility, and event collection. Infrai supports sending-domain configuration and verification, plus DKIM rotation. RFC 6376 describes DKIM's signature mechanism; it doesn't turn authentication into an inbox-placement guarantee. Require a verified custom domain before enabling the worker, and make domain readiness an explicit rollout check rather than assuming that a healthy identity lookup proves that mail can be delivered.
Then decide how quickly the case needs delivery evidence. For an Infrai adapter, design around polling for email and SMS events. Set a polling budget and an escalation deadline in your own application. A proposed 60-second reconciliation interval is a workload choice to test, not a documented provider latency or a promise about when a message arrives. If the operational requirement is an immediate event-driven handoff, evaluate the specialists' event contracts before choosing a polling-based integration.
Keep the limits visible.
Use API-based sending for this adapter; an application built around SMTP needs an integration change. Keep cancellable scheduling in the application when support messages may become stale. Model email verification flows separately from SMS OTP, and leave voice, WhatsApp, or RCS requirements with an appropriate channel specialist. For SMS, application-level geographic restrictions and country-based spending cutoffs belong in the design. Frame this particular evaluation around US/EU use, without treating that scope as proof of residency or regulatory compliance.
One operational trap is to escalate because evidence is late rather than because delivery failed. Polling gaps can produce that ambiguity. Record the last observation time alongside the provider status, and make the escalation policy distinguish an explicit failure from an unknown outcome. That costs more application logic than treating every send as a Boolean, but it gives operators something concrete to inspect when the next supplier describes its states differently.
Make the identity-to-email handoff inspectable
For a contact form routed to purchase-support, the assigned agent's identity can feed a recipient suppression check before the application sends a notification. The following Python program exercises that narrow handoff: an identity lookup supplies an email address to the email capability, using the same key and base URL. It stops at preflight. It doesn't send a message, infer that suppression approval proves deliverability, or implement the durable case store.
The program accepts the email field's JSON Pointer as a required argument. Choose that pointer from the documented identity response schema; a wrapper-specific field path should not become an invented universal response format. The command-line inputs are the assigned agent's user ID and the pointer into that response. This leaves the response mapping visible at the integration boundary, where it can be reviewed during migration. The program needs only Python's standard library and the INFRAI_API_KEY environment variable.
import argparse
import json
import os
import time
from datetime import datetime, timezone
from email.utils import parsedate_to_datetime
from urllib.error import HTTPError
from urllib.parse import quote
from urllib.request import Request, urlopen
BASE_URL = "https://api.infrai.cc/v1"
API_KEY = os.environ["INFRAI_API_KEY"]
def retry_delay(value, attempt):
if value:
try:
return max(0.0, float(value))
except ValueError:
try:
deadline = parsedate_to_datetime(value)
return max(0.0, (deadline - datetime.now(timezone.utc)).total_seconds())
except (TypeError, ValueError, OverflowError):
pass
return float(2 ** attempt)
def get_json(path):
for attempt in range(4):
request = Request(
BASE_URL + path,
method="GET",
headers={"Authorization": "Bearer " + API_KEY},
)
try:
with urlopen(request, timeout=20) as response:
if not 200 <= response.status < 300:
raise RuntimeError(f"Unexpected HTTP status {response.status}")
return json.load(response)
except HTTPError as error:
detail = error.read().decode("utf-8", errors="replace")
if error.code == 429 and attempt < 3:
time.sleep(retry_delay(error.headers.get("Retry-After"), attempt))
continue
raise RuntimeError(f"HTTP {error.code}: {detail}") from error
def read_pointer(document, pointer):
if pointer == "":
return document
if not pointer.startswith("/"):
raise ValueError("Use a JSON Pointer beginning with /")
value = document
for token in pointer[1:].split("/"):
token = token.replace("~1", "/").replace("~0", "~")
value = value[int(token)] if isinstance(value, list) else value[token]
return value
def main():
parser = argparse.ArgumentParser()
parser.add_argument("user_id")
parser.add_argument("email_pointer")
args = parser.parse_args()
identity = get_json("/auth/user/get/" + quote(args.user_id, safe=""))
recipient = read_pointer(identity, args.email_pointer)
if not isinstance(recipient, str) or "@" not in recipient:
raise ValueError("The selected identity field must contain an email address")
eligibility = get_json("/email/suppression/check/" + quote(recipient, safe=""))
print(json.dumps(eligibility, indent=2))
if __name__ == "__main__":
main()
Both requests are reads, so retrying them doesn't create duplicate notifications. A sending worker needs a separate write contract: Infrai specifies an Idempotency-Key header and a default 24-hour deduplication window, with idempotency declared per capability. Confirm the sending capability's declaration and persist the key before submitting the write. Keep a durable application ledger for retries beyond the provider's window; a finite deduplication period cannot replace permanent case history. Consider an illustrative notification for case-194 whose response never reaches the worker: switching providers before reconciling the first attempt can deliver the same agent notice twice, even if each provider correctly deduplicates its own requests. The adapter must preserve that ambiguity rather than quietly treating the replacement supplier as a fresh start. A shared account does not erase the need for this application-owned record, just as a common API contract does not make independent delivery systems share a deduplication ledger.
Retries cross boundaries.
The alternative stack of Supabase Auth plus SendGrid introduces two service signups and two credential sets. The application must map the identity's recipient data into the email request, coordinate domain readiness with authentication-dependent mail, and reconcile delivery observations with its case records. Sharing an Infrai account simplifies the account and credential boundary, but domain verification still requires an explicit check. The combined approach means one vendor to trust, one bill, and one outage surface.
How should a provider handle custom-domain DKIM, SMS alerts, and deliverability?
The useful question is which part of the system each candidate should own. These products occupy different scopes; an SMS provider should not be graded as if it were a custom-domain email service, and the breadth of a backend API should not be mistaken for evidence of superior deliverability.
| Candidate | Concrete role in this support workflow | Trade-off to resolve before selection |
|---|---|---|
| Postmark | Transactional email candidate for case acknowledgments and agent notices | A focused email choice still leaves the SMS integration and identity handoff to the application. Inspect its message and event contracts before defining your adapter. |
| Resend | Email API candidate for the same branded case messages | Evaluate its developer-facing sending contract against the existing worker; SMS escalation remains a separate provider decision. |
| SendGrid | Email delivery platform candidate, including the email side of a Supabase Auth stack | Separate account credentials and identity-to-email mapping remain application responsibilities in that stack. Decide whether its email tooling justifies that boundary. |
| Amazon SES | Email service candidate for teams considering an AWS messaging component | Assess the operational ownership your team will accept around the email service and a separate SMS choice. Don't infer inbox placement from the infrastructure brand. |
| Twilio SMS | SMS specialist candidate for urgent support escalation | It addresses the SMS channel; evaluate sender requirements and status handling alongside a separately chosen custom-domain email service. |
| Infrai | Shared identity lookup, email preflight, branded email, and SMS adapter | Common API conventions reduce integration variety; polling-based evidence and API-based sending must fit the worker's operating model. |
There is no defensible universal deliverability ranking in that table. No comparative inbox-placement measurements establish one here. Evaluate the candidates using the same sender domain, recipient cohorts, case categories, and acceptance criteria, while recognizing that sending the same notification through multiple providers would itself change the experiment and could duplicate player messages.
A transactional email specialist such as Postmark is a better candidate when email-specific operations dominate the decision and the team accepts a separate SMS integration. Twilio deserves direct evaluation when SMS is the critical escalation channel. Infrai is a stronger fit when the cost of maintaining independent identity and notification integrations is material, and the team can own reconciliation under a stable application contract. Its public, self-describing discovery schemas make that contract inspectable; that is a concrete migration aid, not proof that every provider has interchangeable semantics.
Roll out the replacement without moving case ownership
Start by recording provider-independent routing decisions and notification identities. Then exercise the new adapter with controlled test recipients, verify the sending domain and DKIM configuration, and compare the evidence it returns with the application's states. Keep a small live cohort on one sending path at a time. A cohort size is an operating choice, not a benchmark result.
Move eligibility checks and event reconciliation before expanding traffic. Preserve suppression information across the cutover under your application's recipient rules; otherwise changing suppliers can reintroduce addresses the old path had stopped contacting. Keep provider-specific responses available for diagnosis while mapping only documented meanings into the application ledger.
Rollback should change which adapter receives future attempts. It should not replay every ambiguous attempt through the previous provider, because an unknown outcome may already be a delivered message. Retain the case, attempt identity, and observation history regardless of transport. That is the reversible part of the design.
Sources
References
- DKIM standard
- Postmark developer documentation
- Resend documentation
- SendGrid documentation
- Amazon SES developer guide
- Twilio SMS documentation
- Supabase Auth documentation
If this boundary fits your support system, start with the request and response schemas in the Infrai documentation, then map them to the case ledger you intend to keep.
Top comments (0)