Deploy a Website
Deploy a website. Files is a map of file paths to file contents. Configuration is optional and contains additional information about the deployment.
/web/v1/deployment
Request Body
application/json
Requiredsource
Requiredobject | object | objectThe files to deploy, a map of file paths to file contents, e.g. { "index.js": {"content": "your main", "encoding": "utf-8"}, "file2.js": {"content": "your helper" } }
Do not include node modules in this bundle, they will not work. Instead, includes a package-lock.json, bun.lockb, pnpm-lock.yaml, or yarn.lock, the node modules for the project will be installed from that lock file, or use the node_modules field in the configuration to specify the node modules to install.
config
objectResponse Body
200
successfully deployed
deploymentId
Requiredstring"uuid"
projectId
RequiredDeprecatedstring"uuid"
domains
array | nullentrypoint
RequiredstringThe entrypoint file for the website. If not specified we try to automatically detect it.
400
failed to deploy
message
Requiredstringsuccessfully deployed