roboto.domain.triggers.targets#
Module Contents#
- class roboto.domain.triggers.targets.InvokeActionTarget(/, **data)#
Bases:
_TargetSpecBaseStored configuration for invoking an action when a trigger fires.
Spec only — dispatch behavior lives server-side. String leaves of
parameter_values,required_inputs, andadditional_inputsmay contain{{...}}placeholders resolved against the event namespace at dispatch time.- Parameters:
data (Any)
- action: roboto.domain.actions.action_record.ActionReference#
The action to invoke.
ownerdefaults to the trigger’s org when omitted anddigestto the action’s latest version.
- additional_inputs: list[str] | None = None#
Optional extra file patterns passed as invocation inputs beyond the required ones.
- compute_requirement_overrides: roboto.domain.actions.action_record.ComputeRequirements | None = None#
Optional compute requirement overrides for the invocation.
- container_parameter_overrides: roboto.domain.actions.action_record.ContainerParameters | None = None#
Optional container parameter overrides for the invocation.
- invocation_input: roboto.domain.actions.invocation_record.InvocationInput | None = None#
Optional query-based input selection (files, topics, sessions) resolved when the invocation runs. The way a schedule-fired trigger names its inputs, since a schedule fires with no file subject; may also accompany an event-fired trigger’s patterns.
- model_config#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- parameter_values: dict[str, Any] = None#
Parameter values passed to the action; string leaves may be templated.
- referenced_placeholders()#
Return every
{{name}}placeholder referenced by this target’s templated fields.- Return type:
set[str]
- required_inputs: list[str] = None#
File patterns (e.g.
**/*.bag) that gate dispatch on the firing event’s files, for file- and dataset-scoped events. May be empty for events with no file subject (e.g. invocation events).
- subject_types: ClassVar[frozenset[roboto.uri.RobotoUriType] | None]#
The action runs against the event’s dataset, and a file event names its dataset too.
- target_id: str#
Stable id of this target within its trigger. Part of the dispatch idempotency key: the target’s once-per history is kept under this id, so renaming it (or replacing it with an identical target under a new id) starts a fresh history and the target fires again for subjects the old id already fired for.
- timeout: int | None = None#
Optional invocation timeout override, in minutes.
- type: Literal[TriggerTargetType]#
Discriminator for
TriggerTargetSpec.
- upload_destination: roboto.domain.actions.invocation_record.InvocationUploadDestination | None = None#
Optional destination for the invocation’s output files.
- class roboto.domain.triggers.targets.SendSlackMessageTarget(/, **data)#
Bases:
_TargetSpecBaseStored configuration for posting a Slack message when a trigger fires.
Spec only — dispatch behavior lives server-side. The channel must be on the org’s Slack outbound allowlist at dispatch time.
- Parameters:
data (Any)
- channel_id: str#
Slack channel to post to.
- model_config#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- referenced_placeholders()#
Return every
{{name}}placeholder referenced by this target’s templated text.- Return type:
set[str]
- target_id: str#
Stable id of this target within its trigger; part of the dispatch idempotency key.
- text: str#
Message body; may contain
{{...}}placeholders resolved against the event namespace.
- type: Literal[TriggerTargetType]#
Discriminator for
TriggerTargetSpec.
- class roboto.domain.triggers.targets.StartAgentTarget(/, **data)#
Bases:
_TargetSpecBaseStored configuration for starting an agent thread when a trigger fires.
Spec only — dispatch behavior lives server-side. Each value in
valuesis a template resolved against the event namespace, then handed to the agent’s own variable resolution as a plain value.- Parameters:
data (Any)
- agent_id: str#
The agent definition to launch.
- analysis_scope: roboto.ai.core.AnalysisScope | None = None#
Optional analysis scope for the resulting thread.
- model_config#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- referenced_placeholders()#
Return every
{{name}}placeholder referenced by this target’s templated values.- Return type:
set[str]
- target_id: str#
Stable id of this target within its trigger; part of the dispatch idempotency key.
- type: Literal[TriggerTargetType]#
Discriminator for
TriggerTargetSpec.
- values: dict[str, str] = None#
Agent variable name to a template string resolved against the event namespace.
- visibility: roboto.ai.agent_thread.record.ThreadVisibility#
Visibility of the resulting agent thread.
- roboto.domain.triggers.targets.TriggerTargetSpec#
A trigger target spec, discriminated on
type.
- class roboto.domain.triggers.targets.TriggerTargetType#
Bases:
roboto.compat.StrEnumThe kind of thing a trigger does when it fires.
- InvokeAction = 'invoke_action'#
Invoke a containerized action.
- SendSlackMessage = 'send_slack_message'#
Post a message to a Slack channel on the org’s allowlist.
- StartAgent = 'start_agent'#
Start an AI agent thread from a saved agent definition.
- roboto.domain.triggers.targets.target_catalog_manifest()#
Which kinds of entity each target can act on, as the web UI’s target picker reads it.
target_catalog.jsonin this package is this function’s output, written byscripts/gen_trigger_manifests.pyand drift-checked by a test on each side.- Return type:
dict[str, Any]