@hostinger/sdk 1.48.0 → 1.49.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/api.js CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.48.0
6
+ * API Version: 1.49.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -422,6 +422,64 @@ export const HostingV1NodeJsStartBuildRequestPackageManagerEnum = {
422
422
  export const HostingV1NodeJsStartBuildRequestSourceTypeEnum = {
423
423
  Archive: 'archive'
424
424
  };
425
+ export const HostingV1NodeJsStoredBuildSettingsResourceAppTypeEnum = {
426
+ CreateReactApp: 'create-react-app',
427
+ Gatsby: 'gatsby',
428
+ Vite: 'vite',
429
+ Angular: 'angular',
430
+ React: 'react',
431
+ Vue: 'vue',
432
+ Parcel: 'parcel',
433
+ Next: 'next',
434
+ Nuxt: 'nuxt',
435
+ Nest: 'nest',
436
+ Express: 'express',
437
+ Fastify: 'fastify',
438
+ Astro: 'astro',
439
+ Svelte: 'svelte',
440
+ SvelteKit: 'svelte-kit',
441
+ Hono: 'hono',
442
+ ReactRouter: 'react-router',
443
+ Nitro: 'nitro',
444
+ Other: 'other'
445
+ };
446
+ export const HostingV1NodeJsStoredBuildSettingsResourcePackageManagerEnum = {
447
+ Npm: 'npm',
448
+ Yarn: 'yarn',
449
+ Pnpm: 'pnpm'
450
+ };
451
+ export const HostingV1NodeJsUpdateBuildSettingsRequestNodeVersionEnum = {
452
+ NUMBER_18: 18,
453
+ NUMBER_20: 20,
454
+ NUMBER_22: 22,
455
+ NUMBER_24: 24
456
+ };
457
+ export const HostingV1NodeJsUpdateBuildSettingsRequestAppTypeEnum = {
458
+ CreateReactApp: 'create-react-app',
459
+ Gatsby: 'gatsby',
460
+ Vite: 'vite',
461
+ Angular: 'angular',
462
+ React: 'react',
463
+ Vue: 'vue',
464
+ Parcel: 'parcel',
465
+ Next: 'next',
466
+ Nuxt: 'nuxt',
467
+ Nest: 'nest',
468
+ Express: 'express',
469
+ Fastify: 'fastify',
470
+ Astro: 'astro',
471
+ Svelte: 'svelte',
472
+ SvelteKit: 'svelte-kit',
473
+ Hono: 'hono',
474
+ ReactRouter: 'react-router',
475
+ Nitro: 'nitro',
476
+ Other: 'other'
477
+ };
478
+ export const HostingV1NodeJsUpdateBuildSettingsRequestPackageManagerEnum = {
479
+ Npm: 'npm',
480
+ Yarn: 'yarn',
481
+ Pnpm: 'pnpm'
482
+ };
425
483
  export const HostingV1NodeJsVulnerabilityResourceSeverityEnum = {
426
484
  Low: 'low',
427
485
  Moderate: 'moderate',
@@ -13870,6 +13928,82 @@ export const ListWebsiteFilesAndDirectoriesV1FileTypesEnum = {
13870
13928
  */
13871
13929
  export const HostingNodeJSApiAxiosParamCreator = function (configuration) {
13872
13930
  return {
13931
+ /**
13932
+ * Returns an AI analysis of why a build failed and how to fix it, based on the build logs, the project file list and package.json. Only builds in the `failed` state can be analysed; any other state returns 422. When no analysis could be produced both `analysis` and `solution` are null, in which case read `Get NodeJS build logs` instead. Each call runs the analysis again, so call it once per failed build and keep the result. Limited to 5 calls per minute per API client (429 above that).
13933
+ * @summary Analyse failed Node.js build
13934
+ * @param {string} username
13935
+ * @param {string} domain Domain name
13936
+ * @param {string} uuid Build UUID
13937
+ * @param {*} [options] Override http request option.
13938
+ * @throws {RequiredError}
13939
+ */
13940
+ analyseFailedNodeJsBuildV1: (username_1, domain_1, uuid_1, ...args_1) => __awaiter(this, [username_1, domain_1, uuid_1, ...args_1], void 0, function* (username, domain, uuid, options = {}) {
13941
+ // verify required parameter 'username' is not null or undefined
13942
+ assertParamExists('analyseFailedNodeJsBuildV1', 'username', username);
13943
+ // verify required parameter 'domain' is not null or undefined
13944
+ assertParamExists('analyseFailedNodeJsBuildV1', 'domain', domain);
13945
+ // verify required parameter 'uuid' is not null or undefined
13946
+ assertParamExists('analyseFailedNodeJsBuildV1', 'uuid', uuid);
13947
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/{uuid}/analysis`
13948
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
13949
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)))
13950
+ .replace(`{${"uuid"}}`, encodeURIComponent(String(uuid)));
13951
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13952
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13953
+ let baseOptions;
13954
+ if (configuration) {
13955
+ baseOptions = configuration.baseOptions;
13956
+ }
13957
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
13958
+ const localVarHeaderParameter = {};
13959
+ const localVarQueryParameter = {};
13960
+ // authentication apiToken required
13961
+ // http bearer authentication required
13962
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13963
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13964
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13965
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13966
+ return {
13967
+ url: toPathString(localVarUrlObj),
13968
+ options: localVarRequestOptions,
13969
+ };
13970
+ }),
13971
+ /**
13972
+ * Empties the Node.js application\'s runtime log file. This cannot be undone, so confirm with the user before calling it. Returns success even when no log file exists yet. Use it before reproducing a problem so the next `Get Node.js runtime logs` call returns only fresh entries; start that call with `period` again instead of reusing a `from_line` from before the clear.
13973
+ * @summary Clear Node.js runtime logs
13974
+ * @param {string} username
13975
+ * @param {string} domain Domain name
13976
+ * @param {*} [options] Override http request option.
13977
+ * @throws {RequiredError}
13978
+ */
13979
+ clearNodeJsRuntimeLogsV1: (username_1, domain_1, ...args_1) => __awaiter(this, [username_1, domain_1, ...args_1], void 0, function* (username, domain, options = {}) {
13980
+ // verify required parameter 'username' is not null or undefined
13981
+ assertParamExists('clearNodeJsRuntimeLogsV1', 'username', username);
13982
+ // verify required parameter 'domain' is not null or undefined
13983
+ assertParamExists('clearNodeJsRuntimeLogsV1', 'domain', domain);
13984
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/runtime-logs`
13985
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
13986
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
13987
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13988
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13989
+ let baseOptions;
13990
+ if (configuration) {
13991
+ baseOptions = configuration.baseOptions;
13992
+ }
13993
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
13994
+ const localVarHeaderParameter = {};
13995
+ const localVarQueryParameter = {};
13996
+ // authentication apiToken required
13997
+ // http bearer authentication required
13998
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13999
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
14000
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
14001
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
14002
+ return {
14003
+ url: toPathString(localVarUrlObj),
14004
+ options: localVarRequestOptions,
14005
+ };
14006
+ }),
13873
14007
  /**
13874
14008
  * Retrieve logs from a specific Node.js build process. To stream live output while a build is running, poll this endpoint repeatedly while the build state is `running`, passing the previously returned `lines` count as `from_line` to fetch only new output since the last call. Log content may contain ANSI escape sequences (color codes).
13875
14009
  * @summary Get NodeJS build logs
@@ -13914,6 +14048,46 @@ export const HostingNodeJSApiAxiosParamCreator = function (configuration) {
13914
14048
  options: localVarRequestOptions,
13915
14049
  };
13916
14050
  }),
14051
+ /**
14052
+ * Returns one build by UUID: its state (`pending`, `running`, `completed`, `failed`), the options it ran with and timestamps. Poll this while a build is pending or running. When it is failed, read `Get NodeJS build logs` and `Analyse failed Node.js build` for the cause. Returns 404 when the UUID does not belong to a build of this website.
14053
+ * @summary Get Node.js build details
14054
+ * @param {string} username
14055
+ * @param {string} domain Domain name
14056
+ * @param {string} uuid Build UUID
14057
+ * @param {*} [options] Override http request option.
14058
+ * @throws {RequiredError}
14059
+ */
14060
+ getNodeJsBuildDetailsV1: (username_1, domain_1, uuid_1, ...args_1) => __awaiter(this, [username_1, domain_1, uuid_1, ...args_1], void 0, function* (username, domain, uuid, options = {}) {
14061
+ // verify required parameter 'username' is not null or undefined
14062
+ assertParamExists('getNodeJsBuildDetailsV1', 'username', username);
14063
+ // verify required parameter 'domain' is not null or undefined
14064
+ assertParamExists('getNodeJsBuildDetailsV1', 'domain', domain);
14065
+ // verify required parameter 'uuid' is not null or undefined
14066
+ assertParamExists('getNodeJsBuildDetailsV1', 'uuid', uuid);
14067
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/{uuid}`
14068
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
14069
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)))
14070
+ .replace(`{${"uuid"}}`, encodeURIComponent(String(uuid)));
14071
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
14072
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
14073
+ let baseOptions;
14074
+ if (configuration) {
14075
+ baseOptions = configuration.baseOptions;
14076
+ }
14077
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
14078
+ const localVarHeaderParameter = {};
14079
+ const localVarQueryParameter = {};
14080
+ // authentication apiToken required
14081
+ // http bearer authentication required
14082
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
14083
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
14084
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
14085
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
14086
+ return {
14087
+ url: toPathString(localVarUrlObj),
14088
+ options: localVarRequestOptions,
14089
+ };
14090
+ }),
13917
14091
  /**
13918
14092
  * Auto-detect Node.js build settings from a package.json inside an archive already on the server. Use this before calling `Start Node.js Build` to preview what settings will be used, or to let the user review and override values (framework, node version, root directory, output directory, build script) before committing to a build. The archive must already be present on the website\'s file storage. Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.
13919
14093
  * @summary Get Node.js build settings from archive
@@ -13956,6 +14130,94 @@ export const HostingNodeJSApiAxiosParamCreator = function (configuration) {
13956
14130
  options: localVarRequestOptions,
13957
14131
  };
13958
14132
  }),
14133
+ /**
14134
+ * Returns the build settings stored for the website: framework (`app_type`), Node.js version, root and output directory, build script, entry file and package manager. Stored settings drive Git auto-deployment builds. A build started through the API uses the values sent in that request and saves them here only when no settings exist yet. Returns 404 until the first build or the first settings update stores them. Use this after a failed build to check whether the framework or the entry file were detected wrong, then fix them with the `Update Node.js build settings` endpoint.
14135
+ * @summary Get Node.js build settings
14136
+ * @param {string} username
14137
+ * @param {string} domain Domain name
14138
+ * @param {*} [options] Override http request option.
14139
+ * @throws {RequiredError}
14140
+ */
14141
+ getNodeJsBuildSettingsV1: (username_1, domain_1, ...args_1) => __awaiter(this, [username_1, domain_1, ...args_1], void 0, function* (username, domain, options = {}) {
14142
+ // verify required parameter 'username' is not null or undefined
14143
+ assertParamExists('getNodeJsBuildSettingsV1', 'username', username);
14144
+ // verify required parameter 'domain' is not null or undefined
14145
+ assertParamExists('getNodeJsBuildSettingsV1', 'domain', domain);
14146
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/settings`
14147
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
14148
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
14149
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
14150
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
14151
+ let baseOptions;
14152
+ if (configuration) {
14153
+ baseOptions = configuration.baseOptions;
14154
+ }
14155
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
14156
+ const localVarHeaderParameter = {};
14157
+ const localVarQueryParameter = {};
14158
+ // authentication apiToken required
14159
+ // http bearer authentication required
14160
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
14161
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
14162
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
14163
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
14164
+ return {
14165
+ url: toPathString(localVarUrlObj),
14166
+ options: localVarRequestOptions,
14167
+ };
14168
+ }),
14169
+ /**
14170
+ * Returns the Node.js application\'s runtime console log entries, oldest first, each with timestamp, level and message. On the first call send `period` (`1h`, `1d`, `1w` or `1m`) and optionally `levels` and `limit` (1-5000, default 1000); when more entries match than `limit`, the newest are kept. To poll for new entries send `total_lines + 1` from the previous response as `from_line` and omit `period`; `period` and `from_line` cannot be combined. Lines that are not JSON with a timestamp, level and message are skipped, so `logs` may hold fewer than `limit` entries while `total_lines` counts every raw line. Entries with a timestamp before `last_deployed_at` belong to the previous deployment. Returns an empty `logs` list when the application has not written a log file yet.
14171
+ * @summary Get Node.js runtime logs
14172
+ * @param {string} username
14173
+ * @param {string} domain Domain name
14174
+ * @param {GetNodeJsRuntimeLogsV1PeriodEnum} [period] Time window for the first fetch. Required when `from_line` is not sent.
14175
+ * @param {number} [fromLine] 1-based line of the log file to start from. For polling send `total_lines + 1` from the previous response. Cannot be combined with `period`.
14176
+ * @param {number} [limit] Maximum number of log entries to return. When more entries match, the newest are kept.
14177
+ * @param {Array<GetNodeJsRuntimeLogsV1LevelsEnum>} [levels] Return only entries with these log levels, sent as a comma-separated list, e.g. ERROR,WARN. Matching runs on the raw log line, so entries written with numeric levels (for example by pino) are excluded while this filter is set.
14178
+ * @param {*} [options] Override http request option.
14179
+ * @throws {RequiredError}
14180
+ */
14181
+ getNodeJsRuntimeLogsV1: (username_1, domain_1, period_1, fromLine_1, limit_1, levels_1, ...args_1) => __awaiter(this, [username_1, domain_1, period_1, fromLine_1, limit_1, levels_1, ...args_1], void 0, function* (username, domain, period, fromLine, limit, levels, options = {}) {
14182
+ // verify required parameter 'username' is not null or undefined
14183
+ assertParamExists('getNodeJsRuntimeLogsV1', 'username', username);
14184
+ // verify required parameter 'domain' is not null or undefined
14185
+ assertParamExists('getNodeJsRuntimeLogsV1', 'domain', domain);
14186
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/runtime-logs`
14187
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
14188
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
14189
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
14190
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
14191
+ let baseOptions;
14192
+ if (configuration) {
14193
+ baseOptions = configuration.baseOptions;
14194
+ }
14195
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
14196
+ const localVarHeaderParameter = {};
14197
+ const localVarQueryParameter = {};
14198
+ // authentication apiToken required
14199
+ // http bearer authentication required
14200
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
14201
+ if (period !== undefined) {
14202
+ localVarQueryParameter['period'] = period;
14203
+ }
14204
+ if (fromLine !== undefined) {
14205
+ localVarQueryParameter['from_line'] = fromLine;
14206
+ }
14207
+ if (limit !== undefined) {
14208
+ localVarQueryParameter['limit'] = limit;
14209
+ }
14210
+ if (levels) {
14211
+ localVarQueryParameter['levels'] = levels.join(COLLECTION_FORMATS.csv);
14212
+ }
14213
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
14214
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
14215
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
14216
+ return {
14217
+ url: toPathString(localVarUrlObj),
14218
+ options: localVarRequestOptions,
14219
+ };
14220
+ }),
13959
14221
  /**
13960
14222
  * Retrieve a paginated list of Node.js build processes for a specific website. Each build represents a single run of the Node.js build pipeline. Use the `states` query parameter to filter results by build state (pending, running, completed, failed). Use the `uuid` from a build to poll its output via the `Get Node.js Build Logs` endpoint.
13961
14223
  * @summary List NodeJS builds
@@ -14239,6 +14501,47 @@ export const HostingNodeJSApiAxiosParamCreator = function (configuration) {
14239
14501
  options: localVarRequestOptions,
14240
14502
  };
14241
14503
  }),
14504
+ /**
14505
+ * Replaces the build settings stored for the website. Send the full set: `node_version` is required and every nullable field you omit is stored as null. Creates the settings when none exist yet. This does not start a build. Stored settings drive Git auto-deployment builds; a build started through the API uses the values sent in that request, so to rebuild with corrected settings call `Start Node.js build` with the same values. Typical fixes: a wrong `app_type` after auto-detection, or a missing `entry_file` for express, fastify, nest, nuxt and hono apps.
14506
+ * @summary Update Node.js build settings
14507
+ * @param {string} username
14508
+ * @param {string} domain Domain name
14509
+ * @param {HostingV1NodeJsUpdateBuildSettingsRequest} hostingV1NodeJsUpdateBuildSettingsRequest
14510
+ * @param {*} [options] Override http request option.
14511
+ * @throws {RequiredError}
14512
+ */
14513
+ updateNodeJsBuildSettingsV1: (username_1, domain_1, hostingV1NodeJsUpdateBuildSettingsRequest_1, ...args_1) => __awaiter(this, [username_1, domain_1, hostingV1NodeJsUpdateBuildSettingsRequest_1, ...args_1], void 0, function* (username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options = {}) {
14514
+ // verify required parameter 'username' is not null or undefined
14515
+ assertParamExists('updateNodeJsBuildSettingsV1', 'username', username);
14516
+ // verify required parameter 'domain' is not null or undefined
14517
+ assertParamExists('updateNodeJsBuildSettingsV1', 'domain', domain);
14518
+ // verify required parameter 'hostingV1NodeJsUpdateBuildSettingsRequest' is not null or undefined
14519
+ assertParamExists('updateNodeJsBuildSettingsV1', 'hostingV1NodeJsUpdateBuildSettingsRequest', hostingV1NodeJsUpdateBuildSettingsRequest);
14520
+ const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/settings`
14521
+ .replace(`{${"username"}}`, encodeURIComponent(String(username)))
14522
+ .replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
14523
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
14524
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
14525
+ let baseOptions;
14526
+ if (configuration) {
14527
+ baseOptions = configuration.baseOptions;
14528
+ }
14529
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
14530
+ const localVarHeaderParameter = {};
14531
+ const localVarQueryParameter = {};
14532
+ // authentication apiToken required
14533
+ // http bearer authentication required
14534
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
14535
+ localVarHeaderParameter['Content-Type'] = 'application/json';
14536
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
14537
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
14538
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
14539
+ localVarRequestOptions.data = serializeDataIfNeeded(hostingV1NodeJsUpdateBuildSettingsRequest, localVarRequestOptions, configuration);
14540
+ return {
14541
+ url: toPathString(localVarUrlObj),
14542
+ options: localVarRequestOptions,
14543
+ };
14544
+ }),
14242
14545
  };
14243
14546
  };
14244
14547
  /**
@@ -14248,6 +14551,39 @@ export const HostingNodeJSApiAxiosParamCreator = function (configuration) {
14248
14551
  export const HostingNodeJSApiFp = function (configuration) {
14249
14552
  const localVarAxiosParamCreator = HostingNodeJSApiAxiosParamCreator(configuration);
14250
14553
  return {
14554
+ /**
14555
+ * Returns an AI analysis of why a build failed and how to fix it, based on the build logs, the project file list and package.json. Only builds in the `failed` state can be analysed; any other state returns 422. When no analysis could be produced both `analysis` and `solution` are null, in which case read `Get NodeJS build logs` instead. Each call runs the analysis again, so call it once per failed build and keep the result. Limited to 5 calls per minute per API client (429 above that).
14556
+ * @summary Analyse failed Node.js build
14557
+ * @param {string} username
14558
+ * @param {string} domain Domain name
14559
+ * @param {string} uuid Build UUID
14560
+ * @param {*} [options] Override http request option.
14561
+ * @throws {RequiredError}
14562
+ */
14563
+ analyseFailedNodeJsBuildV1(username, domain, uuid, options) {
14564
+ return __awaiter(this, void 0, void 0, function* () {
14565
+ var _a, _b;
14566
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.analyseFailedNodeJsBuildV1(username, domain, uuid, options);
14567
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.analyseFailedNodeJsBuildV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14568
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14569
+ });
14570
+ },
14571
+ /**
14572
+ * Empties the Node.js application\'s runtime log file. This cannot be undone, so confirm with the user before calling it. Returns success even when no log file exists yet. Use it before reproducing a problem so the next `Get Node.js runtime logs` call returns only fresh entries; start that call with `period` again instead of reusing a `from_line` from before the clear.
14573
+ * @summary Clear Node.js runtime logs
14574
+ * @param {string} username
14575
+ * @param {string} domain Domain name
14576
+ * @param {*} [options] Override http request option.
14577
+ * @throws {RequiredError}
14578
+ */
14579
+ clearNodeJsRuntimeLogsV1(username, domain, options) {
14580
+ return __awaiter(this, void 0, void 0, function* () {
14581
+ var _a, _b;
14582
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.clearNodeJsRuntimeLogsV1(username, domain, options);
14583
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.clearNodeJsRuntimeLogsV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14584
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14585
+ });
14586
+ },
14251
14587
  /**
14252
14588
  * Retrieve logs from a specific Node.js build process. To stream live output while a build is running, poll this endpoint repeatedly while the build state is `running`, passing the previously returned `lines` count as `from_line` to fetch only new output since the last call. Log content may contain ANSI escape sequences (color codes).
14253
14589
  * @summary Get NodeJS build logs
@@ -14266,6 +14602,23 @@ export const HostingNodeJSApiFp = function (configuration) {
14266
14602
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14267
14603
  });
14268
14604
  },
14605
+ /**
14606
+ * Returns one build by UUID: its state (`pending`, `running`, `completed`, `failed`), the options it ran with and timestamps. Poll this while a build is pending or running. When it is failed, read `Get NodeJS build logs` and `Analyse failed Node.js build` for the cause. Returns 404 when the UUID does not belong to a build of this website.
14607
+ * @summary Get Node.js build details
14608
+ * @param {string} username
14609
+ * @param {string} domain Domain name
14610
+ * @param {string} uuid Build UUID
14611
+ * @param {*} [options] Override http request option.
14612
+ * @throws {RequiredError}
14613
+ */
14614
+ getNodeJsBuildDetailsV1(username, domain, uuid, options) {
14615
+ return __awaiter(this, void 0, void 0, function* () {
14616
+ var _a, _b;
14617
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getNodeJsBuildDetailsV1(username, domain, uuid, options);
14618
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.getNodeJsBuildDetailsV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14619
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14620
+ });
14621
+ },
14269
14622
  /**
14270
14623
  * Auto-detect Node.js build settings from a package.json inside an archive already on the server. Use this before calling `Start Node.js Build` to preview what settings will be used, or to let the user review and override values (framework, node version, root directory, output directory, build script) before committing to a build. The archive must already be present on the website\'s file storage. Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.
14271
14624
  * @summary Get Node.js build settings from archive
@@ -14283,6 +14636,42 @@ export const HostingNodeJSApiFp = function (configuration) {
14283
14636
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14284
14637
  });
14285
14638
  },
14639
+ /**
14640
+ * Returns the build settings stored for the website: framework (`app_type`), Node.js version, root and output directory, build script, entry file and package manager. Stored settings drive Git auto-deployment builds. A build started through the API uses the values sent in that request and saves them here only when no settings exist yet. Returns 404 until the first build or the first settings update stores them. Use this after a failed build to check whether the framework or the entry file were detected wrong, then fix them with the `Update Node.js build settings` endpoint.
14641
+ * @summary Get Node.js build settings
14642
+ * @param {string} username
14643
+ * @param {string} domain Domain name
14644
+ * @param {*} [options] Override http request option.
14645
+ * @throws {RequiredError}
14646
+ */
14647
+ getNodeJsBuildSettingsV1(username, domain, options) {
14648
+ return __awaiter(this, void 0, void 0, function* () {
14649
+ var _a, _b;
14650
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getNodeJsBuildSettingsV1(username, domain, options);
14651
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.getNodeJsBuildSettingsV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14652
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14653
+ });
14654
+ },
14655
+ /**
14656
+ * Returns the Node.js application\'s runtime console log entries, oldest first, each with timestamp, level and message. On the first call send `period` (`1h`, `1d`, `1w` or `1m`) and optionally `levels` and `limit` (1-5000, default 1000); when more entries match than `limit`, the newest are kept. To poll for new entries send `total_lines + 1` from the previous response as `from_line` and omit `period`; `period` and `from_line` cannot be combined. Lines that are not JSON with a timestamp, level and message are skipped, so `logs` may hold fewer than `limit` entries while `total_lines` counts every raw line. Entries with a timestamp before `last_deployed_at` belong to the previous deployment. Returns an empty `logs` list when the application has not written a log file yet.
14657
+ * @summary Get Node.js runtime logs
14658
+ * @param {string} username
14659
+ * @param {string} domain Domain name
14660
+ * @param {GetNodeJsRuntimeLogsV1PeriodEnum} [period] Time window for the first fetch. Required when &#x60;from_line&#x60; is not sent.
14661
+ * @param {number} [fromLine] 1-based line of the log file to start from. For polling send &#x60;total_lines + 1&#x60; from the previous response. Cannot be combined with &#x60;period&#x60;.
14662
+ * @param {number} [limit] Maximum number of log entries to return. When more entries match, the newest are kept.
14663
+ * @param {Array<GetNodeJsRuntimeLogsV1LevelsEnum>} [levels] Return only entries with these log levels, sent as a comma-separated list, e.g. ERROR,WARN. Matching runs on the raw log line, so entries written with numeric levels (for example by pino) are excluded while this filter is set.
14664
+ * @param {*} [options] Override http request option.
14665
+ * @throws {RequiredError}
14666
+ */
14667
+ getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options) {
14668
+ return __awaiter(this, void 0, void 0, function* () {
14669
+ var _a, _b;
14670
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options);
14671
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.getNodeJsRuntimeLogsV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14672
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14673
+ });
14674
+ },
14286
14675
  /**
14287
14676
  * Retrieve a paginated list of Node.js build processes for a specific website. Each build represents a single run of the Node.js build pipeline. Use the `states` query parameter to filter results by build state (pending, running, completed, failed). Use the `uuid` from a build to poll its output via the `Get Node.js Build Logs` endpoint.
14288
14677
  * @summary List NodeJS builds
@@ -14402,6 +14791,23 @@ export const HostingNodeJSApiFp = function (configuration) {
14402
14791
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14403
14792
  });
14404
14793
  },
14794
+ /**
14795
+ * Replaces the build settings stored for the website. Send the full set: `node_version` is required and every nullable field you omit is stored as null. Creates the settings when none exist yet. This does not start a build. Stored settings drive Git auto-deployment builds; a build started through the API uses the values sent in that request, so to rebuild with corrected settings call `Start Node.js build` with the same values. Typical fixes: a wrong `app_type` after auto-detection, or a missing `entry_file` for express, fastify, nest, nuxt and hono apps.
14796
+ * @summary Update Node.js build settings
14797
+ * @param {string} username
14798
+ * @param {string} domain Domain name
14799
+ * @param {HostingV1NodeJsUpdateBuildSettingsRequest} hostingV1NodeJsUpdateBuildSettingsRequest
14800
+ * @param {*} [options] Override http request option.
14801
+ * @throws {RequiredError}
14802
+ */
14803
+ updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options) {
14804
+ return __awaiter(this, void 0, void 0, function* () {
14805
+ var _a, _b;
14806
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options);
14807
+ const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingNodeJSApi.updateNodeJsBuildSettingsV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
14808
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
14809
+ });
14810
+ },
14405
14811
  };
