---
title: "Update an event"
method: PATCH
path: "/cdp/{connection_id}/event/{id}"
tags: ["cdp", "event"]
---

# Update an event

`PATCH /cdp/{connection_id}/event/{id}`

## Request

- Base URL: `http://api.unified.to`
- URL: `http://api.unified.to/cdp/{connection_id}/event/{id}`
- Auth: API key in header `authorization`

## Path parameters

- `connection_id` string, required
- `id` string, required

## Query parameters

- `fields` string[]
- `raw` string

## Request body

- CdpEvent
  - `id` string: Unique identifier for this event object
  - `created_at` string, date-time: The date that this event object was ingested (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
  - `name` string: The specific event name (eg. "Product Purchased")
  - `type` 'TRACK' | 'PAGE' | 'SCREEN' | 'IDENTIFY' | 'GROUP' | 'ALIAS': The unified structural category of the event
  - `occurred_at` string, date-time: When the event actually happened (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
  - `profile_id` string: The profile this event is associated with; points to CdpProfile
  - `identifiers` CdpIdentifier[]: The identifiers that link this event to a profile
    - `type` 'EMAIL' | 'USER_ID' | 'ANONYMOUS_ID' | 'DEVICE_ID' | 'PHONE' | 'CRM_ID' | 'LOYALTY_ID' | 'OTHER': The type of the identifier (eg. EMAIL, USER_ID, ANONYMOUS_ID)
    - `value` string, required: The identifier value that resolves to the profile
    - `is_primary` boolean: Whether this is the primary identifier for the profile
    - `encoding` string: The encoding of the identifier value (eg. raw, sha256)
    - `source` string: The source that provided this identifier
  - `metadata` CdpMetadata[]: The event payload/properties
    - `id` string
    - `slug` string: The attribute/trait key (eg. lifetime_value)
    - `value` unknown
    - `namespace` string: The scope or origin of the attribute (eg. computed, event, visitor)
    - `format` 'TEXT' | 'NUMBER' | 'DATE' | 'BOOLEAN' | 'ARRAY' | 'OBJECT': The data type of the attribute value
    - `extra_data` unknown
  - `source` string: The source that produced this event
  - `source_id` string: The cdp_source this event originated from; points to CdpSource
  - `raw` unknown

## Response `200`

Successful

- CdpEvent
  - `id` string: Unique identifier for this event object
  - `created_at` string, date-time: The date that this event object was ingested (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
  - `name` string: The specific event name (eg. "Product Purchased")
  - `type` 'TRACK' | 'PAGE' | 'SCREEN' | 'IDENTIFY' | 'GROUP' | 'ALIAS': The unified structural category of the event
  - `occurred_at` string, date-time: When the event actually happened (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
  - `profile_id` string: The profile this event is associated with; points to CdpProfile
  - `identifiers` CdpIdentifier[]: The identifiers that link this event to a profile
    - `type` 'EMAIL' | 'USER_ID' | 'ANONYMOUS_ID' | 'DEVICE_ID' | 'PHONE' | 'CRM_ID' | 'LOYALTY_ID' | 'OTHER': The type of the identifier (eg. EMAIL, USER_ID, ANONYMOUS_ID)
    - `value` string, required: The identifier value that resolves to the profile
    - `is_primary` boolean: Whether this is the primary identifier for the profile
    - `encoding` string: The encoding of the identifier value (eg. raw, sha256)
    - `source` string: The source that provided this identifier
  - `metadata` CdpMetadata[]: The event payload/properties
    - `id` string
    - `slug` string: The attribute/trait key (eg. lifetime_value)
    - `value` unknown
    - `namespace` string: The scope or origin of the attribute (eg. computed, event, visitor)
    - `format` 'TEXT' | 'NUMBER' | 'DATE' | 'BOOLEAN' | 'ARRAY' | 'OBJECT': The data type of the attribute value
    - `extra_data` unknown
  - `source` string: The source that produced this event
  - `source_id` string: The cdp_source this event originated from; points to CdpSource
  - `raw` unknown

---

[API](https://skmtc.dev/unified/apis/unified-to-api-2.md) · [All operations](https://skmtc.dev/unified/apis/unified-to-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/unified/apis/unified-to-api-2/revisions/7a38bdd7f089?raw)
