@emilgroup/action-sdk 1.1.1-beta.6 → 1.2.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.
Files changed (43) hide show
  1. package/.openapi-generator/FILES +7 -0
  2. package/README.md +2 -2
  3. package/api/actions-api.ts +559 -130
  4. package/api/executions-api.ts +471 -0
  5. package/api.ts +2 -0
  6. package/dist/api/actions-api.d.ts +358 -112
  7. package/dist/api/actions-api.js +427 -97
  8. package/dist/api/executions-api.d.ts +272 -0
  9. package/dist/api/executions-api.js +452 -0
  10. package/dist/api.d.ts +1 -0
  11. package/dist/api.js +1 -0
  12. package/dist/models/action-class.d.ts +9 -20
  13. package/dist/models/action-execution-class.d.ts +36 -0
  14. package/dist/models/action-ref-class.d.ts +36 -0
  15. package/dist/models/action-ref-class.js +15 -0
  16. package/dist/models/action-version-class.d.ts +127 -0
  17. package/dist/models/action-version-class.js +21 -0
  18. package/dist/models/create-action-request-dto.d.ts +47 -5
  19. package/dist/models/create-action-request-dto.js +6 -0
  20. package/dist/models/get-action-version-response-class.d.ts +25 -0
  21. package/dist/models/get-action-version-response-class.js +15 -0
  22. package/dist/models/index.d.ts +6 -0
  23. package/dist/models/index.js +6 -0
  24. package/dist/models/list-action-versions-response-class.d.ts +43 -0
  25. package/dist/models/list-action-versions-response-class.js +15 -0
  26. package/dist/models/trigger-action-request-dto.d.ts +62 -0
  27. package/dist/models/trigger-action-request-dto.js +15 -0
  28. package/dist/models/trigger-action-response-class.d.ts +25 -0
  29. package/dist/models/trigger-action-response-class.js +15 -0
  30. package/dist/models/update-action-request-dto.d.ts +41 -5
  31. package/dist/models/update-action-request-dto.js +6 -0
  32. package/models/action-class.ts +9 -20
  33. package/models/action-execution-class.ts +36 -0
  34. package/models/action-ref-class.ts +42 -0
  35. package/models/action-version-class.ts +136 -0
  36. package/models/create-action-request-dto.ts +50 -5
  37. package/models/get-action-version-response-class.ts +31 -0
  38. package/models/index.ts +6 -0
  39. package/models/list-action-versions-response-class.ts +49 -0
  40. package/models/trigger-action-request-dto.ts +66 -0
  41. package/models/trigger-action-response-class.ts +31 -0
  42. package/models/update-action-request-dto.ts +44 -5
  43. package/package.json +1 -1
