From a28be9b56dd684d7a285fae807491a0a1da5b402 Mon Sep 17 00:00:00 2001 From: scaleway-bot Date: Mon, 7 Apr 2025 14:14:35 +0000 Subject: [PATCH 1/2] feat: update generated APIs --- packages/clients/src/api/index.gen.ts | 2 ++ .../src/api/instance/v1/marshalling.gen.ts | 2 ++ .../clients/src/api/instance/v1/types.gen.ts | 13 ++++++++- .../src/api/product_catalog/index.gen.ts | 6 +++++ .../api/product_catalog/v2alpha1/index.gen.ts | 27 +++++++++++++++++++ 5 files changed, 49 insertions(+), 1 deletion(-) create mode 100644 packages/clients/src/api/product_catalog/index.gen.ts create mode 100644 packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts diff --git a/packages/clients/src/api/index.gen.ts b/packages/clients/src/api/index.gen.ts index 9ad0f77af..5e47484ee 100644 --- a/packages/clients/src/api/index.gen.ts +++ b/packages/clients/src/api/index.gen.ts @@ -32,6 +32,7 @@ import * as LlmInference from './llm_inference/index.gen' import * as Marketplace from './marketplace/index.gen' import * as Mnq from './mnq/index.gen' import * as Mongodb from './mongodb/index.gen' +import * as ProductCatalog from './product_catalog/index.gen' import * as Qaas from './qaas/index.gen' import * as Rdb from './rdb/index.gen' import * as Redis from './redis/index.gen' @@ -75,6 +76,7 @@ export { Marketplace, Mnq, Mongodb, + ProductCatalog, Qaas, Rdb, Redis, diff --git a/packages/clients/src/api/instance/v1/marshalling.gen.ts b/packages/clients/src/api/instance/v1/marshalling.gen.ts index b7e9b4d76..6b0ea7e20 100644 --- a/packages/clients/src/api/instance/v1/marshalling.gen.ts +++ b/packages/clients/src/api/instance/v1/marshalling.gen.ts @@ -404,6 +404,7 @@ const unmarshalServer = (data: unknown): Server => { creationDate: unmarshalDate(data.creation_date), dynamicIpRequired: data.dynamic_ip_required, enableIpv6: data.enable_ipv6, + endOfService: data.end_of_service, hostname: data.hostname, id: data.id, image: data.image ? unmarshalImage(data.image) : undefined, @@ -1834,6 +1835,7 @@ export const marshalCreateServerRequest = ( image: request.image, name: request.name || randomName('srv'), placement_group: request.placementGroup, + protected: request.protected, public_ip: request.publicIp, public_ips: request.publicIps, routed_ip_enabled: request.routedIpEnabled, diff --git a/packages/clients/src/api/instance/v1/types.gen.ts b/packages/clients/src/api/instance/v1/types.gen.ts index d4a31a905..87e058627 100644 --- a/packages/clients/src/api/instance/v1/types.gen.ts +++ b/packages/clients/src/api/instance/v1/types.gen.ts @@ -632,6 +632,10 @@ export interface Server { * This value is reset when admin_password_encryption_ssh_key_id is set to an empty string. */ adminPasswordEncryptedValue?: string + /** + * True if the Instance type has reached end of service. + */ + endOfService: boolean } export interface VolumeTemplate { @@ -888,7 +892,7 @@ export interface Task { hrefFrom: string hrefResult: string /** - * Zone in which the task is excecuted. + * Zone in which the task is executed. */ zone: ScwZone } @@ -1437,6 +1441,10 @@ export type CreateServerRequest = { * The public_key value of this key is used to encrypt the admin password. */ adminPasswordEncryptionSshKeyId?: string + /** + * True to activate server protection option. + */ + protected: boolean } export interface CreateServerResponse { @@ -2783,6 +2791,9 @@ export type UpdateServerRequest = { * @deprecated */ enableIpv6?: boolean + /** + * True to activate server protection option. + */ protected?: boolean securityGroup?: SecurityGroupTemplate /** diff --git a/packages/clients/src/api/product_catalog/index.gen.ts b/packages/clients/src/api/product_catalog/index.gen.ts new file mode 100644 index 000000000..36dc2b2b7 --- /dev/null +++ b/packages/clients/src/api/product_catalog/index.gen.ts @@ -0,0 +1,6 @@ +/** + * This file is automatically generated from /scripts/generate.js + * PLEASE DO NOT EDIT HERE + */ + +export * as v2alpha1 from './v2alpha1/index.gen' diff --git a/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts b/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts new file mode 100644 index 000000000..b94d747c0 --- /dev/null +++ b/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts @@ -0,0 +1,27 @@ +// This file was automatically generated. DO NOT EDIT. +// If you have any remark or suggestion do not hesitate to open an issue. +export { PublicCatalogAPI } from './api.gen' +export type { + ListPublicCatalogProductsResponse, + PublicCatalogApiListPublicCatalogProductsRequest, + PublicCatalogProduct, + PublicCatalogProductLocality, + PublicCatalogProductPrice, + PublicCatalogProductPriceUnitOfMeasure, + PublicCatalogProductPriceUnitOfMeasureCountableUnit, + PublicCatalogProductProperties, + PublicCatalogProductPropertiesAppleSilicon, + PublicCatalogProductPropertiesDedibox, + PublicCatalogProductPropertiesElasticMetal, + PublicCatalogProductPropertiesHardware, + PublicCatalogProductPropertiesHardwareCPU, + PublicCatalogProductPropertiesHardwareCPUArch, + PublicCatalogProductPropertiesHardwareCPUPhysical, + PublicCatalogProductPropertiesHardwareCPUVirtual, + PublicCatalogProductPropertiesHardwareGPU, + PublicCatalogProductPropertiesHardwareNetwork, + PublicCatalogProductPropertiesHardwareRAM, + PublicCatalogProductPropertiesHardwareStorage, + PublicCatalogProductPropertiesInstance, +} from './types.gen' +export * as ValidationRules from './validation-rules.gen' From acbf818eeeedfc3e8c8dffc589f1373a4b6a4c93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20L=C3=A9one?= Date: Mon, 7 Apr 2025 16:22:19 +0200 Subject: [PATCH 2/2] Fix --- packages/clients/src/api/index.gen.ts | 2 -- .../src/api/product_catalog/index.gen.ts | 6 ----- .../api/product_catalog/v2alpha1/index.gen.ts | 27 ------------------- 3 files changed, 35 deletions(-) delete mode 100644 packages/clients/src/api/product_catalog/index.gen.ts delete mode 100644 packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts diff --git a/packages/clients/src/api/index.gen.ts b/packages/clients/src/api/index.gen.ts index 5e47484ee..9ad0f77af 100644 --- a/packages/clients/src/api/index.gen.ts +++ b/packages/clients/src/api/index.gen.ts @@ -32,7 +32,6 @@ import * as LlmInference from './llm_inference/index.gen' import * as Marketplace from './marketplace/index.gen' import * as Mnq from './mnq/index.gen' import * as Mongodb from './mongodb/index.gen' -import * as ProductCatalog from './product_catalog/index.gen' import * as Qaas from './qaas/index.gen' import * as Rdb from './rdb/index.gen' import * as Redis from './redis/index.gen' @@ -76,7 +75,6 @@ export { Marketplace, Mnq, Mongodb, - ProductCatalog, Qaas, Rdb, Redis, diff --git a/packages/clients/src/api/product_catalog/index.gen.ts b/packages/clients/src/api/product_catalog/index.gen.ts deleted file mode 100644 index 36dc2b2b7..000000000 --- a/packages/clients/src/api/product_catalog/index.gen.ts +++ /dev/null @@ -1,6 +0,0 @@ -/** - * This file is automatically generated from /scripts/generate.js - * PLEASE DO NOT EDIT HERE - */ - -export * as v2alpha1 from './v2alpha1/index.gen' diff --git a/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts b/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts deleted file mode 100644 index b94d747c0..000000000 --- a/packages/clients/src/api/product_catalog/v2alpha1/index.gen.ts +++ /dev/null @@ -1,27 +0,0 @@ -// This file was automatically generated. DO NOT EDIT. -// If you have any remark or suggestion do not hesitate to open an issue. -export { PublicCatalogAPI } from './api.gen' -export type { - ListPublicCatalogProductsResponse, - PublicCatalogApiListPublicCatalogProductsRequest, - PublicCatalogProduct, - PublicCatalogProductLocality, - PublicCatalogProductPrice, - PublicCatalogProductPriceUnitOfMeasure, - PublicCatalogProductPriceUnitOfMeasureCountableUnit, - PublicCatalogProductProperties, - PublicCatalogProductPropertiesAppleSilicon, - PublicCatalogProductPropertiesDedibox, - PublicCatalogProductPropertiesElasticMetal, - PublicCatalogProductPropertiesHardware, - PublicCatalogProductPropertiesHardwareCPU, - PublicCatalogProductPropertiesHardwareCPUArch, - PublicCatalogProductPropertiesHardwareCPUPhysical, - PublicCatalogProductPropertiesHardwareCPUVirtual, - PublicCatalogProductPropertiesHardwareGPU, - PublicCatalogProductPropertiesHardwareNetwork, - PublicCatalogProductPropertiesHardwareRAM, - PublicCatalogProductPropertiesHardwareStorage, - PublicCatalogProductPropertiesInstance, -} from './types.gen' -export * as ValidationRules from './validation-rules.gen'