@membranehq/sdk 0.9.11 → 0.10.10
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 +74 -31
- package/dist/bundle.js +31 -14
- package/dist/bundle.js.map +1 -1
- package/dist/dts/accessors/connections-accessors.d.ts +17 -11
- package/dist/dts/accessors/integrations-accessors.d.ts +14 -11
- package/dist/dts/agent/session.d.ts +5 -0
- package/dist/dts/alerts/index.d.ts +1 -0
- package/dist/dts/alerts/types.d.ts +106 -13
- package/dist/dts/alerts/utils.d.ts +8 -0
- package/dist/dts/config/index.d.ts +1 -0
- package/dist/dts/dto/index.d.ts +3 -0
- package/dist/dts/functions/base.d.ts +2 -2
- package/dist/dts/index.browser.d.ts +1 -0
- package/dist/dts/logging/index.d.ts +9 -0
- package/dist/dts/orgs/types.d.ts +63 -1
- package/dist/dts/platform-users.d.ts +17 -2
- package/dist/dts/usage/types.d.ts +1 -0
- package/dist/dts/webhooks/types.d.ts +4 -2
- package/dist/dts/workspace-elements/api/action-run-log-records-api.d.ts +6 -2
- package/dist/dts/workspace-elements/api/connections-api.d.ts +18 -3
- package/dist/dts/workspace-elements/api/data-link-table-instances-api.d.ts +3 -1
- package/dist/dts/workspace-elements/api/data-source-instances-api.d.ts +3 -1
- package/dist/dts/workspace-elements/api/external-event-log-records-api.d.ts +3 -1
- package/dist/dts/workspace-elements/api/external-event-pulls-api.d.ts +3 -1
- package/dist/dts/workspace-elements/api/external-event-subscriptions-api.d.ts +3 -1
- package/dist/dts/workspace-elements/api/field-mapping-instances-api.d.ts +6 -2
- package/dist/dts/workspace-elements/api/flow-runs-api.d.ts +6 -2
- package/dist/dts/workspace-elements/api/flows-api.d.ts +6 -2
- package/dist/dts/workspace-elements/api/integrations-api.d.ts +5 -1
- package/dist/dts/workspace-elements/api/packages-api.d.ts +2 -0
- package/dist/dts/workspace-elements/base/actions/index.d.ts +1 -1
- package/dist/dts/workspace-elements/base/connections/types.d.ts +3 -1
- package/dist/dts/workspace-elements/base/connectors/auth.d.ts +20 -0
- package/dist/dts/workspace-elements/base/connectors/functions.d.ts +12 -490
- package/dist/dts/workspace-elements/base/connectors/functions.test.d.ts +1 -0
- package/dist/dts/workspace-elements/base/connectors/index.d.ts +1 -0
- package/dist/dts/workspace-elements/base/connectors/types.d.ts +922 -478
- package/dist/dts/workspace-elements/base/data-collections/data-locations/collections/methods/base.d.ts +1 -2
- package/dist/dts/workspace-elements/base/packages/index.d.ts +2 -0
- package/dist/dts/workspace-elements/element-utils.d.ts +2 -0
- package/dist/dts/workspace-elements/element-utils.test.d.ts +1 -0
- package/dist/dts/workspace-elements/index.d.ts +1 -0
- package/dist/dts/workspace-elements/types.d.ts +9 -3
- package/dist/dts/workspaces/types.d.ts +39 -1
- package/dist/index.browser.d.mts +1356 -583
- package/dist/index.browser.d.ts +1356 -583
- package/dist/index.browser.js +592 -114
- package/dist/index.browser.js.map +1 -1
- package/dist/index.browser.mjs +569 -115
- package/dist/index.browser.mjs.map +1 -1
- package/dist/index.node.d.mts +1357 -583
- package/dist/index.node.d.ts +1357 -583
- package/dist/index.node.js +599 -114
- package/dist/index.node.js.map +1 -1
- package/dist/index.node.mjs +576 -115
- package/dist/index.node.mjs.map +1 -1
- package/package.json +2 -1
package/dist/index.node.mjs
CHANGED
|
@@ -3478,6 +3478,7 @@ var WorkspaceEventType;
|
|
|
3478
3478
|
WorkspaceEventType["FlowRunCompleted"] = "flowRun.completed";
|
|
3479
3479
|
WorkspaceEventType["FlowRunFailed"] = "flowRun.failed";
|
|
3480
3480
|
WorkspaceEventType["FlowRunStopped"] = "flowRun.stopped";
|
|
3481
|
+
WorkspaceEventType["AlertCreated"] = "alert.created";
|
|
3481
3482
|
})(WorkspaceEventType || (WorkspaceEventType = {}));
|
|
3482
3483
|
var WorkspaceElementState;
|
|
3483
3484
|
(function (WorkspaceElementState) {
|
|
@@ -3528,8 +3529,9 @@ const BaseIntegrationLevelMembraneInterfaceExportProperties = BaseMembraneInterf
|
|
|
3528
3529
|
parentUuid: z.string().optional(),
|
|
3529
3530
|
isCustomized: z.boolean().optional(),
|
|
3530
3531
|
});
|
|
3532
|
+
const MembraneElementLayer = z.enum(['universal', 'integration', 'connection']);
|
|
3531
3533
|
const IntegrationLevelMembraneInterfaceSelectorQuery = z.object({
|
|
3532
|
-
layer:
|
|
3534
|
+
layer: MembraneElementLayer.optional(),
|
|
3533
3535
|
integrationKey: z.string().optional(),
|
|
3534
3536
|
integrationId: z.string().optional(),
|
|
3535
3537
|
connectionId: z.string().optional(),
|
|
@@ -3549,8 +3551,7 @@ const WorkspaceElementSearchQuery = z.object({
|
|
|
3549
3551
|
});
|
|
3550
3552
|
const WorkspaceElementSearchResult = z.object({
|
|
3551
3553
|
elementType: z.enum(WorkspaceElementType),
|
|
3552
|
-
|
|
3553
|
-
name: z.string(),
|
|
3554
|
+
element: z.any(),
|
|
3554
3555
|
});
|
|
3555
3556
|
|
|
3556
3557
|
function mergeWithFormulas(a, b) {
|
|
@@ -3772,7 +3773,9 @@ const BaseConnection = BaseWorkspaceElement.extend({
|
|
|
3772
3773
|
isDefunct: z.boolean().optional(),
|
|
3773
3774
|
state: z.enum(WorkspaceElementState).optional(),
|
|
3774
3775
|
error: ErrorDataSchema.optional(),
|
|
3775
|
-
integrationId: z.string(),
|
|
3776
|
+
integrationId: z.string().optional(),
|
|
3777
|
+
connectorId: z.string().optional(),
|
|
3778
|
+
connectorVersion: z.string().optional(),
|
|
3776
3779
|
authOptionKey: z.string().optional(),
|
|
3777
3780
|
createdAt: z.string(),
|
|
3778
3781
|
updatedAt: z.string(),
|
|
@@ -3858,6 +3861,7 @@ const ConnectorAuthSpec = z.object({
|
|
|
3858
3861
|
title: z.string().optional(),
|
|
3859
3862
|
description: z.string().optional(),
|
|
3860
3863
|
type: z.enum(CONNECTOR_AUTH_TYPES),
|
|
3864
|
+
inputSchema: DataSchema.optional(),
|
|
3861
3865
|
ui: z
|
|
3862
3866
|
.object({
|
|
3863
3867
|
schema: DataSchema.optional(),
|
|
@@ -3992,7 +3996,7 @@ const ConnectorAuthMethodTypes = {
|
|
|
3992
3996
|
},
|
|
3993
3997
|
};
|
|
3994
3998
|
},
|
|
3995
|
-
getOutputSchema: () => REST_API_CLIENT_SCHEMA,
|
|
3999
|
+
getOutputSchema: () => REST_API_CLIENT_SCHEMA$1,
|
|
3996
4000
|
isRequired: true,
|
|
3997
4001
|
},
|
|
3998
4002
|
test: {
|
|
@@ -4147,7 +4151,7 @@ const REST_API_CLIENT_RESPONSE_HANDLERS_SCHEMA = {
|
|
|
4147
4151
|
},
|
|
4148
4152
|
},
|
|
4149
4153
|
};
|
|
4150
|
-
const REST_API_CLIENT_SCHEMA = {
|
|
4154
|
+
const REST_API_CLIENT_SCHEMA$1 = {
|
|
4151
4155
|
type: 'object',
|
|
4152
4156
|
properties: {
|
|
4153
4157
|
args: {
|
|
@@ -4185,11 +4189,6 @@ const CONNECTOR_DOCS_DIR = 'docs';
|
|
|
4185
4189
|
const CONNECTOR_GLOBAL_WEBHOOKS_DIR = 'global-webhooks';
|
|
4186
4190
|
const CONNECTOR_EVENTS_DIR = 'events';
|
|
4187
4191
|
|
|
4188
|
-
const ConnectorOperationMethodImplementationTypes = [
|
|
4189
|
-
ConnectorMethodImplementationType.restApiMapping,
|
|
4190
|
-
ConnectorMethodImplementationType.javascript,
|
|
4191
|
-
];
|
|
4192
|
-
|
|
4193
4192
|
var FunctionType;
|
|
4194
4193
|
(function (FunctionType) {
|
|
4195
4194
|
FunctionType["mapping"] = "mapping";
|
|
@@ -4209,10 +4208,157 @@ const BaseFunctionDefinition = z.object({
|
|
|
4209
4208
|
});
|
|
4210
4209
|
const GenericFunctionDefinition = z
|
|
4211
4210
|
.object({
|
|
4212
|
-
type: z.enum(['mapping', 'operation-mapping', 'rest-api-mapping', 'graphql-api-mapping', 'javascript']),
|
|
4211
|
+
type: z.enum(['mapping', 'operation-mapping', 'rest-api-mapping', 'graphql-api-mapping', 'javascript']).optional(),
|
|
4213
4212
|
})
|
|
4214
4213
|
.loose();
|
|
4215
4214
|
|
|
4215
|
+
function getEffectiveConnectorOption(connector, optionKey) {
|
|
4216
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
4217
|
+
const option = (_a = connector.options) === null || _a === void 0 ? void 0 : _a[optionKey];
|
|
4218
|
+
const connectorInputSchema = (_b = connector.inputSchema) !== null && _b !== void 0 ? _b : (_c = connector.ui) === null || _c === void 0 ? void 0 : _c.schema;
|
|
4219
|
+
const optionInputSchema = (_d = option === null || option === void 0 ? void 0 : option.inputSchema) !== null && _d !== void 0 ? _d : (_e = option === null || option === void 0 ? void 0 : option.ui) === null || _e === void 0 ? void 0 : _e.schema;
|
|
4220
|
+
return {
|
|
4221
|
+
...connector,
|
|
4222
|
+
...option,
|
|
4223
|
+
inputSchema: mergeSchemas([connectorInputSchema, optionInputSchema]),
|
|
4224
|
+
parametersSchema: mergeSchemas([connector.parametersSchema, option === null || option === void 0 ? void 0 : option.parametersSchema]),
|
|
4225
|
+
credentialsSchema: mergeSchemas([connector.credentialsSchema, option === null || option === void 0 ? void 0 : option.credentialsSchema]),
|
|
4226
|
+
makeApiClient: (_f = option === null || option === void 0 ? void 0 : option.makeApiClient) !== null && _f !== void 0 ? _f : connector.makeApiClient,
|
|
4227
|
+
test: (_g = option === null || option === void 0 ? void 0 : option.test) !== null && _g !== void 0 ? _g : connector.test,
|
|
4228
|
+
};
|
|
4229
|
+
}
|
|
4230
|
+
const getDefaultInputSchema = (authConfig) => {
|
|
4231
|
+
var _a, _b, _c;
|
|
4232
|
+
const connectionParameters = (_a = authConfig === null || authConfig === void 0 ? void 0 : authConfig.inputSchema) !== null && _a !== void 0 ? _a : (_b = authConfig === null || authConfig === void 0 ? void 0 : authConfig.ui) === null || _b === void 0 ? void 0 : _b.schema;
|
|
4233
|
+
return {
|
|
4234
|
+
type: 'object',
|
|
4235
|
+
properties: {
|
|
4236
|
+
connectorParameters: (_c = authConfig === null || authConfig === void 0 ? void 0 : authConfig.parametersSchema) !== null && _c !== void 0 ? _c : {},
|
|
4237
|
+
...(connectionParameters && { connectionParameters }),
|
|
4238
|
+
},
|
|
4239
|
+
};
|
|
4240
|
+
};
|
|
4241
|
+
const REST_API_CLIENT_SCHEMA = {
|
|
4242
|
+
type: 'object',
|
|
4243
|
+
properties: {
|
|
4244
|
+
args: {
|
|
4245
|
+
type: 'object',
|
|
4246
|
+
properties: {
|
|
4247
|
+
baseUri: {
|
|
4248
|
+
type: 'string',
|
|
4249
|
+
description: 'This prefix will be added to all relative API requests.',
|
|
4250
|
+
},
|
|
4251
|
+
query: {
|
|
4252
|
+
type: 'object',
|
|
4253
|
+
additionalProperties: true,
|
|
4254
|
+
},
|
|
4255
|
+
headers: {
|
|
4256
|
+
type: 'object',
|
|
4257
|
+
additionalProperties: true,
|
|
4258
|
+
},
|
|
4259
|
+
auth: {
|
|
4260
|
+
type: 'object',
|
|
4261
|
+
description: 'Basic authentication',
|
|
4262
|
+
properties: {
|
|
4263
|
+
username: { type: 'string' },
|
|
4264
|
+
password: { type: 'string' },
|
|
4265
|
+
},
|
|
4266
|
+
},
|
|
4267
|
+
},
|
|
4268
|
+
},
|
|
4269
|
+
},
|
|
4270
|
+
};
|
|
4271
|
+
const ConnectorFunctionSpecs = {
|
|
4272
|
+
getOAuthConfig: {
|
|
4273
|
+
authTypes: ['oauth2', 'oauth1'],
|
|
4274
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4275
|
+
getInputSchema: (authConfig) => {
|
|
4276
|
+
const schema = getDefaultInputSchema(authConfig);
|
|
4277
|
+
return {
|
|
4278
|
+
...schema,
|
|
4279
|
+
properties: {
|
|
4280
|
+
...schema.properties,
|
|
4281
|
+
redirectUri: { type: 'string' },
|
|
4282
|
+
state: { type: 'string' },
|
|
4283
|
+
},
|
|
4284
|
+
};
|
|
4285
|
+
},
|
|
4286
|
+
getOutputSchema: (authConfig) => {
|
|
4287
|
+
return (authConfig === null || authConfig === void 0 ? void 0 : authConfig.type) === 'oauth1' ? OAUTH1_CONFIG_SCHEMA : OAUTH_CONFIG_SCHEMA;
|
|
4288
|
+
},
|
|
4289
|
+
isRequired: true,
|
|
4290
|
+
},
|
|
4291
|
+
getTokenData: {
|
|
4292
|
+
authTypes: ['oauth2'],
|
|
4293
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4294
|
+
getInputSchema: getDefaultInputSchema,
|
|
4295
|
+
getOutputSchema: (authConfig) => {
|
|
4296
|
+
var _a;
|
|
4297
|
+
return (_a = authConfig === null || authConfig === void 0 ? void 0 : authConfig.customCredentialsSchema) !== null && _a !== void 0 ? _a : authConfig === null || authConfig === void 0 ? void 0 : authConfig.credentialsSchema;
|
|
4298
|
+
},
|
|
4299
|
+
isRequired: false,
|
|
4300
|
+
},
|
|
4301
|
+
getCredentialsFromAccessTokenResponse: {
|
|
4302
|
+
authTypes: ['oauth2'],
|
|
4303
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4304
|
+
isRequired: false,
|
|
4305
|
+
},
|
|
4306
|
+
getCredentialsFromRefreshTokenResponse: {
|
|
4307
|
+
authTypes: ['oauth2'],
|
|
4308
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4309
|
+
isRequired: false,
|
|
4310
|
+
},
|
|
4311
|
+
getCredentialsFromConnectionParameters: {
|
|
4312
|
+
authTypes: ['client-credentials', 'oauth2'],
|
|
4313
|
+
getInputSchema: getDefaultInputSchema,
|
|
4314
|
+
getOutputSchema: (authConfig) => {
|
|
4315
|
+
return authConfig === null || authConfig === void 0 ? void 0 : authConfig.credentialsSchema;
|
|
4316
|
+
},
|
|
4317
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4318
|
+
isRequired: false,
|
|
4319
|
+
},
|
|
4320
|
+
refreshCredentials: {
|
|
4321
|
+
authTypes: ['oauth2', 'oauth1', 'client-credentials'],
|
|
4322
|
+
getInputSchema: getDefaultInputSchema,
|
|
4323
|
+
getOutputSchema: (authConfig) => {
|
|
4324
|
+
return authConfig === null || authConfig === void 0 ? void 0 : authConfig.credentialsSchema;
|
|
4325
|
+
},
|
|
4326
|
+
supportedFunctionTypes: [FunctionType.javascript],
|
|
4327
|
+
isRequired: false,
|
|
4328
|
+
},
|
|
4329
|
+
makeApiClient: {
|
|
4330
|
+
supportedFunctionTypes: [FunctionType.mapping, FunctionType.javascript],
|
|
4331
|
+
getInputSchema: (authConfig) => {
|
|
4332
|
+
var _a, _b, _c;
|
|
4333
|
+
return {
|
|
4334
|
+
type: 'object',
|
|
4335
|
+
properties: {
|
|
4336
|
+
credentials: mergeSchemas([
|
|
4337
|
+
((_a = authConfig === null || authConfig === void 0 ? void 0 : authConfig.customCredentialsSchema) !== null && _a !== void 0 ? _a : authConfig === null || authConfig === void 0 ? void 0 : authConfig.credentialsSchema),
|
|
4338
|
+
(_b = authConfig === null || authConfig === void 0 ? void 0 : authConfig.inputSchema) !== null && _b !== void 0 ? _b : (_c = authConfig === null || authConfig === void 0 ? void 0 : authConfig.ui) === null || _c === void 0 ? void 0 : _c.schema,
|
|
4339
|
+
]),
|
|
4340
|
+
},
|
|
4341
|
+
};
|
|
4342
|
+
},
|
|
4343
|
+
getOutputSchema: () => REST_API_CLIENT_SCHEMA,
|
|
4344
|
+
isRequired: true,
|
|
4345
|
+
},
|
|
4346
|
+
test: {
|
|
4347
|
+
supportedFunctionTypes: [FunctionType.operationMapping, FunctionType.restApiMapping, FunctionType.javascript],
|
|
4348
|
+
getOutputSchema: () => ({
|
|
4349
|
+
title: 'Success Criteria',
|
|
4350
|
+
description: 'If this value is truthy, the test is considered a success.',
|
|
4351
|
+
type: 'boolean',
|
|
4352
|
+
}),
|
|
4353
|
+
isRequired: true,
|
|
4354
|
+
},
|
|
4355
|
+
};
|
|
4356
|
+
|
|
4357
|
+
const ConnectorOperationMethodImplementationTypes = [
|
|
4358
|
+
ConnectorMethodImplementationType.restApiMapping,
|
|
4359
|
+
ConnectorMethodImplementationType.javascript,
|
|
4360
|
+
];
|
|
4361
|
+
|
|
4216
4362
|
const GraphQLFieldMappingSchema = z.lazy(() => z.object({
|
|
4217
4363
|
field: z.string(),
|
|
4218
4364
|
args: z.record(z.string(), z.any()).optional(),
|
|
@@ -4322,7 +4468,8 @@ const ConnectorSpec = z.object({
|
|
|
4322
4468
|
type: z.enum(['openapi', 'graphql']),
|
|
4323
4469
|
})
|
|
4324
4470
|
.optional(),
|
|
4325
|
-
ui: ConnectorUiSpec.optional(),
|
|
4471
|
+
ui: ConnectorUiSpec.optional().describe('[INTERNAL] Deprecated: Use inputSchema instead'),
|
|
4472
|
+
inputSchema: DataSchema.optional(),
|
|
4326
4473
|
auth: ConnectorAuth.optional(),
|
|
4327
4474
|
parametersSchema: DataSchema.optional(),
|
|
4328
4475
|
udms: z.array(z.string()).optional(),
|
|
@@ -4345,14 +4492,10 @@ const ConnectorAuthWithFunctions = z.object({
|
|
|
4345
4492
|
type: z
|
|
4346
4493
|
.enum(['integration-app-token', 'membrane-token', 'oauth2', 'oauth1', 'client-credentials', 'proxy'])
|
|
4347
4494
|
.optional(),
|
|
4495
|
+
credentialsSchema: DataSchema.optional(),
|
|
4348
4496
|
customCredentialsSchema: DataSchema.optional(),
|
|
4349
|
-
|
|
4350
|
-
|
|
4351
|
-
schema: DataSchema.optional(),
|
|
4352
|
-
description: z.string().optional(),
|
|
4353
|
-
helpUri: z.string().optional(),
|
|
4354
|
-
})
|
|
4355
|
-
.optional(),
|
|
4497
|
+
inputSchema: DataSchema.optional(),
|
|
4498
|
+
parametersSchema: DataSchema.optional(),
|
|
4356
4499
|
getCredentialsFromConnectionParameters: GenericFunctionDefinition.optional(),
|
|
4357
4500
|
refreshCredentials: GenericFunctionDefinition.optional(),
|
|
4358
4501
|
makeApiClient: GenericFunctionDefinition.optional(),
|
|
@@ -4360,18 +4503,40 @@ const ConnectorAuthWithFunctions = z.object({
|
|
|
4360
4503
|
getTokenData: GenericFunctionDefinition.optional(),
|
|
4361
4504
|
getCredentialsFromAccessTokenResponse: GenericFunctionDefinition.optional(),
|
|
4362
4505
|
getCredentialsFromRefreshTokenResponse: GenericFunctionDefinition.optional(),
|
|
4506
|
+
test: GenericFunctionDefinition.optional(),
|
|
4363
4507
|
proxyKey: z.string().optional(),
|
|
4508
|
+
ui: z
|
|
4509
|
+
.object({
|
|
4510
|
+
schema: DataSchema.optional(),
|
|
4511
|
+
description: z.string().optional(),
|
|
4512
|
+
helpUri: z.string().optional(),
|
|
4513
|
+
})
|
|
4514
|
+
.optional()
|
|
4515
|
+
.describe('[INTERNAL] Deprecated: Use inputSchema instead'),
|
|
4364
4516
|
});
|
|
4365
|
-
const
|
|
4517
|
+
const WriteableConnectorOption = ConnectorAuthWithFunctions.extend({
|
|
4366
4518
|
title: z.string().optional(),
|
|
4367
4519
|
description: z.string().optional(),
|
|
4368
4520
|
enabled: z.any().optional(),
|
|
4521
|
+
}).omit({
|
|
4522
|
+
credentialsSchema: true,
|
|
4523
|
+
});
|
|
4524
|
+
const ConnectorOption = WriteableConnectorOption.extend({
|
|
4525
|
+
credentialsSchema: DataSchema.optional(),
|
|
4526
|
+
});
|
|
4527
|
+
const GeneratedConnectorOption = z.object({
|
|
4528
|
+
key: z.string(),
|
|
4529
|
+
type: z.enum(CONNECTOR_AUTH_TYPES),
|
|
4530
|
+
title: z.string().optional(),
|
|
4531
|
+
description: z.string().optional(),
|
|
4532
|
+
inputSchema: DataSchema.optional(),
|
|
4369
4533
|
});
|
|
4370
4534
|
const ConnectorOptions = z.record(z.string(), ConnectorOption);
|
|
4371
4535
|
const WritableConnectorVersionData = ConnectorAuthWithFunctions.extend({
|
|
4372
4536
|
parametersSchema: DataSchema.optional(),
|
|
4373
|
-
|
|
4374
|
-
|
|
4537
|
+
options: z.record(z.string(), WriteableConnectorOption).optional(),
|
|
4538
|
+
}).omit({
|
|
4539
|
+
credentialsSchema: true,
|
|
4375
4540
|
});
|
|
4376
4541
|
const ConnectorVersionData = z
|
|
4377
4542
|
.object({
|
|
@@ -4389,7 +4554,10 @@ const ConnectorVersionData = z
|
|
|
4389
4554
|
version: z.string(),
|
|
4390
4555
|
credentialsSchema: DataSchema.optional(),
|
|
4391
4556
|
})
|
|
4392
|
-
.extend(WritableConnectorVersionData.shape)
|
|
4557
|
+
.extend(WritableConnectorVersionData.shape)
|
|
4558
|
+
.extend({
|
|
4559
|
+
options: ConnectorOptions.optional(),
|
|
4560
|
+
});
|
|
4393
4561
|
const ConnectorVersion = ConnectorVersionData.extend({
|
|
4394
4562
|
id: z.string(),
|
|
4395
4563
|
connectorId: z.string(),
|
|
@@ -4404,6 +4572,7 @@ const WriteableConnectorFields = z
|
|
|
4404
4572
|
categories: z.array(z.string()).optional(),
|
|
4405
4573
|
})
|
|
4406
4574
|
.extend(WritableConnectorVersionData.shape);
|
|
4575
|
+
const ConnectorExportProperties = WriteableConnectorFields;
|
|
4407
4576
|
const UpdateConnectorRequest = WriteableConnectorFields;
|
|
4408
4577
|
const CreateConnectorRequest = WriteableConnectorFields.extend({
|
|
4409
4578
|
name: z.string(),
|
|
@@ -4413,16 +4582,12 @@ const BaseConnector = z.object({
|
|
|
4413
4582
|
id: z.string(),
|
|
4414
4583
|
key: z.string(),
|
|
4415
4584
|
uuid: z.string(),
|
|
4585
|
+
appUuid: z.string().optional(),
|
|
4416
4586
|
name: z.string(),
|
|
4417
4587
|
logoUri: z.string(),
|
|
4418
|
-
appUri: z.string(),
|
|
4419
|
-
apiDocsUri: z.string(),
|
|
4420
|
-
hasReadme: z.boolean(),
|
|
4421
|
-
status: z.string().optional(),
|
|
4422
4588
|
categories: z.array(z.string()).optional(),
|
|
4423
4589
|
isPublic: z.boolean().optional(),
|
|
4424
4590
|
popularity: z.number().optional(),
|
|
4425
|
-
appUuid: z.string().optional(),
|
|
4426
4591
|
});
|
|
4427
4592
|
const Connector = z
|
|
4428
4593
|
.object({})
|
|
@@ -4486,8 +4651,8 @@ const DataCollectionMethodCreate = {
|
|
|
4486
4651
|
},
|
|
4487
4652
|
};
|
|
4488
4653
|
},
|
|
4489
|
-
getInputSchema: ({ collectionSpec, method,
|
|
4490
|
-
var _a
|
|
4654
|
+
getInputSchema: ({ collectionSpec, method, credentialsSchema }) => {
|
|
4655
|
+
var _a;
|
|
4491
4656
|
let fieldsSchema = collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema;
|
|
4492
4657
|
if (method === null || method === void 0 ? void 0 : method.fields) {
|
|
4493
4658
|
fieldsSchema = pickFieldsFromSchema(fieldsSchema, method.fields);
|
|
@@ -4497,12 +4662,12 @@ const DataCollectionMethodCreate = {
|
|
|
4497
4662
|
}
|
|
4498
4663
|
return {
|
|
4499
4664
|
type: 'object',
|
|
4500
|
-
properties: {
|
|
4665
|
+
properties: nonEmptyObjectProperties({
|
|
4501
4666
|
fields: (_a = transformVariablesWith(fieldsSchema, (locator) => `fields.${locatorToField(locator)}`)) !== null && _a !== void 0 ? _a : {
|
|
4502
4667
|
type: 'object',
|
|
4503
4668
|
},
|
|
4504
|
-
credentials:
|
|
4505
|
-
},
|
|
4669
|
+
credentials: credentialsSchema,
|
|
4670
|
+
}),
|
|
4506
4671
|
};
|
|
4507
4672
|
},
|
|
4508
4673
|
getOutputSchema: ({}) => ({
|
|
@@ -4517,17 +4682,16 @@ const DataCollectionMethodCreate = {
|
|
|
4517
4682
|
const DataCollectionMethodDelete = {
|
|
4518
4683
|
name: 'Delete',
|
|
4519
4684
|
description: 'Delete a data record from the collection by id',
|
|
4520
|
-
getInputSchema: ({ collectionHandler, parameters,
|
|
4521
|
-
var _a;
|
|
4685
|
+
getInputSchema: ({ collectionHandler, parameters, credentialsSchema }) => {
|
|
4522
4686
|
return {
|
|
4523
4687
|
type: 'object',
|
|
4524
|
-
properties: {
|
|
4688
|
+
properties: nonEmptyObjectProperties({
|
|
4525
4689
|
id: {
|
|
4526
4690
|
type: 'string',
|
|
4527
4691
|
referenceCollection: { key: collectionHandler === null || collectionHandler === void 0 ? void 0 : collectionHandler.key, parameters },
|
|
4528
4692
|
},
|
|
4529
|
-
credentials:
|
|
4530
|
-
},
|
|
4693
|
+
credentials: credentialsSchema,
|
|
4694
|
+
}),
|
|
4531
4695
|
};
|
|
4532
4696
|
},
|
|
4533
4697
|
getOutputSchema: () => null,
|
|
@@ -4551,15 +4715,14 @@ const DataCollectionMethodFind = {
|
|
|
4551
4715
|
},
|
|
4552
4716
|
};
|
|
4553
4717
|
},
|
|
4554
|
-
getInputSchema: ({ collectionSpec, method,
|
|
4555
|
-
var _a;
|
|
4718
|
+
getInputSchema: ({ collectionSpec, method, credentialsSchema }) => {
|
|
4556
4719
|
const queryFieldsSchema = pickFieldsFromSchema(collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema, method === null || method === void 0 ? void 0 : method.queryFields);
|
|
4557
4720
|
const schema = {
|
|
4558
4721
|
type: 'object',
|
|
4559
|
-
properties: {
|
|
4722
|
+
properties: nonEmptyObjectProperties({
|
|
4560
4723
|
cursor: { type: 'string' },
|
|
4561
|
-
credentials:
|
|
4562
|
-
},
|
|
4724
|
+
credentials: credentialsSchema,
|
|
4725
|
+
}),
|
|
4563
4726
|
};
|
|
4564
4727
|
if (queryFieldsSchema === null || queryFieldsSchema === void 0 ? void 0 : queryFieldsSchema.properties) {
|
|
4565
4728
|
schema.properties = {
|
|
@@ -4590,19 +4753,16 @@ const DataCollectionMethodFind = {
|
|
|
4590
4753
|
const DataCollectionMethodFindById = {
|
|
4591
4754
|
name: 'Find by ID',
|
|
4592
4755
|
description: 'Find a single data record in the collection by its id',
|
|
4593
|
-
getInputSchema: ({ collectionHandler, parameters,
|
|
4594
|
-
|
|
4595
|
-
|
|
4596
|
-
|
|
4597
|
-
|
|
4598
|
-
|
|
4599
|
-
type: 'string',
|
|
4600
|
-
referenceCollection: { key: collectionHandler === null || collectionHandler === void 0 ? void 0 : collectionHandler.key, parameters },
|
|
4601
|
-
},
|
|
4602
|
-
credentials: (_a = connectorSpec === null || connectorSpec === void 0 ? void 0 : connectorSpec.auth) === null || _a === void 0 ? void 0 : _a.credentialsSchema,
|
|
4756
|
+
getInputSchema: ({ collectionHandler, parameters, credentialsSchema }) => ({
|
|
4757
|
+
type: 'object',
|
|
4758
|
+
properties: nonEmptyObjectProperties({
|
|
4759
|
+
id: {
|
|
4760
|
+
type: 'string',
|
|
4761
|
+
referenceCollection: { key: collectionHandler === null || collectionHandler === void 0 ? void 0 : collectionHandler.key, parameters },
|
|
4603
4762
|
},
|
|
4604
|
-
|
|
4605
|
-
|
|
4763
|
+
credentials: credentialsSchema,
|
|
4764
|
+
}),
|
|
4765
|
+
}),
|
|
4606
4766
|
getOutputSchema: ({ collectionSpec }) => {
|
|
4607
4767
|
var _a;
|
|
4608
4768
|
return ({
|
|
@@ -4631,8 +4791,7 @@ const DataCollectionMethodList = {
|
|
|
4631
4791
|
},
|
|
4632
4792
|
};
|
|
4633
4793
|
},
|
|
4634
|
-
getInputSchema: ({ method, collectionSpec,
|
|
4635
|
-
var _a;
|
|
4794
|
+
getInputSchema: ({ method, collectionSpec, credentialsSchema }) => {
|
|
4636
4795
|
const fieldsSchema = collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema;
|
|
4637
4796
|
let filterSchema;
|
|
4638
4797
|
if (method === null || method === void 0 ? void 0 : method.filterFields) {
|
|
@@ -4646,7 +4805,7 @@ const DataCollectionMethodList = {
|
|
|
4646
4805
|
type: 'string',
|
|
4647
4806
|
description: 'Cursor returned in response to the previous "list" request',
|
|
4648
4807
|
},
|
|
4649
|
-
credentials:
|
|
4808
|
+
credentials: credentialsSchema,
|
|
4650
4809
|
}),
|
|
4651
4810
|
};
|
|
4652
4811
|
},
|
|
@@ -4685,15 +4844,14 @@ const DataCollectionMethodMatch = {
|
|
|
4685
4844
|
},
|
|
4686
4845
|
};
|
|
4687
4846
|
},
|
|
4688
|
-
getInputSchema: ({ collectionSpec, method,
|
|
4689
|
-
var _a;
|
|
4847
|
+
getInputSchema: ({ collectionSpec, method, credentialsSchema }) => {
|
|
4690
4848
|
const fieldsSchema = pickFieldsFromSchema(collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema, method === null || method === void 0 ? void 0 : method.fields);
|
|
4691
4849
|
return {
|
|
4692
4850
|
type: 'object',
|
|
4693
|
-
properties: {
|
|
4851
|
+
properties: nonEmptyObjectProperties({
|
|
4694
4852
|
query: transformVariablesWith(fieldsSchema !== null && fieldsSchema !== void 0 ? fieldsSchema : {}, (locator) => `query.${locatorToField(locator)}`),
|
|
4695
|
-
credentials:
|
|
4696
|
-
},
|
|
4853
|
+
credentials: credentialsSchema,
|
|
4854
|
+
}),
|
|
4697
4855
|
};
|
|
4698
4856
|
},
|
|
4699
4857
|
getOutputSchema: ({ collectionSpec }) => {
|
|
@@ -4711,17 +4869,14 @@ const DataCollectionMethodMatch = {
|
|
|
4711
4869
|
const DataCollectionMethodSearch = {
|
|
4712
4870
|
name: 'Search',
|
|
4713
4871
|
description: 'Find data records in a collection by a string query',
|
|
4714
|
-
getInputSchema: ({
|
|
4715
|
-
|
|
4716
|
-
|
|
4717
|
-
type: '
|
|
4718
|
-
|
|
4719
|
-
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
},
|
|
4723
|
-
});
|
|
4724
|
-
},
|
|
4872
|
+
getInputSchema: ({ credentialsSchema }) => ({
|
|
4873
|
+
type: 'object',
|
|
4874
|
+
properties: nonEmptyObjectProperties({
|
|
4875
|
+
query: { type: 'string' },
|
|
4876
|
+
cursor: { type: 'string' },
|
|
4877
|
+
credentials: credentialsSchema,
|
|
4878
|
+
}),
|
|
4879
|
+
}),
|
|
4725
4880
|
getOutputSchema: ({ collectionSpec }) => {
|
|
4726
4881
|
var _a;
|
|
4727
4882
|
return ({
|
|
@@ -4758,8 +4913,8 @@ const DataCollectionMethodUpdate = {
|
|
|
4758
4913
|
},
|
|
4759
4914
|
};
|
|
4760
4915
|
},
|
|
4761
|
-
getInputSchema: ({ collectionSpec, collectionHandler,
|
|
4762
|
-
var _a
|
|
4916
|
+
getInputSchema: ({ collectionSpec, collectionHandler, credentialsSchema, method, parameters }) => {
|
|
4917
|
+
var _a;
|
|
4763
4918
|
let fieldsSchema = collectionSpec === null || collectionSpec === void 0 ? void 0 : collectionSpec.fieldsSchema;
|
|
4764
4919
|
if (method === null || method === void 0 ? void 0 : method.fields) {
|
|
4765
4920
|
fieldsSchema = pickFieldsFromSchema(fieldsSchema, method.fields);
|
|
@@ -4769,7 +4924,7 @@ const DataCollectionMethodUpdate = {
|
|
|
4769
4924
|
}
|
|
4770
4925
|
return {
|
|
4771
4926
|
type: 'object',
|
|
4772
|
-
properties: {
|
|
4927
|
+
properties: nonEmptyObjectProperties({
|
|
4773
4928
|
id: {
|
|
4774
4929
|
type: 'string',
|
|
4775
4930
|
referenceCollection: { key: collectionHandler === null || collectionHandler === void 0 ? void 0 : collectionHandler.key, parameters },
|
|
@@ -4777,8 +4932,8 @@ const DataCollectionMethodUpdate = {
|
|
|
4777
4932
|
fields: (_a = transformVariablesWith(fieldsSchema, (locator) => `fields.${locatorToField(locator)}`)) !== null && _a !== void 0 ? _a : {
|
|
4778
4933
|
type: 'object',
|
|
4779
4934
|
},
|
|
4780
|
-
credentials:
|
|
4781
|
-
},
|
|
4935
|
+
credentials: credentialsSchema,
|
|
4936
|
+
}),
|
|
4782
4937
|
};
|
|
4783
4938
|
},
|
|
4784
4939
|
getOutputSchema: ({}) => ({
|
|
@@ -9385,6 +9540,7 @@ const PackageCalculatedProperties = z.object({
|
|
|
9385
9540
|
key: z.string(),
|
|
9386
9541
|
name: z.string(),
|
|
9387
9542
|
isCustomized: z.boolean().optional(),
|
|
9543
|
+
isPublic: z.boolean().optional(),
|
|
9388
9544
|
});
|
|
9389
9545
|
const BasePackage = BaseMembraneInterface.merge(PackageEditableProperties).merge(PackageCalculatedProperties);
|
|
9390
9546
|
const WritablePackageVersionData = z.object({
|
|
@@ -9830,6 +9986,7 @@ const FindActionRunLogsResponse = createPaginationResponseSchema(ActionRunLogRec
|
|
|
9830
9986
|
|
|
9831
9987
|
const FindConnectionsQuery = PaginationQuery.merge(SearchQuery).merge(IncludeArchivedQuery).extend({
|
|
9832
9988
|
connectorId: z.string().optional(),
|
|
9989
|
+
connectorVersion: z.string().optional(),
|
|
9833
9990
|
id: z.string().optional(),
|
|
9834
9991
|
userId: z.string().optional(),
|
|
9835
9992
|
name: z.string().optional(),
|
|
@@ -9879,8 +10036,15 @@ const ConnectionMessagePayload = z.discriminatedUnion('type', [
|
|
|
9879
10036
|
type: z.literal('newConnectionFailure'),
|
|
9880
10037
|
error: z.string(),
|
|
9881
10038
|
errorData: ErrorDataSchema.optional(),
|
|
10039
|
+
connectionId: z.string().optional(),
|
|
9882
10040
|
}),
|
|
9883
10041
|
]);
|
|
10042
|
+
const GenerateOptionsRequest = z.object({
|
|
10043
|
+
integrationId: z.string().optional(),
|
|
10044
|
+
connectorId: z.string().optional(),
|
|
10045
|
+
connectorParameters: z.any().optional(),
|
|
10046
|
+
connectorVersion: z.string().optional(),
|
|
10047
|
+
});
|
|
9884
10048
|
|
|
9885
10049
|
const ListPublicConnectorsQuery = PaginationQuery.extend({
|
|
9886
10050
|
search: z.string().optional(),
|
|
@@ -10073,12 +10237,16 @@ const IntegrationAuthOption = z.object({
|
|
|
10073
10237
|
type: z.enum(CONNECTOR_AUTH_TYPES),
|
|
10074
10238
|
title: z.string().optional(),
|
|
10075
10239
|
description: z.string().optional(),
|
|
10076
|
-
|
|
10240
|
+
inputSchema: DataSchema.optional(),
|
|
10241
|
+
ui: IntegrationAuthUi.optional().describe('[INTERNAL] Deprecated: Use inputSchema instead'),
|
|
10077
10242
|
});
|
|
10078
10243
|
const IntegrationApiResponse = BaseIntegration.extend({
|
|
10079
10244
|
connection: BaseConnection.optional(),
|
|
10080
10245
|
spec: z.any().optional(),
|
|
10081
|
-
authOptions: z
|
|
10246
|
+
authOptions: z
|
|
10247
|
+
.array(IntegrationAuthOption)
|
|
10248
|
+
.optional()
|
|
10249
|
+
.describe('[INTERNAL] Deprecated: Use POST /connectors/:id/generate-options instead'),
|
|
10082
10250
|
parametersSchema: DataSchema.optional(),
|
|
10083
10251
|
});
|
|
10084
10252
|
|
|
@@ -10419,6 +10587,107 @@ function hasCycles(nodes) {
|
|
|
10419
10587
|
return hasCycles;
|
|
10420
10588
|
}
|
|
10421
10589
|
|
|
10590
|
+
function addUndefinedWriteableProperties(value, schema) {
|
|
10591
|
+
if (!(schema instanceof z.ZodObject)) {
|
|
10592
|
+
return value;
|
|
10593
|
+
}
|
|
10594
|
+
const allProperties = Object.keys(schema.shape);
|
|
10595
|
+
for (const key of allProperties) {
|
|
10596
|
+
if (!(key in value)) {
|
|
10597
|
+
value[key] = undefined;
|
|
10598
|
+
}
|
|
10599
|
+
}
|
|
10600
|
+
return value;
|
|
10601
|
+
}
|
|
10602
|
+
function lenientParseWithSchema(data, schema) {
|
|
10603
|
+
if (data === undefined || data === null) {
|
|
10604
|
+
return data;
|
|
10605
|
+
}
|
|
10606
|
+
const def = schema._def;
|
|
10607
|
+
if (!def) {
|
|
10608
|
+
return data;
|
|
10609
|
+
}
|
|
10610
|
+
const typeName = def.typeName || def.type;
|
|
10611
|
+
if (typeName === 'ZodOptional' || typeName === 'optional') {
|
|
10612
|
+
if (data === undefined)
|
|
10613
|
+
return undefined;
|
|
10614
|
+
return lenientParseWithSchema(data, def.innerType);
|
|
10615
|
+
}
|
|
10616
|
+
if (typeName === 'ZodNullable' || typeName === 'nullable') {
|
|
10617
|
+
if (data === null)
|
|
10618
|
+
return null;
|
|
10619
|
+
return lenientParseWithSchema(data, def.innerType);
|
|
10620
|
+
}
|
|
10621
|
+
if (typeName === 'ZodObject' || typeName === 'object') {
|
|
10622
|
+
if (typeof data !== 'object' || Array.isArray(data)) {
|
|
10623
|
+
return data;
|
|
10624
|
+
}
|
|
10625
|
+
const shape = schema.shape;
|
|
10626
|
+
const result = {};
|
|
10627
|
+
if (shape) {
|
|
10628
|
+
for (const key in shape) {
|
|
10629
|
+
if (key in data) {
|
|
10630
|
+
result[key] = lenientParseWithSchema(data[key], shape[key]);
|
|
10631
|
+
}
|
|
10632
|
+
}
|
|
10633
|
+
}
|
|
10634
|
+
const catchall = def.catchall;
|
|
10635
|
+
if (catchall) {
|
|
10636
|
+
const catchallDef = catchall._def;
|
|
10637
|
+
if ((catchallDef === null || catchallDef === void 0 ? void 0 : catchallDef.typeName) === 'ZodNever' || (catchallDef === null || catchallDef === void 0 ? void 0 : catchallDef.type) === 'never') ;
|
|
10638
|
+
else if ((catchallDef === null || catchallDef === void 0 ? void 0 : catchallDef.typeName) === 'ZodAny' || (catchallDef === null || catchallDef === void 0 ? void 0 : catchallDef.type) === 'unknown' || (catchallDef === null || catchallDef === void 0 ? void 0 : catchallDef.type) === 'any') {
|
|
10639
|
+
for (const key in data) {
|
|
10640
|
+
if (!(key in result)) {
|
|
10641
|
+
result[key] = data[key];
|
|
10642
|
+
}
|
|
10643
|
+
}
|
|
10644
|
+
}
|
|
10645
|
+
else {
|
|
10646
|
+
for (const key in data) {
|
|
10647
|
+
if (shape && !(key in shape)) {
|
|
10648
|
+
result[key] = data[key];
|
|
10649
|
+
}
|
|
10650
|
+
}
|
|
10651
|
+
}
|
|
10652
|
+
}
|
|
10653
|
+
return result;
|
|
10654
|
+
}
|
|
10655
|
+
if (typeName === 'ZodArray' || typeName === 'array') {
|
|
10656
|
+
if (!Array.isArray(data)) {
|
|
10657
|
+
return data;
|
|
10658
|
+
}
|
|
10659
|
+
const elementSchema = def.element || def.type;
|
|
10660
|
+
if (!elementSchema) {
|
|
10661
|
+
return data;
|
|
10662
|
+
}
|
|
10663
|
+
return data.map((item) => lenientParseWithSchema(item, elementSchema));
|
|
10664
|
+
}
|
|
10665
|
+
if (typeName === 'ZodRecord' || typeName === 'record') {
|
|
10666
|
+
if (typeof data !== 'object' || data === null || Array.isArray(data)) {
|
|
10667
|
+
return data;
|
|
10668
|
+
}
|
|
10669
|
+
const valueSchema = def.valueType;
|
|
10670
|
+
if (!valueSchema) {
|
|
10671
|
+
return data;
|
|
10672
|
+
}
|
|
10673
|
+
const result = {};
|
|
10674
|
+
for (const key in data) {
|
|
10675
|
+
result[key] = lenientParseWithSchema(data[key], valueSchema);
|
|
10676
|
+
}
|
|
10677
|
+
return result;
|
|
10678
|
+
}
|
|
10679
|
+
return data;
|
|
10680
|
+
}
|
|
10681
|
+
|
|
10682
|
+
function setEditablePropertiesForWorkspaceElement(currentElement, newEditableFields, exportSchema) {
|
|
10683
|
+
const parsedNewFields = lenientParseWithSchema(newEditableFields, exportSchema);
|
|
10684
|
+
const normalizedFields = addUndefinedWriteableProperties(parsedNewFields, exportSchema);
|
|
10685
|
+
return {
|
|
10686
|
+
...currentElement,
|
|
10687
|
+
...normalizedFields,
|
|
10688
|
+
};
|
|
10689
|
+
}
|
|
10690
|
+
|
|
10422
10691
|
const WorkspaceElementSpecs = {
|
|
10423
10692
|
[WorkspaceElementType.Customer]: {
|
|
10424
10693
|
type: WorkspaceElementType.Customer,
|
|
@@ -10445,6 +10714,7 @@ const WorkspaceElementSpecs = {
|
|
|
10445
10714
|
apiPath: 'connectors',
|
|
10446
10715
|
name: 'Connector',
|
|
10447
10716
|
namePlural: 'Connectors',
|
|
10717
|
+
exportPropertiesSchema: ConnectorExportProperties,
|
|
10448
10718
|
},
|
|
10449
10719
|
[WorkspaceElementType.Connection]: {
|
|
10450
10720
|
type: WorkspaceElementType.Connection,
|
|
@@ -10745,6 +11015,26 @@ async function streamToString(stream) {
|
|
|
10745
11015
|
});
|
|
10746
11016
|
});
|
|
10747
11017
|
}
|
|
11018
|
+
function isBlob(value) {
|
|
11019
|
+
var _a;
|
|
11020
|
+
if (value === null || typeof value !== 'object') {
|
|
11021
|
+
return false;
|
|
11022
|
+
}
|
|
11023
|
+
if (typeof Blob !== 'undefined' && value instanceof Blob) {
|
|
11024
|
+
return true;
|
|
11025
|
+
}
|
|
11026
|
+
const obj = value;
|
|
11027
|
+
const hasRequiredProps = typeof obj.size === 'number' && typeof obj.type === 'string' && typeof obj.slice === 'function';
|
|
11028
|
+
if (!hasRequiredProps) {
|
|
11029
|
+
return false;
|
|
11030
|
+
}
|
|
11031
|
+
const hasBlobMethod = typeof obj.stream === 'function' || typeof obj.text === 'function' || typeof obj.arrayBuffer === 'function';
|
|
11032
|
+
if (hasBlobMethod) {
|
|
11033
|
+
return true;
|
|
11034
|
+
}
|
|
11035
|
+
const constructorName = (_a = obj.constructor) === null || _a === void 0 ? void 0 : _a.name;
|
|
11036
|
+
return constructorName === 'Blob' || constructorName === 'File';
|
|
11037
|
+
}
|
|
10748
11038
|
function truncateData(data, depth = 0) {
|
|
10749
11039
|
const maxArrayItems = 500;
|
|
10750
11040
|
const maxObjectKeys = 500;
|
|
@@ -10768,6 +11058,9 @@ function truncateData(data, depth = 0) {
|
|
|
10768
11058
|
else if (Buffer.isBuffer(data)) {
|
|
10769
11059
|
return data.toString('utf-8').slice(0, maxStringLength);
|
|
10770
11060
|
}
|
|
11061
|
+
else if (isBlob(data)) {
|
|
11062
|
+
return `<Blob: size=${data.size}, type=${data.type}>`;
|
|
11063
|
+
}
|
|
10771
11064
|
else if (typeof data === 'object') {
|
|
10772
11065
|
const keys = Object.keys(data);
|
|
10773
11066
|
const result = {};
|
|
@@ -11001,6 +11294,7 @@ var UsageType;
|
|
|
11001
11294
|
UsageType["EXTERNAL_EVENTS_PULL_DURATION"] = "external-events-pull-duration";
|
|
11002
11295
|
UsageType["EXTERNAL_EVENT_PULL_NUMBER"] = "external-event-pull-number";
|
|
11003
11296
|
UsageType["EXTERNAL_EVENT_PULL_LOG_SIZE"] = "external-event-pull-log-size";
|
|
11297
|
+
UsageType["EXTERNAL_EVENT_WEBHOOK_REFRESH_DURATION"] = "external-event-webhook-refresh-duration";
|
|
11004
11298
|
UsageType["APP_EVENTS_NUMBER"] = "app-events-number";
|
|
11005
11299
|
UsageType["APP_EVENTS_SIZE"] = "app-events-size";
|
|
11006
11300
|
UsageType["FILES_UPLOAD_NUMBER"] = "files-upload-number";
|
|
@@ -11115,6 +11409,144 @@ function getFlowRunVariableSchema() {
|
|
|
11115
11409
|
};
|
|
11116
11410
|
}
|
|
11117
11411
|
|
|
11412
|
+
var AlertStatus;
|
|
11413
|
+
(function (AlertStatus) {
|
|
11414
|
+
AlertStatus["ONGOING"] = "ongoing";
|
|
11415
|
+
AlertStatus["RESOLVED"] = "resolved";
|
|
11416
|
+
})(AlertStatus || (AlertStatus = {}));
|
|
11417
|
+
var AlertSeverity;
|
|
11418
|
+
(function (AlertSeverity) {
|
|
11419
|
+
AlertSeverity["CRITICAL"] = "critical";
|
|
11420
|
+
AlertSeverity["WARNING"] = "warning";
|
|
11421
|
+
})(AlertSeverity || (AlertSeverity = {}));
|
|
11422
|
+
var AlertType;
|
|
11423
|
+
(function (AlertType) {
|
|
11424
|
+
AlertType["fileUploadsMbPerHour"] = "fileUploadsMbPerHour";
|
|
11425
|
+
AlertType["apiRequestsPerSecond"] = "apiRequestsPerSecond";
|
|
11426
|
+
AlertType["apiRequestsPerHour"] = "apiRequestsPerHour";
|
|
11427
|
+
AlertType["webhookRequestsPerSecond"] = "webhookRequestsPerSecond";
|
|
11428
|
+
AlertType["webhookRequestsPerHour"] = "webhookRequestsPerHour";
|
|
11429
|
+
AlertType["workspaceElementCreationsPerSecond"] = "workspaceElementCreationsPerSecond";
|
|
11430
|
+
AlertType["workspaceElementCreationsPerHour"] = "workspaceElementCreationsPerHour";
|
|
11431
|
+
AlertType["externalEventsPerCustomerPerDay"] = "externalEventsPerCustomerPerDay";
|
|
11432
|
+
AlertType["totalUsagePerDay"] = "totalUsagePerDay";
|
|
11433
|
+
AlertType["totalUsagePer30Days"] = "totalUsagePer30Days";
|
|
11434
|
+
AlertType["testAlert"] = "testAlert";
|
|
11435
|
+
})(AlertType || (AlertType = {}));
|
|
11436
|
+
var AlertCategory;
|
|
11437
|
+
(function (AlertCategory) {
|
|
11438
|
+
AlertCategory["RATE_LIMIT"] = "rateLimit";
|
|
11439
|
+
AlertCategory["USAGE"] = "usage";
|
|
11440
|
+
AlertCategory["TEST"] = "test";
|
|
11441
|
+
})(AlertCategory || (AlertCategory = {}));
|
|
11442
|
+
const ALERT_TYPE_CATEGORIES = {
|
|
11443
|
+
[AlertType.fileUploadsMbPerHour]: AlertCategory.RATE_LIMIT,
|
|
11444
|
+
[AlertType.apiRequestsPerSecond]: AlertCategory.RATE_LIMIT,
|
|
11445
|
+
[AlertType.apiRequestsPerHour]: AlertCategory.RATE_LIMIT,
|
|
11446
|
+
[AlertType.webhookRequestsPerSecond]: AlertCategory.RATE_LIMIT,
|
|
11447
|
+
[AlertType.webhookRequestsPerHour]: AlertCategory.RATE_LIMIT,
|
|
11448
|
+
[AlertType.workspaceElementCreationsPerSecond]: AlertCategory.RATE_LIMIT,
|
|
11449
|
+
[AlertType.workspaceElementCreationsPerHour]: AlertCategory.RATE_LIMIT,
|
|
11450
|
+
[AlertType.externalEventsPerCustomerPerDay]: AlertCategory.RATE_LIMIT,
|
|
11451
|
+
[AlertType.totalUsagePerDay]: AlertCategory.USAGE,
|
|
11452
|
+
[AlertType.totalUsagePer30Days]: AlertCategory.USAGE,
|
|
11453
|
+
[AlertType.testAlert]: AlertCategory.TEST,
|
|
11454
|
+
};
|
|
11455
|
+
const AlertSchema = z.object({
|
|
11456
|
+
id: z.string(),
|
|
11457
|
+
description: z.string(),
|
|
11458
|
+
status: z.enum(Object.values(AlertStatus)),
|
|
11459
|
+
type: z.enum(Object.values(AlertType)),
|
|
11460
|
+
workspaceId: z.string(),
|
|
11461
|
+
createdAt: z.date(),
|
|
11462
|
+
updatedAt: z.date(),
|
|
11463
|
+
lastSeenAt: z.date(),
|
|
11464
|
+
resolvedAt: z.date().optional(),
|
|
11465
|
+
customerId: z.string().optional(),
|
|
11466
|
+
severity: z.enum(Object.values(AlertSeverity)),
|
|
11467
|
+
});
|
|
11468
|
+
const ALERT_DELIVERY_METHODS = ['internal', 'webhook', 'email'];
|
|
11469
|
+
const AlertTypeDeliverySettingsSchema = z.object({
|
|
11470
|
+
internal: z.literal(true),
|
|
11471
|
+
webhook: z
|
|
11472
|
+
.object({
|
|
11473
|
+
enabled: z.boolean(),
|
|
11474
|
+
})
|
|
11475
|
+
.optional(),
|
|
11476
|
+
email: z
|
|
11477
|
+
.object({
|
|
11478
|
+
enabled: z.boolean(),
|
|
11479
|
+
})
|
|
11480
|
+
.optional(),
|
|
11481
|
+
});
|
|
11482
|
+
const DEFAULT_ALERT_TYPE_DELIVERY_SETTINGS = {
|
|
11483
|
+
internal: true,
|
|
11484
|
+
webhook: {
|
|
11485
|
+
enabled: false,
|
|
11486
|
+
},
|
|
11487
|
+
email: {
|
|
11488
|
+
enabled: false,
|
|
11489
|
+
},
|
|
11490
|
+
};
|
|
11491
|
+
const AlertDeliverySettingsSchema = z.object({
|
|
11492
|
+
alertTypes: z.record(z.enum(Object.values(AlertType)), AlertTypeDeliverySettingsSchema.optional()).optional(),
|
|
11493
|
+
});
|
|
11494
|
+
const DEFAULT_ALERT_DELIVERY_SETTINGS = {
|
|
11495
|
+
alertTypes: undefined,
|
|
11496
|
+
};
|
|
11497
|
+
|
|
11498
|
+
function isValidAlertType(value) {
|
|
11499
|
+
return Object.values(AlertType).includes(value);
|
|
11500
|
+
}
|
|
11501
|
+
function getAlertTypeDisplayName(alertType) {
|
|
11502
|
+
const names = {
|
|
11503
|
+
[AlertType.fileUploadsMbPerHour]: 'File Uploads MB Per Hour',
|
|
11504
|
+
[AlertType.apiRequestsPerSecond]: 'API Requests Per Second',
|
|
11505
|
+
[AlertType.apiRequestsPerHour]: 'API Requests Per Hour',
|
|
11506
|
+
[AlertType.webhookRequestsPerSecond]: 'Webhook Requests Per Second',
|
|
11507
|
+
[AlertType.webhookRequestsPerHour]: 'Webhook Requests Per Hour',
|
|
11508
|
+
[AlertType.workspaceElementCreationsPerSecond]: 'Workspace Element Creations Per Second',
|
|
11509
|
+
[AlertType.workspaceElementCreationsPerHour]: 'Workspace Element Creations Per Hour',
|
|
11510
|
+
[AlertType.externalEventsPerCustomerPerDay]: 'External Events Per Customer Per Day',
|
|
11511
|
+
[AlertType.totalUsagePerDay]: 'Total Usage Per Day',
|
|
11512
|
+
[AlertType.totalUsagePer30Days]: 'Total Usage Per 30 Days',
|
|
11513
|
+
[AlertType.testAlert]: 'Test Alert',
|
|
11514
|
+
};
|
|
11515
|
+
return names[alertType] || alertType;
|
|
11516
|
+
}
|
|
11517
|
+
function getAlertDeliveryMethodLabel(method) {
|
|
11518
|
+
const labels = {
|
|
11519
|
+
internal: 'Internal Delivery',
|
|
11520
|
+
webhook: 'Webhook Delivery',
|
|
11521
|
+
email: 'Email Delivery',
|
|
11522
|
+
};
|
|
11523
|
+
return labels[method] || method;
|
|
11524
|
+
}
|
|
11525
|
+
function isDeliveryMethodEnabled(settings, method) {
|
|
11526
|
+
var _a;
|
|
11527
|
+
if (method === 'internal') {
|
|
11528
|
+
return true;
|
|
11529
|
+
}
|
|
11530
|
+
if (((_a = settings[method]) !== null && _a !== void 0 ? _a : DEFAULT_ALERT_TYPE_DELIVERY_SETTINGS[method]).enabled) {
|
|
11531
|
+
return true;
|
|
11532
|
+
}
|
|
11533
|
+
return false;
|
|
11534
|
+
}
|
|
11535
|
+
function getAlertCategoryDisplayName(category) {
|
|
11536
|
+
const names = {
|
|
11537
|
+
[AlertCategory.RATE_LIMIT]: 'Rate Limit Alerts',
|
|
11538
|
+
[AlertCategory.USAGE]: 'Usage Alerts',
|
|
11539
|
+
[AlertCategory.TEST]: 'Test',
|
|
11540
|
+
};
|
|
11541
|
+
return names[category] || category;
|
|
11542
|
+
}
|
|
11543
|
+
function getAlertTypesByCategory(category) {
|
|
11544
|
+
return Object.entries(ALERT_TYPE_CATEGORIES)
|
|
11545
|
+
.filter(([, alertCategory]) => alertCategory === category)
|
|
11546
|
+
.map(([alertType]) => alertType)
|
|
11547
|
+
.filter(isValidAlertType);
|
|
11548
|
+
}
|
|
11549
|
+
|
|
11118
11550
|
var WorkspaceType;
|
|
11119
11551
|
(function (WorkspaceType) {
|
|
11120
11552
|
WorkspaceType["PRODUCTION"] = "production";
|
|
@@ -11169,6 +11601,7 @@ const WorkspaceLimitsSchema = z$1.object({
|
|
|
11169
11601
|
totalNumberOfConnections: WorkspaceLimit.optional(),
|
|
11170
11602
|
totalNumberOfWorkspaceElements: WorkspaceLimit.optional(),
|
|
11171
11603
|
instantTasksQueueSize: WorkspaceLimit.optional(),
|
|
11604
|
+
QueuedTasksQueueSize: WorkspaceLimit.optional(),
|
|
11172
11605
|
parallelApiRequestsPerCustomer: WorkspaceLimit.optional(),
|
|
11173
11606
|
parallelBackgroundJobsPerCustomer: WorkspaceLimit.optional(),
|
|
11174
11607
|
apiRequestsPerCustomerPerSecond: WorkspaceLimit.optional(),
|
|
@@ -11185,6 +11618,7 @@ const EngineWorkspaceSettingsSchema = z$1.object({
|
|
|
11185
11618
|
enableWebhookLogs: z$1.boolean().optional(),
|
|
11186
11619
|
enableActionRunLogs: z$1.boolean().optional(),
|
|
11187
11620
|
disableSecretKeyAuth: z$1.boolean().optional(),
|
|
11621
|
+
useMembraneUniverse: z$1.boolean().optional(),
|
|
11188
11622
|
});
|
|
11189
11623
|
const WorkspacePublicKey = z$1.object({
|
|
11190
11624
|
name: z$1.string(),
|
|
@@ -11211,6 +11645,7 @@ const AppSchema = z$1.object({
|
|
|
11211
11645
|
featureFlags: z$1.array(z$1.string()).optional(),
|
|
11212
11646
|
limits: WorkspaceLimitsSchema.optional(),
|
|
11213
11647
|
settings: EngineWorkspaceSettingsSchema.optional(),
|
|
11648
|
+
alertDeliverySettings: AlertDeliverySettingsSchema.optional(),
|
|
11214
11649
|
type: z$1.nativeEnum(WorkspaceType).optional(),
|
|
11215
11650
|
jwksUri: z$1.string().nullable().optional(),
|
|
11216
11651
|
isTrial: z$1.boolean().optional(),
|
|
@@ -11388,13 +11823,14 @@ function buildIntegrationsMap(integrations) {
|
|
|
11388
11823
|
return map;
|
|
11389
11824
|
}
|
|
11390
11825
|
|
|
11826
|
+
const IneligibilityReasonSchema = z.enum(['disposable', 'blockedDomain', 'notCompanyEmail']);
|
|
11391
11827
|
const PlatformUserSchema = z.object({
|
|
11392
11828
|
id: z.string(),
|
|
11393
11829
|
email: z.string(),
|
|
11394
11830
|
name: z.string(),
|
|
11395
11831
|
trialRequested: z.boolean(),
|
|
11396
|
-
introVideoStatus: z.string().optional(),
|
|
11397
11832
|
isEligible: z.boolean().optional(),
|
|
11833
|
+
ineligibilityReason: IneligibilityReasonSchema.optional(),
|
|
11398
11834
|
emailVerified: z.boolean().optional(),
|
|
11399
11835
|
});
|
|
11400
11836
|
const FullPlatformUser = z.object({
|
|
@@ -11407,8 +11843,8 @@ const FullPlatformUser = z.object({
|
|
|
11407
11843
|
isAdmin: z.boolean().optional(),
|
|
11408
11844
|
trialRequested: z.boolean(),
|
|
11409
11845
|
pat: z.string().optional(),
|
|
11410
|
-
introVideoStatus: z.string().optional(),
|
|
11411
11846
|
isEligible: z.boolean().optional(),
|
|
11847
|
+
ineligibilityReason: IneligibilityReasonSchema.optional(),
|
|
11412
11848
|
emailVerified: z.boolean().optional(),
|
|
11413
11849
|
});
|
|
11414
11850
|
|
|
@@ -11419,6 +11855,12 @@ var OrgLimitsType;
|
|
|
11419
11855
|
OrgLimitsType["LAST_THIRTY_DAY_USAGE"] = "lastThirtyDayUsage";
|
|
11420
11856
|
OrgLimitsType["MEMBRANE_EXPERT_CREDITS_CAP"] = "membraneExpertCreditsCapPerMonth";
|
|
11421
11857
|
})(OrgLimitsType || (OrgLimitsType = {}));
|
|
11858
|
+
var OrgPlan;
|
|
11859
|
+
(function (OrgPlan) {
|
|
11860
|
+
OrgPlan["Core"] = "core";
|
|
11861
|
+
OrgPlan["Pro"] = "pro";
|
|
11862
|
+
OrgPlan["Ultimate"] = "ultimate";
|
|
11863
|
+
})(OrgPlan || (OrgPlan = {}));
|
|
11422
11864
|
var OrgUserRole;
|
|
11423
11865
|
(function (OrgUserRole) {
|
|
11424
11866
|
OrgUserRole["Admin"] = "admin";
|
|
@@ -11448,6 +11890,7 @@ const OrgSchema = z.object({
|
|
|
11448
11890
|
id: z.string(),
|
|
11449
11891
|
key: z.string(),
|
|
11450
11892
|
name: z.string(),
|
|
11893
|
+
plan: z.enum(OrgPlan).optional(),
|
|
11451
11894
|
createdAt: z.coerce.date(),
|
|
11452
11895
|
updatedAt: z.coerce.date(),
|
|
11453
11896
|
trialEndDate: z.string().optional(),
|
|
@@ -11466,6 +11909,13 @@ const OrgSchema = z.object({
|
|
|
11466
11909
|
autoChargeThreshold: z.number().optional(),
|
|
11467
11910
|
autoChargePurchaseAmount: z.number().optional(),
|
|
11468
11911
|
autoChargeMonthlyLimit: z.number().optional(),
|
|
11912
|
+
freeInfraCredits: z.number().optional(),
|
|
11913
|
+
paidInfraCredits: z.number().optional(),
|
|
11914
|
+
freeInfraMonthlyCredits: z.number().nullable().optional(),
|
|
11915
|
+
infraAutoChargeEnabled: z.boolean().optional(),
|
|
11916
|
+
infraAutoChargeThreshold: z.number().optional(),
|
|
11917
|
+
infraAutoChargePurchaseAmount: z.number().optional(),
|
|
11918
|
+
infraAutoChargeMonthlyLimit: z.number().optional(),
|
|
11469
11919
|
});
|
|
11470
11920
|
const AccountResponse = z.object({
|
|
11471
11921
|
user: FullPlatformUser.optional(),
|
|
@@ -11493,27 +11943,10 @@ var WebhookTypeEnum;
|
|
|
11493
11943
|
WebhookTypeEnum["TASK_UPDATED"] = "task-updated";
|
|
11494
11944
|
WebhookTypeEnum["TASK_ACTIVITY_CREATED"] = "task-activity-created";
|
|
11495
11945
|
WebhookTypeEnum["CONNECTOR_VERSION_PUBLISHED"] = "connector-version-published";
|
|
11946
|
+
WebhookTypeEnum["AGENT_SESSION_FINISHED"] = "agent-session-finished";
|
|
11947
|
+
WebhookTypeEnum["SEND_ALERT_EMAIL"] = "send-alert-email";
|
|
11496
11948
|
})(WebhookTypeEnum || (WebhookTypeEnum = {}));
|
|
11497
11949
|
|
|
11498
|
-
var AlertStatus;
|
|
11499
|
-
(function (AlertStatus) {
|
|
11500
|
-
AlertStatus["ONGOING"] = "ongoing";
|
|
11501
|
-
AlertStatus["RESOLVED"] = "resolved";
|
|
11502
|
-
})(AlertStatus || (AlertStatus = {}));
|
|
11503
|
-
var AlertSeverity;
|
|
11504
|
-
(function (AlertSeverity) {
|
|
11505
|
-
AlertSeverity["CRITICAL"] = "critical";
|
|
11506
|
-
AlertSeverity["WARNING"] = "warning";
|
|
11507
|
-
})(AlertSeverity || (AlertSeverity = {}));
|
|
11508
|
-
var AlertType;
|
|
11509
|
-
(function (AlertType) {
|
|
11510
|
-
AlertType["externalEventsPerCustomerPerDay"] = "externalEventsPerCustomerPerDay";
|
|
11511
|
-
AlertType["totalUsagePerDay"] = "totalUsagePerDay";
|
|
11512
|
-
AlertType["totalUsagePer30Days"] = "totalUsagePer30Days";
|
|
11513
|
-
AlertType["membraneAgentUsagePer30Days"] = "membraneAgentUsagePer30Days";
|
|
11514
|
-
AlertType["testAlert"] = "testAlert";
|
|
11515
|
-
})(AlertType || (AlertType = {}));
|
|
11516
|
-
|
|
11517
11950
|
const IntegrationSpecificElementSelector = z$1.object({
|
|
11518
11951
|
id: z$1.string().optional(),
|
|
11519
11952
|
key: z$1.string().optional(),
|
|
@@ -12500,7 +12933,7 @@ class ConnectionAccessor {
|
|
|
12500
12933
|
dataCollection(key, parameters) {
|
|
12501
12934
|
return new ConnectionDataCollectionAccessor(this.client, this, key, parameters);
|
|
12502
12935
|
}
|
|
12503
|
-
async reconnect({ parameters, authOptionKey, connectorParameters, } = {}) {
|
|
12936
|
+
async reconnect({ parameters, authOptionKey, connectorParameters, onPopupClosed, } = {}) {
|
|
12504
12937
|
const connection = await this.get();
|
|
12505
12938
|
const connectorSpec = await this.client.get(`/integrations/${connection.integrationId}/connector-spec`);
|
|
12506
12939
|
return createOrUpdateConnection({
|
|
@@ -12511,6 +12944,7 @@ class ConnectionAccessor {
|
|
|
12511
12944
|
connectorParameters,
|
|
12512
12945
|
apiUri: this.client.apiUri,
|
|
12513
12946
|
token: await this.client.getToken(),
|
|
12947
|
+
onPopupClosed,
|
|
12514
12948
|
});
|
|
12515
12949
|
}
|
|
12516
12950
|
async openReconnectUI({} = {}) {
|
|
@@ -12599,21 +13033,31 @@ class ConnectionProxy {
|
|
|
12599
13033
|
}
|
|
12600
13034
|
}
|
|
12601
13035
|
async function createOrUpdateConnection(options) {
|
|
12602
|
-
const { connectionId, integrationId, name, parameters, connectorParameters, allowMultipleConnections, authOptionKey, connectorSpec, apiUri, token, redirectUri, } = options !== null && options !== void 0 ? options : {};
|
|
13036
|
+
const { connectionId, integrationId, connectorId, connectorVersion, name, parameters, connectorParameters, allowMultipleConnections, authOptionKey, connectorSpec, apiUri, token, redirectUri, onPopupClosed, } = options !== null && options !== void 0 ? options : {};
|
|
12603
13037
|
const connectionType = getConnectionType({
|
|
12604
13038
|
connectorSpec,
|
|
12605
13039
|
authOptionKey,
|
|
12606
13040
|
redirectUri,
|
|
12607
13041
|
});
|
|
12608
|
-
|
|
12609
|
-
|
|
12610
|
-
|
|
13042
|
+
let popupPath;
|
|
13043
|
+
if (connectionId) {
|
|
13044
|
+
popupPath = `connection-popup?connectionId=${connectionId}`;
|
|
13045
|
+
}
|
|
13046
|
+
else if (connectorId) {
|
|
13047
|
+
const versionParam = connectorVersion ? `&connectorVersion=${connectorVersion}` : '';
|
|
13048
|
+
popupPath = `connection-popup?connectorId=${connectorId}${versionParam}`;
|
|
13049
|
+
}
|
|
13050
|
+
else {
|
|
13051
|
+
popupPath = `connection-popup?integrationId=${integrationId}`;
|
|
13052
|
+
}
|
|
12611
13053
|
return new Promise((resolve, reject) => {
|
|
12612
13054
|
const requestId = simpleUniqueId() + simpleUniqueId();
|
|
12613
13055
|
const payload = {
|
|
12614
13056
|
token,
|
|
12615
13057
|
connectionParameters: parameters,
|
|
12616
13058
|
connectorParameters,
|
|
13059
|
+
connectorId,
|
|
13060
|
+
connectorVersion,
|
|
12617
13061
|
name,
|
|
12618
13062
|
authOptionKey,
|
|
12619
13063
|
allowMultipleConnections,
|
|
@@ -12659,10 +13103,10 @@ async function createOrUpdateConnection(options) {
|
|
|
12659
13103
|
iframeElement.id = targetElementId;
|
|
12660
13104
|
iframeElement.name = targetElementId;
|
|
12661
13105
|
iframeElement.style.position = 'absolute';
|
|
12662
|
-
iframeElement.style.top = '-
|
|
12663
|
-
iframeElement.style.left = '-
|
|
12664
|
-
iframeElement.style.width = '
|
|
12665
|
-
iframeElement.style.height = '
|
|
13106
|
+
iframeElement.style.top = '-100px';
|
|
13107
|
+
iframeElement.style.left = '-100px';
|
|
13108
|
+
iframeElement.style.width = '1px';
|
|
13109
|
+
iframeElement.style.height = '1px';
|
|
12666
13110
|
iframeElement.style.border = 'none';
|
|
12667
13111
|
iframeElement.style.backgroundColor = 'transparent';
|
|
12668
13112
|
document.body.appendChild(iframeElement);
|
|
@@ -12696,6 +13140,7 @@ async function createOrUpdateConnection(options) {
|
|
|
12696
13140
|
cancelCheckInterval = setInterval(() => {
|
|
12697
13141
|
if (popup === null || popup === void 0 ? void 0 : popup.closed) {
|
|
12698
13142
|
cleanup();
|
|
13143
|
+
onPopupClosed === null || onPopupClosed === void 0 ? void 0 : onPopupClosed();
|
|
12699
13144
|
resolve(null);
|
|
12700
13145
|
}
|
|
12701
13146
|
}, 1000);
|
|
@@ -12727,6 +13172,9 @@ const createConnectionEventHandler = (requestId, onResolve, onReject, onFinally)
|
|
|
12727
13172
|
}
|
|
12728
13173
|
if (message.type == 'newConnectionFailure') {
|
|
12729
13174
|
const error = new MembraneError((_a = message.errorData) !== null && _a !== void 0 ? _a : message.error);
|
|
13175
|
+
if (message.connectionId) {
|
|
13176
|
+
error.data.data = { ...error.data.data, connectionId: message.connectionId };
|
|
13177
|
+
}
|
|
12730
13178
|
onReject(error);
|
|
12731
13179
|
}
|
|
12732
13180
|
onFinally();
|
|
@@ -12906,7 +13354,7 @@ class IntegrationAccessor extends ElementAccessor {
|
|
|
12906
13354
|
});
|
|
12907
13355
|
});
|
|
12908
13356
|
}
|
|
12909
|
-
async connect({ name, parameters, connectorParameters, authOptionKey, allowMultipleConnections, redirectUri, sameWindow, } = {}) {
|
|
13357
|
+
async connect({ name, parameters, connectorParameters, authOptionKey, allowMultipleConnections, redirectUri, sameWindow, onPopupClosed, } = {}) {
|
|
12910
13358
|
const integration = await this.get();
|
|
12911
13359
|
const connectorSpec = await this.getConnectorSpec();
|
|
12912
13360
|
return createOrUpdateConnection({
|
|
@@ -12920,9 +13368,10 @@ class IntegrationAccessor extends ElementAccessor {
|
|
|
12920
13368
|
apiUri: this.client.apiUri,
|
|
12921
13369
|
token: await this.client.getToken(),
|
|
12922
13370
|
redirectUri: sameWindow ? redirectUri : undefined,
|
|
13371
|
+
onPopupClosed,
|
|
12923
13372
|
});
|
|
12924
13373
|
}
|
|
12925
|
-
async createConnection({ parameters, name }) {
|
|
13374
|
+
async createConnection({ parameters, name, }) {
|
|
12926
13375
|
return this.connect({ parameters, name });
|
|
12927
13376
|
}
|
|
12928
13377
|
async getOperations() {
|
|
@@ -13244,6 +13693,7 @@ var AgentSessionState;
|
|
|
13244
13693
|
})(AgentSessionState || (AgentSessionState = {}));
|
|
13245
13694
|
const AgentSession = z.object({
|
|
13246
13695
|
id: z.string(),
|
|
13696
|
+
workspaceId: z.string(),
|
|
13247
13697
|
userId: z.string().optional(),
|
|
13248
13698
|
workspaceElementType: z.enum(WorkspaceElementType),
|
|
13249
13699
|
workspaceElementId: z.string(),
|
|
@@ -13258,6 +13708,7 @@ const AgentSession = z.object({
|
|
|
13258
13708
|
state: z.enum(AgentSessionState).default(AgentSessionState.BUSY),
|
|
13259
13709
|
usage: z.number().optional(),
|
|
13260
13710
|
hasWorker: z.boolean(),
|
|
13711
|
+
isExternal: z.boolean().optional(),
|
|
13261
13712
|
createdAt: z.iso.datetime(),
|
|
13262
13713
|
updatedAt: z.iso.datetime(),
|
|
13263
13714
|
});
|
|
@@ -13267,6 +13718,7 @@ const CreateAgentSession = z.object({
|
|
|
13267
13718
|
prompt: z.string().min(1),
|
|
13268
13719
|
testCustomerId: z.string().optional(),
|
|
13269
13720
|
isExternal: z.boolean().optional(),
|
|
13721
|
+
modelId: z.string().optional(),
|
|
13270
13722
|
});
|
|
13271
13723
|
const AgentSessionInputSchema = z.object({
|
|
13272
13724
|
input: z.string().min(1),
|
|
@@ -13278,6 +13730,8 @@ const PatchAgentSessionSchema = z.object({
|
|
|
13278
13730
|
title: z.string().optional(),
|
|
13279
13731
|
summary: z.string().optional(),
|
|
13280
13732
|
cost: z.number().optional(),
|
|
13733
|
+
error: ErrorDataSchema.optional(),
|
|
13734
|
+
opencodeSessionUuid: z.string().optional(),
|
|
13281
13735
|
status: z.enum(AgentSessionStatus).optional(),
|
|
13282
13736
|
});
|
|
13283
13737
|
|
|
@@ -13597,6 +14051,7 @@ const membraneConfigSchema = z.object({
|
|
|
13597
14051
|
apiUri: z.string().optional(),
|
|
13598
14052
|
consoleUri: z.string().optional(),
|
|
13599
14053
|
testCustomerId: z.string().optional(),
|
|
14054
|
+
accessToken: z.string().optional(),
|
|
13600
14055
|
});
|
|
13601
14056
|
class MembraneConfigLoader {
|
|
13602
14057
|
constructor(cwd = process.cwd()) {
|
|
@@ -13704,6 +14159,9 @@ class MembraneConfigLoader {
|
|
|
13704
14159
|
throw new Error(`Failed to parse ${CONFIG_FILE_NAME}: ${yamlError.message}`);
|
|
13705
14160
|
}
|
|
13706
14161
|
const config = {};
|
|
14162
|
+
if (parsedConfig === null || parsedConfig === void 0 ? void 0 : parsedConfig.accessToken) {
|
|
14163
|
+
config.accessToken = String(parsedConfig.accessToken);
|
|
14164
|
+
}
|
|
13707
14165
|
if (parsedConfig === null || parsedConfig === void 0 ? void 0 : parsedConfig.workspaceKey) {
|
|
13708
14166
|
config.workspaceKey = String(parsedConfig.workspaceKey);
|
|
13709
14167
|
}
|
|
@@ -13723,6 +14181,9 @@ class MembraneConfigLoader {
|
|
|
13723
14181
|
}
|
|
13724
14182
|
loadFromEnv() {
|
|
13725
14183
|
const config = {};
|
|
14184
|
+
if (process.env.MEMBRANE_ACCESS_TOKEN) {
|
|
14185
|
+
config.accessToken = process.env.MEMBRANE_ACCESS_TOKEN;
|
|
14186
|
+
}
|
|
13726
14187
|
if (process.env.MEMBRANE_WORKSPACE_KEY) {
|
|
13727
14188
|
config.workspaceKey = process.env.MEMBRANE_WORKSPACE_KEY;
|
|
13728
14189
|
}
|
|
@@ -13763,5 +14224,5 @@ function hasMembraneCredentials(cwd) {
|
|
|
13763
14224
|
return getDefaultMembraneConfigLoader().hasWorkspaceCredentials();
|
|
13764
14225
|
}
|
|
13765
14226
|
|
|
13766
|
-
export { ACTIONS, AccessDeniedError, AccountResponse, ActionAccessor, ActionApiResponse, ActionDependency, ActionDependencyType, ActionEditableProperties, ActionExportProperties, ActionInstanceAccessor, ActionInstanceApiResponse, ActionInstanceSetupError, ActionInstancesAccessor, ActionRunError, ActionRunLogRecordApiResponse, ActionRunLogStatus, ActionRunResponse, ActionType, ActionsAccessor, AgentSession, AgentSessionInputSchema, AgentSessionState, AgentSessionStatus, AlertSeverity, AlertStatus, AlertType, ApiRequestSpec, AppDataSchemaAccessor, AppDataSchemaApiResponse, AppDataSchemaEditableProperties, AppDataSchemaExportProperties, AppDataSchemaInstanceAccessor, AppDataSchemaInstanceApiResponse, AppDataSchemaInstancesAccessor, AppDataSchemasAccessor, AppEventLogRecordApiResponse, AppEventSubscriptionAccessor, AppEventSubscriptionApiResponse, AppEventSubscriptionsAccessor, AppEventTypeAccessor, AppEventTypeApiResponse, AppEventTypeEditableProperties, AppEventTypeExportProperties, AppEventTypesAccessor, AppSchema, AppliedToIntegrations, BackwardCompatibleDataSourceEditableProperties, BadRequestError, BadRequestErrorKey, BaseAction, BaseActionInstance, BaseActionRunLogRecord, BaseAppDataSchema, BaseAppDataSchemaInstance, BaseAppEventSubscription, BaseAppEventType, BaseConnection, BaseConnector, BaseCustomer, BaseDataLinkTable, BaseDataLinkTableInstance, BaseDataSource, BaseDataSourceInstance, BaseExternalEvent, BaseExternalEventLogRecord, BaseExternalEventPull, BaseExternalEventSubscription, BaseFieldMapping, BaseFieldMappingInstance, BaseFlow, BaseFlowInstance, BaseFlowRun, BaseFunctionDefinition, BaseIntegration, BaseIntegrationLevelMembraneInterface, BaseIntegrationLevelMembraneInterfaceEditableProperties, BaseIntegrationLevelMembraneInterfaceExportProperties, BaseIntegrationLevelMembraneInterfaceReadOnlyProperties, BaseMembraneInterface, BaseMembraneInterfaceEditableProperties, BaseMembraneInterfaceReadOnlyProperties, BasePackage, BaseScreen, BaseWorkspaceElement, CONFIG_FILE_NAME, 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, CONNECTOR_VERSION_DEVELOPMENT, CONNECTOR_VERSION_LATEST, CommonFindElementsQuery, CommonFindInstancesQuery, CommonInstancesListQuery, CommonIntegrationOrConnectionQuery, CommonListElementsQuery, ConcurrencyError, ConcurrencyErrorKey, ConfigurationError, ConfigurationState, ConnectionAccessor, ConnectionApiResponse, ConnectionApiResponseWithSecrets, ConnectionDataCollectionAccessor, ConnectionError, ConnectionErrorKey, ConnectionLevelActionAccessor, ConnectionLevelActionsAccessor, ConnectionLevelDataSourceAccessor, ConnectionLevelDataSourcesAccessor, ConnectionLevelFieldMappingAccessor, ConnectionLevelFieldMappingsAccessor, ConnectionLevelFlowAccessor, ConnectionLevelFlowsAccessor, ConnectionMessagePayload, ConnectionOperationAccessor, ConnectionProxy, ConnectionRequest, ConnectionSelector, ConnectionSpec, ConnectionsAccessor, Connector, ConnectorAuth, ConnectorAuthClientCredentials, ConnectorAuthHandlerBase, ConnectorAuthIntegrationAppToken, ConnectorAuthMembraneToken, ConnectorAuthMethodTypes, ConnectorAuthOAuth1, ConnectorAuthOAuth2, ConnectorAuthProxy, ConnectorAuthSpec, ConnectorAuthWithFunctions, ConnectorDataCollectionEventImplementationType, ConnectorDataCollectionMethodKeys, ConnectorDataLocationTypes, ConnectorEventHandlerMethods, ConnectorEventImplementationType, ConnectorFileUpdateType, ConnectorMethodImplementation, ConnectorMethodImplementationBase, ConnectorMethodImplementationGraphqlApiMapping, ConnectorMethodImplementationJavascript, ConnectorMethodImplementationMapping, ConnectorMethodImplementationNotSupported, ConnectorMethodImplementationOperationMapping, ConnectorMethodImplementationRestApiMapping, ConnectorMethodImplementationType, ConnectorOperationMethodImplementationTypes, ConnectorOption, ConnectorOptions, ConnectorSpec, ConnectorStatus, ConnectorStatusValues, ConnectorUdmCollectionMapping, ConnectorUdmListItem, ConnectorUdmSpec, ConnectorUiSpec, ConnectorVersion, ConnectorVersionData, CreateActionInstanceRequest, CreateActionRequest, CreateAgentSession, CreateConnectionRequest, CreateConnectorRequest, CreateCustomerRequest, CreateDataLinkTableRequest, CreateDataSourceInstanceRequest, CreateDataSourceRequest, CreateFieldMappingRequest, CreateFlowNodeRequest, CreateFlowRequest, CreateFlowRunRequest, CreateIntegrationRequest, CreatePackageRequest, 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, DataLinkTableEditableProperties, DataLinkTableExportProperties, DataLinkTableInstanceAccessor, DataLinkTableInstanceApiResponse, DataLinkTableInstancesAccessor, DataLinkTablesAccessor, DataLocationMethodImplementationTypes, DataLocationPointer, DataLocationTypeCollection, DataLocatorStep, DataLocatorStepArrayItem, DataLocatorStepObjectProperty, DataLocatorStepType, DataRecordSchema, DataSchema, DataSourceAccessor, DataSourceApiResponse, DataSourceEditableProperties, DataSourceExportProperties, DataSourceInstanceAccessor, DataSourceInstanceApiResponse, DataSourceInstancesAccessor, DataSourceUnitConfig, DataSourcesAccessor, DependencyError, DownstreamFlowNodeRunSchema, EDITABLE_LIMITS, ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor, ElementsExportFields, EngineWorkspaceSettingsSchema, ErrorData, ErrorDataSchema, ErrorType, ExternalEvent, ExternalEventLogRecordApiResponse, ExternalEventLogStatus, ExternalEventPullApiResponse, ExternalEventPullStatus, ExternalEventSubscriptionAccessor, ExternalEventSubscriptionApiResponse, ExternalEventSubscriptionConfig, ExternalEventSubscriptionStatus, ExternalEventSubscriptionType, ExternalEventSubscriptionsAccessor, ExternalEventType, ExternalEventUnitConfig, FLOW_NODE_SPECS, FieldMappingAccessor, FieldMappingApiResponse, FieldMappingDirection, FieldMappingEditableProperties, FieldMappingExportProperties, FieldMappingInstanceAccessor, FieldMappingInstanceApiResponse, FieldMappingInstancesAccessor, FieldMappingUnitConfig, FieldMappingsAccessor, FindActionInstancesQuery, FindActionRunLogsQuery, FindActionRunLogsResponse, FindActionsQuery, FindAppEventSubscriptionsQuery, FindAppEventTypesQuery, FindAppEventsQuery, FindConnectionsQuery, FindConnectionsResponse, FindCustomersQuery, FindDataLinkTableInstanceLinksQuery, FindDataLinkTableInstancesQuery, FindDataLinkTablesQuery, FindDataLinksInTableQuery, FindDataLinksQuery, FindDataLinksResponse, FindDataSourceEventsQuery, FindDataSourceInstanceQuery, FindDataSourceInstanceSyncsQuery, FindDataSourceInstancesQuery, FindDataSourceSyncsQuery, FindDataSourcesQuery, FindExternalEventPullsQuery, FindFieldMappingsQuery, FindFlowInstancesQuery, FindFlowRunsQuery, FindFlowRunsResponse, FindFlowsQuery, FindIntegrationLevelMembraneInterfaceQuery, FindIntegrationsQuery, FindPackagesQuery, FindScreensQuery, FlowAccessor, FlowApiResponse, FlowEditableProperties, FlowExportProperties, 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, FullPlatformUser, FunctionDefinition, FunctionType, GenericFunctionDefinition, GraphQLApiMappingSchema, GraphQLFieldMappingSchema, GraphqlApiMappingFunction, HTTP_REQUEST_SCHEMA, HandyScenarioTemplateElement, HttpRequestMethod, HttpRequestSpec, IncludeArchivedQuery, IncomingWebhooksState, InsufficientCreditsError, IntegrationAccessor, IntegrationApiResponse, MembraneClient as IntegrationAppClient, IntegrationAppError, IntegrationAuthOption, IntegrationAuthUi, IntegrationEditableProperties, IntegrationElementLevel, IntegrationElementType, IntegrationExportProperties, IntegrationLevelActionAccessor, IntegrationLevelActionsListAccessor, IntegrationLevelDataSourceAccessor, IntegrationLevelDataSourcesListAccessor, IntegrationLevelFieldMappingAccessor, IntegrationLevelFieldMappingsListAccessor, IntegrationLevelFlowAccessor, IntegrationLevelFlowsListAccessor, IntegrationLevelMembraneInterfaceSelectorQuery, IntegrationSpecificElementSelector, IntegrationsAccessor, InternalError, InvalidLocatorError, JavascriptFunction, LimitUnits, ListActionInstancesForConnectionQuery, ListDataSourceInstancesForConnectionQuery, ListExternalAppsQuery, ListExternalEventLogRecordsQuery, ListExternalEventPullsQuery, ListExternalEventSubscriptionsQuery, ListFlowInstancesForConnectionQuery, ListPublicConnectorsQuery, ListPublicPackagesQuery, LogRecordType, MEMBRANE_ELEMENT_CONFIG_FILE_NAME, MIN_FULL_SYNC_INTERVAL_SECONDS, MIN_PULL_UPDATES_INTERVAL_SECONDS, MappingFunction, MappingSchema, MembraneAgentKey, axios as MembraneAxiosInstance, MembraneClient, MembraneConfigLoader, MembraneError, MinimalConnector, NotAuthenticatedError, NotFoundError, OAUTH1_CONFIG_SCHEMA, OAUTH_CONFIG_SCHEMA, OpenapiMappingSchema, OperationMappingFunction, OperationMappingSchema, OrgLimits, OrgLimitsType, OrgSchema, OrgUserRole, OrgUserStatus, OrgWorkspaceSchema, OrgWorkspaceUser, PACKAGE_VERSION_DEVELOPMENT, PACKAGE_VERSION_LATEST, PARALLEL_EXECUTION_LIMITS, PackageAccessor, PackageApiResponse, PackageCalculatedProperties, PackageEditableProperties, PackageElement, PackageElementApi, PackageElementExport, PackageExportProperties, PackageVersionData, PackageVersionListItem, PackagesAccessor, PaginationQuery, PaginationResponse, PatchAgentSessionSchema, PlatformUserSchema, RATE_LIMITS, RateLimitExceededError, RequestMappingSchema, ResetFlowInstanceOptions, RestApiMappingFunction, RestApiMappingSchema, RunActionRequest, RunFlowApiRequest, ScenarioAccessor, ScenarioTemplate, ScenarioTemplateCategory, ScenarioTemplateElements, ScenariosAccessor, ScreenAccessor, ScreenApiResponse, ScreenBlock, ScreenBlockType, ScreenType, ScreensAccessor, SearchQuery, SelfAccessor, UDM, UNIFIED_DATA_MODELS, UnitRunError, UpdateActionInstanceRequest, UpdateActionRequest, UpdateConnectionRequest, UpdateConnectorRequest, UpdateCustomerRequest, UpdateDataLinkTableRequest, UpdateDataSourceInstanceRequest, UpdateDataSourceRequest, UpdateFieldMappingRequest, UpdateFlowRequest, UpdateIntegrationRequest, UpdatePackageRequest, UpstreamFlowNodeRunSchema, UsageType, UserAccessor, UsersAccessor, WORKSPACE_SIZE_LIMITS, WebhookTypeEnum, WorkspaceElementChangeType, WorkspaceElementDependencyType, WorkspaceElementSearchQuery, WorkspaceElementSearchResult, WorkspaceElementSpecs, WorkspaceElementState, WorkspaceElementType, WorkspaceEventType, WorkspaceLimitsSchema, WorkspaceNotificationType, WorkspaceOnboardingStep, WorkspacePublicKey, WorkspaceSyncEventType, WorkspaceType, WritableConnectorVersionData, WritablePackageVersionData, WriteableConnectorFields, __resolveValue, addRequiredFieldsToSchema, addUdmFallbackFields, backwardCompatibleFilterMatch, buildData, buildDataSchema, buildValue, compareWorkspaceExports, compressDataSchema, createCompoundSchema, createFlowInstanceSchema, createObjectFromLocators, createOrUpdateConnection, createPaginationResponseSchema, createSchema, dataCollectionEventTypeToExternalEventType, dataLocationParametersMatch, doesMatchFilter, excludeFieldsFromSchema, excludeFieldsFromValue, excludeReadOnlyFieldsFromSchema, excludeWriteOnlyFieldsFromSchema, externalEventTypeToDataCollectionEventType, extractFieldLocator, extractMembraneErrorData, findUdmCollectionMapping, findUdmDefaultCollection, findUdmRootLocation, findValueLocators, generateExampleFromSchema, getActionInstanceVariableSchema, getActionRunTimeVariablesSchema, getAllEventMethodFilePaths, getBusinessDaysBetween, getChildNodeKeys, getDataCollectionCreateFields, getDataCollectionUpdateFields, getDataLocationMethodPath, getDefaultMembraneConfigLoader, getDownstreamNodeKeys, getElementSelector, getErrorFromData, getEventMethodFileKey, getFilterFieldValuesByLocator, getFlowInstanceNodeDependency, getFlowNode, getFlowNodeConfigTimeVariablesSchema, getFlowNodeDescription, getFlowNodeRunTimeVariablesSchema, getFlowNodeSpec, getFlowNodeTitle, getFormula$1 as getFormula, getFormulaLocators, getFormula as getFormula_internalDoNotUse, getFullNameForLocator, getFullTitleForLocator, getIconUriForLocator, getLocatorsFromData, getLocatorsFromSchema, getMembraneElementPath, 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, hasMembraneCredentials, injectFormulaCatalog, isBusinessDay, isDataActionType, isDataLocationMethodSupported, isFormula$1 as isFormula, isFormula as isFormula_internalDoNotUse, isMembraneError, isObject, isSameDataLocation, isSchemaEmpty, isStream, isValidLocator, loadMembraneConfig, locatorToField, locatorToSteps, locatorToString, makeDataLocationOperationPath, makeDataLocationPath, makeDataRecordSchema, makeObjectPropertyLocator, makeSchemaForLocator, membraneConfigSchema, mergeSchemas, mergeWithFormulas, nonEmptyObjectProperties, parseDataLocationPath, parseDate, parseMembraneElementPath, patchSchema, pickFieldsFromSchema, pickFieldsFromValue, populateSchemaTitles, processCopy, removeNonExistentVars, removeRequiredFieldsFromSchema, resolveFormulas, schemaAllowsCustomValue, schemaHasFixedValues, schemaHasProperties, schemaIsNumber, schemaIsScalar, schemaTypeFromValue, schemaWithTitle, setSchemaAtLocator, setValueAtLocator, stepsToLocator, streamToString, transformVariablesWith, transformVars, truncateData, unwrapSchema, unwrapSchemas, updateFlowInstanceSchema, updateImpliedSchema, valueToSchema, valueToString, walkSchema, wrapAnyOfSchema, zodBooleanCoercion };
|
|
14227
|
+
export { ACTIONS, ALERT_DELIVERY_METHODS, ALERT_TYPE_CATEGORIES, AccessDeniedError, AccountResponse, ActionAccessor, ActionApiResponse, ActionDependency, ActionDependencyType, ActionEditableProperties, ActionExportProperties, ActionInstanceAccessor, ActionInstanceApiResponse, ActionInstanceSetupError, ActionInstancesAccessor, ActionRunError, ActionRunLogRecordApiResponse, ActionRunLogStatus, ActionRunResponse, ActionType, ActionsAccessor, AgentSession, AgentSessionInputSchema, AgentSessionState, AgentSessionStatus, AlertCategory, AlertDeliverySettingsSchema, AlertSchema, AlertSeverity, AlertStatus, AlertType, AlertTypeDeliverySettingsSchema, ApiRequestSpec, AppDataSchemaAccessor, AppDataSchemaApiResponse, AppDataSchemaEditableProperties, AppDataSchemaExportProperties, AppDataSchemaInstanceAccessor, AppDataSchemaInstanceApiResponse, AppDataSchemaInstancesAccessor, AppDataSchemasAccessor, AppEventLogRecordApiResponse, AppEventSubscriptionAccessor, AppEventSubscriptionApiResponse, AppEventSubscriptionsAccessor, AppEventTypeAccessor, AppEventTypeApiResponse, AppEventTypeEditableProperties, AppEventTypeExportProperties, AppEventTypesAccessor, AppSchema, AppliedToIntegrations, BackwardCompatibleDataSourceEditableProperties, BadRequestError, BadRequestErrorKey, BaseAction, BaseActionInstance, BaseActionRunLogRecord, BaseAppDataSchema, BaseAppDataSchemaInstance, BaseAppEventSubscription, BaseAppEventType, BaseConnection, BaseConnector, BaseCustomer, BaseDataLinkTable, BaseDataLinkTableInstance, BaseDataSource, BaseDataSourceInstance, BaseExternalEvent, BaseExternalEventLogRecord, BaseExternalEventPull, BaseExternalEventSubscription, BaseFieldMapping, BaseFieldMappingInstance, BaseFlow, BaseFlowInstance, BaseFlowRun, BaseFunctionDefinition, BaseIntegration, BaseIntegrationLevelMembraneInterface, BaseIntegrationLevelMembraneInterfaceEditableProperties, BaseIntegrationLevelMembraneInterfaceExportProperties, BaseIntegrationLevelMembraneInterfaceReadOnlyProperties, BaseMembraneInterface, BaseMembraneInterfaceEditableProperties, BaseMembraneInterfaceReadOnlyProperties, BasePackage, BaseScreen, BaseWorkspaceElement, CONFIG_FILE_NAME, 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, CONNECTOR_VERSION_DEVELOPMENT, CONNECTOR_VERSION_LATEST, CommonFindElementsQuery, CommonFindInstancesQuery, CommonInstancesListQuery, CommonIntegrationOrConnectionQuery, CommonListElementsQuery, ConcurrencyError, ConcurrencyErrorKey, ConfigurationError, ConfigurationState, ConnectionAccessor, ConnectionApiResponse, ConnectionApiResponseWithSecrets, ConnectionDataCollectionAccessor, ConnectionError, ConnectionErrorKey, ConnectionLevelActionAccessor, ConnectionLevelActionsAccessor, ConnectionLevelDataSourceAccessor, ConnectionLevelDataSourcesAccessor, ConnectionLevelFieldMappingAccessor, ConnectionLevelFieldMappingsAccessor, ConnectionLevelFlowAccessor, ConnectionLevelFlowsAccessor, ConnectionMessagePayload, ConnectionOperationAccessor, ConnectionProxy, ConnectionRequest, ConnectionSelector, ConnectionSpec, ConnectionsAccessor, Connector, ConnectorAuth, ConnectorAuthClientCredentials, ConnectorAuthHandlerBase, ConnectorAuthIntegrationAppToken, ConnectorAuthMembraneToken, ConnectorAuthMethodTypes, ConnectorAuthOAuth1, ConnectorAuthOAuth2, ConnectorAuthProxy, ConnectorAuthSpec, ConnectorAuthWithFunctions, ConnectorDataCollectionEventImplementationType, ConnectorDataCollectionMethodKeys, ConnectorDataLocationTypes, ConnectorEventHandlerMethods, ConnectorEventImplementationType, ConnectorExportProperties, ConnectorFileUpdateType, ConnectorFunctionSpecs, ConnectorMethodImplementation, ConnectorMethodImplementationBase, ConnectorMethodImplementationGraphqlApiMapping, ConnectorMethodImplementationJavascript, ConnectorMethodImplementationMapping, ConnectorMethodImplementationNotSupported, ConnectorMethodImplementationOperationMapping, ConnectorMethodImplementationRestApiMapping, ConnectorMethodImplementationType, ConnectorOperationMethodImplementationTypes, ConnectorOption, ConnectorOptions, ConnectorSpec, ConnectorStatus, ConnectorStatusValues, ConnectorUdmCollectionMapping, ConnectorUdmListItem, ConnectorUdmSpec, ConnectorUiSpec, ConnectorVersion, ConnectorVersionData, CreateActionInstanceRequest, CreateActionRequest, CreateAgentSession, CreateConnectionRequest, CreateConnectorRequest, CreateCustomerRequest, CreateDataLinkTableRequest, CreateDataSourceInstanceRequest, CreateDataSourceRequest, CreateFieldMappingRequest, CreateFlowNodeRequest, CreateFlowRequest, CreateFlowRunRequest, CreateIntegrationRequest, CreatePackageRequest, CustomCodeError, CustomerAccessor, CustomerApiResponse, CustomerSelector, CustomersAccessor, DATA_RECORD_SCHEMA, DEFAULT_ALERT_DELIVERY_SETTINGS, DEFAULT_ALERT_TYPE_DELIVERY_SETTINGS, 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, DataLinkTableEditableProperties, DataLinkTableExportProperties, DataLinkTableInstanceAccessor, DataLinkTableInstanceApiResponse, DataLinkTableInstancesAccessor, DataLinkTablesAccessor, DataLocationMethodImplementationTypes, DataLocationPointer, DataLocationTypeCollection, DataLocatorStep, DataLocatorStepArrayItem, DataLocatorStepObjectProperty, DataLocatorStepType, DataRecordSchema, DataSchema, DataSourceAccessor, DataSourceApiResponse, DataSourceEditableProperties, DataSourceExportProperties, DataSourceInstanceAccessor, DataSourceInstanceApiResponse, DataSourceInstancesAccessor, DataSourceUnitConfig, DataSourcesAccessor, DependencyError, DownstreamFlowNodeRunSchema, EDITABLE_LIMITS, ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor, ElementsExportFields, EngineWorkspaceSettingsSchema, ErrorData, ErrorDataSchema, ErrorType, ExternalEvent, ExternalEventLogRecordApiResponse, ExternalEventLogStatus, ExternalEventPullApiResponse, ExternalEventPullStatus, ExternalEventSubscriptionAccessor, ExternalEventSubscriptionApiResponse, ExternalEventSubscriptionConfig, ExternalEventSubscriptionStatus, ExternalEventSubscriptionType, ExternalEventSubscriptionsAccessor, ExternalEventType, ExternalEventUnitConfig, FLOW_NODE_SPECS, FieldMappingAccessor, FieldMappingApiResponse, FieldMappingDirection, FieldMappingEditableProperties, FieldMappingExportProperties, FieldMappingInstanceAccessor, FieldMappingInstanceApiResponse, FieldMappingInstancesAccessor, FieldMappingUnitConfig, FieldMappingsAccessor, FindActionInstancesQuery, FindActionRunLogsQuery, FindActionRunLogsResponse, FindActionsQuery, FindAppEventSubscriptionsQuery, FindAppEventTypesQuery, FindAppEventsQuery, FindConnectionsQuery, FindConnectionsResponse, FindCustomersQuery, FindDataLinkTableInstanceLinksQuery, FindDataLinkTableInstancesQuery, FindDataLinkTablesQuery, FindDataLinksInTableQuery, FindDataLinksQuery, FindDataLinksResponse, FindDataSourceEventsQuery, FindDataSourceInstanceQuery, FindDataSourceInstanceSyncsQuery, FindDataSourceInstancesQuery, FindDataSourceSyncsQuery, FindDataSourcesQuery, FindExternalEventPullsQuery, FindFieldMappingsQuery, FindFlowInstancesQuery, FindFlowRunsQuery, FindFlowRunsResponse, FindFlowsQuery, FindIntegrationLevelMembraneInterfaceQuery, FindIntegrationsQuery, FindPackagesQuery, FindScreensQuery, FlowAccessor, FlowApiResponse, FlowEditableProperties, FlowExportProperties, 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, FullPlatformUser, FunctionDefinition, FunctionType, GenerateOptionsRequest, GeneratedConnectorOption, GenericFunctionDefinition, GraphQLApiMappingSchema, GraphQLFieldMappingSchema, GraphqlApiMappingFunction, HTTP_REQUEST_SCHEMA, HandyScenarioTemplateElement, HttpRequestMethod, HttpRequestSpec, IncludeArchivedQuery, IncomingWebhooksState, InsufficientCreditsError, IntegrationAccessor, IntegrationApiResponse, MembraneClient as IntegrationAppClient, IntegrationAppError, IntegrationAuthOption, IntegrationAuthUi, IntegrationEditableProperties, IntegrationElementLevel, IntegrationElementType, IntegrationExportProperties, IntegrationLevelActionAccessor, IntegrationLevelActionsListAccessor, IntegrationLevelDataSourceAccessor, IntegrationLevelDataSourcesListAccessor, IntegrationLevelFieldMappingAccessor, IntegrationLevelFieldMappingsListAccessor, IntegrationLevelFlowAccessor, IntegrationLevelFlowsListAccessor, IntegrationLevelMembraneInterfaceSelectorQuery, IntegrationSpecificElementSelector, IntegrationsAccessor, InternalError, InvalidLocatorError, JavascriptFunction, LimitUnits, ListActionInstancesForConnectionQuery, ListDataSourceInstancesForConnectionQuery, ListExternalAppsQuery, ListExternalEventLogRecordsQuery, ListExternalEventPullsQuery, ListExternalEventSubscriptionsQuery, ListFlowInstancesForConnectionQuery, ListPublicConnectorsQuery, ListPublicPackagesQuery, LogRecordType, MEMBRANE_ELEMENT_CONFIG_FILE_NAME, MIN_FULL_SYNC_INTERVAL_SECONDS, MIN_PULL_UPDATES_INTERVAL_SECONDS, MappingFunction, MappingSchema, MembraneAgentKey, axios as MembraneAxiosInstance, MembraneClient, MembraneConfigLoader, MembraneElementLayer, MembraneError, MinimalConnector, NotAuthenticatedError, NotFoundError, OAUTH1_CONFIG_SCHEMA, OAUTH_CONFIG_SCHEMA, OpenapiMappingSchema, OperationMappingFunction, OperationMappingSchema, OrgLimits, OrgLimitsType, OrgPlan, OrgSchema, OrgUserRole, OrgUserStatus, OrgWorkspaceSchema, OrgWorkspaceUser, PACKAGE_VERSION_DEVELOPMENT, PACKAGE_VERSION_LATEST, PARALLEL_EXECUTION_LIMITS, PackageAccessor, PackageApiResponse, PackageCalculatedProperties, PackageEditableProperties, PackageElement, PackageElementApi, PackageElementExport, PackageExportProperties, PackageVersionData, PackageVersionListItem, PackagesAccessor, PaginationQuery, PaginationResponse, PatchAgentSessionSchema, PlatformUserSchema, RATE_LIMITS, RateLimitExceededError, RequestMappingSchema, ResetFlowInstanceOptions, RestApiMappingFunction, RestApiMappingSchema, RunActionRequest, RunFlowApiRequest, ScenarioAccessor, ScenarioTemplate, ScenarioTemplateCategory, ScenarioTemplateElements, ScenariosAccessor, ScreenAccessor, ScreenApiResponse, ScreenBlock, ScreenBlockType, ScreenType, ScreensAccessor, SearchQuery, SelfAccessor, UDM, UNIFIED_DATA_MODELS, UnitRunError, UpdateActionInstanceRequest, UpdateActionRequest, UpdateConnectionRequest, UpdateConnectorRequest, UpdateCustomerRequest, UpdateDataLinkTableRequest, UpdateDataSourceInstanceRequest, UpdateDataSourceRequest, UpdateFieldMappingRequest, UpdateFlowRequest, UpdateIntegrationRequest, UpdatePackageRequest, UpstreamFlowNodeRunSchema, UsageType, UserAccessor, UsersAccessor, WORKSPACE_SIZE_LIMITS, WebhookTypeEnum, WorkspaceElementChangeType, WorkspaceElementDependencyType, WorkspaceElementSearchQuery, WorkspaceElementSearchResult, WorkspaceElementSpecs, WorkspaceElementState, WorkspaceElementType, WorkspaceEventType, WorkspaceLimitsSchema, WorkspaceNotificationType, WorkspaceOnboardingStep, WorkspacePublicKey, WorkspaceSyncEventType, WorkspaceType, WritableConnectorVersionData, WritablePackageVersionData, WriteableConnectorFields, WriteableConnectorOption, __resolveValue, addRequiredFieldsToSchema, addUdmFallbackFields, addUndefinedWriteableProperties, backwardCompatibleFilterMatch, buildData, buildDataSchema, buildValue, compareWorkspaceExports, compressDataSchema, createCompoundSchema, createFlowInstanceSchema, createObjectFromLocators, createOrUpdateConnection, createPaginationResponseSchema, createSchema, dataCollectionEventTypeToExternalEventType, dataLocationParametersMatch, doesMatchFilter, excludeFieldsFromSchema, excludeFieldsFromValue, excludeReadOnlyFieldsFromSchema, excludeWriteOnlyFieldsFromSchema, externalEventTypeToDataCollectionEventType, extractFieldLocator, extractMembraneErrorData, findUdmCollectionMapping, findUdmDefaultCollection, findUdmRootLocation, findValueLocators, generateExampleFromSchema, getActionInstanceVariableSchema, getActionRunTimeVariablesSchema, getAlertCategoryDisplayName, getAlertDeliveryMethodLabel, getAlertTypeDisplayName, getAlertTypesByCategory, getAllEventMethodFilePaths, getBusinessDaysBetween, getChildNodeKeys, getDataCollectionCreateFields, getDataCollectionUpdateFields, getDataLocationMethodPath, getDefaultMembraneConfigLoader, getDownstreamNodeKeys, getEffectiveConnectorOption, getElementSelector, getErrorFromData, getEventMethodFileKey, getFilterFieldValuesByLocator, getFlowInstanceNodeDependency, getFlowNode, getFlowNodeConfigTimeVariablesSchema, getFlowNodeDescription, getFlowNodeRunTimeVariablesSchema, getFlowNodeSpec, getFlowNodeTitle, getFormula$1 as getFormula, getFormulaLocators, getFormula as getFormula_internalDoNotUse, getFullNameForLocator, getFullTitleForLocator, getIconUriForLocator, getLocatorsFromData, getLocatorsFromSchema, getMembraneElementPath, 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, hasMembraneCredentials, injectFormulaCatalog, isBlob, isBusinessDay, isDataActionType, isDataLocationMethodSupported, isDeliveryMethodEnabled, isFormula$1 as isFormula, isFormula as isFormula_internalDoNotUse, isMembraneError, isObject, isSameDataLocation, isSchemaEmpty, isStream, isValidAlertType, isValidLocator, lenientParseWithSchema, loadMembraneConfig, locatorToField, locatorToSteps, locatorToString, makeDataLocationOperationPath, makeDataLocationPath, makeDataRecordSchema, makeObjectPropertyLocator, makeSchemaForLocator, membraneConfigSchema, mergeSchemas, mergeWithFormulas, nonEmptyObjectProperties, parseDataLocationPath, parseDate, parseMembraneElementPath, patchSchema, pickFieldsFromSchema, pickFieldsFromValue, populateSchemaTitles, processCopy, removeNonExistentVars, removeRequiredFieldsFromSchema, resolveFormulas, schemaAllowsCustomValue, schemaHasFixedValues, schemaHasProperties, schemaIsNumber, schemaIsScalar, schemaTypeFromValue, schemaWithTitle, setEditablePropertiesForWorkspaceElement, setSchemaAtLocator, setValueAtLocator, stepsToLocator, streamToString, transformVariablesWith, transformVars, truncateData, unwrapSchema, unwrapSchemas, updateFlowInstanceSchema, updateImpliedSchema, valueToSchema, valueToString, walkSchema, wrapAnyOfSchema, zodBooleanCoercion };
|
|
13767
14228
|
//# sourceMappingURL=index.node.mjs.map
|