@scaleway/sdk-jobs 2.2.2 → 2.3.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/_virtual/_rolldown/runtime.js +11 -0
- package/dist/index.gen.js +3 -6
- package/dist/v1alpha1/api.gen.js +193 -265
- package/dist/v1alpha1/content.gen.js +5 -6
- package/dist/v1alpha1/index.gen.js +24 -22
- package/dist/v1alpha1/marshalling.gen.js +137 -229
- package/dist/v1alpha1/validation-rules.gen.js +63 -101
- package/dist/v1alpha2/api.gen.js +194 -269
- package/dist/v1alpha2/content.gen.js +8 -9
- package/dist/v1alpha2/index.gen.js +24 -22
- package/dist/v1alpha2/marshalling.gen.js +161 -259
- package/dist/v1alpha2/validation-rules.gen.js +65 -107
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -83,6 +83,7 @@ const api = new Jobs.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
|
|
|
@@ -93,4 +94,3 @@ This repository is at its early stage and is still in active development. If you
|
|
|
93
94
|
## License
|
|
94
95
|
|
|
95
96
|
This project is Apache 2.0 licensed. See the [LICENSE](https://github.com/scaleway/scaleway-sdk-js/blob/master/LICENSE) file for details.
|
|
96
|
-
|
|
@@ -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
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export {
|
|
4
|
-
index_gen as Jobsv1alpha1,
|
|
5
|
-
index_gen$1 as Jobsv1alpha2
|
|
6
|
-
};
|
|
1
|
+
import { index_gen_exports } from "./v1alpha1/index.gen.js";
|
|
2
|
+
import { index_gen_exports as index_gen_exports$1 } from "./v1alpha2/index.gen.js";
|
|
3
|
+
export { index_gen_exports as Jobsv1alpha1, index_gen_exports$1 as Jobsv1alpha2 };
|
package/dist/v1alpha1/api.gen.js
CHANGED
|
@@ -1,266 +1,194 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
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
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
method: "GET",
|
|
194
|
-
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs/${validatePathParam("jobRunId", request.jobRunId)}`
|
|
195
|
-
},
|
|
196
|
-
unmarshalJobRun
|
|
197
|
-
);
|
|
198
|
-
/**
|
|
199
|
-
* Stop a job run by its unique identifier.
|
|
200
|
-
*
|
|
201
|
-
* @param request - The request {@link StopJobRunRequest}
|
|
202
|
-
* @returns A Promise of JobRun
|
|
203
|
-
*/
|
|
204
|
-
stopJobRun = (request) => this.client.fetch(
|
|
205
|
-
{
|
|
206
|
-
body: "{}",
|
|
207
|
-
headers: jsonContentHeaders,
|
|
208
|
-
method: "POST",
|
|
209
|
-
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs/${validatePathParam("jobRunId", request.jobRunId)}/stop`
|
|
210
|
-
},
|
|
211
|
-
unmarshalJobRun
|
|
212
|
-
);
|
|
213
|
-
pageOfListJobRuns = (request = {}) => this.client.fetch(
|
|
214
|
-
{
|
|
215
|
-
method: "GET",
|
|
216
|
-
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs`,
|
|
217
|
-
urlParams: urlParams(
|
|
218
|
-
["job_definition_id", request.jobDefinitionId],
|
|
219
|
-
["order_by", request.orderBy],
|
|
220
|
-
["organization_id", request.organizationId],
|
|
221
|
-
["page", request.page],
|
|
222
|
-
["page_size", request.pageSize ?? this.client.settings.defaultPageSize],
|
|
223
|
-
["project_id", request.projectId],
|
|
224
|
-
["state", request.state],
|
|
225
|
-
["states", request.states]
|
|
226
|
-
)
|
|
227
|
-
},
|
|
228
|
-
unmarshalListJobRunsResponse
|
|
229
|
-
);
|
|
230
|
-
/**
|
|
231
|
-
* List all job runs with filters.
|
|
232
|
-
*
|
|
233
|
-
* @param request - The request {@link ListJobRunsRequest}
|
|
234
|
-
* @returns A Promise of ListJobRunsResponse
|
|
235
|
-
*/
|
|
236
|
-
listJobRuns = (request = {}) => enrichForPagination("jobRuns", this.pageOfListJobRuns, request);
|
|
237
|
-
/**
|
|
238
|
-
* List jobs resources for the console.
|
|
239
|
-
*
|
|
240
|
-
* @param request - The request {@link ListJobsResourcesRequest}
|
|
241
|
-
* @returns A Promise of ListJobsResourcesResponse
|
|
242
|
-
*/
|
|
243
|
-
listJobsResources = (request = {}) => this.client.fetch(
|
|
244
|
-
{
|
|
245
|
-
method: "GET",
|
|
246
|
-
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/jobs-resources`
|
|
247
|
-
},
|
|
248
|
-
unmarshalListJobsResourcesResponse
|
|
249
|
-
);
|
|
250
|
-
/**
|
|
251
|
-
* Get jobs limits for the console.
|
|
252
|
-
*
|
|
253
|
-
* @param request - The request {@link GetJobsLimitsRequest}
|
|
254
|
-
* @returns A Promise of JobsLimits
|
|
255
|
-
*/
|
|
256
|
-
getJobsLimits = (request = {}) => this.client.fetch(
|
|
257
|
-
{
|
|
258
|
-
method: "GET",
|
|
259
|
-
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/jobs-limits`
|
|
260
|
-
},
|
|
261
|
-
unmarshalJobsLimits
|
|
262
|
-
);
|
|
263
|
-
}
|
|
264
|
-
export {
|
|
265
|
-
API
|
|
1
|
+
import { marshalCreateJobDefinitionRequest, marshalCreateJobDefinitionSecretsRequest, marshalStartJobDefinitionRequest, marshalUpdateJobDefinitionRequest, marshalUpdateJobDefinitionSecretRequest, unmarshalCreateJobDefinitionSecretsResponse, unmarshalJobDefinition, unmarshalJobRun, unmarshalJobsLimits, unmarshalListJobDefinitionSecretsResponse, unmarshalListJobDefinitionsResponse, unmarshalListJobRunsResponse, unmarshalListJobsResourcesResponse, unmarshalSecret, unmarshalStartJobDefinitionResponse } from "./marshalling.gen.js";
|
|
2
|
+
import { API, enrichForPagination, toApiLocality, urlParams, validatePathParam } from "@scaleway/sdk-client";
|
|
3
|
+
var jsonContentHeaders = { "Content-Type": "application/json; charset=utf-8" };
|
|
4
|
+
/**
|
|
5
|
+
* Serverless Jobs API.
|
|
6
|
+
|
|
7
|
+
This API allows you to manage your Serverless Jobs.
|
|
8
|
+
*/
|
|
9
|
+
var API$1 = class extends API {
|
|
10
|
+
/**
|
|
11
|
+
* Locality of this API.
|
|
12
|
+
* type ∈ {'zone','region','global','unspecified'}
|
|
13
|
+
*/
|
|
14
|
+
static LOCALITY = toApiLocality({ regions: [
|
|
15
|
+
"fr-par",
|
|
16
|
+
"nl-ams",
|
|
17
|
+
"pl-waw"
|
|
18
|
+
] });
|
|
19
|
+
/**
|
|
20
|
+
* Create a new job definition in a specified Project.
|
|
21
|
+
*
|
|
22
|
+
* @param request - The request {@link CreateJobDefinitionRequest}
|
|
23
|
+
* @returns A Promise of JobDefinition
|
|
24
|
+
*/
|
|
25
|
+
createJobDefinition = (request) => this.client.fetch({
|
|
26
|
+
body: JSON.stringify(marshalCreateJobDefinitionRequest(request, this.client.settings)),
|
|
27
|
+
headers: jsonContentHeaders,
|
|
28
|
+
method: "POST",
|
|
29
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions`
|
|
30
|
+
}, unmarshalJobDefinition);
|
|
31
|
+
/**
|
|
32
|
+
* Get a job definition by its unique identifier.
|
|
33
|
+
*
|
|
34
|
+
* @param request - The request {@link GetJobDefinitionRequest}
|
|
35
|
+
* @returns A Promise of JobDefinition
|
|
36
|
+
*/
|
|
37
|
+
getJobDefinition = (request) => this.client.fetch({
|
|
38
|
+
method: "GET",
|
|
39
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}`
|
|
40
|
+
}, unmarshalJobDefinition);
|
|
41
|
+
pageOfListJobDefinitions = (request = {}) => this.client.fetch({
|
|
42
|
+
method: "GET",
|
|
43
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions`,
|
|
44
|
+
urlParams: urlParams(["order_by", request.orderBy], ["organization_id", request.organizationId], ["page", request.page], ["page_size", request.pageSize ?? this.client.settings.defaultPageSize], ["project_id", request.projectId])
|
|
45
|
+
}, unmarshalListJobDefinitionsResponse);
|
|
46
|
+
/**
|
|
47
|
+
* List all your job definitions with filters.
|
|
48
|
+
*
|
|
49
|
+
* @param request - The request {@link ListJobDefinitionsRequest}
|
|
50
|
+
* @returns A Promise of ListJobDefinitionsResponse
|
|
51
|
+
*/
|
|
52
|
+
listJobDefinitions = (request = {}) => enrichForPagination("jobDefinitions", this.pageOfListJobDefinitions, request);
|
|
53
|
+
/**
|
|
54
|
+
* Update an existing job definition associated with the specified unique identifier.
|
|
55
|
+
*
|
|
56
|
+
* @param request - The request {@link UpdateJobDefinitionRequest}
|
|
57
|
+
* @returns A Promise of JobDefinition
|
|
58
|
+
*/
|
|
59
|
+
updateJobDefinition = (request) => this.client.fetch({
|
|
60
|
+
body: JSON.stringify(marshalUpdateJobDefinitionRequest(request, this.client.settings)),
|
|
61
|
+
headers: jsonContentHeaders,
|
|
62
|
+
method: "PATCH",
|
|
63
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}`
|
|
64
|
+
}, unmarshalJobDefinition);
|
|
65
|
+
/**
|
|
66
|
+
* Delete an existing job definition by its unique identifier.
|
|
67
|
+
*
|
|
68
|
+
* @param request - The request {@link DeleteJobDefinitionRequest}
|
|
69
|
+
*/
|
|
70
|
+
deleteJobDefinition = (request) => this.client.fetch({
|
|
71
|
+
method: "DELETE",
|
|
72
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}`
|
|
73
|
+
});
|
|
74
|
+
/**
|
|
75
|
+
* Run an existing job definition by its unique identifier. This will create a new job run.
|
|
76
|
+
*
|
|
77
|
+
* @param request - The request {@link StartJobDefinitionRequest}
|
|
78
|
+
* @returns A Promise of StartJobDefinitionResponse
|
|
79
|
+
*/
|
|
80
|
+
startJobDefinition = (request) => this.client.fetch({
|
|
81
|
+
body: JSON.stringify(marshalStartJobDefinitionRequest(request, this.client.settings)),
|
|
82
|
+
headers: jsonContentHeaders,
|
|
83
|
+
method: "POST",
|
|
84
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/start`
|
|
85
|
+
}, unmarshalStartJobDefinitionResponse);
|
|
86
|
+
/**
|
|
87
|
+
* Create a secret reference within a job definition.
|
|
88
|
+
*
|
|
89
|
+
* @param request - The request {@link CreateJobDefinitionSecretsRequest}
|
|
90
|
+
* @returns A Promise of CreateJobDefinitionSecretsResponse
|
|
91
|
+
*/
|
|
92
|
+
createJobDefinitionSecrets = (request) => this.client.fetch({
|
|
93
|
+
body: JSON.stringify(marshalCreateJobDefinitionSecretsRequest(request, this.client.settings)),
|
|
94
|
+
headers: jsonContentHeaders,
|
|
95
|
+
method: "POST",
|
|
96
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/secrets`
|
|
97
|
+
}, unmarshalCreateJobDefinitionSecretsResponse);
|
|
98
|
+
/**
|
|
99
|
+
* Get a secret references within a job definition.
|
|
100
|
+
*
|
|
101
|
+
* @param request - The request {@link GetJobDefinitionSecretRequest}
|
|
102
|
+
* @returns A Promise of Secret
|
|
103
|
+
*/
|
|
104
|
+
getJobDefinitionSecret = (request) => this.client.fetch({
|
|
105
|
+
method: "GET",
|
|
106
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/secrets/${validatePathParam("secretId", request.secretId)}`
|
|
107
|
+
}, unmarshalSecret);
|
|
108
|
+
/**
|
|
109
|
+
* List secrets references within a job definition.
|
|
110
|
+
*
|
|
111
|
+
* @param request - The request {@link ListJobDefinitionSecretsRequest}
|
|
112
|
+
* @returns A Promise of ListJobDefinitionSecretsResponse
|
|
113
|
+
*/
|
|
114
|
+
listJobDefinitionSecrets = (request) => this.client.fetch({
|
|
115
|
+
method: "GET",
|
|
116
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/secrets`
|
|
117
|
+
}, unmarshalListJobDefinitionSecretsResponse);
|
|
118
|
+
/**
|
|
119
|
+
* Update a secret reference within a job definition.
|
|
120
|
+
*
|
|
121
|
+
* @param request - The request {@link UpdateJobDefinitionSecretRequest}
|
|
122
|
+
* @returns A Promise of Secret
|
|
123
|
+
*/
|
|
124
|
+
updateJobDefinitionSecret = (request) => this.client.fetch({
|
|
125
|
+
body: JSON.stringify(marshalUpdateJobDefinitionSecretRequest(request, this.client.settings)),
|
|
126
|
+
headers: jsonContentHeaders,
|
|
127
|
+
method: "PATCH",
|
|
128
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/secrets/${validatePathParam("secretId", request.secretId)}`
|
|
129
|
+
}, unmarshalSecret);
|
|
130
|
+
/**
|
|
131
|
+
* Delete a secret reference within a job definition.
|
|
132
|
+
*
|
|
133
|
+
* @param request - The request {@link DeleteJobDefinitionSecretRequest}
|
|
134
|
+
*/
|
|
135
|
+
deleteJobDefinitionSecret = (request) => this.client.fetch({
|
|
136
|
+
method: "DELETE",
|
|
137
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-definitions/${validatePathParam("jobDefinitionId", request.jobDefinitionId)}/secrets/${validatePathParam("secretId", request.secretId)}`
|
|
138
|
+
});
|
|
139
|
+
/**
|
|
140
|
+
* Get a job run by its unique identifier.
|
|
141
|
+
*
|
|
142
|
+
* @param request - The request {@link GetJobRunRequest}
|
|
143
|
+
* @returns A Promise of JobRun
|
|
144
|
+
*/
|
|
145
|
+
getJobRun = (request) => this.client.fetch({
|
|
146
|
+
method: "GET",
|
|
147
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs/${validatePathParam("jobRunId", request.jobRunId)}`
|
|
148
|
+
}, unmarshalJobRun);
|
|
149
|
+
/**
|
|
150
|
+
* Stop a job run by its unique identifier.
|
|
151
|
+
*
|
|
152
|
+
* @param request - The request {@link StopJobRunRequest}
|
|
153
|
+
* @returns A Promise of JobRun
|
|
154
|
+
*/
|
|
155
|
+
stopJobRun = (request) => this.client.fetch({
|
|
156
|
+
body: "{}",
|
|
157
|
+
headers: jsonContentHeaders,
|
|
158
|
+
method: "POST",
|
|
159
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs/${validatePathParam("jobRunId", request.jobRunId)}/stop`
|
|
160
|
+
}, unmarshalJobRun);
|
|
161
|
+
pageOfListJobRuns = (request = {}) => this.client.fetch({
|
|
162
|
+
method: "GET",
|
|
163
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/job-runs`,
|
|
164
|
+
urlParams: urlParams(["job_definition_id", request.jobDefinitionId], ["order_by", request.orderBy], ["organization_id", request.organizationId], ["page", request.page], ["page_size", request.pageSize ?? this.client.settings.defaultPageSize], ["project_id", request.projectId], ["state", request.state], ["states", request.states])
|
|
165
|
+
}, unmarshalListJobRunsResponse);
|
|
166
|
+
/**
|
|
167
|
+
* List all job runs with filters.
|
|
168
|
+
*
|
|
169
|
+
* @param request - The request {@link ListJobRunsRequest}
|
|
170
|
+
* @returns A Promise of ListJobRunsResponse
|
|
171
|
+
*/
|
|
172
|
+
listJobRuns = (request = {}) => enrichForPagination("jobRuns", this.pageOfListJobRuns, request);
|
|
173
|
+
/**
|
|
174
|
+
* List jobs resources for the console.
|
|
175
|
+
*
|
|
176
|
+
* @param request - The request {@link ListJobsResourcesRequest}
|
|
177
|
+
* @returns A Promise of ListJobsResourcesResponse
|
|
178
|
+
*/
|
|
179
|
+
listJobsResources = (request = {}) => this.client.fetch({
|
|
180
|
+
method: "GET",
|
|
181
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/jobs-resources`
|
|
182
|
+
}, unmarshalListJobsResourcesResponse);
|
|
183
|
+
/**
|
|
184
|
+
* Get jobs limits for the console.
|
|
185
|
+
*
|
|
186
|
+
* @param request - The request {@link GetJobsLimitsRequest}
|
|
187
|
+
* @returns A Promise of JobsLimits
|
|
188
|
+
*/
|
|
189
|
+
getJobsLimits = (request = {}) => this.client.fetch({
|
|
190
|
+
method: "GET",
|
|
191
|
+
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/jobs-limits`
|
|
192
|
+
}, unmarshalJobsLimits);
|
|
266
193
|
};
|
|
194
|
+
export { API$1 as API };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
+
/** Lists transient statutes of the enum {@link JobRunState}. */
|
|
1
2
|
const JOB_RUN_TRANSIENT_STATUSES = [
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
"queued",
|
|
4
|
+
"scheduled",
|
|
5
|
+
"running"
|
|
5
6
|
];
|
|
6
|
-
export {
|
|
7
|
-
JOB_RUN_TRANSIENT_STATUSES
|
|
8
|
-
};
|
|
7
|
+
export { JOB_RUN_TRANSIENT_STATUSES };
|
|
@@ -1,24 +1,26 @@
|
|
|
1
|
+
import { __exportAll } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { marshalCreateJobDefinitionRequest, marshalCreateJobDefinitionSecretsRequest, marshalStartJobDefinitionRequest, marshalUpdateJobDefinitionRequest, marshalUpdateJobDefinitionSecretRequest, unmarshalCreateJobDefinitionSecretsResponse, unmarshalJobDefinition, unmarshalJobRun, unmarshalJobsLimits, unmarshalListJobDefinitionSecretsResponse, unmarshalListJobDefinitionsResponse, unmarshalListJobRunsResponse, unmarshalListJobsResourcesResponse, unmarshalSecret, unmarshalStartJobDefinitionResponse } from "./marshalling.gen.js";
|
|
1
3
|
import { API } from "./api.gen.js";
|
|
2
4
|
import { JOB_RUN_TRANSIENT_STATUSES } from "./content.gen.js";
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
};
|
|
5
|
+
import { validation_rules_gen_exports } from "./validation-rules.gen.js";
|
|
6
|
+
var index_gen_exports = /* @__PURE__ */ __exportAll({
|
|
7
|
+
API: () => API,
|
|
8
|
+
JOB_RUN_TRANSIENT_STATUSES: () => JOB_RUN_TRANSIENT_STATUSES,
|
|
9
|
+
ValidationRules: () => validation_rules_gen_exports,
|
|
10
|
+
marshalCreateJobDefinitionRequest: () => marshalCreateJobDefinitionRequest,
|
|
11
|
+
marshalCreateJobDefinitionSecretsRequest: () => marshalCreateJobDefinitionSecretsRequest,
|
|
12
|
+
marshalStartJobDefinitionRequest: () => marshalStartJobDefinitionRequest,
|
|
13
|
+
marshalUpdateJobDefinitionRequest: () => marshalUpdateJobDefinitionRequest,
|
|
14
|
+
marshalUpdateJobDefinitionSecretRequest: () => marshalUpdateJobDefinitionSecretRequest,
|
|
15
|
+
unmarshalCreateJobDefinitionSecretsResponse: () => unmarshalCreateJobDefinitionSecretsResponse,
|
|
16
|
+
unmarshalJobDefinition: () => unmarshalJobDefinition,
|
|
17
|
+
unmarshalJobRun: () => unmarshalJobRun,
|
|
18
|
+
unmarshalJobsLimits: () => unmarshalJobsLimits,
|
|
19
|
+
unmarshalListJobDefinitionSecretsResponse: () => unmarshalListJobDefinitionSecretsResponse,
|
|
20
|
+
unmarshalListJobDefinitionsResponse: () => unmarshalListJobDefinitionsResponse,
|
|
21
|
+
unmarshalListJobRunsResponse: () => unmarshalListJobRunsResponse,
|
|
22
|
+
unmarshalListJobsResourcesResponse: () => unmarshalListJobsResourcesResponse,
|
|
23
|
+
unmarshalSecret: () => unmarshalSecret,
|
|
24
|
+
unmarshalStartJobDefinitionResponse: () => unmarshalStartJobDefinitionResponse
|
|
25
|
+
});
|
|
26
|
+
export { index_gen_exports };
|