Integrations

Preferences

Subscriber preference management

Overview

Let subscribers manage their email preferences with a self-service page. The preferences system supports double opt-in confirmation, frequency controls, category-based subscriptions, and one-click unsubscribe — helping you stay compliant with email regulations and keep your audience engaged.

Double Opt-in

Initiate the double opt-in flow by submitting a subscriber's email address. The system sends a confirmation email containing a unique token link. The subscriber must click the link to verify their subscription.

POST/api/optin

Send a double opt-in confirmation email to the given address. Returns a pending status until the subscriber confirms.

Parameters

NameTypeDescription
email*stringSubscriber email address
namestringSubscriber display name

Request

json
{
  "email": "subscriber@example.com",
  "name": "Jane Doe"
}

Response

json
{
  "success": true,
  "message": "Confirmation email sent",
  "status": "pending"
}

Confirm Opt-in

When a subscriber clicks the confirmation link in their email, this endpoint validates the token and activates their subscription. The token is single-use and expires after 24 hours.

GET/api/optin/confirm?token=...

Confirm a subscriber's opt-in using the token from the confirmation email. Activates the subscription on success.

Parameters

NameTypeDescription
token*stringUnique confirmation token from the opt-in email

Response

json
{
  "success": true,
  "message": "Subscription confirmed",
  "email": "subscriber@example.com"
}

Get Preferences

Retrieve a subscriber's current preferences including email frequency and category subscriptions. The token authenticates the subscriber without requiring a password.

GET/api/preferences?token=...

Fetch the subscriber's current email preferences including frequency settings and subscribed categories.

Parameters

NameTypeDescription
token*stringSubscriber preference token

Response

json
{
  "email": "subscriber@example.com",
  "name": "Jane Doe",
  "frequency": "weekly",
  "categories": ["product-updates", "newsletters"],
  "subscribed": true
}

Unsubscribe

Unsubscribe a user from all emails. Accepts either an email address or a subscriber token. This immediately stops all future emails to the address.

POST/api/unsubscribe

Unsubscribe a user from all emails. Provide either an email address or a subscriber token.

Parameters

NameTypeDescription
emailstringSubscriber email address (provide email or token)
tokenstringSubscriber preference token (provide email or token)

Request

json
{
  "email": "subscriber@example.com"
}

Response

json
{
  "success": true,
  "message": "Successfully unsubscribed"
}

Preference Page

Each subscriber gets a unique preferences page accessible at /preferences?token=.... This page provides a self-service interface where subscribers can:

  • Choose their preferred email frequency (daily, weekly, monthly)
  • Subscribe or unsubscribe from specific email categories
  • Fully unsubscribe from all communications
  • View their current subscription status

The preference token is automatically included in the footer of every email sent through the platform. No password is required — the token serves as a secure, unique identifier for each subscriber.