@membranehq/sdk 0.9.5 → 0.9.7
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 +1080 -187
- package/dist/dts/agent/session.d.ts +12 -0
- package/dist/dts/config/index.d.ts +1 -0
- package/dist/dts/orgs/types.d.ts +10 -0
- package/dist/dts/workspace-elements/base/connectors/auth.d.ts +1540 -51
- package/dist/dts/workspace-elements/base/connectors/methods.d.ts +111 -34
- package/dist/dts/workspace-elements/base/connectors/types.d.ts +5131 -53
- package/dist/dts/workspace-elements/base/connectors/udm.d.ts +29 -13
- package/dist/dts/workspace-elements/base/data-collections/schemas.d.ts +5 -4
- package/dist/dts/workspaces/compare.d.ts +4 -1
- package/dist/dts/workspaces/types.d.ts +24 -2
- package/dist/index.browser.d.mts +7169 -456
- package/dist/index.browser.d.ts +7169 -456
- package/dist/index.browser.js +257 -5
- package/dist/index.browser.js.map +1 -1
- package/dist/index.browser.mjs +226 -6
- package/dist/index.browser.mjs.map +1 -1
- package/dist/index.node.d.mts +7170 -456
- package/dist/index.node.d.ts +7170 -456
- package/dist/index.node.js +264 -5
- package/dist/index.node.js.map +1 -1
- package/dist/index.node.mjs +233 -6
- package/dist/index.node.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.node.js
CHANGED
|
@@ -3803,6 +3803,45 @@ const CONNECTOR_METHOD_IMPLEMENTATION_SUFFIXES = {
|
|
|
3803
3803
|
[exports.ConnectorMethodImplementationType.javascript]: ['.js', '.ts'],
|
|
3804
3804
|
[exports.ConnectorMethodImplementationType.mapping]: ['.map.yml', '.yml'],
|
|
3805
3805
|
};
|
|
3806
|
+
const ConnectorMethodImplementationBase = z.z.object({
|
|
3807
|
+
implementationType: z.z.nativeEnum(exports.ConnectorMethodImplementationType).optional(),
|
|
3808
|
+
filePath: z.z.string().optional(),
|
|
3809
|
+
inheritedFromPath: z.z.array(z.z.string()).optional(),
|
|
3810
|
+
isIncomplete: z.z.boolean().optional(),
|
|
3811
|
+
parametersSchema: DataSchema.optional(),
|
|
3812
|
+
});
|
|
3813
|
+
const ConnectorMethodImplementationMapping = ConnectorMethodImplementationBase.extend({
|
|
3814
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.mapping),
|
|
3815
|
+
mapping: z.z.any(),
|
|
3816
|
+
});
|
|
3817
|
+
const ConnectorMethodImplementationOperationMapping = ConnectorMethodImplementationBase.extend({
|
|
3818
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.operationMapping),
|
|
3819
|
+
mapping: z.z.any(),
|
|
3820
|
+
});
|
|
3821
|
+
const ConnectorMethodImplementationRestApiMapping = ConnectorMethodImplementationBase.extend({
|
|
3822
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.restApiMapping),
|
|
3823
|
+
mapping: z.z.any(),
|
|
3824
|
+
});
|
|
3825
|
+
const ConnectorMethodImplementationGraphqlApiMapping = ConnectorMethodImplementationBase.extend({
|
|
3826
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.graphqlApiMapping),
|
|
3827
|
+
mapping: z.z.any(),
|
|
3828
|
+
});
|
|
3829
|
+
const ConnectorMethodImplementationJavascript = ConnectorMethodImplementationBase.extend({
|
|
3830
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.javascript),
|
|
3831
|
+
code: z.z.string(),
|
|
3832
|
+
});
|
|
3833
|
+
const ConnectorMethodImplementationNotSupported = ConnectorMethodImplementationBase.extend({
|
|
3834
|
+
implementationType: z.z.literal(exports.ConnectorMethodImplementationType.notSupported),
|
|
3835
|
+
});
|
|
3836
|
+
const ConnectorMethodImplementation = z.z.union([
|
|
3837
|
+
ConnectorMethodImplementationBase,
|
|
3838
|
+
ConnectorMethodImplementationMapping,
|
|
3839
|
+
ConnectorMethodImplementationOperationMapping,
|
|
3840
|
+
ConnectorMethodImplementationRestApiMapping,
|
|
3841
|
+
ConnectorMethodImplementationGraphqlApiMapping,
|
|
3842
|
+
ConnectorMethodImplementationJavascript,
|
|
3843
|
+
ConnectorMethodImplementationNotSupported,
|
|
3844
|
+
]);
|
|
3806
3845
|
|
|
3807
3846
|
const CONNECTOR_AUTH_TYPES = [
|
|
3808
3847
|
'integration-app-token',
|
|
@@ -3812,6 +3851,25 @@ const CONNECTOR_AUTH_TYPES = [
|
|
|
3812
3851
|
'client-credentials',
|
|
3813
3852
|
'proxy',
|
|
3814
3853
|
];
|
|
3854
|
+
const ConnectorAuthSpec = z.z.object({
|
|
3855
|
+
title: z.z.string().optional(),
|
|
3856
|
+
description: z.z.string().optional(),
|
|
3857
|
+
type: z.z.enum(CONNECTOR_AUTH_TYPES),
|
|
3858
|
+
ui: z.z
|
|
3859
|
+
.object({
|
|
3860
|
+
schema: DataSchema.optional(),
|
|
3861
|
+
helpUri: z.z.string().optional(),
|
|
3862
|
+
})
|
|
3863
|
+
.optional(),
|
|
3864
|
+
});
|
|
3865
|
+
const ConnectorAuthHandlerBase = ConnectorAuthSpec.extend({
|
|
3866
|
+
credentialsSchema: DataSchema.optional(),
|
|
3867
|
+
customCredentialsSchema: DataSchema.optional(),
|
|
3868
|
+
makeApiClient: ConnectorMethodImplementationBase.optional(),
|
|
3869
|
+
refreshCredentials: ConnectorMethodImplementationBase.optional(),
|
|
3870
|
+
test: ConnectorMethodImplementationBase.optional(),
|
|
3871
|
+
enabled: z.z.any().optional(),
|
|
3872
|
+
});
|
|
3815
3873
|
function getAuthSpec(spec, authOptionKey) {
|
|
3816
3874
|
var _a, _b;
|
|
3817
3875
|
let authSpec;
|
|
@@ -3883,7 +3941,7 @@ const ConnectorAuthMethodTypes = {
|
|
|
3883
3941
|
isRequired: false,
|
|
3884
3942
|
},
|
|
3885
3943
|
getCredentialsFromConnectionParameters: {
|
|
3886
|
-
authTypes: ['client-credentials'],
|
|
3944
|
+
authTypes: ['client-credentials', 'oauth2'],
|
|
3887
3945
|
getInputSchema: getDefaultAuthInputSchema,
|
|
3888
3946
|
getOutputSchema: ({ connectorSpec, authOptionKey }) => {
|
|
3889
3947
|
var _a;
|
|
@@ -3941,6 +3999,52 @@ const ConnectorAuthMethodTypes = {
|
|
|
3941
3999
|
isRequired: true,
|
|
3942
4000
|
},
|
|
3943
4001
|
};
|
|
4002
|
+
const ConnectorAuthOAuth2 = ConnectorAuthHandlerBase.extend({
|
|
4003
|
+
type: z.z.literal('oauth2'),
|
|
4004
|
+
getOAuthConfig: ConnectorMethodImplementation.optional(),
|
|
4005
|
+
getTokenData: ConnectorMethodImplementation.optional(),
|
|
4006
|
+
getCredentialsFromAccessTokenResponse: ConnectorMethodImplementation.optional(),
|
|
4007
|
+
getCredentialsFromRefreshTokenResponse: ConnectorMethodImplementation.optional(),
|
|
4008
|
+
oAuthConfig: ConnectorMethodImplementation.optional(),
|
|
4009
|
+
});
|
|
4010
|
+
const ConnectorAuthOAuth1 = ConnectorAuthHandlerBase.extend({
|
|
4011
|
+
type: z.z.literal('oauth1'),
|
|
4012
|
+
getOAuthConfig: ConnectorMethodImplementation.optional(),
|
|
4013
|
+
});
|
|
4014
|
+
const ConnectorAuthClientCredentials = ConnectorAuthHandlerBase.extend({
|
|
4015
|
+
type: z.z.literal('client-credentials'),
|
|
4016
|
+
getCredentialsFromConnectionParameters: ConnectorMethodImplementationBase.optional(),
|
|
4017
|
+
});
|
|
4018
|
+
const ConnectorAuthProxy = ConnectorAuthHandlerBase.extend({
|
|
4019
|
+
type: z.z.literal('proxy'),
|
|
4020
|
+
proxyKey: z.z.string(),
|
|
4021
|
+
});
|
|
4022
|
+
const ConnectorAuthIntegrationAppToken = ConnectorAuthHandlerBase.extend({
|
|
4023
|
+
type: z.z.literal('integration-app-token'),
|
|
4024
|
+
});
|
|
4025
|
+
const ConnectorAuthMembraneToken = ConnectorAuthHandlerBase.extend({
|
|
4026
|
+
type: z.z.literal('membrane-token'),
|
|
4027
|
+
});
|
|
4028
|
+
const ConnectorAuthVariant = z.z.union([
|
|
4029
|
+
ConnectorAuthOAuth2,
|
|
4030
|
+
ConnectorAuthOAuth1,
|
|
4031
|
+
ConnectorAuthClientCredentials,
|
|
4032
|
+
ConnectorAuthIntegrationAppToken,
|
|
4033
|
+
ConnectorAuthMembraneToken,
|
|
4034
|
+
ConnectorAuthProxy,
|
|
4035
|
+
]);
|
|
4036
|
+
const ConnectorAuth = ConnectorAuthVariant.and(z.z.object({
|
|
4037
|
+
options: z.z
|
|
4038
|
+
.record(z.z.string(), z.z.union([
|
|
4039
|
+
ConnectorAuthOAuth2,
|
|
4040
|
+
ConnectorAuthOAuth1,
|
|
4041
|
+
ConnectorAuthClientCredentials,
|
|
4042
|
+
ConnectorAuthIntegrationAppToken,
|
|
4043
|
+
ConnectorAuthMembraneToken,
|
|
4044
|
+
ConnectorAuthProxy,
|
|
4045
|
+
]))
|
|
4046
|
+
.optional(),
|
|
4047
|
+
}));
|
|
3944
4048
|
const OAUTH_CONFIG_SCHEMA = {
|
|
3945
4049
|
type: 'object',
|
|
3946
4050
|
properties: {
|
|
@@ -4077,6 +4181,8 @@ const ConnectorOperationMethodImplementationTypes = [
|
|
|
4077
4181
|
exports.ConnectorMethodImplementationType.javascript,
|
|
4078
4182
|
];
|
|
4079
4183
|
|
|
4184
|
+
const CONNECTOR_VERSION_DEVELOPMENT = 'dev';
|
|
4185
|
+
const CONNECTOR_VERSION_LATEST = 'latest';
|
|
4080
4186
|
const CONNECTOR_CATEGORIES = [
|
|
4081
4187
|
'Accounting',
|
|
4082
4188
|
'Ads',
|
|
@@ -4098,12 +4204,88 @@ const CONNECTOR_CATEGORIES = [
|
|
|
4098
4204
|
'Sales',
|
|
4099
4205
|
'Ticketing',
|
|
4100
4206
|
];
|
|
4207
|
+
const ConnectorStatusValues = ['production', 'beta', 'planned'];
|
|
4208
|
+
const ConnectorUiSpec = z.z.object({
|
|
4209
|
+
schema: DataSchema.optional(),
|
|
4210
|
+
description: z.z.string().optional(),
|
|
4211
|
+
helpUri: z.z.string().optional(),
|
|
4212
|
+
test: z.z.boolean().optional(),
|
|
4213
|
+
});
|
|
4214
|
+
const ConnectorSpec = z.z.object({
|
|
4215
|
+
key: z.z.string().optional(),
|
|
4216
|
+
name: z.z.string().optional(),
|
|
4217
|
+
appUri: z.z.string().optional(),
|
|
4218
|
+
logoUri: z.z.string().optional(),
|
|
4219
|
+
apiDocsUri: z.z.string().optional(),
|
|
4220
|
+
api: z.z
|
|
4221
|
+
.object({
|
|
4222
|
+
type: z.z.enum(['openapi', 'graphql']),
|
|
4223
|
+
})
|
|
4224
|
+
.optional(),
|
|
4225
|
+
ui: ConnectorUiSpec.optional(),
|
|
4226
|
+
auth: ConnectorAuth.optional(),
|
|
4227
|
+
parametersSchema: DataSchema.optional(),
|
|
4228
|
+
udms: z.z.array(z.z.string()).optional(),
|
|
4229
|
+
udm: z.z.record(z.z.string(), z.z.any()).optional(),
|
|
4230
|
+
operations: z.z.array(z.z.any()).optional(),
|
|
4231
|
+
test: ConnectorMethodImplementation.optional(),
|
|
4232
|
+
hasReadme: z.z.boolean().optional(),
|
|
4233
|
+
appUuid: z.z.string().optional(),
|
|
4234
|
+
knowledgeBaseUuid: z.z.string().optional(),
|
|
4235
|
+
workspaceId: z.z.string().optional(),
|
|
4236
|
+
data: z.z.any().optional(),
|
|
4237
|
+
});
|
|
4101
4238
|
exports.ConnectorStatus = void 0;
|
|
4102
4239
|
(function (ConnectorStatus) {
|
|
4103
4240
|
ConnectorStatus["production"] = "production";
|
|
4104
4241
|
ConnectorStatus["beta"] = "beta";
|
|
4105
4242
|
ConnectorStatus["planned"] = "planned";
|
|
4106
4243
|
})(exports.ConnectorStatus || (exports.ConnectorStatus = {}));
|
|
4244
|
+
const WritableConnectorVersionData = z.z.object({
|
|
4245
|
+
auth: ConnectorAuth.optional(),
|
|
4246
|
+
parametersSchema: DataSchema.optional(),
|
|
4247
|
+
});
|
|
4248
|
+
const ConnectorVersionData = z.z
|
|
4249
|
+
.object({
|
|
4250
|
+
baseUri: z.z.string(),
|
|
4251
|
+
revision: z.z.string().optional(),
|
|
4252
|
+
dataCollectionsCount: z.z.number().optional(),
|
|
4253
|
+
operationsCount: z.z.number().optional(),
|
|
4254
|
+
eventsCount: z.z.number().optional(),
|
|
4255
|
+
udms: z.z.array(z.z.string()).optional(),
|
|
4256
|
+
hasTest: z.z.boolean().optional(),
|
|
4257
|
+
hasAuthTest: z.z.boolean().optional(),
|
|
4258
|
+
hasOperations: z.z.boolean().optional(),
|
|
4259
|
+
hasData: z.z.boolean().optional(),
|
|
4260
|
+
isReadOnly: z.z.boolean().optional(),
|
|
4261
|
+
version: z.z.string(),
|
|
4262
|
+
})
|
|
4263
|
+
.extend(WritableConnectorVersionData.shape);
|
|
4264
|
+
const ConnectorVersion = ConnectorVersionData.extend({
|
|
4265
|
+
id: z.z.string(),
|
|
4266
|
+
connectorId: z.z.string(),
|
|
4267
|
+
changelog: z.z.string(),
|
|
4268
|
+
});
|
|
4269
|
+
const BaseConnector = z.z.object({
|
|
4270
|
+
id: z.z.string(),
|
|
4271
|
+
key: z.z.string(),
|
|
4272
|
+
uuid: z.z.string(),
|
|
4273
|
+
name: z.z.string(),
|
|
4274
|
+
logoUri: z.z.string(),
|
|
4275
|
+
appUri: z.z.string(),
|
|
4276
|
+
apiDocsUri: z.z.string(),
|
|
4277
|
+
hasReadme: z.z.boolean(),
|
|
4278
|
+
status: z.z.string().optional(),
|
|
4279
|
+
categories: z.z.array(z.z.string()).optional(),
|
|
4280
|
+
isPublic: z.z.boolean().optional(),
|
|
4281
|
+
popularity: z.z.number().optional(),
|
|
4282
|
+
appUuid: z.z.string().optional(),
|
|
4283
|
+
});
|
|
4284
|
+
const Connector = z.z
|
|
4285
|
+
.object({})
|
|
4286
|
+
.extend(ConnectorSpec.shape)
|
|
4287
|
+
.extend(BaseConnector.shape)
|
|
4288
|
+
.extend(ConnectorVersionData.shape);
|
|
4107
4289
|
const MinimalConnector = z.z.object({
|
|
4108
4290
|
id: z.z.string(),
|
|
4109
4291
|
key: z.z.string(),
|
|
@@ -8326,6 +8508,10 @@ const DataCollectionSpec = z.z.object({
|
|
|
8326
8508
|
udm: DataCollectionUdmsSpec.optional(),
|
|
8327
8509
|
find: DataCollectionFindSpec.optional(),
|
|
8328
8510
|
});
|
|
8511
|
+
const DataLocationPointer = z.z.object({
|
|
8512
|
+
key: z.z.string(),
|
|
8513
|
+
parameters: z.z.record(z.z.string(), z.z.any()).optional(),
|
|
8514
|
+
});
|
|
8329
8515
|
const DataCollectionMethodRequest = z.z.object({
|
|
8330
8516
|
parameters: z.z.record(z.z.string(), z.z.any()).optional(),
|
|
8331
8517
|
});
|
|
@@ -8393,6 +8579,18 @@ const ConnectorDataLocationTypes = {
|
|
|
8393
8579
|
collection: DataLocationTypeCollection,
|
|
8394
8580
|
};
|
|
8395
8581
|
|
|
8582
|
+
const ConnectorUdmListItem = z.z.object({
|
|
8583
|
+
key: z.z.string(),
|
|
8584
|
+
});
|
|
8585
|
+
const ConnectorUdmCollectionMapping = DataLocationPointer.extend({
|
|
8586
|
+
fieldsToCollection: z.z.any().optional(),
|
|
8587
|
+
fieldsFromCollection: z.z.any().optional(),
|
|
8588
|
+
});
|
|
8589
|
+
const ConnectorUdmSpec = z.z.object({
|
|
8590
|
+
defaultCollection: DataLocationPointer.optional(),
|
|
8591
|
+
rootDirectory: DataLocationPointer.optional(),
|
|
8592
|
+
collectionMappings: z.z.array(ConnectorUdmCollectionMapping),
|
|
8593
|
+
});
|
|
8396
8594
|
function findUdmCollectionMapping(udm, collectionKey, parameters) {
|
|
8397
8595
|
if (!Array.isArray(udm === null || udm === void 0 ? void 0 : udm.collectionMappings)) {
|
|
8398
8596
|
return undefined;
|
|
@@ -10217,6 +10415,7 @@ function getMembraneElementPath(elementType, elementKey, integrationKey) {
|
|
|
10217
10415
|
return `${integrationTypePath}/${integrationKey}/${elementTypePath}/${elementKey}/${MEMBRANE_ELEMENT_CONFIG_FILE_NAME}`;
|
|
10218
10416
|
}
|
|
10219
10417
|
function parseMembraneElementPath(relativePath) {
|
|
10418
|
+
const normalizedPath = relativePath.split(/[\\/]/).join('/');
|
|
10220
10419
|
const typeByApiPath = new Map();
|
|
10221
10420
|
for (const spec of Object.values(WorkspaceElementSpecs)) {
|
|
10222
10421
|
typeByApiPath.set(spec.apiPath, spec.type);
|
|
@@ -10225,7 +10424,7 @@ function parseMembraneElementPath(relativePath) {
|
|
|
10225
10424
|
.map((spec) => spec.apiPath)
|
|
10226
10425
|
.join('|');
|
|
10227
10426
|
const universalPattern = new RegExp(`^(?<elementType>${elementTypes})/(?<elementKey>[^/]+)/${MEMBRANE_ELEMENT_CONFIG_FILE_NAME}$`);
|
|
10228
|
-
const universalMatch =
|
|
10427
|
+
const universalMatch = normalizedPath.match(universalPattern);
|
|
10229
10428
|
if (universalMatch === null || universalMatch === void 0 ? void 0 : universalMatch.groups) {
|
|
10230
10429
|
const { elementType: elementTypePath, elementKey } = universalMatch.groups;
|
|
10231
10430
|
const elementType = typeByApiPath.get(elementTypePath);
|
|
@@ -10233,8 +10432,12 @@ function parseMembraneElementPath(relativePath) {
|
|
|
10233
10432
|
return { type: elementType, key: elementKey };
|
|
10234
10433
|
}
|
|
10235
10434
|
}
|
|
10236
|
-
const
|
|
10237
|
-
|
|
10435
|
+
const integrationLevelElementTypes = Object.values(WorkspaceElementSpecs)
|
|
10436
|
+
.filter((spec) => spec.isIntegrationLevel)
|
|
10437
|
+
.map((spec) => spec.apiPath)
|
|
10438
|
+
.join('|');
|
|
10439
|
+
const integrationLevelPattern = new RegExp(`^integrations/(?<integrationKey>[^/]+)/(?<elementType>${integrationLevelElementTypes})/(?<elementKey>[^/]+)/${MEMBRANE_ELEMENT_CONFIG_FILE_NAME}$`);
|
|
10440
|
+
const integrationLevelMatch = normalizedPath.match(integrationLevelPattern);
|
|
10238
10441
|
if (integrationLevelMatch === null || integrationLevelMatch === void 0 ? void 0 : integrationLevelMatch.groups) {
|
|
10239
10442
|
const { integrationKey, elementType: elementTypePath, elementKey } = integrationLevelMatch.groups;
|
|
10240
10443
|
const elementType = typeByApiPath.get(elementTypePath);
|
|
@@ -10679,6 +10882,7 @@ const WorkspaceLimitsSchema = z.object({
|
|
|
10679
10882
|
parallelBackgroundJobs: WorkspaceLimit.optional(),
|
|
10680
10883
|
parallelEventLogs: WorkspaceLimit.optional(),
|
|
10681
10884
|
parallelEventLogsPerConnection: WorkspaceLimit.optional(),
|
|
10885
|
+
parallelInstantTasksActiveJobs: WorkspaceLimit.optional(),
|
|
10682
10886
|
ParallelWriteDatabaseRequests: WorkspaceLimit.optional(),
|
|
10683
10887
|
fileUploadsMbPerHour: WorkspaceLimit.optional(),
|
|
10684
10888
|
apiRequestsPerSecond: WorkspaceLimit.optional(),
|
|
@@ -10691,6 +10895,7 @@ const WorkspaceLimitsSchema = z.object({
|
|
|
10691
10895
|
totalNumberOfCustomers: WorkspaceLimit.optional(),
|
|
10692
10896
|
totalNumberOfConnections: WorkspaceLimit.optional(),
|
|
10693
10897
|
totalNumberOfWorkspaceElements: WorkspaceLimit.optional(),
|
|
10898
|
+
instantTasksQueueSize: WorkspaceLimit.optional(),
|
|
10694
10899
|
parallelApiRequestsPerCustomer: WorkspaceLimit.optional(),
|
|
10695
10900
|
parallelBackgroundJobsPerCustomer: WorkspaceLimit.optional(),
|
|
10696
10901
|
apiRequestsPerCustomerPerSecond: WorkspaceLimit.optional(),
|
|
@@ -10807,7 +11012,7 @@ exports.WorkspaceElementChangeType = void 0;
|
|
|
10807
11012
|
WorkspaceElementChangeType["UPDATE"] = "update";
|
|
10808
11013
|
WorkspaceElementChangeType["DELETE"] = "delete";
|
|
10809
11014
|
})(exports.WorkspaceElementChangeType || (exports.WorkspaceElementChangeType = {}));
|
|
10810
|
-
function compareWorkspaceExports(baseExport, targetExport) {
|
|
11015
|
+
function compareWorkspaceExports(baseExport, targetExport, options = { includeDeletions: true }) {
|
|
10811
11016
|
const changes = [];
|
|
10812
11017
|
const comparison = {
|
|
10813
11018
|
[exports.WorkspaceElementChangeType.CREATE]: new Set(),
|
|
@@ -10847,6 +11052,9 @@ function compareWorkspaceExports(baseExport, targetExport) {
|
|
|
10847
11052
|
sourceUuidByTargetUuid.set(targetElement.uuid, baseElement.uuid);
|
|
10848
11053
|
}
|
|
10849
11054
|
const change = compareElementExports(baseElement, targetElement);
|
|
11055
|
+
if (options.includeDeletions === false && (change === null || change === void 0 ? void 0 : change.type) === exports.WorkspaceElementChangeType.DELETE) {
|
|
11056
|
+
continue;
|
|
11057
|
+
}
|
|
10850
11058
|
if (change) {
|
|
10851
11059
|
changes.push(change);
|
|
10852
11060
|
}
|
|
@@ -12749,6 +12957,11 @@ exports.AgentSessionStatus = void 0;
|
|
|
12749
12957
|
AgentSessionStatus["FAILED"] = "failed";
|
|
12750
12958
|
AgentSessionStatus["CANCELLED"] = "cancelled";
|
|
12751
12959
|
})(exports.AgentSessionStatus || (exports.AgentSessionStatus = {}));
|
|
12960
|
+
exports.AgentSessionState = void 0;
|
|
12961
|
+
(function (AgentSessionState) {
|
|
12962
|
+
AgentSessionState["BUSY"] = "busy";
|
|
12963
|
+
AgentSessionState["IDLE"] = "idle";
|
|
12964
|
+
})(exports.AgentSessionState || (exports.AgentSessionState = {}));
|
|
12752
12965
|
const AgentSession = z.z.object({
|
|
12753
12966
|
id: z.z.string(),
|
|
12754
12967
|
workspaceId: z.z.string(),
|
|
@@ -12769,6 +12982,7 @@ const AgentSession = z.z.object({
|
|
|
12769
12982
|
logs: z.z.array(z.z.any()).optional(),
|
|
12770
12983
|
usage: z.z.number().optional(),
|
|
12771
12984
|
summary: z.z.string().optional(),
|
|
12985
|
+
state: z.z.enum(exports.AgentSessionState).default(exports.AgentSessionState.IDLE),
|
|
12772
12986
|
});
|
|
12773
12987
|
const CreateAgentSession = z.z.object({
|
|
12774
12988
|
workspaceElementType: z.z.enum(exports.WorkspaceElementType).optional(),
|
|
@@ -12780,6 +12994,12 @@ const AgentSessionInputSchema = z.z.object({
|
|
|
12780
12994
|
input: z.z.string().min(1),
|
|
12781
12995
|
synthetic: z.z.boolean().optional(),
|
|
12782
12996
|
});
|
|
12997
|
+
const PatchAgentSessionSchema = z.z.object({
|
|
12998
|
+
state: z.z.enum(exports.AgentSessionState).optional(),
|
|
12999
|
+
lastActivityAt: z.z.iso.datetime().optional(),
|
|
13000
|
+
summary: z.z.string().optional(),
|
|
13001
|
+
status: z.z.enum(exports.AgentSessionStatus).optional(),
|
|
13002
|
+
});
|
|
12783
13003
|
|
|
12784
13004
|
const API_VERSIONS = {
|
|
12785
13005
|
LEGACY: 'legacy',
|
|
@@ -13095,6 +13315,7 @@ const membraneConfigSchema = z.z.object({
|
|
|
13095
13315
|
workspaceKey: z.z.string(),
|
|
13096
13316
|
workspaceSecret: z.z.string(),
|
|
13097
13317
|
apiUri: z.z.string().optional(),
|
|
13318
|
+
consoleUri: z.z.string().optional(),
|
|
13098
13319
|
testCustomerId: z.z.string().optional(),
|
|
13099
13320
|
});
|
|
13100
13321
|
class MembraneConfigLoader {
|
|
@@ -13212,6 +13433,9 @@ class MembraneConfigLoader {
|
|
|
13212
13433
|
if (parsedConfig === null || parsedConfig === void 0 ? void 0 : parsedConfig.apiUri) {
|
|
13213
13434
|
config.apiUri = String(parsedConfig.apiUri);
|
|
13214
13435
|
}
|
|
13436
|
+
if (parsedConfig === null || parsedConfig === void 0 ? void 0 : parsedConfig.consoleUri) {
|
|
13437
|
+
config.consoleUri = String(parsedConfig.consoleUri);
|
|
13438
|
+
}
|
|
13215
13439
|
if (parsedConfig === null || parsedConfig === void 0 ? void 0 : parsedConfig.testCustomerId) {
|
|
13216
13440
|
config.testCustomerId = String(parsedConfig.testCustomerId);
|
|
13217
13441
|
}
|
|
@@ -13228,6 +13452,9 @@ class MembraneConfigLoader {
|
|
|
13228
13452
|
if (process.env.MEMBRANE_API_URI) {
|
|
13229
13453
|
config.apiUri = process.env.MEMBRANE_API_URI;
|
|
13230
13454
|
}
|
|
13455
|
+
if (process.env.MEMBRANE_CONSOLE_URI) {
|
|
13456
|
+
config.consoleUri = process.env.MEMBRANE_CONSOLE_URI;
|
|
13457
|
+
}
|
|
13231
13458
|
if (process.env.MEMBRANE_TEST_CUSTOMER_ID) {
|
|
13232
13459
|
config.testCustomerId = process.env.MEMBRANE_TEST_CUSTOMER_ID;
|
|
13233
13460
|
}
|
|
@@ -13304,6 +13531,7 @@ exports.BaseAppDataSchemaInstance = BaseAppDataSchemaInstance;
|
|
|
13304
13531
|
exports.BaseAppEventSubscription = BaseAppEventSubscription;
|
|
13305
13532
|
exports.BaseAppEventType = BaseAppEventType;
|
|
13306
13533
|
exports.BaseConnection = BaseConnection;
|
|
13534
|
+
exports.BaseConnector = BaseConnector;
|
|
13307
13535
|
exports.BaseCustomer = BaseCustomer;
|
|
13308
13536
|
exports.BaseDataLinkTable = BaseDataLinkTable;
|
|
13309
13537
|
exports.BaseDataLinkTableInstance = BaseDataLinkTableInstance;
|
|
@@ -13338,6 +13566,8 @@ exports.CONNECTOR_EVENTS_DIR = CONNECTOR_EVENTS_DIR;
|
|
|
13338
13566
|
exports.CONNECTOR_GLOBAL_WEBHOOKS_DIR = CONNECTOR_GLOBAL_WEBHOOKS_DIR;
|
|
13339
13567
|
exports.CONNECTOR_METHOD_IMPLEMENTATION_SUFFIXES = CONNECTOR_METHOD_IMPLEMENTATION_SUFFIXES;
|
|
13340
13568
|
exports.CONNECTOR_OPERATIONS_DIR = CONNECTOR_OPERATIONS_DIR;
|
|
13569
|
+
exports.CONNECTOR_VERSION_DEVELOPMENT = CONNECTOR_VERSION_DEVELOPMENT;
|
|
13570
|
+
exports.CONNECTOR_VERSION_LATEST = CONNECTOR_VERSION_LATEST;
|
|
13341
13571
|
exports.CommonInstancesListQuery = CommonInstancesListQuery;
|
|
13342
13572
|
exports.CommonIntegrationOrConnectionQuery = CommonIntegrationOrConnectionQuery;
|
|
13343
13573
|
exports.CommonListElementsQuery = CommonListElementsQuery;
|
|
@@ -13363,12 +13593,38 @@ exports.ConnectionRequest = ConnectionRequest;
|
|
|
13363
13593
|
exports.ConnectionSelector = ConnectionSelector;
|
|
13364
13594
|
exports.ConnectionSpec = ConnectionSpec;
|
|
13365
13595
|
exports.ConnectionsAccessor = ConnectionsAccessor;
|
|
13596
|
+
exports.Connector = Connector;
|
|
13597
|
+
exports.ConnectorAuth = ConnectorAuth;
|
|
13598
|
+
exports.ConnectorAuthClientCredentials = ConnectorAuthClientCredentials;
|
|
13599
|
+
exports.ConnectorAuthHandlerBase = ConnectorAuthHandlerBase;
|
|
13600
|
+
exports.ConnectorAuthIntegrationAppToken = ConnectorAuthIntegrationAppToken;
|
|
13601
|
+
exports.ConnectorAuthMembraneToken = ConnectorAuthMembraneToken;
|
|
13366
13602
|
exports.ConnectorAuthMethodTypes = ConnectorAuthMethodTypes;
|
|
13603
|
+
exports.ConnectorAuthOAuth1 = ConnectorAuthOAuth1;
|
|
13604
|
+
exports.ConnectorAuthOAuth2 = ConnectorAuthOAuth2;
|
|
13605
|
+
exports.ConnectorAuthProxy = ConnectorAuthProxy;
|
|
13606
|
+
exports.ConnectorAuthSpec = ConnectorAuthSpec;
|
|
13367
13607
|
exports.ConnectorDataCollectionEventImplementationType = ConnectorDataCollectionEventImplementationType;
|
|
13368
13608
|
exports.ConnectorDataCollectionMethodKeys = ConnectorDataCollectionMethodKeys;
|
|
13369
13609
|
exports.ConnectorDataLocationTypes = ConnectorDataLocationTypes;
|
|
13370
13610
|
exports.ConnectorEventHandlerMethods = ConnectorEventHandlerMethods;
|
|
13611
|
+
exports.ConnectorMethodImplementation = ConnectorMethodImplementation;
|
|
13612
|
+
exports.ConnectorMethodImplementationBase = ConnectorMethodImplementationBase;
|
|
13613
|
+
exports.ConnectorMethodImplementationGraphqlApiMapping = ConnectorMethodImplementationGraphqlApiMapping;
|
|
13614
|
+
exports.ConnectorMethodImplementationJavascript = ConnectorMethodImplementationJavascript;
|
|
13615
|
+
exports.ConnectorMethodImplementationMapping = ConnectorMethodImplementationMapping;
|
|
13616
|
+
exports.ConnectorMethodImplementationNotSupported = ConnectorMethodImplementationNotSupported;
|
|
13617
|
+
exports.ConnectorMethodImplementationOperationMapping = ConnectorMethodImplementationOperationMapping;
|
|
13618
|
+
exports.ConnectorMethodImplementationRestApiMapping = ConnectorMethodImplementationRestApiMapping;
|
|
13371
13619
|
exports.ConnectorOperationMethodImplementationTypes = ConnectorOperationMethodImplementationTypes;
|
|
13620
|
+
exports.ConnectorSpec = ConnectorSpec;
|
|
13621
|
+
exports.ConnectorStatusValues = ConnectorStatusValues;
|
|
13622
|
+
exports.ConnectorUdmCollectionMapping = ConnectorUdmCollectionMapping;
|
|
13623
|
+
exports.ConnectorUdmListItem = ConnectorUdmListItem;
|
|
13624
|
+
exports.ConnectorUdmSpec = ConnectorUdmSpec;
|
|
13625
|
+
exports.ConnectorUiSpec = ConnectorUiSpec;
|
|
13626
|
+
exports.ConnectorVersion = ConnectorVersion;
|
|
13627
|
+
exports.ConnectorVersionData = ConnectorVersionData;
|
|
13372
13628
|
exports.CreateActionInstanceRequest = CreateActionInstanceRequest;
|
|
13373
13629
|
exports.CreateActionRequest = CreateActionRequest;
|
|
13374
13630
|
exports.CreateAgentSession = CreateAgentSession;
|
|
@@ -13436,6 +13692,7 @@ exports.DataLinkTableInstanceApiResponse = DataLinkTableInstanceApiResponse;
|
|
|
13436
13692
|
exports.DataLinkTableInstancesAccessor = DataLinkTableInstancesAccessor;
|
|
13437
13693
|
exports.DataLinkTablesAccessor = DataLinkTablesAccessor;
|
|
13438
13694
|
exports.DataLocationMethodImplementationTypes = DataLocationMethodImplementationTypes;
|
|
13695
|
+
exports.DataLocationPointer = DataLocationPointer;
|
|
13439
13696
|
exports.DataLocationTypeCollection = DataLocationTypeCollection;
|
|
13440
13697
|
exports.DataLocatorStep = DataLocatorStep;
|
|
13441
13698
|
exports.DataLocatorStepArrayItem = DataLocatorStepArrayItem;
|
|
@@ -13587,6 +13844,7 @@ exports.PackageExportProperties = PackageExportProperties;
|
|
|
13587
13844
|
exports.PackagesAccessor = PackagesAccessor;
|
|
13588
13845
|
exports.PaginationQuery = PaginationQuery;
|
|
13589
13846
|
exports.PaginationResponse = PaginationResponse;
|
|
13847
|
+
exports.PatchAgentSessionSchema = PatchAgentSessionSchema;
|
|
13590
13848
|
exports.PlatformUserSchema = PlatformUserSchema;
|
|
13591
13849
|
exports.RATE_LIMITS = RATE_LIMITS;
|
|
13592
13850
|
exports.RateLimitExceededError = RateLimitExceededError;
|
|
@@ -13623,6 +13881,7 @@ exports.WORKSPACE_SIZE_LIMITS = WORKSPACE_SIZE_LIMITS;
|
|
|
13623
13881
|
exports.WorkspaceElementSpecs = WorkspaceElementSpecs;
|
|
13624
13882
|
exports.WorkspaceLimitsSchema = WorkspaceLimitsSchema;
|
|
13625
13883
|
exports.WorkspacePublicKey = WorkspacePublicKey;
|
|
13884
|
+
exports.WritableConnectorVersionData = WritableConnectorVersionData;
|
|
13626
13885
|
exports.__resolveValue = __resolveValue;
|
|
13627
13886
|
exports.addRequiredFieldsToSchema = addRequiredFieldsToSchema;
|
|
13628
13887
|
exports.addUdmFallbackFields = addUdmFallbackFields;
|