Skip to content

Commit 54ec5a1

Browse files
authored
Merge branch 'main' into v1.6667.0
2 parents 58b9e78 + 9f0a4ec commit 54ec5a1

File tree

52 files changed

+2697
-300
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+2697
-300
lines changed

packages/client/src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,5 @@ export type { Money, ScwFile, TimeSeries } from './scw/custom-types'
2929
export * as Errors from './scw/errors/standard'
3030
export type { Region, Zone } from './scw/locality'
3131
export * from './internals'
32+
export { toApiLocality } from './scw/locality'
33+
export type { ApiLocality } from './scw/locality'

packages_generated/applesilicon/src/v1alpha1/api.gen.ts

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
waitForResource,
910
} from '@scaleway/sdk-client'
10-
import type { Zone as ScwZone, WaitForOptions } from '@scaleway/sdk-client'
11+
import type { ApiLocality, WaitForOptions } from '@scaleway/sdk-client'
1112
import {
1213
SERVER_PRIVATE_NETWORK_SERVER_TRANSIENT_STATUSES as SERVER_PRIVATE_NETWORK_SERVER_TRANSIENT_STATUSES_APPLESILICON,
1314
SERVER_TRANSIENT_STATUSES as SERVER_TRANSIENT_STATUSES_APPLESILICON,
@@ -73,8 +74,13 @@ const jsonContentHeaders = {
7374
This API allows you to manage your Apple silicon machines.
7475
*/
7576
export class API extends ParentAPI {
76-
/** Lists the available zones of the API. */
77-
public static readonly LOCALITIES: ScwZone[] = ['fr-par-3']
77+
/**
78+
* Locality of this API.
79+
* type ∈ {'zone','region','global','unspecified'}
80+
*/
81+
public static readonly LOCALITY: ApiLocality = toApiLocality({
82+
zones: ['fr-par-3'],
83+
})
7884

7985
/**
8086
* List server types. List all technical details about Apple silicon server types available in the specified zone. Since there is only one Availability Zone for Apple silicon servers, the targeted value is `fr-par-3`.
@@ -332,8 +338,13 @@ export class API extends ParentAPI {
332338
* Apple silicon - Private Networks API.
333339
*/
334340
export class PrivateNetworkAPI extends ParentAPI {
335-
/** Lists the available zones of the API. */
336-
public static readonly LOCALITIES: ScwZone[] = ['fr-par-1', 'fr-par-3']
341+
/**
342+
* Locality of this API.
343+
* type ∈ {'zone','region','global','unspecified'}
344+
*/
345+
public static readonly LOCALITY: ApiLocality = toApiLocality({
346+
zones: ['fr-par-1', 'fr-par-3'],
347+
})
337348

338349
getServerPrivateNetwork = (
339350
request: Readonly<PrivateNetworkApiGetServerPrivateNetworkRequest>,

packages_generated/audit_trail/src/v1alpha1/api.gen.ts

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,11 @@
22
// If you have any remark or suggestion do not hesitate to open an issue.
33
import {
44
API as ParentAPI,
5+
toApiLocality,
56
urlParams,
67
validatePathParam,
78
} from '@scaleway/sdk-client'
8-
import type { Region as ScwRegion } from '@scaleway/sdk-client'
9+
import type { ApiLocality } from '@scaleway/sdk-client'
910
import {
1011
unmarshalListEventsResponse,
1112
unmarshalListProductsResponse,
@@ -23,8 +24,13 @@ import type {
2324
This API allows you to ensure accountability and security by recording events and changes performed within your Scaleway Organization.
2425
*/
2526
export class API extends ParentAPI {
26-
/** Lists the available regions of the API. */
27-
public static readonly LOCALITIES: ScwRegion[] = ['fr-par', 'nl-ams']
27+
/**
28+
* Locality of this API.
29+
* type ∈ {'zone','region','global','unspecified'}
30+
*/
31+
public static readonly LOCALITY: ApiLocality = toApiLocality({
32+
regions: ['fr-par', 'nl-ams'],
33+
})
2834

2935
/**
3036
* List events. Retrieve the list of Audit Trail events for a Scaleway Organization and/or Project. You must specify the `organization_id` and optionally, the `project_id`.

packages_generated/audit_trail/src/v1alpha1/marshalling.gen.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ const unmarshalSecretManagerSecretInfo = (
117117
}
118118

119119
return {
120+
keyId: data.key_id,
120121
path: data.path,
121122
} as SecretManagerSecretInfo
122123
}

packages_generated/audit_trail/src/v1alpha1/types.gen.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ export interface KubernetesPoolInfo {
5151

5252
export interface SecretManagerSecretInfo {
5353
path: string
54+
keyId?: string
5455
}
5556

5657
export interface SecretManagerSecretVersionInfo {

packages_generated/baremetal/src/v1/api.gen.ts

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
waitForResource,
910
} from '@scaleway/sdk-client'
10-
import type { Zone as ScwZone, WaitForOptions } from '@scaleway/sdk-client'
11+
import type { ApiLocality, WaitForOptions } from '@scaleway/sdk-client'
1112
import { SERVER_TRANSIENT_STATUSES as SERVER_TRANSIENT_STATUSES_BAREMETAL } from './content.gen'
1213
import {
1314
marshalAddOptionServerRequest,
@@ -104,15 +105,20 @@ const jsonContentHeaders = {
104105
This API allows you to manage your Elastic Metal servers.
105106
*/
106107
export class API extends ParentAPI {
107-
/** Lists the available zones of the API. */
108-
public static readonly LOCALITIES: ScwZone[] = [
109-
'fr-par-1',
110-
'fr-par-2',
111-
'nl-ams-1',
112-
'nl-ams-2',
113-
'pl-waw-2',
114-
'pl-waw-3',
115-
]
108+
/**
109+
* Locality of this API.
110+
* type ∈ {'zone','region','global','unspecified'}
111+
*/
112+
public static readonly LOCALITY: ApiLocality = toApiLocality({
113+
zones: [
114+
'fr-par-1',
115+
'fr-par-2',
116+
'nl-ams-1',
117+
'nl-ams-2',
118+
'pl-waw-2',
119+
'pl-waw-3',
120+
],
121+
})
116122

117123
protected pageOfListServers = (request: Readonly<ListServersRequest> = {}) =>
118124
this.client.fetch<ListServersResponse>(
@@ -690,8 +696,13 @@ After adding the BMC option, you need to Get Remote Access to get the login/pass
690696
* Elastic Metal - Private Network API.
691697
*/
692698
export class PrivateNetworkAPI extends ParentAPI {
693-
/** Lists the available zones of the API. */
694-
public static readonly LOCALITIES: ScwZone[] = ['fr-par-2']
699+
/**
700+
* Locality of this API.
701+
* type ∈ {'zone','region','global','unspecified'}
702+
*/
703+
public static readonly LOCALITY: ApiLocality = toApiLocality({
704+
zones: ['fr-par-2'],
705+
})
695706

696707
/**
697708
* Add a server to a Private Network.

packages_generated/baremetal/src/v3/api.gen.ts

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
} from '@scaleway/sdk-client'
9-
import type { Zone as ScwZone } from '@scaleway/sdk-client'
10+
import type { ApiLocality } from '@scaleway/sdk-client'
1011
import {
1112
marshalPrivateNetworkApiAddServerPrivateNetworkRequest,
1213
marshalPrivateNetworkApiSetServerPrivateNetworksRequest,
@@ -32,15 +33,20 @@ const jsonContentHeaders = {
3233
* Elastic Metal - Private Networks API.
3334
*/
3435
export class PrivateNetworkAPI extends ParentAPI {
35-
/** Lists the available zones of the API. */
36-
public static readonly LOCALITIES: ScwZone[] = [
37-
'fr-par-1',
38-
'fr-par-2',
39-
'nl-ams-1',
40-
'nl-ams-2',
41-
'pl-waw-2',
42-
'pl-waw-3',
43-
]
36+
/**
37+
* Locality of this API.
38+
* type ∈ {'zone','region','global','unspecified'}
39+
*/
40+
public static readonly LOCALITY: ApiLocality = toApiLocality({
41+
zones: [
42+
'fr-par-1',
43+
'fr-par-2',
44+
'nl-ams-1',
45+
'nl-ams-2',
46+
'pl-waw-2',
47+
'pl-waw-3',
48+
],
49+
})
4450

4551
/**
4652
* Add a server to a Private Network. Add an Elastic Metal server to a Private Network.

packages_generated/block/src/v1/api.gen.ts

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
waitForResource,
910
} from '@scaleway/sdk-client'
10-
import type { Zone as ScwZone, WaitForOptions } from '@scaleway/sdk-client'
11+
import type { ApiLocality, WaitForOptions } from '@scaleway/sdk-client'
1112
import {
1213
SNAPSHOT_TRANSIENT_STATUSES as SNAPSHOT_TRANSIENT_STATUSES_BLOCK,
1314
VOLUME_TRANSIENT_STATUSES as VOLUME_TRANSIENT_STATUSES_BLOCK,
@@ -56,18 +57,23 @@ const jsonContentHeaders = {
5657
This API allows you to manage your Block Storage volumes.
5758
*/
5859
export class API extends ParentAPI {
59-
/** Lists the available zones of the API. */
60-
public static readonly LOCALITIES: ScwZone[] = [
61-
'fr-par-1',
62-
'fr-par-2',
63-
'fr-par-3',
64-
'nl-ams-1',
65-
'nl-ams-2',
66-
'nl-ams-3',
67-
'pl-waw-1',
68-
'pl-waw-2',
69-
'pl-waw-3',
70-
]
60+
/**
61+
* Locality of this API.
62+
* type ∈ {'zone','region','global','unspecified'}
63+
*/
64+
public static readonly LOCALITY: ApiLocality = toApiLocality({
65+
zones: [
66+
'fr-par-1',
67+
'fr-par-2',
68+
'fr-par-3',
69+
'nl-ams-1',
70+
'nl-ams-2',
71+
'nl-ams-3',
72+
'pl-waw-1',
73+
'pl-waw-2',
74+
'pl-waw-3',
75+
],
76+
})
7177

7278
protected pageOfListVolumeTypes = (
7379
request: Readonly<ListVolumeTypesRequest> = {},

packages_generated/block/src/v1alpha1/api.gen.ts

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
waitForResource,
910
} from '@scaleway/sdk-client'
10-
import type { Zone as ScwZone, WaitForOptions } from '@scaleway/sdk-client'
11+
import type { ApiLocality, WaitForOptions } from '@scaleway/sdk-client'
1112
import {
1213
SNAPSHOT_TRANSIENT_STATUSES as SNAPSHOT_TRANSIENT_STATUSES_BLOCK,
1314
VOLUME_TRANSIENT_STATUSES as VOLUME_TRANSIENT_STATUSES_BLOCK,
@@ -58,18 +59,23 @@ const jsonContentHeaders = {
5859
This API allows you to manage your Block Storage volumes.
5960
*/
6061
export class API extends ParentAPI {
61-
/** Lists the available zones of the API. */
62-
public static readonly LOCALITIES: ScwZone[] = [
63-
'fr-par-1',
64-
'fr-par-2',
65-
'fr-par-3',
66-
'nl-ams-1',
67-
'nl-ams-2',
68-
'nl-ams-3',
69-
'pl-waw-1',
70-
'pl-waw-2',
71-
'pl-waw-3',
72-
]
62+
/**
63+
* Locality of this API.
64+
* type ∈ {'zone','region','global','unspecified'}
65+
*/
66+
public static readonly LOCALITY: ApiLocality = toApiLocality({
67+
zones: [
68+
'fr-par-1',
69+
'fr-par-2',
70+
'fr-par-3',
71+
'nl-ams-1',
72+
'nl-ams-2',
73+
'nl-ams-3',
74+
'pl-waw-1',
75+
'pl-waw-2',
76+
'pl-waw-3',
77+
],
78+
})
7379

7480
protected pageOfListVolumeTypes = (
7581
request: Readonly<ListVolumeTypesRequest> = {},

packages_generated/cockpit/src/v1/api.gen.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
import {
44
API as ParentAPI,
55
enrichForPagination,
6+
toApiLocality,
67
urlParams,
78
validatePathParam,
89
} from '@scaleway/sdk-client'
9-
import type { ApiLocality } from '../types/locality'
10-
import { toApiLocality } from '../types/locality'
10+
import type { ApiLocality } from '@scaleway/sdk-client'
1111
import {
1212
marshalGlobalApiCreateGrafanaUserRequest,
1313
marshalGlobalApiResetGrafanaUserPasswordRequest,

0 commit comments

Comments
 (0)