Uploading information about calls

Uploads information about calls.

Tip

Create a CSV data file and send it using this method. We recommend that you also automate your API queries using modules available in your programming language.

For more information on what data to send and what a sample request looks like, see Passing offline conversions.

Note

It may take up to two hours to process the data after you upload it.

Request

POST

https://api-metrika.yandex.net/management/v1/counter/{counterId}/offline_conversions/upload_calls

Path parameters

Name

Description

counterId*

Type: integer<int32>

ID of the counter for which you want to upload information about calls.
Example: 2215573

Query parameters

Name

Description

comment

Type: string

Comment.

new_goal_name

Type: string

Name of a new goal for calls if this goal doesn't exist yet. If the goal exists, this parameter will be ignored.
Example: Звонок

Body

multipart/form-data
{
    "file": null
}

Name

Description

file*

Type: string<binary>

Call information to upload, which is passed as multipart/form-data.

Responses

200 OK

OK

Body

application/json
{
    "uploading": {
        "id": 0,
        "create_time": "2022-12-29T18:02:01Z",
        "source_quantity": 0,
        "line_quantity": 0,
        "comment": "string",
        "client_id_type": "USER_ID",
        "status": "string",
        "static_calls_quantity": 0,
        "dynamic_calls_quantity": 0
    }
}

Name

Description

uploading*

Type: OfflineCallsUploading

Information about call uploads.

OfflineCallsUploading

Information about call uploads.

Name

Description

client_id_type

Type: string

Type of user IDs. Possible values:

  • user_id: Site user ID assigned by the site owner.
  • client_id: Site user ID assigned by Yandex Metrica.
  • YCLID: The ID of a click on a Yandex Direct ad assigned by Yandex Direct.

Example: USER_ID

comment

Type: string

Custom comment. The maximum number of characters is 255.

Min length: 0

Max length: 255

create_time

Type: string<date-time>

Upload time.

dynamic_calls_quantity

Type: integer<int32>

Number of dynamic calls.

id

Type: integer<int64>

Upload ID.

line_quantity

Type: integer<int32>

Number of rows that passed validation during upload.

source_quantity

Type: integer<int32>

Number of rows in the source file.

static_calls_quantity

Type: integer<int32>

Number of static calls.

status

Type: string

Upload status:

  • PREPARED: Upload prepared.
  • UPLOADED: Upload complete.
  • EXPORTED: Upload exported.
  • MATCHED: Event IDs matched.
  • PROCESSED: Upload processed.
  • LINKAGE_FAILURE: Couldn't find a matching user ID. If you send data on static calls, they won't be attributed to sessions in Yandex Metrica, but they will appear in your call reports.

No longer supported, please use an alternative and newer version.