14406
14812
  };
14407
14813
  /**
@@ -14411,6 +14817,29 @@ export const HostingNodeJSApiFp = function (configuration) {
14411
14817
  export const HostingNodeJSApiFactory = function (configuration, basePath, axios) {
14412
14818
  const localVarFp = HostingNodeJSApiFp(configuration);
14413
14819
  return {
14820
+ /**
14821
+ * Returns an AI analysis of why a build failed and how to fix it, based on the build logs, the project file list and package.json. Only builds in the `failed` state can be analysed; any other state returns 422. When no analysis could be produced both `analysis` and `solution` are null, in which case read `Get NodeJS build logs` instead. Each call runs the analysis again, so call it once per failed build and keep the result. Limited to 5 calls per minute per API client (429 above that).
14822
+ * @summary Analyse failed Node.js build
14823
+ * @param {string} username
14824
+ * @param {string} domain Domain name
14825
+ * @param {string} uuid Build UUID
14826
+ * @param {*} [options] Override http request option.
14827
+ * @throws {RequiredError}
14828
+ */
14829
+ analyseFailedNodeJsBuildV1(username, domain, uuid, options) {
14830
+ return localVarFp.analyseFailedNodeJsBuildV1(username, domain, uuid, options).then((request) => request(axios, basePath));
14831
+ },
14832
+ /**
14833
+ * Empties the Node.js application\'s runtime log file. This cannot be undone, so confirm with the user before calling it. Returns success even when no log file exists yet. Use it before reproducing a problem so the next `Get Node.js runtime logs` call returns only fresh entries; start that call with `period` again instead of reusing a `from_line` from before the clear.
14834
+ * @summary Clear Node.js runtime logs
14835
+ * @param {string} username
14836
+ * @param {string} domain Domain name
14837
+ * @param {*} [options] Override http request option.
14838
+ * @throws {RequiredError}
14839
+ */
14840
+ clearNodeJsRuntimeLogsV1(username, domain, options) {
14841
+ return localVarFp.clearNodeJsRuntimeLogsV1(username, domain, options).then((request) => request(axios, basePath));
14842
+ },
14414
14843
  /**
14415
14844
  * Retrieve logs from a specific Node.js build process. To stream live output while a build is running, poll this endpoint repeatedly while the build state is `running`, passing the previously returned `lines` count as `from_line` to fetch only new output since the last call. Log content may contain ANSI escape sequences (color codes).
14416
14845
  * @summary Get NodeJS build logs
@@ -14424,6 +14853,18 @@ export const HostingNodeJSApiFactory = function (configuration, basePath, axios)
14424
14853
  getNodeJSBuildLogsV1(username, domain, uuid, fromLine, options) {
14425
14854
  return localVarFp.getNodeJSBuildLogsV1(username, domain, uuid, fromLine, options).then((request) => request(axios, basePath));
14426
14855
  },
14856
+ /**
14857
+ * Returns one build by UUID: its state (`pending`, `running`, `completed`, `failed`), the options it ran with and timestamps. Poll this while a build is pending or running. When it is failed, read `Get NodeJS build logs` and `Analyse failed Node.js build` for the cause. Returns 404 when the UUID does not belong to a build of this website.
14858
+ * @summary Get Node.js build details
14859
+ * @param {string} username
14860
+ * @param {string} domain Domain name
14861
+ * @param {string} uuid Build UUID
14862
+ * @param {*} [options] Override http request option.
14863
+ * @throws {RequiredError}
14864
+ */
14865
+ getNodeJsBuildDetailsV1(username, domain, uuid, options) {
14866
+ return localVarFp.getNodeJsBuildDetailsV1(username, domain, uuid, options).then((request) => request(axios, basePath));
14867
+ },
14427
14868
  /**
14428
14869
  * Auto-detect Node.js build settings from a package.json inside an archive already on the server. Use this before calling `Start Node.js Build` to preview what settings will be used, or to let the user review and override values (framework, node version, root directory, output directory, build script) before committing to a build. The archive must already be present on the website\'s file storage. Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.
14429
14870
  * @summary Get Node.js build settings from archive
@@ -14436,6 +14877,32 @@ export const HostingNodeJSApiFactory = function (configuration, basePath, axios)
14436
14877
  getNodeJsBuildSettingsFromArchiveV1(username, domain, archivePath, options) {
14437
14878
  return localVarFp.getNodeJsBuildSettingsFromArchiveV1(username, domain, archivePath, options).then((request) => request(axios, basePath));
14438
14879
  },
14880
+ /**
14881
+ * Returns the build settings stored for the website: framework (`app_type`), Node.js version, root and output directory, build script, entry file and package manager. Stored settings drive Git auto-deployment builds. A build started through the API uses the values sent in that request and saves them here only when no settings exist yet. Returns 404 until the first build or the first settings update stores them. Use this after a failed build to check whether the framework or the entry file were detected wrong, then fix them with the `Update Node.js build settings` endpoint.
14882
+ * @summary Get Node.js build settings
14883
+ * @param {string} username
14884
+ * @param {string} domain Domain name
14885
+ * @param {*} [options] Override http request option.
14886
+ * @throws {RequiredError}
14887
+ */
14888
+ getNodeJsBuildSettingsV1(username, domain, options) {
14889
+ return localVarFp.getNodeJsBuildSettingsV1(username, domain, options).then((request) => request(axios, basePath));
14890
+ },
14891
+ /**
14892
+ * Returns the Node.js application\'s runtime console log entries, oldest first, each with timestamp, level and message. On the first call send `period` (`1h`, `1d`, `1w` or `1m`) and optionally `levels` and `limit` (1-5000, default 1000); when more entries match than `limit`, the newest are kept. To poll for new entries send `total_lines + 1` from the previous response as `from_line` and omit `period`; `period` and `from_line` cannot be combined. Lines that are not JSON with a timestamp, level and message are skipped, so `logs` may hold fewer than `limit` entries while `total_lines` counts every raw line. Entries with a timestamp before `last_deployed_at` belong to the previous deployment. Returns an empty `logs` list when the application has not written a log file yet.
14893
+ * @summary Get Node.js runtime logs
14894
+ * @param {string} username
14895
+ * @param {string} domain Domain name
14896
+ * @param {GetNodeJsRuntimeLogsV1PeriodEnum} [period] Time window for the first fetch. Required when &#x60;from_line&#x60; is not sent.
14897
+ * @param {number} [fromLine] 1-based line of the log file to start from. For polling send &#x60;total_lines + 1&#x60; from the previous response. Cannot be combined with &#x60;period&#x60;.
14898
+ * @param {number} [limit] Maximum number of log entries to return. When more entries match, the newest are kept.
14899
+ * @param {Array<GetNodeJsRuntimeLogsV1LevelsEnum>} [levels] Return only entries with these log levels, sent as a comma-separated list, e.g. ERROR,WARN. Matching runs on the raw log line, so entries written with numeric levels (for example by pino) are excluded while this filter is set.
14900
+ * @param {*} [options] Override http request option.
14901
+ * @throws {RequiredError}
14902
+ */
14903
+ getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options) {
14904
+ return localVarFp.getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options).then((request) => request(axios, basePath));
14905
+ },
14439
14906
  /**
14440
14907
  * Retrieve a paginated list of Node.js build processes for a specific website. Each build represents a single run of the Node.js build pipeline. Use the `states` query parameter to filter results by build state (pending, running, completed, failed). Use the `uuid` from a build to poll its output via the `Get Node.js Build Logs` endpoint.
14441
14908
  * @summary List NodeJS builds
@@ -14520,6 +14987,18 @@ export const HostingNodeJSApiFactory = function (configuration, basePath, axios)
14520
14987
  startNodeJsBuildV1(username, domain, hostingV1NodeJsStartBuildRequest, options) {
14521
14988
  return localVarFp.startNodeJsBuildV1(username, domain, hostingV1NodeJsStartBuildRequest, options).then((request) => request(axios, basePath));
14522
14989
  },
14990
+ /**
14991
+ * Replaces the build settings stored for the website. Send the full set: `node_version` is required and every nullable field you omit is stored as null. Creates the settings when none exist yet. This does not start a build. Stored settings drive Git auto-deployment builds; a build started through the API uses the values sent in that request, so to rebuild with corrected settings call `Start Node.js build` with the same values. Typical fixes: a wrong `app_type` after auto-detection, or a missing `entry_file` for express, fastify, nest, nuxt and hono apps.
14992
+ * @summary Update Node.js build settings
14993
+ * @param {string} username
14994
+ * @param {string} domain Domain name
14995
+ * @param {HostingV1NodeJsUpdateBuildSettingsRequest} hostingV1NodeJsUpdateBuildSettingsRequest
14996
+ * @param {*} [options] Override http request option.
14997
+ * @throws {RequiredError}
14998
+ */
14999
+ updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options) {
15000
+ return localVarFp.updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options).then((request) => request(axios, basePath));
15001
+ },
14523
15002
  };
