@membranehq/sdk 0.4.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/dist/bundle.d.ts +8370 -1268
  2. package/dist/bundle.js +2216 -2085
  3. package/dist/bundle.js.map +1 -1
  4. package/dist/dts/accessors/connections-accessors.d.ts +57 -1
  5. package/dist/dts/accessors/integrations-accessors.d.ts +57 -1
  6. package/dist/dts/api-client.d.ts +1 -0
  7. package/dist/dts/client.d.ts +1 -0
  8. package/dist/dts/data-schema/types.d.ts +4 -3
  9. package/dist/dts/entity-repository.d.ts +87 -20
  10. package/dist/dts/formulas/dataSchemaRef.d.ts +2 -2
  11. package/dist/dts/http-requests.d.ts +20 -6
  12. package/dist/dts/iframe.d.ts +12 -4
  13. package/dist/dts/index.d.ts +2 -1
  14. package/dist/dts/sse/index.d.ts +1 -0
  15. package/dist/dts/sse/workspace-elements.d.ts +9 -0
  16. package/dist/dts/workspace-elements/api/actions-api.d.ts +702 -40
  17. package/dist/dts/workspace-elements/api/connections-api.d.ts +702 -41
  18. package/dist/dts/workspace-elements/api/customers-api.d.ts +56 -13
  19. package/dist/dts/workspace-elements/api/data-sources-api.d.ts +834 -77
  20. package/dist/dts/workspace-elements/api/external-events-api.d.ts +440 -6
  21. package/dist/dts/workspace-elements/api/field-mappings-api.d.ts +586 -6
  22. package/dist/dts/workspace-elements/api/flow-runs-api.d.ts +1 -1
  23. package/dist/dts/workspace-elements/api/flows-api.d.ts +2417 -50
  24. package/dist/dts/workspace-elements/api/integrations-api.d.ts +253 -24
  25. package/dist/dts/workspace-elements/api/scenarios-api.d.ts +397 -34
  26. package/dist/dts/workspace-elements/api/screens-api.d.ts +2 -2
  27. package/dist/dts/workspace-elements/base/action-instances/types.d.ts +61 -14
  28. package/dist/dts/workspace-elements/base/action-run-log-records/types.d.ts +30 -7
  29. package/dist/dts/workspace-elements/base/actions/types.d.ts +60 -17
  30. package/dist/dts/workspace-elements/base/app-data-schema-instances/types.d.ts +42 -7
  31. package/dist/dts/workspace-elements/base/app-data-schemas/types.d.ts +35 -7
  32. package/dist/dts/workspace-elements/base/app-event-subscriptions/types.d.ts +78 -9
  33. package/dist/dts/workspace-elements/base/app-event-types/types.d.ts +70 -7
  34. package/dist/dts/workspace-elements/base/connections/types.d.ts +76 -20
  35. package/dist/dts/workspace-elements/base/connectors/types.d.ts +14 -2
  36. package/dist/dts/workspace-elements/base/customers/index.d.ts +26 -6
  37. package/dist/dts/workspace-elements/base/data-collections/schemas.d.ts +75 -74
  38. package/dist/dts/workspace-elements/base/data-link-table-instances/types.d.ts +61 -11
  39. package/dist/dts/workspace-elements/base/data-link-tables/types.d.ts +26 -4
  40. package/dist/dts/workspace-elements/base/data-source-instances/types.d.ts +1030 -19
  41. package/dist/dts/workspace-elements/base/data-sources/types.d.ts +89 -22
  42. package/dist/dts/workspace-elements/base/external-event-log-records/types.d.ts +31 -8
  43. package/dist/dts/workspace-elements/base/external-event-pulls/types.d.ts +35 -8
  44. package/dist/dts/workspace-elements/base/external-event-subscriptions/types.d.ts +199 -23
  45. package/dist/dts/workspace-elements/base/external-events/types.d.ts +145 -5
  46. package/dist/dts/workspace-elements/base/field-mapping-instances/types.d.ts +74 -16
  47. package/dist/dts/workspace-elements/base/field-mappings/types.d.ts +91 -14
  48. package/dist/dts/workspace-elements/base/flow-instances/schemas.d.ts +39 -39
  49. package/dist/dts/workspace-elements/base/flow-instances/types.d.ts +155 -24
  50. package/dist/dts/workspace-elements/base/flow-runs/flow-node-runs.d.ts +20 -20
  51. package/dist/dts/workspace-elements/base/flow-runs/types.d.ts +114 -19
  52. package/dist/dts/workspace-elements/base/flows/types.d.ts +220 -26
  53. package/dist/dts/workspace-elements/base/integrations/types.d.ts +497 -24
  54. package/dist/dts/workspace-elements/base/scenarios/types.d.ts +723 -23
  55. package/dist/dts/workspace-elements/base/screens/types.d.ts +40 -6
  56. package/dist/index.d.ts +12141 -2138
  57. package/dist/index.js +1555 -522
  58. package/dist/index.js.map +1 -1
  59. package/dist/index.module.d.mts +12141 -2138
  60. package/dist/index.module.mjs +1414 -490
  61. package/dist/index.module.mjs.map +1 -1
  62. package/package.json +1 -1
