@superwall/cli 2.5.0 → 2.5.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.
Files changed (103) hide show
  1. package/README.md +7 -0
  2. package/dist/{apple-Dyr7OFBx.js → apple-D2z3tALE.js} +14 -14
  3. package/dist/{approve-Czs1-JO9.js → approve-I-lvTanp.js} +35 -28
  4. package/dist/{assets-BrB9jQPQ.js → assets-oo93EFou.js} +3 -3
  5. package/dist/auth.d.ts +1 -1
  6. package/dist/auth.js +3 -3
  7. package/dist/{session-D3fgXQBt.js → base-Cft9NZfU.js} +35 -35
  8. package/dist/{billing-D5qqIlVb.js → billing-Bo1UEKqV.js} +3 -3
  9. package/dist/{bind-B3eEcRyp.js → bind-BvScWziR.js} +4 -4
  10. package/dist/{build-DD9pSwHX.js → build-Co487gha.js} +11 -9
  11. package/dist/{client-AI9H4GGB.js → client-Tp6iD66_.js} +55 -5
  12. package/dist/create-CHIPz5vb.js +20 -0
  13. package/dist/{create-ChfgWpiM.js → create-G3HuOHZ4.js} +31 -31
  14. package/dist/{create-B4m-IKlr.js → create-uA3nrMIa.js} +6 -6
  15. package/dist/design-lint-CiFc78aM.js +158 -0
  16. package/dist/{doctor-XtXW6tKE.js → doctor-CHF9aNFc.js} +6 -6
  17. package/dist/{drivers-CMEL13gp.js → drivers-YZEcBiSV.js} +3 -3
  18. package/dist/entry.js +20 -20
  19. package/dist/{environment-BWT2S4qC.js → environment-EU7Mrk7j.js} +3 -3
  20. package/dist/{existing-b0GxFcnc.js → existing-DV_6NLfW.js} +2 -2
  21. package/dist/{selection-BltBpyp5.js → framework-b-Yf8sP1.js} +50 -50
  22. package/dist/held-Dd19AduK.js +17 -0
  23. package/dist/{held-D3PUNky2.js → held-L0vz0_hA.js} +6 -6
  24. package/dist/install-CXfLcLhU.js +109 -0
  25. package/dist/{integrate-qvKd9pVW.js → integrate-DS2YGLsM.js} +23 -23
  26. package/dist/{types-JdxmnCko.js → lock-DgSx-p8Y.js} +79 -79
  27. package/dist/login-C0BjJmFy.js +17 -0
  28. package/dist/{login-PMoXUGqq.js → login-Ca6FhI6R.js} +6 -6
  29. package/dist/{login-COmGHrU5.js → login-DoMmU3Bq.js} +1 -1
  30. package/dist/{lookup-gjcKIZvh.js → lookup-DhMLZmdW.js} +3 -3
  31. package/dist/{migrate-SkkLLdmr.js → migrate-CoQWqzhJ.js} +29 -29
  32. package/dist/{migration-DS44-3Zr.js → migration-C22iQzAW.js} +29 -11
  33. package/dist/{notification-url-BjQPLf4-.js → notification-url-CqnXE9yB.js} +2 -2
  34. package/dist/{open-DQpm2yVs.js → open-DriuY3di.js} +2 -2
  35. package/dist/{org-C04eAO-j.js → org-D7LQrg3k.js} +3 -3
  36. package/dist/{organization-BOECL3vZ.js → organization-DDidaGRK.js} +8 -8
  37. package/dist/{orgs-D6Kk96mG.js → orgs-CYXjVdxM.js} +1 -1
  38. package/dist/{paths-REb-GrbX.js → paths-Bf3othB-.js} +1 -1
  39. package/dist/{playbook-Du4Oydbf.js → playbook-K7vmAUsu.js} +10 -10
  40. package/dist/{project-CP6hiHra.js → project-NoMtbMyl.js} +9 -9
  41. package/dist/{promote-Dm2_b1WK.js → promote-DXxxj4BU.js} +23 -22
  42. package/dist/pull-Bfa3_SBt.js +106 -0
  43. package/dist/pull-DGrlBSAG.js +36 -0
  44. package/dist/{pull-F6pvO4To.js → pull-DuFUkP7t.js} +8 -8
  45. package/dist/{push-D_l9KJZN.js → push-CrowxhpU.js} +54 -48
  46. package/dist/push-DPZdch2W.js +30 -0
  47. package/dist/push-DV-kJZdw.js +22 -0
  48. package/dist/{push-BIFLhAiO.js → push-Dk5x2xP3.js} +122 -22
  49. package/dist/{registry-DIJB0mJa.js → registry-HhZVRBqY.js} +178 -155
  50. package/dist/resolve-D3RBtfkI.js +242 -0
  51. package/dist/{resources-BaP3p_LY.js → resources-CkG6SCia.js} +2 -2
  52. package/dist/{run-C5OPwhvS.js → run-CL5ZnujW.js} +2 -2
  53. package/dist/{run-CgLmD2vR.js → run-Co8u_BkN.js} +93 -70
  54. package/dist/scan-BQmjhs3g.js +4 -0
  55. package/dist/{scan-Bj5y0zTZ.js → scan-DhmGH1rF.js} +1 -1
  56. package/dist/{scope-Bp_zwJOo.js → scope-D0XpYMn4.js} +5 -5
  57. package/dist/{scope-CCb_7UvN.js → scope-ehZ7L1nj.js} +25 -11
  58. package/dist/{sdk-TvT0p_nO.js → sdk-DEfQttek.js} +7 -7
  59. package/dist/{series-TAixFBWW.js → series-D2ZpZ8cx.js} +96 -63
  60. package/dist/server-4ZK_1Off.js +29 -0
  61. package/dist/{server-CdVIboQn.js → server-DamMN_ig.js} +9 -9
  62. package/dist/session-4F_YWSul.js +6 -0
  63. package/dist/{session-Ywim-P8M.js → session-G1uwJI8L.js} +1 -1
  64. package/dist/{setup-zzjtTy8k.js → setup-BFTSxEWU.js} +9 -9
  65. package/dist/skills/index.json +2 -2
  66. package/dist/skills/superwall/workflows/integrate/flutter.md +9 -7
  67. package/dist/skills/{superwall-workspaces → superwall-artifacts}/SKILL.md +47 -32
  68. package/dist/skills/{superwall-workspaces → superwall-artifacts}/references/cli.md +35 -29
  69. package/dist/skills/{superwall-workspaces → superwall-artifacts}/references/slots.md +9 -9
  70. package/dist/{skills-2qYaUXGE.js → skills-CE4c9eHX.js} +4 -4
  71. package/dist/{skills-8um2fBPS.js → skills-ClEVgXUB.js} +8 -8
  72. package/dist/{git-D7AVdugb.js → source-BccdO4aL.js} +111 -102
  73. package/dist/{source-push-kAep4gPe.js → source-push-EyF02ekO.js} +43 -26
  74. package/dist/{spinner-BANVLncC.js → spinner-mWZnJCkN.js} +3 -3
  75. package/dist/{starter-CiLrp1cN.js → starter-BtUUQWhd.js} +38 -28
  76. package/dist/{status-CoYMK7QL.js → status-SAZxltzW.js} +42 -39
  77. package/dist/{storage-DzP22xKn.js → storage-R5-qDvHq.js} +1 -1
  78. package/dist/{storekit-n1x0bWkQ.js → storekit-CQHVFTOC.js} +3 -3
  79. package/dist/storekit-DK3xXKoY.js +17 -0
  80. package/dist/{telemetry-CXN6f-ZX.js → telemetry-B-uKuu49.js} +1 -1
  81. package/dist/{token-FmeHywYt.js → token-C2kzntVM.js} +1 -1
  82. package/dist/tools.d.ts +6 -1
  83. package/dist/tools.js +208 -130
  84. package/dist/{try-BWbzgelb.js → try-BrJJyXgq.js} +32 -32
  85. package/dist/{upgrade-CoWCEnoi.js → upgrade-g_Bd9oJe.js} +2 -2
  86. package/dist/{upgrade-Bk5boOgW.js → upgrade-zOXTIaAZ.js} +2 -2
  87. package/package.json +2 -2
  88. package/dist/create-CJljlkJK.js +0 -20
  89. package/dist/held-CX7Zf8u-.js +0 -17
  90. package/dist/install-CVUXsx8c.js +0 -103
  91. package/dist/login-ClnJi1Ea.js +0 -17
  92. package/dist/pull-DsdOoG-D.js +0 -36
  93. package/dist/pull-zYAbqo9n.js +0 -106
  94. package/dist/push-CJVfvFZq.js +0 -29
  95. package/dist/push-SVzv7fzE.js +0 -22
  96. package/dist/resolve--GsHj0Q1.js +0 -171
  97. package/dist/scan-v_WTE722.js +0 -4
  98. package/dist/server-CvJVusw3.js +0 -29
  99. package/dist/session-B8JNXkwN.js +0 -6
  100. package/dist/storekit-D5eopLM0.js +0 -17
  101. /package/dist/{download-2Zu2I_Og.js → download-DhGd4hOB.js} +0 -0
  102. /package/dist/{reports-CuhB1_ub.js → reports-HYVp169R.js} +0 -0
  103. /package/dist/{storage-BjQCiTuz.d.ts → storage-Bdz5AmqS.d.ts} +0 -0
