> ## Documentation Index
> Fetch the complete documentation index at: https://docs.barndoor.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Agent Profiles

> Configuring agents that operate with their own access credentials to MCPs and LLMs and provides visibility to what your agents are doing and what their models costs are.

## Overview

<Frame>
  <img src="https://mintcdn.com/barndoor/GZbbBabC4MisXQDA/images/agent-profile/agent_profile_overview.png?fit=max&auto=format&n=GZbbBabC4MisXQDA&q=85&s=e9bb3aa3be0b586ece9396c1318dec5d" alt="AgentProfile: one record covering data access policies, per-agent spend, LLM access, budget guardrails, MCP access, and human manager" width="960" height="540" data-path="images/agent-profile/agent_profile_overview.png" />
</Frame>

Every agent in Barndoor has an **AgentProfile,** a single record where your agents may be registered and used for enabling access controls.  It may be a commercial agents such as Anthropic Claude, OpenAI ChatGPT, Codex, Gemini, Cursor and so on. Or it may be custom developed agents.

For your custom agents, **AgentProfile** may be further used for configuration and ongoing management, especially in cases where the agent is autonomous and you utilize both Barndoor's LLM gateway and MCP gateway.  You may configure the **AgentProfile** with the virtual keys it needs to make model API calls as well as grant it specific credentials, such as services account credentials, for the MCP's of systems it requires access to.

By doing so, your **AgentProfile** ties together its access controls and credentials in one place, and provides visibility into it's ongoing AI token model costs, policy enforcement logs, error rates, and so on.

<Note>
  This binds together the LLM Gateway and MCP Gateway product modules. AgentProfile is the central object for both governed tool traffic and LLM usage especially useful for custom agents.
</Note>

## Configuring an Autonomous Agent with AgentProfile

**To configure your autonomous agent:**

1. Select and open the agent from the **AI Agents** list. [https://app.barndoor.ai/agents](https://app.barndoor.ai/agents)
2. Select the Edit action to open the agent configuration modal
3. If the agent is to contain its own credentials to your MCP servers, enable the MCP Connections feature
4. If the agent is to contain its own LLM keys, enable the LLM Gateway Enabled feature
5. (Recommended) Turn off **ToolIQ Write Confirmations** so the agent can operate without a human in the loop. Be sure to test thoroughly before allowing it to make system updates.

From this point, configure access to tools the agent should have to in the [Access Control Center](https://app.barndoor.ai/policies).

## Enabling MCP Server Connections on an agent

Agents may be given its own service account credentials to the MCP Servers it needs access to. This is most valuable when creating custom agents that do not work explicitly on behalf of a user's own login credentials.

On the Edit AI Agent modal, the **MCP Connections Enabled** toggle controls whether this feature is enabled for the agent.

* **Default:** off for new agents.
* **When enabled:** the agent can be given access credentials for each MCP server available in Barndoor.
* **When disabled:** the agent must utilize MCP user login credentials found otherwise in your agent application or through the user connection flows in Barndoor My Apps.

Once the feature is enabled, select the **Manage Connections** action from the agent details page. You are then able to add the MCP server connections that the agent is to have access to.

## Enabling LLM Gateway on an agent

Most agents will interact with an AI model via the LLM gateway. If you are managing agentic access to models with Barndoor's LLM gateway, this process will bind a virtual key to the agent so you can manage what models it may access and track its token spend.

On the Edit AI Agent modal, the **LLM Gateway Enabled** toggle controls whether this feature is enabled for the agent.

* **Default:** off for new agents.
* **When enabled:** the agent can be bound to LLM Gateway keys, and Barndoor starts routing and tracking its model calls.
* **When disabled after keys are bound:** a confirmation dialog warns you that bindings will be preserved but disabled. Turning the toggle back on automatically reactivates them.

### Managing key bindings

Once LLM Gateway is enabled, a **Manage keys** action appears on the agent detail page kebab menu (`⋮`). It opens a dedicated screen listing keys you're authorized to bind or you may provision a new key.  An agent may have more than one model key, but each key may only be bound to a single agent.

#### Bind a key

Keys that have been created already may be bound to the agent if they have not been used with other agents.

#### Creating a key from this screen

**Create new key** opens a key-creation form. The resulting key is automatically bound to the current agent as part of the same action.

#### Managing an existing key binding

Keys may be unbound from an agent through the **Unbind** button. All event history is preserved against the agent, but new activity using the key will not be associated to the agent. Keys may be subsequently bound to a new or existing agent.