@@ -1,3 +1,4 @@
1
+ import { z } from 'zod';
1
2
  import { CreateActionRequest } from './actions-api';
2
3
  import { CreateAppDataSchemaRequest } from './app-data-schemas-api';
3
4
  import { CreateAppEventTypeRequest } from './app-event-types-api';
@@ -7,39 +8,163 @@ import { CreateFieldMappingRequest } from './field-mappings-api';
7
8
  import { CreateFlowRequest } from './flows-api';
8
9
  import { SearchQuery, PaginationQuery } from '../../entity-repository';
9
10
  import { IntegrationElementType } from '../../integration-elements';
10
- import { BaseIntegration } from '../base/integrations';
11
- import { BaseScenario } from '../base/scenarios';
12
- export declare enum ScenarioTemplateCategory {
13
- DataExport = "data-export",
14
- DataImport = "data-import",
15
- BiDirectionalSync = "bi-directional-sync",
16
- UnifiedApi = "unified-api",
17
- DataEnrichment = "data-enrichment"
18
- }
19
- export type ScenarioToDo = {
11
+ export declare const ScenarioToDoApi: z.ZodObject<{
12
+ name: z.ZodString;
13
+ description: z.ZodString;
14
+ isComplete: z.ZodBoolean;
15
+ }, "strip", z.ZodTypeAny, {
20
16
  name: string;
21
17
  description: string;
22
18
  isComplete: boolean;
23
- };
24
- export type ScenarioElement = {
19
+ }, {
20
+ name: string;
21
+ description: string;
22
+ isComplete: boolean;
23
+ }>;
24
+ export type ScenarioToDoApi = z.infer<typeof ScenarioToDoApi>;
25
+ export declare const ScenarioElementApi: z.ZodObject<{
26
+ id: z.ZodString;
27
+ type: z.ZodNativeEnum<typeof IntegrationElementType>;
28
+ element: z.ZodOptional<z.ZodAny>;
29
+ }, "strip", z.ZodTypeAny, {
30
+ type: IntegrationElementType;
25
31
  id: string;
32
+ element?: any;
33
+ }, {
26
34
  type: IntegrationElementType;
35
+ id: string;
27
36
  element?: any;
28
- };
29
- export interface FindScenariosQuery extends SearchQuery, PaginationQuery {
30
- }
31
- export interface CreateScenarioRequest {
37
+ }>;
38
+ export type ScenarioElementApi = z.infer<typeof ScenarioElementApi>;
39
+ export declare const FindScenariosQuery: z.ZodObject<{
40
+ search: z.ZodOptional<z.ZodString>;
41
+ } & {
42
+ limit: z.ZodOptional<z.ZodNumber>;
43
+ cursor: z.ZodOptional<z.ZodString>;
44
+ }, "strip", z.ZodTypeAny, {
45
+ search?: string | undefined;
46
+ limit?: number | undefined;
47
+ cursor?: string | undefined;
48
+ }, {
49
+ search?: string | undefined;
50
+ limit?: number | undefined;
51
+ cursor?: string | undefined;
52
+ }>;
53
+ export type FindScenariosQuery = z.infer<typeof FindScenariosQuery>;
54
+ export declare const CreateScenarioRequest: z.ZodObject<{
55
+ name: z.ZodString;
56
+ key: z.ZodString;
57
+ elements: z.ZodOptional<z.ZodArray<z.ZodObject<{
58
+ id: z.ZodString;
59
+ type: z.ZodNativeEnum<typeof IntegrationElementType>;
60
+ element: z.ZodOptional<z.ZodAny>;
61
+ }, "strip", z.ZodTypeAny, {
62
+ type: IntegrationElementType;
63
+ id: string;
64
+ element?: any;
65
+ }, {
66
+ type: IntegrationElementType;
67
+ id: string;
68
+ element?: any;
69
+ }>, "many">>;
70
+ todos: z.ZodOptional<z.ZodArray<z.ZodObject<{
71
+ name: z.ZodString;
72
+ description: z.ZodString;
73
+ isComplete: z.ZodBoolean;
74
+ }, "strip", z.ZodTypeAny, {
75
+ name: string;
76
+ description: string;
77
+ isComplete: boolean;
78
+ }, {
79
+ name: string;
80
+ description: string;
81
+ isComplete: boolean;
82
+ }>, "many">>;
83
+ }, "strip", z.ZodTypeAny, {
84
+ key: string;
32
85
  name: string;
86
+ elements?: {
87
+ type: IntegrationElementType;
88
+ id: string;
89
+ element?: any;
90
+ }[] | undefined;
91
+ todos?: {
92
+ name: string;
93
+ description: string;
94
+ isComplete: boolean;
95
+ }[] | undefined;
96
+ }, {
33
97
  key: string;
34
- elements?: ScenarioElement[];
35
- todos?: ScenarioToDo[];
36
- }
37
- export interface UpdateScenarioRequest {
38
- name?: string;
39
- key?: string;
40
- elements?: ScenarioElement[];
41
- todos?: ScenarioToDo[];
42
- }
98
+ name: string;
99
+ elements?: {
100
+ type: IntegrationElementType;
101
+ id: string;
102
+ element?: any;
103
+ }[] | undefined;
104
+ todos?: {
105
+ name: string;
106
+ description: string;
107
+ isComplete: boolean;
108
+ }[] | undefined;
109
+ }>;
110
+ export type CreateScenarioRequest = z.infer<typeof CreateScenarioRequest>;
111
+ export declare const UpdateScenarioRequest: z.ZodObject<{
112
+ name: z.ZodOptional<z.ZodString>;
113
+ key: z.ZodOptional<z.ZodString>;
114
+ elements: z.ZodOptional<z.ZodArray<z.ZodObject<{
115
+ id: z.ZodString;
116
+ type: z.ZodNativeEnum<typeof IntegrationElementType>;
117
+ element: z.ZodOptional<z.ZodAny>;
118
+ }, "strip", z.ZodTypeAny, {
119
+ type: IntegrationElementType;
120
+ id: string;
121
+ element?: any;
122
+ }, {
123
+ type: IntegrationElementType;
124
+ id: string;
125
+ element?: any;
126
+ }>, "many">>;
127
+ todos: z.ZodOptional<z.ZodArray<z.ZodObject<{
128
+ name: z.ZodString;
129
+ description: z.ZodString;
130
+ isComplete: z.ZodBoolean;
131
+ }, "strip", z.ZodTypeAny, {
132
+ name: string;
133
+ description: string;
134
+ isComplete: boolean;
135
+ }, {
136
+ name: string;
137
+ description: string;
138
+ isComplete: boolean;
139
+ }>, "many">>;
140
+ }, "strip", z.ZodTypeAny, {
141
+ key?: string | undefined;
142
+ name?: string | undefined;
143
+ elements?: {
144
+ type: IntegrationElementType;
145
+ id: string;
146
+ element?: any;
147
+ }[] | undefined;
148
+ todos?: {
149
+ name: string;
150
+ description: string;
151
+ isComplete: boolean;
152
+ }[] | undefined;
153
+ }, {
154
+ key?: string | undefined;
155
+ name?: string | undefined;
156
+ elements?: {
157
+ type: IntegrationElementType;
158
+ id: string;
159
+ element?: any;
160
+ }[] | undefined;
161
+ todos?: {
162
+ name: string;
163
+ description: string;
164
+ isComplete: boolean;
165
+ }[] | undefined;
166
+ }>;
167
+ export type UpdateScenarioRequest = z.infer<typeof UpdateScenarioRequest>;
43
168
  export interface FindScenarioTemplatesQuery extends SearchQuery, PaginationQuery {
44
169
  }
