@codapult/cli 0.14.4 → 0.15.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.
@@ -22,6 +22,8 @@ const BUILT_IN_PRESETS = {
22
22
  // Showcase / marketing-only site.
23
23
  marketing: {
24
24
  authProvider: 'none',
25
+ jobProvider: 'none',
26
+ ssoProvider: 'none',
25
27
  enableAuth: false,
26
28
  enableAI: false,
27
29
  enableTeams: false,
@@ -60,6 +62,7 @@ const DEFAULT_CONFIG = {
60
62
  appName: 'Codapult',
61
63
  appUrl: 'http://localhost:3000',
62
64
  authProvider: 'better-auth',
65
+ ssoProvider: 'none',
63
66
  paymentProvider: 'stripe',
64
67
  storageProvider: 'local',
65
68
  jobProvider: 'memory',
@@ -69,7 +72,7 @@ const DEFAULT_CONFIG = {
69
72
  enableTeams: true,
70
73
  enableWaitlist: true,
71
74
  enableGraphQL: true,
72
- enableSSO: true,
75
+ enableSSO: false,
73
76
  enableApiDocs: true,
74
77
  enableHelpCenter: true,
75
78
  enableExperiments: true,
@@ -463,7 +466,6 @@ const FEATURE_ENV_VARS = {
463
466
  enableReferrals: 'ENABLE_REFERRALS',
464
467
  enableAnalytics: 'ENABLE_ANALYTICS',
465
468
  enableWorkflows: 'ENABLE_WORKFLOWS',
466
- enableSSO: 'ENABLE_SSO',
467
469
  enableExperiments: 'ENABLE_EXPERIMENTS',
468
470
  enableDripCampaigns: 'ENABLE_DRIP_CAMPAIGNS',
469
471
  enableOnboarding: 'ENABLE_ONBOARDING',
@@ -670,24 +672,28 @@ async function interactiveSetup() {
670
672
  'kinde',
671
673
  'none',
672
674
  ]);
675
+ const ssoProvider = await selectPrompt(iface, 'SSO provider (Enterprise SSO (SAML)):', ['jackson', 'none']);
673
676
  const authEnabled = authProvider !== 'none';
677
+ const ssoEnabled = authEnabled && ssoProvider !== 'none';
674
678
  const config = {
675
679
  appName,
676
680
  appUrl,
677
681
  authProvider,
678
- paymentProvider: await selectPrompt(iface, 'Payment provider:', ['stripe', 'lemonsqueezy']),
682
+ ssoProvider,
683
+ paymentProvider: await selectPrompt(iface, 'Payment provider:', ['stripe', 'lemonsqueezy', 'polar']),
679
684
  storageProvider: await selectPrompt(iface, 'Storage provider:', ['local', 's3']),
680
685
  jobProvider: await selectPrompt(iface, 'Background jobs:', [
681
686
  'memory',
682
687
  'bullmq',
688
+ 'none',
683
689
  ]),
684
690
  enableAuth: authEnabled,
691
+ enableSSO: ssoEnabled,
685
692
  enableAI: emptyLine() && (await confirm(iface, 'Enable AI Chat module?')),
686
693
  enableBlog: await confirm(iface, 'Enable Blog module?'),
687
694
  enableTeams: authEnabled && (await confirm(iface, 'Enable Teams/Organizations?')),
688
695
  enableWaitlist: await confirm(iface, 'Enable Waitlist page?'),
689
696
  enableGraphQL: await confirm(iface, 'Enable GraphQL API layer?'),
690
- enableSSO: authEnabled && (await confirm(iface, 'Enable Enterprise SSO (SAML)?')),
691
697
  enableApiDocs: await confirm(iface, 'Enable interactive API docs?'),
692
698
  enableHelpCenter: await confirm(iface, 'Enable Documentation module?'),
693
699
  enableExperiments: await confirm(iface, 'Enable A/B Testing?'),
@@ -17,7 +17,7 @@ export function registerResources(server) {
17
17
  });
18
18
  server.registerResource('codapult_app_config', 'codapult://config/app', {
19
19
  title: 'App Configuration',
20
- description: `Application config (src/config/app.ts) — brand, AI, company. Feature toggles and auth methods live in src/lib/config.ts — see codapult://config/env.`,
20
+ description: `Application config (src/config/app.ts) — brand, AI, company. Feature toggles and auth methods live in src/config/env.ts — see codapult://config/env.`,
21
21
  mimeType: 'text/plain',
22
22
  }, () => {
23
23
  const content = readProjectFile(getRoot(), 'src/config/app.ts') ?? 'Config file not found';
@@ -27,10 +27,10 @@ export function registerResources(server) {
27
27
  });
28
28
  server.registerResource('codapult_env_config', 'codapult://config/env', {
29
29
  title: 'Environment Configuration',
30
- description: `Typed env access (src/lib/config.ts) — feature toggles (env.features), auth methods (env.auth), provider selection (dbProvider, paymentProvider, storageProvider, jobProvider), and checkout resolution. This is the source of truth for which modules are enabled — see also codapult://env-example or codapult_project_status.`,
30
+ description: `Typed env access (src/config/env.ts) — feature toggles (env.features), auth methods (env.auth), provider selection (dbProvider, paymentProvider, storageProvider, jobProvider), and checkout resolution. This is the source of truth for which modules are enabled — see also codapult://env-example or codapult_project_status.`,
31
31
  mimeType: 'text/plain',
32
32
  }, () => {
33
- const content = readProjectFile(getRoot(), 'src/lib/config.ts') ?? 'Config file not found';
33
+ const content = readProjectFile(getRoot(), 'src/config/env.ts') ?? 'Config file not found';
34
34
  return {
35
35
  contents: [{ uri: 'codapult://config/env', text: content, mimeType: 'text/plain' }],
36
36
  };
@@ -1,18 +1,19 @@
1
1
  /**
2
- * Shared, read-only mirror of `src/lib/config.ts` from the host project.
2
+ * Shared, read-only mirror of `src/config/env.ts` from the host project.
3
3
  *
4
4
  * Keep this file in sync with the host's `env.features`, `env.auth`,
5
5
  * provider enums, and the `superRefine` validation in
6
- * `codapult/src/lib/config.ts`. The CLI cannot import from the host project,
7
- * so this module centralises the provider/feature shape that several
8
- * commands share regardless of whether env values come from `.env.local` or
9
- * `process.env`.
6
+ * `codapult/src/config/env.ts` and `codapult/src/config/env-schema.ts`.
7
+ * The CLI cannot import from the host project, so this module centralises
8
+ * the provider/feature shape that several commands share regardless of whether
9
+ * env values come from `.env.local` or `process.env`.
10
10
  */
11
11
  export type DbProvider = 'turso' | 'postgres';
12
12
  export type AuthProvider = 'better-auth' | 'kinde' | 'none';
13
13
  export type PaymentProvider = 'stripe' | 'lemonsqueezy' | 'polar';
14
+ export type SSOProvider = 'jackson' | 'none';
14
15
  export type StorageProvider = 'local' | 's3' | 'r2';
15
- export type JobProvider = 'memory' | 'bullmq';
16
+ export type JobProvider = 'memory' | 'bullmq' | 'none';
16
17
  export type NotificationTransport = 'poll' | 'sse' | 'ws';
17
18
  export type EmbeddingProvider = 'openai' | 'ollama';
18
19
  export type VectorStoreProvider = 'sqlite' | 'memory';
@@ -29,6 +30,7 @@ export declare function readEnv<T extends string>(envContent: string, key: strin
29
30
  export interface Adapters {
30
31
  database: DbProvider;
31
32
  auth: AuthProvider;
33
+ sso: SSOProvider;
32
34
  payments: PaymentProvider;
33
35
  storage: StorageProvider;
34
36
  jobs: JobProvider;
@@ -40,7 +42,7 @@ export interface Adapters {
40
42
  export declare function getAdapters(envContent: string): Adapters;
41
43
  /**
42
44
  * Compute the effective set of feature toggles from .env content.
43
- * Mirrors `env.features` in `codapult/src/lib/config.ts`:
45
+ * Mirrors `env.features` in `codapult/src/config/env.ts`:
44
46
  * - default `true` for every ENABLE_* (unset → enabled);
45
47
  * - explicit "false" disables;
46
48
  * - `auth` derived from AUTH_PROVIDER !== 'none';
@@ -1,12 +1,12 @@
1
1
  /**
2
- * Shared, read-only mirror of `src/lib/config.ts` from the host project.
2
+ * Shared, read-only mirror of `src/config/env.ts` from the host project.
3
3
  *
4
4
  * Keep this file in sync with the host's `env.features`, `env.auth`,
5
5
  * provider enums, and the `superRefine` validation in
6
- * `codapult/src/lib/config.ts`. The CLI cannot import from the host project,
7
- * so this module centralises the provider/feature shape that several
8
- * commands share regardless of whether env values come from `.env.local` or
9
- * `process.env`.
6
+ * `codapult/src/config/env.ts` and `codapult/src/config/env-schema.ts`.
7
+ * The CLI cannot import from the host project, so this module centralises
8
+ * the provider/feature shape that several commands share regardless of whether
9
+ * env values come from `.env.local` or `process.env`.
10
10
  */
11
11
  /** Feature toggle key → ENABLE_* env var. Order = display order. */
12
12
  export const FEATURE_ENV = {
@@ -26,7 +26,6 @@ export const FEATURE_ENV = {
26
26
  reports: 'ENABLE_REPORTS',
27
27
  onboarding: 'ENABLE_ONBOARDING',
28
28
  branding: 'ENABLE_BRANDING',
29
- sso: 'ENABLE_SSO',
30
29
  experiments: 'ENABLE_EXPERIMENTS',
31
30
  dripCampaigns: 'ENABLE_DRIP_CAMPAIGNS',
32
31
  plugins: 'ENABLE_PLUGINS',
@@ -64,6 +63,7 @@ export function getAdapters(envContent) {
64
63
  return {
65
64
  database: readEnv(envContent, 'DB_PROVIDER', 'turso'),
66
65
  auth: readEnv(envContent, 'AUTH_PROVIDER', 'better-auth'),
66
+ sso: readEnv(envContent, 'SSO_PROVIDER', 'none'),
67
67
  payments: readEnv(envContent, 'PAYMENT_PROVIDER', 'stripe'),
68
68
  storage: readEnv(envContent, 'STORAGE_PROVIDER', 'local'),
69
69
  jobs: readEnv(envContent, 'JOB_PROVIDER', 'memory'),
@@ -74,7 +74,7 @@ export function getAdapters(envContent) {
74
74
  }
75
75
  /**
76
76
  * Compute the effective set of feature toggles from .env content.
77
- * Mirrors `env.features` in `codapult/src/lib/config.ts`:
77
+ * Mirrors `env.features` in `codapult/src/config/env.ts`:
78
78
  * - default `true` for every ENABLE_* (unset → enabled);
79
79
  * - explicit "false" disables;
80
80
  * - `auth` derived from AUTH_PROVIDER !== 'none';
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@codapult/cli",
3
- "version": "0.14.4",
3
+ "version": "0.15.0",
4
4
  "description": "Codapult CLI — manage, update, and diagnose your Codapult SaaS project",
5
5
  "license": "MIT",
6
- "packageManager": "pnpm@11.15.0+sha512.266f8957a30d2be6e9468e5e66bcdedd35a794175f71b067ba8504d686cce1d0c0f429b33c323c3c569ad4891e667574a49ff71d1b89a22cc66f13c65818c578",
6
+ "packageManager": "pnpm@11.20.0+sha512.9a6f330a95b66446ea088faf1521405a8a01f07fde7124cc9958dfed52d4bb436737e65b08f85f37b46fcba375092558ac51262b816844b22f63406ed166bfee",
7
7
  "engines": {
8
8
  "node": ">=20.19.0"
9
9
  },
@@ -43,7 +43,7 @@
43
43
  "access": "public"
44
44
  },
45
45
  "dependencies": {
46
- "@modelcontextprotocol/sdk": "^1.29.0",
46
+ "@modelcontextprotocol/sdk": "^1.30.0",
47
47
  "commander": "^15.0.0",
48
48
  "picocolors": "^1.1.1",
49
49
  "zod": "^4.4.3"
@@ -54,14 +54,14 @@
54
54
  "@js-toolkit/prettier-config": "^1.0.1",
55
55
  "@js-toolkit/tsconfig": "^1.0.1",
56
56
  "@release-it/conventional-changelog": "^11.0.1",
57
- "@types/node": "^26.1.1",
57
+ "@types/node": "^26.2.0",
58
58
  "eslint": "^9.39.4",
59
59
  "eslint-config-prettier": "^10.1.8",
60
60
  "eslint-plugin-prettier": "^5.5.6",
61
- "prettier": "^3.9.5",
62
- "release-it": "^20.2.1",
61
+ "prettier": "^3.9.6",
62
+ "release-it": "^21.0.1",
63
63
  "typescript": "^6.0.3",
64
- "typescript-eslint": "^8.64.0",
64
+ "typescript-eslint": "^8.66.0",
65
65
  "vitest": "^4.1.10"
66
66
  }
67
67
  }