agent-console-server 3.3.0 → 3.5.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/README.md +14 -12
- package/dist/EphemeralAgentEventTypes-DGkHIIcW.js +838 -0
- package/dist/cli.js +104 -26
- package/dist/contracts.d.ts +2 -2
- package/dist/contracts.js +2 -3
- package/dist/{constants-eNCfNezp.d.ts → getSignedText-DQwqr8CH.d.ts} +267 -8
- package/dist/index.d.ts +321 -12
- package/dist/index.js +3 -4
- package/dist/{readToken-CAukYBGj.js → spawnPtyShell-CtAiD2BH.js} +1104 -115
- package/package.json +9 -5
- package/dist/EphemeralAgentEventTypes-Cm5oNQXu.js +0 -274
- package/dist/ServerMessage-Deh-bExC.js +0 -363
package/README.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
[![NPM downloads][badge-npm-downloads]][url-npm]
|
|
6
6
|
[![NPM Unpacked Size (with version)][badge-npm-unpacked-size]][url-npm]
|
|
7
7
|
|
|
8
|
-
Runs your Claude Code sessions on your own machine and serves them to the [Esposter agent console](https://esposter.com/agent-console) over one
|
|
8
|
+
Runs your Claude Code sessions on your own machine and serves them to the [Esposter agent console](https://esposter.com/agent-console) over one WebSocket that admits only the browsers paired with it. Sessions go through the Claude Agent SDK with your own settings, CLAUDE.md, skills, hooks and plugins, and they are written where the terminal writes them, so `claude --resume <id>` picks up a console session and the console picks up a terminal one. The wire is Zod contracts, exported as the `contracts` subpath.
|
|
9
9
|
|
|
10
10
|
## Table of Contents
|
|
11
11
|
|
|
@@ -21,26 +21,28 @@ Runs your Claude Code sessions on your own machine and serves them to the [Espos
|
|
|
21
21
|
pnpm dlx agent-console-server
|
|
22
22
|
```
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
On Windows there is also a standalone host that needs no Node or pnpm: download `agent-console-host.exe` from the [latest release](https://github.com/Esposter/Esposter/releases/latest) and open it. It installs itself into `%LOCALAPPDATA%\Esposter\Host`, writes out the Claude Code binary it carries, registers the `esposter-host://` link the page starts it with, and runs in a console window of its own; `agent-console-host.exe uninstall` removes it. It is unsigned, so Windows asks once — choose More info, then Run anyway.
|
|
25
|
+
|
|
26
|
+
Press Connect on the page, or hold Ctrl and click the one-time link the host prints. Each browser pairs with a credential of its own, and the host proves itself with a key before a page sends it. The host keeps its key and each browser's credential hash in `~/.agent-console-server`, and the browser keeps its credential and the host's public key in local storage, so a paired page stays paired across restarts. `agent-console-server devices` lists the paired browsers, and `devices --revoke <id>` removes one.
|
|
25
27
|
|
|
26
28
|
## <a name="documentation">📖 Documentation</a>
|
|
27
29
|
|
|
28
30
|
We highly recommend you take a look at the [documentation](https://esposter.com/docs/api/modules/agent-console-server.html) to level up.
|
|
29
31
|
|
|
30
|
-
`agent-console-server [--port <port>] [--hostname <address>] [--origin <app origin>]`
|
|
32
|
+
`agent-console-server [--port <port>] [--hostname <address>] [--origin <app origin>]`, and `agent-console-server devices [--revoke <id>]`
|
|
31
33
|
|
|
32
34
|
| Flag | Default | What it does |
|
|
33
35
|
| :----------- | :--------------------- | :-------------------------------------------------------------------------------------------------------- |
|
|
34
|
-
| `--port` | `7437` | The port to listen on
|
|
36
|
+
| `--port` | `7437` | The port to listen on, and the one in the link it prints |
|
|
35
37
|
| `--hostname` | `127.0.0.1` | The address to listen on. `0.0.0.0` lets another machine reach the host, over a network you already trust |
|
|
36
|
-
| `--origin` | `https://esposter.com` | The app the printed
|
|
37
|
-
|
|
38
|
-
| Export | What it is
|
|
39
|
-
| :------------------------------- |
|
|
40
|
-
| `agent-console-server/contracts` | The wire: the session list, the event union, the command union and the server messages
|
|
41
|
-
| `createAgentConsoleServer` | The host: an HTTP listener answering the private-network preflight and the
|
|
42
|
-
| `createClaudeAgentSdkDriver` | The Claude Code driver, one streaming-input Agent SDK query per open session
|
|
43
|
-
| `Driver` | The interface another agent's driver implements
|
|
38
|
+
| `--origin` | `https://esposter.com` | The app the printed link opens, and the one origin that may pair, such as `http://localhost:3000` |
|
|
39
|
+
|
|
40
|
+
| Export | What it is |
|
|
41
|
+
| :------------------------------- | :---------------------------------------------------------------------------------------------- |
|
|
42
|
+
| `agent-console-server/contracts` | The wire: the session list, the event union, the command union and the server messages |
|
|
43
|
+
| `createAgentConsoleServer` | The host: an HTTP listener answering the private-network preflight and the paired pages' socket |
|
|
44
|
+
| `createClaudeAgentSdkDriver` | The Claude Code driver, one streaming-input Agent SDK query per open session |
|
|
45
|
+
| `Driver` | The interface another agent's driver implements |
|
|
44
46
|
|
|
45
47
|
Commands: `pnpm build`, `pnpm test`, `pnpm typecheck`, `pnpm lint:fix`.
|
|
46
48
|
|