---
metadata:
  - name: generator
    content: Diplodoc Platform v5.64.0
alternate:
  - https://boost.yandex.com/doc/en/analytics/content/mobile-api/stat/ref/drilldown.md
  - https://boost.yandex.com/doc/ru/analytics/content/mobile-api/stat/ref/drilldown.md
  - https://boost.yandex.com/doc/zh/analytics/content/mobile-api/stat/ref/drilldown.md
  - href: https://boost.yandex.com/doc/zh/analytics/content/mobile-api/stat/ref/drilldown.md
    type: text/markdown
    title: Markdown version
  - href: https://boost.yandex.com/doc/zh/llms.txt?revision=r21772739
    rel: describedby
---
> **Documentation Index:** Fetch the complete configuration index at https://boost.yandex.com/doc/zh/llms.txt?revision=r21772739

<div class="openapi">

# Drill down

<!-- markdownlint-disable-file -->

用于生成多级（树形结构）报告。 每个级别对应一个维度。
对 `drilldown` 方法的请求会返回指定父级别的一个子级别。 父级别由 `parent_id` 参数指定。 要获取顶级数据，请发送不包含 `parent_id` 参数的请求。
要获取嵌套级别的数据，必须指定从根节点的路径。 路径由 `id` 字段的值和 `dimension` 参数形成。 如果省略了`id`字段，请指定`name`字段。
See [一个示例](../examples.md#drilldown) with this request.

## Request

<div class="openapi__requests">

<div class="openapi__request__wrapper" style="--method: var(--dc-openapi-methods-get);margin-bottom: 12px">

<div class="openapi__request">

GET {.openapi__method}
```text translate=no
https://api.appmetrica.yandex.net/stat/v1/data/drilldown
```

</div>

</div>

</div>

### Query parameters

#|
|| **Name** | **Description** ||
||

_params_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**Type**: object" %}

#|
||

_access_filter_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer
{.table-cell}
||
||

_accuracy_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_callback_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_confidence_level_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `0.95`
{.table-cell}
||
||

_date_dimension_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_date1_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `6daysAgo`
{.table-cell}
||
||

_date2_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `today`
{.table-cell}
||
||

_dimensions_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_direct_client_ids_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0
]
```

{% endcut %}
{.table-cell}
||
||

_direct_client_logins_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_exclude_insignificant_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
||

_filters_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_ids_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0
]
```

{% endcut %}
{.table-cell}
||
||

_include_meta_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
||

_include_undefined_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
||

_lang_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_limit_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `100`
{.table-cell}
||
||

_max_deviation_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `0.1`
{.table-cell}
||
||

_metrics_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_offset_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `1`
{.table-cell}
||
||

_only_expandable_undefined_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
||

_parent_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_preset_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_pretty_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `false`
{.table-cell}
||
||

_proposed_accuracy_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
||

_reference_row_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_request_domain_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_require_metric_values_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Default:_{.json-schema-reset .json-schema-value} `false`
{.table-cell}
||
||

_sort_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_timezone_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_with_confidence_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean
{.table-cell}
||
|#{.json-schema-properties}

{% endcut %}

_Example:_{.json-schema-reset .json-schema-example} ``
{.table-cell}
||
||

_statGroupParams_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**Type**: object" %}

#|
||

_label_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

_Min value:_{.json-schema-reset .json-schema-assertion} `1`
{.table-cell}
||
||

_org_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

_Min value:_{.json-schema-reset .json-schema-assertion} `1`
{.table-cell}
||
|#{.json-schema-properties}

{% endcut %}

_Example:_{.json-schema-reset .json-schema-example} ``
{.table-cell}
||
|#{.json-schema-properties}

## Responses

<div class="openapi__response__code__200">

## 200 OK

OK

<div class="openapi-entity">

### Body

{% cut "application/json" %}

