@scaleway/sdk 2.24.0 → 2.25.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/api/cockpit/index.js +4 -2
- package/dist/api/cockpit/v1/api.gen.js +456 -0
- package/dist/api/cockpit/v1/index.gen.js +6 -0
- package/dist/api/cockpit/v1/marshalling.gen.js +253 -0
- package/dist/api/cockpit/v1/validation-rules.gen.js +46 -0
- package/dist/api/instance/v1/api.gen.js +1 -1
- package/dist/api/k8s/v1/marshalling.gen.js +1 -0
- package/dist/api/rdb/v1/marshalling.gen.js +1 -0
- package/dist/index.cjs +961 -195
- package/dist/index.d.ts +1244 -278
- package/dist/scw/constants.js +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -497,7 +497,7 @@ const assertValidSettings = obj => {
|
|
|
497
497
|
}
|
|
498
498
|
};
|
|
499
499
|
|
|
500
|
-
const version = 'v2.
|
|
500
|
+
const version = 'v2.24.0';
|
|
501
501
|
const userAgent = `scaleway-sdk-js/${version}`;
|
|
502
502
|
|
|
503
503
|
const isBrowser = () =>
|
|
@@ -2068,7 +2068,7 @@ const marshalUpdateProjectRequest = (request, defaults) => ({
|
|
|
2068
2068
|
|
|
2069
2069
|
// This file was automatically generated. DO NOT EDIT.
|
|
2070
2070
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2071
|
-
const jsonContentHeaders$
|
|
2071
|
+
const jsonContentHeaders$y = {
|
|
2072
2072
|
'Content-Type': 'application/json; charset=utf-8'
|
|
2073
2073
|
};
|
|
2074
2074
|
|
|
@@ -2089,7 +2089,7 @@ let API$y = class API extends API$z {
|
|
|
2089
2089
|
*/
|
|
2090
2090
|
createProject = (request = {}) => this.client.fetch({
|
|
2091
2091
|
body: JSON.stringify(marshalCreateProjectRequest(request, this.client.settings)),
|
|
2092
|
-
headers: jsonContentHeaders$
|
|
2092
|
+
headers: jsonContentHeaders$y,
|
|
2093
2093
|
method: 'POST',
|
|
2094
2094
|
path: `/account/v2/projects`
|
|
2095
2095
|
}, unmarshalProject$1);
|
|
@@ -2153,7 +2153,7 @@ let API$y = class API extends API$z {
|
|
|
2153
2153
|
*/
|
|
2154
2154
|
updateProject = (request = {}) => this.client.fetch({
|
|
2155
2155
|
body: JSON.stringify(marshalUpdateProjectRequest(request, this.client.settings)),
|
|
2156
|
-
headers: jsonContentHeaders$
|
|
2156
|
+
headers: jsonContentHeaders$y,
|
|
2157
2157
|
method: 'PATCH',
|
|
2158
2158
|
path: `/account/v2/projects/${validatePathParam('projectId', request.projectId ?? this.client.settings.defaultProjectId)}`
|
|
2159
2159
|
}, unmarshalProject$1);
|
|
@@ -2162,7 +2162,7 @@ let API$y = class API extends API$z {
|
|
|
2162
2162
|
// This file was automatically generated. DO NOT EDIT.
|
|
2163
2163
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2164
2164
|
|
|
2165
|
-
var index_gen$
|
|
2165
|
+
var index_gen$y = /*#__PURE__*/Object.freeze({
|
|
2166
2166
|
__proto__: null,
|
|
2167
2167
|
API: API$y
|
|
2168
2168
|
});
|
|
@@ -2203,7 +2203,7 @@ const marshalProjectApiUpdateProjectRequest = (request, defaults) => ({
|
|
|
2203
2203
|
|
|
2204
2204
|
// This file was automatically generated. DO NOT EDIT.
|
|
2205
2205
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2206
|
-
const jsonContentHeaders$
|
|
2206
|
+
const jsonContentHeaders$x = {
|
|
2207
2207
|
'Content-Type': 'application/json; charset=utf-8'
|
|
2208
2208
|
};
|
|
2209
2209
|
|
|
@@ -2222,7 +2222,7 @@ class ProjectAPI extends API$z {
|
|
|
2222
2222
|
*/
|
|
2223
2223
|
createProject = request => this.client.fetch({
|
|
2224
2224
|
body: JSON.stringify(marshalProjectApiCreateProjectRequest(request, this.client.settings)),
|
|
2225
|
-
headers: jsonContentHeaders$
|
|
2225
|
+
headers: jsonContentHeaders$x,
|
|
2226
2226
|
method: 'POST',
|
|
2227
2227
|
path: `/account/v3/projects`
|
|
2228
2228
|
}, unmarshalProject);
|
|
@@ -2278,7 +2278,7 @@ class ProjectAPI extends API$z {
|
|
|
2278
2278
|
*/
|
|
2279
2279
|
updateProject = (request = {}) => this.client.fetch({
|
|
2280
2280
|
body: JSON.stringify(marshalProjectApiUpdateProjectRequest(request, this.client.settings)),
|
|
2281
|
-
headers: jsonContentHeaders$
|
|
2281
|
+
headers: jsonContentHeaders$x,
|
|
2282
2282
|
method: 'PATCH',
|
|
2283
2283
|
path: `/account/v3/projects/${validatePathParam('projectId', request.projectId ?? this.client.settings.defaultProjectId)}`
|
|
2284
2284
|
}, unmarshalProject);
|
|
@@ -2322,7 +2322,7 @@ const ProjectApiUpdateProjectRequest = {
|
|
|
2322
2322
|
}
|
|
2323
2323
|
};
|
|
2324
2324
|
|
|
2325
|
-
var validationRules_gen$
|
|
2325
|
+
var validationRules_gen$i = /*#__PURE__*/Object.freeze({
|
|
2326
2326
|
__proto__: null,
|
|
2327
2327
|
ProjectApiCreateProjectRequest: ProjectApiCreateProjectRequest,
|
|
2328
2328
|
ProjectApiListProjectsRequest: ProjectApiListProjectsRequest,
|
|
@@ -2332,16 +2332,16 @@ var validationRules_gen$h = /*#__PURE__*/Object.freeze({
|
|
|
2332
2332
|
// This file was automatically generated. DO NOT EDIT.
|
|
2333
2333
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2334
2334
|
|
|
2335
|
-
var index_gen$
|
|
2335
|
+
var index_gen$x = /*#__PURE__*/Object.freeze({
|
|
2336
2336
|
__proto__: null,
|
|
2337
2337
|
ProjectAPI: ProjectAPI,
|
|
2338
|
-
ValidationRules: validationRules_gen$
|
|
2338
|
+
ValidationRules: validationRules_gen$i
|
|
2339
2339
|
});
|
|
2340
2340
|
|
|
2341
2341
|
var index$A = /*#__PURE__*/Object.freeze({
|
|
2342
2342
|
__proto__: null,
|
|
2343
|
-
v2: index_gen$
|
|
2344
|
-
v3: index_gen$
|
|
2343
|
+
v2: index_gen$y,
|
|
2344
|
+
v3: index_gen$x
|
|
2345
2345
|
});
|
|
2346
2346
|
|
|
2347
2347
|
// This file was automatically generated. DO NOT EDIT.
|
|
@@ -2460,7 +2460,7 @@ const marshalUpdateServerRequest$3 = (request, defaults) => ({
|
|
|
2460
2460
|
|
|
2461
2461
|
// This file was automatically generated. DO NOT EDIT.
|
|
2462
2462
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2463
|
-
const jsonContentHeaders$
|
|
2463
|
+
const jsonContentHeaders$w = {
|
|
2464
2464
|
'Content-Type': 'application/json; charset=utf-8'
|
|
2465
2465
|
};
|
|
2466
2466
|
|
|
@@ -2503,7 +2503,7 @@ let API$x = class API extends API$z {
|
|
|
2503
2503
|
*/
|
|
2504
2504
|
createServer = request => this.client.fetch({
|
|
2505
2505
|
body: JSON.stringify(marshalCreateServerRequest$3(request, this.client.settings)),
|
|
2506
|
-
headers: jsonContentHeaders$
|
|
2506
|
+
headers: jsonContentHeaders$w,
|
|
2507
2507
|
method: 'POST',
|
|
2508
2508
|
path: `/apple-silicon/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers`
|
|
2509
2509
|
}, unmarshalServer$3);
|
|
@@ -2581,7 +2581,7 @@ let API$x = class API extends API$z {
|
|
|
2581
2581
|
*/
|
|
2582
2582
|
updateServer = request => this.client.fetch({
|
|
2583
2583
|
body: JSON.stringify(marshalUpdateServerRequest$3(request, this.client.settings)),
|
|
2584
|
-
headers: jsonContentHeaders$
|
|
2584
|
+
headers: jsonContentHeaders$w,
|
|
2585
2585
|
method: 'PATCH',
|
|
2586
2586
|
path: `/apple-silicon/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}`
|
|
2587
2587
|
}, unmarshalServer$3);
|
|
@@ -2608,7 +2608,7 @@ let API$x = class API extends API$z {
|
|
|
2608
2608
|
*/
|
|
2609
2609
|
rebootServer = request => this.client.fetch({
|
|
2610
2610
|
body: '{}',
|
|
2611
|
-
headers: jsonContentHeaders$
|
|
2611
|
+
headers: jsonContentHeaders$w,
|
|
2612
2612
|
method: 'POST',
|
|
2613
2613
|
path: `/apple-silicon/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/reboot`
|
|
2614
2614
|
}, unmarshalServer$3);
|
|
@@ -2624,7 +2624,7 @@ let API$x = class API extends API$z {
|
|
|
2624
2624
|
*/
|
|
2625
2625
|
reinstallServer = request => this.client.fetch({
|
|
2626
2626
|
body: '{}',
|
|
2627
|
-
headers: jsonContentHeaders$
|
|
2627
|
+
headers: jsonContentHeaders$w,
|
|
2628
2628
|
method: 'POST',
|
|
2629
2629
|
path: `/apple-silicon/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/reinstall`
|
|
2630
2630
|
}, unmarshalServer$3);
|
|
@@ -2633,7 +2633,7 @@ let API$x = class API extends API$z {
|
|
|
2633
2633
|
// This file was automatically generated. DO NOT EDIT.
|
|
2634
2634
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
2635
2635
|
|
|
2636
|
-
var index_gen$
|
|
2636
|
+
var index_gen$w = /*#__PURE__*/Object.freeze({
|
|
2637
2637
|
__proto__: null,
|
|
2638
2638
|
API: API$x,
|
|
2639
2639
|
SERVER_TRANSIENT_STATUSES: SERVER_TRANSIENT_STATUSES$3
|
|
@@ -2641,7 +2641,7 @@ var index_gen$v = /*#__PURE__*/Object.freeze({
|
|
|
2641
2641
|
|
|
2642
2642
|
var index$z = /*#__PURE__*/Object.freeze({
|
|
2643
2643
|
__proto__: null,
|
|
2644
|
-
v1alpha1: index_gen$
|
|
2644
|
+
v1alpha1: index_gen$w
|
|
2645
2645
|
});
|
|
2646
2646
|
|
|
2647
2647
|
// This file was automatically generated. DO NOT EDIT.
|
|
@@ -3059,7 +3059,7 @@ const marshalUpdateSettingRequest = (request, defaults) => ({
|
|
|
3059
3059
|
|
|
3060
3060
|
// This file was automatically generated. DO NOT EDIT.
|
|
3061
3061
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
3062
|
-
const jsonContentHeaders$
|
|
3062
|
+
const jsonContentHeaders$v = {
|
|
3063
3063
|
'Content-Type': 'application/json; charset=utf-8'
|
|
3064
3064
|
};
|
|
3065
3065
|
|
|
@@ -3116,7 +3116,7 @@ let API$w = class API extends API$z {
|
|
|
3116
3116
|
*/
|
|
3117
3117
|
createServer = request => this.client.fetch({
|
|
3118
3118
|
body: JSON.stringify(marshalCreateServerRequest$2(request, this.client.settings)),
|
|
3119
|
-
headers: jsonContentHeaders$
|
|
3119
|
+
headers: jsonContentHeaders$v,
|
|
3120
3120
|
method: 'POST',
|
|
3121
3121
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers`
|
|
3122
3122
|
}, unmarshalServer$2);
|
|
@@ -3131,7 +3131,7 @@ let API$w = class API extends API$z {
|
|
|
3131
3131
|
*/
|
|
3132
3132
|
updateServer = request => this.client.fetch({
|
|
3133
3133
|
body: JSON.stringify(marshalUpdateServerRequest$2(request, this.client.settings)),
|
|
3134
|
-
headers: jsonContentHeaders$
|
|
3134
|
+
headers: jsonContentHeaders$v,
|
|
3135
3135
|
method: 'PATCH',
|
|
3136
3136
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}`
|
|
3137
3137
|
}, unmarshalServer$2);
|
|
@@ -3145,7 +3145,7 @@ let API$w = class API extends API$z {
|
|
|
3145
3145
|
*/
|
|
3146
3146
|
installServer = request => this.client.fetch({
|
|
3147
3147
|
body: JSON.stringify(marshalInstallServerRequest$1(request, this.client.settings)),
|
|
3148
|
-
headers: jsonContentHeaders$
|
|
3148
|
+
headers: jsonContentHeaders$v,
|
|
3149
3149
|
method: 'POST',
|
|
3150
3150
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/install`
|
|
3151
3151
|
}, unmarshalServer$2);
|
|
@@ -3183,7 +3183,7 @@ let API$w = class API extends API$z {
|
|
|
3183
3183
|
*/
|
|
3184
3184
|
rebootServer = request => this.client.fetch({
|
|
3185
3185
|
body: JSON.stringify(marshalRebootServerRequest(request, this.client.settings)),
|
|
3186
|
-
headers: jsonContentHeaders$
|
|
3186
|
+
headers: jsonContentHeaders$v,
|
|
3187
3187
|
method: 'POST',
|
|
3188
3188
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/reboot`
|
|
3189
3189
|
}, unmarshalServer$2);
|
|
@@ -3196,7 +3196,7 @@ let API$w = class API extends API$z {
|
|
|
3196
3196
|
*/
|
|
3197
3197
|
startServer = request => this.client.fetch({
|
|
3198
3198
|
body: JSON.stringify(marshalStartServerRequest(request, this.client.settings)),
|
|
3199
|
-
headers: jsonContentHeaders$
|
|
3199
|
+
headers: jsonContentHeaders$v,
|
|
3200
3200
|
method: 'POST',
|
|
3201
3201
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/start`
|
|
3202
3202
|
}, unmarshalServer$2);
|
|
@@ -3211,7 +3211,7 @@ let API$w = class API extends API$z {
|
|
|
3211
3211
|
*/
|
|
3212
3212
|
stopServer = request => this.client.fetch({
|
|
3213
3213
|
body: '{}',
|
|
3214
|
-
headers: jsonContentHeaders$
|
|
3214
|
+
headers: jsonContentHeaders$v,
|
|
3215
3215
|
method: 'POST',
|
|
3216
3216
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/stop`
|
|
3217
3217
|
}, unmarshalServer$2);
|
|
@@ -3249,7 +3249,7 @@ let API$w = class API extends API$z {
|
|
|
3249
3249
|
*/
|
|
3250
3250
|
startBMCAccess = request => this.client.fetch({
|
|
3251
3251
|
body: JSON.stringify(marshalStartBMCAccessRequest$1(request, this.client.settings)),
|
|
3252
|
-
headers: jsonContentHeaders$
|
|
3252
|
+
headers: jsonContentHeaders$v,
|
|
3253
3253
|
method: 'POST',
|
|
3254
3254
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/bmc-access`
|
|
3255
3255
|
}, unmarshalBMCAccess$1);
|
|
@@ -3287,7 +3287,7 @@ let API$w = class API extends API$z {
|
|
|
3287
3287
|
*/
|
|
3288
3288
|
updateIP = request => this.client.fetch({
|
|
3289
3289
|
body: JSON.stringify(marshalUpdateIPRequest$2(request, this.client.settings)),
|
|
3290
|
-
headers: jsonContentHeaders$
|
|
3290
|
+
headers: jsonContentHeaders$v,
|
|
3291
3291
|
method: 'PATCH',
|
|
3292
3292
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/ips/${validatePathParam('ipId', request.ipId)}`
|
|
3293
3293
|
}, unmarshalIP$3);
|
|
@@ -3301,7 +3301,7 @@ let API$w = class API extends API$z {
|
|
|
3301
3301
|
*/
|
|
3302
3302
|
addOptionServer = request => this.client.fetch({
|
|
3303
3303
|
body: JSON.stringify(marshalAddOptionServerRequest(request, this.client.settings)),
|
|
3304
|
-
headers: jsonContentHeaders$
|
|
3304
|
+
headers: jsonContentHeaders$v,
|
|
3305
3305
|
method: 'POST',
|
|
3306
3306
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/options/${validatePathParam('optionId', request.optionId)}`
|
|
3307
3307
|
}, unmarshalServer$2);
|
|
@@ -3386,7 +3386,7 @@ let API$w = class API extends API$z {
|
|
|
3386
3386
|
*/
|
|
3387
3387
|
updateSetting = request => this.client.fetch({
|
|
3388
3388
|
body: JSON.stringify(marshalUpdateSettingRequest(request, this.client.settings)),
|
|
3389
|
-
headers: jsonContentHeaders$
|
|
3389
|
+
headers: jsonContentHeaders$v,
|
|
3390
3390
|
method: 'PATCH',
|
|
3391
3391
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/settings/${validatePathParam('settingId', request.settingId)}`
|
|
3392
3392
|
}, unmarshalSetting);
|
|
@@ -3431,7 +3431,7 @@ class PrivateNetworkAPI extends API$z {
|
|
|
3431
3431
|
*/
|
|
3432
3432
|
addServerPrivateNetwork = request => this.client.fetch({
|
|
3433
3433
|
body: JSON.stringify(marshalPrivateNetworkApiAddServerPrivateNetworkRequest(request, this.client.settings)),
|
|
3434
|
-
headers: jsonContentHeaders$
|
|
3434
|
+
headers: jsonContentHeaders$v,
|
|
3435
3435
|
method: 'POST',
|
|
3436
3436
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/private-networks`
|
|
3437
3437
|
}, unmarshalServerPrivateNetwork);
|
|
@@ -3445,7 +3445,7 @@ class PrivateNetworkAPI extends API$z {
|
|
|
3445
3445
|
*/
|
|
3446
3446
|
setServerPrivateNetworks = request => this.client.fetch({
|
|
3447
3447
|
body: JSON.stringify(marshalPrivateNetworkApiSetServerPrivateNetworksRequest(request, this.client.settings)),
|
|
3448
|
-
headers: jsonContentHeaders$
|
|
3448
|
+
headers: jsonContentHeaders$v,
|
|
3449
3449
|
method: 'PUT',
|
|
3450
3450
|
path: `/baremetal/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers/${validatePathParam('serverId', request.serverId)}/private-networks`
|
|
3451
3451
|
}, unmarshalSetServerPrivateNetworksResponse);
|
|
@@ -3606,7 +3606,7 @@ const UpdateServerRequest$1 = {
|
|
|
3606
3606
|
}
|
|
3607
3607
|
};
|
|
3608
3608
|
|
|
3609
|
-
var validationRules_gen$
|
|
3609
|
+
var validationRules_gen$h = /*#__PURE__*/Object.freeze({
|
|
3610
3610
|
__proto__: null,
|
|
3611
3611
|
CreateServerRequest: CreateServerRequest,
|
|
3612
3612
|
CreateServerRequestInstall: CreateServerRequestInstall,
|
|
@@ -3627,7 +3627,7 @@ var index$y = /*#__PURE__*/Object.freeze({
|
|
|
3627
3627
|
SERVER_INSTALL_TRANSIENT_STATUSES: SERVER_INSTALL_TRANSIENT_STATUSES$1,
|
|
3628
3628
|
SERVER_PRIVATE_NETWORK_TRANSIENT_STATUSES: SERVER_PRIVATE_NETWORK_TRANSIENT_STATUSES,
|
|
3629
3629
|
SERVER_TRANSIENT_STATUSES: SERVER_TRANSIENT_STATUSES$2,
|
|
3630
|
-
ValidationRules: validationRules_gen$
|
|
3630
|
+
ValidationRules: validationRules_gen$h
|
|
3631
3631
|
});
|
|
3632
3632
|
|
|
3633
3633
|
var index$x = /*#__PURE__*/Object.freeze({
|
|
@@ -3796,7 +3796,7 @@ let API$v = class API extends API$z {
|
|
|
3796
3796
|
// This file was automatically generated. DO NOT EDIT.
|
|
3797
3797
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
3798
3798
|
|
|
3799
|
-
var index_gen$
|
|
3799
|
+
var index_gen$v = /*#__PURE__*/Object.freeze({
|
|
3800
3800
|
__proto__: null,
|
|
3801
3801
|
API: API$v
|
|
3802
3802
|
});
|
|
@@ -4044,15 +4044,15 @@ let API$u = class API extends API$z {
|
|
|
4044
4044
|
// This file was automatically generated. DO NOT EDIT.
|
|
4045
4045
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4046
4046
|
|
|
4047
|
-
var index_gen$
|
|
4047
|
+
var index_gen$u = /*#__PURE__*/Object.freeze({
|
|
4048
4048
|
__proto__: null,
|
|
4049
4049
|
API: API$u
|
|
4050
4050
|
});
|
|
4051
4051
|
|
|
4052
4052
|
var index$w = /*#__PURE__*/Object.freeze({
|
|
4053
4053
|
__proto__: null,
|
|
4054
|
-
v2alpha1: index_gen$
|
|
4055
|
-
v2beta1: index_gen$
|
|
4054
|
+
v2alpha1: index_gen$v,
|
|
4055
|
+
v2beta1: index_gen$u
|
|
4056
4056
|
});
|
|
4057
4057
|
|
|
4058
4058
|
// This file was automatically generated. DO NOT EDIT.
|
|
@@ -4220,247 +4220,1017 @@ const marshalUpdateVolumeRequest$2 = (request, defaults) => ({
|
|
|
4220
4220
|
tags: request.tags
|
|
4221
4221
|
});
|
|
4222
4222
|
|
|
4223
|
-
// This file was automatically generated. DO NOT EDIT.
|
|
4224
|
-
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4225
|
-
const jsonContentHeaders$
|
|
4226
|
-
'Content-Type': 'application/json; charset=utf-8'
|
|
4227
|
-
};
|
|
4223
|
+
// This file was automatically generated. DO NOT EDIT.
|
|
4224
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4225
|
+
const jsonContentHeaders$u = {
|
|
4226
|
+
'Content-Type': 'application/json; charset=utf-8'
|
|
4227
|
+
};
|
|
4228
|
+
|
|
4229
|
+
/**
|
|
4230
|
+
* Scaleway Block Storage API.
|
|
4231
|
+
*
|
|
4232
|
+
* This API allows you to use and manage your Block Storage volumes.
|
|
4233
|
+
*/
|
|
4234
|
+
let API$t = class API extends API$z {
|
|
4235
|
+
/** Lists the available zones of the API. */
|
|
4236
|
+
static LOCALITIES = ['fr-par-1', 'fr-par-2', 'nl-ams-1', 'nl-ams-3', 'pl-waw-3'];
|
|
4237
|
+
pageOfListVolumeTypes = (request = {}) => this.client.fetch({
|
|
4238
|
+
method: 'GET',
|
|
4239
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volume-types`,
|
|
4240
|
+
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize])
|
|
4241
|
+
}, unmarshalListVolumeTypesResponse);
|
|
4242
|
+
|
|
4243
|
+
/**
|
|
4244
|
+
* List volume types. List all available volume types in a specified zone. The
|
|
4245
|
+
* volume types listed are ordered by name in ascending order.
|
|
4246
|
+
*
|
|
4247
|
+
* @param request - The request {@link ListVolumeTypesRequest}
|
|
4248
|
+
* @returns A Promise of ListVolumeTypesResponse
|
|
4249
|
+
*/
|
|
4250
|
+
listVolumeTypes = (request = {}) => enrichForPagination('volumeTypes', this.pageOfListVolumeTypes, request);
|
|
4251
|
+
pageOfListVolumes = (request = {}) => this.client.fetch({
|
|
4252
|
+
method: 'GET',
|
|
4253
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes`,
|
|
4254
|
+
urlParams: urlParams(['name', request.name], ['order_by', request.orderBy], ['organization_id', request.organizationId], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['product_resource_id', request.productResourceId], ['project_id', request.projectId])
|
|
4255
|
+
}, unmarshalListVolumesResponse$2);
|
|
4256
|
+
|
|
4257
|
+
/**
|
|
4258
|
+
* List volumes. List all existing volumes in a specified zone. By default,
|
|
4259
|
+
* the volumes listed are ordered by creation date in ascending order. This
|
|
4260
|
+
* can be modified via the `order_by` field.
|
|
4261
|
+
*
|
|
4262
|
+
* @param request - The request {@link ListVolumesRequest}
|
|
4263
|
+
* @returns A Promise of ListVolumesResponse
|
|
4264
|
+
*/
|
|
4265
|
+
listVolumes = (request = {}) => enrichForPagination('volumes', this.pageOfListVolumes, request);
|
|
4266
|
+
|
|
4267
|
+
/**
|
|
4268
|
+
* Create a volume. To create a new volume from scratch, you must specify
|
|
4269
|
+
* `from_empty` and the `size`. To create a volume from an existing snapshot,
|
|
4270
|
+
* specify `from_snapshot` and the `snapshot_id` in the request payload
|
|
4271
|
+
* instead, size is optional and can be specified if you need to extend the
|
|
4272
|
+
* original size. The volume will take on the same volume class and underlying
|
|
4273
|
+
* IOPS limitations as the original snapshot.
|
|
4274
|
+
*
|
|
4275
|
+
* @param request - The request {@link CreateVolumeRequest}
|
|
4276
|
+
* @returns A Promise of Volume
|
|
4277
|
+
*/
|
|
4278
|
+
createVolume = request => this.client.fetch({
|
|
4279
|
+
body: JSON.stringify(marshalCreateVolumeRequest$2(request, this.client.settings)),
|
|
4280
|
+
headers: jsonContentHeaders$u,
|
|
4281
|
+
method: 'POST',
|
|
4282
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes`
|
|
4283
|
+
}, unmarshalVolume$4);
|
|
4284
|
+
|
|
4285
|
+
/**
|
|
4286
|
+
* Get a volume. Retrieve technical information about a specific volume.
|
|
4287
|
+
* Details such as size, type, and status are returned in the response.
|
|
4288
|
+
*
|
|
4289
|
+
* @param request - The request {@link GetVolumeRequest}
|
|
4290
|
+
* @returns A Promise of Volume
|
|
4291
|
+
*/
|
|
4292
|
+
getVolume = request => this.client.fetch({
|
|
4293
|
+
method: 'GET',
|
|
4294
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes/${validatePathParam('volumeId', request.volumeId)}`
|
|
4295
|
+
}, unmarshalVolume$4);
|
|
4296
|
+
|
|
4297
|
+
/**
|
|
4298
|
+
* Waits for {@link Volume} to be in a final state.
|
|
4299
|
+
*
|
|
4300
|
+
* @param request - The request {@link GetVolumeRequest}
|
|
4301
|
+
* @param options - The waiting options
|
|
4302
|
+
* @returns A Promise of Volume
|
|
4303
|
+
*/
|
|
4304
|
+
waitForVolume = (request, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!VOLUME_TRANSIENT_STATUSES$1.includes(res.status))), this.getVolume, request, options);
|
|
4305
|
+
|
|
4306
|
+
/**
|
|
4307
|
+
* Delete a detached volume. You must specify the `volume_id` of the volume
|
|
4308
|
+
* you want to delete. The volume must not be in the `in_use` status.
|
|
4309
|
+
*
|
|
4310
|
+
* @param request - The request {@link DeleteVolumeRequest}
|
|
4311
|
+
*/
|
|
4312
|
+
deleteVolume = request => this.client.fetch({
|
|
4313
|
+
method: 'DELETE',
|
|
4314
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes/${validatePathParam('volumeId', request.volumeId)}`
|
|
4315
|
+
});
|
|
4316
|
+
|
|
4317
|
+
/**
|
|
4318
|
+
* Update a volume. Update the technical details of a volume, such as its
|
|
4319
|
+
* name, tags, or its new size and `volume_type` (within the same Block
|
|
4320
|
+
* Storage class). You can only resize a volume to a larger size. It is
|
|
4321
|
+
* currently not possible to change your Block Storage Class.
|
|
4322
|
+
*
|
|
4323
|
+
* @param request - The request {@link UpdateVolumeRequest}
|
|
4324
|
+
* @returns A Promise of Volume
|
|
4325
|
+
*/
|
|
4326
|
+
updateVolume = request => this.client.fetch({
|
|
4327
|
+
body: JSON.stringify(marshalUpdateVolumeRequest$2(request, this.client.settings)),
|
|
4328
|
+
headers: jsonContentHeaders$u,
|
|
4329
|
+
method: 'PATCH',
|
|
4330
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes/${validatePathParam('volumeId', request.volumeId)}`
|
|
4331
|
+
}, unmarshalVolume$4);
|
|
4332
|
+
pageOfListSnapshots = (request = {}) => this.client.fetch({
|
|
4333
|
+
method: 'GET',
|
|
4334
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/snapshots`,
|
|
4335
|
+
urlParams: urlParams(['name', request.name], ['order_by', request.orderBy], ['organization_id', request.organizationId], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId], ['volume_id', request.volumeId])
|
|
4336
|
+
}, unmarshalListSnapshotsResponse$3);
|
|
4337
|
+
|
|
4338
|
+
/**
|
|
4339
|
+
* List all snapshots. List all available snapshots in a specified zone. By
|
|
4340
|
+
* default, the snapshots listed are ordered by creation date in ascending
|
|
4341
|
+
* order. This can be modified via the `order_by` field.
|
|
4342
|
+
*
|
|
4343
|
+
* @param request - The request {@link ListSnapshotsRequest}
|
|
4344
|
+
* @returns A Promise of ListSnapshotsResponse
|
|
4345
|
+
*/
|
|
4346
|
+
listSnapshots = (request = {}) => enrichForPagination('snapshots', this.pageOfListSnapshots, request);
|
|
4347
|
+
|
|
4348
|
+
/**
|
|
4349
|
+
* Get a snapshot. Retrieve technical information about a specific snapshot.
|
|
4350
|
+
* Details such as size, volume type, and status are returned in the
|
|
4351
|
+
* response.
|
|
4352
|
+
*
|
|
4353
|
+
* @param request - The request {@link GetSnapshotRequest}
|
|
4354
|
+
* @returns A Promise of Snapshot
|
|
4355
|
+
*/
|
|
4356
|
+
getSnapshot = request => this.client.fetch({
|
|
4357
|
+
method: 'GET',
|
|
4358
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/snapshots/${validatePathParam('snapshotId', request.snapshotId)}`
|
|
4359
|
+
}, unmarshalSnapshot$3);
|
|
4360
|
+
|
|
4361
|
+
/**
|
|
4362
|
+
* Waits for {@link Snapshot} to be in a final state.
|
|
4363
|
+
*
|
|
4364
|
+
* @param request - The request {@link GetSnapshotRequest}
|
|
4365
|
+
* @param options - The waiting options
|
|
4366
|
+
* @returns A Promise of Snapshot
|
|
4367
|
+
*/
|
|
4368
|
+
waitForSnapshot = (request, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!SNAPSHOT_TRANSIENT_STATUSES$3.includes(res.status))), this.getSnapshot, request, options);
|
|
4369
|
+
|
|
4370
|
+
/**
|
|
4371
|
+
* Create a snapshot of a volume. To create a snapshot, the volume must be in
|
|
4372
|
+
* the `in_use` or the `available` status. If your volume is in a transient
|
|
4373
|
+
* state, you need to wait until the end of the current operation.
|
|
4374
|
+
*
|
|
4375
|
+
* @param request - The request {@link CreateSnapshotRequest}
|
|
4376
|
+
* @returns A Promise of Snapshot
|
|
4377
|
+
*/
|
|
4378
|
+
createSnapshot = request => this.client.fetch({
|
|
4379
|
+
body: JSON.stringify(marshalCreateSnapshotRequest$3(request, this.client.settings)),
|
|
4380
|
+
headers: jsonContentHeaders$u,
|
|
4381
|
+
method: 'POST',
|
|
4382
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/snapshots`
|
|
4383
|
+
}, unmarshalSnapshot$3);
|
|
4384
|
+
|
|
4385
|
+
/**
|
|
4386
|
+
* Delete a snapshot. You must specify the `snapshot_id` of the snapshot you
|
|
4387
|
+
* want to delete. The snapshot must not be in use.
|
|
4388
|
+
*
|
|
4389
|
+
* @param request - The request {@link DeleteSnapshotRequest}
|
|
4390
|
+
*/
|
|
4391
|
+
deleteSnapshot = request => this.client.fetch({
|
|
4392
|
+
method: 'DELETE',
|
|
4393
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/snapshots/${validatePathParam('snapshotId', request.snapshotId)}`
|
|
4394
|
+
});
|
|
4395
|
+
|
|
4396
|
+
/**
|
|
4397
|
+
* Update a snapshot. Update the name or tags of the snapshot.
|
|
4398
|
+
*
|
|
4399
|
+
* @param request - The request {@link UpdateSnapshotRequest}
|
|
4400
|
+
* @returns A Promise of Snapshot
|
|
4401
|
+
*/
|
|
4402
|
+
updateSnapshot = request => this.client.fetch({
|
|
4403
|
+
body: JSON.stringify(marshalUpdateSnapshotRequest$3(request, this.client.settings)),
|
|
4404
|
+
headers: jsonContentHeaders$u,
|
|
4405
|
+
method: 'PATCH',
|
|
4406
|
+
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/snapshots/${validatePathParam('snapshotId', request.snapshotId)}`
|
|
4407
|
+
}, unmarshalSnapshot$3);
|
|
4408
|
+
};
|
|
4409
|
+
|
|
4410
|
+
// This file was automatically generated. DO NOT EDIT.
|
|
4411
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4412
|
+
|
|
4413
|
+
const CreateSnapshotRequest = {
|
|
4414
|
+
name: {
|
|
4415
|
+
minLength: 1
|
|
4416
|
+
}
|
|
4417
|
+
};
|
|
4418
|
+
const CreateVolumeRequest = {
|
|
4419
|
+
name: {
|
|
4420
|
+
minLength: 1
|
|
4421
|
+
}
|
|
4422
|
+
};
|
|
4423
|
+
const ListSnapshotsRequest = {
|
|
4424
|
+
page: {
|
|
4425
|
+
greaterThan: 0
|
|
4426
|
+
},
|
|
4427
|
+
pageSize: {
|
|
4428
|
+
greaterThan: 0,
|
|
4429
|
+
lessThanOrEqual: 100
|
|
4430
|
+
}
|
|
4431
|
+
};
|
|
4432
|
+
const ListVolumeTypesRequest = {
|
|
4433
|
+
page: {
|
|
4434
|
+
greaterThan: 0
|
|
4435
|
+
},
|
|
4436
|
+
pageSize: {
|
|
4437
|
+
greaterThan: 0,
|
|
4438
|
+
lessThanOrEqual: 100
|
|
4439
|
+
}
|
|
4440
|
+
};
|
|
4441
|
+
const ListVolumesRequest = {
|
|
4442
|
+
page: {
|
|
4443
|
+
greaterThan: 0
|
|
4444
|
+
},
|
|
4445
|
+
pageSize: {
|
|
4446
|
+
greaterThan: 0,
|
|
4447
|
+
lessThanOrEqual: 100
|
|
4448
|
+
}
|
|
4449
|
+
};
|
|
4450
|
+
const Reference = {
|
|
4451
|
+
productResourceType: {
|
|
4452
|
+
minLength: 1
|
|
4453
|
+
}
|
|
4454
|
+
};
|
|
4455
|
+
|
|
4456
|
+
var validationRules_gen$g = /*#__PURE__*/Object.freeze({
|
|
4457
|
+
__proto__: null,
|
|
4458
|
+
CreateSnapshotRequest: CreateSnapshotRequest,
|
|
4459
|
+
CreateVolumeRequest: CreateVolumeRequest,
|
|
4460
|
+
ListSnapshotsRequest: ListSnapshotsRequest,
|
|
4461
|
+
ListVolumeTypesRequest: ListVolumeTypesRequest,
|
|
4462
|
+
ListVolumesRequest: ListVolumesRequest,
|
|
4463
|
+
Reference: Reference
|
|
4464
|
+
});
|
|
4465
|
+
|
|
4466
|
+
// This file was automatically generated. DO NOT EDIT.
|
|
4467
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4468
|
+
|
|
4469
|
+
var index_gen$t = /*#__PURE__*/Object.freeze({
|
|
4470
|
+
__proto__: null,
|
|
4471
|
+
API: API$t,
|
|
4472
|
+
REFERENCE_TRANSIENT_STATUSES: REFERENCE_TRANSIENT_STATUSES,
|
|
4473
|
+
SNAPSHOT_TRANSIENT_STATUSES: SNAPSHOT_TRANSIENT_STATUSES$3,
|
|
4474
|
+
VOLUME_TRANSIENT_STATUSES: VOLUME_TRANSIENT_STATUSES$1,
|
|
4475
|
+
ValidationRules: validationRules_gen$g
|
|
4476
|
+
});
|
|
4477
|
+
|
|
4478
|
+
var index$v = /*#__PURE__*/Object.freeze({
|
|
4479
|
+
__proto__: null,
|
|
4480
|
+
v1alpha1: index_gen$t
|
|
4481
|
+
});
|
|
4482
|
+
|
|
4483
|
+
// This file was automatically generated. DO NOT EDIT.
|
|
4484
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4485
|
+
const unmarshalContactPointEmail$1 = data => {
|
|
4486
|
+
if (!isJSONObject(data)) {
|
|
4487
|
+
throw new TypeError(`Unmarshalling the type 'ContactPointEmail' failed as data isn't a dictionary.`);
|
|
4488
|
+
}
|
|
4489
|
+
return {
|
|
4490
|
+
to: data.to
|
|
4491
|
+
};
|
|
4492
|
+
};
|
|
4493
|
+
const unmarshalContactPoint$1 = data => {
|
|
4494
|
+
if (!isJSONObject(data)) {
|
|
4495
|
+
throw new TypeError(`Unmarshalling the type 'ContactPoint' failed as data isn't a dictionary.`);
|
|
4496
|
+
}
|
|
4497
|
+
return {
|
|
4498
|
+
email: data.email ? unmarshalContactPointEmail$1(data.email) : undefined,
|
|
4499
|
+
region: data.region
|
|
4500
|
+
};
|
|
4501
|
+
};
|
|
4502
|
+
const unmarshalDataSource = data => {
|
|
4503
|
+
if (!isJSONObject(data)) {
|
|
4504
|
+
throw new TypeError(`Unmarshalling the type 'DataSource' failed as data isn't a dictionary.`);
|
|
4505
|
+
}
|
|
4506
|
+
return {
|
|
4507
|
+
createdAt: unmarshalDate(data.created_at),
|
|
4508
|
+
id: data.id,
|
|
4509
|
+
name: data.name,
|
|
4510
|
+
origin: data.origin,
|
|
4511
|
+
projectId: data.project_id,
|
|
4512
|
+
region: data.region,
|
|
4513
|
+
synchronizedWithGrafana: data.synchronized_with_grafana,
|
|
4514
|
+
type: data.type,
|
|
4515
|
+
updatedAt: unmarshalDate(data.updated_at),
|
|
4516
|
+
url: data.url
|
|
4517
|
+
};
|
|
4518
|
+
};
|
|
4519
|
+
const unmarshalGrafanaProductDashboard$1 = data => {
|
|
4520
|
+
if (!isJSONObject(data)) {
|
|
4521
|
+
throw new TypeError(`Unmarshalling the type 'GrafanaProductDashboard' failed as data isn't a dictionary.`);
|
|
4522
|
+
}
|
|
4523
|
+
return {
|
|
4524
|
+
name: data.name,
|
|
4525
|
+
tags: data.tags,
|
|
4526
|
+
title: data.title,
|
|
4527
|
+
url: data.url,
|
|
4528
|
+
variables: data.variables
|
|
4529
|
+
};
|
|
4530
|
+
};
|
|
4531
|
+
const unmarshalGrafanaUser$1 = data => {
|
|
4532
|
+
if (!isJSONObject(data)) {
|
|
4533
|
+
throw new TypeError(`Unmarshalling the type 'GrafanaUser' failed as data isn't a dictionary.`);
|
|
4534
|
+
}
|
|
4535
|
+
return {
|
|
4536
|
+
id: data.id,
|
|
4537
|
+
login: data.login,
|
|
4538
|
+
password: data.password,
|
|
4539
|
+
role: data.role
|
|
4540
|
+
};
|
|
4541
|
+
};
|
|
4542
|
+
const unmarshalPlan$1 = data => {
|
|
4543
|
+
if (!isJSONObject(data)) {
|
|
4544
|
+
throw new TypeError(`Unmarshalling the type 'Plan' failed as data isn't a dictionary.`);
|
|
4545
|
+
}
|
|
4546
|
+
return {
|
|
4547
|
+
logsIngestionPrice: data.logs_ingestion_price,
|
|
4548
|
+
monthlyPrice: data.monthly_price,
|
|
4549
|
+
name: data.name,
|
|
4550
|
+
retentionLogsInterval: data.retention_logs_interval,
|
|
4551
|
+
retentionMetricsInterval: data.retention_metrics_interval,
|
|
4552
|
+
retentionTracesInterval: data.retention_traces_interval,
|
|
4553
|
+
sampleIngestionPrice: data.sample_ingestion_price,
|
|
4554
|
+
tracesIngestionPrice: data.traces_ingestion_price
|
|
4555
|
+
};
|
|
4556
|
+
};
|
|
4557
|
+
const unmarshalToken$3 = data => {
|
|
4558
|
+
if (!isJSONObject(data)) {
|
|
4559
|
+
throw new TypeError(`Unmarshalling the type 'Token' failed as data isn't a dictionary.`);
|
|
4560
|
+
}
|
|
4561
|
+
return {
|
|
4562
|
+
createdAt: unmarshalDate(data.created_at),
|
|
4563
|
+
id: data.id,
|
|
4564
|
+
name: data.name,
|
|
4565
|
+
projectId: data.project_id,
|
|
4566
|
+
region: data.region,
|
|
4567
|
+
scopes: data.scopes,
|
|
4568
|
+
secretKey: data.secret_key,
|
|
4569
|
+
updatedAt: unmarshalDate(data.updated_at)
|
|
4570
|
+
};
|
|
4571
|
+
};
|
|
4572
|
+
const unmarshalAlertManager = data => {
|
|
4573
|
+
if (!isJSONObject(data)) {
|
|
4574
|
+
throw new TypeError(`Unmarshalling the type 'AlertManager' failed as data isn't a dictionary.`);
|
|
4575
|
+
}
|
|
4576
|
+
return {
|
|
4577
|
+
alertManagerEnabled: data.alert_manager_enabled,
|
|
4578
|
+
alertManagerUrl: data.alert_manager_url,
|
|
4579
|
+
managedAlertsEnabled: data.managed_alerts_enabled,
|
|
4580
|
+
region: data.region
|
|
4581
|
+
};
|
|
4582
|
+
};
|
|
4583
|
+
const unmarshalGrafana = data => {
|
|
4584
|
+
if (!isJSONObject(data)) {
|
|
4585
|
+
throw new TypeError(`Unmarshalling the type 'Grafana' failed as data isn't a dictionary.`);
|
|
4586
|
+
}
|
|
4587
|
+
return {
|
|
4588
|
+
grafanaUrl: data.grafana_url
|
|
4589
|
+
};
|
|
4590
|
+
};
|
|
4591
|
+
const unmarshalListContactPointsResponse$1 = data => {
|
|
4592
|
+
if (!isJSONObject(data)) {
|
|
4593
|
+
throw new TypeError(`Unmarshalling the type 'ListContactPointsResponse' failed as data isn't a dictionary.`);
|
|
4594
|
+
}
|
|
4595
|
+
return {
|
|
4596
|
+
contactPoints: unmarshalArrayOfObject(data.contact_points, unmarshalContactPoint$1),
|
|
4597
|
+
hasAdditionalContactPoints: data.has_additional_contact_points,
|
|
4598
|
+
hasAdditionalReceivers: data.has_additional_receivers,
|
|
4599
|
+
totalCount: data.total_count
|
|
4600
|
+
};
|
|
4601
|
+
};
|
|
4602
|
+
const unmarshalListDataSourcesResponse = data => {
|
|
4603
|
+
if (!isJSONObject(data)) {
|
|
4604
|
+
throw new TypeError(`Unmarshalling the type 'ListDataSourcesResponse' failed as data isn't a dictionary.`);
|
|
4605
|
+
}
|
|
4606
|
+
return {
|
|
4607
|
+
dataSources: unmarshalArrayOfObject(data.data_sources, unmarshalDataSource),
|
|
4608
|
+
totalCount: data.total_count
|
|
4609
|
+
};
|
|
4610
|
+
};
|
|
4611
|
+
const unmarshalListGrafanaProductDashboardsResponse$1 = data => {
|
|
4612
|
+
if (!isJSONObject(data)) {
|
|
4613
|
+
throw new TypeError(`Unmarshalling the type 'ListGrafanaProductDashboardsResponse' failed as data isn't a dictionary.`);
|
|
4614
|
+
}
|
|
4615
|
+
return {
|
|
4616
|
+
dashboards: unmarshalArrayOfObject(data.dashboards, unmarshalGrafanaProductDashboard$1),
|
|
4617
|
+
totalCount: data.total_count
|
|
4618
|
+
};
|
|
4619
|
+
};
|
|
4620
|
+
const unmarshalListGrafanaUsersResponse$1 = data => {
|
|
4621
|
+
if (!isJSONObject(data)) {
|
|
4622
|
+
throw new TypeError(`Unmarshalling the type 'ListGrafanaUsersResponse' failed as data isn't a dictionary.`);
|
|
4623
|
+
}
|
|
4624
|
+
return {
|
|
4625
|
+
grafanaUsers: unmarshalArrayOfObject(data.grafana_users, unmarshalGrafanaUser$1),
|
|
4626
|
+
totalCount: data.total_count
|
|
4627
|
+
};
|
|
4628
|
+
};
|
|
4629
|
+
const unmarshalListPlansResponse$1 = data => {
|
|
4630
|
+
if (!isJSONObject(data)) {
|
|
4631
|
+
throw new TypeError(`Unmarshalling the type 'ListPlansResponse' failed as data isn't a dictionary.`);
|
|
4632
|
+
}
|
|
4633
|
+
return {
|
|
4634
|
+
plans: unmarshalArrayOfObject(data.plans, unmarshalPlan$1),
|
|
4635
|
+
totalCount: data.total_count
|
|
4636
|
+
};
|
|
4637
|
+
};
|
|
4638
|
+
const unmarshalListTokensResponse$3 = data => {
|
|
4639
|
+
if (!isJSONObject(data)) {
|
|
4640
|
+
throw new TypeError(`Unmarshalling the type 'ListTokensResponse' failed as data isn't a dictionary.`);
|
|
4641
|
+
}
|
|
4642
|
+
return {
|
|
4643
|
+
tokens: unmarshalArrayOfObject(data.tokens, unmarshalToken$3),
|
|
4644
|
+
totalCount: data.total_count
|
|
4645
|
+
};
|
|
4646
|
+
};
|
|
4647
|
+
const unmarshalUsage = data => {
|
|
4648
|
+
if (!isJSONObject(data)) {
|
|
4649
|
+
throw new TypeError(`Unmarshalling the type 'Usage' failed as data isn't a dictionary.`);
|
|
4650
|
+
}
|
|
4651
|
+
return {
|
|
4652
|
+
dataSourceId: data.data_source_id,
|
|
4653
|
+
dataSourceOrigin: data.data_source_origin,
|
|
4654
|
+
dataSourceType: data.data_source_type,
|
|
4655
|
+
interval: data.interval,
|
|
4656
|
+
projectId: data.project_id,
|
|
4657
|
+
quantityOverInterval: data.quantity_over_interval,
|
|
4658
|
+
region: data.region,
|
|
4659
|
+
unit: data.unit
|
|
4660
|
+
};
|
|
4661
|
+
};
|
|
4662
|
+
const unmarshalUsageOverview = data => {
|
|
4663
|
+
if (!isJSONObject(data)) {
|
|
4664
|
+
throw new TypeError(`Unmarshalling the type 'UsageOverview' failed as data isn't a dictionary.`);
|
|
4665
|
+
}
|
|
4666
|
+
return {
|
|
4667
|
+
externalLogsUsage: data.external_logs_usage ? unmarshalUsage(data.external_logs_usage) : undefined,
|
|
4668
|
+
externalMetricsUsage: data.external_metrics_usage ? unmarshalUsage(data.external_metrics_usage) : undefined,
|
|
4669
|
+
externalTracesUsage: data.external_traces_usage ? unmarshalUsage(data.external_traces_usage) : undefined,
|
|
4670
|
+
scalewayLogsUsage: data.scaleway_logs_usage ? unmarshalUsage(data.scaleway_logs_usage) : undefined,
|
|
4671
|
+
scalewayMetricsUsage: data.scaleway_metrics_usage ? unmarshalUsage(data.scaleway_metrics_usage) : undefined
|
|
4672
|
+
};
|
|
4673
|
+
};
|
|
4674
|
+
const marshalGlobalApiCreateGrafanaUserRequest = (request, defaults) => ({
|
|
4675
|
+
login: request.login,
|
|
4676
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
4677
|
+
role: request.role
|
|
4678
|
+
});
|
|
4679
|
+
const marshalGlobalApiResetGrafanaUserPasswordRequest = (request, defaults) => ({
|
|
4680
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4681
|
+
});
|
|
4682
|
+
const marshalGlobalApiSelectPlanRequest = (request, defaults) => ({
|
|
4683
|
+
plan_name: request.planName,
|
|
4684
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4685
|
+
});
|
|
4686
|
+
const marshalGlobalApiSyncGrafanaDataSourcesRequest = (request, defaults) => ({
|
|
4687
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4688
|
+
});
|
|
4689
|
+
const marshalContactPointEmail$1 = (request, defaults) => ({
|
|
4690
|
+
to: request.to
|
|
4691
|
+
});
|
|
4692
|
+
const marshalRegionalApiCreateContactPointRequest = (request, defaults) => ({
|
|
4693
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
4694
|
+
...resolveOneOf([{
|
|
4695
|
+
param: 'email',
|
|
4696
|
+
value: request.email !== undefined ? marshalContactPointEmail$1(request.email) : undefined
|
|
4697
|
+
}])
|
|
4698
|
+
});
|
|
4699
|
+
const marshalRegionalApiCreateDataSourceRequest = (request, defaults) => ({
|
|
4700
|
+
name: request.name,
|
|
4701
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
4702
|
+
type: request.type
|
|
4703
|
+
});
|
|
4704
|
+
const marshalRegionalApiCreateTokenRequest = (request, defaults) => ({
|
|
4705
|
+
name: request.name,
|
|
4706
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
4707
|
+
token_scopes: request.tokenScopes !== undefined ? request.tokenScopes : undefined
|
|
4708
|
+
});
|
|
4709
|
+
const marshalRegionalApiDeleteContactPointRequest = (request, defaults) => ({
|
|
4710
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
4711
|
+
...resolveOneOf([{
|
|
4712
|
+
param: 'email',
|
|
4713
|
+
value: request.email !== undefined ? marshalContactPointEmail$1(request.email) : undefined
|
|
4714
|
+
}])
|
|
4715
|
+
});
|
|
4716
|
+
const marshalRegionalApiDisableAlertManagerRequest = (request, defaults) => ({
|
|
4717
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4718
|
+
});
|
|
4719
|
+
const marshalRegionalApiDisableManagedAlertsRequest = (request, defaults) => ({
|
|
4720
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4721
|
+
});
|
|
4722
|
+
const marshalRegionalApiEnableAlertManagerRequest = (request, defaults) => ({
|
|
4723
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4724
|
+
});
|
|
4725
|
+
const marshalRegionalApiEnableManagedAlertsRequest = (request, defaults) => ({
|
|
4726
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4727
|
+
});
|
|
4728
|
+
const marshalRegionalApiTriggerTestAlertRequest = (request, defaults) => ({
|
|
4729
|
+
project_id: request.projectId ?? defaults.defaultProjectId
|
|
4730
|
+
});
|
|
4731
|
+
|
|
4732
|
+
// This file was automatically generated. DO NOT EDIT.
|
|
4733
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4734
|
+
const jsonContentHeaders$t = {
|
|
4735
|
+
'Content-Type': 'application/json; charset=utf-8'
|
|
4736
|
+
};
|
|
4737
|
+
|
|
4738
|
+
/**
|
|
4739
|
+
* Cockpit Global API.
|
|
4740
|
+
*
|
|
4741
|
+
* The Cockpit Global API allows you to manage your Cockpit's Grafana and plans.
|
|
4742
|
+
*/
|
|
4743
|
+
class GlobalAPI extends API$z {
|
|
4744
|
+
/**
|
|
4745
|
+
* Get your Cockpit's Grafana. Retrieve information on your Cockpit's Grafana,
|
|
4746
|
+
* specified by the ID of the Project the Cockpit belongs to. The output
|
|
4747
|
+
* returned displays the URL to access your Cockpit's Grafana.
|
|
4748
|
+
*
|
|
4749
|
+
* @param request - The request {@link GlobalApiGetGrafanaRequest}
|
|
4750
|
+
* @returns A Promise of Grafana
|
|
4751
|
+
*/
|
|
4752
|
+
getGrafana = (request = {}) => this.client.fetch({
|
|
4753
|
+
method: 'GET',
|
|
4754
|
+
path: `/cockpit/v1/grafana`,
|
|
4755
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4756
|
+
}, unmarshalGrafana);
|
|
4757
|
+
|
|
4758
|
+
/**
|
|
4759
|
+
* Synchronize Grafana data sources. Trigger the synchronization of all your
|
|
4760
|
+
* data sources and the alert manager in the relevant regions. The alert
|
|
4761
|
+
* manager will only be synchronized if you have enabled it.
|
|
4762
|
+
*
|
|
4763
|
+
* @param request - The request {@link GlobalApiSyncGrafanaDataSourcesRequest}
|
|
4764
|
+
*/
|
|
4765
|
+
syncGrafanaDataSources = (request = {}) => this.client.fetch({
|
|
4766
|
+
body: JSON.stringify(marshalGlobalApiSyncGrafanaDataSourcesRequest(request, this.client.settings)),
|
|
4767
|
+
headers: jsonContentHeaders$t,
|
|
4768
|
+
method: 'POST',
|
|
4769
|
+
path: `/cockpit/v1/grafana/sync-data-sources`
|
|
4770
|
+
});
|
|
4771
|
+
|
|
4772
|
+
/**
|
|
4773
|
+
* Create a Grafana user. Create a Grafana user to connect to your Cockpit's
|
|
4774
|
+
* Grafana. Upon creation, your user password displays only once, so make sure
|
|
4775
|
+
* that you save it. Each Grafana user is associated with a role: viewer or
|
|
4776
|
+
* editor. A viewer can only view dashboards, whereas an editor can create and
|
|
4777
|
+
* edit dashboards. Note that the `admin` username is not available for
|
|
4778
|
+
* creation.
|
|
4779
|
+
*
|
|
4780
|
+
* @param request - The request {@link GlobalApiCreateGrafanaUserRequest}
|
|
4781
|
+
* @returns A Promise of GrafanaUser
|
|
4782
|
+
*/
|
|
4783
|
+
createGrafanaUser = request => this.client.fetch({
|
|
4784
|
+
body: JSON.stringify(marshalGlobalApiCreateGrafanaUserRequest(request, this.client.settings)),
|
|
4785
|
+
headers: jsonContentHeaders$t,
|
|
4786
|
+
method: 'POST',
|
|
4787
|
+
path: `/cockpit/v1/grafana/users`
|
|
4788
|
+
}, unmarshalGrafanaUser$1);
|
|
4789
|
+
pageOfListGrafanaUsers = (request = {}) => this.client.fetch({
|
|
4790
|
+
method: 'GET',
|
|
4791
|
+
path: `/cockpit/v1/grafana/users`,
|
|
4792
|
+
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4793
|
+
}, unmarshalListGrafanaUsersResponse$1);
|
|
4794
|
+
|
|
4795
|
+
/**
|
|
4796
|
+
* List Grafana users. List all Grafana users created in your Cockpit's
|
|
4797
|
+
* Grafana. By default, the Grafana users returned in the list are ordered in
|
|
4798
|
+
* ascending order.
|
|
4799
|
+
*
|
|
4800
|
+
* @param request - The request {@link GlobalApiListGrafanaUsersRequest}
|
|
4801
|
+
* @returns A Promise of ListGrafanaUsersResponse
|
|
4802
|
+
*/
|
|
4803
|
+
listGrafanaUsers = (request = {}) => enrichForPagination('grafanaUsers', this.pageOfListGrafanaUsers, request);
|
|
4804
|
+
|
|
4805
|
+
/**
|
|
4806
|
+
* Delete a Grafana user. Delete a Grafana user from your Cockpit's Grafana,
|
|
4807
|
+
* specified by the ID of the Project the Cockpit belongs to, and the ID of
|
|
4808
|
+
* the Grafana user.
|
|
4809
|
+
*
|
|
4810
|
+
* @param request - The request {@link GlobalApiDeleteGrafanaUserRequest}
|
|
4811
|
+
*/
|
|
4812
|
+
deleteGrafanaUser = request => this.client.fetch({
|
|
4813
|
+
method: 'DELETE',
|
|
4814
|
+
path: `/cockpit/v1/grafana/users/${validatePathParam('grafanaUserId', request.grafanaUserId)}`,
|
|
4815
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4816
|
+
});
|
|
4817
|
+
|
|
4818
|
+
/**
|
|
4819
|
+
* Reset a Grafana user password. Reset the password of a Grafana user,
|
|
4820
|
+
* specified by the ID of the Project the Cockpit belongs to, and the ID of
|
|
4821
|
+
* the Grafana user. A new password regenerates and only displays once. Make
|
|
4822
|
+
* sure that you save it.
|
|
4823
|
+
*
|
|
4824
|
+
* @param request - The request
|
|
4825
|
+
* {@link GlobalApiResetGrafanaUserPasswordRequest}
|
|
4826
|
+
* @returns A Promise of GrafanaUser
|
|
4827
|
+
*/
|
|
4828
|
+
resetGrafanaUserPassword = request => this.client.fetch({
|
|
4829
|
+
body: JSON.stringify(marshalGlobalApiResetGrafanaUserPasswordRequest(request, this.client.settings)),
|
|
4830
|
+
headers: jsonContentHeaders$t,
|
|
4831
|
+
method: 'POST',
|
|
4832
|
+
path: `/cockpit/v1/grafana/users/${validatePathParam('grafanaUserId', request.grafanaUserId)}/reset-password`
|
|
4833
|
+
}, unmarshalGrafanaUser$1);
|
|
4834
|
+
pageOfListGrafanaProductDashboards = (request = {}) => this.client.fetch({
|
|
4835
|
+
method: 'GET',
|
|
4836
|
+
path: `/cockpit/v1/grafana/product-dashboards`,
|
|
4837
|
+
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['tags', request.tags])
|
|
4838
|
+
}, unmarshalListGrafanaProductDashboardsResponse$1);
|
|
4839
|
+
|
|
4840
|
+
/**
|
|
4841
|
+
* List Scaleway resources dashboards. Retrieve a list of available dashboards
|
|
4842
|
+
* in Grafana, for all Scaleway resources which are integrated with Cockpit.
|
|
4843
|
+
*
|
|
4844
|
+
* @param request - The request
|
|
4845
|
+
* {@link GlobalApiListGrafanaProductDashboardsRequest}
|
|
4846
|
+
* @returns A Promise of ListGrafanaProductDashboardsResponse
|
|
4847
|
+
*/
|
|
4848
|
+
listGrafanaProductDashboards = (request = {}) => enrichForPagination('dashboards', this.pageOfListGrafanaProductDashboards, request);
|
|
4849
|
+
|
|
4850
|
+
/**
|
|
4851
|
+
* Get Scaleway resource dashboard. Retrieve information about the dashboard
|
|
4852
|
+
* of a Scaleway resource in Grafana, specified by the ID of the Project the
|
|
4853
|
+
* Cockpit belongs to, and the name of the dashboard.
|
|
4854
|
+
*
|
|
4855
|
+
* @param request - The request
|
|
4856
|
+
* {@link GlobalApiGetGrafanaProductDashboardRequest}
|
|
4857
|
+
* @returns A Promise of GrafanaProductDashboard
|
|
4858
|
+
*/
|
|
4859
|
+
getGrafanaProductDashboard = request => this.client.fetch({
|
|
4860
|
+
method: 'GET',
|
|
4861
|
+
path: `/cockpit/v1/grafana/product-dashboards/${validatePathParam('dashboardName', request.dashboardName)}`,
|
|
4862
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4863
|
+
}, unmarshalGrafanaProductDashboard$1);
|
|
4864
|
+
pageOfListPlans = (request = {}) => this.client.fetch({
|
|
4865
|
+
method: 'GET',
|
|
4866
|
+
path: `/cockpit/v1/plans`,
|
|
4867
|
+
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize])
|
|
4868
|
+
}, unmarshalListPlansResponse$1);
|
|
4869
|
+
|
|
4870
|
+
/**
|
|
4871
|
+
* List plan types. Retrieve a list of available pricing plan types.
|
|
4872
|
+
*
|
|
4873
|
+
* @param request - The request {@link GlobalApiListPlansRequest}
|
|
4874
|
+
* @returns A Promise of ListPlansResponse
|
|
4875
|
+
*/
|
|
4876
|
+
listPlans = (request = {}) => enrichForPagination('plans', this.pageOfListPlans, request);
|
|
4877
|
+
|
|
4878
|
+
/**
|
|
4879
|
+
* Apply a pricing plan. Apply a pricing plan on a given Project. You must
|
|
4880
|
+
* specify the ID of the pricing plan type. Note that you will be billed for
|
|
4881
|
+
* the plan you apply.
|
|
4882
|
+
*
|
|
4883
|
+
* @param request - The request {@link GlobalApiSelectPlanRequest}
|
|
4884
|
+
* @returns A Promise of Plan
|
|
4885
|
+
*/
|
|
4886
|
+
selectPlan = (request = {}) => this.client.fetch({
|
|
4887
|
+
body: JSON.stringify(marshalGlobalApiSelectPlanRequest(request, this.client.settings)),
|
|
4888
|
+
headers: jsonContentHeaders$t,
|
|
4889
|
+
method: 'PATCH',
|
|
4890
|
+
path: `/cockpit/v1/plans`
|
|
4891
|
+
}, unmarshalPlan$1);
|
|
4892
|
+
|
|
4893
|
+
/**
|
|
4894
|
+
* Get current plan. Retrieve a pricing plan for the given Project, specified
|
|
4895
|
+
* by the ID of the Project.
|
|
4896
|
+
*
|
|
4897
|
+
* @param request - The request {@link GlobalApiGetCurrentPlanRequest}
|
|
4898
|
+
* @returns A Promise of Plan
|
|
4899
|
+
*/
|
|
4900
|
+
getCurrentPlan = (request = {}) => this.client.fetch({
|
|
4901
|
+
method: 'GET',
|
|
4902
|
+
path: `/cockpit/v1/current-plan`,
|
|
4903
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4904
|
+
}, unmarshalPlan$1);
|
|
4905
|
+
}
|
|
4228
4906
|
|
|
4229
4907
|
/**
|
|
4230
|
-
*
|
|
4908
|
+
* Cockpit Regional API.
|
|
4231
4909
|
*
|
|
4232
|
-
*
|
|
4910
|
+
* The Cockpit Regional API allows you to create data sources and tokens to
|
|
4911
|
+
* store and query data types such as metrics, logs, and traces. You can also
|
|
4912
|
+
* push your data into Cockpit, and send alerts to your contact points when your
|
|
4913
|
+
* resources may require your attention, using the regional Alert manager.
|
|
4233
4914
|
*/
|
|
4234
|
-
|
|
4235
|
-
/** Lists the available
|
|
4236
|
-
static LOCALITIES = ['fr-par
|
|
4237
|
-
|
|
4915
|
+
class RegionalAPI extends API$z {
|
|
4916
|
+
/** Lists the available regions of the API. */
|
|
4917
|
+
static LOCALITIES = ['fr-par', 'nl-ams', 'pl-waw'];
|
|
4918
|
+
|
|
4919
|
+
/**
|
|
4920
|
+
* Create a data source. You must specify the data source type upon creation.
|
|
4921
|
+
* Available data source types include:
|
|
4922
|
+
*
|
|
4923
|
+
* - Metrics
|
|
4924
|
+
* - Logs
|
|
4925
|
+
* - Traces The name of the data source will then be used as reference to name
|
|
4926
|
+
* the associated Grafana data source.
|
|
4927
|
+
*
|
|
4928
|
+
* @param request - The request {@link RegionalApiCreateDataSourceRequest}
|
|
4929
|
+
* @returns A Promise of DataSource
|
|
4930
|
+
*/
|
|
4931
|
+
createDataSource = request => this.client.fetch({
|
|
4932
|
+
body: JSON.stringify(marshalRegionalApiCreateDataSourceRequest(request, this.client.settings)),
|
|
4933
|
+
headers: jsonContentHeaders$t,
|
|
4934
|
+
method: 'POST',
|
|
4935
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/data-sources`
|
|
4936
|
+
}, unmarshalDataSource);
|
|
4937
|
+
|
|
4938
|
+
/**
|
|
4939
|
+
* Get a data source. Retrieve information about a given data source,
|
|
4940
|
+
* specified by the data source ID. The data source's information such as its
|
|
4941
|
+
* name, type, URL, origin, and retention period, is returned.
|
|
4942
|
+
*
|
|
4943
|
+
* @param request - The request {@link RegionalApiGetDataSourceRequest}
|
|
4944
|
+
* @returns A Promise of DataSource
|
|
4945
|
+
*/
|
|
4946
|
+
getDataSource = request => this.client.fetch({
|
|
4238
4947
|
method: 'GET',
|
|
4239
|
-
path: `/
|
|
4240
|
-
|
|
4241
|
-
}, unmarshalListVolumeTypesResponse);
|
|
4948
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/data-sources/${validatePathParam('dataSourceId', request.dataSourceId)}`
|
|
4949
|
+
}, unmarshalDataSource);
|
|
4242
4950
|
|
|
4243
4951
|
/**
|
|
4244
|
-
*
|
|
4245
|
-
*
|
|
4952
|
+
* Delete a data source. Delete a given data source, specified by the data
|
|
4953
|
+
* source ID. Note that deleting a data source is irreversible, and cannot be
|
|
4954
|
+
* undone.
|
|
4246
4955
|
*
|
|
4247
|
-
* @param request - The request {@link
|
|
4248
|
-
* @returns A Promise of ListVolumeTypesResponse
|
|
4956
|
+
* @param request - The request {@link RegionalApiDeleteDataSourceRequest}
|
|
4249
4957
|
*/
|
|
4250
|
-
|
|
4251
|
-
|
|
4958
|
+
deleteDataSource = request => this.client.fetch({
|
|
4959
|
+
method: 'DELETE',
|
|
4960
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/data-sources/${validatePathParam('dataSourceId', request.dataSourceId)}`
|
|
4961
|
+
});
|
|
4962
|
+
pageOfListDataSources = (request = {}) => this.client.fetch({
|
|
4252
4963
|
method: 'GET',
|
|
4253
|
-
path: `/
|
|
4254
|
-
urlParams: urlParams(['
|
|
4255
|
-
},
|
|
4964
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/data-sources`,
|
|
4965
|
+
urlParams: urlParams(['order_by', request.orderBy], ['origin', request.origin], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['types', request.types])
|
|
4966
|
+
}, unmarshalListDataSourcesResponse);
|
|
4256
4967
|
|
|
4257
4968
|
/**
|
|
4258
|
-
* List
|
|
4259
|
-
*
|
|
4260
|
-
*
|
|
4969
|
+
* List data sources. Retrieve the list of data sources available in the
|
|
4970
|
+
* specified region. By default, the data sources returned in the list are
|
|
4971
|
+
* ordered by creation date, in ascending order. You can list data sources by
|
|
4972
|
+
* Project, type and origin.
|
|
4261
4973
|
*
|
|
4262
|
-
* @param request - The request {@link
|
|
4263
|
-
* @returns A Promise of
|
|
4974
|
+
* @param request - The request {@link RegionalApiListDataSourcesRequest}
|
|
4975
|
+
* @returns A Promise of ListDataSourcesResponse
|
|
4264
4976
|
*/
|
|
4265
|
-
|
|
4977
|
+
listDataSources = (request = {}) => enrichForPagination('dataSources', this.pageOfListDataSources, request);
|
|
4266
4978
|
|
|
4267
4979
|
/**
|
|
4268
|
-
*
|
|
4269
|
-
*
|
|
4270
|
-
* specify `from_snapshot` and the `snapshot_id` in the request payload
|
|
4271
|
-
* instead, size is optional and can be specified if you need to extend the
|
|
4272
|
-
* original size. The volume will take on the same volume class and underlying
|
|
4273
|
-
* IOPS limitations as the original snapshot.
|
|
4980
|
+
* Get data source usage overview. Retrieve the data source usage overview per
|
|
4981
|
+
* type for the specified Project.
|
|
4274
4982
|
*
|
|
4275
|
-
* @param request - The request {@link
|
|
4276
|
-
* @returns A Promise of
|
|
4983
|
+
* @param request - The request {@link RegionalApiGetUsageOverviewRequest}
|
|
4984
|
+
* @returns A Promise of UsageOverview
|
|
4277
4985
|
*/
|
|
4278
|
-
|
|
4279
|
-
|
|
4986
|
+
getUsageOverview = (request = {}) => this.client.fetch({
|
|
4987
|
+
method: 'GET',
|
|
4988
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/usage-overview`,
|
|
4989
|
+
urlParams: urlParams(['interval', request.interval], ['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
4990
|
+
}, unmarshalUsageOverview);
|
|
4991
|
+
|
|
4992
|
+
/**
|
|
4993
|
+
* Create a token. Give your token the relevant scopes to ensure it has the
|
|
4994
|
+
* right permissions to interact with your data sources and the Alert manager.
|
|
4995
|
+
* Make sure that you create your token in the same regions as the data
|
|
4996
|
+
* sources you want to use it for. Upon creation, your token's secret key
|
|
4997
|
+
* display only once. Make sure that you save it.
|
|
4998
|
+
*
|
|
4999
|
+
* @param request - The request {@link RegionalApiCreateTokenRequest}
|
|
5000
|
+
* @returns A Promise of Token
|
|
5001
|
+
*/
|
|
5002
|
+
createToken = request => this.client.fetch({
|
|
5003
|
+
body: JSON.stringify(marshalRegionalApiCreateTokenRequest(request, this.client.settings)),
|
|
4280
5004
|
headers: jsonContentHeaders$t,
|
|
4281
5005
|
method: 'POST',
|
|
4282
|
-
path: `/
|
|
4283
|
-
},
|
|
5006
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/tokens`
|
|
5007
|
+
}, unmarshalToken$3);
|
|
5008
|
+
pageOfListTokens = (request = {}) => this.client.fetch({
|
|
5009
|
+
method: 'GET',
|
|
5010
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/tokens`,
|
|
5011
|
+
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['token_scopes', request.tokenScopes])
|
|
5012
|
+
}, unmarshalListTokensResponse$3);
|
|
4284
5013
|
|
|
4285
5014
|
/**
|
|
4286
|
-
*
|
|
4287
|
-
*
|
|
5015
|
+
* List tokens. Retrieve a list of all tokens in the specified region. By
|
|
5016
|
+
* default, tokens returned in the list are ordered by creation date, in
|
|
5017
|
+
* ascending order. You can filter tokens by Project ID and token scopes.
|
|
4288
5018
|
*
|
|
4289
|
-
* @param request - The request {@link
|
|
4290
|
-
* @returns A Promise of
|
|
5019
|
+
* @param request - The request {@link RegionalApiListTokensRequest}
|
|
5020
|
+
* @returns A Promise of ListTokensResponse
|
|
4291
5021
|
*/
|
|
4292
|
-
|
|
4293
|
-
method: 'GET',
|
|
4294
|
-
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes/${validatePathParam('volumeId', request.volumeId)}`
|
|
4295
|
-
}, unmarshalVolume$4);
|
|
5022
|
+
listTokens = (request = {}) => enrichForPagination('tokens', this.pageOfListTokens, request);
|
|
4296
5023
|
|
|
4297
5024
|
/**
|
|
4298
|
-
*
|
|
5025
|
+
* Get a token. Retrieve information about a given token, specified by the
|
|
5026
|
+
* token ID. The token's information such as its scopes, is returned.
|
|
4299
5027
|
*
|
|
4300
|
-
* @param request - The request {@link
|
|
4301
|
-
* @
|
|
4302
|
-
* @returns A Promise of Volume
|
|
5028
|
+
* @param request - The request {@link RegionalApiGetTokenRequest}
|
|
5029
|
+
* @returns A Promise of Token
|
|
4303
5030
|
*/
|
|
4304
|
-
|
|
5031
|
+
getToken = request => this.client.fetch({
|
|
5032
|
+
method: 'GET',
|
|
5033
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/tokens/${validatePathParam('tokenId', request.tokenId)}`
|
|
5034
|
+
}, unmarshalToken$3);
|
|
4305
5035
|
|
|
4306
5036
|
/**
|
|
4307
|
-
* Delete a
|
|
4308
|
-
*
|
|
5037
|
+
* Delete a token. Delete a given token, specified by the token ID. Deleting a
|
|
5038
|
+
* token is irreversible and cannot be undone.
|
|
4309
5039
|
*
|
|
4310
|
-
* @param request - The request {@link
|
|
5040
|
+
* @param request - The request {@link RegionalApiDeleteTokenRequest}
|
|
4311
5041
|
*/
|
|
4312
|
-
|
|
5042
|
+
deleteToken = request => this.client.fetch({
|
|
4313
5043
|
method: 'DELETE',
|
|
4314
|
-
path: `/
|
|
5044
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/tokens/${validatePathParam('tokenId', request.tokenId)}`
|
|
4315
5045
|
});
|
|
4316
5046
|
|
|
4317
5047
|
/**
|
|
4318
|
-
*
|
|
4319
|
-
*
|
|
4320
|
-
*
|
|
4321
|
-
*
|
|
5048
|
+
* Get the Alert manager. Retrieve information about the Alert manager which
|
|
5049
|
+
* is unique per Project and region. By default the Alert manager is disabled.
|
|
5050
|
+
* The output returned displays a URL to access the Alert manager, and whether
|
|
5051
|
+
* the Alert manager and managed alerts are enabled.
|
|
4322
5052
|
*
|
|
4323
|
-
* @param request - The request {@link
|
|
4324
|
-
* @returns A Promise of
|
|
5053
|
+
* @param request - The request {@link RegionalApiGetAlertManagerRequest}
|
|
5054
|
+
* @returns A Promise of AlertManager
|
|
4325
5055
|
*/
|
|
4326
|
-
|
|
4327
|
-
body: JSON.stringify(marshalUpdateVolumeRequest$2(request, this.client.settings)),
|
|
4328
|
-
headers: jsonContentHeaders$t,
|
|
4329
|
-
method: 'PATCH',
|
|
4330
|
-
path: `/block/v1alpha1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/volumes/${validatePathParam('volumeId', request.volumeId)}`
|
|
4331
|
-
}, unmarshalVolume$4);
|
|
4332
|
-
pageOfListSnapshots = (request = {}) => this.client.fetch({
|
|
5056
|
+
getAlertManager = (request = {}) => this.client.fetch({
|
|
4333
5057
|
method: 'GET',
|
|
4334
|
-
path: `/
|
|
4335
|
-
urlParams: urlParams(['
|
|
4336
|
-
},
|
|
5058
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager`,
|
|
5059
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
5060
|
+
}, unmarshalAlertManager);
|
|
4337
5061
|
|
|
4338
5062
|
/**
|
|
4339
|
-
*
|
|
4340
|
-
*
|
|
4341
|
-
*
|
|
5063
|
+
* Enable the Alert manager. Enabling the Alert manager allows you to enable
|
|
5064
|
+
* managed alerts and create contact points in the specified Project and
|
|
5065
|
+
* region, to be notified when your Scaleway resources may require your
|
|
5066
|
+
* attention.
|
|
4342
5067
|
*
|
|
4343
|
-
* @param request - The request {@link
|
|
4344
|
-
* @returns A Promise of
|
|
5068
|
+
* @param request - The request {@link RegionalApiEnableAlertManagerRequest}
|
|
5069
|
+
* @returns A Promise of AlertManager
|
|
4345
5070
|
*/
|
|
4346
|
-
|
|
5071
|
+
enableAlertManager = (request = {}) => this.client.fetch({
|
|
5072
|
+
body: JSON.stringify(marshalRegionalApiEnableAlertManagerRequest(request, this.client.settings)),
|
|
5073
|
+
headers: jsonContentHeaders$t,
|
|
5074
|
+
method: 'POST',
|
|
5075
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/enable`
|
|
5076
|
+
}, unmarshalAlertManager);
|
|
4347
5077
|
|
|
4348
5078
|
/**
|
|
4349
|
-
*
|
|
4350
|
-
*
|
|
4351
|
-
*
|
|
5079
|
+
* Disable the Alert manager. Disabling the Alert manager deletes the contact
|
|
5080
|
+
* points you have created and disables managed alerts in the specified
|
|
5081
|
+
* Project and region.
|
|
4352
5082
|
*
|
|
4353
|
-
* @param request - The request {@link
|
|
4354
|
-
* @returns A Promise of
|
|
5083
|
+
* @param request - The request {@link RegionalApiDisableAlertManagerRequest}
|
|
5084
|
+
* @returns A Promise of AlertManager
|
|
4355
5085
|
*/
|
|
4356
|
-
|
|
5086
|
+
disableAlertManager = (request = {}) => this.client.fetch({
|
|
5087
|
+
body: JSON.stringify(marshalRegionalApiDisableAlertManagerRequest(request, this.client.settings)),
|
|
5088
|
+
headers: jsonContentHeaders$t,
|
|
5089
|
+
method: 'POST',
|
|
5090
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/disable`
|
|
5091
|
+
}, unmarshalAlertManager);
|
|
5092
|
+
|
|
5093
|
+
/**
|
|
5094
|
+
* Create a contact point. Contact points are email addresses associated with
|
|
5095
|
+
* the default receiver, that the Alert manager sends alerts to. The source of
|
|
5096
|
+
* the alerts are data sources within the same Project and region as the Alert
|
|
5097
|
+
* manager. If you need to receive alerts for other receivers, you can create
|
|
5098
|
+
* additional contact points and receivers in Grafana. Make sure that you
|
|
5099
|
+
* select the Scaleway Alert manager.
|
|
5100
|
+
*
|
|
5101
|
+
* @param request - The request {@link RegionalApiCreateContactPointRequest}
|
|
5102
|
+
* @returns A Promise of ContactPoint
|
|
5103
|
+
*/
|
|
5104
|
+
createContactPoint = (request = {}) => this.client.fetch({
|
|
5105
|
+
body: JSON.stringify(marshalRegionalApiCreateContactPointRequest(request, this.client.settings)),
|
|
5106
|
+
headers: jsonContentHeaders$t,
|
|
5107
|
+
method: 'POST',
|
|
5108
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/contact-points`
|
|
5109
|
+
}, unmarshalContactPoint$1);
|
|
5110
|
+
pageOfListContactPoints = (request = {}) => this.client.fetch({
|
|
4357
5111
|
method: 'GET',
|
|
4358
|
-
path: `/
|
|
4359
|
-
|
|
5112
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/contact-points`,
|
|
5113
|
+
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
5114
|
+
}, unmarshalListContactPointsResponse$1);
|
|
4360
5115
|
|
|
4361
5116
|
/**
|
|
4362
|
-
*
|
|
5117
|
+
* List contact points. Retrieve a list of contact points for the specified
|
|
5118
|
+
* Project. The response lists all contact points and receivers created in
|
|
5119
|
+
* Grafana or via the API.
|
|
4363
5120
|
*
|
|
4364
|
-
* @param request - The request {@link
|
|
4365
|
-
* @
|
|
4366
|
-
* @returns A Promise of Snapshot
|
|
5121
|
+
* @param request - The request {@link RegionalApiListContactPointsRequest}
|
|
5122
|
+
* @returns A Promise of ListContactPointsResponse
|
|
4367
5123
|
*/
|
|
4368
|
-
|
|
5124
|
+
listContactPoints = (request = {}) => enrichForPagination('contactPoints', this.pageOfListContactPoints, request);
|
|
4369
5125
|
|
|
4370
5126
|
/**
|
|
4371
|
-
*
|
|
4372
|
-
*
|
|
4373
|
-
* state, you need to wait until the end of the current operation.
|
|
5127
|
+
* Delete a contact point. Delete a contact point associated with the default
|
|
5128
|
+
* receiver.
|
|
4374
5129
|
*
|
|
4375
|
-
* @param request - The request {@link
|
|
4376
|
-
* @returns A Promise of Snapshot
|
|
5130
|
+
* @param request - The request {@link RegionalApiDeleteContactPointRequest}
|
|
4377
5131
|
*/
|
|
4378
|
-
|
|
4379
|
-
body: JSON.stringify(
|
|
5132
|
+
deleteContactPoint = (request = {}) => this.client.fetch({
|
|
5133
|
+
body: JSON.stringify(marshalRegionalApiDeleteContactPointRequest(request, this.client.settings)),
|
|
4380
5134
|
headers: jsonContentHeaders$t,
|
|
4381
5135
|
method: 'POST',
|
|
4382
|
-
path: `/
|
|
4383
|
-
}
|
|
5136
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/contact-points/delete`
|
|
5137
|
+
});
|
|
4384
5138
|
|
|
4385
5139
|
/**
|
|
4386
|
-
*
|
|
4387
|
-
*
|
|
5140
|
+
* Enable managed alerts. Enable the sending of managed alerts for the
|
|
5141
|
+
* specified Project. Managed alerts are predefined alerts that apply to
|
|
5142
|
+
* Scaleway recources integrated with Cockpit by default.
|
|
4388
5143
|
*
|
|
4389
|
-
* @param request - The request {@link
|
|
5144
|
+
* @param request - The request {@link RegionalApiEnableManagedAlertsRequest}
|
|
5145
|
+
* @returns A Promise of AlertManager
|
|
4390
5146
|
*/
|
|
4391
|
-
|
|
4392
|
-
|
|
4393
|
-
|
|
4394
|
-
|
|
5147
|
+
enableManagedAlerts = (request = {}) => this.client.fetch({
|
|
5148
|
+
body: JSON.stringify(marshalRegionalApiEnableManagedAlertsRequest(request, this.client.settings)),
|
|
5149
|
+
headers: jsonContentHeaders$t,
|
|
5150
|
+
method: 'POST',
|
|
5151
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/managed-alerts/enable`
|
|
5152
|
+
}, unmarshalAlertManager);
|
|
4395
5153
|
|
|
4396
5154
|
/**
|
|
4397
|
-
*
|
|
5155
|
+
* Disable managed alerts. Disable the sending of managed alerts for the
|
|
5156
|
+
* specified Project.
|
|
4398
5157
|
*
|
|
4399
|
-
* @param request - The request {@link
|
|
4400
|
-
* @returns A Promise of
|
|
5158
|
+
* @param request - The request {@link RegionalApiDisableManagedAlertsRequest}
|
|
5159
|
+
* @returns A Promise of AlertManager
|
|
4401
5160
|
*/
|
|
4402
|
-
|
|
4403
|
-
body: JSON.stringify(
|
|
5161
|
+
disableManagedAlerts = (request = {}) => this.client.fetch({
|
|
5162
|
+
body: JSON.stringify(marshalRegionalApiDisableManagedAlertsRequest(request, this.client.settings)),
|
|
4404
5163
|
headers: jsonContentHeaders$t,
|
|
4405
|
-
method: '
|
|
4406
|
-
path: `/
|
|
4407
|
-
},
|
|
4408
|
-
|
|
5164
|
+
method: 'POST',
|
|
5165
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/managed-alerts/disable`
|
|
5166
|
+
}, unmarshalAlertManager);
|
|
5167
|
+
|
|
5168
|
+
/**
|
|
5169
|
+
* Trigger a test alert. Send a test alert to the Alert manager to make sure
|
|
5170
|
+
* your contact points get notified.
|
|
5171
|
+
*
|
|
5172
|
+
* @param request - The request {@link RegionalApiTriggerTestAlertRequest}
|
|
5173
|
+
*/
|
|
5174
|
+
triggerTestAlert = (request = {}) => this.client.fetch({
|
|
5175
|
+
body: JSON.stringify(marshalRegionalApiTriggerTestAlertRequest(request, this.client.settings)),
|
|
5176
|
+
headers: jsonContentHeaders$t,
|
|
5177
|
+
method: 'POST',
|
|
5178
|
+
path: `/cockpit/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/alert-manager/trigger-test-alert`
|
|
5179
|
+
});
|
|
5180
|
+
}
|
|
4409
5181
|
|
|
4410
5182
|
// This file was automatically generated. DO NOT EDIT.
|
|
4411
5183
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4412
5184
|
|
|
4413
|
-
const
|
|
5185
|
+
const RegionalApiCreateDataSourceRequest = {
|
|
4414
5186
|
name: {
|
|
4415
|
-
|
|
5187
|
+
maxLength: 50,
|
|
5188
|
+
minLength: 3,
|
|
5189
|
+
pattern: /^[A-Za-z0-9-_. ]+$/
|
|
4416
5190
|
}
|
|
4417
5191
|
};
|
|
4418
|
-
const
|
|
5192
|
+
const RegionalApiCreateTokenRequest = {
|
|
4419
5193
|
name: {
|
|
4420
|
-
|
|
5194
|
+
maxLength: 50,
|
|
5195
|
+
minLength: 3,
|
|
5196
|
+
pattern: /^[A-Za-z0-9-_]+$/
|
|
4421
5197
|
}
|
|
4422
5198
|
};
|
|
4423
|
-
const
|
|
5199
|
+
const RegionalApiListContactPointsRequest = {
|
|
4424
5200
|
page: {
|
|
4425
|
-
|
|
5201
|
+
greaterThanOrEqual: 1
|
|
4426
5202
|
},
|
|
4427
5203
|
pageSize: {
|
|
4428
|
-
|
|
4429
|
-
lessThanOrEqual:
|
|
5204
|
+
greaterThanOrEqual: 1,
|
|
5205
|
+
lessThanOrEqual: 1000
|
|
4430
5206
|
}
|
|
4431
5207
|
};
|
|
4432
|
-
const
|
|
5208
|
+
const RegionalApiListDataSourcesRequest = {
|
|
4433
5209
|
page: {
|
|
4434
|
-
|
|
5210
|
+
greaterThanOrEqual: 1
|
|
4435
5211
|
},
|
|
4436
5212
|
pageSize: {
|
|
4437
|
-
|
|
4438
|
-
lessThanOrEqual:
|
|
5213
|
+
greaterThanOrEqual: 1,
|
|
5214
|
+
lessThanOrEqual: 1000
|
|
4439
5215
|
}
|
|
4440
5216
|
};
|
|
4441
|
-
const
|
|
5217
|
+
const RegionalApiListTokensRequest = {
|
|
4442
5218
|
page: {
|
|
4443
|
-
|
|
5219
|
+
greaterThanOrEqual: 1
|
|
4444
5220
|
},
|
|
4445
5221
|
pageSize: {
|
|
4446
|
-
|
|
4447
|
-
lessThanOrEqual:
|
|
4448
|
-
}
|
|
4449
|
-
};
|
|
4450
|
-
const Reference = {
|
|
4451
|
-
productResourceType: {
|
|
4452
|
-
minLength: 1
|
|
5222
|
+
greaterThanOrEqual: 1,
|
|
5223
|
+
lessThanOrEqual: 1000
|
|
4453
5224
|
}
|
|
4454
5225
|
};
|
|
4455
5226
|
|
|
4456
5227
|
var validationRules_gen$f = /*#__PURE__*/Object.freeze({
|
|
4457
5228
|
__proto__: null,
|
|
4458
|
-
|
|
4459
|
-
|
|
4460
|
-
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
Reference: Reference
|
|
5229
|
+
RegionalApiCreateDataSourceRequest: RegionalApiCreateDataSourceRequest,
|
|
5230
|
+
RegionalApiCreateTokenRequest: RegionalApiCreateTokenRequest,
|
|
5231
|
+
RegionalApiListContactPointsRequest: RegionalApiListContactPointsRequest,
|
|
5232
|
+
RegionalApiListDataSourcesRequest: RegionalApiListDataSourcesRequest,
|
|
5233
|
+
RegionalApiListTokensRequest: RegionalApiListTokensRequest
|
|
4464
5234
|
});
|
|
4465
5235
|
|
|
4466
5236
|
// This file was automatically generated. DO NOT EDIT.
|
|
@@ -4468,18 +5238,11 @@ var validationRules_gen$f = /*#__PURE__*/Object.freeze({
|
|
|
4468
5238
|
|
|
4469
5239
|
var index_gen$s = /*#__PURE__*/Object.freeze({
|
|
4470
5240
|
__proto__: null,
|
|
4471
|
-
|
|
4472
|
-
|
|
4473
|
-
SNAPSHOT_TRANSIENT_STATUSES: SNAPSHOT_TRANSIENT_STATUSES$3,
|
|
4474
|
-
VOLUME_TRANSIENT_STATUSES: VOLUME_TRANSIENT_STATUSES$1,
|
|
5241
|
+
GlobalAPI: GlobalAPI,
|
|
5242
|
+
RegionalAPI: RegionalAPI,
|
|
4475
5243
|
ValidationRules: validationRules_gen$f
|
|
4476
5244
|
});
|
|
4477
5245
|
|
|
4478
|
-
var index$v = /*#__PURE__*/Object.freeze({
|
|
4479
|
-
__proto__: null,
|
|
4480
|
-
v1alpha1: index_gen$s
|
|
4481
|
-
});
|
|
4482
|
-
|
|
4483
5246
|
// This file was automatically generated. DO NOT EDIT.
|
|
4484
5247
|
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
4485
5248
|
|
|
@@ -5108,6 +5871,7 @@ var index_gen$r = /*#__PURE__*/Object.freeze({
|
|
|
5108
5871
|
|
|
5109
5872
|
var index$u = /*#__PURE__*/Object.freeze({
|
|
5110
5873
|
__proto__: null,
|
|
5874
|
+
v1: index_gen$s,
|
|
5111
5875
|
v1beta1: index_gen$r
|
|
5112
5876
|
});
|
|
5113
5877
|
|
|
@@ -16489,7 +17253,7 @@ let API$k = class API extends API$z {
|
|
|
16489
17253
|
pageOfListServers = (request = {}) => this.client.fetch({
|
|
16490
17254
|
method: 'GET',
|
|
16491
17255
|
path: `/instance/v1/zones/${validatePathParam('zone', request.zone ?? this.client.settings.defaultZone)}/servers`,
|
|
16492
|
-
urlParams: urlParams(['commercial_type', request.commercialType], ['name', request.name], ['order', request.order], ['organization', request.organization], ['page', request.page], ['per_page', request.perPage ?? this.client.settings.defaultPageSize], ['private_ip', request.privateIp], ['private_network', request.privateNetwork], ['private_networks', request.privateNetworks && request.privateNetworks.length > 0 ? request.privateNetworks.join(',') : undefined], ['private_nic_mac_address', request.privateNicMacAddress], ['project', request.project], ['servers', request.servers && request.servers.length > 0 ? request.servers.join(',') : undefined], ['state', request.state], ['tags', request.tags && request.tags.length > 0 ? request.tags.join(',') : undefined], ['without_ip', request.withoutIp])
|
|
17256
|
+
urlParams: urlParams(['commercial_type', request.commercialType], ['name', request.name], ['order', request.order], ['organization', request.organization], ['page', request.page], ['per_page', request.perPage ?? this.client.settings.defaultPageSize], ['private_ip', request.privateIp], ['private_network', request.privateNetwork], ['private_networks', request.privateNetworks && request.privateNetworks.length > 0 ? request.privateNetworks.join(',') : undefined], ['private_nic_mac_address', request.privateNicMacAddress], ['project', request.project], ['servers', request.servers && request.servers.length > 0 ? request.servers.join(',') : undefined], ['state', request.state], ['tags', request.tags && request.tags.length > 0 ? request.tags.join(',') : undefined], ['with_ip', request.withIp], ['without_ip', request.withoutIp])
|
|
16493
17257
|
}, unmarshalListServersResponse);
|
|
16494
17258
|
|
|
16495
17259
|
/**
|
|
@@ -19737,6 +20501,7 @@ const unmarshalCluster$1 = data => {
|
|
|
19737
20501
|
privateNetworkId: data.private_network_id,
|
|
19738
20502
|
projectId: data.project_id,
|
|
19739
20503
|
region: data.region,
|
|
20504
|
+
routedIpEnabled: data.routed_ip_enabled,
|
|
19740
20505
|
status: data.status,
|
|
19741
20506
|
tags: data.tags,
|
|
19742
20507
|
type: data.type,
|
|
@@ -24710,6 +25475,7 @@ const unmarshalEndpointPrivateNetworkDetails = data => {
|
|
|
24710
25475
|
}
|
|
24711
25476
|
return {
|
|
24712
25477
|
privateNetworkId: data.private_network_id,
|
|
25478
|
+
provisioningMode: data.provisioning_mode,
|
|
24713
25479
|
serviceIp: data.service_ip,
|
|
24714
25480
|
zone: data.zone
|
|
24715
25481
|
};
|