Agentic AI governance: Controls that survive an autonomous agent

by Sujay ChoubeyAug 28, 202617 min read
MCP Gateway

TL;DR: Traditional AI governance frameworks have no concept of an execution layer between the agent's reasoning and the target API. They assume outputs that humans review, not actions that autonomous systems execute at runtime. Autonomous agents break that assumption by deciding their execution paths dynamically, making static pre-approvals obsolete. Prompt-level instructions such as "do not delete" are soft requests a model can reason around or be injected past. Governance holds when it is enforced at the infrastructure layer, where every tool call is validated against clear, code-based policy rules before it reaches the target API. Credentials must be isolated from the LLM context, permissions must be scoped per action and per user, and every denied call must appear in the audit log. At 300M+ tool calls processed per month, this is not a theoretical gap. It is an operational requirement already running at scale.

Your existing AI governance policy was almost certainly written for a model that produces text. That policy assumes a human reads that text and decides what to do next. When the actor is an autonomous agent holding live API credentials and a tool list spanning Gmail, Salesforce, and GitHub, that assumption is gone, and so are the controls built on top of it. The missing piece is an execution layer: a discrete infrastructure tier that sits between the agent's reasoning engine and the target API, governing every call before it fires.

Without an action infrastructure layer, governance defaults to either model-level instructions (unreliable) or manual review (unscalable). This article explains exactly where those frameworks fail and what must replace them.

Why static policies break under autonomous agents

Static governance works by predicting the action set in advance. A human approves a process, that process runs within defined boundaries, and the audit log confirms what happened. Every control in that model depends on knowing what the agent will do before it does it.

Autonomous agents break this at the architectural level. The model determines its next step by reasoning over its current context at runtime, not by following a fixed script. The action an agent takes at step five depends on what it found at step four, so you cannot pre-approve an action set that does not exist until execution begins. The table below maps where most organizations currently sit and what the risk profile looks like at each maturity level.

Governance maturity model

Maturity level

Characteristics

Security mechanism

Risk profile

Level 1: Shadow AI

Ad-hoc agent deployment, hardcoded API keys in developer environments

None

Critical: credential exposure, no audit trail

Level 2: Prompt-bounded

Agents restricted via system prompts and model-level instructions

Soft guardrails

High: prompt injection, policy evasion

Level 3: Gateway monitored

Basic API gateways that log traffic, static human-in-the-loop approvals

Static approvals

Medium: operational bottleneck, slow velocity

Level 4: Policy-as-code

Request-path validation, isolated credential vault

Infrastructure-layer enforcement

Low: least privilege enforced, produces SOC 2 control evidence

Why manual controls fail AI agents

Human-in-the-loop approval made sense when a person reviewed every AI-generated draft before acting on it. An autonomous agent can execute hundreds of sub-tasks within a single workflow, each calling a different API with a different permission scope. Requiring manual sign-off at each step destroys the operational case for deploying it at all. Teams will route around the control rather than accept the latency, producing exactly the shadow AI exposure you were trying to prevent.

Why static approvals fail autonomous agents

A static approval grants permission to a defined process. When an agent decides its next action based on what it retrieved in the previous step, you cannot define the process until it completes. Approving "the agent will update Salesforce" does not cover the specific record it targets, the field it writes, or whether it also calls an unrelated Slack webhook because the model reasoned that was helpful. The action set is not knowable at approval time because the agent reasons dynamically.

What third-party breach data shows

According to the SecurityScorecard 2025 Global Third-Party Breach Report, 35.5% of all breaches in 2024 were third-party related. The Verizon 2025 DBIR found that third-party involvement doubled from 15% to 30% of all breaches in a single year, and IBM's 2026 Cost of a Data Breach Reportputs the global average cost of a data breach at $4.99 million. Agents holding over-privileged API credentials with no audit trail represent a third-party risk vector sitting inside your own infrastructure.

Prompt instructions are not security controls

The most common response to agent governance concerns is adding instructions to the system prompt: "Do not delete records," "Only read, never write," "Always ask for confirmation." These are not security controls. They are requests made to a probabilistic model, and they fail in three distinct ways.

Why prompt limits fail during execution

A language model processes all instructions as semantic context within a token stream. It cannot distinguish between a trusted instruction from the operator and untrusted text retrieved from an external data source, because both arrive as tokens. OWASP (the Open Web Application Security Project) classifies prompt injection as the highest-priority LLM vulnerability precisely because of this structural property. An injection does not "hack" the model; the model simply follows the most contextually relevant instruction it has received, and the attacker's instruction has been positioned to win that competition.

Why "do not delete" is a request, not a control

