---
title: "Update publish settings"
method: PATCH
path: "/v1/projects/{project_id}/publish"
tags: ["deploy-domains"]
---

# Update publish settings

`PATCH /v1/projects/{project_id}/publish`

**Plan:** `All plans`

Updates the published app without redeploying. visibility controls who can view it: public (anyone with the link), workspace (workspace members only), or custom (only the groups/users in audience — the list replaces all existing group/user grants; grants managed in the UI such as org access and email invites are preserved). is_published false takes the app offline; settings are kept and apply again on the next publish (already-offline is a no-op). Changes take effect immediately.

## Path parameters

- `project_id` string, required — Project ID

## Request body

- PublicV1UpdatePublishSettingsInputBody
  - `audience` PublicV1PublishAudienceTarget[], nullable — Complete set of group/user grants for visibility 'custom': replaces existing group and user grants, an empty list removes them all, omit to keep the current audience. Grants managed in the UI (org access, email invites) are preserved. Only valid with visibility 'custom'.
    - `id` string, required — Group ID or workspace member user ID
    - `type` 'group' | 'user', required — Audience target type
  - `is_published` boolean — Set to false to take the published app offline; visibility and audience settings are kept and apply again on the next publish. true is rejected: publishing requires a deploy via POST /v1/projects/{project_id}/publish.
  - `visibility` 'public' | 'workspace' | 'custom' — Who can view the published app: public (anyone with the link), workspace (workspace members only), or custom (only the groups/users in audience). Omit to leave visibility unchanged. Clients must tolerate new values.

## Response `200`

OK

- PublicV1UpdatePublishSettingsResponse
  - `is_published` boolean, required — Whether the project is currently published
  - `url` string — Published project URL
  - `visibility` string, required — Resolved visibility of the published app

## Other responses

- `401` — Missing or invalid API key.
- `402` — This operation or requested configuration requires a workspace plan that includes this feature.
- `403` — The key or caller lacks the required scope or permission.
- `406` — The Accept header excludes every media type this endpoint produces.
- `429` — Too many requests. Retry after the interval in Retry-After when present.
- `default` — Error. The response body uses the standard error envelope; status matches the HTTP status code and type is a machine-readable error code.

---

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