@scaleway/sdk 2.6.0 → 2.8.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/account/v2/api.gen.js +26 -74
- package/dist/api/account/v3/api.gen.js +20 -60
- package/dist/api/applesilicon/v1alpha1/api.gen.js +16 -56
- package/dist/api/baremetal/v1/api.gen.js +36 -132
- package/dist/api/billing/v2alpha1/api.gen.js +17 -57
- package/dist/api/block/v1alpha1/api.gen.js +20 -74
- package/dist/api/block/v1alpha1/marshalling.gen.js +1 -8
- package/dist/api/block/v1alpha1/validation-rules.gen.js +1 -6
- package/dist/api/cockpit/v1beta1/api.gen.js +95 -279
- package/dist/api/container/v1beta1/api.gen.js +51 -123
- package/dist/api/document_db/v1beta1/api.gen.js +18 -66
- package/dist/api/document_db/v1beta1/marshalling.gen.js +20 -1
- package/dist/api/domain/v2beta1/api.gen.js +36 -124
- package/dist/api/flexibleip/v1alpha1/api.gen.js +6 -22
- package/dist/api/function/v1beta1/api.gen.js +55 -135
- package/dist/api/iam/v1alpha1/api.gen.js +66 -226
- package/dist/api/instance/v1/api.gen.js +102 -310
- package/dist/api/instance/v1/marshalling.gen.js +32 -56
- package/dist/api/iot/v1/api.gen.js +24 -88
- package/dist/api/ipam/v1/api.gen.js +12 -28
- package/dist/api/ipfs/v1alpha1/api.gen.js +12 -44
- package/dist/api/jobs/v1alpha1/api.gen.js +12 -44
- package/dist/api/jobs/v1alpha1/marshalling.gen.js +2 -0
- package/dist/api/k8s/v1/api.gen.js +16 -56
- package/dist/api/lb/v1/api.gen.js +72 -248
- package/dist/api/marketplace/v1/api.gen.js +7 -31
- package/dist/api/marketplace/v1/marshalling.gen.js +1 -18
- package/dist/api/marketplace/v2/api.gen.js +21 -53
- package/dist/api/mnq/v1beta1/api.gen.js +76 -212
- package/dist/api/rdb/v1/api.gen.js +24 -88
- package/dist/api/rdb/v1/marshalling.gen.js +11 -1
- package/dist/api/redis/v1/api.gen.js +6 -22
- package/dist/api/registry/v1/api.gen.js +12 -44
- package/dist/api/secret/v1alpha1/api.gen.js +18 -66
- package/dist/api/serverless_sqldb/index.js +2 -0
- package/dist/api/serverless_sqldb/v1alpha1/api.gen.js +162 -0
- package/dist/api/serverless_sqldb/v1alpha1/content.gen.js +7 -0
- package/dist/api/serverless_sqldb/v1alpha1/index.gen.js +7 -0
- package/dist/api/serverless_sqldb/v1alpha1/marshalling.gen.js +77 -0
- package/dist/api/serverless_sqldb/v1alpha1/validation-rules.gen.js +60 -0
- package/dist/api/tem/v1alpha1/api.gen.js +17 -57
- package/dist/api/test/v1/api.gen.js +6 -22
- package/dist/api/vpc/v1/api.gen.js +12 -36
- package/dist/api/vpc/v2/api.gen.js +30 -86
- package/dist/api/vpcgw/v1/api.gen.js +46 -158
- package/dist/api/webhosting/v1alpha1/api.gen.js +12 -44
- package/dist/helpers/marshalling.js +8 -23
- package/dist/index.cjs +925 -621
- package/dist/index.d.ts +2045 -1661
- package/dist/index.js +12 -10
- package/dist/internal/async/interval-retrier.js +8 -16
- package/dist/internal/interceptors/helpers.js +3 -4
- package/dist/internal/logger/console-logger.js +1 -7
- package/dist/internal/logger/index.js +1 -9
- package/dist/scw/auth.js +1 -2
- package/dist/scw/client.js +2 -10
- package/dist/scw/constants.js +1 -1
- package/dist/scw/errors/non-standard/invalid-request-mapper.js +5 -8
- package/dist/scw/errors/scw-error.js +2 -8
- package/dist/scw/errors/standard/permissions-denied-error.js +4 -7
- package/dist/scw/fetch/build-fetcher.js +1 -4
- package/dist/scw/fetch/http-dumper.js +1 -4
- package/dist/scw/fetch/http-interceptors.js +18 -31
- package/dist/scw/fetch/resource-paginator.js +3 -17
- package/package.json +2 -2
|
@@ -25,20 +25,12 @@ class API extends API$1 {
|
|
|
25
25
|
* @param request - The request {@link ActivateCockpitRequest}
|
|
26
26
|
* @returns A Promise of Cockpit
|
|
27
27
|
*/
|
|
28
|
-
activateCockpit = (
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
return _this.client.fetch({
|
|
35
|
-
body: JSON.stringify(marshalActivateCockpitRequest(request, _this.client.settings)),
|
|
36
|
-
headers: jsonContentHeaders,
|
|
37
|
-
method: 'POST',
|
|
38
|
-
path: `/cockpit/v1beta1/activate`
|
|
39
|
-
}, unmarshalCockpit);
|
|
40
|
-
};
|
|
41
|
-
})();
|
|
28
|
+
activateCockpit = (request = {}) => this.client.fetch({
|
|
29
|
+
body: JSON.stringify(marshalActivateCockpitRequest(request, this.client.settings)),
|
|
30
|
+
headers: jsonContentHeaders,
|
|
31
|
+
method: 'POST',
|
|
32
|
+
path: `/cockpit/v1beta1/activate`
|
|
33
|
+
}, unmarshalCockpit);
|
|
42
34
|
|
|
43
35
|
/**
|
|
44
36
|
* Retrieve the Cockpit of the specified Project ID.
|
|
@@ -46,19 +38,11 @@ class API extends API$1 {
|
|
|
46
38
|
* @param request - The request {@link GetCockpitRequest}
|
|
47
39
|
* @returns A Promise of Cockpit
|
|
48
40
|
*/
|
|
49
|
-
getCockpit = (
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
}
|
|
55
|
-
return _this2.client.fetch({
|
|
56
|
-
method: 'GET',
|
|
57
|
-
path: `/cockpit/v1beta1/cockpit`,
|
|
58
|
-
urlParams: urlParams(['project_id', request.projectId ?? _this2.client.settings.defaultProjectId])
|
|
59
|
-
}, unmarshalCockpit);
|
|
60
|
-
};
|
|
61
|
-
})();
|
|
41
|
+
getCockpit = (request = {}) => this.client.fetch({
|
|
42
|
+
method: 'GET',
|
|
43
|
+
path: `/cockpit/v1beta1/cockpit`,
|
|
44
|
+
urlParams: urlParams(['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
45
|
+
}, unmarshalCockpit);
|
|
62
46
|
|
|
63
47
|
/**
|
|
64
48
|
* Waits for {@link Cockpit} to be in a final state.
|
|
@@ -67,15 +51,7 @@ class API extends API$1 {
|
|
|
67
51
|
* @param options - The waiting options
|
|
68
52
|
* @returns A Promise of Cockpit
|
|
69
53
|
*/
|
|
70
|
-
waitForCockpit = (
|
|
71
|
-
var _this3 = this;
|
|
72
|
-
return function (request, options) {
|
|
73
|
-
if (request === void 0) {
|
|
74
|
-
request = {};
|
|
75
|
-
}
|
|
76
|
-
return waitForResource(options?.stop ?? (res => Promise.resolve(!COCKPIT_TRANSIENT_STATUSES.includes(res.status))), _this3.getCockpit, request, options);
|
|
77
|
-
};
|
|
78
|
-
})();
|
|
54
|
+
waitForCockpit = (request = {}, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!COCKPIT_TRANSIENT_STATUSES.includes(res.status))), this.getCockpit, request, options);
|
|
79
55
|
|
|
80
56
|
/**
|
|
81
57
|
* Get metrics from your Cockpit with the specified Project ID.
|
|
@@ -83,19 +59,11 @@ class API extends API$1 {
|
|
|
83
59
|
* @param request - The request {@link GetCockpitMetricsRequest}
|
|
84
60
|
* @returns A Promise of CockpitMetrics
|
|
85
61
|
*/
|
|
86
|
-
getCockpitMetrics = (
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
}
|
|
92
|
-
return _this4.client.fetch({
|
|
93
|
-
method: 'GET',
|
|
94
|
-
path: `/cockpit/v1beta1/cockpit/metrics`,
|
|
95
|
-
urlParams: urlParams(['end_date', request.endDate], ['metric_name', request.metricName], ['project_id', request.projectId ?? _this4.client.settings.defaultProjectId], ['start_date', request.startDate])
|
|
96
|
-
}, unmarshalCockpitMetrics);
|
|
97
|
-
};
|
|
98
|
-
})();
|
|
62
|
+
getCockpitMetrics = (request = {}) => this.client.fetch({
|
|
63
|
+
method: 'GET',
|
|
64
|
+
path: `/cockpit/v1beta1/cockpit/metrics`,
|
|
65
|
+
urlParams: urlParams(['end_date', request.endDate], ['metric_name', request.metricName], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['start_date', request.startDate])
|
|
66
|
+
}, unmarshalCockpitMetrics);
|
|
99
67
|
|
|
100
68
|
/**
|
|
101
69
|
* Deactivate the Cockpit of the specified Project ID.
|
|
@@ -103,20 +71,12 @@ class API extends API$1 {
|
|
|
103
71
|
* @param request - The request {@link DeactivateCockpitRequest}
|
|
104
72
|
* @returns A Promise of Cockpit
|
|
105
73
|
*/
|
|
106
|
-
deactivateCockpit = (
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
return _this5.client.fetch({
|
|
113
|
-
body: JSON.stringify(marshalDeactivateCockpitRequest(request, _this5.client.settings)),
|
|
114
|
-
headers: jsonContentHeaders,
|
|
115
|
-
method: 'POST',
|
|
116
|
-
path: `/cockpit/v1beta1/deactivate`
|
|
117
|
-
}, unmarshalCockpit);
|
|
118
|
-
};
|
|
119
|
-
})();
|
|
74
|
+
deactivateCockpit = (request = {}) => this.client.fetch({
|
|
75
|
+
body: JSON.stringify(marshalDeactivateCockpitRequest(request, this.client.settings)),
|
|
76
|
+
headers: jsonContentHeaders,
|
|
77
|
+
method: 'POST',
|
|
78
|
+
path: `/cockpit/v1beta1/deactivate`
|
|
79
|
+
}, unmarshalCockpit);
|
|
120
80
|
|
|
121
81
|
/**
|
|
122
82
|
* Create a datasource for the specified Project ID and the given type.
|
|
@@ -140,19 +100,11 @@ class API extends API$1 {
|
|
|
140
100
|
method: 'DELETE',
|
|
141
101
|
path: `/cockpit/v1beta1/datasources/${validatePathParam('datasourceId', request.datasourceId)}`
|
|
142
102
|
});
|
|
143
|
-
pageOfListDatasources = (
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
}
|
|
149
|
-
return _this6.client.fetch({
|
|
150
|
-
method: 'GET',
|
|
151
|
-
path: `/cockpit/v1beta1/datasources`,
|
|
152
|
-
urlParams: urlParams(['is_managed_by_scaleway', request.isManagedByScaleway], ['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? _this6.client.settings.defaultPageSize], ['project_id', request.projectId ?? _this6.client.settings.defaultProjectId], ['types', request.types])
|
|
153
|
-
}, unmarshalListDatasourcesResponse);
|
|
154
|
-
};
|
|
155
|
-
})();
|
|
103
|
+
pageOfListDatasources = (request = {}) => this.client.fetch({
|
|
104
|
+
method: 'GET',
|
|
105
|
+
path: `/cockpit/v1beta1/datasources`,
|
|
106
|
+
urlParams: urlParams(['is_managed_by_scaleway', request.isManagedByScaleway], ['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['types', request.types])
|
|
107
|
+
}, unmarshalListDatasourcesResponse);
|
|
156
108
|
|
|
157
109
|
/**
|
|
158
110
|
* Get a list of datasources for the specified Project ID.
|
|
@@ -160,15 +112,7 @@ class API extends API$1 {
|
|
|
160
112
|
* @param request - The request {@link ListDatasourcesRequest}
|
|
161
113
|
* @returns A Promise of ListDatasourcesResponse
|
|
162
114
|
*/
|
|
163
|
-
listDatasources = (
|
|
164
|
-
var _this7 = this;
|
|
165
|
-
return function (request) {
|
|
166
|
-
if (request === void 0) {
|
|
167
|
-
request = {};
|
|
168
|
-
}
|
|
169
|
-
return enrichForPagination('datasources', _this7.pageOfListDatasources, request);
|
|
170
|
-
};
|
|
171
|
-
})();
|
|
115
|
+
listDatasources = (request = {}) => enrichForPagination('datasources', this.pageOfListDatasources, request);
|
|
172
116
|
|
|
173
117
|
/**
|
|
174
118
|
* Create a token associated with the specified Project ID.
|
|
@@ -176,33 +120,17 @@ class API extends API$1 {
|
|
|
176
120
|
* @param request - The request {@link CreateTokenRequest}
|
|
177
121
|
* @returns A Promise of Token
|
|
178
122
|
*/
|
|
179
|
-
createToken = (
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
}, unmarshalToken);
|
|
191
|
-
};
|
|
192
|
-
})();
|
|
193
|
-
pageOfListTokens = (() => {
|
|
194
|
-
var _this9 = this;
|
|
195
|
-
return function (request) {
|
|
196
|
-
if (request === void 0) {
|
|
197
|
-
request = {};
|
|
198
|
-
}
|
|
199
|
-
return _this9.client.fetch({
|
|
200
|
-
method: 'GET',
|
|
201
|
-
path: `/cockpit/v1beta1/tokens`,
|
|
202
|
-
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? _this9.client.settings.defaultPageSize], ['project_id', request.projectId ?? _this9.client.settings.defaultProjectId])
|
|
203
|
-
}, unmarshalListTokensResponse);
|
|
204
|
-
};
|
|
205
|
-
})();
|
|
123
|
+
createToken = (request = {}) => this.client.fetch({
|
|
124
|
+
body: JSON.stringify(marshalCreateTokenRequest(request, this.client.settings)),
|
|
125
|
+
headers: jsonContentHeaders,
|
|
126
|
+
method: 'POST',
|
|
127
|
+
path: `/cockpit/v1beta1/tokens`
|
|
128
|
+
}, unmarshalToken);
|
|
129
|
+
pageOfListTokens = (request = {}) => this.client.fetch({
|
|
130
|
+
method: 'GET',
|
|
131
|
+
path: `/cockpit/v1beta1/tokens`,
|
|
132
|
+
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])
|
|
133
|
+
}, unmarshalListTokensResponse);
|
|
206
134
|
|
|
207
135
|
/**
|
|
208
136
|
* Get a list of tokens associated with the specified Project ID.
|
|
@@ -210,15 +138,7 @@ class API extends API$1 {
|
|
|
210
138
|
* @param request - The request {@link ListTokensRequest}
|
|
211
139
|
* @returns A Promise of ListTokensResponse
|
|
212
140
|
*/
|
|
213
|
-
listTokens = (
|
|
214
|
-
var _this10 = this;
|
|
215
|
-
return function (request) {
|
|
216
|
-
if (request === void 0) {
|
|
217
|
-
request = {};
|
|
218
|
-
}
|
|
219
|
-
return enrichForPagination('tokens', _this10.pageOfListTokens, request);
|
|
220
|
-
};
|
|
221
|
-
})();
|
|
141
|
+
listTokens = (request = {}) => enrichForPagination('tokens', this.pageOfListTokens, request);
|
|
222
142
|
|
|
223
143
|
/**
|
|
224
144
|
* Retrieve the token associated with the specified token ID.
|
|
@@ -247,33 +167,17 @@ class API extends API$1 {
|
|
|
247
167
|
* @param request - The request {@link CreateContactPointRequest}
|
|
248
168
|
* @returns A Promise of ContactPoint
|
|
249
169
|
*/
|
|
250
|
-
createContactPoint = (
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
}, unmarshalContactPoint);
|
|
262
|
-
};
|
|
263
|
-
})();
|
|
264
|
-
pageOfListContactPoints = (() => {
|
|
265
|
-
var _this12 = this;
|
|
266
|
-
return function (request) {
|
|
267
|
-
if (request === void 0) {
|
|
268
|
-
request = {};
|
|
269
|
-
}
|
|
270
|
-
return _this12.client.fetch({
|
|
271
|
-
method: 'GET',
|
|
272
|
-
path: `/cockpit/v1beta1/contact-points`,
|
|
273
|
-
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? _this12.client.settings.defaultPageSize], ['project_id', request.projectId ?? _this12.client.settings.defaultProjectId])
|
|
274
|
-
}, unmarshalListContactPointsResponse);
|
|
275
|
-
};
|
|
276
|
-
})();
|
|
170
|
+
createContactPoint = (request = {}) => this.client.fetch({
|
|
171
|
+
body: JSON.stringify(marshalCreateContactPointRequest(request, this.client.settings)),
|
|
172
|
+
headers: jsonContentHeaders,
|
|
173
|
+
method: 'POST',
|
|
174
|
+
path: `/cockpit/v1beta1/contact-points`
|
|
175
|
+
}, unmarshalContactPoint);
|
|
176
|
+
pageOfListContactPoints = (request = {}) => this.client.fetch({
|
|
177
|
+
method: 'GET',
|
|
178
|
+
path: `/cockpit/v1beta1/contact-points`,
|
|
179
|
+
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId])
|
|
180
|
+
}, unmarshalListContactPointsResponse);
|
|
277
181
|
|
|
278
182
|
/**
|
|
279
183
|
* Get a list of contact points for the Cockpit associated with the specified
|
|
@@ -282,95 +186,55 @@ class API extends API$1 {
|
|
|
282
186
|
* @param request - The request {@link ListContactPointsRequest}
|
|
283
187
|
* @returns A Promise of ListContactPointsResponse
|
|
284
188
|
*/
|
|
285
|
-
listContactPoints = (
|
|
286
|
-
var _this13 = this;
|
|
287
|
-
return function (request) {
|
|
288
|
-
if (request === void 0) {
|
|
289
|
-
request = {};
|
|
290
|
-
}
|
|
291
|
-
return enrichForPagination('contactPoints', _this13.pageOfListContactPoints, request);
|
|
292
|
-
};
|
|
293
|
-
})();
|
|
189
|
+
listContactPoints = (request = {}) => enrichForPagination('contactPoints', this.pageOfListContactPoints, request);
|
|
294
190
|
|
|
295
191
|
/**
|
|
296
192
|
* Delete a contact point for the default receiver.
|
|
297
193
|
*
|
|
298
194
|
* @param request - The request {@link DeleteContactPointRequest}
|
|
299
195
|
*/
|
|
300
|
-
deleteContactPoint = (
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
return _this14.client.fetch({
|
|
307
|
-
body: JSON.stringify(marshalDeleteContactPointRequest(request, _this14.client.settings)),
|
|
308
|
-
headers: jsonContentHeaders,
|
|
309
|
-
method: 'POST',
|
|
310
|
-
path: `/cockpit/v1beta1/delete-contact-point`
|
|
311
|
-
});
|
|
312
|
-
};
|
|
313
|
-
})();
|
|
196
|
+
deleteContactPoint = (request = {}) => this.client.fetch({
|
|
197
|
+
body: JSON.stringify(marshalDeleteContactPointRequest(request, this.client.settings)),
|
|
198
|
+
headers: jsonContentHeaders,
|
|
199
|
+
method: 'POST',
|
|
200
|
+
path: `/cockpit/v1beta1/delete-contact-point`
|
|
201
|
+
});
|
|
314
202
|
|
|
315
203
|
/**
|
|
316
204
|
* Enable the sending of managed alerts for the specified Project's Cockpit.
|
|
317
205
|
*
|
|
318
206
|
* @param request - The request {@link EnableManagedAlertsRequest}
|
|
319
207
|
*/
|
|
320
|
-
enableManagedAlerts = (
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
return _this15.client.fetch({
|
|
327
|
-
body: JSON.stringify(marshalEnableManagedAlertsRequest(request, _this15.client.settings)),
|
|
328
|
-
headers: jsonContentHeaders,
|
|
329
|
-
method: 'POST',
|
|
330
|
-
path: `/cockpit/v1beta1/enable-managed-alerts`
|
|
331
|
-
});
|
|
332
|
-
};
|
|
333
|
-
})();
|
|
208
|
+
enableManagedAlerts = (request = {}) => this.client.fetch({
|
|
209
|
+
body: JSON.stringify(marshalEnableManagedAlertsRequest(request, this.client.settings)),
|
|
210
|
+
headers: jsonContentHeaders,
|
|
211
|
+
method: 'POST',
|
|
212
|
+
path: `/cockpit/v1beta1/enable-managed-alerts`
|
|
213
|
+
});
|
|
334
214
|
|
|
335
215
|
/**
|
|
336
216
|
* Disable the sending of managed alerts for the specified Project's Cockpit.
|
|
337
217
|
*
|
|
338
218
|
* @param request - The request {@link DisableManagedAlertsRequest}
|
|
339
219
|
*/
|
|
340
|
-
disableManagedAlerts = (
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
return _this16.client.fetch({
|
|
347
|
-
body: JSON.stringify(marshalDisableManagedAlertsRequest(request, _this16.client.settings)),
|
|
348
|
-
headers: jsonContentHeaders,
|
|
349
|
-
method: 'POST',
|
|
350
|
-
path: `/cockpit/v1beta1/disable-managed-alerts`
|
|
351
|
-
});
|
|
352
|
-
};
|
|
353
|
-
})();
|
|
220
|
+
disableManagedAlerts = (request = {}) => this.client.fetch({
|
|
221
|
+
body: JSON.stringify(marshalDisableManagedAlertsRequest(request, this.client.settings)),
|
|
222
|
+
headers: jsonContentHeaders,
|
|
223
|
+
method: 'POST',
|
|
224
|
+
path: `/cockpit/v1beta1/disable-managed-alerts`
|
|
225
|
+
});
|
|
354
226
|
|
|
355
227
|
/**
|
|
356
228
|
* Trigger a test alert to all of the Cockpit's receivers.
|
|
357
229
|
*
|
|
358
230
|
* @param request - The request {@link TriggerTestAlertRequest}
|
|
359
231
|
*/
|
|
360
|
-
triggerTestAlert = (
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
return _this17.client.fetch({
|
|
367
|
-
body: JSON.stringify(marshalTriggerTestAlertRequest(request, _this17.client.settings)),
|
|
368
|
-
headers: jsonContentHeaders,
|
|
369
|
-
method: 'POST',
|
|
370
|
-
path: `/cockpit/v1beta1/trigger-test-alert`
|
|
371
|
-
});
|
|
372
|
-
};
|
|
373
|
-
})();
|
|
232
|
+
triggerTestAlert = (request = {}) => this.client.fetch({
|
|
233
|
+
body: JSON.stringify(marshalTriggerTestAlertRequest(request, this.client.settings)),
|
|
234
|
+
headers: jsonContentHeaders,
|
|
235
|
+
method: 'POST',
|
|
236
|
+
path: `/cockpit/v1beta1/trigger-test-alert`
|
|
237
|
+
});
|
|
374
238
|
|
|
375
239
|
/**
|
|
376
240
|
* Create a Grafana user for your Cockpit's Grafana instance. Make sure you
|
|
@@ -385,19 +249,11 @@ class API extends API$1 {
|
|
|
385
249
|
method: 'POST',
|
|
386
250
|
path: `/cockpit/v1beta1/grafana-users`
|
|
387
251
|
}, unmarshalGrafanaUser);
|
|
388
|
-
pageOfListGrafanaUsers = (
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
}
|
|
394
|
-
return _this18.client.fetch({
|
|
395
|
-
method: 'GET',
|
|
396
|
-
path: `/cockpit/v1beta1/grafana-users`,
|
|
397
|
-
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? _this18.client.settings.defaultPageSize], ['project_id', request.projectId ?? _this18.client.settings.defaultProjectId])
|
|
398
|
-
}, unmarshalListGrafanaUsersResponse);
|
|
399
|
-
};
|
|
400
|
-
})();
|
|
252
|
+
pageOfListGrafanaUsers = (request = {}) => this.client.fetch({
|
|
253
|
+
method: 'GET',
|
|
254
|
+
path: `/cockpit/v1beta1/grafana-users`,
|
|
255
|
+
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])
|
|
256
|
+
}, unmarshalListGrafanaUsersResponse);
|
|
401
257
|
|
|
402
258
|
/**
|
|
403
259
|
* Get a list of Grafana users who are able to connect to the Cockpit's
|
|
@@ -406,15 +262,7 @@ class API extends API$1 {
|
|
|
406
262
|
* @param request - The request {@link ListGrafanaUsersRequest}
|
|
407
263
|
* @returns A Promise of ListGrafanaUsersResponse
|
|
408
264
|
*/
|
|
409
|
-
listGrafanaUsers = (
|
|
410
|
-
var _this19 = this;
|
|
411
|
-
return function (request) {
|
|
412
|
-
if (request === void 0) {
|
|
413
|
-
request = {};
|
|
414
|
-
}
|
|
415
|
-
return enrichForPagination('grafanaUsers', _this19.pageOfListGrafanaUsers, request);
|
|
416
|
-
};
|
|
417
|
-
})();
|
|
265
|
+
listGrafanaUsers = (request = {}) => enrichForPagination('grafanaUsers', this.pageOfListGrafanaUsers, request);
|
|
418
266
|
|
|
419
267
|
/**
|
|
420
268
|
* Delete a Grafana user from a Grafana instance, specified by the Cockpit's
|
|
@@ -442,19 +290,11 @@ class API extends API$1 {
|
|
|
442
290
|
method: 'POST',
|
|
443
291
|
path: `/cockpit/v1beta1/grafana-users/${validatePathParam('grafanaUserId', request.grafanaUserId)}/reset-password`
|
|
444
292
|
}, unmarshalGrafanaUser);
|
|
445
|
-
pageOfListPlans = (
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
}
|
|
451
|
-
return _this20.client.fetch({
|
|
452
|
-
method: 'GET',
|
|
453
|
-
path: `/cockpit/v1beta1/plans`,
|
|
454
|
-
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? _this20.client.settings.defaultPageSize])
|
|
455
|
-
}, unmarshalListPlansResponse);
|
|
456
|
-
};
|
|
457
|
-
})();
|
|
293
|
+
pageOfListPlans = (request = {}) => this.client.fetch({
|
|
294
|
+
method: 'GET',
|
|
295
|
+
path: `/cockpit/v1beta1/plans`,
|
|
296
|
+
urlParams: urlParams(['order_by', request.orderBy], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize])
|
|
297
|
+
}, unmarshalListPlansResponse);
|
|
458
298
|
|
|
459
299
|
/**
|
|
460
300
|
* Get a list of all pricing plans available.
|
|
@@ -462,15 +302,7 @@ class API extends API$1 {
|
|
|
462
302
|
* @param request - The request {@link ListPlansRequest}
|
|
463
303
|
* @returns A Promise of ListPlansResponse
|
|
464
304
|
*/
|
|
465
|
-
listPlans = (
|
|
466
|
-
var _this21 = this;
|
|
467
|
-
return function (request) {
|
|
468
|
-
if (request === void 0) {
|
|
469
|
-
request = {};
|
|
470
|
-
}
|
|
471
|
-
return enrichForPagination('plans', _this21.pageOfListPlans, request);
|
|
472
|
-
};
|
|
473
|
-
})();
|
|
305
|
+
listPlans = (request = {}) => enrichForPagination('plans', this.pageOfListPlans, request);
|
|
474
306
|
|
|
475
307
|
/**
|
|
476
308
|
* Select your chosen pricing plan for your Cockpit, specifying the Cockpit's
|
|
@@ -485,19 +317,11 @@ class API extends API$1 {
|
|
|
485
317
|
method: 'POST',
|
|
486
318
|
path: `/cockpit/v1beta1/select-plan`
|
|
487
319
|
}, unmarshalSelectPlanResponse);
|
|
488
|
-
pageOfListGrafanaProductDashboards = (
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
}
|
|
494
|
-
return _this22.client.fetch({
|
|
495
|
-
method: 'GET',
|
|
496
|
-
path: `/cockpit/v1beta1/grafana-product-dashboards`,
|
|
497
|
-
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? _this22.client.settings.defaultPageSize], ['project_id', request.projectId ?? _this22.client.settings.defaultProjectId], ['tags', request.tags])
|
|
498
|
-
}, unmarshalListGrafanaProductDashboardsResponse);
|
|
499
|
-
};
|
|
500
|
-
})();
|
|
320
|
+
pageOfListGrafanaProductDashboards = (request = {}) => this.client.fetch({
|
|
321
|
+
method: 'GET',
|
|
322
|
+
path: `/cockpit/v1beta1/grafana-product-dashboards`,
|
|
323
|
+
urlParams: urlParams(['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['project_id', request.projectId ?? this.client.settings.defaultProjectId], ['tags', request.tags])
|
|
324
|
+
}, unmarshalListGrafanaProductDashboardsResponse);
|
|
501
325
|
|
|
502
326
|
/**
|
|
503
327
|
* List product dashboards. Get a list of available product dashboards.
|
|
@@ -505,15 +329,7 @@ class API extends API$1 {
|
|
|
505
329
|
* @param request - The request {@link ListGrafanaProductDashboardsRequest}
|
|
506
330
|
* @returns A Promise of ListGrafanaProductDashboardsResponse
|
|
507
331
|
*/
|
|
508
|
-
listGrafanaProductDashboards = (
|
|
509
|
-
var _this23 = this;
|
|
510
|
-
return function (request) {
|
|
511
|
-
if (request === void 0) {
|
|
512
|
-
request = {};
|
|
513
|
-
}
|
|
514
|
-
return enrichForPagination('dashboards', _this23.pageOfListGrafanaProductDashboards, request);
|
|
515
|
-
};
|
|
516
|
-
})();
|
|
332
|
+
listGrafanaProductDashboards = (request = {}) => enrichForPagination('dashboards', this.pageOfListGrafanaProductDashboards, request);
|
|
517
333
|
|
|
518
334
|
/**
|
|
519
335
|
* Get a product dashboard. Get a product dashboard specified by the dashboard
|