ecl-logo Documentation

CreateAsanaTask

CreateAsanaTask[task]id

creates a new asana task and returns its id.

Details

  • Returns $Failed if any errors encountered creating the task.
  • All keys in the task except Name are optional; if any keys are not specified they will not be set in the new task.
  • If the ParentTask key is specified, the newly created task will be a subtask of that task.
  • Valid keys for the task are: Name, Notes, Assignee, Followers, Projects, Tags, DueDate, ParentTask
  • Name: the string title for the task.
  • Notes: the task description.
  • Assignee: the person this task should be assigned to (must be an SLL person object).
  • Followers: a list of people that will be added as following this task (must be SLL person objects).
  • Projects: a list of projects this task should be added to (must be the project names as strings).
  • Tags: a list of Tags to add to this task (must be the tag names as strings).
  • DueDate: the due date for this task (must be a DateObject).
  • ParentTask: the task in which the new task should be created as a subtask (must be an asana GID supplied as an integer).
  • Input
    Output
    Messages
  • Assignee`1` does not have a valid Asana ID.
    ErrorUnexpected error creating Asana task.
    Followers`1` do not have valid Asana IDs.
    NameName must be a string.
    ParentTaskThe specified parent task, `1`, is not a valid Asana Task ID.
    SectionNotFoundThe specified section `1` could not be found in project `2`
    SectionProjectMismatchWhen specifying projects and sections, lengths must match.

Examples

Basic Examples  (5)

Create a new task and assignee it to someone:

Add Followers and Notes to a task:

Set the due date for the task:

Add Projects and Tags to a task:

Specify the Section in a Project's to add the task to (any spaces should be escaped with \):

Additional Examples  (2)

Specify Sections in different Projects to add a crosslisted task:

Subtasks  (1)

Create a new subtask within an existing task:

Messages  (8)

Assignee  (1)

Returns $Failed if the Asignee does not have an Asana ID:

Error  (2)

Returns $Failed if there was an error creating the task:

Messages if any followers do not have Asana IDs (2):

Followers  (1)

Messages if any of the followers do not have Asana IDs (1):

Name  (1)

Returns $Failed if the Name key is not specified:

ParentTask  (1)

Returns $Failed if the specified ParentTask does not exist:

SectionNotFound  (1)

Create task in Project and disregard Section, while raising a message, if the specified Section in not present in the Projects:

SectionProjectMismatch  (1)

Create task in project and disregard Sections, while raising a message, if Sections and Projects are not copacetic: