@scaleway/sdk 1.4.0 → 1.5.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/dist/index.cjs CHANGED
@@ -390,7 +390,7 @@ const assertValidSettings = obj => {
390
390
  }
391
391
  };
392
392
 
393
- const version = 'v1.3.0';
393
+ const version = 'v1.4.0';
394
394
  const userAgent = `scaleway-sdk-js/${version}`;
395
395
 
396
396
  const isBrowser = () => typeof window !== 'undefined' && typeof window.document !== 'undefined';
@@ -528,6 +528,15 @@ ${await dumpResponse(response)}
528
528
  return response;
529
529
  };
530
530
 
531
+ /**
532
+ * Validates an object is of type Response without using `instanceof`.
533
+ *
534
+ * @remarks Check issue #509 for more context.
535
+ *
536
+ * @internal
537
+ */
538
+ const isResponse = obj => obj !== null && obj !== undefined && typeof obj === 'object' && 'status' in obj && typeof obj.status === 'number' && 'statusText' in obj && typeof obj.statusText === 'string' && 'headers' in obj && typeof obj.headers === 'object' && 'body' in obj && typeof obj.body !== 'undefined';
539
+
531
540
  /**
532
541
  * Validates an unknown object is a JSON Object.
533
542
  *
@@ -1244,7 +1253,7 @@ const fixLegacyTotalCount = (obj, headers) => {
1244
1253
  * @internal
1245
1254
  */
