From 69b7738aa6c036e037db17da3fcc0e4e52f07677 Mon Sep 17 00:00:00 2001 From: scaleway-bot Date: Tue, 6 Jun 2023 14:45:35 +0000 Subject: [PATCH] feat: update generated APIs --- packages/clients/src/api/lb/v1/api.gen.ts | 6 ++-- .../clients/src/api/lb/v1/marshalling.gen.ts | 6 ++++ packages/clients/src/api/lb/v1/types.gen.ts | 32 +++++++++++++++++-- 3 files changed, 40 insertions(+), 4 deletions(-) diff --git a/packages/clients/src/api/lb/v1/api.gen.ts b/packages/clients/src/api/lb/v1/api.gen.ts index b6b62e8a8..7c9983b86 100644 --- a/packages/clients/src/api/lb/v1/api.gen.ts +++ b/packages/clients/src/api/lb/v1/api.gen.ts @@ -417,7 +417,7 @@ export class API extends ParentAPI { * @param request - The request {@link CreateIpRequest} * @returns A Promise of Ip */ - createIp = (request: Readonly = {}) => + createIp = (request: Readonly) => this.client.fetch( { body: JSON.stringify( @@ -936,6 +936,7 @@ export class API extends ParentAPI { request.region ?? this.client.settings.defaultRegion, )}/lbs/${validatePathParam('lbId', request.lbId)}/backend-stats`, urlParams: urlParams( + ['backend_id', request.backendId], ['page', request.page], [ 'page_size', @@ -1698,7 +1699,7 @@ export class ZonedAPI extends ParentAPI { * @param request - The request {@link ZonedApiCreateIpRequest} * @returns A Promise of Ip */ - createIp = (request: Readonly = {}) => + createIp = (request: Readonly) => this.client.fetch( { body: JSON.stringify( @@ -2288,6 +2289,7 @@ export class ZonedAPI extends ParentAPI { request.zone ?? this.client.settings.defaultZone, )}/lbs/${validatePathParam('lbId', request.lbId)}/backend-stats`, urlParams: urlParams( + ['backend_id', request.backendId], ['page', request.page], [ 'page_size', diff --git a/packages/clients/src/api/lb/v1/marshalling.gen.ts b/packages/clients/src/api/lb/v1/marshalling.gen.ts index 4f59e8beb..c82d82f93 100644 --- a/packages/clients/src/api/lb/v1/marshalling.gen.ts +++ b/packages/clients/src/api/lb/v1/marshalling.gen.ts @@ -1105,6 +1105,7 @@ export const marshalCreateIpRequest = ( request: CreateIpRequest, defaults: DefaultValues, ): Record => ({ + is_ipv6: request.isIpv6, reverse: request.reverse, ...resolveOneOf([ { @@ -1124,8 +1125,10 @@ export const marshalCreateLbRequest = ( request: CreateLbRequest, defaults: DefaultValues, ): Record => ({ + assign_flexible_ip: request.assignFlexibleIp, description: request.description, ip_id: request.ipId, + ip_ids: request.ipIds, name: request.name || randomName('lb'), ssl_compatibility_level: request.sslCompatibilityLevel ?? 'ssl_compatibility_level_unknown', @@ -1494,6 +1497,7 @@ export const marshalZonedApiCreateIpRequest = ( request: ZonedApiCreateIpRequest, defaults: DefaultValues, ): Record => ({ + is_ipv6: request.isIpv6, reverse: request.reverse, ...resolveOneOf([ { @@ -1513,8 +1517,10 @@ export const marshalZonedApiCreateLbRequest = ( request: ZonedApiCreateLbRequest, defaults: DefaultValues, ): Record => ({ + assign_flexible_ip: request.assignFlexibleIp, description: request.description, ip_id: request.ipId, + ip_ids: request.ipIds, name: request.name || randomName('lb'), ssl_compatibility_level: request.sslCompatibilityLevel ?? 'ssl_compatibility_level_unknown', diff --git a/packages/clients/src/api/lb/v1/types.gen.ts b/packages/clients/src/api/lb/v1/types.gen.ts index b93be1fe2..f240872da 100644 --- a/packages/clients/src/api/lb/v1/types.gen.ts +++ b/packages/clients/src/api/lb/v1/types.gen.ts @@ -939,8 +939,18 @@ export type CreateLbRequest = { name?: string /** Description for the Load Balancer. */ description: string - /** ID of an existing flexible IP address to attach to the Load Balancer. */ + /** + * @deprecated ID of an existing flexible IP address to attach to the Load + * Balancer. + */ ipId?: string + /** + * Defines whether to automatically assign a flexible public IP to lb. Default + * value is `false` (do not assign). + */ + assignFlexibleIp?: boolean + /** List of IP IDs to attach to the Load Balancer. */ + ipIds?: string[] /** List of tags for the Load Balancer. */ tags?: string[] /** @@ -1072,6 +1082,8 @@ export type CreateIpRequest = { projectId?: string /** Reverse DNS (domain name) for the IP address. */ reverse?: string + /** If true, creates a Flexible IP with an ipv6 address. */ + isIpv6: boolean } export type GetIpRequest = { @@ -1616,6 +1628,8 @@ export type ListBackendStatsRequest = { page?: number /** Number of items to return. */ pageSize?: number + /** ID of the backend. */ + backendId?: string } export type ListAclsRequest = { @@ -2034,8 +2048,18 @@ export type ZonedApiCreateLbRequest = { name?: string /** Description for the Load Balancer. */ description: string - /** ID of an existing flexible IP address to attach to the Load Balancer. */ + /** + * @deprecated ID of an existing flexible IP address to attach to the Load + * Balancer. + */ ipId?: string + /** + * Defines whether to automatically assign a flexible public IP to lb. Default + * value is `false` (do not assign). + */ + assignFlexibleIp?: boolean + /** List of IP IDs to attach to the Load Balancer. */ + ipIds?: string[] /** List of tags for the Load Balancer. */ tags?: string[] /** @@ -2149,6 +2173,8 @@ export type ZonedApiCreateIpRequest = { projectId?: string /** Reverse DNS (domain name) for the IP address. */ reverse?: string + /** If true, creates a Flexible IP with an ipv6 address. */ + isIpv6: boolean } export type ZonedApiGetIpRequest = { @@ -2621,6 +2647,8 @@ export type ZonedApiListBackendStatsRequest = { page?: number /** Number of items to return. */ pageSize?: number + /** ID of the backend. */ + backendId?: string } export type ZonedApiListAclsRequest = {