---
metadata:
  - name: generator
    content: Diplodoc Platform v5.52.0
alternate:
  - https://yandex.com/dev/metrika/en/management/openapi/offline_conversions/upload_1.md
  - https://yandex.com/dev/metrika/ru/management/openapi/offline_conversions/upload_1.md
  - href: ru/management/openapi/offline_conversions/upload_1.md
    type: text/markdown
    title: Markdown version
  - href: ../../../llms.txt
    type: text/markdown
    title: llms.txt
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.com/dev/metrika/ru/llms.txt

<!-- source: ru/management-src/Upravlenie-oflajn-konversiyami/upload_1.md -->
<div class="openapi">

# Загрузка офлайн-конверсий

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

Выполняет загрузку [офлайн-конверсий](https://yandex.com/dev/metrika/ru/management/conversion.md).

{% note tip %}

Сформируйте CSV-файл с информацией и передайте его с помощью данного метода.
Также рекомендуем генерировать запросы к API в автоматическом режиме с помощью модулей языка программирования.

{% endnote %}

О том, какие данные передавать, и пример запроса см. в разделе [Передача офлайн-конверсий](https://yandex.com/dev/metrika/ru/management/offline-conv.md).

{% note info %}

1. Обработка данных может занимать до двух часов.
2. Ограничение на размер файла — 1 Гб.
3. Кодировка файла — UTF-8.

{% endnote %}


## Request

<div class="openapi__requests">

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

<div class="openapi__request">

POST {.openapi__method}
```text translate=no
https://api-metrika.yandex.net/management/v1/counter/{counterId}/offline_conversions/upload
```

</div>

</div>

</div>

### Path parameters

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

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

Идентификатор счетчика, для которого вы хотите загрузить офлайн-конверсии.
{.table-cell}
||
|#{.json-schema-properties}

### Query parameters

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

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

Комментарий. Максимальная длина — 255 символов. Допустимы цифры, латинские и кириллические буквы.

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

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

Тип офлайн-конверсии.
Возможные значения:
- `BASIC` — тип по умолчанию;
- `CALLS` — звонки;
- `CHATS` — чаты.


_Default:_{.json-schema-reset .json-schema-value} `BASIC`

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

<div class="openapi-entity">

### Body

{% cut "multipart/form-data" %}

```json translate=no
{
  "file": "example"
}
```

{% endcut %}

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

_file_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string&lt;binary&gt;

Офлайн-конверсии, которые вы хотите загрузить, передаваемые как multipart/form-data. Ограничение на размер файла — 1 Гб. Кодировка файла — UTF-8.

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

</div>

## Responses

<div class="openapi__response__code__200">

## 200 OK

OK

<div class="openapi-entity">

### Body

{% cut "application/json" %}

```json translate=no
{
  "uploading": {
    "id": 0,
    "create_time": "2025-01-01T00:00:00Z",
    "source_quantity": 0,
    "line_quantity": 0,
    "comment": "example",
    "type": "BASIC",
    "client_id_type": "USER_ID",
    "status": "example"
  }
}
```

{% endcut %}

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

_uploading_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: [OfflineConversionUploading](#entity-OfflineConversionUploading)

Информация о загрузке офлайн-конверсий.

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

```json translate=no
{
  "id": 0,
  "create_time": "2025-01-01T00:00:00Z",
  "source_quantity": 0,
  "line_quantity": 0,
  "comment": "example",
  "type": "BASIC",
  "client_id_type": "USER_ID",
  "status": "example"
}
```

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

</div>

<div class="openapi-entity">

### OfflineConversionUploading {#entity-OfflineConversionUploading}

Информация о загрузке офлайн-конверсий.

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

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

Тип идентификаторов посетителей.
Возможные значения:
- `USER_ID` — идентификатор посетителя сайта, назначенный владельцем сайта.
- `CLIENT_ID` — идентификатор посетителя сайта, назначенный Яндекс Метрикой.
- `YCLID` — идентификатор клика по рекламному объявлению Яндекс Директа, назначенный Яндекс Директом.


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

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

Произвольный комментарий. Количество символов не должно превышать 255.

_Min length:_{.json-schema-reset .json-schema-assertion} `0`

_Max length:_{.json-schema-reset .json-schema-assertion} `255`

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

_create_time_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string&lt;date-time&gt;

Время загрузки.

_Example:_{.json-schema-reset .json-schema-example} `2025-01-01T00:00:00Z`
{.table-cell}
||
||

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

Идентификатор загрузки.
{.table-cell}
||
||

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

Количество строк, прошедших валидацию при загрузке.
{.table-cell}
||
||

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

Количество строк в исходном файле.
{.table-cell}
||
||

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

Статус загрузки:
- `PREPARED` — загрузка подготовлена.
- `UPLOADED` — загрузка завершена.
- `EXPORTED` — загрузка экспортирована.
- `MATCHED` — произведено сопоставление идентификаторов событий.
- `PROCESSED` — загрузка успешно обработана.
- `LINKAGE_FAILURE` — не удалось сопоставить ни один идентификатор посетителя. Если передана информация о статических звонках, они не будут привязаны к визитам в Метрике, но будут доступны в отчетах по звонкам.


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

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

Возможные значения:
- `BASIC` — тип по умолчанию;
- `CALLS` — звонки;
- `CHATS` — чаты.


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

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

```json translate=no
{
  "id": 0,
  "create_time": "2025-01-01T00:00:00Z",
  "source_quantity": 0,
  "line_quantity": 0,
  "comment": "example",
  "type": "BASIC",
  "client_id_type": "USER_ID",
  "status": "example"
}
```

{% endcut %}

</div>

</div>

</div>
<!-- endsource: ru/management-src/Upravlenie-oflajn-konversiyami/upload_1.md -->

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