@@ -1,22 +1,23 @@
1
+ import { r as NotLoggedInError } from "./token-C2kzntVM.js";
1
2
  import { a as stripAnsi, l as readJson, o as cache, r as formatJson, t as blocks } from "./output-Ggzq5_-t.js";
2
- import { o as AUTO_UPDATE_TARGET, s as CHANNEL, t as API_HOST, v as TELEMETRY_HOST, w as detectAgent, x as VERSION, y as TELEMETRY_KEY } from "./environment-BWT2S4qC.js";
3
- import { n as readSession } from "./storage-DzP22xKn.js";
4
- import { a as withQuery$1, t as ApiError } from "./client-AI9H4GGB.js";
5
- import { C as listKeySources, S as listBundleIdSuggestions, T as replaceRevenueProvider, _ as checkServerNotifications, b as importAppKey, c as resolveAscOrgApi, d as runAscDocs, f as parseParams, h as REVENUE_INTEGRATIONS, i as savedKey, l as resolveAscTeam, m as KEY_LABEL, n as testModeWarning, p as KEY_KINDS, r as chooseKeyApp, t as upsertHeldKey, u as sendAscRequest, v as copyAppKey, w as removeAppKey, x as keyKind, y as findIntegrations } from "./held-D3PUNky2.js";
3
+ import { o as AUTO_UPDATE_TARGET, s as CHANNEL, t as API_HOST, v as TELEMETRY_HOST, w as detectAgent, x as VERSION, y as TELEMETRY_KEY } from "./environment-EU7Mrk7j.js";
4
+ import { n as readSession } from "./storage-R5-qDvHq.js";
5
+ import { a as withQuery$1, n as ApiUnreachableError, t as ApiError } from "./client-Tp6iD66_.js";
6
+ import { C as listKeySources, S as listBundleIdSuggestions, T as replaceRevenueProvider, _ as checkServerNotifications, b as importAppKey, c as resolveAscOrgApi, d as runAscDocs, f as parseParams, h as REVENUE_INTEGRATIONS, i as savedKey, l as resolveAscTeam, m as KEY_LABEL, n as testModeWarning, p as KEY_KINDS, r as chooseKeyApp, t as upsertHeldKey, u as sendAscRequest, v as copyAppKey, w as removeAppKey, x as keyKind, y as findIntegrations } from "./held-L0vz0_hA.js";
6
7
  import { f as writeDefaultApp, i as readOnboardedApp, r as readDefaultApp, t as readAnonymousId } from "./config-CGcG7GOt.js";
7
- import { a as defineCommand, d as readInput, i as defineCatalog, r as UsageError, t as apiCall } from "./spinner-BANVLncC.js";
8
+ import { a as defineCommand, d as readInput, i as defineCatalog, r as UsageError, t as apiCall } from "./spinner-mWZnJCkN.js";
8
9
  import { n as fg, t as THEME } from "./theme-DUsCh-Vd.js";
9
- import { n as runWhoami } from "./session-Ywim-P8M.js";
10
- import { i as orgIdOf, t as listOrgGroups } from "./orgs-D6Kk96mG.js";
11
- import { M as textField, O as field, T as rowName, a as createEntitlement, c as createProject, h as listResource, i as createCampaign, j as parseJson, k as isRecord, m as listProjects, r as createApplication, s as createProduct, t as RESOURCES, u as isAppScoped, y as platformLabel } from "./resources-BaP3p_LY.js";
12
- import { n as orgForNewProject } from "./org-C04eAO-j.js";
13
- import { i as parseDashboardUrl, n as findApplication, r as findProject, t as appNotFound } from "./lookup-gjcKIZvh.js";
14
- import { a as pickScope, i as pickProject, n as chooseApp, r as pickOrganization, t as boundOrganization } from "./scope-Bp_zwJOo.js";
10
+ import { n as runWhoami } from "./session-G1uwJI8L.js";
11
+ import { i as orgIdOf, t as listOrgGroups } from "./orgs-CYXjVdxM.js";
12
+ import { M as textField, O as field, T as rowName, a as createEntitlement, c as createProject, h as listResource, i as createCampaign, j as parseJson, k as isRecord, m as listProjects, r as createApplication, s as createProduct, t as RESOURCES, u as isAppScoped, y as platformLabel } from "./resources-CkG6SCia.js";
13
+ import { n as orgForNewProject } from "./org-D7LQrg3k.js";
14
+ import { i as parseDashboardUrl, n as findApplication, r as findProject, t as appNotFound } from "./lookup-DhMLZmdW.js";
15
+ import { a as pickScope, i as pickProject, n as chooseApp, r as pickOrganization, t as boundOrganization } from "./scope-D0XpYMn4.js";
15
16
  import { a as listAscConfigs, i as findAppNotificationUrl, o as removeAscConfig, t as ascProxy } from "./client-BJQXl62Q.js";
16
17
  import { i as listUnimportedAscProducts, n as findAscAppId, r as listAscApps, t as ascTypeDisplay } from "./products-Cqq59DBQ.js";
17
18
  import { n as readResourceFlags, r as textOf, t as fieldName } from "./input-MDd67UIp.js";
18
- import { a as runAscNotificationUrlSet, i as printServerNotifications, t as describeNotificationUrl } from "./notification-url-BjQPLf4-.js";
19
- import { t as platformForIntegration } from "./bind-B3eEcRyp.js";
19
+ import { a as runAscNotificationUrlSet, i as printServerNotifications, t as describeNotificationUrl } from "./notification-url-CqnXE9yB.js";
20
+ import { t as platformForIntegration } from "./bind-BvScWziR.js";
20
21
  import pc from "picocolors";
