hostinger-api-sdk 2.16.1 → 3.0.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@2.16.1
1
+ ## @hostinger/sdk@3.0.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@2.16.1 --save
8
+ npm install @hostinger/sdk@3.0.0 --save
9
9
  ```
package/api.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 2.16.1
6
+ * API Version: 3.0.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
@@ -7149,6 +7149,12 @@ export interface GPUV1InstanceInstanceListResource {
7149
7149
  * @memberof GPUV1InstanceInstanceListResource
7150
7150
  */
7151
7151
  'action_lock': GPUV1InstanceInstanceListResourceActionLockEnum;
7152
+ /**
7153
+ * Action in progress on the instance, `null` when unlocked
7154
+ * @type {string}
7155
+ * @memberof GPUV1InstanceInstanceListResource
7156
+ */
7157
+ 'action_lock_reason': GPUV1InstanceInstanceListResourceActionLockReasonEnum | null;
7152
7158
  /**
7153
7159
  *
7154
7160
  * @type {GPUV1PoolPoolResource}
@@ -7188,6 +7194,18 @@ export const GPUV1InstanceInstanceListResourceActionLockEnum = {
7188
7194
  } as const;
7189
7195
 
7190
7196
  export type GPUV1InstanceInstanceListResourceActionLockEnum = typeof GPUV1InstanceInstanceListResourceActionLockEnum[keyof typeof GPUV1InstanceInstanceListResourceActionLockEnum];
7197
+ export const GPUV1InstanceInstanceListResourceActionLockReasonEnum = {
7198
+ Creating: 'creating',
7199
+ Booting: 'booting',
7200
+ InstallingTemplate: 'installing_template',
7201
+ ExposingService: 'exposing_service',
7202
+ ConcealingService: 'concealing_service',
7203
+ Restarting: 'restarting',
7204
+ Destroying: 'destroying',
7205
+ Renaming: 'renaming'
7206
+ } as const;
7207
+
7208
+ export type GPUV1InstanceInstanceListResourceActionLockReasonEnum = typeof GPUV1InstanceInstanceListResourceActionLockReasonEnum[keyof typeof GPUV1InstanceInstanceListResourceActionLockReasonEnum];
7191
7209
 
7192
7210
  /**
7193
7211
  *
@@ -7219,6 +7237,12 @@ export interface GPUV1InstanceInstanceResource {
7219
7237
  * @memberof GPUV1InstanceInstanceResource
7220
7238
  */
7221
7239
  'action_lock': GPUV1InstanceInstanceResourceActionLockEnum;
7240
+ /**
7241
+ * Action in progress on the instance, `null` when unlocked
7242
+ * @type {string}
7243
+ * @memberof GPUV1InstanceInstanceResource
7244
+ */
7245
+ 'action_lock_reason': GPUV1InstanceInstanceResourceActionLockReasonEnum | null;
7222
7246
  /**
7223
7247
  *
7224
7248
  * @type {GPUV1PoolPoolResource}
@@ -7237,6 +7261,12 @@ export interface GPUV1InstanceInstanceResource {
7237
7261
  * @memberof GPUV1InstanceInstanceResource
7238
7262
  */
7239
7263
  'os_template': GPUV1OsTemplateOsTemplateResource;
7264
+ /**
7265
+ *
7266
+ * @type {GPUV1LlmModelVariantLlmModelVariantResource}
7267
+ * @memberof GPUV1InstanceInstanceResource
7268
+ */
7269
+ 'llm_model_variant': GPUV1LlmModelVariantLlmModelVariantResource | null;
7240
7270
  /**
7241
7271
  * Array of [`GPU.V1.SshKey.SshKeyResource`](#model/gpuv1sshkeysshkeyresource)
7242
7272
  * @type {Array<GPUV1SshKeySshKeyResource>}
@@ -7264,6 +7294,18 @@ export const GPUV1InstanceInstanceResourceActionLockEnum = {
7264
7294
  } as const;
7265
7295
 
7266
7296
  export type GPUV1InstanceInstanceResourceActionLockEnum = typeof GPUV1InstanceInstanceResourceActionLockEnum[keyof typeof GPUV1InstanceInstanceResourceActionLockEnum];
7297
+ export const GPUV1InstanceInstanceResourceActionLockReasonEnum = {
7298
+ Creating: 'creating',
7299
+ Booting: 'booting',
7300
+ InstallingTemplate: 'installing_template',
7301
+ ExposingService: 'exposing_service',
7302
+ ConcealingService: 'concealing_service',
7303
+ Restarting: 'restarting',
7304
+ Destroying: 'destroying',
7305
+ Renaming: 'renaming'
7306
+ } as const;
7307
+
7308
+ export type GPUV1InstanceInstanceResourceActionLockReasonEnum = typeof GPUV1InstanceInstanceResourceActionLockReasonEnum[keyof typeof GPUV1InstanceInstanceResourceActionLockReasonEnum];
7267
7309
 
7268
7310
  /**
7269
7311
  *
@@ -7296,6 +7338,61 @@ export interface GPUV1InstanceStoreRequest {
7296
7338
  */
7297
7339
  'public_keys': Array<string>;
7298
7340
  }
7341
+ /**
7342
+ *
7343
+ * @export
7344
+ * @interface GPUV1LlmModelVariantLlmModelVariantResource
7345
+ */
7346
+ export interface GPUV1LlmModelVariantLlmModelVariantResource {
7347
+ /**
7348
+ * LLM model variant ID
7349
+ * @type {number}
7350
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7351
+ */
7352
+ 'id': number;
7353
+ /**
7354
+ *
7355
+ * @type {string}
7356
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7357
+ */
7358
+ 'model_tag': string;
7359
+ /**
7360
+ *
7361
+ * @type {number}
7362
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7363
+ */
7364
+ 'parameter_count': number;
7365
+ /**
7366
+ *
7367
+ * @type {Array<string>}
7368
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7369
+ */
7370
+ 'capabilities': Array<GPUV1LlmModelVariantLlmModelVariantResourceCapabilitiesEnum>;
7371
+ /**
7372
+ * Dark theme icon image ID
7373
+ * @type {string}
7374
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7375
+ */
7376
+ 'dark_image_id': string | null;
7377
+ /**
7378
+ * Light theme icon image ID
7379
+ * @type {string}
7380
+ * @memberof GPUV1LlmModelVariantLlmModelVariantResource
7381
+ */
7382
+ 'light_image_id': string | null;
7383
+ }
7384
+
7385
+ export const GPUV1LlmModelVariantLlmModelVariantResourceCapabilitiesEnum = {
7386
+ Tools: 'tools',
7387
+ Thinking: 'thinking',
7388
+ Vision: 'vision',
7389
+ Sound: 'sound',
7390
+ Embedding: 'embedding',
7391
+ Decision: 'decision'
7392
+ } as const;
7393
+
7394
+ export type GPUV1LlmModelVariantLlmModelVariantResourceCapabilitiesEnum = typeof GPUV1LlmModelVariantLlmModelVariantResourceCapabilitiesEnum[keyof typeof GPUV1LlmModelVariantLlmModelVariantResourceCapabilitiesEnum];
7395
+
7299
7396
  /**
7300
7397
  *
7301
7398
  * @export
@@ -7363,12 +7460,6 @@ export interface GPUV1OsTemplateOsTemplateResource {
7363
7460
  * @memberof GPUV1OsTemplateOsTemplateResource
7364
7461
  */
7365
7462
  'kb_url': string;
7366
- /**
7367
- * Icon image ID
7368
- * @type {string}
7369
- * @memberof GPUV1OsTemplateOsTemplateResource
7370
- */
7371
- 'image': string | null;
7372
7463
  /**
7373
7464
  * Dark theme icon image ID
7374
7465
  * @type {string}
@@ -7400,6 +7491,18 @@ export interface GPUV1PoolPoolGroupResource {
7400
7491
  * @memberof GPUV1PoolPoolGroupResource
7401
7492
  */
7402
7493
  'name': string;
7494
+ /**
7495
+ *
7496
+ * @type {string}
7497
+ * @memberof GPUV1PoolPoolGroupResource
7498
+ */
7499
+ 'description': string | null;
7500
+ /**
7501
+ *
7502
+ * @type {string}
7503
+ * @memberof GPUV1PoolPoolGroupResource
7504
+ */
7505
+ 'feature': string | null;
7403
7506
  /**
7404
7507
  * Total VRAM in bytes
7405
7508
  * @type {number}
@@ -7413,7 +7516,7 @@ export interface GPUV1PoolPoolGroupResource {
7413
7516
  */
7414
7517
  'is_available': boolean;
7415
7518
  /**
7416
- * Lowest hourly price of the group instance types, in the requested currency
7519
+ * Lowest hourly price of the group instance types, in credits
7417
7520
  * @type {number}
7418
7521
  * @memberof GPUV1PoolPoolGroupResource
7419
7522
  */
@@ -7468,7 +7571,7 @@ export interface GPUV1PoolPoolInstanceResource {
7468
7571
  */
7469
7572
  'storage': number;
7470
7573
  /**
7471
- * Hourly price in cents (USD)
7574
+ * Hourly price in credits
7472
7575
  * @type {number}
7473
7576
  * @memberof GPUV1PoolPoolInstanceResource
7474
7577
  */
@@ -31930,13 +32033,12 @@ export class EcommerceStoresApi extends BaseAPI {
31930
32033
  export const GPUCatalogApiAxiosParamCreator = function (configuration?: Configuration) {
31931
32034
  return {
31932
32035
  /**
31933
- * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32036
+ * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price, in credits, among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
31934
32037
  * @summary Get pool groups
31935
- * @param {GetPoolGroupsV1CurrencyEnum} [currency] Currency of the returned prices, &#x60;USD&#x60; by default
31936
32038
  * @param {*} [options] Override http request option.
31937
32039
  * @throws {RequiredError}
31938
32040
  */
31939
- getPoolGroupsV1: async (currency?: GetPoolGroupsV1CurrencyEnum, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
32041
+ getPoolGroupsV1: async (options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
31940
32042
  const localVarPath = `/api/gpu/v1/pools/groups`;
31941
32043
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
31942
32044
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
@@ -31953,10 +32055,6 @@ export const GPUCatalogApiAxiosParamCreator = function (configuration?: Configur
31953
32055
  // http bearer authentication required
31954
32056
  await setBearerAuthToObject(localVarHeaderParameter, configuration)
31955
32057
 
31956
- if (currency !== undefined) {
31957
- localVarQueryParameter['currency'] = currency;
31958
- }
31959
-
31960
32058
 
31961
32059
 
31962
32060
  setSearchParams(localVarUrlObj, localVarQueryParameter);
@@ -32093,14 +32191,13 @@ export const GPUCatalogApiFp = function(configuration?: Configuration) {
32093
32191
  const localVarAxiosParamCreator = GPUCatalogApiAxiosParamCreator(configuration)
32094
32192
  return {
32095
32193
  /**
32096
- * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32194
+ * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price, in credits, among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32097
32195
  * @summary Get pool groups
32098
- * @param {GetPoolGroupsV1CurrencyEnum} [currency] Currency of the returned prices, &#x60;USD&#x60; by default
32099
32196
  * @param {*} [options] Override http request option.
32100
32197
  * @throws {RequiredError}
32101
32198
  */
32102
- async getPoolGroupsV1(currency?: GetPoolGroupsV1CurrencyEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<GPUV1PoolPoolGroupResource>>> {
32103
- const localVarAxiosArgs = await localVarAxiosParamCreator.getPoolGroupsV1(currency, options);
32199
+ async getPoolGroupsV1(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<GPUV1PoolPoolGroupResource>>> {
32200
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getPoolGroupsV1(options);
32104
32201
  const localVarOperationServerBasePath = operationServerMap['GPUCatalogApi.getPoolGroupsV1']?.[0]?.url;
32105
32202
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
32106
32203
  },
@@ -32151,14 +32248,13 @@ export const GPUCatalogApiFactory = function (configuration?: Configuration, bas
32151
32248
  const localVarFp = GPUCatalogApiFp(configuration)
32152
32249
  return {
32153
32250
  /**
32154
- * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32251
+ * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price, in credits, among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32155
32252
  * @summary Get pool groups
32156
- * @param {GetPoolGroupsV1CurrencyEnum} [currency] Currency of the returned prices, &#x60;USD&#x60; by default
32157
32253
  * @param {*} [options] Override http request option.
32158
32254
  * @throws {RequiredError}
32159
32255
  */
32160
- getPoolGroupsV1(currency?: GetPoolGroupsV1CurrencyEnum, options?: RawAxiosRequestConfig): AxiosPromise<Array<GPUV1PoolPoolGroupResource>> {
32161
- return localVarFp.getPoolGroupsV1(currency, options).then((request) => request(axios, basePath));
32256
+ getPoolGroupsV1(options?: RawAxiosRequestConfig): AxiosPromise<Array<GPUV1PoolPoolGroupResource>> {
32257
+ return localVarFp.getPoolGroupsV1(options).then((request) => request(axios, basePath));
32162
32258
  },
32163
32259
  /**
32164
32260
  * Retrieve the instance types offered by a specified GPU pool, ordered by CPU core count. Each instance type describes its CPU, memory and storage, and its hourly price. Only instance types that can currently be ordered are returned. Use this endpoint to choose the `pool_instance_id` for a new GPU instance.
@@ -32201,15 +32297,14 @@ export const GPUCatalogApiFactory = function (configuration?: Configuration, bas
32201
32297
  */
32202
32298
  export class GPUCatalogApi extends BaseAPI {
32203
32299
  /**
32204
- * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32300
+ * Retrieve GPU pool groups, ordered by name. Each group bundles the pools of one GPU model and lists its currently available pools, whether any of them is available and the lowest hourly price, in credits, among its instance types. The price is returned even when the group is out of stock. Use this endpoint to show which GPU models can be ordered and from what price.
32205
32301
  * @summary Get pool groups
32206
- * @param {GetPoolGroupsV1CurrencyEnum} [currency] Currency of the returned prices, &#x60;USD&#x60; by default
32207
32302
  * @param {*} [options] Override http request option.
32208
32303
  * @throws {RequiredError}
32209
32304
  * @memberof GPUCatalogApi
32210
32305
  */
32211
- public getPoolGroupsV1(currency?: GetPoolGroupsV1CurrencyEnum, options?: RawAxiosRequestConfig) {
32212
- return GPUCatalogApiFp(this.configuration).getPoolGroupsV1(currency, options).then((request) => request(this.axios, this.basePath));
32306
+ public getPoolGroupsV1(options?: RawAxiosRequestConfig) {
32307
+ return GPUCatalogApiFp(this.configuration).getPoolGroupsV1(options).then((request) => request(this.axios, this.basePath));
32213
32308
  }
32214
32309
 
32215
32310
  /**
@@ -32249,61 +32344,6 @@ export class GPUCatalogApi extends BaseAPI {
32249
32344
  }
32250
32345
  }
32251
32346
 
32252
- /**
32253
- * @export
32254
- */
32255
- export const GetPoolGroupsV1CurrencyEnum = {
32256
- Usd: 'USD',
32257
- Ars: 'ARS',
32258
- Amd: 'AMD',
32259
- Aud: 'AUD',
32260
- Azn: 'AZN',
32261
- Bdt: 'BDT',
32262
- Brl: 'BRL',
32263
- Btc: 'BTC',
32264
- Byn: 'BYN',
32265
- Cad: 'CAD',
32266
- Chf: 'CHF',
32267
- Clp: 'CLP',
32268
- Cny: 'CNY',
32269
- Cop: 'COP',
32270
- Czk: 'CZK',
32271
- Dkk: 'DKK',
32272
- Egp: 'EGP',
32273
- Eur: 'EUR',
32274
- Gbp: 'GBP',
32275
- Gel: 'GEL',
32276
- Hkd: 'HKD',
32277
- Hrk: 'HRK',
32278
- Huf: 'HUF',
32279
- Idr: 'IDR',
32280
- Ils: 'ILS',
32281
- Inr: 'INR',
32282
- Jpy: 'JPY',
32283
- Kgs: 'KGS',
32284
- Krw: 'KRW',
32285
- Kzt: 'KZT',
32286
- Mad: 'MAD',
32287
- Mxn: 'MXN',
32288
- Myr: 'MYR',
32289
- Ngn: 'NGN',
32290
- Nok: 'NOK',
32291
- Nzd: 'NZD',
32292
- Pen: 'PEN',
32293
- Php: 'PHP',
32294
- Pkr: 'PKR',
32295
- Pln: 'PLN',
32296
- Sek: 'SEK',
32297
- Sgd: 'SGD',
32298
- Thb: 'THB',
32299
- Tjs: 'TJS',
32300
- Try: 'TRY',
32301
- Twd: 'TWD',
32302
- Uah: 'UAH',
32303
- Vnd: 'VND',
32304
- Zar: 'ZAR'
32305
- } as const;
32306
- export type GetPoolGroupsV1CurrencyEnum = typeof GetPoolGroupsV1CurrencyEnum[keyof typeof GetPoolGroupsV1CurrencyEnum];
32307
32347
 
32308
32348
 
32309
32349
  /**
package/base.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger API
5
5
  *
6
- * API Version: 2.16.1
6
+ * API Version: 3.0.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: 2.16.1
6
+ * API Version: 3.0.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: 2.16.1
6
+ * API Version: 3.0.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/2.16.1",
51
+ 'User-Agent': "hostinger-typescript-sdk/3.0.0",
52
52
  ...param.baseOptions?.headers,
53
53
  },
54
54
  };