hostinger-api-sdk 1.37.0 → 1.39.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.
Files changed (45) hide show
  1. package/README.md +2 -2
  2. package/api.ts +1052 -17
  3. package/base.ts +1 -1
  4. package/common.ts +1 -1
  5. package/configuration.ts +2 -2
  6. package/dist/api.d.ts +678 -17
  7. package/dist/api.js +723 -19
  8. package/dist/base.d.ts +1 -1
  9. package/dist/base.js +1 -1
  10. package/dist/common.d.ts +1 -1
  11. package/dist/common.js +1 -1
  12. package/dist/configuration.d.ts +1 -1
  13. package/dist/configuration.js +2 -2
  14. package/dist/esm/api.d.ts +678 -17
  15. package/dist/esm/api.js +713 -9
  16. package/dist/esm/base.d.ts +1 -1
  17. package/dist/esm/base.js +1 -1
  18. package/dist/esm/common.d.ts +1 -1
  19. package/dist/esm/common.js +1 -1
  20. package/dist/esm/configuration.d.ts +1 -1
  21. package/dist/esm/configuration.js +2 -2
  22. package/dist/esm/index.d.ts +1 -1
  23. package/dist/esm/index.js +1 -1
  24. package/dist/index.d.ts +1 -1
  25. package/dist/index.js +1 -1
  26. package/docs/AgencyHostingFilesApi.md +54 -0
  27. package/docs/HostingFilesApi.md +56 -0
  28. package/docs/HostingNodeJSApi.md +124 -1
  29. package/docs/HostingV1FilesGenerateUploadUrlRequest.md +22 -0
  30. package/docs/HostingV1FilesUploadUrlResource.md +24 -0
  31. package/docs/HostingV1NodeJsBuildSettingsResource.md +34 -0
  32. package/docs/HostingV1NodeJsGetBuildSettingsRequest.md +20 -0
  33. package/docs/HostingV1NodeJsStartBuildRequest.md +36 -0
  34. package/docs/HostingV1NodeJsStartBuildRequestSourceOptions.md +21 -0
  35. package/docs/HostingV1WebsitesDeployArchiveRequest.md +20 -0
  36. package/docs/HostingV1WebsitesWebsiteResource.md +8 -4
  37. package/docs/HostingWebsitesApi.md +63 -1
  38. package/docs/WordPressInstallationsApi.md +62 -0
  39. package/docs/WordPressPluginsApi.md +62 -0
  40. package/docs/WordPressThemesApi.md +62 -0
  41. package/docs/WordPressV1InstallationsImportWordPressRequest.md +22 -0
  42. package/docs/WordPressV1PluginsDeployPluginRequest.md +22 -0
  43. package/docs/WordPressV1ThemesDeployThemeRequest.md +24 -0
  44. package/index.ts +1 -1
  45. package/package.json +1 -1
@@ -6,6 +6,7 @@ All URIs are relative to *https://developers.hostinger.com*
6
6
  |------------- | ------------- | -------------|
