@forgecart/cli 2.202610071755.0 → 2.202610082355.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (26) hide show
  1. package/dist/src/authorization/cli-authorization-flow.d.ts +55 -0
  2. package/dist/src/authorization/cli-authorization-flow.js +175 -0
  3. package/dist/src/authorization/cli-authorization-flow.js.map +1 -0
  4. package/dist/src/authorization/cli-authorization.client.d.ts +36 -0
  5. package/dist/src/authorization/cli-authorization.client.js +169 -0
  6. package/dist/src/authorization/cli-authorization.client.js.map +1 -0
  7. package/dist/src/authorization/cli-credential-check.d.ts +42 -0
  8. package/dist/src/authorization/cli-credential-check.js +157 -0
  9. package/dist/src/authorization/cli-credential-check.js.map +1 -0
  10. package/dist/src/authorization/cli-unauthorized-refusal.d.ts +21 -0
  11. package/dist/src/authorization/cli-unauthorized-refusal.js +33 -0
  12. package/dist/src/authorization/cli-unauthorized-refusal.js.map +1 -0
  13. package/dist/src/authorization/type/cli-authorization.types.d.ts +55 -0
  14. package/dist/src/authorization/type/cli-authorization.types.js +24 -0
  15. package/dist/src/authorization/type/cli-authorization.types.js.map +1 -0
  16. package/dist/src/commands/init.d.ts +41 -14
  17. package/dist/src/commands/init.js +131 -23
  18. package/dist/src/commands/init.js.map +1 -1
  19. package/dist/src/exit-ladder.d.ts +8 -1
  20. package/dist/src/exit-ladder.js +7 -0
  21. package/dist/src/exit-ladder.js.map +1 -1
  22. package/package.json +1 -1
  23. package/templates/storefront/README.md +6 -2
  24. package/templates/storefront/src/server/forgecart/forgecart-client.factory.ts +11 -7
  25. package/templates/storefront-shadcn/README.md +6 -2
  26. package/templates/storefront-shadcn/src/server/forgecart/forgecart-client.factory.ts +11 -7
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-credential-check.js","sourceRoot":"","sources":["../../../src/authorization/cli-credential-check.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5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,MAAM,CAAC,eAAe,CAAC,GAAW;QACxC,OAAO,MAAM,CAAC,MAAM,CAAS,gBAAgB,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;IAC/D,CAAC;CACF"}
@@ -0,0 +1,21 @@
1
+ import { CliRefusal } from '../exit-ladder.js';
2
+ /** The code a scripted caller routes on beside exit 3 — never the prose after it. */
3
+ export declare const CLI_UNAUTHORIZED_CODE = "FORGECART_CLI_UNAUTHORIZED";
4
+ /** Why no approval delivered the credentials. */
5
+ export declare enum CliUnauthorizedReason {
6
+ /** An administrator pressed Deny on the `/authorize` card. */
7
+ DENIED = "denied",
8
+ /** The authorization's window closed — or the server no longer knows its code. */
9
+ EXPIRED = "expired",
10
+ /** `--timeout` elapsed before an approval. */
11
+ TIMED_OUT = "timed-out"
12
+ }
13
+ /**
14
+ * An authorization that did not end approved — exit
15
+ * {@link CliExitLadder.unauthorized} with {@link CLI_UNAUTHORIZED_CODE}, never a
16
+ * hang (#2772, record `refs/design/cli-improvements`, `init?case=headless`).
17
+ */
18
+ export declare class CliUnauthorizedRefusal extends CliRefusal {
19
+ readonly reason: CliUnauthorizedReason;
20
+ constructor(reason: CliUnauthorizedReason);
21
+ }
@@ -0,0 +1,33 @@
1
+ import { CliExitLadder, CliRefusal } from '../exit-ladder.js';
2
+ /** The code a scripted caller routes on beside exit 3 — never the prose after it. */
3
+ export const CLI_UNAUTHORIZED_CODE = 'FORGECART_CLI_UNAUTHORIZED';
4
+ /** Why no approval delivered the credentials. */
5
+ export var CliUnauthorizedReason;
6
+ (function (CliUnauthorizedReason) {
7
+ /** An administrator pressed Deny on the `/authorize` card. */
8
+ CliUnauthorizedReason["DENIED"] = "denied";
9
+ /** The authorization's window closed — or the server no longer knows its code. */
10
+ CliUnauthorizedReason["EXPIRED"] = "expired";
11
+ /** `--timeout` elapsed before an approval. */
12
+ CliUnauthorizedReason["TIMED_OUT"] = "timed-out";
13
+ })(CliUnauthorizedReason || (CliUnauthorizedReason = {}));
14
+ /** What each reason tells the merchant: what happened, that nothing was written, and the two ways on. */
15
+ const REASON_LINES = {
16
+ [CliUnauthorizedReason.DENIED]: 'the authorization was denied at /authorize; nothing was written.',
17
+ [CliUnauthorizedReason.EXPIRED]: 'the authorization window closed before an approval; nothing was written. Re-run to open a new one, or export the four FORGECART_* keys.',
18
+ [CliUnauthorizedReason.TIMED_OUT]: 'no credentials in the environment, in .env or in .forgecart/config.json, and no approval within --timeout; nothing was written. Export the four FORGECART_* keys, or authorize at the URL above.',
19
+ };
20
+ /**
21
+ * An authorization that did not end approved — exit
22
+ * {@link CliExitLadder.unauthorized} with {@link CLI_UNAUTHORIZED_CODE}, never a
23
+ * hang (#2772, record `refs/design/cli-improvements`, `init?case=headless`).
24
+ */
25
+ export class CliUnauthorizedRefusal extends CliRefusal {
26
+ reason;
27
+ constructor(reason) {
28
+ super(CliExitLadder.unauthorized, [`${CLI_UNAUTHORIZED_CODE} — ${REASON_LINES[reason]}`]);
29
+ this.reason = reason;
30
+ this.name = 'CliUnauthorizedRefusal';
31
+ }
32
+ }
33
+ //# sourceMappingURL=cli-unauthorized-refusal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-unauthorized-refusal.js","sourceRoot":"","sources":["../../../src/authorization/cli-unauthorized-refusal.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE9D,qFAAqF;AACrF,MAAM,CAAC,MAAM,qBAAqB,GAAG,4BAA4B,CAAC;AAElE,iDAAiD;AACjD,MAAM,CAAN,IAAY,qBAOX;AAPD,WAAY,qBAAqB;IAC/B,8DAA8D;IAC9D,0CAAiB,CAAA;IACjB,kFAAkF;IAClF,4CAAmB,CAAA;IACnB,8CAA8C;IAC9C,gDAAuB,CAAA;AACzB,CAAC,EAPW,qBAAqB,KAArB,qBAAqB,QAOhC;AAED,yGAAyG;AACzG,MAAM,YAAY,GAAoD;IACpE,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAC5B,kEAAkE;IACpE,CAAC,qBAAqB,CAAC,OAAO,CAAC,EAC7B,yIAAyI;IAC3I,CAAC,qBAAqB,CAAC,SAAS,CAAC,EAC/B,kMAAkM;CACrM,CAAC;AAEF;;;;GAIG;AACH,MAAM,OAAO,sBAAuB,SAAQ,UAAU;IAC/B;IAArB,YAAqB,MAA6B;QAChD,KAAK,CAAC,aAAa,CAAC,YAAY,EAAE,CAAC,GAAG,qBAAqB,MAAM,YAAY,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;QADvE,WAAM,GAAN,MAAM,CAAuB;QAEhD,IAAI,CAAC,IAAI,GAAG,wBAAwB,CAAC;IACvC,CAAC;CACF"}
@@ -0,0 +1,55 @@
1
+ /**
2
+ * The four credentials a storefront runs on (#2772), by the `.env` key `init`
3
+ * writes each one under — in the order the check names them and the merge
4
+ * writes them.
5
+ */
6
+ export declare enum CliCredentialKey {
7
+ CHANNEL_TOKEN = "FORGECART_CHANNEL_TOKEN",
8
+ ADMIN_SECRET = "FORGECART_ADMIN_SECRET",
9
+ SHOP_API_URL = "FORGECART_SHOP_API_URL",
10
+ ADMIN_API_URL = "FORGECART_ADMIN_API_URL"
11
+ }
12
+ /**
13
+ * Where an authorization stands, as the admin API's status poll answers it —
14
+ * the server's `DeviceAuthStatus` values, upper case.
15
+ */
16
+ export declare enum CliAuthorizationState {
17
+ PENDING = "PENDING",
18
+ APPROVED = "APPROVED",
19
+ DENIED = "DENIED",
20
+ EXPIRED = "EXPIRED"
21
+ }
22
+ /**
23
+ * The four credentials, all present — what an approval delivers, and what the
24
+ * check passes on. `adminSecret` lands in the git-ignored `.env` alone, never
25
+ * in `.forgecart/config.json`.
26
+ */
27
+ export interface CliCredentials {
28
+ channelToken: string;
29
+ adminSecret: string;
30
+ shopApiUrl: string;
31
+ adminApiUrl: string;
32
+ }
33
+ /** What `forgecart init` names when it opens an authorization: the machine, and itself. */
34
+ export interface CliAuthorizationRequestInput {
35
+ deviceName: string;
36
+ cliVersion: string;
37
+ }
38
+ /** The authorization the admin API opened, in the request result's wire shape. */
39
+ export interface CliAuthorizationRequestResult {
40
+ /** The CLI's poll key — a secret: never printed. */
41
+ deviceCode: string;
42
+ /** The code the merchant compares on the `/authorize` card. */
43
+ userCode: string;
44
+ /** The dashboard's `/authorize` page for this code. */
45
+ verificationUrl: string;
46
+ /** When the window closes, ISO 8601. */
47
+ expiresAt: string;
48
+ /** The cadence the poll keeps. */
49
+ pollIntervalSec: number;
50
+ }
51
+ /** One status poll's answer: the credentials ride the APPROVED answer, exactly once. */
52
+ export interface CliAuthorizationStatusResult {
53
+ state: CliAuthorizationState;
54
+ credentials: CliCredentials | null;
55
+ }
@@ -0,0 +1,24 @@
1
+ /**
2
+ * The four credentials a storefront runs on (#2772), by the `.env` key `init`
3
+ * writes each one under — in the order the check names them and the merge
4
+ * writes them.
5
+ */
6
+ export var CliCredentialKey;
7
+ (function (CliCredentialKey) {
8
+ CliCredentialKey["CHANNEL_TOKEN"] = "FORGECART_CHANNEL_TOKEN";
9
+ CliCredentialKey["ADMIN_SECRET"] = "FORGECART_ADMIN_SECRET";
10
+ CliCredentialKey["SHOP_API_URL"] = "FORGECART_SHOP_API_URL";
11
+ CliCredentialKey["ADMIN_API_URL"] = "FORGECART_ADMIN_API_URL";
12
+ })(CliCredentialKey || (CliCredentialKey = {}));
13
+ /**
14
+ * Where an authorization stands, as the admin API's status poll answers it —
15
+ * the server's `DeviceAuthStatus` values, upper case.
16
+ */
17
+ export var CliAuthorizationState;
18
+ (function (CliAuthorizationState) {
19
+ CliAuthorizationState["PENDING"] = "PENDING";
20
+ CliAuthorizationState["APPROVED"] = "APPROVED";
21
+ CliAuthorizationState["DENIED"] = "DENIED";
22
+ CliAuthorizationState["EXPIRED"] = "EXPIRED";
23
+ })(CliAuthorizationState || (CliAuthorizationState = {}));
24
+ //# sourceMappingURL=cli-authorization.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-authorization.types.js","sourceRoot":"","sources":["../../../../src/authorization/type/cli-authorization.types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAN,IAAY,gBAKX;AALD,WAAY,gBAAgB;IAC1B,6DAAyC,CAAA;IACzC,2DAAuC,CAAA;IACvC,2DAAuC,CAAA;IACvC,6DAAyC,CAAA;AAC3C,CAAC,EALW,gBAAgB,KAAhB,gBAAgB,QAK3B;AAED;;;GAGG;AACH,MAAM,CAAN,IAAY,qBAKX;AALD,WAAY,qBAAqB;IAC/B,4CAAmB,CAAA;IACnB,8CAAqB,CAAA;IACrB,0CAAiB,CAAA;IACjB,4CAAmB,CAAA;AACrB,CAAC,EALW,qBAAqB,KAArB,qBAAqB,QAKhC"}
@@ -46,17 +46,38 @@ export declare const DEPS_READY_MARKER_PATH = ".forgecart/deps-ready.json";
46
46
  * (#2774), and the three flags every questioning command shares (#2771).
47
47
  */
48
48
  export interface InitOptions extends QuestionPromptInput, InitQuestionsInput {
49
- /** Channel token (required). */
49
+ /**
50
+ * Channel token — the pod drive's flag, hidden from the help (#2772): given,
51
+ * init writes exactly the flags it was handed and checks nothing; absent,
52
+ * init checks for the four credentials and authorizes in the browser when
53
+ * any is missing, so a merchant's secret never rides an argv.
54
+ */
50
55
  token?: string;
51
56
  /**
52
- * Channel admin secret for the storefront's server-side admin operations.
53
- * Optional at the CLI boundary (a plain storefront needs only the shop
54
- * token); the pod-provisioning path always passes it. Written to `.env`
55
- * only — never `.forgecart/config.json`, which is committable metadata.
57
+ * Channel admin secret for the storefront's server-side admin operations —
58
+ * the pod drive's flag beside `--token`, hidden; the provisioning path
59
+ * passes it whenever the channel has one. Written to `.env` only — never
60
+ * `.forgecart/config.json`, which is committable metadata.
56
61
  */
57
62
  adminSecret?: string;
58
- /** Shop API base URL. */
63
+ /**
64
+ * The admin API's GraphQL URL — the pod drive's flag beside `--token`,
65
+ * hidden. Written to `.env` as FORGECART_ADMIN_API_URL, which the scaffolded
66
+ * storefront reads verbatim rather than deriving it from the shop URL.
67
+ */
68
+ adminApiUrl?: string;
69
+ /**
70
+ * Shop API base URL. The pod drive writes it; a merchant's run requests its
71
+ * authorization from this origin's admin API when no FORGECART_ADMIN_API_URL
72
+ * is set, and writes the shop API URL the approval delivers.
73
+ */
59
74
  apiUrl: string;
75
+ /**
76
+ * `--timeout <seconds>`: the longest the browser authorization may wait for
77
+ * an approval before init exits 3. Absent, the wait is the authorization's
78
+ * own window; `0` checks and refuses without waiting.
79
+ */
80
+ timeout?: number;
60
81
  /**
61
82
  * Shop API URL for the SHOPPER'S BROWSER (the client session socket), when
62
83
  * it differs from `apiUrl`. Workspace pods have a split horizon: the pod's
@@ -93,23 +114,29 @@ export interface InitOptions extends QuestionPromptInput, InitQuestionsInput {
93
114
  * Run `forgecart init`: the credentials, then the questions, then the scaffold
94
115
  * (#2774).
95
116
  *
96
- * Resolves the channel token and the target directory, asks init's questions
97
- * ({@link InitQuestions}) — refusing, before any file is written, a template
98
- * the release does not render — scaffolds the storefront from the warmed
99
- * template of the answers' identity when one is available (see {@link
117
+ * Resolves the target directory and the channel to wire (see
118
+ * {@link resolveChannelWiring}: the pod's `--token` drive, or the credential
119
+ * check and, when it comes up short, the browser authorization), asks init's
120
+ * questions ({@link InitQuestions}) — refusing, before any file is written, a
121
+ * template the release does not render — scaffolds the storefront from the
122
+ * warmed template of the answers' identity when one is available (see {@link
100
123
  * resolveScaffoldPlan}) or the template the answers picked otherwise — or, for
101
124
  * a blank storefront, nothing at all (#2775) — writes the ForgeCart config with
102
125
  * the answers and `.env`, inventories the render under its template identity
103
126
  * with the workspace's design-system seat — the one it records, else the one
104
127
  * the answers determine (#2808) — mirrored into the config, and prints next
105
- * steps. Throws a clear Error on any failure (missing token, unrendered
106
- * template, missing template, copy failure); an unanswered question exits 2
107
- * through the question adapter's refusal.
128
+ * steps. Throws a clear Error on any failure (unrendered template, missing
129
+ * template, copy failure, an unreachable admin API), and refuses on exit 3 when
130
+ * the authorization ends unapproved; an unanswered question exits 2 through the
131
+ * question adapter's refusal.
108
132
  */
109
133
  export declare function runInit(name: string | undefined, options: InitOptions, templateSet: TemplateSet): Promise<void>;
110
134
  /**
111
135
  * Build the `init [name]` command: its own flags, its answers to its questions
112
136
  * (#2774) — validated against the release's template set, whose frameworks and
113
- * examples `--help` lists — and the question adapter's three flags.
137
+ * examples `--help` lists — and the question adapter's three flags. The pod
138
+ * drive's flags — `--token`, `--admin-secret`, `--admin-api-url` — stay
139
+ * accepted and out of the help (#2772): a merchant's run checks for its
140
+ * credentials and authorizes in the browser instead.
114
141
  */
115
142
  export declare function createInitCommand(): Command;
@@ -1,6 +1,10 @@
1
1
  import { mkdir, cp, readFile, rm, writeFile, stat } from 'node:fs/promises';
2
2
  import { join, resolve } from 'node:path';
3
- import { Command, Option } from 'commander';
3
+ import { Command, InvalidArgumentError, Option } from 'commander';
4
+ import { CliAuthorizationFlow } from '../authorization/cli-authorization-flow.js';
5
+ import { CliAuthorizationClient } from '../authorization/cli-authorization.client.js';
6
+ import { CliCredentialCheck } from '../authorization/cli-credential-check.js';
7
+ import { CliCredentialKey, } from '../authorization/type/cli-authorization.types.js';
4
8
  import { print } from '../output.js';
5
9
  import { QuestionPromptAdapter } from '../question/question-prompt.adapter.js';
6
10
  import { TemplateSet } from '../template/template-set.js';
@@ -19,6 +23,13 @@ import { inventoryTemplate, manifestTemplate, readTemplateManifest, serializeTem
19
23
  * nothing logged. Overridable via `--api-url`.
20
24
  */
21
25
  export const DEFAULT_SHOP_API_URL = 'https://api.forgecart.com/shop-api';
26
+ /**
27
+ * The admin API's path beside the shop API's on every platform origin — the
28
+ * server's `ADMIN_API_PATH`. With no FORGECART_ADMIN_API_URL to name the admin
29
+ * API outright, the authorization is requested here on the `--api-url` origin
30
+ * (#2772, ruling R2).
31
+ */
32
+ const ADMIN_API_PATH = '/admin-api';
22
33
  /**
23
34
  * Environment variable naming a dependency-warmed storefront template — a copy
24
35
  * of one bundled template with `node_modules` (and the generated
@@ -228,8 +239,8 @@ function isScaffoldAnswers(value) {
228
239
  }
229
240
  /**
230
241
  * The platform-owned `.env` keys this invocation manages, in canonical render
231
- * order. Conditional keys (browser URL, admin secret) enter the map only when
232
- * their flag is present — an existing line for an unprovided key is
242
+ * order. Conditional keys (browser URL, admin secret, admin API URL) enter the
243
+ * map only when their value is present — an existing line for an unprovided key is
233
244
  * workspace-owned for THIS run and survives untouched (#1123: the prewarmed
234
245
  * config-only path re-runs init on every provisioning drive, and a drive that
235
246
  * omits `--admin-secret` must not strip a secret an earlier drive wrote).
@@ -246,6 +257,13 @@ function buildPlatformEnv(channelToken, options) {
246
257
  if (secret) {
247
258
  entries.set('FORGECART_ADMIN_SECRET', secret);
248
259
  }
260
+ // The admin client's other half beside the secret (#2772) — conditional for
261
+ // the same #1123 reason: a drive that does not name it keeps the line an
262
+ // earlier drive or an approval wrote.
263
+ const adminApiUrl = options.adminApiUrl?.trim();
264
+ if (adminApiUrl) {
265
+ entries.set('FORGECART_ADMIN_API_URL', adminApiUrl);
266
+ }
249
267
  // Conditional for the same #1123 reason as the two above, and with a sharper
250
268
  // consequence: a preview drive omits it, and stripping an origin an earlier
251
269
  // drive wrote would silently de-index a live storefront.
@@ -452,6 +470,78 @@ function printConfigOnly(targetDir, blank) {
452
470
  print(' npm run dev');
453
471
  print('');
454
472
  }
473
+ /**
474
+ * Resolve the channel a run wires (#2772). `--token` is the pod's drive: its
475
+ * flags are the whole configuration and nothing is checked. Otherwise the four
476
+ * credentials are looked for — environment, `.env`, `.forgecart/config.json` —
477
+ * and with all four found nothing is asked; with any absent the browser
478
+ * authorization runs and its approval delivers all four. Nothing is written
479
+ * before this resolves, so an authorization that ends unapproved leaves the
480
+ * directory exactly as it found it.
481
+ */
482
+ async function resolveChannelWiring(targetDir, options) {
483
+ const token = options.token?.trim();
484
+ if (token)
485
+ return { channelToken: token, options, authorized: false };
486
+ assertNoPodDriveFlags(options);
487
+ const check = await CliCredentialCheck.read(targetDir);
488
+ const found = check.credentials();
489
+ if (found)
490
+ return wiredWith(options, found, false);
491
+ const adminApiUrl = check.value(CliCredentialKey.ADMIN_API_URL) ?? adminApiOf(options.apiUrl);
492
+ const flow = new CliAuthorizationFlow(new CliAuthorizationClient(adminApiUrl));
493
+ return wiredWith(options, await flow.authorize(check.report(), options.timeout), true);
494
+ }
495
+ /** The run's wiring once the four credentials are known: they take the seats of the flags they name. */
496
+ function wiredWith(options, credentials, authorized) {
497
+ return {
498
+ channelToken: credentials.channelToken,
499
+ options: {
500
+ ...options,
501
+ apiUrl: credentials.shopApiUrl,
502
+ adminSecret: credentials.adminSecret,
503
+ adminApiUrl: credentials.adminApiUrl,
504
+ },
505
+ authorized,
506
+ };
507
+ }
508
+ /** The pod drive's credential flags ride beside `--token` and nowhere else: a merchant's secret never rides an argv. */
509
+ function assertNoPodDriveFlags(options) {
510
+ if (options.adminSecret === undefined && options.adminApiUrl === undefined)
511
+ return;
512
+ throw new Error('--admin-secret and --admin-api-url belong to the pod drive beside --token. Export FORGECART_ADMIN_SECRET and FORGECART_ADMIN_API_URL instead, or let init authorize this machine in the browser.');
513
+ }
514
+ /** The admin API on the `--api-url` origin — the platform's fixed path pair (ruling R2). */
515
+ function adminApiOf(apiUrl) {
516
+ if (!URL.canParse(apiUrl)) {
517
+ throw new Error(`--api-url ${apiUrl} is not a URL, so the admin API to authorize against cannot be found.`);
518
+ }
519
+ return new URL(ADMIN_API_PATH, apiUrl).toString();
520
+ }
521
+ /**
522
+ * What an approval wrote, and where — printed on the run the approval landed in,
523
+ * and only there. A blank workspace (#2775) renders no template, so no template
524
+ * `.gitignore` keeps its `.env` out of a commit ({@link printEnvCommitNote}).
525
+ */
526
+ function printCredentialsWritten(authorized, blank) {
527
+ if (!authorized)
528
+ return;
529
+ print('');
530
+ print(' ✓ Wrote FORGECART_CHANNEL_TOKEN, FORGECART_ADMIN_SECRET, FORGECART_SHOP_API_URL');
531
+ printEnvCommitNote(blank);
532
+ print('');
533
+ print(' ✓ Recorded the store in .forgecart/config.json (no secrets there).');
534
+ }
535
+ /** Where the written `.env` stands against a commit: the template git-ignores it; a blank workspace has no `.gitignore`. */
536
+ function printEnvCommitNote(blank) {
537
+ if (blank) {
538
+ print(' and FORGECART_ADMIN_API_URL to .env — a blank workspace has no .gitignore,');
539
+ print(' so keep .env out of every commit.');
540
+ return;
541
+ }
542
+ print(' and FORGECART_ADMIN_API_URL to .env — which is git-ignored by the template,');
543
+ print(' so the credentials never enter a commit.');
544
+ }
455
545
  /**
456
546
  * Serve-in-place: the target is already a scaffolded workspace — a warm
457
547
  * storefront materialized from the image's pre-warmed tree (node_modules + a
@@ -461,39 +551,43 @@ function printConfigOnly(targetDir, blank) {
461
551
  * tree already has its template identity, and its config keeps the scaffold
462
552
  * record it carries and mirrors the design-system seat the workspace records
463
553
  * (#2773), settled first ({@link settleInPlaceDesignSystem}, #2808).
554
+ * The channel is resolved before any of it is written
555
+ * ({@link resolveChannelWiring}, #2772).
464
556
  */
465
- async function configureInPlace(targetDir, channelToken, options, manifest) {
557
+ async function configureInPlace(targetDir, options, manifest) {
466
558
  if (!(await isScaffolded(targetDir, manifest))) {
467
559
  throw new Error(`--config-only requires an existing workspace at ${targetDir} ` +
468
560
  '(no package.json found, and no template manifest naming a blank workspace).');
469
561
  }
562
+ const wiring = await resolveChannelWiring(targetDir, options);
470
563
  const scaffold = await readScaffoldRecord(targetDir);
471
564
  const designSystem = await settleInPlaceDesignSystem(targetDir, manifest, scaffold);
472
- await writeChannelConfig(targetDir, channelToken, options, scaffold, designSystem);
473
- printConfigOnly(targetDir, isBlankTemplate(manifestTemplate(manifest)));
565
+ await writeChannelConfig(targetDir, wiring.channelToken, wiring.options, scaffold, designSystem);
566
+ const blank = isBlankTemplate(manifestTemplate(manifest));
567
+ printCredentialsWritten(wiring.authorized, blank);
568
+ printConfigOnly(targetDir, blank);
474
569
  }
475
570
  /**
476
571
  * Run `forgecart init`: the credentials, then the questions, then the scaffold
477
572
  * (#2774).
478
573
  *
479
- * Resolves the channel token and the target directory, asks init's questions
480
- * ({@link InitQuestions}) — refusing, before any file is written, a template
481
- * the release does not render — scaffolds the storefront from the warmed
482
- * template of the answers' identity when one is available (see {@link
574
+ * Resolves the target directory and the channel to wire (see
575
+ * {@link resolveChannelWiring}: the pod's `--token` drive, or the credential
576
+ * check and, when it comes up short, the browser authorization), asks init's
577
+ * questions ({@link InitQuestions}) — refusing, before any file is written, a
578
+ * template the release does not render — scaffolds the storefront from the
579
+ * warmed template of the answers' identity when one is available (see {@link
483
580
  * resolveScaffoldPlan}) or the template the answers picked otherwise — or, for
484
581
  * a blank storefront, nothing at all (#2775) — writes the ForgeCart config with
485
582
  * the answers and `.env`, inventories the render under its template identity
486
583
  * with the workspace's design-system seat — the one it records, else the one
487
584
  * the answers determine (#2808) — mirrored into the config, and prints next
488
- * steps. Throws a clear Error on any failure (missing token, unrendered
489
- * template, missing template, copy failure); an unanswered question exits 2
490
- * through the question adapter's refusal.
585
+ * steps. Throws a clear Error on any failure (unrendered template, missing
586
+ * template, copy failure, an unreachable admin API), and refuses on exit 3 when
587
+ * the authorization ends unapproved; an unanswered question exits 2 through the
588
+ * question adapter's refusal.
491
589
  */
492
590
  export async function runInit(name, options, templateSet) {
493
- const channelToken = options.token?.trim();
494
- if (!channelToken) {
495
- throw new Error('A channel token is required. Pass it with --token <token> (or -t <token>).');
496
- }
497
591
  const targetDir = name ? resolve(process.cwd(), name) : process.cwd();
498
592
  // The workspace's own record: its identity and its design-system seat, which
499
593
  // belongs to the workspace, not to an init run — both init paths carry a seat
@@ -501,9 +595,10 @@ export async function runInit(name, options, templateSet) {
501
595
  // scaffold's answers determine where it records none (#2808).
502
596
  const manifest = await readTemplateManifest(targetDir);
503
597
  if (options.configOnly) {
504
- await configureInPlace(targetDir, channelToken, options, manifest);
598
+ await configureInPlace(targetDir, options, manifest);
505
599
  return;
506
600
  }
601
+ const wiring = await resolveChannelWiring(targetDir, options);
507
602
  const questions = new InitQuestions(templateSet, options, new QuestionPromptAdapter(options));
508
603
  const { answers, source } = await questions.ask();
509
604
  const identity = { uiFramework: answers.uiFramework, example: answers.example };
@@ -511,18 +606,29 @@ export async function runInit(name, options, templateSet) {
511
606
  const designSystem = scaffoldDesignSystem(manifest, answers);
512
607
  await mkdir(targetDir, { recursive: true });
513
608
  await landScaffold(targetDir, plan);
514
- await writeChannelConfig(targetDir, channelToken, options, answers, designSystem);
609
+ await writeChannelConfig(targetDir, wiring.channelToken, wiring.options, answers, designSystem);
515
610
  await writeDepsReadyMarker(targetDir, plan);
516
611
  // Inventory the render for `forgecart refresh` (#1116) under the template
517
612
  // identity it re-renders from (#2774), recording the workspace's
518
613
  // design-system seat (#2773) under the stamp its config mirrors.
519
614
  await writeTemplateManifest(targetDir, await inventoryOf(plan), readPackageVersion(), identity, designSystem);
615
+ printCredentialsWritten(wiring.authorized, plan.source === 'blank');
520
616
  printScaffolded(name ?? '.', options.application ?? false, plan);
521
617
  }
618
+ /** `--timeout`: whole seconds, zero included. */
619
+ function parseTimeoutSeconds(value) {
620
+ if (!/^\d+$/.test(value)) {
621
+ throw new InvalidArgumentError('Pass a whole number of seconds (0 waits for no approval).');
622
+ }
623
+ return Number(value);
624
+ }
522
625
  /**
523
626
  * Build the `init [name]` command: its own flags, its answers to its questions
524
627
  * (#2774) — validated against the release's template set, whose frameworks and
525
- * examples `--help` lists — and the question adapter's three flags.
628
+ * examples `--help` lists — and the question adapter's three flags. The pod
629
+ * drive's flags — `--token`, `--admin-secret`, `--admin-api-url` — stay
630
+ * accepted and out of the help (#2772): a merchant's run checks for its
631
+ * credentials and authorizes in the browser instead.
526
632
  */
527
633
  export function createInitCommand() {
528
634
  const templateSet = TemplateSet.shipped();
@@ -531,11 +637,13 @@ export function createInitCommand() {
531
637
  const command = new Command('init')
532
638
  .description('Scaffold a ForgeCart storefront in the target directory')
533
639
  .argument('[name]', 'Target directory name (defaults to the current directory)')
534
- .option('-t, --token <token>', 'ForgeCart channel token (required)')
535
- .option('--admin-secret <secret>', 'Channel admin secret for server-side admin operations (written to .env only)')
536
- .option('--api-url <url>', 'Shop API base URL written to the storefront environment', DEFAULT_SHOP_API_URL)
640
+ .addOption(new Option('-t, --token <token>', 'Channel token — the pod drive; a merchant authorizes in the browser instead').hideHelp())
641
+ .addOption(new Option('--admin-secret <secret>', 'Channel admin secret beside --token (written to .env only)').hideHelp())
642
+ .addOption(new Option('--admin-api-url <url>', 'Admin API URL beside --token (written to .env)').hideHelp())
643
+ .option('--api-url <url>', 'Shop API base URL; its admin API answers the authorization when FORGECART_ADMIN_API_URL is unset', DEFAULT_SHOP_API_URL)
537
644
  .option('--browser-api-url <url>', 'Shop API URL for the shopper browser when it differs from --api-url (split-horizon pods; must be HTTPS so the session socket can use WSS)')
538
645
  .option('--public-origin <url>', 'Public origin the storefront is served at (https://shop.example.com). Omit for preview deployments: without it every route is noindex and robots.txt disallows the whole tree')
646
+ .addOption(new Option('--timeout <seconds>', 'Seconds the browser authorization waits for an approval before init exits 3 (default: the authorization window; 0 waits for none)').argParser(parseTimeoutSeconds))
539
647
  .option('-a, --application', 'Also scaffold a NestJS application (TODO: next phase)')
540
648
  .option('--config-only', 'Write only per-channel config into an existing pre-warmed storefront (skip the template copy and the questions)')
541
649
  .addOption(ui.choices(templateSet.uiFrameworkIds))
@@ -1 +1 @@
1
- {"version":3,"file":"init.js","sourceRoot":"","sources":["../../../src/commands/init.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAC5E,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAE1C,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAE5C,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,qBAAqB,EAAE,MAAM,wCAAwC,CAAC;AAE/E,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAE1D,OAAO,E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G,IAAI,OAAO,CAAC,MAAM,CAAC;SAChC,WAAW,CAAC,yDAAyD,CAAC;SACtE,QAAQ,CAAC,QAAQ,EAAE,2DAA2D,CAAC;SAC/E,SAAS,CACR,IAAI,MAAM,CACR,qBAAqB,EACrB,6EAA6E,CAC9E,CAAC,QAAQ,EAAE,CACb;SACA,SAAS,CACR,IAAI,MAAM,CACR,yBAAyB,EACzB,4DAA4D,CAC7D,CAAC,QAAQ,EAAE,CACb;SACA,SAAS,CACR,IAAI,MAAM,CAAC,uBAAuB,EAAE,gDAAgD,CAAC,CAAC,QAAQ,EAAE,CACjG;SACA,MAAM,CACL,iBAAiB,EACjB,kGAAkG,EAClG,oBAAoB,CACrB;SACA,MAAM,CACL,yBAAyB,EACzB,2IAA2I,CAC5I;SACA,MAAM,CACL,uBAAuB,EACvB,+KAA+K,CAChL;SACA,SAAS,CACR,IAAI,MAAM,CACR,qBAAqB,EACrB,mIAAmI,CACpI,CAAC,SAAS,CAAC,mBAAmB,CAAC,CACjC;SACA,MAAM,CAAC,mBAAmB,EAAE,uDAAuD,CAAC;SACpF,MAAM,CACL,eAAe,EACf,iHAAiH,CAClH;SACA,SAAS,CAAC,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC;SACjD,SAAS,CAAC,OAAO,CAAC,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;SAClD,MAAM,CAAC,WAAW,EAAE,iEAAiE,CAAC;SACtF,MAAM,CAAC,cAAc,EAAE,wBAAwB,CAAC;SAChD,MAAM,CAAC,KAAK,EAAE,IAAwB,EAAE,OAAoB,EAAE,EAAE;QAC/D,MAAM,OAAO,CAAC,IAAI,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;IAC5C,CAAC,CAAC,CAAC;IACL,OAAO,qBAAqB,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC;AACxD,CAAC"}
@@ -11,7 +11,14 @@ export declare enum CliExitLadder {
11
11
  * something is missing, and a caller supplies it with `--answer`,
12
12
  * `--answers-file` or `--yes`.
13
13
  */
14
- questionUnanswered = 2
14
+ questionUnanswered = 2,
15
+ /**
16
+ * No credentials, and no approval to deliver them (#2772): the browser
17
+ * authorization was denied, expired, or outlasted its wait. Nothing is broken
18
+ * and nobody has said yes yet; a caller supplies the four `FORGECART_*` keys
19
+ * in the environment or approves the authorization.
20
+ */
21
+ unauthorized = 3
15
22
  }
16
23
  /**
17
24
  * The CLI stopping for a reason that is not an error, on its own rung of
@@ -13,6 +13,13 @@ export var CliExitLadder;
13
13
  * `--answers-file` or `--yes`.
14
14
  */
15
15
  CliExitLadder[CliExitLadder["questionUnanswered"] = 2] = "questionUnanswered";
16
+ /**
17
+ * No credentials, and no approval to deliver them (#2772): the browser
18
+ * authorization was denied, expired, or outlasted its wait. Nothing is broken
19
+ * and nobody has said yes yet; a caller supplies the four `FORGECART_*` keys
20
+ * in the environment or approves the authorization.
21
+ */
22
+ CliExitLadder[CliExitLadder["unauthorized"] = 3] = "unauthorized";
16
23
  })(CliExitLadder || (CliExitLadder = {}));
17
24
  /**
18
25
  * The CLI stopping for a reason that is not an error, on its own rung of
@@ -1 +1 @@
1
- {"version":3,"file":"exit-ladder.js","sourceRoot":"","sources":["../../src/exit-ladder.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAN,IAAY,aASX;AATD,WAAY,aAAa;IACvB,4EAA4E;IAC5E,mDAAS,CAAA;IACT;;;;OAIG;IACH,6EAAsB,CAAA;AACxB,CAAC,EATW,aAAa,KAAb,aAAa,QASxB;AAED;;;;GAIG;AACH,MAAM,OAAO,UAAW,SAAQ,KAAK;IAExB;IACA;IAFX,YACW,QAAuB,EACvB,KAAwB;QAEjC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;QAHf,aAAQ,GAAR,QAAQ,CAAe;QACvB,UAAK,GAAL,KAAK,CAAmB;QAGjC,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC3B,CAAC;CACF"}
1
+ {"version":3,"file":"exit-ladder.js","sourceRoot":"","sources":["../../src/exit-ladder.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAN,IAAY,aAgBX;AAhBD,WAAY,aAAa;IACvB,4EAA4E;IAC5E,mDAAS,CAAA;IACT;;;;OAIG;IACH,6EAAsB,CAAA;IACtB;;;;;OAKG;IACH,iEAAgB,CAAA;AAClB,CAAC,EAhBW,aAAa,KAAb,aAAa,QAgBxB;AAED;;;;GAIG;AACH,MAAM,OAAO,UAAW,SAAQ,KAAK;IAExB;IACA;IAFX,YACW,QAAuB,EACvB,KAAwB;QAEjC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;QAHf,aAAQ,GAAR,QAAQ,CAAe;QACvB,UAAK,GAAL,KAAK,CAAmB;QAGjC,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC3B,CAAC;CACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forgecart/cli",
3
- "version": "2.202610071755.0",
3
+ "version": "2.202610082355.0",
4
4
  "type": "module",
5
5
  "description": "CLI for scaffolding and operating ForgeCart channel storefronts",
6
6
  "bin": {