---
title: "Delete environment"
method: DELETE
path: "/api/v1/app/{appId}/env/{envId}"
tags: ["Applications"]
---

# Delete environment

`DELETE /api/v1/app/{appId}/env/{envId}`

## Delete Environment
Removes this Environment from the StackHawk application.

> ⚠️ Danger
> HawkScan scan results are grouped by application & environment. Deleting an environment **also deletes all scan results collected for that environment**.
> StackHawk will delete scan results on demand. This action is permanent and cannot be undone.

> 🧾 Audited
> This is recorded as `ENVIRONMENT_REMOVED` [User Activity](https://apidocs.stackhawk.com/reference/listauditactivity#user-activity-types).


> Requires `delete:application` permission.

## Path parameters

- `appId` string, uuid, required
- `envId` string, uuid, required

## Response `200`

OK

## Other responses

- `400` — Bad Request
- `401` — Unauthorized

---

[API](https://skmtc.net/stackhawk/apis/stackhawk-public-api.md) · [All operations](https://skmtc.net/stackhawk/apis/stackhawk-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/stackhawk/stackhawk-public-api/revisions/ad3dfd54cb63/schema)
