Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Define what your AI agents can do. Enforce policies at runtime. Stay in control across frameworks, platforms, and clouds.
AI agents are moving beyond conversations. They retrieve sensitive information, invoke tools, execute transactions, interact with enterprise systems, and increasingly make decisions on behalf of users and organizations.
As agents become more autonomous, a fundamental question emerges: How do you give agents the freedom to act without giving up control over what they are allowed to do?
System prompts and traditional AI safety filters provide important protections, but they aren't sufficient to govern every action an autonomous agent might take. An agent can generate perfectly acceptable text while issuing an unauthorized refund, accessing restricted records, or invoking a tool in violation of company policy.
Enterprises need a way to define boundaries around agent behavior, evaluate actions as they happen, and enforce consistent policies without hardcoding business rules into every agent.
Agent Controls is a managed policy service that enables developers and organizations to define, centrally manage, and evaluate policies governing AI agent behavior at runtime.
Built on the open-source Agent Control Specification (ACS) and Agent Hooks, Agent Controls brings managed policy evaluation to agents built across different frameworks, platforms, and clouds.
With Agent Controls, you can:
- Control what agents do, not just what they say. Define policies for tool execution, business transactions, sensitive information access, and generated content.
- Go beyond traditional safety filters. Combine deterministic business rules, built-in content safety classifiers, and supported LLM-based evaluations to make context-aware policy decisions.
- Enforce policies at runtime. Evaluate proposed actions and responses at critical intervention points before allowing the agent to proceed.
- Centrally manage and reuse policies. Define policies once, manage them independently of application code, and apply them consistently across multiple agents and applications.
- Preserve visibility into policy decisions. Receive evaluation receipts identifying the policy and version used, so application teams can associate decisions with actual execution outcomes.
Agent Controls separates policy decisions from agent execution. The service evaluates policies and returns decisions such as allow, deny, or transform. The agent runtime or application remains responsible for enforcing those decisions.
Why Agent Controls?
Agents are no longer just generating content. They're taking action.
Traditional approaches to AI safety focus on the inputs and outputs of AI models: detecting harmful content, protecting sensitive information, or preventing unsafe responses.
But autonomous agents introduce a new class of risks. Consider an AI agent responsible for handling customer support requests. The agent can look up customer information, process refunds, update account details, and communicate with customers.
The agent might be instructed not to issue refunds over $100. But what happens when a customer persuades it to issue a $500 refund?
- A system prompt can describe the restriction, but it can't independently prevent execution if the model produces the prohibited tool call.
- A content safety classifier can evaluate whether a response contains harmful or sensitive content, but it doesn't inherently know whether a refund is within the company's financial limits.
- And a generic approval workflow might require human review for every refund, undermining the efficiency and autonomy the organization hoped to achieve.
The challenge isn't simply making agents safer. It's making autonomy governable.
From rigid workflows to controlled autonomy
Enterprises want AI agents that can adapt, reason, and act independently. But they also need assurances that agents will operate within their organizational policies.
Historically, this need has often meant choosing among three approaches:
- Constrain autonomy. Define highly prescriptive workflows and deterministic rules for every possible action.
- Introduce human checkpoints. Require people to approve potentially consequential actions, increasing operational overhead.
- Accept greater uncertainty. Give agents broader autonomy while relying heavily on prompts and application-specific checks to prevent unwanted behavior.
None of these approaches fully addresses the need for autonomous agents operating within enforceable business boundaries.
Agent Controls introduces another approach: define the boundaries centrally, evaluate agent behavior at runtime, and allow agents to operate autonomously within those boundaries. Instead of trying to prescribe every step an agent must take, organizations can define the conditions under which an action is permitted.
For example, a policy might allow a support agent to issue refunds below $100, deny refunds above that amount, and identify actions requiring human review. The agent remains free to determine how to complete a task, but the application enforces the configured policy when relevant actions are attempted. This approach makes it possible to introduce greater autonomy without making every business decision dependent on the model's willingness to follow instructions.
Built on an open foundation: Agent Hooks and ACS
Developers build AI agents by using different frameworks, models, programming languages, and cloud platforms. Enterprises might operate agents in Microsoft Foundry alongside agents built by using other frameworks or hosted in other environments.
Runtime controls shouldn't require every agent to be rewritten for a single platform or every development team to invent a new policy enforcement mechanism.
That's why Microsoft introduced two complementary open-source building blocks.
Agent Hooks: Intercept actions at the right moment
Agent Hooks defines standardized intervention points in the agent execution lifecycle.
These hooks give agent runtimes an opportunity to pause execution and consult a policy evaluator before proceeding.
For example, an agent runtime can intercept:
- Incoming input: Before a user request enters the agent's execution flow.
- Model interactions: Before a model request is sent or after its response is received.
- Tool execution: Before a tool call is executed or after its result is returned.
- Agent output: Before the final response is released to the user.
- Agent lifecycle events: When an agent session starts or shuts down.
Agent Hooks provides the interception and enforcement mechanism. It doesn't determine which business rules or safety policies should apply. That responsibility belongs to a policy evaluator.
Agent Control Specification (ACS): Define what is allowed
The open-source Agent Control Specification (ACS) provides a common policy model and evaluation runtime for governing agent behavior.
ACS lets developers describe policies independently of the agent's implementation.
A policy can specify:
- Which agent actions or lifecycle events it governs.
- What content, tool arguments, or runtime context should be evaluated.
- Which deterministic rules or supported evaluators should be applied.
- What decision should be returned when policy conditions are met.
For example, an ACS policy can express that a refund operation is only permitted when the requested amount is within the organization's configured threshold. Rather than burying that restriction in a system prompt or duplicating it across tool wrappers, developers can express the requirement as an explicit, executable policy.
ACS policies can be evaluated using the open-source runtime within an application, or through the managed agent control service.
Open by design. Portable across agent ecosystems.
Agent Hooks and ACS are designed to separate the agent runtime, policy evaluation, and enforcement mechanism. This separation is fundamental to cross-platform and cross-cloud agent governance. Developers can integrate the open-source building blocks with their chosen agent hosts while maintaining a common approach to describing and evaluating policies.
The resulting architecture doesn't require the underlying agent to run in Microsoft Foundry or use a specific model provider. Agent runtimes need to implement the relevant interception points, supply trustworthy execution context, and enforce policy decisions. The open-source foundation makes these integrations possible without requiring every agent framework to adopt a completely different policy model.
From open-source building blocks to enterprise-scale control
The open-source building blocks give developers the flexibility to implement runtime controls within their own applications. But large organizations face an additional challenge. They rarely have just one agent. They might have hundreds or thousands of agents developed by different teams, using different frameworks, and running across multiple environments.
Without centralized policy management, each team must independently store, configure, distribute, and update its policies. That creates operational challenges:
- How can security and governance teams establish policies that apply consistently across applications?
- How can developers reuse organizational rules without duplicating policy logic?
- How can policy owners update requirements without coordinating application releases across dozens of teams?
- How can organizations understand which policy version was evaluated when an agent took a particular action?
- How can they support different agent frameworks without introducing separate governance systems for each one?
This is where Agent Controls extends the open-source foundation. Agent Controls provides centralized policy management and hosted policy evaluation built on ACS. Policy owners can create and manage shared policies, while developers integrate their applications with a common evaluation API. Rather than deploying an independent copy of every policy into every application, teams can reference centrally managed policies by ID.
When an agent needs to evaluate an action, its host sends the relevant runtime context to Agent Controls. The service evaluates the selected policy and returns a decision for the host to enforce. This provides a common managed policy layer for heterogeneous agent environments, without requiring the service itself to host or execute those agents.
How Agent Controls works
Agent Controls follows a straightforward runtime control flow:
- Define and publish policies. Policy owners author ACS policies describing permitted and prohibited behaviors, then publish the policies to Agent Controls.
- Intercept an agent action. An agent runtime captures an action or content at a relevant intervention point, such as immediately before a tool call.
- Evaluate the applicable policy. The runtime calls Agent Controls, providing the proposed action, execution context, and the policy to evaluate.
- Return a decision. Agent Controls evaluates the policy, including any configured observations, and returns a verdict and evaluation receipt.
- Enforce the decision. The agent runtime allows, blocks, or transforms the proposed operation according to the returned verdict.
Agent Hooks determines when to check. ACS defines how policies are expressed and evaluated. Agent Controls provides centralized management and hosted evaluation. The agent runtime enforces the decision.
Example: A refund agent operating within business boundaries
Imagine an enterprise deploying a customer support agent that can process refunds. The organization defines the following policies:
| Policy | Desired behavior |
|---|---|
Refund amount must not exceed $100 |
Deny refund requests above the threshold |
| Customer information may only be shared with approved destinations | Deny unauthorized transfers |
| Responses must not expose sensitive personal information | Evaluate content and block or transform when required |
| Certain customer commitments require approval | Deny the immediate action and initiate the host's review process |
Now imagine the agent proposes the following tool call:
{
"tool": "refund_order",
"arguments": {
"order_id": "demo-001",
"amount": 150
}
}
Before executing the operation, the agent runtime intercepts the proposed tool call at the pre_tool_call intervention point. The runtime sends the proposed action and its context to Agent Controls. Agent Controls evaluates the applicable ACS policy. The deterministic rule checks the refund amount against the organization's permitted threshold.
Because $150 exceeds the $100 maximum, the policy returns a deny verdict. The agent runtime enforces that verdict by preventing the refund tool from executing.
By contrast, a refund of $75 would satisfy the policy and return allow. The agent isn't required to request human approval for every action, nor is it required to follow a rigid predefined sequence of steps. It can operate within the boundaries established by the organization.
This example illustrates the central value of runtime policies: agents can remain autonomous in how they perform tasks while being constrained in which actions they are allowed to execute.
ACS and hosted Agent Controls: Which should you use?
The open-source ACS runtime and hosted Agent Controls share the same policy foundation but serve different operational needs.
| Capability | Open-source, in-process ACS | Hosted Agent Controls |
|---|---|---|
| Define policies using ACS | Yes | Yes |
| Evaluate deterministic Rego policies | Yes | Yes |
| Run policy evaluation | Open Source SDK | Microsoft-managed service |
| Publish and update policies | Application-managed files or custom infrastructure | Shared ARM policy and Rego resources |
| Configure observations | Application-configured annotators | Supported Content Safety classifiers and enabled LLM judges |
| Reuse policies across applications | Through custom distribution and integration | Through centrally managed policy resources |
| Intercept agent execution | Agent host | Agent host |
| Enforce policy verdicts | Agent host | Agent host |
Use open-source ACS when you want to embed and operate policy evaluation within your own application or infrastructure.
Use hosted Agent Controls when you want to centrally manage policies and rely on a managed service for policy evaluation across agents and applications.
The two approaches are complementary. An organization can use the open-source building blocks for application integration and local development, while using hosted Agent Controls for shared enterprise policies.
Core concepts
Agent host
The host is the application, agent runtime, or gateway that owns execution. It knows when a model request, tool call, or output is about to occur. It constructs the context, calls Agent Controls, and decides whether execution can continue.
The host must report the actual action and use the evaluated values. Evaluating one set of tool arguments and dispatching another bypasses the policy.
Intervention point
An intervention point identifies when a policy applies.
| Point | Evaluate before |
|---|---|
agent_startup |
Starting a session |
input |
Accepting an external input into the agent |
pre_model_call |
Dispatching a model request |
post_model_call |
Consuming a completed model response |
pre_tool_call |
Dispatching a tool call |
post_tool_call |
Consuming a completed tool result |
output |
Releasing final output |
agent_shutdown |
Completing session shutdown |
The ACS policy specifies the intervention points at which its rules apply. The agent host calls Agent Controls at those points to evaluate the corresponding action or content.
Pre-call evaluations determine whether a model request or tool call can proceed. Post-call evaluations govern the use of responses and results after the underlying operation has completed.
Manifest and Rego
An Agent Controls policy consists of two parts: a JSON manifest and one or more Rego modules.
The manifest selects the lifecycle point, runtime value, and Rego rules under evaluation. Rego expresses the decision logic. Rego modules are uploaded separately and referenced by the ARM policy.
For example, a customer-support agent proposes a refund_order tool call with an order ID and a refund amount of 75. The business policy permits refunds of up to 100.
To enforce this limit, the manifest binds the pre_tool_call intervention point to the Rego query data.refund_guard.verdict. It selects tool_call.args from the submitted payload as the evaluation target.
The Rego rule uses the tool name to identify a refund request. It verifies deterministically that the amount is numeric, greater than zero, and no greater than 100.
Snapshot and target
The snapshot describes the current agent event at an intervention point. For a proposed tool call, it includes the tool's name and arguments, together with the agent and session details.
The target is the part of that snapshot the policy is configured to check. In the refund example, the manifest selects the tool arguments:
Snapshot: proposed tool call
Tool name: refund_order
Arguments: <-- target
order_id: demo-001
amount: 75
Agent and session details
Rego can inspect the whole snapshot, including the selected arguments. The target gives policies a consistent reference to the data being checked, regardless of the intervention point. It also identifies the data that a permitted transformation can change.
Annotator
An annotator checks content for a policy. It runs before Rego and returns an annotation, such as a detected category, a label, or a score.
Agent Controls currently supports two types of annotators:
- Azure AI Content Safety classifiers detect configured categories, such as prompt injection and violence.
- LLM judges classify content using custom written criteria in the policy.
The manifest specifies which annotator to run, at which intervention point, and what content it checks. Rego uses the returned annotation as input alongside the snapshot and targets when evaluating the policy.
For example, a support policy might prohibit refund promises in customer responses. At the output intervention point, an LLM judge checks the proposed response and might label it commitment. The Rego rule can then use the label and return deny.
Verdict
A verdict is the result of a policy evaluation. It tells the agent host whether the proposed action can proceed, must be blocked, or requires a change first.
allow: The host can run the proposed action or release the content as submitted.deny: The host blocks the action or withholds the content.transform: The host applies the change specified in the verdict to the target, validates the result, and proceeds with the updated data.
In the refund example, the rule permits a valid amount of 75 and returns allow. An amount of 150 exceeds the limit, so the rule returns deny and the host doesn't issue the refund. A different policy might return transform to redact a field in a response before it is released.
A verdict can also include:
- Warnings, which provide additional information without changing the decision.
- An approval request, which accompanies a
denydecision and includes details for the host's review process. The action stays blocked until the host's configured approval workflow approves it.
Evaluation receipt
An evaluation receipt is a record returned with the verdict. It identifies the policies and versions evaluated, the intervention point checked, and an evaluation ID. The host uses the receipt to verify that the result matches its request and expected policy.
For example, the receipt for a refund check identifies the policy version used to evaluate that call. The host records the evaluation ID alongside the actual refund outcome, such as issued or blocked. This process lets operators trace the application's action back to the policy evaluation.
Use Agent Controls with your application
Agent Controls provides two complementary API surfaces:
Control plane: Manage policies
Use the Azure Resource Manager (ARM) control plane to publish, update, and manage ACS policy resources and reusable Rego modules.
Data plane: Evaluate policies
Use the Unified Moderate data plane API to evaluate actions and content against centrally managed policies.
For the standalone policy evaluation flow, the application selects a policy by using the policyId query parameter and supplies the relevant execution context.
The service returns the evaluation verdict and receipt for the calling application to process.
The project-scoped API profile uses targetResourceId and has separate authorization and receipt requirements. It isn't an interchangeable selector for the standalone policyId flow.
For complete examples, see Agent Controls code samples.
Understand the enforcement boundary
Agent Controls doesn't run your agent, execute its tools, sandbox its process, or control a path that bypasses your interception code. It doesn't infer a user's permissions from a prompt or make a model-generated identity claim trustworthy.
Keep authorization and authoritative business data in trusted application systems. Use policies to decide what can proceed based on correctly constructed contexts, and verify enforcement in the host.
Billing
During public preview, you pay only for classifier and LLM usage triggered by Agent Controls policy evaluation.
Content Safety classifier usage is billed according to Content Safety pricing. If your policy invokes an LLM judge, you're also responsible for the associated model usage charges.