/v1/workspaces/{workspace_id}/projects/{project_id}AuthDelete a project
Deletes the project with all of its environments, configs, flags, segments, SDK keys and history. Pass `confirm` with the exact project name. SDKs using its keys stop receiving updates. Needs `flags.project.manage`; recorded in the workspace audit log.
Path parameters
project_id*string · uuidId of the project.
workspace_id*string · uuidId of the workspace.
Query parameters
notestringA change note (at most 500 characters), saved on the history entry. Environments with `require_note` refuse value writes without one.
confirm*stringThe project's exact name, to confirm the delete. Deleting a project deletes its environments, configs, flags, segments, SDK keys and history.
Response · 204
Deleted.
Example
Request
DELETE https://api.flags.productcraft.co/v1/workspaces/{workspace_id}/projects/{project_id}
Authorization: Bearer YOUR_TOKENimport { Flags } from "@productcraft/flags";
// Reads PRODUCTCRAFT_API_KEY from the environment
const flags = new Flags();
await flags.projects.delete("3f0c3c1e-8a2b-4c55-9d3f-0a1b2c3d4e5f", { confirm: "Storefront" });flags.projects.delete(projectId, params, options?): void