1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-03-23 21:29:38 +02:00
2024-08-13 16:37:03 +03:00

2.0 KiB

sidebar_position
7

Create result from comment

Create task result from comment

Function CreateResultFromComment(Val URL, Val CommentID, Val Token = "") Export

Parameter CLI option Type Description
URL --url String URL of webhook or a Bitrix24 domain, when token used
CommentID --comment Number, String CommentID
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: tasks.task.result.addFromComment :::

  URL       = "https://b24-ar17wx.bitrix24.by/rest/1/f2ppp8uucc891111/";
  CommentID = "2932";
  
  Result = OPI_Bitrix24.CreateResultFromComment(URL, CommentID);
  
  URL       = "b24-ar17wx.bitrix24.by";
  Token     = "fe3fa966006e9f06006b12e400000001000...";
  CommentID = "2936";
  
  Result = OPI_Bitrix24.CreateResultFromComment(URL, CommentID, Token);
    
  oint bitrix24 CreateResultFromComment --url "b24-ar17wx.bitrix24.by" --comment "2936" --token "fe3fa966006e9f06006b12e400000001000..."

{
  "result": {
  "id": 130,
  "taskId": 432,
  "commentId": 1376,
  "createdBy": 1,
  "createdAt": "2024-07-05T13:38:22+00:00",
  "updatedAt": "2024-07-05T13:38:22+00:00",
  "status": 0,
  "text": "The task has been changed, let's split up",
  "formattedText": "The task has been changed, let's split up",
  "files": null
  },
  "time": {
  "start": 1720186706.85195,
  "finish": 1720186706.92671,
  "duration": 0.0747611522674561,
  "processing": 0.0460391044616699,
  "date_start": "2024-07-05T13:38:26+00:00",
  "date_finish": "2024-07-05T13:38:26+00:00",
  "operating_reset_at": 1720187306,
  "operating": 0
  }
  }