1246
1255
  const responseParser = (unmarshaller, responseType) => async response => {
1247
- if (!(response instanceof Response)) {
1256
+ if (!isResponse(response)) {
1248
1257
  throw new TypeError('Invalid response object');
1249
1258
  }
1250
1259
  if (response.ok) {
@@ -1521,7 +1530,7 @@ const waitForResource = (stop, fetcher, request, options, strategy = createExpon
1521
1530
  *
1522
1531
  * @internal
1523
1532
  */
1524
- let API$p = class API {
1533
+ let API$q = class API {
1525
1534
  constructor(client) {
1526
1535
  this.client = client;
1527
1536
  }
@@ -1829,133 +1838,6 @@ const enrichForPagination = (key, fetcher, request) => {
1829
1838
  });
1830
1839
  };
1831
1840
 
1832
- // This file was automatically generated. DO NOT EDIT.
1833
- const unmarshalSSHKeyCreationInfo = data => {
1834
- if (!isJSONObject(data)) {
1835
- throw new TypeError(`Unmarshalling the type 'SSHKeyCreationInfo' failed as data isn't a dictionary.`);
1836
- }
1837
- return {
1838
- address: data.address,
1839
- countryCode: data.country_code,
1840
- userAgent: data.user_agent
1841
- };
1842
- };
1843
- const unmarshalSSHKey$1 = data => {
1844
- if (!isJSONObject(data)) {
1845
- throw new TypeError(`Unmarshalling the type 'SSHKey' failed as data isn't a dictionary.`);
1846
- }
1847
- return {
1848
- createdAt: unmarshalDate(data.created_at),
1849
- creationInfo: data.creation_info ? unmarshalSSHKeyCreationInfo(data.creation_info) : undefined,
1850
- fingerprint: data.fingerprint,
1851
- id: data.id,
1852
- name: data.name,
1853
- organizationId: data.organization_id,
1854
- projectId: data.project_id,
1855
- publicKey: data.public_key,
1856
- updatedAt: unmarshalDate(data.updated_at)
1857
- };
1858
- };
1859
- const unmarshalListSSHKeysResponse$1 = data => {
1860
- if (!isJSONObject(data)) {
1861
- throw new TypeError(`Unmarshalling the type 'ListSSHKeysResponse' failed as data isn't a dictionary.`);
1862
- }
1863
- return {
1864
- sshKeys: unmarshalArrayOfObject(data.ssh_keys, unmarshalSSHKey$1),
1865
- totalCount: data.total_count
1866
- };
1867
- };
1868
- const marshalCreateSSHKeyRequest$1 = (request, defaults) => ({
1869
- name: request.name,
1870
- public_key: request.publicKey,
1871
- ...resolveOneOf([{
1872
- default: defaults.defaultProjectId,
1873
- param: 'project_id',
1874
- value: request.projectId
1875
- }, {
1876
- default: defaults.defaultOrganizationId,
1877
- param: 'organization_id',
1878
- value: request.organizationId
1879
- }])
1880
- });
1881
- const marshalUpdateSSHKeyRequest$1 = (request, defaults) => ({
1882
- name: request.name
1883
- });
1884
-
1885
- // This file was automatically generated. DO NOT EDIT.
1886
- const jsonContentHeaders$n = {
1887
- 'Content-Type': 'application/json; charset=utf-8'
1888
- };
1889
-
1890
- /** Account API. */
1891
- class AccountV2Alpha1GenAPI extends API$p {
1892
- pageOfListSSHKeys = (request = {}) => this.client.fetch({
1893
- method: 'GET',
1894
- path: `/account/v2alpha1/ssh-keys`,
1895
- urlParams: urlParams(['name', request.name], ['order_by', request.orderBy ?? 'created_at_asc'], ['organization_id', request.organizationId ?? this.client.settings.defaultOrganizationId], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId])
1896
- }, unmarshalListSSHKeysResponse$1);
1897
-
1898
- /**
1899
- * List all SSH keys of your project
1900
- *
1901
- * @param request - The request {@link ListSSHKeysRequest}
1902
- * @returns A Promise of ListSSHKeysResponse
1903
- */
1904
- listSSHKeys = (request = {}) => enrichForPagination('sshKeys', this.pageOfListSSHKeys, request);
1905
-
1906
- /**
1907
- * Add an SSH key to your project
1908
- *
1909
- * @param request - The request {@link CreateSSHKeyRequest}
1910
- * @returns A Promise of SSHKey
1911
- */
1912
- createSSHKey = request => this.client.fetch({
1913
- body: JSON.stringify(marshalCreateSSHKeyRequest$1(request, this.client.settings)),
1914
- headers: jsonContentHeaders$n,
1915
- method: 'POST',
1916
- path: `/account/v2alpha1/ssh-keys`
1917
- }, unmarshalSSHKey$1);
1918
-
1919
- /**
1920
- * Get an SSH key from your project
1921
- *
1922
- * @param request - The request {@link GetSSHKeyRequest}
1923
- * @returns A Promise of SSHKey
1924
- */
1925
- getSSHKey = request => this.client.fetch({
1926
- method: 'GET',
1927
- path: `/account/v2alpha1/ssh-key/${validatePathParam('sshKeyId', request.sshKeyId)}`
1928
- }, unmarshalSSHKey$1);
1929
-
1930
- /**
1931
- * Update an SSH key on your project
1932
- *
1933
- * @param request - The request {@link UpdateSSHKeyRequest}
1934
- * @returns A Promise of SSHKey
1935
- */
1936
- updateSSHKey = request => this.client.fetch({
1937
- body: JSON.stringify(marshalUpdateSSHKeyRequest$1(request, this.client.settings)),
1938
- headers: jsonContentHeaders$n,
1939
- method: 'PATCH',
1940
- path: `/account/v2alpha1/ssh-key/${validatePathParam('sshKeyId', request.sshKeyId)}`
1941
- }, unmarshalSSHKey$1);
1942
-
1943
- /**
1944
- * Remove an SSH key from your project
1945
- *
1946
- * @param request - The request {@link DeleteSSHKeyRequest}
1947
- */
1948
- deleteSSHKey = request => this.client.fetch({
1949
- method: 'DELETE',
1950
- path: `/account/v2alpha1/ssh-key/${validatePathParam('sshKeyId', request.sshKeyId)}`
1951
- });
1952
- }
1953
-
1954
- var index$s = /*#__PURE__*/Object.freeze({
1955
- __proto__: null,
1956
- API: AccountV2Alpha1GenAPI
1957
- });
1958
-
1959
1841
  // This file was automatically generated. DO NOT EDIT.
1960
1842
  const unmarshalProject = data => {
1961
1843
  if (!isJSONObject(data)) {
@@ -1999,7 +1881,7 @@ const jsonContentHeaders$m = {
1999
1881
  *
2000
1882
  * User related data. This API allows you to manage projects.
2001
1883
  */
2002
- let API$o = class API extends API$p {
1884
+ let API$p = class API extends API$q {
2003
1885
  /**
2004
1886
  * Create a new Project for an Organization. Generate a new Project for an
2005
1887
  * Organization, specifying its configuration including name and description.
@@ -2073,15 +1955,14 @@ let API$o = class API extends API$p {
2073
1955
 
2074
1956
  // This file was automatically generated. DO NOT EDIT.
2075
1957
 
2076
- var index_gen$k = /*#__PURE__*/Object.freeze({
1958
+ var index_gen$l = /*#__PURE__*/Object.freeze({
2077
1959
  __proto__: null,
2078
- API: API$o
1960
+ API: API$p
2079
1961
  });
2080
1962
 
2081
- var index$r = /*#__PURE__*/Object.freeze({
1963
+ var index$s = /*#__PURE__*/Object.freeze({
2082
1964
  __proto__: null,
2083
- v2: index_gen$k,
2084
- v2alpha1: index$s
1965
+ v2: index_gen$l
2085
1966
  });
2086
1967
 
2087
1968
  // This file was automatically generated. DO NOT EDIT.
@@ -2235,7 +2116,7 @@ const jsonContentHeaders$l = {
2235
2116
  * Cisco in the U.S. and other countries and is used by Apple under license.
2236
2117
  * Scaleway is not affiliated with Apple Inc.
2237
2118
  */
2238
- let API$n = class API extends API$p {
2119
+ let API$o = class API extends API$q {
2239
2120
  /** Lists the available zones of the API. */
2240
2121
  static LOCALITIES = ['fr-par-3'];
2241
2122
 
@@ -2401,15 +2282,15 @@ let API$n = class API extends API$p {
2401
2282
 
2402
2283
  // This file was automatically generated. DO NOT EDIT.
2403
2284
 
2404
- var index_gen$j = /*#__PURE__*/Object.freeze({
2285
+ var index_gen$k = /*#__PURE__*/Object.freeze({
2405
2286
  __proto__: null,
2406
- API: API$n,
2287
+ API: API$o,
2407
2288
  SERVER_TRANSIENT_STATUSES: SERVER_TRANSIENT_STATUSES$2
2408
2289
  });
2409
2290
 
2410
- var index$q = /*#__PURE__*/Object.freeze({
2291
+ var index$r = /*#__PURE__*/Object.freeze({
2411
2292
  __proto__: null,
2412
- v1alpha1: index_gen$j
2293
+ v1alpha1: index_gen$k
2413
2294
  });
2414
2295
 
2415
2296
  // This file was automatically generated. DO NOT EDIT.
@@ -2833,7 +2714,7 @@ const jsonContentHeaders$k = {
2833
2714
  *
2834
2715
  * This API allows to manage your Elastic Metal server. Elastic Metal API.
2835
2716
  */
2836
- let API$m = class API extends API$p {
2717
+ let API$n = class API extends API$q {
2837
2718
  /** Lists the available zones of the API. */
2838
2719
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1'];
2839
2720
  pageOfListServers = (request = {}) => this.client.fetch({
@@ -3183,7 +3064,7 @@ let API$m = class API extends API$p {
3183
3064
  };
3184
3065
 
3185
3066
  /** Elastic Metal Private Network API. */
3186
- class PrivateNetworkAPI extends API$p {
3067
+ class PrivateNetworkAPI extends API$q {
3187
3068
  /** Lists the available zones of the API. */
3188
3069
  static LOCALITIES = ['fr-par-2'];
3189
3070
 
@@ -3241,7 +3122,7 @@ class PrivateNetworkAPI extends API$p {
3241
3122
  });
3242
3123
  }
3243
3124
 
3244
- class BaremetalV1UtilsAPI extends API$m {
3125
+ class BaremetalV1UtilsAPI extends API$n {
3245
3126
  /**
3246
3127
  * Waits for {@link ServerInstall} to be in a final state.
3247
3128
  *
@@ -3385,7 +3266,7 @@ var validationRules_gen$4 = /*#__PURE__*/Object.freeze({
3385
3266
  UpdateServerRequest: UpdateServerRequest
3386
3267
  });
3387
3268
 
3388
- var index$p = /*#__PURE__*/Object.freeze({
3269
+ var index$q = /*#__PURE__*/Object.freeze({
3389
3270
  __proto__: null,
3390
3271
  API: BaremetalV1UtilsAPI,
3391
3272
  PrivateNetworkAPI: PrivateNetworkAPI,
@@ -3395,9 +3276,94 @@ var index$p = /*#__PURE__*/Object.freeze({
3395
3276
  ValidationRules: validationRules_gen$4
3396
3277
  });
3397
3278
 
3279
+ var index$p = /*#__PURE__*/Object.freeze({
3280
+ __proto__: null,
3281
+ v1: index$q
3282
+ });
3283
+
3284
+ // This file was automatically generated. DO NOT EDIT.
3285
+ const unmarshalGetConsumptionResponseConsumption = data => {
3286
+ if (!isJSONObject(data)) {
3287
+ throw new TypeError(`Unmarshalling the type 'GetConsumptionResponseConsumption' failed as data isn't a dictionary.`);
3288
+ }
3289
+ return {
3290
+ category: data.category,
3291
+ description: data.description,
3292
+ operationPath: data.operation_path,
3293
+ projectId: data.project_id,
3294
+ value: data.value ? unmarshalMoney(data.value) : undefined
3295
+ };
3296
+ };
3297
+ const unmarshalInvoice = data => {
3298
+ if (!isJSONObject(data)) {
3299
+ throw new TypeError(`Unmarshalling the type 'Invoice' failed as data isn't a dictionary.`);
3300
+ }
3301
+ return {
3302
+ dueDate: unmarshalDate(data.due_date),
3303
+ id: data.id,
3304
+ invoiceType: data.invoice_type,
3305
+ issuedDate: unmarshalDate(data.issued_date),
3306
+ number: data.number,
3307
+ startDate: unmarshalDate(data.start_date),
3308
+ totalTaxed: data.total_taxed ? unmarshalMoney(data.total_taxed) : undefined,
3309
+ totalUntaxed: data.total_untaxed ? unmarshalMoney(data.total_untaxed) : undefined
3310
+ };
3311
+ };
3312
+ const unmarshalGetConsumptionResponse = data => {
3313
+ if (!isJSONObject(data)) {
3314
+ throw new TypeError(`Unmarshalling the type 'GetConsumptionResponse' failed as data isn't a dictionary.`);
3315
+ }
3316
+ return {
3317
+ consumptions: unmarshalArrayOfObject(data.consumptions, unmarshalGetConsumptionResponseConsumption),
3318
+ updatedAt: unmarshalDate(data.updated_at)
3319
+ };
3320
+ };
3321
+ const unmarshalListInvoicesResponse = data => {
3322
+ if (!isJSONObject(data)) {
3323
+ throw new TypeError(`Unmarshalling the type 'ListInvoicesResponse' failed as data isn't a dictionary.`);
3324
+ }
3325
+ return {
3326
+ invoices: unmarshalArrayOfObject(data.invoices, unmarshalInvoice),
3327
+ totalCount: data.total_count
3328
+ };
3329
+ };
3330
+
3331
+ // This file was automatically generated. DO NOT EDIT.
3332
+ /**
3333
+ * Billing API.
3334
+ *
3335
+ * This API allows you to query your consumption. Billing API.
3336
+ */
3337
+ let API$m = class API extends API$q {
3338
+ getConsumption = (request = {}) => this.client.fetch({
3339
+ method: 'GET',
3340
+ path: `/billing/v2alpha1/consumption`,
3341
+ urlParams: urlParams(['organization_id', request.organizationId ?? this.client.settings.defaultOrganizationId])
3342
+ }, unmarshalGetConsumptionResponse);
3343
+ pageOfListInvoices = (request = {}) => this.client.fetch({
3344
+ method: 'GET',
3345
+ path: `/billing/v2alpha1/invoices`,
3346
+ urlParams: urlParams(['invoice_type', request.invoiceType ?? 'unknown_type'], ['order_by', request.orderBy ?? 'invoice_number_desc'], ['organization_id', request.organizationId], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['started_after', request.startedAfter], ['started_before', request.startedBefore])
3347
+ }, unmarshalListInvoicesResponse);
3348
+ listInvoices = (request = {}) => enrichForPagination('invoices', this.pageOfListInvoices, request);
3349
+ downloadInvoice = request => this.client.fetch({
3350
+ method: 'GET',
3351
+ path: `/billing/v2alpha1/invoices/${validatePathParam('invoiceId', request.invoiceId)}/download`,
3352
+ urlParams: urlParams(['dl', 1], ['file_type', request.fileType ?? 'pdf']),
3353
+ responseType: 'blob'
3354
+ });
3355
+ };
3356
+
3357
+ // This file was automatically generated. DO NOT EDIT.
3358
+
3359
+ var index_gen$j = /*#__PURE__*/Object.freeze({
3360
+ __proto__: null,
3361
+ API: API$m
3362
+ });
3363
+
3398
3364
  var index$o = /*#__PURE__*/Object.freeze({
3399
3365
  __proto__: null,
3400
- v1: index$p
3366
+ v2alpha1: index_gen$j
3401
3367
  });
3402
3368
 
3403
3369
  // This file was automatically generated. DO NOT EDIT.
@@ -3546,7 +3512,7 @@ const marshalCreateGrafanaUserRequest = (request, defaults) => ({
3546
3512
  role: request.role ?? 'unknown_role'
3547
3513
  });
3548
3514
  const marshalCreateTokenRequest$2 = (request, defaults) => ({
3549
- name: request.name,
3515
+ name: request.name || randomName('token'),
3550
3516
  project_id: request.projectId ?? defaults.defaultProjectId,
3551
3517
  scopes: request.scopes ? marshalTokenScopes(request.scopes) : undefined
3552
3518
  });
@@ -3586,7 +3552,7 @@ const jsonContentHeaders$j = {
3586
3552
  *
3587
3553
  * This API allows to manage Cockpits. Cockpit API.
3588
3554
  */
3589
- let API$l = class API extends API$p {
3555
+ let API$l = class API extends API$q {
3590
3556
  /**
3591
3557
  * Activate a cockpit. Activate a cockpit associated with the given project
3592
3558
  * ID.
@@ -3656,7 +3622,7 @@ let API$l = class API extends API$p {
3656
3622
  * @param request - The request {@link CreateTokenRequest}
3657
3623
  * @returns A Promise of Token
3658
3624
  */
3659
- createToken = request => this.client.fetch({
3625
+ createToken = (request = {}) => this.client.fetch({
3660
3626
  body: JSON.stringify(marshalCreateTokenRequest$2(request, this.client.settings)),
3661
3627
  headers: jsonContentHeaders$j,
3662
3628
  method: 'POST',
@@ -4111,7 +4077,7 @@ const jsonContentHeaders$i = {
4111
4077
  *
4112
4078
  * Serverless Containers API. Containers API.
4113
4079
  */
4114
- let API$k = class API extends API$p {
4080
+ let API$k = class API extends API$q {
4115
4081
  /** Lists the available regions of the API. */
4116
4082
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
4117
4083
  pageOfListNamespaces = (request = {}) => this.client.fetch({
@@ -5697,7 +5663,7 @@ const jsonContentHeaders$h = {
5697
5663
  *
5698
5664
  * DNS API. Manage your DNS zones and records.
5699
5665
  */
5700
- let API$j = class API extends API$p {
5666
+ let API$j = class API extends API$q {
5701
5667
  pageOfListDNSZones = request => this.client.fetch({
5702
5668
  method: 'GET',
5703
5669
  path: `/domain/v2beta1/dns-zones`,
@@ -6041,7 +6007,7 @@ let API$j = class API extends API$p {
6041
6007
  *
6042
6008
  * Domains registrar API. Manage your domains and contacts.
6043
6009
  */
6044
- class RegistrarAPI extends API$p {
6010
+ class RegistrarAPI extends API$q {
6045
6011
  pageOfListTasks = (request = {}) => this.client.fetch({
6046
6012
  method: 'GET',
6047
6013
  path: `/domain/v2beta1/tasks`,
@@ -6569,7 +6535,7 @@ const jsonContentHeaders$g = {
6569
6535
  };
6570
6536
 
6571
6537
  /** Flexible IP API. */
6572
- let API$i = class API extends API$p {
6538
+ let API$i = class API extends API$q {
6573
6539
  /** Lists the available zones of the API. */
6574
6540
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1'];
6575
6541
 
@@ -6694,6 +6660,14 @@ let API$i = class API extends API$p {
6694
6660
  method: 'POST',
6695
6661
  path: `/flexible-ip/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/fips/${validatePathParam('fipId', request.fipId)}/mac/duplicate`
6696
6662
  }, unmarshalFlexibleIP);
6663
+
6664
+ /**
6665
+ * Move a virtual MAC. Move a Virtual MAC from a given Flexible IP onto
6666
+ * another Flexible IP.
6667
+ *
6668
+ * @param request - The request {@link MoveMACAddrRequest}
6669
+ * @returns A Promise of FlexibleIP
6670
+ */
6697
6671
  moveMACAddr = request => this.client.fetch({
6698
6672
  body: JSON.stringify(marshalMoveMACAddrRequest(request, this.client.settings)),
6699
6673
  headers: jsonContentHeaders$g,
@@ -6781,6 +6755,7 @@ const unmarshalTriggerMnqNatsClientConfig = data => {
6781
6755
  throw new TypeError(`Unmarshalling the type 'TriggerMnqNatsClientConfig' failed as data isn't a dictionary.`);
6782
6756
  }
6783
6757
  return {
6758
+ mnqCredentialId: data.mnq_credential_id,
6784
6759
  mnqNamespaceId: data.mnq_namespace_id,
6785
6760
  mnqProjectId: data.mnq_project_id,
6786
6761
  mnqRegion: data.mnq_region,
@@ -6792,6 +6767,7 @@ const unmarshalTriggerMnqSqsClientConfig = data => {
6792
6767
  throw new TypeError(`Unmarshalling the type 'TriggerMnqSqsClientConfig' failed as data isn't a dictionary.`);
6793
6768
  }
6794
6769
  return {
6770
+ mnqCredentialId: data.mnq_credential_id,
6795
6771
  mnqNamespaceId: data.mnq_namespace_id,
6796
6772
  mnqProjectId: data.mnq_project_id,
6797
6773
  mnqRegion: data.mnq_region,
@@ -6904,6 +6880,7 @@ const unmarshalRuntime = data => {
6904
6880
  extension: data.extension,
6905
6881
  implementation: data.implementation,
6906
6882
  language: data.language,
6883
+ logoUrl: data.logo_url,
6907
6884
  name: data.name,
6908
6885
  status: data.status,
6909
6886
  statusMessage: data.status_message,
@@ -7180,7 +7157,7 @@ const jsonContentHeaders$f = {
7180
7157
  *
7181
7158
  * Serverless functions API. Functions API.
7182
7159
  */
7183
- let API$h = class API extends API$p {
7160
+ let API$h = class API extends API$q {
7184
7161
  /** Lists the available regions of the API. */
7185
7162
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
7186
7163
  pageOfListNamespaces = (request = {}) => this.client.fetch({
@@ -8027,7 +8004,7 @@ const jsonContentHeaders$e = {
8027
8004
  };
8028
8005
 
8029
8006
  /** IAM API. */
8030
- let API$g = class API extends API$p {
8007
+ let API$g = class API extends API$q {
8031
8008
  pageOfListSSHKeys = (request = {}) => this.client.fetch({
8032
8009
  method: 'GET',
8033
8010
  path: `/iam/v1alpha1/ssh-keys`,
@@ -8410,6 +8387,14 @@ let API$g = class API extends API$p {
8410
8387
  method: 'DELETE',
8411
8388
  path: `/iam/v1alpha1/policies/${validatePathParam('policyId', request.policyId)}`
8412
8389
  });
8390
+
8391
+ /**
8392
+ * Clone a policy. Clone a policy. You must define specify the `policy_id`
8393
+ * parameter in your request.
8394
+ *
8395
+ * @param request - The request {@link ClonePolicyRequest}
8396
+ * @returns A Promise of Policy
8397
+ */
8413
8398
  clonePolicy = request => this.client.fetch({
8414
8399
  body: '{}',
8415
8400
  headers: jsonContentHeaders$e,
@@ -10193,7 +10178,7 @@ const jsonContentHeaders$d = {
10193
10178
  };
10194
10179
 
10195
10180
  /** Instance API. */
10196
- let API$f = class API extends API$p {
10181
+ let API$f = class API extends API$q {
10197
10182
  /** Lists the available zones of the API. */
10198
10183
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'fr-par-3', 'nl-ams-1', 'nl-ams-2', 'pl-waw-1', 'pl-waw-2'];
10199
10184
 
@@ -11834,7 +11819,7 @@ const jsonContentHeaders$c = {
11834
11819
  *
11835
11820
  * This API allows you to manage IoT hubs and devices. IoT API.
11836
11821
  */
11837
- let API$e = class API extends API$p {
11822
+ let API$e = class API extends API$q {
11838
11823
  /** Lists the available regions of the API. */
11839
11824
  static LOCALITIES = ['fr-par'];
11840
11825
  pageOfListHubs = (request = {}) => this.client.fetch({
@@ -12397,6 +12382,7 @@ const unmarshalCluster$1 = data => {
12397
12382
  name: data.name,
12398
12383
  openIdConnectConfig: data.open_id_connect_config ? unmarshalClusterOpenIDConnectConfig(data.open_id_connect_config) : undefined,
12399
12384
  organizationId: data.organization_id,
12385
+ privateNetworkId: data.private_network_id,
12400
12386
  projectId: data.project_id,
12401
12387
  region: data.region,
12402
12388
  status: data.status,
@@ -12625,6 +12611,7 @@ const marshalCreateClusterRequest$1 = (request, defaults) => ({
12625
12611
  name: request.name || randomName('k8s'),
12626
12612
  open_id_connect_config: request.openIdConnectConfig ? marshalCreateClusterRequestOpenIDConnectConfig(request.openIdConnectConfig) : undefined,
12627
12613
  pools: request.pools ? request.pools.map(elt => marshalCreateClusterRequestPoolConfig(elt)) : undefined,
12614
+ private_network_id: request.privateNetworkId,
12628
12615
  tags: request.tags,
12629
12616
  type: request.type,
12630
12617
  version: request.version,
@@ -12655,6 +12642,9 @@ const marshalCreatePoolRequest = (request, defaults) => ({
12655
12642
  upgrade_policy: request.upgradePolicy ? marshalCreatePoolRequestUpgradePolicy(request.upgradePolicy) : undefined,
12656
12643
  zone: request.zone ?? defaults.defaultZone
12657
12644
  });
12645
+ const marshalSetClusterTypeRequest = (request, defaults) => ({
12646
+ type: request.type
12647
+ });
12658
12648
  const marshalUpdateClusterRequest$1 = (request, defaults) => ({
12659
12649
  admission_plugins: request.admissionPlugins,
12660
12650
  apiserver_cert_sans: request.apiserverCertSans,
@@ -12692,7 +12682,7 @@ const jsonContentHeaders$b = {
12692
12682
  };
12693
12683
 
12694
12684
  /** Kapsule API. */
12695
- let API$d = class API extends API$p {
12685
+ let API$d = class API extends API$q {
12696
12686
  /** Lists the available regions of the API. */
12697
12687
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
12698
12688
  pageOfListClusters = (request = {}) => this.client.fetch({
@@ -12789,6 +12779,19 @@ let API$d = class API extends API$p {
12789
12779
  path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}/upgrade`
12790
12780
  }, unmarshalCluster$1);
12791
12781
 
12782
+ /**
12783
+ * Change type of a cluster. Change type of a specific Kubernetes cluster.
12784
+ *
12785
+ * @param request - The request {@link SetClusterTypeRequest}
12786
+ * @returns A Promise of Cluster
12787
+ */
12788
+ setClusterType = request => this.client.fetch({
12789
+ body: JSON.stringify(marshalSetClusterTypeRequest(request, this.client.settings)),
12790
+ headers: jsonContentHeaders$b,
12791
+ method: 'POST',
12792
+ path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}/set-type`
12793
+ }, unmarshalCluster$1);
12794
+
12792
12795
  /**
12793
12796
  * List available versions for a cluster. List the versions that a specific
12794
12797
  * Kubernetes cluster is allowed to upgrade to. Results will comprise every
@@ -14198,7 +14201,7 @@ const jsonContentHeaders$a = {
14198
14201
  *
14199
14202
  * This API allows you to manage your load balancer service. Load balancer API.
14200
14203
  */
14201
- let API$c = class API extends API$p {
14204
+ let API$c = class API extends API$q {
14202
14205
  /** Lists the available regions of the API. */
14203
14206
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
14204
14207
  pageOfListLbs = (request = {}) => this.client.fetch({
@@ -14867,7 +14870,7 @@ let API$c = class API extends API$p {
14867
14870
  * This API allows you to manage your Scaleway Load Balancer services. Load
14868
14871
  * Balancer API.
14869
14872
  */
14870
- class ZonedAPI extends API$p {
14873
+ class ZonedAPI extends API$q {
14871
14874
  /** Lists the available zones of the API. */
14872
14875
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1', 'nl-ams-2', 'pl-waw-1', 'pl-waw-2'];
14873
14876
  pageOfListLbs = (request = {}) => this.client.fetch({
@@ -15844,7 +15847,7 @@ const unmarshalListVersionsResponse$1 = data => {
15844
15847
 
15845
15848
  // This file was automatically generated. DO NOT EDIT.
15846
15849
  /** Marketplace API. */
15847
- let API$b = class API extends API$p {
15850
+ let API$b = class API extends API$q {
15848
15851
  pageOfListImages = (request = {}) => this.client.fetch({
15849
15852
  method: 'GET',
15850
15853
  path: `/marketplace/v1/images`,
@@ -15976,7 +15979,7 @@ const unmarshalListVersionsResponse = data => {
15976
15979
 
15977
15980
  // This file was automatically generated. DO NOT EDIT.
15978
15981
  /** Marketplace API. */
15979
- let API$a = class API extends API$p {
15982
+ let API$a = class API extends API$q {
15980
15983
  pageOfListImages = request => this.client.fetch({
15981
15984
  method: 'GET',
15982
15985
  path: `/marketplace/v2/images`,
@@ -16198,7 +16201,7 @@ const jsonContentHeaders$9 = {
16198
16201
  *
16199
16202
  * This API allows you to manage Messaging or Queueing brokers. MnQ API (beta).
16200
16203
  */
16201
- let API$9 = class API extends API$p {
16204
+ let API$9 = class API extends API$q {
16202
16205
  /** Lists the available regions of the API. */
16203
16206
  static LOCALITIES = ['fr-par'];
16204
16207
  pageOfListNamespaces = (request = {}) => this.client.fetch({
@@ -17043,7 +17046,7 @@ const jsonContentHeaders$8 = {
17043
17046
  };
17044
17047
 
17045
17048
  /** Managed Database for PostgreSQL and MySQL API. */
17046
- let API$8 = class API extends API$p {
17049
+ let API$8 = class API extends API$q {
17047
17050
  /** Lists the available regions of the API. */
17048
17051
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
17049
17052
  pageOfListDatabaseEngines = (request = {}) => this.client.fetch({
@@ -17068,8 +17071,8 @@ let API$8 = class API extends API$p {
17068
17071
 
17069
17072
  /**
17070
17073
  * List available node types. List all available node types. By default, the
17071
- * databases returned in the list are ordered by creation date in ascending
17072
- * order, though this can be modified via the order_by field.
17074
+ * node types returned in the list are ordered by creation date in ascending
17075
+ * order, though this can be modified via the `order_by` field.
17073
17076
  *
17074
17077
  * @param request - The request {@link ListNodeTypesRequest}
17075
17078
  * @returns A Promise of ListNodeTypesResponse
@@ -17082,7 +17085,7 @@ let API$8 = class API extends API$p {
17082
17085
  }, unmarshalListDatabaseBackupsResponse);
17083
17086
 
17084
17087
  /**
17085
- * List database backups. List all backups in a specified zone, for a given
17088
+ * List database backups. List all backups in a specified region, for a given
17086
17089
  * Scaleway Organization or Scaleway Project. By default, the backups listed
17087
17090
  * are ordered by creation date in ascending order. This can be modified via
17088
17091
  * the `order_by` field.
@@ -17207,9 +17210,9 @@ let API$8 = class API extends API$p {
17207
17210
  }, unmarshalListInstancesResponse);
17208
17211
 
17209
17212
  /**
17210
- * List Database Instances. List all Database Instances in the specified zone,
17211
- * for a given Scaleway Organization or Scaleway Project. By default, the
17212
- * Database Instances returned in the list are ordered by creation date in
17213
+ * List Database Instances. List all Database Instances in the specified
17214
+ * region, for a given Scaleway Organization or Scaleway Project. By default,
17215
+ * the Database Instances returned in the list are ordered by creation date in
17213
17216
  * ascending order, though this can be modified via the order_by field. You
17214
17217
  * can define additional parameters for your query, such as `tags` and `name`.
17215
17218
  * For the `name` parameter, the value you include will be checked against the
@@ -17351,7 +17354,7 @@ let API$8 = class API extends API$p {
17351
17354
  });
17352
17355
 
17353
17356
  /**
17354
- * Get Database Instance metrics. Retrieve the time series metrics of a give
17357
+ * Get Database Instance metrics. Retrieve the time series metrics of a given
17355
17358
  * Database Instance. You can define the period from which to retrieve metrics
17356
17359
  * by specifying the `start_date` and `end_date`.
17357
17360
  *
@@ -17772,10 +17775,10 @@ let API$8 = class API extends API$p {
17772
17775
 
17773
17776
  /**
17774
17777
  * List snapshots. List snapshots. You can include the `instance_id` or
17775
- * `project_id` in your query to get the list of snaphots for specific
17778
+ * `project_id` in your query to get the list of snapshots for specific
17776
17779
  * Database Instances and/or Projects. By default, the details returned in the
17777
17780
  * list are ordered by creation date in ascending order, though this can be
17778
- * modified via the order_by field.
17781
+ * modified via the `order_by` field.
17779
17782
  *
17780
17783
  * @param request - The request {@link ListSnapshotsRequest}
17781
17784
  * @returns A Promise of ListSnapshotsResponse
@@ -17868,7 +17871,7 @@ let API$8 = class API extends API$p {
17868
17871
 
17869
17872
  /**
17870
17873
  * Create a new Database Instance endpoint. Create a new endpoint for a
17871
- * Database Instance. You can add `load_balacer` and `private_network`
17874
+ * Database Instance. You can add `load_balancer` and `private_network`
17872
17875
  * specifications to the body of the request. Note that this action replaces
17873
17876
  * your current endpoint, which means you might need to update any environment
17874
17877
  * configurations that point to the old endpoint.
@@ -18227,12 +18230,15 @@ const jsonContentHeaders$7 = {
18227
18230
  };
18228
18231
 
18229
18232
  /** Managed Database for Redis™ API. */
18230
- let API$7 = class API extends API$p {
18233
+ let API$7 = class API extends API$q {
18231
18234
  /** Lists the available zones of the API. */
18232
18235
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1', 'nl-ams-2', 'pl-waw-1', 'pl-waw-2'];
18233
18236
 
18234
18237
  /**
18235
- * Create a cluster.
18238
+ * Create a Redis™ Database Instance. Create a new Redis™ Database Instance
18239
+ * (Redis™ cluster). You must set the `zone`, `project_id`, `version`,
18240
+ * `node_type`, `user_name` and `password` parameters. Optionally you can
18241
+ * define `acl_rules`, `endpoints`, `tls_enabled` and `cluster_settings`.
18236
18242
  *
18237
18243
  * @param request - The request {@link CreateClusterRequest}
18238
18244
  * @returns A Promise of Cluster
@@ -18245,7 +18251,9 @@ let API$7 = class API extends API$p {
18245
18251
  }, unmarshalCluster);
18246
18252
 
18247
18253
  /**
18248
- * Update a cluster.
18254
+ * Update a Redis™ Database Instance. Update the parameters of a Redis™
18255
+ * Database Instance (Redis™ cluster), including `name`, `tags`, `user_name`
18256
+ * and `password`.
18249
18257
  *
18250
18258
  * @param request - The request {@link UpdateClusterRequest}
18251
18259
  * @returns A Promise of Cluster
@@ -18258,7 +18266,11 @@ let API$7 = class API extends API$p {
18258
18266
  }, unmarshalCluster);
18259
18267
 
18260
18268
  /**
18261
- * Get a cluster.
18269
+ * Get a Redis™ Database Instance. Retrieve information about a Redis™
18270
+ * Database Instance (Redis™ cluster). Specify the `cluster_id` and `region`
18271
+ * in your request to get information such as `id`, `status`, `version`,
18272
+ * `tls_enabled`, `cluster_settings`, `upgradable_versions` and `endpoints`
18273
+ * about your cluster in the response.
18262
18274
  *
18263
18275
  * @param request - The request {@link GetClusterRequest}
18264
18276
  * @returns A Promise of Cluster
@@ -18283,7 +18295,12 @@ let API$7 = class API extends API$p {
18283
18295
  }, unmarshalListClustersResponse);
18284
18296
 
18285
18297
  /**
18286
- * List clusters.
18298
+ * List Redis™ Database Instances. List all Redis™ Database Instances (Redis™
18299
+ * cluster) in the specified zone. By default, the Database Instances returned
18300
+ * in the list are ordered by creation date in ascending order, though this
18301
+ * can be modified via the order_by field. You can define additional
18302
+ * parameters for your query, such as `tags`, `name`, `organization_id` and
18303
+ * `version`.
18287
18304
  *
18288
18305
  * @param request - The request {@link ListClustersRequest}
18289
18306
  * @returns A Promise of ListClustersResponse
@@ -18291,11 +18308,13 @@ let API$7 = class API extends API$p {
18291
18308
  listClusters = (request = {}) => enrichForPagination('clusters', this.pageOfListClusters, request);
18292
18309
 
18293
18310
  /**
18294
- * Migrate your cluster architecture. Upgrade your Database for Redis® cluster
18295
- * to a new version or scale it vertically / horizontally. Please note:
18296
- * scaling horizontally your Database for Redis® cluster won't renew its TLS
18297
- * certificate. In order to refresh the SSL certificate, you have to use the
18298
- * dedicated api route.
18311
+ * Scale up a Redis™ Database Instance. Upgrade your standalone Redis
18312
+ * Database Instance node, either by upgrading to a bigger node type (vertical
18313
+ * scaling) or by adding more nodes to your Database Instance to increase your
18314
+ * number of endpoints and distribute cache (horizontal scaling). Note that
18315
+ * scaling horizontally your Redis™ Database Instance will not renew its TLS
18316
+ * certificate. In order to refresh the TLS certificate, you must use the
18317
+ * Renew TLS certificate endpoint.
18299
18318
  *
18300
18319
  * @param request - The request {@link MigrateClusterRequest}
18301
18320
  * @returns A Promise of Cluster
@@ -18308,7 +18327,10 @@ let API$7 = class API extends API$p {
18308
18327
  }, unmarshalCluster);
18309
18328
 
18310
18329
  /**
18311
- * Delete a cluster.
18330
+ * Delete a Redis™ Database Instance. Delete a Redis™ Database Instance
18331
+ * (Redis™ cluster), specified by the `region` and `cluster_id` parameters.
18332
+ * Deleting a Database Instance is permanent, and cannot be undone. Note that
18333
+ * upon deletion all your data will be lost.
18312
18334
  *
18313
18335
  * @param request - The request {@link DeleteClusterRequest}
18314
18336
  * @returns A Promise of Cluster
@@ -18319,7 +18341,9 @@ let API$7 = class API extends API$p {
18319
18341
  }, unmarshalCluster);
18320
18342
 
18321
18343
  /**
18322
- * Get metrics of a cluster.
18344
+ * Get metrics of a Redis™ Database Instance. Retrieve the metrics of a Redis™
18345
+ * Database Instance (Redis™ cluster). You can define the period from which to
18346
+ * retrieve metrics by specifying the `start_date` and `end_date`.
18323
18347
  *
18324
18348
  * @param request - The request {@link GetClusterMetricsRequest}
18325
18349
  * @returns A Promise of ClusterMetricsResponse
@@ -18336,7 +18360,9 @@ let API$7 = class API extends API$p {
18336
18360
  }, unmarshalListNodeTypesResponse);
18337
18361
 
18338
18362
  /**
18339
- * List available node types.
18363
+ * List available node types. List all available node types. By default, the
18364
+ * node types returned in the list are ordered by creation date in ascending
18365
+ * order, though this can be modified via the `order_by` field.
18340
18366
  *
18341
18367
  * @param request - The request {@link ListNodeTypesRequest}
18342
18368
  * @returns A Promise of ListNodeTypesResponse
@@ -18349,7 +18375,9 @@ let API$7 = class API extends API$p {
18349
18375
  }, unmarshalListClusterVersionsResponse);
18350
18376
 
18351
18377
  /**
18352
- * List available Redis™ versions.
18378
+ * List available Redis™ versions. List the Redis™ database engine versions
18379
+ * available. You can define additional parameters for your query, such as
18380
+ * `include_disabled`, `include_beta`, `include_deprecated` and `version`.
18353
18381
  *
18354
18382
  * @param request - The request {@link ListClusterVersionsRequest}
18355
18383
  * @returns A Promise of ListClusterVersionsResponse
@@ -18357,7 +18385,9 @@ let API$7 = class API extends API$p {
18357
18385
  listClusterVersions = request => enrichForPagination('versions', this.pageOfListClusterVersions, request);
18358
18386
 
18359
18387
  /**
18360
- * Get the TLS certificate of a cluster.
18388
+ * Get the TLS certificate of a cluster. Retrieve information about the TLS
18389
+ * certificate of a Redis™ Database Instance (Redis™ cluster). Details like
18390
+ * name and content are returned in the response.
18361
18391
  *
18362
18392
  * @param request - The request {@link GetClusterCertificateRequest}
18363
18393
  * @returns A Promise of Blob
@@ -18370,7 +18400,11 @@ let API$7 = class API extends API$p {
18370
18400
  });
18371
18401
 
18372
18402
  /**
18373
- * Renew the TLS certificate of a cluster.
18403
+ * Renew the TLS certificate of a cluster. Renew a TLS certificate for a
18404
+ * Redis™ Database Instance (Redis™ cluster). Renewing a certificate means
18405
+ * that you will not be able to connect to your Database Instance using the
18406
+ * previous certificate. You will also need to download and update the new
18407
+ * certificate for all database clients.
18374
18408
  *
18375
18409
  * @param request - The request {@link RenewClusterCertificateRequest}
18376
18410
  * @returns A Promise of Cluster
@@ -18383,7 +18417,9 @@ let API$7 = class API extends API$p {
18383
18417
  }, unmarshalCluster);
18384
18418
 
18385
18419
  /**
18386
- * Add cluster settings.
18420
+ * Add advanced settings. Add an advanced setting to a Redis™ Database
18421
+ * Instance (Redis™ cluster). You must set the `name` and the `value` of each
18422
+ * setting.
18387
18423
  *
18388
18424
  * @param request - The request {@link AddClusterSettingsRequest}
18389
18425
  * @returns A Promise of ClusterSettingsResponse
@@ -18396,7 +18432,9 @@ let API$7 = class API extends API$p {
18396
18432
  }, unmarshalClusterSettingsResponse);
18397
18433
 
18398
18434
  /**
18399
- * Delete a cluster setting.
18435
+ * Delete advanced setting. Delete an advanced setting in a Redis™ Database
18436
+ * Instance (Redis™ cluster). You must specify the names of the settings you
18437
+ * want to delete in the request body.
18400
18438
  *
18401
18439
  * @param request - The request {@link DeleteClusterSettingRequest}
18402
18440
  * @returns A Promise of Cluster
@@ -18407,7 +18445,9 @@ let API$7 = class API extends API$p {
18407
18445
  }, unmarshalCluster);
18408
18446
 
18409
18447
  /**
18410
- * Set cluster settings.
18448
+ * Set advanced settings. Update an advanced setting for a Redis™ Database
18449
+ * Instance (Redis™ cluster). Settings added upon database engine
18450
+ * initalization can only be defined once, and cannot, therefore, be updated.
18411
18451
  *
18412
18452
  * @param request - The request {@link SetClusterSettingsRequest}
18413
18453
  * @returns A Promise of ClusterSettingsResponse
@@ -18420,7 +18460,8 @@ let API$7 = class API extends API$p {
18420
18460
  }, unmarshalClusterSettingsResponse);
18421
18461
 
18422
18462
  /**
18423
- * Set ACL rules for a given cluster.
18463
+ * Set ACL rules for a cluster. Replace all the ACL rules of a Redis™ Database
18464
+ * Instance (Redis™ cluster).
18424
18465
  *
18425
18466
  * @param request - The request {@link SetAclRulesRequest}
18426
18467
  * @returns A Promise of SetAclRulesResponse
@@ -18433,7 +18474,8 @@ let API$7 = class API extends API$p {
18433
18474
  }, unmarshalSetAclRulesResponse);
18434
18475
 
18435
18476
  /**
18436
- * Add ACL rules for a given cluster.
18477
+ * Add ACL rules for a cluster. Add an additional ACL rule to a Redis™
18478
+ * Database Instance (Redis™ cluster).
18437
18479
  *
18438
18480
  * @param request - The request {@link AddAclRulesRequest}
18439
18481
  * @returns A Promise of AddAclRulesResponse
@@ -18446,7 +18488,9 @@ let API$7 = class API extends API$p {
18446
18488
  }, unmarshalAddAclRulesResponse);
18447
18489
 
18448
18490
  /**
18449
- * Delete an ACL rule for a given cluster.
18491
+ * Delete an ACL rule for a cluster. Delete an ACL rule of a Redis™ Database
18492
+ * Instance (Redis™ cluster). You must specify the `acl_id` of the rule you
18493
+ * want to delete in your request.
18450
18494
  *
18451
18495
  * @param request - The request {@link DeleteAclRuleRequest}
18452
18496
  * @returns A Promise of Cluster
@@ -18457,7 +18501,9 @@ let API$7 = class API extends API$p {
18457
18501
  }, unmarshalCluster);
18458
18502
 
18459
18503
  /**
18460
- * Get an ACL rule.
18504
+ * Get an ACL rule. Retrieve information about an ACL rule of a Redis™
18505
+ * Database Instance (Redis™ cluster). You must specify the `acl_id` of the
18506
+ * rule in your request.
18461
18507
  *
18462
18508
  * @param request - The request {@link GetAclRuleRequest}
18463
18509
  * @returns A Promise of ACLRule
@@ -18468,7 +18514,9 @@ let API$7 = class API extends API$p {
18468
18514
  }, unmarshalACLRule);
18469
18515
 
18470
18516
  /**
18471
- * Set endpoints for a given cluster.
18517
+ * Set endpoints for a cluster. Update an endpoint for a Redis™ Database
18518
+ * Instance (Redis™ cluster). You must specify the `cluster_id` and the
18519
+ * `endpoints` parameters in your request.
18472
18520
  *
18473
18521
  * @param request - The request {@link SetEndpointsRequest}
18474
18522
  * @returns A Promise of SetEndpointsResponse
@@ -18481,7 +18529,9 @@ let API$7 = class API extends API$p {
18481
18529
  }, unmarshalSetEndpointsResponse);
18482
18530
 
18483
18531
  /**
18484
- * Add endpoints for a given cluster.
18532
+ * Add endpoints for a cluster. Add a new endpoint for a Redis™ Database
18533
+ * Instance (Redis™ cluster). You can add `private_network` or
18534
+ * `public_network` specifications to the body of the request.
18485
18535
  *
18486
18536
  * @param request - The request {@link AddEndpointsRequest}
18487
18537
  * @returns A Promise of AddEndpointsResponse
@@ -18494,7 +18544,10 @@ let API$7 = class API extends API$p {
18494
18544
  }, unmarshalAddEndpointsResponse);
18495
18545
 
18496
18546
  /**
18497
- * Delete an endpoint for a given cluster.
18547
+ * Delete an endpoint for a cluster. Delete the endpoint of a Redis™ Database
18548
+ * Instance (Redis™ cluster). You must specify the `region` and `endpoint_id`
18549
+ * parameters of the endpoint you want to delete. Note that might need to
18550
+ * update any environment configurations that point to the deleted endpoint.
18498
18551
  *
18499
18552
  * @param request - The request {@link DeleteEndpointRequest}
18500
18553
  * @returns A Promise of Cluster
@@ -18505,7 +18558,10 @@ let API$7 = class API extends API$p {
18505
18558
  }, unmarshalCluster);
18506
18559
 
18507
18560
  /**
18508
- * Get an endpoint.
18561
+ * Get an endpoint. Retrieve information about a Redis™ Database Instance
18562
+ * (Redis™ cluster) endpoint. Full details about the endpoint, like `ips`,
18563
+ * `port`, `private_network` and `public_network` specifications are returned
18564
+ * in the response.
18509
18565
  *
18510
18566
  * @param request - The request {@link GetEndpointRequest}
18511
18567
  * @returns A Promise of Endpoint
@@ -18514,6 +18570,16 @@ let API$7 = class API extends API$p {
18514
18570
  method: 'GET',
18515
18571
  path: `/redis/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/endpoints/${validatePathParam('endpointId', request.endpointId)}`
18516
18572
  }, unmarshalEndpoint);
18573
+
18574
+ /**
18575
+ * Update an endpoint. Update information about a Redis™ Database Instance
18576
+ * (Redis™ cluster) endpoint. Full details about the endpoint, like `ips`,
18577
+ * `port`, `private_network` and `public_network` specifications are returned
18578
+ * in the response.
18579
+ *
18580
+ * @param request - The request {@link UpdateEndpointRequest}
18581
+ * @returns A Promise of Endpoint
18582
+ */
18517
18583
  updateEndpoint = request => this.client.fetch({
18518
18584
  body: JSON.stringify(marshalUpdateEndpointRequest(request, this.client.settings)),
18519
18585
  headers: jsonContentHeaders$7,
@@ -18659,7 +18725,7 @@ const jsonContentHeaders$6 = {
18659
18725
  *
18660
18726
  * Container registry API. Registry API.
18661
18727
  */
18662
- let API$6 = class API extends API$p {
18728
+ let API$6 = class API extends API$q {
18663
18729
  /** Lists the available regions of the API. */
18664
18730
  static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
18665
18731
  pageOfListNamespaces = (request = {}) => this.client.fetch({
@@ -18937,17 +19003,17 @@ const jsonContentHeaders$5 = {
18937
19003
  };
18938
19004
 
18939
19005
  /**
18940
- * Secret API (beta).
19006
+ * Secret Manager API documentation.
18941
19007
  *
18942
19008
  * This API allows you to conveniently store, access and share sensitive data.
18943
- * Secret API (beta).
19009
+ * Secret Manager API documentation.
18944
19010
  */
18945
- let API$5 = class API extends API$p {
19011
+ let API$5 = class API extends API$q {
18946
19012
  /** Lists the available regions of the API. */
18947
19013
  static LOCALITIES = ['fr-par'];
18948
19014
 
18949
19015
  /**
18950
- * Create a Secret containing no versions.
19016
+ * Create a secret. You must sepcify the `region` to create a secret.
18951
19017
  *
18952
19018
  * @param request - The request {@link CreateSecretRequest}
18953
19019
  * @returns A Promise of Secret
@@ -18960,7 +19026,8 @@ let API$5 = class API extends API$p {
18960
19026
  }, unmarshalSecret);
18961
19027
 
18962
19028
  /**
18963
- * Get metadata of a Secret.
19029
+ * Get metadata using the secret's name. Retrieve the metadata of a secret
19030
+ * specified by the `region` and the `secret_name` parameters.
18964
19031
  *
18965
19032
  * @param request - The request {@link GetSecretRequest}
18966
19033
  * @returns A Promise of Secret
@@ -18971,7 +19038,8 @@ let API$5 = class API extends API$p {
18971
19038
  }, unmarshalSecret);
18972
19039
 
18973
19040
  /**
18974
- * Get metadata of a Secret.
19041
+ * Get metadata using the secret's ID. Retrieve the metadata of a secret
19042
+ * specified by the `region` and the `secret_id` parameters.
18975
19043
  *
18976
19044
  * @param request - The request {@link GetSecretByNameRequest}
18977
19045
  * @returns A Promise of Secret
@@ -18982,7 +19050,9 @@ let API$5 = class API extends API$p {
18982
19050
  }, unmarshalSecret);
18983
19051
 
18984
19052
  /**
18985
- * Update metadata of a Secret.
19053
+ * Update metadata of a secret. Edit a secret's metadata such as name, tag(s)
19054
+ * and description. The secret to update is specified by the `secret_id` and
19055
+ * `region` parameters.
18986
19056
  *
18987
19057
  * @param request - The request {@link UpdateSecretRequest}
18988
19058
  * @returns A Promise of Secret
@@ -19000,7 +19070,9 @@ let API$5 = class API extends API$p {
19000
19070
  }, unmarshalListSecretsResponse);
19001
19071
 
19002
19072
  /**
19003
- * List Secrets.
19073
+ * List secrets. Retrieve the list of secrets created within an Organization
19074
+ * and/or Project. You must specify either the `organization_id` or the
19075
+ * `project_id` and the `region`.
19004
19076
  *
19005
19077
  * @param request - The request {@link ListSecretsRequest}
19006
19078
  * @returns A Promise of ListSecretsResponse
@@ -19008,7 +19080,8 @@ let API$5 = class API extends API$p {
19008
19080
  listSecrets = (request = {}) => enrichForPagination('secrets', this.pageOfListSecrets, request);
19009
19081
 
19010
19082
  /**
19011
- * Delete a secret.
19083
+ * Delete a secret. Delete a given secret specified by the `region` and
19084
+ * `secret_id` parameters.
19012
19085
  *
19013
19086
  * @param request - The request {@link DeleteSecretRequest}
19014
19087
  */
@@ -19018,7 +19091,8 @@ let API$5 = class API extends API$p {
19018
19091
  });
19019
19092
 
19020
19093
  /**
19021
- * Create a SecretVersion.
19094
+ * Create a version. Create a version of a given secret specified by the
19095
+ * `region` and `secret_id` parameters.
19022
19096
  *
19023
19097
  * @param request - The request {@link CreateSecretVersionRequest}
19024
19098
  * @returns A Promise of SecretVersion
@@ -19031,7 +19105,9 @@ let API$5 = class API extends API$p {
19031
19105
  }, unmarshalSecretVersion);
19032
19106
 
19033
19107
  /**
19034
- * Get metadata of a SecretVersion.
19108
+ * Get metadata of a secret's version using the secret's ID. Retrieve the
19109
+ * metadata of a secret's given version specified by the `region`, `secret_id`
19110
+ * and `revision` parameters.
19035
19111
  *
19036
19112
  * @param request - The request {@link GetSecretVersionRequest}
19037
19113
  * @returns A Promise of SecretVersion
@@ -19042,7 +19118,9 @@ let API$5 = class API extends API$p {
19042
19118
  }, unmarshalSecretVersion);
19043
19119
 
19044
19120
  /**
19045
- * Get metadata of a SecretVersion.
19121
+ * Get metadata of a secret's version using the secret's name. Retrieve the
19122
+ * metadata of a secret's given version specified by the `region`,
19123
+ * `secret_name` and `revision` parameters.
19046
19124
  *
19047
19125
  * @param request - The request {@link GetSecretVersionByNameRequest}
19048
19126
  * @returns A Promise of SecretVersion
@@ -19053,7 +19131,8 @@ let API$5 = class API extends API$p {
19053
19131
  }, unmarshalSecretVersion);
19054
19132
 
19055
19133
  /**
19056
- * Update metadata of a SecretVersion.
19134
+ * Update metadata of a version. Edit the metadata of a secret's given
19135
+ * version, specified by the `region`, `secret_id` and `revision` parameters.
19057
19136
  *
19058
19137
  * @param request - The request {@link UpdateSecretVersionRequest}
19059
19138
  * @returns A Promise of SecretVersion
@@ -19071,7 +19150,9 @@ let API$5 = class API extends API$p {
19071
19150
  }, unmarshalListSecretVersionsResponse);
19072
19151
 
19073
19152
  /**
19074
- * List versions of a secret, not returning any sensitive data.
19153
+ * List versions of a secret using the secret's ID. Retrieve the list of a
19154
+ * given secret's versions specified by the `secret_id` and `region`
19155
+ * parameters.
19075
19156
  *
19076
19157
  * @param request - The request {@link ListSecretVersionsRequest}
19077
19158
  * @returns A Promise of ListSecretVersionsResponse
@@ -19084,7 +19165,9 @@ let API$5 = class API extends API$p {
19084
19165
  }, unmarshalListSecretVersionsResponse);
19085
19166
 
19086
19167
  /**
19087
- * List versions of a secret, not returning any sensitive data.
19168
+ * List versions of a secret using the secret's name. Retrieve the list of a
19169
+ * given secret's versions specified by the `secret_name` and `region`
19170
+ * parameters.
19088
19171
  *
19089
19172
  * @param request - The request {@link ListSecretVersionsByNameRequest}
19090
19173
  * @returns A Promise of ListSecretVersionsResponse
@@ -19092,7 +19175,8 @@ let API$5 = class API extends API$p {
19092
19175
  listSecretVersionsByName = request => enrichForPagination('versions', this.pageOfListSecretVersionsByName, request);
19093
19176
 
19094
19177
  /**
19095
- * Destroy a SecretVersion, permanently destroying the sensitive data.
19178
+ * Delete a version. Delete a secret's version and the sensitive data
19179
+ * contained in it. Deleting a version is permanent and cannot be undone.
19096
19180
  *
19097
19181
  * @param request - The request {@link DestroySecretVersionRequest}
19098
19182
  * @returns A Promise of SecretVersion
@@ -19105,7 +19189,8 @@ let API$5 = class API extends API$p {
19105
19189
  }, unmarshalSecretVersion);
19106
19190
 
19107
19191
  /**
19108
- * Enable a SecretVersion.
19192
+ * Enable a version. Make a specific version accessible. You must specify the
19193
+ * `region`, `secret_id` and `revision` parameters.
19109
19194
  *
19110
19195
  * @param request - The request {@link EnableSecretVersionRequest}
19111
19196
  * @returns A Promise of SecretVersion
@@ -19118,7 +19203,8 @@ let API$5 = class API extends API$p {
19118
19203
  }, unmarshalSecretVersion);
19119
19204
 
19120
19205
  /**
19121
- * Disable a SecretVersion.
19206
+ * Disable a version. Make a specific version inaccessible. You must specify
19207
+ * the `region`, `secret_id` and `revision` parameters.
19122
19208
  *
19123
19209
  * @param request - The request {@link DisableSecretVersionRequest}
19124
19210
  * @returns A Promise of SecretVersion
@@ -19131,7 +19217,9 @@ let API$5 = class API extends API$p {
19131
19217
  }, unmarshalSecretVersion);
19132
19218
 
19133
19219
  /**
19134
- * Access a SecretVersion, returning the sensitive data.
19220
+ * Access a secret's version using the secret's ID. Access sensitive data in a
19221
+ * secret's version specified by the `region`, `secret_id` and `revision`
19222
+ * parameters.
19135
19223
  *
19136
19224
  * @param request - The request {@link AccessSecretVersionRequest}
19137
19225
  * @returns A Promise of AccessSecretVersionResponse
@@ -19142,7 +19230,9 @@ let API$5 = class API extends API$p {
19142
19230
  }, unmarshalAccessSecretVersionResponse);
19143
19231
 
19144
19232
  /**
19145
- * Access a SecretVersion, returning the sensitive data.
19233
+ * Access a secret's version using the secret's name. Access sensitive data in
19234
+ * a secret's version specified by the `region`, `secret_name` and `revision`
19235
+ * parameters.
19146
19236
  *
19147
19237
  * @param request - The request {@link AccessSecretVersionByNameRequest}
19148
19238
  * @returns A Promise of AccessSecretVersionResponse
@@ -19266,7 +19356,7 @@ const jsonContentHeaders$4 = {
19266
19356
  * access-key. Then, you can use other test commands by setting the
19267
19357
  * SCW_SECRET_KEY env variable.
19268
19358
  */
19269
- let API$4 = class API extends API$p {
19359
+ let API$4 = class API extends API$q {
19270
19360
  /**
19271
19361
  * Register a user. Register a human and return a access-key and a secret-key
19272
19362
  * that must be used in all other commands.
@@ -19541,16 +19631,19 @@ const jsonContentHeaders$3 = {
19541
19631
  };
19542
19632
 
19543
19633
  /**
19544
- * Transactional Email API.
19634
+ * Transactional Email API documentation.
19545
19635
  *
19546
- * Tem. Transactional Email API.
19636
+ * Tem. Transactional Email API documentation.
19547
19637
  */
19548
- let API$3 = class API extends API$p {
19638
+ let API$3 = class API extends API$q {
19549
19639
  /** Lists the available regions of the API. */
19550
19640
  static LOCALITIES = ['fr-par'];
19551
19641
 
19552
19642
  /**
19553
- * Send an email.
19643
+ * Send an email. You must specify the `region`, the sender and the
19644
+ * recipient's information and the `project_id` to send an email from a
19645
+ * checked domain. The subject of the email must contain at least 6
19646
+ * characters.
19554
19647
  *
19555
19648
  * @param request - The request {@link CreateEmailRequest}
19556
19649
  * @returns A Promise of CreateEmailResponse
@@ -19563,7 +19656,8 @@ let API$3 = class API extends API$p {
19563
19656
  }, unmarshalCreateEmailResponse);
19564
19657
 
19565
19658
  /**
19566
- * Get information about an email.
19659
+ * Get an email. Retrieve information about a specific email using the
19660
+ * `email_id` and `region` parameters.
19567
19661
  *
19568
19662
  * @param request - The request {@link GetEmailRequest}
19569
19663
  * @returns A Promise of Email
@@ -19588,8 +19682,8 @@ let API$3 = class API extends API$p {
19588
19682
  }, unmarshalListEmailsResponse);
19589
19683
 
19590
19684
  /**
19591
- * List emails sent from a domain and/or for a project and/or for an
19592
- * organization.
19685
+ * List emails. Retrieve the list of emails sent from a specific domain or for
19686
+ * a specific Project or Organization. You must specify the `region`.
19593
19687
  *
19594
19688
  * @param request - The request {@link ListEmailsRequest}
19595
19689
  * @returns A Promise of ListEmailsResponse
@@ -19597,7 +19691,7 @@ let API$3 = class API extends API$p {
19597
19691
  listEmails = (request = {}) => enrichForPagination('emails', this.pageOfListEmails, request);
19598
19692
 
19599
19693
  /**
19600
- * Get statistics on the email statuses.
19694
+ * Email statuses. Get information on your emails' statuses.
19601
19695
  *
19602
19696
  * @param request - The request {@link GetStatisticsRequest}
19603
19697
  * @returns A Promise of Statistics
@@ -19609,7 +19703,9 @@ let API$3 = class API extends API$p {
19609
19703
  }, unmarshalStatistics);
19610
19704
 
19611
19705
  /**
19612
- * Try to cancel an email if it has not yet been sent.
19706
+ * Cancel an email. You can cancel the sending of an email if it has not been
19707
+ * sent yet. You must specify the `region` and the `email_id` of the email you
19708
+ * want to cancel.
19613
19709
  *
19614
19710
  * @param request - The request {@link CancelEmailRequest}
19615
19711
  * @returns A Promise of Email
@@ -19622,7 +19718,8 @@ let API$3 = class API extends API$p {
19622
19718
  }, unmarshalEmail);
19623
19719
 
19624
19720
  /**
19625
- * Register a domain in a project.
19721
+ * Register a domain in a project. You must specify the `region`, `project_id`
19722
+ * and `domain_name` to register a domain in a specific Project.
19626
19723
  *
19627
19724
  * @param request - The request {@link CreateDomainRequest}
19628
19725
  * @returns A Promise of Domain
@@ -19635,7 +19732,8 @@ let API$3 = class API extends API$p {
19635
19732
  }, unmarshalDomain);
19636
19733
 
19637
19734
  /**
19638
- * Get information about a domain.
19735
+ * Get information about a domain. Retrieve information about a specific
19736
+ * domain using the `region` and `domain_id` parameters.
19639
19737
  *
19640
19738
  * @param request - The request {@link GetDomainRequest}
19641
19739
  * @returns A Promise of Domain
@@ -19660,7 +19758,8 @@ let API$3 = class API extends API$p {
19660
19758
  }, unmarshalListDomainsResponse);
19661
19759
 
19662
19760
  /**
19663
- * List domains in a project and/or in an organization.
19761
+ * List domains. Retrieve domains in a specific project or in a specific
19762
+ * Organization using the `region` parameter.
19664
19763
  *
19665
19764
  * @param request - The request {@link ListDomainsRequest}
19666
19765
  * @returns A Promise of ListDomainsResponse
@@ -19668,7 +19767,9 @@ let API$3 = class API extends API$p {
19668
19767
  listDomains = (request = {}) => enrichForPagination('domains', this.pageOfListDomains, request);
19669
19768
 
19670
19769
  /**
19671
- * Revoke a domain.
19770
+ * Delete a domain. You must specify the domain you want to delete by the
19771
+ * `region` and `domain_id`. Deleting a domain is permanent and cannot be
19772
+ * undone.
19672
19773
  *
19673
19774
  * @param request - The request {@link RevokeDomainRequest}
19674
19775
  * @returns A Promise of Domain
@@ -19681,7 +19782,8 @@ let API$3 = class API extends API$p {
19681
19782
  }, unmarshalDomain);
19682
19783
 
19683
19784
  /**
19684
- * Ask for an immediate check of a domain (DNS check).
19785
+ * Domain DNS check. Perform an immediate DNS check of a domain using the
19786
+ * `region` and `domain_id` parameters.
19685
19787
  *
19686
19788
  * @param request - The request {@link CheckDomainRequest}
19687
19789
  * @returns A Promise of Domain
@@ -19752,7 +19854,7 @@ const jsonContentHeaders$2 = {
19752
19854
  };
19753
19855
 
19754
19856
  /** VPC API. */
19755
- let API$2 = class API extends API$p {
19857
+ let API$2 = class API extends API$q {
19756
19858
  /** Lists the available zones of the API. */
19757
19859
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'fr-par-3', 'nl-ams-1', 'nl-ams-2', 'pl-waw-1', 'pl-waw-2'];
19758
19860
  pageOfListPrivateNetworks = (request = {}) => this.client.fetch({
@@ -20178,7 +20280,7 @@ const jsonContentHeaders$1 = {
20178
20280
  };
20179
20281
 
20180
20282
  /** Public Gateways API. */
20181
- let API$1 = class API extends API$p {
20283
+ let API$1 = class API extends API$q {
20182
20284
  /** Lists the available zones of the API. */
20183
20285
  static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1', 'nl-ams-2', 'pl-waw-1', 'pl-waw-2'];
20184
20286
  pageOfListGateways = (request = {}) => this.client.fetch({
@@ -20883,7 +20985,7 @@ const jsonContentHeaders = {
20883
20985
  };
20884
20986
 
20885
20987
  /** Webhosting API. */
20886
- class API extends API$p {
20988
+ class API extends API$q {
20887
20989
  /** Lists the available regions of the API. */
20888
20990
  static LOCALITIES = ['fr-par'];
20889
20991
 
@@ -20958,7 +21060,7 @@ class API extends API$p {
20958
21060
  }, unmarshalHosting);
20959
21061
 
20960
21062
  /**
20961
- * Retore a hosting. Restore a hosting with the given ID.
21063
+ * Restore a hosting. Restore a hosting with the given ID.
20962
21064
  *
20963
21065
  * @param request - The request {@link RestoreHostingRequest}
20964
21066
  * @returns A Promise of Hosting
@@ -20971,7 +21073,8 @@ class API extends API$p {
20971
21073
  }, unmarshalHosting);
20972
21074
 
20973
21075
  /**
20974
- * Get the DNS records. Get the DNS records of a specified domain.
21076
+ * Get the DNS records. The set of DNS record of a specific domain associated
21077
+ * to a hosting.
20975
21078
  *
20976
21079
  * @param request - The request {@link GetDomainDnsRecordsRequest}
20977
21080
  * @returns A Promise of DnsRecords
@@ -21026,10 +21129,11 @@ var index = /*#__PURE__*/Object.freeze({
21026
21129
  v1alpha1: index_gen
21027
21130
  });
21028
21131
 
21029
- exports.API = API$p;
21030
- exports.Account = index$r;
21031
- exports.AppleSilicon = index$q;
21032
- exports.BareMetal = index$o;
21132
+ exports.API = API$q;
21133
+ exports.Account = index$s;
21134
+ exports.AppleSilicon = index$r;
21135
+ exports.BareMetal = index$p;
21136
+ exports.Billing = index$o;
21033
21137
  exports.Cockpit = index$n;
21034
21138
  exports.Container = index$m;
21035
21139
  exports.Domain = index$l;