@membranehq/sdk 0.5.2 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.d.ts +1828 -1832
- package/dist/bundle.js +32 -23
- package/dist/bundle.js.map +1 -1
- package/dist/dts/accessors/action-instances-accessors.d.ts +13 -10
- package/dist/dts/accessors/actions-accessors.d.ts +9 -9
- package/dist/dts/accessors/app-data-schema-instances-accessors.d.ts +3 -3
- package/dist/dts/accessors/app-data-schemas-accessors.d.ts +3 -3
- package/dist/dts/accessors/app-event-subscriptions-accessors.d.ts +3 -3
- package/dist/dts/accessors/app-event-types-accessors.d.ts +3 -3
- package/dist/dts/accessors/base-accessors.d.ts +8 -8
- package/dist/dts/accessors/connections-accessors.d.ts +15 -15
- package/dist/dts/accessors/customers-accessors.d.ts +5 -5
- package/dist/dts/accessors/data-link-table-instances-accessors.d.ts +3 -3
- package/dist/dts/accessors/data-link-tables-accessors.d.ts +3 -3
- package/dist/dts/accessors/data-sources-accessors.d.ts +14 -14
- package/dist/dts/accessors/external-event-subscriptions-accessors.d.ts +3 -3
- package/dist/dts/accessors/field-mapping-instances-accessors.d.ts +7 -7
- package/dist/dts/accessors/field-mappings-accessors.d.ts +7 -7
- package/dist/dts/accessors/flow-instances-accessors.d.ts +8 -8
- package/dist/dts/accessors/flow-runs-accessors.d.ts +3 -3
- package/dist/dts/accessors/flows-accessors.d.ts +7 -7
- package/dist/dts/accessors/integrations-accessors.d.ts +10 -10
- package/dist/dts/accessors/scenarios-accessors.d.ts +3 -3
- package/dist/dts/accessors/screens-accessors.d.ts +3 -3
- package/dist/dts/api-client.d.ts +3 -3
- package/dist/dts/auth/accessors.d.ts +2 -2
- package/dist/dts/client.d.ts +5 -5
- package/dist/dts/data-builder/index.d.ts +1 -1
- package/dist/dts/data-schema/arbitrary-fields.test.d.ts +1 -0
- package/dist/dts/data-schema/types.d.ts +1 -0
- package/dist/dts/error-tools/index.d.ts +1 -1
- package/dist/dts/errors/index.d.ts +24 -15
- package/dist/dts/formulas/base.d.ts +3 -1
- package/dist/dts/index.d.ts +2 -1
- package/dist/dts/index.umd.d.ts +2 -2
- package/dist/dts/integration-elements/connection-level-element.accessor.d.ts +5 -5
- package/dist/dts/integration-elements/integration-level-element.accessor.d.ts +5 -5
- package/dist/dts/workspace-elements/api/action-instances-api.d.ts +119 -65
- package/dist/dts/workspace-elements/api/action-run-log-records-api.d.ts +69 -90
- package/dist/dts/workspace-elements/api/actions-api.d.ts +253 -339
- package/dist/dts/workspace-elements/api/app-data-schema-instances-api.d.ts +21 -21
- package/dist/dts/workspace-elements/api/app-data-schemas-api.d.ts +7 -7
- package/dist/dts/workspace-elements/api/app-event-log-records-api.d.ts +22 -22
- package/dist/dts/workspace-elements/api/app-event-subscriptions-api.d.ts +18 -18
- package/dist/dts/workspace-elements/api/app-event-types-api.d.ts +7 -7
- package/dist/dts/workspace-elements/api/connections-api.d.ts +90 -89
- package/dist/dts/workspace-elements/api/data-link-table-instances-api.d.ts +50 -50
- package/dist/dts/workspace-elements/api/data-link-tables-api.d.ts +7 -7
- package/dist/dts/workspace-elements/api/data-source-instances-api.d.ts +55 -55
- package/dist/dts/workspace-elements/api/data-sources-api.d.ts +62 -62
- package/dist/dts/workspace-elements/api/external-event-log-records-api.d.ts +40 -40
- package/dist/dts/workspace-elements/api/external-event-pulls-api.d.ts +40 -40
- package/dist/dts/workspace-elements/api/external-event-subscriptions-api.d.ts +35 -35
- package/dist/dts/workspace-elements/api/external-events-api.d.ts +20 -20
- package/dist/dts/workspace-elements/api/field-mapping-instances-api.d.ts +166 -166
- package/dist/dts/workspace-elements/api/field-mappings-api.d.ts +96 -96
- package/dist/dts/workspace-elements/api/flow-runs-api.d.ts +128 -128
- package/dist/dts/workspace-elements/api/flows-api.d.ts +223 -223
- package/dist/dts/workspace-elements/api/integrations-api.d.ts +26 -26
- package/dist/dts/workspace-elements/api/scenarios-api.d.ts +21 -21
- package/dist/dts/workspace-elements/base/action-instances/types.d.ts +10 -10
- package/dist/dts/workspace-elements/base/action-run-log-records/types.d.ts +4 -3
- package/dist/dts/workspace-elements/base/actions/index.d.ts +111 -1
- package/dist/dts/workspace-elements/base/app-data-schema-instances/types.d.ts +11 -10
- package/dist/dts/workspace-elements/base/app-data-schemas/types.d.ts +7 -7
- package/dist/dts/workspace-elements/base/app-event-subscriptions/types.d.ts +7 -7
- package/dist/dts/workspace-elements/base/app-event-types/types.d.ts +7 -7
- package/dist/dts/workspace-elements/base/connections/types.d.ts +11 -10
- package/dist/dts/workspace-elements/base/data-link-table-instances/types.d.ts +7 -7
- package/dist/dts/workspace-elements/base/data-link-tables/types.d.ts +7 -7
- package/dist/dts/workspace-elements/base/data-source-instances/types.d.ts +10 -9
- package/dist/dts/workspace-elements/base/data-sources/types.d.ts +8 -8
- package/dist/dts/workspace-elements/base/external-event-log-records/types.d.ts +4 -3
- package/dist/dts/workspace-elements/base/external-event-pulls/types.d.ts +4 -3
- package/dist/dts/workspace-elements/base/external-event-subscriptions/types.d.ts +4 -3
- package/dist/dts/workspace-elements/base/field-mapping-instances/types.d.ts +11 -10
- package/dist/dts/workspace-elements/base/field-mappings/types.d.ts +21 -21
- package/dist/dts/workspace-elements/base/flow-instances/schemas.d.ts +8 -8
- package/dist/dts/workspace-elements/base/flow-instances/types.d.ts +15 -14
- package/dist/dts/workspace-elements/base/flow-runs/flow-node-runs.d.ts +16 -16
- package/dist/dts/workspace-elements/base/flow-runs/types.d.ts +6 -5
- package/dist/dts/workspace-elements/base/flows/types.d.ts +15 -15
- package/dist/dts/workspace-elements/base/integrations/types.d.ts +48 -48
- package/dist/dts/workspace-elements/base/scenarios/types.d.ts +7 -7
- package/dist/dts/workspace-elements/errors.d.ts +2 -2
- package/dist/dts/workspace-elements/types.d.ts +53 -9
- package/dist/dts/workspace-elements-catalog/index.d.ts +3 -0
- package/dist/dts/workspaces/types.d.ts +2 -0
- package/dist/index.d.ts +2416 -2380
- package/dist/index.js +125 -118
- package/dist/index.js.map +1 -1
- package/dist/index.module.d.mts +2416 -2380
- package/dist/index.module.mjs +117 -113
- package/dist/index.module.mjs.map +1 -1
- package/package.json +1 -3
- package/dist/dts/workspace-elements/base/actions/types.d.ts +0 -85
package/dist/bundle.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
2
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
3
3
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
4
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.MembraneClient = factory());
|
|
5
5
|
})(this, (function () { 'use strict';
|
|
6
6
|
|
|
7
7
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -11271,7 +11271,7 @@
|
|
|
11271
11271
|
(function (ConcurrencyErrorKey) {
|
|
11272
11272
|
ConcurrencyErrorKey["LOCK_TIMEOUT"] = "lock_timeout";
|
|
11273
11273
|
})(ConcurrencyErrorKey || (ConcurrencyErrorKey = {}));
|
|
11274
|
-
const ErrorDataSchema = objectType({
|
|
11274
|
+
const ErrorDataSchema = lazyType(() => objectType({
|
|
11275
11275
|
type: nativeEnumType(ErrorType).optional(),
|
|
11276
11276
|
key: stringType().optional(),
|
|
11277
11277
|
message: stringType(),
|
|
@@ -11279,7 +11279,7 @@
|
|
|
11279
11279
|
stack: anyType().optional(),
|
|
11280
11280
|
causedByError: lazyType(() => ErrorDataSchema).optional(),
|
|
11281
11281
|
logs: arrayType(anyType()).optional(),
|
|
11282
|
-
});
|
|
11282
|
+
}));
|
|
11283
11283
|
class ErrorData {
|
|
11284
11284
|
constructor(arg) {
|
|
11285
11285
|
if (arg instanceof Error) {
|
|
@@ -11299,78 +11299,78 @@
|
|
|
11299
11299
|
}
|
|
11300
11300
|
}
|
|
11301
11301
|
}
|
|
11302
|
-
class
|
|
11302
|
+
class MembraneError extends Error {
|
|
11303
11303
|
constructor(arg) {
|
|
11304
11304
|
const errorData = new ErrorData(arg);
|
|
11305
11305
|
super(errorData.message);
|
|
11306
|
-
this.
|
|
11306
|
+
this.isMembraneError = true;
|
|
11307
11307
|
this.data = errorData;
|
|
11308
11308
|
if (!this.data.type) {
|
|
11309
11309
|
this.data.type = ErrorType.INTERNAL;
|
|
11310
11310
|
}
|
|
11311
11311
|
}
|
|
11312
11312
|
}
|
|
11313
|
-
class InternalError extends
|
|
11313
|
+
class InternalError extends MembraneError {
|
|
11314
11314
|
constructor(arg) {
|
|
11315
11315
|
super(arg);
|
|
11316
11316
|
this.data.type = ErrorType.INTERNAL;
|
|
11317
11317
|
}
|
|
11318
11318
|
}
|
|
11319
|
-
class BadRequestError extends
|
|
11319
|
+
class BadRequestError extends MembraneError {
|
|
11320
11320
|
constructor(arg) {
|
|
11321
11321
|
super(arg);
|
|
11322
11322
|
this.data.type = ErrorType.BAD_REQUEST;
|
|
11323
11323
|
}
|
|
11324
11324
|
}
|
|
11325
|
-
class ConcurrencyError extends
|
|
11325
|
+
class ConcurrencyError extends MembraneError {
|
|
11326
11326
|
constructor(arg) {
|
|
11327
11327
|
super(arg);
|
|
11328
11328
|
this.data.type = ErrorType.CONCURRENCY;
|
|
11329
11329
|
}
|
|
11330
11330
|
}
|
|
11331
|
-
class ConfigurationError extends
|
|
11331
|
+
class ConfigurationError extends MembraneError {
|
|
11332
11332
|
constructor(arg) {
|
|
11333
11333
|
super(arg);
|
|
11334
11334
|
this.data.type = ErrorType.CONFIGURATION;
|
|
11335
11335
|
}
|
|
11336
11336
|
}
|
|
11337
|
-
class FlowInstanceSetupError extends
|
|
11337
|
+
class FlowInstanceSetupError extends MembraneError {
|
|
11338
11338
|
constructor(arg) {
|
|
11339
11339
|
super(arg);
|
|
11340
11340
|
this.data.type = ErrorType.FLOW_INSTANCE_SETUP;
|
|
11341
11341
|
}
|
|
11342
11342
|
}
|
|
11343
|
-
class FlowRunError extends
|
|
11343
|
+
class FlowRunError extends MembraneError {
|
|
11344
11344
|
constructor(arg) {
|
|
11345
11345
|
super(arg);
|
|
11346
11346
|
this.data.type = ErrorType.FLOW_RUN;
|
|
11347
11347
|
}
|
|
11348
11348
|
}
|
|
11349
|
-
class ActionRunError extends
|
|
11349
|
+
class ActionRunError extends MembraneError {
|
|
11350
11350
|
constructor(arg) {
|
|
11351
11351
|
super(arg);
|
|
11352
11352
|
this.data.type = ErrorType.ACTION_RUN;
|
|
11353
11353
|
}
|
|
11354
11354
|
}
|
|
11355
|
-
class ActionInstanceSetupError extends
|
|
11355
|
+
class ActionInstanceSetupError extends MembraneError {
|
|
11356
11356
|
constructor(arg) {
|
|
11357
11357
|
super(arg);
|
|
11358
11358
|
this.data.type = ErrorType.ACTION_INSTANCE_SETUP;
|
|
11359
11359
|
}
|
|
11360
11360
|
}
|
|
11361
|
-
class UnitRunError extends
|
|
11361
|
+
class UnitRunError extends MembraneError {
|
|
11362
11362
|
constructor(arg) {
|
|
11363
11363
|
super(arg);
|
|
11364
11364
|
this.data.type = ErrorType.UNIT_RUN;
|
|
11365
11365
|
}
|
|
11366
11366
|
}
|
|
11367
|
-
class ConnectionError extends
|
|
11367
|
+
class ConnectionError extends MembraneError {
|
|
11368
11368
|
constructor(arg) {
|
|
11369
11369
|
super(arg);
|
|
11370
11370
|
this.data.type = ErrorType.CONNECTION;
|
|
11371
11371
|
}
|
|
11372
11372
|
}
|
|
11373
|
-
class CustomCodeError extends
|
|
11373
|
+
class CustomCodeError extends MembraneError {
|
|
11374
11374
|
constructor(arg) {
|
|
11375
11375
|
super(arg);
|
|
11376
11376
|
this.data.type = ErrorType.CUSTOM_CODE;
|
|
@@ -11609,18 +11609,23 @@
|
|
|
11609
11609
|
id: stringType(),
|
|
11610
11610
|
name: stringType(),
|
|
11611
11611
|
});
|
|
11612
|
-
|
|
11612
|
+
const BaseMembraneInterfaceEditableProperties = objectType({
|
|
11613
11613
|
key: stringType().optional(),
|
|
11614
|
+
name: stringType().optional(),
|
|
11614
11615
|
uuid: stringType().optional(),
|
|
11615
11616
|
description: stringType().optional(),
|
|
11617
|
+
});
|
|
11618
|
+
const BaseMembraneInterfaceReadOnlyProperties = objectType({
|
|
11619
|
+
name: stringType(),
|
|
11616
11620
|
state: nativeEnumType(WorkspaceElementState).optional(),
|
|
11617
11621
|
errors: arrayType(ErrorDataSchema).optional(),
|
|
11618
11622
|
revision: stringType().optional(),
|
|
11619
|
-
isDeactivated: booleanType().optional(),
|
|
11620
11623
|
createdAt: stringType().optional(),
|
|
11621
11624
|
updatedAt: stringType().optional(),
|
|
11622
11625
|
archivedAt: stringType().optional(),
|
|
11626
|
+
isDeactivated: booleanType().optional(),
|
|
11623
11627
|
});
|
|
11628
|
+
BaseWorkspaceElement.merge(BaseMembraneInterfaceEditableProperties).merge(BaseMembraneInterfaceReadOnlyProperties);
|
|
11624
11629
|
|
|
11625
11630
|
const MAX_POLLING_ERRORS = 10;
|
|
11626
11631
|
class FlowInstancesAccessor extends ElementInstanceListAccessor {
|
|
@@ -12118,7 +12123,7 @@
|
|
|
12118
12123
|
onResolve(message.connection);
|
|
12119
12124
|
}
|
|
12120
12125
|
if (message.type == 'newConnectionFailure') {
|
|
12121
|
-
const error = new
|
|
12126
|
+
const error = new MembraneError((_a = message.errorData) !== null && _a !== void 0 ? _a : message.error);
|
|
12122
12127
|
onReject(error);
|
|
12123
12128
|
}
|
|
12124
12129
|
onFinally();
|
|
@@ -16288,7 +16293,7 @@
|
|
|
16288
16293
|
LogRecordType["API"] = "api-request";
|
|
16289
16294
|
})(LogRecordType || (LogRecordType = {}));
|
|
16290
16295
|
|
|
16291
|
-
class DependencyError extends
|
|
16296
|
+
class DependencyError extends MembraneError {
|
|
16292
16297
|
constructor(arg, workspaceElementReference) {
|
|
16293
16298
|
super(arg);
|
|
16294
16299
|
this.data.type = ErrorType.DEPENDENCY_ERROR;
|
|
@@ -16358,7 +16363,7 @@
|
|
|
16358
16363
|
}
|
|
16359
16364
|
return payload;
|
|
16360
16365
|
}
|
|
16361
|
-
class
|
|
16366
|
+
class MembraneApiClient {
|
|
16362
16367
|
constructor({ uiUri, apiUri, accessToken, token, fetchToken, fetchCredentials, credentials, } = {}) {
|
|
16363
16368
|
this.apiUri = apiUri !== null && apiUri !== void 0 ? apiUri : DEFAULT_API_URI;
|
|
16364
16369
|
this.uiUri = uiUri !== null && uiUri !== void 0 ? uiUri : DEFAULT_UI_URI;
|
|
@@ -16473,7 +16478,7 @@
|
|
|
16473
16478
|
}
|
|
16474
16479
|
}
|
|
16475
16480
|
|
|
16476
|
-
class
|
|
16481
|
+
class MembraneClient extends MembraneApiClient {
|
|
16477
16482
|
constructor(options) {
|
|
16478
16483
|
super(options);
|
|
16479
16484
|
}
|
|
@@ -16623,7 +16628,11 @@
|
|
|
16623
16628
|
}
|
|
16624
16629
|
}
|
|
16625
16630
|
|
|
16626
|
-
return
|
|
16631
|
+
return MembraneClient;
|
|
16627
16632
|
|
|
16628
16633
|
}));
|
|
16634
|
+
// Backward compatibility alias
|
|
16635
|
+
if (typeof window !== "undefined" && window.MembraneClient) {
|
|
16636
|
+
window.IntegrationAppClient = window.MembraneClient;
|
|
16637
|
+
}
|
|
16629
16638
|
//# sourceMappingURL=bundle.js.map
|