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

# Get scenario analytics summary

> Returns aggregate metrics for a scenario: participant count, total sessions,
average best score and rank, average lift, total practice minutes, and average
session duration. Accepts both UUID and slug for the scenario identifier.




## OpenAPI

````yaml /api-reference/openapi.yaml get /scenarios/{scenario_id}/analytics/summary
openapi: 3.0.3
info:
  title: Exec API
  version: '1.0'
  description: >
    REST API for programmatic access to your Exec workspace.


    Use the Exec API to read workspace data, list members, retrieve group
    information,

    and create interactive scenario creation sessions.


    ## Authentication

    All requests require a valid API key passed in the Authorization header:

    ```

    Authorization: Bearer exec_live_...

    ```


    Create API keys in your workspace settings under **Settings > API**.
servers:
  - url: https://api.exec.com/rest/v1
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Knowledge Hub - Folders
    x-group: Knowledge Hub
  - name: Knowledge Hub - Pages
    x-group: Knowledge Hub
  - name: Knowledge Hub - Sources
    x-group: Knowledge Hub
paths:
  /scenarios/{scenario_id}/analytics/summary:
    get:
      tags:
        - Scenarios
      summary: Get scenario analytics summary
      description: >
        Returns aggregate metrics for a scenario: participant count, total
        sessions,

        average best score and rank, average lift, total practice minutes, and
        average

        session duration. Accepts both UUID and slug for the scenario
        identifier.
      operationId: getScenarioAnalyticsSummary
      parameters:
        - name: scenario_id
          in: path
          required: true
          description: Scenario identifier (UUID or slug)
          schema:
            type: string
        - name: user_ids
          in: query
          description: >-
            Comma-separated user IDs to filter by. When combined with
            user_emails, results are unioned (all matching users from either
            list are included).
          schema:
            type: string
        - name: user_emails
          in: query
          description: >-
            Comma-separated user email addresses to filter by. When combined
            with user_ids, results are unioned (all matching users from either
            list are included).
          schema:
            type: string
        - name: group_ids
          in: query
          description: Comma-separated workspace group IDs to filter by
          schema:
            type: string
        - name: start_date
          in: query
          description: ISO 8601 datetime — only include sessions on or after this date
          schema:
            type: string
            format: date-time
        - name: end_date
          in: query
          description: ISO 8601 datetime — only include sessions on or before this date
          schema:
            type: string
            format: date-time
        - name: exclude_system_users
          in: query
          description: >-
            Exclude sessions from system users (emails ending in @exec.com).
            Default false.
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: Scenario analytics summary
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScenarioAnalyticsSummary'
              example:
                participant_count: 45
                total_sessions: 128
                average_best_score: 74.2
                average_best_rank: silver
                average_lift_percentage: 18.5
                total_practice_minutes: 742
                average_session_duration_seconds: 348
                score_distribution:
                  - rank: gold
                    count: 12
                    percentage: 26.7
                  - rank: silver
                    count: 18
                    percentage: 40
                  - rank: bronze
                    count: 10
                    percentage: 22.2
                  - rank: unranked
                    count: 5
                    percentage: 11.1
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  schemas:
    ScenarioAnalyticsSummary:
      type: object
      description: Aggregate analytics metrics for a scenario.
      properties:
        participant_count:
          type: integer
          description: Number of unique participants with graded sessions
        total_sessions:
          type: integer
          description: Total number of graded sessions
        average_best_score:
          type: number
          description: Average of each participant's best score (0-100)
        average_best_rank:
          type: string
          enum:
            - gold
            - silver
            - bronze
            - unranked
          description: Rank corresponding to the average best score
        average_lift_percentage:
          type: number
          description: Average improvement (best - first score) across participants
        total_practice_minutes:
          type: integer
          description: Total practice time across all sessions in minutes
        average_session_duration_seconds:
          type: number
          description: Average duration per session in seconds
        score_distribution:
          $ref: '#/components/schemas/ScenarioScoreDistribution'
    ScenarioScoreDistribution:
      type: array
      description: >-
        Rank distribution across participants based on best scores (Gold ≥90,
        Silver ≥75, Bronze ≥50, Unranked <50).
      items:
        type: object
        properties:
          rank:
            type: string
            enum:
              - gold
              - silver
              - bronze
              - unranked
            description: Performance rank
          count:
            type: integer
            description: Number of participants at this rank
          percentage:
            type: number
            description: Percentage of participants at this rank
    ValidationErrorDetail:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              description: Error category (e.g., "invalid_request")
            code:
              type: string
              description: Specific error code (e.g., "user_not_found")
            message:
              type: string
              description: Human-readable error message
  responses:
    Unauthorized:
      description: Missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationErrorDetail'
          example:
            error:
              type: authentication_error
              code: invalid_api_key
              message: Invalid or inactive API key
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationErrorDetail'
          example:
            error:
              type: not_found
              message: 'Scenario not found: abc123'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: |
        API key created in Settings > API.

        Format: `exec_live_` followed by 40 alphanumeric characters.

````