terraform-provider-stackgen

sg_agents (Data Source)

⚠️ Experimental — Lists all StackGen AI agents in the organization. When provider workspace_id is set, the list is scoped to that workspace.

Example Usage

# When to use: Inventory agents in the org (names, models, integrations) for
# reporting or to discover which agents already exist before creating new ones.
data "sg_agents" "all" {}

output "agent_names" {
  value = [for a in data.sg_agents.all.agents : a.name]
}

Schema

Read-Only

Nested Schema for agents

Read-Only:

Nested Schema for agents.auto_approve_tools

Required:

Optional: