PUT
Update notification preferences

Authorizations

Origin
string
header
required

Same-origin CSRF check. The Origin header must match the request host; enforced for every mutating verb (POST, PUT, PATCH, DELETE).

Body

application/json
prefs
object | null
required

null clears the overrides on all four flag.notifications.types.* flags and empties notification_prefs. An object sets each flag's override from its snake_case key (true for on, false for off), or, if that key is missing, from its camelCase name: labelChanges for label_changes, policyUpdates for policy_updates. When both spellings are sent, the snake_case one wins. A flag with neither key has its override cleared, so it falls back to its default. accessibility_changes and new_privacy_types have no camelCase name, so a Settings save, which sends only the nine camelCase keys, clears their overrides. The camelCase keys with boolean values are also saved to notification_prefs, and anything else is dropped.

Example:

Response

The resolved preferences after the write.

Per-type notification switches under two sets of names. The four snake_case keys are the flag.notifications.types.* feature flags. The nine camelCase keys are the types the Settings view and the bell use. Two types are in both sets: labelChanges is the same switch as label_changes, and policyUpdates the same as policy_updates. The other seven camelCase types are stored in the notification_prefs setting. Privacy-policy text changes are opt-in: policy_updates and policyUpdates stay false until flag.notifications.types.policy_updates is on.

prefs
object
required

Every switch's current value, in this order: the four snake_case flag keys, each resolved through the flag cascade (your override, then the focus default, then the hard default), then all nine camelCase keys. labelChanges and policyUpdates repeat their flags' values. The other seven come from notification_prefs, with defaults filling any type that was never saved. If the flag resolver fails, prefs holds only the camelCase keys saved in notification_prefs.

stored
object
required

Same values as prefs.

defaults
object
required

The Settings view's defaults, keyed by its own type names. Fixed values, not the flags' resolved state.

Example: