Sites

Deploy a Site

Deploy a Site package, the deploy-request.json pnpm run pack writes, into the Cloud project. It creates the Site the first time its slug is deployed, provisions its data collections, deploys any Function it mounts and, unless promote is false, makes it the production release. Needs sites:write. The body is at most 80 MiB; a larger one gets 413, and an invalid package gets 400 naming every problem.

post/v1/sites/deployments

Request

  • Base URL
    https://api.dexto.ai
  • URL
    https://api.dexto.ai/v1/sites/deployments
  • Auth
    HTTP bearer

Query parameters

promote'true' | 'false'

false leaves a preview deployment to promote later.

provider'aws-lambda' | 'cloudflare-workers' | 'local'

Where the Site's Function should run. Omit to use host policy; an unavailable choice is refused.

Request body

schemaVersion1 required
slugstring required
titlestring required
visibility'private' | 'unlisted' | 'public'
entrypointstring
spaFallbackboolean

Response

Created.

created_siteboolean required

Whether this deploy created the Site.

first_deploymentboolean required

Whether this is the Site's first deployment.

object'site.deploy' required
promotedboolean required
urlstring uri required

The production URL when promoted; otherwise the deployment's preview URL.

Changes

No recorded changes to this operation across all 1 revision of this API.