Inspect

Inspect events

An Inspect event trigger starts a run when an administrative change happens in your organization, such as a repository being added, a role being granted, or an API key being created. Use it to notify a team, review a change against policy, or set up something new automatically, like onboarding a repository the moment it's added.

Requirements

  • Saving the trigger requires the View audit logs and usage role (or Admin), for both the person saving and the automation's owner. Runs see event details from the audit log.
  • If the owner later loses that permission, matching events stop starting runs.
  • If Inspect event isn't listed under Add trigger, it isn't enabled for your organization.

Add the trigger

Select Inspect event under Add trigger and choose one Event. To react to several events, add one trigger per event.

  • Automations and skills: automation.created, automation.updated, automation.archived, automation.unarchived, skill.created, skill.updated, skill.archived
  • Repositories: repository.added, repository.updated, repository.removed
  • Connectors: connector.created, connector.updated, connector.deleted
  • Environment: environment_variable.created, environment_variable.updated, environment_variable.deleted, egress_secret.created, egress_secret.updated, egress_secret.deleted, shared_build_script.created, shared_build_script.updated, shared_build_script.deleted
  • People: user_invitation.created, user_invitation.revoked, user_invitation.accepted, user.provisioned, user_role.granted, user_role.revoked, user.deactivated, user.reactivated
  • API keys: api_key.created, api_key.updated, api_key.rotated, api_key.revoked
  • Organization: organization_review_agent_settings.updated, organization_model_defaults.updated

Filter events

Under Run only when, add up to 20 conditions on the event's details. Each condition has:

  • Field path: a dot path into the event details, such as name or repository. Use numbers for list positions, such as items.0.
  • Operator: contains, does not contain, starts with, ends with, is exactly, is not exactly, matches regex, exists, or does not exist.
  • Value, for operators that compare one.

Text comparisons and regexes ignore case. A list field matches when any item matches. A run starts only when every condition matches; with none, every occurrence of the event starts a run.

Payload

FieldTypeDescription
eventstringThe event name.
actor_idstringThe user who caused it.
session_idstringThe session that caused it, when one did.
payloadobjectThe event's details, such as the repository added or the automation changed.

Each event starts at most one run per automation.

Loop protection

An automation that reacts to Inspect events can cause new ones, for example by editing an automation. To keep runs from triggering each other:

  • Events caused by an automation run's sessions, or by their child sessions, never start Inspect event runs.
  • Each automation starts at most 20 Inspect event runs per hour. Matching events beyond that are skipped.