---
title: "Start Node.js build"
method: POST
path: "/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds"
tags: ["Hosting: NodeJS"]
---

# Start Node.js build

`POST /api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds`

Start a Node.js build process using files already present on the website's file storage.

WARNING: on success this overwrites the website's existing contents and cannot be
undone — verify this is intended before calling this endpoint.

The `source_type` must be `archive` and `source_options.archive_path` must point to an
existing archive file on the server (relative to the website document root).
Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.

To auto-detect build settings from an archive before starting, first call the
`Get Node.js Build Settings from Archive` endpoint.

The returned build `uuid` can be used to poll progress and retrieve logs via
the `Get Node.js Build Logs` endpoint.

## Path parameters

- `username` string, required
- `domain` string, required

## Request body

- HostingV1NodeJsStartBuildRequest
  - `node_version` 18 | 20 | 22 | 24, required — Node.js version
  - `app_type` 'create-react-app' | 'gatsby' | 'vite' | 'angular' | 'react' | 'vue' | 'parcel' | 'next' | 'nuxt' | 'nest' | 'express' | 'fastify' | 'astro' | 'svelte' | 'svelte-kit' | 'hono' | 'react-router' | 'nitro' | 'other', nullable, required — Node.js application type
  - `root_directory` string, nullable, required — Application root directory (where package.json is located) relative to public_html
  - `output_directory` string, nullable, required — Build output directory relative to the root directory
  - `build_script` string, nullable, required — Build script that will be ran to build the application
  - `entry_file` string, nullable — The main entry point file for the application
  - `package_manager` 'npm' | 'yarn' | 'pnpm', nullable — Package manager
  - `source_type` 'archive', required — The source type of the files
  - `source_options` object, nullable, required — Source-specific options
    - `archive_path` string — The path to the archive file relative to the document root of the vhost (required if source is "archive")

## Response `200`

Success response

- HostingV1NodeJsBuildResource
  - `uuid` string — Build UUID
  - `state` 'pending' | 'running' | 'completed' | 'failed' — Build state
  - `options` HostingV1NodeJsBuildOptionsResource
    - `node_version` integer, required — Node.js version
    - `app_type` 'create-react-app' | 'gatsby' | 'vite' | 'angular' | 'react' | 'vue' | 'parcel' | 'next' | 'nuxt' | 'nest' | 'express' | 'fastify' | 'astro' | 'svelte' | 'svelte-kit' | 'hono' | 'react-router' | 'nitro' | 'other', nullable, required — Node.js application type
    - `root_directory` string, nullable, required — Application root directory
    - `output_directory` string, nullable, required — Build output directory
    - `build_script` string, nullable, required — The npm script to run to build the application
    - `entry_file` string, nullable, required — The main entry point file for the application
    - `package_manager` 'npm' | 'yarn' | 'pnpm', nullable, required — Package manager
    - `source_type` 'archive', nullable, required — Source type for the build
    - `source_options` HostingV1NodeJsSourceOptionsResource, required
      - `archive_path` string, nullable — Present if sourceType is "archive"
  - `created_at` string, date-time — Creation timestamp
  - `updated_at` string, date-time — Last update timestamp

## Other responses

- `401` — Unauthenticated response
- `422` — Validation error response
- `500` — Error response

## Changes

- **2026-08-19** `2d2a2dc172ed` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/hostinger/apis/hostinger-api/changes/api/hosting/v1/accounts/:username/websites/:domain/nodejs/builds/post.md)

---

[API](https://skmtc.dev/hostinger/apis/hostinger-api.md) · [All operations](https://skmtc.dev/hostinger/apis/hostinger-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/hostinger/hostinger-api/revisions/53ccee45e5eb/schema)
