HTTP-transport MCP server for macOS that allows AI agents to request keep-awake assertions via the keep_awake tool. Bound to 127.0.0.1 with Bearer-token authentication. Implements JSON-RPC methods: initialize, tools/list, tools/call, and ping.
Three tools with complete input schemas and descriptions, but descriptions are brief (10-20 chars baseline) and lack LLM-optimized guidance. Naming is clear and verb-based (keep_awake, release_awake, status). Parameters are well-typed with descriptions. No output schema documentation visible. Error handling and recovery guidance absent. Composition is sound, each tool has one responsibility. Security: Bearer token auth present; no secrets in parameters.
Request the system to stay awake for a specified duration or indefinitely. Returns a session ID and optional expiration time.
Release a keep-awake session by session ID, or release all MCP-driven sessions if no session ID is provided.
Query the current keep-awake status, including whether the system is being kept awake, when it will stop, and what sources are driving the force-active state.
Output schemas not documented. LLMs cannot infer what fields to expect from keep_awake (sessionId, expiresAt?) or status (keepingAwake, activeUntil, forceActiveSources). Breaks downstream tool chaining and forces guessing.
Descriptions are too brief (10 - 20 chars). 'Request the system to stay awake...' lacks WHEN to use, prerequisites, or side effects. LLMs need 50 - 200 char descriptions to select tools confidently. Current descriptions waste the opportunity to guide agent behavior.
No error handling or recovery guidance. If keep_awake fails (e.g., IOPMAssertion denied), the response should guide the LLM: 'Permission denied. Ensure the app has system power management entitlements.' Current code returns generic HTTP errors.
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | C | 61 | <=2025-11-25 | v2 |
Parameter 'reason' defaults to 'MCP client request' but this default is not declared in the schema. Schema shows no 'default' field. LLMs cannot infer optional behavior without explicit schema defaults.
No idempotency or confirmation pattern for destructive operations. release_awake with no session_id releases ALL MCP sessions, a dangerous default. Should require explicit confirmation or a separate 'release_all_awake' tool.