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

# List Playbook Customer Interactions

> Returns a list of customer interactions for the playbook, ordered with the most recent first by `last_recorded_at` (when its most recent recording took place). Results are paginated using a cursor with a fixed page size of 50; there is no `limit` parameter. Pass the `next_cursor` returned by a previous response as the `cursor` query parameter to fetch the next page. When `next_cursor` is `null`, there are no more results.

Pass `include_analysis=true` to additionally return the `analysis` (the section-by-section assessment of the interaction against its playbook) and `outcome` fields for each customer interaction. These are omitted by default.

Pass `start_date`, `end_date` or both to only return customer interactions whose `last_recorded_at` is in the half-open range `start_date <= last_recorded_at < end_date`. Omitting either leaves that side unbounded. To page through a filtered list, send the same `start_date` and `end_date` with every `cursor`.

> [!NOTE]
>
> **Building AI-powered analysis on top of interaction data?** Use the [Alpharun MCP server](https://dev.alpharun.com/mcp-server.md) instead of exporting interactions into your own system. It gives AI assistants and agents live, queryable access to interactions, transcripts, and playbook analytics — including semantic transcript search — with no data pipeline to build or keep in sync. This endpoint is best for listing records as part of a system integration, not for bulk-copying your Alpharun data.


## OpenAPI

````yaml GET /playbooks/{PLAYBOOK_ID}/customer-interactions
openapi: 3.0.1
info:
  title: Alpharun API
  description: Alpharun REST API reference
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.alpharun.com/api/v1
security:
  - bearerAuth: []
paths:
  /playbooks/{PLAYBOOK_ID}/customer-interactions:
    get:
      description: >-
        Returns a list of customer interactions for the playbook, ordered with
        the most recent first by `last_recorded_at` (when its most recent
        recording took place). Results are paginated using a cursor with a fixed
        page size of 50; there is no `limit` parameter. Pass the `next_cursor`
        returned by a previous response as the `cursor` query parameter to fetch
        the next page. When `next_cursor` is `null`, there are no more results.


        Pass `include_analysis=true` to additionally return the `analysis` (the
        section-by-section assessment of the interaction against its playbook)
        and `outcome` fields for each customer interaction. These are omitted by
        default.


        Pass `start_date`, `end_date` or both to only return customer
        interactions whose `last_recorded_at` is in the half-open range
        `start_date <= last_recorded_at < end_date`. Omitting either leaves that
        side unbounded. To page through a filtered list, send the same
        `start_date` and `end_date` with every `cursor`.
      parameters:
        - name: PLAYBOOK_ID
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: ID of the playbook whose customer interactions to list.
        - name: include_analysis
          in: query
          description: >-
            When `true`, include the `analysis` and `outcome` fields in each
            customer interaction. Defaults to `false`, in which case both fields
            are omitted.
          required: false
          schema:
            type: boolean
            default: false
        - name: cursor
          in: query
          required: false
          schema:
            type: string
            nullable: true
          description: >-
            Pagination cursor returned as `next_cursor` in a previous response.
            Omit on the first request.
        - name: start_date
          in: query
          required: false
          schema:
            type: string
          description: >-
            Inclusive lower bound: only return customer interactions whose
            `last_recorded_at` is at or after this time. An ISO 8601 date or
            date-time, e.g. `2026-10-01` or `2026-10-01T09:00:00-07:00`. A value
            without an offset is interpreted as UTC.
        - name: end_date
          in: query
          required: false
          schema:
            type: string
          description: >-
            Exclusive upper bound: only return customer interactions whose
            `last_recorded_at` is before this time. An ISO 8601 date or
            date-time, e.g. `2026-11-01` or `2026-11-01T09:00:00-07:00`. A value
            without an offset is interpreted as UTC, so
            `start_date=2026-10-01&end_date=2026-11-01` covers October 2026 in
            UTC.
      responses:
        '200':
          description: List of customer interactions for the playbook
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      customer_interactions:
                        type: array
                        items:
                          $ref: '#/components/schemas/CustomerInteraction'
                  next_cursor:
                    type: string
                    nullable: true
                    description: >-
                      Cursor to pass as the `cursor` query parameter to fetch
                      the next page. `null` when there are no more results.
              example:
                data:
                  customer_interactions:
                    - id: abc123
                      teammate:
                        id: teammate123
                        email: jane.smith@example.com
                      summary: >-
                        Customer called about a billing discrepancy on their
                        March invoice. Agent confirmed a duplicate charge,
                        issued a refund, and the customer was satisfied.
                      last_recorded_at: '2026-10-21T15:42:10.123Z'
                      data_extraction_fields:
                        - key: customer_satisfaction_score
                          name: Customer Satisfaction Score
                          type: number
                          value: 4.5
                        - key: issue_resolved
                          name: Issue Resolved
                          type: boolean
                          value: true
                      account:
                        id: account123
                        ext_id: ext_account_456
                      contacts:
                        - id: contact123
                          first_name: John
                          last_name: Doe
                          email: john.doe@example.com
                          phone_number: '+1234567890'
                          ext_id: ext_contact_789
                          custom_fields:
                            - key: preferred_contact_method
                              name: Preferred Contact Method
                              type: text
                              value: email
                next_cursor: null
        '400':
          description: Invalid `cursor`, `start_date` or `end_date`
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Playbook not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    CustomerInteraction:
      type: object
      required:
        - id
        - teammate
        - account
        - contacts
        - last_recorded_at
      properties:
        id:
          type: string
          description: ID of the customer interaction
        teammate:
          type: object
          description: >-
            The teammate (human or AI agent) associated with the customer
            interaction.
          required:
            - id
            - email
          properties:
            id:
              type: string
              format: uuid
              description: Unique identifier of the teammate
            email:
              type: string
              format: email
              description: Email address of the teammate
        summary:
          type: string
          nullable: true
          description: >-
            Summary of the customer interaction. Only generated when a Summary
            template is configured on the playbook the customer interaction is
            attached to; `null` otherwise.
        last_recorded_at:
          type: string
          format: date-time
          description: >-
            When the most recent recording in this customer interaction took
            place, as an ISO 8601 date-time.
        data_extraction_fields:
          type: array
          nullable: true
          description: >-
            Data extraction fields processed for the customer interaction. You
            can configure your data extraction fields in your Alpharun company
            settings.
          items:
            type: object
            required:
              - key
              - name
              - type
              - value
            properties:
              key:
                type: string
                description: Machine-readable key of the data extraction field
              name:
                type: string
                description: Human-friendly name of the data extraction field
              type:
                type: string
                enum:
                  - text
                  - date_and_time
                  - number
                  - boolean
                description: Data type of the field
              value:
                oneOf:
                  - type: string
                  - type: number
                  - type: boolean
                nullable: true
                description: Value of the data extraction field
        custom_fields:
          type: array
          nullable: true
          description: >-
            Custom fields (customer interaction metadata) manually set on the
            customer interaction — via the recording upload `custom_fields`
            option or the `PATCH /customer-interactions/{id}` endpoint. Unlike
            `data_extraction_fields`, these are not AI-generated. Define them in
            your Alpharun company settings. `null` when none are set.
          items:
            type: object
            required:
              - key
              - name
              - type
              - value
            properties:
              key:
                type: string
                description: Machine-readable key of the custom field
              name:
                type: string
                description: Human-friendly name of the custom field
              type:
                type: string
                enum:
                  - text
                  - date_and_time
                  - number
                  - boolean
                description: Data type of the custom field
              value:
                oneOf:
                  - type: string
                  - type: number
                  - type: boolean
                nullable: true
                description: Value of the custom field
        account:
          type: object
          required:
            - id
          properties:
            id:
              type: string
              description: ID of the account
            ext_id:
              type: string
              nullable: true
              description: External ID of the account
        contacts:
          type: array
          description: List of contacts associated with the customer interaction
          items:
            type: object
            required:
              - id
            properties:
              id:
                type: string
                description: ID of the contact
              first_name:
                type: string
                nullable: true
                description: First name of the contact
              last_name:
                type: string
                nullable: true
                description: Last name of the contact
              email:
                type: string
                nullable: true
                description: Email address of the contact
              phone_number:
                type: string
                nullable: true
                description: Phone number of the contact
              ext_id:
                type: string
                nullable: true
                description: External ID of the contact
              custom_fields:
                type: array
                description: Custom fields associated with the contact
                items:
                  type: object
                  required:
                    - key
                    - name
                    - type
                    - value
                  properties:
                    key:
                      type: string
                      description: Machine-readable key of the custom field
                    name:
                      type: string
                      description: Human-friendly name of the custom field
                    type:
                      type: string
                      enum:
                        - text
                        - date_and_time
                        - number
                        - boolean
                      description: Data type of the custom field
                    value:
                      oneOf:
                        - type: string
                        - type: number
                        - type: boolean
                      nullable: true
                      description: Value of the custom field
        analysis:
          type: array
          nullable: true
          description: >-
            Structured assessment of the interaction against its playbook.
            **Only present when the request is made with
            `include_analysis=true`.** A list of sections, each containing a
            list of criteria (see `AnalysisSectionNode`). `null` when the
            interaction has not been graded yet.
          items:
            $ref: '#/components/schemas/AnalysisSectionNode'
        outcome:
          type: object
          nullable: true
          description: >-
            The outcome recorded for the interaction, as defined by its
            playbook. **Only present when the request is made with
            `include_analysis=true`, and only when the playbook defines an
            outcome.**
          required:
            - name
            - value
          properties:
            name:
              type: string
              description: Name of the outcome as configured on the playbook
            value:
              type: string
              nullable: true
              description: >-
                The recorded outcome value's label, or `null` when no outcome
                has been recorded for the interaction.
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
    AnalysisSectionNode:
      type: object
      description: A section of the analysis, containing a list of criteria.
      required:
        - type
        - name
        - is_applicable
        - commentary
        - nodes
      properties:
        type:
          type: string
          enum:
            - section
          description: Discriminator identifying this node as a section.
        name:
          type: string
          description: Name of the section as configured on the playbook.
        is_applicable:
          type: boolean
          description: >-
            Whether the section was found applicable to this interaction. When
            `false`, `nodes` is an empty array (the contained criteria were not
            graded).
        commentary:
          type: string
          nullable: true
          description: >-
            AI-generated commentary for the section, or `null` when none was
            produced.
        nodes:
          type: array
          description: The section's criteria. Empty when the section is not applicable.
          items:
            $ref: '#/components/schemas/AnalysisCriteriaNode'
    AnalysisCriteriaNode:
      type: object
      description: A single graded criterion.
      required:
        - type
        - name
        - value
        - commentary
      properties:
        type:
          type: string
          enum:
            - criteria
          description: Discriminator identifying this node as a criterion.
        name:
          type: string
          description: Name of the criterion as configured on the playbook.
        value:
          type: string
          description: The graded value for the criterion.
        commentary:
          type: string
          description: AI-generated commentary explaining the grade.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.