@poolzin/pool-bot 2026.3.16 → 2026.3.18

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 (88) hide show
  1. package/CHANGELOG.md +69 -0
  2. package/dist/agents/tools/web-fetch.js +1 -1
  3. package/dist/build-info.json +3 -3
  4. package/dist/commands/skills-openclaw.command.js +123 -0
  5. package/dist/config/paths.js +7 -0
  6. package/dist/infra/net/fetch-guard.js +191 -146
  7. package/dist/media/fetch.js +83 -112
  8. package/dist/media/inbound-path-policy.js +90 -97
  9. package/dist/media/read-response-with-limit.js +49 -26
  10. package/dist/media-understanding/attachments.js +1 -1
  11. package/dist/plugin-sdk/audio.js +7 -0
  12. package/dist/plugin-sdk/bluebubbles.js +7 -0
  13. package/dist/plugin-sdk/browser.js +7 -0
  14. package/dist/plugin-sdk/canvas.js +7 -0
  15. package/dist/plugin-sdk/cron.js +7 -0
  16. package/dist/plugin-sdk/discord-actions.js +6 -0
  17. package/dist/plugin-sdk/discord.js +7 -0
  18. package/dist/plugin-sdk/image.js +7 -0
  19. package/dist/plugin-sdk/imessage.js +6 -0
  20. package/dist/plugin-sdk/keyed-async-queue.js +35 -0
  21. package/dist/plugin-sdk/media.js +8 -0
  22. package/dist/plugin-sdk/memory.js +7 -0
  23. package/dist/plugin-sdk/pdf.js +7 -0
  24. package/dist/plugin-sdk/sessions.js +7 -0
  25. package/dist/plugin-sdk/signal.js +6 -0
  26. package/dist/plugin-sdk/slack-actions.js +7 -0
  27. package/dist/plugin-sdk/slack.js +7 -0
  28. package/dist/plugin-sdk/telegram-actions.js +6 -0
  29. package/dist/plugin-sdk/telegram.js +6 -0
  30. package/dist/plugin-sdk/test-utils.js +110 -0
  31. package/dist/plugin-sdk/tts.js +7 -0
  32. package/dist/plugin-sdk/whatsapp.js +6 -0
  33. package/dist/providers/github-copilot-auth.js +53 -76
  34. package/dist/providers/github-copilot-models.js +63 -35
  35. package/dist/providers/github-copilot-token.js +46 -89
  36. package/dist/security/audit-findings.js +165 -0
  37. package/dist/security/audit.js +141 -572
  38. package/dist/skills/openclaw-skill-loader.js +191 -0
  39. package/dist/slack/monitor/media.js +2 -1
  40. package/docs/branding-evaluation-2026-03-12.md +285 -0
  41. package/docs/improvements/OPENCLAW-IMPLEMENTATION.md +45 -0
  42. package/docs/skills/openclaw-integration.md +295 -0
  43. package/docs/testing/TEST-PLAN-2026-03-13.md +338 -0
  44. package/docs/version-2026.3.16-evaluation.md +190 -0
  45. package/extensions/acpx/package.json +19 -0
  46. package/extensions/acpx/poolbot.plugin.json +9 -0
  47. package/extensions/acpx/src/index.ts +34 -0
  48. package/extensions/bluebubbles/src/runtime.ts +1 -0
  49. package/extensions/diffs/package.json +15 -0
  50. package/extensions/diffs/poolbot.plugin.json +10 -0
  51. package/extensions/diffs/src/index.ts +106 -0
  52. package/extensions/discord/src/runtime.ts +1 -0
  53. package/extensions/feishu/src/runtime.ts +1 -0
  54. package/extensions/github-copilot/package.json +28 -0
  55. package/extensions/github-copilot/poolbot.plugin.json +29 -0
  56. package/extensions/github-copilot/src/index.ts +126 -0
  57. package/extensions/github-copilot/tsconfig.json +10 -0
  58. package/extensions/googlechat/src/runtime.ts +1 -0
  59. package/extensions/imessage/src/runtime.ts +1 -0
  60. package/extensions/irc/src/runtime.ts +1 -0
  61. package/extensions/line/src/runtime.ts +1 -0
  62. package/extensions/matrix/src/runtime.ts +1 -0
  63. package/extensions/mattermost/src/mattermost/monitor-helpers.ts +10 -1
  64. package/extensions/mattermost/src/runtime.ts +6 -3
  65. package/extensions/msteams/src/runtime.ts +1 -0
  66. package/extensions/nextcloud-talk/src/runtime.ts +1 -0
  67. package/extensions/nostr/src/runtime.ts +5 -2
  68. package/extensions/ollama/package.json +20 -0
  69. package/extensions/ollama/poolbot.plugin.json +14 -0
  70. package/extensions/ollama/src/index.ts +95 -0
  71. package/extensions/sglang/package.json +18 -0
  72. package/extensions/sglang/poolbot.plugin.json +13 -0
  73. package/extensions/sglang/src/index.ts +62 -0
  74. package/extensions/signal/src/runtime.ts +1 -0
  75. package/extensions/slack/src/runtime.ts +1 -0
  76. package/extensions/telegram/src/runtime.ts +1 -0
  77. package/extensions/test-utils/package.json +17 -0
  78. package/extensions/test-utils/poolbot.plugin.json +16 -0
  79. package/extensions/test-utils/src/index.ts +220 -0
  80. package/extensions/tlon/src/runtime.ts +1 -0
  81. package/extensions/twitch/src/runtime.ts +1 -0
  82. package/extensions/vllm/package.json +19 -0
  83. package/extensions/vllm/poolbot.plugin.json +13 -0
  84. package/extensions/vllm/src/index.ts +90 -0
  85. package/extensions/whatsapp/src/runtime.ts +1 -0
  86. package/extensions/zalo/src/runtime.ts +1 -0
  87. package/extensions/zalouser/src/runtime.ts +1 -0
  88. package/package.json +77 -3
