Promote a custom-activity property
Promotes a custom-activity property into the evaluable registry — registering
(activity_name, property_name) → type so a Segment's SendQL predicate can
reference it as activity.<activity>.<property>. enum_values is required when
type is enum and rejected otherwise. An invalid name or type, or exceeding
the per-activity promoted-property cap, returns 422 validation_failed.
A built-in property returns 409 conflict: the six page properties carried
by every site_* activity (path, referrer, title, utm_source,
utm_medium, utm_campaign) are already evaluable everywhere, so there is
nothing to promote and a second definition could disagree about the type.
Request body
Content type: application/json
activity_name string required The custom activity whose property to promote; a lowercase identifier.
property_name string required The property key to promote; a lowercase identifier.
type string enum required One of: string, number, bool, datetime, enum
enum_values array<string> optional Required when type is enum; must be empty/omitted otherwise.
description string optional Responses
Errors follow the RFC 7807 problem format — see the error reference.
id string<uuid> required activity_name string required The custom activity whose property this promotes; a lowercase identifier.
property_name string required The property key inside the activity's properties; a lowercase identifier.
type string enum required One of: string, number, bool, datetime, enum
enum_values array<string> optional Allowed values when type is enum; omitted otherwise.
description string required created_at string<date-time> required updated_at string<date-time> required code is conflict.
application/problem+json validation_failed Problem. When the refusal is about a
reference — a segment key, template slug, topic or attribute name the
organization does not have — it additionally carries validation_code,
field, line/column, missing, candidates and next_step, so a
client can correct the call without a second round of guessing. See
ValidationProblem.
application/problem+json code is internal_error. The
request_id field can be quoted to SendOps support to investigate.
application/problem+json