Skip to content

feat(dashboard): provider add (with connectivity test) + provider/bot control#54

Merged
QodeXcli merged 1 commit into
mainfrom
feat/dashboard-provider-bot
Jun 30, 2026
Merged

feat(dashboard): provider add (with connectivity test) + provider/bot control#54
QodeXcli merged 1 commit into
mainfrom
feat/dashboard-provider-bot

Conversation

@QodeXcli

Copy link
Copy Markdown
Owner

Why

The final two control batches toward every capability controllable: managing providers and the bot from the dashboard — with the connectivity test you asked for.

What

  • provider.add — a form (name · base URL · key-env · model) adds an OpenAI-compatible provider (reuses buildCustomEntry + addProviderToConfig) and immediately tests it: probeProvider hits {baseUrl}/models with the key from the named env var and reports ✓ reachable — N models / ✗ <reason> (401 = bad key, missing env var, timeout). The secret stays in ~/.qodex/.env — never the form.
  • provider.test — a Test button on every provider row runs the same probe on demand.
  • provider.remove — a Remove button on custom providers.
  • bot.start / bot.stop — start/stop the Telegram/Discord/Slack bot as a detached process tracked by ~/.qodex/bot.pid; the panel shows running (pid) / stopped via a kill(pid, 0) liveness check.

New: src/setup/provider-test.ts (PURE buildModelsUrl + best-effort probeProvider), src/cli/bot-process.ts (PURE pidFilePath/parsePid + start/stop/status).

Safety

Keys never touch the dashboard — only the env-var name does; the secret lives in ~/.qodex/.env. Same local-only + token-gated server. Bot start just spawns qodex bot (itself deny-by-default).

Tests

+12 (models-url trim, missing-key probe without network, pid parsing/path, provider/bot dispatch validation, live render wires the forms). Full suite 1375 green, tsc clean.

Dashboard now controls essentially everything

providers (add + test / remove) · model · caching/efficient/memory/sub-agents/learning · schedules (add/enable/disable/remove) + receipts · remember/forget · skill promote/reject · offload · bot start/stop.

… control

The last two control batches — providers and the bot — now run from the dashboard.

  - provider.add — a form (name · base URL · key-env · model) adds an OpenAI-compatible provider
    (reuses buildCustomEntry + addProviderToConfig) AND immediately TESTS it: probeProvider hits
    {baseUrl}/models with the key from the named env var and reports ✓ reachable / ✗ <reason>
    (401 = bad key, missing env var, timeout). The secret stays in ~/.qodex/.env — never the form.
  - provider.test — a Test button on every provider row runs the same probe on demand.
  - provider.remove — Remove button on custom providers.
  - bot.start / bot.stop — start/stop the Telegram/Discord/Slack bot as a detached process tracked
    by ~/.qodex/bot.pid; the panel shows running(pid)/stopped via a kill(pid,0) liveness check.

New modules: src/setup/provider-test.ts (PURE buildModelsUrl + best-effort probeProvider) and
src/cli/bot-process.ts (PURE pidFilePath/parsePid + start/stop/status). gatherDashboardData adds
a `custom` flag per provider + bot status.

+12 tests (models-url, missing-key probe, pid parsing/path, provider/bot dispatch validation,
live render wires the forms). Full suite 1375 green; tsc clean.
@QodeXcli QodeXcli merged commit ebe3f44 into main Jun 30, 2026
2 checks passed
@QodeXcli QodeXcli deleted the feat/dashboard-provider-bot branch June 30, 2026 03:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant