@hasna/switcher 0.2.17 → 0.2.19
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/Dockerfile +6 -1
- package/README.md +1 -1
- package/dist/claude-desktop.js +19180 -3734
- package/dist/cli/index.js +707 -330
- package/dist/codex-state-bridge.js +4 -4
- package/dist/credentials.d.ts +36 -184
- package/dist/domain.d.ts +271 -737
- package/dist/gateway-service.d.ts +3 -1
- package/dist/index.js +19121 -3675
- package/dist/inference-gateway.d.ts +2 -0
- package/dist/mcp/index.js +19608 -4116
- package/dist/model-policy-schema.d.ts +93 -112
- package/dist/native-state.d.ts +24 -0
- package/dist/opencode2-config.d.ts +8 -12
- package/dist/presets.d.ts +2 -2
- package/dist/process-table.d.ts +7 -0
- package/dist/reasoning.d.ts +11 -2
- package/dist/sdk.js +19121 -3675
- package/dist/serve/index.js +269 -223
- package/docs/GATEWAY-SERVICE.md +66 -30
- package/hasna.contract.json +1 -1
- package/openapi.json +264 -218
- package/package.json +9 -6
package/Dockerfile
CHANGED
|
@@ -26,7 +26,12 @@ RUN apk upgrade --no-cache \
|
|
|
26
26
|
ENV NODE_EXTRA_CA_CERTS=/app/rds-global-bundle.pem \
|
|
27
27
|
PGSSLROOTCERT=/app/rds-global-bundle.pem
|
|
28
28
|
COPY package.json bun.lock ./
|
|
29
|
-
|
|
29
|
+
# The server image runs switcher-serve and switcher-mint-key only. The MCP SDK (and the express and
|
|
30
|
+
# body-parser it brings) is an optional dependency used by the switcher-mcp bin, so it stays out.
|
|
31
|
+
RUN bun install --frozen-lockfile --production --omit=optional --ignore-scripts \
|
|
32
|
+
&& test ! -e node_modules/@modelcontextprotocol/sdk \
|
|
33
|
+
&& test ! -e node_modules/express \
|
|
34
|
+
&& test ! -e node_modules/body-parser
|
|
30
35
|
COPY --from=builder /app/dist ./dist
|
|
31
36
|
COPY --from=builder /app/openapi.json ./openapi.json
|
|
32
37
|
COPY --from=builder /app/hasna.contract.json ./hasna.contract.json
|
package/README.md
CHANGED
|
@@ -621,7 +621,7 @@ Cline uses its native ACP backend with per-launch configuration, durable session
|
|
|
621
621
|
|
|
622
622
|
## Background sessions and the persistent gateway
|
|
623
623
|
|
|
624
|
-
Launches register with one persistent gateway per user on a stable `127.0.0.1` port. A launch's token keeps working for as long as any process it started still runs, including Claude Code's detached background host and its background sessions after `switcher launch` exits. When nothing from the launch remains, the token
|
|
624
|
+
Launches register with one persistent gateway per user on a stable `127.0.0.1` port. A launch's token keeps working for as long as any process it started still runs, including Claude Code's detached background host and its background sessions after `switcher launch` exits. When nothing from the launch remains, the launch ends. For 30 days after that, a request with its token from a process of this user running under a current launch, such as a background session that Claude Code's background host started again, revives it; a copied token used from anywhere else stays refused. For the default `~/.hasna/switcher` home the gateway runs under launchd (macOS) or systemd `--user` (Linux), starts at login, and is installed automatically by the first launch of the installed `switcher`. Other homes and other copies of Switcher use a detached gateway that exits when idle.
|
|
625
625
|
|
|
626
626
|
```sh
|
|
627
627
|
switcher gateway status # running, pid, port, launches and login unit
|