@adobe/aio-commerce-lib-app 2.0.0 → 2.1.0-alpha-20260923164312
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/CHANGELOG.md +10 -0
- package/README.md +4 -0
- package/dist/cjs/actions/app-config/index.cjs +3 -3
- package/dist/cjs/actions/association/index.cjs +1 -1
- package/dist/cjs/actions/config/index.cjs +1 -1
- package/dist/cjs/actions/installation/index.cjs +4 -4
- package/dist/cjs/actions/scope-tree/index.cjs +4 -3
- package/dist/cjs/cli/index.cjs +447 -0
- package/dist/cjs/cli/index.d.cts +40 -0
- package/dist/cjs/commands/index.cjs +73 -1717
- package/dist/cjs/{common-VSsQEHDv.cjs → common-B3KrOG-h.cjs} +1 -1
- package/dist/cjs/config/index.node.cjs +3 -3
- package/dist/{es/logging-CXesop3u.mjs → cjs/constants-tQUzmimN.cjs} +6 -18
- package/dist/cjs/{index.node-vcOo1rt0.cjs → index.node-De5ENMF8.cjs} +2 -2
- package/dist/cjs/{logging-Br3xfBNe.cjs → logging-QTsrSwPc.cjs} +0 -16
- package/dist/cjs/management/index.cjs +1 -1
- package/dist/cjs/{management-Bki3hlxL.cjs → management-DplOGozL.cjs} +11 -10
- package/dist/cjs/{validate-CwWYtRsS.cjs → validate-DkmBVWFX.cjs} +1 -1
- package/dist/cjs/web-src-DvGBiJI5.cjs +1521 -0
- package/dist/cjs/{webhooks-Bcq2Qy7q.cjs → webhooks-zXjrg32x.cjs} +57 -57
- package/dist/es/actions/app-config/index.mjs +3 -3
- package/dist/es/actions/association/index.mjs +1 -1
- package/dist/es/actions/config/index.mjs +1 -1
- package/dist/es/actions/installation/index.mjs +4 -4
- package/dist/es/actions/scope-tree/index.mjs +3 -2
- package/dist/es/cli/index.d.mts +40 -0
- package/dist/es/cli/index.mjs +435 -0
- package/dist/es/commands/index.mjs +29 -1666
- package/dist/es/{common-dy6NrZt8.mjs → common-BWUDGasu.mjs} +1 -1
- package/dist/es/config/index.node.mjs +3 -3
- package/dist/es/constants-CSQsZaDP.mjs +25 -0
- package/dist/es/{index.node-CW46zuxW.mjs → index.node-C5D5IzSs.mjs} +2 -2
- package/dist/es/logging-DbJHXSKh.mjs +32 -0
- package/dist/es/management/index.mjs +1 -1
- package/dist/es/{management-DgwAhaaJ.mjs → management-YDkb15SJ.mjs} +6 -5
- package/dist/es/{validate-NzW1FQwL.mjs → validate-Pd7RIA_3.mjs} +1 -1
- package/dist/es/web-src-CLEUvMl7.mjs +1345 -0
- package/dist/es/{webhooks-CHZ1SXxw.mjs → webhooks-BMBfTqwi.mjs} +58 -58
- package/package.json +11 -1
- /package/dist/cjs/{commands/templates → templates}/admin-ui/tsconfig.json +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/.babelrc +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/index.css +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/index.html +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/src/app.jsx +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/src/components/welcome.jsx +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src/src/pages/main-page.jsx +0 -0
- /package/dist/cjs/{commands/templates → templates}/admin-ui/web-src-template.d.ts +0 -0
- /package/dist/cjs/{commands/templates → templates}/app-management/app-config.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/app-management/association.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/app-management/custom-scripts.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/app-management/installation.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/business-configuration/config.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/business-configuration/scope-tree.js.template +0 -0
- /package/dist/cjs/{commands/templates → templates}/typescript/webpack-config.cjs +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/tsconfig.json +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/.babelrc +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/index.css +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/index.html +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/src/app.jsx +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/src/components/welcome.jsx +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src/src/pages/main-page.jsx +0 -0
- /package/dist/es/{commands/templates → templates}/admin-ui/web-src-template.d.ts +0 -0
- /package/dist/es/{commands/templates → templates}/app-management/app-config.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/app-management/association.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/app-management/custom-scripts.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/app-management/installation.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/business-configuration/config.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/business-configuration/scope-tree.js.template +0 -0
- /package/dist/es/{commands/templates → templates}/typescript/webpack-config.cjs +0 -0
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* governing permissions and limitations under the License.
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
import { c as isCompletedState, d as isSucceededState, o as createRootInstallationStep } from "./management-
|
|
15
|
+
import { c as isCompletedState, d as isSucceededState, o as createRootInstallationStep } from "./management-YDkb15SJ.mjs";
|
|
16
16
|
import { init } from "@adobe/aio-lib-state";
|
|
17
17
|
import { getHeader } from "@adobe/aio-commerce-lib-core/headers";
|
|
18
18
|
import { noContent, ok } from "@adobe/aio-commerce-lib-core/responses";
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
* governing permissions and limitations under the License.
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
import { a as resolveCommerceAppConfig, i as readCommerceAppConfig, n as isTypeScriptConfig, r as parseCommerceAppConfig } from "../index.node-
|
|
15
|
+
import { a as resolveCommerceAppConfig, i as readCommerceAppConfig, n as isTypeScriptConfig, r as parseCommerceAppConfig } from "../index.node-C5D5IzSs.mjs";
|
|
16
|
+
import { a as hasEventing, c as hasAdminUi, d as hasCustomInstallation, f as hasCustomInstallationSteps, i as hasCommerceEvents, l as hasBackendUiV2Components, n as hasWebhooks, o as hasExternalEvents } from "../webhooks-BMBfTqwi.mjs";
|
|
17
|
+
import { a as CommerceAppConfigSchemas, c as hasMetadata, l as hasBusinessConfig, n as validateCommerceAppConfigDomain, o as getConfigDomains, s as hasConfigDomain, t as validateCommerceAppConfig, u as hasBusinessConfigSchema } from "../validate-Pd7RIA_3.mjs";
|
|
16
18
|
import { t as defineConfig } from "../define-Z_Glf1-_.mjs";
|
|
17
|
-
import { a as hasCustomInstallationSteps, c as hasEventing, d as hasAdminUi, f as hasBackendUiV2Components, i as hasCustomInstallation, l as hasExternalEvents, n as hasWebhooks, s as hasCommerceEvents } from "../webhooks-CHZ1SXxw.mjs";
|
|
18
|
-
import { a as CommerceAppConfigSchemas, c as hasMetadata, l as hasBusinessConfig, n as validateCommerceAppConfigDomain, o as getConfigDomains, s as hasConfigDomain, t as validateCommerceAppConfig, u as hasBusinessConfigSchema } from "../validate-NzW1FQwL.mjs";
|
|
19
19
|
|
|
20
20
|
export { CommerceAppConfigSchemas, defineConfig, getConfigDomains, hasAdminUi, hasBackendUiV2Components, hasBusinessConfig, hasBusinessConfigSchema, hasCommerceEvents, hasConfigDomain, hasCustomInstallation, hasCustomInstallationSteps, hasEventing, hasExternalEvents, hasMetadata, hasWebhooks, isTypeScriptConfig, parseCommerceAppConfig, readCommerceAppConfig, resolveCommerceAppConfig, validateCommerceAppConfig, validateCommerceAppConfigDomain };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2026 Adobe. All rights reserved.
|
|
5
|
+
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License. You may obtain a copy
|
|
7
|
+
* of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
*
|
|
9
|
+
* Unless required by applicable law or agreed to in writing, software distributed under
|
|
10
|
+
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
11
|
+
* OF ANY KIND, either express or implied. See the License for the specific language
|
|
12
|
+
* governing permissions and limitations under the License.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
//#region source/management/common/constants.ts
|
|
16
|
+
/**
|
|
17
|
+
* Timeout (in milliseconds) applied to Commerce HTTP clients used for
|
|
18
|
+
* long-running operations (e.g. lifecycle/installation steps, scope syncing).
|
|
19
|
+
* Commerce can take a while to respond to some of these, so we raise it well
|
|
20
|
+
* above the underlying client's default.
|
|
21
|
+
*/
|
|
22
|
+
const LIFECYCLE_HTTP_CLIENT_TIMEOUT_MS = 12e4;
|
|
23
|
+
|
|
24
|
+
//#endregion
|
|
25
|
+
export { LIFECYCLE_HTTP_CLIENT_TIMEOUT_MS as t };
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { t as stringifyError } from "./error-_RMwtrUA.mjs";
|
|
16
|
-
import { t as validateCommerceAppConfig } from "./validate-
|
|
16
|
+
import { t as validateCommerceAppConfig } from "./validate-Pd7RIA_3.mjs";
|
|
17
17
|
import { existsSync } from "fs";
|
|
18
|
-
import { access, mkdir, readFile } from "fs/promises";
|
|
19
18
|
import { basename, dirname, join, parse } from "path";
|
|
19
|
+
import { access, mkdir, readFile } from "fs/promises";
|
|
20
20
|
import NpmPackageJson from "@npmcli/package-json";
|
|
21
21
|
import { getPackageInfo } from "local-pkg";
|
|
22
22
|
import { resolveCommand } from "package-manager-detector";
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2026 Adobe. All rights reserved.
|
|
5
|
+
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License. You may obtain a copy
|
|
7
|
+
* of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
*
|
|
9
|
+
* Unless required by applicable law or agreed to in writing, software distributed under
|
|
10
|
+
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
11
|
+
* OF ANY KIND, either express or implied. See the License for the specific language
|
|
12
|
+
* governing permissions and limitations under the License.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import util from "util";
|
|
16
|
+
|
|
17
|
+
//#region ../../packages-private/common-utils/source/logging.ts
|
|
18
|
+
/**
|
|
19
|
+
* Shorthand to inspect an object.
|
|
20
|
+
*
|
|
21
|
+
* @param obj - The object to inspect.
|
|
22
|
+
* @returns A string representation of the object.
|
|
23
|
+
*/
|
|
24
|
+
function inspect(obj, params = {}) {
|
|
25
|
+
return util.inspect(obj, {
|
|
26
|
+
depth: null,
|
|
27
|
+
...params
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
//#endregion
|
|
32
|
+
export { inspect as t };
|
|
@@ -12,6 +12,6 @@
|
|
|
12
12
|
* governing permissions and limitations under the License.
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
import { a as runValidation, c as isCompletedState, d as isSucceededState, i as runUninstallation, l as isFailedState, n as createInitialUninstallationState, r as runInstallation, s as defineCustomInstallationStep, t as createInitialInstallationState, u as isInProgressState } from "../management-
|
|
15
|
+
import { a as runValidation, c as isCompletedState, d as isSucceededState, i as runUninstallation, l as isFailedState, n as createInitialUninstallationState, r as runInstallation, s as defineCustomInstallationStep, t as createInitialInstallationState, u as isInProgressState } from "../management-YDkb15SJ.mjs";
|
|
16
16
|
|
|
17
17
|
export { createInitialInstallationState, createInitialUninstallationState, defineCustomInstallationStep, isCompletedState, isFailedState, isInProgressState, isSucceededState, runInstallation, runUninstallation, runValidation };
|
|
@@ -13,19 +13,20 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { C as makeWorkspaceConfig, S as groupEventsByRuntimeActions, T as sanitizeEventingIdentifier, _ as getNamespacedEvent, a as eventCodeOf, b as getRegistrationName, c as findExistingRegistrations, d as generateInstanceIdDeprecated, f as getCommerceEventingConfigurationUpdateParams, g as getLegacyRegistrationName, h as getIoEventsExistingData, i as diffByKey, l as findExistingSubscription, m as getIoEventCode, n as EVENTS_STORAGE_KEY, o as findExistingProvider, p as getCommerceEventingExistingData, r as EXTERNAL_PROVIDER_TYPE, s as findExistingProviderMetadata, t as COMMERCE_PROVIDER_TYPE, u as generateInstanceId, v as getProviderKey, w as removeStoredEventProviders, x as getSubscriptionChangeKind, y as getRegistrationDescription } from "./utils-DgpVB4lT.mjs";
|
|
16
|
-
import { t as stringifyError } from "./error-_RMwtrUA.mjs";
|
|
17
16
|
import { a as parseOrThrow, i as getInstallCommerceEnv, t as appliesToEnv } from "./environment-C84BPRJZ.mjs";
|
|
18
|
-
import { a as
|
|
19
|
-
import {
|
|
17
|
+
import { a as hasEventing, c as hasAdminUi, f as hasCustomInstallationSteps, i as hasCommerceEvents, n as hasWebhooks, o as hasExternalEvents } from "./webhooks-BMBfTqwi.mjs";
|
|
18
|
+
import { t as LIFECYCLE_HTTP_CLIENT_TIMEOUT_MS } from "./constants-CSQsZaDP.mjs";
|
|
19
|
+
import { t as inspect } from "./logging-DbJHXSKh.mjs";
|
|
20
|
+
import { t as stringifyError } from "./error-_RMwtrUA.mjs";
|
|
20
21
|
import { resolveCommerceHttpClientParams, resolveIoEventsHttpClientParams } from "@adobe/aio-commerce-lib-api";
|
|
21
22
|
import { getSystemConfigByKey, setSystemConfigByKey } from "@adobe/aio-commerce-lib-config";
|
|
22
23
|
import { resolveImsAuthParams } from "@adobe/aio-commerce-lib-auth";
|
|
23
24
|
import stringify, { stringify as stringify$1 } from "safe-stable-stringify";
|
|
24
|
-
import * as v from "valibot";
|
|
25
|
-
import { createAdminUiApiClient } from "@adobe/aio-commerce-lib-admin-ui/api";
|
|
26
25
|
import { HTTPError } from "ky";
|
|
27
26
|
import { HTTP_NOT_FOUND, unwrapHttpError } from "@adobe/aio-commerce-lib-api/utils";
|
|
27
|
+
import * as v from "valibot";
|
|
28
28
|
import * as camelcaseModule from "camelcase";
|
|
29
|
+
import { createAdminUiApiClient } from "@adobe/aio-commerce-lib-admin-ui/api";
|
|
29
30
|
import { createCustomCommerceEventsApiClient, createEventProvider, createEventSubscription, deleteEventProvider, deleteEventSubscription, getAllEventProviders, getAllEventSubscriptions, updateEventSubscription, updateEventingConfiguration } from "@adobe/aio-commerce-lib-events/commerce";
|
|
30
31
|
import { createCustomAdobeIoEventsApiClient, createEventMetadataForProvider, createEventProvider as createEventProvider$1, createRegistration, deleteEventMetadataForProvider, deleteEventProvider as deleteEventProvider$1, deleteRegistration, getAllEventProviders as getAllEventProviders$1, getAllRegistrations, updateRegistration } from "@adobe/aio-commerce-lib-events/io-events";
|
|
31
32
|
import { createCustomCommerceWebhooksApiClient, getWebhookList, subscribeWebhook, unsubscribeWebhook } from "@adobe/aio-commerce-lib-webhooks/api";
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { t as alphaNumericOrHyphenSchema } from "./schemas-hRovglBF.mjs";
|
|
16
|
-
import {
|
|
16
|
+
import { c as hasAdminUi, d as hasCustomInstallation, f as hasCustomInstallationSteps, i as hasCommerceEvents, n as hasWebhooks, o as hasExternalEvents, r as EventingSchema, s as AdminUiSchema, t as WebhooksSchema, u as InstallationSchema } from "./webhooks-BMBfTqwi.mjs";
|
|
17
17
|
import { RecordedSchemaBusinessConfig, SchemaBusinessConfig } from "@adobe/aio-commerce-lib-config";
|
|
18
18
|
import { CommerceSdkValidationError } from "@adobe/aio-commerce-lib-core/error";
|
|
19
19
|
import * as v from "valibot";
|