@oddessentials/agent-guild 1.22.0 → 1.22.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.
Files changed (36) hide show
  1. package/bin/native/win32-arm64/agent-guild-report.exe +0 -0
  2. package/bin/native/win32-x64/agent-guild-report.exe +0 -0
  3. package/bin/windows/arm64/agent-guild-start.exe +0 -0
  4. package/bin/windows/x64/agent-guild-start.exe +0 -0
  5. package/docs/api.md +23 -12
  6. package/node_modules/node-pty/prebuilds/win32-arm64/conpty.node +0 -0
  7. package/node_modules/node-pty/prebuilds/win32-arm64/conpty_console_list.node +0 -0
  8. package/node_modules/node-pty/prebuilds/win32-x64/conpty.node +0 -0
  9. package/node_modules/node-pty/prebuilds/win32-x64/conpty_console_list.node +0 -0
  10. package/node_modules/smol-toml/LICENSE +24 -0
  11. package/node_modules/smol-toml/README.md +605 -0
  12. package/node_modules/smol-toml/dist/date.d.ts +41 -0
  13. package/node_modules/smol-toml/dist/date.js +156 -0
  14. package/node_modules/smol-toml/dist/error.d.ts +37 -0
  15. package/node_modules/smol-toml/dist/error.js +67 -0
  16. package/node_modules/smol-toml/dist/extract.js +293 -0
  17. package/node_modules/smol-toml/dist/index.cjs +771 -0
  18. package/node_modules/smol-toml/dist/index.d.ts +44 -0
  19. package/node_modules/smol-toml/dist/index.js +34 -0
  20. package/node_modules/smol-toml/dist/parse.d.ts +73 -0
  21. package/node_modules/smol-toml/dist/parse.js +164 -0
  22. package/node_modules/smol-toml/dist/primitive.js +151 -0
  23. package/node_modules/smol-toml/dist/stringify.d.ts +32 -0
  24. package/node_modules/smol-toml/dist/stringify.js +219 -0
  25. package/node_modules/smol-toml/dist/struct.js +156 -0
  26. package/node_modules/smol-toml/dist/util.d.ts +43 -0
  27. package/node_modules/smol-toml/dist/util.js +57 -0
  28. package/node_modules/smol-toml/package.json +68 -0
  29. package/package.json +2 -1
  30. package/src/manager/config.mjs +10 -10
  31. package/src/manager/mcp-connect.mjs +332 -98
  32. package/src/manager/server.mjs +6 -3
  33. package/web/app.js +82 -41
  34. package/web/index.html +10 -6
  35. package/web/styles.css +13 -4
  36. package/web/yard/art.json +1 -1
package/docs/api.md CHANGED
@@ -158,17 +158,28 @@ cannot be used, or is null.
158
158
  `mcp` is null unless the tool is installed and Agent Guild can add its own MCP
159
159
  server (`agent-guild mcp`, see [mcp.md](mcp.md)) to the tool's settings:
160
160
  Claude Code, Codex CLI, Antigravity CLI and Grok Build. Otherwise it is
161
- `{ state, on, total, accounts }`, read from each account's settings and kept
162
- for up to a minute. `accounts` lists `{ id, label, state, detail }` per
163
- account, where `state` is `on`, `off`, `disabled` (Agent Guild's server, turned
164
- off in the tool), `other` (a server of that name that runs something else,
165
- which Agent Guild never changes) or `unknown` (the settings could not be
166
- read), and `detail` says why for `other` and `unknown`. An account whose home folder does not exist yet
167
- reads `off`, and turning the server on makes the folder. `on` counts the
168
- accounts that are on, of `total`. The provider's `state` is `on` or `off` when
169
- every account is, `partial` when some but not all are on, else `unknown`,
170
- `other` or `disabled` for the first of those any account has; `checking`
171
- before the first read, with `accounts` empty.
161
+ `{ mode, accounts }`: `mode` is `claude`, `codex`, `antigravity` or `grok`, and
162
+ `accounts` has one `{ id, label, state, managed, from, command, allowInput,
163
+ detail, fingerprint }` per account, read from that account's settings. A
164
+ settings file the tool keeps as JSON is read again when it changes; a tool
165
+ asked through its CLI is asked again after a minute.
166
+
167
+ `state` is `checking` before the first read, `off`, `on`, `disabled` (turned
168
+ off in the tool), `conflict` or `error`. `on` and `disabled` mean the entry
169
+ named agent-guild starts Agent Guild's MCP server (`agent-guild mcp`, `npx
170
+ @oddessentials/agent-guild mcp` or Node running its `bin/agent-guild.mjs mcp`)
171
+ and reaches this manager's data folder, as the tool would start it: from
172
+ the first `--home=` when it names a folder, else the entry's `AGENT_GUILD_HOME`, else `APPDATA`,
173
+ `XDG_CONFIG_HOME` or the home folder from the tool's environment.
174
+ `conflict` is any other entry of that name, including one whose data folder
175
+ depends on an `AGENT_GUILD_HOME` set where the tool starts; `error` means the
176
+ tool's settings could not be read. `detail` says why for both. `managed` is
177
+ true for the entry Agent Guild adds itself. `from` names the other tool whose
178
+ settings the entry comes from (Grok Build loads Claude Code's and Cursor's), or
179
+ is null. `command` is the entry's command line. `fingerprint` identifies the
180
+ whole entry as read, or is null for `checking` and `error`. An account whose
181
+ home folder does not exist yet reads `off`, and turning the server on makes
182
+ the folder.
172
183
 
173
184
  `usageUrl`, `billingUrl` and `cloudUrl` are
174
185
  `https://` links to the vendor's usage and billing pages and web app, or null.
