// src/acp-extensions.ts
var POSTHOG_NOTIFICATIONS = {
  /** Git branch was created for a task */
  BRANCH_CREATED: "_posthog/branch_created",
  /** Task run has started execution */
  RUN_STARTED: "_posthog/run_started",
  /** Task has completed (success or failure) */
  TASK_COMPLETE: "_posthog/task_complete",
  /** Agent finished processing a turn (prompt returned, waiting for next input) */
  TURN_COMPLETE: "_posthog/turn_complete",
  /** Error occurred during task execution */
  ERROR: "_posthog/error",
  /** Console/log output from the agent */
  CONSOLE: "_posthog/console",
  /** Maps taskRunId to agent's sessionId and adapter type (for resumption) */
  SDK_SESSION: "_posthog/sdk_session",
  /** Git checkpoint captured for handoff */
  GIT_CHECKPOINT: "_posthog/git_checkpoint",
  /** Agent mode changed (interactive/background) */
  MODE_CHANGE: "_posthog/mode_change",
  /** Request to resume a session from previous state */
  SESSION_RESUME: "_posthog/session/resume",
  /** User message sent from client to agent */
  USER_MESSAGE: "_posthog/user_message",
  /** Request to cancel current operation */
  CANCEL: "_posthog/cancel",
  /** Request to close the session */
  CLOSE: "_posthog/close",
  /** Agent status update (thinking, working, etc.) */
  STATUS: "_posthog/status",
  /** Structured backend progress notification; events in the same turn group into one card on the client */
  PROGRESS: "_posthog/progress",
  /** Task-level notification (progress, milestones) */
  TASK_NOTIFICATION: "_posthog/task_notification",
  /** Marks a boundary for log compaction */
  COMPACT_BOUNDARY: "_posthog/compact_boundary",
  /** Token usage update for a session turn */
  USAGE_UPDATE: "_posthog/usage_update",
  /** Response to a relayed permission request (plan approval, question) */
  PERMISSION_RESPONSE: "_posthog/permission_response"
};
function matchesExt(method, expected) {
  if (!method) return false;
  return method === expected || method === `_${expected}`;
}
function isNotification(method, expected) {
  return matchesExt(method, expected);
}

// src/adapters/claude/mcp/tool-metadata.ts
var mcpToolMetadataCache = /* @__PURE__ */ new Map();
function getMcpToolMetadata(toolName) {
  return mcpToolMetadataCache.get(toolName);
}
function isMcpToolReadOnly(toolName) {
  const metadata = mcpToolMetadataCache.get(toolName);
  return metadata?.readOnly === true;
}
export {
  POSTHOG_NOTIFICATIONS,
  getMcpToolMetadata,
  isMcpToolReadOnly,
  isNotification
};
//# sourceMappingURL=index.js.map