# Contact Center AI Insights API . projects . locations . authorizedViewSets . authorizedViews . conversations

## Instance Methods

Gets conversation statistics.

Close httplib2 connections.

### Method Details

`calculateStats(location, filter=None, x__xgafv=None)`

    Gets conversation statistics.

    Args:
      location: string, Required. The location of the conversations. (required)
      filter: string, A filter to reduce results to a specific subset. This field is useful for getting statistics about conversations with specific properties.
      x__xgafv: string, V1 error format.
        Allowed values
          1 - v1 error format
          2 - v2 error format

    Returns:
      An object of the form:

        { # The response for calculating conversation statistics.
      "averageDuration": "A String", # The average duration of all conversations. The average is calculated using only conversations that have a time duration.
      "averageTurnCount": 42, # The average number of turns per conversation.
      "conversationCount": 42, # The total number of conversations.
      "conversationCountTimeSeries": { # A time series representing conversations over time. # A time series representing the count of conversations created over time that match that requested filter criteria.
        "intervalDuration": "A String", # The duration of each interval.
        "points": [ # An ordered list of intervals from earliest to latest, where each interval represents the number of conversations that transpired during the time window.
          { # A single interval in a time series.
            "conversationCount": 42, # The number of conversations created in this interval.
            "startTime": "A String", # The start time of this interval.
          },
        ],
      },
      "customHighlighterMatches": { # A map associating each custom highlighter resource name with its respective number of matches in the set of conversations.
        "a_key": 42,
      },
      "issueMatches": { # A map associating each issue resource name with its respective number of matches in the set of conversations. Key has the format: `projects//locations//issueModels//issues/` Deprecated, use `issue_matches_stats` field instead.
        "a_key": 42,
      },
      "issueMatchesStats": { # A map associating each issue resource name with its respective number of matches in the set of conversations. Key has the format: `projects//locations//issueModels//issues/`
        "a_key": { # Aggregated statistics about an issue.
          "displayName": "A String", # Display name of the issue.
          "issue": "A String", # Issue resource. Format: projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue}
          "labeledConversationsCount": "A String", # Number of conversations attached to the issue at this point in time.
        },
      },
      "smartHighlighterMatches": { # A map associating each smart highlighter display name with its respective number of matches in the set of conversations.
        "a_key": 42,
      },
    }

`close()`

    Close httplib2 connections.