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

# Get Task

`GET /v1/tasks/{id}`

Retrieves the data for a specific task by its ID.

## Path parameters

- `id` string, required — The id of the task to get.

## Response `200`

Successfully retrieved task data.

- union — Task response
  - union — The response of an apply-effect task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'apply-effect', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `effect` 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` ImageFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the image in bytes
            - `width` number, required — The width of the image in pixels
            - `height` number, required — The height of the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'apply-effect', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `effect` 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'apply-effect', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `effect` 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'apply-effect', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `effect` 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an convert task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` ImageFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the image in bytes
            - `width` number, required — The width of the image in pixels
            - `height` number, required — The height of the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of the detect-documents operation
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `documents` object[], required — The list of documents detected in the image
          - `file_id` string, required — The ID of the file containing the document
          - `vertices` object[], required — The coordinates of the vertex inside the image
            - `x` number, required — The x coordinate of the vertex inside the image in pixels
            - `y` number, required — The y coordinate of the vertex inside the image in pixels
          - `bounding_box` BoundingBox, required — The rectangle that contains the document in the image
            - `top` number, required — The position of the top-left corner of the bounding box inside the image in pixels
            - `left` number, required — The position of the top-left corner of the bounding box inside the image in pixels
            - `width` number, required — The width of the bounding box inside the image in pixels
            - `height` number, required — The height of the bounding box inside the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'convert', required — The type of operation being performed by the task.
      - `parameters` union, required
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/png', required — The format to convert the image to.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/jpeg', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like jpeg.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `name` string — The name of the file
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `target_format` 'image/webp', required — The format to convert the image to.
          - `quality` number, required — Image quality (1-100) for lossy formats like webp.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an extract-text task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-text', required — The type of operation being performed by the task.
      - `parameters` union, required — Extract text from an image in various formats.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'plain', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'markdown', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'html', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'json', required — The format of the text to be extracted.
          - `schema` JSONSchemaSpec, required — An OpenAPI schema object describing the expected JSON structure. Required if format is 'json'.
            - `type` 'string' | 'number' | 'integer' | 'boolean' | 'array' | 'object'
            - `format` string
            - `description` string
            - `example` unknown
            - `properties` object
            - `items` JSONSchemaSpec — recursive
            - `required` string[]
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `format` 'plain' | 'markdown' | 'html' | 'json', required
        - `content` string, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-text', required — The type of operation being performed by the task.
      - `parameters` union, required — Extract text from an image in various formats.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'plain', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'markdown', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'html', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'json', required — The format of the text to be extracted.
          - `schema` JSONSchemaSpec, required — An OpenAPI schema object describing the expected JSON structure. Required if format is 'json'.
            - `type` 'string' | 'number' | 'integer' | 'boolean' | 'array' | 'object'
            - `format` string
            - `description` string
            - `example` unknown
            - `properties` object
            - `items` JSONSchemaSpec — recursive
            - `required` string[]
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-text', required — The type of operation being performed by the task.
      - `parameters` union, required — Extract text from an image in various formats.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'plain', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'markdown', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'html', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'json', required — The format of the text to be extracted.
          - `schema` JSONSchemaSpec, required — An OpenAPI schema object describing the expected JSON structure. Required if format is 'json'.
            - `type` 'string' | 'number' | 'integer' | 'boolean' | 'array' | 'object'
            - `format` string
            - `description` string
            - `example` unknown
            - `properties` object
            - `items` JSONSchemaSpec — recursive
            - `required` string[]
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-text', required — The type of operation being performed by the task.
      - `parameters` union, required — Extract text from an image in various formats.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'plain', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'markdown', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'html', required — The format of the text to be extracted.
        - object
          - `input` string, required — The id of the file or task to operate on.
          - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
          - `format` 'json', required — The format of the text to be extracted.
          - `schema` JSONSchemaSpec, required — An OpenAPI schema object describing the expected JSON structure. Required if format is 'json'.
            - `type` 'string' | 'number' | 'integer' | 'boolean' | 'array' | 'object'
            - `format` string
            - `description` string
            - `example` unknown
            - `properties` object
            - `items` JSONSchemaSpec — recursive
            - `required` string[]
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an warp task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'warp', required — The type of operation being performed by the task.
      - `parameters` WarpRequest, required — Transform an image by warping it to a quadrilateral.
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `vertices` unknown[], required — Coordinates of the 4 vertices of the quadrilateral to warp the image to.
          - unknown
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` ImageFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the image in bytes
            - `width` number, required — The width of the image in pixels
            - `height` number, required — The height of the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'warp', required — The type of operation being performed by the task.
      - `parameters` WarpRequest, required — Transform an image by warping it to a quadrilateral.
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `vertices` unknown[], required — Coordinates of the 4 vertices of the quadrilateral to warp the image to.
          - unknown
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'warp', required — The type of operation being performed by the task.
      - `parameters` WarpRequest, required — Transform an image by warping it to a quadrilateral.
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `vertices` unknown[], required — Coordinates of the 4 vertices of the quadrilateral to warp the image to.
          - unknown
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'warp', required — The type of operation being performed by the task.
      - `parameters` WarpRequest, required — Transform an image by warping it to a quadrilateral.
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `vertices` unknown[], required — Coordinates of the 4 vertices of the quadrilateral to warp the image to.
          - unknown
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an extract task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-pages', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `pages` string, required — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` DocumentFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'application/pdf', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the document in bytes
            - `page_count` number, required — The number of pages in the document
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-pages', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `pages` string, required — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-pages', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `pages` string, required — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'extract-pages', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `pages` string, required — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an merge task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'merge', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string[], required — The list of ids of the files to be merged
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` DocumentFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'application/pdf', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the document in bytes
            - `page_count` number, required — The number of pages in the document
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'merge', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string[], required — The list of ids of the files to be merged
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'merge', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string[], required — The list of ids of the files to be merged
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'merge', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string[], required — The list of ids of the files to be merged
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an render task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'render', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `dpi` integer, required — Dots per inch (DPI) for the rendered image. Default is 300.
        - `pages` string — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` ImageFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the image in bytes
            - `width` number, required — The width of the image in pixels
            - `height` number, required — The height of the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'render', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `dpi` integer, required — Dots per inch (DPI) for the rendered image. Default is 300.
        - `pages` string — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'render', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `dpi` integer, required — Dots per inch (DPI) for the rendered image. Default is 300.
        - `pages` string — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'render', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `dpi` integer, required — Dots per inch (DPI) for the rendered image. Default is 300.
        - `pages` string — Page range (e.g., 2-7), a comma-separated list (e.g., 2,3,7) of pages.
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an split task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'split', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` DocumentFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'application/pdf', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the document in bytes
            - `page_count` number, required — The number of pages in the document
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'split', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'split', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'split', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
  - union — The response of an scan task
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'scan', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `scan_mode` 'none' | 'standard', required — Mode for detecting documents in the image. Available modes are: - **none**: No document detection is performed. - **standard**: Using a quick algorithm. Document is detected in the image, and the image is cropped to the detected document area fixing the perspective to match the document's shape.
        - `effect` 'none' | 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'completed', required — The current status of the task.
      - `result` object, required
        - `generated_files` ImageFromTaskResponse[], required
          - `id` string, required — The id of the file
          - `name` string, required — The name of the file
          - `task_id` string, required — The id of the task that generated this file
          - `created_at` string, required — The creation date of the file in ISO format
          - `type` 'image/png' | 'image/jpeg' | 'image/webp', required — The MIME type of the file
          - `properties` object, required
            - `size` number, required — The size of the image in bytes
            - `width` number, required — The width of the image in pixels
            - `height` number, required — The height of the image in pixels
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'scan', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `scan_mode` 'none' | 'standard', required — Mode for detecting documents in the image. Available modes are: - **none**: No document detection is performed. - **standard**: Using a quick algorithm. Document is detected in the image, and the image is cropped to the detected document area fixing the perspective to match the document's shape.
        - `effect` 'none' | 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'pending', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'scan', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `scan_mode` 'none' | 'standard', required — Mode for detecting documents in the image. Available modes are: - **none**: No document detection is performed. - **standard**: Using a quick algorithm. Document is detected in the image, and the image is cropped to the detected document area fixing the perspective to match the document's shape.
        - `effect` 'none' | 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'processing', required — The current status of the task.
      - `result` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.
    - object
      - `id` string, required — The unique identifier for the task.
      - `operation` 'scan', required — The type of operation being performed by the task.
      - `parameters` object, required
        - `input` string, required — The id of the file or task to operate on.
        - `name` string — The name of the file
        - `scan_mode` 'none' | 'standard', required — Mode for detecting documents in the image. Available modes are: - **none**: No document detection is performed. - **standard**: Using a quick algorithm. Document is detected in the image, and the image is cropped to the detected document area fixing the perspective to match the document's shape.
        - `effect` 'none' | 'grayscale' | 'scanner' | 'black-background', required — The effect to apply to the image
        - `callback_url` string, uri — The URL to call when the task is completed or failed. If you want to receive events, you probably prefer to use `webhooks` instead.
      - `status` 'failed', required — The current status of the task.
      - `result` object, required
        - `error` string, required
        - `details` object, required
      - `callback_url` string, nullable, required — The URL to which the task result will be sent upon completion or failure.
      - `created_at` string, required — The creation date of the task in ISO format.
      - `updated_at` string, required — The last update date of the task in ISO format.

## Other responses

- `404` — Task not found. The specified task does not exist.
- `422` — Validation Error. The request parameters are invalid.
- `429` — Rate Limit Exceeded.
- `5XX` — Internal Server Error.

## Changes

- **2025-06-24** `42f9aa9c3b27` — 48 breaking, 102 info
  - the `anyOf[subschema #1: Apply Effect Response]/oneOf[subschema #1: Completed apply-effect Task Response]/parameters/name/allOf[#/components/schemas/FileName]/` response property's maxLength was increased from `30` to `50` for the response status `200`
  - the `anyOf[subschema #1: Apply Effect Response]/oneOf[subschema #2: Pending apply-effect Task Response]/parameters/name/allOf[#/components/schemas/FileName]/` response property's maxLength was increased from `30` to `50` for the response status `200`
  - the `anyOf[subschema #1: Apply Effect Response]/oneOf[subschema #3: Processing apply-effect Task Response]/parameters/name/allOf[#/components/schemas/FileName]/` response property's maxLength was increased from `30` to `50` for the response status `200`
  - the `anyOf[subschema #1: Apply Effect Response]/oneOf[subschema #4: Failed apply-effect Task Response]/parameters/name/allOf[#/components/schemas/FileName]/` response property's maxLength was increased from `30` to `50` for the response status `200`
  - …146 more

[Change history](https://skmtc.dev/scan-documents/apis/scan-documents-api/changes/v1/tasks/:id/get.md)

---

[API](https://skmtc.dev/scan-documents/apis/scan-documents-api.md) · [All operations](https://skmtc.dev/scan-documents/apis/scan-documents-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/scan-documents/scan-documents-api/revisions/42f9aa9c3b27/schema)
