Files
Ethan Palm 2c1ead24af Restricting preview deployment auth gating (#7181)
* Clarify plan gating for preview deployment authentication

Preview deployments and preview deployment authentication are separate
entitlements, but the docs presented them as one Pro-or-Enterprise
requirement. Pro customers see the previews add-on enabled and then hit
a locked Preview authentication toggle with no explanation.

- Separate the two requirements in a callout under "Restrict access to
  preview deployments" and note that password-protected previews use the
  same entitlement.
- Document that preview authentication turns on automatically and locks
  when site-wide authentication is enabled.
- Note that the Trigger preview deployment endpoint accepts no password.
- Correct the Add-ons dashboard URL to /settings/deployment/addons.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* copy edit

* Correct the dashboard path to preview deployments

Previews are a tab on the Activity page, not a top-level dashboard item.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Update preview-deployments.mdx

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-28 16:23:20 -07:00

28 lines
1.6 KiB
Plaintext

---
title: "Trigger preview deployment"
openapi: "/openapi.json POST /project/preview/{projectId}"
keywords: ["preview", "preview deployment", "branch preview", "staging"]
---
Use this endpoint to programmatically create or update a preview deployment for a Git branch. If a preview already exists for the specified branch, the endpoint triggers a redeployment instead of creating a duplicate.
The response includes a `statusId` that you can pass to [Get deployment status](/api/update/status) to track the deployment progress.
## Branch requirements
The `branch` must exist in the repository connected to your Mintlify project and you must have the Mintlify GitHub App installed. Branches on forks are not supported. See [Fork pull requests](/deploy/preview-deployments#fork-pull-requests) for how to preview changes from a fork.
## Use cases
- **CI/CD pipelines**: Automatically create preview deployments when users open or update pull requests.
- **Scheduled previews**: Build previews from long-running feature branches on a schedule.
- **Custom tooling**: Integrate preview creation into internal workflows or Slack bots.
## Access to previews
Previews created with this endpoint are publicly accessible unless you enable authentication for your previews, which applies to every preview in your deployment. You cannot password-protect an individual preview through this endpoint. See [Restrict access to preview deployments](/deploy/preview-deployments#restrict-access-to-preview-deployments).
## Rate limits
This endpoint allows up to 5 requests per minute per organization.