@membranehq/sdk 0.7.5 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -432,7 +432,6 @@ declare class ActionsAccessor extends ElementListAccessor<Action, FindActionsQue
432
432
  }
433
433
  declare class ActionAccessor extends ElementAccessor<Action, UpdateActionRequest, ActionSelector> {
434
434
  constructor(client: MembraneApiClient, selector: ActionSelector | string);
435
- apply(integrationKeys: string[]): Promise<Action[]>;
436
435
  reset(): Promise<any>;
437
436
  }
438
437
  declare class IntegrationLevelActionAccessor extends IntegrationLevelElementAccessor<Action, UpdateActionRequest> {
@@ -3836,7 +3835,6 @@ declare class DataSourcesAccessor extends ElementListAccessor<DataSource, FindDa
3836
3835
  }
3837
3836
  declare class DataSourceAccessor extends ElementAccessor<DataSource, UpdateDataSourceRequest, DataSourceSelector> {
3838
3837
  constructor(client: MembraneApiClient, selector: DataSourceSelector | string);
3839
- apply(integrationKeys: string[]): Promise<DataSource[]>;
3840
3838
  setup(): Promise<void>;
3841
3839
  reset(): Promise<any>;
3842
3840
  }
@@ -4645,7 +4643,6 @@ declare class FlowsAccessor extends ElementListAccessor<Flow, FindFlowsQuery, Cr
4645
4643
  }
4646
4644
  declare class FlowAccessor extends ElementAccessor<Flow, UpdateFlowRequest, FlowSelector> {
4647
4645
  constructor(client: MembraneApiClient, selector: FlowSelector | string);
4648
- apply(integrationKeys: string[]): Promise<Flow[]>;
4649
4646
  reset(): Promise<Flow>;
4650
4647
  }
