Get the operation log

Attention

The toloka.yandex.com domain will be disabled starting May 1, 2023. Please use the toloka.dev domain for API requests.

Gets the operation log.

You can get logs for asynchronous operations (async_mode = true). Such operations run in the background.

Logs are available only for the last month. To get the logs for an earlier period, contact support.

You can get the operation log:

If the operation was successful, the log contains IDs of the created objects, otherwise it contains the details of validation errors.

Request

Production version
Sandbox
GET https://toloka.dev/api/v1/operations/<operation_id>/log
Authorization: OAuth <OAuth token>

Path parameters

ParameterOverview
operation_idOperation ID.

Headers

TitleOverview
AuthorizationA token for account authorization. Add OAuth as a prefix.

Response

Contains a JSON array describing each step of the operation.

[
{
"type": <action type>,
"success": <true/false>,
"input": {
<input values at the operation step>
},
"output": {
<output values at the operation step or error details>
}
},
...
]
ParameterOverview
type

string

Type of operation step. It depends on:

  • Type of operation for which the log is requested.

  • Execution result (success: true/false).

    The type values for a successful asynchronous operation:

  • USER_BONUS_PERSIST — Issuing a reward.

  • TASK_CREATE — Creating a task.

  • TASK_SUITE_CREATE — Creating a task suite.

    The type values for a failed asynchronous operation:

  • USER_BONUS_VALIDATE — Issuing a reward.

  • TASK_VALIDATE — Creating a task.

  • TASK_SUITE_VALIDATE — Creating a task suite.

    The type of operation step determines the input and output values.

success

boolean

Step result:

  • true — Completed successfully.
  • false — Not completed.
inputJSON

The data in the input is copied from the input data passed when creating the operation.
output

JSON

Output values at the operation step.

The data in the output for a successful operation:

  • For the action USER_BONUS_PERSISTuser_bonus_id (the ID of the issued reward).

  • For the action TASK_CREATEtask_id (the ID of the created task).

  • For the action TASK_SUITE_CREATEtask_suite_id (the ID of the created task suite).

    Data in the output for a failed operation:

  • code — Name of the error.

  • message — Explanation of how to fix the error.

  • payload — Specifies the error reason if code = VALIDATION_ERROR.

Example of a log when a reward was issued successfully
Example of a log when issuing a reward failed
Contact support
Toloka API
OverviewAccessing the APIRate limiting
Quick start
Reference
Project
Pools
Training
Subscriptions to events
Toloker selection
Ways to upload tasks
Tasks
Task suites
Tracking operations
Getting responses
Checking completed tasks
Rewards
Messages for Tolokers
Various parameters
Libraries