The following macros are not currently supported in the header:
  • style

Get Task

Resource URL

Returns a specific task object

GET /tasks/:id
ANY /tasks/:id?_method=get

For example,

GET /tasks/100.json

Would return a json object of task with id 100.

Parameters

Table of allowed parameters.

_fieldspartial stringAllows you to specify optional fields and linked objects to include in the response.

Handling the response

Below is a table of available response fields and objects that are returned within the response object of the returned object. The optional fields and objects can be requested in the _fields parameter; see included examples. Underlined values are default.

idunsignedActivity's unique identifier. This can be used to request other endpoints.
titlestring 
custom_idstring 
standingstringactive, pending, inactive, etc
billableunsignedTotal billable minutes
nonbillableunsignedTotal non-billable minutes
budgetedunsignedTotal budgeted minutes.
remainingunsignedTotal remaining minutes
loggedunsignedTotal minutes logged (includes billable and non-billable)
date_createdunix ts 
date_startedunix ts 
date_commencedunix ts 
date_acceptedunix ts 
date_completedunix ts 
date_modifiedunix ts 
date_dueunix ts 
creatorstringAPI resource endpoint for the task creator. For example, staff/12
creator_typestringThe type of creator. For example, staff or affiliation.
creator_idunsignedUnique identifier for the creator object.
assigneeunsigned or objectSee GET staff/:id for response details.
typeunsigned or object 
statusunsigned or object 
managerunsigned or object 
contactunsigned or object 
against_idunsigned intThe id of the object the task is against.
against_typestringThe type of object the task is against. e.g, prospect, company, issue, job or milestone.
companyunsigned intIf the task is against a company, this will return the company's id
company()objectIf the task is against a company, this will return the company's object.
jobunsigned intIf the task is against a job, this will return the job's id
job()objectIf the task is against a job, this will return the job's object.
issueunsigned intIf the task is against an issue, this will return the issue's id.
issue()objectIf the task is against an issue, this will return the issue's object.
milestoneunsigned intIf the task is against a milestone, this will return the milestone's id.
milestone()objectIf the task is against a milestone, this will return the milestone's object.
breadcrumbsarrayContains an array of breadcrumbs for the given task.

Fields that can be object indicate the field can be requested as a resource. For example.

GET /tasks/1.json?_fields=assignee

would return the task's assignee's staff id. Where as,

GET /tasks/1.json?_fields=assignee(email)

would return the assignee's staff object, including any optional fields or objects within the parenthesis. In the above examples case, it would return the staff objects default values and optional email value.

Sample Response

GET /tasks/1.json?_fields=date_created,date_started,assignee(email),type(color)
{
   "response" : {
         "date_created" : "1003327200",
         "assignee" : {
            "email" : "geoff.mcqueen@affinitylive.com",
            "firstname" : "Geoff",
            "id" : "1000",
            "surname" : "McQueen"
         },
         "type" : {
            "title" : "Default",
            "id" : "1"
         },
         "title" : "Complaints System Database",
         "id" : "1",
         "date_started" : "1003327200"
      },
      {
         "date_created" : "1017320400",
         "assignee" : {
            "email" : "adrian@internetrix.com.au",
            "firstname" : "Adrian",
            "id" : "3",
            "surname" : "Smalley"
         },
         "type" : {
            "title" : "Default",
            "id" : "1"
         },
         "title" : "Design Refinement and Tweaking",
         "id" : "2",
         "date_started" : "1017320400"
   },
   "meta" : {
      "status" : "ok",
      "message" : "Everything executed as expected."
   }
}