---
title: "Delete tests"
method: POST
path: "/api/v1/synthetics/tests/delete"
tags: ["Synthetics"]
---

# Delete tests

`POST /api/v1/synthetics/tests/delete`

## Request

- Base URL: `https://api.datadoghq.com`
- URL: `https://api.datadoghq.com/api/v1/synthetics/tests/delete`
- Auth: one of:
  - API key in header `DD-API-KEY` and API key in header `DD-APPLICATION-KEY`
  - OAuth 2
    - Authorization code: `/oauth2/v1/authorize`
    - Token URL: `/oauth2/v1/token` scopes: `synthetics_write`

Delete multiple Synthetic tests by ID.

## Request body

- SyntheticsDeleteTestsPayload: A JSON list of the ID or IDs of the Synthetic tests that you want to delete.
  - `force_delete_dependencies` boolean: Delete the Synthetic test even if it's referenced by other resources (for example, SLOs and composite monitors).
  - `public_ids` string[]: An array of Synthetic test IDs you want to delete.

## Response `200`

OK.

- SyntheticsDeleteTestsResponse: Response object for deleting Synthetic tests.
  - `deleted_tests` SyntheticsDeletedTest[]: Array of objects containing a deleted Synthetic test ID with the associated deletion timestamp.
    - `deleted_at` string, date-time: Deletion timestamp of the Synthetic test ID.
    - `public_id` string: The Synthetic test ID deleted.

## Other responses

- `400`: - JSON format is wrong - Test cannot be deleted as it's used elsewhere (as a sub-test or in an uptime widget) - Some IDs are not owned by the user
- `403`: Forbidden
- `404`: - Tests to be deleted can't be found - Synthetic is not activated for the user
- `429`: Too many requests

---

[API](https://skmtc.dev/datadog/apis/datadog-api-v1-collection.md) - [All operations](https://skmtc.dev/datadog/apis/datadog-api-v1-collection/llms.txt) - [OpenAPI document](https://skmtc.dev/datadog/apis/datadog-api-v1-collection/revisions/ca5871004d26?raw)
