⚠️ Experimental — Resolves a Guild app-declared purpose to a workflow using the selection-only API. The endpoint uses POST but does not run a workflow, change assignments, or persist a server-side selection. Without requested_workflow_name, Guild selects the custom default or provisioned workflow for the purpose. Scoped to the provider’s workspace_id when set.
# The installed app must declare this purpose in workflow_purposes.
# Omit requested_workflow_name to use the custom default or provisioned workflow.
# This lookup selects a name; it does not execute or persist a workflow.
# WARNING: Terraform state retains the resolved workflow name; protect state access.
data "sg_app_workflow_selection" "investigation" {
app_name = "sre"
purpose = "investigate_alert"
}
output "investigation_workflow_name" {
value = data.sg_app_workflow_selection.investigation.workflow_name
}
# To use a custom workflow instead, first attach an approved workflow with
# sg_app.workflow_assignments (purpose, workflow_name, optional is_default),
# then set requested_workflow_name to that assigned name if needed.
app_name (String) Installed deployment-catalog app slug whose declared workflow purpose is resolved.purpose (String) App-declared workflow purpose ID to resolve (for example investigate_alert); it must be declared by the app.requested_workflow_name (String) Explicit workflow to select for this purpose. It must be assigned to the app and purpose. Omit to select the custom default or provisioned workflow.workflow_name (String) Guild-selected workflow name for the requested app purpose; use it with the workflow execution API. No assignment or selection is persisted.