@hostinger/sdk 1.54.3 → 1.56.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/README.md CHANGED
@@ -1,9 +1,9 @@
1
- ## @hostinger/sdk@1.54.3
1
+ ## @hostinger/sdk@1.56.0
2
2
 
3
3
  For more information, please visit [https://developers.hostinger.com](https://developers.hostinger.com).
4
4
 
5
5
  ### Usage
6
6
 
7
7
  ```
8
- npm install @hostinger/sdk@1.54.3 --save
8
+ npm install @hostinger/sdk@1.56.0 --save
9
9
  ```
package/api.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.54.2
6
+ * API Version: 1.56.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
@@ -3838,6 +3838,37 @@ export interface DomainsV1TransferClaimRequest {
3838
3838
  */
3839
3839
  'should_keep_ns': boolean;
3840
3840
  }
3841
+ /**
3842
+ *
3843
+ * @export
3844
+ * @interface DomainsV1TransferTransferRequest
3845
+ */
3846
+ export interface DomainsV1TransferTransferRequest {
3847
+ /**
3848
+ * Domain name
3849
+ * @type {string}
3850
+ * @memberof DomainsV1TransferTransferRequest
3851
+ */
3852
+ 'domain': string;
3853
+ /**
3854
+ * Authorization code from the current registrar
3855
+ * @type {string}
3856
+ * @memberof DomainsV1TransferTransferRequest
3857
+ */
3858
+ 'auth_code': string;
3859
+ /**
3860
+ *
3861
+ * @type {DomainsV1PortfolioClaimRequestDomainContacts}
3862
+ * @memberof DomainsV1TransferTransferRequest
3863
+ */
3864
+ 'domain_contacts': DomainsV1PortfolioClaimRequestDomainContacts;
3865
+ /**
3866
+ * Keep the existing nameservers of the domain
3867
+ * @type {boolean}
3868
+ * @memberof DomainsV1TransferTransferRequest
3869
+ */
3870
+ 'should_keep_ns': boolean;
3871
+ }
3841
3872
  /**
3842
3873
  *
3843
3874
  * @export
@@ -8726,6 +8757,52 @@ export const HostingV1NodeJsVulnerabilityResourceSeverityEnum = {
8726
8757
 
8727
8758
  export type HostingV1NodeJsVulnerabilityResourceSeverityEnum = typeof HostingV1NodeJsVulnerabilityResourceSeverityEnum[keyof typeof HostingV1NodeJsVulnerabilityResourceSeverityEnum];
8728
8759
 
8760
+ /**
8761
+ *
8762
+ * @export
8763
+ * @interface HostingV1OnboardingsOnboardingResource
8764
+ */
8765
+ export interface HostingV1OnboardingsOnboardingResource {
8766
+ /**
8767
+ * Domain of the website being set up.
8768
+ * @type {string}
8769
+ * @memberof HostingV1OnboardingsOnboardingResource
8770
+ */
8771
+ 'domain': string;
8772
+ /**
8773
+ * Hosting account username.
8774
+ * @type {string}
8775
+ * @memberof HostingV1OnboardingsOnboardingResource
8776
+ */
8777
+ 'username': string;
8778
+ /**
8779
+ * `running` while the website is still being set up, `completed` once the setup has finished, `failed` when it stopped before finishing or has not reported progress for over an hour.
8780
+ * @type {string}
8781
+ * @memberof HostingV1OnboardingsOnboardingResource
8782
+ */
8783
+ 'status': HostingV1OnboardingsOnboardingResourceStatusEnum;
8784
+ /**
8785
+ * When the setup was requested.
8786
+ * @type {string}
8787
+ * @memberof HostingV1OnboardingsOnboardingResource
8788
+ */
8789
+ 'created_at': string;
8790
+ /**
8791
+ * When the setup last reported progress.
8792
+ * @type {string}
8793
+ * @memberof HostingV1OnboardingsOnboardingResource
8794
+ */
8795
+ 'updated_at': string;
8796
+ }
8797
+
8798
+ export const HostingV1OnboardingsOnboardingResourceStatusEnum = {
8799
+ Running: 'running',
8800
+ Completed: 'completed',
8801
+ Failed: 'failed'
8802
+ } as const;
8803
+
8804
+ export type HostingV1OnboardingsOnboardingResourceStatusEnum = typeof HostingV1OnboardingsOnboardingResourceStatusEnum[keyof typeof HostingV1OnboardingsOnboardingResourceStatusEnum];
8805
+
8729
8806
  /**
8730
8807
  *
8731
8808
  * @export
@@ -9136,7 +9213,7 @@ export interface HostingV1WebsitesWebsiteResource {
9136
9213
  */
9137
9214
  'vhost_type': HostingV1WebsitesWebsiteResourceVhostTypeEnum | null;
9138
9215
  /**
9139
- * Whether website is enabled
9216
+ * True unless the website is suspended. Not a readiness signal: a website that is still being set up is enabled too, see the list website setups endpoint.
9140
9217
  * @type {boolean}
9141
9218
  * @memberof HostingV1WebsitesWebsiteResource
9142
9219
  */
@@ -24672,6 +24749,46 @@ export const DomainsTransferApiAxiosParamCreator = function (configuration?: Con
24672
24749
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
24673
24750
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
24674
24751
 
24752
+ return {
24753
+ url: toPathString(localVarUrlObj),
24754
+ options: localVarRequestOptions,
24755
+ };
24756
+ },
24757
+ /**
24758
+ * Transfer a domain from another registrar to your account. The transfer runs on a domain transfer service you have already purchased. Before making request, unlock the domain at the current registrar and get its authorization code. A successful response means the transfer has been started. Completion depends on the current registrar and can be followed with the [transfer list endpoint](#tag/domains-transfer). If no WHOIS information is provided, default contact information for that TLD will be used. Before making request, ensure WHOIS information for desired TLD exists in your account. Use this endpoint to bring domains registered elsewhere into your account.
24759
+ * @summary Start domain transfer
24760
+ * @param {DomainsV1TransferTransferRequest} domainsV1TransferTransferRequest
24761
+ * @param {*} [options] Override http request option.
24762
+ * @throws {RequiredError}
24763
+ */
24764
+ startDomainTransferV1: async (domainsV1TransferTransferRequest: DomainsV1TransferTransferRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
24765
+ // verify required parameter 'domainsV1TransferTransferRequest' is not null or undefined
24766
+ assertParamExists('startDomainTransferV1', 'domainsV1TransferTransferRequest', domainsV1TransferTransferRequest)
24767
+ const localVarPath = `/api/domains/v1/transfers`;
24768
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
24769
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
24770
+ let baseOptions;
24771
+ if (configuration) {
24772
+ baseOptions = configuration.baseOptions;
24773
+ }
24774
+
24775
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
24776
+ const localVarHeaderParameter = {} as any;
24777
+ const localVarQueryParameter = {} as any;
24778
+
24779
+ // authentication apiToken required
24780
+ // http bearer authentication required
24781
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
24782
+
24783
+
24784
+
24785
+ localVarHeaderParameter['Content-Type'] = 'application/json';
24786
+
24787
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
24788
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
24789
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
24790
+ localVarRequestOptions.data = serializeDataIfNeeded(domainsV1TransferTransferRequest, localVarRequestOptions, configuration)
24791
+
24675
24792
  return {
24676
24793
  url: toPathString(localVarUrlObj),
24677
24794
  options: localVarRequestOptions,
@@ -24722,6 +24839,18 @@ export const DomainsTransferApiFp = function(configuration?: Configuration) {
24722
24839
  const localVarOperationServerBasePath = operationServerMap['DomainsTransferApi.getTransferV1']?.[0]?.url;
24723
24840
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
24724
24841
  },
24842
+ /**
24843
+ * Transfer a domain from another registrar to your account. The transfer runs on a domain transfer service you have already purchased. Before making request, unlock the domain at the current registrar and get its authorization code. A successful response means the transfer has been started. Completion depends on the current registrar and can be followed with the [transfer list endpoint](#tag/domains-transfer). If no WHOIS information is provided, default contact information for that TLD will be used. Before making request, ensure WHOIS information for desired TLD exists in your account. Use this endpoint to bring domains registered elsewhere into your account.
24844
+ * @summary Start domain transfer
24845
+ * @param {DomainsV1TransferTransferRequest} domainsV1TransferTransferRequest
24846
+ * @param {*} [options] Override http request option.
24847
+ * @throws {RequiredError}
24848
+ */
24849
+ async startDomainTransferV1(domainsV1TransferTransferRequest: DomainsV1TransferTransferRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
24850
+ const localVarAxiosArgs = await localVarAxiosParamCreator.startDomainTransferV1(domainsV1TransferTransferRequest, options);
24851
+ const localVarOperationServerBasePath = operationServerMap['DomainsTransferApi.startDomainTransferV1']?.[0]?.url;
24852
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
24853
+ },
24725
24854
  }
24726
24855
  };
24727
24856
 
@@ -24761,6 +24890,16 @@ export const DomainsTransferApiFactory = function (configuration?: Configuration
24761
24890
  getTransferV1(domain: string, options?: RawAxiosRequestConfig): AxiosPromise<DomainsV1TransferTransferResource> {
24762
24891
  return localVarFp.getTransferV1(domain, options).then((request) => request(axios, basePath));
24763
24892
  },
24893
+ /**
24894
+ * Transfer a domain from another registrar to your account. The transfer runs on a domain transfer service you have already purchased. Before making request, unlock the domain at the current registrar and get its authorization code. A successful response means the transfer has been started. Completion depends on the current registrar and can be followed with the [transfer list endpoint](#tag/domains-transfer). If no WHOIS information is provided, default contact information for that TLD will be used. Before making request, ensure WHOIS information for desired TLD exists in your account. Use this endpoint to bring domains registered elsewhere into your account.
24895
+ * @summary Start domain transfer
24896
+ * @param {DomainsV1TransferTransferRequest} domainsV1TransferTransferRequest
24897
+ * @param {*} [options] Override http request option.
24898
+ * @throws {RequiredError}
24899
+ */
24900
+ startDomainTransferV1(domainsV1TransferTransferRequest: DomainsV1TransferTransferRequest, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
24901
+ return localVarFp.startDomainTransferV1(domainsV1TransferTransferRequest, options).then((request) => request(axios, basePath));
24902
+ },
24764
24903
  };
24765
24904
  };
