@vtex/api 6.48.0 → 6.48.1-beta.2
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/gen/manifest.schema +2 -3
- package/lib/HttpClient/GraphQLClient.d.ts +1 -1
- package/lib/HttpClient/GraphQLClient.js +1 -0
- package/lib/HttpClient/HttpClient.d.ts +4 -3
- package/lib/HttpClient/HttpClient.js +15 -14
- package/lib/HttpClient/agents.d.ts +5 -2
- package/lib/HttpClient/agents.js +23 -4
- package/lib/HttpClient/index.js +22 -10
- package/lib/HttpClient/middlewares/cache.d.ts +1 -1
- package/lib/HttpClient/middlewares/cache.js +48 -42
- package/lib/HttpClient/middlewares/cancellationToken.d.ts +1 -1
- package/lib/HttpClient/middlewares/cancellationToken.js +3 -1
- package/lib/HttpClient/middlewares/inflight.d.ts +1 -1
- package/lib/HttpClient/middlewares/inflight.js +7 -3
- package/lib/HttpClient/middlewares/memoization.d.ts +1 -1
- package/lib/HttpClient/middlewares/memoization.js +10 -8
- package/lib/HttpClient/middlewares/metrics.js +13 -7
- package/lib/HttpClient/middlewares/notFound.d.ts +1 -1
- package/lib/HttpClient/middlewares/notFound.js +5 -2
- package/lib/HttpClient/middlewares/recorder.js +7 -1
- package/lib/HttpClient/middlewares/request/HttpAgentSingleton.js +2 -1
- package/lib/HttpClient/middlewares/request/index.d.ts +1 -1
- package/lib/HttpClient/middlewares/request/index.js +13 -9
- package/lib/HttpClient/middlewares/request/setupAxios/index.js +6 -4
- package/lib/HttpClient/middlewares/request/setupAxios/interceptors/exponentialBackoff.js +7 -5
- package/lib/HttpClient/middlewares/request/setupAxios/interceptors/index.js +4 -3
- package/lib/HttpClient/middlewares/request/setupAxios/interceptors/tracing/index.js +9 -6
- package/lib/HttpClient/middlewares/request/setupAxios/interceptors/tracing/spanSetup.js +10 -7
- package/lib/HttpClient/middlewares/tracing.js +16 -10
- package/lib/HttpClient/typings.d.ts +3 -3
- package/lib/HttpClient/typings.js +1 -0
- package/lib/caches/DiskCache.d.ts +1 -1
- package/lib/caches/DiskCache.js +3 -2
- package/lib/caches/LRUCache.d.ts +3 -3
- package/lib/caches/LRUCache.js +1 -0
- package/lib/caches/LRUDiskCache.d.ts +2 -2
- package/lib/caches/LRUDiskCache.js +3 -2
- package/lib/caches/MultilayeredCache.d.ts +2 -2
- package/lib/caches/MultilayeredCache.js +8 -7
- package/lib/caches/index.js +20 -7
- package/lib/caches/typings.d.ts +5 -5
- package/lib/clients/IOClient.d.ts +1 -1
- package/lib/clients/IOClient.js +1 -0
- package/lib/clients/IOClients.d.ts +1 -1
- package/lib/clients/IOClients.js +1 -0
- package/lib/clients/IOGraphQLClient.js +1 -0
- package/lib/clients/apps/AppClient.js +2 -1
- package/lib/clients/apps/AppGraphQLClient.js +2 -1
- package/lib/clients/apps/Billing.d.ts +1 -1
- package/lib/clients/apps/Billing.js +1 -0
- package/lib/clients/apps/Builder.d.ts +7 -7
- package/lib/clients/apps/Builder.js +2 -1
- package/lib/clients/apps/MessagesGraphQL.d.ts +1 -1
- package/lib/clients/apps/MessagesGraphQL.js +4 -3
- package/lib/clients/apps/Settings.js +4 -3
- package/lib/clients/apps/catalogGraphQL/brand.js +1 -0
- package/lib/clients/apps/catalogGraphQL/category.js +1 -0
- package/lib/clients/apps/catalogGraphQL/index.d.ts +4 -4
- package/lib/clients/apps/catalogGraphQL/index.js +5 -4
- package/lib/clients/apps/catalogGraphQL/product.js +1 -0
- package/lib/clients/apps/catalogGraphQL/sku.js +1 -0
- package/lib/clients/apps/index.js +21 -10
- package/lib/clients/external/ExternalClient.js +1 -0
- package/lib/clients/external/ID.d.ts +4 -4
- package/lib/clients/external/ID.js +1 -0
- package/lib/clients/external/Masterdata.js +1 -0
- package/lib/clients/external/PaymentProvider.d.ts +2 -2
- package/lib/clients/external/PaymentProvider.js +1 -0
- package/lib/clients/external/index.js +18 -7
- package/lib/clients/index.js +22 -10
- package/lib/clients/infra/Apps.d.ts +32 -27
- package/lib/clients/infra/Apps.js +19 -16
- package/lib/clients/infra/Assets.d.ts +6 -5
- package/lib/clients/infra/Assets.js +12 -11
- package/lib/clients/infra/BillingMetrics.d.ts +1 -1
- package/lib/clients/infra/BillingMetrics.js +1 -0
- package/lib/clients/infra/Events.d.ts +1 -1
- package/lib/clients/infra/Events.js +2 -1
- package/lib/clients/infra/Housekeeper.d.ts +3 -3
- package/lib/clients/infra/Housekeeper.js +1 -0
- package/lib/clients/infra/InfraClient.js +1 -0
- package/lib/clients/infra/Registry.d.ts +23 -17
- package/lib/clients/infra/Registry.js +5 -3
- package/lib/clients/infra/Router.d.ts +8 -8
- package/lib/clients/infra/Router.js +1 -0
- package/lib/clients/infra/Sphinx.d.ts +2 -2
- package/lib/clients/infra/Sphinx.js +1 -0
- package/lib/clients/infra/VBase.d.ts +15 -14
- package/lib/clients/infra/VBase.js +4 -3
- package/lib/clients/infra/Workspaces.d.ts +7 -7
- package/lib/clients/infra/Workspaces.js +1 -0
- package/lib/clients/infra/index.js +25 -14
- package/lib/clients/janus/JanusClient.d.ts +1 -1
- package/lib/clients/janus/JanusClient.js +1 -0
- package/lib/clients/janus/LicenseManager.js +2 -1
- package/lib/clients/janus/Segment.d.ts +3 -3
- package/lib/clients/janus/Segment.js +3 -2
- package/lib/clients/janus/Session.d.ts +2 -2
- package/lib/clients/janus/Session.js +1 -0
- package/lib/clients/janus/Tenant.d.ts +1 -1
- package/lib/clients/janus/Tenant.js +1 -0
- package/lib/clients/janus/index.js +19 -8
- package/lib/constants.d.ts +1 -1
- package/lib/constants.js +2 -1
- package/lib/errors/AuthenticationError.js +1 -0
- package/lib/errors/ForbiddenError.js +1 -0
- package/lib/errors/NotFoundError.js +1 -0
- package/lib/errors/RequestCancelledError.js +1 -0
- package/lib/errors/ResolverError.js +2 -1
- package/lib/errors/ResolverWarning.js +1 -0
- package/lib/errors/TooManyRequestsError.js +1 -0
- package/lib/errors/UserInputError.js +1 -0
- package/lib/errors/index.js +22 -11
- package/lib/index.js +31 -18
- package/lib/metrics/MetricsAccumulator.d.ts +2 -2
- package/lib/metrics/MetricsAccumulator.js +10 -9
- package/lib/responses.d.ts +4 -4
- package/lib/service/index.js +11 -6
- package/lib/service/loaders.js +9 -6
- package/lib/service/logger/console.js +8 -4
- package/lib/service/logger/index.js +16 -5
- package/lib/service/logger/logger.js +3 -2
- package/lib/service/logger/metricsLogger.js +11 -10
- package/lib/service/master.js +8 -6
- package/lib/service/metrics/requestMetricsMiddleware.d.ts +1 -1
- package/lib/service/metrics/requestMetricsMiddleware.js +15 -13
- package/lib/service/tracing/TracerSingleton.js +10 -9
- package/lib/service/tracing/metrics/MetricNames.js +13 -12
- package/lib/service/tracing/metrics/instruments.js +15 -7
- package/lib/service/tracing/metrics/measurers/EventLoopLagMeasurer.js +6 -5
- package/lib/service/tracing/tracingMiddlewares.d.ts +3 -3
- package/lib/service/tracing/tracingMiddlewares.js +25 -15
- package/lib/service/worker/index.js +25 -23
- package/lib/service/worker/listeners.js +3 -1
- package/lib/service/worker/runtime/Service.js +2 -1
- package/lib/service/worker/runtime/builtIn/handlers.d.ts +3 -3
- package/lib/service/worker/runtime/builtIn/handlers.js +7 -3
- package/lib/service/worker/runtime/builtIn/middlewares.d.ts +2 -2
- package/lib/service/worker/runtime/builtIn/middlewares.js +6 -3
- package/lib/service/worker/runtime/events/index.d.ts +2 -2
- package/lib/service/worker/runtime/events/index.js +12 -10
- package/lib/service/worker/runtime/events/middlewares/body.js +6 -2
- package/lib/service/worker/runtime/events/middlewares/context.js +2 -1
- package/lib/service/worker/runtime/events/router.d.ts +2 -2
- package/lib/service/worker/runtime/events/router.js +4 -2
- package/lib/service/worker/runtime/graphql/index.js +9 -7
- package/lib/service/worker/runtime/graphql/middlewares/context.js +1 -0
- package/lib/service/worker/runtime/graphql/middlewares/error.js +9 -5
- package/lib/service/worker/runtime/graphql/middlewares/query.d.ts +2 -1
- package/lib/service/worker/runtime/graphql/middlewares/query.js +8 -6
- package/lib/service/worker/runtime/graphql/middlewares/response.js +2 -1
- package/lib/service/worker/runtime/graphql/middlewares/run.d.ts +2 -2
- package/lib/service/worker/runtime/graphql/middlewares/run.js +4 -2
- package/lib/service/worker/runtime/graphql/middlewares/updateSchema.d.ts +2 -1
- package/lib/service/worker/runtime/graphql/middlewares/updateSchema.js +5 -3
- package/lib/service/worker/runtime/graphql/middlewares/upload.js +2 -1
- package/lib/service/worker/runtime/graphql/schema/index.d.ts +1 -1
- package/lib/service/worker/runtime/graphql/schema/index.js +9 -7
- package/lib/service/worker/runtime/graphql/schema/messagesLoaderV2.d.ts +2 -2
- package/lib/service/worker/runtime/graphql/schema/messagesLoaderV2.js +5 -3
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/Auth.js +2 -1
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/CacheControl.js +1 -0
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/Deprecated.js +2 -1
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/Metric.js +1 -0
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/Sanitize.js +1 -0
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/Settings.js +2 -1
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/SmartCacheDirective.js +1 -0
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/TranslatableV2.js +3 -2
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/TranslateTo.js +3 -2
- package/lib/service/worker/runtime/graphql/schema/schemaDirectives/index.js +3 -2
- package/lib/service/worker/runtime/graphql/schema/typeDefs/index.d.ts +2 -1
- package/lib/service/worker/runtime/graphql/schema/typeDefs/index.js +3 -1
- package/lib/service/worker/runtime/graphql/schema/typeDefs/ioUpload.js +1 -0
- package/lib/service/worker/runtime/graphql/schema/typeDefs/sanitizedString.js +3 -2
- package/lib/service/worker/runtime/graphql/typings.d.ts +3 -3
- package/lib/service/worker/runtime/graphql/utils/cacheControl.d.ts +2 -1
- package/lib/service/worker/runtime/graphql/utils/cacheControl.js +3 -1
- package/lib/service/worker/runtime/graphql/utils/error.d.ts +2 -1
- package/lib/service/worker/runtime/graphql/utils/error.js +11 -9
- package/lib/service/worker/runtime/graphql/utils/pathname.js +4 -2
- package/lib/service/worker/runtime/graphql/utils/translations.d.ts +1 -1
- package/lib/service/worker/runtime/graphql/utils/translations.js +8 -4
- package/lib/service/worker/runtime/http/index.d.ts +3 -3
- package/lib/service/worker/runtime/http/index.js +23 -20
- package/lib/service/worker/runtime/http/middlewares/authTokens.js +1 -0
- package/lib/service/worker/runtime/http/middlewares/cancellationToken.js +1 -0
- package/lib/service/worker/runtime/http/middlewares/clients.js +1 -0
- package/lib/service/worker/runtime/http/middlewares/context.js +8 -5
- package/lib/service/worker/runtime/http/middlewares/error.js +10 -6
- package/lib/service/worker/runtime/http/middlewares/rateLimit.js +2 -1
- package/lib/service/worker/runtime/http/middlewares/requestStats.js +1 -0
- package/lib/service/worker/runtime/http/middlewares/setCookie.js +6 -5
- package/lib/service/worker/runtime/http/middlewares/settings.d.ts +1 -1
- package/lib/service/worker/runtime/http/middlewares/settings.js +14 -9
- package/lib/service/worker/runtime/http/middlewares/timings.js +4 -3
- package/lib/service/worker/runtime/http/middlewares/vary.js +1 -0
- package/lib/service/worker/runtime/http/router.d.ts +1 -1
- package/lib/service/worker/runtime/http/router.js +4 -2
- package/lib/service/worker/runtime/http/routes.js +9 -5
- package/lib/service/worker/runtime/method.d.ts +2 -2
- package/lib/service/worker/runtime/method.js +2 -1
- package/lib/service/worker/runtime/statusTrack.d.ts +2 -2
- package/lib/service/worker/runtime/statusTrack.js +11 -5
- package/lib/service/worker/runtime/typings.d.ts +10 -10
- package/lib/service/worker/runtime/utils/compose.d.ts +3 -3
- package/lib/service/worker/runtime/utils/compose.js +5 -2
- package/lib/service/worker/runtime/utils/context.d.ts +4 -1
- package/lib/service/worker/runtime/utils/context.js +6 -4
- package/lib/service/worker/runtime/utils/diff.js +1 -0
- package/lib/service/worker/runtime/utils/recorder.js +2 -1
- package/lib/service/worker/runtime/utils/toArray.js +3 -1
- package/lib/service/worker/runtime/utils/tokenBucket.js +1 -0
- package/lib/tracing/Tags.js +2 -1
- package/lib/tracing/UserLandTracer.js +4 -2
- package/lib/tracing/errorReporting/ErrorReport.js +14 -13
- package/lib/tracing/index.js +10 -9
- package/lib/tracing/spanReference/SpanReferenceTypes.js +1 -0
- package/lib/tracing/spanReference/createSpanReference.js +1 -0
- package/lib/tracing/utils.js +6 -4
- package/lib/utils/MineWinsConflictsResolver.d.ts +4 -4
- package/lib/utils/MineWinsConflictsResolver.js +11 -10
- package/lib/utils/app.js +40 -23
- package/lib/utils/appsStaleIfError.d.ts +1 -0
- package/lib/utils/appsStaleIfError.js +33 -12
- package/lib/utils/billingOptions.js +3 -1
- package/lib/utils/binding.js +5 -2
- package/lib/utils/cancel.js +1 -0
- package/lib/utils/conflicts.mock.js +1 -0
- package/lib/utils/domain.js +2 -1
- package/lib/utils/error.js +6 -4
- package/lib/utils/index.js +23 -12
- package/lib/utils/json.js +1 -0
- package/lib/utils/log.js +4 -2
- package/lib/utils/message.js +9 -5
- package/lib/utils/renameBy.js +3 -1
- package/lib/utils/retry.js +10 -7
- package/lib/utils/status.js +3 -1
- package/lib/utils/tenant.js +5 -2
- package/lib/utils/throwOnGraphQLErrors.js +1 -0
- package/lib/utils/time.d.ts +3 -5
- package/lib/utils/time.js +24 -14
- package/package.json +4 -4
- package/CHANGELOG.md +0 -1858
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { IOContext } from '../service/worker/runtime/typings';
|
|
2
2
|
import { HttpClient } from '../HttpClient/HttpClient';
|
|
3
3
|
import { InstanceOptions } from '../HttpClient/typings';
|
|
4
|
-
export
|
|
4
|
+
export type IOClientConstructor = new (context: IOContext, options?: InstanceOptions) => IOClient;
|
|
5
5
|
/**
|
|
6
6
|
* A client that can be instantiated by the Serviceruntime layer.
|
|
7
7
|
*/
|
package/lib/clients/IOClient.js
CHANGED
|
@@ -6,7 +6,7 @@ import { ID, MasterData, PaymentProvider } from './external';
|
|
|
6
6
|
import { Apps, Assets, BillingMetrics, Events, Registry, Router, VBase, Workspaces } from './infra';
|
|
7
7
|
import { IOClientConstructor } from './IOClient';
|
|
8
8
|
import { LicenseManager, Segment, Session, TenantClient } from './janus';
|
|
9
|
-
export
|
|
9
|
+
export type ClientsImplementation<T extends IOClients> = new (clientOptions: Record<string, InstanceOptions>, ctx: IOContext) => T;
|
|
10
10
|
export declare class IOClients {
|
|
11
11
|
private clientOptions;
|
|
12
12
|
private ctx;
|
package/lib/clients/IOClients.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AppClient = void 0;
|
|
3
4
|
const typings_1 = require("../../HttpClient/typings");
|
|
4
5
|
const routes_1 = require("../../service/worker/runtime/http/routes");
|
|
5
6
|
const IOClient_1 = require("../IOClient");
|
|
@@ -16,7 +17,7 @@ class AppClient extends IOClient_1.IOClient {
|
|
|
16
17
|
let baseURL;
|
|
17
18
|
if (appVersion) {
|
|
18
19
|
const [major] = appVersion.split('.');
|
|
19
|
-
baseURL = routes_1.formatPrivateRoute({ account, workspace, vendor, name, major, protocol });
|
|
20
|
+
baseURL = (0, routes_1.formatPrivateRoute)({ account, workspace, vendor, name, major, protocol });
|
|
20
21
|
}
|
|
21
22
|
else {
|
|
22
23
|
console.warn(`${account} in ${workspace} is using old routing for ${app}. Please change vendor.app to vendor.app@major in client ${(options && options.name) || ''}`);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AppGraphQLClient = void 0;
|
|
3
4
|
const typings_1 = require("../../HttpClient/typings");
|
|
4
5
|
const routes_1 = require("../../service/worker/runtime/http/routes");
|
|
5
6
|
const IOGraphQLClient_1 = require("../IOGraphQLClient");
|
|
@@ -16,7 +17,7 @@ class AppGraphQLClient extends IOGraphQLClient_1.IOGraphQLClient {
|
|
|
16
17
|
let baseURL;
|
|
17
18
|
if (appVersion) {
|
|
18
19
|
const [major] = appVersion.split('.');
|
|
19
|
-
baseURL = routes_1.formatPrivateRoute({ account, workspace, major, name, vendor, protocol, path: '/_v/graphql' });
|
|
20
|
+
baseURL = (0, routes_1.formatPrivateRoute)({ account, workspace, major, name, vendor, protocol, path: '/_v/graphql' });
|
|
20
21
|
}
|
|
21
22
|
else {
|
|
22
23
|
console.warn(`${account} in ${workspace} is using old routing for ${app}. Please change vendor.app to vendor.app@major in client ${(options && options.name) || ''}`);
|
|
@@ -3,7 +3,7 @@ import { IOContext } from '../../service/worker/runtime/typings';
|
|
|
3
3
|
import { AppClient } from './AppClient';
|
|
4
4
|
export declare class Billing extends AppClient {
|
|
5
5
|
constructor(context: IOContext, options?: InstanceOptions);
|
|
6
|
-
status: (tracingConfig?: RequestTracingConfig
|
|
6
|
+
status: (tracingConfig?: RequestTracingConfig) => Promise<ContractStatus>;
|
|
7
7
|
}
|
|
8
8
|
export declare enum ContractStatus {
|
|
9
9
|
ACTIVE = "active_contract",
|
|
@@ -8,17 +8,17 @@ import { AppClient } from './AppClient';
|
|
|
8
8
|
export declare class Builder extends AppClient {
|
|
9
9
|
private stickyHost;
|
|
10
10
|
constructor(ioContext: IOContext, opts?: InstanceOptions);
|
|
11
|
-
availability: (app: string, hintIndex: number, tracingConfig?: RequestTracingConfig
|
|
11
|
+
availability: (app: string, hintIndex: number, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
12
12
|
host: string;
|
|
13
13
|
hostname: string | undefined;
|
|
14
14
|
score: number;
|
|
15
15
|
}>;
|
|
16
|
-
clean: (app: string, tracingConfig?: RequestTracingConfig
|
|
17
|
-
getPinnedDependencies: (tracingConfig?: RequestTracingConfig
|
|
18
|
-
linkApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig
|
|
19
|
-
publishApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig
|
|
20
|
-
relinkApp: (app: string, changes: Change[], params?: RequestParams, tracingConfig?: RequestTracingConfig
|
|
21
|
-
testApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig
|
|
16
|
+
clean: (app: string, tracingConfig?: RequestTracingConfig) => Promise<BuildResult>;
|
|
17
|
+
getPinnedDependencies: (tracingConfig?: RequestTracingConfig) => Promise<any>;
|
|
18
|
+
linkApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig) => Promise<BuildResult>;
|
|
19
|
+
publishApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig) => Promise<BuildResult>;
|
|
20
|
+
relinkApp: (app: string, changes: Change[], params?: RequestParams, tracingConfig?: RequestTracingConfig) => Promise<BuildResult>;
|
|
21
|
+
testApp: (app: string, files: File[], zipOptions?: ZipOptions, params?: RequestParams, tracingConfig?: RequestTracingConfig) => Promise<BuildResult>;
|
|
22
22
|
private zipAndSend;
|
|
23
23
|
}
|
|
24
24
|
interface RequestParams {
|
|
@@ -3,6 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.Builder = void 0;
|
|
6
7
|
const archiver_1 = __importDefault(require("archiver"));
|
|
7
8
|
const cache_1 = require("../../HttpClient/middlewares/cache");
|
|
8
9
|
const AppClient_1 = require("./AppClient");
|
|
@@ -82,7 +83,7 @@ class Builder extends AppClient_1.AppClient {
|
|
|
82
83
|
if (indexOfManifest === -1) {
|
|
83
84
|
throw new Error('No manifest.json file found in files.');
|
|
84
85
|
}
|
|
85
|
-
const zip = archiver_1.default('zip', { zlib });
|
|
86
|
+
const zip = (0, archiver_1.default)('zip', { zlib });
|
|
86
87
|
// Throw stream errors so they reject the promise chain.
|
|
87
88
|
zip.on('error', (e) => {
|
|
88
89
|
throw e;
|
|
@@ -5,7 +5,7 @@ export interface IndexedByFrom {
|
|
|
5
5
|
messages: Array<Omit<Message, 'from'>>;
|
|
6
6
|
from: string;
|
|
7
7
|
}
|
|
8
|
-
export
|
|
8
|
+
export type Behavior = 'FULL' | 'USER_ONLY' | 'USER_AND_APP';
|
|
9
9
|
export interface Message {
|
|
10
10
|
content: string;
|
|
11
11
|
context?: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MessagesGraphQL = void 0;
|
|
3
4
|
const ramda_1 = require("ramda");
|
|
4
5
|
const AppGraphQLClient_1 = require("./AppGraphQLClient");
|
|
5
6
|
const MAX_BATCH_SIZE = 500;
|
|
@@ -12,7 +13,7 @@ class MessagesGraphQL extends AppGraphQLClient_1.AppGraphQLClient {
|
|
|
12
13
|
const allMessages = indexedByFrom.reduce((acc, { from, messages }) => {
|
|
13
14
|
return acc.concat(messages.map(message => ({ from, message })));
|
|
14
15
|
}, []);
|
|
15
|
-
const batchedMessages = ramda_1.splitEvery(MAX_BATCH_SIZE, allMessages);
|
|
16
|
+
const batchedMessages = (0, ramda_1.splitEvery)(MAX_BATCH_SIZE, allMessages);
|
|
16
17
|
const metric = 'messages-translate-v2';
|
|
17
18
|
return Promise.all(batchedMessages.map(batch => {
|
|
18
19
|
const indexedBatch = batch.reduce((acc, { from, message }) => {
|
|
@@ -27,7 +28,7 @@ class MessagesGraphQL extends AppGraphQLClient_1.AppGraphQLClient {
|
|
|
27
28
|
}, {});
|
|
28
29
|
const batchArgs = {
|
|
29
30
|
...rest,
|
|
30
|
-
indexedByFrom: ramda_1.values(indexedBatch),
|
|
31
|
+
indexedByFrom: (0, ramda_1.values)(indexedBatch),
|
|
31
32
|
};
|
|
32
33
|
return this.graphql.query({
|
|
33
34
|
query: `
|
|
@@ -42,7 +43,7 @@ class MessagesGraphQL extends AppGraphQLClient_1.AppGraphQLClient {
|
|
|
42
43
|
requestSpanNameSuffix: metric,
|
|
43
44
|
...tracingConfig === null || tracingConfig === void 0 ? void 0 : tracingConfig.tracing,
|
|
44
45
|
},
|
|
45
|
-
}).then(ramda_1.path(['data', 'translate']));
|
|
46
|
+
}).then((0, ramda_1.path)(['data', 'translate']));
|
|
46
47
|
})).then(ramda_1.flatten);
|
|
47
48
|
}
|
|
48
49
|
async translate(args, tracingConfig) {
|
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Settings = void 0;
|
|
3
4
|
const ramda_1 = require("ramda");
|
|
4
5
|
const HttpClient_1 = require("../../HttpClient");
|
|
5
6
|
const settings_1 = require("../../service/worker/runtime/http/middlewares/settings");
|
|
6
7
|
const app_1 = require("../../utils/app");
|
|
7
8
|
const AppClient_1 = require("./AppClient");
|
|
8
9
|
const LINKED_ROUTE = 'linked';
|
|
9
|
-
const containsLinks = ramda_1.any(app_1.isLinkedApp);
|
|
10
|
+
const containsLinks = (0, ramda_1.any)(app_1.isLinkedApp);
|
|
10
11
|
class Settings extends AppClient_1.AppClient {
|
|
11
12
|
constructor(context, options) {
|
|
12
13
|
super('vtex.settings-server@0.x', context, options);
|
|
13
14
|
}
|
|
14
15
|
getFilteredDependencies(appAtMajor, dependencies) {
|
|
15
|
-
return settings_1.getFilteredDependencies(appAtMajor, dependencies);
|
|
16
|
+
return (0, settings_1.getFilteredDependencies)(appAtMajor, dependencies);
|
|
16
17
|
}
|
|
17
18
|
getDependenciesHash(dependencies) {
|
|
18
|
-
return settings_1.getDependenciesHash(dependencies);
|
|
19
|
+
return (0, settings_1.getDependenciesHash)(dependencies);
|
|
19
20
|
}
|
|
20
21
|
async getSettings(dependencies, appAtMajor, params, tracingConfig) {
|
|
21
22
|
const filtered = this.getFilteredDependencies(appAtMajor, dependencies);
|
|
@@ -7,16 +7,16 @@ import { Product } from './product';
|
|
|
7
7
|
import { SKU } from './sku';
|
|
8
8
|
export declare class CatalogGraphQL extends AppGraphQLClient {
|
|
9
9
|
constructor(ctx: IOContext, opts?: InstanceOptions);
|
|
10
|
-
sku: (id: string, tracingConfig?: RequestTracingConfig
|
|
10
|
+
sku: (id: string, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
11
11
|
sku: SKU;
|
|
12
12
|
} | undefined>;
|
|
13
|
-
product: (id: string, tracingConfig?: RequestTracingConfig
|
|
13
|
+
product: (id: string, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
14
14
|
product: Product;
|
|
15
15
|
} | undefined>;
|
|
16
|
-
category: (id: string, tracingConfig?: RequestTracingConfig
|
|
16
|
+
category: (id: string, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
17
17
|
category: Category;
|
|
18
18
|
} | undefined>;
|
|
19
|
-
brand: (id: string, tracingConfig?: RequestTracingConfig
|
|
19
|
+
brand: (id: string, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
20
20
|
brand: Brand;
|
|
21
21
|
} | undefined>;
|
|
22
22
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CatalogGraphQL = void 0;
|
|
3
4
|
const ramda_1 = require("ramda");
|
|
4
5
|
const __1 = require("..");
|
|
5
6
|
const brand_1 = require("./brand");
|
|
@@ -34,7 +35,7 @@ class CatalogGraphQL extends __1.AppGraphQLClient {
|
|
|
34
35
|
...tracingConfig === null || tracingConfig === void 0 ? void 0 : tracingConfig.tracing,
|
|
35
36
|
},
|
|
36
37
|
})
|
|
37
|
-
.then(ramda_1.prop('data'));
|
|
38
|
+
.then((0, ramda_1.prop)('data'));
|
|
38
39
|
};
|
|
39
40
|
this.product = (id, tracingConfig) => {
|
|
40
41
|
const variables = {
|
|
@@ -55,7 +56,7 @@ class CatalogGraphQL extends __1.AppGraphQLClient {
|
|
|
55
56
|
...tracingConfig === null || tracingConfig === void 0 ? void 0 : tracingConfig.tracing,
|
|
56
57
|
},
|
|
57
58
|
})
|
|
58
|
-
.then(ramda_1.prop('data'));
|
|
59
|
+
.then((0, ramda_1.prop)('data'));
|
|
59
60
|
};
|
|
60
61
|
this.category = (id, tracingConfig) => this.graphql
|
|
61
62
|
.query({
|
|
@@ -69,7 +70,7 @@ class CatalogGraphQL extends __1.AppGraphQLClient {
|
|
|
69
70
|
...tracingConfig === null || tracingConfig === void 0 ? void 0 : tracingConfig.tracing,
|
|
70
71
|
},
|
|
71
72
|
})
|
|
72
|
-
.then(ramda_1.prop('data'));
|
|
73
|
+
.then((0, ramda_1.prop)('data'));
|
|
73
74
|
this.brand = (id, tracingConfig) => this.graphql
|
|
74
75
|
.query({
|
|
75
76
|
inflight: true,
|
|
@@ -82,7 +83,7 @@ class CatalogGraphQL extends __1.AppGraphQLClient {
|
|
|
82
83
|
...tracingConfig === null || tracingConfig === void 0 ? void 0 : tracingConfig.tracing,
|
|
83
84
|
},
|
|
84
85
|
})
|
|
85
|
-
.then(ramda_1.prop('data'));
|
|
86
|
+
.then((0, ramda_1.prop)('data'));
|
|
86
87
|
}
|
|
87
88
|
}
|
|
88
89
|
exports.CatalogGraphQL = CatalogGraphQL;
|
|
@@ -1,12 +1,23 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
function
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
5
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
17
|
+
__exportStar(require("./AppClient"), exports);
|
|
18
|
+
__exportStar(require("./AppGraphQLClient"), exports);
|
|
19
|
+
__exportStar(require("./Billing"), exports);
|
|
20
|
+
__exportStar(require("./Builder"), exports);
|
|
21
|
+
__exportStar(require("./MessagesGraphQL"), exports);
|
|
22
|
+
__exportStar(require("./Settings"), exports);
|
|
23
|
+
__exportStar(require("./catalogGraphQL"), exports);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ExternalClient = void 0;
|
|
3
4
|
const IOClient_1 = require("../IOClient");
|
|
4
5
|
/**
|
|
5
6
|
* Used to perform calls to external endpoints for which you have declared outbound access policies in your manifest.
|
|
@@ -3,10 +3,10 @@ import { IOContext } from '../../service/worker/runtime/typings';
|
|
|
3
3
|
import { ExternalClient } from './ExternalClient';
|
|
4
4
|
export declare class ID extends ExternalClient {
|
|
5
5
|
constructor(context: IOContext, opts?: InstanceOptions);
|
|
6
|
-
getTemporaryToken: (tracingConfig?: RequestTracingConfig
|
|
7
|
-
sendCodeToEmail: (token: string, email: string, tracingConfig?: RequestTracingConfig
|
|
8
|
-
getEmailCodeAuthenticationToken: (token: string, email: string, code: string, tracingConfig?: RequestTracingConfig
|
|
9
|
-
getPasswordAuthenticationToken: (token: string, email: string, password: string, tracingConfig?: RequestTracingConfig
|
|
6
|
+
getTemporaryToken: (tracingConfig?: RequestTracingConfig) => Promise<string>;
|
|
7
|
+
sendCodeToEmail: (token: string, email: string, tracingConfig?: RequestTracingConfig) => Promise<any>;
|
|
8
|
+
getEmailCodeAuthenticationToken: (token: string, email: string, code: string, tracingConfig?: RequestTracingConfig) => Promise<AuthenticationResponse>;
|
|
9
|
+
getPasswordAuthenticationToken: (token: string, email: string, password: string, tracingConfig?: RequestTracingConfig) => Promise<AuthenticationResponse>;
|
|
10
10
|
}
|
|
11
11
|
export interface AuthenticationResponse {
|
|
12
12
|
promptMFA: boolean;
|
|
@@ -4,8 +4,8 @@ import { ExternalClient } from './ExternalClient';
|
|
|
4
4
|
export declare class PaymentProvider extends ExternalClient {
|
|
5
5
|
protected context: IOContext;
|
|
6
6
|
constructor(context: IOContext, options?: InstanceOptions);
|
|
7
|
-
callback: (transactionId: string, paymentId: string, callback: AuthorizationCallback, tracingConfig?: RequestTracingConfig
|
|
8
|
-
inbound: <TRequest, TResponse>(transactionId: string, paymentId: string, action: string, payload: TRequest, tracingConfig?: RequestTracingConfig
|
|
7
|
+
callback: (transactionId: string, paymentId: string, callback: AuthorizationCallback, tracingConfig?: RequestTracingConfig) => Promise<unknown>;
|
|
8
|
+
inbound: <TRequest, TResponse>(transactionId: string, paymentId: string, action: string, payload: TRequest, tracingConfig?: RequestTracingConfig) => Promise<TResponse>;
|
|
9
9
|
}
|
|
10
10
|
export interface AuthorizationCallback {
|
|
11
11
|
paymentId: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PaymentProvider = void 0;
|
|
3
4
|
const ExternalClient_1 = require("./ExternalClient");
|
|
4
5
|
const routes = {
|
|
5
6
|
callback: (transactionId, paymentId) => `${routes.payment(transactionId, paymentId)}/notification`,
|
|
@@ -1,9 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
function
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
5
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
17
|
+
__exportStar(require("./ExternalClient"), exports);
|
|
18
|
+
__exportStar(require("./ID"), exports);
|
|
19
|
+
__exportStar(require("./PaymentProvider"), exports);
|
|
20
|
+
__exportStar(require("./Masterdata"), exports);
|
package/lib/clients/index.js
CHANGED
|
@@ -1,17 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
function
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
5
16
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
6
17
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
7
18
|
};
|
|
8
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
20
|
+
exports.promclient = void 0;
|
|
21
|
+
__exportStar(require("./apps"), exports);
|
|
22
|
+
__exportStar(require("./external"), exports);
|
|
23
|
+
__exportStar(require("./infra"), exports);
|
|
24
|
+
__exportStar(require("./janus"), exports);
|
|
25
|
+
__exportStar(require("./IOClient"), exports);
|
|
26
|
+
__exportStar(require("./IOClients"), exports);
|
|
27
|
+
__exportStar(require("./IOGraphQLClient"), exports);
|
|
16
28
|
const prom_client_1 = __importDefault(require("prom-client"));
|
|
17
29
|
exports.promclient = prom_client_1.default;
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
+
/// <reference types="node" />
|
|
3
|
+
/// <reference types="node" />
|
|
4
|
+
/// <reference types="node" />
|
|
2
5
|
import { IncomingMessage } from 'http';
|
|
3
6
|
import { Readable, Writable } from 'stream';
|
|
4
7
|
import { ZlibOptions } from 'zlib';
|
|
5
8
|
import { InstanceOptions, RequestTracingConfig } from '../../HttpClient';
|
|
6
|
-
import {
|
|
9
|
+
import { AppFilesList, AppManifest } from '../../responses';
|
|
7
10
|
import { IOContext } from '../../service/worker/runtime/typings';
|
|
8
11
|
import { InfraClient } from './InfraClient';
|
|
9
12
|
export declare class Apps extends InfraClient {
|
|
@@ -12,35 +15,37 @@ export declare class Apps extends InfraClient {
|
|
|
12
15
|
private memoryCache;
|
|
13
16
|
private get routes();
|
|
14
17
|
constructor(context: IOContext, options?: InstanceOptions);
|
|
15
|
-
installApp: (descriptor: string, tracingConfig?: RequestTracingConfig
|
|
16
|
-
uninstallApp: (app: string, tracingConfig?: RequestTracingConfig
|
|
17
|
-
acknowledgeApp: (app: string, service: string, tracingConfig?: RequestTracingConfig
|
|
18
|
-
link: (app: string, files: Change[], { zlib }?: ZipOptions, tracingConfig?: RequestTracingConfig
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
installApp: (descriptor: string, tracingConfig?: RequestTracingConfig) => Promise<void> | Promise<AppInstallResponse>;
|
|
19
|
+
uninstallApp: (app: string, tracingConfig?: RequestTracingConfig) => Promise<import("../..").IOResponse<void>>;
|
|
20
|
+
acknowledgeApp: (app: string, service: string, tracingConfig?: RequestTracingConfig) => Promise<void>;
|
|
21
|
+
link: (app: string, files: Change[], { zlib }?: ZipOptions, tracingConfig?: RequestTracingConfig) => Promise<import("../..").AppBundleResponse & {
|
|
22
|
+
bundleSize?: number | undefined;
|
|
23
|
+
}>;
|
|
24
|
+
patch: (app: string, changes: Change[], { zlib }?: ZipOptions, tracingConfig?: RequestTracingConfig) => Promise<void>;
|
|
25
|
+
unlink: (app: string, tracingConfig?: RequestTracingConfig) => Promise<import("../..").IOResponse<void>>;
|
|
26
|
+
unlinkAll: (tracingConfig?: RequestTracingConfig) => Promise<import("../..").IOResponse<void>>;
|
|
27
|
+
saveAppSettings: (app: string, settings: any, tracingConfig?: RequestTracingConfig) => Promise<void>;
|
|
28
|
+
listApps: ({ oldVersion, since, service }?: ListAppsOptions, tracingConfig?: RequestTracingConfig) => Promise<AppsList>;
|
|
29
|
+
listAppFiles: (app: string, { prefix, nextMarker }?: ListFilesOptions, tracingConfig?: RequestTracingConfig) => Promise<AppFilesList>;
|
|
30
|
+
listLinks: (tracingConfig?: RequestTracingConfig) => Promise<string[]>;
|
|
31
|
+
getAppFile: (app: string, path: string, staleIfError?: boolean, tracingConfig?: RequestTracingConfig) => Promise<{
|
|
27
32
|
data: Buffer;
|
|
28
33
|
headers: any;
|
|
29
34
|
}>;
|
|
30
|
-
getAppJSON: <T extends object | null>(app: string, path: string, nullIfNotFound?: boolean
|
|
31
|
-
getFileFromApps: <T extends object | null>(app: string, path: string, nullIfNotFound?: boolean
|
|
32
|
-
getAppFileStream: (app: string, path: string, tracingConfig?: RequestTracingConfig
|
|
33
|
-
getApp: (app: string, tracingConfig?: RequestTracingConfig
|
|
34
|
-
getAppSettings: (app: string, tracingConfig?: RequestTracingConfig
|
|
35
|
-
getAllAppsSettings: (listAppsOptions?: ListAppsOptions, tracingConfig?: RequestTracingConfig
|
|
36
|
-
getAppBundle: (app: string, bundlePath: string, generatePackageJson: boolean, tracingConfig?: RequestTracingConfig
|
|
37
|
-
unpackAppBundle: (app: string, bundlePath: string, unpackPath: string, generatePackageJson: boolean, tracingConfig?: RequestTracingConfig
|
|
38
|
-
getAppsMetaInfos: (filter?: string
|
|
39
|
-
getDependencies: (filter?: string, tracingConfig?: RequestTracingConfig
|
|
40
|
-
updateDependencies: (tracingConfig?: RequestTracingConfig
|
|
41
|
-
updateDependency: (name: string, version: string, registry: string, tracingConfig?: RequestTracingConfig
|
|
42
|
-
resolveDependencies: (apps: string[], registries: string[], filter?: string, tracingConfig?: RequestTracingConfig
|
|
43
|
-
resolveDependenciesWithManifest: (manifest: AppManifest, filter?: string, tracingConfig?: RequestTracingConfig
|
|
35
|
+
getAppJSON: <T extends object | null>(app: string, path: string, nullIfNotFound?: boolean, tracingConfig?: RequestTracingConfig) => Promise<T>;
|
|
36
|
+
getFileFromApps: <T extends object | null>(app: string, path: string, nullIfNotFound?: boolean, tracingConfig?: RequestTracingConfig) => Promise<T>;
|
|
37
|
+
getAppFileStream: (app: string, path: string, tracingConfig?: RequestTracingConfig) => Promise<IncomingMessage>;
|
|
38
|
+
getApp: (app: string, tracingConfig?: RequestTracingConfig) => Promise<AppManifest>;
|
|
39
|
+
getAppSettings: (app: string, tracingConfig?: RequestTracingConfig) => Promise<any>;
|
|
40
|
+
getAllAppsSettings: (listAppsOptions?: ListAppsOptions, tracingConfig?: RequestTracingConfig) => Promise<AppsSettings>;
|
|
41
|
+
getAppBundle: (app: string, bundlePath: string, generatePackageJson: boolean, tracingConfig?: RequestTracingConfig) => Promise<Readable>;
|
|
42
|
+
unpackAppBundle: (app: string, bundlePath: string, unpackPath: string, generatePackageJson: boolean, tracingConfig?: RequestTracingConfig) => Promise<Writable>;
|
|
43
|
+
getAppsMetaInfos: (filter?: string, staleWhileRevalidate?: boolean, tracingConfig?: RequestTracingConfig) => Promise<AppMetaInfo[]>;
|
|
44
|
+
getDependencies: (filter?: string, tracingConfig?: RequestTracingConfig) => Promise<Record<string, string[]>>;
|
|
45
|
+
updateDependencies: (tracingConfig?: RequestTracingConfig) => Promise<Record<string, string[]>>;
|
|
46
|
+
updateDependency: (name: string, version: string, registry: string, tracingConfig?: RequestTracingConfig) => Promise<void>;
|
|
47
|
+
resolveDependencies: (apps: string[], registries: string[], filter?: string, tracingConfig?: RequestTracingConfig) => Promise<any>;
|
|
48
|
+
resolveDependenciesWithManifest: (manifest: AppManifest, filter?: string, tracingConfig?: RequestTracingConfig) => Promise<Record<string, string[]>>;
|
|
44
49
|
private installRuntime;
|
|
45
50
|
}
|
|
46
51
|
interface ZipOptions {
|