---
title: "Discard preview"
method: POST
path: "/apps/{appRef}/deploys/{deployId}/discard"
tags: ["Deploys"]
---

# Discard preview

`POST /apps/{appRef}/deploys/{deployId}/discard`

## Request

- Base URL: `https://api.percher.run`
- URL: `https://api.percher.run/apps/{appRef}/deploys/{deployId}/discard`
- Auth: HTTP bearer

## Path parameters

- `appRef` string, required
- `deployId` string, required

## Response `204`

Preview discarded

## Other responses

- `409`: The preview changed while discarding - it was promoted or removed; nothing was torn down (PREVIEW_PROMOTED)

---

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