---
title: "Set an object"
method: PUT
path: "/v1/objects/{collection}/{id}"
tags: ["Objects"]
---

# Set an object

`PUT /v1/objects/{collection}/{id}`

Creates a new object or updates an existing one in the specified collection. This operation is used to identify objects with their properties, as well as optional preferences and channel data.

## Path parameters

- `collection` string, required
- `id` string, required

## Request body

- SetObjectRequest — A set of parameters to set an object with. Does not include the object id or collection.
  - `channel_data` InlineChannelDataRequest — A request to set channel data for a type of channel inline.
  - `locale` string, nullable — The locale of the object. Used for [message localization](/concepts/translations).
  - `name` string, nullable — An optional name for the object.
  - `preferences` InlinePreferenceSetRequest — Inline set preferences for a recipient, where the key is the preference set id. Preferences that are set inline will be merged into any existing preferences rather than replacing them.
  - `timezone` string, nullable — The timezone of the object. Must be a valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). Used for [recurring schedules](/concepts/schedules#scheduling-workflows-with-recurring-schedules-for-recipients).

## Response `200`

OK

- Object — A custom [Object](/concepts/objects) entity which belongs to a collection.
  - `__typename` string, required — The typename of the schema.
  - `collection` string, required — The collection this object belongs to.
  - `created_at` string, date-time, nullable — Timestamp when the resource was created.
  - `id` string, required — Unique identifier for the object.
  - `properties` object — The custom properties associated with the object.
  - `updated_at` string, date-time, required — The timestamp when the resource was last updated.

## Changes

- **2026-04-14** `3e8f3a4664d4` — 23 info
  - added the new `is_between` enum value to the request property `preferences/additionalProperties/categories/anyOf[subschema #1: PreferenceSetRequestCategories]/additionalProperties/oneOf[subschema #2: PreferenceSetWorkflowCategorySettingObject]/channel_types/anyOf[subschema #1: PreferenceSetChannelTypes]/chat/oneOf[subschema #2: PreferenceSetChannelTypeSetting]/conditions/items/operator`
  - added the new `is_between` enum value to the request property `preferences/additionalProperties/categories/anyOf[subschema #1: PreferenceSetRequestCategories]/additionalProperties/oneOf[subschema #2: PreferenceSetWorkflowCategorySettingObject]/channel_types/anyOf[subschema #1: PreferenceSetChannelTypes]/email/oneOf[subschema #2: PreferenceSetChannelTypeSetting]/conditions/items/operator`
  - added the new `is_between` enum value to the request property `preferences/additionalProperties/categories/anyOf[subschema #1: PreferenceSetRequestCategories]/additionalProperties/oneOf[subschema #2: PreferenceSetWorkflowCategorySettingObject]/channel_types/anyOf[subschema #1: PreferenceSetChannelTypes]/http/oneOf[subschema #2: PreferenceSetChannelTypeSetting]/conditions/items/operator`
  - added the new `is_between` enum value to the request property `preferences/additionalProperties/categories/anyOf[subschema #1: PreferenceSetRequestCategories]/additionalProperties/oneOf[subschema #2: PreferenceSetWorkflowCategorySettingObject]/channel_types/anyOf[subschema #1: PreferenceSetChannelTypes]/in_app_feed/oneOf[subschema #2: PreferenceSetChannelTypeSetting]/conditions/items/operator`
  - …19 more
- …earlier changes not shown

[Full history](https://skmtc.dev/knocklabs/apis/knock-api/changes/v1/objects/:collection/:id/put.md)

---

[API](https://skmtc.dev/knocklabs/apis/knock-api.md) · [All operations](https://skmtc.dev/knocklabs/apis/knock-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/knocklabs/knock-api/revisions/4b8499dddbc5/schema)
