v5

latestOpenAPI 3.1.02026-08-025631,1012.8 MB
Cluster Triggers

Create Cluster Trigger

Create a new trigger for automated cluster execution.

Supports multiple trigger types:
- **cron**: Execute at specific times using cron expressions
- **interval**: Execute at fixed intervals
- **event**: Execute when specific events occur (e.g., documents added)
- **conditional**: Execute when conditions are met (e.g., drift threshold)
post/v1/clusters/triggers

Request body

cluster_idstring nullable

OPTIONAL. Reference to existing cluster definition. If provided, execution_config is inherited from the cluster. Either cluster_id OR execution_config must be provided.

trigger_type'cron' | 'interval' | 'event' | 'conditional' required

Type of trigger for automated cluster execution.

Supported trigger types:

  • cron: Schedule-based execution using cron expressions (e.g., daily at 2am)
  • interval: Fixed-interval execution (e.g., every 6 hours)
  • event: Event-driven execution (e.g., after 100 documents added)
  • conditional: Condition-based execution (e.g., when drift exceeds threshold)
schedule_configobject required

REQUIRED. Type-specific schedule configuration. Contents depend on trigger_type. See trigger type examples above for required fields.

descriptionstring nullable

OPTIONAL. Human-readable description of what this trigger does. Helpful for identifying triggers in dashboards.

status'active' | 'paused' | 'disabled' | 'failed'

Status of a cluster trigger.

Example request

{
  "description": "Daily clustering at 2am UTC",
  "execution_config": {
    "collection_ids": [
      "col_abc123"
    ],
    "config": {
      "algorithm": "kmeans",
      "min_cluster_size": 2,
      "n_clusters": 5
    }
  },
  "schedule_config": {
    "cron_expression": "0 2 * * *",
    "timezone": "UTC"
  },
  "trigger_type": "cron"
}

Response

Successful Response

trigger_idstring

Unique trigger ID

cluster_idstring nullable

Optional link to cluster definition

namespace_idstring required

Namespace ID

internal_idstring required

Organization internal ID

trigger_type'cron' | 'interval' | 'event' | 'conditional' required

Type of trigger for automated cluster execution.

Supported trigger types:

  • cron: Schedule-based execution using cron expressions (e.g., daily at 2am)
  • interval: Fixed-interval execution (e.g., every 6 hours)
  • event: Event-driven execution (e.g., after 100 documents added)
  • conditional: Condition-based execution (e.g., when drift exceeds threshold)
schedule_configobject required

Type-specific schedule configuration

status'active' | 'paused' | 'disabled' | 'failed'

Status of a cluster trigger.

last_triggered_atstring date-time nullable

Last time trigger fired

last_execution_job_idstring nullable

Job ID of last execution

next_scheduled_atstring date-time nullable

Next scheduled execution time

execution_countinteger

Total executions

consecutive_failuresinteger

Consecutive execution failures

last_execution_statusstring nullable

Status of last execution

last_execution_errorstring nullable

Error from last execution

event_counterinteger

Current event count since last trigger

last_cooldown_atstring date-time nullable

Last time cooldown was applied

created_atstring date-time

Creation timestamp

updated_atstring date-time

Last update timestamp

created_bystring nullable

User who created trigger

descriptionstring nullable

Trigger description

Example response

{
  "execution_config": {
    "collection_ids": [
      "col_abc123"
    ],
    "config": {
      "algorithm": "kmeans",
      "min_cluster_size": 2,
      "n_clusters": 5
    }
  }
}