14524
15003
  };
14525
15004
  /**
@@ -14529,6 +15008,31 @@ export const HostingNodeJSApiFactory = function (configuration, basePath, axios)
14529
15008
  * @extends {BaseAPI}
14530
15009
  */
14531
15010
  export class HostingNodeJSApi extends BaseAPI {
15011
+ /**
15012
+ * Returns an AI analysis of why a build failed and how to fix it, based on the build logs, the project file list and package.json. Only builds in the `failed` state can be analysed; any other state returns 422. When no analysis could be produced both `analysis` and `solution` are null, in which case read `Get NodeJS build logs` instead. Each call runs the analysis again, so call it once per failed build and keep the result. Limited to 5 calls per minute per API client (429 above that).
15013
+ * @summary Analyse failed Node.js build
15014
+ * @param {string} username
15015
+ * @param {string} domain Domain name
15016
+ * @param {string} uuid Build UUID
15017
+ * @param {*} [options] Override http request option.
15018
+ * @throws {RequiredError}
15019
+ * @memberof HostingNodeJSApi
15020
+ */
15021
+ analyseFailedNodeJsBuildV1(username, domain, uuid, options) {
15022
+ return HostingNodeJSApiFp(this.configuration).analyseFailedNodeJsBuildV1(username, domain, uuid, options).then((request) => request(this.axios, this.basePath));
15023
+ }
15024
+ /**
15025
+ * Empties the Node.js application\'s runtime log file. This cannot be undone, so confirm with the user before calling it. Returns success even when no log file exists yet. Use it before reproducing a problem so the next `Get Node.js runtime logs` call returns only fresh entries; start that call with `period` again instead of reusing a `from_line` from before the clear.
15026
+ * @summary Clear Node.js runtime logs
15027
+ * @param {string} username
15028
+ * @param {string} domain Domain name
15029
+ * @param {*} [options] Override http request option.
15030
+ * @throws {RequiredError}
15031
+ * @memberof HostingNodeJSApi
15032
+ */
15033
+ clearNodeJsRuntimeLogsV1(username, domain, options) {
15034
+ return HostingNodeJSApiFp(this.configuration).clearNodeJsRuntimeLogsV1(username, domain, options).then((request) => request(this.axios, this.basePath));
15035
+ }
14532
15036
  /**
14533
15037
  * Retrieve logs from a specific Node.js build process. To stream live output while a build is running, poll this endpoint repeatedly while the build state is `running`, passing the previously returned `lines` count as `from_line` to fetch only new output since the last call. Log content may contain ANSI escape sequences (color codes).
14534
15038
  * @summary Get NodeJS build logs
@@ -14543,6 +15047,19 @@ export class HostingNodeJSApi extends BaseAPI {
14543
15047
  getNodeJSBuildLogsV1(username, domain, uuid, fromLine, options) {
14544
15048
  return HostingNodeJSApiFp(this.configuration).getNodeJSBuildLogsV1(username, domain, uuid, fromLine, options).then((request) => request(this.axios, this.basePath));
14545
15049
  }
15050
+ /**
15051
+ * Returns one build by UUID: its state (`pending`, `running`, `completed`, `failed`), the options it ran with and timestamps. Poll this while a build is pending or running. When it is failed, read `Get NodeJS build logs` and `Analyse failed Node.js build` for the cause. Returns 404 when the UUID does not belong to a build of this website.
15052
+ * @summary Get Node.js build details
15053
+ * @param {string} username
15054
+ * @param {string} domain Domain name
15055
+ * @param {string} uuid Build UUID
15056
+ * @param {*} [options] Override http request option.
15057
+ * @throws {RequiredError}
15058
+ * @memberof HostingNodeJSApi
15059
+ */
15060
+ getNodeJsBuildDetailsV1(username, domain, uuid, options) {
15061
+ return HostingNodeJSApiFp(this.configuration).getNodeJsBuildDetailsV1(username, domain, uuid, options).then((request) => request(this.axios, this.basePath));
15062
+ }
14546
15063
  /**
14547
15064
  * Auto-detect Node.js build settings from a package.json inside an archive already on the server. Use this before calling `Start Node.js Build` to preview what settings will be used, or to let the user review and override values (framework, node version, root directory, output directory, build script) before committing to a build. The archive must already be present on the website\'s file storage. Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.
14548
15065
  * @summary Get Node.js build settings from archive
@@ -14556,6 +15073,34 @@ export class HostingNodeJSApi extends BaseAPI {
14556
15073
  getNodeJsBuildSettingsFromArchiveV1(username, domain, archivePath, options) {
14557
15074
  return HostingNodeJSApiFp(this.configuration).getNodeJsBuildSettingsFromArchiveV1(username, domain, archivePath, options).then((request) => request(this.axios, this.basePath));
14558
15075
  }
15076
+ /**
15077
+ * Returns the build settings stored for the website: framework (`app_type`), Node.js version, root and output directory, build script, entry file and package manager. Stored settings drive Git auto-deployment builds. A build started through the API uses the values sent in that request and saves them here only when no settings exist yet. Returns 404 until the first build or the first settings update stores them. Use this after a failed build to check whether the framework or the entry file were detected wrong, then fix them with the `Update Node.js build settings` endpoint.
15078
+ * @summary Get Node.js build settings
15079
+ * @param {string} username
15080
+ * @param {string} domain Domain name
15081
+ * @param {*} [options] Override http request option.
15082
+ * @throws {RequiredError}
15083
+ * @memberof HostingNodeJSApi
15084
+ */
15085
+ getNodeJsBuildSettingsV1(username, domain, options) {
15086
+ return HostingNodeJSApiFp(this.configuration).getNodeJsBuildSettingsV1(username, domain, options).then((request) => request(this.axios, this.basePath));
15087
+ }
15088
+ /**
15089
+ * Returns the Node.js application\'s runtime console log entries, oldest first, each with timestamp, level and message. On the first call send `period` (`1h`, `1d`, `1w` or `1m`) and optionally `levels` and `limit` (1-5000, default 1000); when more entries match than `limit`, the newest are kept. To poll for new entries send `total_lines + 1` from the previous response as `from_line` and omit `period`; `period` and `from_line` cannot be combined. Lines that are not JSON with a timestamp, level and message are skipped, so `logs` may hold fewer than `limit` entries while `total_lines` counts every raw line. Entries with a timestamp before `last_deployed_at` belong to the previous deployment. Returns an empty `logs` list when the application has not written a log file yet.
15090
+ * @summary Get Node.js runtime logs
15091
+ * @param {string} username
15092
+ * @param {string} domain Domain name
15093
+ * @param {GetNodeJsRuntimeLogsV1PeriodEnum} [period] Time window for the first fetch. Required when &#x60;from_line&#x60; is not sent.
15094
+ * @param {number} [fromLine] 1-based line of the log file to start from. For polling send &#x60;total_lines + 1&#x60; from the previous response. Cannot be combined with &#x60;period&#x60;.
15095
+ * @param {number} [limit] Maximum number of log entries to return. When more entries match, the newest are kept.
15096
+ * @param {Array<GetNodeJsRuntimeLogsV1LevelsEnum>} [levels] Return only entries with these log levels, sent as a comma-separated list, e.g. ERROR,WARN. Matching runs on the raw log line, so entries written with numeric levels (for example by pino) are excluded while this filter is set.
15097
+ * @param {*} [options] Override http request option.
15098
+ * @throws {RequiredError}
15099
+ * @memberof HostingNodeJSApi
15100
+ */
15101
+ getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options) {
15102
+ return HostingNodeJSApiFp(this.configuration).getNodeJsRuntimeLogsV1(username, domain, period, fromLine, limit, levels, options).then((request) => request(this.axios, this.basePath));
15103
+ }
14559
15104
  /**
14560
15105
  * Retrieve a paginated list of Node.js build processes for a specific website. Each build represents a single run of the Node.js build pipeline. Use the `states` query parameter to filter results by build state (pending, running, completed, failed). Use the `uuid` from a build to poll its output via the `Get Node.js Build Logs` endpoint.
14561
15106
  * @summary List NodeJS builds
@@ -14647,7 +15192,40 @@ export class HostingNodeJSApi extends BaseAPI {
14647
15192
  startNodeJsBuildV1(username, domain, hostingV1NodeJsStartBuildRequest, options) {
14648
15193
  return HostingNodeJSApiFp(this.configuration).startNodeJsBuildV1(username, domain, hostingV1NodeJsStartBuildRequest, options).then((request) => request(this.axios, this.basePath));
14649
15194
  }
15195
+ /**
15196
+ * Replaces the build settings stored for the website. Send the full set: `node_version` is required and every nullable field you omit is stored as null. Creates the settings when none exist yet. This does not start a build. Stored settings drive Git auto-deployment builds; a build started through the API uses the values sent in that request, so to rebuild with corrected settings call `Start Node.js build` with the same values. Typical fixes: a wrong `app_type` after auto-detection, or a missing `entry_file` for express, fastify, nest, nuxt and hono apps.
15197
+ * @summary Update Node.js build settings
15198
+ * @param {string} username
15199
+ * @param {string} domain Domain name
15200
+ * @param {HostingV1NodeJsUpdateBuildSettingsRequest} hostingV1NodeJsUpdateBuildSettingsRequest
15201
+ * @param {*} [options] Override http request option.
15202
+ * @throws {RequiredError}
15203
+ * @memberof HostingNodeJSApi
15204
+ */
15205
+ updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options) {
15206
+ return HostingNodeJSApiFp(this.configuration).updateNodeJsBuildSettingsV1(username, domain, hostingV1NodeJsUpdateBuildSettingsRequest, options).then((request) => request(this.axios, this.basePath));
15207
+ }
14650
15208
  }
15209
+ /**
15210
+ * @export
15211
+ */
15212
+ export const GetNodeJsRuntimeLogsV1PeriodEnum = {
15213
+ _1h: '1h',
15214
+ _1d: '1d',
15215
+ _1w: '1w',
15216
+ _1m: '1m'
15217
+ };
15218
+ /**
15219
+ * @export
15220
+ */
15221
+ export const GetNodeJsRuntimeLogsV1LevelsEnum = {
15222
+ Log: 'LOG',
15223
+ Error: 'ERROR',
15224
+ Warn: 'WARN',
15225
+ Info: 'INFO',
15226
+ Debug: 'DEBUG',
15227
+ Trace: 'TRACE'
15228
+ };
14651
15229
  /**
14652
15230
  * @export
14653
15231
  */