@emilgroup/action-sdk-node 1.0.1-beta.51 → 1.1.1-beta.12

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.
@@ -0,0 +1,1713 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL ActionService
5
+ * The EMIL ActionService API description
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+ import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
17
+ import { Configuration } from '../configuration';
18
+ // Some imports not used depending on template conditions
19
+ // @ts-ignore
20
+ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
21
+ // @ts-ignore
22
+ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
23
+ // @ts-ignore
24
+ import { CreateActionRequestDto } from '../models';
25
+ // @ts-ignore
26
+ import { CreateActionResponseClass } from '../models';
27
+ // @ts-ignore
28
+ import { GetActionExecutionStatusResponseClass } from '../models';
29
+ // @ts-ignore
30
+ import { GetActionResponseClass } from '../models';
31
+ // @ts-ignore
32
+ import { GetActionVersionResponseClass } from '../models';
33
+ // @ts-ignore
34
+ import { ListActionExecutionsResponseClass } from '../models';
35
+ // @ts-ignore
36
+ import { ListActionVersionsResponseClass } from '../models';
37
+ // @ts-ignore
38
+ import { ListActionsResponseClass } from '../models';
39
+ // @ts-ignore
40
+ import { TriggerActionRequestDto } from '../models';
41
+ // @ts-ignore
42
+ import { TriggerActionResponseClass } from '../models';
43
+ // @ts-ignore
44
+ import { UpdateActionRequestDto } from '../models';
45
+ // @ts-ignore
46
+ import { UpdateActionResponseClass } from '../models';
47
+ // URLSearchParams not necessarily used
48
+ // @ts-ignore
49
+ import { URL, URLSearchParams } from 'url';
50
+ const FormData = require('form-data');
51
+ /**
52
+ * ActionClientApi - axios parameter creator
53
+ * @export
54
+ */
55
+ export const ActionClientApiAxiosParamCreator = function (configuration?: Configuration) {
56
+ return {
57
+ /**
58
+ * Creates a new action configuration **Required Permissions** \"action-management.actions.create\"
59
+ * @summary Create the action
60
+ * @param {CreateActionRequestDto} createActionRequestDto
61
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
62
+ * @param {*} [options] Override http request option.
63
+ * @throws {RequiredError}
64
+ */
65
+ createAction: async (createActionRequestDto: CreateActionRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
66
+ // verify required parameter 'createActionRequestDto' is not null or undefined
67
+ assertParamExists('createAction', 'createActionRequestDto', createActionRequestDto)
68
+ const localVarPath = `/actionservice/v1/actions`;
69
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
70
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
71
+ let baseOptions;
72
+ let baseAccessToken;
73
+ if (configuration) {
74
+ baseOptions = configuration.baseOptions;
75
+ baseAccessToken = configuration.accessToken;
76
+ }
77
+
78
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
79
+ const localVarHeaderParameter = {} as any;
80
+ const localVarQueryParameter = {} as any;
81
+
82
+ // authentication bearer required
83
+ // http bearer authentication required
84
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
85
+
86
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
87
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
88
+ }
89
+
90
+
91
+
92
+ localVarHeaderParameter['Content-Type'] = 'application/json';
93
+
94
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
95
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
96
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
97
+ localVarRequestOptions.data = serializeDataIfNeeded(createActionRequestDto, localVarRequestOptions, configuration)
98
+
99
+ return {
100
+ url: toPathString(localVarUrlObj),
101
+ options: localVarRequestOptions,
102
+ };
103
+ },
104
+ /**
105
+ * Deletes an action configuration by its code **Required Permissions** \"action-management.actions.delete\"
106
+ * @summary Delete the action
107
+ * @param {string} code Action code
108
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
109
+ * @param {*} [options] Override http request option.
110
+ * @throws {RequiredError}
111
+ */
112
+ deleteAction: async (code: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
113
+ // verify required parameter 'code' is not null or undefined
114
+ assertParamExists('deleteAction', 'code', code)
115
+ const localVarPath = `/actionservice/v1/actions/{code}`
116
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
117
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
118
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
119
+ let baseOptions;
120
+ let baseAccessToken;
121
+ if (configuration) {
122
+ baseOptions = configuration.baseOptions;
123
+ baseAccessToken = configuration.accessToken;
124
+ }
125
+
126
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
127
+ const localVarHeaderParameter = {} as any;
128
+ const localVarQueryParameter = {} as any;
129
+
130
+ // authentication bearer required
131
+ // http bearer authentication required
132
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
133
+
134
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
135
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
136
+ }
137
+
138
+
139
+
140
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
141
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
142
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
143
+
144
+ return {
145
+ url: toPathString(localVarUrlObj),
146
+ options: localVarRequestOptions,
147
+ };
148
+ },
149
+ /**
150
+ * Deletes a specific action version by its version code **Required Permissions** \"action-management.actions.delete\"
151
+ * @summary Delete the action version
152
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
153
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
154
+ * @param {*} [options] Override http request option.
155
+ * @throws {RequiredError}
156
+ */
157
+ deleteActionVersion: async (versionCode: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
158
+ // verify required parameter 'versionCode' is not null or undefined
159
+ assertParamExists('deleteActionVersion', 'versionCode', versionCode)
160
+ const localVarPath = `/actionservice/v1/actions/versions/{versionCode}`
161
+ .replace(`{${"versionCode"}}`, encodeURIComponent(String(versionCode)));
162
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
163
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
164
+ let baseOptions;
165
+ let baseAccessToken;
166
+ if (configuration) {
167
+ baseOptions = configuration.baseOptions;
168
+ baseAccessToken = configuration.accessToken;
169
+ }
170
+
171
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
172
+ const localVarHeaderParameter = {} as any;
173
+ const localVarQueryParameter = {} as any;
174
+
175
+ // authentication bearer required
176
+ // http bearer authentication required
177
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
178
+
179
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
180
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
181
+ }
182
+
183
+
184
+
185
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
186
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
187
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
188
+
189
+ return {
190
+ url: toPathString(localVarUrlObj),
191
+ options: localVarRequestOptions,
192
+ };
193
+ },
194
+ /**
195
+ * Retrieves an action configuration by its code **Required Permissions** \"action-management.actions.view\"
196
+ * @summary Retrieve the action
197
+ * @param {string} code Action code
198
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
199
+ * @param {string} [expand] Expand to fetch additional information (e.g. inputValidationSchema)
200
+ * @param {*} [options] Override http request option.
201
+ * @throws {RequiredError}
202
+ */
203
+ getAction: async (code: string, authorization?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
204
+ // verify required parameter 'code' is not null or undefined
205
+ assertParamExists('getAction', 'code', code)
206
+ const localVarPath = `/actionservice/v1/actions/{code}`
207
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
208
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
209
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
210
+ let baseOptions;
211
+ let baseAccessToken;
212
+ if (configuration) {
213
+ baseOptions = configuration.baseOptions;
214
+ baseAccessToken = configuration.accessToken;
215
+ }
216
+
217
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
218
+ const localVarHeaderParameter = {} as any;
219
+ const localVarQueryParameter = {} as any;
220
+
221
+ // authentication bearer required
222
+ // http bearer authentication required
223
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
224
+
225
+ if (expand !== undefined) {
226
+ localVarQueryParameter['expand'] = expand;
227
+ }
228
+
229
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
230
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
231
+ }
232
+
233
+
234
+
235
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
236
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
237
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
238
+
239
+ return {
240
+ url: toPathString(localVarUrlObj),
241
+ options: localVarRequestOptions,
242
+ };
243
+ },
244
+ /**
245
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
246
+ * @summary Retrieve the actionExecution
247
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
248
+ * @param {string} [executionCode] Action execution code
249
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
250
+ * @param {*} [options] Override http request option.
251
+ * @throws {RequiredError}
252
+ */
253
+ getActionExecutionStatus: async (authorization?: string, executionCode?: string, correlationId?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
254
+ const localVarPath = `/actionservice/v1/actions/executions/status`;
255
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
256
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
257
+ let baseOptions;
258
+ let baseAccessToken;
259
+ if (configuration) {
260
+ baseOptions = configuration.baseOptions;
261
+ baseAccessToken = configuration.accessToken;
262
+ }
263
+
264
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
265
+ const localVarHeaderParameter = {} as any;
266
+ const localVarQueryParameter = {} as any;
267
+
268
+ // authentication bearer required
269
+ // http bearer authentication required
270
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
271
+
272
+ if (executionCode !== undefined) {
273
+ localVarQueryParameter['executionCode'] = executionCode;
274
+ }
275
+
276
+ if (correlationId !== undefined) {
277
+ localVarQueryParameter['correlationId'] = correlationId;
278
+ }
279
+
280
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
281
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
282
+ }
283
+
284
+
285
+
286
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
287
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
288
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
289
+
290
+ return {
291
+ url: toPathString(localVarUrlObj),
292
+ options: localVarRequestOptions,
293
+ };
294
+ },
295
+ /**
296
+ * Gets a specific action version by its version code **Required Permissions** \"action-management.actions.view\"
297
+ * @summary Retrieve the action version
298
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
299
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
300
+ * @param {string} [expand]
301
+ * @param {*} [options] Override http request option.
302
+ * @throws {RequiredError}
303
+ */
304
+ getActionVersion: async (versionCode: string, authorization?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
305
+ // verify required parameter 'versionCode' is not null or undefined
306
+ assertParamExists('getActionVersion', 'versionCode', versionCode)
307
+ const localVarPath = `/actionservice/v1/actions/versions/{versionCode}`
308
+ .replace(`{${"versionCode"}}`, encodeURIComponent(String(versionCode)));
309
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
310
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
311
+ let baseOptions;
312
+ let baseAccessToken;
313
+ if (configuration) {
314
+ baseOptions = configuration.baseOptions;
315
+ baseAccessToken = configuration.accessToken;
316
+ }
317
+
318
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
319
+ const localVarHeaderParameter = {} as any;
320
+ const localVarQueryParameter = {} as any;
321
+
322
+ // authentication bearer required
323
+ // http bearer authentication required
324
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
325
+
326
+ if (expand !== undefined) {
327
+ localVarQueryParameter['expand'] = expand;
328
+ }
329
+
330
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
331
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
332
+ }
333
+
334
+
335
+
336
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
337
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
338
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
339
+
340
+ return {
341
+ url: toPathString(localVarUrlObj),
342
+ options: localVarRequestOptions,
343
+ };
344
+ },
345
+ /**
346
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
347
+ * @summary List actionExecutions
348
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
349
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
350
+ * @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.
351
+ * @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;
352
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
353
+ * @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;
354
+ * @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;
355
+ * @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;
356
+ * @param {*} [options] Override http request option.
357
+ * @throws {RequiredError}
358
+ */
359
+ listActionExecutions: async (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
360
+ const localVarPath = `/actionservice/v1/actions/executions`;
361
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
362
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
363
+ let baseOptions;
364
+ let baseAccessToken;
365
+ if (configuration) {
366
+ baseOptions = configuration.baseOptions;
367
+ baseAccessToken = configuration.accessToken;
368
+ }
369
+
370
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
371
+ const localVarHeaderParameter = {} as any;
372
+ const localVarQueryParameter = {} as any;
373
+
374
+ // authentication bearer required
375
+ // http bearer authentication required
376
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
377
+
378
+ if (pageSize !== undefined) {
379
+ localVarQueryParameter['pageSize'] = pageSize;
380
+ }
381
+
382
+ if (pageToken !== undefined) {
383
+ localVarQueryParameter['pageToken'] = pageToken;
384
+ }
385
+
386
+ if (filter !== undefined) {
387
+ localVarQueryParameter['filter'] = filter;
388
+ }
389
+
390
+ if (search !== undefined) {
391
+ localVarQueryParameter['search'] = search;
392
+ }
393
+
394
+ if (order !== undefined) {
395
+ localVarQueryParameter['order'] = order;
396
+ }
397
+
398
+ if (expand !== undefined) {
399
+ localVarQueryParameter['expand'] = expand;
400
+ }
401
+
402
+ if (filters !== undefined) {
403
+ localVarQueryParameter['filters'] = filters;
404
+ }
405
+
406
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
407
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
408
+ }
409
+
410
+
411
+
412
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
413
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
414
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
415
+
416
+ return {
417
+ url: toPathString(localVarUrlObj),
418
+ options: localVarRequestOptions,
419
+ };
420
+ },
421
+ /**
422
+ * Lists all versions for an action by code **Required Permissions** \"action-management.actions.view\"
423
+ * @summary List action versions
424
+ * @param {string} code Action code
425
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
426
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
427
+ * @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.
428
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
429
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
430
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
431
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
432
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
433
+ * @param {*} [options] Override http request option.
434
+ * @throws {RequiredError}
435
+ */
436
+ listActionVersions: async (code: string, authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
437
+ // verify required parameter 'code' is not null or undefined
438
+ assertParamExists('listActionVersions', 'code', code)
439
+ const localVarPath = `/actionservice/v1/actions/{code}/versions`
440
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
441
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
442
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
443
+ let baseOptions;
444
+ let baseAccessToken;
445
+ if (configuration) {
446
+ baseOptions = configuration.baseOptions;
447
+ baseAccessToken = configuration.accessToken;
448
+ }
449
+
450
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
451
+ const localVarHeaderParameter = {} as any;
452
+ const localVarQueryParameter = {} as any;
453
+
454
+ // authentication bearer required
455
+ // http bearer authentication required
456
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
457
+
458
+ if (pageSize !== undefined) {
459
+ localVarQueryParameter['pageSize'] = pageSize;
460
+ }
461
+
462
+ if (pageToken !== undefined) {
463
+ localVarQueryParameter['pageToken'] = pageToken;
464
+ }
465
+
466
+ if (filter !== undefined) {
467
+ localVarQueryParameter['filter'] = filter;
468
+ }
469
+
470
+ if (search !== undefined) {
471
+ localVarQueryParameter['search'] = search;
472
+ }
473
+
474
+ if (order !== undefined) {
475
+ localVarQueryParameter['order'] = order;
476
+ }
477
+
478
+ if (expand !== undefined) {
479
+ localVarQueryParameter['expand'] = expand;
480
+ }
481
+
482
+ if (filters !== undefined) {
483
+ localVarQueryParameter['filters'] = filters;
484
+ }
485
+
486
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
487
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
488
+ }
489
+
490
+
491
+
492
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
493
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
494
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
495
+
496
+ return {
497
+ url: toPathString(localVarUrlObj),
498
+ options: localVarRequestOptions,
499
+ };
500
+ },
501
+ /**
502
+ * Lists all action configurations with optional filters **Required Permissions** \"action-management.actions.view\"
503
+ * @summary List actions
504
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
505
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
506
+ * @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.
507
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
508
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
509
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
510
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
511
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
512
+ * @param {*} [options] Override http request option.
513
+ * @throws {RequiredError}
514
+ */
515
+ listActions: async (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
516
+ const localVarPath = `/actionservice/v1/actions`;
517
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
518
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
519
+ let baseOptions;
520
+ let baseAccessToken;
521
+ if (configuration) {
522
+ baseOptions = configuration.baseOptions;
523
+ baseAccessToken = configuration.accessToken;
524
+ }
525
+
526
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
527
+ const localVarHeaderParameter = {} as any;
528
+ const localVarQueryParameter = {} as any;
529
+
530
+ // authentication bearer required
531
+ // http bearer authentication required
532
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
533
+
534
+ if (pageSize !== undefined) {
535
+ localVarQueryParameter['pageSize'] = pageSize;
536
+ }
537
+
538
+ if (pageToken !== undefined) {
539
+ localVarQueryParameter['pageToken'] = pageToken;
540
+ }
541
+
542
+ if (filter !== undefined) {
543
+ localVarQueryParameter['filter'] = filter;
544
+ }
545
+
546
+ if (search !== undefined) {
547
+ localVarQueryParameter['search'] = search;
548
+ }
549
+
550
+ if (order !== undefined) {
551
+ localVarQueryParameter['order'] = order;
552
+ }
553
+
554
+ if (expand !== undefined) {
555
+ localVarQueryParameter['expand'] = expand;
556
+ }
557
+
558
+ if (filters !== undefined) {
559
+ localVarQueryParameter['filters'] = filters;
560
+ }
561
+
562
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
563
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
564
+ }
565
+
566
+
567
+
568
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
569
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
570
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
571
+
572
+ return {
573
+ url: toPathString(localVarUrlObj),
574
+ options: localVarRequestOptions,
575
+ };
576
+ },
577
+ /**
578
+ * Lists all action versions. Use filters e.g. isActive==true, entityType==LEAD, name, slug. No parent action code required. **Required Permissions** \"action-management.actions.view\"
579
+ * @summary List action versions
580
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
581
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
582
+ * @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.
583
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
584
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
585
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
586
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
587
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
588
+ * @param {*} [options] Override http request option.
589
+ * @throws {RequiredError}
590
+ */
591
+ listAllActionVersions: async (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
592
+ const localVarPath = `/actionservice/v1/actions/versions`;
593
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
594
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
595
+ let baseOptions;
596
+ let baseAccessToken;
597
+ if (configuration) {
598
+ baseOptions = configuration.baseOptions;
599
+ baseAccessToken = configuration.accessToken;
600
+ }
601
+
602
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
603
+ const localVarHeaderParameter = {} as any;
604
+ const localVarQueryParameter = {} as any;
605
+
606
+ // authentication bearer required
607
+ // http bearer authentication required
608
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
609
+
610
+ if (pageSize !== undefined) {
611
+ localVarQueryParameter['pageSize'] = pageSize;
612
+ }
613
+
614
+ if (pageToken !== undefined) {
615
+ localVarQueryParameter['pageToken'] = pageToken;
616
+ }
617
+
618
+ if (filter !== undefined) {
619
+ localVarQueryParameter['filter'] = filter;
620
+ }
621
+
622
+ if (search !== undefined) {
623
+ localVarQueryParameter['search'] = search;
624
+ }
625
+
626
+ if (order !== undefined) {
627
+ localVarQueryParameter['order'] = order;
628
+ }
629
+
630
+ if (expand !== undefined) {
631
+ localVarQueryParameter['expand'] = expand;
632
+ }
633
+
634
+ if (filters !== undefined) {
635
+ localVarQueryParameter['filters'] = filters;
636
+ }
637
+
638
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
639
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
640
+ }
641
+
642
+
643
+
644
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
645
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
646
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
647
+
648
+ return {
649
+ url: toPathString(localVarUrlObj),
650
+ options: localVarRequestOptions,
651
+ };
652
+ },
653
+ /**
654
+ * 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\"
655
+ * @summary Create the actionExecution
656
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
657
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
658
+ * @param {*} [options] Override http request option.
659
+ * @throws {RequiredError}
660
+ */
661
+ triggerAction: async (triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
662
+ // verify required parameter 'triggerActionRequestDto' is not null or undefined
663
+ assertParamExists('triggerAction', 'triggerActionRequestDto', triggerActionRequestDto)
664
+ const localVarPath = `/actionservice/v1/actions/trigger`;
665
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
666
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
667
+ let baseOptions;
668
+ let baseAccessToken;
669
+ if (configuration) {
670
+ baseOptions = configuration.baseOptions;
671
+ baseAccessToken = configuration.accessToken;
672
+ }
673
+
674
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
675
+ const localVarHeaderParameter = {} as any;
676
+ const localVarQueryParameter = {} as any;
677
+
678
+ // authentication bearer required
679
+ // http bearer authentication required
680
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
681
+
682
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
683
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
684
+ }
685
+
686
+
687
+
688
+ localVarHeaderParameter['Content-Type'] = 'application/json';
689
+
690
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
691
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
692
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
693
+ localVarRequestOptions.data = serializeDataIfNeeded(triggerActionRequestDto, localVarRequestOptions, configuration)
694
+
695
+ return {
696
+ url: toPathString(localVarUrlObj),
697
+ options: localVarRequestOptions,
698
+ };
699
+ },
700
+ /**
701
+ * Updates an existing action configuration (patch semantics) **Required Permissions** \"action-management.actions.update\"
702
+ * @summary Update the action
703
+ * @param {string} code Action code
704
+ * @param {UpdateActionRequestDto} updateActionRequestDto
705
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
706
+ * @param {*} [options] Override http request option.
707
+ * @throws {RequiredError}
708
+ */
709
+ updateAction: async (code: string, updateActionRequestDto: UpdateActionRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
710
+ // verify required parameter 'code' is not null or undefined
711
+ assertParamExists('updateAction', 'code', code)
712
+ // verify required parameter 'updateActionRequestDto' is not null or undefined
713
+ assertParamExists('updateAction', 'updateActionRequestDto', updateActionRequestDto)
714
+ const localVarPath = `/actionservice/v1/actions/{code}`
715
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
716
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
717
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
718
+ let baseOptions;
719
+ let baseAccessToken;
720
+ if (configuration) {
721
+ baseOptions = configuration.baseOptions;
722
+ baseAccessToken = configuration.accessToken;
723
+ }
724
+
725
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
726
+ const localVarHeaderParameter = {} as any;
727
+ const localVarQueryParameter = {} as any;
728
+
729
+ // authentication bearer required
730
+ // http bearer authentication required
731
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
732
+
733
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
734
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
735
+ }
736
+
737
+
738
+
739
+ localVarHeaderParameter['Content-Type'] = 'application/json';
740
+
741
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
742
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
743
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
744
+ localVarRequestOptions.data = serializeDataIfNeeded(updateActionRequestDto, localVarRequestOptions, configuration)
745
+
746
+ return {
747
+ url: toPathString(localVarUrlObj),
748
+ options: localVarRequestOptions,
749
+ };
750
+ },
751
+ }
752
+ };
753
+
754
+ /**
755
+ * ActionClientApi - functional programming interface
756
+ * @export
757
+ */
758
+ export const ActionClientApiFp = function(configuration?: Configuration) {
759
+ const localVarAxiosParamCreator = ActionClientApiAxiosParamCreator(configuration)
760
+ return {
761
+ /**
762
+ * Creates a new action configuration **Required Permissions** \"action-management.actions.create\"
763
+ * @summary Create the action
764
+ * @param {CreateActionRequestDto} createActionRequestDto
765
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
766
+ * @param {*} [options] Override http request option.
767
+ * @throws {RequiredError}
768
+ */
769
+ async createAction(createActionRequestDto: CreateActionRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateActionResponseClass>> {
770
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createAction(createActionRequestDto, authorization, options);
771
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
772
+ },
773
+ /**
774
+ * Deletes an action configuration by its code **Required Permissions** \"action-management.actions.delete\"
775
+ * @summary Delete the action
776
+ * @param {string} code Action code
777
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
778
+ * @param {*} [options] Override http request option.
779
+ * @throws {RequiredError}
780
+ */
781
+ async deleteAction(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
782
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteAction(code, authorization, options);
783
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
784
+ },
785
+ /**
786
+ * Deletes a specific action version by its version code **Required Permissions** \"action-management.actions.delete\"
787
+ * @summary Delete the action version
788
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
789
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
790
+ * @param {*} [options] Override http request option.
791
+ * @throws {RequiredError}
792
+ */
793
+ async deleteActionVersion(versionCode: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
794
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteActionVersion(versionCode, authorization, options);
795
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
796
+ },
797
+ /**
798
+ * Retrieves an action configuration by its code **Required Permissions** \"action-management.actions.view\"
799
+ * @summary Retrieve the action
800
+ * @param {string} code Action code
801
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
802
+ * @param {string} [expand] Expand to fetch additional information (e.g. inputValidationSchema)
803
+ * @param {*} [options] Override http request option.
804
+ * @throws {RequiredError}
805
+ */
806
+ async getAction(code: string, authorization?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetActionResponseClass>> {
807
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAction(code, authorization, expand, options);
808
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
809
+ },
810
+ /**
811
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
812
+ * @summary Retrieve the actionExecution
813
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
814
+ * @param {string} [executionCode] Action execution code
815
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
816
+ * @param {*} [options] Override http request option.
817
+ * @throws {RequiredError}
818
+ */
819
+ async getActionExecutionStatus(authorization?: string, executionCode?: string, correlationId?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetActionExecutionStatusResponseClass>> {
820
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getActionExecutionStatus(authorization, executionCode, correlationId, options);
821
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
822
+ },
823
+ /**
824
+ * Gets a specific action version by its version code **Required Permissions** \"action-management.actions.view\"
825
+ * @summary Retrieve the action version
826
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
827
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
828
+ * @param {string} [expand]
829
+ * @param {*} [options] Override http request option.
830
+ * @throws {RequiredError}
831
+ */
832
+ async getActionVersion(versionCode: string, authorization?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetActionVersionResponseClass>> {
833
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getActionVersion(versionCode, authorization, expand, options);
834
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
835
+ },
836
+ /**
837
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
838
+ * @summary List actionExecutions
839
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
840
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
841
+ * @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.
842
+ * @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;
843
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
844
+ * @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;
845
+ * @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;
846
+ * @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;
847
+ * @param {*} [options] Override http request option.
848
+ * @throws {RequiredError}
849
+ */
850
+ async 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>> {
851
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listActionExecutions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
852
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
853
+ },
854
+ /**
855
+ * Lists all versions for an action by code **Required Permissions** \"action-management.actions.view\"
856
+ * @summary List action versions
857
+ * @param {string} code Action code
858
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
859
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
860
+ * @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.
861
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
862
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
863
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
864
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
865
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
866
+ * @param {*} [options] Override http request option.
867
+ * @throws {RequiredError}
868
+ */
869
+ async listActionVersions(code: string, authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListActionVersionsResponseClass>> {
870
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listActionVersions(code, authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
871
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
872
+ },
873
+ /**
874
+ * Lists all action configurations with optional filters **Required Permissions** \"action-management.actions.view\"
875
+ * @summary List actions
876
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
877
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
878
+ * @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.
879
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
880
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
881
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
882
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
883
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
884
+ * @param {*} [options] Override http request option.
885
+ * @throws {RequiredError}
886
+ */
887
+ async listActions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListActionsResponseClass>> {
888
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listActions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
889
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
890
+ },
891
+ /**
892
+ * Lists all action versions. Use filters e.g. isActive==true, entityType==LEAD, name, slug. No parent action code required. **Required Permissions** \"action-management.actions.view\"
893
+ * @summary List action versions
894
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
895
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
896
+ * @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.
897
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
898
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
899
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
900
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
901
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
902
+ * @param {*} [options] Override http request option.
903
+ * @throws {RequiredError}
904
+ */
905
+ async listAllActionVersions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListActionVersionsResponseClass>> {
906
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listAllActionVersions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
907
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
908
+ },
909
+ /**
910
+ * 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\"
911
+ * @summary Create the actionExecution
912
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
913
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
914
+ * @param {*} [options] Override http request option.
915
+ * @throws {RequiredError}
916
+ */
917
+ async triggerAction(triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TriggerActionResponseClass>> {
918
+ const localVarAxiosArgs = await localVarAxiosParamCreator.triggerAction(triggerActionRequestDto, authorization, options);
919
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
920
+ },
921
+ /**
922
+ * Updates an existing action configuration (patch semantics) **Required Permissions** \"action-management.actions.update\"
923
+ * @summary Update the action
924
+ * @param {string} code Action code
925
+ * @param {UpdateActionRequestDto} updateActionRequestDto
926
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
927
+ * @param {*} [options] Override http request option.
928
+ * @throws {RequiredError}
929
+ */
930
+ async updateAction(code: string, updateActionRequestDto: UpdateActionRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateActionResponseClass>> {
931
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateAction(code, updateActionRequestDto, authorization, options);
932
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
933
+ },
934
+ }
935
+ };
936
+
937
+ /**
938
+ * ActionClientApi - factory interface
939
+ * @export
940
+ */
941
+ export const ActionClientApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
942
+ const localVarFp = ActionClientApiFp(configuration)
943
+ return {
944
+ /**
945
+ * Creates a new action configuration **Required Permissions** \"action-management.actions.create\"
946
+ * @summary Create the action
947
+ * @param {CreateActionRequestDto} createActionRequestDto
948
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
949
+ * @param {*} [options] Override http request option.
950
+ * @throws {RequiredError}
951
+ */
952
+ createAction(createActionRequestDto: CreateActionRequestDto, authorization?: string, options?: any): AxiosPromise<CreateActionResponseClass> {
953
+ return localVarFp.createAction(createActionRequestDto, authorization, options).then((request) => request(axios, basePath));
954
+ },
955
+ /**
956
+ * Deletes an action configuration by its code **Required Permissions** \"action-management.actions.delete\"
957
+ * @summary Delete the action
958
+ * @param {string} code Action code
959
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
960
+ * @param {*} [options] Override http request option.
961
+ * @throws {RequiredError}
962
+ */
963
+ deleteAction(code: string, authorization?: string, options?: any): AxiosPromise<void> {
964
+ return localVarFp.deleteAction(code, authorization, options).then((request) => request(axios, basePath));
965
+ },
966
+ /**
967
+ * Deletes a specific action version by its version code **Required Permissions** \"action-management.actions.delete\"
968
+ * @summary Delete the action version
969
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
970
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
971
+ * @param {*} [options] Override http request option.
972
+ * @throws {RequiredError}
973
+ */
974
+ deleteActionVersion(versionCode: string, authorization?: string, options?: any): AxiosPromise<void> {
975
+ return localVarFp.deleteActionVersion(versionCode, authorization, options).then((request) => request(axios, basePath));
976
+ },
977
+ /**
978
+ * Retrieves an action configuration by its code **Required Permissions** \"action-management.actions.view\"
979
+ * @summary Retrieve the action
980
+ * @param {string} code Action code
981
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
982
+ * @param {string} [expand] Expand to fetch additional information (e.g. inputValidationSchema)
983
+ * @param {*} [options] Override http request option.
984
+ * @throws {RequiredError}
985
+ */
986
+ getAction(code: string, authorization?: string, expand?: string, options?: any): AxiosPromise<GetActionResponseClass> {
987
+ return localVarFp.getAction(code, authorization, expand, options).then((request) => request(axios, basePath));
988
+ },
989
+ /**
990
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
991
+ * @summary Retrieve the actionExecution
992
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
993
+ * @param {string} [executionCode] Action execution code
994
+ * @param {string} [correlationId] Correlation ID (e.g. webhook execution code that triggered this action execution)
995
+ * @param {*} [options] Override http request option.
996
+ * @throws {RequiredError}
997
+ */
998
+ getActionExecutionStatus(authorization?: string, executionCode?: string, correlationId?: string, options?: any): AxiosPromise<GetActionExecutionStatusResponseClass> {
999
+ return localVarFp.getActionExecutionStatus(authorization, executionCode, correlationId, options).then((request) => request(axios, basePath));
1000
+ },
1001
+ /**
1002
+ * Gets a specific action version by its version code **Required Permissions** \"action-management.actions.view\"
1003
+ * @summary Retrieve the action version
1004
+ * @param {string} versionCode Version code (e.g. acv_&lt;nanoid&gt;)
1005
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1006
+ * @param {string} [expand]
1007
+ * @param {*} [options] Override http request option.
1008
+ * @throws {RequiredError}
1009
+ */
1010
+ getActionVersion(versionCode: string, authorization?: string, expand?: string, options?: any): AxiosPromise<GetActionVersionResponseClass> {
1011
+ return localVarFp.getActionVersion(versionCode, authorization, expand, options).then((request) => request(axios, basePath));
1012
+ },
1013
+ /**
1014
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
1015
+ * @summary List actionExecutions
1016
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1017
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1018
+ * @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.
1019
+ * @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;
1020
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1021
+ * @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;
1022
+ * @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;
1023
+ * @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;
1024
+ * @param {*} [options] Override http request option.
1025
+ * @throws {RequiredError}
1026
+ */
1027
+ listActionExecutions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListActionExecutionsResponseClass> {
1028
+ return localVarFp.listActionExecutions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
1029
+ },
1030
+ /**
1031
+ * Lists all versions for an action by code **Required Permissions** \"action-management.actions.view\"
1032
+ * @summary List action versions
1033
+ * @param {string} code Action code
1034
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1035
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1036
+ * @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.
1037
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1038
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1039
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1040
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1041
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1042
+ * @param {*} [options] Override http request option.
1043
+ * @throws {RequiredError}
1044
+ */
1045
+ listActionVersions(code: string, authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListActionVersionsResponseClass> {
1046
+ return localVarFp.listActionVersions(code, authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
1047
+ },
1048
+ /**
1049
+ * Lists all action configurations with optional filters **Required Permissions** \"action-management.actions.view\"
1050
+ * @summary List actions
1051
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1052
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1053
+ * @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.
1054
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1055
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1056
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1057
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1058
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1059
+ * @param {*} [options] Override http request option.
1060
+ * @throws {RequiredError}
1061
+ */
1062
+ listActions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListActionsResponseClass> {
1063
+ return localVarFp.listActions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
1064
+ },
1065
+ /**
1066
+ * Lists all action versions. Use filters e.g. isActive==true, entityType==LEAD, name, slug. No parent action code required. **Required Permissions** \"action-management.actions.view\"
1067
+ * @summary List action versions
1068
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1069
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1070
+ * @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.
1071
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1072
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1073
+ * @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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1074
+ * @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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1075
+ * @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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1076
+ * @param {*} [options] Override http request option.
1077
+ * @throws {RequiredError}
1078
+ */
1079
+ listAllActionVersions(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListActionVersionsResponseClass> {
1080
+ return localVarFp.listAllActionVersions(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
1081
+ },
1082
+ /**
1083
+ * 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\"
1084
+ * @summary Create the actionExecution
1085
+ * @param {TriggerActionRequestDto} triggerActionRequestDto
1086
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1087
+ * @param {*} [options] Override http request option.
1088
+ * @throws {RequiredError}
1089
+ */
1090
+ triggerAction(triggerActionRequestDto: TriggerActionRequestDto, authorization?: string, options?: any): AxiosPromise<TriggerActionResponseClass> {
1091
+ return localVarFp.triggerAction(triggerActionRequestDto, authorization, options).then((request) => request(axios, basePath));
1092
+ },
1093
+ /**
1094
+ * Updates an existing action configuration (patch semantics) **Required Permissions** \"action-management.actions.update\"
1095
+ * @summary Update the action
1096
+ * @param {string} code Action code
1097
+ * @param {UpdateActionRequestDto} updateActionRequestDto
1098
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1099
+ * @param {*} [options] Override http request option.
1100
+ * @throws {RequiredError}
1101
+ */
1102
+ updateAction(code: string, updateActionRequestDto: UpdateActionRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateActionResponseClass> {
1103
+ return localVarFp.updateAction(code, updateActionRequestDto, authorization, options).then((request) => request(axios, basePath));
1104
+ },
1105
+ };
1106
+ };
1107
+
1108
+ /**
1109
+ * Request parameters for createAction operation in ActionClientApi.
1110
+ * @export
1111
+ * @interface ActionClientApiCreateActionRequest
1112
+ */
1113
+ export interface ActionClientApiCreateActionRequest {
1114
+ /**
1115
+ *
1116
+ * @type {CreateActionRequestDto}
1117
+ * @memberof ActionClientApiCreateAction
1118
+ */
1119
+ readonly createActionRequestDto: CreateActionRequestDto
1120
+
1121
+ /**
1122
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1123
+ * @type {string}
1124
+ * @memberof ActionClientApiCreateAction
1125
+ */
1126
+ readonly authorization?: string
1127
+ }
1128
+
1129
+ /**
1130
+ * Request parameters for deleteAction operation in ActionClientApi.
1131
+ * @export
1132
+ * @interface ActionClientApiDeleteActionRequest
1133
+ */
1134
+ export interface ActionClientApiDeleteActionRequest {
1135
+ /**
1136
+ * Action code
1137
+ * @type {string}
1138
+ * @memberof ActionClientApiDeleteAction
1139
+ */
1140
+ readonly code: string
1141
+
1142
+ /**
1143
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1144
+ * @type {string}
1145
+ * @memberof ActionClientApiDeleteAction
1146
+ */
1147
+ readonly authorization?: string
1148
+ }
1149
+
1150
+ /**
1151
+ * Request parameters for deleteActionVersion operation in ActionClientApi.
1152
+ * @export
1153
+ * @interface ActionClientApiDeleteActionVersionRequest
1154
+ */
1155
+ export interface ActionClientApiDeleteActionVersionRequest {
1156
+ /**
1157
+ * Version code (e.g. acv_&lt;nanoid&gt;)
1158
+ * @type {string}
1159
+ * @memberof ActionClientApiDeleteActionVersion
1160
+ */
1161
+ readonly versionCode: string
1162
+
1163
+ /**
1164
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1165
+ * @type {string}
1166
+ * @memberof ActionClientApiDeleteActionVersion
1167
+ */
1168
+ readonly authorization?: string
1169
+ }
1170
+
1171
+ /**
1172
+ * Request parameters for getAction operation in ActionClientApi.
1173
+ * @export
1174
+ * @interface ActionClientApiGetActionRequest
1175
+ */
1176
+ export interface ActionClientApiGetActionRequest {
1177
+ /**
1178
+ * Action code
1179
+ * @type {string}
1180
+ * @memberof ActionClientApiGetAction
1181
+ */
1182
+ readonly code: string
1183
+
1184
+ /**
1185
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1186
+ * @type {string}
1187
+ * @memberof ActionClientApiGetAction
1188
+ */
1189
+ readonly authorization?: string
1190
+
1191
+ /**
1192
+ * Expand to fetch additional information (e.g. inputValidationSchema)
1193
+ * @type {string}
1194
+ * @memberof ActionClientApiGetAction
1195
+ */
1196
+ readonly expand?: string
1197
+ }
1198
+
1199
+ /**
1200
+ * Request parameters for getActionExecutionStatus operation in ActionClientApi.
1201
+ * @export
1202
+ * @interface ActionClientApiGetActionExecutionStatusRequest
1203
+ */
1204
+ export interface ActionClientApiGetActionExecutionStatusRequest {
1205
+ /**
1206
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1207
+ * @type {string}
1208
+ * @memberof ActionClientApiGetActionExecutionStatus
1209
+ */
1210
+ readonly authorization?: string
1211
+
1212
+ /**
1213
+ * Action execution code
1214
+ * @type {string}
1215
+ * @memberof ActionClientApiGetActionExecutionStatus
1216
+ */
1217
+ readonly executionCode?: string
1218
+
1219
+ /**
1220
+ * Correlation ID (e.g. webhook execution code that triggered this action execution)
1221
+ * @type {string}
1222
+ * @memberof ActionClientApiGetActionExecutionStatus
1223
+ */
1224
+ readonly correlationId?: string
1225
+ }
1226
+
1227
+ /**
1228
+ * Request parameters for getActionVersion operation in ActionClientApi.
1229
+ * @export
1230
+ * @interface ActionClientApiGetActionVersionRequest
1231
+ */
1232
+ export interface ActionClientApiGetActionVersionRequest {
1233
+ /**
1234
+ * Version code (e.g. acv_&lt;nanoid&gt;)
1235
+ * @type {string}
1236
+ * @memberof ActionClientApiGetActionVersion
1237
+ */
1238
+ readonly versionCode: string
1239
+
1240
+ /**
1241
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1242
+ * @type {string}
1243
+ * @memberof ActionClientApiGetActionVersion
1244
+ */
1245
+ readonly authorization?: string
1246
+
1247
+ /**
1248
+ *
1249
+ * @type {string}
1250
+ * @memberof ActionClientApiGetActionVersion
1251
+ */
1252
+ readonly expand?: string
1253
+ }
1254
+
1255
+ /**
1256
+ * Request parameters for listActionExecutions operation in ActionClientApi.
1257
+ * @export
1258
+ * @interface ActionClientApiListActionExecutionsRequest
1259
+ */
1260
+ export interface ActionClientApiListActionExecutionsRequest {
1261
+ /**
1262
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1263
+ * @type {string}
1264
+ * @memberof ActionClientApiListActionExecutions
1265
+ */
1266
+ readonly authorization?: string
1267
+
1268
+ /**
1269
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1270
+ * @type {number}
1271
+ * @memberof ActionClientApiListActionExecutions
1272
+ */
1273
+ readonly pageSize?: number
1274
+
1275
+ /**
1276
+ * 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.
1277
+ * @type {string}
1278
+ * @memberof ActionClientApiListActionExecutions
1279
+ */
1280
+ readonly pageToken?: string
1281
+
1282
+ /**
1283
+ * 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;
1284
+ * @type {string}
1285
+ * @memberof ActionClientApiListActionExecutions
1286
+ */
1287
+ readonly filter?: string
1288
+
1289
+ /**
1290
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
1291
+ * @type {string}
1292
+ * @memberof ActionClientApiListActionExecutions
1293
+ */
1294
+ readonly search?: string
1295
+
1296
+ /**
1297
+ * 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;
1298
+ * @type {string}
1299
+ * @memberof ActionClientApiListActionExecutions
1300
+ */
1301
+ readonly order?: string
1302
+
1303
+ /**
1304
+ * 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;
1305
+ * @type {string}
1306
+ * @memberof ActionClientApiListActionExecutions
1307
+ */
1308
+ readonly expand?: string
1309
+
1310
+ /**
1311
+ * 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;
1312
+ * @type {string}
1313
+ * @memberof ActionClientApiListActionExecutions
1314
+ */
1315
+ readonly filters?: string
1316
+ }
1317
+
1318
+ /**
1319
+ * Request parameters for listActionVersions operation in ActionClientApi.
1320
+ * @export
1321
+ * @interface ActionClientApiListActionVersionsRequest
1322
+ */
1323
+ export interface ActionClientApiListActionVersionsRequest {
1324
+ /**
1325
+ * Action code
1326
+ * @type {string}
1327
+ * @memberof ActionClientApiListActionVersions
1328
+ */
1329
+ readonly code: string
1330
+
1331
+ /**
1332
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1333
+ * @type {string}
1334
+ * @memberof ActionClientApiListActionVersions
1335
+ */
1336
+ readonly authorization?: string
1337
+
1338
+ /**
1339
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1340
+ * @type {number}
1341
+ * @memberof ActionClientApiListActionVersions
1342
+ */
1343
+ readonly pageSize?: number
1344
+
1345
+ /**
1346
+ * 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.
1347
+ * @type {string}
1348
+ * @memberof ActionClientApiListActionVersions
1349
+ */
1350
+ readonly pageToken?: string
1351
+
1352
+ /**
1353
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1354
+ * @type {string}
1355
+ * @memberof ActionClientApiListActionVersions
1356
+ */
1357
+ readonly filter?: string
1358
+
1359
+ /**
1360
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
1361
+ * @type {string}
1362
+ * @memberof ActionClientApiListActionVersions
1363
+ */
1364
+ readonly search?: string
1365
+
1366
+ /**
1367
+ * 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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1368
+ * @type {string}
1369
+ * @memberof ActionClientApiListActionVersions
1370
+ */
1371
+ readonly order?: string
1372
+
1373
+ /**
1374
+ * 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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1375
+ * @type {string}
1376
+ * @memberof ActionClientApiListActionVersions
1377
+ */
1378
+ readonly expand?: string
1379
+
1380
+ /**
1381
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1382
+ * @type {string}
1383
+ * @memberof ActionClientApiListActionVersions
1384
+ */
1385
+ readonly filters?: string
1386
+ }
1387
+
1388
+ /**
1389
+ * Request parameters for listActions operation in ActionClientApi.
1390
+ * @export
1391
+ * @interface ActionClientApiListActionsRequest
1392
+ */
1393
+ export interface ActionClientApiListActionsRequest {
1394
+ /**
1395
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1396
+ * @type {string}
1397
+ * @memberof ActionClientApiListActions
1398
+ */
1399
+ readonly authorization?: string
1400
+
1401
+ /**
1402
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1403
+ * @type {number}
1404
+ * @memberof ActionClientApiListActions
1405
+ */
1406
+ readonly pageSize?: number
1407
+
1408
+ /**
1409
+ * 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.
1410
+ * @type {string}
1411
+ * @memberof ActionClientApiListActions
1412
+ */
1413
+ readonly pageToken?: string
1414
+
1415
+ /**
1416
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1417
+ * @type {string}
1418
+ * @memberof ActionClientApiListActions
1419
+ */
1420
+ readonly filter?: string
1421
+
1422
+ /**
1423
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
1424
+ * @type {string}
1425
+ * @memberof ActionClientApiListActions
1426
+ */
1427
+ readonly search?: string
1428
+
1429
+ /**
1430
+ * 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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1431
+ * @type {string}
1432
+ * @memberof ActionClientApiListActions
1433
+ */
1434
+ readonly order?: string
1435
+
1436
+ /**
1437
+ * 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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1438
+ * @type {string}
1439
+ * @memberof ActionClientApiListActions
1440
+ */
1441
+ readonly expand?: string
1442
+
1443
+ /**
1444
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1445
+ * @type {string}
1446
+ * @memberof ActionClientApiListActions
1447
+ */
1448
+ readonly filters?: string
1449
+ }
1450
+
1451
+ /**
1452
+ * Request parameters for listAllActionVersions operation in ActionClientApi.
1453
+ * @export
1454
+ * @interface ActionClientApiListAllActionVersionsRequest
1455
+ */
1456
+ export interface ActionClientApiListAllActionVersionsRequest {
1457
+ /**
1458
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1459
+ * @type {string}
1460
+ * @memberof ActionClientApiListAllActionVersions
1461
+ */
1462
+ readonly authorization?: string
1463
+
1464
+ /**
1465
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1466
+ * @type {number}
1467
+ * @memberof ActionClientApiListAllActionVersions
1468
+ */
1469
+ readonly pageSize?: number
1470
+
1471
+ /**
1472
+ * 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.
1473
+ * @type {string}
1474
+ * @memberof ActionClientApiListAllActionVersions
1475
+ */
1476
+ readonly pageToken?: string
1477
+
1478
+ /**
1479
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1480
+ * @type {string}
1481
+ * @memberof ActionClientApiListAllActionVersions
1482
+ */
1483
+ readonly filter?: string
1484
+
1485
+ /**
1486
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
1487
+ * @type {string}
1488
+ * @memberof ActionClientApiListAllActionVersions
1489
+ */
1490
+ readonly search?: string
1491
+
1492
+ /**
1493
+ * 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, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, createdAt, updatedAt, createdBy, updatedBy, owner&lt;/i&gt;
1494
+ * @type {string}
1495
+ * @memberof ActionClientApiListAllActionVersions
1496
+ */
1497
+ readonly order?: string
1498
+
1499
+ /**
1500
+ * 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; &lt;i&gt;Allowed values: inputValidationSchema&lt;i&gt;
1501
+ * @type {string}
1502
+ * @memberof ActionClientApiListAllActionVersions
1503
+ */
1504
+ readonly expand?: string
1505
+
1506
+ /**
1507
+ * 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, actionConfigId, code, versionNumber, isActive, isAvailableInUi, workflowCode, workflowSlug, entityType, productVersionId, productSlug, owner, createdAt, updatedAt, createdBy, updatedBy, name, slug&lt;/i&gt;
1508
+ * @type {string}
1509
+ * @memberof ActionClientApiListAllActionVersions
1510
+ */
1511
+ readonly filters?: string
1512
+ }
1513
+
1514
+ /**
1515
+ * Request parameters for triggerAction operation in ActionClientApi.
1516
+ * @export
1517
+ * @interface ActionClientApiTriggerActionRequest
1518
+ */
1519
+ export interface ActionClientApiTriggerActionRequest {
1520
+ /**
1521
+ *
1522
+ * @type {TriggerActionRequestDto}
1523
+ * @memberof ActionClientApiTriggerAction
1524
+ */
1525
+ readonly triggerActionRequestDto: TriggerActionRequestDto
1526
+
1527
+ /**
1528
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1529
+ * @type {string}
1530
+ * @memberof ActionClientApiTriggerAction
1531
+ */
1532
+ readonly authorization?: string
1533
+ }
1534
+
1535
+ /**
1536
+ * Request parameters for updateAction operation in ActionClientApi.
1537
+ * @export
1538
+ * @interface ActionClientApiUpdateActionRequest
1539
+ */
1540
+ export interface ActionClientApiUpdateActionRequest {
1541
+ /**
1542
+ * Action code
1543
+ * @type {string}
1544
+ * @memberof ActionClientApiUpdateAction
1545
+ */
1546
+ readonly code: string
1547
+
1548
+ /**
1549
+ *
1550
+ * @type {UpdateActionRequestDto}
1551
+ * @memberof ActionClientApiUpdateAction
1552
+ */
1553
+ readonly updateActionRequestDto: UpdateActionRequestDto
1554
+
1555
+ /**
1556
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1557
+ * @type {string}
1558
+ * @memberof ActionClientApiUpdateAction
1559
+ */
1560
+ readonly authorization?: string
1561
+ }
1562
+
1563
+ /**
1564
+ * ActionClientApi - object-oriented interface
1565
+ * @export
1566
+ * @class ActionClientApi
1567
+ * @extends {BaseAPI}
1568
+ */
1569
+ export class ActionClientApi extends BaseAPI {
1570
+ /**
1571
+ * Creates a new action configuration **Required Permissions** \"action-management.actions.create\"
1572
+ * @summary Create the action
1573
+ * @param {ActionClientApiCreateActionRequest} requestParameters Request parameters.
1574
+ * @param {*} [options] Override http request option.
1575
+ * @throws {RequiredError}
1576
+ * @memberof ActionClientApi
1577
+ */
1578
+ public createAction(requestParameters: ActionClientApiCreateActionRequest, options?: AxiosRequestConfig) {
1579
+ return ActionClientApiFp(this.configuration).createAction(requestParameters.createActionRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
1580
+ }
1581
+
1582
+ /**
1583
+ * Deletes an action configuration by its code **Required Permissions** \"action-management.actions.delete\"
1584
+ * @summary Delete the action
1585
+ * @param {ActionClientApiDeleteActionRequest} requestParameters Request parameters.
1586
+ * @param {*} [options] Override http request option.
1587
+ * @throws {RequiredError}
1588
+ * @memberof ActionClientApi
1589
+ */
1590
+ public deleteAction(requestParameters: ActionClientApiDeleteActionRequest, options?: AxiosRequestConfig) {
1591
+ return ActionClientApiFp(this.configuration).deleteAction(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
1592
+ }
1593
+
1594
+ /**
1595
+ * Deletes a specific action version by its version code **Required Permissions** \"action-management.actions.delete\"
1596
+ * @summary Delete the action version
1597
+ * @param {ActionClientApiDeleteActionVersionRequest} requestParameters Request parameters.
1598
+ * @param {*} [options] Override http request option.
1599
+ * @throws {RequiredError}
1600
+ * @memberof ActionClientApi
1601
+ */
1602
+ public deleteActionVersion(requestParameters: ActionClientApiDeleteActionVersionRequest, options?: AxiosRequestConfig) {
1603
+ return ActionClientApiFp(this.configuration).deleteActionVersion(requestParameters.versionCode, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
1604
+ }
1605
+
1606
+ /**
1607
+ * Retrieves an action configuration by its code **Required Permissions** \"action-management.actions.view\"
1608
+ * @summary Retrieve the action
1609
+ * @param {ActionClientApiGetActionRequest} requestParameters Request parameters.
1610
+ * @param {*} [options] Override http request option.
1611
+ * @throws {RequiredError}
1612
+ * @memberof ActionClientApi
1613
+ */
1614
+ public getAction(requestParameters: ActionClientApiGetActionRequest, options?: AxiosRequestConfig) {
1615
+ return ActionClientApiFp(this.configuration).getAction(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
1616
+ }
1617
+
1618
+ /**
1619
+ * Retrieves the latest action execution status by executionCode or correlationId **Required Permissions** \"action-management.actions.view\"
1620
+ * @summary Retrieve the actionExecution
1621
+ * @param {ActionClientApiGetActionExecutionStatusRequest} requestParameters Request parameters.
1622
+ * @param {*} [options] Override http request option.
1623
+ * @throws {RequiredError}
1624
+ * @memberof ActionClientApi
1625
+ */
1626
+ public getActionExecutionStatus(requestParameters: ActionClientApiGetActionExecutionStatusRequest = {}, options?: AxiosRequestConfig) {
1627
+ return ActionClientApiFp(this.configuration).getActionExecutionStatus(requestParameters.authorization, requestParameters.executionCode, requestParameters.correlationId, options).then((request) => request(this.axios, this.basePath));
1628
+ }
1629
+
1630
+ /**
1631
+ * Gets a specific action version by its version code **Required Permissions** \"action-management.actions.view\"
1632
+ * @summary Retrieve the action version
1633
+ * @param {ActionClientApiGetActionVersionRequest} requestParameters Request parameters.
1634
+ * @param {*} [options] Override http request option.
1635
+ * @throws {RequiredError}
1636
+ * @memberof ActionClientApi
1637
+ */
1638
+ public getActionVersion(requestParameters: ActionClientApiGetActionVersionRequest, options?: AxiosRequestConfig) {
1639
+ return ActionClientApiFp(this.configuration).getActionVersion(requestParameters.versionCode, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
1640
+ }
1641
+
1642
+ /**
1643
+ * Lists action executions (latest status per execution only) with optional filters **Required Permissions** \"action-management.actions.view\"
1644
+ * @summary List actionExecutions
1645
+ * @param {ActionClientApiListActionExecutionsRequest} requestParameters Request parameters.
1646
+ * @param {*} [options] Override http request option.
1647
+ * @throws {RequiredError}
1648
+ * @memberof ActionClientApi
1649
+ */
1650
+ public listActionExecutions(requestParameters: ActionClientApiListActionExecutionsRequest = {}, options?: AxiosRequestConfig) {
1651
+ return ActionClientApiFp(this.configuration).listActionExecutions(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
1652
+ }
1653
+
1654
+ /**
1655
+ * Lists all versions for an action by code **Required Permissions** \"action-management.actions.view\"
1656
+ * @summary List action versions
1657
+ * @param {ActionClientApiListActionVersionsRequest} requestParameters Request parameters.
1658
+ * @param {*} [options] Override http request option.
1659
+ * @throws {RequiredError}
1660
+ * @memberof ActionClientApi
1661
+ */
1662
+ public listActionVersions(requestParameters: ActionClientApiListActionVersionsRequest, options?: AxiosRequestConfig) {
1663
+ return ActionClientApiFp(this.configuration).listActionVersions(requestParameters.code, requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
1664
+ }
1665
+
1666
+ /**
1667
+ * Lists all action configurations with optional filters **Required Permissions** \"action-management.actions.view\"
1668
+ * @summary List actions
1669
+ * @param {ActionClientApiListActionsRequest} requestParameters Request parameters.
1670
+ * @param {*} [options] Override http request option.
1671
+ * @throws {RequiredError}
1672
+ * @memberof ActionClientApi
1673
+ */
1674
+ public listActions(requestParameters: ActionClientApiListActionsRequest = {}, options?: AxiosRequestConfig) {
1675
+ return ActionClientApiFp(this.configuration).listActions(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
1676
+ }
1677
+
1678
+ /**
1679
+ * Lists all action versions. Use filters e.g. isActive==true, entityType==LEAD, name, slug. No parent action code required. **Required Permissions** \"action-management.actions.view\"
1680
+ * @summary List action versions
1681
+ * @param {ActionClientApiListAllActionVersionsRequest} requestParameters Request parameters.
1682
+ * @param {*} [options] Override http request option.
1683
+ * @throws {RequiredError}
1684
+ * @memberof ActionClientApi
1685
+ */
1686
+ public listAllActionVersions(requestParameters: ActionClientApiListAllActionVersionsRequest = {}, options?: AxiosRequestConfig) {
1687
+ return ActionClientApiFp(this.configuration).listAllActionVersions(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
1688
+ }
1689
+
1690
+ /**
1691
+ * 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\"
1692
+ * @summary Create the actionExecution
1693
+ * @param {ActionClientApiTriggerActionRequest} requestParameters Request parameters.
1694
+ * @param {*} [options] Override http request option.
1695
+ * @throws {RequiredError}
1696
+ * @memberof ActionClientApi
1697
+ */
1698
+ public triggerAction(requestParameters: ActionClientApiTriggerActionRequest, options?: AxiosRequestConfig) {
1699
+ return ActionClientApiFp(this.configuration).triggerAction(requestParameters.triggerActionRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
1700
+ }
1701
+
1702
+ /**
1703
+ * Updates an existing action configuration (patch semantics) **Required Permissions** \"action-management.actions.update\"
1704
+ * @summary Update the action
1705
+ * @param {ActionClientApiUpdateActionRequest} requestParameters Request parameters.
1706
+ * @param {*} [options] Override http request option.
1707
+ * @throws {RequiredError}
1708
+ * @memberof ActionClientApi
1709
+ */
1710
+ public updateAction(requestParameters: ActionClientApiUpdateActionRequest, options?: AxiosRequestConfig) {
1711
+ return ActionClientApiFp(this.configuration).updateAction(requestParameters.code, requestParameters.updateActionRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
1712
+ }
1713
+ }