Observe and govern
Reference

Manage roles and permissions

Control Organization governance and Agent-specific access with fixed roles, direct grants, and Agent General Access.

For
Organization owners, Organization administrators, and Agent owners
On this page
  1. Understand the authorization model
  2. Organization Roles
  3. Agent permissions
  4. Locked Agent Access Roles
  5. Choose an Agent Access Role
  6. Share an Agent directly
  7. Configure General Access
  8. Understand additive access
  9. Change or remove access
  10. Creator and administrator access
  11. Current custom-role boundary
  12. API reference
  13. Troubleshooting
  14. Security checklist
  15. Next steps
  • RBAC
  • Least privilege
  • 13 minutes

Control who can govern an Organization and what each accepted Member can do with a specific Agent.

Understand the authorization model

Agent Barn evaluates three independent sources of authority. Each is resolved separately, and holding one never converts into another.

Platform Privilege

Read-only oversight across the deployment. It is not an Organization Membership, and it does not grant Agent Permissions.

Organization Role

One fixed role per Membership. It governs members, shared definitions, and Organization settings.

Agent Access

Direct assignments and Agent General Access, resolved per Agent rather than across the Organization.

The diagram shows three separate authority sources side by side. Platform Privilege covers Platform View and platform resources. Organization Role covers Organization-wide governance. Agent Access covers permissions for one specific Agent. Agent Barn evaluates each source on its own; none of the three implies either of the others.

A user may hold more than one source at once. For example:

  • A Platform Administrator is not automatically a member of every Organization
  • An Organization Member is not automatically able to see every Agent
  • An Agent Owner does not become the Organization Owner
  • An Organization Admin does hold implicit Agent Owner authority over the Organization’s Agents

Permissions are evaluated from current persisted state on every request. They are not permanently embedded in a session token.

Organization Roles

Every Membership carries exactly one fixed Organization Role: OWNER, ADMIN, or MEMBER. These roles govern Organization-wide actions such as Membership management, shared Templates, custom Skills, Shared Credentials, and Organization settings.

Organization Owner and Agent Owner are different roles. One governs the tenant; the other governs a single Agent.

Organization Owner

Governs the Organization itself: Memberships, shared definitions, Organization settings, ownership transfer, and Organization deletion.

Holds implicit Agent Owner authority over every Agent in that Organization, as a consequence of the Organization Role.

Agent Owner

Governs one Agent: its configuration, credentials, lifecycle, deletion, and access list.

Holds no Organization governance. An Agent Owner cannot manage Memberships, transfer Organization ownership, or delete the Organization, and is not the owner of the Organization.

Organization Role scope

Organization Role Organization scope Agent scope
Organization Owner Full governance, ownership transfer, and Organization deletion Implicit Agent Owner authority over every Agent
Organization Admin Normal Organization and shared-resource administration Implicit Agent Owner authority over every Agent
Organization Member Create Agents and use shared definitions Only Agents covered by creator, direct, or General Access

See Manage organizations and members for Membership and ownership workflows.

Agent permissions

Agent Access Roles group individual Agent Permissions. The Default roles column names the locked roles that include each Permission.

Permission Allows Default roles
agent.read View the Agent and its basic metadata Viewer, Editor, Owner
activity.read View Agent activity, conversations, tool calls, and logs Viewer, Editor, Owner
cost.read View Agent-specific cost information Viewer, Editor, Owner
agent.update Change Agent configuration and assigned Skills Editor, Owner
agent.lifecycle.manage Start and stop the Agent Editor, Owner
agent.secret.manage Add, replace, or remove Agent credentials Editor, Owner
agent.delete Delete the Agent Owner
agent.access.manage Manage direct access and Agent General Access Owner

Authorization checks use these Permission keys — never a comparison against a role’s display name. A deployment role named “Operator” carries no authority because of its name; its authority comes only from the Permission grants stored for that role.

Locked Agent Access Roles

Agent Barn provides three Agent Access Roles — VIEWER, EDITOR, and OWNER. Their names and Permission grants are locked and cannot be changed.

Agent Viewer

Grants agent.read, activity.read, and cost.read. Use it when someone needs to observe the Agent without changing it. A Viewer can open the Agent, review activity, read conversations and tool calls, review logs, and review Agent-specific costs.

A Viewer cannot start, stop, configure, share, or delete the Agent.

Agent Editor

Includes every Viewer Permission and adds agent.update, agent.lifecycle.manage, and agent.secret.manage. Use it for operators responsible for day-to-day Agent configuration, Skills, lifecycle, and credentials.

An Editor cannot delete the Agent, change who has access, or configure Agent General Access.

Agent Owner