24766
24905
 
@@ -24805,6 +24944,18 @@ export class DomainsTransferApi extends BaseAPI {
24805
24944
  public getTransferV1(domain: string, options?: RawAxiosRequestConfig) {
24806
24945
  return DomainsTransferApiFp(this.configuration).getTransferV1(domain, options).then((request) => request(this.axios, this.basePath));
24807
24946
  }
24947
+
24948
+ /**
24949
+ * Transfer a domain from another registrar to your account. The transfer runs on a domain transfer service you have already purchased. Before making request, unlock the domain at the current registrar and get its authorization code. A successful response means the transfer has been started. Completion depends on the current registrar and can be followed with the [transfer list endpoint](#tag/domains-transfer). If no WHOIS information is provided, default contact information for that TLD will be used. Before making request, ensure WHOIS information for desired TLD exists in your account. Use this endpoint to bring domains registered elsewhere into your account.
24950
+ * @summary Start domain transfer
24951
+ * @param {DomainsV1TransferTransferRequest} domainsV1TransferTransferRequest
24952
+ * @param {*} [options] Override http request option.
24953
+ * @throws {RequiredError}
24954
+ * @memberof DomainsTransferApi
24955
+ */
24956
+ public startDomainTransferV1(domainsV1TransferTransferRequest: DomainsV1TransferTransferRequest, options?: RawAxiosRequestConfig) {
24957
+ return DomainsTransferApiFp(this.configuration).startDomainTransferV1(domainsV1TransferTransferRequest, options).then((request) => request(this.axios, this.basePath));
24958
+ }
24808
24959
  }
