hostinger-api-sdk 1.35.0 → 1.37.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 +2 -2
- package/api.ts +402 -1
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +2 -2
- package/dist/api.d.ts +303 -1
- package/dist/api.js +216 -9
- 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 +303 -1
- package/dist/esm/api.js +204 -1
- 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/AgencyHostingMetricsApi.md +123 -0
- package/docs/AgencyHostingV1OrdersDiskUsageMetricsLimitsResource.md +22 -0
- package/docs/AgencyHostingV1OrdersDiskUsageMetricsMetricResource.md +24 -0
- package/docs/AgencyHostingV1OrdersDiskUsageMetricsMetricsResource.md +22 -0
- package/docs/AgencyHostingV1OrdersResourceUsageMetricsLimitsResource.md +24 -0
- package/docs/AgencyHostingV1OrdersResourceUsageMetricsMetricResource.md +26 -0
- package/docs/AgencyHostingV1OrdersResourceUsageMetricsMetricsResource.md +24 -0
- package/docs/AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource.md +24 -0
- package/docs/HostingV1DatabasesDatabaseResource.md +4 -0
- package/index.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
## hostinger-api-sdk@1.
|
|
1
|
+
## hostinger-api-sdk@1.37.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-api-sdk@1.
|
|
8
|
+
npm install hostinger-api-sdk@1.37.0 --save
|
|
9
9
|
```
|
package/api.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.39.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
|
|
@@ -260,6 +260,69 @@ export interface AgencyHostingV1OrdersDatacenterResource {
|
|
|
260
260
|
*/
|
|
261
261
|
'country': string;
|
|
262
262
|
}
|
|
263
|
+
/**
|
|
264
|
+
*
|
|
265
|
+
* @export
|
|
266
|
+
* @interface AgencyHostingV1OrdersDiskUsageMetricsLimitsResource
|
|
267
|
+
*/
|
|
268
|
+
export interface AgencyHostingV1OrdersDiskUsageMetricsLimitsResource {
|
|
269
|
+
/**
|
|
270
|
+
* Disk usage quota in bytes
|
|
271
|
+
* @type {number}
|
|
272
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsLimitsResource
|
|
273
|
+
*/
|
|
274
|
+
'disk_bytes': number;
|
|
275
|
+
/**
|
|
276
|
+
* Inodes quota
|
|
277
|
+
* @type {number}
|
|
278
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsLimitsResource
|
|
279
|
+
*/
|
|
280
|
+
'inodes': number;
|
|
281
|
+
}
|
|
282
|
+
/**
|
|
283
|
+
*
|
|
284
|
+
* @export
|
|
285
|
+
* @interface AgencyHostingV1OrdersDiskUsageMetricsMetricResource
|
|
286
|
+
*/
|
|
287
|
+
export interface AgencyHostingV1OrdersDiskUsageMetricsMetricResource {
|
|
288
|
+
/**
|
|
289
|
+
* Disk usage in bytes at this sample
|
|
290
|
+
* @type {number}
|
|
291
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsMetricResource
|
|
292
|
+
*/
|
|
293
|
+
'disk_bytes': number;
|
|
294
|
+
/**
|
|
295
|
+
* Number of inodes used at this sample
|
|
296
|
+
* @type {number}
|
|
297
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsMetricResource
|
|
298
|
+
*/
|
|
299
|
+
'inodes': number;
|
|
300
|
+
/**
|
|
301
|
+
* Unix timestamp of the sample
|
|
302
|
+
* @type {number}
|
|
303
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsMetricResource
|
|
304
|
+
*/
|
|
305
|
+
'timestamp': number;
|
|
306
|
+
}
|
|
307
|
+
/**
|
|
308
|
+
*
|
|
309
|
+
* @export
|
|
310
|
+
* @interface AgencyHostingV1OrdersDiskUsageMetricsMetricsResource
|
|
311
|
+
*/
|
|
312
|
+
export interface AgencyHostingV1OrdersDiskUsageMetricsMetricsResource {
|
|
313
|
+
/**
|
|
314
|
+
*
|
|
315
|
+
* @type {AgencyHostingV1OrdersDiskUsageMetricsLimitsResource}
|
|
316
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsMetricsResource
|
|
317
|
+
*/
|
|
318
|
+
'limits': AgencyHostingV1OrdersDiskUsageMetricsLimitsResource;
|
|
319
|
+
/**
|
|
320
|
+
* Array of [`AgencyHosting.V1.Orders.DiskUsageMetrics.MetricResource`](#model/agencyhostingv1ordersdiskusagemetricsmetricresource)
|
|
321
|
+
* @type {Array<AgencyHostingV1OrdersDiskUsageMetricsMetricResource>}
|
|
322
|
+
* @memberof AgencyHostingV1OrdersDiskUsageMetricsMetricsResource
|
|
323
|
+
*/
|
|
324
|
+
'metrics': Array<AgencyHostingV1OrdersDiskUsageMetricsMetricResource>;
|
|
325
|
+
}
|
|
263
326
|
/**
|
|
264
327
|
*
|
|
265
328
|
* @export
|
|
@@ -322,6 +385,112 @@ export interface AgencyHostingV1OrdersPlanResource {
|
|
|
322
385
|
*/
|
|
323
386
|
'key': string | null;
|
|
324
387
|
}
|
|
388
|
+
/**
|
|
389
|
+
*
|
|
390
|
+
* @export
|
|
391
|
+
* @interface AgencyHostingV1OrdersResourceUsageMetricsLimitsResource
|
|
392
|
+
*/
|
|
393
|
+
export interface AgencyHostingV1OrdersResourceUsageMetricsLimitsResource {
|
|
394
|
+
/**
|
|
395
|
+
* Memory usage quota in bytes
|
|
396
|
+
* @type {number}
|
|
397
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsLimitsResource
|
|
398
|
+
*/
|
|
399
|
+
'memory_bytes': number;
|
|
400
|
+
/**
|
|
401
|
+
* CPU usage quota in percent
|
|
402
|
+
* @type {number}
|
|
403
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsLimitsResource
|
|
404
|
+
*/
|
|
405
|
+
'cpu_percent': number;
|
|
406
|
+
/**
|
|
407
|
+
* Process usage quota
|
|
408
|
+
* @type {number}
|
|
409
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsLimitsResource
|
|
410
|
+
*/
|
|
411
|
+
'processes': number;
|
|
412
|
+
}
|
|
413
|
+
/**
|
|
414
|
+
*
|
|
415
|
+
* @export
|
|
416
|
+
* @interface AgencyHostingV1OrdersResourceUsageMetricsMetricResource
|
|
417
|
+
*/
|
|
418
|
+
export interface AgencyHostingV1OrdersResourceUsageMetricsMetricResource {
|
|
419
|
+
/**
|
|
420
|
+
* CPU usage percentage at this sample
|
|
421
|
+
* @type {number}
|
|
422
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricResource
|
|
423
|
+
*/
|
|
424
|
+
'cpu_percent': number;
|
|
425
|
+
/**
|
|
426
|
+
* Memory usage in bytes at this sample
|
|
427
|
+
* @type {number}
|
|
428
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricResource
|
|
429
|
+
*/
|
|
430
|
+
'memory_bytes': number;
|
|
431
|
+
/**
|
|
432
|
+
* Number of processes at this sample
|
|
433
|
+
* @type {number}
|
|
434
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricResource
|
|
435
|
+
*/
|
|
436
|
+
'processes': number;
|
|
437
|
+
/**
|
|
438
|
+
* Unix timestamp of the sample
|
|
439
|
+
* @type {number}
|
|
440
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricResource
|
|
441
|
+
*/
|
|
442
|
+
'timestamp': number;
|
|
443
|
+
}
|
|
444
|
+
/**
|
|
445
|
+
*
|
|
446
|
+
* @export
|
|
447
|
+
* @interface AgencyHostingV1OrdersResourceUsageMetricsMetricsResource
|
|
448
|
+
*/
|
|
449
|
+
export interface AgencyHostingV1OrdersResourceUsageMetricsMetricsResource {
|
|
450
|
+
/**
|
|
451
|
+
*
|
|
452
|
+
* @type {AgencyHostingV1OrdersResourceUsageMetricsLimitsResource}
|
|
453
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricsResource
|
|
454
|
+
*/
|
|
455
|
+
'limits': AgencyHostingV1OrdersResourceUsageMetricsLimitsResource;
|
|
456
|
+
/**
|
|
457
|
+
* Array of [`AgencyHosting.V1.Orders.ResourceUsageMetrics.MetricResource`](#model/agencyhostingv1ordersresourceusagemetricsmetricresource)
|
|
458
|
+
* @type {Array<AgencyHostingV1OrdersResourceUsageMetricsMetricResource>}
|
|
459
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricsResource
|
|
460
|
+
*/
|
|
461
|
+
'metrics': Array<AgencyHostingV1OrdersResourceUsageMetricsMetricResource>;
|
|
462
|
+
/**
|
|
463
|
+
* Array of [`AgencyHosting.V1.Orders.ResourceUsageMetrics.WebsiteResource`](#model/agencyhostingv1ordersresourceusagemetricswebsiteresource)
|
|
464
|
+
* @type {Array<AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource>}
|
|
465
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsMetricsResource
|
|
466
|
+
*/
|
|
467
|
+
'websites': Array<AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource>;
|
|
468
|
+
}
|
|
469
|
+
/**
|
|
470
|
+
*
|
|
471
|
+
* @export
|
|
472
|
+
* @interface AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource
|
|
473
|
+
*/
|
|
474
|
+
export interface AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource {
|
|
475
|
+
/**
|
|
476
|
+
* Website UID
|
|
477
|
+
* @type {string}
|
|
478
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource
|
|
479
|
+
*/
|
|
480
|
+
'uid': string;
|
|
481
|
+
/**
|
|
482
|
+
* Domains associated with the website
|
|
483
|
+
* @type {Array<string>}
|
|
484
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource
|
|
485
|
+
*/
|
|
486
|
+
'domains': Array<string>;
|
|
487
|
+
/**
|
|
488
|
+
* Array of [`AgencyHosting.V1.Orders.ResourceUsageMetrics.MetricResource`](#model/agencyhostingv1ordersresourceusagemetricsmetricresource)
|
|
489
|
+
* @type {Array<AgencyHostingV1OrdersResourceUsageMetricsMetricResource>}
|
|
490
|
+
* @memberof AgencyHostingV1OrdersResourceUsageMetricsWebsiteResource
|
|
491
|
+
*/
|
|
492
|
+
'metrics': Array<AgencyHostingV1OrdersResourceUsageMetricsMetricResource>;
|
|
493
|
+
}
|
|
325
494
|
/**
|
|
326
495
|
*
|
|
327
496
|
* @export
|
|
@@ -4731,6 +4900,18 @@ export interface HostingV1DatabasesDatabaseResource {
|
|
|
4731
4900
|
* @memberof HostingV1DatabasesDatabaseResource
|
|
4732
4901
|
*/
|
|
4733
4902
|
'max_size_mb': number;
|
|
4903
|
+
/**
|
|
4904
|
+
* MySQL hostname for remote connections. Same value as hPanel Remote MySQL. Identical for every database on this account. Not the database user grant host.
|
|
4905
|
+
* @type {string}
|
|
4906
|
+
* @memberof HostingV1DatabasesDatabaseResource
|
|
4907
|
+
*/
|
|
4908
|
+
'host': string;
|
|
4909
|
+
/**
|
|
4910
|
+
* MySQL port for remote connections. Always 3306.
|
|
4911
|
+
* @type {number}
|
|
4912
|
+
* @memberof HostingV1DatabasesDatabaseResource
|
|
4913
|
+
*/
|
|
4914
|
+
'port': number;
|
|
4734
4915
|
}
|
|
4735
4916
|
/**
|
|
4736
4917
|
*
|
|
@@ -14546,6 +14727,226 @@ export class AgencyHostingFilesApi extends BaseAPI {
|
|
|
14546
14727
|
|
|
14547
14728
|
|
|
14548
14729
|
|
|
14730
|
+
/**
|
|
14731
|
+
* AgencyHostingMetricsApi - axios parameter creator
|
|
14732
|
+
* @export
|
|
14733
|
+
*/
|
|
14734
|
+
export const AgencyHostingMetricsApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
14735
|
+
return {
|
|
14736
|
+
/**
|
|
14737
|
+
* Returns aggregated disk and inode usage for the Agency Plan order over the selected time frame, plus the plan quotas. Figures cover the whole order account. Values may be up to one hour stale. CPU, memory, and process usage are on the resource-usage-metrics endpoint.
|
|
14738
|
+
* @summary List Agency Plan order disk usage metrics
|
|
14739
|
+
* @param {number} orderId Agency Plan order ID
|
|
14740
|
+
* @param {ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum} [timeFrameDays] Length of the window in days, ending now. Bucket size grows with the window.
|
|
14741
|
+
* @param {*} [options] Override http request option.
|
|
14742
|
+
* @throws {RequiredError}
|
|
14743
|
+
*/
|
|
14744
|
+
listAgencyPlanOrderDiskUsageMetricsV1: async (orderId: number, timeFrameDays?: ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
14745
|
+
// verify required parameter 'orderId' is not null or undefined
|
|
14746
|
+
assertParamExists('listAgencyPlanOrderDiskUsageMetricsV1', 'orderId', orderId)
|
|
14747
|
+
const localVarPath = `/api/agency-hosting/v1/orders/{order_id}/disk-usage-metrics`
|
|
14748
|
+
.replace(`{${"order_id"}}`, encodeURIComponent(String(orderId)));
|
|
14749
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
14750
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
14751
|
+
let baseOptions;
|
|
14752
|
+
if (configuration) {
|
|
14753
|
+
baseOptions = configuration.baseOptions;
|
|
14754
|
+
}
|
|
14755
|
+
|
|
14756
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
14757
|
+
const localVarHeaderParameter = {} as any;
|
|
14758
|
+
const localVarQueryParameter = {} as any;
|
|
14759
|
+
|
|
14760
|
+
// authentication apiToken required
|
|
14761
|
+
// http bearer authentication required
|
|
14762
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
14763
|
+
|
|
14764
|
+
if (timeFrameDays !== undefined) {
|
|
14765
|
+
localVarQueryParameter['time_frame_days'] = timeFrameDays;
|
|
14766
|
+
}
|
|
14767
|
+
|
|
14768
|
+
|
|
14769
|
+
|
|
14770
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
14771
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
14772
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
14773
|
+
|
|
14774
|
+
return {
|
|
14775
|
+
url: toPathString(localVarUrlObj),
|
|
14776
|
+
options: localVarRequestOptions,
|
|
14777
|
+
};
|
|
14778
|
+
},
|
|
14779
|
+
/**
|
|
14780
|
+
* Returns aggregated CPU, memory, and process usage for the Agency Plan order over the selected time frame, plus the plan quotas and a per-website breakdown. Each website is identified by uid. Suspended and deleted websites are excluded from both the order totals and the per-website breakdown. Values may be up to one hour stale. Disk and inode usage are on the disk-usage-metrics endpoint.
|
|
14781
|
+
* @summary List order resource usage metrics
|
|
14782
|
+
* @param {number} orderId Agency Plan order ID
|
|
14783
|
+
* @param {ListOrderResourceUsageMetricsV1TimeFrameHoursEnum} [timeFrameHours] Length of the window in hours, ending now. Bucket size grows with the window.
|
|
14784
|
+
* @param {*} [options] Override http request option.
|
|
14785
|
+
* @throws {RequiredError}
|
|
14786
|
+
*/
|
|
14787
|
+
listOrderResourceUsageMetricsV1: async (orderId: number, timeFrameHours?: ListOrderResourceUsageMetricsV1TimeFrameHoursEnum, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
14788
|
+
// verify required parameter 'orderId' is not null or undefined
|
|
14789
|
+
assertParamExists('listOrderResourceUsageMetricsV1', 'orderId', orderId)
|
|
14790
|
+
const localVarPath = `/api/agency-hosting/v1/orders/{order_id}/resource-usage-metrics`
|
|
14791
|
+
.replace(`{${"order_id"}}`, encodeURIComponent(String(orderId)));
|
|
14792
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
14793
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
14794
|
+
let baseOptions;
|
|
14795
|
+
if (configuration) {
|
|
14796
|
+
baseOptions = configuration.baseOptions;
|
|
14797
|
+
}
|
|
14798
|
+
|
|
14799
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
14800
|
+
const localVarHeaderParameter = {} as any;
|
|
14801
|
+
const localVarQueryParameter = {} as any;
|
|
14802
|
+
|
|
14803
|
+
// authentication apiToken required
|
|
14804
|
+
// http bearer authentication required
|
|
14805
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
14806
|
+
|
|
14807
|
+
if (timeFrameHours !== undefined) {
|
|
14808
|
+
localVarQueryParameter['time_frame_hours'] = timeFrameHours;
|
|
14809
|
+
}
|
|
14810
|
+
|
|
14811
|
+
|
|
14812
|
+
|
|
14813
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
14814
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
14815
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
14816
|
+
|
|
14817
|
+
return {
|
|
14818
|
+
url: toPathString(localVarUrlObj),
|
|
14819
|
+
options: localVarRequestOptions,
|
|
14820
|
+
};
|
|
14821
|
+
},
|
|
14822
|
+
}
|
|
14823
|
+
};
|
|
14824
|
+
|
|
14825
|
+
/**
|
|
14826
|
+
* AgencyHostingMetricsApi - functional programming interface
|
|
14827
|
+
* @export
|
|
14828
|
+
*/
|
|
14829
|
+
export const AgencyHostingMetricsApiFp = function(configuration?: Configuration) {
|
|
14830
|
+
const localVarAxiosParamCreator = AgencyHostingMetricsApiAxiosParamCreator(configuration)
|
|
14831
|
+
return {
|
|
14832
|
+
/**
|
|
14833
|
+
* Returns aggregated disk and inode usage for the Agency Plan order over the selected time frame, plus the plan quotas. Figures cover the whole order account. Values may be up to one hour stale. CPU, memory, and process usage are on the resource-usage-metrics endpoint.
|
|
14834
|
+
* @summary List Agency Plan order disk usage metrics
|
|
14835
|
+
* @param {number} orderId Agency Plan order ID
|
|
14836
|
+
* @param {ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum} [timeFrameDays] Length of the window in days, ending now. Bucket size grows with the window.
|
|
14837
|
+
* @param {*} [options] Override http request option.
|
|
14838
|
+
* @throws {RequiredError}
|
|
14839
|
+
*/
|
|
14840
|
+
async listAgencyPlanOrderDiskUsageMetricsV1(orderId: number, timeFrameDays?: ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgencyHostingV1OrdersDiskUsageMetricsMetricsResource>> {
|
|
14841
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.listAgencyPlanOrderDiskUsageMetricsV1(orderId, timeFrameDays, options);
|
|
14842
|
+
const localVarOperationServerBasePath = operationServerMap['AgencyHostingMetricsApi.listAgencyPlanOrderDiskUsageMetricsV1']?.[0]?.url;
|
|
14843
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
14844
|
+
},
|
|
14845
|
+
/**
|
|
14846
|
+
* Returns aggregated CPU, memory, and process usage for the Agency Plan order over the selected time frame, plus the plan quotas and a per-website breakdown. Each website is identified by uid. Suspended and deleted websites are excluded from both the order totals and the per-website breakdown. Values may be up to one hour stale. Disk and inode usage are on the disk-usage-metrics endpoint.
|
|
14847
|
+
* @summary List order resource usage metrics
|
|
14848
|
+
* @param {number} orderId Agency Plan order ID
|
|
14849
|
+
* @param {ListOrderResourceUsageMetricsV1TimeFrameHoursEnum} [timeFrameHours] Length of the window in hours, ending now. Bucket size grows with the window.
|
|
14850
|
+
* @param {*} [options] Override http request option.
|
|
14851
|
+
* @throws {RequiredError}
|
|
14852
|
+
*/
|
|
14853
|
+
async listOrderResourceUsageMetricsV1(orderId: number, timeFrameHours?: ListOrderResourceUsageMetricsV1TimeFrameHoursEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgencyHostingV1OrdersResourceUsageMetricsMetricsResource>> {
|
|
14854
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.listOrderResourceUsageMetricsV1(orderId, timeFrameHours, options);
|
|
14855
|
+
const localVarOperationServerBasePath = operationServerMap['AgencyHostingMetricsApi.listOrderResourceUsageMetricsV1']?.[0]?.url;
|
|
14856
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
14857
|
+
},
|
|
14858
|
+
}
|
|
14859
|
+
};
|
|
14860
|
+
|
|
14861
|
+
/**
|
|
14862
|
+
* AgencyHostingMetricsApi - factory interface
|
|
14863
|
+
* @export
|
|
14864
|
+
*/
|
|
14865
|
+
export const AgencyHostingMetricsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
14866
|
+
const localVarFp = AgencyHostingMetricsApiFp(configuration)
|
|
14867
|
+
return {
|
|
14868
|
+
/**
|
|
14869
|
+
* Returns aggregated disk and inode usage for the Agency Plan order over the selected time frame, plus the plan quotas. Figures cover the whole order account. Values may be up to one hour stale. CPU, memory, and process usage are on the resource-usage-metrics endpoint.
|
|
14870
|
+
* @summary List Agency Plan order disk usage metrics
|
|
14871
|
+
* @param {number} orderId Agency Plan order ID
|
|
14872
|
+
* @param {ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum} [timeFrameDays] Length of the window in days, ending now. Bucket size grows with the window.
|
|
14873
|
+
* @param {*} [options] Override http request option.
|
|
14874
|
+
* @throws {RequiredError}
|
|
14875
|
+
*/
|
|
14876
|
+
listAgencyPlanOrderDiskUsageMetricsV1(orderId: number, timeFrameDays?: ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum, options?: RawAxiosRequestConfig): AxiosPromise<AgencyHostingV1OrdersDiskUsageMetricsMetricsResource> {
|
|
14877
|
+
return localVarFp.listAgencyPlanOrderDiskUsageMetricsV1(orderId, timeFrameDays, options).then((request) => request(axios, basePath));
|
|
14878
|
+
},
|
|
14879
|
+
/**
|
|
14880
|
+
* Returns aggregated CPU, memory, and process usage for the Agency Plan order over the selected time frame, plus the plan quotas and a per-website breakdown. Each website is identified by uid. Suspended and deleted websites are excluded from both the order totals and the per-website breakdown. Values may be up to one hour stale. Disk and inode usage are on the disk-usage-metrics endpoint.
|
|
14881
|
+
* @summary List order resource usage metrics
|
|
14882
|
+
* @param {number} orderId Agency Plan order ID
|
|
14883
|
+
* @param {ListOrderResourceUsageMetricsV1TimeFrameHoursEnum} [timeFrameHours] Length of the window in hours, ending now. Bucket size grows with the window.
|
|
14884
|
+
* @param {*} [options] Override http request option.
|
|
14885
|
+
* @throws {RequiredError}
|
|
14886
|
+
*/
|
|
14887
|
+
listOrderResourceUsageMetricsV1(orderId: number, timeFrameHours?: ListOrderResourceUsageMetricsV1TimeFrameHoursEnum, options?: RawAxiosRequestConfig): AxiosPromise<AgencyHostingV1OrdersResourceUsageMetricsMetricsResource> {
|
|
14888
|
+
return localVarFp.listOrderResourceUsageMetricsV1(orderId, timeFrameHours, options).then((request) => request(axios, basePath));
|
|
14889
|
+
},
|
|
14890
|
+
};
|
|
14891
|
+
};
|
|
14892
|
+
|
|
14893
|
+
/**
|
|
14894
|
+
* AgencyHostingMetricsApi - object-oriented interface
|
|
14895
|
+
* @export
|
|
14896
|
+
* @class AgencyHostingMetricsApi
|
|
14897
|
+
* @extends {BaseAPI}
|
|
14898
|
+
*/
|
|
14899
|
+
export class AgencyHostingMetricsApi extends BaseAPI {
|
|
14900
|
+
/**
|
|
14901
|
+
* Returns aggregated disk and inode usage for the Agency Plan order over the selected time frame, plus the plan quotas. Figures cover the whole order account. Values may be up to one hour stale. CPU, memory, and process usage are on the resource-usage-metrics endpoint.
|
|
14902
|
+
* @summary List Agency Plan order disk usage metrics
|
|
14903
|
+
* @param {number} orderId Agency Plan order ID
|
|
14904
|
+
* @param {ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum} [timeFrameDays] Length of the window in days, ending now. Bucket size grows with the window.
|
|
14905
|
+
* @param {*} [options] Override http request option.
|
|
14906
|
+
* @throws {RequiredError}
|
|
14907
|
+
* @memberof AgencyHostingMetricsApi
|
|
14908
|
+
*/
|
|
14909
|
+
public listAgencyPlanOrderDiskUsageMetricsV1(orderId: number, timeFrameDays?: ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum, options?: RawAxiosRequestConfig) {
|
|
14910
|
+
return AgencyHostingMetricsApiFp(this.configuration).listAgencyPlanOrderDiskUsageMetricsV1(orderId, timeFrameDays, options).then((request) => request(this.axios, this.basePath));
|
|
14911
|
+
}
|
|
14912
|
+
|
|
14913
|
+
/**
|
|
14914
|
+
* Returns aggregated CPU, memory, and process usage for the Agency Plan order over the selected time frame, plus the plan quotas and a per-website breakdown. Each website is identified by uid. Suspended and deleted websites are excluded from both the order totals and the per-website breakdown. Values may be up to one hour stale. Disk and inode usage are on the disk-usage-metrics endpoint.
|
|
14915
|
+
* @summary List order resource usage metrics
|
|
14916
|
+
* @param {number} orderId Agency Plan order ID
|
|
14917
|
+
* @param {ListOrderResourceUsageMetricsV1TimeFrameHoursEnum} [timeFrameHours] Length of the window in hours, ending now. Bucket size grows with the window.
|
|
14918
|
+
* @param {*} [options] Override http request option.
|
|
14919
|
+
* @throws {RequiredError}
|
|
14920
|
+
* @memberof AgencyHostingMetricsApi
|
|
14921
|
+
*/
|
|
14922
|
+
public listOrderResourceUsageMetricsV1(orderId: number, timeFrameHours?: ListOrderResourceUsageMetricsV1TimeFrameHoursEnum, options?: RawAxiosRequestConfig) {
|
|
14923
|
+
return AgencyHostingMetricsApiFp(this.configuration).listOrderResourceUsageMetricsV1(orderId, timeFrameHours, options).then((request) => request(this.axios, this.basePath));
|
|
14924
|
+
}
|
|
14925
|
+
}
|
|
14926
|
+
|
|
14927
|
+
/**
|
|
14928
|
+
* @export
|
|
14929
|
+
*/
|
|
14930
|
+
export const ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum = {
|
|
14931
|
+
NUMBER_1: 1,
|
|
14932
|
+
NUMBER_7: 7,
|
|
14933
|
+
NUMBER_14: 14,
|
|
14934
|
+
NUMBER_30: 30
|
|
14935
|
+
} as const;
|
|
14936
|
+
export type ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum = typeof ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum[keyof typeof ListAgencyPlanOrderDiskUsageMetricsV1TimeFrameDaysEnum];
|
|
14937
|
+
/**
|
|
14938
|
+
* @export
|
|
14939
|
+
*/
|
|
14940
|
+
export const ListOrderResourceUsageMetricsV1TimeFrameHoursEnum = {
|
|
14941
|
+
NUMBER_1: 1,
|
|
14942
|
+
NUMBER_24: 24,
|
|
14943
|
+
NUMBER_168: 168,
|
|
14944
|
+
NUMBER_336: 336,
|
|
14945
|
+
NUMBER_720: 720
|
|
14946
|
+
} as const;
|
|
14947
|
+
export type ListOrderResourceUsageMetricsV1TimeFrameHoursEnum = typeof ListOrderResourceUsageMetricsV1TimeFrameHoursEnum[keyof typeof ListOrderResourceUsageMetricsV1TimeFrameHoursEnum];
|
|
14948
|
+
|
|
14949
|
+
|
|
14549
14950
|
/**
|
|
14550
14951
|
* AgencyHostingOrdersApi - axios parameter creator
|
|
14551
14952
|
* @export
|
package/base.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.39.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.
|
|
6
|
+
* API Version: 1.39.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.
|
|
6
|
+
* API Version: 1.39.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.
|
|
51
|
+
'User-Agent': "hostinger-typescript-sdk/1.37.0",
|
|
52
52
|
...param.baseOptions?.headers,
|
|
53
53
|
},
|
|
54
54
|
};
|