21
22
 
22
23
  //#region src/ui/help-layout.ts
@@ -143,7 +144,7 @@ const command = defineCommand({
143
144
  prompts: true,
144
145
  mcp: false,
145
146
  async run(ctx, input) {
146
- const { runLogin } = await import("./login-ClnJi1Ea.js");
147
+ const { runLogin } = await import("./login-C0BjJmFy.js");
147
148
  return runLogin(ctx, input);
148
149
  }
149
150
  });
@@ -159,7 +160,7 @@ const command$1 = defineCommand({
159
160
  prompts: true,
160
161
  mcp: false,
161
162
  async run(ctx) {
162
- const { runLogout } = await import("./session-B8JNXkwN.js");
163
+ const { runLogout } = await import("./session-4F_YWSul.js");
163
164
  return runLogout(ctx);
164
165
  }
165
166
  });
@@ -219,15 +220,15 @@ const team = {
219
220
  value: "id",
220
221
  describe: "The Apple team, when your organization has several"
221
222
  };
222
- const workspace = {
223
+ const artifact = {
223
224
  type: "string",
224
- value: "workspace",
225
- describe: "The workspace: an id, or a slug with --org (default: this project's)"
225
+ value: "artifact",
226
+ describe: "The artifact: an id, or a slug with --org (default: this project's)"
226
227
  };
227
228
  const projectDir = {
228
229
  type: "string",
229
230
  value: "path",
230
- describe: "The workspace project (default: cwd)"
231
+ describe: "The artifact project (default: cwd)"
231
232
  };
232
233
 
233
234
  //#endregion
@@ -595,10 +596,12 @@ async function runApiRequest(ctx, api, request) {
595
596
  }
596
597
  }).catch(async (error) => {
597
598
  if (!(error instanceof ApiError) || error.status >= 500 || error.status === 401) throw error;
599
+ if (namesMissingResource(error)) throw error;
598
600
  throw new Error(`${error.message}\n${await resolveReferenceHint(verb, path)}`, { cause: error });
599
601
  });
600
602
  ctx.output.data(res ?? { ok: true });
601
603
  }
604
+ const namesMissingResource = ({ status, detail }) => status === 404 && (detail.code === "resource_missing" || detail.type === "resource_missing" || detail.resourceType !== void 0);
602
605
  async function resolveReferenceHint(verb, path) {
603
606
  const index = await resolveApiIndex().catch(() => void 0);
604
607
  if (!index) return "The API reference: superwall api docs <words>";
@@ -3480,7 +3483,7 @@ A purchase_key is for the app's bundle ID; an app with none gets --bundle-id sav
3480
3483
  prompts: true,
3481
3484
  mcp: false,
3482
3485
  async run(ctx, input) {
3483
- const { runAscKeysCreate } = await import("./create-CJljlkJK.js");
3486
+ const { runAscKeysCreate } = await import("./create-CHIPz5vb.js");
3484
3487
  return runAscKeysCreate(ctx, input);
3485
3488
  }
3486
3489
  });
@@ -3867,7 +3870,7 @@ With --app it saves the key you hold on that app instead, as asc keys create --k
3867
3870
  prompts: true,
3868
3871
  mcp: false,
