curl --request POST \
--url 'https://api.lovable.dev/v1/projects/project-id/publish' \
--header 'Lovable-API-Key: lov_your-api-key' \
--header 'Lovable-Version: 2026-09-11' \
--header 'Content-Type: application/json' \
--data '{}'{
"error_class": "transient",
"error_message": "<string>",
"id": "<string>",
"status": "running",
"url": "<string>"
}{
"detail": "validation failed",
"errors": [
{
"location": "body.members",
"message": "expected array length >= 1"
}
],
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 400,
"title": "Bad Request",
"type": "invalid_request"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 401,
"title": "Authorization header required",
"type": "unauthorized"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 402,
"title": "You need to upgrade your plan to access this feature",
"type": "payment_required"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 403,
"title": "You don't have the permissions to perform this action",
"type": "forbidden"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 404,
"title": "Not Found",
"type": "project_not_found"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 406,
"title": "This endpoint produces application/json. Send a matching Accept header, */*, or omit the header.",
"type": "not_acceptable"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 429,
"title": "Too Many Requests",
"type": "rate_limited"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 503,
"title": "Request timed out",
"type": "request_timeout"
}{
"detail": "validation failed",
"errors": [
{
"location": "body.workspace_id",
"message": "expected string"
}
],
"props": {
"finding_refs": [
"supabase/finding-1"
]
},
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 429,
"title": "Too Many Requests",
"type": "rate_limited"
}Publish project
Plan: Business or higher
Scope: projects:write
Builds and deploys the project. Returns 202 with the Deployment representation, status running, and null url and error fields; poll GET /v1/projects//publish/ until deployment finishes. Optionally set audience to choose who can open the published app; project reads report it as publish_audience. Omit audience to keep the current setting. Audience changes apply to the currently published version immediately, before the new deployment finishes. To change access settings without rebuilding, use PATCH /v1/projects//publish. To take the app offline, use DELETE /v1/projects//publish.
curl --request POST \
--url 'https://api.lovable.dev/v1/projects/project-id/publish' \
--header 'Lovable-API-Key: lov_your-api-key' \
--header 'Lovable-Version: 2026-09-11' \
--header 'Content-Type: application/json' \
--data '{}'{
"error_class": "transient",
"error_message": "<string>",
"id": "<string>",
"status": "running",
"url": "<string>"
}{
"detail": "validation failed",
"errors": [
{
"location": "body.members",
"message": "expected array length >= 1"
}
],
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 400,
"title": "Bad Request",
"type": "invalid_request"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 401,
"title": "Authorization header required",
"type": "unauthorized"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 402,
"title": "You need to upgrade your plan to access this feature",
"type": "payment_required"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 403,
"title": "You don't have the permissions to perform this action",
"type": "forbidden"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 404,
"title": "Not Found",
"type": "project_not_found"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 406,
"title": "This endpoint produces application/json. Send a matching Accept header, */*, or omit the header.",
"type": "not_acceptable"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 429,
"title": "Too Many Requests",
"type": "rate_limited"
}{
"detail": null,
"errors": null,
"props": null,
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 503,
"title": "Request timed out",
"type": "request_timeout"
}{
"detail": "validation failed",
"errors": [
{
"location": "body.workspace_id",
"message": "expected string"
}
],
"props": {
"finding_refs": [
"supabase/finding-1"
]
},
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"status": 429,
"title": "Too Many Requests",
"type": "rate_limited"
}Authorizations
Lovable API key. Send its value in the Lovable-API-Key header.
Headers
Stable API version to serve, as a YYYY-MM-DD date. Omit for the oldest supported stable version, currently 2026-09-11.
Comma-separated beta revision strings to enable on top of the stable version.
Path Parameters
Project ID.
Body
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 keep the current setting.
public, workspace, custom Groups who can open the app; allowed only with audience 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.
100Show child attributes
Show child attributes
Slug for the managed published URL: acme-landing-page gives https://acme-landing-page.lovable.app. Custom domains and workspace branding can change the hostname.
"acme-landing-page"
Response
Deployment started. Poll GET /v1/projects/{project_id}/publish/{deployment_id} (the Location header) with the returned id until deployment finishes.
Where to address the failure; see the operation description for the action for each class. Null when no failure category is available. More values may be added; for unknown values, show error_message and contact support instead of automatically retrying.
transient, code, configuration, data, integration, policy, internal, null Human-readable reason for a deployment failure; null unless the deployment failed.
Deployment ID.
Deployment progress. running means the deployment was accepted and has not reported completion. completed means the deployment succeeded and url is set. unknown means the deployment exists but its workflow state has no recognized public mapping; it confirms neither success nor failure. Poll again with backoff and a bounded timeout, then report an indeterminate result if it persists. Unknown or mismatched deployment IDs return HTTP 404. Clients must tolerate new values.
running, completed, error, unknown URL produced by this successful deployment; null until this deployment succeeds, even when an older version is published.
Was this page helpful?