@@ -641,7 +652,7 @@ All paths are under `/api/v1`.
641
652
  | PATCH | `/providers/:id/accounts/:account` | `{ label, revision }` | `{ account, dir, providers, revision }`: renames an account, including `default`. |
642
653
  | DELETE | `/providers/:id/accounts/:account?revision=` | | `{ account, dir, providers, revision }`: removes an account from `providers.json`. Its home folder, `dir`, stays on disk. 409 `default_account` for `default`; 409 `account_in_use` while a running session uses it. |
643
654
  | POST | `/providers/:id/reporting` | `{ enabled }` | `{ provider }`: turns agent or model reporting on or off for a tool that has `reportingEnabled`. |
644
- | POST | `/providers/:id/mcp` | `{ enabled }` | `{ provider, results }`: adds Agent Guild's MCP server to, or removes it from, each account of a tool that has `mcp`. Each account is read again first; one whose state is then `other` or `unknown` is left as it is. `results` has one `{ id, label, outcome, state, detail? }` per account, `outcome` `added`, `removed`, `unchanged`, `skipped` or `failed`; a failed account does not undo the others. 400 `not_applicable` for a tool without `mcp`; 409 `provider_unavailable` when it is not installed; 409 `busy` while a change for that tool is running. |
655
+ | POST | `/providers/:id/mcp` | `{ account, action, expect }` | `{ provider, result }`: changes Agent Guild's MCP server in one account's settings. `action` is `on` (add it, or turn it on in the tool), `off` (remove Agent Guild's entry, or turn off one that comes from another tool's settings) or `replace` (put Agent Guild's own entry in place of the one there). `expect` is the account's `fingerprint`: the account is read again first, and nothing changes unless the entry is still that one. `result` is `{ outcome, state, detail? }`, `outcome` `changed`, `unchanged` or `failed`. 400 `not_applicable` for a tool without `mcp`; 404 `unknown_account`; 409 `provider_unavailable` when it is not installed, `busy` while a change for that tool is running, `changed` when the entry is no longer `expect`, `unreadable` when the settings cannot be read, `conflict` for `on` or `off` on another server of that name, `needs_replace` for `on` on a Codex CLI entry Agent Guild did not add. |
645
656
  | POST | `/providers/:id/install` | `{ force? }` | `201 { session }`: a session that installs or updates the tool. 409 `provider_in_use` (with `running`, the session count) while the provider's sessions are running; retry with `force: true` after the user confirms. |
646
657
  | POST | `/providers/:id/uninstall` | `{ path, force? }` | `201 { session }`: a session that removes the copy at `path`, one of the provider's `installs`. `force` as for `install`. |
647
658
  | GET | `/environment?scope=&cwd=&id=` | | An environment snapshot; see [Manager environment](#manager-environment). |
@@ -0,0 +1,24 @@
1
+ Copyright (c) Squirrel Chat et al., All rights reserved.
2
+
3
+ Redistribution and use in source and binary forms, with or without
4
+ modification, are permitted provided that the following conditions are met:
5
+
6
+ 1. Redistributions of source code must retain the above copyright notice, this
7
+ list of conditions and the following disclaimer.
8
+ 2. Redistributions in binary form must reproduce the above copyright notice,
9
+ this list of conditions and the following disclaimer in the
10
+ documentation and/or other materials provided with the distribution.
11
+ 3. Neither the name of the copyright holder nor the names of its contributors
12
+ may be used to endorse or promote products derived from this software without
13
+ specific prior written permission.
14
+
15
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
16
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17
+ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
19
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
20
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
21
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
22
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
23
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
24
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.