@membranehq/sdk 0.7.0 → 0.7.3
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 +3445 -3621
- package/dist/bundle.js +10 -1
- package/dist/bundle.js.map +1 -1
- package/dist/dts/accessors/connections-accessors.d.ts +4 -3
- package/dist/dts/accessors/integrations-accessors.d.ts +4 -3
- package/dist/dts/accessors/scenarios-accessors.d.ts +4 -3
- package/dist/dts/config/config.test.d.ts +1 -0
- package/dist/dts/config/index.d.ts +42 -0
- package/dist/dts/entity-repository.d.ts +2 -2
- package/dist/dts/index.browser.d.ts +31 -0
- package/dist/dts/index.d.ts +2 -0
- package/dist/dts/index.node.d.ts +2 -0
- package/dist/dts/integration-elements/index.d.ts +0 -2
- package/dist/dts/orgs/types.d.ts +1 -0
- package/dist/dts/{workspace-elements/base/scenarios/types.d.ts → scenario-templates/index.d.ts} +64 -169
- package/dist/dts/workspace-elements/api/action-instances-api.d.ts +39 -37
- package/dist/dts/workspace-elements/api/action-run-log-records-api.d.ts +37 -37
- package/dist/dts/workspace-elements/api/actions-api.d.ts +64 -46
- package/dist/dts/workspace-elements/api/app-data-schema-instances-api.d.ts +13 -0
- package/dist/dts/workspace-elements/api/app-data-schemas-api.d.ts +3 -0
- package/dist/dts/workspace-elements/api/app-event-log-records-api.d.ts +17 -2
- package/dist/dts/workspace-elements/api/app-event-subscriptions-api.d.ts +13 -0
- package/dist/dts/workspace-elements/api/app-event-types-api.d.ts +3 -0
- package/dist/dts/workspace-elements/api/connections-api.d.ts +57 -34
- package/dist/dts/workspace-elements/api/customers-api.d.ts +3 -0
- package/dist/dts/workspace-elements/api/data-link-table-instances-api.d.ts +29 -16
- package/dist/dts/workspace-elements/api/data-link-tables-api.d.ts +3 -0
- package/dist/dts/workspace-elements/api/data-source-instances-api.d.ts +51 -32
- package/dist/dts/workspace-elements/api/data-sources-api.d.ts +70 -36
- package/dist/dts/workspace-elements/api/external-event-log-records-api.d.ts +27 -22
- package/dist/dts/workspace-elements/api/external-event-pulls-api.d.ts +27 -22
- package/dist/dts/workspace-elements/api/external-event-subscriptions-api.d.ts +21 -16
- package/dist/dts/workspace-elements/api/external-events-api.d.ts +7 -0
- package/dist/dts/workspace-elements/api/field-mapping-instances-api.d.ts +122 -76
- package/dist/dts/workspace-elements/api/field-mappings-api.d.ts +58 -24
- package/dist/dts/workspace-elements/api/flow-runs-api.d.ts +116 -104
- package/dist/dts/workspace-elements/api/flows-api.d.ts +133 -693
- package/dist/dts/workspace-elements/api/integrations-api.d.ts +12 -14
- package/dist/dts/workspace-elements/api/scenarios-api.d.ts +434 -431
- package/dist/dts/workspace-elements/base/action-instances/types.d.ts +5 -8
- package/dist/dts/workspace-elements/base/action-run-log-records/types.d.ts +2 -2
- package/dist/dts/workspace-elements/base/actions/index.d.ts +18 -15
- package/dist/dts/workspace-elements/base/app-data-schema-instances/types.d.ts +3 -0
- package/dist/dts/workspace-elements/base/app-data-schemas/types.d.ts +3 -0
- package/dist/dts/workspace-elements/base/app-event-subscriptions/types.d.ts +3 -0
- package/dist/dts/workspace-elements/base/app-event-types/types.d.ts +3 -0
- package/dist/dts/workspace-elements/base/connections/types.d.ts +5 -8
- package/dist/dts/workspace-elements/base/customers/index.d.ts +3 -0
- package/dist/dts/workspace-elements/base/data-link-table-instances/types.d.ts +5 -2
- package/dist/dts/workspace-elements/base/data-link-tables/types.d.ts +3 -0
- package/dist/dts/workspace-elements/base/data-source-instances/types.d.ts +7 -4
- package/dist/dts/workspace-elements/base/data-sources/types.d.ts +17 -10
- package/dist/dts/workspace-elements/base/external-event-log-records/types.d.ts +2 -2
- package/dist/dts/workspace-elements/base/external-event-pulls/types.d.ts +2 -2
- package/dist/dts/workspace-elements/base/external-event-subscriptions/types.d.ts +2 -2
- package/dist/dts/workspace-elements/base/field-mapping-instances/types.d.ts +7 -4
- package/dist/dts/workspace-elements/base/field-mappings/types.d.ts +15 -8
- package/dist/dts/workspace-elements/base/flow-instances/schemas.d.ts +26 -26
- package/dist/dts/workspace-elements/base/flow-instances/types.d.ts +15 -15
- package/dist/dts/workspace-elements/base/flow-runs/types.d.ts +2 -2
- package/dist/dts/workspace-elements/base/flows/types.d.ts +21 -14
- package/dist/dts/workspace-elements/base/integrations/types.d.ts +18 -0
- package/dist/dts/workspace-elements/base/scenarios/index.d.ts +163 -1
- package/dist/dts/workspace-elements/types.d.ts +118 -0
- package/dist/dts/workspace-elements-catalog/index.d.ts +1 -0
- package/dist/{index.module.d.mts → index.browser.d.mts} +17767 -17803
- package/dist/{index.d.ts → index.browser.d.ts} +17767 -17803
- package/dist/{index.js → index.browser.js} +114 -132
- package/dist/index.browser.js.map +1 -0
- package/dist/{index.module.mjs → index.browser.mjs} +110 -129
- package/dist/index.browser.mjs.map +1 -0
- package/dist/index.node.d.mts +27932 -0
- package/dist/index.node.d.ts +27932 -0
- package/dist/index.node.js +13334 -0
- package/dist/index.node.js.map +1 -0
- package/dist/index.node.mjs +12862 -0
- package/dist/index.node.mjs.map +1 -0
- package/package.json +38 -15
- package/dist/index.js.map +0 -1
- package/dist/index.module.mjs.map +0 -1
|
@@ -3436,6 +3436,7 @@ const BaseMembraneInterfaceEditableProperties = zod.z.object({
|
|
|
3436
3436
|
name: zod.z.string().optional(),
|
|
3437
3437
|
uuid: zod.z.string().optional(),
|
|
3438
3438
|
description: zod.z.string().optional(),
|
|
3439
|
+
meta: zod.z.record(zod.z.string(), zod.z.any()).optional(),
|
|
3439
3440
|
});
|
|
3440
3441
|
const BaseMembraneInterfaceReadOnlyProperties = zod.z.object({
|
|
3441
3442
|
name: zod.z.string(),
|
|
@@ -3448,6 +3449,14 @@ const BaseMembraneInterfaceReadOnlyProperties = zod.z.object({
|
|
|
3448
3449
|
isDeactivated: zod.z.boolean().optional(),
|
|
3449
3450
|
});
|
|
3450
3451
|
const BaseMembraneInterface = BaseWorkspaceElement.merge(BaseMembraneInterfaceEditableProperties).merge(BaseMembraneInterfaceReadOnlyProperties);
|
|
3452
|
+
const BaseIntegrationLevelMembraneInterfaceEditableProperties = BaseMembraneInterfaceEditableProperties.extend({
|
|
3453
|
+
integrationId: zod.z.string().optional(),
|
|
3454
|
+
parentId: zod.z.string().optional(),
|
|
3455
|
+
});
|
|
3456
|
+
const BaseIntegrationLevelMembraneInterfaceReadOnlyProperties = BaseMembraneInterfaceReadOnlyProperties.extend({
|
|
3457
|
+
isCustomized: zod.z.boolean().optional(),
|
|
3458
|
+
});
|
|
3459
|
+
const BaseIntegrationLevelMembraneInterface = BaseMembraneInterface.merge(BaseIntegrationLevelMembraneInterfaceEditableProperties).merge(BaseIntegrationLevelMembraneInterfaceReadOnlyProperties);
|
|
3451
3460
|
|
|
3452
3461
|
exports.FieldMappingDirection = void 0;
|
|
3453
3462
|
(function (FieldMappingDirection) {
|
|
@@ -3455,12 +3464,10 @@ exports.FieldMappingDirection = void 0;
|
|
|
3455
3464
|
FieldMappingDirection["EXPORT"] = "export";
|
|
3456
3465
|
FieldMappingDirection["BOTH"] = "both";
|
|
3457
3466
|
})(exports.FieldMappingDirection || (exports.FieldMappingDirection = {}));
|
|
3458
|
-
const BaseFieldMapping =
|
|
3459
|
-
revision: zod.z.string(),
|
|
3467
|
+
const BaseFieldMapping = BaseIntegrationLevelMembraneInterface.extend({
|
|
3460
3468
|
publishedRevision: zod.z.string().optional(),
|
|
3461
3469
|
universalFieldMappingId: zod.z.string().optional(),
|
|
3462
3470
|
universalFieldMappingRevision: zod.z.string().optional(),
|
|
3463
|
-
integrationId: zod.z.string().optional(),
|
|
3464
3471
|
dataSourceId: zod.z.string().optional(),
|
|
3465
3472
|
dataSourceKey: zod.z.string().optional(),
|
|
3466
3473
|
appSchema: DataSchema.optional(),
|
|
@@ -3472,8 +3479,6 @@ const BaseFieldMapping = BaseMembraneInterface.extend({
|
|
|
3472
3479
|
frozenImportFields: zod.z.any().optional(),
|
|
3473
3480
|
frozenExportFields: zod.z.any().optional(),
|
|
3474
3481
|
frozenUnifiedExportFields: zod.z.any().optional(),
|
|
3475
|
-
archivedAt: zod.z.string().optional(),
|
|
3476
|
-
customized: zod.z.boolean().optional(),
|
|
3477
3482
|
});
|
|
3478
3483
|
const FieldMappingUnitConfig = zod.z.object({
|
|
3479
3484
|
key: zod.z.string().optional(),
|
|
@@ -3614,7 +3619,7 @@ const ACTIONS = {
|
|
|
3614
3619
|
},
|
|
3615
3620
|
};
|
|
3616
3621
|
|
|
3617
|
-
const ActionEditableProperties =
|
|
3622
|
+
const ActionEditableProperties = BaseIntegrationLevelMembraneInterfaceEditableProperties.extend({
|
|
3618
3623
|
integrationId: zod.z.string().optional(),
|
|
3619
3624
|
parentId: zod.z.string().optional(),
|
|
3620
3625
|
inputSchema: DataSchema.optional(),
|
|
@@ -3623,13 +3628,8 @@ const ActionEditableProperties = BaseMembraneInterfaceEditableProperties.extend(
|
|
|
3623
3628
|
outputMapping: zod.z.any().optional(),
|
|
3624
3629
|
customOutputSchema: DataSchema.optional(),
|
|
3625
3630
|
});
|
|
3626
|
-
const
|
|
3627
|
-
|
|
3628
|
-
name: zod.z.string(),
|
|
3629
|
-
isCustomized: zod.z.boolean().optional(),
|
|
3630
|
-
parentRevision: zod.z.string().optional(),
|
|
3631
|
-
});
|
|
3632
|
-
const BaseAction = BaseMembraneInterface.merge(ActionEditableProperties).merge(ActionCalculatedProperties);
|
|
3631
|
+
const ActionReadOnlyProperties = BaseIntegrationLevelMembraneInterfaceReadOnlyProperties;
|
|
3632
|
+
const BaseAction = BaseMembraneInterface.merge(ActionEditableProperties).merge(ActionReadOnlyProperties);
|
|
3633
3633
|
|
|
3634
3634
|
const ConnectionRequest = zod.z.object({
|
|
3635
3635
|
path: zod.z.any(),
|
|
@@ -3645,6 +3645,7 @@ const BaseConnection = BaseWorkspaceElement.extend({
|
|
|
3645
3645
|
isTest: zod.z.boolean().optional(),
|
|
3646
3646
|
disconnected: zod.z.boolean().optional(),
|
|
3647
3647
|
isDefunct: zod.z.boolean().optional(),
|
|
3648
|
+
state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
|
|
3648
3649
|
error: ErrorDataSchema.optional(),
|
|
3649
3650
|
integrationId: zod.z.string(),
|
|
3650
3651
|
authOptionKey: zod.z.string().optional(),
|
|
@@ -3654,8 +3655,6 @@ const BaseConnection = BaseWorkspaceElement.extend({
|
|
|
3654
3655
|
nextCredentialsRefreshAt: zod.z.string().optional(),
|
|
3655
3656
|
archivedAt: zod.z.string().optional(),
|
|
3656
3657
|
isDeactivated: zod.z.boolean().optional(),
|
|
3657
|
-
state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
|
|
3658
|
-
errors: zod.z.array(ErrorDataSchema).optional(),
|
|
3659
3658
|
meta: zod.z.record(zod.z.any()).optional(),
|
|
3660
3659
|
});
|
|
3661
3660
|
class ConnectionSpec {
|
|
@@ -8342,10 +8341,8 @@ const DataSourceUnitConfig = zod.z.object({
|
|
|
8342
8341
|
pullUpdatesIntervalSeconds: zod.z.number().optional(),
|
|
8343
8342
|
fullSyncIntervalSeconds: zod.z.number().optional(),
|
|
8344
8343
|
});
|
|
8345
|
-
const BaseDataSource =
|
|
8346
|
-
revision: zod.z.string(),
|
|
8344
|
+
const BaseDataSource = BaseIntegrationLevelMembraneInterface.extend({
|
|
8347
8345
|
publishedRevision: zod.z.string().optional(),
|
|
8348
|
-
integrationId: zod.z.string().optional(),
|
|
8349
8346
|
universalDataSourceId: zod.z.string().optional(),
|
|
8350
8347
|
universalDataSourceRevision: zod.z.string().optional(),
|
|
8351
8348
|
udm: zod.z.string().optional(),
|
|
@@ -8353,10 +8350,6 @@ const BaseDataSource = BaseMembraneInterface.extend({
|
|
|
8353
8350
|
fullSyncIntervalSeconds: zod.z.number().optional(),
|
|
8354
8351
|
collectionKey: zod.z.string().optional(),
|
|
8355
8352
|
collectionParameters: zod.z.any().optional(),
|
|
8356
|
-
archivedAt: zod.z.string().optional(),
|
|
8357
|
-
createdAt: zod.z.string().optional(),
|
|
8358
|
-
updatedAt: zod.z.string().optional(),
|
|
8359
|
-
customized: zod.z.boolean().optional(),
|
|
8360
8353
|
defaultPath: zod.z.string().optional(),
|
|
8361
8354
|
});
|
|
8362
8355
|
|
|
@@ -8824,16 +8817,12 @@ const FlowNode = zod.z.object({
|
|
|
8824
8817
|
links: zod.z.array(FlowNodeLink).optional(),
|
|
8825
8818
|
isCustomized: zod.z.boolean().optional(),
|
|
8826
8819
|
});
|
|
8827
|
-
const BaseFlow =
|
|
8828
|
-
integrationId: zod.z.string().optional(),
|
|
8820
|
+
const BaseFlow = BaseIntegrationLevelMembraneInterface.extend({
|
|
8829
8821
|
universalFlowId: zod.z.string().optional(),
|
|
8830
8822
|
universalFlowRevision: zod.z.string().optional(),
|
|
8831
8823
|
parametersSchema: DataSchema.optional(),
|
|
8832
8824
|
nodes: zod.z.record(FlowNode).optional(),
|
|
8833
8825
|
autoCreateInstances: zod.z.boolean().optional(),
|
|
8834
|
-
archivedAt: zod.z.string().optional(),
|
|
8835
|
-
revision: zod.z.string(),
|
|
8836
|
-
customized: zod.z.boolean().optional(),
|
|
8837
8826
|
});
|
|
8838
8827
|
|
|
8839
8828
|
const BaseIntegration = BaseMembraneInterface.extend({
|
|
@@ -8863,72 +8852,43 @@ const AppliedToIntegrations = (elementSchema) => zod.z.array(zod.z.object({
|
|
|
8863
8852
|
integration: BaseIntegration,
|
|
8864
8853
|
}));
|
|
8865
8854
|
|
|
8866
|
-
exports.
|
|
8867
|
-
(function (
|
|
8868
|
-
|
|
8869
|
-
|
|
8870
|
-
|
|
8871
|
-
|
|
8872
|
-
|
|
8873
|
-
|
|
8874
|
-
|
|
8875
|
-
|
|
8876
|
-
|
|
8877
|
-
|
|
8878
|
-
|
|
8855
|
+
exports.IntegrationElementLevel = void 0;
|
|
8856
|
+
(function (IntegrationElementLevel) {
|
|
8857
|
+
IntegrationElementLevel["UNIVERSAL"] = "universal";
|
|
8858
|
+
IntegrationElementLevel["CONNECTOR"] = "connector";
|
|
8859
|
+
IntegrationElementLevel["CONNECTION"] = "connection";
|
|
8860
|
+
})(exports.IntegrationElementLevel || (exports.IntegrationElementLevel = {}));
|
|
8861
|
+
exports.IntegrationElementType = void 0;
|
|
8862
|
+
(function (IntegrationElementType) {
|
|
8863
|
+
IntegrationElementType["APP_DATA_SCHEMA"] = "app-data-schema";
|
|
8864
|
+
IntegrationElementType["APP_EVENT_TYPE"] = "app-event-type";
|
|
8865
|
+
IntegrationElementType["DATA_SOURCE"] = "data-source";
|
|
8866
|
+
IntegrationElementType["SCHEMA"] = "schema";
|
|
8867
|
+
IntegrationElementType["FIELD_MAPPING"] = "field-mapping";
|
|
8868
|
+
IntegrationElementType["FLOW"] = "flow";
|
|
8869
|
+
IntegrationElementType["INTEGRATION"] = "integration";
|
|
8870
|
+
IntegrationElementType["ACTION"] = "action";
|
|
8871
|
+
IntegrationElementType["DATA_LINK_TABLE"] = "data-link-table";
|
|
8872
|
+
IntegrationElementType["EXTERNAL_EVENT"] = "external-event";
|
|
8873
|
+
})(exports.IntegrationElementType || (exports.IntegrationElementType = {}));
|
|
8874
|
+
|
|
8879
8875
|
const ScenarioElement = zod.z.object({
|
|
8880
8876
|
id: zod.z.string(),
|
|
8881
|
-
type: zod.z.
|
|
8877
|
+
type: zod.z.nativeEnum(exports.IntegrationElementType),
|
|
8882
8878
|
element: zod.z.any().optional(),
|
|
8883
8879
|
});
|
|
8884
|
-
const
|
|
8885
|
-
appId: zod.z.string(),
|
|
8880
|
+
const ScenarioEditableProperties = BaseMembraneInterfaceEditableProperties.extend({
|
|
8886
8881
|
scenarioTemplateId: zod.z.string().optional(),
|
|
8887
8882
|
elements: zod.z.array(ScenarioElement).optional(),
|
|
8888
|
-
|
|
8889
|
-
|
|
8890
|
-
archivedAt: zod.z.string().optional(),
|
|
8891
|
-
});
|
|
8892
|
-
const HandyScenarioTemplateElement = zod.z.object({
|
|
8893
|
-
type: zod.z.string(),
|
|
8894
|
-
integration: zod.z.object({ key: zod.z.string(), connectorId: zod.z.string() }).optional(),
|
|
8895
|
-
integrations: zod.z.array(zod.z.object({ key: zod.z.string(), connectorId: zod.z.string() })).optional(),
|
|
8896
|
-
fields: zod.z
|
|
8897
|
-
.object({
|
|
8898
|
-
key: zod.z.string(),
|
|
8899
|
-
name: zod.z.string(),
|
|
8900
|
-
})
|
|
8901
|
-
.and(zod.z.record(zod.z.any())),
|
|
8902
|
-
});
|
|
8903
|
-
const withIntegrationKeys = (schema) => schema.and(zod.z.object({ integrationKeys: zod.z.array(zod.z.string()).optional() }));
|
|
8904
|
-
const ElementsExportFields = zod.z.object({
|
|
8905
|
-
flows: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
8906
|
-
actions: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
8907
|
-
fieldMappings: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
8908
|
-
dataSources: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
8909
|
-
dataLinkTables: zod.z.record(zod.z.any()).optional(),
|
|
8910
|
-
appEventTypes: zod.z.record(zod.z.any()).optional(),
|
|
8911
|
-
appDataSchemas: zod.z.record(zod.z.any()).optional(),
|
|
8883
|
+
integrationId: zod.z.string().optional(),
|
|
8884
|
+
parentId: zod.z.string().optional(),
|
|
8912
8885
|
});
|
|
8913
|
-
const
|
|
8914
|
-
integrations: zod.z.record(ElementsExportFields.and(zod.z.object({ connectorId: zod.z.string() }))).optional(),
|
|
8915
|
-
}));
|
|
8916
|
-
const ScenarioTemplate = zod.z.object({
|
|
8917
|
-
id: zod.z.string(),
|
|
8918
|
-
name: zod.z.string(),
|
|
8886
|
+
const ScenarioCalculatedProperties = zod.z.object({
|
|
8919
8887
|
key: zod.z.string(),
|
|
8920
|
-
|
|
8921
|
-
|
|
8922
|
-
demoWorkspaceKey: zod.z.string().optional(),
|
|
8923
|
-
demoAppUri: zod.z.string().optional(),
|
|
8924
|
-
demoGithubRepo: zod.z.string().optional(),
|
|
8925
|
-
demoVideoYoutubeUri: zod.z.string().optional(),
|
|
8926
|
-
tags: zod.z.array(zod.z.nativeEnum(exports.ScenarioTemplateCategory)).optional(),
|
|
8927
|
-
elements: ScenarioTemplateElements.optional(),
|
|
8928
|
-
todos: zod.z.array(ScenarioToDo.omit({ isComplete: true })).optional(),
|
|
8929
|
-
connectors: zod.z.array(MinimalConnector).optional(),
|
|
8930
|
-
handyElements: zod.z.array(HandyScenarioTemplateElement).optional(),
|
|
8888
|
+
name: zod.z.string(),
|
|
8889
|
+
isCustomized: zod.z.boolean().optional(),
|
|
8931
8890
|
});
|
|
8891
|
+
const BaseScenario = BaseMembraneInterface.merge(ScenarioEditableProperties).merge(ScenarioCalculatedProperties);
|
|
8932
8892
|
|
|
8933
8893
|
exports.ScreenType = void 0;
|
|
8934
8894
|
(function (ScreenType) {
|
|
@@ -8955,6 +8915,7 @@ const BaseScreen = BaseWorkspaceElement.extend({
|
|
|
8955
8915
|
const BaseCustomer = zod.z.object({
|
|
8956
8916
|
id: zod.z.string(),
|
|
8957
8917
|
name: zod.z.string(),
|
|
8918
|
+
meta: zod.z.record(zod.z.any()).optional(),
|
|
8958
8919
|
internalId: zod.z.string(),
|
|
8959
8920
|
fields: zod.z.record(zod.z.string(), zod.z.any()).optional(),
|
|
8960
8921
|
credentials: zod.z.any().optional(),
|
|
@@ -8979,7 +8940,6 @@ const BaseFlowInstance = BaseMembraneInterface.extend({
|
|
|
8979
8940
|
createdAt: zod.z.string(),
|
|
8980
8941
|
updatedAt: zod.z.string(),
|
|
8981
8942
|
state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
|
|
8982
|
-
outdated: zod.z.boolean().optional(),
|
|
8983
8943
|
customized: zod.z
|
|
8984
8944
|
.object({
|
|
8985
8945
|
name: zod.z.boolean().optional(),
|
|
@@ -9070,7 +9030,6 @@ const ActionDependency = zod.z.object({
|
|
|
9070
9030
|
});
|
|
9071
9031
|
const BaseActionInstance = BaseMembraneInterface.extend({
|
|
9072
9032
|
parentId: zod.z.string().optional(),
|
|
9073
|
-
parentRevision: zod.z.string().optional(),
|
|
9074
9033
|
universalParentId: zod.z.string().optional(),
|
|
9075
9034
|
userId: zod.z.string(),
|
|
9076
9035
|
instanceKey: zod.z.string().optional(),
|
|
@@ -9078,7 +9037,6 @@ const BaseActionInstance = BaseMembraneInterface.extend({
|
|
|
9078
9037
|
inputSchema: zod.z.any().optional(),
|
|
9079
9038
|
config: zod.z.any().optional(),
|
|
9080
9039
|
outputSchema: zod.z.any().optional(),
|
|
9081
|
-
isOutdated: zod.z.boolean().optional(),
|
|
9082
9040
|
});
|
|
9083
9041
|
|
|
9084
9042
|
const BaseFieldMappingInstance = BaseMembraneInterface.extend({
|
|
@@ -9606,7 +9564,13 @@ const RunFlowOptions = zod.z.object({
|
|
|
9606
9564
|
});
|
|
9607
9565
|
const FlowApiResponse = BaseFlow.extend({
|
|
9608
9566
|
integration: BaseIntegration.optional(),
|
|
9609
|
-
appliedToIntegrations: AppliedToIntegrations(
|
|
9567
|
+
appliedToIntegrations: AppliedToIntegrations(zod.z.object({
|
|
9568
|
+
id: zod.z.string(),
|
|
9569
|
+
integrationId: zod.z.string().optional(),
|
|
9570
|
+
isCustomized: zod.z.boolean().optional(),
|
|
9571
|
+
universalFlowId: zod.z.string().optional(),
|
|
9572
|
+
})).optional(),
|
|
9573
|
+
dependencies: zod.z.array(zod.z.any()).optional(),
|
|
9610
9574
|
});
|
|
9611
9575
|
const FlowInstanceApiResponse = BaseFlowInstance.extend({
|
|
9612
9576
|
user: zod.z.lazy(() => zod.z.any()).optional(),
|
|
@@ -9914,51 +9878,14 @@ const IntegrationApiResponse = BaseIntegration.extend({
|
|
|
9914
9878
|
parametersSchema: DataSchema.optional(),
|
|
9915
9879
|
});
|
|
9916
9880
|
|
|
9917
|
-
exports.IntegrationElementLevel = void 0;
|
|
9918
|
-
(function (IntegrationElementLevel) {
|
|
9919
|
-
IntegrationElementLevel["UNIVERSAL"] = "universal";
|
|
9920
|
-
IntegrationElementLevel["CONNECTOR"] = "connector";
|
|
9921
|
-
IntegrationElementLevel["CONNECTION"] = "connection";
|
|
9922
|
-
})(exports.IntegrationElementLevel || (exports.IntegrationElementLevel = {}));
|
|
9923
|
-
exports.IntegrationElementType = void 0;
|
|
9924
|
-
(function (IntegrationElementType) {
|
|
9925
|
-
IntegrationElementType["APP_DATA_SCHEMA"] = "app-data-schema";
|
|
9926
|
-
IntegrationElementType["APP_EVENT_TYPE"] = "app-event-type";
|
|
9927
|
-
IntegrationElementType["DATA_SOURCE"] = "data-source";
|
|
9928
|
-
IntegrationElementType["SCHEMA"] = "schema";
|
|
9929
|
-
IntegrationElementType["FIELD_MAPPING"] = "field-mapping";
|
|
9930
|
-
IntegrationElementType["FLOW"] = "flow";
|
|
9931
|
-
IntegrationElementType["INTEGRATION"] = "integration";
|
|
9932
|
-
IntegrationElementType["ACTION"] = "action";
|
|
9933
|
-
IntegrationElementType["DATA_LINK_TABLE"] = "data-link-table";
|
|
9934
|
-
IntegrationElementType["EXTERNAL_EVENT"] = "external-event";
|
|
9935
|
-
})(exports.IntegrationElementType || (exports.IntegrationElementType = {}));
|
|
9936
|
-
|
|
9937
|
-
const ScenarioToDoApi = zod.z.object({
|
|
9938
|
-
name: zod.z.string(),
|
|
9939
|
-
description: zod.z.string(),
|
|
9940
|
-
isComplete: zod.z.boolean(),
|
|
9941
|
-
});
|
|
9942
9881
|
const ScenarioElementApi = zod.z.object({
|
|
9943
9882
|
id: zod.z.string(),
|
|
9944
9883
|
type: zod.z.nativeEnum(exports.IntegrationElementType),
|
|
9945
9884
|
element: zod.z.any().optional(),
|
|
9946
9885
|
});
|
|
9947
|
-
const FindScenariosQuery = zod.z.object({}).merge(SearchQuery).merge(PaginationQuery);
|
|
9948
|
-
const CreateScenarioRequest = zod.z.object({
|
|
9949
|
-
name: zod.z.string(),
|
|
9950
|
-
key: zod.z.string(),
|
|
9951
|
-
elements: zod.z.array(ScenarioElementApi).optional(),
|
|
9952
|
-
todos: zod.z.array(ScenarioToDoApi).optional(),
|
|
9953
|
-
});
|
|
9954
|
-
const UpdateScenarioRequest = zod.z.object({
|
|
9955
|
-
name: zod.z.string().optional(),
|
|
9956
|
-
key: zod.z.string().optional(),
|
|
9957
|
-
elements: zod.z.array(ScenarioElementApi).optional(),
|
|
9958
|
-
todos: zod.z.array(ScenarioToDoApi).optional(),
|
|
9959
|
-
});
|
|
9886
|
+
const FindScenariosQuery = zod.z.object({}).merge(SearchQuery).merge(PaginationQuery).merge(IncludeArchivedQuery);
|
|
9960
9887
|
const ScenarioApiResponse = BaseScenario.extend({
|
|
9961
|
-
appliedToIntegrations:
|
|
9888
|
+
appliedToIntegrations: AppliedToIntegrations(BaseScenario).optional(),
|
|
9962
9889
|
});
|
|
9963
9890
|
|
|
9964
9891
|
const ScreenApiResponse = BaseScreen;
|
|
@@ -10235,6 +10162,9 @@ const WorkspaceElementSpecs = {
|
|
|
10235
10162
|
apiPath: 'scenarios',
|
|
10236
10163
|
name: 'Scenario',
|
|
10237
10164
|
namePlural: 'Scenarios',
|
|
10165
|
+
editablePropertiesSchema: ScenarioEditableProperties,
|
|
10166
|
+
apiResponseSchema: ScenarioApiResponse,
|
|
10167
|
+
findQuerySchema: FindScenariosQuery,
|
|
10238
10168
|
},
|
|
10239
10169
|
[exports.WorkspaceElementType.ActionInstance]: {
|
|
10240
10170
|
type: exports.WorkspaceElementType.ActionInstance,
|
|
@@ -10262,6 +10192,7 @@ const WorkspaceElementSpecs = {
|
|
|
10262
10192
|
apiPath: 'flows',
|
|
10263
10193
|
name: 'Flow',
|
|
10264
10194
|
namePlural: 'Flows',
|
|
10195
|
+
parentFieldKey: 'universalFlowId',
|
|
10265
10196
|
},
|
|
10266
10197
|
[exports.WorkspaceElementType.FlowInstance]: {
|
|
10267
10198
|
type: exports.WorkspaceElementType.FlowInstance,
|
|
@@ -10282,6 +10213,7 @@ const WorkspaceElementSpecs = {
|
|
|
10282
10213
|
apiPath: 'field-mappings',
|
|
10283
10214
|
name: 'Field Mapping',
|
|
10284
10215
|
namePlural: 'Field Mappings',
|
|
10216
|
+
parentFieldKey: 'universalFieldMappingId',
|
|
10285
10217
|
},
|
|
10286
10218
|
[exports.WorkspaceElementType.FieldMappingInstance]: {
|
|
10287
10219
|
type: exports.WorkspaceElementType.FieldMappingInstance,
|
|
@@ -10300,6 +10232,7 @@ const WorkspaceElementSpecs = {
|
|
|
10300
10232
|
apiPath: 'data-sources',
|
|
10301
10233
|
name: 'Data Source',
|
|
10302
10234
|
namePlural: 'Data Sources',
|
|
10235
|
+
parentFieldKey: 'universalDataSourceId',
|
|
10303
10236
|
},
|
|
10304
10237
|
[exports.WorkspaceElementType.DataSourceInstance]: {
|
|
10305
10238
|
type: exports.WorkspaceElementType.DataSourceInstance,
|
|
@@ -12417,6 +12350,54 @@ exports.WorkspaceSyncEventType = void 0;
|
|
|
12417
12350
|
WorkspaceSyncEventType["ElementUpdate"] = "element-update";
|
|
12418
12351
|
})(exports.WorkspaceSyncEventType || (exports.WorkspaceSyncEventType = {}));
|
|
12419
12352
|
|
|
12353
|
+
exports.ScenarioTemplateCategory = void 0;
|
|
12354
|
+
(function (ScenarioTemplateCategory) {
|
|
12355
|
+
ScenarioTemplateCategory["DataExport"] = "data-export";
|
|
12356
|
+
ScenarioTemplateCategory["DataImport"] = "data-import";
|
|
12357
|
+
ScenarioTemplateCategory["BiDirectionalSync"] = "bi-directional-sync";
|
|
12358
|
+
ScenarioTemplateCategory["UnifiedApi"] = "unified-api";
|
|
12359
|
+
ScenarioTemplateCategory["DataEnrichment"] = "data-enrichment";
|
|
12360
|
+
})(exports.ScenarioTemplateCategory || (exports.ScenarioTemplateCategory = {}));
|
|
12361
|
+
const HandyScenarioTemplateElement = zod.z.object({
|
|
12362
|
+
type: zod.z.string(),
|
|
12363
|
+
integration: zod.z.object({ key: zod.z.string(), connectorId: zod.z.string() }).optional(),
|
|
12364
|
+
integrations: zod.z.array(zod.z.object({ key: zod.z.string(), connectorId: zod.z.string() })).optional(),
|
|
12365
|
+
fields: zod.z
|
|
12366
|
+
.object({
|
|
12367
|
+
key: zod.z.string(),
|
|
12368
|
+
name: zod.z.string(),
|
|
12369
|
+
})
|
|
12370
|
+
.and(zod.z.record(zod.z.any())),
|
|
12371
|
+
});
|
|
12372
|
+
const withIntegrationKeys = (schema) => schema.and(zod.z.object({ integrationKeys: zod.z.array(zod.z.string()).optional() }));
|
|
12373
|
+
const ElementsExportFields = zod.z.object({
|
|
12374
|
+
flows: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
12375
|
+
actions: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
12376
|
+
fieldMappings: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
12377
|
+
dataSources: zod.z.record(withIntegrationKeys(zod.z.any())).optional(),
|
|
12378
|
+
dataLinkTables: zod.z.record(zod.z.any()).optional(),
|
|
12379
|
+
appEventTypes: zod.z.record(zod.z.any()).optional(),
|
|
12380
|
+
appDataSchemas: zod.z.record(zod.z.any()).optional(),
|
|
12381
|
+
});
|
|
12382
|
+
const ScenarioTemplateElements = ElementsExportFields.and(zod.z.object({
|
|
12383
|
+
integrations: zod.z.record(ElementsExportFields.and(zod.z.object({ connectorId: zod.z.string() }))).optional(),
|
|
12384
|
+
}));
|
|
12385
|
+
const ScenarioTemplate = zod.z.object({
|
|
12386
|
+
id: zod.z.string(),
|
|
12387
|
+
name: zod.z.string(),
|
|
12388
|
+
key: zod.z.string(),
|
|
12389
|
+
shortDescription: zod.z.string().optional(),
|
|
12390
|
+
description: zod.z.string().optional(),
|
|
12391
|
+
demoWorkspaceKey: zod.z.string().optional(),
|
|
12392
|
+
demoAppUri: zod.z.string().optional(),
|
|
12393
|
+
demoGithubRepo: zod.z.string().optional(),
|
|
12394
|
+
demoVideoYoutubeUri: zod.z.string().optional(),
|
|
12395
|
+
tags: zod.z.array(zod.z.nativeEnum(exports.ScenarioTemplateCategory)).optional(),
|
|
12396
|
+
elements: ScenarioTemplateElements.optional(),
|
|
12397
|
+
connectors: zod.z.array(MinimalConnector).optional(),
|
|
12398
|
+
handyElements: zod.z.array(HandyScenarioTemplateElement).optional(),
|
|
12399
|
+
});
|
|
12400
|
+
|
|
12420
12401
|
function decodeJWT(token) {
|
|
12421
12402
|
if (typeof token !== 'string') {
|
|
12422
12403
|
return undefined;
|
|
@@ -12763,6 +12744,9 @@ exports.BaseFlow = BaseFlow;
|
|
|
12763
12744
|
exports.BaseFlowInstance = BaseFlowInstance;
|
|
12764
12745
|
exports.BaseFlowRun = BaseFlowRun;
|
|
12765
12746
|
exports.BaseIntegration = BaseIntegration;
|
|
12747
|
+
exports.BaseIntegrationLevelMembraneInterface = BaseIntegrationLevelMembraneInterface;
|
|
12748
|
+
exports.BaseIntegrationLevelMembraneInterfaceEditableProperties = BaseIntegrationLevelMembraneInterfaceEditableProperties;
|
|
12749
|
+
exports.BaseIntegrationLevelMembraneInterfaceReadOnlyProperties = BaseIntegrationLevelMembraneInterfaceReadOnlyProperties;
|
|
12766
12750
|
exports.BaseMembraneInterface = BaseMembraneInterface;
|
|
12767
12751
|
exports.BaseMembraneInterfaceEditableProperties = BaseMembraneInterfaceEditableProperties;
|
|
12768
12752
|
exports.BaseMembraneInterfaceReadOnlyProperties = BaseMembraneInterfaceReadOnlyProperties;
|
|
@@ -12819,7 +12803,6 @@ exports.CreateFlowNodeRequest = CreateFlowNodeRequest;
|
|
|
12819
12803
|
exports.CreateFlowRequest = CreateFlowRequest;
|
|
12820
12804
|
exports.CreateFlowRunRequest = CreateFlowRunRequest;
|
|
12821
12805
|
exports.CreateIntegrationRequest = CreateIntegrationRequest;
|
|
12822
|
-
exports.CreateScenarioRequest = CreateScenarioRequest;
|
|
12823
12806
|
exports.CustomCodeError = CustomCodeError;
|
|
12824
12807
|
exports.CustomerAccessor = CustomerAccessor;
|
|
12825
12808
|
exports.CustomerApiResponse = CustomerApiResponse;
|
|
@@ -12998,12 +12981,12 @@ exports.ResetFlowInstanceOptions = ResetFlowInstanceOptions;
|
|
|
12998
12981
|
exports.RunFlowOptions = RunFlowOptions;
|
|
12999
12982
|
exports.ScenarioAccessor = ScenarioAccessor;
|
|
13000
12983
|
exports.ScenarioApiResponse = ScenarioApiResponse;
|
|
12984
|
+
exports.ScenarioCalculatedProperties = ScenarioCalculatedProperties;
|
|
12985
|
+
exports.ScenarioEditableProperties = ScenarioEditableProperties;
|
|
13001
12986
|
exports.ScenarioElement = ScenarioElement;
|
|
13002
12987
|
exports.ScenarioElementApi = ScenarioElementApi;
|
|
13003
12988
|
exports.ScenarioTemplate = ScenarioTemplate;
|
|
13004
12989
|
exports.ScenarioTemplateElements = ScenarioTemplateElements;
|
|
13005
|
-
exports.ScenarioToDo = ScenarioToDo;
|
|
13006
|
-
exports.ScenarioToDoApi = ScenarioToDoApi;
|
|
13007
12990
|
exports.ScenariosAccessor = ScenariosAccessor;
|
|
13008
12991
|
exports.ScreenAccessor = ScreenAccessor;
|
|
13009
12992
|
exports.ScreenApiResponse = ScreenApiResponse;
|
|
@@ -13021,7 +13004,6 @@ exports.UpdateDataSourceInstanceRequest = UpdateDataSourceInstanceRequest;
|
|
|
13021
13004
|
exports.UpdateDataSourceRequest = UpdateDataSourceRequest;
|
|
13022
13005
|
exports.UpdateFlowRequest = UpdateFlowRequest;
|
|
13023
13006
|
exports.UpdateIntegrationRequest = UpdateIntegrationRequest;
|
|
13024
|
-
exports.UpdateScenarioRequest = UpdateScenarioRequest;
|
|
13025
13007
|
exports.UpstreamFlowNodeRunSchema = UpstreamFlowNodeRunSchema;
|
|
13026
13008
|
exports.UserAccessor = UserAccessor;
|
|
13027
13009
|
exports.UsersAccessor = UsersAccessor;
|
|
@@ -13153,4 +13135,4 @@ exports.valueToString = valueToString;
|
|
|
13153
13135
|
exports.walkSchema = walkSchema;
|
|
13154
13136
|
exports.wrapAnyOfSchema = wrapAnyOfSchema;
|
|
13155
13137
|
exports.zodBooleanCoercion = zodBooleanCoercion;
|
|
13156
|
-
//# sourceMappingURL=index.js.map
|
|
13138
|
+
//# sourceMappingURL=index.browser.js.map
|