A prompt instruction is a sign on a door. Policy-as-code is the lock. Research on indirect prompt injection presented at the ACM AISec 2023 workshop demonstrates that adversaries can embed malicious instructions in third-party content that an agent reads during a normal task, causing it to execute attacker-controlled actions rather than the user's original intent. Researchers demonstrated successful attacks against Bing Chat and code-completion engines, including login credential exfiltration scenarios, without any direct access to the system prompt.

Semantic drift compounds this in long agentic workflows. As the context window fills with retrieved documents, tool responses, and prior reasoning steps, early negative constraints lose weight relative to more recent context. A constraint placed at the start of a long session becomes progressively easier to override as the session proceeds.

How models are talked around soft constraints

Jailbreaking techniques exploit the model's instruction-following behavior directly, and complex multi-step reasoning can lead a model to conclude that a restricted action is required to complete the user's legitimate goal. The model is helpful, which means it will find creative paths around soft constraints to complete what it believes the user wants. That is the structural incompatibility between prompt-level governance and enterprise security requirements.

How request-path enforcement secures agents

Composio moves enforcement out of the model layer and into the infrastructure layer because enforcement at the infrastructure layer is what holds under adversarial conditions. This is the action infrastructure layer: a discrete tier in the agent's call path, between reasoning and execution, that every tool call must pass through. This is not a configuration choice. Proxy Execute intercepts every tool call after the agent generates it but before it reaches the target API, handling credential resolution and injection at the point of execution, with policy-as-code enforcement validating permissions in the request path.

Validating requests prior to execution

The data flow at the infrastructure layer works as follows:

  1. Agent generates a tool call: The LLM reasons that it needs to call delete_lead on the CRM.

  2. Proxy Execute intercepts: The request arrives at Composio's Proxy Execute before it touches the target API.

  3. Policy-as-code validation: Policy-as-code enforcement evaluates whether the calling identity has permission to execute delete_lead under the current role and scope configuration.

  4. Credential resolution (Proxy Execute): If the call is permitted, Composio's Proxy Execute decrypts the credential inside an isolated runtime and injects it into the outbound HTTP request. The raw token never returns to the agent or appears in the LLM context.

  5. Response returned: The agent receives the API response.

Hardcoding permission boundaries for agents

An admin disables GITHUB_DELETE_REPO and SLACK_DELETE_CHANNEL for the support team's agent. Regardless of what the model reasons, regardless of what a user injects into the input, those calls are blocked in the request path before execution. The Composio controlled scopes documentation describes how scope restrictions are set at the auth-config level and applied at connection time, so an agent's OAuth grant is bounded to the actions defined in that configuration when the account connects.

3 mandatory controls for secure agent deployment

Every secure agent architecture requires three things that cannot be satisfied by model-level controls: an inventory of agents and their access scope, per-action permissions tied to user identity, and a complete audit trail that includes denied calls.

Mapping autonomous agent access rights

At the scale Composio operates (1,000+ connected apps, 50,000+ agent-ready tools, 1M+ accounts connected, and 300M+ tool calls processed per month), the inventory and access-scoping problem cannot be solved by manual enumeration or static configuration. The same call volume means skills distilled from 300M+ tool calls a month make repeat tasks 30% more accurate on 2× fewer tokens, which means governance must be designed to keep pace with an execution layer that actively improves its own efficiency.

The first step is knowing what is running. This means maintaining a real-time inventory of every active agent, the LLM it uses, the connected accounts it holds credentials for, and the specific actions those accounts permit. Without this inventory, access reviews are incomplete by definition.

Embedding static API keys in developer environments or CI/CD secrets is the credential-handling equivalent of leaving master keys on the desk. Composio's managed OAuth layer handles the full token lifecycle, including consent, token storage, refresh cycles, and scope enforcement, without passing raw credentials to the calling application or the LLM context.

Execution scope compounds the inventory problem. Composio's catalog of 50,000+ agent-ready actions does not load into the LLM context wholesale. At request time, only the tools relevant to the call are resolved, which keeps the model's context window clean.

Per-action permissions by user and role

An agent acting on behalf of a support representative must not inherit the API permissions of an IT administrator. You must scope permissions at the action level, not at the integration level. Granting an agent access to "Slack" is not a permission, it is an undefined boundary. Granting access to SLACK_SEND_MESSAGE but not SLACK_DELETE_CHANNEL is a permission.

