@kya-os/create-mcpi-app 1.7.42-canary.6 → 1.7.42-canary.61

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.
@@ -1,91 +1,25 @@
1
1
 
2
- > @kya-os/create-mcpi-app@1.7.42-canary.2 test /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/create-mcpi-app
3
- > vitest --run
4
-
5
- ▲ [WARNING] The condition "types" here will never be used as it comes after both "import" and "require" [package.json]
6
-
7
- package.json:15:6:
8
- 15 │ "types": "./dist/index.d.ts"
9
- ╵ ~~~~~~~
10
-
11
- The "import" condition comes earlier and will be used for all "import" statements:
12
-
13
- package.json:13:6:
14
- 13 │ "import": "./dist/index.js",
15
- ╵ ~~~~~~~~
16
-
17
- The "require" condition comes earlier and will be used for all "require" calls:
18
-
19
- package.json:14:6:
20
- 14 │ "require": "./dist/index.js",
21
- ╵ ~~~~~~~~~
22
-
23
- ▲ [WARNING] The condition "types" here will never be used as it comes after both "import" and "require" [package.json]
24
-
25
- package.json:20:6:
26
- 20 │ "types": "./dist/helpers/config-builder.d.ts"
27
- ╵ ~~~~~~~
28
-
29
- The "import" condition comes earlier and will be used for all "import" statements:
30
-
31
- package.json:18:6:
32
- 18 │ "import": "./dist/helpers/config-builder.js",
33
- ╵ ~~~~~~~~
34
-
35
- The "require" condition comes earlier and will be used for all "require" calls:
36
-
37
- package.json:19:6:
38
- 19 │ "require": "./dist/helpers/config-builder.js",
39
- ╵ ~~~~~~~~~
2
+ > @kya-os/create-mcpi-app@1.7.42-canary.55 test /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/create-mcpi-app
3
+ > vitest run
40
4
 
41
5
 
42
6
  RUN v4.0.5 /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/create-mcpi-app
43
7
 
44
- ✓ test-cloudflare/tests/cors-security.test.ts (29 tests) 3ms
45
8
  stdout | test-cloudflare/tests/session-management.test.ts > Session Management > Session Security > should not expose session data in logs
46
9
  [Session] Created session: secure-session
47
10
 
48
- ✓ test-cloudflare/tests/session-management.test.ts (17 tests) 18ms
49
- ✓ test-cloudflare/tests/delegation.test.ts (12 tests) 4ms
50
- ✓ test-cloudflare/tests/cache-invalidation.test.ts (18 tests) 16ms
11
+ ✓ test-cloudflare/tests/session-management.test.ts (17 tests) 15ms
12
+ ✓ test-cloudflare/tests/delegation.test.ts (12 tests) 5ms
13
+ ✓ test-cloudflare/tests/cache-invalidation.test.ts (18 tests) 5ms
14
+ ✓ test-cloudflare/tests/do-routing.test.ts (14 tests) 203ms
15
+ ✓ src/utils/__tests__/fetch-remote-config.test.ts (9 tests) 4ms
16
+ ✓ test-cloudflare/tests/cors-security.test.ts (29 tests) 3ms
17
+ ✓ src/__tests__/helpers/generate-identity.test.ts (24 tests) 32ms
18
+ ✓ src/__tests__/helpers/generate-config.test.ts (25 tests) 75ms
51
19
  stderr | src/helpers/__tests__/config-builder.spec.ts > buildConfigWithRemote > should fallback to local config when remote fetch fails
52
20
  [RemoteConfig] Neither projectId nor agentDid provided
53
21
 
