Version 0.1

List tasks

GET /projects/:project-id/tasks

Returns a list of tasks for the project. The returned list is paginated with 50 tasks per page. You can filter tasks by providing a search query. You can also choose the sort order.

Parameters

query

The search query. If not given, all tasks are returned. You can learn the search syntax here.

page

The page number. Defaults to 1.

order-by

Select the sort order. Can be one of the following. Defaults to updated-at-desc. * rank-asc -- By rank * created-at-desc -- By task creation time, descending * created-at-asc -- By task creation time, ascending * updated-at-desc -- By last updated at time of task, descending * updated-at-asc -- By last updated at time of task, ascending

Response

A list of task objects alongwith total count of matching tasks, current page number and total page count.

Example

Request
GET /projects/15/tasks?v=0.1
Host: api.deftask.com 
Response
200 OK
Content-Type: application/json

{
  "tasks": [
    {
      "projectId": 15,
      "taskId": 178,
      "createdAt": "2018-06-07T16:52:06.978319+05:30",
      "updatedAt": "2018-10-01T16:02:43.450783+05:30",
      "title": "Issue with a very long title let's see how this goes or not and going even longer",
      "state": "closed",
      "labelIds": [94, 98],
      "assigneeIds": [33584, 1],
      "creator": 1,
      "updater": 1,
      "readableActivityAt": "2018-09-30T23:11:45.067572+05:30",
      "viewedAt": "2018-10-01T16:02:43.629758+05:30"
    },
    {
      "projectId": 15,
      "taskId": 17612,
      "createdAt": "2018-09-30T21:58:01.136332+05:30",
      "updatedAt": "2018-09-30T21:58:50.711265+05:30",
      "title": "curl test 3",
      "state": "closed",
      "labelIds": [],
      "assigneeIds": [],
      "creator": 1,
      "updater": 1,
      "readableActivityAt": "2018-09-30T21:58:01.136619+05:30",
      "viewedAt": null
    },
    {
      "projectId": 15,
      "taskId": 17613,
      "createdAt": "2018-09-30T21:58:02.440978+05:30",
      "updatedAt": "2018-09-30T21:58:50.711265+05:30",
      "title": "curl test 3",
      "state": "closed",
      "labelIds": [],
      "assigneeIds": [],
      "creator": 1,
      "updater": 1,
      "readableActivityAt": "2018-09-30T21:58:02.441134+05:30",
      "viewedAt": null
    },
    ...
  ],
  "count": 101,
  "page": 1,
  "pageCount": 3,
  "previous": null,
  "next": https://api.deftask.com/projects/15/tasks?page=2&v=0.1
}