---
title: "DELETE /api/v1/dynamic-secrets/leases/{leaseId}"
method: DELETE
path: "/api/v1/dynamic-secrets/leases/{leaseId}"
tags: ["Dynamic Secrets"]
---

# DELETE /api/v1/dynamic-secrets/leases/{leaseId}

`DELETE /api/v1/dynamic-secrets/leases/{leaseId}`

## Path parameters

- `leaseId` string, required

## Request body

- object
  - `projectSlug` string, required — The slug of the project of the dynamic secret in.
  - `path` string — The path of the dynamic secret in.
  - `environmentSlug` string, required — The slug of the environment of the dynamic secret in.
  - `isForced` boolean — A boolean flag to delete the the dynamic secret from Infisical without trying to remove it from external provider. Used when the dynamic secret got modified externally.

## Response `200`

Default Response

- object
  - `lease` object, required
    - `id` string, uuid, required
    - `version` number, required
    - `externalEntityId` string, required
    - `expireAt` string, date-time, required
    - `status` string, nullable
    - `statusDetails` string, nullable
    - `dynamicSecretId` string, uuid, required
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required
    - `config` unknown

## Other responses

- `400` — Default Response
- `401` — Default Response
- `403` — Default Response
- `404` — Default Response
- `422` — Default Response
- `500` — Default Response

---

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