Add a project to a task

Adds the task to the specified project, in the optional location
specified. If no location arguments are given, the task will be added to
the end of the project.

addProject can also be used to reorder a task within a project or
section that already contains it.

At most one of insert_before, insert_after, or section should be
specified. Inserting into a section in an non-order-dependent way can be
done by specifying section, otherwise, to insert within a section in a
particular place, specify insert_before or insert_after and a task
within the section to anchor the position of this task.

A task can have at most 20 projects multi-homed to it.

Returns an empty data block.

Path Params
string
required

The task to operate on.

Query Params
boolean

Provides “pretty” output.
Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.

Body Params

The project to add the task to.

object
Responses

Response body
object
object

An empty object. Some endpoints do not return an object on success. The success is conveyed through a 2-- status code and returning an empty object.

Has additional fields

Language
Credentials
OAuth2
Request
Asana Home
Asana helps you manage projects, focus on what's important, and organize work in one place for seamless collaboration.
© 2023 Asana, Inc.