Composio's SCIM 2.0 integration (System for Cross-domain Identity Management) maps directory groups from Okta, Entra ID, or Google Workspace to teams, and from there action-level access controls apply. When a team member's role changes, updated scopes apply to new connections. Existing connected accounts retain their granted scopes until they reconnect. When someone departs, the credential scope attached to their identity can be revoked from a single dashboard rather than requiring enumeration across multiple developer environments and CI/CD secrets stores. The authenticating tools documentation covers how action-level permissions are configured per connected account.

Logging denied agentic AI requests

Many legacy API logging systems record only successful calls, which is insufficient for governance. Auditors require a complete chain of custody, and a chain of custody has no gaps. Denied calls matter as much as permitted ones because they signal whether an agent attempted to exceed its scope, whether an injection was tried, and whether a permission configuration is working as intended.

Composio's centralized audit log records every tool call with user, team, tool, action, and outcome, including denied calls.

How to phase in agent governance without blocking teams

Governance that stops teams shipping will be routed around. The implementation sequence below introduces controls progressively, starting with the lowest-friction changes and escalating to full policy-as-code enforcement as baselines are established.

Audit agent read-only access scopes

Step 1: Deploy or re-configure existing agents with strictly read-only OAuth scopes. This maps data flows and establishes usage baselines without introducing write-action risk. If an agent cannot operate with read-only scope in a staging environment, that tells you something important about its permission requirements before it reaches production.

Apply strict controls to high-risk calls

Step 2: Identify high-risk write actions, deleting records, sending external emails, and modifying financial data, then apply deterministic policy-as-code blocks at the gateway. Start with a blacklist of destructive actions and expand the whitelist incrementally as team requirements are reviewed and approved. Composio's access model supports both whitelist and blacklist modes.

Mandate audit logs for all agents

Step 3: Centralize all agent activity logs into your SIEM (Security Information and Event Management system) or centralized dashboard before any agent reaches production with write access. The policy framework below gives you a starting point for components to include in your internal documentation, which you can adapt for compliance submissions.

Autonomous agent policy framework components:

  • Policy scope and ownership: Document the team responsible for each deployed agent and the approval chain for permission changes.

  • Permitted agent archetypes and LLM registry: List which LLMs are approved for production use and the classification of agent types (read-only, write-bounded, autonomous).

  • Credential storage and isolation standards: Use industry-standard encryption (such as AES-256), prohibit credential injection into LLM context, and mandate server-side credential resolution.

  • Request-path enforcement rules: Define action-level whitelisting per user role, with gateway-enforced blocks for all unlisted actions.

  • Audit log retention and incident response: Set minimum retention periods aligned with the EU AI Act's six-month minimum for high-risk systems (Articles 19(1) and 26(6)), and define escalation paths for anomalous call patterns.

Immediate termination of agent access

Step 4: Establish a revocation mechanism before any agent goes live. When an anomaly is detected, when a team member departs, or when an agent behaves outside expected scope, you need to invalidate credentials globally in a single action.

Establishing compliance requirements for AI agents

Regulatory requirements for autonomous agents are tightening quickly, and the controls auditors accept for static LLM deployments do not transfer to agentic workflows without architectural changes.

Static model controls vs. autonomous agent policy

Traditional AI compliance focuses on training data governance, model bias documentation, and output filtering, all of which address what the model produces rather than what an agent executes. Autonomous agents are governed by what they execute: state-changing API calls that write records, send messages, and modify data in external systems. The compliance question shifts from "what did the model output?" to "what did the agent do, to which system, under whose authority, and was it permitted?"

The EU AI Act Article 12 requires high-risk AI systems to technically allow automatic recording of events over the lifetime of the system. Articles 19(1) and 26(6) set a minimum six-month retention period for those logs. Logs must be generated automatically by the system rather than assembled after the fact, and must cover risk identification, post-market monitoring, and deployer monitoring, not via scheduled exports or human-triggered notes. Auditors operating under SOC 2, PCI-DSS, or GDPR require reproducible, verifiable evidence of control effectiveness. A system prompt produces probabilistically variable outputs across identical inputs, which means auditors cannot treat it as a deterministic boundary or cite it as SOC 2 control evidence.

Before deploying any autonomous agent with write access to production systems, verify that your architecture satisfies these five requirements:

Compliance and audit readiness requirements:

  • Are API credentials isolated from the LLM context window?

  • Is there a centralized vault encrypting tokens with AES-256?

  • Are agent tool calls validated deterministically before execution?

  • Do audit logs capture denied requests and associated metadata?

  • Is there an instant revocation mechanism for every connected account?

Verifying agent actions via audit logs

