Asana · Schema
TaskBase
CollaborationProductivityProject ManagementProjectsTask ManagementTasksWorkflow
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "#/components/schemas/TaskBase",
"title": "TaskBase",
"allOf": [
{
"$ref": "#/components/schemas/TaskCompact"
},
{
"type": "object",
"properties": {
"approval_status": {
"type": "string",
"description": "*Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`.",
"enum": [
"pending",
"approved",
"rejected",
"changes_requested"
],
"example": "pending"
},
"assignee_status": {
"description": "*Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom.",
"type": "string",
"enum": [
"today",
"upcoming",
"later",
"new",
"inbox"
],
"example": "upcoming"
},
"completed": {
"description": "True if the task is currently marked complete, false if not.",
"type": "boolean",
"example": false
},
"completed_at": {
"description": "The time at which this task was completed, or null if the task is incomplete.",
"type": "string",
"format": "date-time",
"readOnly": true,
"nullable": true,
"example": "2012-02-22T02:06:58.147Z"
},
"completed_by": {
"allOf": [
{
"$ref": "#/components/schemas/UserCompact"
},
{
"readOnly": true,
"nullable": true
}
]
},
"created_at": {
"description": "The time at which this resource was created.",
"type": "string",
"format": "date-time",
"readOnly": true,
"example": "2012-02-22T02:06:58.147Z"
},
"dependencies": {
"description": "[Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency.",
"type": "array",
"items": {
"$ref": "#/components/schemas/AsanaResource"
},
"readOnly": true
},
"dependents": {
"description": "[Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent.",
"type": "array",
"items": {
"$ref": "#/components/schemas/AsanaResource"
},
"readOnly": true
},
"due_at": {
"description": "The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`.",
"type": "string",
"format": "date-time",
"example": "2019-09-15T02:06:58.147Z",
"nullable": true
},
"due_on": {
"description": "The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`.",
"type": "string",
"format": "date",
"example": "2019-09-15",
"nullable": true
},
"external": {
"description": "*OAuth Required*. *Conditional*. This field is returned only if external values are set or included by using [Opt In] (/docs/inputoutput-options).\nThe external field allows you to store app-specific metadata on tasks, including a gid that can be used to retrieve tasks and a data blob that can store app-specific character strings. Note that you will need to authenticate with Oauth to access or modify this data. Once an external gid is set, you can use the notation `external:custom_gid` to reference your object anywhere in the API where you may use the original object gid. See the page on Custom External Data for more details.",
"type": "object",
"properties": {
"gid": {
"type": "string",
"example": "1234"
},
"data": {
"type": "string",
"example": "A blob of information."
}
},
"example": {
"gid": "my_gid",
"data": "A blob of information"
}
},
"html_notes": {
"description": "[Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML.",
"type": "string",
"example": "<body>Mittens <em>really</em> likes the stuff from Humboldt.</body>"
},
"hearted": {
"description": "*Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not.",
"type": "boolean",
"example": true,
"readOnly": true
},
"hearts": {
"description": "*Deprecated - please use likes instead* Array of likes for users who have hearted this task.",
"type": "array",
"items": {
"$ref": "#/components/schemas/Like"
},
"readOnly": true
},
"is_rendered_as_separator": {
"description": "[Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`.",
"type": "boolean",
"example": false,
"readOnly": true
},
"liked": {
"description": "True if the task is liked by the authorized user, false if not.",
"type": "boolean",
"example": true
},
"likes": {
"description": "Array of likes for users who have liked this task.",
"type": "array",
"items": {
"$ref": "#/components/schemas/Like"
},
"readOnly": true
},
"memberships": {
"description": "*Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property.",
"type": "array",
"readOnly": true,
"items": {
"type": "object",
"properties": {
"project": {
"$ref": "#/components/schemas/ProjectCompact"
},
"section": {
"$ref": "#/components/schemas/SectionCompact"
}
}
}
},
"modified_at": {
"description": "The time at which this task was last modified.\n\nThe following conditions will change `modified_at`:\n\n- story is created on a task\n- story is trashed on a task\n- attachment is trashed on a task\n- task is assigned or unassigned\n- custom field value is changed\n- the task itself is trashed\n- Or if any of the following fields are updated:\n - completed\n - name\n - due_date\n - description\n - attachments\n - items\n - schedule_status\n\nThe following conditions will _not_ change `modified_at`:\n\n- moving to a new container (project, portfolio, etc)\n- comments being added to the task (but the stories they generate\n _will_ affect `modified_at`)",
"type": "string",
"format": "date-time",
"readOnly": true,
"example": "2012-02-22T02:06:58.147Z"
},
"name": {
"description": "Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer.",
"type": "string",
"example": "Buy catnip"
},
"notes": {
"description": "Free-form textual information associated with the task (i.e. its description).",
"type": "string",
"example": "Mittens really likes the stuff from Humboldt."
},
"num_hearts": {
"description": "*Deprecated - please use likes instead* The number of users who have hearted this task.",
"type": "integer",
"example": 5,
"readOnly": true
},
"num_likes": {
"description": "The number of users who have liked this task.",
"type": "integer",
"example": 5,
"readOnly": true
},
"num_subtasks": {
"description": "[Opt In](/docs/inputoutput-options). The number of subtasks on this task.\n",
"type": "integer",
"example": 3,
"readOnly": true
},
"start_at": {
"description": "Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`.\n*Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.*",
"type": "string",
"nullable": true,
"format": "date-time",
"example": "2019-09-14T02:06:58.147Z"
},
"start_on": {
"description": "The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`.\n*Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.*",
"type": "string",
"nullable": true,
"format": "date",
"example": "2019-09-14"
},
"actual_time_minutes": {
"description": "This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value.",
"type": "number",
"example": 200,
"readOnly": true,
"nullable": true
}
}
}
]
}