Includes every Editor Permission and adds agent.delete and agent.access.manage. Use it only for the small set of people responsible for the Agent’s complete lifecycle and access boundary.

An Agent Owner can delete the Agent, grant and revoke direct access, change assigned roles, configure General Access, and grant Agent Owner to someone else.

What each role grants

Agent Viewer grants:

Viewer permissions
agent.read
activity.read
cost.read

Agent Editor includes the Viewer Permissions and adds:

Editor adds
agent.update
agent.lifecycle.manage
agent.secret.manage

Agent Owner includes the Editor Permissions and adds:

Owner adds
agent.delete
agent.access.manage

Default Agent Access Role matrix

Capability Agent Viewer Agent Editor Agent Owner
View Agent metadata Yes Yes Yes
View activity and logs Yes Yes Yes
View Agent costs Yes Yes Yes
Update configuration No Yes Yes
Start and stop the Agent No Yes Yes
Manage assigned Skills No Yes Yes
Manage Agent credentials No Yes Yes
Delete the Agent No No Yes
Manage access No No Yes

One Membership can hold at most one explicit Agent Access Role for one Agent.

Choose an Agent Access Role

Use the least-privileged role that supports the person’s real work.

Choose Viewer when

  • The person reviews Agent output
  • They investigate conversations or logs
  • They need cost visibility
  • They should not change runtime behavior

Choose Editor when

  • The person operates the Agent
  • They update configuration or Skills
  • They start and stop workloads
  • They manage integration credentials
  • They should not delete or reshare the Agent

Choose Owner when

  • The person owns the Agent’s security boundary
  • They need to delete it
  • They need to grant or revoke other Members’ access
  • They understand that they can delegate Agent Owner onward

Share an Agent directly

Direct access grants one accepted Organization Member one Agent Access Role for one Agent.

1. Open the Agent

Open the Agent you want to share. You need agent.access.manage. Organization Owners, Organization Admins, and existing Agent Owners hold that Permission.

2. Select Share

Select Share from the Agent header or actions. The dialog shows the available Agent Access Roles, the people with direct access, the General Access setting, and your current draft changes.

Organization Owners and Admins are not listed as direct recipients, because they already hold implicit full access.

3. Search for a Member

Use Search Members by name or email. Results may be marked:

  • Already has access
  • Owner — full access already
  • Admin — full access already
  • Pending invite
  • A role selector and an Add button

Explicit assignments can target accepted Organization Members only. Pending Members cannot receive direct Agent Access until they accept their invitation.

4. Select a role

Choose Viewer, Editor, or Owner. Viewer is the safest default for observation-only access.

5. Add the Member

Select Add. The change stays in the local sharing draft until you save.

6. Save atomically

Review every direct recipient under People with access and the General access setting, then select Save.

Agent Barn applies the entire desired sharing snapshot atomically. If validation fails, none of the draft changes are applied.

Sharing changes take effect on subsequent requests. They do not require the Agent runtime to restart.

Configure General Access

General Access controls whether every accepted Organization Member automatically receives a selected Agent Access Role. Every new Agent defaults to:

Default General access
Restricted

Restricted

  • Organization Owners and Admins retain implicit full access
  • Directly assigned Members retain their roles
  • Other Organization Members cannot see the Agent
  • Future Members receive no automatic access

Use Restricted for sensitive, production, financial, administrative, or customer-specific Agents.

All Organization Members

  • Every current accepted Member receives the selected role
  • Every future accepted Member receives it automatically
  • Pending Members receive nothing until they accept
  • Removed Memberships receive nothing
  • Direct assignments remain active and additive

The selected General Access role must grant agent.read.

Configure it

  1. Open the Agent’s Share dialog.
  2. Find General access.
  3. Select Restricted or All Organization Members.
  4. If you select all Members, choose Viewer, Editor, or Owner.
  5. Review the implications for current and future Members.
  6. Select Save.

Understand additive access

Direct access and General Access are positive, additive grants. Effective Permissions are the union of every applicable grant:

  • Direct Agent Access Permissions
  • General Access Permissions
  • Effective Agent Permissions

The diagram reads: the Permissions from a direct Agent Access assignment, plus the Permissions from Agent General Access, combine into the Member’s effective Agent Permissions. The two sources are added together as a union; neither one narrows the other.

Example: direct Viewer and General Editor

  • Direct: Agent Viewer
  • General: Agent Editor
  • Effective Editor-level permissions

The Member holds both Permission sets, so they can operate the Agent as an Editor.

Example: direct Owner and General Viewer

  • Direct: Agent Owner
  • General: Agent Viewer
  • Effective Owner-level permissions

The broader grant wins, because the union never narrows a Permission set. The Member retains Owner-level capabilities.

