"""MCP Prompts — server-curated playbooks, surfaced in every client. Prompts are the multi-client counterpart of the Claude Code plugin's slash commands: claude.ai connector users, Claude Desktop users and any MCP client that renders prompt templates get the same official flows, maintained in one place. Each prompt returns instructions the model follows with the user's own permissions — they add no authority. Kept to the flows employees actually repeat; a prompt per tool would just be the tool list again. """ from __future__ import annotations from app.mcp.server import mcp_server @mcp_server.prompt( name="it_overview", title="我的 IT 全景 / My IT overview", description="One readable overview of devices, seats, accounts, pending items and expiring resources.", ) def it_overview() -> str: return ( "Build a single readable overview of my IT estate from Helix:\n" "1. get_my_loadout — devices, software seats, accounts.\n" "2. get_my_notifications_summary — unread actionable count.\n" "3. list_my_expiring_resources — anything expiring soon.\n" "Present as short sections (设备/软件席位/账号/待办与到期), highlight " "items needing action, offer natural next steps, and answer in my language." ) @mcp_server.prompt( name="approvals_review", title="审批一览 / Review my approvals", description="What I submitted (with stuck-stage detail) and what awaits my decision.", ) def approvals_review() -> str: return ( "Show my Helix approvals in two views:\n" "1. Submitted by me: list_my_approval_requests grouped by status; for " "pending ones show age and current stage (list_approval_flow_stages " "when something looks stuck).\n" "2. Waiting for me (if my role allows): admin_approval_overview, " "list_my_pending_api_key_apply_approvals, list_my_pending_access_reviews.\n" "Present each pending decision with requester + item + age. Never " "decide anything without my explicit per-item instruction." ) @mcp_server.prompt( name="cost_review", title="成本体检 / My cost review", description="My attributed IT cost with drill-downs and anomalies worth attention.", ) def cost_review() -> str: return ( "Run my IT cost review from Helix:\n" "1. finance_my_attributed_cost — headline + composition.\n" "2. get_api_key_spend if I hold AI API keys.\n" "3. If I manage a team: cost_subordinates_breakdown.\n" "4. cost_anomalies — anything unusual lately.\n" "Quote currencies exactly as returned, note the ~1-2 day provider lag, " "and only offer cost_breakdown/cost_timeseries drill-downs on request." ) @mcp_server.prompt( name="offboarding_handover", title="离职交接清单 / Offboarding handover check", description="Everything Helix will transfer/return/revoke for a departure, as an actionable checklist.", ) def offboarding_handover() -> str: return ( "Help me understand my offboarding footprint in Helix:\n" "1. get_offboarding_preview — the concrete transfer/return/revoke plan.\n" "2. Cross-check owned resources that deserve early handover: " "list_my_domain_registrations, list_my_ai_tool_applications, " "list_my_email_groups (owner), list_my_api_keys.\n" "Present as a checklist with the matching handover tools " "(handover_domain_registration, handover_ai_tool_application, " "transfer_email_group_owner …). Be factual and calm; a preview is NOT " "a filed resignation and I decide every handover explicitly." ) @mcp_server.prompt( name="onboarding_progress", title="入职进度 / My onboarding progress", description="Where my accounts and checklist stand, and what needs my confirmation.", ) def onboarding_progress() -> str: return ( "Walk me through my onboarding state in Helix:\n" "1. get_my_onboarding_status / get_my_onboarding_progress — accounts " "created, pending items, expected dates.\n" "2. Items awaiting my explicit confirmation → acknowledge_onboarding_item " "(ask me one by one).\n" "3. get_my_welcome / get_my_cohort for orientation context.\n" "Answer in my language and keep it to what actually needs me." )