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

# List Roles

> Returns a list of roles



## OpenAPI

````yaml /api-reference/openapi.json get /organizations/roles
openapi: 3.0.1
info:
  title: Attention Service V2
  description: Attention Service API V2
  termsOfService: https://www.attention.com/terms-of-use
  contact:
    name: Attention Team
    url: https://docs.attention.com/welcome
    email: support@attention.com
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
  version: 1.8.0
servers:
  - url: https://api.attention.tech/v2
security:
  - APIKeyHeader: []
paths:
  /organizations/roles:
    get:
      tags:
        - Organization
      summary: List Roles
      description: Returns a list of roles
      operationId: listOrganizationRoles
      responses:
        '200':
          description: Roles successfully returned
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListOrganizationRolesResponse'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/ListOrganizationRolesResponse'
        '401':
          description: Valid API key required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Base_401_Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Base_401_Error'
        '500':
          description: Unexpected server error. Please try again later.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Base_500_Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Base_500_Error'
        default:
          description: unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    ListOrganizationRolesResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/Role'
      example:
        data:
          - name: Admin
            type: ADMIN
            uuid: 84e67f54-5157-442b-a2b3-8b9c728b2fef
          - name: Sales Rep
            type: SALES_REP
            uuid: 55906d03-2849-4c3c-a67f-da07a6300de4
    Base_401_Error:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/BaseError'
      example:
        code: 401
        message: unauthenticated for Invalid API key
    Base_500_Error:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/Error'
      example:
        code: '500'
        detail: >-
          An unexpected error occurred on the server. Please try again later or
          contact support if the problem persists.
        id: internal_server_error
        title: Internal Server Error
    Error:
      type: object
      properties:
        id:
          type: string
          description: A unique identifier for the error.
        status:
          type: string
          description: >-
            The HTTP status code applicable to this problem, expressed as a
            string value.
        code:
          type: string
          description: An application-specific error code, expressed as a string value.
        title:
          type: string
          description: A short, human-readable summary of the problem.
        detail:
          type: string
          description: >-
            A human-readable explanation specific to this occurrence of the
            problem.
        source:
          type: object
          properties:
            pointer:
              type: string
            parameter:
              type: string
        meta:
          type: object
          properties: {}
      example:
        id: not_found_error
        status: '404'
        code: '404'
        title: Not Found Error
        detail: The requested resource was not found
        source:
          pointer: /data/attributes/id
    Role:
      type: object
      properties:
        uuid:
          type: string
        name:
          type: string
        type:
          type: string
      example:
        uuid: 84e67f54-5157-442b-a2b3-8b9c728b2fef
        name: Admin
        type: ADMIN
    BaseError:
      type: object
      properties:
        code:
          type: string
          description: Error code
        message:
          type: string
          description: Error message
      example:
        code: unauthorized
        message: Invalid or expired API key
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      name: Authorization
      in: header

````