45
170
  export interface CreateScenarioTemplateRequest {
@@ -51,8 +176,8 @@ export interface CreateScenarioTemplateRequest {
51
176
  demoGithubRepo?: string;
52
177
  demoVideoYoutubeUri?: string;
53
178
  tags?: string[];
54
- elements?: ScenarioTemplateElements;
55
- todos?: Omit<ScenarioToDo, 'isComplete'>[];
179
+ elements?: ScenarioTemplateElementsApi;
180
+ todos?: Omit<ScenarioToDoApi, 'isComplete'>[];
56
181
  }
57
182
  export interface UpdateScenarioTemplateRequest {
58
183
  name?: string;
@@ -64,8 +189,8 @@ export interface UpdateScenarioTemplateRequest {
64
189
  demoGithubRepo?: string;
65
190
  demoVideoYoutubeUri?: string;
66
191
  tags?: string[];
67
- elements?: ScenarioTemplateElements;
68
- todos?: Omit<ScenarioToDo, 'isComplete'>[];
192
+ elements?: ScenarioTemplateElementsApi;
193
+ todos?: Omit<ScenarioToDoApi, 'isComplete'>[];
69
194
  }
70
195
  export type ScenarioTemplateElementOverride = {
71
196
  type: IntegrationElementType;
@@ -96,12 +221,12 @@ type ElementsExportFields = {
96
221
  appEventTypes?: Record<string, CreateAppEventTypeRequest>;
97
222
  appDataSchemas?: Record<string, CreateAppDataSchemaRequest>;
98
223
  };
99
- export type ScenarioTemplateElements = ElementsExportFields & {
224
+ export type ScenarioTemplateElementsApi = ElementsExportFields & {
100
225
  integrations?: Record<string, ElementsExportFields & {
101
226
  connectorId: string;
102
227
  }>;
103
228
  };
104
- export interface HandyScenarioTemplateElement {
229
+ export interface HandyScenarioTemplateElementApi {
105
230
  type: IntegrationElementType;
106
231
  integration?: {
107
232
  key: string;
@@ -116,8 +241,246 @@ export interface HandyScenarioTemplateElement {
116
241
  name: string;
117
242
  } & Record<string, any>;
118
243
  }
119
- export interface Scenario extends BaseScenario {
120
- appliedToIntegrations?: BaseIntegration[];
121
- }
244
+ export declare const Scenario: z.ZodObject<{
245
+ id: z.ZodString;
246
+ name: z.ZodString;
247
+ } & {
248
+ key: z.ZodString;
249
+ state: z.ZodOptional<z.ZodNativeEnum<typeof import("..").WorkspaceElementState>>;
250
+ errors: z.ZodOptional<z.ZodArray<any, "many">>;
251
+ } & {
252
+ appId: z.ZodString;
253
+ scenarioTemplateId: z.ZodOptional<z.ZodString>;
254
+ elements: z.ZodOptional<z.ZodArray<z.ZodObject<{
255
+ id: z.ZodString;
256
+ type: z.ZodString;
257
+ element: z.ZodOptional<z.ZodAny>;
258
+ }, "strip", z.ZodTypeAny, {
259
+ type: string;
260
+ id: string;
261
+ element?: any;
262
+ }, {
263
+ type: string;
264
+ id: string;
265
+ element?: any;
266
+ }>, "many">>;
267
+ connectors: z.ZodOptional<z.ZodArray<z.ZodObject<{
268
+ id: z.ZodString;
269
+ key: z.ZodString;
270
+ name: z.ZodString;
271
+ logoUri: z.ZodString;
272
+ }, "strip", z.ZodTypeAny, {
273
+ key: string;
274
+ id: string;
275
+ name: string;
276
+ logoUri: string;
277
+ }, {
278
+ key: string;
279
+ id: string;
280
+ name: string;
281
+ logoUri: string;
282
+ }>, "many">>;
283
+ todos: z.ZodOptional<z.ZodArray<z.ZodObject<{
284
+ name: z.ZodString;
285
+ description: z.ZodString;
286
+ isComplete: z.ZodBoolean;
287
+ }, "strip", z.ZodTypeAny, {
288
+ name: string;
289
+ description: string;
290
+ isComplete: boolean;
291
+ }, {
292
+ name: string;
293
+ description: string;
294
+ isComplete: boolean;
295
+ }>, "many">>;
296
+ archivedAt: z.ZodOptional<z.ZodString>;
297
+ } & {
298
+ appliedToIntegrations: z.ZodOptional<z.ZodArray<z.ZodObject<{
299
+ id: z.ZodString;
300
+ name: z.ZodString;
301
+ } & {
302
+ key: z.ZodString;
303
+ state: z.ZodOptional<z.ZodNativeEnum<typeof import("..").WorkspaceElementState>>;
304
+ errors: z.ZodOptional<z.ZodArray<any, "many">>;
305
+ } & {
306
+ logoUri: z.ZodString;
307
+ connectorId: z.ZodOptional<z.ZodString>;
308
+ connectorVersion: z.ZodOptional<z.ZodString>;
309
+ authOptions: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
310
+ oAuthCallbackUri: z.ZodOptional<z.ZodString>;
311
+ parametersSchema: z.ZodOptional<z.ZodType<import("../..").DataSchema, z.ZodTypeDef, import("../..").DataSchema>>;
312
+ parameters: z.ZodOptional<z.ZodAny>;
313
+ baseUri: z.ZodString;
314
+ archivedAt: z.ZodOptional<z.ZodString>;
315
+ hasMissingParameters: z.ZodOptional<z.ZodBoolean>;
316
+ hasDocumentation: z.ZodOptional<z.ZodBoolean>;
317
+ hasOperations: z.ZodOptional<z.ZodBoolean>;
318
+ hasData: z.ZodOptional<z.ZodBoolean>;
319
+ hasEvents: z.ZodOptional<z.ZodBoolean>;
320
+ hasGlobalWebhooks: z.ZodOptional<z.ZodBoolean>;
321
+ hasUdm: z.ZodOptional<z.ZodBoolean>;
322
+ isTest: z.ZodOptional<z.ZodBoolean>;
323
+ appUuid: z.ZodOptional<z.ZodString>;
324
+ isDeactivated: z.ZodOptional<z.ZodBoolean>;
325
+ authType: z.ZodOptional<z.ZodEnum<["integration-app-token", "membrane-token", "oauth2", "oauth1", "client-credentials", "proxy"]>>;
326
+ }, "strip", z.ZodTypeAny, {
327
+ key: string;
328
+ id: string;
329
+ name: string;
330
+ baseUri: string;
331
+ logoUri: string;
332
+ state?: import("..").WorkspaceElementState | undefined;
333
+ errors?: any[] | undefined;
334
+ parameters?: any;
335
+ parametersSchema?: import("../..").DataSchema | undefined;
336
+ archivedAt?: string | undefined;
337
+ isTest?: boolean | undefined;
338
+ connectorId?: string | undefined;
339
+ connectorVersion?: string | undefined;
340
+ authOptions?: any[] | undefined;
341
+ oAuthCallbackUri?: string | undefined;
342
+ hasMissingParameters?: boolean | undefined;
343
+ hasDocumentation?: boolean | undefined;
344
+ hasOperations?: boolean | undefined;
345
+ hasData?: boolean | undefined;
346
+ hasEvents?: boolean | undefined;
347
+ hasGlobalWebhooks?: boolean | undefined;
348
+ hasUdm?: boolean | undefined;
349
+ appUuid?: string | undefined;
350
+ isDeactivated?: boolean | undefined;
351
+ authType?: "proxy" | "integration-app-token" | "membrane-token" | "oauth2" | "oauth1" | "client-credentials" | undefined;
352
+ }, {
353
+ key: string;
354
+ id: string;
355
+ name: string;
356
+ baseUri: string;
357
+ logoUri: string;
358
+ state?: import("..").WorkspaceElementState | undefined;
359
+ errors?: any[] | undefined;
360
+ parameters?: any;
361
+ parametersSchema?: import("../..").DataSchema | undefined;
362
+ archivedAt?: string | undefined;
363
+ isTest?: boolean | undefined;
364
+ connectorId?: string | undefined;
365
+ connectorVersion?: string | undefined;
366
+ authOptions?: any[] | undefined;
367
+ oAuthCallbackUri?: string | undefined;
368
+ hasMissingParameters?: boolean | undefined;
369
+ hasDocumentation?: boolean | undefined;
370
+ hasOperations?: boolean | undefined;
371
+ hasData?: boolean | undefined;
372
+ hasEvents?: boolean | undefined;
373
+ hasGlobalWebhooks?: boolean | undefined;
374
+ hasUdm?: boolean | undefined;
375
+ appUuid?: string | undefined;
376
+ isDeactivated?: boolean | undefined;
377
+ authType?: "proxy" | "integration-app-token" | "membrane-token" | "oauth2" | "oauth1" | "client-credentials" | undefined;
378
+ }>, "many">>;
379
+ }, "strip", z.ZodTypeAny, {
380
+ key: string;
381
+ id: string;
382
+ name: string;
383
+ appId: string;
384
+ state?: import("..").WorkspaceElementState | undefined;
385
+ errors?: any[] | undefined;
386
+ archivedAt?: string | undefined;
387
+ appliedToIntegrations?: {
388
+ key: string;
389
+ id: string;
390
+ name: string;
391
+ baseUri: string;
392
+ logoUri: string;
393
+ state?: import("..").WorkspaceElementState | undefined;
394
+ errors?: any[] | undefined;
395
+ parameters?: any;
396
+ parametersSchema?: import("../..").DataSchema | undefined;
397
+ archivedAt?: string | undefined;
398
+ isTest?: boolean | undefined;
399
+ connectorId?: string | undefined;
400
+ connectorVersion?: string | undefined;
401
+ authOptions?: any[] | undefined;
402
+ oAuthCallbackUri?: string | undefined;
403
+ hasMissingParameters?: boolean | undefined;
404
+ hasDocumentation?: boolean | undefined;
405
+ hasOperations?: boolean | undefined;
406
+ hasData?: boolean | undefined;
407
+ hasEvents?: boolean | undefined;
408
+ hasGlobalWebhooks?: boolean | undefined;
409
+ hasUdm?: boolean | undefined;
410
+ appUuid?: string | undefined;
411
+ isDeactivated?: boolean | undefined;
412
+ authType?: "proxy" | "integration-app-token" | "membrane-token" | "oauth2" | "oauth1" | "client-credentials" | undefined;
413
+ }[] | undefined;
414
+ scenarioTemplateId?: string | undefined;
415
+ elements?: {
416
+ type: string;
417
+ id: string;
418
+ element?: any;
419
+ }[] | undefined;
420
+ connectors?: {
421
+ key: string;
422
+ id: string;
423
+ name: string;
424
+ logoUri: string;
425
+ }[] | undefined;
426
+ todos?: {
427
+ name: string;
428
+ description: string;
429
+ isComplete: boolean;
430
+ }[] | undefined;
431
+ }, {
432
+ key: string;
433
+ id: string;
434
+ name: string;
435
+ appId: string;
436
+ state?: import("..").WorkspaceElementState | undefined;
437
+ errors?: any[] | undefined;
438
+ archivedAt?: string | undefined;
439
+ appliedToIntegrations?: {
440
+ key: string;
441
+ id: string;
442
+ name: string;
443
+ baseUri: string;
444
+ logoUri: string;
445
+ state?: import("..").WorkspaceElementState | undefined;
446
+ errors?: any[] | undefined;
447
+ parameters?: any;
448
+ parametersSchema?: import("../..").DataSchema | undefined;
449
+ archivedAt?: string | undefined;
450
+ isTest?: boolean | undefined;
451
+ connectorId?: string | undefined;
452
+ connectorVersion?: string | undefined;
453
+ authOptions?: any[] | undefined;
454
+ oAuthCallbackUri?: string | undefined;
455
+ hasMissingParameters?: boolean | undefined;
456
+ hasDocumentation?: boolean | undefined;
457
+ hasOperations?: boolean | undefined;
458
+ hasData?: boolean | undefined;
459
+ hasEvents?: boolean | undefined;
460
+ hasGlobalWebhooks?: boolean | undefined;
461
+ hasUdm?: boolean | undefined;
462
+ appUuid?: string | undefined;
463
+ isDeactivated?: boolean | undefined;
464
+ authType?: "proxy" | "integration-app-token" | "membrane-token" | "oauth2" | "oauth1" | "client-credentials" | undefined;
465
+ }[] | undefined;
466
+ scenarioTemplateId?: string | undefined;
467
+ elements?: {
468
+ type: string;
469
+ id: string;
470
+ element?: any;
471
+ }[] | undefined;
472
+ connectors?: {
473
+ key: string;
474
+ id: string;
475
+ name: string;
476
+ logoUri: string;
477
+ }[] | undefined;
478
+ todos?: {
479
+ name: string;
480
+ description: string;
481
+ isComplete: boolean;
482
+ }[] | undefined;
483
+ }>;
484
+ export type Scenario = z.infer<typeof Scenario>;
122
485
  export type ScenarioApiResponse = Scenario;
123
486
  export {};
@@ -9,7 +9,7 @@ export declare enum ScreenBlockType {
9
9
  DataSource = "data-source",
10
10
  Action = "action"
11
11
  }
12
- export interface ScreenBlock {
12
+ export interface ScreenBlockApi {
13
13
  type: ScreenBlockType;
14
14
  [key: string]: any;
15
15
  }
@@ -21,7 +21,7 @@ export interface ScreenSelector {
21
21
  connectionId?: string;
22
22
  }
23
23
  export interface UpdateScreenRequest {
24
- blocks?: ScreenBlock[];
24
+ blocks?: ScreenBlockApi[];
25
25
  key?: string;
26
26
  }
27
27
  export interface CreateScreenRequest extends UpdateScreenRequest {
@@ -1,30 +1,77 @@
1
+ import { z } from 'zod';
1
2
  import { WorkspaceElementState } from '../../types';
2
3
  import { ActionType } from '../actions/action-types';
3
4
  export declare enum ActionDependencyType {
4
5
  FieldMapping = "FieldMapping",
5
6
  DataSource = "DataSource"
6
7
  }
7
- export interface ActionDependency {
8
+ export declare const ActionDependency: z.ZodObject<{
9
+ type: z.ZodNativeEnum<typeof ActionDependencyType>;
10
+ key: z.ZodString;
11
+ element: z.ZodOptional<z.ZodAny>;
12
+ }, "strip", z.ZodTypeAny, {
13
+ key: string;
8
14
  type: ActionDependencyType;
15
+ element?: any;
16
+ }, {
9
17
  key: string;
18
+ type: ActionDependencyType;
10
19
  element?: any;
11
- }
12
- export interface BaseActionInstance {
20
+ }>;
21
+ export type ActionDependency = z.infer<typeof ActionDependency>;
22
+ export declare const BaseActionInstance: z.ZodObject<{
23
+ id: z.ZodString;
24
+ name: z.ZodString;
25
+ revision: z.ZodString;
26
+ parentId: z.ZodOptional<z.ZodString>;
27
+ parentRevision: z.ZodOptional<z.ZodString>;
28
+ universalParentId: z.ZodOptional<z.ZodString>;
29
+ userId: z.ZodString;
30
+ instanceKey: z.ZodOptional<z.ZodString>;
31
+ createdAt: z.ZodOptional<z.ZodString>;
32
+ updatedAt: z.ZodOptional<z.ZodString>;
33
+ archivedAt: z.ZodOptional<z.ZodString>;
34
+ type: z.ZodNativeEnum<typeof ActionType>;
35
+ inputSchema: z.ZodOptional<z.ZodAny>;
36
+ config: z.ZodOptional<z.ZodAny>;
37
+ outputSchema: z.ZodOptional<z.ZodAny>;
38
+ isOutdated: z.ZodOptional<z.ZodBoolean>;
39
+ state: z.ZodNativeEnum<typeof WorkspaceElementState>;
40
+ }, "strip", z.ZodTypeAny, {
41
+ type: ActionType;
13
42
  id: string;
14
43
  name: string;
15
- revision: string;
16
- parentId?: string;
17
- parentRevision?: string;
18
- universalParentId?: string;
44
+ state: WorkspaceElementState;
19
45
  userId: string;
20
- instanceKey?: string;
21
- createdAt?: string;
22
- updatedAt?: string;
23
- archivedAt?: string;
24
- type: ActionType;
46
+ revision: string;
47
+ instanceKey?: string | undefined;
48
+ createdAt?: string | undefined;
49
+ updatedAt?: string | undefined;
50
+ archivedAt?: string | undefined;
51
+ parentId?: string | undefined;
52
+ parentRevision?: string | undefined;
25
53
  inputSchema?: any;
26
54
  config?: any;
27
55
  outputSchema?: any;
28
- isOutdated?: boolean;
56
+ universalParentId?: string | undefined;
57
+ isOutdated?: boolean | undefined;
58
+ }, {
59
+ type: ActionType;
60
+ id: string;
61
+ name: string;
29
62
  state: WorkspaceElementState;
30
- }
63
+ userId: string;
64
+ revision: string;
65
+ instanceKey?: string | undefined;
66
+ createdAt?: string | undefined;
67
+ updatedAt?: string | undefined;
68
+ archivedAt?: string | undefined;
69
+ parentId?: string | undefined;
70
+ parentRevision?: string | undefined;
71
+ inputSchema?: any;
72
+ config?: any;
73
+ outputSchema?: any;
74
+ universalParentId?: string | undefined;
75
+ isOutdated?: boolean | undefined;
76
+ }>;
77
+ export type BaseActionInstance = z.infer<typeof BaseActionInstance>;
@@ -1,19 +1,42 @@
1
- import { ErrorData } from '../../../errors';
1
+ import { z } from 'zod';
2
2
  export declare enum ActionRunStatus {
3
3
  RUNNING = "running",
4
4
  SUCCESS = "success",
5
5
  ERROR = "error",
6
6
  QUEUED = "queued"
7
7
  }
8
- export interface BaseActionRunLogRecord {
8
+ export declare const BaseActionRunLogRecord: z.ZodObject<{
9
+ id: z.ZodString;
10
+ actionId: z.ZodString;
11
+ integrationId: z.ZodString;
12
+ connectionId: z.ZodString;
13
+ input: z.ZodOptional<z.ZodAny>;
14
+ output: z.ZodOptional<z.ZodAny>;
15
+ status: z.ZodNativeEnum<typeof ActionRunStatus>;
16
+ startedAt: z.ZodString;
17
+ completedAt: z.ZodOptional<z.ZodString>;
18
+ error: any;
19
+ }, "strip", z.ZodTypeAny, {
20
+ status: ActionRunStatus;
9
21
  id: string;
10
- actionId: string;
11
- integrationId: string;
12
22
  connectionId: string;
23
+ integrationId: string;
24
+ actionId: string;
25
+ startedAt: string;
26
+ error?: any;
13
27
  input?: any;
14
28
  output?: any;
29
+ completedAt?: string | undefined;
30
+ }, {
15
31
  status: ActionRunStatus;
32
+ id: string;
33
+ connectionId: string;
34
+ integrationId: string;
35
+ actionId: string;
16
36
  startedAt: string;
17
- completedAt?: string;
18
- error?: ErrorData;
19
- }
37
+ error?: any;
38
+ input?: any;
39
+ output?: any;
40
+ completedAt?: string | undefined;
41
+ }>;
42
+ export type BaseActionRunLogRecord = z.infer<typeof BaseActionRunLogRecord>;