@scaleway/sdk-searchdb 1.1.1 → 1.2.1
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 -0
- package/dist/_virtual/_rolldown/runtime.js +11 -0
- package/dist/index.gen.js +2 -4
- package/dist/v1alpha1/api.gen.js +187 -274
- package/dist/v1alpha1/content.gen.js +8 -9
- package/dist/v1alpha1/index.gen.js +22 -20
- package/dist/v1alpha1/marshalling.gen.js +134 -222
- package/dist/v1alpha1/validation-rules.gen.js +101 -115
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -83,6 +83,7 @@ const api = new Searchdb.v1.API(client)
|
|
|
83
83
|
## Support
|
|
84
84
|
|
|
85
85
|
We love feedback! Feel free to reach us on:
|
|
86
|
+
|
|
86
87
|
- [Scaleway Slack community](https://slack.scaleway.com/) - Join us on [#opensource](https://scaleway-community.slack.com/app_redirect?channel=opensource)
|
|
87
88
|
- [GitHub Issues](https://github.com/scaleway/scaleway-sdk-js/issues)
|
|
88
89
|
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __exportAll = (all, no_symbols) => {
|
|
3
|
+
let target = {};
|
|
4
|
+
for (var name in all) __defProp(target, name, {
|
|
5
|
+
get: all[name],
|
|
6
|
+
enumerable: true
|
|
7
|
+
});
|
|
8
|
+
if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
|
|
9
|
+
return target;
|
|
10
|
+
};
|
|
11
|
+
export { __exportAll };
|
package/dist/index.gen.js
CHANGED
package/dist/v1alpha1/api.gen.js
CHANGED
|
@@ -1,276 +1,189 @@
|
|
|
1
|
-
import { API as API$1, toApiLocality, validatePathParam, waitForResource, urlParams, enrichForPagination } from "@scaleway/sdk-client";
|
|
2
1
|
import { DEPLOYMENT_TRANSIENT_STATUSES } from "./content.gen.js";
|
|
3
|
-
import { marshalCreateDeploymentRequest,
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
*
|
|
190
|
-
* @param request - The request {@link DeleteEndpointRequest}
|
|
191
|
-
*/
|
|
192
|
-
deleteEndpoint = (request) => this.client.fetch(
|
|
193
|
-
{
|
|
194
|
-
method: "DELETE",
|
|
195
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/endpoints/${validatePathParam("endpointId", request.endpointId)}`
|
|
196
|
-
}
|
|
197
|
-
);
|
|
198
|
-
pageOfListUsers = (request) => this.client.fetch(
|
|
199
|
-
{
|
|
200
|
-
method: "GET",
|
|
201
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users`,
|
|
202
|
-
urlParams: urlParams(
|
|
203
|
-
["name", request.name],
|
|
204
|
-
["order_by", request.orderBy],
|
|
205
|
-
["page", request.page],
|
|
206
|
-
["page_size", request.pageSize ?? this.client.settings.defaultPageSize]
|
|
207
|
-
)
|
|
208
|
-
},
|
|
209
|
-
unmarshalListUsersResponse
|
|
210
|
-
);
|
|
211
|
-
/**
|
|
212
|
-
* Retrieve a list of deployment users.
|
|
213
|
-
*
|
|
214
|
-
* @param request - The request {@link ListUsersRequest}
|
|
215
|
-
* @returns A Promise of ListUsersResponse
|
|
216
|
-
*/
|
|
217
|
-
listUsers = (request) => enrichForPagination("users", this.pageOfListUsers, request);
|
|
218
|
-
/**
|
|
219
|
-
* Create a new user.
|
|
220
|
-
*
|
|
221
|
-
* @param request - The request {@link CreateUserRequest}
|
|
222
|
-
* @returns A Promise of User
|
|
223
|
-
*/
|
|
224
|
-
createUser = (request) => this.client.fetch(
|
|
225
|
-
{
|
|
226
|
-
body: JSON.stringify(
|
|
227
|
-
marshalCreateUserRequest(request, this.client.settings)
|
|
228
|
-
),
|
|
229
|
-
headers: jsonContentHeaders,
|
|
230
|
-
method: "POST",
|
|
231
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users`
|
|
232
|
-
},
|
|
233
|
-
unmarshalUser
|
|
234
|
-
);
|
|
235
|
-
/**
|
|
236
|
-
* Update an existing user.
|
|
237
|
-
*
|
|
238
|
-
* @param request - The request {@link UpdateUserRequest}
|
|
239
|
-
* @returns A Promise of User
|
|
240
|
-
*/
|
|
241
|
-
updateUser = (request) => this.client.fetch(
|
|
242
|
-
{
|
|
243
|
-
body: JSON.stringify(
|
|
244
|
-
marshalUpdateUserRequest(request, this.client.settings)
|
|
245
|
-
),
|
|
246
|
-
headers: jsonContentHeaders,
|
|
247
|
-
method: "PATCH",
|
|
248
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users/${validatePathParam("username", request.username)}`
|
|
249
|
-
},
|
|
250
|
-
unmarshalUser
|
|
251
|
-
);
|
|
252
|
-
/**
|
|
253
|
-
* Delete an existing user.
|
|
254
|
-
*
|
|
255
|
-
* @param request - The request {@link DeleteUserRequest}
|
|
256
|
-
*/
|
|
257
|
-
deleteUser = (request) => this.client.fetch(
|
|
258
|
-
{
|
|
259
|
-
method: "DELETE",
|
|
260
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users/${validatePathParam("username", request.username)}`
|
|
261
|
-
}
|
|
262
|
-
);
|
|
263
|
-
getDeploymentCertificateAuthority = (request) => this.client.fetch(
|
|
264
|
-
{
|
|
265
|
-
method: "GET",
|
|
266
|
-
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/certificate-authority`,
|
|
267
|
-
urlParams: urlParams(
|
|
268
|
-
["dl", 1]
|
|
269
|
-
),
|
|
270
|
-
responseType: "blob"
|
|
271
|
-
}
|
|
272
|
-
);
|
|
273
|
-
}
|
|
274
|
-
export {
|
|
275
|
-
API
|
|
2
|
+
import { marshalCreateDeploymentRequest, marshalCreateEndpointRequest, marshalCreateUserRequest, marshalUpdateDeploymentRequest, marshalUpdateUserRequest, marshalUpgradeDeploymentRequest, unmarshalDeployment, unmarshalEndpoint, unmarshalListDeploymentsResponse, unmarshalListNodeTypesResponse, unmarshalListUsersResponse, unmarshalListVersionsResponse, unmarshalUser } from "./marshalling.gen.js";
|
|
3
|
+
import { API, enrichForPagination, toApiLocality, urlParams, validatePathParam, waitForResource } from "@scaleway/sdk-client";
|
|
4
|
+
var jsonContentHeaders = { "Content-Type": "application/json; charset=utf-8" };
|
|
5
|
+
/**
|
|
6
|
+
* Cloud Essentials for Opensearch API.
|
|
7
|
+
|
|
8
|
+
The Cloud Essentials for Opensearch API allows you to manage your Opensearch resources.
|
|
9
|
+
*/
|
|
10
|
+
var API$1 = class extends API {
|
|
11
|
+
/**
|
|
12
|
+
* Locality of this API.
|
|
13
|
+
* type ∈ {'zone','region','global','unspecified'}
|
|
14
|
+
*/
|
|
15
|
+
static LOCALITY = toApiLocality({ regions: ["fr-par"] });
|
|
16
|
+
/**
|
|
17
|
+
* Create a new Cloud Essentials for OpenSearch deployment.
|
|
18
|
+
*
|
|
19
|
+
* @param request - The request {@link CreateDeploymentRequest}
|
|
20
|
+
* @returns A Promise of Deployment
|
|
21
|
+
*/
|
|
22
|
+
createDeployment = (request) => this.client.fetch({
|
|
23
|
+
body: JSON.stringify(marshalCreateDeploymentRequest(request, this.client.settings)),
|
|
24
|
+
headers: jsonContentHeaders,
|
|
25
|
+
method: "POST",
|
|
26
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments`
|
|
27
|
+
}, unmarshalDeployment);
|
|
28
|
+
/**
|
|
29
|
+
* Update a Cloud Essentials for OpenSearch deployment.
|
|
30
|
+
*
|
|
31
|
+
* @param request - The request {@link UpdateDeploymentRequest}
|
|
32
|
+
* @returns A Promise of Deployment
|
|
33
|
+
*/
|
|
34
|
+
updateDeployment = (request) => this.client.fetch({
|
|
35
|
+
body: JSON.stringify(marshalUpdateDeploymentRequest(request, this.client.settings)),
|
|
36
|
+
headers: jsonContentHeaders,
|
|
37
|
+
method: "PATCH",
|
|
38
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}`
|
|
39
|
+
}, unmarshalDeployment);
|
|
40
|
+
/**
|
|
41
|
+
* Upgrade a Cloud Essentials for OpenSearch deployment.
|
|
42
|
+
*
|
|
43
|
+
* @param request - The request {@link UpgradeDeploymentRequest}
|
|
44
|
+
* @returns A Promise of Deployment
|
|
45
|
+
*/
|
|
46
|
+
upgradeDeployment = (request) => this.client.fetch({
|
|
47
|
+
body: JSON.stringify(marshalUpgradeDeploymentRequest(request, this.client.settings)),
|
|
48
|
+
headers: jsonContentHeaders,
|
|
49
|
+
method: "POST",
|
|
50
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/upgrade`
|
|
51
|
+
}, unmarshalDeployment);
|
|
52
|
+
/**
|
|
53
|
+
* Retrieve a specific Cloud Essentials for OpenSearch deployment.
|
|
54
|
+
*
|
|
55
|
+
* @param request - The request {@link GetDeploymentRequest}
|
|
56
|
+
* @returns A Promise of Deployment
|
|
57
|
+
*/
|
|
58
|
+
getDeployment = (request) => this.client.fetch({
|
|
59
|
+
method: "GET",
|
|
60
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}`
|
|
61
|
+
}, unmarshalDeployment);
|
|
62
|
+
/**
|
|
63
|
+
* Waits for {@link Deployment} to be in a final state.
|
|
64
|
+
*
|
|
65
|
+
* @param request - The request {@link GetDeploymentRequest}
|
|
66
|
+
* @param options - The waiting options
|
|
67
|
+
* @returns A Promise of Deployment
|
|
68
|
+
*/
|
|
69
|
+
waitForDeployment = (request, options) => waitForResource(options?.stop ?? ((res) => Promise.resolve(!DEPLOYMENT_TRANSIENT_STATUSES.includes(res.status))), this.getDeployment, request, options);
|
|
70
|
+
/**
|
|
71
|
+
* Delete a Cloud Essentials for OpenSearch deployment.
|
|
72
|
+
*
|
|
73
|
+
* @param request - The request {@link DeleteDeploymentRequest}
|
|
74
|
+
* @returns A Promise of Deployment
|
|
75
|
+
*/
|
|
76
|
+
deleteDeployment = (request) => this.client.fetch({
|
|
77
|
+
method: "DELETE",
|
|
78
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}`
|
|
79
|
+
}, unmarshalDeployment);
|
|
80
|
+
pageOfListDeployments = (request = {}) => this.client.fetch({
|
|
81
|
+
method: "GET",
|
|
82
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments`,
|
|
83
|
+
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], ["tags", request.tags], ["version", request.version])
|
|
84
|
+
}, unmarshalListDeploymentsResponse);
|
|
85
|
+
/**
|
|
86
|
+
* Retrieve a list of Cloud Essentials for OpenSearch deployments.
|
|
87
|
+
*
|
|
88
|
+
* @param request - The request {@link ListDeploymentsRequest}
|
|
89
|
+
* @returns A Promise of ListDeploymentsResponse
|
|
90
|
+
*/
|
|
91
|
+
listDeployments = (request = {}) => enrichForPagination("deployments", this.pageOfListDeployments, request);
|
|
92
|
+
pageOfListVersions = (request = {}) => this.client.fetch({
|
|
93
|
+
method: "GET",
|
|
94
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/versions`,
|
|
95
|
+
urlParams: urlParams(["order_by", request.orderBy], ["page", request.page], ["page_size", request.pageSize ?? this.client.settings.defaultPageSize], ["version", request.version])
|
|
96
|
+
}, unmarshalListVersionsResponse);
|
|
97
|
+
/**
|
|
98
|
+
* List available Cloud Essentials for OpenSearch versions.
|
|
99
|
+
*
|
|
100
|
+
* @param request - The request {@link ListVersionsRequest}
|
|
101
|
+
* @returns A Promise of ListVersionsResponse
|
|
102
|
+
*/
|
|
103
|
+
listVersions = (request = {}) => enrichForPagination("versions", this.pageOfListVersions, request);
|
|
104
|
+
pageOfListNodeTypes = (request = {}) => this.client.fetch({
|
|
105
|
+
method: "GET",
|
|
106
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/node-types`,
|
|
107
|
+
urlParams: urlParams(["order_by", request.orderBy], ["page", request.page], ["page_size", request.pageSize ?? this.client.settings.defaultPageSize])
|
|
108
|
+
}, unmarshalListNodeTypesResponse);
|
|
109
|
+
/**
|
|
110
|
+
* Retrieve a list of available node types.
|
|
111
|
+
*
|
|
112
|
+
* @param request - The request {@link ListNodeTypesRequest}
|
|
113
|
+
* @returns A Promise of ListNodeTypesResponse
|
|
114
|
+
*/
|
|
115
|
+
listNodeTypes = (request = {}) => enrichForPagination("nodeTypes", this.pageOfListNodeTypes, request);
|
|
116
|
+
/**
|
|
117
|
+
* Create a new endpoint on a deployment.
|
|
118
|
+
*
|
|
119
|
+
* @param request - The request {@link CreateEndpointRequest}
|
|
120
|
+
* @returns A Promise of Endpoint
|
|
121
|
+
*/
|
|
122
|
+
createEndpoint = (request) => this.client.fetch({
|
|
123
|
+
body: JSON.stringify(marshalCreateEndpointRequest(request, this.client.settings)),
|
|
124
|
+
headers: jsonContentHeaders,
|
|
125
|
+
method: "POST",
|
|
126
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/endpoints`
|
|
127
|
+
}, unmarshalEndpoint);
|
|
128
|
+
/**
|
|
129
|
+
* Delete an existing endpoint.
|
|
130
|
+
*
|
|
131
|
+
* @param request - The request {@link DeleteEndpointRequest}
|
|
132
|
+
*/
|
|
133
|
+
deleteEndpoint = (request) => this.client.fetch({
|
|
134
|
+
method: "DELETE",
|
|
135
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/endpoints/${validatePathParam("endpointId", request.endpointId)}`
|
|
136
|
+
});
|
|
137
|
+
pageOfListUsers = (request) => this.client.fetch({
|
|
138
|
+
method: "GET",
|
|
139
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users`,
|
|
140
|
+
urlParams: urlParams(["name", request.name], ["order_by", request.orderBy], ["page", request.page], ["page_size", request.pageSize ?? this.client.settings.defaultPageSize])
|
|
141
|
+
}, unmarshalListUsersResponse);
|
|
142
|
+
/**
|
|
143
|
+
* Retrieve a list of deployment users.
|
|
144
|
+
*
|
|
145
|
+
* @param request - The request {@link ListUsersRequest}
|
|
146
|
+
* @returns A Promise of ListUsersResponse
|
|
147
|
+
*/
|
|
148
|
+
listUsers = (request) => enrichForPagination("users", this.pageOfListUsers, request);
|
|
149
|
+
/**
|
|
150
|
+
* Create a new user.
|
|
151
|
+
*
|
|
152
|
+
* @param request - The request {@link CreateUserRequest}
|
|
153
|
+
* @returns A Promise of User
|
|
154
|
+
*/
|
|
155
|
+
createUser = (request) => this.client.fetch({
|
|
156
|
+
body: JSON.stringify(marshalCreateUserRequest(request, this.client.settings)),
|
|
157
|
+
headers: jsonContentHeaders,
|
|
158
|
+
method: "POST",
|
|
159
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users`
|
|
160
|
+
}, unmarshalUser);
|
|
161
|
+
/**
|
|
162
|
+
* Update an existing user.
|
|
163
|
+
*
|
|
164
|
+
* @param request - The request {@link UpdateUserRequest}
|
|
165
|
+
* @returns A Promise of User
|
|
166
|
+
*/
|
|
167
|
+
updateUser = (request) => this.client.fetch({
|
|
168
|
+
body: JSON.stringify(marshalUpdateUserRequest(request, this.client.settings)),
|
|
169
|
+
headers: jsonContentHeaders,
|
|
170
|
+
method: "PATCH",
|
|
171
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users/${validatePathParam("username", request.username)}`
|
|
172
|
+
}, unmarshalUser);
|
|
173
|
+
/**
|
|
174
|
+
* Delete an existing user.
|
|
175
|
+
*
|
|
176
|
+
* @param request - The request {@link DeleteUserRequest}
|
|
177
|
+
*/
|
|
178
|
+
deleteUser = (request) => this.client.fetch({
|
|
179
|
+
method: "DELETE",
|
|
180
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/users/${validatePathParam("username", request.username)}`
|
|
181
|
+
});
|
|
182
|
+
getDeploymentCertificateAuthority = (request) => this.client.fetch({
|
|
183
|
+
method: "GET",
|
|
184
|
+
path: `/searchdb/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/deployments/${validatePathParam("deploymentId", request.deploymentId)}/certificate-authority`,
|
|
185
|
+
urlParams: urlParams(["dl", 1]),
|
|
186
|
+
responseType: "blob"
|
|
187
|
+
});
|
|
276
188
|
};
|
|
189
|
+
export { API$1 as API };
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
+
/** Lists transient statutes of the enum {@link DeploymentStatus}. */
|
|
1
2
|
const DEPLOYMENT_TRANSIENT_STATUSES = [
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
"creating",
|
|
4
|
+
"initializing",
|
|
5
|
+
"upgrading",
|
|
6
|
+
"deleting",
|
|
7
|
+
"locking",
|
|
8
|
+
"unlocking"
|
|
8
9
|
];
|
|
9
|
-
export {
|
|
10
|
-
DEPLOYMENT_TRANSIENT_STATUSES
|
|
11
|
-
};
|
|
10
|
+
export { DEPLOYMENT_TRANSIENT_STATUSES };
|
|
@@ -1,22 +1,24 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __exportAll } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
import { DEPLOYMENT_TRANSIENT_STATUSES } from "./content.gen.js";
|
|
3
3
|
import { marshalCreateDeploymentRequest, marshalCreateEndpointRequest, marshalCreateUserRequest, marshalUpdateDeploymentRequest, marshalUpdateUserRequest, marshalUpgradeDeploymentRequest, unmarshalDeployment, unmarshalEndpoint, unmarshalListDeploymentsResponse, unmarshalListNodeTypesResponse, unmarshalListUsersResponse, unmarshalListVersionsResponse, unmarshalUser } from "./marshalling.gen.js";
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
4
|
+
import { API } from "./api.gen.js";
|
|
5
|
+
import { validation_rules_gen_exports } from "./validation-rules.gen.js";
|
|
6
|
+
var index_gen_exports = /* @__PURE__ */ __exportAll({
|
|
7
|
+
API: () => API,
|
|
8
|
+
DEPLOYMENT_TRANSIENT_STATUSES: () => DEPLOYMENT_TRANSIENT_STATUSES,
|
|
9
|
+
ValidationRules: () => validation_rules_gen_exports,
|
|
10
|
+
marshalCreateDeploymentRequest: () => marshalCreateDeploymentRequest,
|
|
11
|
+
marshalCreateEndpointRequest: () => marshalCreateEndpointRequest,
|
|
12
|
+
marshalCreateUserRequest: () => marshalCreateUserRequest,
|
|
13
|
+
marshalUpdateDeploymentRequest: () => marshalUpdateDeploymentRequest,
|
|
14
|
+
marshalUpdateUserRequest: () => marshalUpdateUserRequest,
|
|
15
|
+
marshalUpgradeDeploymentRequest: () => marshalUpgradeDeploymentRequest,
|
|
16
|
+
unmarshalDeployment: () => unmarshalDeployment,
|
|
17
|
+
unmarshalEndpoint: () => unmarshalEndpoint,
|
|
18
|
+
unmarshalListDeploymentsResponse: () => unmarshalListDeploymentsResponse,
|
|
19
|
+
unmarshalListNodeTypesResponse: () => unmarshalListNodeTypesResponse,
|
|
20
|
+
unmarshalListUsersResponse: () => unmarshalListUsersResponse,
|
|
21
|
+
unmarshalListVersionsResponse: () => unmarshalListVersionsResponse,
|
|
22
|
+
unmarshalUser: () => unmarshalUser
|
|
23
|
+
});
|
|
24
|
+
export { index_gen_exports };
|
|
@@ -1,252 +1,164 @@
|
|
|
1
|
-
import { resolveOneOf,
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
`Unmarshalling the type 'EndpointPrivateNetworkDetails' failed as data isn't a dictionary.`
|
|
6
|
-
);
|
|
7
|
-
}
|
|
8
|
-
return {
|
|
9
|
-
privateNetworkId: data.private_network_id
|
|
10
|
-
};
|
|
1
|
+
import { isJSONObject, resolveOneOf, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
|
|
2
|
+
var unmarshalEndpointPrivateNetworkDetails = (data) => {
|
|
3
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'EndpointPrivateNetworkDetails' failed as data isn't a dictionary.`);
|
|
4
|
+
return { privateNetworkId: data.private_network_id };
|
|
11
5
|
};
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
`Unmarshalling the type 'EndpointPublicDetails' failed as data isn't a dictionary.`
|
|
16
|
-
);
|
|
17
|
-
}
|
|
18
|
-
return {};
|
|
6
|
+
var unmarshalEndpointPublicDetails = (data) => {
|
|
7
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'EndpointPublicDetails' failed as data isn't a dictionary.`);
|
|
8
|
+
return {};
|
|
19
9
|
};
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
name: data.name,
|
|
28
|
-
port: data.port,
|
|
29
|
-
url: data.url
|
|
30
|
-
};
|
|
10
|
+
var unmarshalEndpointService = (data) => {
|
|
11
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'EndpointService' failed as data isn't a dictionary.`);
|
|
12
|
+
return {
|
|
13
|
+
name: data.name,
|
|
14
|
+
port: data.port,
|
|
15
|
+
url: data.url
|
|
16
|
+
};
|
|
31
17
|
};
|
|
32
18
|
const unmarshalEndpoint = (data) => {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
privateNetwork: data.private_network ? unmarshalEndpointPrivateNetworkDetails(data.private_network) : void 0,
|
|
42
|
-
public: data.public ? unmarshalEndpointPublicDetails(data.public) : void 0,
|
|
43
|
-
services: unmarshalArrayOfObject(data.services, unmarshalEndpointService)
|
|
44
|
-
};
|
|
19
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Endpoint' failed as data isn't a dictionary.`);
|
|
20
|
+
return {
|
|
21
|
+
dnsRecord: data.dns_record,
|
|
22
|
+
id: data.id,
|
|
23
|
+
privateNetwork: data.private_network ? unmarshalEndpointPrivateNetworkDetails(data.private_network) : void 0,
|
|
24
|
+
public: data.public ? unmarshalEndpointPublicDetails(data.public) : void 0,
|
|
25
|
+
services: unmarshalArrayOfObject(data.services, unmarshalEndpointService)
|
|
26
|
+
};
|
|
45
27
|
};
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
return {
|
|
53
|
-
sizeBytes: data.size_bytes,
|
|
54
|
-
type: data.type
|
|
55
|
-
};
|
|
28
|
+
var unmarshalVolume = (data) => {
|
|
29
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Volume' failed as data isn't a dictionary.`);
|
|
30
|
+
return {
|
|
31
|
+
sizeBytes: data.size_bytes,
|
|
32
|
+
type: data.type
|
|
33
|
+
};
|
|
56
34
|
};
|
|
57
35
|
const unmarshalDeployment = (data) => {
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
updatedAt: unmarshalDate(data.updated_at),
|
|
76
|
-
version: data.version,
|
|
77
|
-
volume: data.volume ? unmarshalVolume(data.volume) : void 0
|
|
78
|
-
};
|
|
36
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Deployment' failed as data isn't a dictionary.`);
|
|
37
|
+
return {
|
|
38
|
+
createdAt: unmarshalDate(data.created_at),
|
|
39
|
+
endpoints: unmarshalArrayOfObject(data.endpoints, unmarshalEndpoint),
|
|
40
|
+
id: data.id,
|
|
41
|
+
name: data.name,
|
|
42
|
+
nodeAmount: data.node_amount,
|
|
43
|
+
nodeType: data.node_type,
|
|
44
|
+
organizationId: data.organization_id,
|
|
45
|
+
projectId: data.project_id,
|
|
46
|
+
region: data.region,
|
|
47
|
+
status: data.status,
|
|
48
|
+
tags: data.tags,
|
|
49
|
+
updatedAt: unmarshalDate(data.updated_at),
|
|
50
|
+
version: data.version,
|
|
51
|
+
volume: data.volume ? unmarshalVolume(data.volume) : void 0
|
|
52
|
+
};
|
|
79
53
|
};
|
|
80
54
|
const unmarshalUser = (data) => {
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
`Unmarshalling the type 'User' failed as data isn't a dictionary.`
|
|
84
|
-
);
|
|
85
|
-
}
|
|
86
|
-
return {
|
|
87
|
-
username: data.username
|
|
88
|
-
};
|
|
55
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'User' failed as data isn't a dictionary.`);
|
|
56
|
+
return { username: data.username };
|
|
89
57
|
};
|
|
90
58
|
const unmarshalListDeploymentsResponse = (data) => {
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
return {
|
|
97
|
-
deployments: unmarshalArrayOfObject(data.deployments, unmarshalDeployment),
|
|
98
|
-
totalCount: data.total_count
|
|
99
|
-
};
|
|
59
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListDeploymentsResponse' failed as data isn't a dictionary.`);
|
|
60
|
+
return {
|
|
61
|
+
deployments: unmarshalArrayOfObject(data.deployments, unmarshalDeployment),
|
|
62
|
+
totalCount: data.total_count
|
|
63
|
+
};
|
|
100
64
|
};
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
maxSizeBytes: data.max_size_bytes,
|
|
111
|
-
minSizeBytes: data.min_size_bytes,
|
|
112
|
-
type: data.type
|
|
113
|
-
};
|
|
65
|
+
var unmarshalNodeTypeVolumeType = (data) => {
|
|
66
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'NodeTypeVolumeType' failed as data isn't a dictionary.`);
|
|
67
|
+
return {
|
|
68
|
+
chunkSizeBytes: data.chunk_size_bytes,
|
|
69
|
+
description: data.description,
|
|
70
|
+
maxSizeBytes: data.max_size_bytes,
|
|
71
|
+
minSizeBytes: data.min_size_bytes,
|
|
72
|
+
type: data.type
|
|
73
|
+
};
|
|
114
74
|
};
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
name: data.name,
|
|
129
|
-
stockStatus: data.stock_status,
|
|
130
|
-
vcpus: data.vcpus
|
|
131
|
-
};
|
|
75
|
+
var unmarshalNodeType = (data) => {
|
|
76
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'NodeType' failed as data isn't a dictionary.`);
|
|
77
|
+
return {
|
|
78
|
+
availableVolumeTypes: unmarshalArrayOfObject(data.available_volume_types, unmarshalNodeTypeVolumeType),
|
|
79
|
+
beta: data.beta,
|
|
80
|
+
description: data.description,
|
|
81
|
+
disabled: data.disabled,
|
|
82
|
+
instanceRange: data.instance_range,
|
|
83
|
+
memoryBytes: data.memory_bytes,
|
|
84
|
+
name: data.name,
|
|
85
|
+
stockStatus: data.stock_status,
|
|
86
|
+
vcpus: data.vcpus
|
|
87
|
+
};
|
|
132
88
|
};
|
|
133
89
|
const unmarshalListNodeTypesResponse = (data) => {
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
return {
|
|
140
|
-
nodeTypes: unmarshalArrayOfObject(data.node_types, unmarshalNodeType),
|
|
141
|
-
totalCount: data.total_count
|
|
142
|
-
};
|
|
90
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListNodeTypesResponse' failed as data isn't a dictionary.`);
|
|
91
|
+
return {
|
|
92
|
+
nodeTypes: unmarshalArrayOfObject(data.node_types, unmarshalNodeType),
|
|
93
|
+
totalCount: data.total_count
|
|
94
|
+
};
|
|
143
95
|
};
|
|
144
96
|
const unmarshalListUsersResponse = (data) => {
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
return {
|
|
151
|
-
totalCount: data.total_count,
|
|
152
|
-
users: unmarshalArrayOfObject(data.users, unmarshalUser)
|
|
153
|
-
};
|
|
97
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListUsersResponse' failed as data isn't a dictionary.`);
|
|
98
|
+
return {
|
|
99
|
+
totalCount: data.total_count,
|
|
100
|
+
users: unmarshalArrayOfObject(data.users, unmarshalUser)
|
|
101
|
+
};
|
|
154
102
|
};
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
disabled: data.disabled,
|
|
164
|
-
endOfLife: unmarshalDate(data.end_of_life),
|
|
165
|
-
version: data.version
|
|
166
|
-
};
|
|
103
|
+
var unmarshalVersion = (data) => {
|
|
104
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Version' failed as data isn't a dictionary.`);
|
|
105
|
+
return {
|
|
106
|
+
beta: data.beta,
|
|
107
|
+
disabled: data.disabled,
|
|
108
|
+
endOfLife: unmarshalDate(data.end_of_life),
|
|
109
|
+
version: data.version
|
|
110
|
+
};
|
|
167
111
|
};
|
|
168
112
|
const unmarshalListVersionsResponse = (data) => {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
return {
|
|
175
|
-
totalCount: data.total_count,
|
|
176
|
-
versions: unmarshalArrayOfObject(data.versions, unmarshalVersion)
|
|
177
|
-
};
|
|
113
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListVersionsResponse' failed as data isn't a dictionary.`);
|
|
114
|
+
return {
|
|
115
|
+
totalCount: data.total_count,
|
|
116
|
+
versions: unmarshalArrayOfObject(data.versions, unmarshalVersion)
|
|
117
|
+
};
|
|
178
118
|
};
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
value: request.privateNetwork !== void 0 ? marshalEndpointSpecPrivateNetworkDetails(request.privateNetwork) : void 0
|
|
192
|
-
}
|
|
193
|
-
])
|
|
194
|
-
});
|
|
195
|
-
const marshalVolume = (request, defaults) => ({
|
|
196
|
-
size_bytes: request.sizeBytes,
|
|
197
|
-
type: request.type
|
|
119
|
+
var marshalEndpointSpecPrivateNetworkDetails = (request, defaults) => ({ private_network_id: request.privateNetworkId });
|
|
120
|
+
var marshalEndpointSpecPublicDetails = (request, defaults) => ({});
|
|
121
|
+
var marshalEndpointSpec = (request, defaults) => ({ ...resolveOneOf([{
|
|
122
|
+
param: "public",
|
|
123
|
+
value: request.public !== void 0 ? marshalEndpointSpecPublicDetails(request.public, defaults) : void 0
|
|
124
|
+
}, {
|
|
125
|
+
param: "private_network",
|
|
126
|
+
value: request.privateNetwork !== void 0 ? marshalEndpointSpecPrivateNetworkDetails(request.privateNetwork, defaults) : void 0
|
|
127
|
+
}]) });
|
|
128
|
+
var marshalVolume = (request, defaults) => ({
|
|
129
|
+
size_bytes: request.sizeBytes,
|
|
130
|
+
type: request.type
|
|
198
131
|
});
|
|
199
132
|
const marshalCreateDeploymentRequest = (request, defaults) => ({
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
133
|
+
endpoints: request.endpoints !== void 0 ? request.endpoints.map((elt) => marshalEndpointSpec(elt, defaults)) : void 0,
|
|
134
|
+
name: request.name,
|
|
135
|
+
node_amount: request.nodeAmount,
|
|
136
|
+
node_type: request.nodeType,
|
|
137
|
+
password: request.password,
|
|
138
|
+
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
139
|
+
tags: request.tags,
|
|
140
|
+
user_name: request.userName,
|
|
141
|
+
version: request.version,
|
|
142
|
+
volume: request.volume !== void 0 ? marshalVolume(request.volume, defaults) : void 0
|
|
210
143
|
});
|
|
211
144
|
const marshalCreateEndpointRequest = (request, defaults) => ({
|
|
212
|
-
|
|
213
|
-
|
|
145
|
+
deployment_id: request.deploymentId,
|
|
146
|
+
endpoint_spec: request.endpointSpec !== void 0 ? marshalEndpointSpec(request.endpointSpec, defaults) : void 0
|
|
214
147
|
});
|
|
215
148
|
const marshalCreateUserRequest = (request, defaults) => ({
|
|
216
|
-
|
|
217
|
-
|
|
149
|
+
password: request.password,
|
|
150
|
+
username: request.username
|
|
218
151
|
});
|
|
219
152
|
const marshalUpdateDeploymentRequest = (request, defaults) => ({
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
});
|
|
223
|
-
const marshalUpdateUserRequest = (request, defaults) => ({
|
|
224
|
-
password: request.password
|
|
153
|
+
name: request.name,
|
|
154
|
+
tags: request.tags
|
|
225
155
|
});
|
|
226
|
-
const
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
}
|
|
236
|
-
])
|
|
237
|
-
});
|
|
238
|
-
export {
|
|
239
|
-
marshalCreateDeploymentRequest,
|
|
240
|
-
marshalCreateEndpointRequest,
|
|
241
|
-
marshalCreateUserRequest,
|
|
242
|
-
marshalUpdateDeploymentRequest,
|
|
243
|
-
marshalUpdateUserRequest,
|
|
244
|
-
marshalUpgradeDeploymentRequest,
|
|
245
|
-
unmarshalDeployment,
|
|
246
|
-
unmarshalEndpoint,
|
|
247
|
-
unmarshalListDeploymentsResponse,
|
|
248
|
-
unmarshalListNodeTypesResponse,
|
|
249
|
-
unmarshalListUsersResponse,
|
|
250
|
-
unmarshalListVersionsResponse,
|
|
251
|
-
unmarshalUser
|
|
252
|
-
};
|
|
156
|
+
const marshalUpdateUserRequest = (request, defaults) => ({ password: request.password });
|
|
157
|
+
const marshalUpgradeDeploymentRequest = (request, defaults) => ({ ...resolveOneOf([{
|
|
158
|
+
param: "node_amount",
|
|
159
|
+
value: request.nodeAmount
|
|
160
|
+
}, {
|
|
161
|
+
param: "volume_size_bytes",
|
|
162
|
+
value: request.volumeSizeBytes
|
|
163
|
+
}]) });
|
|
164
|
+
export { marshalCreateDeploymentRequest, marshalCreateEndpointRequest, marshalCreateUserRequest, marshalUpdateDeploymentRequest, marshalUpdateUserRequest, marshalUpgradeDeploymentRequest, unmarshalDeployment, unmarshalEndpoint, unmarshalListDeploymentsResponse, unmarshalListNodeTypesResponse, unmarshalListUsersResponse, unmarshalListVersionsResponse, unmarshalUser };
|
|
@@ -1,129 +1,115 @@
|
|
|
1
|
+
import { __exportAll } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
+
var validation_rules_gen_exports = /* @__PURE__ */ __exportAll({
|
|
3
|
+
CreateDeploymentRequest: () => CreateDeploymentRequest,
|
|
4
|
+
CreateUserRequest: () => CreateUserRequest,
|
|
5
|
+
DeleteUserRequest: () => DeleteUserRequest,
|
|
6
|
+
ListDeploymentsRequest: () => ListDeploymentsRequest,
|
|
7
|
+
ListNodeTypesRequest: () => ListNodeTypesRequest,
|
|
8
|
+
ListUsersRequest: () => ListUsersRequest,
|
|
9
|
+
ListVersionsRequest: () => ListVersionsRequest,
|
|
10
|
+
UpdateDeploymentRequest: () => UpdateDeploymentRequest,
|
|
11
|
+
UpdateUserRequest: () => UpdateUserRequest,
|
|
12
|
+
Volume: () => Volume
|
|
13
|
+
});
|
|
1
14
|
const CreateDeploymentRequest = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
15
|
+
name: {
|
|
16
|
+
maxLength: 255,
|
|
17
|
+
minLength: 1,
|
|
18
|
+
pattern: /^[A-Za-z0-9\-_]+$/
|
|
19
|
+
},
|
|
20
|
+
nodeType: {
|
|
21
|
+
maxLength: 128,
|
|
22
|
+
minLength: 1,
|
|
23
|
+
pattern: /^[A-Za-z0-9\-_]+$/
|
|
24
|
+
},
|
|
25
|
+
password: {
|
|
26
|
+
maxLength: 128,
|
|
27
|
+
minLength: 12
|
|
28
|
+
},
|
|
29
|
+
userName: {
|
|
30
|
+
maxLength: 63,
|
|
31
|
+
minLength: 1,
|
|
32
|
+
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
33
|
+
},
|
|
34
|
+
version: {
|
|
35
|
+
maxLength: 128,
|
|
36
|
+
minLength: 1,
|
|
37
|
+
pattern: /^[0-9]+\.[0-9]+$/
|
|
38
|
+
}
|
|
26
39
|
};
|
|
27
40
|
const CreateUserRequest = {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
};
|
|
38
|
-
const DeleteUserRequest = {
|
|
39
|
-
username: {
|
|
40
|
-
maxLength: 63,
|
|
41
|
-
minLength: 1,
|
|
42
|
-
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
43
|
-
}
|
|
41
|
+
password: {
|
|
42
|
+
maxLength: 128,
|
|
43
|
+
minLength: 8
|
|
44
|
+
},
|
|
45
|
+
username: {
|
|
46
|
+
maxLength: 63,
|
|
47
|
+
minLength: 1,
|
|
48
|
+
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
49
|
+
}
|
|
44
50
|
};
|
|
51
|
+
const DeleteUserRequest = { username: {
|
|
52
|
+
maxLength: 63,
|
|
53
|
+
minLength: 1,
|
|
54
|
+
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
55
|
+
} };
|
|
45
56
|
const ListDeploymentsRequest = {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
pattern: /^[A-Za-z0-9\-_]+$/
|
|
62
|
-
}
|
|
57
|
+
name: {
|
|
58
|
+
maxLength: 255,
|
|
59
|
+
minLength: 1,
|
|
60
|
+
pattern: /^[A-Za-z0-9\-_]+$/
|
|
61
|
+
},
|
|
62
|
+
page: { greaterThanOrEqual: 1 },
|
|
63
|
+
pageSize: {
|
|
64
|
+
greaterThanOrEqual: 1,
|
|
65
|
+
lessThanOrEqual: 100
|
|
66
|
+
},
|
|
67
|
+
version: {
|
|
68
|
+
maxLength: 128,
|
|
69
|
+
minLength: 1,
|
|
70
|
+
pattern: /^[A-Za-z0-9\-_]+$/
|
|
71
|
+
}
|
|
63
72
|
};
|
|
64
73
|
const ListNodeTypesRequest = {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
lessThanOrEqual: 100
|
|
71
|
-
}
|
|
74
|
+
page: { greaterThanOrEqual: 1 },
|
|
75
|
+
pageSize: {
|
|
76
|
+
greaterThanOrEqual: 1,
|
|
77
|
+
lessThanOrEqual: 100
|
|
78
|
+
}
|
|
72
79
|
};
|
|
73
80
|
const ListUsersRequest = {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
lessThanOrEqual: 100
|
|
85
|
-
}
|
|
81
|
+
name: {
|
|
82
|
+
maxLength: 63,
|
|
83
|
+
minLength: 1,
|
|
84
|
+
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
85
|
+
},
|
|
86
|
+
page: { greaterThanOrEqual: 1 },
|
|
87
|
+
pageSize: {
|
|
88
|
+
greaterThanOrEqual: 1,
|
|
89
|
+
lessThanOrEqual: 100
|
|
90
|
+
}
|
|
86
91
|
};
|
|
87
92
|
const ListVersionsRequest = {
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
lessThanOrEqual: 100
|
|
94
|
-
}
|
|
95
|
-
};
|
|
96
|
-
const UpdateDeploymentRequest = {
|
|
97
|
-
name: {
|
|
98
|
-
maxLength: 255,
|
|
99
|
-
minLength: 1
|
|
100
|
-
}
|
|
93
|
+
page: { greaterThanOrEqual: 1 },
|
|
94
|
+
pageSize: {
|
|
95
|
+
greaterThanOrEqual: 1,
|
|
96
|
+
lessThanOrEqual: 100
|
|
97
|
+
}
|
|
101
98
|
};
|
|
99
|
+
const UpdateDeploymentRequest = { name: {
|
|
100
|
+
maxLength: 255,
|
|
101
|
+
minLength: 1
|
|
102
|
+
} };
|
|
102
103
|
const UpdateUserRequest = {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
};
|
|
113
|
-
const Volume = {
|
|
114
|
-
sizeBytes: {
|
|
115
|
-
greaterThanOrEqual: 1e9
|
|
116
|
-
}
|
|
117
|
-
};
|
|
118
|
-
export {
|
|
119
|
-
CreateDeploymentRequest,
|
|
120
|
-
CreateUserRequest,
|
|
121
|
-
DeleteUserRequest,
|
|
122
|
-
ListDeploymentsRequest,
|
|
123
|
-
ListNodeTypesRequest,
|
|
124
|
-
ListUsersRequest,
|
|
125
|
-
ListVersionsRequest,
|
|
126
|
-
UpdateDeploymentRequest,
|
|
127
|
-
UpdateUserRequest,
|
|
128
|
-
Volume
|
|
104
|
+
password: {
|
|
105
|
+
maxLength: 128,
|
|
106
|
+
minLength: 8
|
|
107
|
+
},
|
|
108
|
+
username: {
|
|
109
|
+
maxLength: 63,
|
|
110
|
+
minLength: 1,
|
|
111
|
+
pattern: /^[a-zA-Z0-9_\-]*$/
|
|
112
|
+
}
|
|
129
113
|
};
|
|
114
|
+
const Volume = { sizeBytes: { greaterThanOrEqual: 1e9 } };
|
|
115
|
+
export { validation_rules_gen_exports };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scaleway/sdk-searchdb",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "Scaleway SDK searchdb",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"files": [
|
|
@@ -26,14 +26,14 @@
|
|
|
26
26
|
"node": ">=20.18.3"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@scaleway/random-name": "5.1.
|
|
30
|
-
"@scaleway/sdk-std": "2.
|
|
29
|
+
"@scaleway/random-name": "5.1.2",
|
|
30
|
+
"@scaleway/sdk-std": "2.2.1"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"@scaleway/sdk-client": "^2.1
|
|
33
|
+
"@scaleway/sdk-client": "^2.2.1"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@scaleway/sdk-client": "^2.1
|
|
36
|
+
"@scaleway/sdk-client": "^2.2.1"
|
|
37
37
|
},
|
|
38
38
|
"scripts": {
|
|
39
39
|
"package:check": "pnpm publint",
|