Adapters
Plunk
Configure the Plunk send API adapter.
Plunk
@opencoredev/email-sdk/plunkOfficialPayload-testedLive account required
import { createEmailClient } from "@opencoredev/email-sdk";
import { plunk } from "@opencoredev/email-sdk/plunk";
const email = createEmailClient({
adapters: [plunk({ apiKey: process.env.PLUNK_API_KEY! })],
});Options
| Option | Type | Required | Notes |
|---|---|---|---|
apiKey | string | Yes | Plunk API key. |
baseUrl | string | No | Defaults to https://next-api.useplunk.com. |
fetch | typeof fetch | No | Useful for tests or custom runtimes. |
Plunk maps metadata to data, replyTo to reply, custom headers to headers, attachments to attachments, and the first returned data.emails[].email value to the SDK response ID. Unsupported fields throw before the API call.
