v1

latestOpenAPI 3.0.32026-07-1271839.7 KB
Validation Rules

addUsedByReference

Adds a single used_by reference to an existing validation rule.

Use this endpoint when attaching a validation rule to a journey block or entity attribute to track where the rule is applied.

post/v1/validation-rules/{ruleId}/used-by

Path parameters

ruleIdstring required

The unique identifier of the validation rule to update.

Request body

type'journey' | 'entity' required

The context in which the rule is used - either a journey block or an entity schema attribute.

schema_slugstring

Slug of the entity schema using this rule. Only applicable when type is entity.

source_idstring

Unique identifier of the source (e.g. journey ID or entity attribute key) that references this rule.

Example request

{
  "type": "journey",
  "source_id": "journey-xyz789"
}

Response

Success

titlestring required

Title of the validation rule.

placeholderstring

Placeholder for the validation rule.

_schema_versionstring required

Schema version of the validation rule.

_idstring required

Unique identifier for the validation rule.

_organization_idstring required

Organization ID that owns this rule.

created_atstring required

ISO timestamp when the rule was created.

updated_atstring required

ISO timestamp when the rule was last updated.

created_bystring required

User ID of the creator.

updated_bystring required

User ID of the last updater.