No deny rules

Agent Barn has no explicit deny role. You cannot assign Viewer directly to reduce access already granted through General Editor — Viewer adds Permissions, and never subtracts them.

To reduce access, change or remove the source granting the broader Permission.

Effective permissions and the interface

Agent read responses include the actions allowed for the current user. The interface uses those effective actions to decide whether to show controls such as Start, Stop, Configure, Manage credentials, Share, and Delete.

Hiding a control is not the security boundary. The API reauthorizes every operation against the current Membership, direct Agent Access, General Access, Agent state, and resource scope. A stale interface may briefly show an outdated control, but the backend still evaluates current persisted authority.

Change or remove access

A user holding agent.access.manage may grant, change, and revoke access — including granting Agent Owner. Every change takes effect on the next request, without an Agent restart.

Change a direct role

  1. Open Share.
  2. Find the Member under People with access.
  3. Select a different role.
  4. Select Save.

Remove direct access

  1. Open the Member’s role selector.
  2. Select Remove access.
  3. Select Save.

Removing direct access does not remove access still granted through General Access. The interface warns when removing a direct assignment leaves General Access active.

Remove General Access

  1. Open Share.
  2. Change General access to Restricted.
  3. Select Save.

Removing General Access does not remove a direct assignment. Direct assignments remain unchanged.

Remove all access for a Member

  1. Remove their direct assignment.
  2. Confirm General Access does not grant the Agent to all Members.
  3. If General Access must remain, remove the Membership from the Organization.

Removing the Organization Membership also removes Organization-derived Agent access.

Creator and administrator access

Agent Creator

Creating an Agent grants its creator explicit Agent Owner access.

The Agent Creator field is immutable provenance. Creator identity by itself is not an authorization grant and is not a permanent exception. An authorized access manager can change or remove the creator’s direct assignment when the creator is an ordinary Organization Member.

Organization Owner and Admin

Organization Owners and Admins hold implicit Agent Owner authority over every Agent in the Organization. They:

  • Are not offered as direct access recipients
  • Are not normally listed under People with access
  • Cannot have that implicit authority removed in the Agent sharing dialog

To remove their implicit Agent access, change or remove their Organization Membership through the Organization governance workflow.

Role changes

If an Admin is demoted to Member:

  • Their implicit full Agent access ends
  • Any preserved direct Agent assignment still applies
  • Agent General Access still applies
  • Otherwise, the Agent becomes inaccessible to them

Review Agent sharing before demoting administrators.

Current custom-role boundary

The current Agent Barn product exposes the three locked Agent Access Roles — Viewer, Editor, and Owner — for role selection and Agent sharing.

The underlying authorization model can resolve Organization-scoped role records, but the current public UI and API do not expose a complete workflow for creating, editing, or deleting custom Agent Access Roles.

Use the locked roles until custom role management is available through supported product surfaces.

API reference

List available Agent Access Roles

HTTP
GET /api/v1/organizations/{organization_id}/agents/share-roles
Response
[
  {
    "id": "c7da77aa-bf9c-5626-8bad-5e0ca5159b5d",
    "name": "VIEWER",
    "permissions": [
      "activity.read",
      "agent.read",
      "cost.read"
    ],
    "is_locked": true
  },
  {
    "id": "30e5e846-5e24-548f-a068-2505f774ce35",
    "name": "EDITOR",
    "permissions": [
      "activity.read",
      "agent.lifecycle.manage",
      "agent.read",
      "agent.secret.manage",
      "agent.update",
      "cost.read"
    ],
    "is_locked": true
  },
  {
    "id": "8f2a47ff-7caf-5ded-9027-4a16b85620b3",
    "name": "OWNER",
    "permissions": [
      "activity.read",
      "agent.access.manage",
      "agent.delete",
      "agent.lifecycle.manage",
      "agent.read",
      "agent.secret.manage",
      "agent.update",
      "cost.read"
    ],
    "is_locked": true
  }
]

Read sharing settings

Requires agent.access.manage.

HTTP
GET /api/v1/organizations/{organization_id}/agents/{agent_id}/share
Response
{
  "general_access": {
    "role": null
  },
  "assignments": [
    {
      "user_id": "018f0000-0000-7000-8000-000000000001",
      "email": "[email protected]",
      "full_name": "Agent Operator",
      "organization_role": "MEMBER",
      "is_pending": false,
      "is_creator": false,
      "access_role": {
        "id": "30e5e846-5e24-548f-a068-2505f774ce35",
        "name": "EDITOR",
        "permissions": [
          "activity.read",
          "agent.lifecycle.manage",
          "agent.read",
          "agent.secret.manage",
          "agent.update",
          "cost.read"
        ],
        "is_locked": true
      }
    }
  ]
}