24809
24960
 
24810
24961
 
@@ -29668,7 +29819,7 @@ export const HostingDatabasesApiAxiosParamCreator = function (configuration?: Co
29668
29819
  };
29669
29820
  },
29670
29821
  /**
29671
- * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint.
29822
+ * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint. Database creation is synchronous, so a 404 here means no database with that name exists under the username, not that it is still being created.
29672
29823
  * @summary Create database remote connection
29673
29824
  * @param {string} username
29674
29825
  * @param {string} name Full database name as returned by the list databases endpoint.
@@ -30080,7 +30231,7 @@ export const HostingDatabasesApiFp = function(configuration?: Configuration) {
30080
30231
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
30081
30232
  },
30082
30233
  /**
30083
- * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint.
30234
+ * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint. Database creation is synchronous, so a 404 here means no database with that name exists under the username, not that it is still being created.
30084
30235
  * @summary Create database remote connection
30085
30236
  * @param {string} username
30086
30237
  * @param {string} name Full database name as returned by the list databases endpoint.
@@ -30224,7 +30375,7 @@ export const HostingDatabasesApiFactory = function (configuration?: Configuratio
30224
30375
  return localVarFp.createAccountDatabaseV1(username, hostingV1DatabasesCreateDatabaseRequest, options).then((request) => request(axios, basePath));
30225
30376
  },
30226
30377
  /**
30227
- * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint.
30378
+ * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint. Database creation is synchronous, so a 404 here means no database with that name exists under the username, not that it is still being created.
30228
30379
  * @summary Create database remote connection
30229
30380
  * @param {string} username
30230
30381
  * @param {string} name Full database name as returned by the list databases endpoint.
@@ -30356,7 +30507,7 @@ export class HostingDatabasesApi extends BaseAPI {
30356
30507
  }
30357
30508
 
30358
30509
  /**
30359
- * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint.
30510
+ * Allows a remote host to connect to the specified database. Provide an IPv4/IPv6 address, or \"%\" to allow any host. The database name must be the full name returned by the list databases endpoint. Database creation is synchronous, so a 404 here means no database with that name exists under the username, not that it is still being created.
30360
30511
  * @summary Create database remote connection
30361
30512
  * @param {string} username
30362
30513
  * @param {string} name Full database name as returned by the list databases endpoint.
@@ -31274,7 +31425,7 @@ export class HostingDomainsApi extends BaseAPI {
31274
31425
  export const HostingFilesApiAxiosParamCreator = function (configuration?: Configuration) {
31275
31426
  return {
31276
31427
  /**
31277
- * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31428
+ * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. While the website is still being set up (`status: running` on the list website setups endpoint) this endpoint returns 409 with a `Retry-After` header: wait that many seconds and retry, or poll the website setups until the status is `completed`. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31278
31429
  * @summary Generate upload URL
31279
31430
  * @param {HostingV1FilesGenerateUploadUrlRequest} hostingV1FilesGenerateUploadUrlRequest
31280
31431
  * @param {*} [options] Override http request option.
@@ -31450,7 +31601,7 @@ export const HostingFilesApiFp = function(configuration?: Configuration) {
31450
31601
  const localVarAxiosParamCreator = HostingFilesApiAxiosParamCreator(configuration)
31451
31602
  return {
31452
31603
  /**
31453
- * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31604
+ * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. While the website is still being set up (`status: running` on the list website setups endpoint) this endpoint returns 409 with a `Retry-After` header: wait that many seconds and retry, or poll the website setups until the status is `completed`. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31454
31605
  * @summary Generate upload URL
31455
31606
  * @param {HostingV1FilesGenerateUploadUrlRequest} hostingV1FilesGenerateUploadUrlRequest
31456
31607
  * @param {*} [options] Override http request option.
@@ -31506,7 +31657,7 @@ export const HostingFilesApiFactory = function (configuration?: Configuration, b
31506
31657
  const localVarFp = HostingFilesApiFp(configuration)
31507
31658
  return {
31508
31659
  /**
31509
- * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31660
+ * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. While the website is still being set up (`status: running` on the list website setups endpoint) this endpoint returns 409 with a `Retry-After` header: wait that many seconds and retry, or poll the website setups until the status is `completed`. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31510
31661
  * @summary Generate upload URL
31511
31662
  * @param {HostingV1FilesGenerateUploadUrlRequest} hostingV1FilesGenerateUploadUrlRequest
31512
31663
  * @param {*} [options] Override http request option.
@@ -31556,7 +31707,7 @@ export const HostingFilesApiFactory = function (configuration?: Configuration, b
31556
31707
  */