4651
4648
  declare class IntegrationLevelFlowAccessor extends IntegrationLevelElementAccessor<Flow, UpdateFlowRequest> {
@@ -4898,7 +4895,6 @@ declare class FieldMappingsAccessor extends ElementListAccessor<FieldMapping, Fi
4898
4895
  declare class FieldMappingAccessor extends ElementAccessor<FieldMapping, UpdateFieldMappingRequest, FieldMappingSelector> {
4899
4896
  constructor(client: MembraneApiClient, selector: string | FieldMappingSelector);
4900
4897
  getAppSchema(): Promise<any>;
4901
- apply(integrationKeys: string[]): Promise<FieldMapping[]>;
4902
4898
  setup(): Promise<any>;
4903
4899
  reset(): Promise<any>;
4904
4900
  }
@@ -5318,6 +5314,9 @@ declare const ScenarioElementApi: z.ZodObject<{
5318
5314
  }, z.core.$strip>;
5319
5315
  type ScenarioElementApi = z.infer<typeof ScenarioElementApi>;
5320
5316
  declare const FindScenariosQuery: z.ZodObject<{
5317
+ integrationId: z.ZodOptional<z.ZodString>;
5318
+ integrationKey: z.ZodOptional<z.ZodString>;
5319
+ parentId: z.ZodOptional<z.ZodString>;
5321
5320
  search: z.ZodOptional<z.ZodString>;
5322
5321
  limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
5323
5322
  cursor: z.ZodOptional<z.ZodString>;
@@ -7159,6 +7158,8 @@ interface WorkspaceElementSpec {
7159
7158
  editablePropertiesSchema?: z.ZodObject<any>;
7160
7159
  apiResponseSchema?: z.ZodObject<any>;
7161
7160
  findQuerySchema?: z.ZodObject<any>;
7161
+ isMembraneInterface?: boolean;
7162
+ isIntegrationLevel?: boolean;
7162
7163
  parentFieldKey?: string;
7163
7164
  }
7164
7165
  interface WorkspaceElements {
@@ -432,7 +432,6 @@ declare class ActionsAccessor extends ElementListAccessor<Action, FindActionsQue
432
432
  }
433
433
  declare class ActionAccessor extends ElementAccessor<Action, UpdateActionRequest, ActionSelector> {
434
434
  constructor(client: MembraneApiClient, selector: ActionSelector | string);
435
- apply(integrationKeys: string[]): Promise<Action[]>;
436
435
  reset(): Promise<any>;
437
436
  }
438
437
  declare class IntegrationLevelActionAccessor extends IntegrationLevelElementAccessor<Action, UpdateActionRequest> {
@@ -3836,7 +3835,6 @@ declare class DataSourcesAccessor extends ElementListAccessor<DataSource, FindDa
3836
3835
  }
3837
3836
  declare class DataSourceAccessor extends ElementAccessor<DataSource, UpdateDataSourceRequest, DataSourceSelector> {
3838
3837
  constructor(client: MembraneApiClient, selector: DataSourceSelector | string);
3839
- apply(integrationKeys: string[]): Promise<DataSource[]>;
3840
3838
  setup(): Promise<void>;
3841
3839
  reset(): Promise<any>;
3842
3840
  }
@@ -4645,7 +4643,6 @@ declare class FlowsAccessor extends ElementListAccessor<Flow, FindFlowsQuery, Cr
4645
4643
  }
4646
4644
  declare class FlowAccessor extends ElementAccessor<Flow, UpdateFlowRequest, FlowSelector> {
4647
4645
  constructor(client: MembraneApiClient, selector: FlowSelector | string);
4648
- apply(integrationKeys: string[]): Promise<Flow[]>;
4649
4646
  reset(): Promise<Flow>;
4650
4647
  }
4651
4648
  declare class IntegrationLevelFlowAccessor extends IntegrationLevelElementAccessor<Flow, UpdateFlowRequest> {
@@ -4898,7 +4895,6 @@ declare class FieldMappingsAccessor extends ElementListAccessor<FieldMapping, Fi
4898
4895
  declare class FieldMappingAccessor extends ElementAccessor<FieldMapping, UpdateFieldMappingRequest, FieldMappingSelector> {
4899
4896
  constructor(client: MembraneApiClient, selector: string | FieldMappingSelector);
4900
4897
  getAppSchema(): Promise<any>;
4901
- apply(integrationKeys: string[]): Promise<FieldMapping[]>;
4902
4898
  setup(): Promise<any>;
4903
4899
  reset(): Promise<any>;
4904
4900
  }
@@ -5318,6 +5314,9 @@ declare const ScenarioElementApi: z.ZodObject<{
5318
5314
  }, z.core.$strip>;
5319
5315
  type ScenarioElementApi = z.infer<typeof ScenarioElementApi>;
5320
5316
  declare const FindScenariosQuery: z.ZodObject<{
5317
+ integrationId: z.ZodOptional<z.ZodString>;
5318
+ integrationKey: z.ZodOptional<z.ZodString>;
5319
+ parentId: z.ZodOptional<z.ZodString>;
5321
5320
  search: z.ZodOptional<z.ZodString>;
5322
5321
  limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
5323
5322
  cursor: z.ZodOptional<z.ZodString>;
@@ -7159,6 +7158,8 @@ interface WorkspaceElementSpec {
7159
7158
  editablePropertiesSchema?: z.ZodObject<any>;
7160
7159
  apiResponseSchema?: z.ZodObject<any>;
7161
7160
  findQuerySchema?: z.ZodObject<any>;
7161
+ isMembraneInterface?: boolean;
7162
+ isIntegrationLevel?: boolean;
7162
7163
  parentFieldKey?: string;
7163
7164
  }
7164
7165
  interface WorkspaceElements {
@@ -70,7 +70,7 @@ exports.ConcurrencyErrorKey = void 0;
70
70
  ConcurrencyErrorKey["LOCK_TIMEOUT"] = "lock_timeout";
71
71
  })(exports.ConcurrencyErrorKey || (exports.ConcurrencyErrorKey = {}));
72
72
  const ErrorDataSchema = zod.z.lazy(() => zod.z.object({
73
- type: zod.z.nativeEnum(exports.ErrorType).optional(),
73
+ type: zod.z.enum(exports.ErrorType).optional(),
74
74
  key: zod.z.string().optional(),
75
75
  message: zod.z.string(),
76
76
  data: zod.z.any().optional(),
@@ -3464,7 +3464,7 @@ const BaseMembraneInterfaceEditableProperties = zod.z.object({
3464
3464
  });
3465
3465
  const BaseMembraneInterfaceReadOnlyProperties = zod.z.object({
3466
3466
  name: zod.z.string(),
3467
- state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
3467
+ state: zod.z.enum(exports.WorkspaceElementState).optional(),
3468
3468
  errors: zod.z.array(ErrorDataSchema).optional(),
3469
3469
  revision: zod.z.string().optional(),
3470
3470
  createdAt: zod.z.string().optional(),
@@ -3525,7 +3525,7 @@ const FieldMappingEditableProperties = BaseIntegrationLevelMembraneInterfaceEdit
3525
3525
  dataSourceKey: zod.z.string().optional(),
3526
3526
  dataSourceId: zod.z.string().optional(),
3527
3527
  appSchema: DataSchema.optional(),
3528
- direction: zod.z.nativeEnum(exports.FieldMappingDirection).optional(),
3528
+ direction: zod.z.enum(exports.FieldMappingDirection).optional(),
3529
3529
  defaultImportValue: zod.z.any().optional(),
3530
3530
  defaultExportValue: zod.z.any().optional(),
3531
3531
  importValue: zod.z.any().optional(),
@@ -3651,7 +3651,7 @@ const ActionEditableProperties = BaseIntegrationLevelMembraneInterfaceEditablePr
3651
3651
  integrationId: zod.z.string().optional(),
3652
3652
  parentId: zod.z.string().optional(),
3653
3653
  inputSchema: DataSchema.optional(),
3654
- type: zod.z.nativeEnum(exports.ActionType).optional(),
3654
+ type: zod.z.enum(exports.ActionType).optional(),
3655
3655
  config: zod.z.any().optional(),
3656
3656
  outputMapping: zod.z.any().optional(),
3657
3657
  customOutputSchema: DataSchema.optional(),
@@ -3673,7 +3673,7 @@ const BaseConnection = BaseWorkspaceElement.extend({
3673
3673
  isTest: zod.z.boolean().optional(),
3674
3674
  disconnected: zod.z.boolean().optional(),
3675
3675
  isDefunct: zod.z.boolean().optional(),
3676
- state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
3676
+ state: zod.z.enum(exports.WorkspaceElementState).optional(),
3677
3677
  error: ErrorDataSchema.optional(),
3678
3678
  integrationId: zod.z.string(),
3679
3679
  authOptionKey: zod.z.string().optional(),
@@ -8420,7 +8420,7 @@ exports.IncomingWebhooksState = void 0;
8420
8420
  IncomingWebhooksState["ERROR"] = "error";
8421
8421
  })(exports.IncomingWebhooksState || (exports.IncomingWebhooksState = {}));
8422
8422
  const ExternalEventUnitConfig = zod.z.object({
8423
- type: zod.z.nativeEnum(exports.ExternalEventType),
8423
+ type: zod.z.enum(exports.ExternalEventType),
8424
8424
  dataSource: DataSourceUnitConfig.optional(),
8425
8425
  eventKey: zod.z.string().optional(),
8426
8426
  eventParameters: zod.z.any().optional(),
@@ -8478,11 +8478,11 @@ exports.FlowRunLaunchedByTrigger = void 0;
8478
8478
  FlowRunLaunchedByTrigger["ExternalEvent"] = "external-event";
8479
8479
  })(exports.FlowRunLaunchedByTrigger || (exports.FlowRunLaunchedByTrigger = {}));
8480
8480
  const FlowRunLaunchedBy = zod.z.object({
8481
- type: zod.z.nativeEnum(exports.FlowRunLaunchedByTrigger),
8481
+ type: zod.z.enum(exports.FlowRunLaunchedByTrigger),
8482
8482
  ids: zod.z.array(zod.z.string()).optional(),
8483
8483
  });
8484
8484
  const FlowRunNode = zod.z.object({
8485
- state: zod.z.nativeEnum(exports.FlowRunNodeState),
8485
+ state: zod.z.enum(exports.FlowRunNodeState),
8486
8486
  runs: zod.z.number().optional(),
8487
8487
  erroredRuns: zod.z.number().optional(),
8488
8488
  outputs: zod.z.number().optional(),
@@ -8497,7 +8497,7 @@ const BaseFlowRun = zod.z.object({
8497
8497
  startNodeKey: zod.z.string(),
8498
8498
  userId: zod.z.string(),
8499
8499
  input: zod.z.any().optional(),
8500
- state: zod.z.nativeEnum(exports.FlowRunState),
8500
+ state: zod.z.enum(exports.FlowRunState),
8501
8501
  startTime: zod.z.string(),
8502
8502
  endTime: zod.z.string().optional(),
8503
8503
  errors: zod.z.array(ErrorDataSchema).optional(),
@@ -8531,7 +8531,7 @@ const FlowNodeRunOutputSchema = zod.z.object({
8531
8531
  downstreamRuns: zod.z.array(DownstreamFlowNodeRunSchema),
8532
8532
  });
8533
8533
  const FlowNodeRunResultSchema = zod.z.object({
8534
- status: zod.z.nativeEnum(exports.FlowNodeRunStatus),
8534
+ status: zod.z.enum(exports.FlowNodeRunStatus),
8535
8535
  logs: zod.z.array(zod.z.any()),
8536
8536
  outputs: zod.z.array(FlowNodeRunOutputSchema),
8537
8537
  errors: zod.z.array(ErrorDataSchema),
@@ -8549,7 +8549,7 @@ const FlowNodeRunRecordWithoutOutputsDataSchema = zod.z.object({
8549
8549
  id: zod.z.string(),
8550
8550
  upstreamRuns: zod.z.array(UpstreamFlowNodeRunSchema),
8551
8551
  input: zod.z.any(),
8552
- status: zod.z.nativeEnum(exports.FlowNodeRunStatus),
8552
+ status: zod.z.enum(exports.FlowNodeRunStatus),
8553
8553
  logs: zod.z.array(zod.z.any()),
8554
8554
  outputs: zod.z.array(FlowNodeRunOutputMetadataSchema),
8555
8555
  errors: zod.z.array(ErrorDataSchema),
@@ -8911,7 +8911,7 @@ exports.IntegrationElementType = void 0;
8911
8911
 
8912
8912
  const ScenarioElement = zod.z.object({
8913
8913
  id: zod.z.string(),
8914
- type: zod.z.nativeEnum(exports.IntegrationElementType),
8914
+ type: zod.z.enum(exports.IntegrationElementType),
8915
8915
  element: zod.z.any().optional(),
8916
8916
  });
8917
8917
  const ScenarioEditableProperties = BaseMembraneInterfaceEditableProperties.extend({
@@ -8940,11 +8940,11 @@ exports.ScreenBlockType = void 0;
8940
8940
  })(exports.ScreenBlockType || (exports.ScreenBlockType = {}));
8941
8941
  const ScreenBlock = zod.z
8942
8942
  .object({
8943
- type: zod.z.nativeEnum(exports.ScreenBlockType),
8943
+ type: zod.z.enum(exports.ScreenBlockType),
8944
8944
  })
8945
8945
  .and(zod.z.record(zod.z.string(), zod.z.any()));
8946
8946
  const BaseScreen = BaseWorkspaceElement.extend({
8947
- type: zod.z.nativeEnum(exports.ScreenType),
8947
+ type: zod.z.enum(exports.ScreenType),
8948
8948
  key: zod.z.string().optional(),
8949
8949
  blocks: zod.z.array(ScreenBlock),
8950
8950
  });
@@ -8976,7 +8976,7 @@ const BaseFlowInstance = BaseMembraneInterface.extend({
8976
8976
  enabled: zod.z.boolean(),
8977
8977
  createdAt: zod.z.string(),
8978
8978
  updatedAt: zod.z.string(),
8979
- state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
8979
+ state: zod.z.enum(exports.WorkspaceElementState).optional(),
8980
8980
  customized: zod.z
8981
8981
  .object({
8982
8982
  name: zod.z.boolean().optional(),
@@ -8991,7 +8991,7 @@ exports.FlowInstanceNodeState = void 0;
8991
8991
  FlowInstanceNodeState["READY"] = "READY";
8992
8992
  })(exports.FlowInstanceNodeState || (exports.FlowInstanceNodeState = {}));
8993
8993
  const FlowInstanceNode = FlowNode.extend({
8994
- state: zod.z.nativeEnum(exports.FlowInstanceNodeState).optional(),
8994
+ state: zod.z.enum(exports.FlowInstanceNodeState).optional(),
8995
8995
  errors: zod.z.array(ErrorDataSchema).optional(),
8996
8996
  userConfig: zod.z.any().optional(),
8997
8997
  testInput: zod.z.any().optional(),
@@ -9061,7 +9061,7 @@ exports.ActionDependencyType = void 0;
9061
9061
  ActionDependencyType["DataSource"] = "DataSource";
9062
9062
  })(exports.ActionDependencyType || (exports.ActionDependencyType = {}));
9063
9063
  const ActionDependency = zod.z.object({
9064
- type: zod.z.nativeEnum(exports.ActionDependencyType),
9064
+ type: zod.z.enum(exports.ActionDependencyType),
9065
9065
  key: zod.z.string(),
9066
9066
  element: zod.z.any().optional(),
9067
9067
  });
@@ -9070,7 +9070,7 @@ const BaseActionInstance = BaseMembraneInterface.extend({
9070
9070
  universalParentId: zod.z.string().optional(),
9071
9071
  userId: zod.z.string(),
9072
9072
  instanceKey: zod.z.string().optional(),
9073
- type: zod.z.nativeEnum(exports.ActionType).optional(),
9073
+ type: zod.z.enum(exports.ActionType).optional(),
9074
9074
  inputSchema: zod.z.any().optional(),
9075
9075
  config: zod.z.any().optional(),
9076
9076
  outputSchema: zod.z.any().optional(),
@@ -9086,7 +9086,7 @@ const BaseFieldMappingInstance = BaseMembraneInterface.extend({
9086
9086
  instanceKey: zod.z.string().optional(),
9087
9087
  dataSourceInstanceId: zod.z.string().optional(),
9088
9088
  dataSourceSchema: DataSchema.optional(),
9089
- direction: zod.z.nativeEnum(exports.FieldMappingDirection).optional(),
9089
+ direction: zod.z.enum(exports.FieldMappingDirection).optional(),
9090
9090
  appSchema: DataSchema.optional(),
9091
9091
  importValue: zod.z.any().optional(),
9092
9092
  exportValue: zod.z.any().optional(),
@@ -9095,7 +9095,7 @@ const BaseFieldMappingInstance = BaseMembraneInterface.extend({
9095
9095
  unifiedImportValue: zod.z.any().optional(),
9096
9096
  frozenImportFields: zod.z.array(zod.z.string()).optional(),
9097
9097
  frozenExportFields: zod.z.array(zod.z.string()).optional(),
9098
- state: zod.z.nativeEnum(exports.WorkspaceElementState).optional(),
9098
+ state: zod.z.enum(exports.WorkspaceElementState).optional(),
9099
9099
  error: ErrorDataSchema.optional(),
9100
9100
  externalSchema: zod.z.any().optional(),
9101
9101
  });
@@ -9123,7 +9123,7 @@ const DataLink = zod.z.object({
9123
9123
  dataLinkTableInstanceId: zod.z.string(),
9124
9124
  externalRecordId: zod.z.string(),
9125
9125
  appRecordId: zod.z.string(),
9126
- direction: zod.z.nativeEnum(exports.DataLinkDirection),
9126
+ direction: zod.z.enum(exports.DataLinkDirection),
9127
9127
  });
9128
9128
  const DataLinkTableConfig = zod.z.object({
9129
9129
  key: zod.z.string(),
@@ -9138,7 +9138,7 @@ exports.HttpRequestMethod = void 0;
9138
9138
  HttpRequestMethod["DELETE"] = "DELETE";
9139
9139
  })(exports.HttpRequestMethod || (exports.HttpRequestMethod = {}));
9140
9140
  const HttpRequestSpec = zod.z.object({
9141
- method: zod.z.string().toUpperCase().pipe(zod.z.nativeEnum(exports.HttpRequestMethod)).optional(),
9141
+ method: zod.z.string().toUpperCase().pipe(zod.z.enum(exports.HttpRequestMethod)).optional(),
9142
9142
  uri: zod.z.any(),
9143
9143
  headers: zod.z.record(zod.z.string(), zod.z.any()).optional(),
9144
9144
  query: zod.z.record(zod.z.string(), zod.z.any()).optional(),
@@ -9221,7 +9221,7 @@ exports.ExternalEventSubscriptionType = void 0;
9221
9221
  ExternalEventSubscriptionType["ConnectorEvent"] = "connector-event";
9222
9222
  })(exports.ExternalEventSubscriptionType || (exports.ExternalEventSubscriptionType = {}));
9223
9223
  const ExternalEventSubscriptionConfig = zod.z.object({
9224
- type: zod.z.nativeEnum(exports.ExternalEventSubscriptionType),
9224
+ type: zod.z.enum(exports.ExternalEventSubscriptionType),
9225
9225
  dataSource: DataSourceUnitConfig.optional(),
9226
9226
  eventKey: zod.z.string().optional(),
9227
9227
  eventParameters: zod.z.any().optional(),
@@ -9233,7 +9233,7 @@ const BaseExternalEventSubscription = zod.z.object({
9233
9233
  connectionId: zod.z.string(),
9234
9234
  integrationId: zod.z.string(),
9235
9235
  config: ExternalEventSubscriptionConfig.optional(),
9236
- status: zod.z.nativeEnum(exports.ExternalEventSubscriptionStatus).optional(),
9236
+ status: zod.z.enum(exports.ExternalEventSubscriptionStatus).optional(),
9237
9237
  error: ErrorDataSchema.optional(),
9238
9238
  isRealTime: zod.z.boolean().optional(),
9239
9239
  requiresPull: zod.z.boolean().optional(),
@@ -9264,7 +9264,7 @@ const BaseExternalEventLogRecord = zod.z.object({
9264
9264
  connectionId: zod.z.string(),
9265
9265
  payload: zod.z.any().optional(),
9266
9266
  launchedFlowRunIds: zod.z.array(zod.z.string()).optional(),
9267
- status: zod.z.nativeEnum(exports.ExternalEventLogStatus),
9267
+ status: zod.z.enum(exports.ExternalEventLogStatus),
9268
9268
  error: ErrorDataSchema.optional(),
9269
9269
  });
9270
9270
 
@@ -9285,7 +9285,7 @@ const BaseExternalEventPull = zod.z.object({
9285
9285
  startDatetime: zod.z.string(),
9286
9286
  endDatetime: zod.z.string(),
9287
9287
  isFullScan: zod.z.boolean().optional(),
9288
- status: zod.z.nativeEnum(exports.ExternalEventPullStatus),
9288
+ status: zod.z.enum(exports.ExternalEventPullStatus),
9289
9289
  collectedEventIds: zod.z.array(zod.z.string()),
9290
9290
  error: ErrorDataSchema.optional(),
9291
9291
  });
@@ -9301,7 +9301,7 @@ const BaseActionRunLogRecord = BaseWorkspaceElement.extend({
9301
9301
  connectionId: zod.z.string(),
9302
9302
  input: zod.z.any().optional(),
9303
9303
  output: zod.z.any().optional(),
9304
- status: zod.z.nativeEnum(exports.ActionRunLogStatus),
9304
+ status: zod.z.enum(exports.ActionRunLogStatus),
9305
9305
  createdAt: zod.z.string(),
9306
9306
  completedAt: zod.z.string().optional(),
9307
9307
  error: ErrorDataSchema.optional(),
@@ -9591,13 +9591,13 @@ const FindFlowRunsQuery = PaginationQuery.extend({
9591
9591
  flowId: zod.z.string().optional(),
9592
9592
  universalFlowId: zod.z.string().optional(),
9593
9593
  userId: zod.z.string().optional(),
9594
- state: zod.z.nativeEnum(exports.FlowRunState).optional(),
9594
+ state: zod.z.enum(exports.FlowRunState).optional(),
9595
9595
  integrationId: zod.z.string().optional(),
9596
9596
  connectionId: zod.z.string().optional(),
9597
9597
  startedAfter: zod.z.string().optional(),
9598
9598
  });
9599
9599
  const FlowRunLaunchedByApi = zod.z.object({
9600
- type: zod.z.nativeEnum(exports.FlowRunLaunchedByTrigger),
9600
+ type: zod.z.enum(exports.FlowRunLaunchedByTrigger),
9601
9601
  ids: zod.z.array(zod.z.string()).optional(),
9602
9602
  });
9603
9603
  const FlowRunApiResponse = BaseFlowRun.extend({
@@ -9644,10 +9644,18 @@ const IntegrationApiResponse = BaseIntegration.extend({
9644
9644
 
9645
9645
  const ScenarioElementApi = zod.z.object({
9646
9646
  id: zod.z.string(),
9647
- type: zod.z.nativeEnum(exports.IntegrationElementType),
9647
+ type: zod.z.enum(exports.IntegrationElementType),
9648
9648
  element: zod.z.any().optional(),
9649
9649
  });
9650
- const FindScenariosQuery = zod.z.object({}).merge(SearchQuery).merge(PaginationQuery).merge(IncludeArchivedQuery);
9650
+ const FindScenariosQuery = zod.z
9651
+ .object({
9652
+ integrationId: zod.z.string().optional(),
9653
+ integrationKey: zod.z.string().optional(),
9654
+ parentId: zod.z.string().optional(),
9655
+ })
9656
+ .extend(SearchQuery.shape)
9657
+ .extend(PaginationQuery.shape)
9658
+ .extend(IncludeArchivedQuery.shape);
9651
9659
  const ScenarioApiResponse = BaseScenario.extend({
9652
9660
  appliedToIntegrations: AppliedToIntegrations(BaseScenario).optional(),
9653
9661
  });
@@ -9724,7 +9732,7 @@ const ListExternalEventLogRecordsQuery = CommonListElementsQuery.extend({
9724
9732
  connectionId: zod.z.string().optional(),
9725
9733
  integrationId: zod.z.string().optional(),
9726
9734
  externalEventSubscriptionId: zod.z.string().optional(),
9727
- status: zod.z.nativeEnum(exports.ExternalEventLogStatus).optional(),
9735
+ status: zod.z.enum(exports.ExternalEventLogStatus).optional(),
9728
9736
  });
9729
9737
  const ExternalEventLogRecordApiResponse = BaseExternalEventLogRecord.extend({
9730
9738
  user: BaseCustomer.optional(),
@@ -9737,7 +9745,7 @@ const ListExternalEventPullsQuery = CommonListElementsQuery.extend({
9737
9745
  connectionId: zod.z.string().optional(),
9738
9746
  integrationId: zod.z.string().optional(),
9739
9747
  externalEventSubscriptionId: zod.z.string().optional(),
9740
- status: zod.z.nativeEnum(exports.ExternalEventPullStatus).optional(),
9748
+ status: zod.z.enum(exports.ExternalEventPullStatus).optional(),
9741
9749
  });
9742
9750
  const ExternalEventPullApiResponse = BaseExternalEventPull.extend({
9743
9751
  user: BaseCustomer.optional(),
@@ -9938,12 +9946,15 @@ const WorkspaceElementSpecs = {
9938
9946
  editablePropertiesSchema: ScenarioEditableProperties,
9939
9947
  apiResponseSchema: ScenarioApiResponse,
9940
9948
  findQuerySchema: FindScenariosQuery,
9949
+ isMembraneInterface: true,
9950
+ isIntegrationLevel: true,
9941
9951
  },
9942
9952
  [exports.WorkspaceElementType.ActionInstance]: {
9943
9953
  type: exports.WorkspaceElementType.ActionInstance,
9944
9954
  apiPath: 'action-instances',
9945
9955
  name: 'Action Instance',
9946
9956
  namePlural: 'Action Instances',
9957
+ isMembraneInterface: true,
9947
9958
  },
9948
9959
  [exports.WorkspaceElementType.Action]: {
9949
9960
  type: exports.WorkspaceElementType.Action,
@@ -9953,6 +9964,8 @@ const WorkspaceElementSpecs = {
9953
9964
  editablePropertiesSchema: ActionEditableProperties,
9954
9965
  apiResponseSchema: ActionApiResponse,
9955
9966
  findQuerySchema: FindActionsQuery,
9967
+ isMembraneInterface: true,
9968
+ isIntegrationLevel: true,
9956
9969
  },
9957
9970
  [exports.WorkspaceElementType.ActionRunLogRecord]: {
9958
9971
  type: exports.WorkspaceElementType.ActionRunLogRecord,
@@ -9966,6 +9979,8 @@ const WorkspaceElementSpecs = {
9966
9979
  name: 'Flow',
9967
9980
  namePlural: 'Flows',
9968
9981
  parentFieldKey: 'universalFlowId',
9982
+ isMembraneInterface: true,
9983
+ isIntegrationLevel: true,
9969
9984
  },
9970
9985
  [exports.WorkspaceElementType.FlowInstance]: {
9971
9986
  type: exports.WorkspaceElementType.FlowInstance,
@@ -9974,6 +9989,7 @@ const WorkspaceElementSpecs = {
9974
9989
  updateSchema: updateFlowInstanceSchema,
9975
9990
  name: 'Flow',
9976
9991
  namePlural: 'Flows',
9992
+ isMembraneInterface: true,
9977
9993
  },
9978
9994
  [exports.WorkspaceElementType.FlowRun]: {
9979
9995
  type: exports.WorkspaceElementType.FlowRun,
@@ -9987,12 +10003,15 @@ const WorkspaceElementSpecs = {
9987
10003
  name: 'Field Mapping',
9988
10004
  namePlural: 'Field Mappings',
9989
10005
  parentFieldKey: 'universalFieldMappingId',
10006
+ isMembraneInterface: true,
10007
+ isIntegrationLevel: true,
9990
10008
  },
9991
10009
  [exports.WorkspaceElementType.FieldMappingInstance]: {
9992
10010
  type: exports.WorkspaceElementType.FieldMappingInstance,
9993
10011
  apiPath: 'field-mapping-instances',
9994
10012
  name: 'Field Mapping Instance',
9995
10013
  namePlural: 'Field Mapping Instances',
10014
+ isMembraneInterface: true,
9996
10015
  },
9997
10016
  [exports.WorkspaceElementType.DataCollection]: {
9998
10017
  type: exports.WorkspaceElementType.DataCollection,
@@ -10006,36 +10025,43 @@ const WorkspaceElementSpecs = {
10006
10025
  name: 'Data Source',
10007
10026
  namePlural: 'Data Sources',
10008
10027
  parentFieldKey: 'universalDataSourceId',
10028
+ isMembraneInterface: true,
10029
+ isIntegrationLevel: true,
10009
10030
  },
10010
10031
  [exports.WorkspaceElementType.DataSourceInstance]: {
10011
10032
  type: exports.WorkspaceElementType.DataSourceInstance,
10012
10033
  apiPath: 'data-source-instances',
10013
10034
  name: 'Data Source Instance',
10014
10035
  namePlural: 'Data Source Instances',
10036
+ isMembraneInterface: true,
10015
10037
  },
10016
10038
  [exports.WorkspaceElementType.DataLinkTable]: {
10017
10039
  type: exports.WorkspaceElementType.DataLinkTable,
10018
10040
  apiPath: 'data-link-tables',
10019
10041
  name: 'Data Link Table',
10020
10042
  namePlural: 'Data Link Tables',
10043
+ isMembraneInterface: true,
10021
10044
  },
10022
10045
  [exports.WorkspaceElementType.DataLinkTableInstance]: {
10023
10046
  type: exports.WorkspaceElementType.DataLinkTableInstance,
10024
10047
  apiPath: 'data-link-table-instances',
10025
10048
  name: 'Data Link Table Instance',
10026
10049
  namePlural: 'Data Link Table Instances',
10050
+ isMembraneInterface: true,
10027
10051
  },
10028
10052
  [exports.WorkspaceElementType.AppEventType]: {
10029
10053
  type: exports.WorkspaceElementType.AppEventType,
10030
10054
  apiPath: 'app-event-types',
10031
10055
  name: 'App Event Type',
10032
10056
  namePlural: 'App Event Types',
10057
+ isMembraneInterface: true,
10033
10058
  },
10034
10059
  [exports.WorkspaceElementType.AppEventSubscription]: {
10035
10060
  type: exports.WorkspaceElementType.AppEventSubscription,
10036
10061
  apiPath: 'app-event-subscriptions',
10037
10062
  name: 'App Event Subscription',
10038
10063
  namePlural: 'App Event Subscriptions',
10064
+ isMembraneInterface: true,
10039
10065
  },
10040
10066
  [exports.WorkspaceElementType.AppEventLogRecord]: {
10041
10067
  type: exports.WorkspaceElementType.AppEventLogRecord,
@@ -10048,18 +10074,21 @@ const WorkspaceElementSpecs = {
10048
10074
  apiPath: 'app-data-schemas',
10049
10075
  name: 'App Data Schema',
10050
10076
  namePlural: 'App Data Schemas',
10077
+ isMembraneInterface: true,
10051
10078
  },
10052
10079
  [exports.WorkspaceElementType.AppDataSchemaInstance]: {
10053
10080
  type: exports.WorkspaceElementType.AppDataSchemaInstance,
10054
10081
  apiPath: 'app-data-schema-instances',
10055
10082
  name: 'App Data Schema Instance',
10056
10083
  namePlural: 'App Data Schema Instances',
10084
+ isMembraneInterface: true,
10057
10085
  },
10058
10086
  [exports.WorkspaceElementType.ExternalEventSubscription]: {
10059
10087
  type: exports.WorkspaceElementType.ExternalEventSubscription,
10060
10088
  apiPath: 'external-event-subscriptions',
10061
10089
  name: 'External Event Subscription',
10062
10090
  namePlural: 'External Event Subscriptions',
10091
+ isMembraneInterface: true,
10063
10092
  },
10064
10093
  [exports.WorkspaceElementType.ExternalEventLogRecord]: {
10065
10094
  type: exports.WorkspaceElementType.ExternalEventLogRecord,
@@ -10078,6 +10107,7 @@ const WorkspaceElementSpecs = {
10078
10107
  apiPath: 'screens',
10079
10108
  name: 'Screen',
10080
10109
  namePlural: 'Screens',
10110
+ isMembraneInterface: true,
10081
10111
  },
10082
10112
  };
10083
10113
 
@@ -10895,11 +10925,6 @@ class ActionAccessor extends ElementAccessor {
10895
10925
  path: 'action',
10896
10926
  });
10897
10927
  }
10898
- async apply(integrationKeys) {
10899
- return await this.options.client.post(this.getPath('apply'), {
10900
- integrationKeys,
10901
- });
10902
- }
10903
10928
  async reset() {
10904
10929
  return await this.options.client.post(this.getPath('reset'));
10905
10930
  }
@@ -11256,11 +11281,6 @@ class DataSourceAccessor extends ElementAccessor {
11256
11281
  path: 'data-source',
11257
11282
  });
11258
11283
  }
11259
- async apply(integrationKeys) {
11260
- return await this.options.client.post(this.getPath('apply'), {
11261
- integrationKeys,
11262
- });
11263
- }
11264
11284
  async setup() {
11265
11285
  await this.options.client.post(this.getPath('setup'));
11266
11286
  }
@@ -12003,11 +12023,6 @@ class FlowAccessor extends ElementAccessor {
12003
12023
  path: 'flow',
12004
12024
  });
12005
12025
  }
12006
- async apply(integrationKeys) {
12007
- return await this.options.client.post(this.getPath('apply'), {
12008
- integrationKeys,
12009
- });
12010
- }
12011
12026
  async reset() {
12012
12027
  return await this.options.client.post(this.getPath('reset'));
12013
12028
  }
@@ -12044,11 +12059,6 @@ class FieldMappingAccessor extends ElementAccessor {
12044
12059
  async getAppSchema() {
12045
12060
  return await this.options.client.get(this.getPath('app-schema'));
12046
12061
  }
12047
- async apply(integrationKeys) {
12048
- return await this.options.client.post(this.getPath('apply'), {
12049
- integrationKeys,
12050
- });
12051
- }
12052
12062
  async setup() {
12053
12063
  return await this.options.client.post(this.getPath('setup'));
12054
12064
  }
@@ -12413,7 +12423,7 @@ const ScenarioTemplate = zod.z.object({
12413
12423
  demoAppUri: zod.z.string().optional(),
12414
12424
  demoGithubRepo: zod.z.string().optional(),
12415
12425
  demoVideoYoutubeUri: zod.z.string().optional(),
12416
- tags: zod.z.array(zod.z.nativeEnum(exports.ScenarioTemplateCategory)).optional(),
12426
+ tags: zod.z.array(zod.z.enum(exports.ScenarioTemplateCategory)).optional(),
12417
12427
  elements: ScenarioTemplateElements.optional(),
12418
12428
  connectors: zod.z.array(MinimalConnector).optional(),
12419
12429
  handyElements: zod.z.array(HandyScenarioTemplateElement).optional(),