# AI Agent Identity and Access Control in Business Applications

> Give AI agents their own identity and least privilege: action matrix, API enforcement, short-lived credentials, human approval, logs, stop switch, and a 30-day plan.

Source: https://www.agsora.tech/en/blog/identitas-dan-hak-akses-ai-agent-di-aplikasi-bisnis
Category: Technology · Published: 2026-12-01 · Updated: 2026-12-01 · By PT Agsora Teknologi Indonesia

Corporate AI assistants are moving from answering questions to doing work: drafting orders, updating customer records, opening tickets, or scheduling deliveries. Once an AI system can act, the most important question is not how clever the model is, but on whose behalf it acts and what it is allowed to touch. Many pilots use an administrator account or an employee's API key because that is quickest. This article explains how to give AI agents controllable identities and permissions inside business applications.

*An AI agent should be treated as a system user with a clear identity, limits, and a supervisor.*

## Why agent access differs from employee access

A staff member with broad rights usually uses a small part of them in a day and recognises an unusual action. An agent works fast, can repeat an action thousands of times, and its decisions are influenced by the text it reads, including emails, documents, or web pages from outsiders. Hidden instructions in that text can redirect it, as covered in [AI application security and prompt injection](https://www.agsora.tech/en/blog/keamanan-aplikasi-ai-prompt-injection-dan-kebocoran-data).

Excessive permission is therefore not theoretical. The 2026 OWASP Top 10 for Agentic Applications lists identity and privilege abuse among the main risks: an agent borrows too much power or uses stale credentials to do things it should not. Least privilege still applies, plus a limit on how far the agent may decide for itself.

## Five basic principles

- Every agent has its own identity, never a borrowed human or shared account.
- Permissions follow the task, not the seniority of whoever built the agent.
- Credentials are short-lived and can be revoked at any moment.
- High-impact actions require human approval.
- Every action is logged and traceable to the agent, trigger, and approver.

You do not need an expensive product to begin. You need design decisions made before the agent touches real data.

## Designing agent identity

Create a service identity for each agent and each environment. The production billing agent shares no key with its test version or with the customer service agent. Record the business owner, technical owner, purpose, systems accessed, and review date.

When an agent works at a user's request, the application should know both: which agent is acting and which user asked. Effective permission should be the overlap of the two. A warehouse employee asking an assistant must not receive salary data simply because the assistant can reach a broad database. This aligns with the [single sign-on and identity management](https://www.agsora.tech/en/blog/sso-dan-manajemen-identitas-untuk-aplikasi-bisnis) you already use for people.

## Build an action matrix

Generic roles such as admin or operator are too coarse. Write down concrete actions and group them by impact:

- Read: view order status, search help articles, check stock.
- Draft: prepare a quotation, a journal entry, or a reply that is not yet sent.
- Limited change: update ticket notes or a status that is easy to reverse.
- High impact: message a customer, issue a purchase order, change a price, or refund money.
- Forbidden: change permissions, delete data in bulk, move funds, or disable logging.

For every action define the object, value limit, hourly volume limit, approver, and method of reversal. The matrix complements how you [design user access rights](https://www.agsora.tech/en/blog/merancang-hak-akses-pengguna).

## Enforce in systems, not in instructions

Telling an agent in its prompt not to delete data is not a control. Instructions can be ignored, misread, or hijacked. Restrictions must be enforced by the APIs and services being called: if the agent identity lacks delete permission, the request fails whatever the conversation says.

Offer narrow tools. A create-draft-order function with validated parameters is safer than free SQL access or system commands. Validate input on the server, cap records per call, and recheck data ownership on every request. If you use the [Model Context Protocol](https://www.agsora.tech/en/blog/model-context-protocol-mcp-menghubungkan-ai-dengan-sistem-bisnis), review each installed server and tool, its origin, and the permissions it carries.

### Credentials

Never place permanent keys in prompts, shared configuration files, or chat history. Issue narrowly scoped, short-lived tokens while a task runs, keep secrets in a secrets manager, and rotate them automatically. The model does not need to see credentials; the application layer adds them when calling a service.

## Human approval that actually helps

An approve button appearing dozens of times a day will be clicked without reading. Ask only for consequential actions and show enough information: what will happen, which data changes, before and after values, the sources the agent used, and the consequence of being wrong.

Approval must be bound to a specific action. If the agent changes the amount or recipient afterwards, the approval lapses. For sensitive transactions, the requester should not be the only approver. The pattern is discussed in [human-in-the-loop approval for AI agents](https://www.agsora.tech/en/blog/human-in-the-loop-persetujuan-manusia-untuk-ai-agent-di-proses-bisnis).

## Logging, monitoring, and a stop switch

Logs should answer simple questions: who asked, which agent acted, which tool was called, with what parameters, what resulted, and who approved. Store them beyond the agent's reach, filter unnecessary personal data, and define retention.

Set limits that raise alerts: call volume spikes, unusual access, repeated permission denials, or rising cost. Provide a way to disable one agent without stopping the whole application, by revoking its identity and cancelling queued work. Rehearse that switch before you need it.

## Example: a purchasing assistant

Picture an agent supporting procurement. It may read stock, purchase history, and the approved supplier list. It may draft purchase requisitions. It may not add suppliers, change bank details, or issue orders above a limit without approval. When it reads a quotation email, the content is treated as data, not as a command.

If an email asks to change a payment account, the most the agent can do is open a verification ticket for finance, who confirm through a separate channel. With this design a malicious instruction has no path to action, even if the model is fooled.

## Test before and after launch

Test normal cases and hostile ones: documents containing hidden instructions, requests for another customer's data, values above limits, and endless repeated calls. The expected result is refusal by the system and a clear record. Include these tests in the release pipeline, because changes to model, prompt, or tools can alter behaviour. Your [AI output evaluation](https://www.agsora.tech/en/blog/evaluasi-kualitas-output-ai-llm-untuk-aplikasi-bisnis) method can be extended to permission tests.

## A 30-day plan

- Week one: list every agent, automation, and AI integration already running, including those built without IT knowing.
- Week two: remove shared accounts and administrator keys, issue separate identities, and assign owners.
- Week three: write the action matrix, narrow tools, and add approvals for consequential actions.
- Week four: enable logs and alerts, test abuse scenarios, and rehearse access revocation.

Afterwards, review access quarterly and whenever an agent receives a new tool. Retire unused agents together with their credentials, just as you would a departed employee's account. Put these rules into the company [AI usage policy](https://www.agsora.tech/en/blog/kebijakan-penggunaan-ai-dan-tata-kelola-ai-di-perusahaan).

## Permissions for data, not only actions

The action matrix needs matching data rules. An agent reading internal documents must respect their viewing rights, including after documents are indexed for search. An index that ignores source permissions lets secrets surface as answers. Check permissions at retrieval time, update the index when access is revoked, and separate conversation memory between users and between customers.

Also decide which data may leave for a third-party model provider. Mask identity numbers, health data, or payment information when the task does not require them. Read the provider's retention and data use terms, and compare them with the personal data protection obligations that apply to your company.

## Share responsibility

Identities without owners pile up. Name a business owner who approves what the agent may do, a technical owner who manages identity, tools, and logs, and a security reviewer for consequential changes. When an owner changes role, assign a successor before old access ends.

Add this check to your existing change process. Adding a tool, widening data scope, or raising a value limit is an access change and should be approved like a permission request for an employee. Approval records make explanations to auditors and customers much easier.

## Frequent mistakes

- Using one API key for every agent because it is convenient.
- Granting full access during a pilot and forgetting to remove it in production.
- Treating prompt instructions as a safeguard.
- Logging only the conversation and not the actions executed.
- Asking approval for everything until approvers stop reading.

Each mistake is cheap to prevent during design and expensive to repair once an agent touches many systems. Start with one agent that matters, apply the action matrix completely, and use the result as the pattern for the next.

## Common questions

### Is this necessary for a read-only assistant

Yes, although the work is lighter. Reading can still expose confidential data, so identity, scope, and logs matter even when nothing is modified.

### Can one agent identity serve several departments

It is better to separate them. Shared identities make permissions grow to the sum of every department's needs, and make it hard to tell who caused an action.

### What should we ask a vendor

Ask how the product authenticates, whether permissions can be limited per tool, how approvals are recorded, where logs are stored, and how access is revoked. Request a demonstration of a refused action, not only a successful one.

**Give AI agents safe and measurable access** AG·SORA designs AI automation with separate identities, least privilege, human approval, and auditable logs. [Free consultation](https://www.agsora.tech/en/services/ai-automation)