31557
31708
  export class HostingFilesApi extends BaseAPI {
31558
31709
  /**
31559
- * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31710
+ * Generate a file browser upload URL with authentication credentials for uploading files directly to a website\'s file storage. While the website is still being set up (`status: running` on the list website setups endpoint) this endpoint returns 409 with a `Retry-After` header: wait that many seconds and retry, or poll the website setups until the status is `completed`. Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the website\'s `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0). Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below. 1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`. 2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or `PATCH` requests with an `upload-offset` header tracking progress) until complete. `relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`. Instead of a TUS client, plain `curl` also works: ``` FILE=app.zip SIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux curl -i -X POST \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Upload-Length: ${SIZE}\" \\ -H \"Upload-Offset: 0\" # -> 201 Created curl -i -X PATCH \"{url}/${FILE}?override=true\" \\ -H \"X-Auth: {auth_key}\" \\ -H \"X-Auth-Rest: {rest_auth_key}\" \\ -H \"Tus-Resumable: 1.0.0\" \\ -H \"Content-Type: application/offset+octet-stream\" \\ -H \"Upload-Offset: 0\" \\ --data-binary \"@${FILE}\" # -> 204 No Content, Upload-Offset response header equals SIZE when done ```
31560
31711
  * @summary Generate upload URL
31561
31712
  * @param {HostingV1FilesGenerateUploadUrlRequest} hostingV1FilesGenerateUploadUrlRequest
31562
31713
  * @param {*} [options] Override http request option.
@@ -34844,7 +34995,7 @@ export class HostingSSLApi extends BaseAPI {
34844
34995
  export const HostingWebsitesApiAxiosParamCreator = function (configuration?: Configuration) {
34845
34996
  return {
34846
34997
  /**
34847
- * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation takes up to a few minutes to complete. Check the websites list endpoint to see when your new website becomes available.
34998
+ * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation is asynchronous and takes up to a few minutes. Poll the list website setups endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. While the setup is `running`, endpoints that operate on the website may respond with `404` or `409`. `is_enabled` on the websites list reflects suspension, not readiness.
34848
34999
  * @summary Create website
34849
35000
  * @param {HostingV1WebsitesCreateWebsiteRequest} hostingV1WebsitesCreateWebsiteRequest
34850
35001
  * @param {*} [options] Override http request option.
@@ -34970,7 +35121,46 @@ export const HostingWebsitesApiAxiosParamCreator = function (configuration?: Con
34970
35121
  };
34971
35122
  },
34972
35123
  /**
34973
- * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results.
35124
+ * Returns the website setups started in the last 24 hours for the hosting accounts accessible to the authenticated client, newest first. Meant for polling right after creating a website: the website shows up in the websites list before its server-side setup has finished, and while the setup is `running` endpoints that operate on that website may respond with `404` or `409`. Poll this endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. `failed` means the setup stopped before finishing or has not reported progress for over an hour. Setups older than 24 hours are not listed.
35125
+ * @summary List website setups
35126
+ * @param {string | null} [domain] Filter by domain name (exact match)
35127
+ * @param {*} [options] Override http request option.
35128
+ * @throws {RequiredError}
35129
+ */
35130
+ listWebsiteSetupsV1: async (domain?: string | null, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
35131
+ const localVarPath = `/api/hosting/v1/onboardings`;
35132
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
35133
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
35134
+ let baseOptions;
35135
+ if (configuration) {
35136
+ baseOptions = configuration.baseOptions;
35137
+ }
35138
+
35139
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
35140
+ const localVarHeaderParameter = {} as any;
35141
+ const localVarQueryParameter = {} as any;
35142
+
35143
+ // authentication apiToken required
35144
+ // http bearer authentication required
35145
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
35146
+
35147
+ if (domain !== undefined) {
35148
+ localVarQueryParameter['domain'] = domain;
35149
+ }
35150
+
35151
+
35152
+
35153
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
35154
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
35155
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
35156
+
35157
+ return {
35158
+ url: toPathString(localVarUrlObj),
35159
+ options: localVarRequestOptions,
35160
+ };
35161
+ },
35162
+ /**
35163
+ * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results. A website appears in this list before its server-side setup has finished, and `is_enabled` reflects suspension, not readiness. To know when a newly created website is ready for file, deploy or database operations, poll the list website setups endpoint instead.
34974
35164
  * @summary List websites
34975
35165
  * @param {number} [page] Page number
34976
35166
  * @param {number} [perPage] Number of items per page
@@ -35049,7 +35239,7 @@ export const HostingWebsitesApiFp = function(configuration?: Configuration) {
35049
35239
  const localVarAxiosParamCreator = HostingWebsitesApiAxiosParamCreator(configuration)
35050
35240
  return {
35051
35241
  /**
35052
- * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation takes up to a few minutes to complete. Check the websites list endpoint to see when your new website becomes available.
35242
+ * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation is asynchronous and takes up to a few minutes. Poll the list website setups endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. While the setup is `running`, endpoints that operate on the website may respond with `404` or `409`. `is_enabled` on the websites list reflects suspension, not readiness.
35053
35243
  * @summary Create website
35054
35244
  * @param {HostingV1WebsitesCreateWebsiteRequest} hostingV1WebsitesCreateWebsiteRequest
35055
35245
  * @param {*} [options] Override http request option.
@@ -35087,7 +35277,19 @@ export const HostingWebsitesApiFp = function(configuration?: Configuration) {
35087
35277
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
35088
35278
  },
35089
35279
  /**
35090
- * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results.
35280
+ * Returns the website setups started in the last 24 hours for the hosting accounts accessible to the authenticated client, newest first. Meant for polling right after creating a website: the website shows up in the websites list before its server-side setup has finished, and while the setup is `running` endpoints that operate on that website may respond with `404` or `409`. Poll this endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. `failed` means the setup stopped before finishing or has not reported progress for over an hour. Setups older than 24 hours are not listed.
35281
+ * @summary List website setups
35282
+ * @param {string | null} [domain] Filter by domain name (exact match)
35283
+ * @param {*} [options] Override http request option.
35284
+ * @throws {RequiredError}
35285
+ */
35286
+ async listWebsiteSetupsV1(domain?: string | null, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<HostingV1OnboardingsOnboardingResource>>> {
35287
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listWebsiteSetupsV1(domain, options);
35288
+ const localVarOperationServerBasePath = operationServerMap['HostingWebsitesApi.listWebsiteSetupsV1']?.[0]?.url;
35289
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
35290
+ },
35291
+ /**
35292
+ * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results. A website appears in this list before its server-side setup has finished, and `is_enabled` reflects suspension, not readiness. To know when a newly created website is ready for file, deploy or database operations, poll the list website setups endpoint instead.
35091
35293
  * @summary List websites
35092
35294
  * @param {number} [page] Page number
35093
35295
  * @param {number} [perPage] Number of items per page
@@ -35115,7 +35317,7 @@ export const HostingWebsitesApiFactory = function (configuration?: Configuration
35115
35317
  const localVarFp = HostingWebsitesApiFp(configuration)
35116
35318
  return {
35117
35319
  /**
35118
- * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation takes up to a few minutes to complete. Check the websites list endpoint to see when your new website becomes available.
35320
+ * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation is asynchronous and takes up to a few minutes. Poll the list website setups endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. While the setup is `running`, endpoints that operate on the website may respond with `404` or `409`. `is_enabled` on the websites list reflects suspension, not readiness.
35119
35321
  * @summary Create website
35120
35322
  * @param {HostingV1WebsitesCreateWebsiteRequest} hostingV1WebsitesCreateWebsiteRequest
35121
35323
  * @param {*} [options] Override http request option.
@@ -35147,7 +35349,17 @@ export const HostingWebsitesApiFactory = function (configuration?: Configuration
35147
35349
  return localVarFp.deployStaticSiteArchiveV1(username, domain, hostingV1WebsitesDeployArchiveRequest, options).then((request) => request(axios, basePath));
35148
35350
  },
35149
35351
  /**
35150
- * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results.
35352
+ * Returns the website setups started in the last 24 hours for the hosting accounts accessible to the authenticated client, newest first. Meant for polling right after creating a website: the website shows up in the websites list before its server-side setup has finished, and while the setup is `running` endpoints that operate on that website may respond with `404` or `409`. Poll this endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. `failed` means the setup stopped before finishing or has not reported progress for over an hour. Setups older than 24 hours are not listed.
35353
+ * @summary List website setups
35354
+ * @param {string | null} [domain] Filter by domain name (exact match)
35355
+ * @param {*} [options] Override http request option.
35356
+ * @throws {RequiredError}
35357
+ */
35358
+ listWebsiteSetupsV1(domain?: string | null, options?: RawAxiosRequestConfig): AxiosPromise<Array<HostingV1OnboardingsOnboardingResource>> {
35359
+ return localVarFp.listWebsiteSetupsV1(domain, options).then((request) => request(axios, basePath));
35360
+ },
35361
+ /**
35362
+ * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results. A website appears in this list before its server-side setup has finished, and `is_enabled` reflects suspension, not readiness. To know when a newly created website is ready for file, deploy or database operations, poll the list website setups endpoint instead.
35151
35363
  * @summary List websites
35152
35364
  * @param {number} [page] Page number
35153
35365
  * @param {number} [perPage] Number of items per page
@@ -35173,7 +35385,7 @@ export const HostingWebsitesApiFactory = function (configuration?: Configuration
35173
35385
  */
35174
35386
  export class HostingWebsitesApi extends BaseAPI {
35175
35387
  /**
35176
- * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation takes up to a few minutes to complete. Check the websites list endpoint to see when your new website becomes available.
35388
+ * Create a new website for the authenticated client. You must choose which hosting order to create this website on. Pass that order as `order_id` together with the domain name. List orders to see available IDs; the website is provisioned on that order\'s hosting plan. The datacenter_code parameter is required when creating the first website on a new hosting plan - this will set up and configure new hosting account in the selected datacenter. Subsequent websites will be hosted on the same datacenter automatically. Website creation is asynchronous and takes up to a few minutes. Poll the list website setups endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. While the setup is `running`, endpoints that operate on the website may respond with `404` or `409`. `is_enabled` on the websites list reflects suspension, not readiness.
35177
35389
  * @summary Create website
35178
35390
  * @param {HostingV1WebsitesCreateWebsiteRequest} hostingV1WebsitesCreateWebsiteRequest
35179
35391
  * @param {*} [options] Override http request option.
@@ -35211,7 +35423,19 @@ export class HostingWebsitesApi extends BaseAPI {
35211
35423
  }
35212
35424
 
35213
35425
  /**
35214
- * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results.
35426
+ * Returns the website setups started in the last 24 hours for the hosting accounts accessible to the authenticated client, newest first. Meant for polling right after creating a website: the website shows up in the websites list before its server-side setup has finished, and while the setup is `running` endpoints that operate on that website may respond with `404` or `409`. Poll this endpoint with the `domain` filter every 10 to 15 seconds and wait for `status: completed` before uploading files, deploying or creating databases. `failed` means the setup stopped before finishing or has not reported progress for over an hour. Setups older than 24 hours are not listed.
35427
+ * @summary List website setups
35428
+ * @param {string | null} [domain] Filter by domain name (exact match)
35429
+ * @param {*} [options] Override http request option.
35430
+ * @throws {RequiredError}
35431
+ * @memberof HostingWebsitesApi
35432
+ */
35433
+ public listWebsiteSetupsV1(domain?: string | null, options?: RawAxiosRequestConfig) {
35434
+ return HostingWebsitesApiFp(this.configuration).listWebsiteSetupsV1(domain, options).then((request) => request(this.axios, this.basePath));
35435
+ }
35436
+
35437
+ /**
35438
+ * Retrieve a paginated list of websites (CloudLinux, Builder, and Horizons) accessible to the authenticated client. This endpoint returns websites from your hosting accounts as well as websites from other client hosting accounts that have shared access with you. Each website includes a `website_type` field describing the type of website detected on the underlying platform (`wordpress`, `builder`, `horizons`, `nodejs`, or `other`). Some fields, such as `vhost_type`, `username`, and `root_directory`, only apply to CloudLinux websites and are null for other platforms. Use `website_types` to list only websites of a given detected type, e.g. only WordPress websites (`website_types=wordpress`) or only Node.js websites (`website_types=nodejs`). Combine with the other available query parameters to filter by username, order ID, enabled status, or domain name for more targeted results. A website appears in this list before its server-side setup has finished, and `is_enabled` reflects suspension, not readiness. To know when a newly created website is ready for file, deploy or database operations, poll the list website setups endpoint instead.
35215
35439
  * @summary List websites
35216
35440
  * @param {number} [page] Page number
35217
35441
  * @param {number} [perPage] Number of items per page
package/base.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.54.2
6
+ * API Version: 1.56.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
package/common.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.54.2
6
+ * API Version: 1.56.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
package/configuration.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.54.2
6
+ * API Version: 1.56.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
@@ -48,7 +48,7 @@ export class Configuration {
48
48
  this.baseOptions = {
49
49
  ...param.baseOptions,
50
50
  headers: {
51
- 'User-Agent': "hostinger-typescript-sdk/1.54.3",
51
+ 'User-Agent': "hostinger-typescript-sdk/1.56.0",
52
52
  ...param.baseOptions?.headers,
53
53
  },
54
54
  };