agent-afk 5.254.3 → 5.254.4

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 CHANGED
@@ -30,6 +30,8 @@ afk chat "hello" # first real conversation
30
30
 
31
31
  That's it. You're in.
32
32
 
33
+ **Using pnpm?** `pnpm add -g agent-afk` works, but pnpm 10 blocks build scripts by default and silently skips `postinstall` (see [#2199](https://github.com/griffinwork40/agent-afk/issues/2199)). Run `pnpm approve-builds -g` after install to approve the hook, or use `npm install -g agent-afk` instead. If a launchd/systemd-supervised `afk daemon` is already running and pnpm skipped the hook, restart it manually with `afk service restart daemon`.
34
+
33
35
  **Try without installing:** `npx agent-afk chat "hello"` runs a one-shot turn with zero global install.
34
36
 
35
37
  **Already using Claude Code or Codex?** `afk login` will detect your existing credentials automatically. Run `afk migrate` to import your plugins, skills, and MCP servers too -- it live-reads the source tool's dirs, so anything you install there keeps showing up in AFK with no re-run.
@@ -22,7 +22,7 @@ export declare class McpClient {
22
22
  onToolListChanged?: () => void;
23
23
  constructor(serverName: string, config: McpServerConfig, layer?: McpServerLayer, trustedAllowSecretEnv?: readonly string[]);
24
24
  connect(): Promise<McpClientConnectResult>;
25
- listTools(): Promise<McpTool[]>;
25
+ listTools(signal?: AbortSignal): Promise<McpTool[]>;
26
26
  refreshTools(): Promise<McpTool[]>;
27
27
  callTool(toolName: string, input: unknown, signal: AbortSignal): Promise<ToolResult>;
28
28
  finishAuth(authorizationCode: string): Promise<void>;
@@ -0,0 +1,13 @@
1
+ export interface McpHealthCheckResult {
2
+ serverName: string;
3
+ healthy: boolean;
4
+ error?: string;
5
+ durationMs: number;
6
+ }
7
+ export interface HealthCheckTarget {
8
+ serverName: string;
9
+ listTools(signal?: AbortSignal): Promise<unknown[]>;
10
+ }
11
+ export declare function runMcpHealthChecks(targets: readonly HealthCheckTarget[], timeoutMs?: number): Promise<McpHealthCheckResult[]>;
12
+ export declare function warnUnhealthyServers(results: readonly McpHealthCheckResult[]): void;
13
+ export declare function isMcpHealthCheckEnabled(): boolean;