---
title: "Bulk delete environments"
method: POST
path: "/projects/{project_id}/environments/bulk_delete"
tags: ["Environments"]
---

# Bulk delete environments

`POST /projects/{project_id}/environments/bulk_delete`

## Request

- Base URL: `https://app.honeybadger.io/v3`
- URL: `https://app.honeybadger.io/v3/projects/{project_id}/environments/bulk_delete`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/honeybadger/apis/honeybadger-api/docs/projects/:project_id/environments/bulk_delete/post.ts> (a function with typed inputs; its response is checked against the schema)

Deletes several environments at once. An empty `environment_ids` deletes nothing. If any ID isn't one of the project's environments, nothing is deleted.

## Path parameters

- `project_id` string, required

## Request body

- object
  - `environment_ids` string[], required: IDs of environments to delete

## Response `200`

Success

- object
  - `data` object, required
    - `count` integer, required: Number of environments deleted
  - `meta` ResponseMeta
    - `request_id` string: Unique identifier for the request, for correlating with support

## Other responses

- `401`: The credential is missing, invalid, expired or revoked (`unauthorized`), or was sent in a way v3 doesn't accept (see the examples).
- `403`: The credential isn't allowed to do this. `error.code` says why. An account or project the credential doesn't cover is 404 `not_found`, not 403.
- `404`: Resource not found
- `422`: Validation error

---

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