Looking for the HTTP endpoints instead — managing lists, domains, webhooks, and members over curl? That’s the REST API.
Provider class
Every provider exposes the same surface:
See Providers for each provider’s credential option names. The zero-config
equivalents are mail() and cancel() from the package root.
Postboi provider methods
The Postboi provider adds account methods on top of the common surface:
SendOptions
body accepts a string of HTML, a FormData object, or a promise resolving
to either, so you can pass a template renderer’s output straight through; see Email templates. formatter controls how grouped-field labels are rendered. headers and tags are forwarded to each
provider’s native concept. See Custom headers & tags. captcha adjusts the built-in spam protection for a single send.
Common constructor options
Every provider also accepts these, on top of its own credentials:
See Errors & retries for retry behaviour, Hooks for the hooks shape, and Spam protection for captcha.
Email type
All accepted address formats:
PostboiError
The normalised error thrown by every provider. See Errors & retries for usage.
postboi/webhooks
Receive delivery events, normalized across providers. See Webhooks.
On SvelteKit, webhook(handler, options?) from postboi/kit wraps receive as a
ready-made +server.ts request handler.