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

# Get Custom Agent Permissions

> Returns all users who have access to the specified agent and their permission levels.



## OpenAPI

````yaml /openapi/agents-openapi.yaml get /noCo/api/v2/elementPermissions/{elementType}/{agentId}
openapi: 3.1.0
info:
  title: DataGOL Custom Agents API
  description: >-
    Complete API for creating, configuring, sharing, and interacting with Custom
    AI Agents on the DataGOL platform. Covers agent CRUD, permissions,
    conversations, and streaming.
  version: 1.0.0
  contact:
    name: DataGOL Support
    url: https://datagol.ai
servers:
  - url: https://be.datagol.ai
    description: Backend API (Production) — agent management, conversations, permissions
  - url: https://ai.datagol.ai
    description: AI Core (Production) — streaming, chat completion, conversation naming
security:
  - ServiceAccountAuth: []
  - BearerAuth: []
tags:
  - name: Custom Agents
    description: Create, read, and manage Custom AI Agents.
  - name: Permissions
    description: View and manage who has access to an agent.
  - name: Conversations
    description: Open and list conversation sessions backed by an agent.
  - name: Messaging
    description: Send messages and stream AI responses.
  - name: Reference Data
    description: >-
      Lookup APIs for workspaces, connectors, and team members used when
      building agent configs.
paths:
  /noCo/api/v2/elementPermissions/{elementType}/{agentId}:
    get:
      tags:
        - Permissions
      summary: Get Custom Agent Permissions
      description: >-
        Returns all users who have access to the specified agent and their
        permission levels.
      operationId: getAgentPermissions
      parameters:
        - name: elementType
          in: path
          required: true
          schema:
            type: string
            enum:
              - CUSTOM_AGENT
          description: Always CUSTOM_AGENT.
          example: CUSTOM_AGENT
        - name: agentId
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: UUID of the Custom Agent.
          example: 7bf5f4d6-743d-414f-aa4a-96f7a20ce0fd
      responses:
        '200':
          description: Array of permission grants for this agent.
        '403':
          description: User lacks VIEW_COPILOT permission.
components:
  securitySchemes:
    ServiceAccountAuth:
      type: apiKey
      in: header
      name: x-auth-token
      description: >
        For server-to-server or automated access, use a DataGOL Service Account
        key.
                Pass it via the `x-auth-token` header instead of `Authorization`:
                `x-auth-token: <service-account-key>`
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >
        JWT token issued by the DataGOL Identity Provider. Embed `Authorization:
        Bearer <token>` in every request. Tokens contain `companyId`, `userId`,
        `roles`, and `permissions` claims.

````