```json translate=no
{
  "query": {
    "timezone": "example",
    "preset": "example",
    "dimensions": [
      "example"
    ],
    "metrics": [
      "example"
    ],
    "sort": [
      "example"
    ],
    "date1": "example",
    "date2": "example",
    "filters": "example",
    "limit": 0,
    "offset": 0
  },
  "data": [
    {
      "dimension": {},
      "metrics": [
        0.5
      ],
      "expand": true
    }
  ],
  "total_rows": 0,
  "total_rows_rounded": true,
  "sampled": true,
  "contains_sensitive_data": true,
  "sample_share": 0.5,
  "sample_size": 0,
  "sample_space": 0,
  "data_lag": 0,
  "totals": [
    0.5
  ],
  "min": [
    0.5
  ],
  "max": [
    0.5
  ]
}
```

{% endcut %}

#|
|| **Name** | **Description** ||
||

_contains_sensitive_data_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean

表示是否可以从响应中省略[敏感数据](https://yandex.com/support/metrica/reports/report-general.html#privacy)。 这些数据包括由 Yandex 算法计算出的数据：人口统计数据（性别、年龄等）、登录页地址、搜索词语以及机器人信息。 如果值是`true`，当样本少于10个用户时，响应不会显示这些数据。
Possible values: `真`, `假`.
{.table-cell}
||
||

_data_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**Type**: object[]" %}

#|
||

_dimension_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**Type**: object" %}

#|
||

_[additional]_{.json-schema-reset .json-schema-additional-property}
{.table-cell}|
**Type**: string

树级别指定的维度值。 例如，第二级树已设置（`parent_id` 数组长度为一个 ID）。 在这种情况下，字段包含请求中第二维度的值。

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% endcut %}

树级别指定的维度值。 例如，第二级树已设置（`parent_id` 数组长度为一个 ID）。 在这种情况下，字段包含请求中第二个维度的值。

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{}
```

{% endcut %}
{.table-cell}
||
||

_expand_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean

表示是否展开此行至树的下一级。
{.table-cell}
||
||

_metrics_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: number[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0.5
]
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

{% endcut %}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  {
    "dimension": {},
    "metrics": [
      0.5
    ],
    "expand": true
  }
]
```

{% endcut %}
{.table-cell}
||
||

_data_lag_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

数据更新延迟，以秒为单位。
{.table-cell}
||
||

_max_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: number[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0.5
]
```

{% endcut %}
{.table-cell}
||
||

_min_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: number[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0.5
]
```

{% endcut %}
{.table-cell}
||
||

_query_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**Type**: object" %}

#|
||

_date1_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

报告期的开始日期，格式为 YYYY-MM-DD。

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_date2_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

报告期末日期，格式为YYYY-MM-DD。

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_dimensions_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_filters_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

Segmentation filter.

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_limit_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

结果页上的项目数量。
{.table-cell}
||
||

_metrics_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_offset_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

请求数据第一行的索引，从1开始。
{.table-cell}
||
||

_preset_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

报告预设。

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_sort_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  "example"
]
```

{% endcut %}
{.table-cell}
||
||

_timezone_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

选择期间的时区，格式为 ±hh:mm。

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% endcut %}

Original request. 包含请求参数，包括模板中的详细参数和属性参数化的参数。

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "timezone": "example",
  "preset": "example",
  "dimensions": [
    "example"
  ],
  "metrics": [
    "example"
  ],
  "sort": [
    "example"
  ],
  "date1": "example",
  "date2": "example",
  "filters": "example",
  "limit": 0,
  "offset": 0
}
```

{% endcut %}
{.table-cell}
||
||

_sample_share_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: number

用于计算的数据百分比。 可用的值范围是 0 到 1。
{.table-cell}
||
||

_sample_size_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

请求数据中的行数。
{.table-cell}
||
||

_sample_space_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

数据行数。
{.table-cell}
||
||

_sampled_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean

Sampling flag. 表示是否应用了采样。 Possible values: `真`, `假`.
{.table-cell}
||
||

_total_rows_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

响应中整个数据集（过滤后）的总行数。
{.table-cell}
||
||

_total_rows_rounded_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: boolean

表示总行数已被四舍五入。
{.table-cell}
||
||

_totals_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: number[]

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
[
  0.5
]
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

</div>

</div>

</div>

[*Deprecated]: No longer supported, please use an alternative and newer version.