@@ -0,0 +1,272 @@
1
+ /**
2
+ * EMIL ActionService
3
+ * The EMIL ActionService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
+ import { Configuration } from '../configuration';
14
+ import { RequestArgs, BaseAPI } from '../base';
15
+ import { GetActionExecutionStatusResponseClass } from '../models';
16
+ import { ListActionExecutionsResponseClass } from '../models';
17
+ import { TriggerActionRequestDto } from '../models';
18
+ import { TriggerActionResponseClass } from '../models';
19
+ /**
20
+ * ExecutionsApi - axios parameter creator
21
+ * @export
22
+ */
23
+ export declare const ExecutionsApiAxiosParamCreator: (configuration?: Configuration) => {
24
+ /**
25
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
26
+ * @summary Retrieve the actionExecution
27
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
28
+ * @param {string} [executionCode] Action execution code
29
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
30
+ * @param {*} [options] Override http request option.
31
+ * @throws {RequiredError}
32
+ */
33
+ getActionExecutionStatus: (authorization?: string, executionCode?: string, correlationId?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
34
+ /**
35
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
36
+ * @summary List actionExecutions
37
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
38
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
39
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
40
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
41
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
42
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, triggeredAt, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, createdAt, updatedAt&lt;/i&gt;
43
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt;
44
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
45
+ * @param {*} [options] Override http request option.
46
+ * @throws {RequiredError}
47
+ */
48
+ listActionExecutions: (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
49
+ /**
50
+ * Triggers an action execution. When the action has an input_validation_schema, the input payload is validated against it; invalid payloads return HTTP 400 with a body containing message and errors (JSON Schema validation errors). **Required Permissions** \"action-management.actions.run\"
51
+ * @summary Create the actionExecution
52
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
53
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
54
+ * @param {*} [options] Override http request option.
55
+ * @throws {RequiredError}
56
+ */
57
+ triggerAction: (triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
58
+ };
59
+ /**
60
+ * ExecutionsApi - functional programming interface
61
+ * @export
62
+ */
63
+ export declare const ExecutionsApiFp: (configuration?: Configuration) => {
64
+ /**
65
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
66
+ * @summary Retrieve the actionExecution
67
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
68
+ * @param {string} [executionCode] Action execution code
69
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
70
+ * @param {*} [options] Override http request option.
71
+ * @throws {RequiredError}
72
+ */
73
+ getActionExecutionStatus(authorization?: string, executionCode?: string, correlationId?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetActionExecutionStatusResponseClass>>;
74
+ /**
75
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
76
+ * @summary List actionExecutions
77
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
78
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
79
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
80
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
81
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
82
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, triggeredAt, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, createdAt, updatedAt&lt;/i&gt;
83
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt;
84
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
85
+ * @param {*} [options] Override http request option.
86
+ * @throws {RequiredError}
87
+ */
88
+ listActionExecutions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListActionExecutionsResponseClass>>;
89
+ /**
90
+ * Triggers an action execution. When the action has an input_validation_schema, the input payload is validated against it; invalid payloads return HTTP 400 with a body containing message and errors (JSON Schema validation errors). **Required Permissions** \"action-management.actions.run\"
91
+ * @summary Create the actionExecution
92
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
93
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
94
+ * @param {*} [options] Override http request option.
95
+ * @throws {RequiredError}
96
+ */
97
+ triggerAction(triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TriggerActionResponseClass>>;
98
+ };
99
+ /**
100
+ * ExecutionsApi - factory interface
101
+ * @export
102
+ */
103
+ export declare const ExecutionsApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
104
+ /**
105
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
106
+ * @summary Retrieve the actionExecution
107
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
108
+ * @param {string} [executionCode] Action execution code
109
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
110
+ * @param {*} [options] Override http request option.
111
+ * @throws {RequiredError}
112
+ */
113
+ getActionExecutionStatus(authorization?: string, executionCode?: string, correlationId?: string, options?: any): AxiosPromise<GetActionExecutionStatusResponseClass>;
114
+ /**
115
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
116
+ * @summary List actionExecutions
117
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
118
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
119
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
120
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
121
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
122
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, triggeredAt, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, createdAt, updatedAt&lt;/i&gt;
123
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt;
124
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
125
+ * @param {*} [options] Override http request option.
126
+ * @throws {RequiredError}
127
+ */
128
+ listActionExecutions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListActionExecutionsResponseClass>;
129
+ /**
130
+ * Triggers an action execution. When the action has an input_validation_schema, the input payload is validated against it; invalid payloads return HTTP 400 with a body containing message and errors (JSON Schema validation errors). **Required Permissions** \"action-management.actions.run\"
131
+ * @summary Create the actionExecution
132
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
133
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
134
+ * @param {*} [options] Override http request option.
135
+ * @throws {RequiredError}
136
+ */
137
+ triggerAction(triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options?: any): AxiosPromise<TriggerActionResponseClass>;
138
+ };
139
+ /**
140
+ * Request parameters for getActionExecutionStatus operation in ExecutionsApi.
141
+ * @export
142
+ * @interface ExecutionsApiGetActionExecutionStatusRequest
143
+ */
144
+ export interface ExecutionsApiGetActionExecutionStatusRequest {
145
+ /**
146
+ * Bearer Token: provided by the login endpoint under the name accessToken.
147
+ * @type {string}
148
+ * @memberof ExecutionsApiGetActionExecutionStatus
149
+ */
150
+ readonly authorization?: string;
151
+ /**
152
+ * Action execution code
153
+ * @type {string}
154
+ * @memberof ExecutionsApiGetActionExecutionStatus
155
+ */
156
+ readonly executionCode?: string;
157
+ /**
158
+ * Correlation ID (e.g. webhook execution code that triggered this action execution)
159
+ * @type {string}
160
+ * @memberof ExecutionsApiGetActionExecutionStatus
161
+ */
162
+ readonly correlationId?: string;
163
+ }
164
+ /**
165
+ * Request parameters for listActionExecutions operation in ExecutionsApi.
166
+ * @export
167
+ * @interface ExecutionsApiListActionExecutionsRequest
168
+ */
169
+ export interface ExecutionsApiListActionExecutionsRequest {
170
+ /**
171
+ * Bearer Token: provided by the login endpoint under the name accessToken.
172
+ * @type {string}
173
+ * @memberof ExecutionsApiListActionExecutions
174
+ */
175
+ readonly authorization?: string;
176
+ /**
177
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
178
+ * @type {number}
179
+ * @memberof ExecutionsApiListActionExecutions
180
+ */
181
+ readonly pageSize?: number;
182
+ /**
183
+ * A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
184
+ * @type {string}
185
+ * @memberof ExecutionsApiListActionExecutions
186
+ */
187
+ readonly pageToken?: string;
188
+ /**
189
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
190
+ * @type {string}
191
+ * @memberof ExecutionsApiListActionExecutions
192
+ */
193
+ readonly filter?: string;
194
+ /**
195
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
196
+ * @type {string}
197
+ * @memberof ExecutionsApiListActionExecutions
198
+ */
199
+ readonly search?: string;
200
+ /**
201
+ * Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, triggeredAt, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, createdAt, updatedAt&lt;/i&gt;
202
+ * @type {string}
203
+ * @memberof ExecutionsApiListActionExecutions
204
+ */
205
+ readonly order?: string;
206
+ /**
207
+ * Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt;
208
+ * @type {string}
209
+ * @memberof ExecutionsApiListActionExecutions
210
+ */
211
+ readonly expand?: string;
212
+ /**
213
+ * Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, executionCode, actionCode, actionSlug, actionVersion, entityCode, entityType, triggeredBySub, status, triggeredBy, triggerSource, correlationId, workflowInstanceCode, force, completedAt, triggeredAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
214
+ * @type {string}
215
+ * @memberof ExecutionsApiListActionExecutions
216
+ */
217
+ readonly filters?: string;
218
+ }
219
+ /**
220
+ * Request parameters for triggerAction operation in ExecutionsApi.
221
+ * @export
222
+ * @interface ExecutionsApiTriggerActionRequest
223
+ */
224
+ export interface ExecutionsApiTriggerActionRequest {
225
+ /**
226
+ *
227
+ * @type {TriggerActionRequestDto}
228
+ * @memberof ExecutionsApiTriggerAction
229
+ */
230
+ readonly triggerActionRequestDto: TriggerActionRequestDto;
231
+ /**
232
+ * Bearer Token: provided by the login endpoint under the name accessToken.
233
+ * @type {string}
234
+ * @memberof ExecutionsApiTriggerAction
235
+ */
236
+ readonly authorization?: string;
237
+ }
238
+ /**
239
+ * ExecutionsApi - object-oriented interface
240
+ * @export
241
+ * @class ExecutionsApi
242
+ * @extends {BaseAPI}
243
+ */
244
+ export declare class ExecutionsApi extends BaseAPI {
245
+ /**
246
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
247
+ * @summary Retrieve the actionExecution
248
+ * @param {ExecutionsApiGetActionExecutionStatusRequest} requestParameters Request parameters.
249
+ * @param {*} [options] Override http request option.
250
+ * @throws {RequiredError}
251
+ * @memberof ExecutionsApi
252
+ */
253
+ getActionExecutionStatus(requestParameters?: ExecutionsApiGetActionExecutionStatusRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetActionExecutionStatusResponseClass, any, {}>>;
254
+ /**
255
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
256
+ * @summary List actionExecutions
257
+ * @param {ExecutionsApiListActionExecutionsRequest} requestParameters Request parameters.
258
+ * @param {*} [options] Override http request option.
259
+ * @throws {RequiredError}
260
+ * @memberof ExecutionsApi
261
+ */
262
+ listActionExecutions(requestParameters?: ExecutionsApiListActionExecutionsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListActionExecutionsResponseClass, any, {}>>;
263
+ /**
264
+ * Triggers an action execution. When the action has an input_validation_schema, the input payload is validated against it; invalid payloads return HTTP 400 with a body containing message and errors (JSON Schema validation errors). **Required Permissions** \"action-management.actions.run\"
265
+ * @summary Create the actionExecution
266
+ * @param {ExecutionsApiTriggerActionRequest} requestParameters Request parameters.
267
+ * @param {*} [options] Override http request option.
268
+ * @throws {RequiredError}
269
+ * @memberof ExecutionsApi
270
+ */
271
+ triggerAction(requestParameters: ExecutionsApiTriggerActionRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<TriggerActionResponseClass, any, {}>>;
272
+ }