Control and proof
AI agent permissions (least privilege)
AI agent permissions are the rules that decide which systems, actions and data an agent's credential may reach, and least privilege for agents means granting only the actions a task needs and enforcing that limit outside the model.
What it is
Least privilege is an old security principle. NIST's glossary defines it as restricting the access privileges of users, or processes acting on their behalf, to the minimum necessary to do their work. An AI agent is exactly such a process. Agent permissions apply the principle per agent: this key may read tickets and create them in one PSA; that key may only read invoices.
Why it matters
A model can be wrong, and it can be manipulated through prompt injection. Permissions decide how much damage either can do. The OWASP Top 10 for LLM applications lists excessive permissions as a root cause of excessive agency, and recommends limiting what extensions may do in other systems to the minimum necessary. OWASP's agent cheat sheet adds two rules: scope permissions per tool (read-only versus write, specific resources), and fail closed for unknown tools.
How it works
- One credential per agent, so each can be limited and revoked on its own.
- A scope listing what the credential may run: whole services, single actions, or classes such as read-only.
- Enforcement where the call executes, not in the model's instructions. OWASP's prompt-injection cheat sheet warns against treating prompt wording as an enforcement boundary.
- Narrowing only. A credential that creates another can grant at most what it holds.
- Revocation that stops the agent at once.
Example
A ticket-triage agent gets a key that allows read:* plus service.ticket.create on the PSA. It can read every connected system and open tickets. It cannot close tickets, edit invoices or delete anything, whatever its prompt says.
Common pitfalls
- One shared admin token for every agent: no least privilege and no way to tell agents apart.
- Vendor scopes that are too coarse. Many OAuth scopes grant read and write together; the limit has to be applied above them.
- Rules written into the system prompt instead of checked by the server.
- Forgetting administration. An agent that can create connections or keys can widen its own reach.
How actionlake handles it
Every actionlake key carries allowed_actions. An entry may name one action, a canonical verb such as service.ticket.create, a whole service (xero.*), an effect class (read:*), an effect class on one service, or everything (*). An empty list allows nothing. The check runs before any cost is incurred. A key can mint keys only within its own scope, and revoking a key revokes every key it minted. Changing connections, credentials or keys needs a separate account:* grant that * does not include, and deciding approvals needs approve:*. Pair scopes with caps and approval rules. Details are on the trust page.
Questions
What does least privilege mean for an AI agent?
Give each agent its own credential that can run only the actions its task needs, enforce the limit on the server that executes calls, and let it create only narrower credentials.
Can I make an AI agent read-only?
Yes, if the platform enforces it per call. A read-only scope must be checked where the action runs; telling the model not to write is not a control.
Are OAuth scopes enough to limit an agent?
Often not. Vendor scopes are usually coarse, granting read and write to a whole area. Agent permissions add a finer limit per action on top of the vendor's scope.
Related terms
- Human-in-the-loop approvalHuman-in-the-loop approval is a control that pauses an AI agent's action until a named person approves or rejects it, so high-impact or irreversible actions never run on the model's judgement alone.
- Agent spending capAn agent spending cap is a hard limit on how much a single AI agent credential may spend or call in a period, checked before each request is sent, so that a looping or misbehaving agent stops at the limit instead of after it.
- Prompt injectionPrompt injection is an attack in which text that a language model reads, typed by a user or hidden in a web page, email, document or tool result, changes the model's behaviour, and in a tool-using agent it can turn into real actions.
- Credential vaultA credential vault for AI agents stores the API keys and OAuth tokens for business systems encrypted outside the agent, and uses them on the agent's behalf only at the moment of each call, so the model, its prompt and its logs never contain a vendor secret.
- Canonical verbA canonical verb is one standard name for the same operation across every system that supports it, written domain.object.operation, such as service.ticket.create, so an agent learns an action once and can run it against any connected system.
- OAuth for MCPOAuth for MCP is the authorisation flow the MCP specification defines for remote servers, in which an MCP client discovers the server's authorisation server, registers itself, sends the person to sign in and consent, and then calls the server with a short-lived, audience-bound access token.
Sources
Connect an agent. Start free.
100,000 calls free every month. No card. Hard caps on every key.