Skip to content

Latest commit

 

History

History
51 lines (42 loc) · 1.07 KB

File metadata and controls

51 lines (42 loc) · 1.07 KB

Add trackings to task

Description: Add a list of trackings to a certain task.
URL: /api/task/:taskId/tracking/
Method: POST
Data constraints: Provide trackings by their ids.

Example request:

POST http://localhost:3000/api/task/2/tracking/

{
  "trackings": ["2", "3"]
}

Example result:

Status: 200 OK

{
  "data": [
    {
      "id": "2",
      "description": "This is the 2nd test tracking.",
      "startTime": "2020-11-15T12:00:00.000Z",
      "endTime": null,
      "createdAt": "2020-11-22T15:45:20.150Z",
      "updatedAt": "2020-11-22T16:05:22.000Z"
    },
    {
      "id": "3",
      "description": "This is the 3rd test tracking.",
      "startTime": "2020-11-15T12:00:00.000Z",
      "endTime": "2020-11-15T15:00:00.000Z",
      "createdAt": "2020-11-22T15:45:20.159Z",
      "updatedAt": "2020-11-22T16:05:22.000Z"
    }
  ]
}