3869
3872
  async run(ctx, { args, flags }) {
3870
- const { upsertHeldKey: upsertHeldKey$1 } = await import("./held-CX7Zf8u-.js");
3873
+ const { upsertHeldKey: upsertHeldKey$1 } = await import("./held-Dd19AduK.js");
3871
3874
  return upsertHeldKey$1(ctx, {
3872
3875
  action: "update",
3873
3876
  key: {
@@ -5119,7 +5122,7 @@ Exit codes
5119
5122
  prompts: true,
5120
5123
  mcp: false,
5121
5124
  async run(ctx, input) {
5122
- const { runSetupApple } = await import("./apple-Dyr7OFBx.js");
5125
+ const { runSetupApple } = await import("./apple-D2z3tALE.js");
5123
5126
  return runSetupApple(ctx, input);
5124
5127
  }
5125
5128
  });
@@ -7750,7 +7753,7 @@ const command$45 = defineCommand({
7750
7753
  prompts: true,
7751
7754
  mcp: false,
7752
7755
  async run(ctx, { args, flags }) {
7753
- const { runBuildPipeline } = await import("./build-DD9pSwHX.js");
7756
+ const { runBuildPipeline } = await import("./build-Co487gha.js");
7754
7757
  await runBuildPipeline({
7755
7758
  output: ctx.output,
7756
7759
  json: ctx.json
@@ -7811,7 +7814,7 @@ const command$46 = defineCommand({
7811
7814
  prompts: true,
7812
7815
  mcp: false,
7813
7816
  async run(ctx, { args, flags }) {
7814
- const { runCreate } = await import("./create-ChfgWpiM.js");
7817
+ const { runCreate } = await import("./create-G3HuOHZ4.js");
7815
7818
  return runCreate(ctx, {
7816
7819
  dir: args.dir,
7817
7820
  ...flags
@@ -7854,7 +7857,7 @@ const command$47 = defineCommand({
7854
7857
  prompts: true,
7855
7858
  mcp: false,
7856
7859
  async run(ctx, { args, flags }) {
7857
- const { runStudio } = await import("./server-CvJVusw3.js");
7860
+ const { runStudio } = await import("./server-4ZK_1Off.js");
7858
7861
  await runStudio({
7859
7862
  dirs: args.dir,
7860
7863
  port: flags.port,
@@ -7894,7 +7897,7 @@ const command$48 = defineCommand({
7894
7897
  prompts: true,
7895
7898
  mcp: false,
7896
7899
  async run(ctx, input) {
7897
- const { runPromote } = await import("./promote-Dm2_b1WK.js");
7900
+ const { runPromote } = await import("./promote-DXxxj4BU.js");
7898
7901
  return runPromote(ctx, input);
7899
7902
  }
7900
7903
  });
@@ -7930,15 +7933,27 @@ const command$49 = defineCommand({
7930
7933
  overwriteSource: {
7931
7934
  type: "boolean",
7932
7935
  describe: "Replace the pushed paywalls' source in the app's repo with yours even though it can't be merged - other paywalls and funnels stay"
7936
+ },
7937
+ existing: {
7938
+ type: "boolean",
7939
+ describe: "Only paywalls already on Superwall - skip any not in superwall.lock instead of creating them"
7940
+ },
7941
+ source: {
7942
+ type: "boolean",
7943
+ describe: "Push the project source to every app, also those whose paywalls did not change (shared files such as the design system)"
7933
7944
  }
7934
7945
  },
7935
- examples: [["publish", "Push every changed paywall and funnel and make it live"], ["publish --id plus-upgrade --platform ios -m \"New annual price\"", "Ship one paywall on one platform and record why"]],
7946
+ examples: [
7947
+ ["publish", "Push every changed paywall and funnel and make it live"],
7948
+ ["publish --id plus-upgrade --platform ios -m \"New annual price\"", "Ship one paywall on one platform and record why"],
7949
+ ["publish --existing --source -m \"Rounder corners\"", "Ship a design-system change: every paywall already on Superwall that it rebuilds, and every app's source"]
7950
+ ],
7936
7951
  auth: "none",
7937
7952
  json: false,
7938
7953
  prompts: true,
7939
7954
  mcp: false,
7940
7955
  async run(ctx, input) {
7941
- const { runPush } = await import("./push-CJVfvFZq.js");
7956
+ const { runPush } = await import("./push-DPZdch2W.js");
7942
7957
  return runPush(ctx, input, true);
7943
7958
  }
7944
7959
  });
@@ -7974,7 +7989,7 @@ const command$50 = defineCommand({
7974
7989
  prompts: true,
7975
7990
  mcp: false,
7976
7991
  async run(ctx, input) {
7977
- const { runPull } = await import("./pull-DsdOoG-D.js");
7992
+ const { runPull } = await import("./pull-DGrlBSAG.js");
7978
7993
  return runPull(ctx, input);
7979
7994
  }
7980
7995
  });
@@ -8010,6 +8025,14 @@ const command$51 = defineCommand({
8010
8025
  overwriteSource: {
8011
8026
  type: "boolean",
8012
8027
  describe: "Replace the pushed paywalls' source in the app's repo with yours even though it can't be merged - other paywalls and funnels stay"
8028
+ },
8029
+ existing: {
8030
+ type: "boolean",
8031
+ describe: "Only paywalls already on Superwall - skip any not in superwall.lock instead of creating them"
8032
+ },
8033
+ source: {
8034
+ type: "boolean",
8035
+ describe: "Push the project source to every app, also those whose paywalls did not change (shared files such as the design system)"
8013
8036
  }
8014
8037
  },
8015
8038
  examples: [["push", "Push every changed paywall and funnel as a new version"], ["push --id plus-upgrade -m \"New annual price\"", "Push one paywall and record why"]],
@@ -8018,7 +8041,7 @@ const command$51 = defineCommand({
8018
8041
  prompts: true,
8019
8042
  mcp: false,
8020
8043
  async run(ctx, input) {
8021
- const { runPush } = await import("./push-CJVfvFZq.js");
8044
+ const { runPush } = await import("./push-DPZdch2W.js");
8022
8045
  return runPush(ctx, input, false);
8023
8046
  }
8024
8047
  });
@@ -8413,7 +8436,7 @@ async function createApp(context, api, nameArg, fields) {
8413
8436
  let name = nameArg;
8414
8437
  let platform = textOf(fields.platform);
8415
8438
  if (interactive && (!name || !platform)) {
8416
- const { scanProject } = await import("./scan-v_WTE722.js");
8439
+ const { scanProject } = await import("./scan-BQmjhs3g.js");
8417
8440
  const detected = (await scanProject(context.installDir).catch(() => null))?.apps[0];
8418
8441
  if (detected && !name && !platform) {
8419
8442
  ui.info(`Detected \`${detected.framework.name}\`` + (detected.details ? ` · \`${detected.details}\`` : ""));
@@ -8723,7 +8746,7 @@ async function runResource(ctx, resource, action, value$1, value2, flags) {
8723
8746
  if (action === "create") return create(ctx, ctx.api, resource, value$1, value2, flags);
8724
8747
  if (action === "use" && resource === "apps") return useApp(ctx, ctx.api, value$1);
8725
8748
  if (action === "storekit" && resource === "products") {
8726
- const { writeStoreKit } = await import("./storekit-D5eopLM0.js");
8749
+ const { writeStoreKit } = await import("./storekit-DK3xXKoY.js");
8727
8750
  return writeStoreKit(ctx, ctx.api, flags.fields.out);
8728
8751
  }
8729
8752
  throw new Error(`Unknown action "${action}" for ${resource}.`);
@@ -10077,7 +10100,7 @@ const command$62 = defineCommand({
10077
10100
  prompts: true,
10078
10101
  mcp: false,
10079
10102
  async run(ctx) {
10080
- const { runDoctor } = await import("./doctor-XtXW6tKE.js");
10103
+ const { runDoctor } = await import("./doctor-CHF9aNFc.js");
10081
10104
  return runDoctor(ctx);
10082
10105
  }
10083
10106
  });
@@ -10201,13 +10224,13 @@ function parseFeedbackReport(value$1) {
10201
10224
  }
10202
10225
  };
10203
10226
  }
10204
- const rateLimited = (error) => error instanceof ApiError && error.status === 429;
10227
+ const fallsBack = (error) => error instanceof ApiError && error.status !== 429 || error instanceof ApiUnreachableError || error instanceof NotLoggedInError || error instanceof SyntaxError;
10205
10228
  async function sendToApi(api, feedback, via) {
10206
10229
  try {
10207
10230
  return parseFeedbackReport(await api.post("/v2/feedback", buildFeedbackBody(feedback, via)));
10208
10231
  } catch (error) {
10209
- if (rateLimited(error)) throw error;
10210
- return;
10232
+ if (fallsBack(error)) return void 0;
10233
+ throw error;
10211
10234
  }
10212
10235
  }
10213
10236
  function buildFeedbackEvent(feedback, via, distinctId, session, osRelease, report) {
@@ -10422,7 +10445,7 @@ const command$64 = defineCommand({
10422
10445
  prompts: true,
10423
10446
  mcp: false,
10424
10447
  async run(ctx, input) {
10425
- const { runSkills } = await import("./skills-8um2fBPS.js");
10448
+ const { runSkills } = await import("./skills-ClEVgXUB.js");
10426
10449
  return runSkills(ctx, input);
10427
10450
  }
10428
10451
  });
@@ -10438,25 +10461,25 @@ const command$65 = defineCommand({
10438
10461
  prompts: true,
10439
10462
  mcp: false,
10440
10463
  async run(ctx) {
10441
- const { runUpgrade } = await import("./upgrade-CoWCEnoi.js");
10464
+ const { runUpgrade } = await import("./upgrade-g_Bd9oJe.js");
10442
10465
  return runUpgrade(ctx, AUTO_UPDATE_TARGET());
10443
10466
  }
10444
10467
  });
10445
10468
 
10446
10469
  //#endregion
10447
- //#region src/commands/workspaces/approve.ts
10470
+ //#region src/commands/artifacts/approve.ts
10448
10471
  const command$66 = defineCommand({
10449
- name: "workspaces approve",
10472
+ name: "artifacts approve",
10450
10473
  summary: "Review what a version can do and make it live",
10451
- details: "Admins only. Shows the version's manifest and how it differs from the live version, then asks. Without a terminal it needs --yes, and --accept-changes too when what the workspace can do changes.",
10474
+ details: "Admins only. Shows the version's manifest and how it differs from the live version, then asks. Without a terminal it needs --yes, and --accept-changes too when what the artifact can do changes.",
10452
10475
  args: { version: { describe: "The version id (default: the latest built that isn't live)" } },
10453
10476
  flags: {
10454
10477
  dir: projectDir,
10455
- workspace,
10478
+ artifact,
10456
10479
  org: {
10457
10480
  type: "string",
10458
10481
  value: "id",
10459
- describe: "The organization of a --workspace slug"
10482
+ describe: "The organization of a --artifact slug"
10460
10483
  },
10461
10484
  yes: {
10462
10485
  ...yes,
@@ -10468,9 +10491,9 @@ const command$66 = defineCommand({
10468
10491
  }
10469
10492
  },
10470
10493
  examples: [
10471
- ["workspaces approve --workspace 42", "Review and approve the latest built version"],
10472
- ["workspaces approve 7 --workspace 42 --json", "Print version 7's manifest and changes, approving nothing"],
10473
- ["workspaces approve 7 --workspace 42 --yes --accept-changes", "Approve it without a terminal, having read them"]
10494
+ ["artifacts approve --artifact 42", "Review and approve the latest built version"],
10495
+ ["artifacts approve 7 --artifact 42 --json", "Print version 7's manifest and changes, approving nothing"],
10496
+ ["artifacts approve 7 --artifact 42 --yes --accept-changes", "Approve it without a terminal, having read them"]
10474
10497
  ],
10475
10498
  auth: "required",
10476
10499
  json: true,
@@ -10478,8 +10501,8 @@ const command$66 = defineCommand({
10478
10501
  mcp: false,
10479
10502
  channel: "next",
10480
10503
  async run(ctx, { args, flags }) {
10481
- const { runWorkspaceApprove } = await import("./approve-Czs1-JO9.js");
10482
- await runWorkspaceApprove(ctx, {
10504
+ const { runArtifactApprove } = await import("./approve-I-lvTanp.js");
10505
+ await runArtifactApprove(ctx, {
10483
10506
  version: args.version,
10484
10507
  ...flags
10485
10508
  });
@@ -10487,25 +10510,25 @@ const command$66 = defineCommand({
10487
10510
  });
10488
10511
 
10489
10512
  //#endregion
10490
- //#region src/commands/workspaces/create.ts
10513
+ //#region src/commands/artifacts/create.ts
10491
10514
  const command$67 = defineCommand({
10492
- name: "workspaces create",
10493
- summary: "Start a workspace: a mini-app that adds to the Superwall dashboard",
10494
- args: { dir: { describe: "Where to put it (default: my-workspace)" } },
10515
+ name: "artifacts create",
10516
+ summary: "Start an artifact: a mini-app that adds to the Superwall dashboard",
10517
+ args: { dir: { describe: "Where to put it (default: my-artifact)" } },
10495
10518
  flags: { install: {
10496
10519
  type: "boolean",
10497
10520
  default: true,
10498
10521
  describe: "Install dependencies after downloading (--no-install to skip)"
10499
10522
  } },
10500
- examples: [["workspaces create", "Download the starter into my-workspace"], ["workspaces create churn-copilot", "Name the directory yourself"]],
10523
+ examples: [["artifacts create", "Download the starter into my-artifact"], ["artifacts create churn-copilot", "Name the directory yourself"]],
10501
10524
  auth: "none",
10502
10525
  json: false,
10503
10526
  prompts: false,
10504
10527
  mcp: false,
10505
10528
  channel: "next",
10506
10529
  async run(ctx, { args, flags }) {
10507
- const { runWorkspaceCreate } = await import("./starter-CiLrp1cN.js");
10508
- await runWorkspaceCreate(ctx, {
10530
+ const { runArtifactCreate } = await import("./starter-BtUUQWhd.js");
10531
+ await runArtifactCreate(ctx, {
10509
10532
  dir: args.dir,
10510
10533
  install: flags.install
10511
10534
  });
@@ -10513,12 +10536,12 @@ const command$67 = defineCommand({
10513
10536
  });
10514
10537
 
10515
10538
  //#endregion
10516
- //#region src/commands/workspaces/dev.ts
10539
+ //#region src/commands/artifacts/dev.ts
10517
10540
  const command$68 = defineCommand({
10518
- name: "workspaces dev",
10519
- summary: "Run a workspace on localhost against your real data, read-only",
10520
- details: "Bundles the workspace the way the builder does, including its client.entry, and runs it in workerd. A local page plays the dashboard: it mounts pages and widgets, sends them context and theme over the bridge, and runs metrics and readouts. API calls go out with a short-lived, read-only token as you, limited to one organization and to the routes a workspace can read. It reads everything you can read in that organization, so only run code you trust. A staff account reaches only that organization too. Writes, outside hosts and raw sockets are refused. Every change rebuilds it.",
10521
- args: { dir: { describe: "The workspace (default: cwd)" } },
10541
+ name: "artifacts dev",
10542
+ summary: "Run an artifact on localhost against your real data, read-only",
10543
+ details: "Bundles the artifact the way the builder does, including its client.entry, and runs it in workerd. A local page plays the dashboard: it mounts pages and widgets, sends them context and theme over the bridge, and runs metrics and readouts. API calls go out with a short-lived, read-only token as you, limited to one organization and to the routes an artifact can read. It reads everything you can read in that organization, so only run code you trust. A staff account reaches only that organization too. Writes, outside hosts and raw sockets are refused. Every change rebuilds it.",
10544
+ args: { dir: { describe: "The artifact (default: cwd)" } },
10522
10545
  flags: {
10523
10546
  port: {
10524
10547
  type: "number",
@@ -10581,15 +10604,15 @@ const command$68 = defineCommand({
10581
10604
  describe: "The whole context as JSON, for a slot this CLI doesn't know"
10582
10605
  }
10583
10606
  },
10584
- examples: [["workspaces dev --org 1234", "Serve this workspace for one organization"], ["workspaces dev --app 5678 --user alice", "Fill in the app and the user a panel receives"]],
10607
+ examples: [["artifacts dev --org 1234", "Serve this artifact for one organization"], ["artifacts dev --app 5678 --user alice", "Fill in the app and the user a panel receives"]],
10585
10608
  auth: "required",
10586
10609
  json: false,
10587
10610
  prompts: true,
10588
10611
  mcp: false,
10589
10612
  channel: "next",
10590
10613
  async run(ctx, { args, flags }) {
10591
- const { runWorkspaceDev } = await import("./run-CgLmD2vR.js");
10592
- await runWorkspaceDev(ctx, {
10614
+ const { runArtifactDev } = await import("./run-Co8u_BkN.js");
10615
+ await runArtifactDev(ctx, {
10593
10616
  dir: args.dir,
10594
10617
  ...flags
10595
10618
  });
@@ -10597,9 +10620,9 @@ const command$68 = defineCommand({
10597
10620
  });
10598
10621
 
10599
10622
  //#endregion
10600
- //#region src/commands/workspaces/install.ts
10623
+ //#region src/commands/artifacts/install.ts
10601
10624
  const command$69 = defineCommand({
10602
- name: "workspaces install",
10625
+ name: "artifacts install",
10603
10626
  summary: "Choose where an entrypoint shows",
10604
10627
  details: "Admins only. Installs an entrypoint of the live version for the whole organization, or one app with --app. An app's row overrides the organization's there. Without an entrypoint, lists what's installed.",
10605
10628
  args: { entrypoint: { describe: "The entrypoint id from superwall.json" } },
@@ -10622,11 +10645,11 @@ const command$69 = defineCommand({
10622
10645
  describe: "Order among the entrypoints shown in one slot, lowest first"
10623
10646
  },
10624
10647
  dir: projectDir,
10625
- workspace,
10648
+ artifact,
10626
10649
  org: {
10627
10650
  type: "string",
10628
10651
  value: "id",
10629
- describe: "The organization of a --workspace slug"
10652
+ describe: "The organization of a --artifact slug"
10630
10653
  },
10631
10654
  yes: {
10632
10655
  ...yes,
@@ -10634,9 +10657,9 @@ const command$69 = defineCommand({
10634
10657
  }
10635
10658
  },
10636
10659
  examples: [
10637
- ["workspaces install", "List what's installed"],
10638
- ["workspaces install churn --app 5678", "Show it in one app"],
10639
- ["workspaces install churn --remove --yes", "Remove the organization-wide row"]
10660
+ ["artifacts install", "List what's installed"],
10661
+ ["artifacts install churn --app 5678", "Show it in one app"],
10662
+ ["artifacts install churn --remove --yes", "Remove the organization-wide row"]
10640
10663
  ],
10641
10664
  auth: "required",
10642
10665
  json: true,
@@ -10644,8 +10667,8 @@ const command$69 = defineCommand({
10644
10667
  mcp: false,
10645
10668
  channel: "next",
10646
10669
  async run(ctx, { args, flags }) {
10647
- const { runWorkspaceInstall } = await import("./install-CVUXsx8c.js");
10648
- await runWorkspaceInstall(ctx, {
10670
+ const { runArtifactInstall } = await import("./install-CXfLcLhU.js");
10671
+ await runArtifactInstall(ctx, {
10649
10672
  entrypoint: args.entrypoint,
10650
10673
  ...flags
10651
10674
  });
@@ -10653,10 +10676,10 @@ const command$69 = defineCommand({
10653
10676
  });
10654
10677
 
10655
10678
  //#endregion
10656
- //#region src/commands/workspaces/list.ts
10679
+ //#region src/commands/artifacts/list.ts
10657
10680
  const command$70 = defineCommand({
10658
- name: "workspaces list",
10659
- summary: "List an organization's workspaces",
10681
+ name: "artifacts list",
10682
+ summary: "List an organization's artifacts",
10660
10683
  flags: {
10661
10684
  org: {
10662
10685
  type: "string",
@@ -10665,43 +10688,43 @@ const command$70 = defineCommand({
10665
10688
  },
10666
10689
  dir: projectDir
10667
10690
  },
10668
- examples: [["workspaces list --org 1234", "Every workspace in organization 1234"]],
10691
+ examples: [["artifacts list --org 1234", "Every artifact in organization 1234"]],
10669
10692
  auth: "required",
10670
10693
  json: true,
10671
10694
  prompts: true,
10672
10695
  mcp: false,
10673
10696
  channel: "next",
10674
10697
  async run(ctx, { flags }) {
10675
- const { runWorkspaceList } = await import("./install-CVUXsx8c.js");
10676
- await runWorkspaceList(ctx, flags);
10698
+ const { runArtifactList } = await import("./install-CXfLcLhU.js");
10699
+ await runArtifactList(ctx, flags);
10677
10700
  }
10678
10701
  });
10679
10702
 
10680
10703
  //#endregion
10681
- //#region src/commands/workspaces/logs.ts
10704
+ //#region src/commands/artifacts/logs.ts
10682
10705
  const command$71 = defineCommand({
10683
- name: "workspaces logs",
10706
+ name: "artifacts logs",
10684
10707
  summary: "Show a version's build log",
10685
10708
  details: "The last 128 KiB, once the build has finished. The latest version by default.",
10686
10709
  args: { version: { describe: "The version id (default: the latest)" } },
10687
10710
  flags: {
10688
10711
  dir: projectDir,
10689
- workspace,
10712
+ artifact,
10690
10713
  org: {
10691
10714
  type: "string",
10692
10715
  value: "id",
10693
- describe: "The organization of a --workspace slug"
10716
+ describe: "The organization of a --artifact slug"
10694
10717
  }
10695
10718
  },
10696
- examples: [["workspaces logs", "The latest version's build log"], ["workspaces logs 7", "Version 7's"]],
10719
+ examples: [["artifacts logs", "The latest version's build log"], ["artifacts logs 7", "Version 7's"]],
10697
10720
  auth: "required",
10698
10721
  json: true,
10699
10722
  prompts: false,
10700
10723
  mcp: false,
10701
10724
  channel: "next",
10702
10725
  async run(ctx, { args, flags }) {
10703
- const { runWorkspaceLogs } = await import("./status-CoYMK7QL.js");
10704
- await runWorkspaceLogs(ctx, {
10726
+ const { runArtifactLogs } = await import("./status-SAZxltzW.js");
10727
+ await runArtifactLogs(ctx, {
10705
10728
  version: args.version,
10706
10729
  ...flags
10707
10730
  });
@@ -10709,10 +10732,10 @@ const command$71 = defineCommand({
10709
10732
  });
10710
10733
 
10711
10734
  //#endregion
10712
- //#region src/commands/workspaces/open.ts
10735
+ //#region src/commands/artifacts/open.ts
10713
10736
  const command$72 = defineCommand({
10714
- name: "workspaces open",
10715
- summary: "Open a workspace in the dashboard",
10737
+ name: "artifacts open",
10738
+ summary: "Open an artifact in the dashboard",
10716
10739
  args: { entrypoint: { describe: "An entrypoint to open inside an app, with --app" } },
10717
10740
  flags: {
10718
10741
  app: {
@@ -10720,11 +10743,11 @@ const command$72 = defineCommand({
10720
10743
  describe: "The app to open the entrypoint in"
10721
10744
  },
10722
10745
  dir: projectDir,
10723
- workspace,
10746
+ artifact,
10724
10747
  org: {
10725
10748
  type: "string",
10726
10749
  value: "id",
10727
- describe: "The organization of a --workspace slug"
10750
+ describe: "The organization of a --artifact slug"
10728
10751
  },
10729
10752
  open: {
10730
10753
  type: "boolean",
@@ -10732,15 +10755,15 @@ const command$72 = defineCommand({
10732
10755
  describe: "Open your browser at a terminal (--no-open to only print the link)"
10733
10756
  }
10734
10757
  },
10735
- examples: [["workspaces open", "This project's workspace"], ["workspaces open panel --app 5678", "One entrypoint, inside an app"]],
10758
+ examples: [["artifacts open", "This project's artifact"], ["artifacts open panel --app 5678", "One entrypoint, inside an app"]],
10736
10759
  auth: "required",
10737
10760
  json: true,
10738
10761
  prompts: false,
10739
10762
  mcp: false,
10740
10763
  channel: "next",
10741
10764
  async run(ctx, { args, flags }) {
10742
- const { runWorkspaceOpen } = await import("./install-CVUXsx8c.js");
10743
- await runWorkspaceOpen(ctx, {
10765
+ const { runArtifactOpen } = await import("./install-CXfLcLhU.js");
10766
+ await runArtifactOpen(ctx, {
10744
10767
  entrypoint: args.entrypoint,
10745
10768
  ...flags
10746
10769
  });
@@ -10748,17 +10771,17 @@ const command$72 = defineCommand({
10748
10771
  });
10749
10772
 
10750
10773
  //#endregion
10751
- //#region src/commands/workspaces/pull.ts
10774
+ //#region src/commands/artifacts/pull.ts
10752
10775
  const command$73 = defineCommand({
10753
- name: "workspaces pull",
10776
+ name: "artifacts pull",
10754
10777
  summary: "Bring teammates' pushes into this project, merged with your edits",
10755
- args: { dir: { describe: "The workspace project, or with --workspace an empty folder to fill (default: cwd)" } },
10778
+ args: { dir: { describe: "The artifact project, or with --artifact an empty folder to fill (default: cwd)" } },
10756
10779
  flags: {
10757
- workspace,
10780
+ artifact,
10758
10781
  org: {
10759
10782
  type: "string",
10760
10783
  value: "id",
10761
- describe: "The organization of a --workspace slug"
10784
+ describe: "The organization of a --artifact slug"
10762
10785
  },
10763
10786
  theirs: {
10764
10787
  type: "boolean",
@@ -10766,9 +10789,9 @@ const command$73 = defineCommand({
10766
10789
  }
10767
10790
  },
10768
10791
  examples: [
10769
- ["workspaces pull", "Merge what teammates pushed into this project"],
10770
- ["workspaces pull --theirs", "Take the source repo's version of files you both changed"],
10771
- ["workspaces pull churn-copilot --workspace 42", "Get workspace 42's source into a new folder"]
10792
+ ["artifacts pull", "Merge what teammates pushed into this project"],
10793
+ ["artifacts pull --theirs", "Take the source repo's version of files you both changed"],
10794
+ ["artifacts pull churn-copilot --artifact 42", "Get artifact 42's source into a new folder"]
10772
10795
  ],
10773
10796
  auth: "required",
10774
10797
  json: true,
@@ -10776,8 +10799,8 @@ const command$73 = defineCommand({
10776
10799
  mcp: false,
10777
10800
  channel: "next",
10778
10801
  async run(ctx, { args, flags }) {
10779
- const { runWorkspacePull } = await import("./pull-zYAbqo9n.js");
10780
- await runWorkspacePull(ctx, {
10802
+ const { runArtifactPull } = await import("./pull-Bfa3_SBt.js");
10803
+ await runArtifactPull(ctx, {
10781
10804
  dir: args.dir,
10782
10805
  ...flags
10783
10806
  });
@@ -10785,12 +10808,12 @@ const command$73 = defineCommand({
10785
10808
  });
10786
10809
 
10787
10810
  //#endregion
10788
- //#region src/commands/workspaces/push.ts
10811
+ //#region src/commands/artifacts/push.ts
10789
10812
  const command$74 = defineCommand({
10790
- name: "workspaces push",
10791
- summary: "Push this workspace's source and build it",
10792
- details: "The first push creates the workspace from the manifest's name and records its id in superwall.workspace.json. Each push makes a version from the commit. Only you can see it until an admin approves it. When the source repo has commits this project doesn't, the push merges them, and your own copy runs them with your reads, so it asks first. Without a terminal it stops unless you pass --accept-merged-commits.",
10793
- args: { dir: { describe: "The workspace project (default: cwd)" } },
10813
+ name: "artifacts push",
10814
+ summary: "Push this artifact's source and build it",
10815
+ details: "The first push creates the artifact from the manifest's name and records its id in superwall.artifact.json. Each push makes a version from the commit. Only you can see it until an admin approves it. When the source repo has commits this project doesn't, the push merges them, and your own copy runs them with your reads, so it asks first. Without a terminal it stops unless you pass --accept-merged-commits.",
10816
+ args: { dir: { describe: "The artifact project (default: cwd)" } },
10794
10817
  flags: {
10795
10818
  org: {
10796
10819
  type: "string",
@@ -10812,9 +10835,9 @@ const command$74 = defineCommand({
10812
10835
  }
10813
10836
  },
10814
10837
  examples: [
10815
- ["workspaces push", "Push and build this project"],
10816
- ["workspaces push --org 1234 -m \"Add the cohort page\"", "The first push, with a note"],
10817
- ["workspaces push --json --accept-merged-commits", "In a script, taking in teammates' commits"]
10838
+ ["artifacts push", "Push and build this project"],
10839
+ ["artifacts push --org 1234 -m \"Add the cohort page\"", "The first push, with a note"],
10840
+ ["artifacts push --json --accept-merged-commits", "In a script, taking in teammates' commits"]
10818
10841
  ],
10819
10842
  auth: "required",
10820
10843
  json: true,
@@ -10822,8 +10845,8 @@ const command$74 = defineCommand({
10822
10845
  mcp: false,
10823
10846
  channel: "next",
10824
10847
  async run(ctx, { args, flags }) {
10825
- const { runWorkspacePush } = await import("./push-SVzv7fzE.js");
10826
- await runWorkspacePush(ctx, {
10848
+ const { runArtifactPush } = await import("./push-DV-kJZdw.js");
10849
+ await runArtifactPush(ctx, {
10827
10850
  dir: args.dir,
10828
10851
  ...flags
10829
10852
  });
@@ -10831,30 +10854,30 @@ const command$74 = defineCommand({
10831
10854
  });
10832
10855
 
10833
10856
  //#endregion
10834
- //#region src/commands/workspaces/share.ts
10857
+ //#region src/commands/artifacts/share.ts
10835
10858
  const command$75 = defineCommand({
10836
- name: "workspaces share",
10859
+ name: "artifacts share",
10837
10860
  summary: "Ask an admin to review a version",
10838
10861
  details: "The latest built version by default. Until an organization owner or admin approves it, only its author can see it. Nobody is told automatically, so it says who to ask.",
10839
10862
  args: { version: { describe: "The version id (default: the latest built)" } },
10840
10863
  flags: {
10841
10864
  dir: projectDir,
10842
- workspace,
10865
+ artifact,
10843
10866
  org: {
10844
10867
  type: "string",
10845
10868
  value: "id",
10846
- describe: "The organization of a --workspace slug"
10869
+ describe: "The organization of a --artifact slug"
10847
10870
  }
10848
10871
  },
10849
- examples: [["workspaces share", "Ask for review of the latest built version"]],
10872
+ examples: [["artifacts share", "Ask for review of the latest built version"]],
10850
10873
  auth: "required",
10851
10874
  json: true,
10852
10875
  prompts: false,
10853
10876
  mcp: false,
10854
10877
  channel: "next",
10855
10878
  async run(ctx, { args, flags }) {
10856
- const { runWorkspaceShare } = await import("./status-CoYMK7QL.js");
10857
- await runWorkspaceShare(ctx, {
10879
+ const { runArtifactShare } = await import("./status-SAZxltzW.js");
10880
+ await runArtifactShare(ctx, {
10858
10881
  version: args.version,
10859
10882
  ...flags
10860
10883
  });
@@ -10862,41 +10885,41 @@ const command$75 = defineCommand({
10862
10885
  });
10863
10886
 
10864
10887
  //#endregion
10865
- //#region src/commands/workspaces/status.ts
10888
+ //#region src/commands/artifacts/status.ts
10866
10889
  const command$76 = defineCommand({
10867
- name: "workspaces status",
10868
- summary: "Show a workspace's state and its latest versions",
10890
+ name: "artifacts status",
10891
+ summary: "Show an artifact's state and its latest versions",
10869
10892
  flags: {
10870
10893
  dir: projectDir,
10871
- workspace,
10894
+ artifact,
10872
10895
  org: {
10873
10896
  type: "string",
10874
10897
  value: "id",
10875
- describe: "The organization of a --workspace slug"
10898
+ describe: "The organization of a --artifact slug"
10876
10899
  },
10877
10900
  all: {
10878
10901
  type: "boolean",
10879
10902
  describe: "List every version, not just the latest and the live one"
10880
10903
  }
10881
10904
  },
10882
- examples: [["workspaces status", "This project's workspace"], ["workspaces status --workspace 42", "Any workspace you can see"]],
10905
+ examples: [["artifacts status", "This project's artifact"], ["artifacts status --artifact 42", "Any artifact you can see"]],
10883
10906
  auth: "required",
10884
10907
  json: true,
10885
10908
  prompts: false,
10886
10909
  mcp: false,
10887
10910
  channel: "next",
10888
10911
  async run(ctx, { flags }) {
10889
- const { runWorkspaceStatus } = await import("./status-CoYMK7QL.js");
10890
- await runWorkspaceStatus(ctx, flags);
10912
+ const { runArtifactStatus } = await import("./status-SAZxltzW.js");
10913
+ await runArtifactStatus(ctx, flags);
10891
10914
  }
10892
10915
  });
10893
10916
 
10894
10917
  //#endregion
10895
- //#region src/commands/workspaces/try.ts
10918
+ //#region src/commands/artifacts/try.ts
10896
10919
  const command$77 = defineCommand({
10897
- name: "workspaces try",
10920
+ name: "artifacts try",
10898
10921
  summary: "Upload a draft and run an entrypoint on the real runtime",
10899
- details: "Nothing is saved: the draft runs as you, read-only and with no outside hosts, and only you can reach it for a day. A metric prints its series. A page, panel, tab, card or action opens in the dashboard. Readouts run with workspaces dev until the runtime takes them.",
10922
+ details: "Nothing is saved: the draft runs as you, read-only and with no outside hosts, and only you can reach it for a day. A metric prints its series. A page, panel, tab, card or action opens in the dashboard. Readouts run with artifacts dev until the runtime takes them.",
10900
10923
  args: { entrypoint: {
10901
10924
  describe: "The entrypoint id from superwall.json",
10902
10925
  required: true
@@ -10905,7 +10928,7 @@ const command$77 = defineCommand({
10905
10928
  dir: {
10906
10929
  type: "string",
10907
10930
  value: "path",
10908
- describe: "The workspace (default: cwd)"
10931
+ describe: "The artifact (default: cwd)"
10909
10932
  },
10910
10933
  app: {
10911
10934
  ...app,
@@ -10978,9 +11001,9 @@ const command$77 = defineCommand({
10978
11001
  }
10979
11002
  },
10980
11003
  examples: [
10981
- ["workspaces try transactions --app 5678", "Run a metric for one app over the last 30 days"],
10982
- ["workspaces try transactions --app 5678 --breakdown store --filter store=APP_STORE", "Split and filter it"],
10983
- ["workspaces try home --org 1234", "Open a page in the dashboard"]
11004
+ ["artifacts try transactions --app 5678", "Run a metric for one app over the last 30 days"],
11005
+ ["artifacts try transactions --app 5678 --breakdown store --filter store=APP_STORE", "Split and filter it"],
11006
+ ["artifacts try home --org 1234", "Open a page in the dashboard"]
10984
11007
  ],
10985
11008
  auth: "required",
10986
11009
  json: true,
@@ -10988,8 +11011,8 @@ const command$77 = defineCommand({
10988
11011
  mcp: false,
10989
11012
  channel: "next",
10990
11013
  async run(ctx, { args, flags }) {
10991
- const { runWorkspaceTry } = await import("./try-BWbzgelb.js");
10992
- await runWorkspaceTry(ctx, {
11014
+ const { runArtifactTry } = await import("./try-BrJJyXgq.js");
11015
+ await runArtifactTry(ctx, {
10993
11016
  entrypoint: args.entrypoint,
10994
11017
  ...flags
10995
11018
  });
@@ -10997,11 +11020,11 @@ const command$77 = defineCommand({
10997
11020
  });
10998
11021
 
10999
11022
  //#endregion
11000
- //#region src/commands/workspaces/update.ts
11023
+ //#region src/commands/artifacts/update.ts
11001
11024
  const command$78 = defineCommand({
11002
- name: "workspaces update",
11003
- summary: "Refresh a workspace's vendored SDK from the public repo",
11004
- args: { dir: { describe: "The workspace (default: cwd)" } },
11025
+ name: "artifacts update",
11026
+ summary: "Refresh an artifact's vendored SDK from the public repo",
11027
+ args: { dir: { describe: "The artifact (default: cwd)" } },
11005
11028
  flags: {
11006
11029
  install: {
11007
11030
  type: "boolean",
@@ -11013,15 +11036,15 @@ const command$78 = defineCommand({
11013
11036
  describe: "Replace a vendored SDK that's newer than the latest published one"
11014
11037
  }
11015
11038
  },
11016
- examples: [["workspaces update", "Replace vendor/workspace-sdk with the latest and update the lockfile"]],
11039
+ examples: [["artifacts update", "Replace vendor/artifact-sdk with the latest and update the lockfile"]],
11017
11040
  auth: "none",
11018
11041
  json: false,
11019
11042
  prompts: false,
11020
11043
  mcp: false,
11021
11044
  channel: "next",
11022
11045
  async run(ctx, { args, flags }) {
11023
- const { runWorkspaceUpdate } = await import("./starter-CiLrp1cN.js");
11024
- await runWorkspaceUpdate(ctx, {
11046
+ const { runArtifactUpdate } = await import("./starter-BtUUQWhd.js");
11047
+ await runArtifactUpdate(ctx, {
11025
11048
  dir: args.dir,
11026
11049
  install: flags.install,
11027
11050
  force: flags.force
@@ -11063,8 +11086,8 @@ const command$79 = defineCommand({
11063
11086
  prompts: true,
11064
11087
  mcp: false,
11065
11088
  async run(ctx, { flags }) {
11066
- const { runIntegrate } = await import("./integrate-qvKd9pVW.js");
11067
- const { printPlaybook } = await import("./playbook-Du4Oydbf.js");
11089
+ const { runIntegrate } = await import("./integrate-DS2YGLsM.js");
11090
+ const { printPlaybook } = await import("./playbook-K7vmAUsu.js");
11068
11091
  if (flags.skill) return printPlaybook(ctx.installDir, "integrate");
11069
11092
  await runIntegrate({
11070
11093
  ...ctx,
@@ -11110,8 +11133,8 @@ const command$80 = defineCommand({
11110
11133
  prompts: true,
11111
11134
  mcp: false,
11112
11135
  async run(ctx, { args, flags }) {
11113
- const { runPaywallMigration, runProviderMigration, runScreenMigration } = await import("./migrate-SkkLLdmr.js");
11114
- const { printPlaybook } = await import("./playbook-Du4Oydbf.js");
11136
+ const { runPaywallMigration, runProviderMigration, runScreenMigration } = await import("./migrate-CoQWqzhJ.js");
11137
+ const { printPlaybook } = await import("./playbook-K7vmAUsu.js");
11115
11138
  if (flags.screen !== void 0) return runScreenMigration(ctx, {
11116
11139
  path: flags.screen,
11117
11140
  screenshot: flags.screenshot
@@ -11145,8 +11168,8 @@ const command$81 = defineCommand({
11145
11168
  prompts: true,
11146
11169
  mcp: false,
11147
11170
  async run(ctx, { flags }) {
11148
- const { runReview } = await import("./integrate-qvKd9pVW.js");
11149
- const { printPlaybook } = await import("./playbook-Du4Oydbf.js");
11171
+ const { runReview } = await import("./integrate-DS2YGLsM.js");
11172
+ const { printPlaybook } = await import("./playbook-K7vmAUsu.js");
11150
11173
  if (flags.skill) return printPlaybook(ctx.installDir, flags.fix ? "review-fix" : "review");
11151
11174
  await runReview(ctx, flags.fix);
11152
11175
  }
@@ -11180,14 +11203,14 @@ const GROUPS = [
11180
11203
  ]
11181
11204
  },
11182
11205
  {
11183
- id: "workspaces",
11184
- title: "Workspaces",
11185
- prefix: "workspaces",
11206
+ id: "artifacts",
11207
+ title: "Artifacts",
11208
+ prefix: "artifacts",
11186
11209
  channel: "next",
11187
11210
  topics: [{
11188
- name: "workspaces",
11211
+ name: "artifacts",
11189
11212
  summary: "Mini-apps that add pages, panels and metrics to the Superwall dashboard",
11190
- details: "A workspace is a Worker with a superwall.json manifest. It holds no credential: it calls Superwall as whoever is viewing it."
11213
+ details: "An artifact is a Worker with a superwall.json manifest. It holds no credential: it calls Superwall as whoever is viewing it."
11191
11214
  }],
11192
11215
  commands: [
11193
11216
  command$67,