1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2024-12-16 11:38:11 +02:00
OpenIntegrations/docs/en/md/Bitrix24/Timekeeping/Get-task-time-accounting-list.md
2024-08-18 17:47:59 +03:00

2.2 KiB

sidebar_position
3

Get task time accounting list

Get list of time accounting records for task

Function GetTaskTimeAccountingList(Val URL, Val TaskID, Val Token = "") Export

Parameter CLI option Type Description
URL --url String URL of webhook or a Bitrix24 domain, when token used
TaskID --task String, Number Task ID
Token --token String Access token, when app auth method used

Returns: Map Of KeyAndValue - serialized JSON of answer from Bitrix24 API


:::tip Method at API documentation: task.elapseditem.getlist :::

    URL    = "https://b24-ar17wx.bitrix24.by/rest/1/ztbe...";
    TaskID = "1092";

    Result = OPI_Bitrix24.GetTaskTimeAccountingList(URL, TaskID);

    URL   = "b24-ar17wx.bitrix24.by";
    Token = "c03fa966006e9f06006b12e400000001000...";

    Result = OPI_Bitrix24.GetTaskTimeAccountingList(URL, TaskID, Token);
    
  oint bitrix24 GetTaskTimeAccountingList --url "b24-ar17wx.bitrix24.by" --task "1088" --token "fe3fa966006e9f06006b12e400000001000..."

{
  "result": [
  {
  "ID": "40",
  "TASK_ID": "638",
  "USER_ID": "1",
  "COMMENT_TEXT": "",
  "SECONDS": "3600",
  "MINUTES": "60",
  "SOURCE": "2",
  "CREATED_DATE": "2024-07-12T20:36:21+00:00",
  "DATE_START": "2024-07-12T20:36:21+00:00",
  "DATE_STOP": "2024-07-12T20:36:21+00:00"
  },
  {
  "ID": "42",
  "TASK_ID": "638",
  "USER_ID": "10",
  "COMMENT_TEXT": "Time spent on work",
  "SECONDS": "7200",
  "MINUTES": "120",
  "SOURCE": "2",
  "CREATED_DATE": "2024-06-12T17:36:21+00:00",
  "DATE_START": "2024-07-12T20:36:22+00:00",
  "DATE_STOP": "2024-07-12T20:36:22+00:00"
  }
  ],
  "total": 2,
  "time": {
  "start": 1720816584.48831,
  "finish": 1720816584.5364,
  "duration": 0.0480880737304688,
  "processing": 0.0219790935516357,
  "date_start": "2024-07-12T20:36:24+00:00",
  "date_finish": "2024-07-12T20:36:24+00:00",
  "operating_reset_at": 1720817184,
  "operating": 0
  }
  }