Para agentes de IA: markdown de esta página — /docs-content-en/tasks/day-plan.md índice de la documentación — /llms.txt

Los artículos de la documentación están disponibles actualmente en inglés.

Read the day plan

GET /v1/tasks/day-plan

Returns the tasks that the key owner added to the plan for the current day in the Bitrix24 workday widget.

Parameters

Parameter Type Required Description
expand (query) string no The only value is tasks: it adds a data.tasks array of task objects to the response. Without the parameter, only identifiers are returned

The method has no other query parameters: any of them is rejected with 400 INVALID_PARAMS.

Examples

curl — personal key

Terminal
curl "https://vibecode.bitrix24.com/v1/tasks/day-plan?expand=tasks" \
  -H "X-Api-Key: YOUR_API_KEY"

curl — OAuth application

Terminal
curl "https://vibecode.bitrix24.com/v1/tasks/day-plan?expand=tasks" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/day-plan?expand=tasks', {
  headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})

const { success, data } = await res.json()
console.log(data.taskIds)

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/day-plan?expand=tasks', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

const { success, data } = await res.json()
console.log(data.taskIds)

Response fields

Field Type Description
success boolean Always true on success
data object The day plan
data.taskIds number[] Identifiers of the day plan tasks in plan order. An empty array if the plan is empty
data.tasks object[] Only with expand=tasks. The plan tasks with the same fields as in the task list. All fields: Task fields

Response example

A request with expand=tasks, two tasks in the plan. The main task fields are shown:

JSON
{
  "success": true,
  "data": {
    "taskIds": [4125, 4127],
    "tasks": [
      {
        "id": 4125,
        "title": "Prepare the report",
        "status": 2,
        "responsibleId": 1317,
        "groupId": 155,
        "stageId": 625,
        "deadline": "2026-10-19T18:00:00.000Z"
      },
      {
        "id": 4127,
        "title": "Approve the contract",
        "status": 5,
        "responsibleId": 1317,
        "groupId": 155,
        "stageId": 625,
        "deadline": "2026-10-19T18:00:00.000Z"
      }
    ]
  }
}

Without expand, only the array of identifiers is returned:

JSON
{
  "success": true,
  "data": {
    "taskIds": [4125, 4127]
  }
}

Error response example

400 — an unsupported query parameter or a different expand value was passed:

JSON
{
  "success": false,
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Only expand=tasks is supported"
  }
}

Errors

HTTP Code Description
400 INVALID_PARAMS expand is not tasks, or another query parameter was passed
401 MISSING_API_KEY The X-Api-Key header is missing
401 TOKEN_MISSING The key has no valid Bitrix24 token
403 SCOPE_DENIED The key has neither the task nor the tasks scope
422 BITRIX_ERROR Bitrix24 rejected the request. The reason is in message
502 BITRIX_ERROR Bitrix24 returned a plan with an unexpected structure: Invalid day plan response

Full list of common API errors: Errors.

Known behavior

  • Only your own plan. The method reads the day plan of the Bitrix24 user the key acts on behalf of. You cannot read another employee's plan. A read-only key works.
  • The API does not fill the plan. Tasks are added to the plan manually in the Bitrix24 workday widget, with the "Select from list" button in the "Plan for the day" block. Starting a task timer does not add the task to the plan.
  • A completed task stays in the plan. After completion, its identifier is still returned in taskIds.
  • Reading trims the plan to 30 tasks, and the trim is saved. If the plan has more than 30 tasks, the call returns 30, and the extra tasks are removed from the plan permanently. The removed task is not necessarily the last one added.
  • The day plan and My Plan are different lists. My Plan stages are set by moving a task and read with the filter[stagesId] filter in the task list. They do not affect the day plan.

See also