7
7
  |[**createWebsiteV1**](#createwebsitev1) | **POST** /api/hosting/v1/websites | Create website|
8
8
  |[**deleteWebsiteV1**](#deletewebsitev1) | **DELETE** /api/hosting/v1/websites/{domain} | Delete website|
9
+ |[**deployStaticSiteArchiveV1**](#deploystaticsitearchivev1) | **POST** /api/hosting/v1/accounts/{username}/websites/{domain}/deploy | Deploy static site archive|
9
10
  |[**listWebsitesV1**](#listwebsitesv1) | **GET** /api/hosting/v1/websites | List websites|
10
11
 
11
12
  # **createWebsiteV1**
@@ -117,10 +118,71 @@ const { status, data } = await apiInstance.deleteWebsiteV1(
117
118
 
118
119
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
119
120
 
121
+ # **deployStaticSiteArchiveV1**
122
+ > CommonSuccessEmptyResource deployStaticSiteArchiveV1(hostingV1WebsitesDeployArchiveRequest)
123
+
124
+ Deploy a static application from an archive file. WARNING: this overwrites the website\'s existing contents and cannot be undone — verify this is intended before calling this endpoint. This endpoint allows you to deploy a static application from an archive file that has been uploaded to the website\'s directory. This only works for static sites (pre-built HTML/CSS/JS with no build step). For Node.js applications, use `Create NodeJS build from archive` instead, or `Start Node.js build` if the archive is already uploaded. For WordPress sites, use `Import WordPress website`.
125
+
126
+ ### Example
127
+
128
+ ```typescript
129
+ import {
130
+ HostingWebsitesApi,
131
+ Configuration,
132
+ HostingV1WebsitesDeployArchiveRequest
133
+ } from 'hostinger-api-sdk';
134
+
135
+ const configuration = new Configuration();
136
+ const apiInstance = new HostingWebsitesApi(configuration);
137
+
138
+ let username: string; // (default to undefined)
139
+ let domain: string; //Domain name (default to undefined)
140
+ let hostingV1WebsitesDeployArchiveRequest: HostingV1WebsitesDeployArchiveRequest; //
141
+
142
+ const { status, data } = await apiInstance.deployStaticSiteArchiveV1(
143
+ username,
144
+ domain,
145
+ hostingV1WebsitesDeployArchiveRequest
146
+ );
147
+ ```
148
+
149
+ ### Parameters
150
+
151
+ |Name | Type | Description | Notes|
152
+ |------------- | ------------- | ------------- | -------------|
153
+ | **hostingV1WebsitesDeployArchiveRequest** | **HostingV1WebsitesDeployArchiveRequest**| | |
154
+ | **username** | [**string**] | | defaults to undefined|
155
+ | **domain** | [**string**] | Domain name | defaults to undefined|
156
+
157
+
158
+ ### Return type
159
+
160
+ **CommonSuccessEmptyResource**
161
+
162
+ ### Authorization
163
+
164
+ [apiToken](../README.md#apiToken)
165
+
166
+ ### HTTP request headers
167
+
168
+ - **Content-Type**: application/json
169
+ - **Accept**: application/json
170
+
171
+
172
+ ### HTTP response details
173
+ | Status code | Description | Response headers |
174
+ |-------------|-------------|------------------|
175
+ |**200** | Success response | - |
176
+ |**422** | Validation error response | - |
177
+ |**401** | Unauthenticated response | - |
178
+ |**500** | Error response | - |
179
+
180
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
181
+
120
182
  # **listWebsitesV1**
121
183
  > HostingListWebsitesV1200Response listWebsitesV1()
122
184
 
123
- Retrieve a paginated list of websites (main and addon types) 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. Use the available query parameters to filter results by username, order ID, enabled status, or domain name for more targeted results.
185
+ 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 the available query parameters to filter results by username, order ID, enabled status, or domain name for more targeted results.
124
186
 
125
187
  ### Example
126
188
 
@@ -8,6 +8,7 @@ All URIs are relative to *https://developers.hostinger.com*
8
8
  |[**deleteWordPressInstallationV1**](#deletewordpressinstallationv1) | **DELETE** /api/hosting/v1/accounts/{username}/wordpress/{software} | Delete WordPress installation|
9
9
  |[**detectWordPressInstallationsV1**](#detectwordpressinstallationsv1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/installations/detect | Detect WordPress installations|
10
10
  |[**getInstallationJWTTokenV1**](#getinstallationjwttokenv1) | **GET** /api/hosting/v1/accounts/{username}/wordpress/{software}/jwt-token | Get installation JWT token|
11
+ |[**importWordPressWebsiteV1**](#importwordpresswebsitev1) | **POST** /api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/import | Import WordPress website|
11
12
  |[**installWordPressV1**](#installwordpressv1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/installations | Install WordPress|
12
13
  |[**listAvailableWordPressCoreUpdatesV1**](#listavailablewordpresscoreupdatesv1) | **GET** /api/hosting/v1/accounts/{username}/wordpress/{software}/updates | List available WordPress core updates|
13
14
  |[**listWordPressInstallationsV1**](#listwordpressinstallationsv1) | **GET** /api/hosting/v1/wordpress/installations | List WordPress installations|
@@ -242,6 +243,67 @@ const { status, data } = await apiInstance.getInstallationJWTTokenV1(
242
243
 
243
244
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
244
245
 
246
+ # **importWordPressWebsiteV1**
247
+ > CommonSuccessEmptyResource importWordPressWebsiteV1(wordPressV1InstallationsImportWordPressRequest)
248
+
249
+ Import WordPress website to the specified domain. WARNING: this overwrites the website\'s existing contents and cannot be undone — verify this is intended before calling this endpoint. This endpoint allows you to import a WordPress website from archive and database files that have been uploaded to the website\'s directory.
250
+
251
+ ### Example
252
+
253
+ ```typescript
254
+ import {
255
+ WordPressInstallationsApi,
256
+ Configuration,
257
+ WordPressV1InstallationsImportWordPressRequest
258
+ } from 'hostinger-api-sdk';
259
+
260
+ const configuration = new Configuration();
261
+ const apiInstance = new WordPressInstallationsApi(configuration);
262
+
263
+ let username: string; // (default to undefined)
264
+ let domain: string; //Domain name (default to undefined)
265
+ let wordPressV1InstallationsImportWordPressRequest: WordPressV1InstallationsImportWordPressRequest; //
266
+
267
+ const { status, data } = await apiInstance.importWordPressWebsiteV1(
268
+ username,
269
+ domain,
270
+ wordPressV1InstallationsImportWordPressRequest
271
+ );
272
+ ```
273
+
274
+ ### Parameters
275
+
276
+ |Name | Type | Description | Notes|
277
+ |------------- | ------------- | ------------- | -------------|
278
+ | **wordPressV1InstallationsImportWordPressRequest** | **WordPressV1InstallationsImportWordPressRequest**| | |
279
+ | **username** | [**string**] | | defaults to undefined|
280
+ | **domain** | [**string**] | Domain name | defaults to undefined|
281
+
282
+
283
+ ### Return type
284
+
285
+ **CommonSuccessEmptyResource**
286
+
287
+ ### Authorization
288
+
289
+ [apiToken](../README.md#apiToken)
290
+
291
+ ### HTTP request headers
292
+
293
+ - **Content-Type**: application/json
294
+ - **Accept**: application/json
295
+
296
+
297
+ ### HTTP response details
298
+ | Status code | Description | Response headers |
299
+ |-------------|-------------|------------------|
300
+ |**200** | Success response | - |
301
+ |**422** | Validation error response | - |
302
+ |**401** | Unauthenticated response | - |
303
+ |**500** | Error response | - |
304
+
305
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
306
+
245
307
  # **installWordPressV1**
246
308
  > CommonSuccessEmptyResource installWordPressV1(wordPressV1InstallationsInstallWordPressRequest)
247
309
 
@@ -7,6 +7,7 @@ All URIs are relative to *https://developers.hostinger.com*
7
7
  |[**activateWordPressPluginV1**](#activatewordpresspluginv1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/{software}/plugins/activate | Activate WordPress plugin|
8
8
  |[**checkIfWooCommerceIsInstalledV1**](#checkifwoocommerceisinstalledv1) | **GET** /api/hosting/v1/wordpress/plugins/is-woocommerce-installed | Check if WooCommerce is installed|
9
9
  |[**deactivateWordPressPluginV1**](#deactivatewordpresspluginv1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/{software}/plugins/deactivate | Deactivate WordPress plugin|
10
+ |[**deployWordPressPluginV1**](#deploywordpresspluginv1) | **POST** /api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/plugins/deploy | Deploy WordPress plugin|
10
11
  |[**installWordPressPluginsV1**](#installwordpresspluginsv1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/{software}/plugins/install | Install WordPress plugins|
11
12
  |[**listAvailableWordPressPluginsV1**](#listavailablewordpresspluginsv1) | **GET** /api/hosting/v1/accounts/{username}/wordpress/{software}/plugins/available | List available WordPress plugins|
12
13
  |[**listInstalledWordPressPluginsV1**](#listinstalledwordpresspluginsv1) | **GET** /api/hosting/v1/accounts/{username}/wordpress/{software}/plugins | List installed WordPress plugins|
@@ -191,6 +192,67 @@ const { status, data } = await apiInstance.deactivateWordPressPluginV1(
191
192
 
192
193
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
193
194
 
195
+ # **deployWordPressPluginV1**
196
+ > CommonSuccessEmptyResource deployWordPressPluginV1(wordPressV1PluginsDeployPluginRequest)
197
+
198
+ Deploy a WordPress plugin from an already uploaded directory. This endpoint allows you to deploy a WordPress plugin that has been uploaded to the website\'s directory. The plugin will be activated and made available in the WordPress admin panel.
199
+
200
+ ### Example
201
+
202
+ ```typescript
203
+ import {
204
+ WordPressPluginsApi,
205
+ Configuration,
206
+ WordPressV1PluginsDeployPluginRequest
207
+ } from 'hostinger-api-sdk';
208
+
209
+ const configuration = new Configuration();
210
+ const apiInstance = new WordPressPluginsApi(configuration);
211
+
212
+ let username: string; // (default to undefined)
213
+ let domain: string; //Domain name (default to undefined)
214
+ let wordPressV1PluginsDeployPluginRequest: WordPressV1PluginsDeployPluginRequest; //
215
+
216
+ const { status, data } = await apiInstance.deployWordPressPluginV1(
217
+ username,
218
+ domain,
219
+ wordPressV1PluginsDeployPluginRequest
220
+ );
221
+ ```
222
+
223
+ ### Parameters
224
+
225
+ |Name | Type | Description | Notes|
226
+ |------------- | ------------- | ------------- | -------------|
227
+ | **wordPressV1PluginsDeployPluginRequest** | **WordPressV1PluginsDeployPluginRequest**| | |
228
+ | **username** | [**string**] | | defaults to undefined|
229
+ | **domain** | [**string**] | Domain name | defaults to undefined|
230
+
231
+
232
+ ### Return type
233
+
234
+ **CommonSuccessEmptyResource**
235
+
236
+ ### Authorization
237
+
238
+ [apiToken](../README.md#apiToken)
239
+
240
+ ### HTTP request headers
241
+
242
+ - **Content-Type**: application/json
243
+ - **Accept**: application/json
244
+
245
+
246
+ ### HTTP response details
247
+ | Status code | Description | Response headers |
248
+ |-------------|-------------|------------------|
249
+ |**200** | Success response | - |
250
+ |**422** | Validation error response | - |
251
+ |**401** | Unauthenticated response | - |
252
+ |**500** | Error response | - |
253
+
254
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
255
+
194
256
  # **installWordPressPluginsV1**
195
257
  > CommonSuccessEmptyResource installWordPressPluginsV1(wordPressV1PluginsInstallPluginsRequest)
196
258
 
@@ -5,6 +5,7 @@ All URIs are relative to *https://developers.hostinger.com*
5
5
  |Method | HTTP request | Description|
6
6
  |------------- | ------------- | -------------|
7
7
  |[**activateWordPressThemeV1**](#activatewordpressthemev1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/{software}/themes/activate | Activate WordPress theme|
8
+ |[**deployWordPressThemeV1**](#deploywordpressthemev1) | **POST** /api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/themes/deploy | Deploy WordPress theme|
8
9
  |[**installWordPressThemeV1**](#installwordpressthemev1) | **POST** /api/hosting/v1/accounts/{username}/wordpress/{software}/themes/install | Install WordPress theme|
9
10
  |[**listInstalledWordPressThemesV1**](#listinstalledwordpressthemesv1) | **GET** /api/hosting/v1/accounts/{username}/wordpress/{software}/themes | List installed WordPress themes|
10
11
  |[**listWordPressThemesV1**](#listwordpressthemesv1) | **GET** /api/hosting/v1/wordpress/themes | List WordPress themes|
@@ -72,6 +73,67 @@ const { status, data } = await apiInstance.activateWordPressThemeV1(
72
73
 
73
74
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
74
75
 
76
+ # **deployWordPressThemeV1**
77
+ > CommonSuccessEmptyResource deployWordPressThemeV1(wordPressV1ThemesDeployThemeRequest)
78
+
79
+ Deploy a WordPress theme from an already uploaded directory. This endpoint allows you to deploy a WordPress theme that has been uploaded to the website\'s directory. The theme can be optionally activated after deployment.
80
+
81
+ ### Example
82
+
83
+ ```typescript
84
+ import {
85
+ WordPressThemesApi,
86
+ Configuration,
87
+ WordPressV1ThemesDeployThemeRequest
88
+ } from 'hostinger-api-sdk';
89
+
90
+ const configuration = new Configuration();
91
+ const apiInstance = new WordPressThemesApi(configuration);
92
+
93
+ let username: string; // (default to undefined)
94
+ let domain: string; //Domain name (default to undefined)
95
+ let wordPressV1ThemesDeployThemeRequest: WordPressV1ThemesDeployThemeRequest; //
96
+
97
+ const { status, data } = await apiInstance.deployWordPressThemeV1(
98
+ username,
99
+ domain,
100
+ wordPressV1ThemesDeployThemeRequest
101
+ );
102
+ ```
103
+
104
+ ### Parameters
105
+
106
+ |Name | Type | Description | Notes|
107
+ |------------- | ------------- | ------------- | -------------|
108
+ | **wordPressV1ThemesDeployThemeRequest** | **WordPressV1ThemesDeployThemeRequest**| | |
109
+ | **username** | [**string**] | | defaults to undefined|
110
+ | **domain** | [**string**] | Domain name | defaults to undefined|
111
+
112
+
113
+ ### Return type
114
+
115
+ **CommonSuccessEmptyResource**
116
+
117
+ ### Authorization
118
+
119
+ [apiToken](../README.md#apiToken)
120
+
121
+ ### HTTP request headers
122
+
123
+ - **Content-Type**: application/json
124
+ - **Accept**: application/json
125
+
126
+
127
+ ### HTTP response details
128
+ | Status code | Description | Response headers |
129
+ |-------------|-------------|------------------|
130
+ |**200** | Success response | - |
131
+ |**422** | Validation error response | - |
132
+ |**401** | Unauthenticated response | - |
133
+ |**500** | Error response | - |
134
+
135
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
136
+
75
137
  # **installWordPressThemeV1**
76
138
  > CommonSuccessEmptyResource installWordPressThemeV1(wordPressV1ThemesInstallThemeRequest)
77
139
 
@@ -0,0 +1,22 @@
1
+ # WordPressV1InstallationsImportWordPressRequest
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **archive_path** | **string** | Path to the WordPress archive file (relative to website root) | [default to undefined]
9
+ **sql_path** | **string** | Path to the database SQL file (relative to website root) | [default to undefined]
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import { WordPressV1InstallationsImportWordPressRequest } from 'hostinger-api-sdk';
15
+
16
+ const instance: WordPressV1InstallationsImportWordPressRequest = {
17
+ archive_path,
18
+ sql_path,
19
+ };
20
+ ```
21
+
22
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,22 @@
1
+ # WordPressV1PluginsDeployPluginRequest
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **slug** | **string** | Slug of the plugin | [default to undefined]
9
+ **plugin_path** | **string** | Relative path to the plugin directory from wp-content/plugins | [default to undefined]
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import { WordPressV1PluginsDeployPluginRequest } from 'hostinger-api-sdk';
15
+
16
+ const instance: WordPressV1PluginsDeployPluginRequest = {
17
+ slug,
18
+ plugin_path,
19
+ };
20
+ ```
21
+
22
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,24 @@
1
+ # WordPressV1ThemesDeployThemeRequest
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **slug** | **string** | Slug of the theme | [default to undefined]
9
+ **theme_path** | **string** | Relative path to the theme directory from wp-content/themes | [default to undefined]
10
+ **is_activated** | **boolean** | Whether to activate the theme after deployment | [optional] [default to false]
11
+
12
+ ## Example
13
+
14
+ ```typescript
15
+ import { WordPressV1ThemesDeployThemeRequest } from 'hostinger-api-sdk';
16
+
17
+ const instance: WordPressV1ThemesDeployThemeRequest = {
18
+ slug,
19
+ theme_path,
20
+ is_activated,
21
+ };
22
+ ```
23
+
24
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
package/index.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 1.39.0
6
+ * API Version: 1.41.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hostinger-api-sdk",
3
- "version": "1.37.0",
3
+ "version": "1.39.0",
4
4
  "description": "Hostinger API TypeScript SDK",
5
5
  "author": "Hostinger",
6
6
  "repository": {