@wix/create-app 0.0.201 → 0.0.203

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.
@@ -13,7 +13,7 @@ import {
13
13
  pathExists,
14
14
  require_is_git_url,
15
15
  require_lib
16
- } from "./chunk-IWAYBIJ2.js";
16
+ } from "./chunk-K4POCV53.js";
17
17
  import {
18
18
  __commonJS,
19
19
  __require,
@@ -3984,4 +3984,4 @@ ejs/lib/ejs.js:
3984
3984
  * @license {@link http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0}
3985
3985
  *)
3986
3986
  */
3987
- //# sourceMappingURL=generator-XLHVMQCA.js.map
3987
+ //# sourceMappingURL=generator-64M7WKXO.js.map
package/build/index.js CHANGED
@@ -99,7 +99,7 @@ import {
99
99
  setupTestEnv,
100
100
  writeJson,
101
101
  zod_default
102
- } from "./chunk-IWAYBIJ2.js";
102
+ } from "./chunk-K4POCV53.js";
103
103
  import {
104
104
  __commonJS,
105
105
  __dirname,
@@ -52423,6 +52423,9 @@ function getErrorComponent(code, cause) {
52423
52423
  }
52424
52424
  );
52425
52425
  },
52426
+ FailedToGetApp: () => {
52427
+ return () => /* @__PURE__ */ import_react77.default.createElement(SystemErrorMessage, { message: `Failed to fetch app configuration` });
52428
+ },
52426
52429
  FailedToConnectToLogsService: () => {
52427
52430
  return () => /* @__PURE__ */ import_react77.default.createElement(ErrorMessage, { message: `Failed to connect to logs service.` });
52428
52431
  },
@@ -53007,9 +53010,6 @@ ${errorMessage2}`
53007
53010
  FailedToGetUrl: () => {
53008
53011
  return () => /* @__PURE__ */ import_react77.default.createElement(SystemErrorMessage, { message: "Failed to get meta site URL." });
53009
53012
  },
53010
- FailedToUpdateExternalSiteUrl: () => {
53011
- return () => /* @__PURE__ */ import_react77.default.createElement(SystemErrorMessage, { message: "Failed to update external site URL." });
53012
- },
53013
53013
  FailedToGetGitHubOnboardingStatus: ({ projectId }) => {
53014
53014
  return () => /* @__PURE__ */ import_react77.default.createElement(
53015
53015
  SystemErrorMessage,
@@ -57958,7 +57958,7 @@ function reportCommandStartEvent({
57958
57958
  var package_default = {
57959
57959
  name: "@wix/create-app",
57960
57960
  description: "Create Wix apps",
57961
- version: "0.0.201",
57961
+ version: "0.0.203",
57962
57962
  author: "Ihor Machuzhak",
57963
57963
  bin: "bin/index.cjs",
57964
57964
  devDependencies: {
@@ -67170,7 +67170,16 @@ var appSecretsSchema = external_exports.object({
67170
67170
  webhookPublicKey: external_exports.string()
67171
67171
  });
67172
67172
  var appSchema = external_exports.object({
67173
- app: external_exports.object({
67173
+ id: external_exports.string(),
67174
+ name: external_exports.string(),
67175
+ namespace: external_exports.string().optional(),
67176
+ codeIdentifier: external_exports.string().optional()
67177
+ });
67178
+ var getAppSchema = external_exports.object({
67179
+ app: appSchema
67180
+ });
67181
+ var getAppWithSecretsSchema = external_exports.object({
67182
+ app: appSchema.extend({
67174
67183
  appSecrets: appSecretsSchema
67175
67184
  })
67176
67185
  });
@@ -67421,18 +67430,13 @@ var DevCenterClient = class {
67421
67430
  });
67422
67431
  }
67423
67432
  };
67424
- getAppSecret = async (req) => {
67433
+ getAppSecret = async ({ appId }) => {
67425
67434
  try {
67426
67435
  const { data } = await pRetry(
67427
- () => this.httpClient.request(
67428
- getApp({
67429
- withSecrets: true,
67430
- ...req
67431
- })
67432
- ),
67436
+ () => this.httpClient.request(getApp({ appId, withSecrets: true })),
67433
67437
  this.retryOptions
67434
67438
  );
67435
- return appSchema.parse(data).app.appSecrets;
67439
+ return getAppWithSecretsSchema.parse(data).app.appSecrets;
67436
67440
  } catch (e2) {
67437
67441
  if (isHttpError(e2) && e2.response?.status === 403 && isHttpApplicationError(e2) && e2.response.data.details.applicationError.code === "PERMISSION_DENIED") {
67438
67442
  throw new CliError({
@@ -67446,6 +67450,20 @@ var DevCenterClient = class {
67446
67450
  });
67447
67451
  }
67448
67452
  };
67453
+ getApp = async ({ appId }) => {
67454
+ try {
67455
+ const { data } = await pRetry(
67456
+ () => this.httpClient.request(getApp({ appId })),
67457
+ this.retryOptions
67458
+ );
67459
+ return getAppSchema.parse(data).app;
67460
+ } catch (e2) {
67461
+ throw new CliError({
67462
+ code: CliErrorCode.FailedToGetApp(),
67463
+ cause: e2
67464
+ });
67465
+ }
67466
+ };
67449
67467
  /**
67450
67468
  * This method is deprecated.
67451
67469
  */
@@ -67727,7 +67745,8 @@ var DevCenterClient = class {
67727
67745
  tenantType: V1TenantType.SITE
67728
67746
  },
67729
67747
  appInstance: {
67730
- appDefId: appId
67748
+ appDefId: appId,
67749
+ version: "latest"
67731
67750
  }
67732
67751
  })
67733
67752
  ),
@@ -68675,7 +68694,7 @@ function getTasks({
68675
68694
  cause: e2
68676
68695
  });
68677
68696
  }
68678
- const { generateApp } = await import("./generator-XLHVMQCA.js");
68697
+ const { generateApp } = await import("./generator-64M7WKXO.js");
68679
68698
  await generateApp({
68680
68699
  packageName,
68681
68700
  packageFolder,