Analyze Key Drivers

Version 4.0.26.6 (latest)

Analyze Key Drivers

Identifies the dimensional segments that most significantly drove a metric's change between two time periods.

Given a data source (a saved query or a model/explore pair), a contribution metric, and a list of dimensions to analyse, this endpoint compares a test (breach) period against a control (baseline) period and returns a ranked list of segment-level insights. Each insight reports the metric value in both periods, the absolute and relative difference, the unexpected deviation (how much a segment over or under-performed relative to the overall trend), its proportional contribution to the total change, and its a-priori support (what share of total volume that segment represents).

Request

POST /internal/kda/analyze
Datatype
Description
Request
HTTP Request
body
HTTP Body
Expand HTTP Body definition...
body
Analysis parameters
Expand KdaRequestPayload definition...
data_source
Defines the Looker dataset. Must provide either query_id OR (model_name + explore_name).
contribution_metric
string
The LookML measure to analyze (e.g., 'orders.total_revenue').
dimensions
string[]
base_filters
object
Optional Looker-syntax filters to scope the entire dataset (e.g., {'users.country': 'India'}).
baseline_filters
object
Defines the EXPECTED, PAST, or NORMAL group (State A). For time KDA, put the past date filter here (e.g., {'orders.created_date': 'last week'}). For cohort KDA, put the baseline segment here (e.g., {'users.status': 'Active'}).
breach_filters
object
Defines the ANOMALOUS, CURRENT, or COMPARISON group (State B). For time KDA, put the current date here. For 'Rest of Population' cohort comparisons, use a minus sign to negate the baseline (e.g., {'users.status': '-Active'}).

Response

200: Analysis result as JSON

Datatype
Description
status
string
Status of the analysis (e.g., 'SUCCESS', 'FAILED')
dimensions
string[]
drivers
any[]

400: Bad Request

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link

404: Not Found

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link

422: Validation Error

Datatype
Description
(object)
message
string
Error details
Expand ValidationErrorDetail definition...
field
string
Field with error
code
string
Error code
message
string
Error info message
documentation_url
string
Documentation link
documentation_url
string
Documentation link

429: Too Many Requests

Datatype
Description
(object)
message
string
Error details
documentation_url
string
Documentation link