---
title: "Get task by id"
method: GET
path: "/tasks/{id}"
tags: ["Task"]
---

# Get task by id

`GET /tasks/{id}`

Returns a specific task. 

**[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
Permission to view the containing page or blog post and its corresponding space.

## Path parameters

- `id` integer, required

## Query parameters

- `body-format` 'storage' | 'atlas_doc_format' — The primary formats a body can be represented as. A subset of BodyRepresentation. These formats are the only allowed formats in certain use cases.

## Response `200`

Returned if the requested task is returned.

- Task
  - `id` string — ID of the task.
  - `localId` string — Local ID of the task. This ID is local to the corresponding page or blog post.
  - `spaceId` string — ID of the space the task is in.
  - `pageId` string — ID of the page the task is in.
  - `blogPostId` string — ID of the blog post the task is in.
  - `status` 'complete' | 'incomplete' — Status of the task.
  - `body` TaskBodySingle — Contains fields for each representation type requested.
    - `storage` BodyType
      - `representation` string — Type of content representation used for the value field.
      - `value` string — Body of the content, in the format found in the representation field.
    - `atlas_doc_format` BodyType
      - `representation` string — Type of content representation used for the value field.
      - `value` string — Body of the content, in the format found in the representation field.
  - `createdBy` string — Account ID of the user who created this task.
  - `assignedTo` string — Account ID of the user to whom this task is assigned.
  - `completedBy` string — Account ID of the user who completed this task.
  - `createdAt` string, date-time — Date and time when the task was created. In format "YYYY-MM-DDTHH:mm:ss.sssZ".
  - `updatedAt` string, date-time — Date and time when the task was updated. In format "YYYY-MM-DDTHH:mm:ss.sssZ".
  - `dueAt` string, date-time — Date and time when the task is due. In format "YYYY-MM-DDTHH:mm:ss.sssZ".
  - `completedAt` string, date-time — Date and time when the task was completed. In format "YYYY-MM-DDTHH:mm:ss.sssZ".

## Other responses

- `400` — Returned if an invalid request is provided.
- `401` — Returned if the authentication credentials are incorrect or missing from the request.
- `404` — Returned if the calling user does not have permission to view the requested task or the task was not found.

---

[API](https://skmtc.net/atlassian/apis/the-confluence-cloud-rest-api-v2.md) · [All operations](https://skmtc.net/atlassian/apis/the-confluence-cloud-rest-api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/atlassian/the-confluence-cloud-rest-api-v2/versions/c4bd1ed570f2/schema)
