@membranehq/sdk 0.4.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.d.ts +16299 -1303
- package/dist/bundle.js +3980 -3701
- package/dist/bundle.js.map +1 -1
- package/dist/dts/accessors/connections-accessors.d.ts +78 -1
- package/dist/dts/accessors/integrations-accessors.d.ts +78 -1
- package/dist/dts/api-client.d.ts +1 -0
- package/dist/dts/client.d.ts +1 -0
- package/dist/dts/data-schema/index.d.ts +0 -1
- package/dist/dts/data-schema/types.d.ts +4 -3
- package/dist/dts/entity-repository.d.ts +88 -20
- package/dist/dts/formulas/dataSchemaRef.d.ts +2 -2
- package/dist/dts/http-requests.d.ts +20 -6
- package/dist/dts/iframe.d.ts +12 -4
- package/dist/dts/index.d.ts +2 -1
- package/dist/dts/sse/index.d.ts +1 -0
- package/dist/dts/sse/workspace-elements.d.ts +9 -0
- package/dist/dts/workspace-elements/api/action-instances-api.d.ts +269 -8
- package/dist/dts/workspace-elements/api/action-run-log-records-api.d.ts +529 -10
- package/dist/dts/workspace-elements/api/actions-api.d.ts +1010 -45
- package/dist/dts/workspace-elements/api/app-data-schema-instances-api.d.ts +203 -8
- package/dist/dts/workspace-elements/api/app-data-schemas-api.d.ts +49 -3
- package/dist/dts/workspace-elements/api/app-event-log-records-api.d.ts +376 -0
- package/dist/dts/workspace-elements/api/app-event-subscriptions-api.d.ts +293 -8
- package/dist/dts/workspace-elements/api/app-event-types-api.d.ts +88 -3
- package/dist/dts/workspace-elements/api/connections-api.d.ts +993 -42
- package/dist/dts/workspace-elements/api/customers-api.d.ts +92 -16
- package/dist/dts/workspace-elements/api/data-link-table-instances-api.d.ts +541 -12
- package/dist/dts/workspace-elements/api/data-link-tables-api.d.ts +43 -2
- package/dist/dts/workspace-elements/api/data-source-instances-api.d.ts +1590 -12
- package/dist/dts/workspace-elements/api/data-sources-api.d.ts +1113 -78
- package/dist/dts/workspace-elements/api/external-event-log-records-api.d.ts +696 -19
- package/dist/dts/workspace-elements/api/external-event-pulls-api.d.ts +702 -19
- package/dist/dts/workspace-elements/api/external-event-subscriptions-api.d.ts +559 -10
- package/dist/dts/workspace-elements/api/external-events-api.d.ts +582 -6
- package/dist/dts/workspace-elements/api/field-mapping-instances-api.d.ts +2786 -14
- package/dist/dts/workspace-elements/api/field-mappings-api.d.ts +885 -7
- package/dist/dts/workspace-elements/api/flow-runs-api.d.ts +1652 -47
- package/dist/dts/workspace-elements/api/flows-api.d.ts +3202 -52
- package/dist/dts/workspace-elements/api/index.d.ts +1 -1
- package/dist/dts/workspace-elements/api/integrations-api.d.ts +339 -26
- package/dist/dts/workspace-elements/api/scenarios-api.d.ts +523 -35
- package/dist/dts/workspace-elements/api/screens-api.d.ts +35 -15
- package/dist/dts/workspace-elements/base/action-instances/types.d.ts +78 -15
- package/dist/dts/workspace-elements/base/action-run-log-records/types.d.ts +37 -12
- package/dist/dts/workspace-elements/base/actions/types.d.ts +78 -18
- package/dist/dts/workspace-elements/base/app-data-schema-instances/types.d.ts +59 -7
- package/dist/dts/workspace-elements/base/app-data-schemas/types.d.ts +49 -7
- package/dist/dts/workspace-elements/base/app-event-subscriptions/types.d.ts +92 -9
- package/dist/dts/workspace-elements/base/app-event-types/types.d.ts +84 -7
- package/dist/dts/workspace-elements/base/connections/types.d.ts +82 -20
- package/dist/dts/workspace-elements/base/connectors/types.d.ts +14 -2
- package/dist/dts/workspace-elements/base/customers/index.d.ts +32 -6
- package/dist/dts/workspace-elements/base/data-collections/schemas.d.ts +93 -92
- package/dist/dts/workspace-elements/base/data-link-table-instances/types.d.ts +78 -11
- package/dist/dts/workspace-elements/base/data-link-tables/types.d.ts +43 -4
- package/dist/dts/workspace-elements/base/data-source-instances/types.d.ts +1048 -19
- package/dist/dts/workspace-elements/base/data-sources/types.d.ts +97 -22
- package/dist/dts/workspace-elements/base/external-event-log-records/types.d.ts +31 -8
- package/dist/dts/workspace-elements/base/external-event-pulls/types.d.ts +35 -8
- package/dist/dts/workspace-elements/base/external-event-subscriptions/types.d.ts +197 -24
- package/dist/dts/workspace-elements/base/external-events/types.d.ts +145 -5
- package/dist/dts/workspace-elements/base/field-mapping-instances/types.d.ts +92 -16
- package/dist/dts/workspace-elements/base/field-mappings/types.d.ts +105 -14
- package/dist/dts/workspace-elements/base/flow-instances/schemas.d.ts +43 -43
- package/dist/dts/workspace-elements/base/flow-instances/types.d.ts +170 -24
- package/dist/dts/workspace-elements/base/flow-runs/flow-node-runs.d.ts +20 -20
- package/dist/dts/workspace-elements/base/flow-runs/types.d.ts +127 -19
- package/dist/dts/workspace-elements/base/flows/types.d.ts +234 -26
- package/dist/dts/workspace-elements/base/integrations/types.d.ts +988 -25
- package/dist/dts/workspace-elements/base/scenarios/types.d.ts +740 -23
- package/dist/dts/workspace-elements/base/screens/types.d.ts +48 -6
- package/dist/dts/workspace-elements/types.d.ts +25 -3
- package/dist/dts/workspaces/types.d.ts +4 -3
- package/dist/index.d.ts +26481 -3080
- package/dist/index.js +1717 -535
- package/dist/index.js.map +1 -1
- package/dist/index.module.d.mts +26481 -3080
- package/dist/index.module.mjs +1550 -502
- package/dist/index.module.mjs.map +1 -1
- package/package.json +3 -2
- package/dist/dts/data-schema/schemas.d.ts +0 -4
- package/dist/dts/workspace-elements/api/app-events-api.d.ts +0 -17
package/dist/index.module.mjs
CHANGED
|
@@ -5,9 +5,9 @@ import jsonata from 'jsonata';
|
|
|
5
5
|
import deepEqual from 'fast-deep-equal';
|
|
6
6
|
import structuredClonePolyfill from '@ungap/structured-clone';
|
|
7
7
|
import urljoin from 'url-join';
|
|
8
|
+
import { connectToChild } from 'penpal';
|
|
8
9
|
import { fromError } from 'zod-validation-error/v3';
|
|
9
10
|
import qs from 'qs';
|
|
10
|
-
import { connectToChild } from 'penpal';
|
|
11
11
|
import axiosOriginal from 'axios';
|
|
12
12
|
|
|
13
13
|
var ErrorType;
|
|
@@ -1308,19 +1308,19 @@ function createSchemaForObject(obj) {
|
|
|
1308
1308
|
return schema;
|
|
1309
1309
|
}
|
|
1310
1310
|
|
|
1311
|
-
const
|
|
1311
|
+
const DataSchema = z.lazy(() => z.object({
|
|
1312
1312
|
title: z.string().optional(),
|
|
1313
1313
|
description: z.string().optional(),
|
|
1314
1314
|
type: z.union([z.string(), z.array(z.string())]).optional(),
|
|
1315
1315
|
format: z.string().optional(),
|
|
1316
|
-
properties: z.record(
|
|
1317
|
-
items:
|
|
1318
|
-
additionalProperties: z.union([z.boolean(),
|
|
1316
|
+
properties: z.record(DataSchema).optional(),
|
|
1317
|
+
items: DataSchema.optional(),
|
|
1318
|
+
additionalProperties: z.union([z.boolean(), DataSchema]).optional(),
|
|
1319
1319
|
enum: z.array(z.string()).optional(),
|
|
1320
1320
|
referenceRecords: z.array(z.any()).optional(),
|
|
1321
1321
|
referenceCollection: z
|
|
1322
1322
|
.object({
|
|
1323
|
-
key: z.any(),
|
|
1323
|
+
key: z.any().optional(),
|
|
1324
1324
|
parameters: z.record(z.any()).optional(),
|
|
1325
1325
|
})
|
|
1326
1326
|
.optional(),
|
|
@@ -1337,7 +1337,7 @@ const DataSchemaSchema = z.lazy(() => z.object({
|
|
|
1337
1337
|
readOnly: z.boolean().optional(),
|
|
1338
1338
|
writeOnly: z.boolean().optional(),
|
|
1339
1339
|
examples: z.array(z.any()).optional(),
|
|
1340
|
-
anyOf: z.array(
|
|
1340
|
+
anyOf: z.array(DataSchema).optional(),
|
|
1341
1341
|
isImplied: z.boolean().optional(),
|
|
1342
1342
|
isSensitive: z.boolean().optional(),
|
|
1343
1343
|
referenceCollectionPath: z.string().optional(),
|
|
@@ -3361,12 +3361,118 @@ function getFormula(value) {
|
|
|
3361
3361
|
return undefined;
|
|
3362
3362
|
}
|
|
3363
3363
|
|
|
3364
|
+
var ConfigurationState;
|
|
3365
|
+
(function (ConfigurationState) {
|
|
3366
|
+
ConfigurationState["CONFIGURED"] = "CONFIGURED";
|
|
3367
|
+
ConfigurationState["NOT_CONFIGURED"] = "NOT_CONFIGURED";
|
|
3368
|
+
})(ConfigurationState || (ConfigurationState = {}));
|
|
3369
|
+
var WorkspaceElementType;
|
|
3370
|
+
(function (WorkspaceElementType) {
|
|
3371
|
+
WorkspaceElementType["Customer"] = "customer";
|
|
3372
|
+
WorkspaceElementType["Connector"] = "connector";
|
|
3373
|
+
WorkspaceElementType["Integration"] = "integration";
|
|
3374
|
+
WorkspaceElementType["Flow"] = "flow";
|
|
3375
|
+
WorkspaceElementType["FlowInstance"] = "flow-instance";
|
|
3376
|
+
WorkspaceElementType["FlowRun"] = "flow-run";
|
|
3377
|
+
WorkspaceElementType["Action"] = "action";
|
|
3378
|
+
WorkspaceElementType["Scenario"] = "scenario";
|
|
3379
|
+
WorkspaceElementType["ActionInstance"] = "action-instance";
|
|
3380
|
+
WorkspaceElementType["Connection"] = "connection";
|
|
3381
|
+
WorkspaceElementType["FieldMapping"] = "field-mapping";
|
|
3382
|
+
WorkspaceElementType["FieldMappingInstance"] = "field-mapping-instance";
|
|
3383
|
+
WorkspaceElementType["DataSource"] = "data-source";
|
|
3384
|
+
WorkspaceElementType["DataSourceInstance"] = "data-source-instance";
|
|
3385
|
+
WorkspaceElementType["DataLinkTable"] = "data-link-table";
|
|
3386
|
+
WorkspaceElementType["DataLinkTableInstance"] = "data-link-table-instance";
|
|
3387
|
+
WorkspaceElementType["AppEventType"] = "app-event-type";
|
|
3388
|
+
WorkspaceElementType["AppEventSubscription"] = "app-event-subscription";
|
|
3389
|
+
WorkspaceElementType["AppEventLogRecord"] = "app-event-log-record";
|
|
3390
|
+
WorkspaceElementType["AppDataSchema"] = "app-data-schema";
|
|
3391
|
+
WorkspaceElementType["AppDataSchemaInstance"] = "app-data-schema-instance";
|
|
3392
|
+
WorkspaceElementType["ExternalEventSubscription"] = "external-event-subscription";
|
|
3393
|
+
WorkspaceElementType["ExternalEventLogRecord"] = "external-event-log-record";
|
|
3394
|
+
WorkspaceElementType["ExternalEventPull"] = "external-event-pull";
|
|
3395
|
+
WorkspaceElementType["DataCollection"] = "data-collection";
|
|
3396
|
+
WorkspaceElementType["Screen"] = "screen";
|
|
3397
|
+
WorkspaceElementType["ActionRunLogRecord"] = "action-run-log-record";
|
|
3398
|
+
})(WorkspaceElementType || (WorkspaceElementType = {}));
|
|
3399
|
+
var WorkspaceEventType;
|
|
3400
|
+
(function (WorkspaceEventType) {
|
|
3401
|
+
WorkspaceEventType["ConnectionCreated"] = "connection.created";
|
|
3402
|
+
WorkspaceEventType["ConnectionDeleted"] = "connection.deleted";
|
|
3403
|
+
WorkspaceEventType["ConnectionDisconnected"] = "connection.disconnected";
|
|
3404
|
+
WorkspaceEventType["ConnectionReconnected"] = "connection.reconnected";
|
|
3405
|
+
WorkspaceEventType["FlowRunQueued"] = "flowRun.queued";
|
|
3406
|
+
WorkspaceEventType["FlowRunStarted"] = "flowRun.started";
|
|
3407
|
+
WorkspaceEventType["FlowRunCompleted"] = "flowRun.completed";
|
|
3408
|
+
WorkspaceEventType["FlowRunFailed"] = "flowRun.failed";
|
|
3409
|
+
WorkspaceEventType["FlowRunStopped"] = "flowRun.stopped";
|
|
3410
|
+
})(WorkspaceEventType || (WorkspaceEventType = {}));
|
|
3411
|
+
var WorkspaceElementState;
|
|
3412
|
+
(function (WorkspaceElementState) {
|
|
3413
|
+
WorkspaceElementState["CONFIGURATION_ERROR"] = "CONFIGURATION_ERROR";
|
|
3414
|
+
WorkspaceElementState["SETUP_FAILED"] = "SETUP_FAILED";
|
|
3415
|
+
WorkspaceElementState["READY"] = "READY";
|
|
3416
|
+
})(WorkspaceElementState || (WorkspaceElementState = {}));
|
|
3417
|
+
var WorkspaceElementDependencyType;
|
|
3418
|
+
(function (WorkspaceElementDependencyType) {
|
|
3419
|
+
WorkspaceElementDependencyType["Configuration"] = "CONFIGURATION";
|
|
3420
|
+
WorkspaceElementDependencyType["Parent"] = "PARENT";
|
|
3421
|
+
})(WorkspaceElementDependencyType || (WorkspaceElementDependencyType = {}));
|
|
3422
|
+
const BaseWorkspaceElement = z.object({
|
|
3423
|
+
id: z.string(),
|
|
3424
|
+
name: z.string(),
|
|
3425
|
+
});
|
|
3426
|
+
const BaseMembraneInterface = BaseWorkspaceElement.extend({
|
|
3427
|
+
key: z.string().optional(),
|
|
3428
|
+
uuid: z.string().optional(),
|
|
3429
|
+
description: z.string().optional(),
|
|
3430
|
+
state: z.nativeEnum(WorkspaceElementState).optional(),
|
|
3431
|
+
errors: z.array(ErrorDataSchema).optional(),
|
|
3432
|
+
revision: z.string().optional(),
|
|
3433
|
+
isDeactivated: z.boolean().optional(),
|
|
3434
|
+
createdAt: z.string().optional(),
|
|
3435
|
+
updatedAt: z.string().optional(),
|
|
3436
|
+
archivedAt: z.string().optional(),
|
|
3437
|
+
});
|
|
3438
|
+
|
|
3364
3439
|
var FieldMappingDirection;
|
|
3365
3440
|
(function (FieldMappingDirection) {
|
|
3366
3441
|
FieldMappingDirection["IMPORT"] = "import";
|
|
3367
3442
|
FieldMappingDirection["EXPORT"] = "export";
|
|
3368
3443
|
FieldMappingDirection["BOTH"] = "both";
|
|
3369
3444
|
})(FieldMappingDirection || (FieldMappingDirection = {}));
|
|
3445
|
+
const BaseFieldMapping = BaseMembraneInterface.extend({
|
|
3446
|
+
revision: z.string(),
|
|
3447
|
+
publishedRevision: z.string().optional(),
|
|
3448
|
+
universalFieldMappingId: z.string().optional(),
|
|
3449
|
+
universalFieldMappingRevision: z.string().optional(),
|
|
3450
|
+
integrationId: z.string().optional(),
|
|
3451
|
+
dataSourceId: z.string(),
|
|
3452
|
+
dataSourceKey: z.string(),
|
|
3453
|
+
appSchema: DataSchema,
|
|
3454
|
+
direction: z.nativeEnum(FieldMappingDirection),
|
|
3455
|
+
defaultImportValue: z.any().optional(),
|
|
3456
|
+
defaultExportValue: z.any().optional(),
|
|
3457
|
+
importValue: z.any().optional(),
|
|
3458
|
+
exportValue: z.any().optional(),
|
|
3459
|
+
frozenImportFields: z.any().optional(),
|
|
3460
|
+
frozenExportFields: z.any().optional(),
|
|
3461
|
+
frozenUnifiedExportFields: z.any().optional(),
|
|
3462
|
+
archivedAt: z.string().optional(),
|
|
3463
|
+
customized: z.boolean().optional(),
|
|
3464
|
+
});
|
|
3465
|
+
const FieldMappingUnitConfig = z.object({
|
|
3466
|
+
key: z.string().optional(),
|
|
3467
|
+
input: z.any().optional(),
|
|
3468
|
+
includeRawFields: z.any().optional(),
|
|
3469
|
+
importValue: z.any().optional(),
|
|
3470
|
+
exportValue: z.any().optional(),
|
|
3471
|
+
default: z.any().optional(),
|
|
3472
|
+
defaultUnifiedValue: z.any().optional(),
|
|
3473
|
+
defaultValue: z.any().optional(),
|
|
3474
|
+
appSchema: DataSchema.optional(),
|
|
3475
|
+
});
|
|
3370
3476
|
|
|
3371
3477
|
function mergeWithFormulas(a, b) {
|
|
3372
3478
|
if (Array.isArray(a) && Array.isArray(b)) {
|
|
@@ -3495,6 +3601,51 @@ const ACTIONS = {
|
|
|
3495
3601
|
},
|
|
3496
3602
|
};
|
|
3497
3603
|
|
|
3604
|
+
const BaseAction = BaseMembraneInterface.extend({
|
|
3605
|
+
integrationId: z.string().optional(),
|
|
3606
|
+
parentId: z.string().optional(),
|
|
3607
|
+
parentRevision: z.string().optional(),
|
|
3608
|
+
isCustomized: z.boolean().optional(),
|
|
3609
|
+
type: z.nativeEnum(ActionType),
|
|
3610
|
+
inputSchema: DataSchema.optional(),
|
|
3611
|
+
config: z.any().optional(),
|
|
3612
|
+
outputMapping: z.any().optional(),
|
|
3613
|
+
customOutputSchema: DataSchema.optional(),
|
|
3614
|
+
defaultOutputSchema: DataSchema.optional(),
|
|
3615
|
+
transformedOutputSchema: DataSchema.optional(),
|
|
3616
|
+
outputSchema: DataSchema.optional(),
|
|
3617
|
+
dependencies: z.array(z.any()).optional(),
|
|
3618
|
+
});
|
|
3619
|
+
|
|
3620
|
+
const ConnectionRequest = z.object({
|
|
3621
|
+
path: z.any(),
|
|
3622
|
+
method: z.enum(['GET', 'POST', 'PUT', 'PATCH', 'DELETE']).optional(),
|
|
3623
|
+
pathParameters: z.record(z.string()).optional(),
|
|
3624
|
+
headers: z.record(z.string()).optional(),
|
|
3625
|
+
query: z.record(z.string()).optional(),
|
|
3626
|
+
data: z.any().optional(),
|
|
3627
|
+
});
|
|
3628
|
+
const BaseConnection = BaseWorkspaceElement.extend({
|
|
3629
|
+
name: z.string(),
|
|
3630
|
+
userId: z.string(),
|
|
3631
|
+
isTest: z.boolean().optional(),
|
|
3632
|
+
disconnected: z.boolean().optional(),
|
|
3633
|
+
isDefunct: z.boolean().optional(),
|
|
3634
|
+
error: ErrorDataSchema.optional(),
|
|
3635
|
+
integrationId: z.string(),
|
|
3636
|
+
credentials: z.unknown().optional(),
|
|
3637
|
+
parameters: z.unknown().optional(),
|
|
3638
|
+
connectorParameters: z.unknown().optional(),
|
|
3639
|
+
createdAt: z.string(),
|
|
3640
|
+
updatedAt: z.string(),
|
|
3641
|
+
lastActiveAt: z.string().optional(),
|
|
3642
|
+
nextCredentialsRefreshAt: z.string().optional(),
|
|
3643
|
+
archivedAt: z.string().optional(),
|
|
3644
|
+
isDeactivated: z.boolean().optional(),
|
|
3645
|
+
state: z.nativeEnum(WorkspaceElementState).optional(),
|
|
3646
|
+
errors: z.array(ErrorDataSchema).optional(),
|
|
3647
|
+
meta: z.record(z.any()).optional(),
|
|
3648
|
+
});
|
|
3498
3649
|
class ConnectionSpec {
|
|
3499
3650
|
constructor(opts) {
|
|
3500
3651
|
Object.assign(this, opts);
|
|
@@ -3818,6 +3969,12 @@ var ConnectorStatus;
|
|
|
3818
3969
|
ConnectorStatus["beta"] = "beta";
|
|
3819
3970
|
ConnectorStatus["planned"] = "planned";
|
|
3820
3971
|
})(ConnectorStatus || (ConnectorStatus = {}));
|
|
3972
|
+
const MinimalConnector = z.object({
|
|
3973
|
+
id: z.string(),
|
|
3974
|
+
key: z.string(),
|
|
3975
|
+
name: z.string(),
|
|
3976
|
+
logoUri: z.string(),
|
|
3977
|
+
});
|
|
3821
3978
|
|
|
3822
3979
|
const DataRecordSchema = z.object({
|
|
3823
3980
|
id: z.string(),
|
|
@@ -7283,7 +7440,7 @@ function getWritableFieldsSchema(spec) {
|
|
|
7283
7440
|
return mergeSchemas([getDataCollectionCreateFields(spec), getDataCollectionUpdateFields(spec)]);
|
|
7284
7441
|
}
|
|
7285
7442
|
function getReferenceCollectionPointerForSchema(schema) {
|
|
7286
|
-
if (schema === null || schema === void 0 ? void 0 : schema.referenceCollection) {
|
|
7443
|
+
if ((schema === null || schema === void 0 ? void 0 : schema.referenceCollection) && schema.referenceCollection.key) {
|
|
7287
7444
|
return schema.referenceCollection;
|
|
7288
7445
|
}
|
|
7289
7446
|
else if (schema === null || schema === void 0 ? void 0 : schema.referenceCollectionPath) {
|
|
@@ -7878,8 +8035,8 @@ const DataCollectionRecordFromFieldsMethod = {
|
|
|
7878
8035
|
getInputSchema: ({ collectionSpec }) => ({
|
|
7879
8036
|
type: 'object',
|
|
7880
8037
|
properties: {
|
|
7881
|
-
|
|
7882
|
-
|
|
8038
|
+
...((collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema) && { fields: collectionSpec.fieldsSchema }),
|
|
8039
|
+
...((collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.parametersSchema) && { parameters: collectionSpec.parametersSchema }),
|
|
7883
8040
|
},
|
|
7884
8041
|
}),
|
|
7885
8042
|
getOutputSchema: () => DATA_RECORD_SCHEMA,
|
|
@@ -7918,7 +8075,7 @@ const DataCollectionFieldsFromApiMethod = {
|
|
|
7918
8075
|
},
|
|
7919
8076
|
};
|
|
7920
8077
|
},
|
|
7921
|
-
getOutputSchema: ({ collectionSpec }) => collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema,
|
|
8078
|
+
getOutputSchema: ({ collectionSpec }) => (collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema) || { type: 'object' },
|
|
7922
8079
|
supportedImplementationTypes: [ConnectorMethodImplementationType.javascript],
|
|
7923
8080
|
};
|
|
7924
8081
|
const DataCollectionFieldsToApiMethod = {
|
|
@@ -7927,7 +8084,7 @@ const DataCollectionFieldsToApiMethod = {
|
|
|
7927
8084
|
getInputSchema: ({ collectionSpec }) => ({
|
|
7928
8085
|
type: 'object',
|
|
7929
8086
|
properties: {
|
|
7930
|
-
|
|
8087
|
+
...((collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema) && { fields: collectionSpec.fieldsSchema }),
|
|
7931
8088
|
},
|
|
7932
8089
|
}),
|
|
7933
8090
|
getOutputSchema: () => {
|
|
@@ -7969,134 +8126,134 @@ const DataLocationTypeCollection = {
|
|
|
7969
8126
|
};
|
|
7970
8127
|
const ConnectorDataCollectionMethodKeys = Object.keys(DataLocationTypeCollection.methods);
|
|
7971
8128
|
|
|
7972
|
-
const
|
|
8129
|
+
const ApiRequestSpec = z.object({
|
|
7973
8130
|
path: z.unknown(),
|
|
7974
8131
|
method: z.unknown(),
|
|
7975
8132
|
});
|
|
7976
|
-
const
|
|
7977
|
-
apiRequests: z.array(
|
|
8133
|
+
const DataCollectionMethodSpec = z.object({
|
|
8134
|
+
apiRequests: z.array(ApiRequestSpec).optional(),
|
|
7978
8135
|
});
|
|
7979
|
-
const
|
|
8136
|
+
const DataCollectionListSpec = DataCollectionMethodSpec.extend({
|
|
7980
8137
|
filterFields: z.array(z.string()).optional(),
|
|
7981
8138
|
});
|
|
7982
|
-
const
|
|
7983
|
-
const
|
|
8139
|
+
const DataCollectionSearchSpec = DataCollectionMethodSpec.extend({});
|
|
8140
|
+
const DataCollectionMatchSpec = DataCollectionMethodSpec.extend({
|
|
7984
8141
|
fields: z.array(z.string()).optional(),
|
|
7985
8142
|
});
|
|
7986
|
-
const
|
|
7987
|
-
const
|
|
8143
|
+
const DataCollectionFindByIdSpec = DataCollectionMethodSpec.extend({});
|
|
8144
|
+
const DataCollectionCreateSpec = DataCollectionMethodSpec.extend({
|
|
7988
8145
|
fields: z.array(z.string()).optional(),
|
|
7989
8146
|
requiredFields: z.array(z.string()).optional(),
|
|
7990
8147
|
excludedFields: z.array(z.string()).optional(),
|
|
7991
8148
|
});
|
|
7992
|
-
const
|
|
8149
|
+
const DataCollectionUpdateSpec = DataCollectionMethodSpec.extend({
|
|
7993
8150
|
fields: z.array(z.string()).optional(),
|
|
7994
8151
|
excludedFields: z.array(z.string()).optional(),
|
|
7995
8152
|
});
|
|
7996
|
-
const
|
|
7997
|
-
const
|
|
8153
|
+
const DataCollectionDeleteSpec = DataCollectionMethodSpec.extend({});
|
|
8154
|
+
const DataCollectionFindSpec = DataCollectionMethodSpec.extend({
|
|
7998
8155
|
queryFields: z.array(z.string()).optional(),
|
|
7999
8156
|
});
|
|
8000
|
-
const
|
|
8157
|
+
const DataCollectionEventTypeSpec = z.object({
|
|
8001
8158
|
type: z.enum(['push', 'pull']),
|
|
8002
8159
|
isFullScan: z.boolean().optional(),
|
|
8003
8160
|
isIdOnly: z.boolean().optional(),
|
|
8004
8161
|
});
|
|
8005
|
-
const
|
|
8162
|
+
const DataCollectionEventsSpec = z
|
|
8006
8163
|
.object({
|
|
8007
|
-
created:
|
|
8008
|
-
updated:
|
|
8009
|
-
deleted:
|
|
8010
|
-
all:
|
|
8164
|
+
created: DataCollectionEventTypeSpec.optional(),
|
|
8165
|
+
updated: DataCollectionEventTypeSpec.optional(),
|
|
8166
|
+
deleted: DataCollectionEventTypeSpec.optional(),
|
|
8167
|
+
all: DataCollectionEventTypeSpec.optional(),
|
|
8011
8168
|
})
|
|
8012
|
-
.catchall(
|
|
8013
|
-
const
|
|
8169
|
+
.catchall(DataCollectionEventTypeSpec);
|
|
8170
|
+
const DataCollectionUdmSpec = z.object({
|
|
8014
8171
|
fields: z.array(z.string()).optional(),
|
|
8015
8172
|
extract: z.record(z.any()).optional(),
|
|
8016
8173
|
parse: z.record(z.any()).optional(),
|
|
8017
8174
|
});
|
|
8018
|
-
const
|
|
8019
|
-
const
|
|
8175
|
+
const DataCollectionUdmsSpec = z.record(DataCollectionUdmSpec);
|
|
8176
|
+
const DataCollectionSpec = z.object({
|
|
8020
8177
|
type: z.literal('collection'),
|
|
8021
8178
|
key: z.string().optional(),
|
|
8022
8179
|
name: z.string(),
|
|
8023
|
-
parametersSchema:
|
|
8024
|
-
fieldsSchema:
|
|
8025
|
-
list:
|
|
8026
|
-
search:
|
|
8027
|
-
match:
|
|
8028
|
-
findById:
|
|
8029
|
-
create:
|
|
8030
|
-
update:
|
|
8031
|
-
delete:
|
|
8032
|
-
events:
|
|
8180
|
+
parametersSchema: DataSchema.optional(),
|
|
8181
|
+
fieldsSchema: DataSchema.optional(),
|
|
8182
|
+
list: DataCollectionListSpec.optional(),
|
|
8183
|
+
search: DataCollectionSearchSpec.optional(),
|
|
8184
|
+
match: DataCollectionMatchSpec.optional(),
|
|
8185
|
+
findById: DataCollectionFindByIdSpec.optional(),
|
|
8186
|
+
create: DataCollectionCreateSpec.optional(),
|
|
8187
|
+
update: DataCollectionUpdateSpec.optional(),
|
|
8188
|
+
delete: DataCollectionDeleteSpec.optional(),
|
|
8189
|
+
events: DataCollectionEventsSpec.optional(),
|
|
8033
8190
|
customFields: z.boolean().optional(),
|
|
8034
|
-
udm:
|
|
8035
|
-
find:
|
|
8191
|
+
udm: DataCollectionUdmsSpec.optional(),
|
|
8192
|
+
find: DataCollectionFindSpec.optional(),
|
|
8036
8193
|
});
|
|
8037
|
-
const
|
|
8194
|
+
const DataCollectionMethodRequest = z.object({
|
|
8038
8195
|
parameters: z.record(z.any()).optional(),
|
|
8039
8196
|
});
|
|
8040
|
-
const
|
|
8197
|
+
const DataCollectionFindRequest = z.object({
|
|
8041
8198
|
query: z.any().optional(),
|
|
8042
8199
|
cursor: z.string().optional(),
|
|
8043
8200
|
});
|
|
8044
|
-
const
|
|
8201
|
+
const DataCollectionFindResponse = z.object({
|
|
8045
8202
|
records: z.array(DataRecordSchema),
|
|
8046
8203
|
cursor: z.string().optional(),
|
|
8047
8204
|
});
|
|
8048
|
-
const
|
|
8205
|
+
const DataCollectionListRequest = DataCollectionMethodRequest.extend({
|
|
8049
8206
|
filter: z.any().optional(),
|
|
8050
8207
|
unifiedFilter: z.any().optional(),
|
|
8051
8208
|
cursor: z.string().optional(),
|
|
8052
8209
|
});
|
|
8053
|
-
const
|
|
8210
|
+
const DataCollectionListResponseDrilldown = z.object({
|
|
8054
8211
|
parameters: z.record(z.any()).optional(),
|
|
8055
8212
|
filter: z.record(z.any()).optional(),
|
|
8056
8213
|
});
|
|
8057
|
-
const
|
|
8214
|
+
const DataCollectionListResponse = z.object({
|
|
8058
8215
|
records: z.array(DataRecordSchema),
|
|
8059
|
-
drilldowns: z.array(
|
|
8216
|
+
drilldowns: z.array(DataCollectionListResponseDrilldown).optional(),
|
|
8060
8217
|
cursor: z.string().optional(),
|
|
8061
8218
|
});
|
|
8062
|
-
const
|
|
8219
|
+
const DataCollectionSearchRequest = DataCollectionMethodRequest.extend({
|
|
8063
8220
|
query: z.string(),
|
|
8064
8221
|
cursor: z.string().optional(),
|
|
8065
8222
|
});
|
|
8066
|
-
const
|
|
8223
|
+
const DataCollectionSearchResponse = z.object({
|
|
8067
8224
|
records: z.array(DataRecordSchema),
|
|
8068
8225
|
cursor: z.string().optional(),
|
|
8069
8226
|
});
|
|
8070
|
-
const
|
|
8227
|
+
const DataCollectionFindByIdRequest = DataCollectionMethodRequest.extend({
|
|
8071
8228
|
id: z.string(),
|
|
8072
8229
|
udm: z.string().optional(),
|
|
8073
8230
|
});
|
|
8074
|
-
const
|
|
8231
|
+
const DataCollectionFindByIdResponse = z.object({
|
|
8075
8232
|
record: DataRecordSchema,
|
|
8076
8233
|
});
|
|
8077
|
-
const
|
|
8234
|
+
const DataCollectionMatchRequest = DataCollectionMethodRequest.extend({
|
|
8078
8235
|
query: z.record(z.any()),
|
|
8079
8236
|
});
|
|
8080
|
-
const
|
|
8237
|
+
const DataCollectionMatchResponse = z.object({
|
|
8081
8238
|
record: DataRecordSchema.optional(),
|
|
8082
8239
|
});
|
|
8083
|
-
const
|
|
8240
|
+
const DataCollectionCreateRequest = DataCollectionMethodRequest.extend({
|
|
8084
8241
|
fields: z.record(z.any()),
|
|
8085
8242
|
});
|
|
8086
|
-
const
|
|
8243
|
+
const DataCollectionCreateResponse = z.object({
|
|
8087
8244
|
id: z.string(),
|
|
8088
8245
|
});
|
|
8089
|
-
const
|
|
8246
|
+
const DataCollectionUpdateRequest = DataCollectionMethodRequest.extend({
|
|
8090
8247
|
id: z.string(),
|
|
8091
8248
|
fields: z.record(z.any()),
|
|
8092
8249
|
});
|
|
8093
|
-
const
|
|
8250
|
+
const DataCollectionUpdateResponse = z.object({
|
|
8094
8251
|
id: z.string(),
|
|
8095
8252
|
});
|
|
8096
|
-
const
|
|
8253
|
+
const DataCollectionDeleteRequest = DataCollectionMethodRequest.extend({
|
|
8097
8254
|
id: z.string(),
|
|
8098
8255
|
});
|
|
8099
|
-
const
|
|
8256
|
+
const DataCollectionDeleteResponse = z.object({});
|
|
8100
8257
|
const ConnectorDataLocationTypes = {
|
|
8101
8258
|
collection: DataLocationTypeCollection,
|
|
8102
8259
|
};
|
|
@@ -8164,6 +8321,56 @@ const DEFAULT_FULL_SYNC_INTERVAL_SECONDS = 60 * 60 * 3;
|
|
|
8164
8321
|
const MIN_FULL_SYNC_INTERVAL_SECONDS = 1 * 60;
|
|
8165
8322
|
const MIN_PULL_UPDATES_INTERVAL_SECONDS = 1 * 60;
|
|
8166
8323
|
|
|
8324
|
+
const DataSourceUnitConfig = z.object({
|
|
8325
|
+
key: z.string().optional(),
|
|
8326
|
+
collectionKey: z.any().optional(),
|
|
8327
|
+
collectionParameters: z.any().optional(),
|
|
8328
|
+
udm: z.any().optional(),
|
|
8329
|
+
path: z.string().optional(),
|
|
8330
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
8331
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
8332
|
+
});
|
|
8333
|
+
const BaseDataSource = BaseMembraneInterface.extend({
|
|
8334
|
+
revision: z.string(),
|
|
8335
|
+
publishedRevision: z.string().optional(),
|
|
8336
|
+
integrationId: z.string().optional(),
|
|
8337
|
+
universalDataSourceId: z.string().optional(),
|
|
8338
|
+
universalDataSourceRevision: z.string().optional(),
|
|
8339
|
+
udm: z.string().optional(),
|
|
8340
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
8341
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
8342
|
+
collectionKey: z.string().optional(),
|
|
8343
|
+
collectionParameters: z.any().optional(),
|
|
8344
|
+
archivedAt: z.string().optional(),
|
|
8345
|
+
createdAt: z.string().optional(),
|
|
8346
|
+
updatedAt: z.string().optional(),
|
|
8347
|
+
customized: z.boolean().optional(),
|
|
8348
|
+
defaultPath: z.string().optional(),
|
|
8349
|
+
});
|
|
8350
|
+
|
|
8351
|
+
const BaseDataSourceInstance = BaseMembraneInterface.extend({
|
|
8352
|
+
userId: z.string(),
|
|
8353
|
+
revision: z.string(),
|
|
8354
|
+
dataSourceRevision: z.string().optional(),
|
|
8355
|
+
dataSourceId: z.string().optional(),
|
|
8356
|
+
universalDataSourceId: z.string().optional(),
|
|
8357
|
+
udm: z.string().optional(),
|
|
8358
|
+
connectionId: z.string(),
|
|
8359
|
+
integrationId: z.string(),
|
|
8360
|
+
instanceKey: z.string().optional(),
|
|
8361
|
+
collectionKey: z.string().optional(),
|
|
8362
|
+
collectionParameters: z.any().optional(),
|
|
8363
|
+
defaultCollectionKey: z.string().optional(),
|
|
8364
|
+
defaultCollectionParameters: z.any().optional(),
|
|
8365
|
+
collectionSpec: DataCollectionSpec.optional(),
|
|
8366
|
+
isCustomized: z.boolean().optional(),
|
|
8367
|
+
errors: z.array(ErrorDataSchema).optional(),
|
|
8368
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
8369
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
8370
|
+
path: z.string().optional(),
|
|
8371
|
+
defaultPath: z.string().optional(),
|
|
8372
|
+
});
|
|
8373
|
+
|
|
8167
8374
|
var ExternalEventType;
|
|
8168
8375
|
(function (ExternalEventType) {
|
|
8169
8376
|
ExternalEventType["DataRecordCreated"] = "data-record-created";
|
|
@@ -8176,6 +8383,15 @@ var IncomingWebhooksState;
|
|
|
8176
8383
|
IncomingWebhooksState["SUCCESS"] = "success";
|
|
8177
8384
|
IncomingWebhooksState["ERROR"] = "error";
|
|
8178
8385
|
})(IncomingWebhooksState || (IncomingWebhooksState = {}));
|
|
8386
|
+
const ExternalEventUnitConfig = z.object({
|
|
8387
|
+
type: z.nativeEnum(ExternalEventType),
|
|
8388
|
+
dataSource: DataSourceUnitConfig.optional(),
|
|
8389
|
+
eventKey: z.string().optional(),
|
|
8390
|
+
eventParameters: z.any().optional(),
|
|
8391
|
+
});
|
|
8392
|
+
const BaseExternalEvent = z.object({
|
|
8393
|
+
config: ExternalEventUnitConfig.optional(),
|
|
8394
|
+
});
|
|
8179
8395
|
|
|
8180
8396
|
function externalEventTypeToDataCollectionEventType(type) {
|
|
8181
8397
|
switch (type) {
|
|
@@ -8209,6 +8425,49 @@ var FlowRunNodeState;
|
|
|
8209
8425
|
FlowRunNodeState["STOPPED"] = "stopped";
|
|
8210
8426
|
FlowRunNodeState["FAILED"] = "failed";
|
|
8211
8427
|
})(FlowRunNodeState || (FlowRunNodeState = {}));
|
|
8428
|
+
var FlowRunState;
|
|
8429
|
+
(function (FlowRunState) {
|
|
8430
|
+
FlowRunState["QUEUED"] = "queued";
|
|
8431
|
+
FlowRunState["RUNNING"] = "running";
|
|
8432
|
+
FlowRunState["COMPLETED"] = "completed";
|
|
8433
|
+
FlowRunState["STOPPED"] = "stopped";
|
|
8434
|
+
FlowRunState["FAILED"] = "failed";
|
|
8435
|
+
})(FlowRunState || (FlowRunState = {}));
|
|
8436
|
+
var FlowRunLaunchedByTrigger;
|
|
8437
|
+
(function (FlowRunLaunchedByTrigger) {
|
|
8438
|
+
FlowRunLaunchedByTrigger["ApiTrigger"] = "api-trigger";
|
|
8439
|
+
FlowRunLaunchedByTrigger["ScheduleTrigger"] = "schedule-trigger";
|
|
8440
|
+
FlowRunLaunchedByTrigger["AppEventTrigger"] = "app-event-trigger";
|
|
8441
|
+
FlowRunLaunchedByTrigger["DataSourceTrigger"] = "data-source-trigger";
|
|
8442
|
+
FlowRunLaunchedByTrigger["ExternalEvent"] = "external-event";
|
|
8443
|
+
})(FlowRunLaunchedByTrigger || (FlowRunLaunchedByTrigger = {}));
|
|
8444
|
+
const FlowRunLaunchedBy = z.object({
|
|
8445
|
+
type: z.nativeEnum(FlowRunLaunchedByTrigger),
|
|
8446
|
+
ids: z.array(z.string()).optional(),
|
|
8447
|
+
});
|
|
8448
|
+
const FlowRunNode = z.object({
|
|
8449
|
+
state: z.nativeEnum(FlowRunNodeState),
|
|
8450
|
+
runs: z.number().optional(),
|
|
8451
|
+
erroredRuns: z.number().optional(),
|
|
8452
|
+
outputs: z.number().optional(),
|
|
8453
|
+
});
|
|
8454
|
+
const BaseFlowRun = z.object({
|
|
8455
|
+
id: z.string(),
|
|
8456
|
+
name: z.string().optional(),
|
|
8457
|
+
flowInstanceId: z.string(),
|
|
8458
|
+
universalFlowId: z.string().optional(),
|
|
8459
|
+
connectionId: z.string().optional(),
|
|
8460
|
+
integrationId: z.string().optional(),
|
|
8461
|
+
startNodeKey: z.string(),
|
|
8462
|
+
userId: z.string(),
|
|
8463
|
+
input: z.any().optional(),
|
|
8464
|
+
state: z.nativeEnum(FlowRunState),
|
|
8465
|
+
startTime: z.string(),
|
|
8466
|
+
endTime: z.string().optional(),
|
|
8467
|
+
errors: z.array(ErrorDataSchema).optional(),
|
|
8468
|
+
nodes: z.record(FlowRunNode).optional(),
|
|
8469
|
+
launchedBy: FlowRunLaunchedBy.optional(),
|
|
8470
|
+
});
|
|
8212
8471
|
|
|
8213
8472
|
var FlowNodeRunStatus;
|
|
8214
8473
|
(function (FlowNodeRunStatus) {
|
|
@@ -8533,11 +8792,216 @@ const FLOW_NODE_SPECS = {
|
|
|
8533
8792
|
[FlowNodeType.RunAction]: RunAction,
|
|
8534
8793
|
};
|
|
8535
8794
|
|
|
8795
|
+
const FlowNodeLink = z.object({
|
|
8796
|
+
key: z.string().optional(),
|
|
8797
|
+
filter: z.any().optional(),
|
|
8798
|
+
name: z.string().optional(),
|
|
8799
|
+
});
|
|
8800
|
+
const FlowNode = z.object({
|
|
8801
|
+
type: z.string().optional(),
|
|
8802
|
+
version: z.number().optional(),
|
|
8803
|
+
name: z.string().optional(),
|
|
8804
|
+
description: z.string().optional(),
|
|
8805
|
+
config: z.any().optional(),
|
|
8806
|
+
concurrency: z.number().optional(),
|
|
8807
|
+
onError: z.enum(['stop', 'continue']).optional(),
|
|
8808
|
+
ui: z.any().optional(),
|
|
8809
|
+
inputSchema: z.any().optional(),
|
|
8810
|
+
outputSchema: z.any().optional(),
|
|
8811
|
+
outputExample: z.any().optional(),
|
|
8812
|
+
links: z.array(FlowNodeLink).optional(),
|
|
8813
|
+
isCustomized: z.boolean().optional(),
|
|
8814
|
+
});
|
|
8815
|
+
const BaseFlow = BaseMembraneInterface.extend({
|
|
8816
|
+
integrationId: z.string().optional(),
|
|
8817
|
+
universalFlowId: z.string().optional(),
|
|
8818
|
+
universalFlowRevision: z.string().optional(),
|
|
8819
|
+
parametersSchema: DataSchema.optional(),
|
|
8820
|
+
nodes: z.record(FlowNode).optional(),
|
|
8821
|
+
autoCreateInstances: z.boolean().optional(),
|
|
8822
|
+
archivedAt: z.string().optional(),
|
|
8823
|
+
revision: z.string(),
|
|
8824
|
+
customized: z.boolean().optional(),
|
|
8825
|
+
});
|
|
8826
|
+
|
|
8827
|
+
const IntegrationAuthUi = z.object({
|
|
8828
|
+
schema: z.any().optional(),
|
|
8829
|
+
helpUri: z.string().optional(),
|
|
8830
|
+
});
|
|
8831
|
+
const IntegrationAuthOption = z.object({
|
|
8832
|
+
key: z.string(),
|
|
8833
|
+
type: z.enum(CONNECTOR_AUTH_TYPES),
|
|
8834
|
+
title: z.string().optional(),
|
|
8835
|
+
description: z.string().optional(),
|
|
8836
|
+
ui: IntegrationAuthUi.optional(),
|
|
8837
|
+
});
|
|
8838
|
+
const BaseIntegration = BaseMembraneInterface.extend({
|
|
8839
|
+
logoUri: z.string(),
|
|
8840
|
+
connectorId: z.string().optional(),
|
|
8841
|
+
connectorVersion: z.string().optional(),
|
|
8842
|
+
authOptions: z.array(IntegrationAuthOption).optional(),
|
|
8843
|
+
oAuthCallbackUri: z.string().optional(),
|
|
8844
|
+
parametersSchema: DataSchema.optional(),
|
|
8845
|
+
parameters: z.any().optional(),
|
|
8846
|
+
baseUri: z.string(),
|
|
8847
|
+
archivedAt: z.string().optional(),
|
|
8848
|
+
hasMissingParameters: z.boolean().optional(),
|
|
8849
|
+
hasDocumentation: z.boolean().optional(),
|
|
8850
|
+
hasOperations: z.boolean().optional(),
|
|
8851
|
+
operationsCount: z.number().optional(),
|
|
8852
|
+
hasData: z.boolean().optional(),
|
|
8853
|
+
dataCollectionsCount: z.number().optional(),
|
|
8854
|
+
hasEvents: z.boolean().optional(),
|
|
8855
|
+
eventsCount: z.number().optional(),
|
|
8856
|
+
hasGlobalWebhooks: z.boolean().optional(),
|
|
8857
|
+
hasUdm: z.boolean().optional(),
|
|
8858
|
+
isTest: z.boolean().optional(),
|
|
8859
|
+
appUuid: z.string().optional(),
|
|
8860
|
+
isDeactivated: z.boolean().optional(),
|
|
8861
|
+
authType: z.enum(CONNECTOR_AUTH_TYPES).optional(),
|
|
8862
|
+
});
|
|
8863
|
+
const AppliedToIntegrations = (elementSchema) => z.array(z.object({
|
|
8864
|
+
element: elementSchema,
|
|
8865
|
+
integration: BaseIntegration,
|
|
8866
|
+
}));
|
|
8867
|
+
|
|
8868
|
+
var ScenarioTemplateCategory;
|
|
8869
|
+
(function (ScenarioTemplateCategory) {
|
|
8870
|
+
ScenarioTemplateCategory["DataExport"] = "data-export";
|
|
8871
|
+
ScenarioTemplateCategory["DataImport"] = "data-import";
|
|
8872
|
+
ScenarioTemplateCategory["BiDirectionalSync"] = "bi-directional-sync";
|
|
8873
|
+
ScenarioTemplateCategory["UnifiedApi"] = "unified-api";
|
|
8874
|
+
ScenarioTemplateCategory["DataEnrichment"] = "data-enrichment";
|
|
8875
|
+
})(ScenarioTemplateCategory || (ScenarioTemplateCategory = {}));
|
|
8876
|
+
const ScenarioToDo = z.object({
|
|
8877
|
+
name: z.string(),
|
|
8878
|
+
description: z.string(),
|
|
8879
|
+
isComplete: z.boolean(),
|
|
8880
|
+
});
|
|
8881
|
+
const ScenarioElement = z.object({
|
|
8882
|
+
id: z.string(),
|
|
8883
|
+
type: z.string(),
|
|
8884
|
+
element: z.any().optional(),
|
|
8885
|
+
});
|
|
8886
|
+
const BaseScenario = BaseMembraneInterface.extend({
|
|
8887
|
+
appId: z.string(),
|
|
8888
|
+
scenarioTemplateId: z.string().optional(),
|
|
8889
|
+
elements: z.array(ScenarioElement).optional(),
|
|
8890
|
+
connectors: z.array(MinimalConnector).optional(),
|
|
8891
|
+
todos: z.array(ScenarioToDo).optional(),
|
|
8892
|
+
archivedAt: z.string().optional(),
|
|
8893
|
+
});
|
|
8894
|
+
const HandyScenarioTemplateElement = z.object({
|
|
8895
|
+
type: z.string(),
|
|
8896
|
+
integration: z.object({ key: z.string(), connectorId: z.string() }).optional(),
|
|
8897
|
+
integrations: z.array(z.object({ key: z.string(), connectorId: z.string() })).optional(),
|
|
8898
|
+
fields: z
|
|
8899
|
+
.object({
|
|
8900
|
+
key: z.string(),
|
|
8901
|
+
name: z.string(),
|
|
8902
|
+
})
|
|
8903
|
+
.and(z.record(z.any())),
|
|
8904
|
+
});
|
|
8905
|
+
const withIntegrationKeys = (schema) => schema.and(z.object({ integrationKeys: z.array(z.string()).optional() }));
|
|
8906
|
+
const ElementsExportFields = z.object({
|
|
8907
|
+
flows: z.record(withIntegrationKeys(z.any())).optional(),
|
|
8908
|
+
actions: z.record(withIntegrationKeys(z.any())).optional(),
|
|
8909
|
+
fieldMappings: z.record(withIntegrationKeys(z.any())).optional(),
|
|
8910
|
+
dataSources: z.record(withIntegrationKeys(z.any())).optional(),
|
|
8911
|
+
dataLinkTables: z.record(z.any()).optional(),
|
|
8912
|
+
appEventTypes: z.record(z.any()).optional(),
|
|
8913
|
+
appDataSchemas: z.record(z.any()).optional(),
|
|
8914
|
+
});
|
|
8915
|
+
const ScenarioTemplateElements = ElementsExportFields.and(z.object({
|
|
8916
|
+
integrations: z.record(ElementsExportFields.and(z.object({ connectorId: z.string() }))).optional(),
|
|
8917
|
+
}));
|
|
8918
|
+
const ScenarioTemplate = z.object({
|
|
8919
|
+
id: z.string(),
|
|
8920
|
+
name: z.string(),
|
|
8921
|
+
key: z.string(),
|
|
8922
|
+
shortDescription: z.string().optional(),
|
|
8923
|
+
description: z.string().optional(),
|
|
8924
|
+
demoWorkspaceKey: z.string().optional(),
|
|
8925
|
+
demoAppUri: z.string().optional(),
|
|
8926
|
+
demoGithubRepo: z.string().optional(),
|
|
8927
|
+
demoVideoYoutubeUri: z.string().optional(),
|
|
8928
|
+
tags: z.array(z.nativeEnum(ScenarioTemplateCategory)).optional(),
|
|
8929
|
+
elements: ScenarioTemplateElements.optional(),
|
|
8930
|
+
todos: z.array(ScenarioToDo.omit({ isComplete: true })).optional(),
|
|
8931
|
+
connectors: z.array(MinimalConnector).optional(),
|
|
8932
|
+
handyElements: z.array(HandyScenarioTemplateElement).optional(),
|
|
8933
|
+
});
|
|
8934
|
+
|
|
8935
|
+
var ScreenType;
|
|
8936
|
+
(function (ScreenType) {
|
|
8937
|
+
ScreenType["Integration"] = "integration";
|
|
8938
|
+
})(ScreenType || (ScreenType = {}));
|
|
8939
|
+
var ScreenBlockType;
|
|
8940
|
+
(function (ScreenBlockType) {
|
|
8941
|
+
ScreenBlockType["Flow"] = "flow";
|
|
8942
|
+
ScreenBlockType["FieldMapping"] = "field-mapping";
|
|
8943
|
+
ScreenBlockType["DataSource"] = "data-source";
|
|
8944
|
+
ScreenBlockType["Action"] = "action";
|
|
8945
|
+
})(ScreenBlockType || (ScreenBlockType = {}));
|
|
8946
|
+
const ScreenBlock = z
|
|
8947
|
+
.object({
|
|
8948
|
+
type: z.nativeEnum(ScreenBlockType),
|
|
8949
|
+
})
|
|
8950
|
+
.and(z.record(z.any()));
|
|
8951
|
+
const BaseScreen = BaseWorkspaceElement.extend({
|
|
8952
|
+
type: z.nativeEnum(ScreenType),
|
|
8953
|
+
key: z.string().optional(),
|
|
8954
|
+
blocks: z.array(ScreenBlock),
|
|
8955
|
+
});
|
|
8956
|
+
|
|
8957
|
+
const BaseCustomer = z.object({
|
|
8958
|
+
id: z.string(),
|
|
8959
|
+
name: z.string(),
|
|
8960
|
+
internalId: z.string(),
|
|
8961
|
+
fields: z.record(z.string(), z.any()).optional(),
|
|
8962
|
+
credentials: z.any().optional(),
|
|
8963
|
+
lastActiveAt: z.string().optional(),
|
|
8964
|
+
isTest: z.boolean().optional(),
|
|
8965
|
+
isBillable: z.boolean().optional(),
|
|
8966
|
+
createdAt: z.string().optional(),
|
|
8967
|
+
archivedAt: z.string().optional(),
|
|
8968
|
+
});
|
|
8969
|
+
|
|
8970
|
+
const BaseFlowInstance = BaseMembraneInterface.extend({
|
|
8971
|
+
userId: z.string(),
|
|
8972
|
+
connectionId: z.string().optional(),
|
|
8973
|
+
flowId: z.string().optional(),
|
|
8974
|
+
universalFlowId: z.string().optional(),
|
|
8975
|
+
integrationId: z.string(),
|
|
8976
|
+
instanceKey: z.string().optional(),
|
|
8977
|
+
parameters: z.any().optional(),
|
|
8978
|
+
parametersSchema: DataSchema.optional(),
|
|
8979
|
+
nodes: z.record(z.any()).optional(),
|
|
8980
|
+
enabled: z.boolean(),
|
|
8981
|
+
createdAt: z.string(),
|
|
8982
|
+
updatedAt: z.string(),
|
|
8983
|
+
state: z.nativeEnum(WorkspaceElementState).optional(),
|
|
8984
|
+
outdated: z.boolean().optional(),
|
|
8985
|
+
customized: z
|
|
8986
|
+
.object({
|
|
8987
|
+
name: z.boolean().optional(),
|
|
8988
|
+
nodes: z.boolean().optional(),
|
|
8989
|
+
})
|
|
8990
|
+
.optional(),
|
|
8991
|
+
dependencies: z.array(z.any()).optional(),
|
|
8992
|
+
});
|
|
8536
8993
|
var FlowInstanceNodeState;
|
|
8537
8994
|
(function (FlowInstanceNodeState) {
|
|
8538
8995
|
FlowInstanceNodeState["SETUP_FAILED"] = "SETUP_FAILED";
|
|
8539
8996
|
FlowInstanceNodeState["READY"] = "READY";
|
|
8540
8997
|
})(FlowInstanceNodeState || (FlowInstanceNodeState = {}));
|
|
8998
|
+
const FlowInstanceNode = FlowNode.extend({
|
|
8999
|
+
state: z.nativeEnum(FlowInstanceNodeState).optional(),
|
|
9000
|
+
errors: z.array(ErrorDataSchema).optional(),
|
|
9001
|
+
userConfig: z.any().optional(),
|
|
9002
|
+
testInput: z.any().optional(),
|
|
9003
|
+
dependencies: z.array(z.any()).optional(),
|
|
9004
|
+
});
|
|
8541
9005
|
|
|
8542
9006
|
const flowNodeLinkSchema = z.object({
|
|
8543
9007
|
key: z.string().optional(),
|
|
@@ -8601,6 +9065,47 @@ var ActionDependencyType;
|
|
|
8601
9065
|
ActionDependencyType["FieldMapping"] = "FieldMapping";
|
|
8602
9066
|
ActionDependencyType["DataSource"] = "DataSource";
|
|
8603
9067
|
})(ActionDependencyType || (ActionDependencyType = {}));
|
|
9068
|
+
const ActionDependency = z.object({
|
|
9069
|
+
type: z.nativeEnum(ActionDependencyType),
|
|
9070
|
+
key: z.string(),
|
|
9071
|
+
element: z.any().optional(),
|
|
9072
|
+
});
|
|
9073
|
+
const BaseActionInstance = BaseMembraneInterface.extend({
|
|
9074
|
+
parentId: z.string().optional(),
|
|
9075
|
+
parentRevision: z.string().optional(),
|
|
9076
|
+
universalParentId: z.string().optional(),
|
|
9077
|
+
userId: z.string(),
|
|
9078
|
+
instanceKey: z.string().optional(),
|
|
9079
|
+
type: z.nativeEnum(ActionType),
|
|
9080
|
+
inputSchema: z.any().optional(),
|
|
9081
|
+
config: z.any().optional(),
|
|
9082
|
+
outputSchema: z.any().optional(),
|
|
9083
|
+
isOutdated: z.boolean().optional(),
|
|
9084
|
+
});
|
|
9085
|
+
|
|
9086
|
+
const BaseFieldMappingInstance = BaseMembraneInterface.extend({
|
|
9087
|
+
userId: z.string(),
|
|
9088
|
+
revision: z.string(),
|
|
9089
|
+
connectionId: z.string(),
|
|
9090
|
+
integrationId: z.string(),
|
|
9091
|
+
fieldMappingRevision: z.string().optional(),
|
|
9092
|
+
fieldMappingId: z.string().optional(),
|
|
9093
|
+
instanceKey: z.string().optional(),
|
|
9094
|
+
dataSourceInstanceId: z.string().optional(),
|
|
9095
|
+
dataSourceSchema: DataSchema.optional(),
|
|
9096
|
+
direction: z.nativeEnum(FieldMappingDirection).optional(),
|
|
9097
|
+
appSchema: DataSchema.optional(),
|
|
9098
|
+
importValue: z.any().optional(),
|
|
9099
|
+
exportValue: z.any().optional(),
|
|
9100
|
+
isCustomized: z.boolean().optional(),
|
|
9101
|
+
unifiedExportValue: z.any().optional(),
|
|
9102
|
+
unifiedImportValue: z.any().optional(),
|
|
9103
|
+
frozenImportFields: z.array(z.string()).optional(),
|
|
9104
|
+
frozenExportFields: z.array(z.string()).optional(),
|
|
9105
|
+
state: z.nativeEnum(WorkspaceElementState).optional(),
|
|
9106
|
+
error: ErrorDataSchema.optional(),
|
|
9107
|
+
externalSchema: z.any().optional(),
|
|
9108
|
+
});
|
|
8604
9109
|
|
|
8605
9110
|
var DataLinkDirection;
|
|
8606
9111
|
(function (DataLinkDirection) {
|
|
@@ -8608,27 +9113,167 @@ var DataLinkDirection;
|
|
|
8608
9113
|
DataLinkDirection["EXPORT"] = "export";
|
|
8609
9114
|
DataLinkDirection["BOTH"] = "both";
|
|
8610
9115
|
})(DataLinkDirection || (DataLinkDirection = {}));
|
|
9116
|
+
const BaseDataLinkTable = BaseMembraneInterface.extend({
|
|
9117
|
+
archivedAt: z.string().optional(),
|
|
9118
|
+
});
|
|
8611
9119
|
|
|
8612
|
-
|
|
8613
|
-
|
|
8614
|
-
|
|
8615
|
-
|
|
8616
|
-
|
|
8617
|
-
|
|
8618
|
-
|
|
8619
|
-
|
|
8620
|
-
|
|
8621
|
-
|
|
8622
|
-
|
|
8623
|
-
|
|
8624
|
-
|
|
9120
|
+
const BaseDataLinkTableInstance = BaseMembraneInterface.extend({
|
|
9121
|
+
dataLinkTableId: z.string().optional(),
|
|
9122
|
+
connectionId: z.string().optional(),
|
|
9123
|
+
integrationId: z.string(),
|
|
9124
|
+
instanceKey: z.string().optional(),
|
|
9125
|
+
userId: z.string(),
|
|
9126
|
+
archivedAt: z.string().optional(),
|
|
9127
|
+
});
|
|
9128
|
+
const DataLink = z.object({
|
|
9129
|
+
id: z.string(),
|
|
9130
|
+
dataLinkTableInstanceId: z.string(),
|
|
9131
|
+
externalRecordId: z.string(),
|
|
9132
|
+
appRecordId: z.string(),
|
|
9133
|
+
direction: z.nativeEnum(DataLinkDirection),
|
|
9134
|
+
});
|
|
9135
|
+
const DataLinkTableConfig = z.object({
|
|
9136
|
+
key: z.string(),
|
|
9137
|
+
});
|
|
8625
9138
|
|
|
8626
|
-
var
|
|
8627
|
-
(function (
|
|
8628
|
-
|
|
9139
|
+
var HttpRequestMethod;
|
|
9140
|
+
(function (HttpRequestMethod) {
|
|
9141
|
+
HttpRequestMethod["GET"] = "GET";
|
|
9142
|
+
HttpRequestMethod["POST"] = "POST";
|
|
9143
|
+
HttpRequestMethod["PATCH"] = "PATCH";
|
|
9144
|
+
HttpRequestMethod["PUT"] = "PUT";
|
|
9145
|
+
HttpRequestMethod["DELETE"] = "DELETE";
|
|
9146
|
+
})(HttpRequestMethod || (HttpRequestMethod = {}));
|
|
9147
|
+
const HttpRequestSpec = z.object({
|
|
9148
|
+
method: z.string().toUpperCase().pipe(z.nativeEnum(HttpRequestMethod)).optional(),
|
|
9149
|
+
uri: z.any(),
|
|
9150
|
+
headers: z.record(z.any()).optional(),
|
|
9151
|
+
query: z.record(z.any()).optional(),
|
|
9152
|
+
body: z.any().optional(),
|
|
9153
|
+
});
|
|
9154
|
+
const HTTP_REQUEST_SCHEMA = {
|
|
9155
|
+
type: 'object',
|
|
9156
|
+
properties: {
|
|
9157
|
+
uri: { type: 'string' },
|
|
9158
|
+
method: {
|
|
9159
|
+
type: 'string',
|
|
9160
|
+
enum: ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'],
|
|
9161
|
+
},
|
|
9162
|
+
body: {},
|
|
9163
|
+
query: {
|
|
9164
|
+
type: 'object',
|
|
9165
|
+
section: true,
|
|
9166
|
+
additionalProperties: true,
|
|
9167
|
+
},
|
|
9168
|
+
headers: {
|
|
9169
|
+
type: 'object',
|
|
9170
|
+
section: true,
|
|
9171
|
+
additionalProperties: true,
|
|
9172
|
+
},
|
|
9173
|
+
},
|
|
9174
|
+
};
|
|
9175
|
+
|
|
9176
|
+
const BaseAppEventType = BaseMembraneInterface.extend({
|
|
9177
|
+
revision: z.string(),
|
|
9178
|
+
archivedAt: z.string().optional(),
|
|
9179
|
+
subscribeRequest: HttpRequestSpec.optional(),
|
|
9180
|
+
example: z.any().optional(),
|
|
9181
|
+
schema: DataSchema.optional(),
|
|
9182
|
+
globalWebhookUri: z.string(),
|
|
9183
|
+
userIdFormula: z.any().optional(),
|
|
9184
|
+
});
|
|
9185
|
+
|
|
9186
|
+
const BaseAppEventSubscription = BaseMembraneInterface.extend({
|
|
9187
|
+
revision: z.string(),
|
|
9188
|
+
appEventTypeId: z.string(),
|
|
9189
|
+
userId: z.string(),
|
|
9190
|
+
instanceKey: z.string().optional(),
|
|
9191
|
+
isSubscribed: z.boolean(),
|
|
9192
|
+
schema: DataSchema.optional(),
|
|
9193
|
+
webhookUri: z.string(),
|
|
9194
|
+
subscriptionRequest: HttpRequestSpec,
|
|
9195
|
+
subscriptionResponse: z.any().optional(),
|
|
9196
|
+
archivedAt: z.string().optional(),
|
|
9197
|
+
});
|
|
9198
|
+
|
|
9199
|
+
const BaseAppDataSchema = BaseMembraneInterface.extend({
|
|
9200
|
+
schema: z.any(),
|
|
9201
|
+
code: z.string().optional(),
|
|
9202
|
+
archivedAt: z.string().optional(),
|
|
9203
|
+
revision: z.string().optional(),
|
|
9204
|
+
});
|
|
9205
|
+
|
|
9206
|
+
const BaseAppDataSchemaInstance = BaseMembraneInterface.extend({
|
|
9207
|
+
appId: z.string(),
|
|
9208
|
+
userId: z.string(),
|
|
9209
|
+
appDataSchemaId: z.string(),
|
|
9210
|
+
appDataSchemaRevision: z.string(),
|
|
9211
|
+
instanceKey: z.string().optional(),
|
|
9212
|
+
schema: z.any().optional(),
|
|
9213
|
+
error: ErrorDataSchema.optional(),
|
|
9214
|
+
archivedAt: z.string().optional(),
|
|
9215
|
+
});
|
|
9216
|
+
|
|
9217
|
+
var ExternalEventSubscriptionStatus;
|
|
9218
|
+
(function (ExternalEventSubscriptionStatus) {
|
|
9219
|
+
ExternalEventSubscriptionStatus["Subscribed"] = "subscribed";
|
|
9220
|
+
ExternalEventSubscriptionStatus["Unsubscribed"] = "unsubscribed";
|
|
9221
|
+
ExternalEventSubscriptionStatus["Error"] = "error";
|
|
9222
|
+
})(ExternalEventSubscriptionStatus || (ExternalEventSubscriptionStatus = {}));
|
|
9223
|
+
var ExternalEventSubscriptionType;
|
|
9224
|
+
(function (ExternalEventSubscriptionType) {
|
|
9225
|
+
ExternalEventSubscriptionType["DataRecordCreated"] = "data-record-created";
|
|
9226
|
+
ExternalEventSubscriptionType["DataRecordUpdated"] = "data-record-updated";
|
|
9227
|
+
ExternalEventSubscriptionType["DataRecordDeleted"] = "data-record-deleted";
|
|
9228
|
+
ExternalEventSubscriptionType["ConnectorEvent"] = "connector-event";
|
|
9229
|
+
})(ExternalEventSubscriptionType || (ExternalEventSubscriptionType = {}));
|
|
9230
|
+
const ExternalEventSubscriptionConfig = z.object({
|
|
9231
|
+
type: z.nativeEnum(ExternalEventSubscriptionType),
|
|
9232
|
+
dataSource: DataSourceUnitConfig.optional(),
|
|
9233
|
+
eventKey: z.string().optional(),
|
|
9234
|
+
eventParameters: z.any().optional(),
|
|
9235
|
+
});
|
|
9236
|
+
const BaseExternalEventSubscription = z.object({
|
|
9237
|
+
id: z.string(),
|
|
9238
|
+
name: z.string().optional(),
|
|
9239
|
+
userId: z.string(),
|
|
9240
|
+
connectionId: z.string(),
|
|
9241
|
+
integrationId: z.string(),
|
|
9242
|
+
config: ExternalEventSubscriptionConfig.optional(),
|
|
9243
|
+
status: z.nativeEnum(ExternalEventSubscriptionStatus).optional(),
|
|
9244
|
+
error: ErrorDataSchema.optional(),
|
|
9245
|
+
isRealTime: z.boolean().optional(),
|
|
9246
|
+
requiresPull: z.boolean().optional(),
|
|
9247
|
+
requiresFullSync: z.boolean().optional(),
|
|
9248
|
+
createdAt: z.string().optional(),
|
|
9249
|
+
archivedAt: z.string().optional(),
|
|
9250
|
+
stateData: z.any().optional(),
|
|
9251
|
+
nextPullEventsTimestamp: z.number().optional(),
|
|
9252
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
9253
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
9254
|
+
nextRefreshTimestamp: z.number().optional(),
|
|
9255
|
+
globalWebhookKey: z.string().optional(),
|
|
9256
|
+
globalWebhookEventSelector: z.string().optional(),
|
|
9257
|
+
});
|
|
9258
|
+
|
|
9259
|
+
var ExternalEventLogStatus;
|
|
9260
|
+
(function (ExternalEventLogStatus) {
|
|
9261
|
+
ExternalEventLogStatus["CREATED"] = "created";
|
|
8629
9262
|
ExternalEventLogStatus["ERROR"] = "error";
|
|
8630
9263
|
ExternalEventLogStatus["SUCCESS"] = "success";
|
|
8631
9264
|
})(ExternalEventLogStatus || (ExternalEventLogStatus = {}));
|
|
9265
|
+
const BaseExternalEventLogRecord = z.object({
|
|
9266
|
+
id: z.string(),
|
|
9267
|
+
userId: z.string(),
|
|
9268
|
+
name: z.string().optional(),
|
|
9269
|
+
externalEventSubscriptionId: z.string(),
|
|
9270
|
+
integrationId: z.string(),
|
|
9271
|
+
connectionId: z.string(),
|
|
9272
|
+
payload: z.any().optional(),
|
|
9273
|
+
launchedFlowRunIds: z.array(z.string()).optional(),
|
|
9274
|
+
status: z.nativeEnum(ExternalEventLogStatus),
|
|
9275
|
+
error: ErrorDataSchema.optional(),
|
|
9276
|
+
});
|
|
8632
9277
|
|
|
8633
9278
|
var ExternalEventPullStatus;
|
|
8634
9279
|
(function (ExternalEventPullStatus) {
|
|
@@ -8637,135 +9282,785 @@ var ExternalEventPullStatus;
|
|
|
8637
9282
|
ExternalEventPullStatus["ERROR"] = "error";
|
|
8638
9283
|
ExternalEventPullStatus["QUEUED"] = "queued";
|
|
8639
9284
|
})(ExternalEventPullStatus || (ExternalEventPullStatus = {}));
|
|
9285
|
+
const BaseExternalEventPull = z.object({
|
|
9286
|
+
id: z.string(),
|
|
9287
|
+
name: z.string().optional(),
|
|
9288
|
+
userId: z.string(),
|
|
9289
|
+
externalEventSubscriptionId: z.string(),
|
|
9290
|
+
integrationId: z.string(),
|
|
9291
|
+
connectionId: z.string(),
|
|
9292
|
+
startDatetime: z.string(),
|
|
9293
|
+
endDatetime: z.string(),
|
|
9294
|
+
isFullScan: z.boolean().optional(),
|
|
9295
|
+
status: z.nativeEnum(ExternalEventPullStatus),
|
|
9296
|
+
collectedEventIds: z.array(z.string()),
|
|
9297
|
+
error: ErrorDataSchema.optional(),
|
|
9298
|
+
});
|
|
9299
|
+
|
|
9300
|
+
var ActionRunLogStatus;
|
|
9301
|
+
(function (ActionRunLogStatus) {
|
|
9302
|
+
ActionRunLogStatus["SUCCESS"] = "success";
|
|
9303
|
+
ActionRunLogStatus["ERROR"] = "error";
|
|
9304
|
+
})(ActionRunLogStatus || (ActionRunLogStatus = {}));
|
|
9305
|
+
const BaseActionRunLogRecord = BaseWorkspaceElement.extend({
|
|
9306
|
+
actionId: z.string(),
|
|
9307
|
+
integrationId: z.string(),
|
|
9308
|
+
connectionId: z.string(),
|
|
9309
|
+
input: z.any().optional(),
|
|
9310
|
+
output: z.any().optional(),
|
|
9311
|
+
status: z.nativeEnum(ActionRunLogStatus),
|
|
9312
|
+
createdAt: z.string(),
|
|
9313
|
+
completedAt: z.string().optional(),
|
|
9314
|
+
error: ErrorDataSchema.optional(),
|
|
9315
|
+
});
|
|
9316
|
+
|
|
9317
|
+
const zodBooleanCoercion = () => z.preprocess((val) => {
|
|
9318
|
+
if (typeof val === 'boolean')
|
|
9319
|
+
return val;
|
|
9320
|
+
if (typeof val === 'string') {
|
|
9321
|
+
const lower = val.toLowerCase();
|
|
9322
|
+
if (lower === 'true' || lower === '1')
|
|
9323
|
+
return true;
|
|
9324
|
+
if (lower === 'false' || lower === '0')
|
|
9325
|
+
return false;
|
|
9326
|
+
return Boolean(val);
|
|
9327
|
+
}
|
|
9328
|
+
if (typeof val === 'number')
|
|
9329
|
+
return Boolean(val);
|
|
9330
|
+
return Boolean(val);
|
|
9331
|
+
}, z.boolean());
|
|
9332
|
+
const IncludeArchivedQuery = z.object({
|
|
9333
|
+
includeArchived: zodBooleanCoercion().optional(),
|
|
9334
|
+
});
|
|
9335
|
+
const SearchQuery = z.object({
|
|
9336
|
+
search: z.string().optional(),
|
|
9337
|
+
});
|
|
9338
|
+
const PaginationQuery = z.object({
|
|
9339
|
+
limit: z.coerce.number().optional(),
|
|
9340
|
+
cursor: z.string().optional(),
|
|
9341
|
+
});
|
|
9342
|
+
const CommonListElementsQuery = SearchQuery.merge(PaginationQuery).merge(IncludeArchivedQuery);
|
|
9343
|
+
const CommonInstancesListQuery = CommonListElementsQuery.extend({
|
|
9344
|
+
userId: z.string().optional(),
|
|
9345
|
+
instanceKey: z.string().optional(),
|
|
9346
|
+
});
|
|
9347
|
+
const CommonIntegrationOrConnectionQuery = z.object({
|
|
9348
|
+
connectionId: z.string().optional(),
|
|
9349
|
+
integrationId: z.string().optional(),
|
|
9350
|
+
integrationKey: z.string().optional(),
|
|
9351
|
+
});
|
|
9352
|
+
class PaginationResponse {
|
|
9353
|
+
}
|
|
9354
|
+
|
|
9355
|
+
const ListActionsForIntegrationQuery = z
|
|
9356
|
+
.object({
|
|
9357
|
+
parentId: z.string().optional(),
|
|
9358
|
+
})
|
|
9359
|
+
.merge(PaginationQuery);
|
|
9360
|
+
const FindActionsQuery = ListActionsForIntegrationQuery.extend({
|
|
9361
|
+
integrationId: z.string().optional(),
|
|
9362
|
+
});
|
|
9363
|
+
const CreateActionRequest = z.object({
|
|
9364
|
+
key: z.string(),
|
|
9365
|
+
name: z.string(),
|
|
9366
|
+
type: z.nativeEnum(ActionType).optional(),
|
|
9367
|
+
inputSchema: z.any().optional(),
|
|
9368
|
+
config: z.any().optional(),
|
|
9369
|
+
integrationId: z.string().optional(),
|
|
9370
|
+
});
|
|
9371
|
+
const UpdateActionRequest = z.object({
|
|
9372
|
+
key: z.string().optional(),
|
|
9373
|
+
type: z.nativeEnum(ActionType).optional(),
|
|
9374
|
+
name: z.string().optional(),
|
|
9375
|
+
inputSchema: z.any().optional(),
|
|
9376
|
+
config: z.any().optional(),
|
|
9377
|
+
customOutputSchema: z.any().optional(),
|
|
9378
|
+
outputMapping: z.any().optional(),
|
|
9379
|
+
});
|
|
9380
|
+
const ListActionInstancesForConnectionQuery = z
|
|
9381
|
+
.object({
|
|
9382
|
+
parentId: z.string().optional(),
|
|
9383
|
+
universalParentId: z.string().optional(),
|
|
9384
|
+
})
|
|
9385
|
+
.merge(PaginationQuery);
|
|
9386
|
+
const FindActionInstancesQuery = ListActionInstancesForConnectionQuery.extend({
|
|
9387
|
+
integrationKey: z.string().optional(),
|
|
9388
|
+
integrationId: z.string().optional(),
|
|
9389
|
+
userId: z.string().optional(),
|
|
9390
|
+
connectionId: z.string().optional(),
|
|
9391
|
+
});
|
|
9392
|
+
const CreateActionInstanceRequest = z.object({
|
|
9393
|
+
parentId: z.string(),
|
|
9394
|
+
connectionId: z.string(),
|
|
9395
|
+
config: z.any().optional(),
|
|
9396
|
+
});
|
|
9397
|
+
const UpdateActionInstanceRequest = z.object({
|
|
9398
|
+
config: z.any().optional(),
|
|
9399
|
+
});
|
|
9400
|
+
const ActionRunResponse = z.object({
|
|
9401
|
+
output: z.any().optional(),
|
|
9402
|
+
logs: z.array(z.any()).optional(),
|
|
9403
|
+
});
|
|
9404
|
+
const ActionApiResponse = BaseAction.extend({
|
|
9405
|
+
integration: BaseIntegration.optional(),
|
|
9406
|
+
appliedToIntegrations: AppliedToIntegrations(BaseAction).optional(),
|
|
9407
|
+
});
|
|
9408
|
+
|
|
9409
|
+
const ActionInstanceApiResponse = BaseActionInstance.extend({
|
|
9410
|
+
user: BaseCustomer.optional(),
|
|
9411
|
+
parent: BaseAction.optional(),
|
|
9412
|
+
});
|
|
9413
|
+
|
|
9414
|
+
const ActionRunLogRecordApiResponse = BaseActionRunLogRecord.extend({
|
|
9415
|
+
action: BaseAction.optional(),
|
|
9416
|
+
integration: BaseIntegration.optional(),
|
|
9417
|
+
connection: BaseConnection.optional(),
|
|
9418
|
+
});
|
|
9419
|
+
|
|
9420
|
+
const FindConnectionsQuery = z
|
|
9421
|
+
.object({
|
|
9422
|
+
userId: z.string().optional(),
|
|
9423
|
+
isTest: zodBooleanCoercion().optional(),
|
|
9424
|
+
integrationKey: z.string().optional(),
|
|
9425
|
+
integrationId: z.string().optional(),
|
|
9426
|
+
includeArchived: zodBooleanCoercion().optional(),
|
|
9427
|
+
})
|
|
9428
|
+
.merge(PaginationQuery);
|
|
9429
|
+
const CreateConnectionRequest = z.object({
|
|
9430
|
+
name: z.string(),
|
|
9431
|
+
integrationId: z.string(),
|
|
9432
|
+
credentials: z.string().optional(),
|
|
9433
|
+
});
|
|
9434
|
+
const UpdateConnectionRequest = z.object({
|
|
9435
|
+
name: z.string().optional(),
|
|
9436
|
+
credentials: z.string().optional(),
|
|
9437
|
+
accessToken: z.string().optional(),
|
|
9438
|
+
});
|
|
9439
|
+
class FindConnectionsResponse extends PaginationResponse {
|
|
9440
|
+
}
|
|
9441
|
+
const ConnectionSelector = z.object({
|
|
9442
|
+
id: z.string().optional(),
|
|
9443
|
+
integrationKey: z.string().optional(),
|
|
9444
|
+
integrationId: z.string().optional(),
|
|
9445
|
+
connectionId: z.string().optional(),
|
|
9446
|
+
});
|
|
9447
|
+
const ConnectionApiResponse = BaseConnection.extend({
|
|
9448
|
+
user: BaseCustomer.optional(),
|
|
9449
|
+
integration: BaseIntegration.optional(),
|
|
9450
|
+
});
|
|
9451
|
+
const ConnectionMessagePayload = z.discriminatedUnion('type', [
|
|
9452
|
+
z.object({
|
|
9453
|
+
source: z.string(),
|
|
9454
|
+
requestId: z.string(),
|
|
9455
|
+
type: z.literal('newConnectionCreated'),
|
|
9456
|
+
connection: ConnectionApiResponse,
|
|
9457
|
+
}),
|
|
9458
|
+
z.object({
|
|
9459
|
+
source: z.string(),
|
|
9460
|
+
requestId: z.string(),
|
|
9461
|
+
type: z.literal('newConnectionFailure'),
|
|
9462
|
+
error: z.string(),
|
|
9463
|
+
errorData: ErrorDataSchema.optional(),
|
|
9464
|
+
}),
|
|
9465
|
+
]);
|
|
9466
|
+
|
|
9467
|
+
const ListDataSourcesForIntegrationQuery = z
|
|
9468
|
+
.object({
|
|
9469
|
+
universalDataSourceId: z.string().optional(),
|
|
9470
|
+
})
|
|
9471
|
+
.merge(PaginationQuery);
|
|
9472
|
+
const FindDataSourcesQuery = ListDataSourcesForIntegrationQuery.extend({
|
|
9473
|
+
integrationId: z.string().optional(),
|
|
9474
|
+
});
|
|
9475
|
+
const CreateDataSourceRequest = z.object({
|
|
9476
|
+
key: z.string(),
|
|
9477
|
+
name: z.string(),
|
|
9478
|
+
integrationId: z.string().optional(),
|
|
9479
|
+
udm: z.string().optional(),
|
|
9480
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
9481
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
9482
|
+
rootPath: z.string().optional(),
|
|
9483
|
+
defaultPath: z.string().optional(),
|
|
9484
|
+
collectionKey: z.string().optional(),
|
|
9485
|
+
collectionParameters: z.any().optional(),
|
|
9486
|
+
});
|
|
9487
|
+
const UpdateDataSourceRequest = z.object({
|
|
9488
|
+
key: z.string().optional(),
|
|
9489
|
+
name: z.string().optional(),
|
|
9490
|
+
archivedAt: z.string().optional(),
|
|
9491
|
+
udm: z.string().optional(),
|
|
9492
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
9493
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
9494
|
+
rootPath: z.string().optional(),
|
|
9495
|
+
defaultPath: z.string().optional(),
|
|
9496
|
+
});
|
|
9497
|
+
const FindDataSourceInstancesQuery = z
|
|
9498
|
+
.object({
|
|
9499
|
+
userId: z.string().optional(),
|
|
9500
|
+
dataSourceId: z.string().optional(),
|
|
9501
|
+
universalDataSourceId: z.string().optional(),
|
|
9502
|
+
connectionId: z.string().optional(),
|
|
9503
|
+
integrationKey: z.string().optional(),
|
|
9504
|
+
integrationId: z.string().optional(),
|
|
9505
|
+
})
|
|
9506
|
+
.merge(PaginationQuery);
|
|
9507
|
+
const CreateDataSourceInstanceRequest = z.object({
|
|
9508
|
+
dataSourceId: z.string(),
|
|
9509
|
+
connectionId: z.string(),
|
|
9510
|
+
path: z.string().optional(),
|
|
9511
|
+
});
|
|
9512
|
+
const UpdateDataSourceInstanceRequest = z.object({
|
|
9513
|
+
path: z.string().optional(),
|
|
9514
|
+
collectionKey: z.string().optional(),
|
|
9515
|
+
collectionParameters: z.any().optional(),
|
|
9516
|
+
pullUpdatesIntervalSeconds: z.number().optional(),
|
|
9517
|
+
fullSyncIntervalSeconds: z.number().optional(),
|
|
9518
|
+
subscribedTo: z
|
|
9519
|
+
.object({
|
|
9520
|
+
created: z.boolean().optional(),
|
|
9521
|
+
updated: z.boolean().optional(),
|
|
9522
|
+
deleted: z.boolean().optional(),
|
|
9523
|
+
})
|
|
9524
|
+
.optional(),
|
|
9525
|
+
});
|
|
9526
|
+
const FindDataSourceEventsQuery = z
|
|
9527
|
+
.object({
|
|
9528
|
+
userId: z.string().optional(),
|
|
9529
|
+
udm: z.string().optional(),
|
|
9530
|
+
dataSourceInstanceId: z.string().optional(),
|
|
9531
|
+
startDatetime: z.string().optional(),
|
|
9532
|
+
endDatetime: z.string().optional(),
|
|
9533
|
+
})
|
|
9534
|
+
.merge(PaginationQuery);
|
|
9535
|
+
const FindDataSourceSyncsQuery = z
|
|
9536
|
+
.object({
|
|
9537
|
+
userId: z.string().optional(),
|
|
9538
|
+
dataSourceId: z.string().optional(),
|
|
9539
|
+
dataSourceInstanceId: z.string().optional(),
|
|
9540
|
+
integrationId: z.string().optional(),
|
|
9541
|
+
connectionId: z.string().optional(),
|
|
9542
|
+
startedAfter: z.string().optional(),
|
|
9543
|
+
})
|
|
9544
|
+
.merge(PaginationQuery);
|
|
9545
|
+
const ListDataSourceInstancesForConnectionQuery = z
|
|
9546
|
+
.object({
|
|
9547
|
+
dataSourceId: z.string().optional(),
|
|
9548
|
+
})
|
|
9549
|
+
.merge(PaginationQuery);
|
|
9550
|
+
const FindDataSourceInstanceSyncsQuery = ListDataSourceInstancesForConnectionQuery.extend({
|
|
9551
|
+
userId: z.string().optional(),
|
|
9552
|
+
connectionId: z.string().optional(),
|
|
9553
|
+
integrationId: z.string().optional(),
|
|
9554
|
+
dataSourceInstanceId: z.string().optional(),
|
|
9555
|
+
});
|
|
9556
|
+
const DataSourceApiResponse = BaseDataSource.extend({
|
|
9557
|
+
integration: BaseIntegration.optional(),
|
|
9558
|
+
appliedToIntegrations: AppliedToIntegrations(BaseDataSource).optional(),
|
|
9559
|
+
});
|
|
9560
|
+
|
|
9561
|
+
const DataSourceInstanceApiResponse = BaseDataSourceInstance.extend({
|
|
9562
|
+
user: BaseCustomer.optional(),
|
|
9563
|
+
dataSource: BaseDataSource.optional(),
|
|
9564
|
+
connection: BaseConnection.optional(),
|
|
9565
|
+
integration: BaseIntegration.optional(),
|
|
9566
|
+
});
|
|
9567
|
+
|
|
9568
|
+
const ExternalEvent = BaseExternalEvent.extend({
|
|
9569
|
+
appliedToIntegrations: AppliedToIntegrations(BaseExternalEvent).optional(),
|
|
9570
|
+
});
|
|
9571
|
+
|
|
9572
|
+
const ListFlowsForIntegrationQuery = z
|
|
9573
|
+
.object({
|
|
9574
|
+
universalFlowId: z.string().optional(),
|
|
9575
|
+
})
|
|
9576
|
+
.merge(CommonListElementsQuery);
|
|
9577
|
+
const FindFlowsQuery = ListFlowsForIntegrationQuery.extend({
|
|
9578
|
+
integrationId: z.string().optional(),
|
|
9579
|
+
});
|
|
9580
|
+
const CreateFlowNodeRequest = z.object({
|
|
9581
|
+
type: z.string(),
|
|
9582
|
+
config: z.any().optional(),
|
|
9583
|
+
ui: z.any().optional(),
|
|
9584
|
+
links: z.array(z.lazy(() => z.any())).optional(),
|
|
9585
|
+
});
|
|
9586
|
+
const CreateFlowRequest = z.object({
|
|
9587
|
+
key: z.string(),
|
|
9588
|
+
name: z.string(),
|
|
9589
|
+
integrationId: z.string().optional(),
|
|
9590
|
+
nodes: z.record(z.string(), CreateFlowNodeRequest).optional(),
|
|
9591
|
+
parametersSchema: DataSchema.optional(),
|
|
9592
|
+
autoCreateInstances: z.boolean().optional(),
|
|
9593
|
+
});
|
|
9594
|
+
const UpdateFlowRequest = CreateFlowRequest.extend({
|
|
9595
|
+
archivedAt: z.string().optional(),
|
|
9596
|
+
});
|
|
9597
|
+
const ListFlowInstancesForConnectionQuery = z
|
|
9598
|
+
.object({
|
|
9599
|
+
flowId: z.string().optional(),
|
|
9600
|
+
flowKey: z.string().optional(),
|
|
9601
|
+
enabled: z.boolean().optional(),
|
|
9602
|
+
})
|
|
9603
|
+
.merge(CommonInstancesListQuery);
|
|
9604
|
+
const FindFlowInstancesQuery = ListFlowInstancesForConnectionQuery.merge(CommonIntegrationOrConnectionQuery);
|
|
9605
|
+
const ResetFlowInstanceOptions = z.object({
|
|
9606
|
+
name: z.boolean().optional(),
|
|
9607
|
+
nodes: z.record(z.string(), z.boolean()).optional(),
|
|
9608
|
+
allNodes: z.boolean().optional(),
|
|
9609
|
+
});
|
|
9610
|
+
const RunFlowOptions = z.object({
|
|
9611
|
+
nodeKey: z.string().optional(),
|
|
9612
|
+
input: z.any().optional(),
|
|
9613
|
+
returnImmediately: z.boolean().optional(),
|
|
9614
|
+
onUpdate: z.function().optional(),
|
|
9615
|
+
});
|
|
9616
|
+
const FlowApiResponse = BaseFlow.extend({
|
|
9617
|
+
integration: BaseIntegration.optional(),
|
|
9618
|
+
appliedToIntegrations: AppliedToIntegrations(BaseFlow).optional(),
|
|
9619
|
+
});
|
|
9620
|
+
const FlowInstanceApiResponse = BaseFlowInstance.extend({
|
|
9621
|
+
user: z.lazy(() => z.any()).optional(),
|
|
9622
|
+
connection: z.lazy(() => z.any()).optional(),
|
|
9623
|
+
flow: z.lazy(() => FlowApiResponse).optional(),
|
|
9624
|
+
integration: z.lazy(() => z.any()).optional(),
|
|
9625
|
+
});
|
|
9626
|
+
|
|
9627
|
+
const CreateFlowRunRequest = z.object({
|
|
9628
|
+
flowInstanceId: z.string(),
|
|
9629
|
+
nodeKey: z.string().optional(),
|
|
9630
|
+
input: z.any().optional(),
|
|
9631
|
+
});
|
|
9632
|
+
const FindFlowRunsQuery = PaginationQuery.extend({
|
|
9633
|
+
id: z.string().optional(),
|
|
9634
|
+
flowInstanceId: z.string().optional(),
|
|
9635
|
+
startNodeKey: z.string().optional(),
|
|
9636
|
+
flowId: z.string().optional(),
|
|
9637
|
+
universalFlowId: z.string().optional(),
|
|
9638
|
+
userId: z.string().optional(),
|
|
9639
|
+
state: z.nativeEnum(FlowRunState).optional(),
|
|
9640
|
+
integrationId: z.string().optional(),
|
|
9641
|
+
connectionId: z.string().optional(),
|
|
9642
|
+
startedAfter: z.string().optional(),
|
|
9643
|
+
});
|
|
9644
|
+
const FlowRunLaunchedByApi = z.object({
|
|
9645
|
+
type: z.nativeEnum(FlowRunLaunchedByTrigger),
|
|
9646
|
+
ids: z.array(z.string()).optional(),
|
|
9647
|
+
});
|
|
9648
|
+
const FlowRunApiResponse = BaseFlowRun.extend({
|
|
9649
|
+
flowInstance: BaseFlowInstance.optional(),
|
|
9650
|
+
connection: BaseConnection.optional(),
|
|
9651
|
+
integration: BaseIntegration.optional(),
|
|
9652
|
+
user: BaseCustomer.optional(),
|
|
9653
|
+
});
|
|
9654
|
+
const FindFlowRunsResponse = z.object({
|
|
9655
|
+
items: z.array(FlowRunApiResponse),
|
|
9656
|
+
cursor: z.string().optional(),
|
|
9657
|
+
});
|
|
9658
|
+
|
|
9659
|
+
const POPUP_ELEMENT_ID = '__integration-app-popup';
|
|
9660
|
+
const CONTAINER_ELEMENT_ID = '__integration-app-container';
|
|
9661
|
+
const CONTAINER_ELEMENT_CLASS = '__integration-app-container';
|
|
9662
|
+
const CONTAINER_ELEMENT_CLASS__LOADER = '__integration-app-container__loader';
|
|
9663
|
+
const BODY_CLASS = '__integration-app-open';
|
|
9664
|
+
const STYLES_ELEMENT_ID = '__integration-app-embed-styles';
|
|
9665
|
+
const OpenConfigurationOptions = z.object({
|
|
9666
|
+
onClose: z.function().optional(),
|
|
9667
|
+
showPoweredBy: z.boolean().optional(),
|
|
9668
|
+
});
|
|
9669
|
+
let IFRAME_START_SHOW_LOADER_TIME = 0;
|
|
9670
|
+
let IFRAME_SHOW_LOADER_TIMEOUT_ID;
|
|
9671
|
+
const IFRAME_SHOW_LOADER_MINIMAL_TIME = 500;
|
|
9672
|
+
const IFRAME_LAYOUT_SHIFT_TIME = 300;
|
|
9673
|
+
function showIframeLoader() {
|
|
9674
|
+
const container = getContainer();
|
|
9675
|
+
container === null || container === void 0 ? void 0 : container.classList.add(CONTAINER_ELEMENT_CLASS__LOADER);
|
|
9676
|
+
IFRAME_START_SHOW_LOADER_TIME = Date.now();
|
|
9677
|
+
}
|
|
9678
|
+
function hideIframeLoader(waitLayoutShift = IFRAME_LAYOUT_SHIFT_TIME) {
|
|
9679
|
+
if (IFRAME_SHOW_LOADER_TIMEOUT_ID) {
|
|
9680
|
+
clearTimeout(IFRAME_SHOW_LOADER_TIMEOUT_ID);
|
|
9681
|
+
}
|
|
9682
|
+
const delta = Date.now() - IFRAME_START_SHOW_LOADER_TIME;
|
|
9683
|
+
if (delta >= IFRAME_SHOW_LOADER_MINIMAL_TIME) {
|
|
9684
|
+
setTimeout(() => {
|
|
9685
|
+
const container = getContainer();
|
|
9686
|
+
container === null || container === void 0 ? void 0 : container.classList.remove(CONTAINER_ELEMENT_CLASS__LOADER);
|
|
9687
|
+
IFRAME_START_SHOW_LOADER_TIME = 0;
|
|
9688
|
+
}, waitLayoutShift);
|
|
9689
|
+
return;
|
|
9690
|
+
}
|
|
9691
|
+
else {
|
|
9692
|
+
const waitLayoutShift = delta >= IFRAME_LAYOUT_SHIFT_TIME ? 0 : IFRAME_LAYOUT_SHIFT_TIME - delta;
|
|
9693
|
+
const timeoutTime = IFRAME_SHOW_LOADER_MINIMAL_TIME - delta;
|
|
9694
|
+
IFRAME_SHOW_LOADER_TIMEOUT_ID = setTimeout(() => {
|
|
9695
|
+
hideIframeLoader(waitLayoutShift);
|
|
9696
|
+
}, timeoutTime);
|
|
9697
|
+
return;
|
|
9698
|
+
}
|
|
9699
|
+
}
|
|
9700
|
+
async function openIframe(uri, callbacks = {}, { mountTargetSelector } = {}) {
|
|
9701
|
+
close();
|
|
9702
|
+
init(mountTargetSelector);
|
|
9703
|
+
return new Promise((resolve) => {
|
|
9704
|
+
function complete(callback) {
|
|
9705
|
+
close(callback);
|
|
9706
|
+
resolve();
|
|
9707
|
+
}
|
|
9708
|
+
function doOpen() {
|
|
9709
|
+
const iframe = document.createElement('iframe');
|
|
9710
|
+
iframe.src = uri;
|
|
9711
|
+
iframe.id = POPUP_ELEMENT_ID;
|
|
9712
|
+
iframe.onload = () => {
|
|
9713
|
+
hideIframeLoader();
|
|
9714
|
+
};
|
|
9715
|
+
if (!!getContainer()) {
|
|
9716
|
+
document.body.classList.add(BODY_CLASS);
|
|
9717
|
+
showIframeLoader();
|
|
9718
|
+
appendToContainer(iframe);
|
|
9719
|
+
handleIframeUnmount(iframe);
|
|
9720
|
+
connectToChild({
|
|
9721
|
+
iframe,
|
|
9722
|
+
methods: {
|
|
9723
|
+
...callbacks,
|
|
9724
|
+
handshake: (...args) => {
|
|
9725
|
+
var _a;
|
|
9726
|
+
hideIframeLoader();
|
|
9727
|
+
(_a = callbacks === null || callbacks === void 0 ? void 0 : callbacks.handshake) === null || _a === void 0 ? void 0 : _a.call(callbacks, ...args);
|
|
9728
|
+
},
|
|
9729
|
+
close: () => complete(callbacks.onClose),
|
|
9730
|
+
},
|
|
9731
|
+
});
|
|
9732
|
+
}
|
|
9733
|
+
else {
|
|
9734
|
+
throw Error('Membrane container element not found. Was it manually removed?');
|
|
9735
|
+
}
|
|
9736
|
+
}
|
|
9737
|
+
if (document.readyState === 'complete' || document.readyState === 'interactive') {
|
|
9738
|
+
doOpen();
|
|
9739
|
+
}
|
|
9740
|
+
else {
|
|
9741
|
+
document.addEventListener('DOMContentLoaded', () => {
|
|
9742
|
+
doOpen();
|
|
9743
|
+
});
|
|
9744
|
+
}
|
|
9745
|
+
});
|
|
9746
|
+
}
|
|
9747
|
+
function close(callback) {
|
|
9748
|
+
document.body.classList.remove(BODY_CLASS);
|
|
9749
|
+
if (!!getContainer()) {
|
|
9750
|
+
deleteContainer();
|
|
9751
|
+
if (callback) {
|
|
9752
|
+
callback();
|
|
9753
|
+
}
|
|
9754
|
+
}
|
|
9755
|
+
}
|
|
9756
|
+
function init(mountTargetSelector) {
|
|
9757
|
+
var _a;
|
|
9758
|
+
injectStyles(mountTargetSelector);
|
|
9759
|
+
if (!!getContainer()) {
|
|
9760
|
+
return;
|
|
9761
|
+
}
|
|
9762
|
+
const container = createContainer();
|
|
9763
|
+
if (mountTargetSelector && document.querySelector(mountTargetSelector)) {
|
|
9764
|
+
(_a = document.querySelector(mountTargetSelector)) === null || _a === void 0 ? void 0 : _a.appendChild(container);
|
|
9765
|
+
}
|
|
9766
|
+
else {
|
|
9767
|
+
document.body.appendChild(container);
|
|
9768
|
+
}
|
|
9769
|
+
}
|
|
9770
|
+
function injectStyles(mountTargetSelector) {
|
|
9771
|
+
const hasCustomMountTarget = Boolean(mountTargetSelector && document.querySelector(mountTargetSelector));
|
|
9772
|
+
const styles = [
|
|
9773
|
+
`.${CONTAINER_ELEMENT_CLASS}:empty {
|
|
9774
|
+
display: none;
|
|
9775
|
+
}`,
|
|
9776
|
+
hasCustomMountTarget
|
|
9777
|
+
? `.${CONTAINER_ELEMENT_CLASS} {
|
|
9778
|
+
inset: 0;
|
|
9779
|
+
background: rgba(0, 0, 0, 0);
|
|
9780
|
+
transition: background 0.2s ease-out;
|
|
9781
|
+
display: flex;
|
|
9782
|
+
justify-content: center;
|
|
9783
|
+
align-items: center;
|
|
9784
|
+
width: 100%;
|
|
9785
|
+
height: 100%;
|
|
9786
|
+
}`
|
|
9787
|
+
: `.${CONTAINER_ELEMENT_CLASS} {
|
|
9788
|
+
position: fixed;
|
|
9789
|
+
inset: 0;
|
|
9790
|
+
z-index: 2147483647;
|
|
9791
|
+
display: flex;
|
|
9792
|
+
justify-content: center;
|
|
9793
|
+
align-items: center;
|
|
9794
|
+
pointer-events: auto;
|
|
9795
|
+
background: rgba(0, 0, 0, 0);
|
|
9796
|
+
transition: background 0.2s ease-out;
|
|
9797
|
+
}`,
|
|
9798
|
+
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER} {
|
|
9799
|
+
background: rgba(0, 0, 0, 0.8);
|
|
9800
|
+
}`,
|
|
9801
|
+
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER}::before {
|
|
9802
|
+
${hasCustomMountTarget ? 'position: absolute;' : ''}
|
|
9803
|
+
content: "";
|
|
9804
|
+
width: 5rem;
|
|
9805
|
+
height: 4rem;
|
|
9806
|
+
background-image: url('data:image/svg+xml,%3Csvg viewBox="0 0 32 22" fill="%23000" xmlns="http://www.w3.org/2000/svg" %3E%3Cdefs%3E%3Cmask id="a"%3E%3Crect width="100%25" height="100%25" fill="%23fff" /%3E%3Cpath d="M11.8 13.12a3 3 0 0 1 0-4.24l7.08-7.07a3 3 0 0 1 4.24 0l7.07 7.07a3 3 0 0 1 0 4.24l-7.07 7.07a3 3 0 0 1-4.24 0l-7.07-7.07Z"%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 21 11" to="-360 21 11" /%3E%3C/path%3E%3C/mask%3E%3Cmask id="b"%3E%3Crect width="100%25" height="100%25" fill="%23fff"/%3E%3Cpath fill-rule="evenodd" clip-rule="evenodd" d="M1.8 8.88a3 3 0 0 0 0 4.24l7.08 7.07a3 3 0 0 0 4.24 0l7.07-7.07a3 3 0 0 0 0-4.24L13.12 1.8a3 3 0 0 0-4.24 0L1.8 8.88Zm.71.7a2 2 0 0 0 0 2.83L9.6 19.5a2 2 0 0 0 2.82 0l7.08-7.08a2 2 0 0 0 0-2.82l-7.1-7.1a2 2 0 0 0-2.82 0L2.5 9.6Z" %3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 11 11" to="720 11 11" /%3E%3C/path%3E%3C/mask%3E%3C/defs%3E%3Cg mask="url(%23a)"%3E%3Cpath fill-rule="evenodd" clip-rule="evenodd" d="M1.8 8.88a3 3 0 0 0 0 4.24l7.08 7.07a3 3 0 0 0 4.24 0l7.07-7.07a3 3 0 0 0 0-4.24L13.12 1.8a3 3 0 0 0-4.24 0L1.8 8.88Zm.71.7a2 2 0 0 0 0 2.83L9.6 19.5a2 2 0 0 0 2.82 0l7.08-7.08a2 2 0 0 0 0-2.82l-7.1-7.1a2 2 0 0 0-2.82 0L2.5 9.6Z"%0A%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 11 11" to="720 11 11" /%3E%3C/path%3E%3C/g%3E%3Cg mask="url(%23b)"%3E%3Cpath d="M11.8 13.12a3 3 0 0 1 0-4.24l7.08-7.07a3 3 0 0 1 4.24 0l7.07 7.07a3 3 0 0 1 0 4.24l-7.07 7.07a3 3 0 0 1-4.24 0l-7.07-7.07Z"%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 21 11" to="-360 21 11" /%3E%3C/path%3E%3C/g%3E%3C/svg%3E');
|
|
9807
|
+
background-size: contain;
|
|
9808
|
+
background-repeat: no-repeat;
|
|
9809
|
+
background-position: center;
|
|
9810
|
+
filter: invert(1);
|
|
9811
|
+
}`,
|
|
9812
|
+
`.${CONTAINER_ELEMENT_CLASS} iframe {
|
|
9813
|
+
${hasCustomMountTarget ? '' : 'position: absolute;'}
|
|
9814
|
+
width: 100%;
|
|
9815
|
+
height: 100%;
|
|
9816
|
+
border-width: 0;
|
|
9817
|
+
|
|
9818
|
+
/* fix transparent bg, because iframe document has light scheme */
|
|
9819
|
+
color-scheme: light;
|
|
9820
|
+
}`,
|
|
9821
|
+
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER} iframe {
|
|
9822
|
+
visibility: hidden;
|
|
9823
|
+
}`,
|
|
9824
|
+
!hasCustomMountTarget
|
|
9825
|
+
? `body.${BODY_CLASS} {
|
|
9826
|
+
overflow: hidden;
|
|
9827
|
+
}`
|
|
9828
|
+
: '',
|
|
9829
|
+
];
|
|
9830
|
+
let styleElement = document.getElementById(STYLES_ELEMENT_ID);
|
|
9831
|
+
if (!styleElement) {
|
|
9832
|
+
styleElement = document.createElement('style');
|
|
9833
|
+
styleElement.id = STYLES_ELEMENT_ID;
|
|
9834
|
+
styleElement.type = 'text/css';
|
|
9835
|
+
document.head.appendChild(styleElement);
|
|
9836
|
+
}
|
|
9837
|
+
styleElement.textContent = styles.join('\n');
|
|
9838
|
+
}
|
|
9839
|
+
function removeInjectedStyles() {
|
|
9840
|
+
const stylesElement = document.getElementById(STYLES_ELEMENT_ID);
|
|
9841
|
+
if (stylesElement) {
|
|
9842
|
+
stylesElement.remove();
|
|
9843
|
+
}
|
|
9844
|
+
}
|
|
9845
|
+
function createContainer() {
|
|
9846
|
+
const container = document.createElement('div');
|
|
9847
|
+
container.id = CONTAINER_ELEMENT_ID;
|
|
9848
|
+
container.classList.add(CONTAINER_ELEMENT_CLASS);
|
|
9849
|
+
return container;
|
|
9850
|
+
}
|
|
9851
|
+
function getContainer() {
|
|
9852
|
+
return document.getElementById(CONTAINER_ELEMENT_ID);
|
|
9853
|
+
}
|
|
9854
|
+
function appendToContainer(el) {
|
|
9855
|
+
const container = getContainer();
|
|
9856
|
+
container === null || container === void 0 ? void 0 : container.appendChild(el);
|
|
9857
|
+
}
|
|
9858
|
+
function deleteContainer() {
|
|
9859
|
+
const container = getContainer();
|
|
9860
|
+
if (container) {
|
|
9861
|
+
container.remove();
|
|
9862
|
+
}
|
|
9863
|
+
removeInjectedStyles();
|
|
9864
|
+
}
|
|
9865
|
+
function handleIframeUnmount(iframe) {
|
|
9866
|
+
const observer = new MutationObserver((mutationsList) => {
|
|
9867
|
+
for (const mutation of mutationsList) {
|
|
9868
|
+
for (const removedNode of mutation.removedNodes) {
|
|
9869
|
+
if (removedNode instanceof HTMLElement && removedNode.id === POPUP_ELEMENT_ID) {
|
|
9870
|
+
observer.disconnect();
|
|
9871
|
+
deleteContainer();
|
|
9872
|
+
return;
|
|
9873
|
+
}
|
|
9874
|
+
}
|
|
9875
|
+
}
|
|
9876
|
+
});
|
|
9877
|
+
const parent = iframe.parentNode;
|
|
9878
|
+
if (parent) {
|
|
9879
|
+
observer.observe(parent, {
|
|
9880
|
+
childList: true,
|
|
9881
|
+
});
|
|
9882
|
+
}
|
|
9883
|
+
else {
|
|
9884
|
+
console.warn(`iframe with ID "${POPUP_ELEMENT_ID}" has no parent node`);
|
|
9885
|
+
}
|
|
9886
|
+
}
|
|
8640
9887
|
|
|
8641
|
-
|
|
8642
|
-
|
|
8643
|
-
|
|
8644
|
-
|
|
8645
|
-
|
|
8646
|
-
|
|
8647
|
-
|
|
9888
|
+
const CreateIntegrationRequest = z.object({
|
|
9889
|
+
name: z.string().optional(),
|
|
9890
|
+
key: z.string(),
|
|
9891
|
+
baseUri: z.string(),
|
|
9892
|
+
logoUri: z.string(),
|
|
9893
|
+
});
|
|
9894
|
+
const UpdateIntegrationRequest = z.object({
|
|
9895
|
+
name: z.string().optional(),
|
|
9896
|
+
key: z.string().optional(),
|
|
9897
|
+
baseUri: z.string().optional(),
|
|
9898
|
+
logoUri: z.string().optional(),
|
|
9899
|
+
});
|
|
9900
|
+
const FindIntegrationsQuery = z.object({}).merge(PaginationQuery).merge(SearchQuery);
|
|
9901
|
+
const OpenNewConnectionOptions = z
|
|
9902
|
+
.object({
|
|
9903
|
+
allowMultipleConnections: z.boolean().optional(),
|
|
9904
|
+
name: z.string().optional(),
|
|
9905
|
+
connectorParameters: z.any().optional(),
|
|
9906
|
+
})
|
|
9907
|
+
.merge(OpenConfigurationOptions);
|
|
9908
|
+
const IntegrationApiResponse = BaseIntegration.extend({
|
|
9909
|
+
connection: BaseConnection.optional(),
|
|
9910
|
+
spec: z.any().optional(),
|
|
9911
|
+
});
|
|
8648
9912
|
|
|
8649
|
-
var
|
|
8650
|
-
(function (
|
|
8651
|
-
|
|
8652
|
-
|
|
8653
|
-
|
|
8654
|
-
|
|
8655
|
-
|
|
8656
|
-
|
|
8657
|
-
|
|
8658
|
-
|
|
8659
|
-
|
|
8660
|
-
|
|
8661
|
-
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
|
|
8665
|
-
|
|
8666
|
-
|
|
8667
|
-
|
|
8668
|
-
|
|
8669
|
-
|
|
8670
|
-
WorkspaceElementType["DataLinkTable"] = "data-link-table";
|
|
8671
|
-
WorkspaceElementType["DataLinkTableInstance"] = "data-link-table-instance";
|
|
8672
|
-
WorkspaceElementType["AppEventType"] = "app-event-type";
|
|
8673
|
-
WorkspaceElementType["AppEventSubscription"] = "app-event-subscription";
|
|
8674
|
-
WorkspaceElementType["AppDataSchema"] = "app-data-schema";
|
|
8675
|
-
WorkspaceElementType["AppDataSchemaInstance"] = "app-data-schema-instance";
|
|
8676
|
-
WorkspaceElementType["ExternalEventSubscription"] = "external-event-subscription";
|
|
8677
|
-
WorkspaceElementType["ExternalEventLogRecord"] = "external-event-log-record";
|
|
8678
|
-
WorkspaceElementType["ExternalEventPull"] = "external-event-pull";
|
|
8679
|
-
WorkspaceElementType["DataCollection"] = "data-collection";
|
|
8680
|
-
WorkspaceElementType["Screen"] = "screen";
|
|
8681
|
-
WorkspaceElementType["ActionRunLogRecord"] = "action-run-log-record";
|
|
8682
|
-
})(WorkspaceElementType || (WorkspaceElementType = {}));
|
|
8683
|
-
var WorkspaceEventType;
|
|
8684
|
-
(function (WorkspaceEventType) {
|
|
8685
|
-
WorkspaceEventType["ConnectionCreated"] = "connection.created";
|
|
8686
|
-
WorkspaceEventType["ConnectionDeleted"] = "connection.deleted";
|
|
8687
|
-
WorkspaceEventType["ConnectionDisconnected"] = "connection.disconnected";
|
|
8688
|
-
WorkspaceEventType["ConnectionReconnected"] = "connection.reconnected";
|
|
8689
|
-
WorkspaceEventType["FlowRunQueued"] = "flowRun.queued";
|
|
8690
|
-
WorkspaceEventType["FlowRunStarted"] = "flowRun.started";
|
|
8691
|
-
WorkspaceEventType["FlowRunCompleted"] = "flowRun.completed";
|
|
8692
|
-
WorkspaceEventType["FlowRunFailed"] = "flowRun.failed";
|
|
8693
|
-
WorkspaceEventType["FlowRunStopped"] = "flowRun.stopped";
|
|
8694
|
-
})(WorkspaceEventType || (WorkspaceEventType = {}));
|
|
8695
|
-
var WorkspaceElementState;
|
|
8696
|
-
(function (WorkspaceElementState) {
|
|
8697
|
-
WorkspaceElementState["CONFIGURATION_ERROR"] = "CONFIGURATION_ERROR";
|
|
8698
|
-
WorkspaceElementState["SETUP_FAILED"] = "SETUP_FAILED";
|
|
8699
|
-
WorkspaceElementState["READY"] = "READY";
|
|
8700
|
-
})(WorkspaceElementState || (WorkspaceElementState = {}));
|
|
8701
|
-
var WorkspaceElementDependencyType;
|
|
8702
|
-
(function (WorkspaceElementDependencyType) {
|
|
8703
|
-
WorkspaceElementDependencyType["Configuration"] = "CONFIGURATION";
|
|
8704
|
-
WorkspaceElementDependencyType["Parent"] = "PARENT";
|
|
8705
|
-
})(WorkspaceElementDependencyType || (WorkspaceElementDependencyType = {}));
|
|
8706
|
-
const BaseWorkspaceElement = z.object({
|
|
8707
|
-
id: z.string(),
|
|
9913
|
+
var IntegrationElementLevel;
|
|
9914
|
+
(function (IntegrationElementLevel) {
|
|
9915
|
+
IntegrationElementLevel["UNIVERSAL"] = "universal";
|
|
9916
|
+
IntegrationElementLevel["CONNECTOR"] = "connector";
|
|
9917
|
+
IntegrationElementLevel["CONNECTION"] = "connection";
|
|
9918
|
+
})(IntegrationElementLevel || (IntegrationElementLevel = {}));
|
|
9919
|
+
var IntegrationElementType;
|
|
9920
|
+
(function (IntegrationElementType) {
|
|
9921
|
+
IntegrationElementType["APP_DATA_SCHEMA"] = "app-data-schema";
|
|
9922
|
+
IntegrationElementType["APP_EVENT_TYPE"] = "app-event-type";
|
|
9923
|
+
IntegrationElementType["DATA_SOURCE"] = "data-source";
|
|
9924
|
+
IntegrationElementType["SCHEMA"] = "schema";
|
|
9925
|
+
IntegrationElementType["FIELD_MAPPING"] = "field-mapping";
|
|
9926
|
+
IntegrationElementType["FLOW"] = "flow";
|
|
9927
|
+
IntegrationElementType["INTEGRATION"] = "integration";
|
|
9928
|
+
IntegrationElementType["ACTION"] = "action";
|
|
9929
|
+
IntegrationElementType["DATA_LINK_TABLE"] = "data-link-table";
|
|
9930
|
+
IntegrationElementType["EXTERNAL_EVENT"] = "external-event";
|
|
9931
|
+
})(IntegrationElementType || (IntegrationElementType = {}));
|
|
9932
|
+
|
|
9933
|
+
const ScenarioToDoApi = z.object({
|
|
8708
9934
|
name: z.string(),
|
|
9935
|
+
description: z.string(),
|
|
9936
|
+
isComplete: z.boolean(),
|
|
8709
9937
|
});
|
|
8710
|
-
const
|
|
9938
|
+
const ScenarioElementApi = z.object({
|
|
9939
|
+
id: z.string(),
|
|
9940
|
+
type: z.nativeEnum(IntegrationElementType),
|
|
9941
|
+
element: z.any().optional(),
|
|
9942
|
+
});
|
|
9943
|
+
const FindScenariosQuery = z.object({}).merge(SearchQuery).merge(PaginationQuery);
|
|
9944
|
+
const CreateScenarioRequest = z.object({
|
|
9945
|
+
name: z.string(),
|
|
8711
9946
|
key: z.string(),
|
|
8712
|
-
|
|
8713
|
-
|
|
9947
|
+
elements: z.array(ScenarioElementApi).optional(),
|
|
9948
|
+
todos: z.array(ScenarioToDoApi).optional(),
|
|
9949
|
+
});
|
|
9950
|
+
const UpdateScenarioRequest = z.object({
|
|
9951
|
+
name: z.string().optional(),
|
|
9952
|
+
key: z.string().optional(),
|
|
9953
|
+
elements: z.array(ScenarioElementApi).optional(),
|
|
9954
|
+
todos: z.array(ScenarioToDoApi).optional(),
|
|
9955
|
+
});
|
|
9956
|
+
const ScenarioApiResponse = BaseScenario.extend({
|
|
9957
|
+
appliedToIntegrations: z.array(BaseIntegration).optional(),
|
|
8714
9958
|
});
|
|
8715
9959
|
|
|
8716
|
-
|
|
8717
|
-
(function (ActionRunLogStatus) {
|
|
8718
|
-
ActionRunLogStatus["SUCCESS"] = "success";
|
|
8719
|
-
ActionRunLogStatus["ERROR"] = "error";
|
|
8720
|
-
})(ActionRunLogStatus || (ActionRunLogStatus = {}));
|
|
9960
|
+
const ScreenApiResponse = BaseScreen;
|
|
8721
9961
|
|
|
8722
|
-
|
|
8723
|
-
|
|
9962
|
+
const CreateCustomerRequest = z.object({
|
|
9963
|
+
name: z.string().optional(),
|
|
9964
|
+
internalId: z.string(),
|
|
9965
|
+
fields: z.any().optional(),
|
|
9966
|
+
credentials: z.any().optional(),
|
|
9967
|
+
});
|
|
9968
|
+
const UpdateCustomerRequest = z.object({
|
|
9969
|
+
name: z.string().optional(),
|
|
9970
|
+
internalId: z.string().optional(),
|
|
9971
|
+
fields: z.any().optional(),
|
|
9972
|
+
credentials: z.any().optional(),
|
|
9973
|
+
});
|
|
9974
|
+
const FindCustomersQuery = z
|
|
9975
|
+
.object({
|
|
9976
|
+
isTest: zodBooleanCoercion().optional(),
|
|
9977
|
+
})
|
|
9978
|
+
.merge(PaginationQuery)
|
|
9979
|
+
.merge(SearchQuery);
|
|
9980
|
+
const CustomerSelector = z.object({ id: z.string() });
|
|
9981
|
+
const CustomerApiResponse = BaseCustomer;
|
|
9982
|
+
|
|
9983
|
+
const FieldMappingApiResponse = BaseFieldMapping.extend({
|
|
9984
|
+
integration: BaseIntegration.optional(),
|
|
9985
|
+
appliedToIntegrations: AppliedToIntegrations(BaseFieldMapping).optional(),
|
|
9986
|
+
});
|
|
8724
9987
|
|
|
8725
|
-
|
|
8726
|
-
|
|
8727
|
-
|
|
8728
|
-
|
|
8729
|
-
|
|
8730
|
-
|
|
9988
|
+
const FieldMappingInstanceApiResponse = BaseFieldMappingInstance.extend({
|
|
9989
|
+
user: BaseCustomer.optional(),
|
|
9990
|
+
connection: BaseConnection.optional(),
|
|
9991
|
+
integration: BaseIntegration.optional(),
|
|
9992
|
+
fieldMapping: BaseFieldMapping.optional(),
|
|
9993
|
+
dataSourceInstance: DataSourceInstanceApiResponse.optional(),
|
|
9994
|
+
});
|
|
8731
9995
|
|
|
8732
|
-
|
|
8733
|
-
(function (FlowRunState) {
|
|
8734
|
-
FlowRunState["QUEUED"] = "queued";
|
|
8735
|
-
FlowRunState["RUNNING"] = "running";
|
|
8736
|
-
FlowRunState["COMPLETED"] = "completed";
|
|
8737
|
-
FlowRunState["STOPPED"] = "stopped";
|
|
8738
|
-
FlowRunState["FAILED"] = "failed";
|
|
8739
|
-
})(FlowRunState || (FlowRunState = {}));
|
|
8740
|
-
var FlowRunLaunchedByTrigger;
|
|
8741
|
-
(function (FlowRunLaunchedByTrigger) {
|
|
8742
|
-
FlowRunLaunchedByTrigger["ApiTrigger"] = "api-trigger";
|
|
8743
|
-
FlowRunLaunchedByTrigger["ScheduleTrigger"] = "schedule-trigger";
|
|
8744
|
-
FlowRunLaunchedByTrigger["AppEventTrigger"] = "app-event-trigger";
|
|
8745
|
-
FlowRunLaunchedByTrigger["DataSourceTrigger"] = "data-source-trigger";
|
|
8746
|
-
FlowRunLaunchedByTrigger["ExternalEvent"] = "external-event";
|
|
8747
|
-
})(FlowRunLaunchedByTrigger || (FlowRunLaunchedByTrigger = {}));
|
|
9996
|
+
const DataLinkTableApiResponse = BaseDataLinkTable;
|
|
8748
9997
|
|
|
8749
|
-
|
|
8750
|
-
|
|
8751
|
-
|
|
8752
|
-
|
|
8753
|
-
|
|
8754
|
-
|
|
8755
|
-
ScenarioTemplateCategory["DataEnrichment"] = "data-enrichment";
|
|
8756
|
-
})(ScenarioTemplateCategory || (ScenarioTemplateCategory = {}));
|
|
9998
|
+
const DataLinkTableInstanceApiResponse = BaseDataLinkTableInstance.extend({
|
|
9999
|
+
dataLinkTable: BaseDataLinkTable.optional(),
|
|
10000
|
+
connection: BaseConnection.optional(),
|
|
10001
|
+
integration: BaseIntegration.optional(),
|
|
10002
|
+
user: BaseCustomer.optional(),
|
|
10003
|
+
});
|
|
8757
10004
|
|
|
8758
|
-
|
|
8759
|
-
|
|
8760
|
-
|
|
8761
|
-
|
|
8762
|
-
|
|
8763
|
-
|
|
8764
|
-
|
|
8765
|
-
|
|
8766
|
-
|
|
8767
|
-
|
|
8768
|
-
|
|
10005
|
+
const AppEventTypeApiResponse = BaseAppEventType;
|
|
10006
|
+
|
|
10007
|
+
const AppEventSubscriptionApiResponse = BaseAppEventSubscription.extend({
|
|
10008
|
+
appEventType: BaseAppEventType.optional(),
|
|
10009
|
+
user: BaseCustomer.optional(),
|
|
10010
|
+
});
|
|
10011
|
+
|
|
10012
|
+
const AppDataSchemaApiResponse = BaseAppDataSchema;
|
|
10013
|
+
|
|
10014
|
+
const AppDataSchemaInstanceApiResponse = BaseAppDataSchemaInstance.extend({
|
|
10015
|
+
user: BaseCustomer.optional(),
|
|
10016
|
+
appDataSchema: BaseAppDataSchema.optional(),
|
|
10017
|
+
});
|
|
10018
|
+
|
|
10019
|
+
const ListExternalEventLogRecordsQuery = CommonListElementsQuery.extend({
|
|
10020
|
+
connectionId: z.string().optional(),
|
|
10021
|
+
integrationId: z.string().optional(),
|
|
10022
|
+
externalEventSubscriptionId: z.string().optional(),
|
|
10023
|
+
status: z.nativeEnum(ExternalEventLogStatus).optional(),
|
|
10024
|
+
});
|
|
10025
|
+
const ExternalEventLogRecordApiResponse = BaseExternalEventLogRecord.extend({
|
|
10026
|
+
user: BaseCustomer.optional(),
|
|
10027
|
+
externalEventSubscription: BaseExternalEventSubscription.optional(),
|
|
10028
|
+
integration: BaseIntegration.optional(),
|
|
10029
|
+
connection: BaseConnection.optional(),
|
|
10030
|
+
});
|
|
10031
|
+
|
|
10032
|
+
const ListExternalEventPullsQuery = CommonListElementsQuery.extend({
|
|
10033
|
+
connectionId: z.string().optional(),
|
|
10034
|
+
integrationId: z.string().optional(),
|
|
10035
|
+
externalEventSubscriptionId: z.string().optional(),
|
|
10036
|
+
status: z.nativeEnum(ExternalEventPullStatus).optional(),
|
|
10037
|
+
});
|
|
10038
|
+
const ExternalEventPullApiResponse = BaseExternalEventPull.extend({
|
|
10039
|
+
user: BaseCustomer.optional(),
|
|
10040
|
+
externalEventSubscription: BaseExternalEventSubscription.optional(),
|
|
10041
|
+
integration: BaseIntegration.optional(),
|
|
10042
|
+
connection: BaseConnection.optional(),
|
|
10043
|
+
});
|
|
10044
|
+
|
|
10045
|
+
const ExternalEventSubscriptionApiResponse = BaseExternalEventSubscription.extend({
|
|
10046
|
+
user: BaseCustomer.optional(),
|
|
10047
|
+
connection: BaseConnection.optional(),
|
|
10048
|
+
integration: BaseIntegration.optional(),
|
|
10049
|
+
});
|
|
10050
|
+
|
|
10051
|
+
const AppEventLogRecordApiResponse = z.object({
|
|
10052
|
+
id: z.string(),
|
|
10053
|
+
name: z.string().optional(),
|
|
10054
|
+
userId: z.string(),
|
|
10055
|
+
user: BaseCustomer.optional(),
|
|
10056
|
+
appEventTypeId: z.string(),
|
|
10057
|
+
appEventType: BaseAppEventType.optional(),
|
|
10058
|
+
appEventSubscriptionId: z.string(),
|
|
10059
|
+
appEventSubscription: BaseAppEventSubscription.optional(),
|
|
10060
|
+
event: z.any(),
|
|
10061
|
+
datetime: z.string(),
|
|
10062
|
+
launchedFlowRunIds: z.array(z.string()),
|
|
10063
|
+
});
|
|
8769
10064
|
|
|
8770
10065
|
class DependencyError extends IntegrationAppError {
|
|
8771
10066
|
constructor(arg, workspaceElementReference) {
|
|
@@ -8838,7 +10133,7 @@ function getChildNodeKeys(flow, nodeKey) {
|
|
|
8838
10133
|
return (nodeLinks
|
|
8839
10134
|
.map((nodeLink) => nodeLink.key)
|
|
8840
10135
|
.filter(Boolean)
|
|
8841
|
-
.filter((k) => { var _a; return !!((_a = flow.nodes) === null || _a === void 0 ? void 0 : _a[k]); }));
|
|
10136
|
+
.filter((k) => { var _a; return k && !!((_a = flow.nodes) === null || _a === void 0 ? void 0 : _a[k]); }));
|
|
8842
10137
|
}
|
|
8843
10138
|
function getDownstreamNodeKeys(flow, nodeKey) {
|
|
8844
10139
|
const linkedKeys = getChildNodeKeys(flow, nodeKey);
|
|
@@ -9029,6 +10324,12 @@ const WorkspaceElementSpecs = {
|
|
|
9029
10324
|
name: 'App Event Subscription',
|
|
9030
10325
|
namePlural: 'App Event Subscriptions',
|
|
9031
10326
|
},
|
|
10327
|
+
[WorkspaceElementType.AppEventLogRecord]: {
|
|
10328
|
+
type: WorkspaceElementType.AppEventLogRecord,
|
|
10329
|
+
apiPath: 'app-events',
|
|
10330
|
+
name: 'App Event Log Record',
|
|
10331
|
+
namePlural: 'App Event Log Records',
|
|
10332
|
+
},
|
|
9032
10333
|
[WorkspaceElementType.AppDataSchema]: {
|
|
9033
10334
|
type: WorkspaceElementType.AppDataSchema,
|
|
9034
10335
|
apiPath: 'app-data-schemas',
|
|
@@ -9411,83 +10712,33 @@ class DataForm {
|
|
|
9411
10712
|
|
|
9412
10713
|
function parseDate(value) {
|
|
9413
10714
|
let timestamp;
|
|
9414
|
-
if (typeof value === 'number') {
|
|
9415
|
-
timestamp = value;
|
|
9416
|
-
}
|
|
9417
|
-
else if (typeof value === 'string') {
|
|
9418
|
-
timestamp = Date.parse(value);
|
|
9419
|
-
if (isNaN(timestamp)) {
|
|
9420
|
-
timestamp = undefined;
|
|
9421
|
-
}
|
|
9422
|
-
if (!timestamp && Number(value) > 1000000000) {
|
|
9423
|
-
timestamp = Number(value);
|
|
9424
|
-
}
|
|
9425
|
-
}
|
|
9426
|
-
if (timestamp) {
|
|
9427
|
-
return timestampToDate(timestamp);
|
|
9428
|
-
}
|
|
9429
|
-
else {
|
|
9430
|
-
return undefined;
|
|
9431
|
-
}
|
|
9432
|
-
}
|
|
9433
|
-
function timestampToDate(value) {
|
|
9434
|
-
if (Math.round(value).toString().length < 13) {
|
|
9435
|
-
return new Date(value * 1000);
|
|
9436
|
-
}
|
|
9437
|
-
else {
|
|
9438
|
-
return new Date(value);
|
|
9439
|
-
}
|
|
9440
|
-
}
|
|
9441
|
-
|
|
9442
|
-
var HttpRequestMethod;
|
|
9443
|
-
(function (HttpRequestMethod) {
|
|
9444
|
-
HttpRequestMethod["GET"] = "GET";
|
|
9445
|
-
HttpRequestMethod["POST"] = "POST";
|
|
9446
|
-
HttpRequestMethod["PATCH"] = "PATCH";
|
|
9447
|
-
HttpRequestMethod["PUT"] = "PUT";
|
|
9448
|
-
HttpRequestMethod["DELETE"] = "DELETE";
|
|
9449
|
-
})(HttpRequestMethod || (HttpRequestMethod = {}));
|
|
9450
|
-
const HTTP_REQUEST_SCHEMA = {
|
|
9451
|
-
type: 'object',
|
|
9452
|
-
properties: {
|
|
9453
|
-
uri: { type: 'string' },
|
|
9454
|
-
method: {
|
|
9455
|
-
type: 'string',
|
|
9456
|
-
enum: ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'],
|
|
9457
|
-
},
|
|
9458
|
-
body: {},
|
|
9459
|
-
query: {
|
|
9460
|
-
type: 'object',
|
|
9461
|
-
section: true,
|
|
9462
|
-
additionalProperties: true,
|
|
9463
|
-
},
|
|
9464
|
-
headers: {
|
|
9465
|
-
type: 'object',
|
|
9466
|
-
section: true,
|
|
9467
|
-
additionalProperties: true,
|
|
9468
|
-
},
|
|
9469
|
-
},
|
|
9470
|
-
};
|
|
9471
|
-
|
|
9472
|
-
var IntegrationElementLevel;
|
|
9473
|
-
(function (IntegrationElementLevel) {
|
|
9474
|
-
IntegrationElementLevel["UNIVERSAL"] = "universal";
|
|
9475
|
-
IntegrationElementLevel["CONNECTOR"] = "connector";
|
|
9476
|
-
IntegrationElementLevel["CONNECTION"] = "connection";
|
|
9477
|
-
})(IntegrationElementLevel || (IntegrationElementLevel = {}));
|
|
9478
|
-
var IntegrationElementType;
|
|
9479
|
-
(function (IntegrationElementType) {
|
|
9480
|
-
IntegrationElementType["APP_DATA_SCHEMA"] = "app-data-schema";
|
|
9481
|
-
IntegrationElementType["APP_EVENT_TYPE"] = "app-event-type";
|
|
9482
|
-
IntegrationElementType["DATA_SOURCE"] = "data-source";
|
|
9483
|
-
IntegrationElementType["SCHEMA"] = "schema";
|
|
9484
|
-
IntegrationElementType["FIELD_MAPPING"] = "field-mapping";
|
|
9485
|
-
IntegrationElementType["FLOW"] = "flow";
|
|
9486
|
-
IntegrationElementType["INTEGRATION"] = "integration";
|
|
9487
|
-
IntegrationElementType["ACTION"] = "action";
|
|
9488
|
-
IntegrationElementType["DATA_LINK_TABLE"] = "data-link-table";
|
|
9489
|
-
IntegrationElementType["EXTERNAL_EVENT"] = "external-event";
|
|
9490
|
-
})(IntegrationElementType || (IntegrationElementType = {}));
|
|
10715
|
+
if (typeof value === 'number') {
|
|
10716
|
+
timestamp = value;
|
|
10717
|
+
}
|
|
10718
|
+
else if (typeof value === 'string') {
|
|
10719
|
+
timestamp = Date.parse(value);
|
|
10720
|
+
if (isNaN(timestamp)) {
|
|
10721
|
+
timestamp = undefined;
|
|
10722
|
+
}
|
|
10723
|
+
if (!timestamp && Number(value) > 1000000000) {
|
|
10724
|
+
timestamp = Number(value);
|
|
10725
|
+
}
|
|
10726
|
+
}
|
|
10727
|
+
if (timestamp) {
|
|
10728
|
+
return timestampToDate(timestamp);
|
|
10729
|
+
}
|
|
10730
|
+
else {
|
|
10731
|
+
return undefined;
|
|
10732
|
+
}
|
|
10733
|
+
}
|
|
10734
|
+
function timestampToDate(value) {
|
|
10735
|
+
if (Math.round(value).toString().length < 13) {
|
|
10736
|
+
return new Date(value * 1000);
|
|
10737
|
+
}
|
|
10738
|
+
else {
|
|
10739
|
+
return new Date(value);
|
|
10740
|
+
}
|
|
10741
|
+
}
|
|
9491
10742
|
|
|
9492
10743
|
var UsageType;
|
|
9493
10744
|
(function (UsageType) {
|
|
@@ -9619,7 +10870,7 @@ function getFlowRunVariableSchema() {
|
|
|
9619
10870
|
var WorkspaceOnboardingStep;
|
|
9620
10871
|
(function (WorkspaceOnboardingStep) {
|
|
9621
10872
|
WorkspaceOnboardingStep["AddConnectors"] = "add-connectors";
|
|
9622
|
-
WorkspaceOnboardingStep["ConnectYourApp"] = "
|
|
10873
|
+
WorkspaceOnboardingStep["ConnectYourApp"] = "first-connection";
|
|
9623
10874
|
WorkspaceOnboardingStep["BuildIntegrations"] = "build-integrations";
|
|
9624
10875
|
WorkspaceOnboardingStep["Completed"] = "completed";
|
|
9625
10876
|
})(WorkspaceOnboardingStep || (WorkspaceOnboardingStep = {}));
|
|
@@ -9627,7 +10878,14 @@ var WorkspaceNotificationType;
|
|
|
9627
10878
|
(function (WorkspaceNotificationType) {
|
|
9628
10879
|
WorkspaceNotificationType["WorkspaceUpdate"] = "workspace-update";
|
|
9629
10880
|
WorkspaceNotificationType["CopilotActivity"] = "copilot-activity";
|
|
10881
|
+
WorkspaceNotificationType["LocalClientUpdate"] = "local-client-update";
|
|
9630
10882
|
})(WorkspaceNotificationType || (WorkspaceNotificationType = {}));
|
|
10883
|
+
var LimitUnits;
|
|
10884
|
+
(function (LimitUnits) {
|
|
10885
|
+
LimitUnits["Number"] = "number";
|
|
10886
|
+
LimitUnits["Msec"] = "msec";
|
|
10887
|
+
LimitUnits["Mb"] = "Mb";
|
|
10888
|
+
})(LimitUnits || (LimitUnits = {}));
|
|
9631
10889
|
var WorkspaceType;
|
|
9632
10890
|
(function (WorkspaceType) {
|
|
9633
10891
|
WorkspaceType["PRODUCTION"] = "production";
|
|
@@ -9924,231 +11182,6 @@ class IntegrationLevelActionsListAccessor extends IntegrationLevelElementsListAc
|
|
|
9924
11182
|
}
|
|
9925
11183
|
}
|
|
9926
11184
|
|
|
9927
|
-
const POPUP_ELEMENT_ID = '__integration-app-popup';
|
|
9928
|
-
const CONTAINER_ELEMENT_ID = '__integration-app-container';
|
|
9929
|
-
const CONTAINER_ELEMENT_CLASS = '__integration-app-container';
|
|
9930
|
-
const CONTAINER_ELEMENT_CLASS__LOADER = '__integration-app-container__loader';
|
|
9931
|
-
const BODY_CLASS = '__integration-app-open';
|
|
9932
|
-
const STYLES_ELEMENT_ID = '__integration-app-embed-styles';
|
|
9933
|
-
let IFRAME_START_SHOW_LOADER_TIME = 0;
|
|
9934
|
-
let IFRAME_SHOW_LOADER_TIMEOUT_ID;
|
|
9935
|
-
const IFRAME_SHOW_LOADER_MINIMAL_TIME = 500;
|
|
9936
|
-
const IFRAME_LAYOUT_SHIFT_TIME = 300;
|
|
9937
|
-
function showIframeLoader() {
|
|
9938
|
-
const container = getContainer();
|
|
9939
|
-
container === null || container === void 0 ? void 0 : container.classList.add(CONTAINER_ELEMENT_CLASS__LOADER);
|
|
9940
|
-
IFRAME_START_SHOW_LOADER_TIME = Date.now();
|
|
9941
|
-
}
|
|
9942
|
-
function hideIframeLoader(waitLayoutShift = IFRAME_LAYOUT_SHIFT_TIME) {
|
|
9943
|
-
if (IFRAME_SHOW_LOADER_TIMEOUT_ID) {
|
|
9944
|
-
clearTimeout(IFRAME_SHOW_LOADER_TIMEOUT_ID);
|
|
9945
|
-
}
|
|
9946
|
-
const delta = Date.now() - IFRAME_START_SHOW_LOADER_TIME;
|
|
9947
|
-
if (delta >= IFRAME_SHOW_LOADER_MINIMAL_TIME) {
|
|
9948
|
-
setTimeout(() => {
|
|
9949
|
-
const container = getContainer();
|
|
9950
|
-
container === null || container === void 0 ? void 0 : container.classList.remove(CONTAINER_ELEMENT_CLASS__LOADER);
|
|
9951
|
-
IFRAME_START_SHOW_LOADER_TIME = 0;
|
|
9952
|
-
}, waitLayoutShift);
|
|
9953
|
-
return;
|
|
9954
|
-
}
|
|
9955
|
-
else {
|
|
9956
|
-
const waitLayoutShift = delta >= IFRAME_LAYOUT_SHIFT_TIME ? 0 : IFRAME_LAYOUT_SHIFT_TIME - delta;
|
|
9957
|
-
const timeoutTime = IFRAME_SHOW_LOADER_MINIMAL_TIME - delta;
|
|
9958
|
-
IFRAME_SHOW_LOADER_TIMEOUT_ID = setTimeout(() => {
|
|
9959
|
-
hideIframeLoader(waitLayoutShift);
|
|
9960
|
-
}, timeoutTime);
|
|
9961
|
-
return;
|
|
9962
|
-
}
|
|
9963
|
-
}
|
|
9964
|
-
async function openIframe(uri, callbacks = {}, { mountTargetSelector } = {}) {
|
|
9965
|
-
close();
|
|
9966
|
-
init(mountTargetSelector);
|
|
9967
|
-
return new Promise((resolve) => {
|
|
9968
|
-
function complete(callback) {
|
|
9969
|
-
close(callback);
|
|
9970
|
-
resolve();
|
|
9971
|
-
}
|
|
9972
|
-
function doOpen() {
|
|
9973
|
-
const iframe = document.createElement('iframe');
|
|
9974
|
-
iframe.src = uri;
|
|
9975
|
-
iframe.id = POPUP_ELEMENT_ID;
|
|
9976
|
-
iframe.onload = () => {
|
|
9977
|
-
hideIframeLoader();
|
|
9978
|
-
};
|
|
9979
|
-
if (!!getContainer()) {
|
|
9980
|
-
document.body.classList.add(BODY_CLASS);
|
|
9981
|
-
showIframeLoader();
|
|
9982
|
-
appendToContainer(iframe);
|
|
9983
|
-
handleIframeUnmount(iframe);
|
|
9984
|
-
connectToChild({
|
|
9985
|
-
iframe,
|
|
9986
|
-
methods: {
|
|
9987
|
-
...callbacks,
|
|
9988
|
-
handshake: (...args) => {
|
|
9989
|
-
var _a;
|
|
9990
|
-
hideIframeLoader();
|
|
9991
|
-
(_a = callbacks === null || callbacks === void 0 ? void 0 : callbacks.handshake) === null || _a === void 0 ? void 0 : _a.call(callbacks, ...args);
|
|
9992
|
-
},
|
|
9993
|
-
close: () => complete(callbacks.onClose),
|
|
9994
|
-
},
|
|
9995
|
-
});
|
|
9996
|
-
}
|
|
9997
|
-
else {
|
|
9998
|
-
throw Error('Membrane container element not found. Was it manually removed?');
|
|
9999
|
-
}
|
|
10000
|
-
}
|
|
10001
|
-
if (document.readyState === 'complete' || document.readyState === 'interactive') {
|
|
10002
|
-
doOpen();
|
|
10003
|
-
}
|
|
10004
|
-
else {
|
|
10005
|
-
document.addEventListener('DOMContentLoaded', () => {
|
|
10006
|
-
doOpen();
|
|
10007
|
-
});
|
|
10008
|
-
}
|
|
10009
|
-
});
|
|
10010
|
-
}
|
|
10011
|
-
function close(callback) {
|
|
10012
|
-
document.body.classList.remove(BODY_CLASS);
|
|
10013
|
-
if (!!getContainer()) {
|
|
10014
|
-
deleteContainer();
|
|
10015
|
-
if (callback) {
|
|
10016
|
-
callback();
|
|
10017
|
-
}
|
|
10018
|
-
}
|
|
10019
|
-
}
|
|
10020
|
-
function init(mountTargetSelector) {
|
|
10021
|
-
var _a;
|
|
10022
|
-
injectStyles(mountTargetSelector);
|
|
10023
|
-
if (!!getContainer()) {
|
|
10024
|
-
return;
|
|
10025
|
-
}
|
|
10026
|
-
const container = createContainer();
|
|
10027
|
-
if (mountTargetSelector && document.querySelector(mountTargetSelector)) {
|
|
10028
|
-
(_a = document.querySelector(mountTargetSelector)) === null || _a === void 0 ? void 0 : _a.appendChild(container);
|
|
10029
|
-
}
|
|
10030
|
-
else {
|
|
10031
|
-
document.body.appendChild(container);
|
|
10032
|
-
}
|
|
10033
|
-
}
|
|
10034
|
-
function injectStyles(mountTargetSelector) {
|
|
10035
|
-
const hasCustomMountTarget = Boolean(mountTargetSelector && document.querySelector(mountTargetSelector));
|
|
10036
|
-
const styles = [
|
|
10037
|
-
`.${CONTAINER_ELEMENT_CLASS}:empty {
|
|
10038
|
-
display: none;
|
|
10039
|
-
}`,
|
|
10040
|
-
hasCustomMountTarget
|
|
10041
|
-
? `.${CONTAINER_ELEMENT_CLASS} {
|
|
10042
|
-
inset: 0;
|
|
10043
|
-
background: rgba(0, 0, 0, 0);
|
|
10044
|
-
transition: background 0.2s ease-out;
|
|
10045
|
-
display: flex;
|
|
10046
|
-
justify-content: center;
|
|
10047
|
-
align-items: center;
|
|
10048
|
-
width: 100%;
|
|
10049
|
-
height: 100%;
|
|
10050
|
-
}`
|
|
10051
|
-
: `.${CONTAINER_ELEMENT_CLASS} {
|
|
10052
|
-
position: fixed;
|
|
10053
|
-
inset: 0;
|
|
10054
|
-
z-index: 2147483647;
|
|
10055
|
-
display: flex;
|
|
10056
|
-
justify-content: center;
|
|
10057
|
-
align-items: center;
|
|
10058
|
-
pointer-events: auto;
|
|
10059
|
-
background: rgba(0, 0, 0, 0);
|
|
10060
|
-
transition: background 0.2s ease-out;
|
|
10061
|
-
}`,
|
|
10062
|
-
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER} {
|
|
10063
|
-
background: rgba(0, 0, 0, 0.8);
|
|
10064
|
-
}`,
|
|
10065
|
-
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER}::before {
|
|
10066
|
-
${hasCustomMountTarget ? 'position: absolute;' : ''}
|
|
10067
|
-
content: "";
|
|
10068
|
-
width: 5rem;
|
|
10069
|
-
height: 4rem;
|
|
10070
|
-
background-image: url('data:image/svg+xml,%3Csvg viewBox="0 0 32 22" fill="%23000" xmlns="http://www.w3.org/2000/svg" %3E%3Cdefs%3E%3Cmask id="a"%3E%3Crect width="100%25" height="100%25" fill="%23fff" /%3E%3Cpath d="M11.8 13.12a3 3 0 0 1 0-4.24l7.08-7.07a3 3 0 0 1 4.24 0l7.07 7.07a3 3 0 0 1 0 4.24l-7.07 7.07a3 3 0 0 1-4.24 0l-7.07-7.07Z"%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 21 11" to="-360 21 11" /%3E%3C/path%3E%3C/mask%3E%3Cmask id="b"%3E%3Crect width="100%25" height="100%25" fill="%23fff"/%3E%3Cpath fill-rule="evenodd" clip-rule="evenodd" d="M1.8 8.88a3 3 0 0 0 0 4.24l7.08 7.07a3 3 0 0 0 4.24 0l7.07-7.07a3 3 0 0 0 0-4.24L13.12 1.8a3 3 0 0 0-4.24 0L1.8 8.88Zm.71.7a2 2 0 0 0 0 2.83L9.6 19.5a2 2 0 0 0 2.82 0l7.08-7.08a2 2 0 0 0 0-2.82l-7.1-7.1a2 2 0 0 0-2.82 0L2.5 9.6Z" %3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 11 11" to="720 11 11" /%3E%3C/path%3E%3C/mask%3E%3C/defs%3E%3Cg mask="url(%23a)"%3E%3Cpath fill-rule="evenodd" clip-rule="evenodd" d="M1.8 8.88a3 3 0 0 0 0 4.24l7.08 7.07a3 3 0 0 0 4.24 0l7.07-7.07a3 3 0 0 0 0-4.24L13.12 1.8a3 3 0 0 0-4.24 0L1.8 8.88Zm.71.7a2 2 0 0 0 0 2.83L9.6 19.5a2 2 0 0 0 2.82 0l7.08-7.08a2 2 0 0 0 0-2.82l-7.1-7.1a2 2 0 0 0-2.82 0L2.5 9.6Z"%0A%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 11 11" to="720 11 11" /%3E%3C/path%3E%3C/g%3E%3Cg mask="url(%23b)"%3E%3Cpath d="M11.8 13.12a3 3 0 0 1 0-4.24l7.08-7.07a3 3 0 0 1 4.24 0l7.07 7.07a3 3 0 0 1 0 4.24l-7.07 7.07a3 3 0 0 1-4.24 0l-7.07-7.07Z"%3E%3CanimateTransform attributeName="transform" attributeType="XML" type="rotate" repeatCount="indefinite" calcMode="spline" keyTimes="0;1" dur="5s" keySplines="0 0 0.1 1" from="0 21 11" to="-360 21 11" /%3E%3C/path%3E%3C/g%3E%3C/svg%3E');
|
|
10071
|
-
background-size: contain;
|
|
10072
|
-
background-repeat: no-repeat;
|
|
10073
|
-
background-position: center;
|
|
10074
|
-
filter: invert(1);
|
|
10075
|
-
}`,
|
|
10076
|
-
`.${CONTAINER_ELEMENT_CLASS} iframe {
|
|
10077
|
-
${hasCustomMountTarget ? '' : 'position: absolute;'}
|
|
10078
|
-
width: 100%;
|
|
10079
|
-
height: 100%;
|
|
10080
|
-
border-width: 0;
|
|
10081
|
-
|
|
10082
|
-
/* fix transparent bg, because iframe document has light scheme */
|
|
10083
|
-
color-scheme: light;
|
|
10084
|
-
}`,
|
|
10085
|
-
`.${CONTAINER_ELEMENT_CLASS}.${CONTAINER_ELEMENT_CLASS__LOADER} iframe {
|
|
10086
|
-
visibility: hidden;
|
|
10087
|
-
}`,
|
|
10088
|
-
!hasCustomMountTarget
|
|
10089
|
-
? `body.${BODY_CLASS} {
|
|
10090
|
-
overflow: hidden;
|
|
10091
|
-
}`
|
|
10092
|
-
: '',
|
|
10093
|
-
];
|
|
10094
|
-
let styleElement = document.getElementById(STYLES_ELEMENT_ID);
|
|
10095
|
-
if (!styleElement) {
|
|
10096
|
-
styleElement = document.createElement('style');
|
|
10097
|
-
styleElement.id = STYLES_ELEMENT_ID;
|
|
10098
|
-
styleElement.type = 'text/css';
|
|
10099
|
-
document.head.appendChild(styleElement);
|
|
10100
|
-
}
|
|
10101
|
-
styleElement.textContent = styles.join('\n');
|
|
10102
|
-
}
|
|
10103
|
-
function removeInjectedStyles() {
|
|
10104
|
-
const stylesElement = document.getElementById(STYLES_ELEMENT_ID);
|
|
10105
|
-
if (stylesElement) {
|
|
10106
|
-
stylesElement.remove();
|
|
10107
|
-
}
|
|
10108
|
-
}
|
|
10109
|
-
function createContainer() {
|
|
10110
|
-
const container = document.createElement('div');
|
|
10111
|
-
container.id = CONTAINER_ELEMENT_ID;
|
|
10112
|
-
container.classList.add(CONTAINER_ELEMENT_CLASS);
|
|
10113
|
-
return container;
|
|
10114
|
-
}
|
|
10115
|
-
function getContainer() {
|
|
10116
|
-
return document.getElementById(CONTAINER_ELEMENT_ID);
|
|
10117
|
-
}
|
|
10118
|
-
function appendToContainer(el) {
|
|
10119
|
-
const container = getContainer();
|
|
10120
|
-
container === null || container === void 0 ? void 0 : container.appendChild(el);
|
|
10121
|
-
}
|
|
10122
|
-
function deleteContainer() {
|
|
10123
|
-
const container = getContainer();
|
|
10124
|
-
if (container) {
|
|
10125
|
-
container.remove();
|
|
10126
|
-
}
|
|
10127
|
-
removeInjectedStyles();
|
|
10128
|
-
}
|
|
10129
|
-
function handleIframeUnmount(iframe) {
|
|
10130
|
-
const observer = new MutationObserver((mutationsList) => {
|
|
10131
|
-
for (const mutation of mutationsList) {
|
|
10132
|
-
for (const removedNode of mutation.removedNodes) {
|
|
10133
|
-
if (removedNode instanceof HTMLElement && removedNode.id === POPUP_ELEMENT_ID) {
|
|
10134
|
-
observer.disconnect();
|
|
10135
|
-
deleteContainer();
|
|
10136
|
-
return;
|
|
10137
|
-
}
|
|
10138
|
-
}
|
|
10139
|
-
}
|
|
10140
|
-
});
|
|
10141
|
-
const parent = iframe.parentNode;
|
|
10142
|
-
if (parent) {
|
|
10143
|
-
observer.observe(parent, {
|
|
10144
|
-
childList: true,
|
|
10145
|
-
});
|
|
10146
|
-
}
|
|
10147
|
-
else {
|
|
10148
|
-
console.warn(`iframe with ID "${POPUP_ELEMENT_ID}" has no parent node`);
|
|
10149
|
-
}
|
|
10150
|
-
}
|
|
10151
|
-
|
|
10152
11185
|
class ConnectionLevelElementAccessor {
|
|
10153
11186
|
constructor(client, connectionSelector, selector, elementKey, query) {
|
|
10154
11187
|
this.client = client;
|
|
@@ -11370,6 +12403,11 @@ class ExternalEventSubscriptionAccessor {
|
|
|
11370
12403
|
}
|
|
11371
12404
|
}
|
|
11372
12405
|
|
|
12406
|
+
var WorkspaceSyncEventType;
|
|
12407
|
+
(function (WorkspaceSyncEventType) {
|
|
12408
|
+
WorkspaceSyncEventType["ElementUpdate"] = "element-update";
|
|
12409
|
+
})(WorkspaceSyncEventType || (WorkspaceSyncEventType = {}));
|
|
12410
|
+
|
|
11373
12411
|
function decodeJWT(token) {
|
|
11374
12412
|
if (typeof token !== 'string') {
|
|
11375
12413
|
return undefined;
|
|
@@ -11463,6 +12501,13 @@ class IntegrationAppApiClient {
|
|
|
11463
12501
|
async delete(uri, data, options) {
|
|
11464
12502
|
return this.makeApiRequest('DELETE', { ...(options !== null && options !== void 0 ? options : {}), url: uri, data });
|
|
11465
12503
|
}
|
|
12504
|
+
async createEventSource(uri, queryParams) {
|
|
12505
|
+
const token = await this.getToken();
|
|
12506
|
+
const allParams = { ...queryParams, token };
|
|
12507
|
+
const queryString = qs.stringify(omitBy(allParams, isEmptyValue));
|
|
12508
|
+
const urlWithToken = `${this.apiUri}/${uri}?${queryString}`;
|
|
12509
|
+
return new EventSource(urlWithToken);
|
|
12510
|
+
}
|
|
11466
12511
|
async getEmbedUri(page, pageParams, options) {
|
|
11467
12512
|
var _a;
|
|
11468
12513
|
const paramsWithToken = {
|
|
@@ -11643,6 +12688,9 @@ class IntegrationAppClient extends IntegrationAppApiClient {
|
|
|
11643
12688
|
get scenarios() {
|
|
11644
12689
|
return new ScenariosAccessor(this);
|
|
11645
12690
|
}
|
|
12691
|
+
async createEventSource(uri, queryParams) {
|
|
12692
|
+
return super.createEventSource(uri, queryParams);
|
|
12693
|
+
}
|
|
11646
12694
|
async connectionRequest(connectionId, uri, data) {
|
|
11647
12695
|
return this.post(`connections/${connectionId}/execute-request`, {
|
|
11648
12696
|
key: uri,
|
|
@@ -11653,5 +12701,5 @@ class IntegrationAppClient extends IntegrationAppApiClient {
|
|
|
11653
12701
|
|
|
11654
12702
|
injectFormulaCatalog(getFormula, isFormula, hasFormulas);
|
|
11655
12703
|
|
|
11656
|
-
export { ACTIONS, AccessDeniedError, ActionAccessor, ActionDependencyType, ActionInstanceAccessor, ActionInstanceSetupError, ActionInstancesAccessor, ActionRunError, ActionRunLogStatus, ActionRunStatus, ActionType, ActionsAccessor, AlertSeverity, AlertStatus, AlertType, ApiRequestSpecSchema, AppDataSchemaAccessor, AppDataSchemaInstanceAccessor, AppDataSchemaInstancesAccessor, AppDataSchemasAccessor, AppEventSubscriptionAccessor, AppEventSubscriptionsAccessor, AppEventTypeAccessor, AppEventTypesAccessor, BadRequestError, BadRequestErrorKey, BaseMembraneInterface, BaseWorkspaceElement, CONNECTOR_AUTH_TYPES, CONNECTOR_CATEGORIES, CONNECTOR_DATA_DIR, CONNECTOR_DOCS_DIR, CONNECTOR_EVENTS_DIR, CONNECTOR_GLOBAL_WEBHOOKS_DIR, CONNECTOR_METHOD_IMPLEMENTATION_SUFFIXES, CONNECTOR_OPERATIONS_DIR, ConcurrencyError, ConcurrencyErrorKey, ConfigurationError, ConfigurationState, ConnectionAccessor, ConnectionDataCollectionAccessor, ConnectionError, ConnectionErrorKey, ConnectionLevelActionAccessor, ConnectionLevelActionsAccessor, ConnectionLevelDataSourceAccessor, ConnectionLevelDataSourcesAccessor, ConnectionLevelFieldMappingAccessor, ConnectionLevelFieldMappingsAccessor, ConnectionLevelFlowAccessor, ConnectionLevelFlowsAccessor, ConnectionOperationAccessor, ConnectionProxy, ConnectionSpec, ConnectionsAccessor, ConnectorAuthMethodTypes, ConnectorCopilotFileChunkTopicKey, ConnectorCopilotSuggestionType, ConnectorDataCollectionEventImplementationType, ConnectorDataCollectionMethodKeys, ConnectorDataLocationTypes, ConnectorEventHandlerMethods, ConnectorEventImplementationType, ConnectorMethodImplementationType, ConnectorOperationMethodImplementationTypes, ConnectorStatus, CopilotActionStatus, CopilotActionType, CopilotActivityScope, CopilotActivityType, CopilotTaskStatus, CopilotTaskType, CreateConnectionRequest, CustomCodeError, CustomerAccessor, CustomersAccessor, DATA_RECORD_SCHEMA, DEFAULT_FULL_SYNC_INTERVAL_SECONDS, DEFAULT_PULL_UPDATES_INTERVAL_SECONDS, DataBuilderFormulaType, DataCollectionCreateRequestSchema, DataCollectionCreateResponseSchema, DataCollectionCreateSpecSchema, DataCollectionDeleteRequestSchema, DataCollectionDeleteResponseSchema, DataCollectionDeleteSpecSchema, DataCollectionEventType, DataCollectionEventTypeSpecSchema, DataCollectionEventsSpecSchema, DataCollectionFindByIdRequestSchema, DataCollectionFindByIdResponseSchema, DataCollectionFindByIdSpecSchema, DataCollectionFindRequestSchema, DataCollectionFindResponseSchema, DataCollectionFindSpecSchema, DataCollectionListRequestSchema, DataCollectionListResponseDrilldownSchema, DataCollectionListResponseSchema, DataCollectionListSpecSchema, DataCollectionMatchRequestSchema, DataCollectionMatchResponseSchema, DataCollectionMatchSpecSchema, DataCollectionMethodRequestSchema, DataCollectionMethodSpecSchema, DataCollectionSearchRequestSchema, DataCollectionSearchResponseSchema, DataCollectionSearchSpecSchema, DataCollectionSpecSchema, DataCollectionUdmSpecSchema, DataCollectionUdmsSpecSchema, DataCollectionUpdateRequestSchema, DataCollectionUpdateResponseSchema, DataCollectionUpdateSpecSchema, DataFilterCondition, DataForm, DataLinkDirection, DataLinkTableAccessor, DataLinkTableInstanceAccessor, DataLinkTableInstancesAccessor, DataLinkTablesAccessor, DataLocationMethodImplementationTypes, DataLocationTypeCollection, DataLocatorStep, DataLocatorStepArrayItem, DataLocatorStepObjectProperty, DataLocatorStepType, DataRecordSchema, DataSchemaSchema, DataSourceAccessor, DataSourceInstanceAccessor, DataSourceInstancesAccessor, DataSourcesAccessor, DependencyError, DownstreamFlowNodeRunSchema, EDITABLE_LIMITS, ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor, ErrorData, ErrorDataSchema, ErrorType, ExternalEventLogStatus, ExternalEventPullStatus, ExternalEventSubscriptionAccessor, ExternalEventSubscriptionStatus, ExternalEventSubscriptionType, ExternalEventSubscriptionsAccessor, ExternalEventType, FLOW_NODE_SPECS, FieldMappingAccessor, FieldMappingDirection, FieldMappingInstanceAccessor, FieldMappingInstancesAccessor, FieldMappingsAccessor, FindConnectionsResponse, FlowAccessor, FlowInstanceAccessor, FlowInstanceNodeState, FlowInstanceSetupError, FlowInstancesAccessor, FlowNodeRunOutputMetadataSchema, FlowNodeRunOutputSchema, FlowNodeRunOutputWithoutDownstreamRunsSchema, FlowNodeRunParametersSchema, FlowNodeRunRecordSchema, FlowNodeRunRecordWithoutOutputsDataSchema, FlowNodeRunResultSchema, FlowNodeRunStatus, FlowNodeSpec, FlowNodeType, FlowRunAccessor, FlowRunError, FlowRunLaunchedByTrigger, FlowRunNodeState, FlowRunState, FlowRunsAccessor, FlowsAccessor, Formula, HTTP_REQUEST_SCHEMA, HttpRequestMethod, IncomingWebhooksState, IntegrationAccessor, IntegrationAppClient, IntegrationAppError, IntegrationElementLevel, IntegrationElementType, IntegrationLevelActionAccessor, IntegrationLevelActionsListAccessor, IntegrationLevelDataSourceAccessor, IntegrationLevelDataSourcesListAccessor, IntegrationLevelFieldMappingAccessor, IntegrationLevelFieldMappingsListAccessor, IntegrationLevelFlowAccessor, IntegrationLevelFlowsListAccessor, IntegrationsAccessor, InternalError, InvalidLocatorError, LogRecordType, MIN_FULL_SYNC_INTERVAL_SECONDS, MIN_PULL_UPDATES_INTERVAL_SECONDS, NotAuthenticatedError, NotFoundError, OAUTH1_CONFIG_SCHEMA, OAUTH_CONFIG_SCHEMA, OrgLimitsType, OrgUserRole, OrgUserStatus, PARALLEL_EXECUTION_LIMITS, PaginationResponse, RATE_LIMITS, RateLimitExceededError, ScenarioAccessor, ScenarioTemplateCategory, ScenariosAccessor, ScreenAccessor, ScreenBlockType, ScreenType, ScreensAccessor, SelfAccessor, UDM, UNIFIED_DATA_MODELS, UnitRunError, UpdateConnectionRequest, UpstreamFlowNodeRunSchema, UsageType, UserAccessor, UsersAccessor, WORKSPACE_SIZE_LIMITS, WebhookTypeEnum, WorkspaceElementDependencyType, WorkspaceElementSpecs, WorkspaceElementState, WorkspaceElementType, WorkspaceEventType, WorkspaceNotificationType, WorkspaceOnboardingStep, WorkspaceType, addRequiredFieldsToSchema, addUdmFallbackFields, backwardCompatibleFilterMatch, buildData, buildDataSchema, buildValue, compressDataSchema, createCompoundSchema, createFlowInstanceSchema, createObjectFromLocators, createOrUpdateConnection, createSchema, dataCollectionEventTypeToExternalEventType, dataLocationParametersMatch, doesMatchFilter, excludeFieldsFromSchema, excludeFieldsFromValue, excludeReadOnlyFieldsFromSchema, excludeWriteOnlyFieldsFromSchema, externalEventTypeToDataCollectionEventType, extractFieldLocator, extractIntegrationAppErrorData, findUdmCollectionMapping, findUdmDefaultCollection, findUdmRootLocation, findValueLocators, generateExampleFromSchema, getActionInstanceVariableSchema, getActionRunTimeVariablesSchema, getAllEventMethodFilePaths, getChildNodeKeys, getDataCollectionCreateFields, getDataCollectionUpdateFields, getDataLocationMethodPath, getDownstreamNodeKeys, getErrorFromData, getEventMethodFileKey, getFilterFieldValuesByLocator, getFlowInstanceNodeDependency, getFlowNode, getFlowNodeConfigTimeVariablesSchema, getFlowNodeDescription, getFlowNodeRunTimeVariablesSchema, getFlowNodeSpec, getFlowNodeTitle, getFormula$1 as getFormula, getFormulaLocators, getFormula as getFormula_internalDoNotUse, getFullNameForLocator, getFullTitleForLocator, getIconUriForLocator, getLocatorsFromData, getLocatorsFromSchema, getMissingRequiredFields, getNameComponentsForLocator, getNameForLocator, getNodeInputSchema, getOperatorsBySchema, getParentNodeKeys, getReferenceCollectionPathForSchema, getReferenceCollectionPointerForSchema, getRequiredFieldsFromSchema, getRootNodeKeys, getSchemaByLocator, getSchemaFromValue, getUpstreamNodeKeys, getValueAtLocator, getValueByLocator, getVariableLocators, getWritableFieldsSchema, hasCycles, hasFormulas$1 as hasFormulas, hasFormulas as hasFormulas_internalDoNotUse, injectFormulaCatalog, isDataActionType, isDataLocationMethodSupported, isFormula$1 as isFormula, isFormula as isFormula_internalDoNotUse, isIntegrationAppError, isObject, isSameDataLocation, isSchemaEmpty, isStream, isValidLocator, locatorToField, locatorToSteps, locatorToString, makeDataLocationOperationPath, makeDataLocationPath, makeDataRecordSchema, makeObjectPropertyLocator, makeSchemaForLocator, mergeSchemas, mergeWithFormulas, nonEmptyObjectProperties, parseDataLocationPath, parseDate, patchSchema, pickFieldsFromSchema, pickFieldsFromValue, populateSchemaTitles, processCopy, removeNonExistentVars, removeRequiredFieldsFromSchema, resolveFormulas, resolveValue, schemaAllowsCustomValue, schemaHasFixedValues, schemaHasProperties, schemaIsNumber, schemaIsScalar, schemaTypeFromValue, schemaWithTitle, setSchemaAtLocator, setValueAtLocator, stepsToLocator, streamToString, transformVariablesWith, transformVars, truncateData, unwrapSchema, unwrapSchemas, updateFlowInstanceSchema, updateImpliedSchema, valueToSchema, valueToString, walkSchema, wrapAnyOfSchema };
|
|
12704
|
+
export { ACTIONS, AccessDeniedError, ActionAccessor, ActionApiResponse, ActionDependency, ActionDependencyType, ActionInstanceAccessor, ActionInstanceApiResponse, ActionInstanceSetupError, ActionInstancesAccessor, ActionRunError, ActionRunLogRecordApiResponse, ActionRunLogStatus, ActionRunResponse, ActionType, ActionsAccessor, AlertSeverity, AlertStatus, AlertType, ApiRequestSpec, AppDataSchemaAccessor, AppDataSchemaApiResponse, AppDataSchemaInstanceAccessor, AppDataSchemaInstanceApiResponse, AppDataSchemaInstancesAccessor, AppDataSchemasAccessor, AppEventLogRecordApiResponse, AppEventSubscriptionAccessor, AppEventSubscriptionApiResponse, AppEventSubscriptionsAccessor, AppEventTypeAccessor, AppEventTypeApiResponse, AppEventTypesAccessor, AppliedToIntegrations, BadRequestError, BadRequestErrorKey, BaseAction, BaseActionInstance, BaseActionRunLogRecord, BaseAppDataSchema, BaseAppDataSchemaInstance, BaseAppEventSubscription, BaseAppEventType, BaseConnection, BaseCustomer, BaseDataLinkTable, BaseDataLinkTableInstance, BaseDataSource, BaseDataSourceInstance, BaseExternalEvent, BaseExternalEventLogRecord, BaseExternalEventPull, BaseExternalEventSubscription, BaseFieldMapping, BaseFieldMappingInstance, BaseFlow, BaseFlowInstance, BaseFlowRun, BaseIntegration, BaseMembraneInterface, BaseScenario, BaseScreen, BaseWorkspaceElement, CONNECTOR_AUTH_TYPES, CONNECTOR_CATEGORIES, CONNECTOR_DATA_DIR, CONNECTOR_DOCS_DIR, CONNECTOR_EVENTS_DIR, CONNECTOR_GLOBAL_WEBHOOKS_DIR, CONNECTOR_METHOD_IMPLEMENTATION_SUFFIXES, CONNECTOR_OPERATIONS_DIR, CommonInstancesListQuery, CommonIntegrationOrConnectionQuery, CommonListElementsQuery, ConcurrencyError, ConcurrencyErrorKey, ConfigurationError, ConfigurationState, ConnectionAccessor, ConnectionApiResponse, ConnectionDataCollectionAccessor, ConnectionError, ConnectionErrorKey, ConnectionLevelActionAccessor, ConnectionLevelActionsAccessor, ConnectionLevelDataSourceAccessor, ConnectionLevelDataSourcesAccessor, ConnectionLevelFieldMappingAccessor, ConnectionLevelFieldMappingsAccessor, ConnectionLevelFlowAccessor, ConnectionLevelFlowsAccessor, ConnectionMessagePayload, ConnectionOperationAccessor, ConnectionProxy, ConnectionRequest, ConnectionSelector, ConnectionSpec, ConnectionsAccessor, ConnectorAuthMethodTypes, ConnectorCopilotFileChunkTopicKey, ConnectorCopilotSuggestionType, ConnectorDataCollectionEventImplementationType, ConnectorDataCollectionMethodKeys, ConnectorDataLocationTypes, ConnectorEventHandlerMethods, ConnectorEventImplementationType, ConnectorMethodImplementationType, ConnectorOperationMethodImplementationTypes, ConnectorStatus, CopilotActionStatus, CopilotActionType, CopilotActivityScope, CopilotActivityType, CopilotTaskStatus, CopilotTaskType, CreateActionInstanceRequest, CreateActionRequest, CreateConnectionRequest, CreateCustomerRequest, CreateDataSourceInstanceRequest, CreateDataSourceRequest, CreateFlowNodeRequest, CreateFlowRequest, CreateFlowRunRequest, CreateIntegrationRequest, CreateScenarioRequest, CustomCodeError, CustomerAccessor, CustomerApiResponse, CustomerSelector, CustomersAccessor, DATA_RECORD_SCHEMA, DEFAULT_FULL_SYNC_INTERVAL_SECONDS, DEFAULT_PULL_UPDATES_INTERVAL_SECONDS, DataBuilderFormulaType, DataCollectionCreateRequest, DataCollectionCreateResponse, DataCollectionCreateSpec, DataCollectionDeleteRequest, DataCollectionDeleteResponse, DataCollectionDeleteSpec, DataCollectionEventType, DataCollectionEventTypeSpec, DataCollectionEventsSpec, DataCollectionFindByIdRequest, DataCollectionFindByIdResponse, DataCollectionFindByIdSpec, DataCollectionFindRequest, DataCollectionFindResponse, DataCollectionFindSpec, DataCollectionListRequest, DataCollectionListResponse, DataCollectionListResponseDrilldown, DataCollectionListSpec, DataCollectionMatchRequest, DataCollectionMatchResponse, DataCollectionMatchSpec, DataCollectionMethodRequest, DataCollectionMethodSpec, DataCollectionSearchRequest, DataCollectionSearchResponse, DataCollectionSearchSpec, DataCollectionSpec, DataCollectionUdmSpec, DataCollectionUdmsSpec, DataCollectionUpdateRequest, DataCollectionUpdateResponse, DataCollectionUpdateSpec, DataFilterCondition, DataForm, DataLink, DataLinkDirection, DataLinkTableAccessor, DataLinkTableApiResponse, DataLinkTableConfig, DataLinkTableInstanceAccessor, DataLinkTableInstanceApiResponse, DataLinkTableInstancesAccessor, DataLinkTablesAccessor, DataLocationMethodImplementationTypes, DataLocationTypeCollection, DataLocatorStep, DataLocatorStepArrayItem, DataLocatorStepObjectProperty, DataLocatorStepType, DataRecordSchema, DataSchema, DataSourceAccessor, DataSourceApiResponse, DataSourceInstanceAccessor, DataSourceInstanceApiResponse, DataSourceInstancesAccessor, DataSourceUnitConfig, DataSourcesAccessor, DependencyError, DownstreamFlowNodeRunSchema, EDITABLE_LIMITS, ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor, ElementsExportFields, ErrorData, ErrorDataSchema, ErrorType, ExternalEvent, ExternalEventLogRecordApiResponse, ExternalEventLogStatus, ExternalEventPullApiResponse, ExternalEventPullStatus, ExternalEventSubscriptionAccessor, ExternalEventSubscriptionApiResponse, ExternalEventSubscriptionConfig, ExternalEventSubscriptionStatus, ExternalEventSubscriptionType, ExternalEventSubscriptionsAccessor, ExternalEventType, ExternalEventUnitConfig, FLOW_NODE_SPECS, FieldMappingAccessor, FieldMappingApiResponse, FieldMappingDirection, FieldMappingInstanceAccessor, FieldMappingInstanceApiResponse, FieldMappingInstancesAccessor, FieldMappingUnitConfig, FieldMappingsAccessor, FindActionInstancesQuery, FindActionsQuery, FindConnectionsQuery, FindConnectionsResponse, FindCustomersQuery, FindDataSourceEventsQuery, FindDataSourceInstanceSyncsQuery, FindDataSourceInstancesQuery, FindDataSourceSyncsQuery, FindDataSourcesQuery, FindFlowInstancesQuery, FindFlowRunsQuery, FindFlowRunsResponse, FindFlowsQuery, FindIntegrationsQuery, FindScenariosQuery, FlowAccessor, FlowApiResponse, FlowInstanceAccessor, FlowInstanceApiResponse, FlowInstanceNode, FlowInstanceNodeState, FlowInstanceSetupError, FlowInstancesAccessor, FlowNode, FlowNodeLink, FlowNodeRunOutputMetadataSchema, FlowNodeRunOutputSchema, FlowNodeRunOutputWithoutDownstreamRunsSchema, FlowNodeRunParametersSchema, FlowNodeRunRecordSchema, FlowNodeRunRecordWithoutOutputsDataSchema, FlowNodeRunResultSchema, FlowNodeRunStatus, FlowNodeSpec, FlowNodeType, FlowRunAccessor, FlowRunApiResponse, FlowRunError, FlowRunLaunchedBy, FlowRunLaunchedByApi, FlowRunLaunchedByTrigger, FlowRunNode, FlowRunNodeState, FlowRunState, FlowRunsAccessor, FlowsAccessor, Formula, HTTP_REQUEST_SCHEMA, HandyScenarioTemplateElement, HttpRequestMethod, HttpRequestSpec, IncludeArchivedQuery, IncomingWebhooksState, IntegrationAccessor, IntegrationApiResponse, IntegrationAppClient, IntegrationAppError, IntegrationAuthOption, IntegrationAuthUi, IntegrationElementLevel, IntegrationElementType, IntegrationLevelActionAccessor, IntegrationLevelActionsListAccessor, IntegrationLevelDataSourceAccessor, IntegrationLevelDataSourcesListAccessor, IntegrationLevelFieldMappingAccessor, IntegrationLevelFieldMappingsListAccessor, IntegrationLevelFlowAccessor, IntegrationLevelFlowsListAccessor, IntegrationsAccessor, InternalError, InvalidLocatorError, LimitUnits, ListActionInstancesForConnectionQuery, ListActionsForIntegrationQuery, ListDataSourceInstancesForConnectionQuery, ListDataSourcesForIntegrationQuery, ListExternalEventLogRecordsQuery, ListExternalEventPullsQuery, ListFlowInstancesForConnectionQuery, ListFlowsForIntegrationQuery, LogRecordType, MIN_FULL_SYNC_INTERVAL_SECONDS, MIN_PULL_UPDATES_INTERVAL_SECONDS, MinimalConnector, NotAuthenticatedError, NotFoundError, OAUTH1_CONFIG_SCHEMA, OAUTH_CONFIG_SCHEMA, OpenNewConnectionOptions, OrgLimitsType, OrgUserRole, OrgUserStatus, PARALLEL_EXECUTION_LIMITS, PaginationQuery, PaginationResponse, RATE_LIMITS, RateLimitExceededError, ResetFlowInstanceOptions, RunFlowOptions, ScenarioAccessor, ScenarioApiResponse, ScenarioElement, ScenarioElementApi, ScenarioTemplate, ScenarioTemplateCategory, ScenarioTemplateElements, ScenarioToDo, ScenarioToDoApi, ScenariosAccessor, ScreenAccessor, ScreenApiResponse, ScreenBlock, ScreenBlockType, ScreenType, ScreensAccessor, SearchQuery, SelfAccessor, UDM, UNIFIED_DATA_MODELS, UnitRunError, UpdateActionInstanceRequest, UpdateActionRequest, UpdateConnectionRequest, UpdateCustomerRequest, UpdateDataSourceInstanceRequest, UpdateDataSourceRequest, UpdateFlowRequest, UpdateIntegrationRequest, UpdateScenarioRequest, UpstreamFlowNodeRunSchema, UsageType, UserAccessor, UsersAccessor, WORKSPACE_SIZE_LIMITS, WebhookTypeEnum, WorkspaceElementDependencyType, WorkspaceElementSpecs, WorkspaceElementState, WorkspaceElementType, WorkspaceEventType, WorkspaceNotificationType, WorkspaceOnboardingStep, WorkspaceSyncEventType, WorkspaceType, addRequiredFieldsToSchema, addUdmFallbackFields, backwardCompatibleFilterMatch, buildData, buildDataSchema, buildValue, compressDataSchema, createCompoundSchema, createFlowInstanceSchema, createObjectFromLocators, createOrUpdateConnection, createSchema, dataCollectionEventTypeToExternalEventType, dataLocationParametersMatch, doesMatchFilter, excludeFieldsFromSchema, excludeFieldsFromValue, excludeReadOnlyFieldsFromSchema, excludeWriteOnlyFieldsFromSchema, externalEventTypeToDataCollectionEventType, extractFieldLocator, extractIntegrationAppErrorData, findUdmCollectionMapping, findUdmDefaultCollection, findUdmRootLocation, findValueLocators, generateExampleFromSchema, getActionInstanceVariableSchema, getActionRunTimeVariablesSchema, getAllEventMethodFilePaths, getChildNodeKeys, getDataCollectionCreateFields, getDataCollectionUpdateFields, getDataLocationMethodPath, getDownstreamNodeKeys, getErrorFromData, getEventMethodFileKey, getFilterFieldValuesByLocator, getFlowInstanceNodeDependency, getFlowNode, getFlowNodeConfigTimeVariablesSchema, getFlowNodeDescription, getFlowNodeRunTimeVariablesSchema, getFlowNodeSpec, getFlowNodeTitle, getFormula$1 as getFormula, getFormulaLocators, getFormula as getFormula_internalDoNotUse, getFullNameForLocator, getFullTitleForLocator, getIconUriForLocator, getLocatorsFromData, getLocatorsFromSchema, getMissingRequiredFields, getNameComponentsForLocator, getNameForLocator, getNodeInputSchema, getOperatorsBySchema, getParentNodeKeys, getReferenceCollectionPathForSchema, getReferenceCollectionPointerForSchema, getRequiredFieldsFromSchema, getRootNodeKeys, getSchemaByLocator, getSchemaFromValue, getUpstreamNodeKeys, getValueAtLocator, getValueByLocator, getVariableLocators, getWritableFieldsSchema, hasCycles, hasFormulas$1 as hasFormulas, hasFormulas as hasFormulas_internalDoNotUse, injectFormulaCatalog, isDataActionType, isDataLocationMethodSupported, isFormula$1 as isFormula, isFormula as isFormula_internalDoNotUse, isIntegrationAppError, isObject, isSameDataLocation, isSchemaEmpty, isStream, isValidLocator, locatorToField, locatorToSteps, locatorToString, makeDataLocationOperationPath, makeDataLocationPath, makeDataRecordSchema, makeObjectPropertyLocator, makeSchemaForLocator, mergeSchemas, mergeWithFormulas, nonEmptyObjectProperties, parseDataLocationPath, parseDate, patchSchema, pickFieldsFromSchema, pickFieldsFromValue, populateSchemaTitles, processCopy, removeNonExistentVars, removeRequiredFieldsFromSchema, resolveFormulas, resolveValue, schemaAllowsCustomValue, schemaHasFixedValues, schemaHasProperties, schemaIsNumber, schemaIsScalar, schemaTypeFromValue, schemaWithTitle, setSchemaAtLocator, setValueAtLocator, stepsToLocator, streamToString, transformVariablesWith, transformVars, truncateData, unwrapSchema, unwrapSchemas, updateFlowInstanceSchema, updateImpliedSchema, valueToSchema, valueToString, walkSchema, wrapAnyOfSchema, zodBooleanCoercion };
|
|
11657
12705
|
//# sourceMappingURL=index.module.mjs.map
|