Decorators

Idempotency

Deduplicate replayed email sends with an idempotency key.

Deduplicate replayed email sends with an idempotency key.

The one rule

Wrap it outside RetryTransport so all retry attempts share a key.

Configuration

The optional options are store and ttlMs; memory is the default store.

import { IdempotencyTransport } from "sently/idempotency";

const transport = new IdempotencyTransport(inner, { ttlMs: 86_400_000 });
const mailer = await createMailer({ transport });

On this page