Notify API reference

Notify API · Recipients

patch/v1/workspaces/{workspace_id}/recipients/{external_id}/preferencesAuth

Update a recipient's preferences

Sets or removes (`enabled: null`) the cells you send and keeps the others; also sets unsubscribe-all, time zone and quiet hours.

Path parameters

workspace_id*string · uuid

Id of the workspace.

external_id*string

Your user id for the recipient (URL-encoded): 1-255 of `A-Z a-z 0-9 . _ : @ | -`.

Request body

preferencesarray

Cells to set or (with `enabled: null`) remove; other cells are kept.

unsubscribed_allboolean

Opt out of (or back into) every non-critical notification.

timezonestring

IANA time zone of the recipient (quiet hours).

Example: "Europe/Lisbon"

quiet_hoursobject

Quiet window; null removes it.

Response · 200 The preferences after the change.

external_id*string

The recipient external id.

unsubscribed_all*boolean

Opted out of every non-critical notification.

timezone*string

IANA time zone.

quiet_hours*object

The recipient's own quiet window; null when they set none (the workspace default then applies, see `effective_quiet_hours`).

effective_quiet_hours*object

The quiet window that applies: the recipient's own, else the workspace default. Null: no quiet hours apply.

preferences*array

Cells the recipient set (anything else follows the category defaults).

Example

Request

PATCH https://api.notify.productcraft.co/v1/workspaces/{workspace_id}/recipients/{external_id}/preferences
Authorization: Bearer YOUR_TOKEN
Content-Type: application/json

{
  "preferences": [
    {
      "scope": {},
      "key": "billing",
      "channel": {},
      "enabled": false
    }
  ],
  "unsubscribed_all": false,
  "timezone": "Europe/Lisbon",
  "quiet_hours": {}
}

Response

{
  "external_id": "string",
  "unsubscribed_all": false,
  "timezone": "string",
  "quiet_hours": {},
  "effective_quiet_hours": {},
  "preferences": [
    {
      "scope": {},
      "key": "string",
      "channel": {},
      "enabled": false
    }
  ]
}