Restore a deleted project
const url = 'https://example.com/v1/projects/example/restore';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/projects/example/restore \ --header 'Authorization: Bearer <token>'Brings a deleted project back as it was: its members, team grants, keys, own service account and slugs, and its triggers’ next fires run. Fires and deliveries that came due while it was deleted were skipped, and runs cancelled at the delete stay cancelled. Its updatedAt moves to the restore. A live project answers 200, unchanged. A deleted project doesn’t count against the workspace’s limit on projects in production, so restoring one that’s in production counts it again: at the limit, the restore is refused (403 production-limit-reached) and the project stays deleted. Needs admin on the workspace: roles on a deleted project reach nothing, its own admins’ included. Restoring a deleted project is recorded in the audit log, project-restored.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Header Parameters
Section titled “Header Parameters”Responses
Section titled “Responses”The project, live again.
object
Examplegenerated
{ "id": "example", "tenantId": "example", "orgId": "example", "name": "example", "slug": "example", "isDefault": true, "description": "example", "productionSince": "2026-04-15T12:00:00Z", "formerSlugs": [ "example" ], "sortEndUserCorrections": true, "everyoneCanRun": true, "repoConnectionId": "example", "createdAt": "example", "updatedAt": "example"}Missing / malformed / expired / revoked bearer token.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}No admin on the workspace (permission-denied); or the project is in production and the workspace’s projects in production are at its limit (production-limit-reached, details.limit projects-in-production, details.projectsInProduction the limit, details.inProduction the count, details.projectId): it stays deleted until one is taken out of production. Without an authorization store, key-project-mismatch (details.keyProjectId): the API key or session is limited to a project, and this writes above it, to the workspace, an org or a team (with a store, that is permission-denied).
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}project-not-found: no project, live or deleted, with that id under this workspace.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}idempotency-key-in-flight (with Retry-After): a request with the same Idempotency-Key still runs, so this one wasn’t run; send it again after Retry-After to get that request’s answer.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”rate-limit-exceeded with details.limit: "api-requests", on a runtime that sets workspace limits (Kindgi Cloud): this workspace’s limit on API requests a minute is reached, so the request wasn’t run; Retry-After says when to send it again.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”project-restore-unsupported: this runtime’s project binding can’t restore a deleted project.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}The Idempotency-Key store (idempotency-store-unavailable) or the authorization store (authz-backend-unavailable) couldn’t be reached before the request ran, or the database was too busy for its authorization check (database-busy), so nothing was changed; Retry-After (whole seconds) says when to try again with the same key. Or tenant-state-unavailable (with Retry-After), on a runtime serving many workspaces: the workspace’s state couldn’t be read, so nothing was changed.
object
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Headers
Section titled “Headers”See also
GET /v1/projects/{projectId}: Fetch a project by idPATCH /v1/projects/{projectId}: Partially update a projectDELETE /v1/projects/{projectId}: Delete a project (idempotent)GET /v1/projects/{projectId}/queue-rules: List a project's queue rules- Organize work by org and project
- Kindgi 0.7.0
- Error code
authz-backend-unavailable - Error code
database-busy - Error code
idempotency-key-in-flight - Error code
idempotency-store-unavailable - Error code
key-project-mismatch - Error code
permission-denied - Error code
production-limit-reached - Error code
project-not-found - Error code
project-restore-unsupported - Error code
rate-limit-exceeded - Error code
tenant-state-unavailable - Every error code