---
title: "Create Custom Field Trigger"
method: POST
path: "/custom_field_triggers"
tags: ["custom_field_triggers"]
---

# Create Custom Field Trigger

`POST /custom_field_triggers`

## Request body

- CreateCustomFieldTriggerRequest — Create a SET_CUSTOM_FIELD trigger. Server validates all references so the UI can't produce a trigger that would silently never fire or write garbage.
  - `source_custom_field_id` string, uuid, required
  - `trigger_option_id` string, uuid, required
  - `target_custom_field_id` string, uuid, required
  - `value_source` 'current_timestamp' | 'literal', required — Where a SET_CUSTOM_FIELD action's written value comes from.
  - `value_literal` string, nullable
  - `overwrite_policy` 'set_if_empty' | 'always' — Whether a SET_CUSTOM_FIELD action may overwrite an existing value.

## Response `200`

Successful Response

- CustomFieldTriggerResponse
  - `trigger_id` string, uuid, required
  - `action_type` 'set_custom_field', required — What a trigger does — the discriminator for its typed child table. New actions (notifications, tasks, workflows) are added as new values here plus their own `custom_field_trigger_<action>` child table; nothing reshapes.
  - `enabled` boolean, required
  - `source_custom_field_id` string, uuid, required
  - `source_field_name` string, nullable
  - `trigger_option_id` string, uuid, nullable
  - `trigger_option_label` string, nullable
  - `target_custom_field_id` string, uuid, nullable
  - `target_field_name` string, nullable
  - `target_definition_type` 'DROPDOWN' | 'FREE_TEXT' | 'MULTISELECT' | 'NUMBER' | 'DATE' | 'BOOLEAN' | 'USER' | 'MULTI_USER'
  - `value_source` 'current_timestamp' | 'literal' — Where a SET_CUSTOM_FIELD action's written value comes from.
  - `value_literal` string, nullable
  - `overwrite_policy` 'set_if_empty' | 'always' — Whether a SET_CUSTOM_FIELD action may overwrite an existing value.

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/kobaltlabs/apis/fastapi.md) · [All operations](https://skmtc.dev/kobaltlabs/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/kobaltlabs/fastapi/revisions/425d5b8a3c17/schema)
