Files
fusion/packages/cli/package.json
gsxdsm 7e3c68249e feat(dashboard): bearer-token auth with browser persistence + MIT license
Pre-release polish. Two related changes bundled because they both land the
project on public-release footing:

Dashboard auth
- fn dashboard now gates the HTTP API + terminal/badge WebSockets behind a
  bearer token by default. Token resolution order: --token flag,
  FUSION_DASHBOARD_TOKEN env, FUSION_DAEMON_TOKEN env (back-compat), or an
  auto-generated fn_<32 hex>. --no-auth disables. The startup banner prints
  a click-to-open URL with ?token=<token> embedded.
- Auth middleware now also accepts fn_token=<token> as a query-string
  fallback so EventSource and WebSocket clients (which can't set custom
  headers) still authenticate.
- setupTerminalWebSocket / setupBadgeWebSocket now refuse unauthenticated
  upgrades with a proper 401 + socket close.
- Frontend: new auth.ts module captures ?token= off the URL into
  localStorage (key fn.authToken), strips it from the visible URL via
  replaceState, and installs a window.fetch wrapper that injects
  Authorization: Bearer <token> on every same-origin /api/* request.
  EventSource/WebSocket URL builders (api.ts, sse-bus.ts, useTerminal,
  useBadgeWebSocket) route through appendTokenQuery().

MIT license
- LICENSE file at repo root.
- license: "MIT" on root package.json and every packages/*/package.json,
  plus description/bugs metadata on the CLI package.

Docs
- docs/cli-reference.md documents --token / --no-auth / FUSION_DASHBOARD_TOKEN
  and the click-to-open auth flow.
- docs/getting-started.md, docs/docker.md, README.md point at the new flow
  and the CLI reference section.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-21 20:12:00 -07:00

87 lines
2.0 KiB
JSON

{
"name": "@gsxdsm/fusion",
"version": "0.4.0",
"license": "MIT",
"description": "Fusion CLI: HTTP API server, daemon, dashboard launcher, and task tooling for the Fusion AI coding agent.",
"homepage": "https://github.com/Runfusion/Fusion#readme",
"bugs": {
"url": "https://github.com/Runfusion/Fusion/issues"
},
"type": "module",
"keywords": [
"pi-package"
],
"bin": {
"fn": "./dist/bin.js"
},
"pi": {
"extensions": [
"./dist/extension.js"
],
"skills": [
"./skill"
],
"image": "https://raw.githubusercontent.com/Runfusion/Fusion/main/demo/screenshot.png"
},
"publishConfig": {
"access": "public"
},
"files": [
"dist/**/*.js",
"dist/**/*.d.ts",
"dist/**/*.d.ts.map",
"dist/**/*.js.map",
"dist/client/**",
"skill/**",
"README.md"
],
"scripts": {
"dev": "tsx src/bin.ts",
"build": "tsup",
"build:exe": "bun run build.ts",
"build:exe:all": "bun run build.ts --all",
"typecheck": "tsc --noEmit",
"test": "vitest run --silent=passed-only --reporter=dot"
},
"dependencies": {
"@mariozechner/pi-ai": "^0.62.0",
"@mariozechner/pi-coding-agent": "^0.62.0",
"express": "^5.1.0",
"ioredis": "^5.6.0",
"multer": "^2.1.1"
},
"peerDependencies": {
"@mariozechner/pi-ai": "*",
"@mariozechner/pi-coding-agent": "*",
"@sinclair/typebox": "*"
},
"peerDependenciesMeta": {
"@mariozechner/pi-ai": {
"optional": true
},
"@mariozechner/pi-coding-agent": {
"optional": true
},
"@sinclair/typebox": {
"optional": true
}
},
"devDependencies": {
"@fusion/core": "workspace:*",
"@fusion/dashboard": "workspace:*",
"@fusion/engine": "workspace:*",
"@sinclair/typebox": "^0.34.0",
"@types/node": "^22.0.0",
"@vitest/coverage-v8": "^3.1.0",
"tsup": "^8.5.1",
"tsx": "^4.19.0",
"typescript": "^5.7.0",
"vitest": "^3.1.0",
"yaml": "^2.8.3"
},
"repository": {
"type": "git",
"url": "https://github.com/Runfusion/Fusion"
}
}