Skip to main content
Custom object events are published when custom objects are created, updated, or deleted within the platform. These events enable integrations to stay synchronized with custom business data and workflows. These events are delivered through the platform events system.

Developer quickstart

Minimal handler (custom objects only)

Checklist

  • Validate eventData against your configured schema per organization.
  • Track field-level changes for analytics and workflow triggers.
  • Use idempotency when syncing to CRMs/ERPs to avoid duplicates.

Event structure

Custom object events follow a flexible structure to accommodate various custom object types:

Event publishing

Custom object events are published through a dedicated platform publisher service with the following characteristics:

Event attributes

All custom object events include these platform event attributes:
  • event_name - The specific event type
  • event_id - Unique event identifier (or generated UUID if not provided)
  • event_timestamp - Unix timestamp of the event
  • context_user_id - ID of the user who triggered the event
  • context_user_type - Type of the user (AGENT, CUSTOMER, etc.)
  • context_organization_id - Organization ID

Ordering

Where applicable, events are ordered per organization or configured scope.

Event types

Since custom objects are flexible by nature, the specific event types depend on the custom object definitions. However, common patterns include:

Lifecycle events

custom-object:{type}:created

Triggered when a new custom object is created. Example for a “Deal” custom object:

custom-object:{type}:updated

Triggered when a custom object is updated. Example payload:

custom-object:{type}:deleted

Triggered when a custom object is deleted. Example payload:

Field-specific events

custom-object:{type}:field:{field_name}:changed

Triggered when specific important fields change. Example for stage changes:

Integration examples

CRM synchronization

Workflow automation

Analytics and reporting

Real-time notifications

Event processing considerations

Payload flexibility

Since custom objects can have varying structures, event processing should be robust:

Error handling

Best practices

  1. Schema validation: Always validate custom object data against defined schemas
  2. Event versioning: Consider versioning for custom object event schemas
  3. Error handling: Implement robust error handling for flexible data structures
  4. Performance: Monitor processing times for complex custom objects
  5. Security: Validate permissions for custom object access
  6. Documentation: Document custom object event schemas for each organization

Configuration

Custom object events can be configured per organization:
This configuration allows organizations to customize which events are published and how they’re processed, providing flexibility while maintaining consistency in the event structure.