> ## Documentation Index
> Fetch the complete documentation index at: https://docs.orq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Agent governance

> Set who builds an Agent, what a run may call and reach, what it may spend, and what each run records.

Agent governance runs on four axes. **Build** decides who creates an Agent and what it carries. **Run** decides what it may call and how long it may work. **Reach** decides which projects, gateways, and keys a run can touch. **Spend** decides what its requests may cost. **Audit** records the changes and the runs.

> [card] [Build](#build)
>
> **Admin** and **Developer** create, edit, and delete Agents; **Researcher** has view access.

> [card] [Run](#run)
>
> Max turns and max execution time bound what an Agent does at runtime.

> [card] [Reach](#reach)
>
> Gateway sharing and key scope decide which projects and tools a run can use.

> [card] [Spend](#spend)
>
> Budgets cap cost, tokens, and requests per minute, per scope.

## Build

The workspace role decides who builds Agents, and the same three roles apply to every Agent in the workspace.

| Role | Agents |
| - | - |
| **Admin** | Create, edit, duplicate, and delete |
| **Developer** | Create, edit, duplicate, and delete |
| **Researcher** | View |

The Agent then carries its own capability scope: the [tools](https://docs.orq.ai/ai-studio/ai-engineering/build-agents.md#add-tools), [MCP servers](https://docs.orq.ai/ai-studio/ai-engineering/build-agents.md#mcp-servers), [skills](https://docs.orq.ai/ai-studio/ai-engineering/skills.md), and knowledge bases attached to it. A run reaches what the Agent carries.

## Run

An Agent has no identity of its own: every run borrows the identity of the member or key that invokes it, and a key minted for its session carries that caller's grants. A member's session carries that member's role, and an API key carries the key's grants.

* **Tool approval**: not supported. An Agent runs its tools without waiting for a human decision, and `requires_approval` on a tool and `tool_approval_required` on the Agent have no effect. See [Tool approval](https://docs.orq.ai/ai-studio/ai-engineering/build-agents.md#tool-approval).
* **Max turns** and **max execution time**: 100 turns and 600 seconds by default, and execution time counts model thinking only, not tool calls. See [Runtime constraints](https://docs.orq.ai/ai-studio/ai-engineering/build-agents.md#configure-runtime-constraints).
* **Evaluators and guardrails**: attach them to the Agent to score its output. Output guardrails are skipped when the Agent streams, because they cannot run on partial chunks. See [Evaluators and Guardrails](https://docs.orq.ai/ai-studio/ai-engineering/build-agents.md#configure-evaluators-and-guardrails).

## Reach

* **MCP gateways**: a run reaches the gateways attached to its Agent, each shared with projects. A key minted for an Agent session carries only that Agent's gateways, and a gateway serves only the tools toggled on its **Toolset** tab. See [Project access](https://docs.orq.ai/ai-gateway/mcp-portal/mcp-gateways.md#project-access) and [Scope tools](https://docs.orq.ai/ai-gateway/mcp-portal/mcp-gateways.md#scope-tools).
* **API keys**: the key's permission domains, project scope, and `mcp_access` allowlist. `mcp_access` is set through the [API](https://docs.orq.ai/reference/api-keys/update-an-api-key.md). A [service account key](https://docs.orq.ai/ai-studio/organization/api-keys.md#service-account-keys) outlives the member who created it, which keeps production runs working when people leave. See [API keys](https://docs.orq.ai/ai-gateway/configuration/api-keys.md).

## Spend

* **Budgets**: cost, token, and requests-per-minute limits on a workspace, project, identity, API key, provider, or model. A request over the limit is rejected with `429`. See [Budgets](https://docs.orq.ai/ai-gateway/budgets.md).
* **Rate limits**: the workspace plan sets requests per minute, and the daily cap applies on Free. See [Rate limits](https://docs.orq.ai/ai-gateway/features/rate-limits.md).

## Limits

| Limit | What it means |
| - | - |
| Per-user tool scoping | Tools follow the gateway's exposure and the projects the caller reaches; a gateway cannot withhold one tool from one person. See [Per-user tool scoping](https://docs.orq.ai/ai-gateway/mcp-portal/mcp-gateways.md#per-user-tool-scoping). |
| Permissions per team | MCP permissions follow the workspace role and stay the same per team and per gateway. Give a team its own tools with its own gateway. See [Roles and Permissions](https://docs.orq.ai/ai-gateway/mcp-portal/mcp-gateways.md#roles-and-permissions). |
| Guardrail Rules on tool calls | Guardrail Rules cover model traffic. Attach the **Guardrail** or **Evaluator** to the gateway that serves the tools to check its tool calls, with no rule conditions. See [Guardrails](https://docs.orq.ai/ai-gateway/mcp-portal/mcp-gateways.md#guardrails). |

## Audit

Changes to Agents and Agent Schedules are recorded in [Audit logs](https://docs.orq.ai/ai-studio/organization/audit-logs.md#tracked-entities) under the `agent` and `agent_schedule` entities, and each run leaves [Traces](https://docs.orq.ai/ai-studio/observability/traces.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.