Skip to main content
PATCH
cURL

Authorizations

Lovable-API-Key
string
header
required

Lovable API key. Send its value in the Lovable-API-Key header.

Headers

Lovable-Version
string

Stable API version to serve, as a YYYY-MM-DD date. Omit for the oldest supported stable version, currently 2026-09-11.

Lovable-Beta
string

Comma-separated beta revision strings to enable on top of the stable version.

Path Parameters

project_id
string
required

Project ID.

Body

application/json

Provide audience, audience_targets, or both. An empty object leaves settings unchanged.

audience
enum<string>

Who can open the published app; project reads report this value as publish_audience. A custom audience can include existing grants managed in the UI. Omit to leave the audience unchanged, including while the app is unpublished.

Available options:
public,
workspace,
custom
audience_targets
object[]

Groups who can open the app; allowed only when the supplied or current audience is custom. Providing a list replaces all group and user grants and removes workspace-wide access; an empty list removes those grants. Existing organization access and email invitations managed in the UI are preserved. Omit to preserve saved targets across audience changes. Targets are inactive outside custom mode. Null is not accepted.

Maximum array length: 100

Response

OK

audience
enum<string>
required

Who can open the published app; project reads report this value as publish_audience. More values may be added; clients must tolerate unknown values.

Available options:
public,
workspace,
custom
audience_targets
object[]
required

Saved groups and users, including while the app is offline or the audience is not custom. These targets grant access only in custom mode. Users granted through invitations or organization membership are included; organization-wide access and pending email invitations are not listed. This read projection is not a writable target list; only groups can be supplied in audience_targets.