---
title: "Undeletes multiple 'TestCase' entities"
method: POST
path: "/testcase/bulk/undelete"
tags: ["TestCase"]
---

# Undeletes multiple 'TestCase' entities

`POST /testcase/bulk/undelete`

## Request

- Base URL: `https://app.testiny.io/api/v1`
- URL: `https://app.testiny.io/api/v1/testcase/bulk/undelete`
- Auth: API key in header `X-Api-Key`
- TypeScript: <https://skmtc.dev/testiny/apis/testiny-api/docs/testcase/bulk/undelete/post.ts> (a function with typed inputs; its response is checked against the schema)

Undeletes multiple existing 'TestCase' entities (only if the entity type supports soft-deletion). Returns a full undeleted entity list including (optional) deletion metadata.

## Request body

- TestCase[]
  - `id` integer: The unique entity id - must be a positive integer
  - `title` string: A descriptive title for this entity or mapping (1 to 500 characters)
  - `sort_index` number: An integer sort index for natural ordering of this entity or mapping value - value must be in range (-999999999999999,999999999999999)
  - `is_deleted` boolean: If the entity has been soft-deleted this value is true
  - `created_at` string, date-time: The creation time for this entity or mapping value
  - `created_by` number: The creator user id of this entity or mapping value - or zero if created by the system
  - `modified_at` string, date-time: The last modification time for this entity or mapping value
  - `modified_by` number: The id of the user who last modified or undeleted this entity or mapping value - or zero if modified by the system
  - `deleted_at` string, date-time: The soft-deletion time for this entity or mapping value
  - `deleted_by` number: The id of the user who deleted this entity or mapping value - or zero if deleted by the system
  - `_etag` string, required: A tag for detecting conflicting modifications - current value (may be empty) must be passed along in an update (or update must be forced)
  - `project_id` integer: The project id this entity or mapping belongs to
  - `owner_user_id` integer: The global user id of the test case owner
  - `$owner_name` string: The resolved display name of the owner user - read only
  - `type` string: Reserved for future use
  - `template` string: The template type used for the test case: STEPS, TEXT or BDD
  - `precondition_text` string: A description of the precondition required for the test case (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `content_text` string: The test case content - used with template STEPS (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `steps_text` string: The test case content - used with template TEXT (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `expected_result_text` string: The test case expected result - used with template TEXT (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `bdd_scenarios_text` string: The gherkin scenarios used with template BDD (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `priority` number: The test case priority (This is a builtin-custom field)
  - `status` string: The test case status (This is a builtin-custom field)
  - `testcase_type` string: The test case type (This is a builtin-custom field)
  - `automation` string: The test case automation status (This is a builtin-custom field)
  - `estimate` number: A test case time estimate (This is a builtin-custom field)

## Response `200`

Returns an array of TestCase.

- TestCase[]
  - `id` integer: The unique entity id - must be a positive integer
  - `title` string: A descriptive title for this entity or mapping (1 to 500 characters)
  - `sort_index` number: An integer sort index for natural ordering of this entity or mapping value - value must be in range (-999999999999999,999999999999999)
  - `is_deleted` boolean: If the entity has been soft-deleted this value is true
  - `created_at` string, date-time: The creation time for this entity or mapping value
  - `created_by` number: The creator user id of this entity or mapping value - or zero if created by the system
  - `modified_at` string, date-time: The last modification time for this entity or mapping value
  - `modified_by` number: The id of the user who last modified or undeleted this entity or mapping value - or zero if modified by the system
  - `deleted_at` string, date-time: The soft-deletion time for this entity or mapping value
  - `deleted_by` number: The id of the user who deleted this entity or mapping value - or zero if deleted by the system
  - `_etag` string, required: A tag for detecting conflicting modifications - current value (may be empty) must be passed along in an update (or update must be forced)
  - `project_id` integer: The project id this entity or mapping belongs to
  - `owner_user_id` integer: The global user id of the test case owner
  - `$owner_name` string: The resolved display name of the owner user - read only
  - `type` string: Reserved for future use
  - `template` string: The template type used for the test case: STEPS, TEXT or BDD
  - `precondition_text` string: A description of the precondition required for the test case (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `content_text` string: The test case content - used with template STEPS (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `steps_text` string: The test case content - used with template TEXT (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `expected_result_text` string: The test case expected result - used with template TEXT (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `bdd_scenarios_text` string: The gherkin scenarios used with template BDD (can be a rich text document, i.e. markdown with header line `<!--markdown-->` or Testiny JSON format)
  - `priority` number: The test case priority (This is a builtin-custom field)
  - `status` string: The test case status (This is a builtin-custom field)
  - `testcase_type` string: The test case type (This is a builtin-custom field)
  - `automation` string: The test case automation status (This is a builtin-custom field)
  - `estimate` number: A test case time estimate (This is a builtin-custom field)

## Other responses

- `4XX`: The request failed because invalid request parameters or data were supplied or access was denied.
- `5XX`: The request failed because an error occurred during processing of the request.

---

[API](https://skmtc.dev/testiny/apis/testiny-api.md) - [All operations](https://skmtc.dev/testiny/apis/testiny-api/llms.txt) - [OpenAPI document](https://skmtc.dev/testiny/apis/testiny-api/revisions/8f7643b2429d?raw)
