Skip to main content
Contacts

Update contact email preferences by ID

Updates one or more email preferences for a customer contact by their Featurebase ID.

PATCH
/v2/contacts/{id}/email-preferences

Important: This endpoint only supports customer contacts. Leads do not have a customer email preference surface in the public API.

Path Parameters

  • id - The Featurebase contact ID (24-character ObjectId)

Request Body

  • preferences - A partial map of preference keys to their desired stored status. Only the preferences included in the request are updated; any preferences omitted are left unchanged. At least one preference must be provided.

Supported Preference Keys

  • all - Master delivery gate. When unsubscribed, the contact will not receive any emails regardless of the per-category values. Per-category values are still persisted, so flipping all back to subscribed restores the contact's previous granular preferences.
  • postUpdates - Status changes and updates on posts the contact interacts with.
  • postComments - New comments on posts the contact follows.
  • commentReplies - Replies to the contact's own comments.
  • changelog - New changelog releases.

Per-key Values

  • subscribed - The contact will receive this email category (subject to the all gate).
  • unsubscribed - The contact will not receive this email category.

Combining all with per-category keys

You can send all together with any per-category keys in the same request. The full map is applied atomically as the contact's new stored state — there is no implicit reset of the other keys. This makes the endpoint safe for preference-center UIs that POST the entire form state on submit.

The computed per-category result (after applying the all gate) is surfaced as effectiveStatus in the response, while status reflects the value actually stored for that key.

Example Request (partial update)

{
  "preferences": {
    "postUpdates": "unsubscribed",
    "changelog": "subscribed"
  }
}

Example Request (full preference-center submit)

{
  "preferences": {
    "all": "subscribed",
    "postUpdates": "subscribed",
    "postComments": "unsubscribed",
    "commentReplies": "unsubscribed",
    "changelog": "unsubscribed"
  }
}

Example Response

{
  "object": "contact_email_preferences",
  "contactId": "676f0f6765bdaa7d7d760f88",
  "userId": "usr_12345",
  "email": "john@example.com",
  "preferences": {
    "all": {
      "status": "subscribed",
      "effectiveStatus": "subscribed"
    },
    "postUpdates": {
      "status": "subscribed",
      "effectiveStatus": "subscribed"
    },
    "postComments": {
      "status": "unsubscribed",
      "effectiveStatus": "unsubscribed"
    },
    "commentReplies": {
      "status": "unsubscribed",
      "effectiveStatus": "unsubscribed"
    },
    "changelog": {
      "status": "unsubscribed",
      "effectiveStatus": "unsubscribed"
    }
  }
}
Authorizationstringheaderrequired

API key as Bearer token. Use: Authorization: Bearer sk_...

idstringrequired

Featurebase contact ID

Example: 507f1f77bcf86cd799439011
Featurebase-Versionenum<string>header

API version for this request. Defaults to your organization's configured API version if not specified.

Available options: 2026-08-19.orbit, 2026-01-01.nova, 2025-12-12.clover
Example: 2026-08-19.orbit

Body

application/json
preferencesobjectrequired

Response

application/json

Success

contactIdstringrequired

Featurebase contact ID

Example: 676f0f6765bdaa7d7d760f88
emailstring | null

Contact email address, if available

Example: john@example.com
objectenum<string>required

Object type identifier

Available options: contact_email_preferences
Example: contact_email_preferences
preferencesobjectrequired

Email preference state for this contact, including both stored status and final effective status.

userIdstring | null

External user ID from your system, if available

Example: usr_12345