54
- stderr | src/utils/__tests__/fetch-remote-config.test.ts > fetchRemoteConfig > Error handling > should return null if API request fails
55
- [RemoteConfig] API returned 404: Not Found
56
-
57
- stderr | src/utils/__tests__/fetch-remote-config.test.ts > fetchRemoteConfig > Error handling > should return null if API throws error
58
- [RemoteConfig] Failed to fetch config: Error: Network error
59
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/create-mcpi-app/src/utils/__tests__/fetch-remote-config.test.ts:173:35
60
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
61
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
62
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
63
- at new Promise (<anonymous>)
64
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
65
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
66
- at processTicksAndRejections (node:internal/process/task_queues:103:5)
67
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
68
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
69
-
70
- stderr | src/utils/__tests__/fetch-remote-config.test.ts > fetchRemoteConfig > Error handling > should return null if neither projectId nor agentDid provided
71
- [RemoteConfig] Neither projectId nor agentDid provided
72
-
73
- stderr | src/utils/__tests__/fetch-remote-config.test.ts > fetchRemoteConfig > Error handling > should handle cache read errors gracefully
74
- [RemoteConfig] Cache read failed: Error: Cache error
75
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/create-mcpi-app/src/utils/__tests__/fetch-remote-config.test.ts:201:50
76
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
77
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
78
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
79
- at new Promise (<anonymous>)
80
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
81
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
82
- at processTicksAndRejections (node:internal/process/task_queues:103:5)
83
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
84
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
85
-
86
22
  ✓ src/helpers/__tests__/config-builder.spec.ts (12 tests) 4ms
87
- ✓ src/utils/__tests__/fetch-remote-config.test.ts (9 tests) 5ms
88
- ✓ test-cloudflare/tests/do-routing.test.ts (14 tests) 153ms
89
23
  stdout | src/__tests__/helpers/install.test.ts > install > Dependency installation > should install dependencies with npm
90
24
 
91
25
  📦 Installing dependencies with npm...
@@ -102,63 +36,61 @@ stdout | src/__tests__/helpers/install.test.ts > install > Dependency installati
102
36
  ✓ Lockfile created (pnpm-lock.yaml) - remember to commit it
103
37
 
104
38
  stdout | src/__tests__/helpers/install.test.ts > install > Dependency installation > should use correct working directory
105
- stderr | src/__tests__/helpers/install.test.ts > install > Install progress reporting > should report correct package manager in log
106
39
 
107
40
  📦 Installing dependencies with npm...
108
- ⚠️ Warning: No lockfile generated (pnpm-lock.yaml)
109
41
  ✓ Lockfile created (package-lock.json) - remember to commit it
110
42
 
111
-
43
+ ✓ src/__tests__/helpers/validate-project-structure.test.ts (23 tests) 113ms
112
44
  stdout | src/__tests__/helpers/install.test.ts > install > Install progress reporting > should check for lockfile after installation
113
45
 
46
+ stderr | src/__tests__/helpers/install.test.ts > install > Install progress reporting > should report correct package manager in log
114
47
  📦 Installing dependencies with npm...
115
48
  ✓ Lockfile created (package-lock.json) - remember to commit it
116
49
 
117
- ✓ src/__tests__/helpers/generate-identity.test.ts (24 tests) 115ms
118
50
  stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should throw error when installation fails
119
51
 
52
+ ⚠️ Warning: No lockfile generated (pnpm-lock.yaml)
53
+
120
54
  stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should throw error when installation fails
121
55
  📦 Installing dependencies with npm...
122
56
 
57
+ stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should handle network errors during installation
123
58
  Failed to install dependencies with npm.
124
59
 
60
+
61
+ 📦 Installing dependencies with npm...
125
62
  stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should handle network errors during installation
126
63
  Failed to install dependencies with npm.
127
- stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should handle network errors during installation
128
64
 
65
+ stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should handle permission errors during installation
66
+ Failed to install dependencies with npm.
129
67
 
130
- 📦 Installing dependencies with npm...
131
68
 
132
- stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should handle permission errors during installation
133
69
  stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should handle permission errors during installation
134
70
 
135
71
  📦 Installing dependencies with npm...
136
72
 
137
73
  stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should log error message when installation fails
138
- Failed to install dependencies with npm.
139
-
140
74
 
141
75
  📦 Installing dependencies with npm...
142
76
 
143
- stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should handle invalid package manager gracefully
144
- ⚠️ Warning: Unknown package manager "unknown", cannot check lockfile
145
-
146
77
  stdout | src/__tests__/helpers/install.test.ts > install > Error handling > should handle invalid package manager gracefully
147
78
 
79
+ stderr | src/__tests__/helpers/install.test.ts > install > Error handling > should handle invalid package manager gracefully
80
+ ⚠️ Warning: Unknown package manager "unknown", cannot check lockfile
148
81
  📦 Installing dependencies with unknown...
