@frontera-sdk/cli 1.53.3 → 1.53.4
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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@frontera-sdk/cli",
|
|
3
|
-
"version": "1.53.
|
|
3
|
+
"version": "1.53.4",
|
|
4
4
|
"description": "The frontera CLI — scaffold, pull, save and deploy Frontera apps and automations.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"frontera",
|
|
@@ -40,8 +40,8 @@
|
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@anthropic-ai/claude-agent-sdk": "^0.3.251",
|
|
42
42
|
"@faker-js/faker": "10.6.0",
|
|
43
|
-
"@frontera-sdk/core": "1.53.
|
|
44
|
-
"@frontera-sdk/functions": "1.53.
|
|
43
|
+
"@frontera-sdk/core": "1.53.4",
|
|
44
|
+
"@frontera-sdk/functions": "1.53.4",
|
|
45
45
|
"ai": "^6.0.116",
|
|
46
46
|
"axe-core": "4.12.1",
|
|
47
47
|
"gray-matter": "^4.0.3",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"yaml": "^2.9.0"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
|
-
"@frontera-sdk/forge-contracts": "1.53.
|
|
52
|
+
"@frontera-sdk/forge-contracts": "1.53.4",
|
|
53
53
|
"@types/bun": "^1.3.14",
|
|
54
54
|
"typescript": "^5.9.3"
|
|
55
55
|
}
|
|
@@ -9,15 +9,24 @@ import type { Command } from '../types'
|
|
|
9
9
|
*
|
|
10
10
|
* A server is authored as `mcp-servers/<slug>.yaml` in a project and saved by
|
|
11
11
|
* `frontera local dev`, which also archives one whose file was removed. These
|
|
12
|
-
* commands cover the rest: seeing what a workspace serves and where a
|
|
13
|
-
* connects, why a tool is left out for you, and archiving a server the
|
|
14
|
-
* never had a file for.
|
|
12
|
+
* commands cover the rest: seeing what a workspace serves and where and how a
|
|
13
|
+
* client connects, why a tool is left out for you, and archiving a server the
|
|
14
|
+
* project never had a file for.
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
+
/** How a client connects: signing in with a Frontera account, or a key where sign-in is not offered. */
|
|
18
|
+
export function connectHow(server: { signIn?: boolean }): string {
|
|
19
|
+
return server.signIn === false
|
|
20
|
+
? 'with the runtime\'s workspace key (signing in with a Frontera account is not available on a local runtime)'
|
|
21
|
+
: 'by signing in with your Frontera account from the client, or with a workspace key'
|
|
22
|
+
}
|
|
23
|
+
|
|
17
24
|
interface McpServerRow {
|
|
18
25
|
slug?: string
|
|
19
26
|
name?: string
|
|
20
27
|
url?: string
|
|
28
|
+
/** Whether a person can connect by signing in with their Frontera account; false on a local runtime. */
|
|
29
|
+
signIn?: boolean
|
|
21
30
|
revision?: number
|
|
22
31
|
tools?: Array<{ name?: string; kind?: string; target?: string }>
|
|
23
32
|
unavailable?: Array<{ name?: string; reason?: string; temporary?: boolean }>
|
|
@@ -65,7 +74,7 @@ const get: Command = {
|
|
|
65
74
|
async run(ctx) {
|
|
66
75
|
const slug = serverRef(ctx, 'get')
|
|
67
76
|
const server = (await new PlatformApi(ctx.apiUrl, ctx.token, ctx.workspaceId).mcpServer(slug)).server as McpServerRow
|
|
68
|
-
const lines = [`${server.name ?? slug} (${slug}), revision ${server.revision ?? '?'}`, ` connect at ${server.url ?? '?'}`, '']
|
|
77
|
+
const lines = [`${server.name ?? slug} (${slug}), revision ${server.revision ?? '?'}`, ` connect at ${server.url ?? '?'}`, ` ${connectHow(server)}`, '']
|
|
69
78
|
lines.push(table(['tool', 'kind', 'runs'], (server.tools ?? []).map((t) => [t.name ?? '?', t.kind ?? '', t.target ?? ''])))
|
|
70
79
|
for (const tool of server.unavailable ?? []) {
|
|
71
80
|
lines.push(` ${tool.temporary ? 'for now, ' : ''}${tool.name ?? '?'} is left out for you: ${tool.reason ?? 'unavailable'}`)
|
|
@@ -25,7 +25,7 @@ export interface McpServerApplied {
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
interface SavedServer {
|
|
28
|
-
server?: { slug?: string; name?: string; url?: string; tools?: unknown[] }
|
|
28
|
+
server?: { slug?: string; name?: string; url?: string; signIn?: boolean; tools?: unknown[] }
|
|
29
29
|
created?: boolean
|
|
30
30
|
warnings?: Array<{ name?: string; reason?: string }>
|
|
31
31
|
}
|
|
@@ -58,7 +58,9 @@ export async function applyMcpServer(root: string, slug: string, file: string, c
|
|
|
58
58
|
const saved = ((res.body as { data?: unknown } | null)?.data ?? res.body) as SavedServer | null
|
|
59
59
|
const tools = saved?.server?.tools?.length ?? 0
|
|
60
60
|
const url = saved?.server?.url
|
|
61
|
-
|
|
61
|
+
// A local runtime offers no sign-in: a client there sends the runtime's workspace key.
|
|
62
|
+
const how = saved?.server?.signIn === false ? " with the runtime's workspace key" : ''
|
|
63
|
+
const lines = [` ${saved?.created ? 'created' : 'applied'} MCP server ${slug} (${tools} tool${tools === 1 ? '' : 's'})${url ? ` — connect at ${url}${how}` : ''}`]
|
|
62
64
|
for (const warning of saved?.warnings ?? []) {
|
|
63
65
|
lines.push(` warning: MCP server ${slug}: tool ${warning.name ?? '?'} is offered to nobody for now: ${warning.reason ?? 'unavailable'}`)
|
|
64
66
|
}
|