---
title: "Redeploy an app"
method: POST
path: "/api/v1/apps/{appId}/redeploy"
tags: ["Apps"]
---

# Redeploy an app

`POST /api/v1/apps/{appId}/redeploy`

## Request

- Base URL: `https://app.khotan.com`
- URL: `https://app.khotan.com/api/v1/apps/{appId}/redeploy`
- Auth: one of:
  - HTTP bearer
  - API key in header `x-api-key`

Triggers a fresh production deployment from the tip of the app's linked branch and responds 202 with the new deployment's initial status (queued or building). Poll the app detail endpoint to observe the deployment reaching ready or failed. The new build picks up the currently-applied environment variables.

## Path parameters

- `appId` string, required

## Response `202`

The new deployment's initial status.

- object
  - `status` 'queued' | 'building' | 'ready' | 'failed' | 'canceled', required

## Other responses

- `401`: Authentication is missing or invalid.
- `404`: The resource was not found.
- `409`: Response.
- `429`: Too many requests; retry after the indicated delay.
- `502`: Response.

---

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