Replace sharing settings

HTTP
PUT /api/v1/organizations/{organization_id}/agents/{agent_id}/share
Content-Type: application/json

Restricted, with one direct Editor:

Request body
{
  "general_access_role_id": null,
  "assignments": [
    {
      "user_id": "018f0000-0000-7000-8000-000000000001",
      "access_role_id": "30e5e846-5e24-548f-a068-2505f774ce35"
    }
  ]
}

All Organization Members as Viewer, with one direct Editor:

Request body
{
  "general_access_role_id": "c7da77aa-bf9c-5626-8bad-5e0ca5159b5d",
  "assignments": [
    {
      "user_id": "018f0000-0000-7000-8000-000000000001",
      "access_role_id": "30e5e846-5e24-548f-a068-2505f774ce35"
    }
  ]
}

Remove every direct assignment and return to Restricted:

Request body
{
  "general_access_role_id": null,
  "assignments": []
}

The write is atomic. Invalid recipients, duplicate users, unavailable roles, or other validation errors prevent the complete update.

Agent Secret plaintext is never returned through Agent access, at any role.

Troubleshooting

Symptom Likely cause Resolution
The Share control is missing You do not hold agent.access.manage for this Agent Ask an Agent Owner, Organization Admin, or Organization Owner to manage access.
A Member does not appear in search The search term is empty, the Membership is in another Organization, or the result limit was reached Search by a more specific name or email, and confirm the active Organization.
The search result says Pending invite The recipient has not accepted their Membership invitation Ask them to accept the latest invitation before granting direct access.
The result says an Owner or Admin already has full access Organization Owner and Admin authority over Agents is implicit Do not add a duplicate direct assignment.
Removing direct access did not block the Member General Access still grants that Member a role Change General Access to Restricted, or review the Member’s remaining grants.
Assigning Viewer did not reduce Editor permissions A broader role is still granted through another access source Reduce or remove the broader direct or General grant. Viewer cannot subtract permissions.
A Member cannot see the Agent at all The Agent is Restricted and has no direct assignment for that Member Grant direct access, or configure General Access.
A brand-new Member can see the Agent immediately General Access applies to every accepted Member, including future ones Change the Agent to Restricted if automatic access is not intended.
A removed Member still appears briefly The interface cached prior authorization state Refresh. Subsequent API requests are evaluated against current persisted Membership state.
The API rejects duplicate assignment users One Membership may appear at most once per Agent Submit a single assignment carrying the desired role.
The API rejects an Agent Access Role The role is not a locked system role, or is not available to this Agent Fetch the current role catalogue and use one of its returned IDs.
The General Access role is rejected The selected role does not grant agent.read Select a role that grants read access, such as Viewer, Editor, or Owner.
A user can view the Agent but cannot configure it They hold Viewer rather than Editor Grant Editor if configuration access is appropriate for their work.
An Editor cannot share the Agent Editor does not include agent.access.manage Grant Agent Owner only if that person should delegate access onward.
An authorized update still returns a state conflict Permissions do not bypass Agent lifecycle rules Stop the Agent, or complete the required lifecycle transition, then retry.
An Agent returns HTTP 404 for one Member The Agent is outside that Member’s effective visibility scope Check the Organization, the Membership, the direct assignment, and General Access.
Saving the sharing dialog fails A Member, role, or Agent changed while the dialog was open Reload the sharing settings, review the complete snapshot, and save again.

Security checklist

Before saving Agent access:

  • Start with Restricted
  • Prefer Viewer for observation
  • Use Editor for operational work
  • Reserve Owner for lifecycle and access administrators
  • Avoid granting Agent Owner through General Access
  • Remember that General Access applies to future Members
  • Verify the active Organization
  • Do not attempt to grant pending users direct access
  • Review direct and General Access together
  • Check for additive grants before assuming access was removed
  • Review access before demoting an Organization Admin
  • Remove access promptly when responsibilities change
  • Review Agents that expose credentials, customer data, or external write access more frequently
  • Remember that Agent Secret plaintext is never returned, even to Agent Owners
  • Treat agent.secret.manage, agent.delete, and agent.access.manage as sensitive capabilities
  • Do not alter locked roles or Permissions directly in the database
  • Periodically test the product as a Viewer and as an Editor to confirm least-privilege behavior

Next steps

After configuring roles and permissions:

  1. Review every Agent Owner assignment.
  2. Confirm sensitive Agents use Restricted General Access.
  3. Verify Members can reach only the intended Agents.
  4. Test the Viewer and Editor boundaries.
  5. Review Membership changes for access impact.
  6. Continue to Review Agent activity.
Documentation