quoxcli 0.2.0 → 0.3.1
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/LICENSE +1 -1
- package/README.md +2 -0
- package/bin/quox.js +99 -126
- package/lib/api/endpoints/admin.js +26 -0
- package/lib/api/endpoints/agent-schedules.js +26 -0
- package/lib/api/endpoints/agents.js +7 -0
- package/lib/api/endpoints/assistants.js +12 -0
- package/lib/api/endpoints/away.js +15 -0
- package/lib/api/endpoints/chat.js +7 -0
- package/lib/api/endpoints/contactsq.js +2 -0
- package/lib/api/endpoints/conversations.js +14 -0
- package/lib/api/endpoints/executions.js +13 -0
- package/lib/api/endpoints/fetchAllowlist.js +27 -0
- package/lib/api/endpoints/files.js +14 -0
- package/lib/api/endpoints/hat.js +30 -0
- package/lib/api/endpoints/inbox.js +20 -0
- package/lib/api/endpoints/index.js +14 -0
- package/lib/api/endpoints/memory.js +19 -0
- package/lib/api/endpoints/mind.js +13 -0
- package/lib/api/endpoints/mon.js +6 -0
- package/lib/api/endpoints/objectives.js +6 -0
- package/lib/api/endpoints/plugins.js +18 -0
- package/lib/api/endpoints/presence.js +33 -0
- package/lib/api/endpoints/quoxplan.js +7 -0
- package/lib/api/endpoints/quoxseo.js +6 -0
- package/lib/api/endpoints/router.js +17 -0
- package/lib/api/endpoints/safety.js +7 -0
- package/lib/api/endpoints/skills.js +20 -0
- package/lib/api/endpoints/stepup.js +20 -0
- package/lib/api/endpoints/teams.js +2 -2
- package/lib/api/endpoints/triggers.js +26 -0
- package/lib/api/endpoints/v1.js +86 -0
- package/lib/api/endpoints/ward.js +7 -0
- package/lib/api/endpoints/workflows.js +7 -0
- package/lib/api/endpoints/x.js +8 -0
- package/lib/commands/actions.js +61 -0
- package/lib/commands/admin.js +16 -0
- package/lib/commands/agent.js +163 -27
- package/lib/commands/agentAttach.js +94 -6
- package/lib/commands/approvals.js +73 -1
- package/lib/commands/aside.js +24 -0
- package/lib/commands/ask.js +144 -0
- package/lib/commands/assistant.js +59 -4
- package/lib/commands/auth.js +8 -2
- package/lib/commands/backup.js +8 -4
- package/lib/commands/brain.js +105 -14
- package/lib/commands/build.js +19 -5
- package/lib/commands/chat.js +57 -2
- package/lib/commands/claude.js +34 -8
- package/lib/commands/contacts.js +49 -0
- package/lib/commands/conversation.js +35 -4
- package/lib/commands/dashboard.js +43 -0
- package/lib/commands/department.js +28 -7
- package/lib/commands/devResident.js +15 -3
- package/lib/commands/devSupervisor.js +13 -1
- package/lib/commands/discord.js +75 -39
- package/lib/commands/done.js +98 -28
- package/lib/commands/engagement.js +17 -6
- package/lib/commands/fetchAllowlist.js +71 -0
- package/lib/commands/file.js +38 -1
- package/lib/commands/fleet.js +311 -4
- package/lib/commands/governance.js +12 -3
- package/lib/commands/gripe.js +44 -13
- package/lib/commands/hat.js +178 -9
- package/lib/commands/helpers.js +18 -1
- package/lib/commands/hyperion.js +58 -0
- package/lib/commands/inbox.js +74 -23
- package/lib/commands/licence.js +14 -155
- package/lib/commands/lucid.js +10 -4
- package/lib/commands/memory.js +85 -8
- package/lib/commands/mind.js +71 -0
- package/lib/commands/mon.js +69 -2
- package/lib/commands/monitoring.js +1 -1
- package/lib/commands/motion.js +2 -2
- package/lib/commands/nucleus.js +48 -17
- package/lib/commands/objective.js +11 -0
- package/lib/commands/offload.js +89 -0
- package/lib/commands/onboard.js +2 -1
- package/lib/commands/org.js +11 -1
- package/lib/commands/peek.js +28 -0
- package/lib/commands/plan.js +38 -0
- package/lib/commands/plugin.js +110 -0
- package/lib/commands/presence.js +89 -0
- package/lib/commands/provider.js +159 -0
- package/lib/commands/qlarity.js +19 -3
- package/lib/commands/quoxchat.js +13 -4
- package/lib/commands/quoxseo.js +38 -0
- package/lib/commands/reach.js +2 -1
- package/lib/commands/router.js +77 -0
- package/lib/commands/rows.js +358 -0
- package/lib/commands/run.js +64 -9
- package/lib/commands/server.js +292 -0
- package/lib/commands/setup.js +33 -7
- package/lib/commands/skills.js +48 -5
- package/lib/commands/slot.js +260 -7
- package/lib/commands/status.js +1 -1
- package/lib/commands/team.js +3 -1
- package/lib/commands/tips.js +23 -0
- package/lib/commands/tool.js +133 -45
- package/lib/commands/trace.js +12 -7
- package/lib/commands/trigger.js +95 -0
- package/lib/commands/update.js +46 -0
- package/lib/commands/vault.js +31 -8
- package/lib/commands/vm.js +237 -0
- package/lib/commands/voice.js +34 -3
- package/lib/commands/volt.js +45 -3
- package/lib/commands/walkthrough.js +32 -0
- package/lib/commands/watch.js +73 -21
- package/lib/commands/welcome.js +14 -0
- package/lib/commands/workflow.js +189 -32
- package/lib/commands/x.js +13 -4
- package/lib/core/actingAs.js +2 -2
- package/lib/core/activeSummary.js +186 -0
- package/lib/core/aside.js +54 -0
- package/lib/core/askDecision.js +60 -0
- package/lib/core/auth.js +164 -13
- package/lib/core/callerSource.js +1 -1
- package/lib/core/cliBuild.js +62 -0
- package/lib/core/client.js +144 -35
- package/lib/core/commandRegistrars.js +121 -0
- package/lib/core/config.js +142 -24
- package/lib/core/customHats.js +168 -0
- package/lib/core/doneEngineFetch.js +8 -0
- package/lib/core/errors.js +329 -20
- package/lib/core/global-flags.js +105 -5
- package/lib/core/hyperion.js +102 -0
- package/lib/core/inboxResolution.js +65 -0
- package/lib/core/lazyCommands.js +4 -1
- package/lib/core/offload.js +504 -0
- package/lib/core/org-override.js +1 -1
- package/lib/core/orgResolve.js +70 -0
- package/lib/core/output.js +4 -4
- package/lib/core/peek.js +126 -0
- package/lib/core/profileUsers.js +51 -0
- package/lib/core/promptCancel.js +18 -0
- package/lib/core/repoPath.js +11 -0
- package/lib/core/residentSeed.js +3 -1
- package/lib/core/rootOptions.js +39 -0
- package/lib/core/router.js +168 -0
- package/lib/core/selfUpdate.js +188 -0
- package/lib/core/sessionsOverview.js +64 -0
- package/lib/core/slotKeeper.js +248 -3
- package/lib/core/slotWake.js +120 -0
- package/lib/core/supervisorEngine.js +71 -2
- package/lib/core/version.js +1 -1
- package/lib/core/vm.js +361 -0
- package/lib/core/vmTui.js +86 -0
- package/lib/core/walkthrough.js +35 -0
- package/lib/hyperion/deck.js +29 -0
- package/lib/lucid/LucidCard.jsx +68 -0
- package/lib/lucid/LucidIntro.jsx +45 -58
- package/lib/lucid/cards.js +86 -0
- package/lib/lucid/markdown.js +81 -0
- package/lib/lucid/motion.js +56 -0
- package/lib/quoxon/activity.js +14 -2
- package/lib/quoxon/aocl.js +117 -0
- package/lib/quoxon/api.js +504 -25
- package/lib/quoxon/app.js +3000 -230
- package/lib/quoxon/approvalFacts.js +94 -0
- package/lib/quoxon/approvalsView.js +325 -0
- package/lib/quoxon/asideView.js +40 -0
- package/lib/quoxon/ask.js +121 -0
- package/lib/quoxon/away.js +52 -0
- package/lib/quoxon/bang.js +224 -0
- package/lib/quoxon/bulkRisk.js +17 -0
- package/lib/quoxon/capabilities.js +13 -6
- package/lib/quoxon/cells.js +53 -0
- package/lib/quoxon/commandShort.js +112 -0
- package/lib/quoxon/commands.js +363 -38
- package/lib/quoxon/connect.js +210 -23
- package/lib/quoxon/connectCard.js +19 -2
- package/lib/quoxon/consent.js +86 -0
- package/lib/quoxon/copy.js +4 -3
- package/lib/quoxon/countdownLine.js +11 -0
- package/lib/quoxon/demo.autoplay.js +29 -0
- package/lib/quoxon/demo.fixtures.js +1 -1
- package/lib/quoxon/demo.js +44 -3
- package/lib/quoxon/devObserver.js +20 -0
- package/lib/quoxon/dividerAocl.js +191 -0
- package/lib/quoxon/dividerRule.js +57 -0
- package/lib/quoxon/dragonModes.js +150 -0
- package/lib/quoxon/dragonView.js +41 -0
- package/lib/quoxon/earlyInput.js +40 -0
- package/lib/quoxon/echo.js +15 -0
- package/lib/quoxon/egg.js +2 -2
- package/lib/quoxon/events.js +244 -25
- package/lib/quoxon/feedback.js +50 -0
- package/lib/quoxon/gallery.js +21 -7
- package/lib/quoxon/handoffOffer.js +78 -0
- package/lib/quoxon/hatSwitch.js +37 -0
- package/lib/quoxon/headless.js +161 -0
- package/lib/quoxon/hostUrls.js +41 -0
- package/lib/quoxon/indicator.js +6 -2
- package/lib/quoxon/intent.js +12 -1
- package/lib/quoxon/keys.js +49 -6
- package/lib/quoxon/launcher.js +103 -0
- package/lib/quoxon/main.js +92 -160
- package/lib/quoxon/markdown.js +45 -21
- package/lib/quoxon/markdownSettle.js +19 -0
- package/lib/quoxon/matrixDomains.json +46 -0
- package/lib/quoxon/mentions.js +90 -0
- package/lib/quoxon/mind.js +103 -0
- package/lib/quoxon/mode.js +46 -0
- package/lib/quoxon/model.js +132 -26
- package/lib/quoxon/modelPrefs.js +345 -0
- package/lib/quoxon/motion/clock.js +3 -2
- package/lib/quoxon/motion/level.js +91 -0
- package/lib/quoxon/mouse.js +211 -0
- package/lib/quoxon/noai.js +57 -0
- package/lib/quoxon/objects/away.js +72 -0
- package/lib/quoxon/objects/fetch.js +17 -5
- package/lib/quoxon/objects/fleet.js +149 -0
- package/lib/quoxon/objects/health.js +186 -0
- package/lib/quoxon/objects/index.js +24 -3
- package/lib/quoxon/objects/mirror.js +137 -0
- package/lib/quoxon/objects/peek.js +17 -0
- package/lib/quoxon/objects/prove.js +130 -0
- package/lib/quoxon/objects/replay.js +125 -0
- package/lib/quoxon/objects/sitrep.js +58 -0
- package/lib/quoxon/objects/view.js +11 -0
- package/lib/quoxon/onboarding/copy.js +32 -4
- package/lib/quoxon/onboarding/credential.js +17 -4
- package/lib/quoxon/onboarding/dockerOffer.js +45 -0
- package/lib/quoxon/onboarding/failureCause.js +33 -0
- package/lib/quoxon/onboarding/finish.js +15 -0
- package/lib/quoxon/onboarding/index.js +34 -7
- package/lib/quoxon/onboarding/installRunner.js +64 -5
- package/lib/quoxon/onboarding/preflight.js +17 -3
- package/lib/quoxon/onboarding/probe.js +65 -0
- package/lib/quoxon/onboarding/view.js +76 -19
- package/lib/quoxon/orgLabel.js +10 -0
- package/lib/quoxon/orgSwitch.js +33 -0
- package/lib/quoxon/ownBroadcast.js +22 -0
- package/lib/quoxon/palette.js +43 -0
- package/lib/quoxon/print.js +9 -5
- package/lib/quoxon/profileSwitch.js +53 -0
- package/lib/quoxon/promptHistory.js +41 -0
- package/lib/quoxon/providers.js +48 -0
- package/lib/quoxon/qart.js +20 -51
- package/lib/quoxon/qdragon.js +410 -0
- package/lib/quoxon/qdragonFly.js +61 -0
- package/lib/quoxon/qdragonScenes.js +282 -0
- package/lib/quoxon/qeyes.js +213 -0
- package/lib/quoxon/qmotion.js +58 -37
- package/lib/quoxon/render.js +638 -119
- package/lib/quoxon/resend.js +72 -0
- package/lib/quoxon/roster.js +95 -9
- package/lib/quoxon/route.js +6 -5
- package/lib/quoxon/rows.js +711 -0
- package/lib/quoxon/rowsStore.js +80 -0
- package/lib/quoxon/screenContext.js +150 -0
- package/lib/quoxon/screenFrames.js +254 -0
- package/lib/quoxon/session.js +172 -2
- package/lib/quoxon/sessionDead.js +17 -0
- package/lib/quoxon/signin.js +125 -0
- package/lib/quoxon/slash/agents.js +112 -0
- package/lib/quoxon/slash/argSources.js +65 -0
- package/lib/quoxon/slash/args.js +65 -0
- package/lib/quoxon/slash/automate.js +89 -0
- package/lib/quoxon/slash/broadcast.js +140 -0
- package/lib/quoxon/slash/broadcastRun.js +108 -0
- package/lib/quoxon/slash/card.js +30 -0
- package/lib/quoxon/slash/challenge.js +114 -0
- package/lib/quoxon/slash/cliCommand.js +53 -0
- package/lib/quoxon/slash/cliLeaves.json +948 -0
- package/lib/quoxon/slash/compact.js +1 -1
- package/lib/quoxon/slash/confirm.js +30 -0
- package/lib/quoxon/slash/crystallize.js +69 -0
- package/lib/quoxon/slash/dashboard.js +136 -0
- package/lib/quoxon/slash/draft.js +54 -0
- package/lib/quoxon/slash/hatWalk.js +206 -0
- package/lib/quoxon/slash/inverses.js +77 -0
- package/lib/quoxon/slash/killer.js +24 -0
- package/lib/quoxon/slash/killerApi.js +16 -0
- package/lib/quoxon/slash/ledger.js +13 -8
- package/lib/quoxon/slash/listView.js +3 -1
- package/lib/quoxon/slash/modelCmd.js +261 -0
- package/lib/quoxon/slash/palette.js +21 -7
- package/lib/quoxon/slash/paletteController.js +117 -7
- package/lib/quoxon/slash/panels.js +21 -6
- package/lib/quoxon/slash/picker.js +20 -2
- package/lib/quoxon/slash/restart.js +71 -13
- package/lib/quoxon/slash/rowCmd.js +157 -0
- package/lib/quoxon/slash/rowWalk.js +175 -0
- package/lib/quoxon/slash/settings.js +16 -6
- package/lib/quoxon/slash/spawn.js +177 -0
- package/lib/quoxon/slash/stepUp.js +274 -0
- package/lib/quoxon/slash/stepUpCard.js +60 -0
- package/lib/quoxon/slash/stepUpCmds.js +78 -0
- package/lib/quoxon/slash/undoApi.js +38 -0
- package/lib/quoxon/slash/undoCmd.js +49 -0
- package/lib/quoxon/slash/undoWish.js +15 -0
- package/lib/quoxon/slash/watch.js +164 -0
- package/lib/quoxon/slash/wish.js +23 -0
- package/lib/quoxon/slash/wishCmd.js +32 -0
- package/lib/quoxon/slotChat.js +300 -0
- package/lib/quoxon/slotFormat.js +195 -0
- package/lib/quoxon/slotRun.js +131 -0
- package/lib/quoxon/sound/mapping.js +2 -1
- package/lib/quoxon/stray.js +22 -0
- package/lib/quoxon/suggestCommand.js +59 -0
- package/lib/quoxon/term.js +46 -11
- package/lib/quoxon/textBuffer.js +176 -2
- package/lib/quoxon/theme.js +58 -25
- package/lib/quoxon/tips.js +433 -0
- package/lib/quoxon/toolError.js +41 -0
- package/lib/quoxon/transcript.js +42 -4
- package/lib/quoxon/web/qface.js +18 -10
- package/lib/quoxon/welcome.js +1 -1
- package/lib/quoxon/whatsnew.js +136 -0
- package/lib/quoxon/whatsnew.jsonl +89 -0
- package/lib/quoxon/windowOrg.js +113 -0
- package/lib/server/diag.js +129 -0
- package/lib/server/doctor.js +71 -0
- package/lib/server/install.js +149 -0
- package/lib/server/pluginEnable.js +161 -0
- package/lib/server/skew.js +56 -0
- package/lib/server/snapshot.js +131 -0
- package/lib/server/status.js +128 -0
- package/lib/server/sys.js +65 -0
- package/lib/server/uninstall.js +63 -0
- package/lib/server/update.js +234 -0
- package/lib/toolOutputShape.js +315 -0
- package/lib/tui/views/HyperionDeck.jsx +79 -0
- package/lib/tui/views/LucidDeck.jsx +209 -217
- package/package.json +4 -1
- package/lib/core/websiteSession.js +0 -148
package/LICENSE
CHANGED
|
@@ -30,6 +30,6 @@ THIS IS A SOURCE-AVAILABLE PROPRIETARY LICENCE. IT IS NOT AN OPEN-SOURCE LICENCE
|
|
|
30
30
|
|
|
31
31
|
13. Law and versions. This licence is governed by the law of England and Wales, subject to mandatory protections in Your jurisdiction. Courts of England and Wales have jurisdiction where legally permitted. Quox may offer NEW versions under revised terms. Publishing new terms does not retroactively withdraw grants validly received for earlier versions. Separately signed agreements and applicable third-party licences govern where they apply.
|
|
32
32
|
|
|
33
|
-
14. Contact. For white-label, managed-hosting, OEM, redistribution or other permissions:
|
|
33
|
+
14. Contact. For white-label, managed-hosting, OEM, redistribution or other permissions: hello@quox.ai.
|
|
34
34
|
|
|
35
35
|
Copyright (c) 2025-2026 Quox LTD. All rights reserved.
|
package/README.md
CHANGED
|
@@ -12,6 +12,8 @@ npm install -g quoxcli
|
|
|
12
12
|
|
|
13
13
|
Needs Node.js 20 or later. This installs two commands: `quox`, and `quoxon` (an alias that opens the conversation).
|
|
14
14
|
|
|
15
|
+
Docs: https://cli.quox.ai/docs/start/
|
|
16
|
+
|
|
15
17
|
## Prerequisite: a running QuoxCORE
|
|
16
18
|
|
|
17
19
|
You need a QuoxCORE instance to talk to. Install one on a machine you control: see https://github.com/quoxai/quoxcore, or run:
|
package/bin/quox.js
CHANGED
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import '../lib/core/prodEnv.js'; // first: production React unless NODE_ENV is set (before anything loads React)
|
|
3
3
|
|
|
4
|
-
import { Command } from 'commander';
|
|
5
|
-
import { loadConfig, resolveProfileFlagFromArgv } from '../lib/core/config.js';
|
|
6
|
-
import { resolveCliVersion, BASE_VERSION } from '../lib/core/version.js';
|
|
7
|
-
import { mergeShadowedGlobals } from '../lib/core/global-flags.js';
|
|
8
|
-
import { createAuth } from '../lib/core/auth.js';
|
|
9
|
-
import { extractActingAs } from '../lib/core/actingAs.js';
|
|
10
|
-
import { createClient } from '../lib/core/client.js';
|
|
11
|
-
import { handleError } from '../lib/core/errors.js';
|
|
12
|
-
import { assertOrgOverrideSafe, commandPath } from '../lib/core/org-override.js';
|
|
13
|
-
// QUOXIFY pass 2 (DEVSUITE phase 15): the two dev-suite members that had no
|
|
14
|
-
// unified verb at all. Gripe's own definition of done named `quox gripe`.
|
|
15
|
-
import { generateCompletion } from '../lib/core/completions.js';
|
|
16
|
-
import { loadAllPlugins } from '../lib/plugins/loader.js';
|
|
17
|
-
import { registerCommandGroups } from '../lib/core/lazyCommands.js';
|
|
18
4
|
import v8 from 'node:v8';
|
|
19
5
|
|
|
6
|
+
// QUOXON-LATENCY: a warm `claude` spare cannot carry this turn's conversation id in its
|
|
7
|
+
// (fixed) env, so the collector writes it to QUOX_SESSION_ID_FILE for the turn. Surface it
|
|
8
|
+
// as QUOX_SESSION_ID before any command reads it. An explicit QUOX_SESSION_ID wins.
|
|
9
|
+
if (!process.env.QUOX_SESSION_ID && process.env.QUOX_SESSION_ID_FILE) {
|
|
10
|
+
// dynamic, not a static import: bin/quox.js keeps its static imports to prodEnv + node:v8 (r3early, input capture first)
|
|
11
|
+
try { process.env.QUOX_SESSION_ID = (await import('node:fs')).readFileSync(process.env.QUOX_SESSION_ID_FILE, 'utf8').trim(); } catch { /* turn ended: no session */ }
|
|
12
|
+
}
|
|
13
|
+
|
|
20
14
|
// CORTEX-BENCH: Node's fetch parses HTTP with a WebAssembly module, and V8
|
|
21
15
|
// recompiles it at the optimising tier on a background thread; Node waits for
|
|
22
16
|
// that compile before exiting, adding 350-700ms to every short command after
|
|
@@ -27,13 +21,29 @@ v8.setFlagsFromString('--liftoff-only');
|
|
|
27
21
|
// subcommand and only client flags, a TTY gets the QUOXON client and
|
|
28
22
|
// `--print` runs headless. The old 15-item menu is `quox tui`. Decided from
|
|
29
23
|
// argv alone, before config or any command module loads.
|
|
24
|
+
// R3 D4: raw mode before ANY heavy module loads. The command modules below used to be static imports,
|
|
25
|
+
// evaluated before this block, so keys typed in the first ~2 s echoed cooked and an Enter was lost.
|
|
30
26
|
{
|
|
31
27
|
const { routesToQuoxon } = await import('../lib/quoxon/route.js');
|
|
32
28
|
const qArgv = process.argv.slice(2);
|
|
33
29
|
if (routesToQuoxon(qArgv, process.stdout.isTTY)) {
|
|
34
|
-
|
|
30
|
+
// QUOXON-RESTART-LEAK: the first interactive client on a terminal becomes a tiny launcher (no TUI, no polling)
|
|
31
|
+
// that runs the client as its child and re-runs it on /restart, so restarts never nest (98 deep, 15 GB, 2026-10-17).
|
|
32
|
+
const launcher = await import('../lib/quoxon/launcher.js');
|
|
33
|
+
if (launcher.shouldLaunch({ argv: qArgv })) {
|
|
34
|
+
const code = await launcher.runLauncher({ argv: qArgv });
|
|
35
|
+
if (code !== null) process.exit(code); // null: no handoff dir, so run the client in this process as before
|
|
36
|
+
}
|
|
37
|
+
launcher.takeLauncherHandoff(); // a launched client: read and drop the handoff var before anything can spawn
|
|
38
|
+
if (!qArgv.some(a => a === '--print' || a.startsWith('--print=') || a === '-h' || a === '--help')) (await import('../lib/quoxon/earlyInput.js')).captureEarlyInput();
|
|
35
39
|
try {
|
|
36
|
-
|
|
40
|
+
// QUOXON-LATENCY: --print runs headless without loading React / Ink / the App (~2 s cold).
|
|
41
|
+
const headless = qArgv.some(a => a === '--print' || a.startsWith('--print='))
|
|
42
|
+
&& await (await import('../lib/quoxon/headless.js')).runHeadless(qArgv);
|
|
43
|
+
if (!headless) {
|
|
44
|
+
const { main: quoxonMain } = await import('../lib/quoxon/main.js');
|
|
45
|
+
await quoxonMain(qArgv);
|
|
46
|
+
}
|
|
37
47
|
} catch (err) {
|
|
38
48
|
console.error(err?.message || err);
|
|
39
49
|
process.exitCode = 1;
|
|
@@ -42,6 +52,24 @@ v8.setFlagsFromString('--liftoff-only');
|
|
|
42
52
|
}
|
|
43
53
|
}
|
|
44
54
|
|
|
55
|
+
// The commander CLI: loaded only when the conversation client is not (see the block above).
|
|
56
|
+
// `quox --update` is `quox update` (owner 2026-10-16): one updater, lib/core/selfUpdate.js.
|
|
57
|
+
if (process.argv.includes('--update')) process.argv = [...process.argv.slice(0, 2), ...(await import('../lib/core/selfUpdate.js')).rewriteUpdateFlag(process.argv.slice(2))];
|
|
58
|
+
const { Command } = await import('commander');
|
|
59
|
+
const { loadConfig, resolveProfileFlagFromArgv } = await import('../lib/core/config.js');
|
|
60
|
+
const { resolveCliVersion, BASE_VERSION } = await import('../lib/core/version.js');
|
|
61
|
+
const { applyRootOptions, installFlagDeliveryHooks } = await import('../lib/core/rootOptions.js');
|
|
62
|
+
const { createAuth } = await import('../lib/core/auth.js');
|
|
63
|
+
const { extractActingAs } = await import('../lib/core/actingAs.js');
|
|
64
|
+
const { createClient } = await import('../lib/core/client.js');
|
|
65
|
+
const { handleError } = await import('../lib/core/errors.js');
|
|
66
|
+
const { assertOrgOverrideSafe, commandPath } = await import('../lib/core/org-override.js');
|
|
67
|
+
// QUOXIFY pass 2 (DEVSUITE phase 15): the two dev-suite members that had no
|
|
68
|
+
// unified verb at all. Gripe's own definition of done named `quox gripe`.
|
|
69
|
+
const { generateCompletion } = await import('../lib/core/completions.js');
|
|
70
|
+
const { loadAllPlugins } = await import('../lib/plugins/loader.js');
|
|
71
|
+
const { registerCommandGroups } = await import('../lib/core/lazyCommands.js');
|
|
72
|
+
|
|
45
73
|
// #610: --version must reflect the ACTUAL running commit, not a frozen literal
|
|
46
74
|
// (the global CLI worktree was silently 32 commits behind and --version never
|
|
47
75
|
// showed it). The git-backed resolution lives in ../lib/core/version.js, shared
|
|
@@ -56,18 +84,9 @@ const program = new Command();
|
|
|
56
84
|
program
|
|
57
85
|
.name('quox')
|
|
58
86
|
.description('QuoxCORE CLI — manage agents, workflows, memory, fleet, and more')
|
|
59
|
-
.version(versionRequested ? resolveCliVersion() : BASE_VERSION)
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
.option('-q, --quiet', 'suppress output, show IDs only')
|
|
63
|
-
.option('--org <slug>', 'override active organization')
|
|
64
|
-
.option('-p, --profile <name>', 'use a specific config profile')
|
|
65
|
-
.option('--no-color', 'disable colored output')
|
|
66
|
-
.option('-v, --verbose', 'show detailed output')
|
|
67
|
-
.option('--debug', 'show HTTP request/response details')
|
|
68
|
-
.option('--dry-run', 'show what would happen without executing')
|
|
69
|
-
.option('-y, --yes', 'skip confirmation prompts')
|
|
70
|
-
.option('--insecure', 'allow self-signed SSL certificates')
|
|
87
|
+
.version(versionRequested ? resolveCliVersion() : BASE_VERSION);
|
|
88
|
+
// Global options live in lib/core/rootOptions.js so the safety-flag test builds this same root.
|
|
89
|
+
applyRootOptions(program)
|
|
71
90
|
.addHelpText('after', '\nConversation (QUOXON client):\n quox interactive conversation (terminal only)\n quox --print "<prompt>" [--output text|json] [--conversation <id>] [--timeout <s>] one headless turn; exit 0 completed, 2 held for approval, 3 interrupted, 4 not signed in, 5 unconfirmed\n quox --demo simulated journey, nothing real runs\n');
|
|
72
91
|
|
|
73
92
|
// Wire up global flags
|
|
@@ -81,8 +100,30 @@ program.hook('preAction', (thisCommand) => {
|
|
|
81
100
|
// never receives it: commander resolves against the root first and the
|
|
82
101
|
// subcommand reads undefined forever. See lib/core/global-flags.js for the
|
|
83
102
|
// 13 places this had already shipped, including --dry-run executing for real.
|
|
84
|
-
|
|
85
|
-
|
|
103
|
+
// Also: a --dry-run the leaf cannot honour is refused, never silently dropped
|
|
104
|
+
// (quox#1077 follow-up). Both hooks live in lib/core/rootOptions.js.
|
|
105
|
+
installFlagDeliveryHooks(program);
|
|
106
|
+
|
|
107
|
+
// #1141: `--org <slug>` (and a slug in QUOX_ORG_ID) resolves to the org ID once, here, so every verb and
|
|
108
|
+
// the GRIPE-709 guard below see an ID. ID-shaped values pass through with no call. Login-type verbs are left alone.
|
|
109
|
+
program.hook('preAction', async (thisCommand, actionCommand) => {
|
|
110
|
+
const { isOrgId, resolveOrgRef } = await import('../lib/core/orgResolve.js');
|
|
111
|
+
const { EXEMPT } = await import('../lib/core/org-override.js');
|
|
112
|
+
if (EXEMPT.has(commandPath(actionCommand))) return;
|
|
113
|
+
const rootOrg = thisCommand.opts().org;
|
|
114
|
+
const leafOrg = actionCommand !== thisCommand ? actionCommand.getOptionValue?.('org') : undefined;
|
|
115
|
+
const envOrg = process.env.QUOX_ORG_ID;
|
|
116
|
+
if ([rootOrg, leafOrg, envOrg].every((v) => !v || typeof v !== 'string' || isOrgId(v))) return;
|
|
117
|
+
const { resolveEndpoint } = await import('../lib/api/endpoints.js');
|
|
118
|
+
const listOrgs = async () => {
|
|
119
|
+
const ep = resolveEndpoint('orgs.list');
|
|
120
|
+
const d = await client.get(ep.path, { service: ep.service });
|
|
121
|
+
return Array.isArray(d) ? d : (d?.organizations || d?.orgs || d?.data || []);
|
|
122
|
+
};
|
|
123
|
+
const base = { profile: config.getActiveProfileName?.() || 'default', authData: config.getAuth?.() || null, listOrgs };
|
|
124
|
+
if (typeof rootOrg === 'string' && !isOrgId(rootOrg)) thisCommand.setOptionValue('org', await resolveOrgRef(rootOrg, base));
|
|
125
|
+
if (typeof leafOrg === 'string' && !isOrgId(leafOrg)) actionCommand.setOptionValue('org', await resolveOrgRef(leafOrg, base));
|
|
126
|
+
if (envOrg && !isOrgId(envOrg)) process.env.QUOX_ORG_ID = await resolveOrgRef(envOrg, { ...base, source: 'QUOX_ORG_ID' });
|
|
86
127
|
});
|
|
87
128
|
|
|
88
129
|
// GRIPE-709: --org must be honoured or refused, never silently ignored.
|
|
@@ -135,101 +176,8 @@ const ctx = { config, auth, client, program };
|
|
|
135
176
|
// module(s) that define the command being run (see lib/core/lazyCommands.js),
|
|
136
177
|
// with a full load whenever the command is unknown, help is asked for, or the
|
|
137
178
|
// lazy path fails. A miss can only be slower, never wrong.
|
|
138
|
-
const COMMAND_REGISTRARS =
|
|
139
|
-
|
|
140
|
-
['../lib/commands/service.js', 'registerServiceCommands'],
|
|
141
|
-
['../lib/commands/status.js', 'registerStatusCommand'],
|
|
142
|
-
['../lib/commands/doctor.js', 'registerDoctorCommand'],
|
|
143
|
-
['../lib/commands/open.js', 'registerOpenCommand'],
|
|
144
|
-
['../lib/commands/motion.js', 'registerMotionCommand'],
|
|
145
|
-
['../lib/commands/config-cmd.js', 'registerConfigCommands'],
|
|
146
|
-
['../lib/commands/org.js', 'registerOrgCommands'],
|
|
147
|
-
['../lib/commands/invites.js', 'registerInvitesCommands'],
|
|
148
|
-
['../lib/commands/team.js', 'registerTeamCommands'],
|
|
149
|
-
['../lib/commands/department.js', 'registerDepartmentCommands'],
|
|
150
|
-
['../lib/commands/agent.js', 'registerAgentCommands'],
|
|
151
|
-
['../lib/commands/tool.js', 'registerToolCommands'],
|
|
152
|
-
['../lib/commands/workflow.js', 'registerWorkflowCommands'],
|
|
153
|
-
['../lib/commands/objective.js', 'registerObjectiveCommands'],
|
|
154
|
-
['../lib/commands/assistant.js', 'registerAssistantCommands'],
|
|
155
|
-
['../lib/commands/fleet.js', 'registerFleetCommands'],
|
|
156
|
-
['../lib/commands/chat.js', 'registerChatCommands'],
|
|
157
|
-
['../lib/commands/memory.js', 'registerMemoryCommands'],
|
|
158
|
-
['../lib/commands/brain.js', 'registerBrainCommands'],
|
|
159
|
-
['../lib/commands/entity.js', 'registerEntityCommands'],
|
|
160
|
-
['../lib/commands/backup.js', 'registerBackupCommands'],
|
|
161
|
-
['../lib/commands/inbox.js', 'registerInboxCommands'],
|
|
162
|
-
['../lib/commands/approvals.js', 'registerApprovalsCommands'],
|
|
163
|
-
['../lib/commands/mail.js', 'registerMailCommands'],
|
|
164
|
-
['../lib/commands/calendar.js', 'registerCalendarCommands'],
|
|
165
|
-
['../lib/commands/notes.js', 'registerNotesCommands'],
|
|
166
|
-
['../lib/commands/contacts.js', 'registerContactsCommands'],
|
|
167
|
-
['../lib/commands/licence.js', 'registerLicenceCommands'],
|
|
168
|
-
['../lib/commands/run.js', 'registerRunCommands'],
|
|
169
|
-
['../lib/commands/file.js', 'registerFileCommands'],
|
|
170
|
-
['../lib/commands/admin.js', 'registerAdminCommands'],
|
|
171
|
-
['../lib/commands/aee.js', 'registerAeeCommands'],
|
|
172
|
-
['../lib/commands/integration.js', 'registerIntegrationCommands'],
|
|
173
|
-
['../lib/commands/consent.js', 'registerConsentCommands'],
|
|
174
|
-
['../lib/commands/setup.js', 'registerSetupCommands'],
|
|
175
|
-
['../lib/commands/watch.js', 'registerWatchCommands'],
|
|
176
|
-
['../lib/commands/tag.js', 'registerTagCommands'],
|
|
177
|
-
['../lib/commands/scope.js', 'registerScopeCommands'],
|
|
178
|
-
['../lib/commands/notification.js', 'registerNotificationCommands'],
|
|
179
|
-
['../lib/commands/prompt.js', 'registerPromptCommands'],
|
|
180
|
-
['../lib/commands/plugin.js', 'registerPluginCommands'],
|
|
181
|
-
['../lib/commands/powers.js', 'registerPowersCommands'],
|
|
182
|
-
['../lib/commands/conversation.js', 'registerConversationCommands'],
|
|
183
|
-
['../lib/commands/vault.js', 'registerVaultCommands'],
|
|
184
|
-
['../lib/commands/volt.js', 'registerVoltCommands'],
|
|
185
|
-
['../lib/commands/governance.js', 'registerGovernanceCommands'],
|
|
186
|
-
['../lib/commands/skills.js', 'registerSkillsCommands'],
|
|
187
|
-
['../lib/commands/claude.js', 'registerClaudeCommands'],
|
|
188
|
-
['../lib/commands/monitoring.js', 'registerMonitoringCommands'],
|
|
189
|
-
['../lib/commands/trigger.js', 'registerTriggerCommands'],
|
|
190
|
-
['../lib/commands/webhook.js', 'registerWebhookCommands'],
|
|
191
|
-
['../lib/commands/sso.js', 'registerSsoCommands'],
|
|
192
|
-
['../lib/commands/role.js', 'registerRoleCommands'],
|
|
193
|
-
['../lib/commands/domain.js', 'registerDomainCommands'],
|
|
194
|
-
['../lib/commands/security.js', 'registerSecurityCommands'],
|
|
195
|
-
['../lib/commands/safety.js', 'registerSafetyCommands'],
|
|
196
|
-
['../lib/commands/scim.js', 'registerScimCommands'],
|
|
197
|
-
['../lib/commands/llm-policy.js', 'registerLlmPolicyCommands'],
|
|
198
|
-
['../lib/commands/hat.js', 'registerHatCommands'],
|
|
199
|
-
['../lib/commands/settings.js', 'registerSettingsCommands'],
|
|
200
|
-
['../lib/commands/llm.js', 'registerLlmCommands'],
|
|
201
|
-
['../lib/commands/capabilities.js', 'registerCapabilitiesCommands'],
|
|
202
|
-
['../lib/commands/quoxchat.js', 'registerQuoxchatCommands'],
|
|
203
|
-
['../lib/commands/budget.js', 'registerBudgetCommands'],
|
|
204
|
-
['../lib/commands/trace.js', 'registerTraceCommands'],
|
|
205
|
-
['../lib/commands/mon.js', 'registerMonCommands'],
|
|
206
|
-
['../lib/commands/quoxbox.js', 'registerQuoxboxCommands'],
|
|
207
|
-
['../lib/commands/plan.js', 'registerPlanCommands'],
|
|
208
|
-
['../lib/commands/engagement.js', 'registerEngagementCommands'],
|
|
209
|
-
['../lib/commands/done.js', 'registerDoneCommands'],
|
|
210
|
-
['../lib/commands/discord.js', 'registerDiscordCommands'],
|
|
211
|
-
['../lib/commands/qlarity.js', 'registerQlarityCommands'],
|
|
212
|
-
['../lib/commands/reach.js', 'registerReachCommands'],
|
|
213
|
-
['../lib/commands/inventory.js', 'registerInventoryCommands'],
|
|
214
|
-
['../lib/commands/policy.js', 'registerPolicyCommands'],
|
|
215
|
-
['../lib/commands/quoxseo.js', 'registerQuoxseoCommands'],
|
|
216
|
-
['../lib/commands/voice.js', 'registerVoiceCommands'],
|
|
217
|
-
['../lib/commands/awareness.js', 'registerAwarenessCommands'],
|
|
218
|
-
['../lib/commands/lucid.js', 'registerLucidCommands'],
|
|
219
|
-
['../lib/commands/tg.js', 'registerTgCommands'],
|
|
220
|
-
['../lib/commands/dev.js', 'registerDevCommands'],
|
|
221
|
-
['../lib/commands/build.js', 'registerBuildCommands'],
|
|
222
|
-
['../lib/commands/slot.js', 'registerSlotCommands'],
|
|
223
|
-
['../lib/commands/gripe.js', 'registerGripeCommands'],
|
|
224
|
-
['../lib/commands/nucleus.js', 'registerNucleusCommands'],
|
|
225
|
-
['../lib/commands/onboard.js', 'registerOnboardCommands'],
|
|
226
|
-
['../lib/commands/x.js', 'registerXCommands'],
|
|
227
|
-
['../lib/commands/linkedin.js', 'registerLinkedInCommands'],
|
|
228
|
-
['../lib/commands/facebook.js', 'registerFacebookCommands'],
|
|
229
|
-
['../lib/commands/instagram.js', 'registerInstagramCommands'],
|
|
230
|
-
['../lib/commands/tiktok.js', 'registerTikTokCommands'],
|
|
231
|
-
];
|
|
232
|
-
await registerCommandGroups(program, ctx, COMMAND_REGISTRARS, process.argv.slice(2), import.meta.url);
|
|
179
|
+
const { COMMAND_REGISTRARS, COMMAND_REGISTRARS_BASE } = await import('../lib/core/commandRegistrars.js');
|
|
180
|
+
await registerCommandGroups(program, ctx, COMMAND_REGISTRARS, process.argv.slice(2), COMMAND_REGISTRARS_BASE);
|
|
233
181
|
|
|
234
182
|
// TUI command
|
|
235
183
|
program
|
|
@@ -272,6 +220,20 @@ try {
|
|
|
272
220
|
// Plugin loading should never crash the CLI
|
|
273
221
|
}
|
|
274
222
|
|
|
223
|
+
// C4: once a day, warn when this CLI and the server differ in major/minor. Never for JSON/quiet output,
|
|
224
|
+
// a non-TTY stderr, or `quox server …` itself (that verb shows versions); never fails a command.
|
|
225
|
+
async function warnVersionSkew() {
|
|
226
|
+
try {
|
|
227
|
+
const o = program.opts();
|
|
228
|
+
if (o.output === 'json' || o.output === 'quiet' || o.json || o.quiet || !process.stderr.isTTY || process.env.QUOX_NO_SKEW_CHECK) return;
|
|
229
|
+
const first = process.argv.slice(2).find((a) => !a.startsWith('-'));
|
|
230
|
+
if (!first || first === 'server') return;
|
|
231
|
+
const { checkSkewOncePerDay } = await import('../lib/server/skew.js');
|
|
232
|
+
const sk = await checkSkewOncePerDay({ collectorUrl: config.getServiceUrl('collector') });
|
|
233
|
+
if (sk) process.stderr.write(`\u26a0 version skew: ${sk.message}\n`);
|
|
234
|
+
} catch { /* advisory only */ }
|
|
235
|
+
}
|
|
236
|
+
|
|
275
237
|
// Bare `quox` in a TTY never reaches here (routed to QUOXON above); bare
|
|
276
238
|
// non-TTY prints the banner so a script never hangs.
|
|
277
239
|
{
|
|
@@ -285,8 +247,19 @@ try {
|
|
|
285
247
|
process.exit(0);
|
|
286
248
|
}
|
|
287
249
|
await program.parseAsync(process.argv);
|
|
250
|
+
await warnVersionSkew();
|
|
288
251
|
} catch (err) {
|
|
289
|
-
|
|
252
|
+
// #1101: Ctrl-C at any inquirer prompt is the user leaving: "Cancelled.", cursor back, exit 130, no stack.
|
|
253
|
+
const { exitOnPromptCancel } = await import('../lib/core/promptCancel.js');
|
|
254
|
+
exitOnPromptCancel(err); // exits 130 on a cancel; otherwise falls through to the normal error printer
|
|
255
|
+
// #995: tell the error printer which group failed and what verbs it has, so a 404 hint names a real one
|
|
256
|
+
let ctx = null;
|
|
257
|
+
try {
|
|
258
|
+
const word = process.argv.slice(2).find((a, i, all) => !a.startsWith('-') && !['-p', '--profile', '--org', '-o', '--output'].includes(all[i - 1]));
|
|
259
|
+
const grp = word && program.commands.find((c) => c.name() === word || c.aliases().includes(word));
|
|
260
|
+
if (grp) ctx = { group: grp.name(), subcommands: grp.commands.map((c) => c.name()) };
|
|
261
|
+
} catch { /* the hint is advisory */ }
|
|
262
|
+
handleError(err, program.opts().output, ctx);
|
|
290
263
|
process.exit(err.exitCode || 1);
|
|
291
264
|
}
|
|
292
265
|
}
|
|
@@ -17,6 +17,32 @@ export const admin = {
|
|
|
17
17
|
path: () => '/api/admin/agent-identities',
|
|
18
18
|
tags: ['admin-write'],
|
|
19
19
|
},
|
|
20
|
+
// Instance basics after setup (app URL etc). Served by services/auth/routes/admin-instance.js.
|
|
21
|
+
'admin.instance.basics.get': {
|
|
22
|
+
method: 'GET',
|
|
23
|
+
service: 'auth',
|
|
24
|
+
path: () => '/api/admin/instance/basics',
|
|
25
|
+
tags: ['live-safe'],
|
|
26
|
+
},
|
|
27
|
+
'admin.instance.basics.set': {
|
|
28
|
+
method: 'PUT',
|
|
29
|
+
service: 'auth',
|
|
30
|
+
path: () => '/api/admin/instance/basics',
|
|
31
|
+
tags: ['admin-write'],
|
|
32
|
+
},
|
|
33
|
+
// LAN integration targets gate (allow_lan_integration_targets). Served by services/auth/routes/admin-instance.js.
|
|
34
|
+
'admin.instance.lan_targets.get': {
|
|
35
|
+
method: 'GET',
|
|
36
|
+
service: 'auth',
|
|
37
|
+
path: () => '/api/admin/instance/lan-targets',
|
|
38
|
+
tags: ['live-safe'],
|
|
39
|
+
},
|
|
40
|
+
'admin.instance.lan_targets.set': {
|
|
41
|
+
method: 'PUT',
|
|
42
|
+
service: 'auth',
|
|
43
|
+
path: () => '/api/admin/instance/lan-targets',
|
|
44
|
+
tags: ['admin-write'],
|
|
45
|
+
},
|
|
20
46
|
'admin.config.update': {
|
|
21
47
|
method: 'PATCH',
|
|
22
48
|
service: 'auth',
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 'agent-schedules.*' endpoints (tasks service, services/tasks/server.js "agent-schedules" routes).
|
|
3
|
+
* A cron-driven task for an agent: the scheduler creates an objective and runs the prompt each tick,
|
|
4
|
+
* escalating to the owner's approvals inbox per the escalation policy. /watch (quoxon) stands on this.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
export const agentSchedules = {
|
|
8
|
+
'agent-schedules.create': {
|
|
9
|
+
method: 'POST',
|
|
10
|
+
service: 'tasks',
|
|
11
|
+
path: () => `/api/agent-schedules`,
|
|
12
|
+
tags: ['live-write'],
|
|
13
|
+
},
|
|
14
|
+
'agent-schedules.list': {
|
|
15
|
+
method: 'GET',
|
|
16
|
+
service: 'tasks',
|
|
17
|
+
path: () => `/api/agent-schedules`,
|
|
18
|
+
tags: ['live-safe'],
|
|
19
|
+
},
|
|
20
|
+
'agent-schedules.delete': {
|
|
21
|
+
method: 'DELETE',
|
|
22
|
+
service: 'tasks',
|
|
23
|
+
path: ({ id }) => `/api/agent-schedules/${encodeURIComponent(id)}`,
|
|
24
|
+
tags: ['live-write'],
|
|
25
|
+
},
|
|
26
|
+
};
|
|
@@ -23,6 +23,13 @@ export const agents = {
|
|
|
23
23
|
path: ({ orgId, agentId }) => `/api/orgs/${orgId}/agents/${agentId}`,
|
|
24
24
|
tags: ['live-safe'],
|
|
25
25
|
},
|
|
26
|
+
// ASIDE: a no-tools, no-conversation model call (quox aside, the TUI /aside). Spends tokens, changes nothing.
|
|
27
|
+
'agents.invoke.notools': {
|
|
28
|
+
method: 'POST',
|
|
29
|
+
service: 'collector',
|
|
30
|
+
path: () => `/api/internal/agents/invoke`,
|
|
31
|
+
tags: ['skip-live'],
|
|
32
|
+
},
|
|
26
33
|
'agents.list': {
|
|
27
34
|
method: 'GET',
|
|
28
35
|
service: 'auth',
|
|
@@ -23,12 +23,24 @@ export const assistants = {
|
|
|
23
23
|
path: ({ orgId, assistantId }) => `/api/orgs/${orgId}/assistants/${assistantId}/deploy`,
|
|
24
24
|
tags: ['live-write'],
|
|
25
25
|
},
|
|
26
|
+
'assistants.undeploy': {
|
|
27
|
+
method: 'DELETE',
|
|
28
|
+
service: 'auth',
|
|
29
|
+
path: ({ orgId, assistantId, deploymentId }) => `/api/orgs/${orgId}/assistants/${assistantId}/deployments/${deploymentId}`,
|
|
30
|
+
tags: ['live-write'],
|
|
31
|
+
},
|
|
26
32
|
'assistants.fork': {
|
|
27
33
|
method: 'POST',
|
|
28
34
|
service: 'auth',
|
|
29
35
|
path: ({ orgId, assistantId }) => `/api/orgs/${orgId}/assistants/${assistantId}/fork`,
|
|
30
36
|
tags: ['live-write'],
|
|
31
37
|
},
|
|
38
|
+
'assistants.publish': {
|
|
39
|
+
method: 'POST',
|
|
40
|
+
service: 'auth',
|
|
41
|
+
path: ({ orgId, assistantId }) => `/api/orgs/${orgId}/assistants/${assistantId}/publish`,
|
|
42
|
+
tags: ['live-write'],
|
|
43
|
+
},
|
|
32
44
|
'assistants.get': {
|
|
33
45
|
method: 'GET',
|
|
34
46
|
service: 'auth',
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 'away.*' endpoints: E5 "What happened while I was away?" (`/away` in the quox client).
|
|
3
|
+
* Collector route GET /api/v1/away?since=<iso> (org + user scoped, requireServiceOrUserAuth).
|
|
4
|
+
*
|
|
5
|
+
* See cli/lib/api/endpoints/index.js for the fragment convention.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export const away = {
|
|
9
|
+
'away.digest': {
|
|
10
|
+
method: 'GET',
|
|
11
|
+
service: 'collector',
|
|
12
|
+
path: () => `/api/v1/away`,
|
|
13
|
+
tags: ['live-safe'],
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -31,6 +31,13 @@ export const chat = {
|
|
|
31
31
|
path: () => `/api/v1/providers/ollama/probe`,
|
|
32
32
|
tags: ['live-safe'],
|
|
33
33
|
},
|
|
34
|
+
// QUOXON-MODEL: live model list for the hosted providers (openai | anthropic), server cached 1 h.
|
|
35
|
+
'chat.providers.models': {
|
|
36
|
+
method: 'GET',
|
|
37
|
+
service: 'collector',
|
|
38
|
+
path: ({ provider }) => `/api/v1/providers/${encodeURIComponent(provider)}/models`,
|
|
39
|
+
tags: ['live-safe'],
|
|
40
|
+
},
|
|
34
41
|
'chat.providers.ollama.models': {
|
|
35
42
|
method: 'GET',
|
|
36
43
|
service: 'collector',
|
|
@@ -57,8 +57,10 @@ export const contactsq = {
|
|
|
57
57
|
'contactsq.sync.remove': { method: 'DELETE', service: 'collector', path: ({ id }) => `${B}/sync/sources/${id}`, tags: ['live-write'] },
|
|
58
58
|
// P8a: morning brief, timeline / touchpoints / policy (selftest), handoff notes.
|
|
59
59
|
'contactsq.brief': { method: 'GET', service: 'collector', path: () => `${B}/brief`, tags: ['live-safe'] },
|
|
60
|
+
'contactsq.count': { method: 'GET', service: 'collector', path: () => `${B}/count`, tags: ['live-safe'] },
|
|
60
61
|
'contactsq.timeline': { method: 'GET', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/timeline`, tags: ['live-safe'] },
|
|
61
62
|
'contactsq.touchpoints.add': { method: 'POST', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/touchpoints`, tags: ['live-write'] },
|
|
63
|
+
'contactsq.best_channel': { method: 'GET', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/best-channel`, tags: ['live-safe'] },
|
|
62
64
|
'contactsq.policy': { method: 'POST', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/policy`, tags: ['live-safe'] },
|
|
63
65
|
'contactsq.handoffs.add': { method: 'POST', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/handoffs` },
|
|
64
66
|
'contactsq.handoffs': { method: 'GET', service: 'collector', path: ({ id }) => `${B}/contacts/${id}/handoffs`, tags: ['live-safe'] },
|
|
@@ -5,6 +5,20 @@
|
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
7
|
export const conversations = {
|
|
8
|
+
// #1016: chat conversations (the collector's chat_session_turns, what chat writes). The memory-service
|
|
9
|
+
// routes below are the IMPORTED conversation archive, reached with --archive.
|
|
10
|
+
'conversations.chat.list': {
|
|
11
|
+
method: 'GET',
|
|
12
|
+
service: 'collector',
|
|
13
|
+
path: () => `/api/v1/conversations`,
|
|
14
|
+
tags: ['live-safe'],
|
|
15
|
+
},
|
|
16
|
+
'conversations.chat.turns': {
|
|
17
|
+
method: 'GET',
|
|
18
|
+
service: 'collector',
|
|
19
|
+
path: ({ id }) => `/api/v1/conversations/${encodeURIComponent(id)}/turns`,
|
|
20
|
+
tags: ['live-safe'],
|
|
21
|
+
},
|
|
8
22
|
'conversations.get': {
|
|
9
23
|
method: 'GET',
|
|
10
24
|
service: 'memory',
|
|
@@ -29,4 +29,17 @@ export const executions = {
|
|
|
29
29
|
path: () => `/api/executions`,
|
|
30
30
|
tags: ['live-safe'],
|
|
31
31
|
},
|
|
32
|
+
// #997: `run cancel`/`run resume` reach the engine first (these are the runs `run list` shows)
|
|
33
|
+
'executions.cancel': {
|
|
34
|
+
method: 'POST',
|
|
35
|
+
service: 'quoxflow',
|
|
36
|
+
path: ({ executionId }) => `/api/executions/${executionId}/cancel`,
|
|
37
|
+
tags: ['live-write'],
|
|
38
|
+
},
|
|
39
|
+
'executions.resume': {
|
|
40
|
+
method: 'POST',
|
|
41
|
+
service: 'quoxflow',
|
|
42
|
+
path: ({ executionId }) => `/api/executions/${executionId}/resume`,
|
|
43
|
+
tags: ['live-write'],
|
|
44
|
+
},
|
|
32
45
|
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 'fetchAllowlist.*' endpoints: the per-org URL-prefix allowlist behind the governed
|
|
3
|
+
* agent fetch tool (web_fetch_allowlisted, quox#1171). Collector-owned routes
|
|
4
|
+
* (services/collector/lib/agentFetchAllowlistRoutes.js). Writes are human org
|
|
5
|
+
* admin only on the server.
|
|
6
|
+
*
|
|
7
|
+
* See cli/lib/api/endpoints/index.js for the fragment convention.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
export const fetchAllowlist = {
|
|
11
|
+
'fetchAllowlist.list': {
|
|
12
|
+
method: 'GET',
|
|
13
|
+
service: 'collector',
|
|
14
|
+
path: () => `/api/v1/fetch-allowlist`,
|
|
15
|
+
tags: ['live-safe'],
|
|
16
|
+
},
|
|
17
|
+
'fetchAllowlist.add': {
|
|
18
|
+
method: 'POST',
|
|
19
|
+
service: 'collector',
|
|
20
|
+
path: () => `/api/v1/fetch-allowlist`,
|
|
21
|
+
},
|
|
22
|
+
'fetchAllowlist.remove': {
|
|
23
|
+
method: 'DELETE',
|
|
24
|
+
service: 'collector',
|
|
25
|
+
path: ({ prefix }) => `/api/v1/fetch-allowlist?url_prefix=${encodeURIComponent(prefix)}`,
|
|
26
|
+
},
|
|
27
|
+
};
|
|
@@ -23,4 +23,18 @@ export const files = {
|
|
|
23
23
|
path: () => `/upload`,
|
|
24
24
|
tags: ['live-write'],
|
|
25
25
|
},
|
|
26
|
+
// F01 A': quarantined legacy files (no proven owner) and their owner-approved assignment. Collector routes,
|
|
27
|
+
// human instance admin only (enforced server-side).
|
|
28
|
+
'files.quarantine.list': {
|
|
29
|
+
method: 'GET',
|
|
30
|
+
service: 'collector',
|
|
31
|
+
path: () => `/api/v1/admin/files/quarantine`,
|
|
32
|
+
tags: ['live-safe'],
|
|
33
|
+
},
|
|
34
|
+
'files.quarantine.assign': {
|
|
35
|
+
method: 'POST',
|
|
36
|
+
service: 'collector',
|
|
37
|
+
path: () => `/api/v1/admin/files/assign`,
|
|
38
|
+
tags: ['live-write'],
|
|
39
|
+
},
|
|
26
40
|
};
|
package/lib/api/endpoints/hat.js
CHANGED
|
@@ -26,6 +26,36 @@ export const hat = {
|
|
|
26
26
|
path: ({ orgId, hatId }) => `/api/orgs/${orgId}/quoxhat/hats/${encodeURIComponent(hatId)}`,
|
|
27
27
|
tags: ['live-safe'],
|
|
28
28
|
},
|
|
29
|
+
// quox#1183: which hat a conversation is on, and the person's own switch (audited quoxhat.binding.selected).
|
|
30
|
+
'hat.resolve': {
|
|
31
|
+
method: 'GET',
|
|
32
|
+
service: 'auth',
|
|
33
|
+
path: ({ orgId }) => `/api/orgs/${orgId}/quoxhat/resolve`,
|
|
34
|
+
tags: ['live-safe'],
|
|
35
|
+
},
|
|
36
|
+
'hat.bind': {
|
|
37
|
+
method: 'PUT',
|
|
38
|
+
service: 'auth',
|
|
39
|
+
path: ({ orgId, conversationId }) => `/api/orgs/${orgId}/quoxhat/bindings/${encodeURIComponent(conversationId)}`,
|
|
40
|
+
},
|
|
41
|
+
// CUSTOM-HATS (owner 2026-10-17): create / edit (definition + optional rename) / delete a custom
|
|
42
|
+
// hat. Same auth routes the dashboard uses; org hats need org manage-settings, a private hat only
|
|
43
|
+
// its owner. Every write is revisioned and audited server-side (quoxhat.hat.created|updated|deleted).
|
|
44
|
+
'hat.create': {
|
|
45
|
+
method: 'POST',
|
|
46
|
+
service: 'auth',
|
|
47
|
+
path: ({ orgId }) => `/api/orgs/${orgId}/quoxhat/hats`,
|
|
48
|
+
},
|
|
49
|
+
'hat.update': {
|
|
50
|
+
method: 'PUT',
|
|
51
|
+
service: 'auth',
|
|
52
|
+
path: ({ orgId, hatId }) => `/api/orgs/${orgId}/quoxhat/hats/${encodeURIComponent(hatId)}`,
|
|
53
|
+
},
|
|
54
|
+
'hat.delete': {
|
|
55
|
+
method: 'DELETE',
|
|
56
|
+
service: 'auth',
|
|
57
|
+
path: ({ orgId, hatId }) => `/api/orgs/${orgId}/quoxhat/hats/${encodeURIComponent(hatId)}`,
|
|
58
|
+
},
|
|
29
59
|
// Audited reset of an org-edited built-in hat back to its current template
|
|
30
60
|
// (needs org manage-settings); writes quoxhat.hat.reset_to_template.
|
|
31
61
|
'hat.reset': {
|
|
@@ -17,12 +17,32 @@ export const inbox = {
|
|
|
17
17
|
path: ({ orgId }) => `/api/orgs/${orgId}/inbox`,
|
|
18
18
|
tags: ['live-safe'],
|
|
19
19
|
},
|
|
20
|
+
// quox#827: the ONE server-side set of open approvals this user can act on (also backs stats.pending_approvals and LUCID).
|
|
21
|
+
'inbox.approvals.open': {
|
|
22
|
+
method: 'GET',
|
|
23
|
+
service: 'auth',
|
|
24
|
+
path: ({ orgId }) => `/api/orgs/${orgId}/approvals/open`,
|
|
25
|
+
tags: ['live-safe'],
|
|
26
|
+
},
|
|
20
27
|
'inbox.respond': {
|
|
21
28
|
method: 'POST',
|
|
22
29
|
service: 'auth',
|
|
23
30
|
path: ({ orgId, itemId }) => `/api/orgs/${orgId}/inbox/${itemId}/respond`,
|
|
24
31
|
tags: ['live-write'],
|
|
25
32
|
},
|
|
33
|
+
// quox ask: a session files a decision request (one inbox item) and waits for the human's answer.
|
|
34
|
+
'inbox.decision.create': {
|
|
35
|
+
method: 'POST',
|
|
36
|
+
service: 'auth',
|
|
37
|
+
path: ({ orgId }) => `/api/orgs/${orgId}/decisions`,
|
|
38
|
+
tags: ['live-write'],
|
|
39
|
+
},
|
|
40
|
+
'inbox.decision.get': {
|
|
41
|
+
method: 'GET',
|
|
42
|
+
service: 'auth',
|
|
43
|
+
path: ({ orgId, id }) => `/api/orgs/${orgId}/decisions/${id}`,
|
|
44
|
+
tags: ['live-safe'],
|
|
45
|
+
},
|
|
26
46
|
'inbox.stats.list': {
|
|
27
47
|
method: 'GET',
|
|
28
48
|
service: 'auth',
|