149
82
 
83
+
150
84
  stdout | src/__tests__/helpers/install.test.ts > install > Lockfile validation > should warn when lockfile not created
151
85
 
152
86
  📦 Installing dependencies with npm...
153
87
 
154
- ✓ src/__tests__/helpers/install.test.ts (20 tests) 157ms
155
- ✓ src/__tests__/helpers/generate-config.test.ts (25 tests) 356ms
156
- ✓ src/__tests__/helpers/validate-project-structure.test.ts (23 tests) 278ms
157
- ✓ src/__tests__/helpers/fetch-cloudflare-mcpi-template.test.ts (21 tests) 438ms
158
- ✓ src/__tests__/cloudflare-template.test.ts (24 tests) 428ms
88
+ ✓ src/__tests__/helpers/install.test.ts (20 tests) 45ms
89
+ ✓ src/__tests__/helpers/fetch-cloudflare-mcpi-template.test.ts (21 tests) 805ms
90
+ ✓ src/__tests__/cloudflare-template.test.ts (30 tests | 2 skipped) 1304ms
159
91
 
160
92
  Test Files 13 passed (13)
161
- Tests 248 passed (248)
162
- Start at 13:13:08
163
- Duration 1.15s (transform 946ms, setup 0ms, collect 2.06s, tests 1.97s, environment 1ms, prepare 108ms)
93
+ Tests 252 passed | 2 skipped (254)
94
+ Start at 23:09:55
95
+ Duration 3.36s (transform 3.79s, setup 0ms, collect 5.64s, tests 2.61s, environment 1ms, prepare 512ms)
164
96
 
@@ -1,14 +1,25 @@
1
- interface CloudflareMcpiTemplateOptions {
2
- packageManager?: string;
3
- projectName?: string;
1
+ interface CloudflareTemplateOptions {
2
+ packageManager: string;
3
+ projectName: string;
4
4
  apikey?: string;
5
5
  projectId?: string;
6
6
  skipIdentity?: boolean;
7
+ skipCommands?: boolean;
7
8
  }
8
9
  /**
9
- * Scaffold Cloudflare Worker MCP server
10
- * Uses McpAgent from agents/mcp for MCP protocol support
10
+ * Fetches the Cloudflare MCP-I template
11
+ *
12
+ * Generates a complete project structure:
13
+ * - package.json with all scripts
14
+ * - wrangler.toml with all KV namespaces configured
15
+ * - .dev.vars with all secrets
16
+ * - src/index.ts
17
+ * - src/agent.ts
18
+ * - src/tools/greet.ts
19
+ * - src/mcpi-runtime-config.ts
20
+ * - scripts/setup.js for KV namespace creation and key regeneration
21
+ * - Automatically runs setup to create KV namespaces
11
22
  */
12
- export declare function fetchCloudflareMcpiTemplate(projectPath: string, options?: CloudflareMcpiTemplateOptions): Promise<void>;
23
+ export declare function fetchCloudflareMcpiTemplate(targetDir: string, options: CloudflareTemplateOptions | string): Promise<void>;
13
24
  export {};
14
25
  //# sourceMappingURL=fetch-cloudflare-mcpi-template.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fetch-cloudflare-mcpi-template.d.ts","sourceRoot":"","sources":["../../src/helpers/fetch-cloudflare-mcpi-template.ts"],"names":[],"mappings":"AAKA,UAAU,6BAA6B;IACrC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED;;;GAGG;AACH,wBAAsB,2BAA2B,CAC/C,WAAW,EAAE,MAAM,EACnB,OAAO,GAAE,6BAAkC,GAC1C,OAAO,CAAC,IAAI,CAAC,CAyyCf"}
1
+ {"version":3,"file":"fetch-cloudflare-mcpi-template.d.ts","sourceRoot":"","sources":["../../src/helpers/fetch-cloudflare-mcpi-template.ts"],"names":[],"mappings":"AAOA,UAAU,yBAAyB;IACjC,cAAc,EAAE,MAAM,CAAC;IACvB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAsB,2BAA2B,CAC/C,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,yBAAyB,GAAG,MAAM,GAC1C,OAAO,CAAC,IAAI,CAAC,CA6uBf"}