hostinger-api-sdk 1.5.0 → 1.5.1
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 +2 -2
- package/api.ts +81 -195
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +2 -2
- package/dist/api.d.ts +59 -99
- package/dist/api.js +55 -189
- package/dist/base.d.ts +1 -1
- package/dist/base.js +1 -1
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +2 -2
- package/dist/esm/api.d.ts +59 -99
- package/dist/esm/api.js +55 -189
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +1 -1
- package/dist/esm/common.d.ts +1 -1
- package/dist/esm/common.js +1 -1
- package/dist/esm/configuration.d.ts +1 -1
- package/dist/esm/configuration.js +2 -2
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/docs/HostingCacheApi.md +26 -130
- package/docs/HostingV1CacheToggleCacheRequest.md +20 -0
- package/docs/HostingV1CacheToggleCachelessModeRequest.md +20 -0
- package/index.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
## hostinger-api-sdk@1.5.
|
|
1
|
+
## hostinger-api-sdk@1.5.1
|
|
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-api-sdk@1.5.
|
|
8
|
+
npm install hostinger-api-sdk@1.5.1 --save
|
|
9
9
|
```
|
package/api.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.5.
|
|
6
|
+
* API Version: 1.5.1
|
|
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
|
|
@@ -2479,6 +2479,32 @@ export interface HostingListWebsitesV1200Response {
|
|
|
2479
2479
|
*/
|
|
2480
2480
|
'meta': CommonSchemaPaginationMetaSchema;
|
|
2481
2481
|
}
|
|
2482
|
+
/**
|
|
2483
|
+
*
|
|
2484
|
+
* @export
|
|
2485
|
+
* @interface HostingV1CacheToggleCacheRequest
|
|
2486
|
+
*/
|
|
2487
|
+
export interface HostingV1CacheToggleCacheRequest {
|
|
2488
|
+
/**
|
|
2489
|
+
* Turn server-side caching on (true) or off (false) for the website.
|
|
2490
|
+
* @type {boolean}
|
|
2491
|
+
* @memberof HostingV1CacheToggleCacheRequest
|
|
2492
|
+
*/
|
|
2493
|
+
'enabled': boolean;
|
|
2494
|
+
}
|
|
2495
|
+
/**
|
|
2496
|
+
*
|
|
2497
|
+
* @export
|
|
2498
|
+
* @interface HostingV1CacheToggleCachelessModeRequest
|
|
2499
|
+
*/
|
|
2500
|
+
export interface HostingV1CacheToggleCachelessModeRequest {
|
|
2501
|
+
/**
|
|
2502
|
+
* Turn development (cacheless) mode on (true) or off (false) for the website.
|
|
2503
|
+
* @type {boolean}
|
|
2504
|
+
* @memberof HostingV1CacheToggleCachelessModeRequest
|
|
2505
|
+
*/
|
|
2506
|
+
'enabled': boolean;
|
|
2507
|
+
}
|
|
2482
2508
|
/**
|
|
2483
2509
|
*
|
|
2484
2510
|
* @export
|
|
@@ -10974,19 +11000,22 @@ export const HostingCacheApiAxiosParamCreator = function (configuration?: Config
|
|
|
10974
11000
|
};
|
|
10975
11001
|
},
|
|
10976
11002
|
/**
|
|
10977
|
-
* Turns
|
|
10978
|
-
* @summary
|
|
11003
|
+
* Turns development (cacheless) mode on or off, based on the enabled flag. When enabled, nothing is cached, effectively turning off all caching for the website; use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable it after finishing development work to restore the performance benefits of caching.
|
|
11004
|
+
* @summary Toggle cacheless mode
|
|
10979
11005
|
* @param {string} username
|
|
10980
11006
|
* @param {string} domain Domain name
|
|
11007
|
+
* @param {HostingV1CacheToggleCachelessModeRequest} hostingV1CacheToggleCachelessModeRequest
|
|
10981
11008
|
* @param {*} [options] Override http request option.
|
|
10982
11009
|
* @throws {RequiredError}
|
|
10983
11010
|
*/
|
|
10984
|
-
|
|
11011
|
+
toggleCachelessModeV1: async (username: string, domain: string, hostingV1CacheToggleCachelessModeRequest: HostingV1CacheToggleCachelessModeRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
10985
11012
|
// verify required parameter 'username' is not null or undefined
|
|
10986
|
-
assertParamExists('
|
|
11013
|
+
assertParamExists('toggleCachelessModeV1', 'username', username)
|
|
10987
11014
|
// verify required parameter 'domain' is not null or undefined
|
|
10988
|
-
assertParamExists('
|
|
10989
|
-
|
|
11015
|
+
assertParamExists('toggleCachelessModeV1', 'domain', domain)
|
|
11016
|
+
// verify required parameter 'hostingV1CacheToggleCachelessModeRequest' is not null or undefined
|
|
11017
|
+
assertParamExists('toggleCachelessModeV1', 'hostingV1CacheToggleCachelessModeRequest', hostingV1CacheToggleCachelessModeRequest)
|
|
11018
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/cacheless-mode/toggle`
|
|
10990
11019
|
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
10991
11020
|
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
10992
11021
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
@@ -11006,51 +11035,12 @@ export const HostingCacheApiAxiosParamCreator = function (configuration?: Config
|
|
|
11006
11035
|
|
|
11007
11036
|
|
|
11008
11037
|
|
|
11009
|
-
|
|
11010
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
11011
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
11012
|
-
|
|
11013
|
-
return {
|
|
11014
|
-
url: toPathString(localVarUrlObj),
|
|
11015
|
-
options: localVarRequestOptions,
|
|
11016
|
-
};
|
|
11017
|
-
},
|
|
11018
|
-
/**
|
|
11019
|
-
* Turns off server-side caching for the website until it is enabled again. May impact performance. Use it when experiencing cache-related issues; to temporarily bypass caching while developing or debugging, prefer enabling cacheless mode instead. Does nothing if caching is already disabled.
|
|
11020
|
-
* @summary Disable website cache
|
|
11021
|
-
* @param {string} username
|
|
11022
|
-
* @param {string} domain Domain name
|
|
11023
|
-
* @param {*} [options] Override http request option.
|
|
11024
|
-
* @throws {RequiredError}
|
|
11025
|
-
*/
|
|
11026
|
-
disableWebsiteCacheV1: async (username: string, domain: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
11027
|
-
// verify required parameter 'username' is not null or undefined
|
|
11028
|
-
assertParamExists('disableWebsiteCacheV1', 'username', username)
|
|
11029
|
-
// verify required parameter 'domain' is not null or undefined
|
|
11030
|
-
assertParamExists('disableWebsiteCacheV1', 'domain', domain)
|
|
11031
|
-
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/cache/disable`
|
|
11032
|
-
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
11033
|
-
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
11034
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
11035
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
11036
|
-
let baseOptions;
|
|
11037
|
-
if (configuration) {
|
|
11038
|
-
baseOptions = configuration.baseOptions;
|
|
11039
|
-
}
|
|
11040
|
-
|
|
11041
|
-
const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
|
|
11042
|
-
const localVarHeaderParameter = {} as any;
|
|
11043
|
-
const localVarQueryParameter = {} as any;
|
|
11044
|
-
|
|
11045
|
-
// authentication apiToken required
|
|
11046
|
-
// http bearer authentication required
|
|
11047
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
11048
|
-
|
|
11038
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
11049
11039
|
|
|
11050
|
-
|
|
11051
11040
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
11052
11041
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
11053
11042
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
11043
|
+
localVarRequestOptions.data = serializeDataIfNeeded(hostingV1CacheToggleCachelessModeRequest, localVarRequestOptions, configuration)
|
|
11054
11044
|
|
|
11055
11045
|
return {
|
|
11056
11046
|
url: toPathString(localVarUrlObj),
|
|
@@ -11058,19 +11048,22 @@ export const HostingCacheApiAxiosParamCreator = function (configuration?: Config
|
|
|
11058
11048
|
};
|
|
11059
11049
|
},
|
|
11060
11050
|
/**
|
|
11061
|
-
*
|
|
11062
|
-
* @summary
|
|
11051
|
+
* Turns server-side caching for the website on or off, based on the enabled flag. Enable it for faster page loads, reduced server load, and improved user experience; recommended for production websites. Disabling may impact performance; to temporarily bypass caching while developing or debugging, prefer toggling cacheless mode instead. Does nothing if caching is already in the requested state.
|
|
11052
|
+
* @summary Toggle website cache
|
|
11063
11053
|
* @param {string} username
|
|
11064
11054
|
* @param {string} domain Domain name
|
|
11055
|
+
* @param {HostingV1CacheToggleCacheRequest} hostingV1CacheToggleCacheRequest
|
|
11065
11056
|
* @param {*} [options] Override http request option.
|
|
11066
11057
|
* @throws {RequiredError}
|
|
11067
11058
|
*/
|
|
11068
|
-
|
|
11059
|
+
toggleWebsiteCacheV1: async (username: string, domain: string, hostingV1CacheToggleCacheRequest: HostingV1CacheToggleCacheRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
11069
11060
|
// verify required parameter 'username' is not null or undefined
|
|
11070
|
-
assertParamExists('
|
|
11061
|
+
assertParamExists('toggleWebsiteCacheV1', 'username', username)
|
|
11071
11062
|
// verify required parameter 'domain' is not null or undefined
|
|
11072
|
-
assertParamExists('
|
|
11073
|
-
|
|
11063
|
+
assertParamExists('toggleWebsiteCacheV1', 'domain', domain)
|
|
11064
|
+
// verify required parameter 'hostingV1CacheToggleCacheRequest' is not null or undefined
|
|
11065
|
+
assertParamExists('toggleWebsiteCacheV1', 'hostingV1CacheToggleCacheRequest', hostingV1CacheToggleCacheRequest)
|
|
11066
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/cache/toggle`
|
|
11074
11067
|
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
11075
11068
|
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
11076
11069
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
@@ -11090,51 +11083,12 @@ export const HostingCacheApiAxiosParamCreator = function (configuration?: Config
|
|
|
11090
11083
|
|
|
11091
11084
|
|
|
11092
11085
|
|
|
11093
|
-
|
|
11094
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
11095
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
11096
|
-
|
|
11097
|
-
return {
|
|
11098
|
-
url: toPathString(localVarUrlObj),
|
|
11099
|
-
options: localVarRequestOptions,
|
|
11100
|
-
};
|
|
11101
|
-
},
|
|
11102
|
-
/**
|
|
11103
|
-
* Turns on server-side caching for the website for better performance. Use it for faster page loads, reduced server load, or improved user experience. Recommended for production websites. Does nothing if caching is already enabled.
|
|
11104
|
-
* @summary Enable website cache
|
|
11105
|
-
* @param {string} username
|
|
11106
|
-
* @param {string} domain Domain name
|
|
11107
|
-
* @param {*} [options] Override http request option.
|
|
11108
|
-
* @throws {RequiredError}
|
|
11109
|
-
*/
|
|
11110
|
-
enableWebsiteCacheV1: async (username: string, domain: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
11111
|
-
// verify required parameter 'username' is not null or undefined
|
|
11112
|
-
assertParamExists('enableWebsiteCacheV1', 'username', username)
|
|
11113
|
-
// verify required parameter 'domain' is not null or undefined
|
|
11114
|
-
assertParamExists('enableWebsiteCacheV1', 'domain', domain)
|
|
11115
|
-
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/cache/enable`
|
|
11116
|
-
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
11117
|
-
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
11118
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
11119
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
11120
|
-
let baseOptions;
|
|
11121
|
-
if (configuration) {
|
|
11122
|
-
baseOptions = configuration.baseOptions;
|
|
11123
|
-
}
|
|
11124
|
-
|
|
11125
|
-
const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
|
|
11126
|
-
const localVarHeaderParameter = {} as any;
|
|
11127
|
-
const localVarQueryParameter = {} as any;
|
|
11128
|
-
|
|
11129
|
-
// authentication apiToken required
|
|
11130
|
-
// http bearer authentication required
|
|
11131
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
11132
|
-
|
|
11086
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
11133
11087
|
|
|
11134
|
-
|
|
11135
11088
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
11136
11089
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
11137
11090
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
11091
|
+
localVarRequestOptions.data = serializeDataIfNeeded(hostingV1CacheToggleCacheRequest, localVarRequestOptions, configuration)
|
|
11138
11092
|
|
|
11139
11093
|
return {
|
|
11140
11094
|
url: toPathString(localVarUrlObj),
|
|
@@ -11166,55 +11120,31 @@ export const HostingCacheApiFp = function(configuration?: Configuration) {
|
|
|
11166
11120
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
11167
11121
|
},
|
|
11168
11122
|
/**
|
|
11169
|
-
* Turns
|
|
11170
|
-
* @summary
|
|
11123
|
+
* Turns development (cacheless) mode on or off, based on the enabled flag. When enabled, nothing is cached, effectively turning off all caching for the website; use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable it after finishing development work to restore the performance benefits of caching.
|
|
11124
|
+
* @summary Toggle cacheless mode
|
|
11171
11125
|
* @param {string} username
|
|
11172
11126
|
* @param {string} domain Domain name
|
|
11127
|
+
* @param {HostingV1CacheToggleCachelessModeRequest} hostingV1CacheToggleCachelessModeRequest
|
|
11173
11128
|
* @param {*} [options] Override http request option.
|
|
11174
11129
|
* @throws {RequiredError}
|
|
11175
11130
|
*/
|
|
11176
|
-
async
|
|
11177
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.
|
|
11178
|
-
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.
|
|
11131
|
+
async toggleCachelessModeV1(username: string, domain: string, hostingV1CacheToggleCachelessModeRequest: HostingV1CacheToggleCachelessModeRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
|
|
11132
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.toggleCachelessModeV1(username, domain, hostingV1CacheToggleCachelessModeRequest, options);
|
|
11133
|
+
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.toggleCachelessModeV1']?.[0]?.url;
|
|
11179
11134
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
11180
11135
|
},
|
|
11181
11136
|
/**
|
|
11182
|
-
* Turns
|
|
11183
|
-
* @summary
|
|
11137
|
+
* Turns server-side caching for the website on or off, based on the enabled flag. Enable it for faster page loads, reduced server load, and improved user experience; recommended for production websites. Disabling may impact performance; to temporarily bypass caching while developing or debugging, prefer toggling cacheless mode instead. Does nothing if caching is already in the requested state.
|
|
11138
|
+
* @summary Toggle website cache
|
|
11184
11139
|
* @param {string} username
|
|
11185
11140
|
* @param {string} domain Domain name
|
|
11141
|
+
* @param {HostingV1CacheToggleCacheRequest} hostingV1CacheToggleCacheRequest
|
|
11186
11142
|
* @param {*} [options] Override http request option.
|
|
11187
11143
|
* @throws {RequiredError}
|
|
11188
11144
|
*/
|
|
11189
|
-
async
|
|
11190
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.
|
|
11191
|
-
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.
|
|
11192
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
11193
|
-
},
|
|
11194
|
-
/**
|
|
11195
|
-
* Enables development (cacheless) mode where nothing is cached, effectively turning off all caching for the website. Use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable cacheless mode afterwards to restore normal caching.
|
|
11196
|
-
* @summary Enable cacheless mode
|
|
11197
|
-
* @param {string} username
|
|
11198
|
-
* @param {string} domain Domain name
|
|
11199
|
-
* @param {*} [options] Override http request option.
|
|
11200
|
-
* @throws {RequiredError}
|
|
11201
|
-
*/
|
|
11202
|
-
async enableCachelessModeV1(username: string, domain: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
|
|
11203
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.enableCachelessModeV1(username, domain, options);
|
|
11204
|
-
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.enableCachelessModeV1']?.[0]?.url;
|
|
11205
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
11206
|
-
},
|
|
11207
|
-
/**
|
|
11208
|
-
* Turns on server-side caching for the website for better performance. Use it for faster page loads, reduced server load, or improved user experience. Recommended for production websites. Does nothing if caching is already enabled.
|
|
11209
|
-
* @summary Enable website cache
|
|
11210
|
-
* @param {string} username
|
|
11211
|
-
* @param {string} domain Domain name
|
|
11212
|
-
* @param {*} [options] Override http request option.
|
|
11213
|
-
* @throws {RequiredError}
|
|
11214
|
-
*/
|
|
11215
|
-
async enableWebsiteCacheV1(username: string, domain: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
|
|
11216
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.enableWebsiteCacheV1(username, domain, options);
|
|
11217
|
-
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.enableWebsiteCacheV1']?.[0]?.url;
|
|
11145
|
+
async toggleWebsiteCacheV1(username: string, domain: string, hostingV1CacheToggleCacheRequest: HostingV1CacheToggleCacheRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CommonSuccessEmptyResource>> {
|
|
11146
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.toggleWebsiteCacheV1(username, domain, hostingV1CacheToggleCacheRequest, options);
|
|
11147
|
+
const localVarOperationServerBasePath = operationServerMap['HostingCacheApi.toggleWebsiteCacheV1']?.[0]?.url;
|
|
11218
11148
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
11219
11149
|
},
|
|
11220
11150
|
}
|
|
@@ -11240,48 +11170,28 @@ export const HostingCacheApiFactory = function (configuration?: Configuration, b
|
|
|
11240
11170
|
return localVarFp.clearWebsiteCacheV1(username, domain, directory, options).then((request) => request(axios, basePath));
|
|
11241
11171
|
},
|
|
11242
11172
|
/**
|
|
11243
|
-
* Turns
|
|
11244
|
-
* @summary
|
|
11245
|
-
* @param {string} username
|
|
11246
|
-
* @param {string} domain Domain name
|
|
11247
|
-
* @param {*} [options] Override http request option.
|
|
11248
|
-
* @throws {RequiredError}
|
|
11249
|
-
*/
|
|
11250
|
-
disableCachelessModeV1(username: string, domain: string, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
|
|
11251
|
-
return localVarFp.disableCachelessModeV1(username, domain, options).then((request) => request(axios, basePath));
|
|
11252
|
-
},
|
|
11253
|
-
/**
|
|
11254
|
-
* Turns off server-side caching for the website until it is enabled again. May impact performance. Use it when experiencing cache-related issues; to temporarily bypass caching while developing or debugging, prefer enabling cacheless mode instead. Does nothing if caching is already disabled.
|
|
11255
|
-
* @summary Disable website cache
|
|
11173
|
+
* Turns development (cacheless) mode on or off, based on the enabled flag. When enabled, nothing is cached, effectively turning off all caching for the website; use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable it after finishing development work to restore the performance benefits of caching.
|
|
11174
|
+
* @summary Toggle cacheless mode
|
|
11256
11175
|
* @param {string} username
|
|
11257
11176
|
* @param {string} domain Domain name
|
|
11177
|
+
* @param {HostingV1CacheToggleCachelessModeRequest} hostingV1CacheToggleCachelessModeRequest
|
|
11258
11178
|
* @param {*} [options] Override http request option.
|
|
11259
11179
|
* @throws {RequiredError}
|
|
11260
11180
|
*/
|
|
11261
|
-
|
|
11262
|
-
return localVarFp.
|
|
11181
|
+
toggleCachelessModeV1(username: string, domain: string, hostingV1CacheToggleCachelessModeRequest: HostingV1CacheToggleCachelessModeRequest, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
|
|
11182
|
+
return localVarFp.toggleCachelessModeV1(username, domain, hostingV1CacheToggleCachelessModeRequest, options).then((request) => request(axios, basePath));
|
|
11263
11183
|
},
|
|
11264
11184
|
/**
|
|
11265
|
-
*
|
|
11266
|
-
* @summary
|
|
11185
|
+
* Turns server-side caching for the website on or off, based on the enabled flag. Enable it for faster page loads, reduced server load, and improved user experience; recommended for production websites. Disabling may impact performance; to temporarily bypass caching while developing or debugging, prefer toggling cacheless mode instead. Does nothing if caching is already in the requested state.
|
|
11186
|
+
* @summary Toggle website cache
|
|
11267
11187
|
* @param {string} username
|
|
11268
11188
|
* @param {string} domain Domain name
|
|
11189
|
+
* @param {HostingV1CacheToggleCacheRequest} hostingV1CacheToggleCacheRequest
|
|
11269
11190
|
* @param {*} [options] Override http request option.
|
|
11270
11191
|
* @throws {RequiredError}
|
|
11271
11192
|
*/
|
|
11272
|
-
|
|
11273
|
-
return localVarFp.
|
|
11274
|
-
},
|
|
11275
|
-
/**
|
|
11276
|
-
* Turns on server-side caching for the website for better performance. Use it for faster page loads, reduced server load, or improved user experience. Recommended for production websites. Does nothing if caching is already enabled.
|
|
11277
|
-
* @summary Enable website cache
|
|
11278
|
-
* @param {string} username
|
|
11279
|
-
* @param {string} domain Domain name
|
|
11280
|
-
* @param {*} [options] Override http request option.
|
|
11281
|
-
* @throws {RequiredError}
|
|
11282
|
-
*/
|
|
11283
|
-
enableWebsiteCacheV1(username: string, domain: string, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
|
|
11284
|
-
return localVarFp.enableWebsiteCacheV1(username, domain, options).then((request) => request(axios, basePath));
|
|
11193
|
+
toggleWebsiteCacheV1(username: string, domain: string, hostingV1CacheToggleCacheRequest: HostingV1CacheToggleCacheRequest, options?: RawAxiosRequestConfig): AxiosPromise<CommonSuccessEmptyResource> {
|
|
11194
|
+
return localVarFp.toggleWebsiteCacheV1(username, domain, hostingV1CacheToggleCacheRequest, options).then((request) => request(axios, basePath));
|
|
11285
11195
|
},
|
|
11286
11196
|
};
|
|
11287
11197
|
};
|
|
@@ -11308,55 +11218,31 @@ export class HostingCacheApi extends BaseAPI {
|
|
|
11308
11218
|
}
|
|
11309
11219
|
|
|
11310
11220
|
/**
|
|
11311
|
-
* Turns
|
|
11312
|
-
* @summary
|
|
11313
|
-
* @param {string} username
|
|
11314
|
-
* @param {string} domain Domain name
|
|
11315
|
-
* @param {*} [options] Override http request option.
|
|
11316
|
-
* @throws {RequiredError}
|
|
11317
|
-
* @memberof HostingCacheApi
|
|
11318
|
-
*/
|
|
11319
|
-
public disableCachelessModeV1(username: string, domain: string, options?: RawAxiosRequestConfig) {
|
|
11320
|
-
return HostingCacheApiFp(this.configuration).disableCachelessModeV1(username, domain, options).then((request) => request(this.axios, this.basePath));
|
|
11321
|
-
}
|
|
11322
|
-
|
|
11323
|
-
/**
|
|
11324
|
-
* Turns off server-side caching for the website until it is enabled again. May impact performance. Use it when experiencing cache-related issues; to temporarily bypass caching while developing or debugging, prefer enabling cacheless mode instead. Does nothing if caching is already disabled.
|
|
11325
|
-
* @summary Disable website cache
|
|
11326
|
-
* @param {string} username
|
|
11327
|
-
* @param {string} domain Domain name
|
|
11328
|
-
* @param {*} [options] Override http request option.
|
|
11329
|
-
* @throws {RequiredError}
|
|
11330
|
-
* @memberof HostingCacheApi
|
|
11331
|
-
*/
|
|
11332
|
-
public disableWebsiteCacheV1(username: string, domain: string, options?: RawAxiosRequestConfig) {
|
|
11333
|
-
return HostingCacheApiFp(this.configuration).disableWebsiteCacheV1(username, domain, options).then((request) => request(this.axios, this.basePath));
|
|
11334
|
-
}
|
|
11335
|
-
|
|
11336
|
-
/**
|
|
11337
|
-
* Enables development (cacheless) mode where nothing is cached, effectively turning off all caching for the website. Use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable cacheless mode afterwards to restore normal caching.
|
|
11338
|
-
* @summary Enable cacheless mode
|
|
11221
|
+
* Turns development (cacheless) mode on or off, based on the enabled flag. When enabled, nothing is cached, effectively turning off all caching for the website; use it while actively developing, testing changes, debugging issues, or when real-time updates must be visible. Disable it after finishing development work to restore the performance benefits of caching.
|
|
11222
|
+
* @summary Toggle cacheless mode
|
|
11339
11223
|
* @param {string} username
|
|
11340
11224
|
* @param {string} domain Domain name
|
|
11225
|
+
* @param {HostingV1CacheToggleCachelessModeRequest} hostingV1CacheToggleCachelessModeRequest
|
|
11341
11226
|
* @param {*} [options] Override http request option.
|
|
11342
11227
|
* @throws {RequiredError}
|
|
11343
11228
|
* @memberof HostingCacheApi
|
|
11344
11229
|
*/
|
|
11345
|
-
public
|
|
11346
|
-
return HostingCacheApiFp(this.configuration).
|
|
11230
|
+
public toggleCachelessModeV1(username: string, domain: string, hostingV1CacheToggleCachelessModeRequest: HostingV1CacheToggleCachelessModeRequest, options?: RawAxiosRequestConfig) {
|
|
11231
|
+
return HostingCacheApiFp(this.configuration).toggleCachelessModeV1(username, domain, hostingV1CacheToggleCachelessModeRequest, options).then((request) => request(this.axios, this.basePath));
|
|
11347
11232
|
}
|
|
11348
11233
|
|
|
11349
11234
|
/**
|
|
11350
|
-
* Turns
|
|
11351
|
-
* @summary
|
|
11235
|
+
* Turns server-side caching for the website on or off, based on the enabled flag. Enable it for faster page loads, reduced server load, and improved user experience; recommended for production websites. Disabling may impact performance; to temporarily bypass caching while developing or debugging, prefer toggling cacheless mode instead. Does nothing if caching is already in the requested state.
|
|
11236
|
+
* @summary Toggle website cache
|
|
11352
11237
|
* @param {string} username
|
|
11353
11238
|
* @param {string} domain Domain name
|
|
11239
|
+
* @param {HostingV1CacheToggleCacheRequest} hostingV1CacheToggleCacheRequest
|
|
11354
11240
|
* @param {*} [options] Override http request option.
|
|
11355
11241
|
* @throws {RequiredError}
|
|
11356
11242
|
* @memberof HostingCacheApi
|
|
11357
11243
|
*/
|
|
11358
|
-
public
|
|
11359
|
-
return HostingCacheApiFp(this.configuration).
|
|
11244
|
+
public toggleWebsiteCacheV1(username: string, domain: string, hostingV1CacheToggleCacheRequest: HostingV1CacheToggleCacheRequest, options?: RawAxiosRequestConfig) {
|
|
11245
|
+
return HostingCacheApiFp(this.configuration).toggleWebsiteCacheV1(username, domain, hostingV1CacheToggleCacheRequest, options).then((request) => request(this.axios, this.basePath));
|
|
11360
11246
|
}
|
|
11361
11247
|
}
|
|
11362
11248
|
|
package/base.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.5.
|
|
6
|
+
* API Version: 1.5.1
|
|
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.5.
|
|
6
|
+
* API Version: 1.5.1
|
|
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.5.
|
|
6
|
+
* API Version: 1.5.1
|
|
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.5.
|
|
51
|
+
'User-Agent': "hostinger-typescript-sdk/1.5.1",
|
|
52
52
|
...param.baseOptions?.headers,
|
|
53
53
|
},
|
|
54
54
|
};
|