@scaleway/sdk 1.10.1 → 1.12.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/README.md +1 -1
- package/dist/api/account/v2/api.gen.js +1 -0
- package/dist/api/account/v2/index.gen.js +1 -0
- package/dist/api/account/v2/marshalling.gen.js +1 -0
- package/dist/api/applesilicon/v1alpha1/api.gen.js +1 -0
- package/dist/api/applesilicon/v1alpha1/index.gen.js +1 -0
- package/dist/api/applesilicon/v1alpha1/marshalling.gen.js +1 -0
- package/dist/api/baremetal/v1/api.gen.js +1 -0
- package/dist/api/baremetal/v1/marshalling.gen.js +1 -0
- package/dist/api/billing/v2alpha1/api.gen.js +1 -0
- package/dist/api/billing/v2alpha1/index.gen.js +1 -0
- package/dist/api/billing/v2alpha1/marshalling.gen.js +1 -0
- package/dist/api/cockpit/v1beta1/api.gen.js +1 -0
- package/dist/api/cockpit/v1beta1/index.gen.js +1 -0
- package/dist/api/cockpit/v1beta1/marshalling.gen.js +1 -0
- package/dist/api/container/v1beta1/api.gen.js +1 -0
- package/dist/api/container/v1beta1/index.gen.js +1 -0
- package/dist/api/container/v1beta1/marshalling.gen.js +1 -0
- package/dist/api/domain/v2beta1/api.gen.js +3 -2
- package/dist/api/domain/v2beta1/index.gen.js +1 -0
- package/dist/api/domain/v2beta1/marshalling.gen.js +1 -0
- package/dist/api/flexibleip/v1alpha1/api.gen.js +1 -0
- package/dist/api/flexibleip/v1alpha1/index.gen.js +1 -0
- package/dist/api/flexibleip/v1alpha1/marshalling.gen.js +1 -0
- package/dist/api/function/v1beta1/api.gen.js +1 -0
- package/dist/api/function/v1beta1/index.gen.js +1 -0
- package/dist/api/function/v1beta1/marshalling.gen.js +1 -0
- package/dist/api/iam/v1alpha1/api.gen.js +19 -1
- package/dist/api/iam/v1alpha1/index.gen.js +1 -0
- package/dist/api/iam/v1alpha1/marshalling.gen.js +6 -1
- package/dist/api/instance/v1/api.gen.js +1 -0
- package/dist/api/instance/v1/marshalling.gen.js +1 -0
- package/dist/api/iot/v1/api.gen.js +1 -0
- package/dist/api/iot/v1/index.gen.js +1 -0
- package/dist/api/iot/v1/marshalling.gen.js +1 -0
- package/dist/api/k8s/v1/api.gen.js +49 -55
- package/dist/api/k8s/v1/marshalling.gen.js +4 -2
- package/dist/api/lb/v1/api.gen.js +1 -0
- package/dist/api/lb/v1/marshalling.gen.js +11 -0
- package/dist/api/marketplace/v1/api.gen.js +1 -0
- package/dist/api/marketplace/v1/index.gen.js +1 -0
- package/dist/api/marketplace/v1/marshalling.gen.js +1 -0
- package/dist/api/marketplace/v2/api.gen.js +1 -0
- package/dist/api/marketplace/v2/index.gen.js +1 -0
- package/dist/api/marketplace/v2/marshalling.gen.js +1 -0
- package/dist/api/mnq/v1alpha1/api.gen.js +1 -0
- package/dist/api/mnq/v1alpha1/index.gen.js +1 -0
- package/dist/api/mnq/v1alpha1/marshalling.gen.js +1 -0
- package/dist/api/rdb/v1/api.gen.js +1 -0
- package/dist/api/rdb/v1/index.gen.js +1 -0
- package/dist/api/rdb/v1/marshalling.gen.js +1 -0
- package/dist/api/redis/v1/api.gen.js +1 -0
- package/dist/api/redis/v1/index.gen.js +1 -0
- package/dist/api/redis/v1/marshalling.gen.js +1 -0
- package/dist/api/registry/v1/api.gen.js +1 -0
- package/dist/api/registry/v1/index.gen.js +1 -0
- package/dist/api/registry/v1/marshalling.gen.js +1 -0
- package/dist/api/secret/v1alpha1/api.gen.js +1 -0
- package/dist/api/secret/v1alpha1/index.gen.js +1 -0
- package/dist/api/secret/v1alpha1/marshalling.gen.js +1 -0
- package/dist/api/tem/v1alpha1/api.gen.js +11 -2
- package/dist/api/tem/v1alpha1/index.gen.js +1 -0
- package/dist/api/tem/v1alpha1/marshalling.gen.js +2 -0
- package/dist/api/test/v1/api.gen.js +1 -0
- package/dist/api/test/v1/index.gen.js +1 -0
- package/dist/api/test/v1/marshalling.gen.js +1 -0
- package/dist/api/vpc/v1/api.gen.js +1 -0
- package/dist/api/vpc/v1/index.gen.js +1 -0
- package/dist/api/vpc/v1/marshalling.gen.js +1 -0
- package/dist/api/vpcgw/v1/api.gen.js +1 -0
- package/dist/api/vpcgw/v1/index.gen.js +1 -0
- package/dist/api/vpcgw/v1/marshalling.gen.js +1 -0
- package/dist/api/webhosting/v1alpha1/api.gen.js +1 -0
- package/dist/api/webhosting/v1alpha1/index.gen.js +1 -0
- package/dist/api/webhosting/v1alpha1/marshalling.gen.js +1 -0
- package/dist/index.cjs +183 -68
- package/dist/index.d.ts +386 -306
- package/dist/scw/client-ini-profile.js +3 -3
- package/dist/scw/client.js +2 -2
- package/dist/scw/constants.js +1 -1
- package/dist/scw/custom-marshalling.js +5 -1
- package/dist/scw/fetch/resource-paginator.js +2 -0
- package/package.json +2 -2
|
@@ -6,6 +6,7 @@ import { CLUSTER_TRANSIENT_STATUSES, POOL_TRANSIENT_STATUSES, NODE_TRANSIENT_STA
|
|
|
6
6
|
import { unmarshalListClustersResponse, marshalCreateClusterRequest, unmarshalCluster, marshalUpdateClusterRequest, marshalUpgradeClusterRequest, marshalSetClusterTypeRequest, unmarshalListClusterAvailableVersionsResponse, unmarshalListPoolsResponse, marshalCreatePoolRequest, unmarshalPool, marshalUpgradePoolRequest, marshalUpdatePoolRequest, unmarshalExternalNode, unmarshalListNodesResponse, unmarshalNode, unmarshalListVersionsResponse, unmarshalVersion } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -27,8 +28,7 @@ class API extends API$1 {
|
|
|
27
28
|
}, unmarshalListClustersResponse);
|
|
28
29
|
};
|
|
29
30
|
/**
|
|
30
|
-
* List
|
|
31
|
-
* Region.
|
|
31
|
+
* List Clusters. List all existing Kubernetes clusters in a specific region.
|
|
32
32
|
*
|
|
33
33
|
* @param request - The request {@link ListClustersRequest}
|
|
34
34
|
* @returns A Promise of ListClustersResponse
|
|
@@ -40,8 +40,7 @@ class API extends API$1 {
|
|
|
40
40
|
return enrichForPagination('clusters', _this.pageOfListClusters, request);
|
|
41
41
|
};
|
|
42
42
|
/**
|
|
43
|
-
* Create a new
|
|
44
|
-
* account.
|
|
43
|
+
* Create a new Cluster. Create a new Kubernetes cluster in a Scaleway region.
|
|
45
44
|
*
|
|
46
45
|
* @param request - The request {@link CreateClusterRequest}
|
|
47
46
|
* @returns A Promise of Cluster
|
|
@@ -53,8 +52,7 @@ class API extends API$1 {
|
|
|
53
52
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters`
|
|
54
53
|
}, unmarshalCluster);
|
|
55
54
|
/**
|
|
56
|
-
* Get
|
|
57
|
-
* cluster.
|
|
55
|
+
* Get a Cluster. Retrieve information about a specific Kubernetes cluster.
|
|
58
56
|
*
|
|
59
57
|
* @param request - The request {@link GetClusterRequest}
|
|
60
58
|
* @returns A Promise of Cluster
|
|
@@ -72,10 +70,9 @@ class API extends API$1 {
|
|
|
72
70
|
*/
|
|
73
71
|
this.waitForCluster = (request, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!CLUSTER_TRANSIENT_STATUSES.includes(res.status))), this.getCluster, request, options);
|
|
74
72
|
/**
|
|
75
|
-
* Update a
|
|
76
|
-
*
|
|
77
|
-
*
|
|
78
|
-
* do so, use the dedicated endpoint.
|
|
73
|
+
* Update a Cluster. Update information on a specific Kubernetes cluster. You
|
|
74
|
+
* can update details such as its name, description, tags and configuration.
|
|
75
|
+
* To upgrade a cluster, you will need to use the dedicated endpoint.
|
|
79
76
|
*
|
|
80
77
|
* @param request - The request {@link UpdateClusterRequest}
|
|
81
78
|
* @returns A Promise of Cluster
|
|
@@ -87,9 +84,9 @@ class API extends API$1 {
|
|
|
87
84
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}`
|
|
88
85
|
}, unmarshalCluster);
|
|
89
86
|
/**
|
|
90
|
-
* Delete a
|
|
91
|
-
* and nodes. Note that this method will not delete any Load
|
|
92
|
-
* Block
|
|
87
|
+
* Delete a Cluster. Delete a specific Kubernetes cluster and all its
|
|
88
|
+
* associated pools and nodes. Note that this method will not delete any Load
|
|
89
|
+
* Balancer or Block Volume that are associated with the cluster.
|
|
93
90
|
*
|
|
94
91
|
* @param request - The request {@link DeleteClusterRequest}
|
|
95
92
|
* @returns A Promise of Cluster
|
|
@@ -100,7 +97,7 @@ class API extends API$1 {
|
|
|
100
97
|
urlParams: urlParams(['with_additional_resources', request.withAdditionalResources])
|
|
101
98
|
}, unmarshalCluster);
|
|
102
99
|
/**
|
|
103
|
-
* Upgrade a
|
|
100
|
+
* Upgrade a Cluster. Upgrade a specific Kubernetes cluster and possibly its
|
|
104
101
|
* associated pools to a specific and supported Kubernetes version.
|
|
105
102
|
*
|
|
106
103
|
* @param request - The request {@link UpgradeClusterRequest}
|
|
@@ -113,7 +110,7 @@ class API extends API$1 {
|
|
|
113
110
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}/upgrade`
|
|
114
111
|
}, unmarshalCluster);
|
|
115
112
|
/**
|
|
116
|
-
* Change
|
|
113
|
+
* Change the Cluster type. Change the type of a specific Kubernetes cluster.
|
|
117
114
|
*
|
|
118
115
|
* @param request - The request {@link SetClusterTypeRequest}
|
|
119
116
|
* @returns A Promise of Cluster
|
|
@@ -125,8 +122,8 @@ class API extends API$1 {
|
|
|
125
122
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}/set-type`
|
|
126
123
|
}, unmarshalCluster);
|
|
127
124
|
/**
|
|
128
|
-
* List available versions for a
|
|
129
|
-
* Kubernetes cluster is allowed to upgrade to. Results will
|
|
125
|
+
* List available versions for a Cluster. List the versions that a specific
|
|
126
|
+
* Kubernetes cluster is allowed to upgrade to. Results will include every
|
|
130
127
|
* patch version greater than the current patch, as well as one minor version
|
|
131
128
|
* ahead of the current version. Any upgrade skipping a minor version will not
|
|
132
129
|
* work.
|
|
@@ -145,10 +142,10 @@ class API extends API$1 {
|
|
|
145
142
|
responseType: 'blob'
|
|
146
143
|
});
|
|
147
144
|
/**
|
|
148
|
-
* Reset the admin token of a
|
|
149
|
-
* Kubernetes cluster. This will
|
|
150
|
-
*
|
|
151
|
-
*
|
|
145
|
+
* Reset the admin token of a Cluster. Reset the admin token for a specific
|
|
146
|
+
* Kubernetes cluster. This will revoke the old admin token (which will not be
|
|
147
|
+
* usable afterwards) and create a new one. Note that you will need to
|
|
148
|
+
* download kubeconfig again to keep interacting with the cluster.
|
|
152
149
|
*
|
|
153
150
|
* @param request - The request {@link ResetClusterAdminTokenRequest}
|
|
154
151
|
*/
|
|
@@ -164,7 +161,7 @@ class API extends API$1 {
|
|
|
164
161
|
urlParams: urlParams(['name', request.name], ['order_by', request.orderBy ?? 'created_at_asc'], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['status', request.status ?? 'unknown'])
|
|
165
162
|
}, unmarshalListPoolsResponse);
|
|
166
163
|
/**
|
|
167
|
-
* List
|
|
164
|
+
* List Pools in a Cluster. List all the existing pools for a specific
|
|
168
165
|
* Kubernetes cluster.
|
|
169
166
|
*
|
|
170
167
|
* @param request - The request {@link ListPoolsRequest}
|
|
@@ -172,7 +169,7 @@ class API extends API$1 {
|
|
|
172
169
|
*/
|
|
173
170
|
this.listPools = request => enrichForPagination('pools', this.pageOfListPools, request);
|
|
174
171
|
/**
|
|
175
|
-
* Create a new
|
|
172
|
+
* Create a new Pool in a Cluster. Create a new pool in a specific Kubernetes
|
|
176
173
|
* cluster.
|
|
177
174
|
*
|
|
178
175
|
* @param request - The request {@link CreatePoolRequest}
|
|
@@ -185,8 +182,8 @@ class API extends API$1 {
|
|
|
185
182
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/clusters/${validatePathParam('clusterId', request.clusterId)}/pools`
|
|
186
183
|
}, unmarshalPool);
|
|
187
184
|
/**
|
|
188
|
-
* Get a
|
|
189
|
-
* cluster.
|
|
185
|
+
* Get a Pool in a Cluster. Retrieve details about a specific pool in a
|
|
186
|
+
* Kubernetes cluster.
|
|
190
187
|
*
|
|
191
188
|
* @param request - The request {@link GetPoolRequest}
|
|
192
189
|
* @returns A Promise of Pool
|
|
@@ -204,9 +201,9 @@ class API extends API$1 {
|
|
|
204
201
|
*/
|
|
205
202
|
this.waitForPool = (request, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!POOL_TRANSIENT_STATUSES.includes(res.status))), this.getPool, request, options);
|
|
206
203
|
/**
|
|
207
|
-
* Upgrade a
|
|
208
|
-
* pool. Note that
|
|
209
|
-
*
|
|
204
|
+
* Upgrade a Pool in a Cluster. Upgrade the Kubernetes version of a specific
|
|
205
|
+
* pool. Note that it only works if the targeted version matches the cluster's
|
|
206
|
+
* version.
|
|
210
207
|
*
|
|
211
208
|
* @param request - The request {@link UpgradePoolRequest}
|
|
212
209
|
* @returns A Promise of Pool
|
|
@@ -218,8 +215,8 @@ class API extends API$1 {
|
|
|
218
215
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/pools/${validatePathParam('poolId', request.poolId)}/upgrade`
|
|
219
216
|
}, unmarshalPool);
|
|
220
217
|
/**
|
|
221
|
-
* Update a
|
|
222
|
-
* size, autoscaling settings, and tags.
|
|
218
|
+
* Update a Pool in a Cluster. Update the attributes of a specific pool, such
|
|
219
|
+
* as its desired size, autoscaling settings, and tags.
|
|
223
220
|
*
|
|
224
221
|
* @param request - The request {@link UpdatePoolRequest}
|
|
225
222
|
* @returns A Promise of Pool
|
|
@@ -231,8 +228,8 @@ class API extends API$1 {
|
|
|
231
228
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/pools/${validatePathParam('poolId', request.poolId)}`
|
|
232
229
|
}, unmarshalPool);
|
|
233
230
|
/**
|
|
234
|
-
* Delete a
|
|
235
|
-
* the pool's nodes will also be deleted.
|
|
231
|
+
* Delete a Pool in a Cluster. Delete a specific pool from a cluster. Note
|
|
232
|
+
* that all the pool's nodes will also be deleted.
|
|
236
233
|
*
|
|
237
234
|
* @param request - The request {@link DeletePoolRequest}
|
|
238
235
|
* @returns A Promise of Pool
|
|
@@ -242,8 +239,8 @@ class API extends API$1 {
|
|
|
242
239
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/pools/${validatePathParam('poolId', request.poolId)}`
|
|
243
240
|
}, unmarshalPool);
|
|
244
241
|
/**
|
|
245
|
-
* Create a Kosmos node.
|
|
246
|
-
* intended to be
|
|
242
|
+
* Create a Kosmos node. Retrieve metadata for a Kosmos node. This method is
|
|
243
|
+
* not intended to be called by end users but rather programmatically by the
|
|
247
244
|
* kapsule-node-agent.
|
|
248
245
|
*
|
|
249
246
|
* @param request - The request {@link CreateExternalNodeRequest}
|
|
@@ -261,7 +258,7 @@ class API extends API$1 {
|
|
|
261
258
|
urlParams: urlParams(['name', request.name], ['order_by', request.orderBy ?? 'created_at_asc'], ['page', request.page], ['page_size', request.pageSize ?? this.client.settings.defaultPageSize], ['pool_id', request.poolId], ['status', request.status ?? 'unknown'])
|
|
262
259
|
}, unmarshalListNodesResponse);
|
|
263
260
|
/**
|
|
264
|
-
* List
|
|
261
|
+
* List Nodes in a Cluster. List all the existing nodes for a specific
|
|
265
262
|
* Kubernetes cluster.
|
|
266
263
|
*
|
|
267
264
|
* @param request - The request {@link ListNodesRequest}
|
|
@@ -269,7 +266,7 @@ class API extends API$1 {
|
|
|
269
266
|
*/
|
|
270
267
|
this.listNodes = request => enrichForPagination('nodes', this.pageOfListNodes, request);
|
|
271
268
|
/**
|
|
272
|
-
* Get a
|
|
269
|
+
* Get a Node in a Cluster. Retrieve details about a specific Kubernetes Node.
|
|
273
270
|
*
|
|
274
271
|
* @param request - The request {@link GetNodeRequest}
|
|
275
272
|
* @returns A Promise of Node
|
|
@@ -287,13 +284,12 @@ class API extends API$1 {
|
|
|
287
284
|
*/
|
|
288
285
|
this.waitForNode = (request, options) => waitForResource(options?.stop ?? (res => Promise.resolve(!NODE_TRANSIENT_STATUSES.includes(res.status))), this.getNode, request, options);
|
|
289
286
|
/**
|
|
290
|
-
* Replace a
|
|
291
|
-
* cordoned
|
|
292
|
-
*
|
|
293
|
-
*
|
|
294
|
-
*
|
|
295
|
-
*
|
|
296
|
-
* disruption of your applications.
|
|
287
|
+
* Replace a Node in a Cluster. Replace a specific Node. The node will first
|
|
288
|
+
* be cordoned (scheduling will be disabled on it). The existing pods on the
|
|
289
|
+
* node will then be drained and rescheduled onto another schedulable node.
|
|
290
|
+
* Note that when there is not enough space to reschedule all the pods (such
|
|
291
|
+
* as in a one-node cluster), disruption of your applications can be
|
|
292
|
+
* expected.
|
|
297
293
|
*
|
|
298
294
|
* @deprecated
|
|
299
295
|
* @param request - The request {@link ReplaceNodeRequest}
|
|
@@ -306,12 +302,11 @@ class API extends API$1 {
|
|
|
306
302
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/nodes/${validatePathParam('nodeId', request.nodeId)}/replace`
|
|
307
303
|
}, unmarshalNode);
|
|
308
304
|
/**
|
|
309
|
-
* Reboot a
|
|
310
|
-
* cordoned
|
|
311
|
-
*
|
|
312
|
-
*
|
|
313
|
-
* one-node cluster
|
|
314
|
-
* applications.
|
|
305
|
+
* Reboot a Node in a Cluster. Reboot a specific Node. The node will first be
|
|
306
|
+
* cordoned (scheduling will be disabled on it). The existing pods on the node
|
|
307
|
+
* will then be drained and rescheduled onto another schedulable node. Note
|
|
308
|
+
* that when there is not enough space to reschedule all the pods (such as in
|
|
309
|
+
* a one-node cluster), disruption of your applications can be expected.
|
|
315
310
|
*
|
|
316
311
|
* @param request - The request {@link RebootNodeRequest}
|
|
317
312
|
* @returns A Promise of Node
|
|
@@ -323,9 +318,9 @@ class API extends API$1 {
|
|
|
323
318
|
path: `/k8s/v1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/nodes/${validatePathParam('nodeId', request.nodeId)}/reboot`
|
|
324
319
|
}, unmarshalNode);
|
|
325
320
|
/**
|
|
326
|
-
* Delete a
|
|
327
|
-
* not enough space to reschedule all the pods (in a one-node
|
|
328
|
-
*
|
|
321
|
+
* Delete a Node in a Cluster. Delete a specific Node. Note that when there is
|
|
322
|
+
* not enough space to reschedule all the pods (such as in a one-node
|
|
323
|
+
* cluster), disruption of your applications can be expected.
|
|
329
324
|
*
|
|
330
325
|
* @param request - The request {@link DeleteNodeRequest}
|
|
331
326
|
* @returns A Promise of Node
|
|
@@ -336,7 +331,7 @@ class API extends API$1 {
|
|
|
336
331
|
urlParams: urlParams(['replace', request.replace], ['skip_drain', request.skipDrain])
|
|
337
332
|
}, unmarshalNode);
|
|
338
333
|
/**
|
|
339
|
-
* List all available
|
|
334
|
+
* List all available Versions. List all available versions for the creation
|
|
340
335
|
* of a new Kubernetes cluster.
|
|
341
336
|
*
|
|
342
337
|
* @param request - The request {@link ListVersionsRequest}
|
|
@@ -352,8 +347,7 @@ class API extends API$1 {
|
|
|
352
347
|
}, unmarshalListVersionsResponse);
|
|
353
348
|
};
|
|
354
349
|
/**
|
|
355
|
-
* Get
|
|
356
|
-
* the details about the version.
|
|
350
|
+
* Get a Version. Retrieve a specific Kubernetes version and its details.
|
|
357
351
|
*
|
|
358
352
|
* @param request - The request {@link GetVersionRequest}
|
|
359
353
|
* @returns A Promise of Version
|
|
@@ -3,6 +3,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
3
3
|
import { unmarshalDate, unmarshalArrayOfObject, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
4
4
|
|
|
5
5
|
// This file was automatically generated. DO NOT EDIT.
|
|
6
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
6
7
|
const unmarshalMaintenanceWindow = data => {
|
|
7
8
|
if (!isJSONObject(data)) {
|
|
8
9
|
throw new TypeError(`Unmarshalling the type 'MaintenanceWindow' failed as data isn't a dictionary.`);
|
|
@@ -165,11 +166,12 @@ const unmarshalExternalNode = data => {
|
|
|
165
166
|
return {
|
|
166
167
|
clusterCa: data.cluster_ca,
|
|
167
168
|
clusterUrl: data.cluster_url,
|
|
168
|
-
|
|
169
|
+
externalIp: data.external_ip,
|
|
169
170
|
id: data.id,
|
|
170
171
|
kubeletConfig: data.kubelet_config,
|
|
171
172
|
kubeToken: data.kube_token,
|
|
172
|
-
name: data.name
|
|
173
|
+
name: data.name,
|
|
174
|
+
poolVersion: data.pool_version
|
|
173
175
|
};
|
|
174
176
|
};
|
|
175
177
|
const unmarshalListClusterAvailableVersionsResponse = data => {
|
|
@@ -6,6 +6,7 @@ import { LB_TRANSIENT_STATUSES, CERTIFICATE_TRANSIENT_STATUSES } from './content
|
|
|
6
6
|
import { unmarshalListLbsResponse, marshalCreateLbRequest, unmarshalLb, marshalUpdateLbRequest, marshalMigrateLbRequest, unmarshalListIpsResponse, marshalCreateIpRequest, unmarshalIp, marshalUpdateIpRequest, unmarshalListBackendsResponse, marshalCreateBackendRequest, unmarshalBackend, marshalUpdateBackendRequest, marshalAddBackendServersRequest, marshalRemoveBackendServersRequest, marshalSetBackendServersRequest, marshalUpdateHealthCheckRequest, unmarshalHealthCheck, unmarshalListFrontendsResponse, marshalCreateFrontendRequest, unmarshalFrontend, marshalUpdateFrontendRequest, unmarshalListRoutesResponse, marshalCreateRouteRequest, unmarshalRoute, marshalUpdateRouteRequest, unmarshalLbStats, unmarshalListBackendStatsResponse, unmarshalListAclResponse, marshalCreateAclRequest, unmarshalAcl, marshalUpdateAclRequest, marshalCreateCertificateRequest, unmarshalCertificate, unmarshalListCertificatesResponse, marshalUpdateCertificateRequest, unmarshalListLbTypesResponse, marshalCreateSubscriberRequest, unmarshalSubscriber, unmarshalListSubscriberResponse, marshalUpdateSubscriberRequest, marshalSubscribeToLbRequest, unmarshalListLbPrivateNetworksResponse, marshalAttachPrivateNetworkRequest, unmarshalPrivateNetwork, marshalZonedApiCreateLbRequest, marshalZonedApiUpdateLbRequest, marshalZonedApiMigrateLbRequest, marshalZonedApiCreateIpRequest, marshalZonedApiUpdateIpRequest, marshalZonedApiCreateBackendRequest, marshalZonedApiUpdateBackendRequest, marshalZonedApiAddBackendServersRequest, marshalZonedApiRemoveBackendServersRequest, marshalZonedApiSetBackendServersRequest, marshalZonedApiUpdateHealthCheckRequest, marshalZonedApiCreateFrontendRequest, marshalZonedApiUpdateFrontendRequest, marshalZonedApiCreateRouteRequest, marshalZonedApiUpdateRouteRequest, marshalZonedApiCreateAclRequest, marshalZonedApiUpdateAclRequest, marshalZonedApiSetAclsRequest, unmarshalSetAclsResponse, marshalZonedApiCreateCertificateRequest, marshalZonedApiUpdateCertificateRequest, marshalZonedApiCreateSubscriberRequest, marshalZonedApiUpdateSubscriberRequest, marshalZonedApiSubscribeToLbRequest, marshalZonedApiAttachPrivateNetworkRequest } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -3,6 +3,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
3
3
|
import { unmarshalDate, unmarshalArrayOfObject, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
4
4
|
|
|
5
5
|
// This file was automatically generated. DO NOT EDIT.
|
|
6
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
6
7
|
const unmarshalSubscriberEmailConfig = data => {
|
|
7
8
|
if (!isJSONObject(data)) {
|
|
8
9
|
throw new TypeError(`Unmarshalling the type 'SubscriberEmailConfig' failed as data isn't a dictionary.`);
|
|
@@ -187,6 +188,7 @@ const unmarshalBackend = data => {
|
|
|
187
188
|
id: data.id,
|
|
188
189
|
ignoreSslServerVerify: data.ignore_ssl_server_verify,
|
|
189
190
|
lb: data.lb ? unmarshalLb(data.lb) : undefined,
|
|
191
|
+
maxConnections: data.max_connections,
|
|
190
192
|
maxRetries: data.max_retries,
|
|
191
193
|
name: data.name,
|
|
192
194
|
onMarkedDownAction: data.on_marked_down_action,
|
|
@@ -198,6 +200,7 @@ const unmarshalBackend = data => {
|
|
|
198
200
|
stickySessions: data.sticky_sessions,
|
|
199
201
|
stickySessionsCookieName: data.sticky_sessions_cookie_name,
|
|
200
202
|
timeoutConnect: data.timeout_connect,
|
|
203
|
+
timeoutQueue: data.timeout_queue,
|
|
201
204
|
timeoutServer: data.timeout_server,
|
|
202
205
|
timeoutTunnel: data.timeout_tunnel,
|
|
203
206
|
updatedAt: unmarshalDate(data.updated_at)
|
|
@@ -607,6 +610,7 @@ const marshalCreateBackendRequest = (request, defaults) => ({
|
|
|
607
610
|
forward_protocol: request.forwardProtocol,
|
|
608
611
|
health_check: marshalHealthCheck(request.healthCheck),
|
|
609
612
|
ignore_ssl_server_verify: request.ignoreSslServerVerify,
|
|
613
|
+
max_connections: request.maxConnections,
|
|
610
614
|
max_retries: request.maxRetries,
|
|
611
615
|
name: request.name || randomName('lbb'),
|
|
612
616
|
on_marked_down_action: request.onMarkedDownAction ?? 'on_marked_down_action_none',
|
|
@@ -618,6 +622,7 @@ const marshalCreateBackendRequest = (request, defaults) => ({
|
|
|
618
622
|
sticky_sessions: request.stickySessions,
|
|
619
623
|
sticky_sessions_cookie_name: request.stickySessionsCookieName,
|
|
620
624
|
timeout_connect: request.timeoutConnect,
|
|
625
|
+
timeout_queue: request.timeoutQueue,
|
|
621
626
|
timeout_server: request.timeoutServer,
|
|
622
627
|
timeout_tunnel: request.timeoutTunnel
|
|
623
628
|
});
|
|
@@ -718,6 +723,7 @@ const marshalUpdateBackendRequest = (request, defaults) => ({
|
|
|
718
723
|
forward_port_algorithm: request.forwardPortAlgorithm,
|
|
719
724
|
forward_protocol: request.forwardProtocol,
|
|
720
725
|
ignore_ssl_server_verify: request.ignoreSslServerVerify,
|
|
726
|
+
max_connections: request.maxConnections,
|
|
721
727
|
max_retries: request.maxRetries,
|
|
722
728
|
name: request.name,
|
|
723
729
|
on_marked_down_action: request.onMarkedDownAction ?? 'on_marked_down_action_none',
|
|
@@ -728,6 +734,7 @@ const marshalUpdateBackendRequest = (request, defaults) => ({
|
|
|
728
734
|
sticky_sessions: request.stickySessions,
|
|
729
735
|
sticky_sessions_cookie_name: request.stickySessionsCookieName,
|
|
730
736
|
timeout_connect: request.timeoutConnect,
|
|
737
|
+
timeout_queue: request.timeoutQueue,
|
|
731
738
|
timeout_server: request.timeoutServer,
|
|
732
739
|
timeout_tunnel: request.timeoutTunnel
|
|
733
740
|
});
|
|
@@ -825,6 +832,7 @@ const marshalZonedApiCreateBackendRequest = (request, defaults) => ({
|
|
|
825
832
|
forward_protocol: request.forwardProtocol,
|
|
826
833
|
health_check: marshalHealthCheck(request.healthCheck),
|
|
827
834
|
ignore_ssl_server_verify: request.ignoreSslServerVerify,
|
|
835
|
+
max_connections: request.maxConnections,
|
|
828
836
|
max_retries: request.maxRetries,
|
|
829
837
|
name: request.name || randomName('lbb'),
|
|
830
838
|
on_marked_down_action: request.onMarkedDownAction ?? 'on_marked_down_action_none',
|
|
@@ -836,6 +844,7 @@ const marshalZonedApiCreateBackendRequest = (request, defaults) => ({
|
|
|
836
844
|
sticky_sessions: request.stickySessions,
|
|
837
845
|
sticky_sessions_cookie_name: request.stickySessionsCookieName,
|
|
838
846
|
timeout_connect: request.timeoutConnect,
|
|
847
|
+
timeout_queue: request.timeoutQueue,
|
|
839
848
|
timeout_server: request.timeoutServer,
|
|
840
849
|
timeout_tunnel: request.timeoutTunnel
|
|
841
850
|
});
|
|
@@ -939,6 +948,7 @@ const marshalZonedApiUpdateBackendRequest = (request, defaults) => ({
|
|
|
939
948
|
forward_port_algorithm: request.forwardPortAlgorithm,
|
|
940
949
|
forward_protocol: request.forwardProtocol,
|
|
941
950
|
ignore_ssl_server_verify: request.ignoreSslServerVerify,
|
|
951
|
+
max_connections: request.maxConnections,
|
|
942
952
|
max_retries: request.maxRetries,
|
|
943
953
|
name: request.name,
|
|
944
954
|
on_marked_down_action: request.onMarkedDownAction ?? 'on_marked_down_action_none',
|
|
@@ -949,6 +959,7 @@ const marshalZonedApiUpdateBackendRequest = (request, defaults) => ({
|
|
|
949
959
|
sticky_sessions: request.stickySessions,
|
|
950
960
|
sticky_sessions_cookie_name: request.stickySessionsCookieName,
|
|
951
961
|
timeout_connect: request.timeoutConnect,
|
|
962
|
+
timeout_queue: request.timeoutQueue,
|
|
952
963
|
timeout_server: request.timeoutServer,
|
|
953
964
|
timeout_tunnel: request.timeoutTunnel
|
|
954
965
|
});
|
|
@@ -4,6 +4,7 @@ import { enrichForPagination } from '../../../scw/fetch/resource-paginator.js';
|
|
|
4
4
|
import { unmarshalListImagesResponse, unmarshalGetImageResponse, unmarshalListVersionsResponse, unmarshalGetVersionResponse } from './marshalling.gen.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
/** Marketplace API. */
|
|
8
9
|
class API extends API$1 {
|
|
9
10
|
constructor() {
|
|
@@ -2,6 +2,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
2
2
|
import { unmarshalArrayOfObject, unmarshalDate } from '../../../helpers/marshalling.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
5
6
|
const unmarshalLocalImage = data => {
|
|
6
7
|
if (!isJSONObject(data)) {
|
|
7
8
|
throw new TypeError(`Unmarshalling the type 'LocalImage' failed as data isn't a dictionary.`);
|
|
@@ -4,6 +4,7 @@ import { enrichForPagination } from '../../../scw/fetch/resource-paginator.js';
|
|
|
4
4
|
import { unmarshalListImagesResponse, unmarshalImage, unmarshalListVersionsResponse, unmarshalVersion, unmarshalListLocalImagesResponse, unmarshalLocalImage, unmarshalListCategoriesResponse, unmarshalCategory } from './marshalling.gen.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
/** Marketplace API. */
|
|
8
9
|
class API extends API$1 {
|
|
9
10
|
constructor() {
|
|
@@ -2,6 +2,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
2
2
|
import { unmarshalDate, unmarshalArrayOfObject } from '../../../helpers/marshalling.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
5
6
|
const unmarshalCategory = data => {
|
|
6
7
|
if (!isJSONObject(data)) {
|
|
7
8
|
throw new TypeError(`Unmarshalling the type 'Category' failed as data isn't a dictionary.`);
|
|
@@ -4,6 +4,7 @@ import { enrichForPagination } from '../../../scw/fetch/resource-paginator.js';
|
|
|
4
4
|
import { unmarshalListNamespacesResponse, marshalCreateNamespaceRequest, unmarshalNamespace, marshalUpdateNamespaceRequest, marshalCreateCredentialRequest, unmarshalCredential, unmarshalListCredentialsResponse, marshalUpdateCredentialRequest } from './marshalling.gen.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
const jsonContentHeaders = {
|
|
8
9
|
'Content-Type': 'application/json; charset=utf-8'
|
|
9
10
|
};
|
|
@@ -3,6 +3,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
3
3
|
import { unmarshalDate, unmarshalArrayOfObject } from '../../../helpers/marshalling.js';
|
|
4
4
|
|
|
5
5
|
// This file was automatically generated. DO NOT EDIT.
|
|
6
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
6
7
|
const unmarshalPermissions = data => {
|
|
7
8
|
if (!isJSONObject(data)) {
|
|
8
9
|
throw new TypeError(`Unmarshalling the type 'Permissions' failed as data isn't a dictionary.`);
|
|
@@ -6,6 +6,7 @@ import { DATABASE_BACKUP_TRANSIENT_STATUSES, INSTANCE_TRANSIENT_STATUSES, READ_R
|
|
|
6
6
|
import { unmarshalListDatabaseEnginesResponse, unmarshalListNodeTypesResponse, unmarshalListDatabaseBackupsResponse, marshalCreateDatabaseBackupRequest, unmarshalDatabaseBackup, marshalUpdateDatabaseBackupRequest, marshalRestoreDatabaseBackupRequest, marshalUpgradeInstanceRequest, unmarshalInstance, unmarshalListInstancesResponse, marshalCreateInstanceRequest, marshalUpdateInstanceRequest, marshalCloneInstanceRequest, unmarshalInstanceMetrics, marshalCreateReadReplicaRequest, unmarshalReadReplica, marshalCreateReadReplicaEndpointRequest, marshalPrepareInstanceLogsRequest, unmarshalPrepareInstanceLogsResponse, unmarshalListInstanceLogsResponse, unmarshalInstanceLog, marshalPurgeInstanceLogsRequest, unmarshalListInstanceLogsDetailsResponse, marshalAddInstanceSettingsRequest, unmarshalAddInstanceSettingsResponse, marshalDeleteInstanceSettingsRequest, unmarshalDeleteInstanceSettingsResponse, marshalSetInstanceSettingsRequest, unmarshalSetInstanceSettingsResponse, unmarshalListInstanceACLRulesResponse, marshalAddInstanceACLRulesRequest, unmarshalAddInstanceACLRulesResponse, marshalSetInstanceACLRulesRequest, unmarshalSetInstanceACLRulesResponse, marshalDeleteInstanceACLRulesRequest, unmarshalDeleteInstanceACLRulesResponse, unmarshalListUsersResponse, marshalCreateUserRequest, unmarshalUser, marshalUpdateUserRequest, unmarshalListDatabasesResponse, marshalCreateDatabaseRequest, unmarshalDatabase, unmarshalListPrivilegesResponse, marshalSetPrivilegeRequest, unmarshalPrivilege, unmarshalListSnapshotsResponse, unmarshalSnapshot, marshalCreateSnapshotRequest, marshalUpdateSnapshotRequest, marshalCreateInstanceFromSnapshotRequest, marshalCreateEndpointRequest, unmarshalEndpoint, marshalMigrateEndpointRequest } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -2,3 +2,4 @@ export { API } from './api.gen.js';
|
|
|
2
2
|
export { DATABASE_BACKUP_TRANSIENT_STATUSES, INSTANCE_LOG_TRANSIENT_STATUSES, INSTANCE_TRANSIENT_STATUSES, MAINTENANCE_TRANSIENT_STATUSES, READ_REPLICA_TRANSIENT_STATUSES, SNAPSHOT_TRANSIENT_STATUSES } from './content.gen.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
@@ -4,6 +4,7 @@ import { unmarshalTimeSeries } from '../../../scw/custom-marshalling.js';
|
|
|
4
4
|
import { unmarshalArrayOfObject, unmarshalDate, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
const unmarshalEndpointDirectAccessDetails = data => {
|
|
8
9
|
if (!isJSONObject(data)) {
|
|
9
10
|
throw new TypeError(`Unmarshalling the type 'EndpointDirectAccessDetails' failed as data isn't a dictionary.`);
|
|
@@ -6,6 +6,7 @@ import { CLUSTER_TRANSIENT_STATUSES } from './content.gen.js';
|
|
|
6
6
|
import { marshalCreateClusterRequest, unmarshalCluster, marshalUpdateClusterRequest, unmarshalListClustersResponse, marshalMigrateClusterRequest, unmarshalClusterMetricsResponse, unmarshalListNodeTypesResponse, unmarshalListClusterVersionsResponse, marshalAddClusterSettingsRequest, unmarshalClusterSettingsResponse, marshalSetClusterSettingsRequest, marshalSetAclRulesRequest, unmarshalSetAclRulesResponse, marshalAddAclRulesRequest, unmarshalAddAclRulesResponse, unmarshalACLRule, marshalSetEndpointsRequest, unmarshalSetEndpointsResponse, marshalAddEndpointsRequest, unmarshalAddEndpointsResponse, unmarshalEndpoint, marshalUpdateEndpointRequest } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -4,6 +4,7 @@ import { unmarshalTimeSeries } from '../../../scw/custom-marshalling.js';
|
|
|
4
4
|
import { unmarshalArrayOfObject, unmarshalDate, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
const unmarshalPrivateNetwork = data => {
|
|
8
9
|
if (!isJSONObject(data)) {
|
|
9
10
|
throw new TypeError(`Unmarshalling the type 'PrivateNetwork' failed as data isn't a dictionary.`);
|
|
@@ -6,6 +6,7 @@ import { NAMESPACE_TRANSIENT_STATUSES, IMAGE_TRANSIENT_STATUSES, TAG_TRANSIENT_S
|
|
|
6
6
|
import { unmarshalListNamespacesResponse, unmarshalNamespace, marshalCreateNamespaceRequest, marshalUpdateNamespaceRequest, unmarshalListImagesResponse, unmarshalImage, marshalUpdateImageRequest, unmarshalListTagsResponse, unmarshalTag } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -2,3 +2,4 @@ export { API } from './api.gen.js';
|
|
|
2
2
|
export { IMAGE_TRANSIENT_STATUSES, NAMESPACE_TRANSIENT_STATUSES, TAG_TRANSIENT_STATUSES } from './content.gen.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
@@ -3,6 +3,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
3
3
|
import { unmarshalDate, unmarshalArrayOfObject, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
4
4
|
|
|
5
5
|
// This file was automatically generated. DO NOT EDIT.
|
|
6
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
6
7
|
const unmarshalImage = data => {
|
|
7
8
|
if (!isJSONObject(data)) {
|
|
8
9
|
throw new TypeError(`Unmarshalling the type 'Image' failed as data isn't a dictionary.`);
|
|
@@ -4,6 +4,7 @@ import { enrichForPagination } from '../../../scw/fetch/resource-paginator.js';
|
|
|
4
4
|
import { marshalCreateSecretRequest, unmarshalSecret, marshalUpdateSecretRequest, unmarshalListSecretsResponse, marshalAddSecretOwnerRequest, marshalCreateSecretVersionRequest, unmarshalSecretVersion, marshalUpdateSecretVersionRequest, unmarshalListSecretVersionsResponse, unmarshalAccessSecretVersionResponse } from './marshalling.gen.js';
|
|
5
5
|
|
|
6
6
|
// This file was automatically generated. DO NOT EDIT.
|
|
7
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
7
8
|
const jsonContentHeaders = {
|
|
8
9
|
'Content-Type': 'application/json; charset=utf-8'
|
|
9
10
|
};
|
|
@@ -2,6 +2,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
2
2
|
import { unmarshalDate, unmarshalArrayOfObject, resolveOneOf } from '../../../helpers/marshalling.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
5
6
|
const unmarshalSecret = data => {
|
|
6
7
|
if (!isJSONObject(data)) {
|
|
7
8
|
throw new TypeError(`Unmarshalling the type 'Secret' failed as data isn't a dictionary.`);
|
|
@@ -6,6 +6,7 @@ import { EMAIL_TRANSIENT_STATUSES, DOMAIN_TRANSIENT_STATUSES } from './content.g
|
|
|
6
6
|
import { marshalCreateEmailRequest, unmarshalCreateEmailResponse, unmarshalEmail, unmarshalListEmailsResponse, unmarshalStatistics, marshalCreateDomainRequest, unmarshalDomain, unmarshalListDomainsResponse } from './marshalling.gen.js';
|
|
7
7
|
|
|
8
8
|
// This file was automatically generated. DO NOT EDIT.
|
|
9
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
9
10
|
const jsonContentHeaders = {
|
|
10
11
|
'Content-Type': 'application/json; charset=utf-8'
|
|
11
12
|
};
|
|
@@ -57,12 +58,20 @@ class API extends API$1 {
|
|
|
57
58
|
return _this.client.fetch({
|
|
58
59
|
method: 'GET',
|
|
59
60
|
path: `/transactional-email/v1alpha1/regions/${validatePathParam('region', request.region ?? _this.client.settings.defaultRegion)}/emails`,
|
|
60
|
-
urlParams: urlParams(['domain_id', request.domainId], ['mail_from', request.mailFrom], ['mail_to', request.mailTo], ['message_id', request.messageId], ['page', request.page], ['page_size', request.pageSize ?? _this.client.settings.defaultPageSize], ['project_id', request.projectId], ['since', request.since], ['statuses', request.statuses], ['subject', request.subject], ['until', request.until])
|
|
61
|
+
urlParams: urlParams(['domain_id', request.domainId], ['mail_from', request.mailFrom], ['mail_rcpt', request.mailRcpt], ['mail_to', request.mailTo], ['message_id', request.messageId], ['order_by', request.orderBy ?? 'created_at_desc'], ['page', request.page], ['page_size', request.pageSize ?? _this.client.settings.defaultPageSize], ['project_id', request.projectId], ['since', request.since], ['statuses', request.statuses], ['subject', request.subject], ['until', request.until])
|
|
61
62
|
}, unmarshalListEmailsResponse);
|
|
62
63
|
};
|
|
63
64
|
/**
|
|
64
65
|
* List emails. Retrieve the list of emails sent from a specific domain or for
|
|
65
|
-
* a specific Project or Organization. You must specify the `region`.
|
|
66
|
+
* a specific Project or Organization. You must specify the `region`. You can
|
|
67
|
+
* filter your emails in ascending or descending order using:
|
|
68
|
+
*
|
|
69
|
+
* - Created_at
|
|
70
|
+
* - Updated_at
|
|
71
|
+
* - Status
|
|
72
|
+
* - Mail_from
|
|
73
|
+
* - Mail_rcpt
|
|
74
|
+
* - Subject
|
|
66
75
|
*
|
|
67
76
|
* @param request - The request {@link ListEmailsRequest}
|
|
68
77
|
* @returns A Promise of ListEmailsResponse
|
|
@@ -2,6 +2,7 @@ import { isJSONObject } from '../../../helpers/json.js';
|
|
|
2
2
|
import { unmarshalDate, unmarshalArrayOfObject } from '../../../helpers/marshalling.js';
|
|
3
3
|
|
|
4
4
|
// This file was automatically generated. DO NOT EDIT.
|
|
5
|
+
// If you have any remark or suggestion do not hesitate to open an issue.
|
|
5
6
|
const unmarshalDomainStatistics = data => {
|
|
6
7
|
if (!isJSONObject(data)) {
|
|
7
8
|
throw new TypeError(`Unmarshalling the type 'DomainStatistics' failed as data isn't a dictionary.`);
|
|
@@ -54,6 +55,7 @@ const unmarshalEmail = data => {
|
|
|
54
55
|
id: data.id,
|
|
55
56
|
lastTries: unmarshalArrayOfObject(data.last_tries, unmarshalEmailTry),
|
|
56
57
|
mailFrom: data.mail_from,
|
|
58
|
+
mailRcpt: data.mail_rcpt,
|
|
57
59
|
messageId: data.message_id,
|
|
58
60
|
projectId: data.project_id,
|
|
59
61
|
rcptTo: data.rcpt_to,
|