Composio's SOC 2 Type II and ISO/IEC 27001:2022 certified architecture provides pre-filled compliance documentation through the trust center, covering the control mapping that enterprise security questionnaires require. The 11x case study documents $4.2 million in enterprise deals closed after deploying Composio for Outlook, Salesforce, and Cal.com integrations, with approximately 380 engineering hours saved on integration builds that previously required months of in-house OAuth plumbing.

The governance argument for autonomous agents comes down to a single architectural decision: where does enforcement happen? The layer that executes 300M+ tool calls a month across 1,000+ apps for 1M+ connected accounts is already operating as an action execution tier. The governance question is whether that tier enforces policy deterministically or defers to the model. Prompt instructions tell the model what it should do. Composio evaluates policy-as-code in the request path before the model's decision touches any API, enforcing what it can do rather than what it should do. For any agent with write access to production systems, only one of those options survives an audit, a breach investigation, or a well-crafted injection payload.

For a deeper look at the full governance framework, the AI agent management governance guide covers policy structure, access review cadences, and vendor risk assessment in detail.

If your next enterprise security review will ask how you govern your agents, book a technical security architecture call to walk through your specific requirements before that review arrives. If you want to test policy-as-code enforcement against your own agent configuration first, the free tier provides 100,000 tool calls per month with no sales call required.

FAQs

What is agentic AI governance?

Agentic AI governance is the set of controls that restrict what autonomous agents can execute when they call external APIs and take state-changing actions at runtime. Unlike static LLM governance, which focuses on model outputs, agentic governance must operate at the infrastructure layer because the agent's action set is determined dynamically during execution, not at approval time.

Does Composio store raw API credentials on the platform?

No. Credentials are encrypted using industry-standard AES-256 encryption and isolated within a secure runtime, and no credential is ever returned to the LLM context or application memory.

What compliance certifications does Composio hold?

Composio is SOC 2 Type II and ISO/IEC 27001:2022 certified.

Can we self-host Composio's governance layer?

Self-hosting options are available at the Enterprise tier. Teams with specific data residency or on-premise credential management requirements should contact Composio to confirm current deployment options against their environment.

Why do auditors reject system prompt instructions as security controls?

Auditors require deterministic, reproducible evidence of control effectiveness, and system prompt instructions produce probabilistically variable outputs across identical inputs. This means prompt instructions cannot serve as auditable control evidence under SOC 2, GDPR, or PCI-DSS frameworks.

How does policy-as-code enforcement differ from an LLM firewall?

LLM firewalls add a probabilistic evaluation layer that reduces but does not eliminate the risk of policy evasion, and they introduce additional latency. Policy-as-code enforced in the request path is deterministic: if an action is blocked, the HTTP request is rejected before it executes, regardless of what the model or any injected instruction says.

What is action infrastructure and how does it differ from an API gateway?

A standard API gateway routes and logs traffic; action infrastructure is a purpose-built execution layer that sits between an agent's reasoning engine and the target API, where only the tools needed for a given call are resolved at request time, which keeps the model's context window clean. Unlike a gateway, it resolves credentials inside an isolated runtime, enforces action-level policy-as-code, and logs denied calls alongside successful ones. At 300M+ tool calls per month across 1M+ connected accounts, that enforcement must be deterministic rather than probabilistic.

Key terms glossary

Action infrastructure: The discrete infrastructure tier that sits between an agent's reasoning engine and the target API, responsible for policy-as-code enforcement, credential resolution, action-level permission scoping, and audit logging for every tool call an agent generates. Distinguished from an API gateway by its agent-native design: it handles the full token lifecycle, enforces least-privilege access at the individual action level, and logs denied calls as first-class audit events.

Request-path enforcement: A security architecture where access policies are evaluated and enforced on outbound API calls before they are executed, independent of the LLM's instructions. Composio enforces policies between the agent and the target API, not inside the model.

Credential isolation: The practice of storing and resolving API credentials within a secure vault, so they are never exposed to the LLM context window or application memory. Composio resolves credentials inside an isolated runtime and injects them into the outbound HTTP request only at the point of execution.

Policy-as-code: Defining security and access rules using deterministic code or configuration files, so enforcement stays consistent and verifiable across all systems regardless of what the model was instructed to do.

Least privilege: The access control principle that limits each agent, user, or role to the minimum set of actions required for its defined function. In agentic contexts, this means action-level permissions rather than integration-level access grants.

Audit trail: A complete log of every tool call executed by an agent, including denied calls, the identity that made the call, the policy outcome, and the timestamp. A complete audit trail includes denied actions, not only successful ones.

Indirect prompt injection: An attack vector in which malicious instructions are embedded in third-party content that an agent retrieves during a legitimate task, causing the model to execute the attacker's commands rather than the user's original intent.

Share