@happyvertical/smrt-app-cli 0.71.0 → 0.73.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.
package/AGENTS.md CHANGED
@@ -22,6 +22,10 @@ Application CLI support for SMRT-based apps.
22
22
  `smrt-mcp-bridge` parses argv with `parseMcpBridgeArgs`: empty, missing or
23
23
  repeated value options and an explicit invalid (even empty) path are usage
24
24
  errors (exit 2) — never silently the default.
25
+ - `./mcp-bridge` (`dist/bin/smrt-mcp-bridge.mjs`, `vite.bridge.config.ts`)
26
+ is the `smrt-mcp-bridge` bin with every dependency inlined: a desktop bundle
27
+ ships it byte for byte, so it must import only Node built-ins.
28
+ `postbuild.mjs` runs it alone and fails the build otherwise.
25
29
  - Keep command output stream-injectable so tests can assert behavior without writing to the real terminal.
26
30
 
27
31
  ## Gotchas
package/README.md CHANGED
@@ -180,6 +180,20 @@ route elsewhere, set `mcpPath` on `createAppCli()` or pass it per call
180
180
  (`smrt-mcp-bridge`, or `SMRT_MCP_PATH`) and `--mcp-path` / `SMRT_APP_MCP_PATH`
181
181
  (`smrt-app`). The path must be same-server and absolute.
182
182
 
183
+ ### Agent credentials and `auth status`
184
+
185
+ `auth status` asks the session endpoint who the token belongs to. A durable
186
+ agent credential is not a session, and apps commonly refuse it there, so the
187
+ command would report `authenticated: false` for a valid token. Set
188
+ `agentStatusPath` on `createAppCli()` (`--agent-status-path` /
189
+ `SMRT_APP_AGENT_STATUS_PATH` for `smrt-app`) to the app's same-server
190
+ credential-introspection route, for example
191
+ `/api/tracker/agent-credentials/self`. When the session check fails, `auth
192
+ status` then calls that route and prints `authenticated: true`,
193
+ `kind: "agent-credential"`, and the route's JSON body (agent slug,
194
+ capabilities, expiry). If the route also rejects the token, the original
195
+ session error is reported unchanged.
196
+
183
197
  For a local-profile s-m-r-t app, mint a credential with
184
198
  `smrt app token --scopes <scope>` in the app checkout. The token is printed
185
199
  once. Then give the bridge the loopback server and that token through the
@@ -203,6 +217,11 @@ app's environment prefix. This Claude Desktop entry is an example:
203
217
  The token is sent only when `<PREFIX>_SERVER_URL` matches the target server.
204
218
  Revoke a token with `smrt app token revoke <id>`.
205
219
 
220
+ For a desktop bundle, `@happyvertical/smrt-app-cli/mcp-bridge`
221
+ (`dist/bin/smrt-mcp-bridge.mjs`) is the same binary as one self-contained
222
+ file that imports only Node built-ins; pass its path to `smrt desktop bundle
223
+ --bridge`.
224
+
206
225
  The package also ships the generic `smrt-mcp-bridge` binary. The remote app
207
226
  surface is typically mounted with
208
227
  [`@happyvertical/smrt-app-mcp`](../smrt-app-mcp/README.md).
@@ -327,3 +346,11 @@ connection directly through `saveCliConfig` without mutating process environment
327
346
  Modern stdio bridges advertise `tools.listChanged` and poll the stateless upstream
328
347
  catalog every two seconds (including pages). Changed descriptors, revocation and
329
348
  recovery invalidate discovery; close clears the timer. No shared catalog cache.
349
+
350
+ ## Commands without a published schema
351
+
352
+ When a custom action publishes no input schema (for example an action that
353
+ takes an untyped option bag), its command accepts only a positional JSON
354
+ payload. The CLI prints a one-line stderr hint to that effect only when no
355
+ payload was passed; passing one is silent. GET payloads travel as query
356
+ strings, so every value is a string: the server must coerce numbers itself.
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { i as runAppCliExecutable } from "../src-C8vwCeRO.js";
2
+ import { i as runAppCliExecutable } from "../src-xyvymq8n.js";
3
3
  //#region src/bin/smrt-app.ts
4
4
  /**
5
5
  * `smrt-app` — configuration-driven executable for a published SMRT app CLI.
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { h as runMcpStdioBridge, u as resolveMcpPath } from "../config-DynygNnu.js";
2
+ import { d as resolveMcpPath, g as runMcpStdioBridge } from "../config-CXiXf3ei.js";
3
3
  //#region src/bridge-args.ts
4
4
  /**
5
5
  * Argument parsing for the generic `smrt-mcp-bridge` binary. Every value