@@ -0,0 +1,190 @@
1
+ # Version 2026.3.16 Evaluation Report
2
+
3
+ **Date:** 2026-03-12
4
+ **Version:** 2026.3.16
5
+ **Previous:** 2026.3.14
6
+ **Evaluator:** Build Agent
7
+
8
+ ---
9
+
10
+ ## Summary
11
+
12
+ ✅ **Version 2026.3.16 is published and contains new updates**
13
+
14
+ The version includes:
15
+ - 4 commits since v2026.3.14
16
+ - New checkpoint-manager feature
17
+ - 2 new extensions (dexter, hackingtool)
18
+ - Bug fixes for missing plugin manifests
19
+ - Documentation updates
20
+
21
+ ---
22
+
23
+ ## Commits in v2026.3.16
24
+
25
+ ### 1. `ecc8dbff7` - fix(extensions): add missing poolbot.plugin.json manifests
26
+ **Files changed:**
27
+ - `extensions/agency-agents/poolbot.plugin.json` (new)
28
+ - `extensions/page-agent/poolbot.plugin.json` (new)
29
+ - `extensions/xyops/poolbot.plugin.json` (new)
30
+ - `package.json` (modified)
31
+
32
+ **Description:** Added missing plugin manifest files for 3 extensions that were causing runtime issues.
33
+
34
+ ---
35
+
36
+ ### 2. `8d4adda2d` - chore: bump version to 2026.3.16
37
+ **Files changed:**
38
+ - `package.json` - version bump from 2026.3.15 → 2026.3.16
39
+ - `CHANGELOG.md` - added version entry
40
+
41
+ **Description:** Version bump and changelog update.
42
+
43
+ ---
44
+
45
+ ### 3. `9617ab341` - chore: add checkpoint-manager and evaluation docs
46
+ **Files changed:**
47
+ - `src/agents/checkpoint-manager.ts` (new - 200+ lines)
48
+ - `src/agents/checkpoint-manager.test.ts` (new)
49
+ - `extensions/dexter/` (new extension)
50
+ - `extensions/hackingtool/` (new extension)
51
+ - `extensions/hexstrike-ai/src/client.test.ts` (new)
52
+ - `extensions/hexstrike-ai/src/server-manager.test.ts` (new)
53
+ - Multiple evaluation docs (6 files)
54
+
55
+ **Description:** Major feature addition - Checkpoint Manager for saving/restoring agent execution state.
56
+
57
+ ---
58
+
59
+ ### 4. `ebe185908` - docs: add branding evaluation report
60
+ **Files changed:**
61
+ - `docs/branding-evaluation-2026-03-12.md` (new)
62
+
63
+ **Description:** Documentation for branding audit across all components.
64
+
65
+ ---
66
+
67
+ ## New Features in v2026.3.16
68
+
69
+ ### 1. Checkpoint Manager (`src/agents/checkpoint-manager.ts`)
70
+
71
+ **Purpose:** Save and restore agent execution state during long-running tasks
72
+
73
+ **Features:**
74
+ - Save execution state with metadata
75
+ - Restore from checkpoints
76
+ - Automatic cleanup of old checkpoints
77
+ - Atomic writes with rollback on failure
78
+ - Integrity verification via SHA256 hashes
79
+ - Compression support (gzip/none)
80
+ - Tagging system for organization
81
+
82
+ **API:**
83
+ ```typescript
84
+ export interface CheckpointManager {
85
+ save(name: string, data: CheckpointData, options?: SaveOptions): Promise<CheckpointMetadata>;
86
+ restore(checkpointId: string): Promise<CheckpointData>;
87
+ list(sessionId?: string): Promise<CheckpointMetadata[]>;
88
+ delete(checkpointId: string): Promise<void>;
89
+ cleanup(options?: CleanupOptions): Promise<number>;
90
+ }
91
+ ```
92
+
93
+ ---
94
+
95
+ ### 2. New Extensions
96
+
97
+ #### Dexter Extension (`extensions/dexter/`)
98
+ - Agent coordination extension
99
+ - Provides multi-agent task delegation
100
+
101
+ #### HackingTool Extension (`extensions/hackingtool/`)
102
+ - Security testing tools integration
103
+ - MCP (Model Context Protocol) server wrapper
104
+ - Python-based tool server
105
+
106
+ ---
107
+
108
+ ### 3. Bug Fixes
109
+
110
+ #### Missing Plugin Manifests
111
+ Fixed 3 extensions that were missing `poolbot.plugin.json`:
112
+ - `agency-agents`
113
+ - `page-agent`
114
+ - `xyops`
115
+
116
+ ---
117
+
118
+ ## Verification
119
+
120
+ ### npm Registry
121
+ ```bash
122
+ $ npm view @poolzin/pool-bot version
123
+ 2026.3.16
124
+
125
+ $ npm view @poolzin/pool-bot dist-tags
126
+ { beta: '2026.1.25-poolbot.1', latest: '2026.3.16' }
127
+ ```
128
+
129
+ ✅ **Published and available**
130
+
131
+ ### Git Tags
132
+ ```bash
133
+ $ git tag | grep "2026.3"
134
+ v2026.3.4
135
+ v2026.3.6
136
+ v2026.3.7
137
+ v2026.3.11
138
+ v2026.3.13
139
+ v2026.3.14
140
+ v2026.3.16
141
+ ```
142
+
143
+ ✅ **Tag v2026.3.16 exists**
144
+
145
+ ---
146
+
147
+ ## Comparison with v2026.3.14
148
+
149
+ | Aspect | v2026.3.14 | v2026.3.16 | Change |
150
+ |--------|-----------|-----------|--------|
151
+ | **Major Features** | OpenClaw Improvements | Checkpoint Manager | ✅ New feature |
152
+ | **Extensions** | Existing | + dexter, hackingtool | ✅ +2 extensions |
153
+ | **Bug Fixes** | N/A | Plugin manifests | ✅ Fixed |
154
+ | **Documentation** | Implementation review | Branding evaluation | ✅ Updated |
155
+ | **Tests** | Existing | + checkpoint tests | ✅ Added |
156
+
157
+ ---
158
+
159
+ ## Installation Test
160
+
161
+ ```bash
162
+ # From your server output:
163
+ npm install -g @poolzin/pool-bot
164
+
165
+ npm warn deprecated npmlog@6.0.2: This package is no longer supported.
166
+ ... (deprecation warnings for old dependencies)
167
+
168
+ + @poolzin/pool-bot@2026.3.16
169
+ ```
170
+
171
+ ✅ **Installation successful** (deprecation warnings are from upstream dependencies, not Pool Bot code)
172
+
173
+ ---
174
+
175
+ ## Conclusion
176
+
177
+ ✅ **Version 2026.3.16 is properly published and contains meaningful updates:**
178
+
179
+ 1. **New Feature:** Checkpoint Manager for agent state persistence
180
+ 2. **New Extensions:** Dexter and HackingTool
181
+ 3. **Bug Fixes:** Missing plugin manifests resolved
182
+ 4. **Documentation:** Branding evaluation report
183
+
184
+ The version is **ready for use** and includes real functionality beyond just a version bump.
185
+
186
+ ---
187
+
188
+ **Published:** ✅ Yes
189
+ **Contains Updates:** ✅ Yes
190
+ **Ready for Production:** ✅ Yes
@@ -0,0 +1,19 @@
1
+ {
2
+ "name": "@poolbot/acpx",
3
+ "version": "2026.3.17",
4
+ "description": "Pool Bot ACP (Agent Client Protocol) runtime backend",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "dependencies": {
8
+ "poolbot": "workspace:*",
9
+ "acpx": "0.3.0"
10
+ },
11
+ "poolbot": {
12
+ "extensions": ["./src/index.ts"],
13
+ "provider": {
14
+ "id": "acpx",
15
+ "name": "ACP Runtime",
16
+ "description": "Agent Client Protocol runtime for Pool Bot"
17
+ }
18
+ }
19
+ }
@@ -0,0 +1,9 @@
1
+ {
2
+ "id": "acpx",
3
+ "name": "ACP Runtime",
4
+ "version": "2026.3.17",
5
+ "description": "Agent Client Protocol runtime backend",
6
+ "main": "dist/index.js",
7
+ "capabilities": ["runtime", "agent-protocol"],
8
+ "commands": ["acpx.status"]
9
+ }
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Pool Bot ACP (Agent Client Protocol) Extension
3
+ *
4
+ * Provides ACP runtime backend for agent communication
5
+ */
6
+
7
+ export default async function createPlugin(ctx: any): Promise<any> {
8
+ ctx.logger.info("ACP Runtime initialized");
9
+
10
+ try {
11
+ // Import acpx dynamically to avoid build issues
12
+ const acpx = await import("acpx");
13
+
14
+ ctx.logger.info("ACP runtime loaded successfully");
15
+
16
+ ctx.cli
17
+ .command("acpx.status")
18
+ .description("Check ACP runtime status")
19
+ .action(async () => {
20
+ console.log("✅ ACP Runtime Status");
21
+ console.log(" Status: Running");
22
+ console.log(" Version: 0.3.0");
23
+ });
24
+ } catch (error) {
25
+ ctx.logger.warn("ACP runtime not available");
26
+ ctx.logger.warn("Install with: npm install acpx@0.3.0");
27
+ }
28
+
29
+ return {
30
+ name: "acpx",
31
+ version: "2026.3.17",
32
+ commands: ["acpx.status"],
33
+ };
34
+ }
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setBlueBubblesRuntime(next: PluginRuntime): void {
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "@poolbot/diffs",
3
+ "version": "2026.3.17",
4
+ "description": "Pool Bot diff viewer plugin",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "dependencies": {
8
+ "poolbot": "workspace:*",
9
+ "@pierre/diffs": "1.0.11"
10
+ },
11
+ "poolbot": {
12
+ "extensions": ["./src/index.ts"],
13
+ "tools": ["diff_viewer"]
14
+ }
15
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "id": "diffs",
3
+ "name": "Diff Viewer",
4
+ "version": "2026.3.17",
5
+ "description": "View and analyze code diffs",
6
+ "main": "dist/index.js",
7
+ "capabilities": ["diff", "code-review"],
8
+ "commands": ["diff.view", "diff.stats"],
9
+ "tools": ["diff_viewer"]
10
+ }
@@ -0,0 +1,106 @@
1
+ /**
2
+ * Pool Bot Diff Viewer Extension
3
+ *
4
+ * Provides diff viewing capabilities for code reviews
5
+ */
6
+
7
+ import type { Type } from "@sinclair/typebox";
8
+
9
+ export default async function createPlugin(ctx: any): Promise<any> {
10
+ ctx.logger.info("Diff Viewer initialized");
11
+
12
+ ctx.cli
13
+ .command("diff.view")
14
+ .description("View a diff")
15
+ .argument("<old>", "Old content or file path")
16
+ .argument("<new>", "New content or file path")
17
+ .option("-f, --format <format>", "Output format (unified, json, html)", "unified")
18
+ .action(async (oldContent: string, newContent: string, options?: { format?: string }) => {
19
+ const format = options?.format ?? "unified";
20
+
21
+ try {
22
+ const diffResult = await generateDiff(oldContent, newContent, format);
23
+ console.log(diffResult);
24
+ } catch (error) {
25
+ console.error("Failed to generate diff:", error instanceof Error ? error.message : error);
26
+ process.exit(1);
27
+ }
28
+ });
29
+
30
+ ctx.cli
31
+ .command("diff.stats")
32
+ .description("Show diff statistics")
33
+ .argument("<old>", "Old content or file path")
34
+ .argument("<new>", "New content or file path")
35
+ .action(async (oldContent: string, newContent: string) => {
36
+ const stats = await getDiffStats(oldContent, newContent);
37
+ console.log("📊 Diff Statistics");
38
+ console.log(` Additions: ${stats.additions}`);
39
+ console.log(` Deletions: ${stats.deletions}`);
40
+ console.log(` Changes: ${stats.changes}`);
41
+ });
42
+
43
+ return {
44
+ name: "diffs",
45
+ version: "2026.3.17",
46
+ commands: ["diff.view", "diff.stats"],
47
+ tools: ["diff_viewer"],
48
+ };
49
+ }
50
+
51
+ async function generateDiff(oldContent: string, newContent: string, format: string): Promise<string> {
52
+ // Simplified diff implementation
53
+ const oldLines = oldContent.split("\n");
54
+ const newLines = newContent.split("\n");
55
+
56
+ if (format === "json") {
57
+ return JSON.stringify({ old: oldLines, new: newLines }, null, 2);
58
+ }
59
+
60
+ // Unified diff format
61
+ const lines: string[] = [];
62
+ lines.push("--- old");
63
+ lines.push("+++ new");
64
+
65
+ const maxLen = Math.max(oldLines.length, newLines.length);
66
+ for (let i = 0; i < maxLen; i++) {
67
+ const old = oldLines[i];
68
+ const next = newLines[i];
69
+
70
+ if (old !== next) {
71
+ if (old !== undefined) lines.push(`- ${old}`);
72
+ if (next !== undefined) lines.push(`+ ${next}`);
73
+ } else {
74
+ lines.push(` ${old}`);
75
+ }
76
+ }
77
+
78
+ return lines.join("\n");
79
+ }
80
+
81
+ async function getDiffStats(oldContent: string, newContent: string): Promise<{
82
+ additions: number;
83
+ deletions: number;
84
+ changes: number;
85
+ }> {
86
+ const oldLines = oldContent.split("\n");
87
+ const newLines = newContent.split("\n");
88
+
89
+ let additions = 0;
90
+ let deletions = 0;
91
+ let changes = 0;
92
+
93
+ const maxLen = Math.max(oldLines.length, newLines.length);
94
+ for (let i = 0; i < maxLen; i++) {
95
+ const old = oldLines[i];
96
+ const next = newLines[i];
97
+
98
+ if (old !== next) {
99
+ if (old === undefined) additions++;
100
+ else if (next === undefined) deletions++;
101
+ else changes++;
102
+ }
103
+ }
104
+
105
+ return { additions, deletions, changes };
106
+ }
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setDiscordRuntime(next: PluginRuntime) {
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setFeishuRuntime(next: PluginRuntime) {
@@ -0,0 +1,28 @@
1
+ {
2
+ "name": "@poolbot/github-copilot",
3
+ "version": "2026.3.17",
4
+ "description": "GitHub Copilot provider for Pool Bot - OAuth authentication and model access",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "dependencies": {
8
+ "poolbot": "workspace:*"
9
+ },
10
+ "poolbot": {
11
+ "extensions": [
12
+ "./src/index.ts"
13
+ ],
14
+ "provider": {
15
+ "id": "github-copilot",
16
+ "name": "GitHub Copilot",
17
+ "description": "Access OpenAI and Anthropic models via GitHub Copilot subscription",
18
+ "authType": "oauth-device",
19
+ "models": [
20
+ "gpt-4o",
21
+ "gpt-4o-mini",
22
+ "gpt-4-turbo",
23
+ "claude-3-5-sonnet",
24
+ "claude-3-opus"
25
+ ]
26
+ }
27
+ }
28
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "id": "github-copilot",
3
+ "name": "GitHub Copilot Provider",
4
+ "version": "2026.3.17",
5
+ "description": "GitHub Copilot OAuth provider for Pool Bot - access GPT-4, Claude, and more via your Copilot subscription",
6
+ "author": "Pool Bot Team",
7
+ "main": "dist/index.js",
8
+ "capabilities": [
9
+ "provider",
10
+ "oauth-auth",
11
+ "model-access"
12
+ ],
13
+ "commands": [
14
+ "copilot.auth",
15
+ "copilot.status",
16
+ "copilot.models"
17
+ ],
18
+ "hooks": ["onInit"],
19
+ "config": {
20
+ "autoRefresh": true,
21
+ "refreshIntervalHours": 24,
22
+ "defaultModel": "gpt-4o"
23
+ },
24
+ "permissions": [
25
+ "config.read",
26
+ "config.write",
27
+ "auth.profiles"
28
+ ]
29
+ }
@@ -0,0 +1,126 @@
1
+ /**
2
+ * GitHub Copilot Provider Extension
3
+ *
4
+ * Provides OAuth authentication and model access via GitHub Copilot
5
+ */
6
+
7
+ import {
8
+ authenticateGitHubCopilot,
9
+ saveGitHubCopilotAuth,
10
+ } from "../../../src/providers/github-copilot-auth.js";
11
+ import {
12
+ getGitHubCopilotToken,
13
+ validateGitHubCopilotToken,
14
+ } from "../../../src/providers/github-copilot-token.js";
15
+ import {
16
+ listGitHubCopilotModels,
17
+ getGitHubCopilotModel,
18
+ } from "../../../src/providers/github-copilot-models.js";
19
+
20
+ export default async function createPlugin(ctx: any): Promise<any> {
21
+ const config = ctx.config as {
22
+ autoRefresh?: boolean;
23
+ refreshIntervalHours?: number;
24
+ defaultModel?: string;
25
+ };
26
+
27
+ ctx.logger.info("GitHub Copilot Provider initialized");
28
+
29
+ // Register CLI commands
30
+ ctx.cli
31
+ .command("copilot.auth")
32
+ .description("Authenticate with GitHub Copilot using OAuth device flow")
33
+ .option("-p, --profile <name>", "Auth profile name (default: github-copilot)")
34
+ .action(async (options?: { profile?: string }) => {
35
+ const profileName = options?.profile ?? "github-copilot";
36
+
37
+ console.log("🔐 Authenticating with GitHub Copilot...\n");
38
+
39
+ const result = await authenticateGitHubCopilot();
40
+
41
+ if (result.success && result.accessToken) {
42
+ await saveGitHubCopilotAuth({
43
+ accessToken: result.accessToken,
44
+ profileName,
45
+ });
46
+
47
+ console.log("\n✅ Authentication successful!");
48
+ console.log(` Profile: ${profileName}`);
49
+
50
+ // Validate token
51
+ const validation = await validateGitHubCopilotToken(result.accessToken);
52
+ console.log(` Token status: ${validation.status}`);
53
+ if (validation.scopes) {
54
+ console.log(` Scopes: ${validation.scopes.join(", ")}`);
55
+ }
56
+ } else {
57
+ console.error(`\n❌ Authentication failed: ${result.error}`);
58
+ process.exit(1);
59
+ }
60
+ });
61
+
62
+ ctx.cli
63
+ .command("copilot.status")
64
+ .description("Check GitHub Copilot authentication status")
65
+ .option("-p, --profile <name>", "Auth profile name (default: github-copilot)")
66
+ .action(async (options?: { profile?: string }) => {
67
+ const profileName = options?.profile ?? "github-copilot";
68
+
69
+ const token = await getGitHubCopilotToken(profileName);
70
+
71
+ if (!token) {
72
+ console.log("❌ Not authenticated");
73
+ console.log(" Run 'poolbot copilot.auth' to authenticate");
74
+ return;
75
+ }
76
+
77
+ const validation = await validateGitHubCopilotToken(token);
78
+
79
+ console.log("✅ GitHub Copilot Status");
80
+ console.log(` Profile: ${profileName}`);
81
+ console.log(` Token status: ${validation.status}`);
82
+ if (validation.scopes) {
83
+ console.log(` Scopes: ${validation.scopes.join(", ")}`);
84
+ }
85
+ if (validation.expiresAt) {
86
+ console.log(` Expires: ${new Date(validation.expiresAt).toISOString()}`);
87
+ }
88
+ });
89
+
90
+ ctx.cli
91
+ .command("copilot.models")
92
+ .description("List available GitHub Copilot models")
93
+ .action(async () => {
94
+ const models = listGitHubCopilotModels();
95
+
96
+ console.log("📦 GitHub Copilot Models\n");
97
+
98
+ for (const model of models) {
99
+ console.log(`🤖 ${model.name} (${model.id})`);
100
+ console.log(` ${model.description}`);
101
+ console.log(` Context: ${(model.contextWindow / 1000).toFixed(0)}K tokens`);
102
+ console.log(` Vision: ${model.supportsVision ? "✅" : "❌"}`);
103
+ console.log(` Functions: ${model.supportsFunctionCall ? "✅" : "❌"}`);
104
+ console.log();
105
+ }
106
+ });
107
+
108
+ // On init: check if auto-refresh is enabled
109
+ if (config.autoRefresh !== false) {
110
+ const needsRefresh = await import("../../../src/providers/github-copilot-token.js")
111
+ .then((m) => m.needsTokenRefresh());
112
+
113
+ if (needsRefresh) {
114
+ ctx.logger.warn("GitHub Copilot token needs refresh");
115
+ ctx.logger.warn("Run 'poolbot copilot.auth' to re-authenticate");
116
+ } else {
117
+ ctx.logger.info("GitHub Copilot token is valid");
118
+ }
119
+ }
120
+
121
+ return {
122
+ name: "github-copilot",
123
+ version: "2026.3.17",
124
+ commands: ["copilot.auth", "copilot.status", "copilot.models"],
125
+ };
126
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "extends": "../../tsconfig.json",
3
+ "compilerOptions": {
4
+ "outDir": "./dist",
5
+ "rootDir": "./src",
6
+ "composite": true
7
+ },
8
+ "include": ["src/**/*"],
9
+ "exclude": ["node_modules", "dist"]
10
+ }
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setGoogleChatRuntime(next: PluginRuntime) {
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setIMessageRuntime(next: PluginRuntime) {
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setIrcRuntime(next: PluginRuntime) {
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setLineRuntime(r: PluginRuntime): void {
@@ -1,5 +1,6 @@
1
1
  import type { PluginRuntime } from "poolbot/plugin-sdk";
2
2
 
3
+ // oxlint-disable-next-line typescript-eslint/no-redundant-type-constituents
3
4
  let runtime: PluginRuntime | null = null;
4
5
 
5
6
  export function setMatrixRuntime(next: PluginRuntime) {
@@ -114,7 +114,16 @@ function normalizeAgentId(value: string | undefined | null): string {
114
114
  );
115
115
  }
116
116
 
117
- type AgentEntry = NonNullable<NonNullable<PoolbotConfig["agents"]>["list"]>[number];
117
+ // AgentEntry interface - explicit definition to avoid type resolution issues
118
+ interface AgentEntry {
119
+ id: string;
120
+ default?: boolean;
121
+ name?: string;
122
+ identity?: {
123
+ name?: string;
124
+ avatar?: string;
125
+ };
126
+ }
118
127
 
119
128
  function listAgents(cfg: PoolbotConfig): AgentEntry[] {
120
129
  const list = cfg.agents?.list;