Skip to content

MCP Provider ​

Feature Overview ​

PPP exposes its data (CPD, Logbook, Profile, Appraisals, Wellness — scoped to the authenticated doctor) as a Model Context Protocol (MCP) provider. Doctors connect their own AI agents (Claude, OpenAI, Gemini) and query their portfolio without using the PPP UI — supporting the "manage records on your own device" goal.

Open Questions ​

#QuestionProposed answer / statusRef
Q1OAuth scopes — what's the minimum read-only set; what can be written (CPD entry, reflection)?Confirmed (transcript 2026-05-20 ~00:43:23): Exposing platform as MCP provider is confirmed. Matt agreed immediately. Scope/rate-limit/token details still TBD — see remaining rows below. Engineering proposal: v1 read-only across CPD / Logbook / Profile; CPD-entry write in v2 after audit.Transcript 2026-05-20 §00:43:23
Q2Rate limiting and abuse — per-doctor request budget?Engineering proposal: 100 req/min, 5000/day per token.Engineering-raised
Q3Admin exposure — do admin tiers get their own MCP scope for cohort queries?Engineering proposal: no (v1) — admin queries go via dashboard; revisit if Matt asks.Engineering-raised
Q4Token lifecycle — fixed expiry vs refresh-token?Engineering proposal: 90-day expiry, doctor-revocable from profile settings.Engineering-raised
Closed Questions (0) — click to expand
#QuestionResolutionRef
Matt's Requirements (from Notion brief) ​

Source: transcript only — no Notion page yet authored.

Purpose ​

  • Expose PPP as a Model Context Protocol (MCP) provider so doctors interact with their CPD / portfolio data via Claude, OpenAI or Gemini — without using the PPP UI.†
  • Aligns with the goal of doctors managing records on their own devices.†

Surface (v1) ​

  • Read tools for: CPD activities, Surgical Logbook entries, Profile (registrations, hospitals, qualifications), Wellness self-reports.
  • Write tools (v1 minimum): the doctor's AI must be able to "grab this email from my inbox and update my CPD" and "ask for a report for my appraisal" — i.e. ingest-from-inbox into CPD and request-report flows.†
  • Demo priority: explicitly de-prioritised vs the 28-May demo — ship after demo if scope tightens.†

Acceptance Criteria ​

Core — MCP server ​

  • ⏳ PPP exposes an MCP server at a public endpoint (e.g. mcp.professionalperformanceportfolio.com).†
  • ⏳ Server implements the published MCP spec (stdio + HTTP transports).
  • ⏳ Discovery endpoint lists available tools and resources for an authenticated doctor.

Authentication ​

  • ⏳ Doctor generates a personal-access MCP token from Profile → Integrations.
  • ⏳ Token is HMAC-SHA256 signed; carries the doctor's userId + scope claims.
  • ⏳ Token expiry default 90 days, doctor-revocable any time (Q4).
  • ⏳ Token never exposes admin/cohort data — only the issuing doctor's records.

v1 read tools ​

  • ⏳ list_cpd_activities(year?, category?) — returns CPD activities for the doctor.
  • ⏳ get_cpd_compliance_summary() — returns annual progress (hours, categories, AMC requirements).
  • ⏳ list_logbook_entries(date_from?, date_to?, procedure?) — returns surgical logbook entries.
  • ⏳ get_profile() — returns Profile (registrations, hospitals, qualifications).
  • ⏳ list_wellness_responses(date_from?) — returns doctor's own PPP Pulse / WHO-5 responses.

v1 write tools ​

  • ⏳ add_cpd_activity(activity) — create a CPD activity from a parsed email / external source.†
  • ⏳ request_appraisal_report(timeframe) — async generation of an appraisal PDF, returned as a download URL.†
  • ⏳ Write tools require step-up confirmation (signed callback) so an AI cannot mutate state without doctor acknowledgement.
  • ⏳ Every write tool invocation appears in the doctor's own activity history with the source-AI identifier captured.

Rate limiting ​

  • ⏳ 100 req/min, 5000/day per token (Q2). 429 on overage.
  • ⏳ Server emits structured rate-limit headers.

Audit & telemetry ​

  • ⏳ Every MCP tool invocation is audit-logged (token id, tool name, timestamp, response size).
  • ⏳ Doctor can view their own MCP access log from Profile → Integrations.
  • ⏳ Anomalous access (e.g. 10× normal volume) triggers a security email to the doctor.

Documentation ​

  • ⏳ Public docs page lists available tools + example payloads + how to wire to Claude/Codex.
  • ⏳ Docs include a one-paragraph data-policy summary (read-only, doctor-scoped).
Current Status ​
Sub-featureStatusNotes
MCP server scaffold❌ Not started
Token issuance + revocation❌ Not started
v1 read tools❌ Not started
Rate limiting❌ Not started
Audit log + doctor-visible access UI❌ Not started
Public docs page❌ Not started

Open issues on label:feature:mcp-provider — no open issues. Fetched at: 2026-10-13T07:29:49Z — live list on GitHub.

Downstream References ​
FeatureLinkage
Profile (Doctor)Source of profile data
CPDRead tools surface CPD activities + compliance summary
LogbookRead tools surface logbook entries
WellnessRead tools surface PPP Pulse responses
API LicensingSibling spec — paid B2B API; MCP is doctor-personal
Change Log ​
DateChangePR/IssueReason
2026-07-13BDD scenario coverage intentionally deferred — spec is status: specified (not yet built). No @feature:mcp-provider scenarios needed yet.#10578, #10572Coverage/BDD gap audit (#10572) flagged this spec as having zero BDD tag match. Confirmed specified-but-unbuilt per front-matter status:; BDD is written when the feature is built, not at the specification stage. This note stops future coverage sweeps from re-flagging the gap.
2026-05-20New spec — expose PPP as Model Context Protocol (MCP) provider; doctor-scoped read tools for CPD, Logbook, Profile, Wellness; doctor-issued tokens.#0Matt's 2026-05-20 Dev Session ratified exposing PPP as an MCP provider so doctors can interact with their portfolio via Claude/OpenAI/Gemini without using the UI.

Internal documentation — org members only