Docs

How does a policy decision work?

Match the caller and target, resolve rule priority, then apply the connection mode.

Product v2.0.0Explanation / guide

This page is a rebuild draft for team review. Check your deployed version before applying its instructions.

A policy answers a concrete access question

For example: “May the support assistant invoke this query tool against the payroll resource?” The useful pieces are the caller, action, target, conditions, effect, and priority.

A binding attaches a rule to a catalog entity, such as a tool or resource. A selector narrows which requests match. A rule's lifecycle state also matters: a draft should not be treated as a published access rule.

Priority comes before effect

In the current Data Plane evaluator, the highest-priority matching rule determines the decision for a target. If rules at that highest priority disagree, deny wins. If no rule matches the primary target, evaluation returns an implicit deny.

Matching rules for one targetResult
Allow at 100, deny at 200Deny
Deny at 100, allow at 200Allow
Allow at 100, deny at 100Deny
No matching ruleImplicit deny

“Deny always overrides allow” is too broad for this evaluator. Deliberately inspect priority when reviewing policy.

A call can touch more than one target

The gateway may evaluate the tool and supported resources or columns inferred from its arguments. A deny at a relevant additional target can block the whole call even when the tool itself was allowed. An additional target with no matching rules is treated differently from a primary-target implicit deny.

That is why allowing a query tool does not necessarily authorize every table it can query. Target recognition depends on catalog entries, argument extraction, and the request shape. Data granularity explains the boundary.

Decision and execution are different

Server modePolicy deniesDoes the ordinary call proceed?
ObserveThe response retains a deny verdict with an observe explanationYes, for this policy-mode path
SimulateThe response retains a deny verdict with a simulate explanationYes, for this policy-mode path
EnforceThe denial is appliedNo

These modes do not turn an actual invocation into a dry run. A /gateway/check request checks policy without calling the upstream tool. A /gateway/invoke request may execute work in observe or simulate mode. Actor-blocking and other validation paths have their own behavior; use the returned fields and relevant reference.

Inspect the evidence

Read decision, allowed, policyMode, matchedRules, explanation, and invocationId together. A denied verdict with allowed: true can be consistent with observe mode. An allowed verdict with an upstream error is a different problem from policy denial.

Next: Compare outcomes in the browser demo, run a real allow/deny exercise, or investigate a decision.

About this page and its source

Knowledge ID: learn.policy-decisions. Reference snapshot: c60ee75. Generated 2026-10-28. Authored explanations accompany source-derived facts; a build date does not establish runtime support.