Task Templates - Approvals API

List all approvals of a task template

List all approvals of the task template with a specific ID:

GET /task_templates/:id/approvals

Response

Status: 200 OK
[
  {
    "approver": {
      "id": 6,
      "name": "Howard Tanner",
      "account": {
        "id": "widget",
        "name": "Widget International"
      }
    },
    "id": 2,
    "planned_effort": 4
  },
  {
    "approver": {
      "id": 82,
      "name": "Beatrice Baldwin",
      "account": {
        "id": "widget",
        "name": "Widget International"
      }
    },
    "id": 24,
    "planned_effort": 3
  },
  "..."
]

The response contains these fields by default.

Add an approval to a task template

Add an approval to a task template with a specific ID.

POST /task_templates/:id/approvals

When creating a new approval for a task template these fields are available.

Response

Status: 201 Created
{
  "approver": {
    "id": 50378,
    "name": "Matt Leach"
  },
  "id": 16093,
  "planned_effort": 3
}

Update an approval of a task template

Update an approval of a task template with a specific ID.

PATCH /task_templates/:id/approvals/:approval_id

When updating an existing approval for a task template these fields are available.

Response

Status: 200 OK
{
  "planned_effort": 3,
  "...": "..."
}

Remove an approval from a task template

Remove an approval with a specific ID from a task template with a specific ID.

DELETE /task_templates/:id/approvals/:approval_id

Response

Status: 204 No Content

Remove all approvals from a task template

Remove all approval from a task template with a specific ID.

DELETE /task_templates/:id/approvals/

Response

Status: 204 No Content

Fields

approver
Required reference to Person — The ID of the person who is selected as the approver for the task template approval.
id
Readonly integer — The unique ID of the task template approval.
planned_effort
Optional integer — The Planned effort field is used to enter the number of hours the approver is expected to spend working on a task that was created based on the task template to which the approval belongs.