capabilities.work

Set Object Preferences and Audit Messages

A 3-step recipe with Knock. We can help you get access.

Recipe · 3 steps

Set Object Preferences and Audit Messages

with Knock
Works with AI assistants

Upsert an object, set its preferences, and audit its messages.

  1. Create or update the object in the collection with the supplied name.
  2. Update the object's preference set with the supplied channel types and workflow opt-ins.
  3. List recent messages delivered to the object to audit its notification history.
What you'll need to have ready
  • apiKey: Knock secret API key (sk_...) used as a Bearer token.
  • collection: The collection the object belongs to.
  • objectId: The unique identifier for the object.
  • name: A display name to set on the object.
  • preferenceSetId: The preference set identifier to update (defaults to "default").
  • channelTypes: A map of channel type names to boolean opt-in values.
  • workflowPreferences: A map of workflow keys to per-workflow preference settings.
For your developer

Arazzo workflow knock-app:object-preferences-message-audit, 3 operations: setObject → updateObjectPreferenceSet → listMessagesForObject. Specs on APIs.io.