> ## 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.

# Ask Attention V2

> Analyzes conversations or prompts to provide insights and attention points. This endpoint helps identify key information, sentiment, and important details in the provided content.



## OpenAPI

````yaml /api-reference/openapi.json post /ask_attention/v2
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:
  /ask_attention/v2:
    post:
      tags:
        - Tool
        - AskAttention
      summary: Ask Attention V2
      description: >-
        Analyzes conversations or prompts to provide insights and attention
        points. This endpoint helps identify key information, sentiment, and
        important details in the provided content.
      operationId: askAttentionV2
      parameters:
        - name: include_timestamps
          in: query
          description: >-
            When true, return timestamped segments (start/end seconds + excerpt)
            for each conversation alongside the textual answer.
          schema:
            type: boolean
        - name: summarize
          in: query
          description: >-
            When true, synthesize all per-conversation outputs into a single
            combined response appended with conversation_id "summary".
          schema:
            type: boolean
      requestBody:
        description: Request containing the content to be analyzed and analysis parameters
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AskAttentionRequestV2'
          application/vnd.api+json:
            schema:
              $ref: '#/components/schemas/AskAttentionRequestV2'
        required: true
      responses:
        '200':
          description: Content successfully analyzed with attention points identified
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AskAttentionResponseV2'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/AskAttentionResponseV2'
        '400':
          description: Bad request - invalid request parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Authentication failed - valid API key required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden - the API key does not have the necessary permissions
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error occurred during analysis
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    AskAttentionRequestV2:
      required:
        - conversations_ids
        - deal_id
        - prompt
      type: object
      properties:
        conversations_ids:
          type: array
          items:
            maxLength: 50
            type: string
        deal_id:
          type: string
        prompt:
          type: string
      example:
        conversations_ids: []
        deal_id: conv_123
        prompt: >-
          Customer mentioned budget constraints but showed interest in premium
          features
    AskAttentionResponseV2:
      type: array
      example:
        - output: Yes, this is an example of an 'Ask Attention' response
          conversation_id: conv_uuid_1
          error: ''
          segments:
            - start_sec: 120.5
              end_sec: 135
              text: Speaker A discusses pricing and discounts.
        - output: Yes, this is another example of an 'Ask Attention' response
          conversation_id: conv_uuid_2
          error: ''
          segments:
            - start_sec: 45
              end_sec: 62.5
              text: Speaker B asks about the integration timeline.
      items:
        required:
          - conversation_id
          - error
          - output
        type: object
        properties:
          output:
            type: string
          conversation_id:
            type: string
          error:
            type: string
          segments:
            type: array
            description: >-
              Optional timestamped segments relevant to the answer (present when
              include_timestamps=true).
            items:
              type: object
              properties:
                start_sec:
                  type: number
                  description: Start time in seconds
                end_sec:
                  type: number
                  description: End time in seconds
                text:
                  type: string
                  description: Transcript excerpt for this segment
          title:
            type: string
            description: Conversation title
    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
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      name: Authorization
      in: header

````