Skip to content
Mintlify
Admin

Trigger preview deployment

POST/project/preview/{projectId}

Create or update a preview deployment for a specific branch. If a preview already exists for the branch, it triggers a redeployment. Returns a status ID to track progress and the preview URL.

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 to track the deployment progress.

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.

Rate limits

This endpoint allows up to 5 requests per minute per organization.

Ctrl+I