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

# Sitzungsmetriken nach Kategorie abrufen

> Ruft die Anzahl der Sitzungen und den ACU-Verbrauch ab, gruppiert nach Kategorie und Unterkategorie.

<div id="permissions">
  ## Berechtigungen
</div>

Erfordert einen Service-Benutzer mit der Berechtigung `ViewAccountMetrics` auf Enterprise-Ebene.


## OpenAPI

````yaml de/v3-openapi.yaml GET /v3/enterprise/metrics/sessions-by-category
openapi: 3.1.0
info:
  description: Devin v3 API mit Service-User-Authentifizierung und RBAC
  title: Devin API v3
  version: 3.0.0
servers: []
security:
  - bearerAuth: []
paths:
  /v3/enterprise/metrics/sessions-by-category:
    get:
      tags:
        - metrics
      summary: Sitzungsmetriken nach Kategorie abrufen
      description: >-
        Ruft die Anzahl der Sitzungen und den ACU-Verbrauch ab, gruppiert nach
        Kategorie und Unterkategorie.
      operationId: >-
        handle_get_sessions_by_category_v3_enterprise_metrics_sessions_by_category_get
      parameters:
        - in: query
          name: time_before
          required: true
          schema:
            title: Time Before
            type: integer
        - in: query
          name: time_after
          required: true
          schema:
            title: Time After
            type: integer
        - in: query
          name: org_ids
          required: false
          schema:
            anyOf:
              - items:
                  type: string
                type: array
              - type: 'null'
            title: Org Ids
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionsByCategoryResponse'
          description: Erfolgreiche Antwort
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Nicht autorisiert
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Verboten
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Nicht gefunden
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Konflikt
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Nicht verarbeitbarer Inhalt
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Zu viele Anfragen
components:
  schemas:
    SessionsByCategoryResponse:
      properties:
        categories:
          items:
            $ref: '#/components/schemas/CategoryMetrics'
          title: Categories
          type: array
      required:
        - categories
      title: SessionsByCategoryResponse
      type: object
    ProblemDetail:
      description: >-
        RFC 9457 application/problem+json-Fehlertext für die v3-API.


        detail wird aus dem Legacy-Body {"detail": ...} aus Gründen der
        Abwärtskompatibilität beibehalten; die

        anderen Member sind additiv. errors enthält Validierungsfehler auf
        Feldebene

        (nur 422).
      properties:
        detail:
          anyOf:
            - type: string
            - type: 'null'
          description: Eine menschenlesbare Erklärung, die speziell für diesen Fall gilt.
          title: Detail
        errors:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          description: Validierungsfehler auf Feldebene (nur bei 422-Antworten).
          title: Errors
        instance:
          anyOf:
            - type: string
            - type: 'null'
          description: Eine URI-Referenz (der Anfragepfad) für diesen Fall.
          title: Instance
        status:
          description: Der HTTP-Statuscode.
          title: Status
          type: integer
        title:
          description: Eine kurze, menschenlesbare Zusammenfassung des Problemtyps.
          title: Title
          type: string
        type:
          default: about:blank
          description: Eine URI-Referenz, die den Problemtyp identifiziert.
          title: Type
          type: string
      required:
        - title
        - status
      title: ProblemDetail
      type: object
    CategoryMetrics:
      properties:
        acus:
          title: Acus
          type: number
        category:
          title: Category
          type: string
        sessions_count:
          title: Sessions Count
          type: integer
        subcategories:
          items:
            $ref: '#/components/schemas/SubcategoryMetrics'
          title: Subcategories
          type: array
      required:
        - category
        - sessions_count
        - acus
        - subcategories
      title: CategoryMetrics
      type: object
    SubcategoryMetrics:
      properties:
        acus:
          title: Acus
          type: number
        display_name:
          title: Display Name
          type: string
        sessions_count:
          title: Sessions Count
          type: integer
        subcategory_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Subcategory Id
      required:
        - subcategory_id
        - display_name
        - sessions_count
        - acus
      title: SubcategoryMetrics
      type: object
  securitySchemes:
    bearerAuth:
      description: 'Servicebenutzer-Anmeldedaten (Präfix: cog_)'
      scheme: bearer
      type: http

````