{"openapi":"3.1.0","info":{"title":"Archangel Health Surgical Patient Platform","description":"Personalized surgical education videos generated from EHR data.","version":"0.2.0"},"paths":{"/api/auth/register":{"post":{"summary":"Auth Register","description":"Register a new user; returns access token and user. The account starts\nunverified — the portal handoff is gated until the doctor verifies their\nemail (see /api/auth/verify-email).","operationId":"auth_register_api_auth_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/verify-email":{"post":{"summary":"Auth Verify Email","operationId":"auth_verify_email_api_auth_verify_email_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyEmailCodeBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/verify-email/by-token":{"get":{"summary":"Auth Verify Email By Token","operationId":"auth_verify_email_by_token_api_auth_verify_email_by_token_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/verify-email/resend":{"post":{"summary":"Auth Verify Email Resend","operationId":"auth_verify_email_resend_api_auth_verify_email_resend_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResendVerificationBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/login":{"post":{"summary":"Auth Login","description":"Sign in; returns access token and user.","operationId":"auth_login_api_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/mfa/enroll":{"post":{"summary":"Mfa Enroll","description":"Begin TOTP enrollment: returns the secret + otpauth URI to render a QR.\nNot active until confirmed via /api/auth/mfa/verify.","operationId":"mfa_enroll_api_auth_mfa_enroll_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/mfa/verify":{"post":{"summary":"Mfa Verify Enroll","operationId":"mfa_verify_enroll_api_auth_mfa_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaCodeBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/mfa/disable":{"post":{"summary":"Mfa Disable Endpoint","operationId":"mfa_disable_endpoint_api_auth_mfa_disable_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaCodeBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/mfa/status":{"get":{"summary":"Mfa Status","operationId":"mfa_status_api_auth_mfa_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/mfa/login":{"post":{"summary":"Mfa Login","description":"Second step of login: exchange the mfa_token + TOTP code for an access token.","operationId":"mfa_login_api_auth_mfa_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MfaLoginBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/logout":{"post":{"summary":"Auth Logout","description":"Revoke the presented staff token (landing or tenant) so it can't be reused (PRD-3).","operationId":"auth_logout_api_auth_logout_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/portal-handoff":{"post":{"summary":"Create Portal Handoff","operationId":"create_portal_handoff_api_auth_portal_handoff_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortalHandoffCreateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/portal-handoff/consume":{"post":{"summary":"Consume Portal Handoff","operationId":"consume_portal_handoff_api_auth_portal_handoff_consume_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortalHandoffConsumeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/me":{"get":{"summary":"Auth Me","description":"Return current user from Bearer token.","operationId":"auth_me_api_auth_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}}}},"security":[{"HTTPBearer":[]}]}},"/auth/signout":{"get":{"summary":"Auth Signout","description":"Redirect to landing page with signout=1 so landing can clear auth state.","operationId":"auth_signout_auth_signout_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/doctor/profile":{"get":{"summary":"Doctor Profile","description":"Return current doctor's profile (landing auth) or tenant staff profile.","operationId":"doctor_profile_api_doctor_profile_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DoctorProfileOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/doctor/onboard":{"post":{"summary":"Doctor Onboard","description":"Set doctor profile and generate health system code. Email must match current user.","operationId":"doctor_onboard_api_doctor_onboard_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DoctorOnboard"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DoctorProfileOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/patient/by-codes":{"get":{"summary":"Patient By Codes","description":"Resolve health system (clinic) code + resource_code to patient_id and dashboard URL.","operationId":"patient_by_codes_api_patient_by_codes_get","parameters":[{"name":"clinic_code","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clinic Code"}},{"name":"resource_code","in":"query","required":false,"schema":{"type":"string","default":"","title":"Resource Code"}},{"name":"health_system_code","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Health System Code"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/logout":{"post":{"summary":"Patient Logout","description":"Clear and revoke the current patient session cookie (PRD-1 §10).","operationId":"patient_logout_api_patient_logout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/care-plan":{"get":{"summary":"Patient Code Entry","description":"Self-contained patient code-entry page. Used as the entry point when the\nlanding app isn't configured (LANDING_URL unset) so patient SMS/email links\nalways reach a real code-entry experience instead of a bare dashboard URL.\nOptional ?hs= pre-fills the (non-sensitive) health-system code.","operationId":"patient_code_entry_care_plan_get","parameters":[{"name":"hs","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hs"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/recovery":{"get":{"summary":"Patient Code Entry","description":"Self-contained patient code-entry page. Used as the entry point when the\nlanding app isn't configured (LANDING_URL unset) so patient SMS/email links\nalways reach a real code-entry experience instead of a bare dashboard URL.\nOptional ?hs= pre-fills the (non-sensitive) health-system code.","operationId":"patient_code_entry_recovery_get","parameters":[{"name":"hs","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hs"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/version":{"get":{"summary":"Api Version","description":"Which commit is live, and when did it start?\n\nThis exists because \"I pushed a fix and I am not seeing it\" had no answer\nshort of reading a dashboard: nothing the running process served said what\ncode it was. A deploy that never happened, a deploy that failed back to the\nprevious image, and a real bug in the new code all present identically — as\nthe old behaviour — and the only way to tell them apart was to guess.\n\nDeliberately unauthenticated and deliberately thin: a commit SHA and a start\ntime, which is what a health check and an operator both need. Nothing about\naccounts, data, configuration or the environment goes here.","operationId":"api_version_api_version_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/":{"get":{"summary":"Doctor Portal Entry","description":"Entry point: tenant sign-in first, then /doctor/app for the roster UI.","operationId":"doctor_portal_entry__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/doctor/sign-in":{"get":{"summary":"Doctor Tenant Sign In Page","description":"Health-system tenant login (surgeon / RN); stores JWT in archangel_doctor_auth_token.","operationId":"doctor_tenant_sign_in_page_doctor_sign_in_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/doctor/app":{"get":{"summary":"Doctor Portal App","description":"Main doctor roster / console (after sign-in).","operationId":"doctor_portal_app_doctor_app_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/asclepius":{"get":{"summary":"Asclepius Portal","description":"Asclepius — Expert Evaluation Portal (standalone page, own auth).\n\nThe HTML shell is served unauthenticated by design (like /doctor); the page\nJS gates on an Asclepius token and shows its own login. Reached as its own\ntop-level tab in the doctor portal (embedded via iframe) or directly. Static\nassets load from /static/asclepius/. No PHI.","operationId":"asclepius_portal_asclepius_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/asclepius/env/annotate":{"get":{"summary":"Asclepius Env Annotate Page","description":"Asclepius ENV · Clinical RL Environment — trajectory annotation surface\n(Clinical RL Environments PRD §7). A new content TYPE inside the same\nevaluator portal design system (§7.6), not a new app. Served unauthenticated\nby design (like /asclepius); the page JS gates on the Asclepius token.\nOptional ``?run_id=`` query param opens a specific trajectory; otherwise it\npulls the next unannotated one from the ENV queue. No PHI (de-identified\ncontext only).","operationId":"asclepius_env_annotate_page_asclepius_env_annotate_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/asclepius/admin":{"get":{"summary":"Asclepius Admin Console","description":"Asclepius Operations — the admin console, on its own page (PRD-F R1).\n\nServed unauthenticated exactly like ``/asclepius`` above, and for the same\nreason: the HTML is a static shell with no data in it. The page boots by\ncalling ``/auth/me`` and renders a sign-in gate for a session that is not\nan operator's, but that gate is honesty rather than security. Every admin\nAPI this page calls is gated server-side by ``require_admin``, and none of\nthat moved. Splitting the console out of the physician bundle is bundle\nhygiene and surface clarity; the authorization boundary was and remains the\nserver.\n\nNo signup-url injection: nobody joins Archangel through the console.","operationId":"asclepius_admin_console_asclepius_admin_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/community":{"get":{"summary":"Community Page","description":"Asclepius Community — private colleague workspace for verified\ncontributor physicians (Community PRD §1). The HTML shell is served\nunauthenticated by design (like /asclepius): the page JS presents the\nexisting Asclepius session token and every API/WS call enforces the\nverified-contributor gate server-side. There is no public registration\nroute, no invite link, and no join form — the only way in is a verified\ncontributor account arriving from the doctor portal (PRD §1, §9.3).","operationId":"community_page_community_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/partner/upload":{"get":{"summary":"Partner Upload Page","description":"Data-partner secure upload page (EHR Ingestion PRD §4): a minimal,\nstandalone page (no app shell, no PHI displayed) reached only through a\ntokenized, expiring link. The token is validated server-side on the POST —\nthis shell renders for anyone, uploads only with a valid token.","operationId":"partner_upload_page_partner_upload_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/provider":{"get":{"summary":"Data Provider Portal","description":"Data Provider Portal (EHR PRD §4, email+password door) — a standalone,\nlocked-down page (like /asclepius). Served unauthenticated by design; the page\nJS gates on an Asclepius data_partner token and shows its own login → forced\npassword reset → single upload screen. Static assets load from /static/provider/.","operationId":"data_provider_portal_provider_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/workspace":{"get":{"summary":"Buyer Workspace Portal","description":"Buyer secure data workspace — a standalone, locked-down page (like\n/provider). Served unauthenticated by design; the page JS gates on an\nAsclepius buyer token and shows its own login → forced password reset →\ndeliveries list. Every dataset delivered to the buyer's email appears here.\nStatic assets load from /static/buyer/.","operationId":"buyer_workspace_portal_workspace_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/doctor":{"get":{"summary":"Doctor Portal Legacy Path","description":"Bookmarks to /doctor land on sign-in; dashboard is /doctor/app.","operationId":"doctor_portal_legacy_path_doctor_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/dev":{"get":{"summary":"Dev Login Shortcut","description":"Local-dev one-click sign-in. Gated on EMAIL_DEV_MODE so it never ships\nto prod. Auto-creates the dev doctor on first hit, issues a JWT, drops it\ninto localStorage on the same origin, and redirects to the portal — so\n`python3 -m uvicorn main:app` + opening http://localhost:8000/dev is all\nyou need to see the doctor UI.","operationId":"dev_login_shortcut_dev_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/api/patients":{"get":{"summary":"List Patients","description":"Return all patients in the store for the doctor roster.\n\nExcludes draft patients (``is_draft=True``) — these are work-in-progress\nrecords created during the TEAM eligibility flow and are not yet committed\nto the roster. They are either promoted (on finalize) or hard-deleted (on\ncancel). If a draft is left behind by an interrupted session, it stays\ninvisible until the server restarts.","operationId":"list_patients_api_patients_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/discharge-materials":{"get":{"summary":"Get Discharge Materials","operationId":"get_discharge_materials_api_patient__patient_id__discharge_materials_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/events":{"post":{"summary":"Track Patient Event","operationId":"track_patient_event_api_patient__patient_id__events_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventTrackRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/pcp-referral":{"patch":{"summary":"Update Pcp Referral","operationId":"update_pcp_referral_api_patient__patient_id__pcp_referral_patch","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PCPReferralUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/demo/sign-in-routes":{"get":{"summary":"Demo Sign In Routes","description":"Public email → auth routing hints for landing sign-in (no passwords).","operationId":"demo_sign_in_routes_api_demo_sign_in_routes_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/patient/{patient_id}":{"patch":{"summary":"Update Patient Details","operationId":"update_patient_details_api_patient__patient_id__patch","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/timeline":{"get":{"summary":"Get Patient Timeline","operationId":"get_patient_timeline_api_patient__patient_id__timeline_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/escalations":{"get":{"summary":"List Escalations","operationId":"list_escalations_api_escalations_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/escalations/{escalation_id}/resolved":{"patch":{"summary":"Set Escalation Resolved","operationId":"set_escalation_resolved_api_escalations__escalation_id__resolved_patch","parameters":[{"name":"escalation_id","in":"path","required":true,"schema":{"type":"integer","title":"Escalation Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EscalationResolveRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/escalations/{escalation_id}/triage-timeline":{"get":{"summary":"Get Triage Timeline","operationId":"get_triage_timeline_api_escalations__escalation_id__triage_timeline_get","parameters":[{"name":"escalation_id","in":"path","required":true,"schema":{"type":"integer","title":"Escalation Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/escalations/{escalation_id}/intervention":{"post":{"summary":"Send Intervention","operationId":"send_intervention_api_escalations__escalation_id__intervention_post","parameters":[{"name":"escalation_id","in":"path","required":true,"schema":{"type":"integer","title":"Escalation Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EscalationInterventionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/escalations/consent":{"post":{"summary":"Submit Escalation Consent","operationId":"submit_escalation_consent_api_escalations_consent_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EscalationConsentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/survey":{"get":{"summary":"Survey Page","operationId":"survey_page_survey_get","parameters":[{"name":"clinic_code","in":"query","required":true,"schema":{"type":"string","title":"Clinic Code"}},{"name":"resource_code","in":"query","required":true,"schema":{"type":"string","title":"Resource Code"}},{"name":"day","in":"query","required":true,"schema":{"type":"integer","title":"Day"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/survey/submit":{"post":{"summary":"Submit Survey","operationId":"submit_survey_api_survey_submit_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SurveySubmitRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/preop-survey/questions":{"get":{"summary":"Get Preop Survey Questions","operationId":"get_preop_survey_questions_api_preop_survey_questions_get","parameters":[{"name":"window","in":"query","required":true,"schema":{"type":"string","title":"Window"}},{"name":"patient_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/preop-survey/submit":{"post":{"summary":"Submit Preop Survey","operationId":"submit_preop_survey_api_preop_survey_submit_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpSurveySubmitBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patients/{patient_id}/preop-window/{window}":{"get":{"summary":"Get Preop Window Detail","operationId":"get_preop_window_detail_api_patients__patient_id__preop_window__window__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"window","in":"path","required":true,"schema":{"type":"string","title":"Window"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patients/{patient_id}/preop-window/{window}/action":{"post":{"summary":"Preop Window Action","operationId":"preop_window_action_api_patients__patient_id__preop_window__window__action_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"window","in":"path","required":true,"schema":{"type":"string","title":"Window"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpWindowActionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/doctor/patient/{patient_id}/survey/{day}":{"get":{"summary":"Get Doctor Survey","operationId":"get_doctor_survey_api_doctor_patient__patient_id__survey__day__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"day","in":"path","required":true,"schema":{"type":"integer","title":"Day"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/doctor/patient/{patient_id}":{"get":{"summary":"Doctor Patient View","description":"Doctor's view of a patient dashboard (same as patient view but with back-to-roster nav).","operationId":"doctor_patient_view_doctor_patient__patient_id__get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/upload-pdf":{"post":{"summary":"Upload Pdf","description":"Extract text from an uploaded PDF discharge document.","operationId":"upload_pdf_api_upload_pdf_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_pdf_api_upload_pdf_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/send-to-patient/{patient_id}":{"post":{"summary":"Send To Patient","description":"Send the patient dashboard link via SMS (Twilio) and email. Email includes clinic/resource codes and link to code-entry page.","operationId":"send_to_patient_api_send_to_patient__patient_id__post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/process-discharge":{"post":{"summary":"Process Discharge","description":"Full two-resource pipeline:\n  Raw discharge notes → Extract → Generate (Diagnosis + Treatment)\n                     → ElevenLabs audio for each → Store\n\nIf called by an authenticated doctor with a profile, assigns clinic_code, resource_code, and office_phone to the patient.\nReturns both resource sets for immediate display.","operationId":"process_discharge_api_process_discharge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DischargeInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/process-preop":{"post":{"summary":"Process Preop","description":"Pre-op resource pipeline:\n  Surgical prep notes -> Extract -> Generate pre-op voice + battlecard -> ElevenLabs audio -> Store","operationId":"process_preop_api_process_preop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/process-discharge/stream":{"post":{"summary":"Process Discharge Stream","operationId":"process_discharge_stream_api_process_discharge_stream_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DischargeInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/process-preop/stream":{"post":{"summary":"Process Preop Stream","operationId":"process_preop_stream_api_process_preop_stream_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/process-patient":{"post":{"summary":"Process Patient","description":"Legacy full pipeline (single resource set).","operationId":"process_patient_api_process_patient_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EHRBundle"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/resources":{"get":{"summary":"Get Patient Resources","description":"Return the two-resource sets (diagnosis + treatment) if available.","operationId":"get_patient_resources_api_patient__patient_id__resources_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/preop-audio":{"get":{"summary":"Get Preop Audio","description":"Lazy pre-op TTS — used when battlecard exists but audio was not cached.","operationId":"get_preop_audio_api_patient__patient_id__preop_audio_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/audio":{"get":{"summary":"Get Patient Audio","operationId":"get_patient_audio_api_patient__patient_id__audio_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/battlecard":{"get":{"summary":"Get Battlecard","operationId":"get_battlecard_api_patient__patient_id__battlecard_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/config":{"get":{"summary":"Get Dashboard Config","operationId":"get_dashboard_config_api_patient__patient_id__config_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/discharge":{"get":{"summary":"Get Discharge Instructions","operationId":"get_discharge_instructions_api_patient__patient_id__discharge_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/patient/{patient_id}/voice":{"get":{"summary":"Digital Care Companion Page","description":"Serves the Digital Care Companion conversation interface.","operationId":"digital_care_companion_page_patient__patient_id__voice_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"k","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"K"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/patient/{patient_id}/digital-care-companion":{"get":{"summary":"Digital Care Companion Page","description":"Serves the Digital Care Companion conversation interface.","operationId":"digital_care_companion_page_patient__patient_id__digital_care_companion_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"k","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"K"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/patient/{patient_id}/pre-op":{"get":{"summary":"Pre Op Page","description":"Serves the pre-operative preparation page.","operationId":"pre_op_page_patient__patient_id__pre_op_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"k","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"K"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/patient/{patient_id}":{"get":{"summary":"Patient Dashboard","operationId":"patient_dashboard_patient__patient_id__get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"k","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"K"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/avatar/chat":{"post":{"summary":"Digital Care Companion Chat","operationId":"digital_care_companion_chat_api_avatar_chat_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/digital-care-companion/chat":{"post":{"summary":"Digital Care Companion Chat","operationId":"digital_care_companion_chat_api_digital_care_companion_chat_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/start-interview":{"post":{"summary":"Intake Forms Start Interview","operationId":"intake_forms_start_interview_api_intake_forms_start_interview_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeFormsStartInterviewBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/interview/section-message":{"post":{"summary":"Intake Forms Interview Section Message","operationId":"intake_forms_interview_section_message_api_intake_forms__intake_form_id__interview_section_message_post","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeSectionMessageBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/interview/complete-section":{"post":{"summary":"Intake Forms Interview Complete Section","operationId":"intake_forms_interview_complete_section_api_intake_forms__intake_form_id__interview_complete_section_post","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeCompleteSectionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/interview/reset-section":{"post":{"summary":"Intake Forms Interview Reset Section","operationId":"intake_forms_interview_reset_section_api_intake_forms__intake_form_id__interview_reset_section_post","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeResetSectionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/complete-interview":{"post":{"summary":"Intake Forms Complete Interview","operationId":"intake_forms_complete_interview_api_intake_forms__intake_form_id__complete_interview_post","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeFormsCompleteInterviewBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}":{"get":{"summary":"Intake Forms Get","operationId":"intake_forms_get_api_intake_forms__intake_form_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"summary":"Intake Forms Patch","operationId":"intake_forms_patch_api_intake_forms__intake_form_id__patch","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeFormsPatchBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/latest/{patient_id}":{"get":{"summary":"Intake Forms Latest For Patient","operationId":"intake_forms_latest_for_patient_api_intake_forms_latest__patient_id__get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/submit":{"post":{"summary":"Intake Forms Submit","operationId":"intake_forms_submit_api_intake_forms__intake_form_id__submit_post","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeFormsSubmitBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intake-forms/{intake_form_id}/edit-history":{"get":{"summary":"Intake Forms Edit History","operationId":"intake_forms_edit_history_api_intake_forms__intake_form_id__edit_history_get","parameters":[{"name":"intake_form_id","in":"path","required":true,"schema":{"type":"string","title":"Intake Form Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/doctors/{doctor_id}/notifications":{"get":{"summary":"Intake Notifications List","operationId":"intake_notifications_list_api_doctors__doctor_id__notifications_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"doctor_id","in":"path","required":true,"schema":{"type":"string","title":"Doctor Id"}},{"name":"notif_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notif Type"}},{"name":"unread_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Unread Only"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/doctors/{doctor_id}/notifications/{notif_id}/read":{"patch":{"summary":"Intake Notifications Mark Read","operationId":"intake_notifications_mark_read_api_doctors__doctor_id__notifications__notif_id__read_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"doctor_id","in":"path","required":true,"schema":{"type":"string","title":"Doctor Id"}},{"name":"notif_id","in":"path","required":true,"schema":{"type":"string","title":"Notif Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pre-op/intake/start":{"post":{"summary":"Preop Intake Start","operationId":"preop_intake_start_api_pre_op_intake_start_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeStartRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pre-op/intake/answer":{"post":{"summary":"Preop Intake Answer","operationId":"preop_intake_answer_api_pre_op_intake_answer_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeAnswerRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pre-op/intake/submit":{"post":{"summary":"Preop Intake Submit","operationId":"preop_intake_submit_api_pre_op_intake_submit_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeSubmitRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/doctor/patient/{patient_id}/latest-intake":{"get":{"summary":"Doctor Latest Intake","operationId":"doctor_latest_intake_api_doctor_patient__patient_id__latest_intake_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pre-op/notify-care-team":{"post":{"summary":"Preop Notify Care Team","operationId":"preop_notify_care_team_api_pre_op_notify_care_team_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CareTeamNotificationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/prompts":{"get":{"tags":["internal"],"summary":"List Prompts","operationId":"list_prompts_internal_prompts_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/samples":{"get":{"tags":["internal"],"summary":"List Samples","operationId":"list_samples_internal_samples_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/voices":{"get":{"tags":["internal"],"summary":"List Voices","operationId":"list_voices_internal_voices_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/run":{"post":{"tags":["internal"],"summary":"Run Prompt","operationId":"run_prompt_internal_run_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/prompts/{prompt_id}":{"patch":{"tags":["internal"],"summary":"Save Prompt","operationId":"save_prompt_internal_prompts__prompt_id__patch","parameters":[{"name":"prompt_id","in":"path","required":true,"schema":{"type":"string","title":"Prompt Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavePromptRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/internal/git/push":{"post":{"tags":["internal"],"summary":"Git Push","operationId":"git_push_internal_git_push_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GitPushRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/auth/login":{"post":{"tags":["admin"],"summary":"Admin Login","operationId":"admin_login_admin_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminLoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/auth/logout":{"post":{"tags":["admin"],"summary":"Admin Logout","description":"Revoke the presented admin token (PRD-3).","operationId":"admin_logout_admin_auth_logout_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/audit/events":{"get":{"tags":["admin"],"summary":"Admin Audit Events","description":"Read the ePHI access audit trail (PRD-5; §164.312(b)).","operationId":"admin_audit_events_admin_audit_events_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"patient_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Id"}},{"name":"actor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Id"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/audit/verify":{"get":{"tags":["admin"],"summary":"Admin Audit Verify","description":"Recompute the audit hash chain and report any tampering.","operationId":"admin_audit_verify_admin_audit_verify_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/compliance/subprocessors":{"get":{"tags":["admin"],"summary":"Admin Subprocessors","description":"Subprocessor BAA register + live PHI-eligibility, for the security-review\npacket (PRD-4).","operationId":"admin_subprocessors_admin_compliance_subprocessors_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/demo-credentials":{"get":{"tags":["admin"],"summary":"Admin Demo Credentials","description":"Read-only demo account reference for ops (passwords included).","operationId":"admin_demo_credentials_admin_demo_credentials_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/stats":{"get":{"tags":["admin"],"summary":"Admin Stats","operationId":"admin_stats_admin_stats_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/preop-prompts":{"get":{"tags":["admin"],"summary":"Admin Get Preop Prompts","operationId":"admin_get_preop_prompts_admin_preop_prompts_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/preop-prompts/{prompt_id}":{"patch":{"tags":["admin"],"summary":"Admin Update Preop Prompt","operationId":"admin_update_preop_prompt_admin_preop_prompts__prompt_id__patch","parameters":[{"name":"prompt_id","in":"path","required":true,"schema":{"type":"string","title":"Prompt Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/intake-form-library":{"get":{"tags":["admin"],"summary":"Admin Get Intake Form Library","operationId":"admin_get_intake_form_library_admin_intake_form_library_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/intake-form-library/{specialty}":{"put":{"tags":["admin"],"summary":"Admin Update Intake Form Library","operationId":"admin_update_intake_form_library_admin_intake_form_library__specialty__put","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeTemplateUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/intake-frameworks":{"get":{"tags":["admin"],"summary":"Admin Get Intake Frameworks","operationId":"admin_get_intake_frameworks_admin_intake_frameworks_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/intake-frameworks/{specialty}":{"put":{"tags":["admin"],"summary":"Admin Update Intake Frameworks","operationId":"admin_update_intake_frameworks_admin_intake_frameworks__specialty__put","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntakeFrameworkUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/intake-section-prompts":{"get":{"tags":["admin"],"summary":"Admin Get Intake Section Prompts","description":"Return sample conversation markdown files for intake interview sections 3-10.","operationId":"admin_get_intake_section_prompts_admin_intake_section_prompts_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/health-systems/invite":{"post":{"tags":["admin"],"summary":"Admin Create Health System Invite","description":"Generate a unique onboarding URL for a new health system (internal admin only).","operationId":"admin_create_health_system_invite_admin_health_systems_invite_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/asclepius/invite":{"post":{"tags":["admin"],"summary":"Admin Create Asclepius Invite","description":"Mint + send a personal Asclepius (physician-evaluator) onboarding link\non behalf of a named lead (internal admin only). Unlike\n``/health-systems/invite`` above (which mints a generic, unpersonalized\nlink for the clinical/TEAM product), this locks the invite to\n``product=\"asclepius\"`` and ties it to one email, reusing the exact\nminting + cap logic the public self-serve endpoint uses\n(``routers.onboarding.self_serve_invite``) so an admin-sent invite and a\nphysician-typed-their-own-email invite share one counter and one shape.","operationId":"admin_create_asclepius_invite_admin_asclepius_invite_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusAdminInviteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/health-systems":{"get":{"tags":["admin"],"summary":"Admin List Health Systems","description":"List all health systems (invites + onboarded) with team rosters for customer management.","operationId":"admin_list_health_systems_admin_health_systems_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/triage/initial-tier/config":{"get":{"tags":["admin"],"summary":"Admin Get Initial Tier Config","description":"Return the read-only tuning snapshot for the Pre-Op Initial Tier algorithm.\n\nPowers the admin portal's \"Triage Logic\" tab. Shape is documented in\n`triage/tuning.py::get_config()`.","operationId":"admin_get_initial_tier_config_admin_triage_initial_tier_config_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/triage/preop-retier/config":{"get":{"tags":["admin"],"summary":"Admin Get Preop Retier Config","description":"Return the read-only tuning snapshot for the Pre-Op Re-Tier algorithm.\n\nRendered alongside the initial-tier section under the same admin\n\"Triage Logic\" tab. Shape is documented in\n`triage/preop_retier/tuning.py::get_config()`.","operationId":"admin_get_preop_retier_config_admin_triage_preop_retier_config_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/triage/intraop/config":{"get":{"tags":["admin"],"summary":"Admin Get Intraop Config","description":"Return the read-only tuning snapshot for the Intra-Op Reassessment.\n\nRendered as a third section in the admin \"Triage Logic\" tab. Shape is\ndocumented in `triage/intraop/tuning.py::get_config()` and includes\nhard upgrades, soft thresholds, per-family P90 OR-time benchmarks,\nthe conservative-default policy, and extraction tuning.","operationId":"admin_get_intraop_config_admin_triage_intraop_config_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/triage/postop/config":{"get":{"tags":["admin"],"summary":"Admin Get Postop Config","description":"Return the read-only tuning snapshot for the Post-Op Scoring &\nRe-Tiering algorithm.\n\nRendered as a fourth section in the admin \"Triage Logic\" tab. Shape\nis documented in `triage/postop/tuning.py::get_config()` and includes\nhard escalators, positive contributor weights, engagement-audit\nflags, the delta cap and thresholds, daily check-in / D-X survey /\nmed adherence / video / lost-contact configs, and the cron cadence.\nWound-photo-related entries are intentionally absent (PRD §8 out of\nscope v1).","operationId":"admin_get_postop_config_admin_triage_postop_config_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/grounding/reports":{"get":{"tags":["admin"],"summary":"List Grounding Reports Admin","operationId":"list_grounding_reports_admin_admin_grounding_reports_get","parameters":[{"name":"verdict","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verdict"}},{"name":"track","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Track"}},{"name":"prompt_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Version"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/grounding/reports/{report_id}":{"get":{"tags":["admin"],"summary":"Get Grounding Report Admin","operationId":"get_grounding_report_admin_admin_grounding_reports__report_id__get","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/grounding/stats":{"get":{"tags":["admin"],"summary":"Grounding Stats Admin","operationId":"grounding_stats_admin_admin_grounding_stats_get","parameters":[{"name":"window_days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Window Days"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/grounding/inspector-recall":{"get":{"tags":["admin"],"summary":"Grounding Inspector Recall Admin","operationId":"grounding_inspector_recall_admin_admin_grounding_inspector_recall_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ai-calls/stats":{"get":{"tags":["admin"],"summary":"Ai Call Stats Admin","operationId":"ai_call_stats_admin_admin_ai_calls_stats_get","parameters":[{"name":"window_days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Window Days"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ai-calls":{"get":{"tags":["admin"],"summary":"Ai Calls Admin","operationId":"ai_calls_admin_admin_ai_calls_get","parameters":[{"name":"role","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"}},{"name":"prompt_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Id"}},{"name":"prompt_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Version"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ai-calls/prompts":{"get":{"tags":["admin"],"summary":"Ai Call Prompts Admin","operationId":"ai_call_prompts_admin_admin_ai_calls_prompts_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/credential-config":{"get":{"tags":["onboarding"],"summary":"Credential Config","description":"What to ask a doctor for, country by country.\n\nPublic and tokenless: it is a form schema, identical for everyone, and the\nwizard needs it before a token is necessarily in hand. Fetched once at\nmount rather than per keystroke — the whole table is a few kilobytes and a\nround trip per country change would make the form feel broken on a plane.","operationId":"credential_config_api_onboarding_credential_config_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/onboarding/session":{"get":{"tags":["onboarding"],"summary":"Onboarding Session","operationId":"onboarding_session_api_onboarding_session_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/campaigns/{slug}":{"get":{"tags":["onboarding"],"summary":"Project Campaign","operationId":"project_campaign_api_onboarding_campaigns__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/self-serve":{"post":{"tags":["onboarding"],"summary":"Self Serve Invite","description":"Public: mint a physician-contributor onboarding link on demand.\n\nIssues the same magic link the admin \"Generate Health System Link\" button\ncreates, so a physician clicking \"Become a contributor\" on the landing\nlands directly in the existing onboarding wizard. Abuse guards, layered:\nIP rate limit (5 / 10 min) → global cap (60/h) → per-email cap\n(3 pending / 24h) → 7-day expiry (vs the admin default 30) → the wizard's\nown email-OTP step, which still gates every completion on proof of inbox\ncontrol.","operationId":"self_serve_invite_api_onboarding_self_serve_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelfServeBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/step1-identity":{"post":{"tags":["onboarding"],"summary":"Step1 Identity","operationId":"step1_identity_api_onboarding_step1_identity_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Step1Body"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/request-otp":{"post":{"tags":["onboarding"],"summary":"Request Otp","operationId":"request_otp_api_onboarding_request_otp_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardTokenBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/verify-otp":{"post":{"tags":["onboarding"],"summary":"Verify Otp","operationId":"verify_otp_api_onboarding_verify_otp_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyOtpBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/step3-organization":{"post":{"tags":["onboarding"],"summary":"Step3 Organization","operationId":"step3_organization_api_onboarding_step3_organization_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Step3Body"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/add-team-member":{"post":{"tags":["onboarding"],"summary":"Add Team Member","operationId":"add_team_member_api_onboarding_add_team_member_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddMemberBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/finish":{"post":{"tags":["onboarding"],"summary":"Finish Onboarding","operationId":"finish_onboarding_api_onboarding_finish_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinishBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/select-product":{"post":{"tags":["onboarding"],"summary":"Select Product","operationId":"select_product_api_onboarding_select_product_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelectProductBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/institution":{"post":{"tags":["onboarding"],"summary":"Asclepius Institution","operationId":"asclepius_institution_api_onboarding_asclepius_institution_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusInstitutionBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/credentials":{"post":{"tags":["onboarding"],"summary":"Asclepius Credentials","operationId":"asclepius_credentials_api_onboarding_asclepius_credentials_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusCredentialsBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/attestations":{"post":{"tags":["onboarding"],"summary":"Asclepius Attestations","operationId":"asclepius_attestations_api_onboarding_asclepius_attestations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusAttestationsBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/password":{"post":{"tags":["onboarding"],"summary":"Asclepius Set Password","description":"The physician chooses their own password, right after the OTP.\n\nPersisted here rather than carried in React state because the wizard\nresumes from SERVER state (onboarding_step), so a refresh would otherwise\ndrop the password and land the user past the step that collects it.","operationId":"asclepius_set_password_api_onboarding_asclepius_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusPasswordBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/password":{"post":{"tags":["onboarding"],"summary":"Member Set Password","operationId":"member_set_password_api_onboarding_member_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusPasswordBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/cv":{"post":{"tags":["onboarding"],"summary":"Asclepius Cv Upload","description":"Optional CV upload during signup (PRD-B Phase 2/4).\n\nAccepts either the director onboarding token or an invited-member token,\nstores the raw document content-addressed, and records the sha **on the\nperson's own row, server-side** (B-5.7). The sha is never round-tripped\nthrough the client: ``credentials`` is a free-form dict, so a client-set\n``cvAssetSha`` would be an unvalidated reference into the shared asset\nstore — which also holds de-identified clinical images.\n\nParsing happens AFTER the response is sent (B-1.1): pdfminer/pypdf and\nespecially the OCR fallback are tens of CPU-seconds, and nothing about the\nCV needs to be parsed before the form returns.","operationId":"asclepius_cv_upload_api_onboarding_asclepius_cv_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_asclepius_cv_upload_api_onboarding_asclepius_cv_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/cv/status":{"get":{"tags":["onboarding"],"summary":"Asclepius Cv Status","description":"Where the CV parse has got to, and what it found (§2 screen 3).\n\nPolled by the wizard between the upload and the Review screen. Returns the\nparse SUGGESTIONS, not a decision: the Review screen prefills from them and\nthe physician edits anything that is wrong, so nothing here is authoritative\nand nothing here can fail the application.","operationId":"asclepius_cv_status_api_onboarding_asclepius_cv_status_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/add-member":{"post":{"tags":["onboarding"],"summary":"Asclepius Add Member","operationId":"asclepius_add_member_api_onboarding_asclepius_add_member_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AsclepiusAddMemberBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/asclepius/finish":{"post":{"tags":["onboarding"],"summary":"Asclepius Finish","operationId":"asclepius_finish_api_onboarding_asclepius_finish_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardTokenBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/session":{"get":{"tags":["onboarding"],"summary":"Member Session","operationId":"member_session_api_onboarding_member_session_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/credentials":{"post":{"tags":["onboarding"],"summary":"Member Credentials","operationId":"member_credentials_api_onboarding_member_credentials_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MemberCredentialsBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/attestations":{"post":{"tags":["onboarding"],"summary":"Member Attestations","operationId":"member_attestations_api_onboarding_member_attestations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MemberAttestationsBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/request-otp":{"post":{"tags":["onboarding"],"summary":"Member Request Otp","description":"Hard-gate email verification for invited clinicians (Feature B): mails a\n6-digit OTP to the same inbox that received the invite, via the existing\n``otp_challenges`` machinery the director already uses.","operationId":"member_request_otp_api_onboarding_member_request_otp_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardTokenBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/verify-otp":{"post":{"tags":["onboarding"],"summary":"Member Verify Otp","operationId":"member_verify_otp_api_onboarding_member_verify_otp_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyOtpBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/onboarding/member/finish":{"post":{"tags":["onboarding"],"summary":"Member Finish","operationId":"member_finish_api_onboarding_member_finish_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardTokenBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/auth/login":{"post":{"tags":["tenant"],"summary":"Tenant Auth Login","operationId":"tenant_auth_login_api_tenant__slug__auth_login_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantLoginBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/me":{"get":{"tags":["tenant"],"summary":"Tenant Me","operationId":"tenant_me_api_tenant__slug__me_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/audit-log":{"get":{"tags":["tenant"],"summary":"Tenant Audit Log","operationId":"tenant_audit_log_api_tenant__slug__audit_log_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/grounding/reports":{"get":{"tags":["tenant"],"summary":"Tenant List Grounding Reports","operationId":"tenant_list_grounding_reports_api_tenant__slug__grounding_reports_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"verdict","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verdict"}},{"name":"track","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Track"}},{"name":"prompt_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Version"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/grounding/reports/{report_id}":{"get":{"tags":["tenant"],"summary":"Tenant Get Grounding Report","operationId":"tenant_get_grounding_report_api_tenant__slug__grounding_reports__report_id__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"report_id","in":"path","required":true,"schema":{"type":"integer","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/grounding/stats":{"get":{"tags":["tenant"],"summary":"Tenant Grounding Stats","operationId":"tenant_grounding_stats_api_tenant__slug__grounding_stats_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"window_days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Window Days"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/grounding/inspector-recall":{"get":{"tags":["tenant"],"summary":"Tenant Grounding Inspector Recall","operationId":"tenant_grounding_inspector_recall_api_tenant__slug__grounding_inspector_recall_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/ai-calls/stats":{"get":{"tags":["tenant"],"summary":"Tenant Ai Call Stats","operationId":"tenant_ai_call_stats_api_tenant__slug__ai_calls_stats_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"window_days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Window Days"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/ai-calls":{"get":{"tags":["tenant"],"summary":"Tenant Ai Calls","operationId":"tenant_ai_calls_api_tenant__slug__ai_calls_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"role","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"}},{"name":"prompt_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Id"}},{"name":"prompt_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Version"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/tenant/{slug}/ai-calls/prompts":{"get":{"tags":["tenant"],"summary":"Tenant Ai Call Prompts","operationId":"tenant_ai_call_prompts_api_tenant__slug__ai_calls_prompts_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-draft-patient":{"post":{"tags":["eligibility"],"summary":"Create Draft Patient","operationId":"create_draft_patient_api_eligibility_draft_patient_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DraftPatientRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-draft-patients/{patient_id}":{"delete":{"tags":["eligibility"],"summary":"Delete Draft Patient","description":"Cancel a draft, retaining accepted originals and their source metadata.\n\nRefuses to delete patients without ``is_draft=True`` so it cannot be\nmisused to evict a finalized patient from the roster.","operationId":"delete_draft_patient_api_eligibility_draft_patients__patient_id__delete","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-documents":{"post":{"tags":["eligibility"],"summary":"Upload Eligibility Document","operationId":"upload_eligibility_document_api_eligibility_documents_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_eligibility_document_api_eligibility_documents_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/eligibility-documents":{"get":{"tags":["eligibility"],"summary":"List Patient Eligibility Documents","description":"Return summary metadata for every doc currently attached to ``patient_id``.\n\nUseful for the doctor portal when reopening a draft, or for showing\n\"previously uploaded files\" alongside an in-progress eligibility check.","operationId":"list_patient_eligibility_documents_api_patient__patient_id__eligibility_documents_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-documents/{doc_id}":{"delete":{"tags":["eligibility"],"summary":"Delete Eligibility Document","operationId":"delete_eligibility_document_api_eligibility_documents__doc_id__delete","parameters":[{"name":"doc_id","in":"path","required":true,"schema":{"type":"string","title":"Doc Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks":{"post":{"tags":["eligibility"],"summary":"Create Eligibility Check","operationId":"create_eligibility_check_api_eligibility_checks_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCheckRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}":{"get":{"tags":["eligibility"],"summary":"Get Check","operationId":"get_check_api_eligibility_checks__check_id__get","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}/stream-ticket":{"post":{"tags":["eligibility"],"summary":"Check Stream Ticket","operationId":"check_stream_ticket_api_eligibility_checks__check_id__stream_ticket_post","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}/stream":{"get":{"tags":["eligibility"],"summary":"Stream Check","operationId":"stream_check_api_eligibility_checks__check_id__stream_get","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}/override":{"post":{"tags":["eligibility"],"summary":"Override Field","operationId":"override_field_api_eligibility_checks__check_id__override_post","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OverrideRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}/rerun":{"post":{"tags":["eligibility"],"summary":"Rerun Check","operationId":"rerun_check_api_eligibility_checks__check_id__rerun_post","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-checks/{check_id}/finalize":{"post":{"tags":["eligibility"],"summary":"Finalize Check","operationId":"finalize_check_api_eligibility_checks__check_id__finalize_post","parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FinalizeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-batches":{"post":{"tags":["eligibility"],"summary":"Create Eligibility Batch","operationId":"create_eligibility_batch_api_eligibility_batches_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_create_eligibility_batch_api_eligibility_batches_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-batches/{batch_id}":{"get":{"tags":["eligibility"],"summary":"Get Batch","operationId":"get_batch_api_eligibility_batches__batch_id__get","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-batches/{batch_id}/stream-ticket":{"post":{"tags":["eligibility"],"summary":"Batch Stream Ticket","operationId":"batch_stream_ticket_api_eligibility_batches__batch_id__stream_ticket_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/eligibility-batches/{batch_id}/stream":{"get":{"tags":["eligibility"],"summary":"Stream Batch","operationId":"stream_batch_api_eligibility_batches__batch_id__stream_get","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/postop-notes":{"get":{"tags":["eligibility"],"summary":"Get Postop Notes","operationId":"get_postop_notes_api_patient__patient_id__postop_notes_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/postop-notes/confirm":{"post":{"tags":["eligibility"],"summary":"Confirm Postop Notes","operationId":"confirm_postop_notes_api_patient__patient_id__postop_notes_confirm_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotesConfirmRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/preop-notes":{"get":{"tags":["eligibility"],"summary":"Get Preop Notes","operationId":"get_preop_notes_api_patient__patient_id__preop_notes_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/preop-notes/confirm":{"post":{"tags":["eligibility"],"summary":"Confirm Preop Notes","operationId":"confirm_preop_notes_api_patient__patient_id__preop_notes_confirm_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotesConfirmRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/audit/eligibility":{"get":{"tags":["eligibility"],"summary":"List Audit Events","description":"Return recent events only when patient or batch ownership is provable.","operationId":"list_audit_events_admin_audit_eligibility_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form":{"get":{"tags":["intraop"],"summary":"Get Intraop Form","operationId":"get_intraop_form_api_episodes__patient_id__intraop_form_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/StaffContext"},{"type":"null"}],"title":"Staff"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["intraop"],"summary":"Create Or Get Intraop Form","description":"Idempotent: returns the existing form when one exists, else creates a NEW row.","operationId":"create_or_get_intraop_form_api_episodes__patient_id__intraop_form_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FormUpsertRequest","default":{}}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["intraop"],"summary":"Patch Intraop Form","description":"Autosave endpoint: merges supplied fields into the form blob.\n\nPass-4 status-aware role gating (PRD §4.2):\n  - status in {NEW, IN_PROGRESS, REOPENED}    → rn_coordinator\n  - status == READY_FOR_SURGEON_REVIEW        → surgeon\n  - status == LOCKED                          → 409 (admin REOPEN required)","operationId":"patch_intraop_form_api_episodes__patient_id__intraop_form_patch","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FormUpsertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/lock":{"post":{"tags":["intraop"],"summary":"Lock Intraop Form","description":"Surgeon lock — finalizes the intra-op reassessment (PRD §4.5).\n\nPass-4: surgeon role required AND form must be in `READY_FOR_SURGEON_REVIEW`.","operationId":"lock_intraop_form_api_episodes__patient_id__intraop_form_lock_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/mark-ready-for-review":{"post":{"tags":["intraop"],"summary":"Mark Intraop Form Ready For Review","description":"RN flips an IN_PROGRESS form to READY_FOR_SURGEON_REVIEW (PRD §4.4).\n\nValidates required fields and OR-duration consistency, persists draft\nattribution, opens an `escalations` row tagged `intraop:ready_for_review`,\nand logs `INTRAOP_FORM_READY_FOR_REVIEW`.","operationId":"mark_intraop_form_ready_for_review_api_episodes__patient_id__intraop_form_mark_ready_for_review_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/recall":{"post":{"tags":["intraop"],"summary":"Recall Intraop Form Draft","description":"RN pulls a READY_FOR_SURGEON_REVIEW draft back to IN_PROGRESS (PRD §4.4).","operationId":"recall_intraop_form_draft_api_episodes__patient_id__intraop_form_recall_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intraop-forms":{"get":{"tags":["intraop"],"summary":"List Intraop Forms","description":"Surgeon \"Forms awaiting your review\" surface (PRD §4.6).\n\nTenant-scoped. Restricted to surgeons (the only role expected to act\non the queue).","operationId":"list_intraop_forms_api_intraop_forms_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"READY_FOR_SURGEON_REVIEW","title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/reopen":{"post":{"tags":["intraop"],"summary":"Reopen Intraop Form","description":"Reopen a LOCKED form. Pass-4: accepts either a valid admin token OR a\nsurgeon Bearer whose email matches `surgeon_locked_by`.","operationId":"reopen_intraop_form_api_episodes__patient_id__intraop_form_reopen_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"X-Admin-Token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Admin-Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/preview":{"post":{"tags":["intraop"],"summary":"Preview Intraop Tier","description":"Live tier preview. Pass-4: any clinical staff role (read-only).","operationId":"preview_intraop_tier_api_episodes__patient_id__intraop_form_preview_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-form/pdf":{"post":{"tags":["intraop"],"summary":"Upload Intraop Pdf","description":"Upload AIMS / chart PDF for extraction. Pass-4: clinical write role.","operationId":"upload_intraop_pdf_api_episodes__patient_id__intraop_form_pdf_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_intraop_pdf_api_episodes__patient_id__intraop_form_pdf_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intraop-extractions/{extraction_id}":{"get":{"tags":["intraop"],"summary":"Get Intraop Extraction","operationId":"get_intraop_extraction_api_intraop_extractions__extraction_id__get","parameters":[{"name":"extraction_id","in":"path","required":true,"schema":{"type":"string","title":"Extraction Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/intraop-extractions/{extraction_id}/stream":{"get":{"tags":["intraop"],"summary":"Stream Intraop Extraction","description":"SSE poller — emits `status` updates until COMPLETE / FAILED.","operationId":"stream_intraop_extraction_api_intraop_extractions__extraction_id__stream_get","parameters":[{"name":"extraction_id","in":"path","required":true,"schema":{"type":"string","title":"Extraction Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/intraop-reassessments":{"get":{"tags":["intraop"],"summary":"List Intraop Reassessments","description":"Reassessment audit list. Pass-4: any clinical staff role.","operationId":"list_intraop_reassessments_api_episodes__patient_id__intraop_reassessments_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/switch-to-postop":{"post":{"tags":["intraop"],"summary":"Switch To Postop","description":"Surgeon-triggered transition: marks OR as ended, ensures a form row,\nand returns the form id so the UI can navigate to the intra-op form.\nPass-4: surgeon role required.","operationId":"switch_to_postop_api_episodes__patient_id__switch_to_postop_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SwitchToPostopRequest","default":{}}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop":{"get":{"tags":["postop"],"summary":"Get Postop View","description":"Read post-op blob. Pass-4: any clinical staff role; patients hit\ntheir own dashboard which uses a different code path (`/patient/{id}`).","operationId":"get_postop_view_api_episodes__patient_id__postop_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/discharge":{"post":{"tags":["postop"],"summary":"Post Discharge","description":"Record discharge timestamp. Pass-4: clinical write role (RN or surgeon).","operationId":"post_discharge_api_episodes__patient_id__postop_discharge_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DischargeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/checkin":{"post":{"tags":["postop"],"summary":"Post Daily Checkin","description":"Patient-submitted daily check-in. Pass-4: patient-session only.","operationId":"post_daily_checkin_api_episodes__patient_id__postop_checkin_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DailyCheckinRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/survey/{day}":{"post":{"tags":["postop"],"summary":"Post Dayx Survey","operationId":"post_dayx_survey_api_episodes__patient_id__postop_survey__day__post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"day","in":"path","required":true,"schema":{"type":"integer","title":"Day"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DayXSurveyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/med-adherence":{"post":{"tags":["postop"],"summary":"Post Med Adherence","description":"Patient-submitted med-adherence response. Pass-4: patient-session only.","operationId":"post_med_adherence_api_episodes__patient_id__postop_med_adherence_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MedAdherenceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/video-event":{"post":{"tags":["postop"],"summary":"Post Video Event","description":"Patient-submitted post-op video event. Pass-4: patient-session only.","operationId":"post_video_event_api_episodes__patient_id__postop_video_event_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoEventRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/self-flag":{"post":{"tags":["postop"],"summary":"Post Self Flag","description":"Patient one-tap self-flag. Pass-4: patient-session only.","operationId":"post_self_flag_api_episodes__patient_id__postop_self_flag_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelfFlagRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/self-flag/resolve":{"post":{"tags":["postop"],"summary":"Post Self Flag Resolve","description":"RN closes a patient self-flag. Pass-4: alert resolve = `rn_coordinator` only.","operationId":"post_self_flag_resolve_api_episodes__patient_id__postop_self_flag_resolve_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelfFlagResolveRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop/care-goal-changed":{"post":{"tags":["postop"],"summary":"Post Care Goal Changed","description":"RN-driven care-goal pivot flag. Pass-4: clinical write role.","operationId":"post_care_goal_changed_api_episodes__patient_id__postop_care_goal_changed_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CareGoalRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop-retier/run":{"post":{"tags":["postop"],"summary":"Post Retier Run","description":"Manual recompute. Pass-4: clinical write role (RN or surgeon).","operationId":"post_retier_run_api_episodes__patient_id__postop_retier_run_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/RetierRunRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/postop-retier-events":{"get":{"tags":["postop"],"summary":"List Retier Events","description":"Audit list. Pass-4: any clinical staff role (read-only includes NP/PA).","operationId":"list_retier_events_api_episodes__patient_id__postop_retier_events_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/initial-tier/compute":{"post":{"tags":["initial-tier"],"summary":"Post Initial Tier Compute","description":"Stateless preview — no persistence, no events. Pass-4 PRD §3.1\ntreats `compute` as a clinical write surface (the surgeon's workflow\ndecision tool), so NP/PA is blocked even though it's read-only at the\nstorage layer.","operationId":"post_initial_tier_compute_api_triage_initial_tier_compute_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitialTierInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Initial Tier Compute Api Triage Initial Tier Compute Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{episode_id}/initial-tier":{"post":{"tags":["initial-tier"],"summary":"Post Initial Tier Assign","description":"Assign the initial tier and persist onto `_patient_store[episode_id]`.\n\nIdempotent: if the same input snapshot has already been recorded, the\npersisted blob and event log are not duplicated. The tier reassignment\nitself is always recomputed (the algorithm is pure), so the response\nis always a fresh `TierAssignment`.","operationId":"post_initial_tier_assign_api_episodes__episode_id__initial_tier_post","parameters":[{"name":"episode_id","in":"path","required":true,"schema":{"type":"string","title":"Episode Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssignInitialTierRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Initial Tier Assign Api Episodes  Episode Id  Initial Tier Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{episode_id}/initial-tier/override":{"post":{"tags":["initial-tier"],"summary":"Post Initial Tier Override","description":"Coordinator override of the algorithmic initial tier.\n\nPer PRD §13.13, the override changes `current_tier` *but* leaves the\n`initial_tier_was_hard_escalator` flag unchanged so the pre-op re-tier\nsticky-hard guard still respects the underlying clinical condition.","operationId":"post_initial_tier_override_api_episodes__episode_id__initial_tier_override_post","parameters":[{"name":"episode_id","in":"path","required":true,"schema":{"type":"string","title":"Episode Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitialTierOverrideRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Initial Tier Override Api Episodes  Episode Id  Initial Tier Override Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/tuning/initial-tier/current":{"get":{"tags":["initial-tier"],"summary":"Get Initial Tier Tuning Current","description":"Read tuning snapshot. Pass-4: any authenticated staff role.","operationId":"get_initial_tier_tuning_current_api_triage_tuning_initial_tier_current_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Initial Tier Tuning Current Api Triage Tuning Initial Tier Current Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/tuning/initial-tier":{"post":{"tags":["initial-tier"],"summary":"Post Initial Tier Tuning","description":"Admin contract surface (no-op deploy v1).\n\nMirrors the prior triage stages — accepts (and ignores) a tuning\npayload, returns the current static config so client tooling can\nconfirm a deploy round-trip. Use `/admin/triage/initial-tier/config`\nfor the read-side rendered in the admin portal.","operationId":"post_initial_tier_tuning_api_triage_tuning_initial_tier_post","parameters":[{"name":"x-admin-token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Admin-Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Initial Tier Tuning Api Triage Tuning Initial Tier Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/preop-retier/compute":{"post":{"tags":["preop-retier"],"summary":"Post Preop Retier Compute","description":"Stateless preview — no persistence, no events. Pass-4 PRD §3.2\ntreats `compute` as a clinical write surface so NP/PA is blocked.","operationId":"post_preop_retier_compute_api_triage_preop_retier_compute_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpReTierInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Preop Retier Compute Api Triage Preop Retier Compute Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{episode_id}/preop-retier/run":{"post":{"tags":["preop-retier"],"summary":"Post Preop Retier Run","description":"Manual recompute. Always writes a `preop_retier_events` row\nregardless of `changed`. Honors the per-episode lock.","operationId":"post_preop_retier_run_api_episodes__episode_id__preop_retier_run_post","parameters":[{"name":"episode_id","in":"path","required":true,"schema":{"type":"string","title":"Episode Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpReTierRunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Preop Retier Run Api Episodes  Episode Id  Preop Retier Run Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{episode_id}/pam":{"post":{"tags":["preop-retier"],"summary":"Post Pam Submission","description":"Score PAM, persist, then synchronously re-tier inside the episode lock.\n\nPass-4: patient-session only — staff can't submit PAM responses on a\npatient's behalf. A patient session must match this episode; if a staff\nBearer is presented, return 403.","operationId":"post_pam_submission_api_episodes__episode_id__pam_post","parameters":[{"name":"episode_id","in":"path","required":true,"schema":{"type":"string","title":"Episode Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PamSubmission"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Pam Submission Api Episodes  Episode Id  Pam Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/events/preop-video":{"post":{"tags":["preop-retier"],"summary":"Post Preop Video Event","description":"Record a pre-op video play event, dedupe within 60s for same\n`(episode_id, session_id)`, then trigger a re-tier.\n\nPass-4: patient-session only — clinicians don't generate video-watched\nevents; the patient app posts these directly.","operationId":"post_preop_video_event_api_events_preop_video_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreOpVideoEvent"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Preop Video Event Api Events Preop Video Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/events/battlecard":{"post":{"tags":["preop-retier"],"summary":"Post Battlecard Event","description":"Record a battle-card view event, dedupe within 30 minutes for\nthe patient, then trigger a re-tier.\n\nPass-4: patient-session only — same rationale as `/api/events/preop-video`.","operationId":"post_battlecard_event_api_events_battlecard_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BattleCardEvent"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Battlecard Event Api Events Battlecard Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/tuning/preop-retier/current":{"get":{"tags":["preop-retier"],"summary":"Get Preop Retier Tuning Current","description":"Read tuning snapshot. Pass-4: any authenticated staff role.","operationId":"get_preop_retier_tuning_current_api_triage_tuning_preop_retier_current_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Preop Retier Tuning Current Api Triage Tuning Preop Retier Current Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/triage/tuning/preop-retier":{"post":{"tags":["preop-retier"],"summary":"Post Preop Retier Tuning","description":"Admin contract surface (no-op deploy v1).\n\nUse `/admin/triage/preop-retier/config` for the read-side rendered\nin the admin portal.","operationId":"post_preop_retier_tuning_api_triage_tuning_preop_retier_post","parameters":[{"name":"x-admin-token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Admin-Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Post Preop Retier Tuning Api Triage Tuning Preop Retier Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/teachback/{track}/start":{"post":{"tags":["teachback"],"summary":"Start Teachback","operationId":"start_teachback_api_episodes__patient_id__teachback__track__start_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"track","in":"path","required":true,"schema":{"type":"string","title":"Track"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeachBackStartResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/teachback/{track}/answer":{"post":{"tags":["teachback"],"summary":"Answer Teachback","operationId":"answer_teachback_api_episodes__patient_id__teachback__track__answer_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"track","in":"path","required":true,"schema":{"type":"string","title":"Track"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeachBackAnswerBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{patient_id}/teachback/{track}":{"get":{"tags":["teachback"],"summary":"Get Teachback Session State","operationId":"get_teachback_session_state_api_episodes__patient_id__teachback__track__get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"track","in":"path","required":true,"schema":{"type":"string","title":"Track"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/teachback/stats":{"get":{"tags":["teachback"],"summary":"Admin Teachback Stats","operationId":"admin_teachback_stats_admin_teachback_stats_get","parameters":[{"name":"window_days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Window Days"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"X-Admin-Token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Admin-Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/teachback/grader-recall":{"get":{"tags":["teachback"],"summary":"Admin Teachback Recall","operationId":"admin_teachback_recall_admin_teachback_grader_recall_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"X-Admin-Token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Admin-Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/episodes/{episode_id}/triage-explain":{"get":{"tags":["triage-explain"],"summary":"Get Triage Explain","operationId":"get_triage_explain_api_episodes__episode_id__triage_explain_get","parameters":[{"name":"episode_id","in":"path","required":true,"schema":{"type":"string","title":"Episode Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patients/{patient_id}/care-team-messages":{"post":{"tags":["messaging"],"summary":"Clinician Send Care Team Message","operationId":"clinician_send_care_team_message_api_patients__patient_id__care_team_messages_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CareTeamMessageSendBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["messaging"],"summary":"Clinician List Care Team Messages","operationId":"clinician_list_care_team_messages_api_patients__patient_id__care_team_messages_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/care-team-messages":{"get":{"tags":["messaging"],"summary":"Patient List Care Team Messages","operationId":"patient_list_care_team_messages_api_patient__patient_id__care_team_messages_get","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/patient/{patient_id}/care-team-messages/reply":{"post":{"tags":["messaging"],"summary":"Patient Reply Care Team Message","operationId":"patient_reply_care_team_message_api_patient__patient_id__care_team_messages_reply_post","parameters":[{"name":"patient_id","in":"path","required":true,"schema":{"type":"string","title":"Patient Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CareTeamPatientReplyBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters":{"post":{"tags":["telehealth"],"summary":"Create Encounter","operationId":"create_encounter_api_telehealth_encounters_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateEncounterBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/session":{"post":{"tags":["telehealth"],"summary":"Create Session","operationId":"create_session_api_telehealth_encounters__encounter_id__session_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/patient-type":{"post":{"tags":["telehealth"],"summary":"Set Patient Type","operationId":"set_patient_type_api_telehealth_encounters__encounter_id__patient_type_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientTypeBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/invite":{"post":{"tags":["telehealth"],"summary":"Invite Patient","operationId":"invite_patient_api_telehealth_encounters__encounter_id__invite_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/start":{"post":{"tags":["telehealth"],"summary":"Start Encounter","operationId":"start_encounter_api_telehealth_encounters__encounter_id__start_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/heartbeat":{"post":{"tags":["telehealth"],"summary":"Heartbeat Encounter","operationId":"heartbeat_encounter_api_telehealth_encounters__encounter_id__heartbeat_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/location":{"post":{"tags":["telehealth"],"summary":"Set Location","operationId":"set_location_api_telehealth_encounters__encounter_id__location_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LocationBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/documentation":{"post":{"tags":["telehealth"],"summary":"Save Documentation","operationId":"save_documentation_api_telehealth_encounters__encounter_id__documentation_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentationBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/end":{"post":{"tags":["telehealth"],"summary":"End Encounter","operationId":"end_encounter_api_telehealth_encounters__encounter_id__end_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EndEncounterBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/attest":{"post":{"tags":["telehealth"],"summary":"Post Attestation","operationId":"post_attestation_api_telehealth_encounters__encounter_id__attest_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttestBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/build-claim":{"post":{"tags":["telehealth"],"summary":"Build Claim","operationId":"build_claim_api_telehealth_encounters__encounter_id__build_claim_post","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}":{"get":{"tags":["telehealth"],"summary":"Get Encounter Api","operationId":"get_encounter_api_api_telehealth_encounters__encounter_id__get","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/encounters/{encounter_id}/patient-join-token":{"get":{"tags":["telehealth"],"summary":"Patient Join Token","operationId":"patient_join_token_api_telehealth_encounters__encounter_id__patient_join_token_get","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"t","in":"query","required":true,"schema":{"type":"string","title":"T"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/telehealth/claims/{claim_id}/download":{"get":{"tags":["telehealth"],"summary":"Download Claim","operationId":"download_claim_api_telehealth_claims__claim_id__download_get","parameters":[{"name":"claim_id","in":"path","required":true,"schema":{"type":"string","title":"Claim Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/telehealth/setup/{encounter_id}":{"get":{"tags":["telehealth"],"summary":"Telehealth Setup Page","operationId":"telehealth_setup_page_telehealth_setup__encounter_id__get","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/telehealth/room/{encounter_id}":{"get":{"tags":["telehealth"],"summary":"Telehealth Room Page","operationId":"telehealth_room_page_telehealth_room__encounter_id__get","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/telehealth/join/{encounter_id}":{"get":{"tags":["telehealth"],"summary":"Telehealth Join Page","operationId":"telehealth_join_page_telehealth_join__encounter_id__get","parameters":[{"name":"encounter_id","in":"path","required":true,"schema":{"type":"string","title":"Encounter Id"}},{"name":"t","in":"query","required":true,"schema":{"type":"string","title":"T"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/telehealth/unavailable":{"get":{"tags":["telehealth"],"summary":"Telehealth Unavailable","operationId":"telehealth_unavailable_telehealth_unavailable_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/api/asclepius/assets/onboarding-demo/ticket":{"post":{"tags":["asclepius-media"],"summary":"Onboarding Demo Ticket","description":"Mint a 30-minute, demo-only ticket for the player element.","operationId":"onboarding_demo_ticket_api_asclepius_assets_onboarding_demo_ticket_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assets/onboarding-demo":{"get":{"tags":["asclepius-media"],"summary":"Onboarding Demo","description":"Stream the demo, honoring HTTP Range.\n\nStarlette answers HEAD from this same route, which is what a player issues\nfirst to learn the length before it will draw a timeline.","operationId":"onboarding_demo_api_asclepius_assets_onboarding_demo_get","parameters":[{"name":"t","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"T"}},{"name":"Range","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Range"}},{"name":"If-None-Match","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"If-None-Match"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assets/onboarding-demo/meta":{"get":{"tags":["asclepius-media"],"summary":"Onboarding Demo Meta","description":"Is there a demo to play, and how big is it?\n\nThe walkthrough asks this BEFORE it renders stop 2, so a deployment that has\nnot had the video uploaded yet shows the practice case on its own instead of\na card that plays a 404.","operationId":"onboarding_demo_meta_api_asclepius_assets_onboarding_demo_meta_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/assets/onboarding-demo":{"post":{"tags":["asclepius-media"],"summary":"Upload Onboarding Demo","description":"One-time (per re-record) admin upload of the demo video.\n\nDeliberately an ENDPOINT and not only a deploy step: the asset store lives on\na persistent volume that a developer's laptop does not have, so \"copy the file\nonto the server\" is not a thing anyone can actually do on a managed host.\n``backend/scripts/upload_onboarding_demo.py`` drives this over HTTPS.\n\nThe body is streamed straight through to the store — nothing here reads the\nwhole file — so a 500 MB upload costs one chunk of memory on the way past.","operationId":"upload_onboarding_demo_api_asclepius_admin_assets_onboarding_demo_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_onboarding_demo_api_asclepius_admin_assets_onboarding_demo_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/taxonomy":{"get":{"tags":["asclepius"],"summary":"Get Taxonomy","operationId":"get_taxonomy_api_asclepius_taxonomy_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/login":{"post":{"tags":["asclepius"],"summary":"Login","operationId":"login_api_asclepius_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/password/forgot":{"post":{"tags":["asclepius"],"summary":"Forgot Password","operationId":"forgot_password_api_asclepius_auth_password_forgot_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForgotPasswordRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/signin-link":{"post":{"tags":["asclepius"],"summary":"Request Signin Link","operationId":"request_signin_link_api_asclepius_auth_signin_link_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SigninLinkRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/signin-link/exchange":{"post":{"tags":["asclepius"],"summary":"Exchange Signin Link","description":"Trade the emailed token for a session, once.\n\nExpired, already used and never-existed collapse to one sentence, the same\nway the reset door collapses them: the holder of a bad link learns nothing\nabout which it was.","operationId":"exchange_signin_link_api_asclepius_auth_signin_link_exchange_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SigninLinkExchange"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/password/reset":{"post":{"tags":["asclepius"],"summary":"Reset Password","operationId":"reset_password_api_asclepius_auth_password_reset_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResetPasswordRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/password/change":{"post":{"tags":["asclepius"],"summary":"Change Password","operationId":"change_password_api_asclepius_auth_password_change_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChangePasswordRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/sso":{"post":{"tags":["asclepius"],"summary":"Sso","description":"Exchange a valid doctor-portal session for an Asclepius session (SSO).\n\nA clinician already signed into the doctor portal enters the evaluator portal\nautomatically — no second login. The presented ``tenant_staff`` token is the\naccess barrier: it must be valid/unrevoked (only an authenticated, affiliated\nclinician holds one). On first arrival we auto-provision an evaluator account\nkeyed to the doctor's email so access \"just works\"; on later visits we resume\nthat same account. The portal is never left unauthenticated — an anonymous\nvisitor with no doctor session still gets the login form (PRD §3, §7.1).","operationId":"sso_api_asclepius_auth_sso_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SsoRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/portal-handoff":{"post":{"tags":["asclepius"],"summary":"Create Asclepius Portal Handoff","operationId":"create_asclepius_portal_handoff_api_asclepius_auth_portal_handoff_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/portal-handoff/consume":{"post":{"tags":["asclepius"],"summary":"Consume Asclepius Portal Handoff","operationId":"consume_asclepius_portal_handoff_api_asclepius_auth_portal_handoff_consume_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AscPortalHandoffConsumeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/auth/me":{"get":{"tags":["asclepius"],"summary":"Me","description":"The signed-in physician, and the tick of the onboarding cadence clock.\n\nWelcome package v2 §5: ``sessions_seen`` increments on the ``/auth/me`` that\nfollows a login — not in ``/auth/login``, because the portal also reaches\nthis endpoint on a cold boot from a token still in storage, and a physician\nwho closes the tab on Monday and opens it on Tuesday has started a session\nwithout signing in again.\n\nIdempotent per LOGIN, keyed on the token's ``jti``: a reload, a second tab\nand the parallel calls one page paint makes all carry the same token and\ncount once, while a genuine new sign-in mints a new one and counts. Without\nthat key the clock would run at the speed of page loads and every physician\nwould be past the re-entry page before they had seen it twice.\n\nBest-effort by construction. This endpoint is how the portal learns who it is\ntalking to, and a counter that cannot write is not a reason to fail that.","operationId":"me_api_asclepius_auth_me_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/profile":{"get":{"tags":["asclepius"],"summary":"My Profile","description":"Everything the portal shows a physician about their own account.\n\nUntil now the only self-scoped write on this whole API was the tutorial\nstate, and there was no way for a doctor to see what we hold about them,\nlet alone correct a phone number. The credential fields come back\n``editable: false`` rather than being withheld: someone should be able to\nread what they submitted and see plainly which parts are settled.","operationId":"my_profile_api_asclepius_me_profile_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["asclepius"],"summary":"Update My Profile","description":"Correct the handful of fields that are the physician's own to correct.","operationId":"update_my_profile_api_asclepius_me_profile_patch","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/agreement":{"get":{"tags":["asclepius"],"summary":"My Agreement","description":"The agreement, in full, as text, plus what this physician has signed.\n\nFULL TEXT, not a link to a PDF, on the DLA's reasoning verbatim: a clickwrap\nthat requires downloading something to read it is a clickwrap whose \"I have\nread this\" is provably false.\n\nServed to every account, including one that has already signed and one that\nis not yet approved to work. Somebody is entitled to read the terms before\nthey answer anything, and to read them again afterwards.","operationId":"my_agreement_api_asclepius_me_agreement_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/agreement/sign":{"post":{"tags":["asclepius"],"summary":"Sign My Agreement","description":"Take one signature and file the record.\n\nThe order of operations is the DLA's, and it is deliberate: verify the\naffirmations and that the text has not changed underneath the signer, render\nand store the PDF so a row can never point at a document that does not\nexist, then INSERT the append-only row. A failure at the PDF step leaves\nnothing signed.\n\nSIGNING THE VERSION ALREADY SIGNED IS A 409, not an idempotent success. Two\nrows for one version is a question somebody has to answer later, and a\nphysician who clicked twice needs to know the first click worked. Signing a\nNEWER version is the normal path and writes a new row beside the old one.","operationId":"sign_my_agreement_api_asclepius_me_agreement_sign_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgreementSignRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/agreement/{agreement_id}.pdf":{"get":{"tags":["asclepius"],"summary":"My Agreement Pdf","description":"The executed copy, rendered from the version that was signed.\n\nNOT from ``CURRENT_VERSION``. The row names its own version and\n``pdf_from_row`` refuses to guess one, so shipping v2 can never rewrite a v1\nsigner's executed contract into a document they never saw. That is the\nsingle most important property of this endpoint.\n\nServe the hash-verified original. A profile-name change must never rewrite\nthe executed contract. Rebuild only when the stored blob is unavailable\nand the result matches the bytes filed at signature.","operationId":"my_agreement_pdf_api_asclepius_me_agreement__agreement_id__pdf_get","parameters":[{"name":"agreement_id","in":"path","required":true,"schema":{"type":"string","title":"Agreement Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/password":{"post":{"tags":["asclepius"],"summary":"Change My Password","description":"Change a password from inside the product.\n\nThe only route to this was the signed-out \"forgot password\" flow, which\nmeans a doctor who simply wanted a new password had to pretend they had\nlost the old one and go and find an email. The current password is\nrequired: a session left open on a ward computer should not be enough to\ntake the account.","operationId":"change_my_password_api_asclepius_me_password_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordChange"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/avatar":{"post":{"tags":["asclepius"],"summary":"Upload My Avatar","description":"A physician's own headshot.\n\nOn BROWSE like the rest of ``/me/*``, so somebody still awaiting\nverification can set one -- they are in the community from the day they\nsign up, and appearing there as two grey letters for a week is a poor\nwelcome.","operationId":"upload_my_avatar_api_asclepius_me_avatar_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_my_avatar_api_asclepius_me_avatar_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["asclepius"],"summary":"Delete My Avatar","operationId":"delete_my_avatar_api_asclepius_me_avatar_delete","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/users/{user_id}/avatar":{"get":{"tags":["asclepius"],"summary":"Get User Avatar","description":"Serve a physician's picture to any signed-in member of the product.\n\nNot self-scoped: the point of a profile picture is that colleagues see it\nbeside a message and an admin sees it while checking a registry entry. It\nis gated on being signed in at all, which is the same bar the display name\nit sits next to already clears.","operationId":"get_user_avatar_api_asclepius_users__user_id__avatar_get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/application":{"get":{"tags":["asclepius"],"summary":"My Application","description":"What this applicant still owes us, and what they may upload or correct.","operationId":"my_application_api_asclepius_me_application_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/documents/{kind}":{"post":{"tags":["asclepius"],"summary":"Upload My Document","description":"A pending applicant's CV, registration certificate or licence document.\n\nReceived, never verified: the item flips to complete only when an admin\nreviews the file. The bytes decide the stored type (``store_cv`` sniffs them\nand scrubs PDF metadata), the declared type is a UX gate only, and a\nreplaced blob is kept on disk with its sha in the event.","operationId":"upload_my_document_api_asclepius_me_documents__kind__post","parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","title":"Kind"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_my_document_api_asclepius_me_documents__kind__post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/credentials":{"patch":{"tags":["asclepius"],"summary":"Correct My Credentials","description":"Fix an identifier typed wrong at signup, then re-check it.\n\nOnly while pending, only the numbers a registry is asked about, and the\nverification that was about the old number is cleared with it. The recheck\nruns in the background through the same path the admin's Recheck uses.","operationId":"correct_my_credentials_api_asclepius_me_credentials_patch","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CredentialCorrection"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/tutorial":{"patch":{"tags":["asclepius"],"summary":"Update My Tutorial","description":"One transition on the caller's own first-run tutorial state.\n\nServer-authoritative: the \"the tutorial never re-triggers once finished\"\ninvariant lives in THESE rules, not in client flags. ``start`` after\ncompleted/skipped is a deliberate no-op (replay is a client-side affair and\nmust never clear completion); ``reset`` is allowed self-service because the\ntutorial writes no real data.","operationId":"update_my_tutorial_api_asclepius_me_tutorial_patch","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TutorialStateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/first-run":{"patch":{"tags":["asclepius"],"summary":"Update My First Run","description":"One transition on the caller's own first-login walkthrough.\n\nServer-authoritative and server-STORED (§6): doctors switch devices, and a\nchecklist in localStorage restarts on the phone. The rules that make a stop\npermanent live here, not in client flags.","operationId":"update_my_first_run_api_asclepius_me_first_run_patch","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FirstRunUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/bank-link/interest":{"post":{"tags":["asclepius"],"summary":"Register Bank Link Interest","description":"§6 stop 5 — \"we'll DM you the moment banking goes live\".\n\nThe card in the walkthrough is disabled and clearly labelled; this is the\nonly thing behind it, and it stores a status rather than pretending to link\nanything. The Stripe work lands on the payments track and reads this column\nto find who has been waiting.","operationId":"register_bank_link_interest_api_asclepius_me_bank_link_interest_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/bank-link/start":{"post":{"tags":["asclepius"],"summary":"Start Bank Link","description":"Begin (or resume) Stripe Connect Express onboarding for THIS physician.\n\nTwo different kinds of idempotency, and the difference is the whole design:\n\n* the ACCOUNT is created once, ever. A second account for the same\n  physician is a second place their bank details could live and a payout\n  destination that silently stops matching the one they onboarded.\n* the LINK is minted fresh on every call, because account links are\n  single-use and expire in minutes. Storing one would hand a physician a\n  dead URL and no way to ask for another.\n\nNothing about the bank account comes back through here. Stripe hosts the\nform; we get an id and a redirect.","operationId":"start_bank_link_api_asclepius_me_bank_link_start_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/bank-link":{"get":{"tags":["asclepius"],"summary":"Get Bank Link","description":"Where this physician's payouts stand, read live from Stripe.\n\n``payouts_enabled`` is fetched at the moment of the question and thrown\naway, never cached. A stored copy of compliance state is stale the instant\nStripe updates it, and the version of that bug that matters is the one where\nwe tell a physician they are good to be paid after Stripe has decided\notherwise.\n\nA Stripe read that fails degrades to the stored status rather than 500ing:\nthe physician's own earnings page should not go blank because an upstream\nAPI is slow. A MISCONFIGURED rail still raises, because that is an operator\nproblem and hiding it is how a dark rail stays dark unnoticed.","operationId":"get_bank_link_api_asclepius_me_bank_link_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/community/preview":{"get":{"tags":["asclepius"],"summary":"Community Preview","description":"A fixture rendered through the real community interface.\n\nAn applicant waiting on a decision should be able to see what they are\napplying to. They must not see the community itself: those rooms are worth\nreading precisely because everyone in them is credential-verified, and\nrejecting an application afterwards does not unread the messages. The\ncommunity's own gate refuses them and is untouched by this.\n\nServed ONLY to an account that cannot reach the real thing. An approved\nphysician asking for this gets 404 rather than a fixture, because handing\na colleague invented conversations while the real room sits one tab away\nis a way to make somebody doubt everything else on the screen.","operationId":"community_preview_api_asclepius_community_preview_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tutorial/task":{"get":{"tags":["asclepius"],"summary":"Get Tutorial Task","description":"The practice case, blinded EXACTLY like a real task (same\n``_blind_task`` path: ground_truth stripped, answer texts withheld).","operationId":"get_tutorial_task_api_asclepius_tutorial_task_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/exam/task":{"get":{"tags":["asclepius"],"summary":"Get Exam Task","description":"One synthetic case in the applicant's own specialty.\n\nBlinded through the SAME ``_blind_task`` path a paid case takes, so the\nworkspace they sit it in is the workspace they would work in, which is what\nmakes it worth reading.","operationId":"get_exam_task_api_asclepius_exam_task_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/exam/submit":{"post":{"tags":["asclepius"],"summary":"Submit Exam","description":"Store the examination and its admin-only evidence snapshot.\n\nThe physician receives a receipt, never the score or answer key.","operationId":"submit_exam_api_asclepius_exam_submit_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tutorial/reveal":{"post":{"tags":["asclepius"],"summary":"Tutorial Reveal","description":"Mirror of ``POST /tasks/{id}/reveal`` minus persistence: the same\nnon-empty-instinct gate (the tutorial teaches the real rule), but no\n``independent_commits`` row — the practice case leaves no data behind.","operationId":"tutorial_reveal_api_asclepius_tutorial_reveal_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TutorialIndependentAnswer"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tutorial/report":{"post":{"tags":["asclepius"],"summary":"Report Tutorial Case","operationId":"report_tutorial_case_api_asclepius_tutorial_report_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TutorialConcern"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tutorial/submit":{"post":{"tags":["asclepius"],"summary":"Tutorial Submit","description":"Grade the practice submission, and DECIDE whether it passed.\n\nThis is the pass decision, not just feedback. The practice case gates all\nreal work, so \"completed\" had to stop meaning \"clicked through\": before\nthis, a 0-of-4 stamped ``completed`` and that was the only thing between a\nnew physician and a paid case.\n\nNever touches the real submit pipeline: no ``submissions`` row, no\n``records``, no QA routing.","operationId":"tutorial_submit_api_asclepius_tutorial_submit_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/users":{"post":{"tags":["asclepius"],"summary":"Create User","operationId":"create_user_api_asclepius_users_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUserRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Users","operationId":"list_users_api_asclepius_users_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/users/{user_id}/real-data-approval":{"post":{"tags":["asclepius"],"summary":"Set Real Data Approval","description":"Grant/revoke V4 real-case access for a contributor (EHR PRD §9.5) — the\nBAA/training attestation lives outside the system; this flag records the\nadmin's decision. Serving enforces it on every /tasks/next.","operationId":"set_real_data_approval_api_asclepius_users__user_id__real_data_approval_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RealDataApprovalRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks":{"post":{"tags":["asclepius"],"summary":"Upload Tasks","operationId":"upload_tasks_api_asclepius_tasks_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskUploadRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Tasks","operationId":"list_tasks_api_asclepius_tasks_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/upload-file":{"post":{"tags":["asclepius"],"summary":"Upload Tasks File","description":"Accept a JSON (list or {tasks:[...]}) or CSV task batch (PRD §4.3, §6.1).","operationId":"upload_tasks_file_api_asclepius_tasks_upload_file_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_tasks_file_api_asclepius_tasks_upload_file_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/task-notifications/drain":{"post":{"tags":["asclepius"],"summary":"Drain Task Notifications","description":"Manual re-drain safety net (also handy for local QA): sends every\nstill-``pending`` outbox row. A crashed BackgroundTasks drain leaves rows\n``pending`` rather than losing them, so this recovers the tail.","operationId":"drain_task_notifications_api_asclepius_admin_task_notifications_drain_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/generate":{"post":{"tags":["asclepius"],"summary":"Generate Task","description":"Generate two candidate answers via the LLM and store them as a task.","operationId":"generate_task_api_asclepius_tasks_generate_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CandidateGenRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/load-v4-real-cases":{"post":{"tags":["asclepius"],"summary":"Load V4 Real Cases","description":"Load the three V4 REAL de-identified cases as ``partner_ehr`` tasks\n(V4 Cases & Promotion PRD §3).\n\nThe real-data sibling of ``/generation/{specialty}/load-gold``: no LLM needed\n(each case ships with its authored A/B preference pair), idempotent on a\nstable ``v4real-<case_id>`` task id.\n\n``holds`` in the response names any case the content gate is holding OUT of\nthe queue and why. A non-empty ``holds`` is the honest answer to \"did all\nthree ship?\" — read it rather than the ``loaded`` count.","operationId":"load_v4_real_cases_api_asclepius_generation_load_v4_real_cases_post","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Load only this specialty's V4 cases; omit for all.","title":"Specialty"},"description":"Load only this specialty's V4 cases; omit for all."},{"name":"max_labels","in":"query","required":false,"schema":{"type":"integer","maximum":10,"minimum":1,"description":"Independent labels per case. Default 3 (one labeller + two for Cohen's kappa). This is what we PAY for, it is not how many physicians can SEE the case.","default":3,"title":"Max Labels"},"description":"Independent labels per case. Default 3 (one labeller + two for Cohen's kappa). This is what we PAY for, it is not how many physicians can SEE the case."},{"name":"open_to_all_specialties","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Show these cases to every approved physician, bypassing specialty routing. VISIBILITY only, it does not change max_labels or what we pay. Omit to follow ASCLEPIUS_V4_OPEN_TO_ALL (default on), which is what the boot seeder uses; pass it explicitly to override for this call.","title":"Open To All Specialties"},"description":"Show these cases to every approved physician, bypassing specialty routing. VISIBILITY only, it does not change max_labels or what we pay. Omit to follow ASCLEPIUS_V4_OPEN_TO_ALL (default on), which is what the boot seeder uses; pass it explicitly to override for this call."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/{specialty}":{"post":{"tags":["asclepius"],"summary":"Generate Specialty Tasks","description":"Generate ``count`` validated tasks (prompt + 2 candidates) for a specialty.\n\nnephrology is the only enabled specialty in v1; any other returns 400. With\nno LLM configured, returns 503 (we never emit ungated synthetic tasks).","operationId":"generate_specialty_tasks_api_asclepius_generation__specialty__post","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/{specialty}/topup":{"post":{"tags":["asclepius"],"summary":"Topup Generation","description":"Continuous supply (PRD §B4): generate NOVEL V3 multimodal cases until the OPEN\n(unlabeled) pool for this specialty reaches ``target`` (default\n``ASCLEPIUS_TARGET_POOL_SIZE``). A no-op when the pool is already at/above target.\nRespects the same novelty + hardness + structure gates as ``/generation`` and\nreports the drop-reason counts so a shortfall ('why only 3?') is answerable.","operationId":"topup_generation_api_asclepius_generation__specialty__topup_post","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"target","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":500,"minimum":0},{"type":"null"}],"description":"Desired open V3 pool size; defaults to ASCLEPIUS_TARGET_POOL_SIZE.","title":"Target"},"description":"Desired open V3 pool size; defaults to ASCLEPIUS_TARGET_POOL_SIZE."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/{specialty}/load-gold":{"post":{"tags":["asclepius"],"summary":"Load Gold Specialty Cases","description":"Load the ratified GOLD multimodal cases for a specialty (Two-Model PRD\nWorkstream C — the \"load gold\" half of the load-vs-generate split).\n\nUnlike ``POST /generation/{specialty}`` (which synthesizes NOVEL cases via the\nLLM and needs a key), this inserts the hand-authored, clinician-ratified seed\ncases — real labs + EHR + an authored A/B pair — with NO LLM required. Idempotent\n(stable ``gold-<case_id>`` task ids are skipped if already present).","operationId":"load_gold_specialty_cases_api_asclepius_generation__specialty__load_gold_post","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/jobs":{"get":{"tags":["asclepius"],"summary":"List Generation Jobs","operationId":"list_generation_jobs_api_asclepius_generation_jobs_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/generation/seed-corpus":{"get":{"tags":["asclepius"],"summary":"Get Seed Corpus","operationId":"get_seed_corpus_api_asclepius_generation_seed_corpus_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"type":"string","default":"nephrology","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/specialties":{"get":{"tags":["asclepius"],"summary":"List Specialties","operationId":"list_specialties_api_asclepius_specialties_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assets/ingest":{"post":{"tags":["asclepius"],"summary":"Ingest Image Asset","description":"Ingest a PNG/JPEG/PDF and attach it as a StudyAsset to a V4 (real de-identified)\ncase's study (PRD §3). Enforces PNG/JPEG/PDF only (415), size/dim caps, PDF→raster,\nmetadata strip, content-addressed store + dedupe. The image BYTES go to the asset\nstore; only the reference is written to the case. Images NEVER enter V1/V2/V3.","operationId":"ingest_image_asset_api_asclepius_assets_ingest_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_ingest_image_asset_api_asclepius_assets_ingest_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assets/{asset_id}":{"get":{"tags":["asclepius"],"summary":"Get Asset","description":"Stream a cleaned image asset by id (PRD §4). Authenticated (evaluator/admin);\nthe served bytes carry no provider/model, no partner identity, and no residual\nmetadata (stripped at ingest). The store path is never exposed.","operationId":"get_asset_api_asclepius_assets__asset_id__get","parameters":[{"name":"asset_id","in":"path","required":true,"schema":{"type":"string","title":"Asset Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/next":{"get":{"tags":["asclepius"],"summary":"Next Task","operationId":"next_task_api_asclepius_tasks_next_get","parameters":[{"name":"portal_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Declare the active flow. 'v2' opts into value-aware routing (serves the highest expected value-per-minute task for you). Absent or 'v1' keeps the classic oldest-first queue unchanged.","title":"Portal Version"},"description":"Declare the active flow. 'v2' opts into value-aware routing (serves the highest expected value-per-minute task for you). Absent or 'v1' keeps the classic oldest-first queue unchanged."},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"The V3 specialty picker's choice (nephrology|cardiology|oncology). Drives which specialty's cases are served/generated; an unknown or disabled value falls back to the evaluator's own specialty.","title":"Specialty"},"description":"The V3 specialty picker's choice (nephrology|cardiology|oncology). Drives which specialty's cases are served/generated; an unknown or disabled value falls back to the evaluator's own specialty."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/available":{"get":{"tags":["asclepius"],"summary":"Available Tasks","description":"The tasks THIS evaluator can pick right now — the dashboard list.\n\nReuses the exact eligibility the router uses to serve the next case\n(``store.eligible_tasks_for_evaluator`` already drops tasks the evaluator has\nlabeled or that are at capacity), with the same hard/real filters, so the\ndashboard count matches what /tasks/next would hand out. Multimodal is only a\nserving PREFERENCE (V3 falls back to text), so it is NOT a hard filter here:\nthe list shows everything the evaluator may work on. Cards are lightweight\nmetadata only — the case content still loads through the existing task flow.","operationId":"available_tasks_api_asclepius_tasks_available_get","parameters":[{"name":"portal_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Active flow (v1/v2/v3/v4), same as /tasks/next.","title":"Portal Version"},"description":"Active flow (v1/v2/v3/v4), same as /tasks/next."},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Specialty picker choice; falls back to the evaluator's own.","title":"Specialty"},"description":"Specialty picker choice; falls back to the evaluator's own."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/real-case-access":{"get":{"tags":["asclepius"],"summary":"Real Case Access Report","description":"Why can (or cannot) this physician see the V4 real cases?\n\nEvery gate between an approved doctor and a real chart, evaluated for a named\naccount, with the reason spelled out. This exists because the question kept\nbeing answered by reading source: a physician reports an empty queue, and\n``real_data_approved`` is one flag, LABEL is another, specialty routing is a\nthird, and per-case capacity is a fourth — four different reasons for one\nidentical empty screen. An operator should be able to ask the product.","operationId":"real_case_access_report_api_asclepius_admin_real_case_access_get","parameters":[{"name":"email","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Check one physician by email; omit for a summary.","title":"Email"},"description":"Check one physician by email; omit for a summary."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/stats":{"get":{"tags":["asclepius"],"summary":"My Stats","description":"This evaluator's own real numbers for the dashboard tracking widget:\ntotal cases completed, how many in the last 7 days, and their last\nsubmission timestamp. Every ``submissions`` row is already a completed\ncase (drafts live client-side, never written here), so no status filter\nis needed.\n\nCounts, dates and a day streak, and that is a rule rather than a current\nlimitation.\nThis is the one work-history surface the physician themselves reads, so the\nmoment a field here derives from grading, agreement or the contributor\nscore it becomes the internal number wearing a chart. What somebody sees\nabout their own record is what they did, not how we rate it.","operationId":"my_stats_api_asclepius_me_stats_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}":{"get":{"tags":["asclepius"],"summary":"Get Task","operationId":"get_task_api_asclepius_tasks__task_id__get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/reveal":{"post":{"tags":["asclepius"],"summary":"Reveal Task Answers","description":"Commit the evaluator's blind independent answer and reveal the candidate\nanswers in one step (Eval Flow Upgrade §1, v2 anti-peeking). This is the ONLY\nway to obtain the answer texts under withholding: a non-empty independent\nanswer must be recorded server-side FIRST, so the answer was provably written\nbefore the AI answers were seen. The commit is the authoritative independent\nanswer used at packaging. Idempotent — the first commit's answer/timestamp win.","operationId":"reveal_task_answers_api_asclepius_tasks__task_id__reveal_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndependentAnswer"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/answers":{"get":{"tags":["asclepius"],"summary":"Get Task Answers","description":"Re-fetch the revealed candidate answer texts (Eval Flow Upgrade §1, v2 anti-\npeeking) — e.g. on a mid-task refresh resuming into the compare stage. GATED:\nreturns text only to an evaluator who has already committed an independent\nanswer (POST /tasks/{id}/reveal). Texts are still blinded (no generator_model).","operationId":"get_task_answers_api_asclepius_tasks__task_id__answers_get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/trajectory-outcome":{"get":{"tags":["asclepius"],"summary":"Trajectory Outcome","description":"Reveal encounter *k+1* — the answer key the chart itself wrote (§4 Phase 4).\n\nReturns what the record added AFTER this decision point, dated from the moment\nthe physician committed (\"day +12\"), together with the expectations they sealed,\nso they can mark which held. Their own falsifier is the rubric; no reviewer\ngrades this and no model does.\n\nWHAT THIS REVEALS, EXACTLY. The window runs from just after this decision point\nup to and including the NEXT decision point in the walk. That is the presenting\ndata of encounter *k+1* — the GGT back at 983 — and not its resolution, which\nbelongs to the point after. Said plainly here rather than described as \"the next\nencounter\", because a physician marking an expectation ``not_assessable`` needs\nto know whether the observation is genuinely absent from the record or merely\nbeyond this window.\n\nAlso honest about what it is NOT: what happened next reflects the treatment\nactually given, not the plan this physician proposed. Where they proposed\nsomething different, this does not test their plan — it tests the one that was\nfollowed (§6). The self-score therefore asks about ANTICIPATION of the observed\ncourse, never about counterfactual outcomes.","operationId":"trajectory_outcome_api_asclepius_tasks__task_id__trajectory_outcome_get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/trajectory-self-score":{"post":{"tags":["asclepius"],"summary":"Trajectory Self Score","description":"Record which of the physician's own expectations held (§4 Phase 4).\n\nThis is the third signal — the one that is automatic and free of human grading,\nand therefore the one that scales past the constraint the whole business runs\ninto: subspecialist hours. It is written from the physician's own submission\nand graded against their own stated falsifier.\n\nMarks are bounded by the prediction they grade: a mark pointing past the\ncommitted expectations is dropped, because a self-score that does not line up\nwith the commitment it scores is not evidence of anything. A physician with no\nstored prediction cannot self-score at all — there would be nothing to grade.","operationId":"trajectory_self_score_api_asclepius_tasks__task_id__trajectory_self_score_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrajectorySelfScore"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/trajectories/{trajectory_id}":{"get":{"tags":["asclepius"],"summary":"Get Trajectory","description":"This evaluator's walk through one chart (§4 Phase 5 — trajectory mode).\n\nThe session view: how many decision points this chart carries, how far this\nphysician has come, and which point they may open next. Per-evaluator on\npurpose — two physicians walking the same chart are two independent\ntrajectories that happen to share a case set, and a shared \"7 of 13\" would be a\nlie to both of them.\n\nReturns METADATA ONLY. No case content, no prompts, no outcomes: the sequence\ngate exists precisely so a physician cannot read ahead, and a session view that\nrendered every point's chart would be that leak wearing a progress bar. Each\npoint is opened through the ordinary by-ID path, which re-checks the gate.","operationId":"get_trajectory_api_asclepius_trajectories__trajectory_id__get","parameters":[{"name":"trajectory_id","in":"path","required":true,"schema":{"type":"string","title":"Trajectory Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/submissions":{"post":{"tags":["asclepius"],"summary":"Submit","operationId":"submit_api_asclepius_submissions_post","parameters":[{"name":"async_pipeline","in":"query","required":false,"schema":{"type":"boolean","description":"Real submit progress (BUG-5): when true, return 202 + submission_id immediately and run the pipeline as a background job; poll GET /submissions/{id}/status for backend-stamped phases. Default false keeps the synchronous 200 + result behavior.","default":false,"title":"Async Pipeline"},"description":"Real submit progress (BUG-5): when true, return 202 + submission_id immediately and run the pipeline as a background job; poll GET /submissions/{id}/status for backend-stamped phases. Default false keeps the synchronous 200 + result behavior."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Submissions","operationId":"list_submissions_api_asclepius_submissions_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/submissions/{submission_id}/status":{"get":{"tags":["asclepius"],"summary":"Submission Status","description":"Real submit progress (BUG-5): the phase + pct the backend STAMPED as each\npipeline stage actually started — never an invented percentage. Pollable by\nthe submitting evaluator (or admin/QA). Returns ``done=true`` once the row\nreaches a terminal status, with the final status + issues so the client can\ntake the existing success / needs-QA path.","operationId":"submission_status_api_asclepius_submissions__submission_id__status_get","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/baselines":{"post":{"tags":["asclepius"],"summary":"Run Task Baselines","description":"Answer this task's rendered case COLD with each configured frontier model\n(ASCLEPIUS_BASELINE_MODELS) and store the verbatim responses (FEAT-1). The\non-policy artifact that proves the case is hard.","operationId":"run_task_baselines_api_asclepius_tasks__task_id__baselines_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Task Baselines","operationId":"list_task_baselines_api_asclepius_tasks__task_id__baselines_get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/tasks/{task_id}/grade-real-models":{"post":{"tags":["asclepius"],"summary":"Grade Real Models","description":"\"Grade the real models\" mode (FEAT-1 / PRD §A): swap the task's A/B pair to two\nreal frontier answers (blinded, source='baseline', truly-random slots) via the\nassembly ladder (§A3 + §A7):\n\n  * two-frontier (one OpenAI + one Anthropic) is the strong default;\n  * on a genuine single-provider failure it reverts to the OLD Anthropic-only\n    method so annotation continues (tagged ``legacy_fallback``, counted);\n  * a sustained high fallback rate is treated as an incident → ``503 needs_baseline``\n    + admin alert, never mostly-legacy data shipped silently;\n  * V4 real cases stay Anthropic-only unless ``ASCLEPIUS_TWO_FRONTIER_V4`` is on (§A7);\n  * NEVER a gold stand-in for a failed model answer.\n\nOn submission a per-model failure record is computed.","operationId":"grade_real_models_api_asclepius_tasks__task_id__grade_real_models_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/baselines/model-failures":{"get":{"tags":["asclepius"],"summary":"Model Failures","description":"The Model-Failure artifact (FEAT-1): \"cases where model X failed, with the\nexpert correction\", filterable by model + error tag. This is what you put in\nfront of a lab.","operationId":"model_failures_api_asclepius_baselines_model_failures_get","parameters":[{"name":"model","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"}},{"name":"error_tag","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Tag"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/reasoning/split":{"post":{"tags":["asclepius"],"summary":"Reasoning Split","description":"Split a chosen/ideal answer into ordered reasoning steps for tap-to-grade\n(Eval Flow Upgrade §4). Returns ``{steps: [str, ...], source}``. Degrades to a\nlocal heuristic split when no LLM is configured (never errors the doctor).","operationId":"reasoning_split_api_asclepius_reasoning_split_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasoningSplitRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/reasoning/pregrade":{"post":{"tags":["asclepius"],"summary":"Reasoning Pregrade","description":"Split + pre-grade an answer's reasoning steps (Speed Optimization §2):\neach step arrives with a SUGGESTED ``good``/``bad`` label (+ a one-line\ncritique on bad steps) so the doctor verifies instead of authoring. The\nlabels are suggestions only — every step still requires an explicit human\nconfirm/correct before submit. Degrades to the heuristic splitter with\n``suggested_label = null`` when no LLM is configured.","operationId":"reasoning_pregrade_api_asclepius_reasoning_pregrade_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasoningSplitRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/rubric/suggest":{"post":{"tags":["asclepius"],"summary":"Rubric Suggest","description":"Auto-seed proposed rubric criteria from the doctor's already-captured tags\n(FEAT-2). The client sends the in-progress draft (error tags + reasons,\nwhy-better tags, graded/corrected steps); we return pre-filled, editable\n``{text, points, axis, source}`` chips. NOTHING is applied — the doctor\nconfirms/edits/deletes before the rubric ships (same anti-rubber-stamp rule as\neverywhere else). Post-reveal + on the doctor's own tags, so no anti-peeking\ngate; the answer key stays server-side.","operationId":"rubric_suggest_api_asclepius_rubric_suggest_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmissionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assist/prelabel":{"post":{"tags":["asclepius"],"summary":"Assist Prelabel","description":"Suggest the weaker answer + error tags + a draft rationale for a task the\nevaluator is grading — VERIFY, don't author. Guardrails:\n\n  * Anti-peeking: gated behind the evaluator's independent-answer commit\n    (like ``GET /tasks/{id}/answers``) — the suggestion describes the A/B\n    answers, so it must not exist pre-reveal.\n  * Never applied server-side: the verdict/tags/rationale stay untouched;\n    the client renders the suggestion as a tap-to-accept hint only.\n  * Low-confidence suggestions (< ASCLEPIUS_ASSIST_MIN_CONF, default 0.6)\n    are HIDDEN — returned as ``skipped`` so the UI never nudges on an\n    uncertain call.\n  * Degrades to ``skipped=True`` with no LLM key — manual labeling always\n    works.\n\nThe access gate is resolved IN THE BODY rather than through ``Depends``,\nbecause the task id arrives in the payload and a path-parameter dependency\ncannot see it. Same rule as ``require_task_access``, same two branches — an\napplicant on their own examination, or the full chain for everybody else.","operationId":"assist_prelabel_api_asclepius_assist_prelabel_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PrelabelRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/assist/cite":{"post":{"tags":["asclepius"],"summary":"Assist Cite","description":"Auto-suggest the 1–3 most relevant library citations for a rationale or\nreasoning step so grounding a record is a one-click *confirm* (WS3 — the\nbiggest ratio lever: more grounded/premium records at less time).\n\nGuardrails: the doctor MUST confirm — nothing is auto-attached; the suggestion\nis a starting point. Retrieval is deterministic (always works); an optional\nLLM rerank refines ordering. Degrades to ``skipped=True`` when the specialty\nhas no citation library (the doctor types a citation as before). No\nanti-peeking gate: citing happens post-reveal on the doctor's OWN text.\n\nTUTORIAL rather than full access, for the same reason and on the same\nevidence as ``/citations/search`` (PRD A §2.1). This one was MISSED when\nthat change was made: §2.0 listed the endpoints the examination workspace\ncalls and this was not on the list, so an applicant sitting the examination\ngot a 403 on every automatic citation suggestion. The client swallows the\nerror, so nothing visibly broke — the one-click citation chips were simply\ndead for the only population the examination exists for, which is what §2.3\nmeans by \"cite a guideline ... zero 403s\". Same reasoning as the search box:\nthe library is published guidance, keyed by specialty, and nothing\npatient-specific is reachable through it.","operationId":"assist_cite_api_asclepius_assist_cite_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CiteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/citations/search":{"post":{"tags":["asclepius"],"summary":"Citations Search","description":"The explicit \"Search the library\" box (BUG-3c escape hatch): the doctor\ntyped a query on purpose, so this is more permissive than the auto-suggest —\nany token overlap matches, ranked by relevance. A blank query returns the\nlibrary head so the box is never a dead end. ``skipped`` when the specialty\nhas no library. Never gated on the independent commit (the doctor is grounding\ntheir OWN text, post-reveal), like ``/assist/cite``.\n\nTUTORIAL rather than full access (PRD A §2.1): an applicant sitting the\ncredentialing examination has to be able to cite, and \"Search the library\"\nis the box they do it in. Nothing patient-specific is reachable through it —\nthe library is published guidance, keyed by specialty — so it is a\nsurface-level permission rather than a task-scoped carve-out. It admits\nadvisors too, who already hold TUTORIAL and already click through the whole\npractice case; the same reasoning covers both.","operationId":"citations_search_api_asclepius_citations_search_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CiteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/transcribe":{"post":{"tags":["asclepius"],"summary":"Transcribe Audio","description":"Transcribe a short dictation clip from the in-app mic. Provider-abstracted\n(``ASCLEPIUS_STT_PROVIDER``: ``standard`` = Deepgram/Whisper, ``wispr`` stub).\nAudio is EPHEMERAL — held in memory for this request only, never persisted\n(synthetic prompts, no PHI; TLS in transit). 503 when no provider is\nconfigured so the mic button can degrade to typing.\n\nTUTORIAL rather than full access (PRD A §2.1): dictation is a UI convenience\nover the user's own microphone, not access to any of our data, and an\napplicant taking the examination is offered the same mic button everyone\nelse is.","operationId":"transcribe_audio_api_asclepius_transcribe_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_transcribe_audio_api_asclepius_transcribe_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/submissions/{submission_id}":{"get":{"tags":["asclepius"],"summary":"Get Submission","operationId":"get_submission_api_asclepius_submissions__submission_id__get","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/qa/queue":{"get":{"tags":["asclepius"],"summary":"Qa Queue","operationId":"qa_queue_api_asclepius_qa_queue_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/qa/approve-all":{"post":{"tags":["asclepius"],"summary":"Qa Approve All","description":"Approve every submission currently held in QA in one step, moving them all\nto ``export_ready``. Lets a solo admin clear the QA backlog and export\nimmediately. Each approval is logged with the reviewer for the audit trail.","operationId":"qa_approve_all_api_asclepius_qa_approve_all_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/qa/{submission_id}/decision":{"post":{"tags":["asclepius"],"summary":"Qa Decision","operationId":"qa_decision_api_asclepius_qa__submission_id__decision_post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QADecisionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/exports":{"post":{"tags":["asclepius"],"summary":"Create Export","operationId":"create_export_api_asclepius_exports_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/asclepius__schemas__ExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Exports","operationId":"list_exports_api_asclepius_exports_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/profiles":{"get":{"tags":["asclepius"],"summary":"List Export Profiles","operationId":"list_export_profiles_api_asclepius_profiles_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/exports/{export_id}/download":{"get":{"tags":["asclepius"],"summary":"Download Export","operationId":"download_export_api_asclepius_exports__export_id__download_get","parameters":[{"name":"export_id","in":"path","required":true,"schema":{"type":"string","title":"Export Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/organizations":{"get":{"tags":["asclepius"],"summary":"List Organizations","description":"All contributors grouped by organization (spec §3 — \"listed by organization\nname, then I click into it\").","operationId":"list_organizations_api_asclepius_organizations_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors":{"get":{"tags":["asclepius"],"summary":"List Contributors","description":"Every contributor (optionally within one organization): internal display\nname, hashed id, primary specialty, # records labeled, verified status.","operationId":"list_contributors_api_asclepius_contributors_get","parameters":[{"name":"organization","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}":{"get":{"tags":["asclepius"],"summary":"Get Contributor","description":"A contributor's profile: the generalized blurb + a credential summary. Tier\nB values are masked unless ``include_verify=true`` (admin edit path); the\naudited release path is the Further Credential Summary dossier.","operationId":"get_contributor_api_asclepius_contributors__id_hashed__get","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"include_verify","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Verify"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["asclepius"],"summary":"Upsert Contributor","description":"Create/update a contributor's credential profile (Tier A ship + Tier B\nvault). The contributor (user) must already exist.","operationId":"upsert_contributor_api_asclepius_contributors__id_hashed__put","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContributorCredentialsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}/submissions":{"get":{"tags":["asclepius"],"summary":"List Contributor Submissions","description":"Every task this contributor completed, newest first — with the completion\ntime (rendered Pacific client-side) and the product version they labelled\nwith. Powers the per-task / per-day / per-week export controls.","operationId":"list_contributor_submissions_api_asclepius_contributors__id_hashed__submissions_get","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}/export":{"post":{"tags":["asclepius"],"summary":"Export Contributor Data","description":"Button 1 — \"Export Data\": all export-ready records labeled by THIS\ncontributor, Tier A only. The Tier B leak gate guards the batch.","operationId":"export_contributor_data_api_asclepius_contributors__id_hashed__export_post","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScopedExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/organizations/{organization}/export":{"post":{"tags":["asclepius"],"summary":"Export Organization Data","description":"Export all Tier A data labeled by every contributor in an organization\n(spec §3 — \"within the organization name: export all the data that\norganization labelled\").","operationId":"export_organization_data_api_asclepius_organizations__organization__export_post","parameters":[{"name":"organization","in":"path","required":true,"schema":{"type":"string","title":"Organization"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScopedExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}/credential-summary":{"post":{"tags":["asclepius"],"summary":"Create Credential Summary","description":"Button 2 — \"Further Credential Summary\": generate a verification dossier\n(PDF + JSON) containing Tier B + Tier A + verification handles, watermarked\nconfidential, with the §9 notice prepended. Requires a click-through\nacknowledgment and is logged for audit (spec §6).","operationId":"create_credential_summary_api_asclepius_contributors__id_hashed__credential_summary_post","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CredentialSummaryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}/credential-summaries":{"get":{"tags":["asclepius"],"summary":"List Credential Summaries","description":"The audit trail of credential summaries generated for this contributor.","operationId":"list_credential_summaries_api_asclepius_contributors__id_hashed__credential_summaries_get","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/contributors/{id_hashed}/credential-summary/{summary_id}/download":{"get":{"tags":["asclepius"],"summary":"Download Credential Summary","operationId":"download_credential_summary_api_asclepius_contributors__id_hashed__credential_summary__summary_id__download_get","parameters":[{"name":"id_hashed","in":"path","required":true,"schema":{"type":"string","title":"Id Hashed"}},{"name":"summary_id","in":"path","required":true,"schema":{"type":"string","title":"Summary Id"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"pdf","title":"Format"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/metrics/organizations":{"get":{"tags":["asclepius"],"summary":"Metrics Organizations","operationId":"metrics_organizations_api_asclepius_metrics_organizations_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/metrics/contributors":{"get":{"tags":["asclepius"],"summary":"Metrics Contributors","operationId":"metrics_contributors_api_asclepius_metrics_contributors_get","parameters":[{"name":"organization","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/metrics/value-per-time":{"get":{"tags":["asclepius"],"summary":"Metrics Value Per Time","description":"Value-per-clinician-minute — the north-star metric (Value-per-Minute PRD\nA4). Median REALIZED and PROJECTED V/T, split by product version (v1 vs v2),\ndifficulty, grounded vs plain, Mode A vs B, and per contributor.\n\nThe team is held to REALIZED V/T ≥ the target; projected (× reuse) is the\nfuller economics but a forecast. Reported next to κ + the assist override\nrate so a rising ratio with falling quality reads as the regression it is.","operationId":"metrics_value_per_time_api_asclepius_metrics_value_per_time_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/credential-policy":{"get":{"tags":["asclepius"],"summary":"Credential Policy","description":"The tiering policy + the §9 notice text, for the UI (ack modal, tier hints).","operationId":"credential_policy_api_asclepius_credential_policy_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/debug/mm-generate":{"get":{"tags":["asclepius"],"summary":"Debug Mm Generate","description":"Diagnostic: run the REAL multimodal generation pipeline once and report what\nhappened — the accepted count and the exact per-reason DROP breakdown — so an\noperator can see precisely why V3 is (or isn't) getting structured cases instead\nof guessing. Synthetic data only (no PHI), so it is available to any signed-in\nevaluator. Accepted cases are inserted into the queue (this doubles as a manual\n'force a case' button).","operationId":"debug_mm_generate_api_asclepius_debug_mm_generate_get","parameters":[{"name":"n","in":"query","required":false,"schema":{"type":"integer","maximum":3,"minimum":1,"default":1,"title":"N"}},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/debug/load-gold-cases":{"get":{"tags":["asclepius"],"summary":"Debug Load Gold Cases","description":"Load the 10 ratified GOLD nephrology multimodal cases into the queue as\nready-to-serve V3 tasks (real labs + EHR + an authored A/B pair, NO LLM needed).\nIdempotent. Any signed-in evaluator can call it (synthetic data only) so V3 can be\npopulated on demand — independent of the ANTHROPIC_API_KEY state.","operationId":"debug_load_gold_cases_api_asclepius_debug_load_gold_cases_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/stats":{"get":{"tags":["asclepius"],"summary":"Stats","operationId":"stats_api_asclepius_stats_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/events":{"get":{"tags":["asclepius"],"summary":"Events","operationId":"events_api_asclepius_events_get","parameters":[{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/upload-links":{"post":{"tags":["asclepius"],"summary":"Mint Upload Link","description":"Mint a single-purpose, expiring partner upload link (PRD §4). The raw\ntoken is returned ONCE here and never stored (SHA-256 at rest).","operationId":"mint_upload_link_api_asclepius_admin_upload_links_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadLinkRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius"],"summary":"List Upload Links","operationId":"list_upload_links_api_asclepius_admin_upload_links_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/upload-links/{link_id}/revoke":{"post":{"tags":["asclepius"],"summary":"Revoke Upload Link","operationId":"revoke_upload_link_api_asclepius_admin_upload_links__link_id__revoke_post","parameters":[{"name":"link_id","in":"path","required":true,"schema":{"type":"string","title":"Link Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/partner/uploads":{"post":{"tags":["asclepius"],"summary":"Partner Upload","description":"The partner's one capability (PRD §4): POST a .zip through their token.\nCaps + magic-byte check + SHA-256 + encrypted quarantine write happen inline;\nunpack/parse/verify run in the background (never in the request path).","operationId":"partner_upload_api_asclepius_partner_uploads_post","parameters":[{"name":"t","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"upload link token","title":"T"},"description":"upload link token"}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_partner_upload_api_asclepius_partner_uploads_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/partner/uploads/{upload_id}":{"get":{"tags":["asclepius"],"summary":"Partner Upload Status","description":"The partner polls their OWN upload's status through the same token —\naccepted / quarantined + a human-readable reason. No other data is exposed.","operationId":"partner_upload_status_api_asclepius_partner_uploads__upload_id__get","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"t","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"T"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads":{"get":{"tags":["asclepius"],"summary":"List Ingestion Uploads","description":"Paginated over FULL history (newest first). Returns the page plus the\ngrand total so the admin UI can page through every upload ever received.\n\n``status`` (Audit PRD §21.5) narrows to one state — ``needs_review`` surfaces\nthe admin review queue. ``counts`` always carries the per-status totals so the\nfilter chips render real numbers regardless of the active filter.","operationId":"list_ingestion_uploads_api_asclepius_ingestion_uploads_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/download":{"get":{"tags":["asclepius"],"summary":"Download Ingestion Upload","description":"Admin download of the ORIGINAL partner-uploaded bundle (decrypted at rest).\nAvailable until the raw blob is purged (ASCLEPIUS_RAW_RETENTION_DAYS).","operationId":"download_ingestion_upload_api_asclepius_ingestion_uploads__upload_id__download_get","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/notify-sender":{"post":{"tags":["asclepius"],"summary":"Notify Upload Sender","description":"Manually email the partner that their upload didn't come through (no PHI,\n'nothing was leaked / no breach, please re-send'). Complements the automatic\nnotification on rejected/lost uploads; use it for anything you want to flag.","operationId":"notify_upload_sender_api_asclepius_ingestion_uploads__upload_id__notify_sender_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}":{"get":{"tags":["asclepius"],"summary":"Get Ingestion Upload","operationId":"get_ingestion_upload_api_asclepius_ingestion_uploads__upload_id__get","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/reconcile":{"post":{"tags":["asclepius"],"summary":"Run Ingestion Reconcile","description":"Run terminal-state reconciliation on demand (Audit §9.3): re-bind unbound sealed\nkeys and hold cases with missing/corrupt asset blobs. Also runs at startup and can\nbe scheduled nightly. Returns the counts the admin ingestion card surfaces.","operationId":"run_ingestion_reconcile_api_asclepius_ingestion_reconcile_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/review":{"get":{"tags":["asclepius"],"summary":"Get Upload Review","description":"The admin review queue for one upload (Audit PRD §21.5): every case that\nraised a review reason, with its reasons split blocking-first so the UI renders\nthe PHI hold above the advisory note. A case with no reasons is omitted.","operationId":"get_upload_review_api_asclepius_ingestion_uploads__upload_id__review_get","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases/{ingest_case_id}/review/clear":{"post":{"tags":["asclepius"],"summary":"Clear Case Review","description":"Clear a case's blocking review reasons (Audit PRD §21.5). A note is\nmandatory (the schema enforces presence; we reject whitespace-only here) and the\naction stamps ``reviewed_by_hashed`` + ``reviewed_at``. Clearing all blocking\nreasons flips the case back to ``ingested`` so it re-enters the annotation queue;\nadvisory reasons are retained on the record but never held the case.","operationId":"clear_case_review_api_asclepius_ingestion_cases__ingest_case_id__review_clear_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewClearRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases/{ingest_case_id}/review/reject":{"post":{"tags":["asclepius"],"summary":"Reject Case Review","description":"Reject a case awaiting review (Audit PRD §21.5) — the reviewer found the flag\nis real (e.g. the image does carry burned-in PHI). The case is quarantined, never\nserved for annotation, and the action is attributable.","operationId":"reject_case_review_api_asclepius_ingestion_cases__ingest_case_id__review_reject_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/retry":{"post":{"tags":["asclepius"],"summary":"Retry Ingestion Upload","description":"Re-run the pipeline (e.g. after loosening a knob or fixing an adapter).\nOnly the raw blob is reused; prior case rows for the upload stay for audit.","operationId":"retry_ingestion_upload_api_asclepius_ingestion_uploads__upload_id__retry_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/quarantine":{"get":{"tags":["asclepius"],"summary":"List Quarantine","description":"Quarantined cases with MASKED findings (a suspected identifier is never\nrendered in cleartext — PRD §8).","operationId":"list_quarantine_api_asclepius_ingestion_quarantine_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/quarantine/{ingest_case_id}/reject":{"post":{"tags":["asclepius"],"summary":"Quarantine Reject","operationId":"quarantine_reject_api_asclepius_ingestion_quarantine__ingest_case_id__reject_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/quarantine/{ingest_case_id}/scrub":{"post":{"tags":["asclepius"],"summary":"Quarantine Scrub","description":"Targeted scrub (PRD §8): redact EXACTLY the flagged spans and re-run the\nverification + hard guard. An explicit, logged human action — never automatic.","operationId":"quarantine_scrub_api_asclepius_ingestion_quarantine__ingest_case_id__scrub_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/quarantine/{ingest_case_id}/override":{"post":{"tags":["asclepius"],"summary":"Quarantine Override","description":"Documented admin override of VERIFIER findings (e.g. a false positive on a\nlab value shaped like a phone number). The ``deidentify()`` HARD guard still\nruns and cannot be overridden — if it rejects, the override fails.","operationId":"quarantine_override_api_asclepius_ingestion_quarantine__ingest_case_id__override_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuarantineOverrideRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases":{"get":{"tags":["asclepius"],"summary":"List Ingestion Cases","description":"``upload_id`` scopes the list to one partner file — what the admin's\nper-upload \"Preview cases\" control needs, so it does not pull every ingest\ncase in the system to find the two it is about to plan.","operationId":"list_ingestion_cases_api_asclepius_ingestion_cases_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"upload_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases/{ingest_case_id}/promote":{"post":{"tags":["asclepius"],"summary":"Promote Ingest Case","description":"Ingested case → gradable V4 task (PRD §9): attach the clinical question,\nrender the case prompt, generate candidates CONDITIONED ON THE REAL CASE,\ngate (hardness + real-variant case judge — no ground-truth dimension: the\nspecialist is the answer key), insert as a partner_ehr task. Needs an LLM.\n\n``?dry_run=true`` (or ``{\"dry_run\": true}``) runs every gate and returns the\nsample WITHOUT committing anything — see the block below. The query parameter\nexists because this is a thing you reach for from a terminal mid-debug, and\nit only ever turns the dry run ON: a query string cannot force a commit that\nthe body asked to be a dry run.","operationId":"promote_ingest_case_api_asclepius_ingestion_cases__ingest_case_id__promote_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"dry_run","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Dry Run"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromoteCaseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/prepare":{"post":{"tags":["asclepius"],"summary":"Prepare Upload Promotion","description":"Step 1 of the upload-scoped promote: run the conversion + automated tests\non ONE sample case from this partner file and return it for review (labs,\nnotes, EHR records, candidates, test scores) WITHOUT committing anything. The\nadmin reviews, then calls /promote-all to extend case creation to the rest.","operationId":"prepare_upload_promotion_api_asclepius_ingestion_uploads__upload_id__prepare_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadPromoteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/uploads/{upload_id}/promote-all":{"post":{"tags":["asclepius"],"summary":"Promote Upload All","description":"Step 2 of the upload-scoped promote: after the admin approved the sample,\nextend case creation to EVERY remaining ingested case in this partner file.\nEach case runs the same conversion + gate; passing cases become V4 tasks,\ngated/failed cases stay 'ingested' with the reason recorded.","operationId":"promote_upload_all_api_asclepius_ingestion_uploads__upload_id__promote_all_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadPromoteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases/{ingest_case_id}/generation-jobs/{job_id}":{"get":{"tags":["asclepius"],"summary":"Real Case Generation Status","operationId":"real_case_generation_status_api_asclepius_ingestion_cases__ingest_case_id__generation_jobs__job_id__get","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ingestion/cases/{ingest_case_id}/generate":{"post":{"tags":["asclepius"],"summary":"Generate Real Cases","operationId":"generate_real_cases_api_asclepius_ingestion_cases__ingest_case_id__generate_post","parameters":[{"name":"ingest_case_id","in":"path","required":true,"schema":{"type":"string","title":"Ingest Case Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateRealCasesRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/data-providers":{"post":{"tags":["asclepius-provider"],"summary":"Invite Data Provider","description":"Create a data_partner account + temporary password, and email the provider\nthe portal link + credentials. Idempotent (existing provider → rotate + re-\ninvite). 503 if email isn't configured — we never create the account without\nbeing able to tell the provider.","operationId":"invite_data_provider_api_asclepius_admin_data_providers_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataProviderInviteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius-provider"],"summary":"List Data Providers","operationId":"list_data_providers_api_asclepius_admin_data_providers_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/data-providers/{provider_id}/resend":{"post":{"tags":["asclepius-provider"],"summary":"Resend Data Provider Invite","operationId":"resend_data_provider_invite_api_asclepius_admin_data_providers__provider_id__resend_post","parameters":[{"name":"provider_id","in":"path","required":true,"schema":{"type":"string","title":"Provider Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/data-providers/{provider_id}/revoke":{"post":{"tags":["asclepius-provider"],"summary":"Revoke Data Provider","operationId":"revoke_data_provider_api_asclepius_admin_data_providers__provider_id__revoke_post","parameters":[{"name":"provider_id","in":"path","required":true,"schema":{"type":"string","title":"Provider Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/provider/me":{"get":{"tags":["asclepius-provider"],"summary":"Provider Me","operationId":"provider_me_api_asclepius_provider_me_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/provider/password":{"post":{"tags":["asclepius-provider"],"summary":"Provider Password","description":"Forced first-login reset (and normal change). On the FORCED first reset the\nBearer token is proof of identity (the temp password was consumed at login),\nso ``current_password`` may be blank; a NORMAL change requires it.","operationId":"provider_password_api_asclepius_provider_password_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderPasswordRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/provider/uploads":{"post":{"tags":["asclepius-provider"],"summary":"Provider Upload","description":"Accept the provider's file(s), bundle to a zip, and hand off to the SHARED\ningestion pipeline (unpack/parse/verify run in the BACKGROUND, never in the\nrequest path — PRD §4). Returns a receipt; the portal polls GET /provider/\nuploads for the real per-file outcome.","operationId":"provider_upload_api_asclepius_provider_uploads_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_provider_upload_api_asclepius_provider_uploads_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius-provider"],"summary":"Provider Uploads","description":"The provider's OWN uploads + status (mapped to plain-English states). Scoped\nto this provider by partner_id — never another provider's data.","operationId":"provider_uploads_api_asclepius_provider_uploads_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/login":{"post":{"tags":["asclepius-provider"],"summary":"Hs Login","description":"Sign in with the emailed username + password.\n\nONE code path for existing and non-existing usernames. Every observable —\nstatus code, message, Retry-After, and the progressive delay — is produced\nby the same statements regardless of whether the account is real, so the\nresponse cannot be used to enumerate which hospitals are partners. Usernames\nhere are derived deterministically from the organization name, which is what\nmade the old 5th-attempt 429/401 split a partnership-disclosure leak.\n\nThe hard lock is scoped to (username, ip): five wrong guesses stop THAT\ncaller, not the hospital. A username-only lock let anyone who could guess\n`massgeneral` hold Mass General out of its own portal indefinitely.","operationId":"hs_login_api_asclepius_hs_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsLoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/logout":{"post":{"tags":["asclepius-provider"],"summary":"Hs Logout","description":"Sign out for real. The cookie is cleared AND the token's jti is denylisted\nuntil it would have expired — on a shared hospital workstation a cookie the\nbrowser already handed out has to stop working, not just stop being sent.","operationId":"hs_logout_api_asclepius_hs_logout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/me":{"get":{"tags":["asclepius-provider"],"summary":"Hs Me","operationId":"hs_me_api_asclepius_hs_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/password":{"post":{"tags":["asclepius-provider"],"summary":"Hs Password","description":"Forced first-login reset (and normal change). On the FORCED reset the\nsession cookie is proof of identity (the temp passphrase was consumed at\nlogin); a NORMAL change requires the current password.\n\nChanging the password invalidates every session issued against the old one\n(the ``se`` epoch claim), so this re-issues the caller's own cookie — otherwise\nthe user would be signed out by their own password change.","operationId":"hs_password_api_asclepius_hs_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsPasswordRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/uploads":{"get":{"tags":["asclepius-provider"],"summary":"Hs Uploads","description":"This health system's uploads — date, filename, size, and one of four\nplain-language states: received · processing · accepted · needs_attention.\n\nGated on the UPLOAD surface, like every door that writes one. A pending\naccount used to be handed a 200 and an empty list here, which reads as \"you\nhave sent us nothing\" when the truth is \"you may not use this yet\", and it\nwas the one upload surface that answered differently from its four siblings.","operationId":"hs_uploads_api_asclepius_hs_uploads_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["asclepius-provider"],"summary":"Hs Upload","description":"Accept the health system's file(s) — a .zip or bare .json/.csv/.hl7/.txt —\nbundle via the SHARED ``wrap_loose_files`` packer, and hand off to the shared\ningestion pipeline. The upload is stamped with the health_system_id so it\nappears under that system in the admin. Specialty is NOT collected here — it\nis a property of the data, determined at ingest.\n\n``request_id`` is optional and names the data request this answers, when it\nanswers one.","operationId":"hs_upload_api_asclepius_hs_uploads_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_hs_upload_api_asclepius_hs_uploads_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/uploads/sessions":{"post":{"tags":["asclepius-provider"],"summary":"Hs Upload Declare","description":"Declare a bundle and receive its chunk plan.\n\nIdempotent on the declared bytes: re-declaring the same ``{sha256, size}``\nreturns the EXISTING session, so a refresh at 3.2 GB resumes instead of\nrestarting. The session id IS the idempotency key.","operationId":"hs_upload_declare_api_asclepius_hs_uploads_sessions_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsUploadDeclareRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/uploads/sessions/{session_id}":{"get":{"tags":["asclepius-provider"],"summary":"Hs Upload Session State","description":"Which parts are already stored — the resume endpoint. An interrupted 4 GB\nupload continues from here rather than starting over.\n\nGated on the UPLOAD surface with the rest of the chunked handshake: an\naccount that may not declare or send a part has no business reading the\nprogress of one either.","operationId":"hs_upload_session_state_api_asclepius_hs_uploads_sessions__session_id__get","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["asclepius-provider"],"summary":"Hs Upload Abort","description":"Give up on an unfinished upload and release its parts immediately, rather\nthan waiting for the reaper.\n\nGated on the UPLOAD surface with the rest of the chunked handshake. It is a\nwrite against an upload, and the account that may not make one may not\ndestroy one.","operationId":"hs_upload_abort_api_asclepius_hs_uploads_sessions__session_id__delete","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/uploads/sessions/{session_id}/parts/{part}":{"put":{"tags":["asclepius-provider"],"summary":"Hs Upload Part","description":"One chunk, verified against its own sha256.\n\nIts own request, so the platform's five-minute body limit applies per chunk\nand is irrelevant at this size. The body is read whole because a part is\nbounded by the server-chosen chunk size — the ceiling is a configuration\nconstant, not something the client can grow.","operationId":"hs_upload_part_api_asclepius_hs_uploads_sessions__session_id__parts__part__put","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"part","in":"path","required":true,"schema":{"type":"integer","title":"Part"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/uploads/sessions/{session_id}/complete":{"post":{"tags":["asclepius-provider"],"summary":"Hs Upload Complete","description":"Assemble, verify the whole-file digest, and only then create the upload.\n\nOrder matters and is the invariant: the blob is written and verified BEFORE\nthe ``ingest_uploads`` row exists, so there is never a row pointing at bytes\nwe have not proven. A digest mismatch retains recovery bytes without an\naccepted receipt.","operationId":"hs_upload_complete_api_asclepius_hs_uploads_sessions__session_id__complete_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/signup":{"post":{"tags":["asclepius-provider"],"summary":"Hs Signup","description":"Stage a signup and mail a code. Creates no account.\n\nThe guard stack is the one ``/api/onboarding/self-serve`` already runs, in\nthe same order: IP limit, global cap, honeypot, per-address cap, then proof\nof the mailbox. It diverges in one place, deliberately. Onboarding answers\nan over-cap address with a 429 whose text confirms we have seen it before;\nhere every outcome returns the same body, because this file's standing rule\nis one code path with one observable, and ``hs_login`` two hundred lines up\ngoes to considerable trouble for exactly that property. Losing it on the\nsignup route would be an odd place to stop caring.\n\nThe send is awaited, which the authenticated routes below must not do. It is\ncorrect here: no session exists yet, so response time correlates with\nnothing about an existing partner, and the person genuinely needs to be told\nif the code could not be sent.","operationId":"hs_signup_api_asclepius_hs_signup_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsSignupRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/signup/resend":{"post":{"tags":["asclepius-provider"],"summary":"Hs Signup Resend","description":"Mail the code again. Always the same body, whether or not anything was\nstaged for that address.","operationId":"hs_signup_resend_api_asclepius_hs_signup_resend_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsSignupResendRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/signup/verify":{"post":{"tags":["asclepius-provider"],"summary":"Hs Signup Verify","description":"Trade a correct code for an account and a session.\n\nSigns them straight in rather than bouncing to the login form: the username\nwas derived from their organization name and they have never seen it, so a\nredirect to \"enter your username\" would strand every single signup.","operationId":"hs_signup_verify_api_asclepius_hs_signup_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsSignupVerifyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/invite/{token}":{"get":{"tags":["asclepius-provider"],"summary":"Hs Invite Lookup","description":"What the claim screen needs to render itself. PUBLIC and unauthenticated.\n\n**An unknown or expired token is a 200 with ``found: false``, never a 404.**\nExactly the reasoning ``GET /api/asclepius/hs-referral/{token}`` states: a\n404 makes this a membership oracle, feed it tokens and the status code tells\nyou which ones are live, and on this route a live token additionally names a\nhealth system that is talking to us. The page renders its \"this link has\nalready been used\" state either way, which is what it should do for a stale\nlink regardless of why the link is stale.\n\nNothing here is new to the holder of the token. Their own address, the\norganization they are being added to and the first name of the colleague who\nadded them were all in the email the link came in. Built by whitelist, as\nthat endpoint is: no username, no approval status, no password state.","operationId":"hs_invite_lookup_api_asclepius_hs_invite__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/invite/{token}/claim":{"post":{"tags":["asclepius-provider"],"summary":"Hs Invite Claim","description":"Spend an invite: set a name and a password, and sign in.\n\nSigns them straight into the portal rather than bouncing to the login form,\nfor the same reason ``/hs/signup/verify`` does: the username was derived\nfrom their organization's name and they have never seen it, so \"now enter\nyour username\" would strand every single person this letter reaches.\n\nSingle use is enforced by the store, which clears the hash in the same\nstatement that writes the password. A second visit to the link therefore\nfinds nothing, which is the correct answer: the account now has an owner.","operationId":"hs_invite_claim_api_asclepius_hs_invite__token__claim_post","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsInviteClaimRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/intake":{"get":{"tags":["asclepius-provider"],"summary":"Hs Intake Get","operationId":"hs_intake_get_api_asclepius_hs_intake_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["asclepius-provider"],"summary":"Hs Intake Post","operationId":"hs_intake_post_api_asclepius_hs_intake_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsIntakeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/payouts":{"get":{"tags":["asclepius-provider"],"summary":"Hs Payouts","description":"The signed-in organization's ledger, and nobody else's.\n\nThis route takes NO identifier, in the path, the query or a body. The\n``hs_id`` comes from the session and from nowhere else, which is the same\nproperty the physician earnings route holds: it is a fact about the route\nrather than about a check somebody remembered to write. There is\ndeliberately no ``/hs/payouts/{hs_id}``.","operationId":"hs_payouts_api_asclepius_hs_payouts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/requests":{"get":{"tags":["asclepius-provider"],"summary":"Hs Requests","description":"The data requests this organization can answer right now.\n\nNO identifier, in the path, the query or a body. The organization comes off\nthe session, which is the property ``/hs/payouts`` holds and for the same\nreason. There is deliberately no ``/hs/requests/{hs_id}``.\n\nGated on the ORGANIZATION's state as well as the account's surface, because\na request is an ask to upload and an organization that has not signed the\nagreement may not. A partner in intake, in review, or holding an unsigned\nagreement is told what it is told at every other upload door rather than\nhanded a list of things it cannot act on.\n\nClosed requests are gone from here the moment they close. A request we have\nstopped asking for still sitting on the portal is how a partner spends a\nweek assembling cases nobody is waiting for.","operationId":"hs_requests_api_asclepius_hs_requests_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/application":{"get":{"tags":["asclepius-provider"],"summary":"Hs Application Get","description":"The questions, and what this organization last answered.","operationId":"hs_application_get_api_asclepius_hs_application_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["asclepius-provider"],"summary":"Hs Application Post","description":"Record the four answers and move the organization to `submitted`.\n\nEvery value is checked against the server's own option list. Not because a\nbad value would be dangerous -- these are strings in a form -- but because\nan unvalidated one lands in the column an operator reads to decide whether a\nBAA is required, and a column that can hold anything is a column nobody can\nfilter on.","operationId":"hs_application_post_api_asclepius_hs_application_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsApplicationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/members":{"get":{"tags":["asclepius-provider"],"summary":"Hs Members Get","operationId":"hs_members_get_api_asclepius_hs_members_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["asclepius-provider"],"summary":"Hs Members Post","description":"Add teammates. Each gets their own account and their own claim link.\n\nTHE ORGANIZATION IS FIXED BY THE SESSION. This route takes addresses and\nnothing else -- no hs_id, no organization name -- so there is no version of\nit that adds somebody to a health system the caller is not already in. That\nis the same property /hs/payouts holds and for the same reason.\n\nAdding an address that already has an active account on this organization\nROTATES nothing and sends nothing: re-adding a colleague by accident must\nnot invalidate the password they are already using.\n\nNOTHING THAT GUARDS THE NEW ACCOUNT TRAVELS BY EMAIL. Each address gets a\none-time claim link and sets its own password on arrival, which is also\nwhere the account finally gets a NAME: it had none before, so the portal\nheader rendered the derived username at a hospital executive.","operationId":"hs_members_post_api_asclepius_hs_members_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsMemberRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/agreement":{"get":{"tags":["asclepius-provider"],"summary":"Hs Agreement Get","description":"The agreement, in full, as text.\n\nFULL TEXT, not a link to a PDF. §5.1: a clickwrap that requires downloading\nsomething to read it is a clickwrap whose \"I have read this\" is provably\nfalse, and the reasonable-notice line in the case law is exactly there.\n\nServed to every state, not only to the one that can sign. An organization\nstill filling in the application is entitled to read what it would be\nsigning before it answers anything, and a member who arrives after the\nsignature is entitled to read what their organization agreed to.","operationId":"hs_agreement_get_api_asclepius_hs_agreement_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/agreement/sign":{"post":{"tags":["asclepius-provider"],"summary":"Hs Agreement Sign","description":"Take one signature, render the record, and open the upload door.\n\nThe order of operations is the whole of it, and it is deliberate:\n\n  1. verify the state, the affirmations, and that the text has not changed\n     underneath the signer;\n  2. render the PDF and store it, so a row can never point at a document\n     that does not exist;\n  3. INSERT the signature row -- append-only, enforced by trigger;\n  4. move the organization to `active`;\n  5. mail the copies, in the background.\n\nA failure at step 2 leaves nothing signed. A failure at step 5 leaves an\nagreement that is signed and an email that did not arrive, which is the\nright way round: the signature is the fact, the email is a copy of it.","operationId":"hs_agreement_sign_api_asclepius_hs_agreement_sign_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsAgreementSignRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/agreement/document":{"get":{"tags":["asclepius-provider"],"summary":"Hs Agreement Document","description":"The signed PDF, for the organization that signed it.\n\nScoped to the SESSION's organization and takes no identifier, so there is no\nversion of this route that serves one partner's contract to another. The\nE-SIGN retention requirement is what this exists for: the copy was emailed,\ninboxes lose things, and a contract you cannot get back is a contract you\ncannot rely on.","operationId":"hs_agreement_document_api_asclepius_hs_agreement_document_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/media/imports":{"post":{"summary":"Cloud Import","operationId":"cloud_import_api_asclepius_hs_media_imports_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Import"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/media/capabilities":{"get":{"summary":"Capabilities","operationId":"capabilities_api_asclepius_hs_media_capabilities_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/media/collections":{"get":{"summary":"Collections","operationId":"collections_api_asclepius_hs_media_collections_get","parameters":[{"name":"after","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"","title":"After"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"summary":"Collection","operationId":"collection_api_asclepius_hs_media_collections_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/hs/media/collections/{cid}":{"get":{"summary":"Catalog","operationId":"catalog_api_asclepius_hs_media_collections__cid__get","parameters":[{"name":"cid","in":"path","required":true,"schema":{"type":"string","title":"Cid"}},{"name":"after","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"","title":"After"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/media/files":{"post":{"summary":"Declare","operationId":"declare_api_asclepius_hs_media_files_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Declare"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/media/files/{fid}":{"get":{"summary":"State","operationId":"state_api_asclepius_hs_media_files__fid__get","parameters":[{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"summary":"Cancel","operationId":"cancel_api_asclepius_hs_media_files__fid__delete","parameters":[{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/media/files/{fid}/sign":{"post":{"summary":"Sign","operationId":"sign_api_asclepius_hs_media_files__fid__sign_post","parameters":[{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Sign"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs/media/files/{fid}/complete":{"post":{"summary":"Complete","operationId":"complete_api_asclepius_hs_media_files__fid__complete_post","parameters":[{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/media/{org}/collections":{"get":{"summary":"Collections","operationId":"collections_api_asclepius_admin_media__org__collections_get","parameters":[{"name":"org","in":"path","required":true,"schema":{"type":"string","title":"Org"}},{"name":"after","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"","title":"After"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/media/{org}/collections/{cid}":{"get":{"summary":"Catalog","operationId":"catalog_api_asclepius_admin_media__org__collections__cid__get","parameters":[{"name":"org","in":"path","required":true,"schema":{"type":"string","title":"Org"}},{"name":"cid","in":"path","required":true,"schema":{"type":"string","title":"Cid"}},{"name":"after","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"","title":"After"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/media/{org}/files/{fid}/review":{"post":{"summary":"Review","operationId":"review_api_asclepius_admin_media__org__files__fid__review_post","parameters":[{"name":"org","in":"path","required":true,"schema":{"type":"string","title":"Org"}},{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Review"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/media/{org}/deliveries":{"post":{"summary":"Deliver","operationId":"deliver_api_asclepius_admin_media__org__deliveries_post","parameters":[{"name":"org","in":"path","required":true,"schema":{"type":"string","title":"Org"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Delivery"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/media/{org}/files/{fid}/retry":{"post":{"summary":"Retry","operationId":"retry_api_asclepius_admin_media__org__files__fid__retry_post","parameters":[{"name":"org","in":"path","required":true,"schema":{"type":"string","title":"Org"}},{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/media/{did}":{"get":{"summary":"Manifest","operationId":"manifest_api_asclepius_buyer_media__did__get","parameters":[{"name":"did","in":"path","required":true,"schema":{"type":"string","title":"Did"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/media/{did}/files/{fid}/download":{"post":{"summary":"Download","operationId":"download_api_asclepius_buyer_media__did__files__fid__download_post","parameters":[{"name":"did","in":"path","required":true,"schema":{"type":"string","title":"Did"}},{"name":"fid","in":"path","required":true,"schema":{"type":"string","title":"Fid"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/metrics/questions":{"get":{"tags":["asclepius-admin"],"summary":"Metrics Questions","description":"SUPPLY · QUALITY · PIPELINE · DEMAND, each with a headline figure and a\n14-day sparkline series. Cohen's κ is NOT in this payload on purpose — the\nclient reads it from /stats and renders it beside expert acceptance,\nseparately labeled: expert acceptance is not κ, and merging them would\nmisreport the number a buyer audits most closely.","operationId":"metrics_questions_api_asclepius_admin_metrics_questions_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/case-options":{"get":{"tags":["asclepius-admin"],"summary":"Export Case Options","description":"Everything the five scope pickers need, in one call.\n\n``specialties`` / ``versions`` are what the old two-filter surface returned\nand are unchanged. ``cases`` and ``physicians`` are new (PRD §2.1): the Case\nscope types or pastes an id and wants a typeahead behind it, and the\nPhysician scope picks a PERSON BY NAME while the bundle it produces carries\nonly ``annotator_id_hashed``. Both halves come from one row so a caller\ncannot cross them.","operationId":"export_case_options_api_asclepius_admin_export_case_options_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/case-preview":{"get":{"tags":["asclepius-admin"],"summary":"Export Case Preview","operationId":"export_case_preview_api_asclepius_admin_export_case_preview_get","parameters":[{"name":"case_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Id"}},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"}},{"name":"scope","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope"}},{"name":"case_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"comma-separated case ids for the Case scope","title":"Case Ids"},"description":"comma-separated case ids for the Case scope"},{"name":"annotator_id_hashed","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotator Id Hashed"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/approve":{"post":{"tags":["asclepius-admin"],"summary":"Export Approve Unapproved","description":"Approve, for export, the submissions the preview said would not ship.\n\nThis is the \"[ Approve all 4 ]\" button (PRD §2.2). It calls the SAME policy\nfunction the single-row Approve button calls — ``payments.approve_earning``\n— once per submission, server-side. One round trip instead of N, one rate\nlimit instead of N, and exactly one definition of what approving means.\n\nTwo cases it handles that the per-row button never sees:\n\n* a submission whose ledger row does not exist yet. The accrual sweep\n  materialises rows lazily, so a freshly submitted case may have none.\n  ``reconcile_task_accruals`` runs first, which is the same call the admin\n  ledger makes on every page load.\n* a submission whose author does not accrue payment at all (an advisor on\n  the equity-only model). There is no money to approve, and the work is\n  still real: the export gate moves on its own. \"Approved money ⇔ exportable\n  record\" holds vacuously — there is no money either way.","operationId":"export_approve_unapproved_api_asclepius_admin_export_approve_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApproveForExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/migration-report":{"get":{"tags":["asclepius-admin"],"summary":"Export Migration Report","description":"What the boot migration did, and whether any row was lost (PRD §0, §4).\n\nRead this instead of SSHing into a container. It reports the run that\nhappened when this process started: how many cases had been approved or\npaid but could not ship, how many are now exportable, how many voided\nearnings were deliberately left alone — and the no-data-loss contract check\ntaken around the sweep by the sweep itself.\n\n``ran`` is False when the process has not finished the boot sweep yet (it\nruns off the event loop) or when this build started before the migration\nexisted. Refresh; it does not need a redeploy.","operationId":"export_migration_report_api_asclepius_admin_export_migration_report_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/case-bundle":{"post":{"tags":["asclepius-admin"],"summary":"Export Case Bundle","operationId":"export_case_bundle_api_asclepius_admin_export_case_bundle_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaseBundleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/exclusivity":{"get":{"tags":["asclepius-admin"],"summary":"Export Exclusivity","description":"What is exclusively committed, to whom, and over how much.\n\nLive commitments first (those are the ones that block a cut), then the ended\nones, which are kept because \"we were exclusive to them until March\" is the\nfact a dispute turns on.","operationId":"export_exclusivity_api_asclepius_admin_export_exclusivity_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/export/exclusivity/{license_id}/release":{"post":{"tags":["asclepius-admin"],"summary":"Release Export Exclusivity","description":"End an exclusive commitment so its records can be sold again. The row is\nkept and marked released rather than deleted, because deleting it destroys the\nonly record that the promise ever existed.","operationId":"release_export_exclusivity_api_asclepius_admin_export_exclusivity__license_id__release_post","parameters":[{"name":"license_id","in":"path","required":true,"schema":{"type":"string","title":"License Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseReleaseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/storage/durability":{"get":{"tags":["asclepius-admin"],"summary":"Storage Durability","description":"Will this deployment survive its next redeploy? Three cheap syscalls.\n\nSplit out of ``/storage/reconcile`` deliberately. That endpoint walks every\ncase row and stats the whole blob tree, so it is cached for fifteen minutes\nand far too heavy to call on a page load — which meant the ONE question an\noperator needs answered constantly (\"is my data on the volume?\") was locked\nbehind the one query that could not be asked constantly. This is three\n``stat`` calls and a write probe, never cached, safe to call on every admin\nrender.\n\n``gate_armed`` is the part that outlives any single answer. With\n``ENV=production`` the app REFUSES TO BOOT on non-durable storage, so the\nquestion stops needing to be asked. Without it, storage can silently become\nephemeral again on any future variable change and nothing will stop the\ncontainer from accepting data it is going to destroy — so an unarmed gate is\nreported as a problem even when today's verdict is green.","operationId":"storage_durability_api_asclepius_admin_storage_durability_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/storage/reconcile":{"get":{"tags":["asclepius-admin"],"summary":"Storage Reconcile","description":"What the storage layer actually holds versus what the database believes.\n\nRead-only. ``missing_blobs`` is an INCIDENT, not a metric: each entry is a case\nthat will 404 when a physician opens its image, or ship to a buyer as a\nreference resolving to nothing. ``orphan_blobs`` is disk cost only — reported,\nnever deleted, because a wrongly-deleted blob is unrecoverable once the partner\nbundle behind it has aged out of its retention window.\n\nAlso returns the live durability verdict for all three stores, so the operator\ncan see *why* blobs went missing rather than only that they did.","operationId":"storage_reconcile_api_asclepius_admin_storage_reconcile_get","parameters":[{"name":"refresh","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Refresh"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/physicians":{"get":{"tags":["asclepius-admin"],"summary":"List Physicians","operationId":"list_physicians_api_asclepius_admin_physicians_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/physicians/{user_id}":{"get":{"tags":["asclepius-admin"],"summary":"Physician Profile","description":"Everything captured at onboarding: NPI + NPPES payload, CV, LinkedIn,\nboard certification, years, score breakdown, Slack, task history, and —\nwhen they are a reviewer — review history.","operationId":"physician_profile_api_asclepius_admin_physicians__user_id__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/users/{user_id}/role":{"post":{"tags":["asclepius-admin"],"summary":"Set User Role","description":"Grant or revoke the admin role on one account.\n\nThis is how the second founder becomes an admin without touching env\nvars: the env-bootstrapped admin promotes their existing account once\nfrom the roster. Two roles only; every other role is provisioned by its\nown flow and must not be reachable from a console button. Self-demotion\nis refused so the console cannot lock its last operator out.","operationId":"set_user_role_api_asclepius_admin_users__user_id__role_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/users/{user_id}/deactivate":{"post":{"tags":["asclepius-admin"],"summary":"Deactivate User","description":"Switch one account off without deleting anything.\n\nFor test and fraudulent signups. Sign-in already refuses an inactive\naccount, and the row, its credentials and every decision stay on record.\nAn admin must be demoted first, and nobody can switch off their own login.","operationId":"deactivate_user_api_asclepius_admin_users__user_id__deactivate_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeactivateBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/outbox/summary":{"get":{"tags":["asclepius-admin"],"summary":"Outbox Summary","description":"Read-only health of the admin outbox: counts by kind and status, the\nerrors holding pending mail back, and how much is due now. No addresses.","operationId":"outbox_summary_api_asclepius_admin_outbox_summary_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/outreach/queue":{"post":{"tags":["asclepius-admin"],"summary":"Queue Outreach","description":"Queue one outreach email per recipient (PRD_PHYSICIAN_EMAIL_OUTREACH).\n\nEach recipient is re-checked against live state; anyone no longer eligible\nis reported as skipped with the reason. ``dry_run`` (the default) renders\nwithout minting links or writing to the outbox.","operationId":"queue_outreach_api_asclepius_admin_outreach_queue_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutreachBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/physicians/restore":{"post":{"tags":["asclepius-admin"],"summary":"Restore Physician","description":"Put one account back together as a labeling physician, in a single call.\n\nThe repair is four writes across three screens — role, tier, verification,\nreal-data approval — and an account filed under an operator role is on NONE\nof those screens, so the sequence could not be started from the console at\nall. Every step here is reachable through its own route; what this adds is\nthat they can be done in one action on an account the UI cannot reach, and\nthat the response says what each one did.\n\nNothing is implicit. ``approve_verification`` is a credentialing decision and\nis off by default; when set, it is recorded as a human decision by the calling\nadmin (``verified_by``), exactly as the queue would. Real-data approval is\nnever set directly — it is left to the same APPROVED + LABELING policy that\ngoverns everyone else, so this endpoint cannot become a side door around it.","operationId":"restore_physician_api_asclepius_admin_physicians_restore_post","parameters":[{"name":"email","in":"query","required":true,"schema":{"type":"string","description":"The account to restore, by email.","title":"Email"},"description":"The account to restore, by email."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestorePhysicianBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/application-progress":{"get":{"tags":["asclepius-admin"],"summary":"Application Progress","description":"Every applicant's checklist on one screen, plus the signups with no account.\n\nLives here rather than under /verify because the signup half reads the team\nstore. One checklist function serves this, the dossier and the applicant's\nown card (PRD_APPLICATION_COMPLETION_PORTAL).","operationId":"application_progress_api_asclepius_admin_application_progress_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"pending","title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/signups":{"get":{"tags":["asclepius-admin"],"summary":"List Signups","description":"Every physician who started onboarding and does not yet have an account.\n\nSorted by most recent activity, because the person who touched the wizard an\nhour ago is the one a nudge still reaches.","operationId":"list_signups_api_asclepius_admin_signups_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/manual-reminders/preview":{"post":{"tags":["asclepius-admin"],"summary":"Preview Manual Reminders","operationId":"preview_manual_reminders_api_asclepius_admin_manual_reminders_preview_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManualReminderPreview"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/manual-reminders/{reminder_id}/send":{"post":{"tags":["asclepius-admin"],"summary":"Send Manual Reminder","operationId":"send_manual_reminder_api_asclepius_admin_manual_reminders__reminder_id__send_post","parameters":[{"name":"reminder_id","in":"path","required":true,"schema":{"type":"string","title":"Reminder Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/manual-reminders/history":{"get":{"tags":["asclepius-admin"],"summary":"Manual Reminder History","operationId":"manual_reminder_history_api_asclepius_admin_manual_reminders_history_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/signups/resend":{"post":{"tags":["asclepius-admin"],"summary":"Resend Signup Link","description":"Mail this physician their onboarding link again, resuming where they stopped.\n\nAny new token is minted onto the SAME row, so a doctor who stalled after\nentering their credentials returns to a wizard that still has them. A link\nthat is still alive is re-sent unchanged rather than replaced — see below.\nThe link goes to their address only, never back in the response body, so\nthis cannot be used to read out a live onboarding credential.","operationId":"resend_signup_link_api_asclepius_admin_signups_resend_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignupResendRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/health-systems/{hs_id}":{"get":{"tags":["asclepius-admin"],"summary":"Health System Detail","description":"One health system: portal accounts, linked physicians, and every upload\nplaced into the four workflow buckets.","operationId":"health_system_detail_api_asclepius_admin_health_systems__hs_id__get","parameters":[{"name":"hs_id","in":"path","required":true,"schema":{"type":"string","title":"Hs Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/uploads/{upload_id}/specialty":{"post":{"tags":["asclepius-admin"],"summary":"Set Upload Specialty","description":"Assign the specialty for an upload's cases (FIX-C C-3.2).\n\nIngest no longer guesses. Where nothing declared a specialty the cases carry\nNULL and surface as \"not yet determined\", and this is how an operator\nresolves it — before promotion, which still falls back to a literal.","operationId":"set_upload_specialty_api_asclepius_admin_uploads__upload_id__specialty_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadSpecialtyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/health-systems/{hs_id}/unlock":{"post":{"tags":["asclepius-admin"],"summary":"Unlock Health System","description":"Clear brute-force lock state for a health system's portal accounts.\n\nWithout this the only recovery from a lockout was re-provisioning, which\nrotates the passphrase and forces the hospital through another reset — a\nheavy remedy for someone else's five wrong guesses. Locks are now scoped to\n(username, ip), so this is a support tool rather than the sole defence, but\nan operator still needs a way to say \"clear it now\".","operationId":"unlock_health_system_api_asclepius_admin_health_systems__hs_id__unlock_post","parameters":[{"name":"hs_id","in":"path","required":true,"schema":{"type":"string","title":"Hs Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/HsAccessRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/health-systems/{hs_id}/access":{"post":{"tags":["asclepius-admin"],"summary":"Set Health System Access","description":"Deactivate (or restore) portal access. ``username`` scopes it to one\naccount; omitting it applies to the whole health system.\n\nBoth ``hs_portal_users.active`` and ``health_systems.active`` existed from\nthe first build and nothing ever wrote them — they were columns for a\nrevocation path that did not exist. ``require_hs_portal`` already rejects an\ninactive account on every request, so flipping the flag ends live sessions\ntoo.","operationId":"set_health_system_access_api_asclepius_admin_health_systems__hs_id__access_post","parameters":[{"name":"hs_id","in":"path","required":true,"schema":{"type":"string","title":"Hs Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsAccessRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/health-systems":{"get":{"tags":["asclepius-admin"],"summary":"List Health Systems","description":"One row per health system with the counts the admin section needs.","operationId":"list_health_systems_api_asclepius_admin_health_systems_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/hs-requests":{"post":{"tags":["asclepius-admin"],"summary":"Create Hs Data Request","description":"Write the request down, then enqueue one letter per active member of every\npartner that may upload.\n\nThe enqueue is synchronous and the SEND is not. That split is the whole\ndesign: the operator finds out immediately whether the request was recorded\nand how many people it will reach, and nothing about their request depends on\nan email provider being up.","operationId":"create_hs_data_request_api_asclepius_admin_hs_requests_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsDataRequestBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius-admin"],"summary":"List Hs Data Requests","description":"Every request, newest first. Closed ones stay here forever: they are the\nrecord of what we asked for and when, which is the only way to read a\npartner's upload history as a response to anything.","operationId":"list_hs_data_requests_api_asclepius_admin_hs_requests_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/hs-requests/{request_id}":{"get":{"tags":["asclepius-admin"],"summary":"Get Hs Data Request","description":"One request plus the uploads carrying its id, grouped by health system.\n\nGrouped rather than listed flat because the question this view answers is\n\"who answered\", not \"what arrived\": three uploads from one partner is one\npartner responding, and a flat list reads as three.","operationId":"get_hs_data_request_api_asclepius_admin_hs_requests__request_id__get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/hs-requests/{request_id}/close":{"post":{"tags":["asclepius-admin"],"summary":"Close Hs Data Request","description":"Close a request as ``fulfilled`` or ``withdrawn``.\n\nTwo reasons and no free text, because the reason is read by a person\nscanning a list rather than by whoever wrote it. ``fulfilled`` says we got\nwhat we asked for; ``withdrawn`` says we stopped asking, and a partner\nreading the portal should not have to guess which.","operationId":"close_hs_data_request_api_asclepius_admin_hs_requests__request_id__close_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HsDataRequestCloseBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/hs-requests/{request_id}/retry-failed":{"post":{"tags":["asclepius-admin"],"summary":"Retry Failed Hs Request Notifications","description":"Flip this request's failed letters back to pending, for the shared drain\nto re-attempt on its next tick.\n\nWithout this a failed outbox row is terminal: re-broadcasting enqueues\nnothing because every idempotency key already exists, so one transport\noutage permanently under-delivered a request the operator believes went\nout. Only rows that FAILED are touched; sent stays sent, and a retry that\nfails again just lands back here.","operationId":"retry_failed_hs_request_notifications_api_asclepius_admin_hs_requests__request_id__retry_failed_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/community/invite":{"post":{"tags":["asclepius-admin"],"summary":"Invite To Community","description":"Mail one approved physician their link into Asclepius Community.\n\nThe 409 on an unapproved physician is the point of the endpoint, not a\nformality: this link opens a room of credential-verified peers, and a\nphysician we have not verified must never be handed one.\n\nIdempotent on the physician: already joined returns 200 with\n``already_joined`` and sends nothing, so a second click is free.","operationId":"invite_to_community_api_asclepius_admin_community_invite_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommunityInviteBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/submissions/{submission_id}/validity-finding":{"post":{"tags":["asclepius-admin"],"summary":"Record Validity Finding","description":"Record that a clinical-validity attestation was, or was not, true.\n\nA HUMAN DECIDES, ALWAYS. There is no sweep, no heuristic and no model that\nwrites this: the whole reason the attestation moves responsibility is that a\nnamed person looked at the case and reached a conclusion, and an automated\nfinding would be an automated pay cut, which this codebase already refuses\nto make (see the quality-hold branch in ``payments.reconcile_task_accruals``).\n\nThe payment consequence is not applied here. It is applied by the accrual\nsweep reading ``validity_finding``, which is what makes it idempotent, makes\nit survive a finding recorded before the ledger row exists, and keeps the\none rule about restating settled money in the one module that owns money.","operationId":"record_validity_finding_api_asclepius_admin_submissions__submission_id__validity_finding_post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidityFindingBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches":{"get":{"tags":["asclepius-admin"],"summary":"Admin Batches","description":"The three case classes, counted. Level 1 of the Batches screen.\n\nThe classes are not a new taxonomy — they are a grouping over discriminators\nevery task row already carries (``trajectory_id``, ``case_source``), so nothing\nhere can disagree with what the queue thinks a case is.","operationId":"admin_batches_api_asclepius_admin_batches_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/{batch}":{"get":{"tags":["asclepius-admin"],"summary":"Admin Batch Cases","description":"The case rows inside one batch, with routing status resolved per row.","operationId":"admin_batch_cases_api_asclepius_admin_batches__batch__get","parameters":[{"name":"batch","in":"path","required":true,"schema":{"type":"string","title":"Batch"}},{"name":"trajectory_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trajectory Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":2000,"minimum":1,"default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/relay":{"post":{"tags":["asclepius-admin"],"summary":"Admin Send Relay","description":"One trajectory, N doctors, one point each, walked in sequence.\n\nA different product from the solo walk, not a variant of it. The solo walk\ncaptures one physician's evolving judgment about a patient; this captures how\nclinicians build on each other's reasoning — doctor k reads doctor k−1's\ncommitted assessment before writing their own, exactly like a real handoff.\n\nWhat this commits, atomically enough that a partial state is not servable:\nthe rotation as assignment rows, ``walk_mode='relay'`` on every point, and\n``distribution`` left at ``assigned_only``. Only doctor #0's point is\nserveable on send; everyone else's assignment exists and is held closed by the\nrelay gate until the chart reaches them.","operationId":"admin_send_relay_api_asclepius_admin_batches_relay_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RelaySendBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/relay/{trajectory_id}":{"get":{"tags":["asclepius-admin"],"summary":"Admin Trajectory Chain","description":"The walk as a chain: who has each point, who the chart is waiting on (§8.7).\n\nServed for SOLO walks too, deliberately. At max_labels=1 a solo walk that its\nphysician abandons is unrecoverable by anyone else — nobody can satisfy the\nsequence gate for the remaining points — so it is dead stock, and before this\nit was dead stock invisible as a problem anywhere in admin.","operationId":"admin_trajectory_chain_api_asclepius_admin_batches_relay__trajectory_id__get","parameters":[{"name":"trajectory_id","in":"path","required":true,"schema":{"type":"string","title":"Trajectory Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/relay/{trajectory_id}/reassign":{"post":{"tags":["asclepius-admin"],"summary":"Admin Reassign Point","description":"Hand one stuck point to somebody else (§8.7).\n\nRevokes the current holder's assignment, writes the new one, and tells the new\ndoctor. The nudge clock resets by construction: ``nudged_at`` lives on the\nassignment, so the new row starts unnudged and the replacement gets their own\none reminder rather than inheriting a spent one.\n\nRecorded in the audit log as a reassignment because the export's provenance\nreads it: a relay walk with a substitution in the middle is a handoff chain a\nbuyer should be able to see, not a detail that quietly disappears once the\nchart is complete.","operationId":"admin_reassign_point_api_asclepius_admin_batches_relay__trajectory_id__reassign_post","parameters":[{"name":"trajectory_id","in":"path","required":true,"schema":{"type":"string","title":"Trajectory Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReassignPointBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/resolve-selection":{"post":{"tags":["asclepius-admin"],"summary":"Admin Resolve Selection","description":"Complete a selection with the earlier chart-walk points it implies.\n\nThis exists so the CLIENT NEVER COMPARES SEQUENCE INDICES. The admin screen\nwants to tell an operator \"3 selected, +5 earlier points included\" before they\ncommit, and the obvious way to get that number is a loop over sequence_index\nin JavaScript — which is precisely what this product does not allow anywhere,\nfor a reason that outlives this screen: a client that knows how to order a walk\nis a client someone will later trust to enforce the order, and a test asserts\nthe shipped client contains no such comparison.\n\nSo the arithmetic stays server-side and the screen asks for the answer. One\ncheap call on selection change, no ordering logic in the browser, and the same\nfunction (``missing_trajectory_predecessors``) that ``allocate`` refuses with —\nso the preview count and the commit can never disagree about what is required.","operationId":"admin_resolve_selection_api_asclepius_admin_batches_resolve_selection_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolveSelectionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/batches/preview/{task_id}":{"get":{"tags":["asclepius-admin"],"summary":"Admin Batch Preview","description":"What the doctor will see — built by the doctor's own payload function.\n\n§2.3. The load-bearing decision is that this calls ``_blind_task``, the exact\nfunction the serve path calls, rather than assembling its own view of the case.\nA preview that reimplemented the payload would be a SECOND definition of \"what\na physician may see\", and the first time the two drifted the admin screen would\nshow a future the portal correctly hides — which is not a cosmetic difference.\nA screenshot of encounter 6 pasted into a Slack thread leaks the answer to\ndecision 5 exactly as thoroughly as serving it would, and just as permanently.\n\nFor a longitudinal point the truncation is already baked into the stored case\n(``build_encounter_case`` writes the visible window, not the whole chart), so\nreusing the serve payload inherits it for free. A test asserts the preview\ncarries no offset past the decision point, because \"inherits it for free\" is\nthe kind of claim that stops being true after an innocent refactor.","operationId":"admin_batch_preview_api_asclepius_admin_batches_preview__task_id__get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/assignments/allocate":{"post":{"tags":["asclepius-admin"],"summary":"Admin Allocate","description":"Propose an allocation, and commit it only when asked.\n\nTHE POINT: the allocator proposes and an admin commits. The response is a\ntable an operator reads and adjusts, and a case nothing could be proposed\nfor comes back in ``unassigned`` WITH A REASON rather than quietly vanishing\nfrom the list.\n\nCommitting writes ``assignments`` rows, which are a PRIORITY and not a\npermission: an assigned case sorts to the top of its assignee's queue and\nevery other physician still sees it exactly where it was. Nothing about who\nMAY draw a case changes here.","operationId":"admin_allocate_api_asclepius_admin_assignments_allocate_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocateBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/assignments":{"get":{"tags":["asclepius-admin"],"summary":"Admin List Assignments","operationId":"admin_list_assignments_api_asclepius_admin_assignments_get","parameters":[{"name":"task_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/assignments/{assignment_id}/revoke":{"post":{"tags":["asclepius-admin"],"summary":"Admin Revoke Assignment","description":"Take an assignment back. The case returns to the ordinary queue, where it\nalways was: revoking removes a priority, not an access grant.","operationId":"admin_revoke_assignment_api_asclepius_admin_assignments__assignment_id__revoke_post","parameters":[{"name":"assignment_id","in":"path","required":true,"schema":{"type":"string","title":"Assignment Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/community/post":{"post":{"tags":["asclepius-admin"],"summary":"Community Persona Post","description":"Post into the community as the Archangel account.\n\nDelegates to ``post_system_message``, which is where the PHI gate, the URL\nmasking, the bot authorship and the announcement fan-out already live. This\nroute adds exactly two things: who is allowed to press the button, and a\nrecord of which admin pressed it. The bot logs itself as the author, which\nis right for the reader and useless for an investigation, so the acting\nadmin is recorded here.","operationId":"community_persona_post_api_asclepius_admin_community_post_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommunityPersonaPostIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/buyer-deliveries":{"post":{"tags":["asclepius-buyer"],"summary":"Send Buyer Delivery","description":"Package the selected organizations' data (optionally within a time window)\nand deliver it to a buyer's secure workspace. Builds the export (Tier A only,\nleak-gated), provisions/rotates the buyer account, records the delivery, and\nemails the buyer credentials + the workspace link. 503 if email isn't\nconfigured — we never deliver without being able to tell the buyer.","operationId":"send_buyer_delivery_api_asclepius_admin_buyer_deliveries_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerDeliveryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["asclepius-buyer"],"summary":"List Buyer Deliveries Admin","description":"Delivery history for the admin: who received what, when, and how many\nrecords (with the product-version mix from the underlying export).","operationId":"list_buyer_deliveries_admin_api_asclepius_admin_buyer_deliveries_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/me":{"get":{"tags":["asclepius-buyer"],"summary":"Buyer Me","operationId":"buyer_me_api_asclepius_buyer_me_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/password":{"post":{"tags":["asclepius-buyer"],"summary":"Buyer Password","description":"Forced first-login reset (and normal change), mirroring the provider flow.","operationId":"buyer_password_api_asclepius_buyer_password_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderPasswordRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/deliveries":{"get":{"tags":["asclepius-buyer"],"summary":"Buyer Deliveries","description":"Every dataset delivered to this buyer — scoped strictly to their account.","operationId":"buyer_deliveries_api_asclepius_buyer_deliveries_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/buyer/deliveries/{export_id}/download":{"get":{"tags":["asclepius-buyer"],"summary":"Buyer Download Delivery","description":"Stream a delivered dataset — but ONLY if it was delivered to THIS buyer.","operationId":"buyer_download_delivery_api_asclepius_buyer_deliveries__export_id__download_get","parameters":[{"name":"export_id","in":"path","required":true,"schema":{"type":"string","title":"Export Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/status":{"get":{"tags":["asclepius-sandbox"],"summary":"Sandbox Status","operationId":"sandbox_status_api_asclepius_sandbox_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/sandbox/seed":{"post":{"tags":["asclepius-sandbox"],"summary":"Sandbox Seed Endpoint","operationId":"sandbox_seed_endpoint_api_asclepius_sandbox_seed_post","parameters":[{"name":"fresh","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Fresh"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/accounts":{"get":{"tags":["asclepius-sandbox"],"summary":"Sandbox Accounts","description":"The ten doctors + credentials. The passwords come from the two env\nvariables and are returned to the sandbox admin's browser only — never\nwritten to the repo, a log line or the database.","operationId":"sandbox_accounts_api_asclepius_sandbox_accounts_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/accounts/fresh":{"post":{"tags":["asclepius-sandbox"],"summary":"Sandbox Seed Fresh Doctor","description":"One more physician with the walkthrough still ahead of them.","operationId":"sandbox_seed_fresh_doctor_api_asclepius_sandbox_accounts_fresh_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/reset":{"post":{"tags":["asclepius-sandbox"],"summary":"Sandbox Reset","description":"Drop the three sandbox DBs and the sandbox asset dir, then reseed.\n\nGuarded three times before a file is touched: the realm middleware (a\nlive token cannot reach this path), ``require_sandbox_admin`` (the realm\nmust be the sandbox), and the typed confirmation. ``sandbox_seed.reset``\nthen re-checks the realm and validates every path it is about to delete\nis a derived sandbox path (§6.6).","operationId":"sandbox_reset_api_asclepius_sandbox_reset_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResetBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/outbox":{"get":{"tags":["asclepius-sandbox"],"summary":"Sandbox Outbox","operationId":"sandbox_outbox_api_asclepius_sandbox_outbox_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["asclepius-sandbox"],"summary":"Sandbox Outbox Clear","operationId":"sandbox_outbox_clear_api_asclepius_sandbox_outbox_delete","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/outbox/{outbox_id}":{"get":{"tags":["asclepius-sandbox"],"summary":"Sandbox Outbox Message","operationId":"sandbox_outbox_message_api_asclepius_sandbox_outbox__outbox_id__get","parameters":[{"name":"outbox_id","in":"path","required":true,"schema":{"type":"integer","title":"Outbox Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/copy-sources":{"get":{"tags":["asclepius-sandbox"],"summary":"Sandbox Copy Sources","description":"The LIVE health systems available to copy, read through the one\nsanctioned read-only live handle, plus the committed fixture provider.","operationId":"sandbox_copy_sources_api_asclepius_sandbox_copy_sources_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sandbox/copy-health-system/{hs_id}":{"post":{"tags":["asclepius-sandbox"],"summary":"Sandbox Copy Health System","operationId":"sandbox_copy_health_system_api_asclepius_sandbox_copy_health_system__hs_id__post","parameters":[{"name":"hs_id","in":"path","required":true,"schema":{"type":"string","title":"Hs Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue":{"get":{"tags":["asclepius-verify"],"summary":"Verification Queue","description":"The admin queue.\n\nB-5.8: paginated, and duplicate detection is ONE grouped query rather than\na full-table scan per row. 'pending' self-limits (an admin works it down),\nbut 'approved' only ever grows, so an unpaginated version degraded\nlinearly forever.","operationId":"verification_queue_api_asclepius_verify_queue_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"pending","title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}},{"name":"ready","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Ready"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}":{"get":{"tags":["asclepius-verify"],"summary":"Verification Dossier","operationId":"verification_dossier_api_asclepius_verify_queue__user_id__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"case_domain","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Domain"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/cv":{"get":{"tags":["asclepius-verify"],"summary":"Verification Cv","description":"The raw CV file — the admin's ground truth when the parse is empty.","operationId":"verification_cv_api_asclepius_verify_queue__user_id__cv_get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"preview","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Preview"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/document/{kind}":{"get":{"tags":["asclepius-verify"],"summary":"Verification Document","description":"A document by slot: ``cv`` or ``licence`` (the regulator-issued one).","operationId":"verification_document_api_asclepius_verify_queue__user_id__document__kind__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"kind","in":"path","required":true,"schema":{"type":"string","title":"Kind"}},{"name":"preview","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Preview"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/documents/{kind}/review":{"post":{"tags":["asclepius-verify"],"summary":"Review Document","description":"The only thing that completes a document item. Bound to the current sha,\nso a file uploaded after this verdict reads as received again.","operationId":"review_document_api_asclepius_verify_queue__user_id__documents__kind__review_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"kind","in":"path","required":true,"schema":{"type":"string","title":"Kind"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentReviewBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/documents/licence/request":{"post":{"tags":["asclepius-verify"],"summary":"Request Licence Document","description":"Ask a US applicant for their licence document. Adds the item to their\nchecklist; nothing else changes.","operationId":"request_licence_document_api_asclepius_verify_queue__user_id__documents_licence_request_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/examination/{exam_id}/export":{"get":{"tags":["asclepius-verify"],"summary":"Examination Export","description":"Download one applicant's complete examination artifact for model review.","operationId":"examination_export_api_asclepius_verify_queue__user_id__examination__exam_id__export_get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"exam_id","in":"path","required":true,"schema":{"type":"string","title":"Exam Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/approve":{"post":{"tags":["asclepius-verify"],"summary":"Approve Signup","operationId":"approve_signup_api_asclepius_verify_queue__user_id__approve_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApproveBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/welcome/retry":{"post":{"tags":["asclepius-verify"],"summary":"Retry Welcome Email","operationId":"retry_welcome_email_api_asclepius_verify_queue__user_id__welcome_retry_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/reject":{"post":{"tags":["asclepius-verify"],"summary":"Reject Signup","operationId":"reject_signup_api_asclepius_verify_queue__user_id__reject_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RejectBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/recheck-pending":{"get":{"tags":["asclepius-verify"],"summary":"Recheck Pending List","description":"The retry list (PRD §1.2). UNAVAILABLE routes to manual review *and*\nschedules a retry — this is the retry, as a list the admin can see and run\nrather than an invisible background job.","operationId":"recheck_pending_list_api_asclepius_verify_recheck_pending_get","parameters":[{"name":"older_than_minutes","in":"query","required":false,"schema":{"type":"integer","default":60,"title":"Older Than Minutes"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["asclepius-verify"],"summary":"Recheck Pending Run","description":"Bulk-run the retry list. Bounded by ``limit`` and by the\n``older_than_minutes`` floor so a sweep cannot hot-loop a rate-limiting\nregistry. Runs off the event loop — this makes N network calls.","operationId":"recheck_pending_run_api_asclepius_verify_recheck_pending_post","parameters":[{"name":"older_than_minutes","in":"query","required":false,"schema":{"type":"integer","default":60,"title":"Older Than Minutes"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/recheck-npi":{"post":{"tags":["asclepius-verify"],"summary":"Recheck Npi","description":"Manual retry — the human path out of UNAVAILABLE.\n\nNon-destructive: a recheck that cannot reach NPPES records an attempt and\nleaves any existing verified result intact (see ``store.set_npi_result``).\nRuns off the event loop — it makes a network call.","operationId":"recheck_npi_api_asclepius_verify_queue__user_id__recheck_npi_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/queue/{user_id}/password-setup-link":{"post":{"tags":["asclepius-verify"],"summary":"Send Password Setup Link","description":"Mail a legacy passwordless applicant a link to set their password.\n\nOnboarding Master PRD §3.2 step 6. The applicant-facing door is the gate\ncard's \"Set my password\", and it covers everybody who reaches it. This\ncovers the ones who do not: the physician who emails support instead of\nclicking, or who never gets far enough to see the card because they gave up\nat the sign-in form.\n\nTHREE THINGS IT DELIBERATELY IS NOT:\n\n* Not a new credential path. It mints the ordinary password reset, through\n  the same ``mint_password_reset`` the forgot door uses, so the ceiling on\n  live resets and the provenance row are shared rather than reimplemented.\n* Not an approval. Setting a password leaves ``verification_status``\n  untouched; this hands somebody the ability to sit their examination, not\n  a decision about them.\n* Not available for an account that HAS a password. Refused with a 400\n  rather than silently mailing a reset, because an admin clicking this on\n  the wrong row would otherwise be a way to hand out reset links for live\n  accounts — the exact hazard ``_needs_credentials`` exists to bound.","operationId":"send_password_setup_link_api_asclepius_verify_queue__user_id__password_setup_link_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/tiering/{user_id}":{"get":{"tags":["asclepius-verify"],"summary":"Tiering For User","description":"``P(TR | physician, case domain)`` for one physician.\n\n``case_domain`` is the whole point of the endpoint: the same physician is a different\nanswer on a nephrology case and a cardiology one, and an admin deciding a tier needs to be\nable to ask both. Omitted, it defaults to the physician's own declared specialty.","operationId":"tiering_for_user_api_asclepius_verify_tiering__user_id__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"case_domain","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Domain"}},{"name":"explore","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Explore"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/tiering/{user_id}/decide":{"post":{"tags":["asclepius-verify"],"summary":"Tiering Decide","description":"Record an explicit tier decision as a training observation, without re-approving.\n\nSeparate from ``/approve`` on purpose. Approval is a lifecycle event that happens once;\na tier judgment is something an admin may make repeatedly and per-domain, and every one of\nthose is a label. Collapsing them would throw away most of the training signal — the\noverride IS the training signal (§5.3).","operationId":"tiering_decide_api_asclepius_verify_tiering__user_id__decide_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TierOverrideBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/tiering-weights":{"get":{"tags":["asclepius-verify"],"summary":"Tiering Weights","description":"The current posterior, next to the prior it started from.\n\nShown side by side deliberately: the useful question about a learned model is never \"what\nis the weight\" but \"how far has it moved from the rule, and did the data earn that\".","operationId":"tiering_weights_api_asclepius_verify_tiering_weights_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/tiering-weights/apply":{"post":{"tags":["asclepius-verify"],"summary":"Tiering Weights Apply","description":"Fold the un-applied decisions into the weights, exactly once.\n\nRuns off the event loop: a few Newton steps over a 17-dimensional system plus a sqlite\ntransaction is short but not free, and it is a synchronous function.","operationId":"tiering_weights_apply_api_asclepius_verify_tiering_weights_apply_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/fairness":{"get":{"tags":["asclepius-verify"],"summary":"Fairness Monitor","description":"TR selection rate by voluntary self-reported demographics, four-fifths comparison.\n\nReads ``fairness_observations`` and nothing else. There is no join to ``users`` here and\nthere cannot be one: the table is keyed by an HMAC pseudonym and carries the decided tier\ncopied in at decision time. Collecting demographics separately is exactly what makes this\nmonitor possible without making the model able to see them.","operationId":"fairness_monitor_api_asclepius_verify_fairness_get","parameters":[{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/demographics/{user_id}":{"post":{"tags":["asclepius-verify"],"summary":"Record Demographics","description":"Voluntary self-report, written straight to the fairness table.\n\nA physician may only submit their own; an admin may submit on behalf of one who answered\non paper. Never inferred, never required, and never written to the users row.","operationId":"record_demographics_api_asclepius_verify_demographics__user_id__post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemographicsBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/calibration/exam":{"get":{"tags":["asclepius-verify"],"summary":"Calibration Exam","description":"Start an attempt. The response NEVER carries a key — see ``calibration.blind_item``.","operationId":"calibration_exam_api_asclepius_verify_calibration_exam_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/calibration/{attempt_id}/submit":{"post":{"tags":["asclepius-verify"],"summary":"Calibration Submit","operationId":"calibration_submit_api_asclepius_verify_calibration__attempt_id__submit_post","parameters":[{"name":"attempt_id","in":"path","required":true,"schema":{"type":"string","title":"Attempt Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CalibrationSubmitBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/calibration/{attempt_id}/rescore":{"post":{"tags":["asclepius-verify"],"summary":"Calibration Rescore","description":"Re-grade an old attempt against today's keys, from the stored raw responses —\nso an item can be re-keyed without re-testing everyone who already sat it.","operationId":"calibration_rescore_api_asclepius_verify_calibration__attempt_id__rescore_post","parameters":[{"name":"attempt_id","in":"path","required":true,"schema":{"type":"string","title":"Attempt Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/leie/load":{"post":{"tags":["asclepius-verify"],"summary":"Leie Load","description":"Load an OIG LEIE monthly CSV snapshot (gate A5).\n\nTakes the CSV body rather than fetching a URL: the download is ~100 MB and lives on a\ngovernment host with its own availability, and an import path that reaches the public\ninternet on an admin click is an outage waiting to be attributed to us. The founder\ndownloads the monthly file; this ingests it atomically.","operationId":"leie_load_api_asclepius_verify_leie_load_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeieLoadBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/readiness":{"get":{"tags":["asclepius-verify"],"summary":"Tr Readiness","description":"Can ANY physician become a TR today, and if not, what exactly is missing?\n\nAUDIT M1. There are **two** independent day-one blockers and they have two different\nowners, but only one of them — the empty calibration item bank — was written down. The\nother is the OIG LEIE snapshot: with `leie_meta` empty, gate A5 answers `unknown` for\nevery physician, `propose()` short-circuits on an undetermined gate, and everyone lands in\nthe admin band no matter how well they score.\n\nBoth fail loudly in isolation and neither is visible as a *launch* condition, so a plan\nthat resolves the item bank alone ships zero TRs and looks like a modelling problem. This\nendpoint is the thing that says otherwise in one call.","operationId":"tr_readiness_api_asclepius_verify_readiness_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/retier-candidates":{"get":{"tags":["asclepius-verify"],"summary":"Retier Candidates","description":"Approved labelers whose filed work reads like a reviewer's.\n\nTwo conditions, both necessary. The score is the judgment; the case count is\nwhat makes the score mean anything, since a blended score over three cases\nis mostly the credential prior wearing a number.","operationId":"retier_candidates_api_asclepius_verify_retier_candidates_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/retier/{user_id}":{"post":{"tags":["asclepius-verify"],"summary":"Retier Physician","description":"Move an already-approved physician between labeler and reviewer.\n\nDeliberately not part of the approval endpoint. Approval decides whether\nsomebody works here at all and carries a first tier as one of its outputs;\nthis is the smaller, later thing, and keeping them separate means a\npromotion cannot accidentally re-run the side effects of an approval\n(credentials minted, welcome mail, community post).\n\nA note is required for the same reason a rejection requires one: in six\nmonths the only person who can explain a role change is whoever wrote it\ndown at the time.","operationId":"retier_physician_api_asclepius_verify_retier__user_id__post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetierBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/verify/leie/status":{"get":{"tags":["asclepius-verify"],"summary":"Leie Status","operationId":"leie_status_api_asclepius_verify_leie_status_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/asclepius/review":{"get":{"tags":["asclepius-review"],"summary":"Review Portal Page","description":"PRD-1 §2.1: there is no standalone review page any more.\n\nReview is a VIEW INSIDE the evaluation portal — same shell, same rail, same\nsession, same design system — so this route redirects into it rather than\n404ing. The old URL is in physicians' bookmarks and in email we have already\nsent; a dead link is a reviewer who cannot find their work.","operationId":"review_portal_page_asclepius_review_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/review/me":{"get":{"tags":["asclepius-review"],"summary":"Review Me","description":"Who am I, for the review portal boot. Served to ANY authenticated portal\nuser (not just reviewers) so the page can render an honest 'not a reviewer'\nstate instead of a bare 403.","operationId":"review_me_api_asclepius_review_me_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/stats":{"get":{"tags":["asclepius-review"],"summary":"Review Stats","operationId":"review_stats_api_asclepius_review_stats_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/pair/next":{"get":{"tags":["asclepius-review"],"summary":"Next Review Pair","description":"Draw + claim the oldest ``review_ready`` CASE for this reviewer.\n\nReturns the case with BOTH labels side by side, blinded, in an A/B order\nseeded on ``(task_id, reviewer_id)`` — stable across reloads so a refresh\ndoes not swap the columns, and uncorrelated with submission order so position\nnever leaks who went first.\n\nThe store query already excludes cases this reviewer labelled or reviewed;\nthe claim is compare-and-set on the TASK, so two reviewers drawing\nconcurrently can never hold the same pair.\n\nPREVIEW (§4.1) is a different draw, not a flag on this one: no claim, no\nsession, and a draw token the submit path refuses. Restricted to operators —\na real reviewer asking for a preview would be asking to work for free, and a\nlabeler asking for one would be asking to read a pair they were excluded\nfrom. An operator whose tier does not carry review is FORCED into it, which\nis the whole point: clicking through the reviewer surface must not grade a\nphysician's work by accident.","operationId":"next_review_pair_api_asclepius_review_pair_next_get","parameters":[{"name":"preview","in":"query","required":false,"schema":{"type":"boolean","description":"Operator preview (PRD-1 §4.1): serve a pair WITHOUT claiming it, open no session, and mark the response so a submit against it is refused.","default":false,"title":"Preview"},"description":"Operator preview (PRD-1 §4.1): serve a pair WITHOUT claiming it, open no session, and mark the response so a submit against it is refused."},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/next":{"get":{"tags":["asclepius-review"],"summary":"Next Review","description":"Draw + claim the oldest reviewable submission for this reviewer.\n\nThe store query already excludes the reviewer's own submissions and anything\nthey reviewed before; the claim is compare-and-set so two reviewers drawing\nconcurrently can never hold the same submission. The served payload is the\nblinded whitelist view — no labeler identity, asserted by test (PRD A §4).","operationId":"next_review_api_asclepius_review_next_get","parameters":[{"name":"preview","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Preview"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/{submission_id}":{"post":{"tags":["asclepius-review"],"summary":"Submit Review","operationId":"submit_review_api_asclepius_review__submission_id__post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","title":"Submission Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReviewSubmitBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/pair/{task_id}":{"post":{"tags":["asclepius-review"],"summary":"Submit Pair Review","description":"The reviewer's adjudication of a pair: which is stronger, and is either\nright.\n\n``accepted_side`` is a POSITION ('A' or 'B') in what this reviewer was shown.\nThe server re-derives the same seeded A/B map it served and resolves the\nposition to a submission id, so the client never learns — and never gets to\nassert — whose work it accepted.","operationId":"submit_pair_review_api_asclepius_review_pair__task_id__post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PairReviewSubmitBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/review/double-label/next":{"get":{"tags":["asclepius-review"],"summary":"Next Double Label","description":"The next task flagged for a second INDEPENDENT label that THIS user may\ntake. Any evaluator can serve as the second labeler — it is labeling work,\nnot review work. The store query excludes the first labeler and anyone who\nalready submitted (independence is enforced in SQL, PRD A §1.3), and the V4\nwall holds: real cases only for real-data-approved users. The labeling\nitself happens in the main evaluator portal; this returns a pointer.","operationId":"next_double_label_api_asclepius_review_double_label_next_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/earnings":{"get":{"tags":["asclepius-payments"],"summary":"My Earnings","description":"Summary + recent ledger for the signed-in physician. Own rows only —\nthe user id comes from the token and from nowhere else.","operationId":"my_earnings_api_asclepius_earnings_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/referrals":{"get":{"tags":["asclepius-payments"],"summary":"My Referrals","description":"This physician's own funnel. No id parameter exists to tamper with.","operationId":"my_referrals_api_asclepius_referrals_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["asclepius-payments"],"summary":"Create Referral","description":"Refer a colleague.\n\n**The response is byte-identical whether or not the address already has an\naccount** (defect 2). The advisor path narrowed its oracle to physician\naccounts, which closed the worst version of it, but it still answered \"does\nthis doctor have an account here?\" one address at a time to anyone who could\ncall it — and generalising the endpoint to every physician multiplies who\nthat is. The referral is recorded either way and the FUNNEL reports the\noutcome, which loses the referrer nothing: they see the row on their own\npage, where the answer is about their own referral rather than about a\nstranger's account.\n\n**The residual, stated rather than hidden:** a new address sends an email and\nan existing member does not, so the two paths differ in RESPONSE TIME by a\nSendGrid round trip. That is a real side channel and it is left in place\nknowingly — closing it means either firing the send blind (losing the\ndelivery signal and every send error with it) or padding the fast path, both\nof which cost more than they buy against a probe that is already bounded to\n20 attempts a day per account and 3 per address across the whole fleet.","operationId":"create_referral_api_asclepius_referrals_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/referrals/enterprise-note":{"post":{"tags":["asclepius-payments"],"summary":"Enterprise Note","description":"A physician flags that their health system might sell data or partner\non enterprise labeling. Free text straight to a founder inbox: at this\ndeal size a human reads every word, so no form fields, no CRM.\n\nReachable by a physician still under review, which matters because of who\nsends these: the person who can open an institutional door is very often\nthe one who just walked through it, and the week they join is the week they\nare most willing to make the introduction.\n\nBounded and throttled per user (3/day) because it is an outbound email a\nsigned-in physician can trigger; the note is plain text in the builder so\nnothing in it can inject markup or headers.","operationId":"enterprise_note_api_asclepius_referrals_enterprise_note_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnterpriseNoteBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/referrals/health-system":{"post":{"tags":["asclepius-payments"],"summary":"Create Hs Referral","description":"Introduce a named person at a health system.\n\n**Why this endpoint returns before the email is sent.** Enrichment is a\nmodel call with a web search inside it, and the physician who just pressed a\nbutton should not watch a spinner for however long that takes. The row and\nits landing token are written synchronously, so the introduction exists and\nis attributable the moment this returns, and delivery is scheduled after.\n\n**The response does not disclose whether we already know this organization.**\nSame rule as ``create_referral`` above: the message is the same either way,\nand the physician's own funnel reports the real outcome a request later.","operationId":"create_hs_referral_api_asclepius_referrals_health_system_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthSystemReferralBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/hs-referral/{token}":{"get":{"tags":["asclepius-payments"],"summary":"Hs Referral Prefill","description":"What the /partner page needs to prefill itself. PUBLIC and unauthenticated.\n\n**This endpoint returns nothing the holder of the token was not already\nsent.** The token arrives in the link inside their own introduction email,\nand everything below, their name, their address, their organization, their\nrole, and the first name of the physician who introduced them, was in that\nemail's body. The whole point is to save a CIO from retyping four fields we\nalready know; it is not a lookup service.\n\nSpecifically NOT returned: the referrer's email address, their note, our\nenrichment, and every other row on ``hs_referrals``. Built by whitelist.\n\n**An unknown token is a 200 with ``found: false``, not a 404.** A 404 makes\nthis a membership oracle, feed it tokens and the status code tells you\nwhich ones are live. The page renders an ordinary empty form either way,\nwhich is exactly what it should do when someone follows a stale link.\n\n``status`` is advanced to ``opened`` as a side effect, which is what makes\nthe referring physician's funnel row move on its own.","operationId":"hs_referral_prefill_api_asclepius_hs_referral__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sessions":{"post":{"tags":["asclepius-payments"],"summary":"Open Session","description":"Open (or resume) a billable session. Idempotent — a client that opens twice\ngets the same session back, with the nonce it must beat with.","operationId":"open_session_api_asclepius_sessions_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenSessionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sessions/{session_id}/heartbeat":{"post":{"tags":["asclepius-payments"],"summary":"Session Heartbeat","operationId":"session_heartbeat_api_asclepius_sessions__session_id__heartbeat_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HeartbeatBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sessions/{session_id}/close":{"post":{"tags":["asclepius-payments"],"summary":"Close Session","description":"Close a session and settle it. Safe to call repeatedly — and it will be,\nbecause the client closes on both ``visibilitychange`` and ``pagehide``.","operationId":"close_session_api_asclepius_sessions__session_id__close_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloseSessionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sessions/{session_id}/resume":{"post":{"tags":["asclepius-payments"],"summary":"Resume Session","description":"Re-issue a beating credential to a client that legitimately lost one — a\nphysician who reloaded the page mid-session.\n\nThis is the ONLY route besides creating a session and beating on one that\nreturns a nonce, and it is deliberately expensive: hard rate limit, ownership\ncheck, and a counter on the session row. ``open_session`` used to do this job\nfor free and unlimited, which turned its idempotence into a nonce dispenser.","operationId":"resume_session_api_asclepius_sessions__session_id__resume_post","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/sessions/{session_id}":{"get":{"tags":["asclepius-payments"],"summary":"Session State","description":"Server-authoritative state, for a client that reloaded mid-session and\nneeds the truth back — including a fresh nonce to resume beating with.","operationId":"session_state_api_asclepius_sessions__session_id__get","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings":{"get":{"tags":["asclepius-payments"],"summary":"Admin Earnings","description":"The whole ledger, filterable. Reconciles first so the admin view and the\ndoctor's view are never two different answers to the same question.","operationId":"admin_earnings_api_asclepius_admin_earnings_get","parameters":[{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"payout_batch_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Batch Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":2000,"minimum":1,"default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/referrals":{"get":{"tags":["asclepius-payments"],"summary":"Admin Referrals","description":"The whole referral book, for the Money tab: who referred whom, where\neach row sits in the funnel, what the ledger has paid, and any fraud\nflag. Admin eyes only, so the invitee's raw address is shown.","operationId":"admin_referrals_api_asclepius_admin_referrals_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":2000,"minimum":1,"default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/mark-paid":{"post":{"tags":["asclepius-payments"],"summary":"Mark Paid","description":"Record that a batch of approved earnings has actually been disbursed.\n\nThis is the ledger's record that money moved; it does not move money. The\ntransfer is a treasury operation, and ``payout_batch_id`` is how the two are\nreconciled — ``GET /admin/earnings?payout_batch_id=...`` returns exactly the\nrows a given disbursement covered.\n\n``user_id`` appears here and nowhere else on this router. That is the point of\nthe split: every doctor-facing route scopes from the session and cannot name\nanother physician, and the one route that must name one is admin-gated.","operationId":"mark_paid_api_asclepius_admin_earnings_mark_paid_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkPaidBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/{earning_id}/retry-transfer":{"post":{"tags":["asclepius-payments"],"summary":"Admin Retry Transfer","description":"Retry the Stripe transfer for one settled row (C4).\n\nThe gate is deliberately narrow: settled, and not already transferred. A\nrow still in review has no decision to execute, and a row with a known\ntransfer (including a reversal) is done. The durable intent retains the\noriginal request, serializes dispatch, and refuses expired retries.","operationId":"admin_retry_transfer_api_asclepius_admin_earnings__earning_id__retry_transfer_post","parameters":[{"name":"earning_id","in":"path","required":true,"schema":{"type":"string","title":"Earning Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/stripe/webhook":{"post":{"tags":["asclepius-payments"],"summary":"Stripe Webhook","description":"Stripe's callback. Signature-verified, stored, then processed (D1, G5).\n\nThe order matters and is the whole reason this is a table rather than a\nhandler. The event lands in ``stripe_webhook_events`` BEFORE anything acts\non it, and the duplicate test is ``processed_at IS NOT NULL`` rather than\n\"have I seen this id\": a crash between the insert and the handler must leave\na work item that Stripe's redelivery picks up, not a row that makes the\nredelivery look like a duplicate and drop it.\n\n404 while dark, so the route is not observable and does not offer a\nsignature oracle to anyone probing for one.","operationId":"stripe_webhook_api_asclepius_stripe_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/asclepius/admin/earnings/{earning_id}/case-export":{"get":{"tags":["asclepius-payments"],"summary":"Admin Case Export","description":"Download the one case behind a ledger row, shaped exactly as it ships.","operationId":"admin_case_export_api_asclepius_admin_earnings__earning_id__case_export_get","parameters":[{"name":"earning_id","in":"path","required":true,"schema":{"type":"string","title":"Earning Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/held":{"get":{"tags":["asclepius-payments"],"summary":"Admin Held Earnings","description":"Rows where the payout algorithm proposed paying less than the posted rate\nand is waiting on a human.\n\nThis queue exists because a proposal nobody can see is an automated decision\nwith extra steps. If it grows, physicians are waiting on us, and that is\nvisible here rather than only in their inbox.","operationId":"admin_held_earnings_api_asclepius_admin_earnings_held_get","parameters":[{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":2000,"minimum":1,"default":500,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/{earning_id}/release":{"post":{"tags":["asclepius-payments"],"summary":"Admin Release Earning Hold","description":"Decide a proposed pay reduction.\n\nTHE POINT OF THIS ENDPOINT: the algorithm never applies a pay cut on its\nown. It computes a multiplier, and a row it wants to pay below the posted\nrate is held until a person acts here. An automated reduction and a proposed\nreduction a human approves are materially different objects, legally and\nethically, and this route is the difference between them.\n\n``pay_full_rate`` overrides the proposal and pays the posted rate, because\nthe person deciding is allowed to disagree with the model. Either way the\ndecision is attributed and timestamped: reducing a physician's pay is\nconsequential and an unattributable reduction cannot be appealed.\n\nReleasing does not itself approve the row. It removes the hold, and the\nnormal ledger rules (a verdict, or the auto-approve window) then apply, so\nthis endpoint decides ONE question and does not quietly decide others.","operationId":"admin_release_earning_hold_api_asclepius_admin_earnings__earning_id__release_post","parameters":[{"name":"earning_id","in":"path","required":true,"schema":{"type":"string","title":"Earning Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReleaseHoldBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/{earning_id}/approve":{"post":{"tags":["asclepius-payments"],"summary":"Admin Approve Earning","description":"Approve one case — the ledger AND the export gate, in one action.\n\nTHE POINT OF THIS ENDPOINT (PRD §1.1): before it existed there was no admin\naction that moved a labeler's earning at all. `/release` decides a proposed\npay cut and `/void` declines to pay; neither approves. So an accrued row sat\nreading \"Pending review\" with no button under it, waiting on a reviewer who\nmight never come, and even when one did the case still could not ship —\nbecause approving the MONEY never touched `records.status`, which is the\nonly thing export reads.\n\nThree writes, one meaning:\n\n1. the ledger row moves ``accrued`` → ``approved`` (compare-and-set, so a\n   double-click cannot double-approve),\n2. the submission and its records move to ``export_ready`` — but only from a\n   non-terminal state: an already-``exported`` case is never downgraded and a\n   ``rejected`` one is Void's business, not this route's,\n3. an audit event, because this deliberately BYPASSES QA sampling and an\n   audit that does not say so is not an audit.\n\nA row the payout algorithm has HELD is refused with a 409 pointing at\n`/release`. That hold is the promise that an automated pay cut never applies\nwithout a person deciding it, and approving through this route would apply\nthe reduced amount while looking like a plain approval.","operationId":"admin_approve_earning_api_asclepius_admin_earnings__earning_id__approve_post","parameters":[{"name":"earning_id","in":"path","required":true,"schema":{"type":"string","title":"Earning Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApproveEarningBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/{earning_id}/void":{"post":{"tags":["asclepius-payments"],"summary":"Admin Void Earning","description":"Decline to pay for one case.\n\nFour properties, all of them load-bearing:\n\n1. ``paid`` is a **409**. The money already left; a refund is a treasury\n   operation and out of scope here. Voiding it would leave the ledger saying\n   we owe nothing for work we have already disbursed.\n2. Idempotent on ``earning_id`` — a double-click cannot double-decrement,\n   because the store's guarded UPDATE is the arbiter rather than a read.\n3. The recomputed total comes back, so the console renders the ledger's\n   number instead of subtracting its own.\n4. An audit row, because voiding a physician's pay is consequential and must\n   be attributable to the person who did it.","operationId":"admin_void_earning_api_asclepius_admin_earnings__earning_id__void_post","parameters":[{"name":"earning_id","in":"path","required":true,"schema":{"type":"string","title":"Earning Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VoidEarningBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/earnings/pay":{"post":{"tags":["asclepius-payments"],"summary":"Admin Pay Earnings","description":"Send payment for one physician's approved rows.\n\nThin over ``asc_payments.mark_paid`` rather than a parallel write path —\nthat function owns the batch-id idempotency and the compare-and-set that\nmakes a retried disbursement safe, and a second implementation of it is a\nsecond chance to pay twice.\n\nThe one thing added here is the compensation guard: an advisor on\n``equity_only`` holds equity and is not paid per case. It calls\n``compensation.accrues_payment`` rather than re-testing the column, because\nthe rule that NULL is payable lives in that function and a re-implementation\nwritten as ``!= 'equity_only'`` gets legacy contributors wrong.","operationId":"admin_pay_earnings_api_asclepius_admin_earnings_pay_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayEarningsBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops":{"get":{"summary":"Dashboard","operationId":"dashboard_api_asclepius_admin_payment_ops_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/readiness":{"get":{"summary":"Readiness","operationId":"readiness_api_asclepius_admin_payment_ops_readiness_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/batches":{"post":{"summary":"Create Batch","operationId":"create_batch_api_asclepius_admin_payment_ops_batches_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchDraft"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/batches/{batch_id}/approve":{"post":{"summary":"Approve","operationId":"approve_api_asclepius_admin_payment_ops_batches__batch_id__approve_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Approval"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/batches/{batch_id}/cancel":{"post":{"summary":"Cancel","operationId":"cancel_api_asclepius_admin_payment_ops_batches__batch_id__cancel_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/batches/{batch_id}/retry":{"post":{"summary":"Retry","operationId":"retry_api_asclepius_admin_payment_ops_batches__batch_id__retry_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Approval"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/tax-review":{"post":{"summary":"Tax Review","operationId":"tax_review_api_asclepius_admin_payment_ops_tax_review_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxReview"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/physicians/{user_id}/tax-collection":{"post":{"summary":"Tax Collection","operationId":"tax_collection_api_asclepius_admin_payment_ops_physicians__user_id__tax_collection_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/reconciliation":{"post":{"summary":"Reconciliation","operationId":"reconciliation_api_asclepius_admin_payment_ops_reconciliation_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Reconciliation"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/payment-ops/reconciliation/{report_id}":{"get":{"summary":"Read Reconciliation","operationId":"read_reconciliation_api_asclepius_admin_payment_ops_reconciliation__report_id__get","parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","title":"Report Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/scores/{user_id}":{"get":{"tags":["asclepius-score"],"summary":"Admin Score","description":"The full picture for one physician: current score, component\nbreakdown, and the per-case trajectory.","operationId":"admin_score_api_asclepius_admin_scores__user_id__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/card":{"post":{"tags":["asclepius-card"],"summary":"Mint My Card","description":"Mint or re-mint the card URL. The raw token is returned once, here.\n\nRe-minting deliberately reuses one column rather than keeping a history:\nthere is no second row to forget to revoke, so \"I shared that with the\nwrong person\" is one button and the old link is dead the moment it lands.","operationId":"mint_my_card_api_asclepius_me_card_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["asclepius-card"],"summary":"Revoke My Card","description":"Take the card down.\n\nNot gated on approval, unlike minting: somebody whose standing changed\nafter they minted one must still be able to withdraw it, and a revoke can\nonly ever reduce what is public. ``ok`` is True either way because the\ncaller asked for a state, not for a transition, and telling them \"there was\nnothing to revoke\" invites a retry loop over an outcome they already have.","operationId":"revoke_my_card_api_asclepius_me_card_delete","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/card/{token}":{"get":{"tags":["asclepius-card"],"summary":"Public Card Page","description":"The card, server-rendered, for anyone holding the link.\n\nServer-rendered rather than a client-side fetch because the audience\nincludes crawlers: a preview unfurled by Slack or LinkedIn never runs the\nJavaScript, and a shared link that unfurls to nothing is the same as not\nhaving built the feature. Rate-limited like the other public doors, since\nthis one takes a token from a stranger and hits the database with it.","operationId":"public_card_page_api_asclepius_card__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/card/{token}/image":{"get":{"tags":["asclepius-card"],"summary":"Public Card Image","description":"The share image, rendered from the same payload the page renders.\n\nSame 404 rules as the page, for the same reason: an image endpoint that\nanswered when the page did not would leak precisely the standing the page\nis careful not to.","operationId":"public_card_image_api_asclepius_card__token__image_get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{specialty}/generate":{"post":{"tags":["asclepius-env"],"summary":"Generate Environments","operationId":"generate_environments_api_asclepius_environments__specialty__generate_post","parameters":[{"name":"specialty","in":"path","required":true,"schema":{"type":"string","title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{task_id}/rollout":{"post":{"tags":["asclepius-env"],"summary":"Rollout Environment","operationId":"rollout_environment_api_asclepius_environments__task_id__rollout_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RolloutRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{task_id}/verify":{"post":{"tags":["asclepius-env"],"summary":"Verify Environment","operationId":"verify_environment_api_asclepius_environments__task_id__verify_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{task_id}/certify":{"post":{"tags":["asclepius-env"],"summary":"Certify Environment","description":"Reward-integrity gate: score a padded-but-hollow trajectory against a\nterse-correct one. ``shippable: false`` means the reward is gameable and the\nenvironment must be repaired before it ships (PRD §7.5 guardrail).","operationId":"certify_environment_api_asclepius_environments__task_id__certify_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/export":{"get":{"tags":["asclepius-env"],"summary":"Export Environments","operationId":"export_environments_api_asclepius_environments_export_get","parameters":[{"name":"mode","in":"query","required":false,"schema":{"type":"string","default":"raw","title":"Mode"}},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/reward-model/train":{"post":{"tags":["asclepius-env"],"summary":"Train Reward Model","operationId":"train_reward_model_api_asclepius_environments_reward_model_train_post","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/annotation-queue":{"get":{"tags":["asclepius-env"],"summary":"Annotation Queue","description":"The ENV annotation queue (PRD §7.2). Gated on ``portal_version == 'env'``.\n\n``allow_legacy``: a client cached before the rename still sends ``'v5'``. It is\naccepted for one release rather than 400ing a physician mid-annotation over a\nstring their page will stop sending the moment it reloads. Nothing is STORED\nfrom it — the response echoes ``ENV_PORTAL_VERSION``.","operationId":"annotation_queue_api_asclepius_environments_annotation_queue_get","parameters":[{"name":"portal_version","in":"query","required":false,"schema":{"type":"string","default":"env","title":"Portal Version"}},{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/runs/{run_id}":{"get":{"tags":["asclepius-env"],"summary":"Get Run For Annotation","description":"Fetch ONE trajectory's annotation view by run_id (regardless of whether it\nis already annotated) so a physician can open/re-open a specific run — the\nqueue only lists UNannotated runs, so re-opening must not route through it.","operationId":"get_run_for_annotation_api_asclepius_environments_runs__run_id__get","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{task_id}/annotate":{"post":{"tags":["asclepius-env"],"summary":"Annotate Environment","description":"A board-certified physician submits the §7 annotation for one trajectory\n(run). Gated on ``portal_version == 'env'`` (PRD §12.9).\n\nLegacy ``'v5'`` is accepted for one release — see the queue above. It is never\nwritten: an env annotation lands in ``env_runs``, which has no portal_version\ncolumn, so there is no way for the legacy string to be mistaken later for a\nlongitudinal submission.","operationId":"annotate_environment_api_asclepius_environments__task_id__annotate_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments/{task_id}":{"get":{"tags":["asclepius-env"],"summary":"Get Environment","operationId":"get_environment_api_asclepius_environments__task_id__get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/environments":{"get":{"tags":["asclepius-env"],"summary":"List Environments","operationId":"list_environments_api_asclepius_environments_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"mode","in":"query","required":false,"schema":{"type":"string","default":"generated","title":"Mode"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/auth/login":{"post":{"tags":["ehr-sandbox"],"summary":"Access Login","operationId":"access_login_api_asclepius_ehr_sandbox_auth_login_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/practice":{"get":{"tags":["ehr-sandbox"],"summary":"Practice Catalog","operationId":"practice_catalog_api_asclepius_ehr_sandbox_practice_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/practice/replay":{"post":{"tags":["ehr-sandbox"],"summary":"Practice Replay","operationId":"practice_replay_api_asclepius_ehr_sandbox_practice_replay_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PracticeBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/practice/step":{"post":{"tags":["ehr-sandbox"],"summary":"Practice Step","operationId":"practice_step_api_asclepius_ehr_sandbox_practice_step_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PracticeStepBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/practice/agent-step":{"post":{"tags":["ehr-sandbox"],"summary":"Practice Agent Step","operationId":"practice_agent_step_api_asclepius_ehr_sandbox_practice_agent_step_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PracticeAgentBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/charts/build":{"post":{"tags":["ehr-sandbox"],"summary":"Build Charts","operationId":"build_charts_api_asclepius_ehr_sandbox_charts_build_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuildBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/charts":{"get":{"tags":["ehr-sandbox"],"summary":"Charts","operationId":"charts_api_asclepius_ehr_sandbox_charts_get","parameters":[{"name":"upload_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/charts/{chart_id}/compile":{"post":{"tags":["ehr-sandbox"],"summary":"Compile Chart","operationId":"compile_chart_api_asclepius_ehr_sandbox_charts__chart_id__compile_post","parameters":[{"name":"chart_id","in":"path","required":true,"schema":{"type":"string","title":"Chart Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompileBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/visits/{visit_id}/waive-audit":{"post":{"tags":["ehr-sandbox"],"summary":"Waive","operationId":"waive_api_asclepius_ehr_sandbox_visits__visit_id__waive_audit_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WaiveBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/tasks":{"get":{"tags":["ehr-sandbox"],"summary":"Tasks","operationId":"tasks_api_asclepius_ehr_sandbox_tasks_get","parameters":[{"name":"split","in":"query","required":false,"schema":{"anyOf":[{"enum":["train","dev","heldout"],"type":"string"},{"type":"null"}],"title":"Split"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"enum":["ready","retired"],"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/tasks/{task_id}/sanity":{"post":{"tags":["ehr-sandbox"],"summary":"Sanity","operationId":"sanity_api_asclepius_ehr_sandbox_tasks__task_id__sanity_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/tasks/{task_id}/validate":{"post":{"tags":["ehr-sandbox"],"summary":"Validate Task","operationId":"validate_task_api_asclepius_ehr_sandbox_tasks__task_id__validate_post","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/runs":{"post":{"tags":["ehr-sandbox"],"summary":"Start Runs","operationId":"start_runs_api_asclepius_ehr_sandbox_runs_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/runs/{run_group}":{"get":{"tags":["ehr-sandbox"],"summary":"Run Status","operationId":"run_status_api_asclepius_ehr_sandbox_runs__run_group__get","parameters":[{"name":"run_group","in":"path","required":true,"schema":{"type":"string","title":"Run Group"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reports/{run_group}":{"get":{"tags":["ehr-sandbox"],"summary":"Get Report","operationId":"get_report_api_asclepius_ehr_sandbox_reports__run_group__get","parameters":[{"name":"run_group","in":"path","required":true,"schema":{"type":"string","title":"Run Group"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/summary":{"get":{"tags":["ehr-sandbox"],"summary":"Summary","operationId":"summary_api_asclepius_ehr_sandbox_summary_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/exclusions":{"post":{"tags":["ehr-sandbox"],"summary":"Exclusion","operationId":"exclusion_api_asclepius_ehr_sandbox_exclusions_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExclusionBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/admin/reviews":{"get":{"tags":["ehr-sandbox"],"summary":"Admin Reviews","operationId":"admin_reviews_api_asclepius_ehr_sandbox_admin_reviews_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reviews/queue":{"get":{"tags":["ehr-sandbox"],"summary":"Queue","operationId":"queue_api_asclepius_ehr_sandbox_reviews_queue_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reviews/{review_id}":{"get":{"tags":["ehr-sandbox"],"summary":"Review View","operationId":"review_view_api_asclepius_ehr_sandbox_reviews__review_id__get","parameters":[{"name":"review_id","in":"path","required":true,"schema":{"type":"string","title":"Review Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reviews/{review_id}/verdict":{"post":{"tags":["ehr-sandbox"],"summary":"Review Verdict","operationId":"review_verdict_api_asclepius_ehr_sandbox_reviews__review_id__verdict_post","parameters":[{"name":"review_id","in":"path","required":true,"schema":{"type":"string","title":"Review Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reviews/{review_id}/outcome":{"get":{"tags":["ehr-sandbox"],"summary":"Outcome","operationId":"outcome_api_asclepius_ehr_sandbox_reviews__review_id__outcome_get","parameters":[{"name":"review_id","in":"path","required":true,"schema":{"type":"string","title":"Review Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/reviews/{review_id}/reflection":{"post":{"tags":["ehr-sandbox"],"summary":"Reflection","operationId":"reflection_api_asclepius_ehr_sandbox_reviews__review_id__reflection_post","parameters":[{"name":"review_id","in":"path","required":true,"schema":{"type":"string","title":"Review Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/exports/package":{"post":{"tags":["ehr-sandbox"],"summary":"Export Package","operationId":"export_package_api_asclepius_ehr_sandbox_exports_package_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/ehr-sandbox/exports/{export_id}/{artifact}":{"get":{"tags":["ehr-sandbox"],"summary":"Download Export","operationId":"download_export_api_asclepius_ehr_sandbox_exports__export_id___artifact__get","parameters":[{"name":"export_id","in":"path","required":true,"schema":{"type":"string","title":"Export Id"}},{"name":"artifact","in":"path","required":true,"schema":{"enum":["archive","grader-key"],"type":"string","title":"Artifact"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/me":{"get":{"tags":["community"],"summary":"Me","operationId":"me_api_community_me_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/channels":{"get":{"tags":["community"],"summary":"Channels","operationId":"channels_api_community_channels_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/channels/{slug}/messages":{"get":{"tags":["community"],"summary":"Channel Messages","operationId":"channel_messages_api_community_channels__slug__messages_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"before","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Before"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"After"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["community"],"summary":"Post Message","operationId":"post_message_api_community_channels__slug__messages_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/messages/{message_id}":{"patch":{"tags":["community"],"summary":"Edit Message","operationId":"edit_message_api_community_messages__message_id__patch","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageEdit"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["community"],"summary":"Delete Message","operationId":"delete_message_api_community_messages__message_id__delete","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/messages/{message_id}/reactions":{"post":{"tags":["community"],"summary":"Toggle Reaction","operationId":"toggle_reaction_api_community_messages__message_id__reactions_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReactionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/messages/{message_id}/thread":{"get":{"tags":["community"],"summary":"Thread","operationId":"thread_api_community_messages__message_id__thread_get","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/channels/{slug}/read":{"post":{"tags":["community"],"summary":"Mark Read","operationId":"mark_read_api_community_channels__slug__read_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReadIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/prefs":{"get":{"tags":["community"],"summary":"Get Email Prefs","operationId":"get_email_prefs_api_community_prefs_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["community"],"summary":"Set Email Prefs","description":"Set any subset of the four knobs. An absent key is left alone.\n\nPartial rather than whole-object writes because the panel toggles one\nswitch at a time, and a whole-object PUT from a stale page would silently\nrevert a change made in another tab.","operationId":"set_email_prefs_api_community_prefs_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/unsubscribe":{"get":{"tags":["community"],"summary":"Unsubscribe","description":"One click, no sign-in required.\n\nAn unsubscribe link that makes someone log in first is an unsubscribe link\nthat gets a spam complaint instead, and one complaint costs the sending\ndomain that every other physician's mail goes through. The token only ever\nturns mail OFF, so the worst a leaked one can do is stop an email.\n\n``kind`` stops one stream instead of all of them, so the link at the foot\nof a pin notification can mean \"stop telling me about pins\". Without it the\nbehaviour is byte for byte what it always was, and it has to stay that way:\nevery link in mail already sent carries no kind, and a link that came to\nmean less than it said when it was sent would be the worse bug.","operationId":"unsubscribe_api_community_unsubscribe_get","parameters":[{"name":"token","in":"query","required":false,"schema":{"type":"string","default":"","title":"Token"}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","default":"","title":"Kind"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/badge":{"get":{"tags":["community"],"summary":"Badge","description":"Unread badge for the portal side-panel Community item (PRD §4). Soft\nendpoint: a non-member gets ``eligible: false`` rather than an error, so\nthe portal can decide whether to render the item at all.","operationId":"badge_api_community_badge_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/dms":{"get":{"tags":["community"],"summary":"List Dms","operationId":"list_dms_api_community_dms_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["community"],"summary":"Open Dm","description":"Get-or-create the conversation with another member. The peer must pass\nthe same §1 gate (verified contributor or staff) — you cannot DM an\naccount that cannot itself enter the community.","operationId":"open_dm_api_community_dms_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DmOpen"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/dms/group":{"post":{"tags":["community"],"summary":"Create Group","description":"Open a named group with colleagues who can themselves enter the community.\n\nThe same §1 gate as ``open_dm``: you cannot put an account in a group it\ncould not read. A named user who is not a member 404s rather than being\ndropped silently, because a group that quietly opened with two of the three\npeople you picked is worse than one that refused.","operationId":"create_group_api_community_dms_group_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GroupCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/dms/{dm_id}/members":{"post":{"tags":["community"],"summary":"Add Group Members","description":"Add colleagues to a group you are in.\n\nPARTICIPANTS ONLY, and deliberately not ``_dm_or_404``: that helper grants an\nadmin access to a case room, and \"can read this conversation\" is not the same\npermission as \"can decide who else reads it\". Membership is checked directly.\n\nScoped to ``kind='group'``. A case room's roster is owned by routing -- it is\nthe team on a case, and it changes when an assignment does, not when somebody\nin the room decides -- and a two-party DM's privacy is the entire thing it\nis: silently turning one into a three-way conversation would break a promise\nboth participants are relying on.","operationId":"add_group_members_api_community_dms__dm_id__members_post","parameters":[{"name":"dm_id","in":"path","required":true,"schema":{"type":"string","title":"Dm Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GroupMembersIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/dms/{dm_id}/messages":{"get":{"tags":["community"],"summary":"Dm Messages","operationId":"dm_messages_api_community_dms__dm_id__messages_get","parameters":[{"name":"dm_id","in":"path","required":true,"schema":{"type":"string","title":"Dm Id"}},{"name":"before","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Before"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"After"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["community"],"summary":"Post Dm Message","operationId":"post_dm_message_api_community_dms__dm_id__messages_post","parameters":[{"name":"dm_id","in":"path","required":true,"schema":{"type":"string","title":"Dm Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DmMessageIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/dms/{dm_id}/read":{"post":{"tags":["community"],"summary":"Mark Dm Read","operationId":"mark_dm_read_api_community_dms__dm_id__read_post","parameters":[{"name":"dm_id","in":"path","required":true,"schema":{"type":"string","title":"Dm Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReadIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/persona/avatar":{"get":{"tags":["community"],"summary":"Persona Avatar","description":"The Archangel account's picture.\n\nIts own route rather than the users avatar endpoint because the account is\na virtual author with no users row, which is deliberate: a real account for\nthe bot would show up in the member directory, the verification queue and\nthe buyer-facing exports. Same gate as everything else here, and a 404 when\nnobody has supplied a picture, which the client already handles by falling\nback to initials.","operationId":"persona_avatar_api_community_persona_avatar_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/members":{"get":{"tags":["community"],"summary":"Members Endpoint","operationId":"members_endpoint_api_community_members_get","parameters":[{"name":"specialty","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/members/{user_id}":{"get":{"tags":["community"],"summary":"Member Profile","description":"One colleague's full profile, fetched when somebody opens them.\n\nThe counterpart to the trim in ``public_member_summary``: the blurb and the\ntraining detail are what a member wants when they click a name, and they are\ndead weight in a list of a thousand people. Same gate, same scrub, same\n``member_map`` source, so this can show nothing the list could not.\n\nA user id that is not a member 404s exactly as an unknown one does, for the\nreason ``_visible_channel_or_404`` gives: the API is not an oracle for who\nholds an account here.","operationId":"member_profile_api_community_members__user_id__get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/search":{"get":{"tags":["community"],"summary":"Search","operationId":"search_api_community_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":200,"title":"Q"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/attachments":{"post":{"tags":["community"],"summary":"Upload Attachment","operationId":"upload_attachment_api_community_attachments_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_attachment_api_community_attachments_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/attachments/{asset_id}":{"get":{"tags":["community"],"summary":"Download Attachment","operationId":"download_attachment_api_community_attachments__asset_id__get","parameters":[{"name":"asset_id","in":"path","required":true,"schema":{"type":"string","title":"Asset Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/admin/flags":{"get":{"tags":["community"],"summary":"Admin Flags","description":"Repeat PHI-block offenders (category counts only — never content).","operationId":"admin_flags_api_community_admin_flags_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/admin/members/{user_id}/deactivate":{"post":{"tags":["community"],"summary":"Deactivate Member","operationId":"deactivate_member_api_community_admin_members__user_id__deactivate_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/admin/messages/{message_id}/digest-lead":{"post":{"tags":["community"],"summary":"Set Digest Lead","description":"`Set as top story` / `Clear breaking` (Digest Design PRD §2.2).\n\nRewrites ``payload_json`` and re-renders. NO RE-RUN: the model already\nanswered, the contract already accepted what it said, and asking it again\nto move a rule three inches would spend a call to get a different digest.\n\nWhat this can change is which item leads and whether the badge shows. What\nit cannot change is a single word on the card. That split is the whole\ndesign of the endpoint: every string in the payload arrived through\n``digest_contract.validate_payload`` and the house-style gate at the write\npath, and an override that accepted text would be a member-facing route\nthat writes unvalidated prose onto a post signed by the platform.\n\nClearing the badge is ``urgent: false``, and it is allowed on any lead.\nSETTING it is not offered here at all -- ``urgent`` is earned by one of four\nsame-day events that only the compose pass can see, and a button that\ngranted it would turn a rule into a preference.","operationId":"set_digest_lead_api_community_admin_messages__message_id__digest_lead_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigestLeadIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/admin/members/{user_id}/reactivate":{"post":{"tags":["community"],"summary":"Reactivate Member","operationId":"reactivate_member_api_community_admin_members__user_id__reactivate_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","title":"User Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/handoff/redeem":{"post":{"tags":["community"],"summary":"Redeem Handoff","description":"Exchange a portal handoff code for an Asclepius session. The code is\nsingle-use and short-lived; the §1 gate is re-checked at redemption.","operationId":"redeem_handoff_api_community_handoff_redeem_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HandoffRedeem"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/ws-ticket":{"post":{"tags":["community"],"summary":"Ws Ticket","operationId":"ws_ticket_api_community_ws_ticket_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/community/unread":{"get":{"tags":["community"],"summary":"Portal Unread","description":"Rail-badge total for the portal side panel. Soft for non-members\n(0, not an error) so the panel never surfaces a community error.","operationId":"portal_unread_community_unread_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/community/handoff":{"post":{"tags":["community"],"summary":"Portal Handoff","operationId":"portal_handoff_community_handoff_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/community/join/{token}":{"get":{"tags":["community"],"summary":"Redeem Community Invite","operationId":"redeem_community_invite_community_join__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/events":{"post":{"tags":["community-social"],"summary":"Create Event","operationId":"create_event_api_community_events_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["community-social"],"summary":"List Events","operationId":"list_events_api_community_events_get","parameters":[{"name":"scope","in":"query","required":false,"schema":{"type":"string","default":"upcoming","title":"Scope"}},{"name":"channel_slug","in":"query","required":false,"schema":{"type":"string","default":"events","title":"Channel Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/events/{event_id}":{"get":{"tags":["community-social"],"summary":"Get Event","operationId":"get_event_api_community_events__event_id__get","parameters":[{"name":"event_id","in":"path","required":true,"schema":{"type":"integer","title":"Event Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/events/{event_id}/rsvp":{"post":{"tags":["community-social"],"summary":"Rsvp Event","operationId":"rsvp_event_api_community_events__event_id__rsvp_post","parameters":[{"name":"event_id","in":"path","required":true,"schema":{"type":"integer","title":"Event Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/events/{event_id}/cancel":{"post":{"tags":["community-social"],"summary":"Cancel Event","operationId":"cancel_event_api_community_events__event_id__cancel_post","parameters":[{"name":"event_id","in":"path","required":true,"schema":{"type":"integer","title":"Event Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/events/{event_id}/calendar.ics":{"get":{"tags":["community-social"],"summary":"Event Ics","operationId":"event_ics_api_community_events__event_id__calendar_ics_get","parameters":[{"name":"event_id","in":"path","required":true,"schema":{"type":"integer","title":"Event Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/polls":{"post":{"tags":["community-social"],"summary":"Create Poll","operationId":"create_poll_api_community_polls_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PollIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/polls/{poll_id}/vote":{"post":{"tags":["community-social"],"summary":"Vote Poll","operationId":"vote_poll_api_community_polls__poll_id__vote_post","parameters":[{"name":"poll_id","in":"path","required":true,"schema":{"type":"integer","title":"Poll Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VoteIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/polls/{poll_id}/close":{"post":{"tags":["community-social"],"summary":"Close Poll","operationId":"close_poll_api_community_polls__poll_id__close_post","parameters":[{"name":"poll_id","in":"path","required":true,"schema":{"type":"integer","title":"Poll Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/messages/{message_id}/pin":{"post":{"tags":["community-social"],"summary":"Pin Message","operationId":"pin_message_api_community_messages__message_id__pin_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["community-social"],"summary":"Unpin Message","operationId":"unpin_message_api_community_messages__message_id__pin_delete","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"integer","title":"Message Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/channels/{slug}/pins":{"get":{"tags":["community-social"],"summary":"List Pins","operationId":"list_pins_api_community_channels__slug__pins_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/channels/{slug}/bookmarks":{"post":{"tags":["community-social"],"summary":"Add Bookmark","operationId":"add_bookmark_api_community_channels__slug__bookmarks_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BookmarkIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["community-social"],"summary":"List Bookmarks","operationId":"list_bookmarks_api_community_channels__slug__bookmarks_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/community/bookmarks/{bookmark_id}":{"delete":{"tags":["community-social"],"summary":"Remove Bookmark","operationId":"remove_bookmark_api_community_bookmarks__bookmark_id__delete","parameters":[{"name":"bookmark_id","in":"path","required":true,"schema":{"type":"integer","title":"Bookmark Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/leads":{"post":{"tags":["leads"],"summary":"Submit Lead","operationId":"submit_lead_api_leads_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/leads/admin":{"get":{"tags":["leads"],"summary":"List Leads Admin","description":"Read the submissions back, newest first.\n\nLives here rather than in the admin router because the write lives here: the\ntable is a team-store table, this module already holds the team-store handle,\nand splitting reader from writer across two routers is how the two drift\nabout what a source string means.\n\nEvery source is returned by default and ``source`` narrows it, because the\nhealth-system pipeline and the buyer pipeline are read by different people\nand neither wants to scroll past the other. Honeypot submissions cannot\nappear: they were never stored (``submit_lead`` returns before the write).\n\nAn unknown ``source`` is an empty page rather than a 422. The filter names a\nstream we may add to or rename, and a console that 500s because a chip is a\nrelease behind is worse than one that shows nothing.","operationId":"list_leads_admin_api_leads_admin_get","parameters":[{"name":"source","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"before_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Before Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/leads/admin/{lead_id}/booked":{"post":{"tags":["leads"],"summary":"Mark Lead Booked","description":"Record that this lead booked its call.\n\nAdmin-gated exactly like the reader above, and for the same reason: the lead\ntable is an audit trail of attestations, and who may write on one is the\nsame question as who may read one.\n\nIt exists because nothing else can know. The booking happens on Calendly,\nwhich does not call us back, so the only thing that can say a call was\nbooked is the person who saw it appear in their calendar. What the stamp\nBUYS is the reminder: ``partner_lead_nudge`` will not chase a row whose call\nis booked, so this is how an operator stops a letter that would otherwise\nask a partner to book a meeting they are already coming to.\n\nIdempotent. Clicking it twice is an operator clicking it twice, and the\nfirst time is the one that is true, so a second call succeeds and changes\nnothing.","operationId":"mark_lead_booked_api_leads_admin__lead_id__booked_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"integer","title":"Lead Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/taxonomy":{"get":{"tags":["gold"],"summary":"Get Taxonomy","operationId":"get_taxonomy_api_gold_taxonomy_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits":{"post":{"tags":["gold"],"summary":"Create Visit","operationId":"create_visit_api_gold_visits_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateVisitRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["gold"],"summary":"List Visits","operationId":"list_visits_api_gold_visits_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/consent":{"post":{"tags":["gold"],"summary":"Record Consent","operationId":"record_consent_api_gold_visits__visit_id__consent_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/audio":{"post":{"tags":["gold"],"summary":"Upload Audio","operationId":"upload_audio_api_gold_visits__visit_id__audio_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_audio_api_gold_visits__visit_id__audio_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}":{"get":{"tags":["gold"],"summary":"Get Visit","operationId":"get_visit_api_gold_visits__visit_id__get","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/stream-ticket":{"post":{"tags":["gold"],"summary":"Visit Stream Ticket","operationId":"visit_stream_ticket_api_gold_visits__visit_id__stream_ticket_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/stream":{"get":{"tags":["gold"],"summary":"Stream Visit","operationId":"stream_visit_api_gold_visits__visit_id__stream_get","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/submit":{"post":{"tags":["gold"],"summary":"Submit Visit","operationId":"submit_visit_api_gold_visits__visit_id__submit_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/visits/{visit_id}/approve":{"post":{"tags":["gold"],"summary":"Approve Visit","operationId":"approve_visit_api_gold_visits__visit_id__approve_post","parameters":[{"name":"visit_id","in":"path","required":true,"schema":{"type":"string","title":"Visit Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApproveRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/stats":{"get":{"tags":["gold"],"summary":"Get Stats","operationId":"get_stats_api_gold_stats_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/gold/export":{"post":{"tags":["gold"],"summary":"Export Records","operationId":"export_records_api_gold_export_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/routers__gold__ExportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/projects/invites/{slug}":{"get":{"tags":["projects"],"summary":"Invite","operationId":"invite_api_asclepius_projects_invites__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"invite","in":"query","required":true,"schema":{"type":"string","title":"Invite"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects":{"get":{"tags":["projects"],"summary":"Mine","operationId":"mine_api_asclepius_me_projects_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/projects/recruiting":{"get":{"tags":["projects"],"summary":"Recruiting Projects","operationId":"recruiting_projects_api_asclepius_projects_recruiting_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/entry":{"get":{"tags":["projects"],"summary":"Entry State","operationId":"entry_state_api_asclepius_me_projects__project_id__entry_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/entry/profile":{"patch":{"tags":["projects"],"summary":"Entry Profile","operationId":"entry_profile_api_asclepius_me_projects__project_id__entry_profile_patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/slack-confirmed":{"post":{"tags":["projects"],"summary":"Entry Slack Confirmed","operationId":"entry_slack_confirmed_api_asclepius_me_projects__project_id__slack_confirmed_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/project-offer":{"post":{"tags":["projects"],"summary":"Entry Project Offer","operationId":"entry_project_offer_api_asclepius_me_projects__project_id__project_offer_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/terms/decline":{"post":{"tags":["projects"],"summary":"Entry Terms Decline","operationId":"entry_terms_decline_api_asclepius_me_projects__project_id__terms_decline_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/payout-preference":{"get":{"tags":["projects"],"summary":"Payout Preference","operationId":"payout_preference_api_asclepius_me_payout_preference_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["projects"],"summary":"Update Payout Preference","operationId":"update_payout_preference_api_asclepius_me_payout_preference_put","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/timer":{"post":{"tags":["projects"],"summary":"Entry Timer","operationId":"entry_timer_api_asclepius_me_projects__project_id__timer_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/chat-click":{"post":{"tags":["projects"],"summary":"Entry Chat Click","operationId":"entry_chat_click_api_asclepius_me_projects__project_id__chat_click_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}":{"get":{"tags":["projects"],"summary":"Detail","operationId":"detail_api_asclepius_me_projects__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/enroll":{"post":{"tags":["projects"],"summary":"Enroll","operationId":"enroll_api_asclepius_me_projects__project_id__enroll_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/enroll-signup":{"post":{"tags":["projects"],"summary":"Enroll Signup","operationId":"enroll_signup_api_asclepius_me_projects_enroll_signup_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/agreement":{"get":{"tags":["projects"],"summary":"Agreement","operationId":"agreement_api_asclepius_me_projects__project_id__agreement_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/agreement/details":{"patch":{"tags":["projects"],"summary":"Details","operationId":"details_api_asclepius_me_projects__project_id__agreement_details_patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/agreement/accept":{"post":{"tags":["projects"],"summary":"Accept","operationId":"accept_api_asclepius_me_projects__project_id__agreement_accept_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/agreement/download":{"get":{"tags":["projects"],"summary":"Download","operationId":"download_api_asclepius_me_projects__project_id__agreement_download_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/terms":{"get":{"tags":["projects"],"summary":"Project Terms","operationId":"project_terms_api_asclepius_me_projects__project_id__terms_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/terms/details":{"patch":{"tags":["projects"],"summary":"Project Terms Details","operationId":"project_terms_details_api_asclepius_me_projects__project_id__terms_details_patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/terms/accept":{"post":{"tags":["projects"],"summary":"Project Terms Accept","operationId":"project_terms_accept_api_asclepius_me_projects__project_id__terms_accept_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/terms/download":{"get":{"tags":["projects"],"summary":"Project Terms Download","operationId":"project_terms_download_api_asclepius_me_projects__project_id__terms_download_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/compensation":{"get":{"tags":["projects"],"summary":"Project Compensation","operationId":"project_compensation_api_asclepius_me_projects__project_id__compensation_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/rate-offers/{offer_id}/accept":{"post":{"tags":["projects"],"summary":"Accept Rate Offer","operationId":"accept_rate_offer_api_asclepius_me_projects__project_id__rate_offers__offer_id__accept_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"offer_id","in":"path","required":true,"schema":{"type":"string","title":"Offer Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/rate-offers/{offer_id}/counter":{"post":{"tags":["projects"],"summary":"Counter Rate Offer","operationId":"counter_rate_offer_api_asclepius_me_projects__project_id__rate_offers__offer_id__counter_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"offer_id","in":"path","required":true,"schema":{"type":"string","title":"Offer Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/rate-offers/{offer_id}/download":{"get":{"tags":["projects"],"summary":"Download Rate Offer","operationId":"download_rate_offer_api_asclepius_me_projects__project_id__rate_offers__offer_id__download_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"offer_id","in":"path","required":true,"schema":{"type":"string","title":"Offer Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/booking-link":{"get":{"tags":["projects"],"summary":"Booking Link","operationId":"booking_link_api_asclepius_me_projects__project_id__booking_link_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/bookings":{"get":{"tags":["projects"],"summary":"Bookings","operationId":"bookings_api_asclepius_me_projects__project_id__bookings_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/ledger":{"get":{"tags":["projects"],"summary":"Ledger","operationId":"ledger_api_asclepius_me_projects__project_id__ledger_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/financial-history":{"get":{"tags":["projects"],"summary":"Financial History","operationId":"financial_history_api_asclepius_me_projects__project_id__financial_history_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":25,"title":"Limit"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/setup/start":{"post":{"tags":["projects"],"summary":"Setup Start","operationId":"setup_start_api_asclepius_me_projects__project_id__setup_start_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/setup/rate":{"post":{"tags":["projects"],"summary":"Setup Rate","operationId":"setup_rate_api_asclepius_me_projects__project_id__setup_rate_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/chat/open":{"post":{"tags":["projects"],"summary":"Chat Open","operationId":"chat_open_api_asclepius_me_projects__project_id__chat_open_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/requests":{"get":{"tags":["projects"],"summary":"Requests","operationId":"requests_api_asclepius_me_projects__project_id__requests_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":25,"title":"Limit"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects"],"summary":"Submit Request","operationId":"submit_request_api_asclepius_me_projects__project_id__requests_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/requests/{request_id}":{"get":{"tags":["projects"],"summary":"Request Detail","operationId":"request_detail_api_asclepius_me_projects__project_id__requests__request_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/requests/{request_id}/{action}":{"post":{"tags":["projects"],"summary":"Request Action","operationId":"request_action_api_asclepius_me_projects__project_id__requests__request_id___action__post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"action","in":"path","required":true,"schema":{"type":"string","title":"Action"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/me/projects/{project_id}/support":{"post":{"tags":["projects"],"summary":"Support","operationId":"support_api_asclepius_me_projects__project_id__support_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/shared-slack":{"get":{"tags":["projects"],"summary":"Shared Slack Setting","operationId":"shared_slack_setting_api_asclepius_admin_projects_shared_slack_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["projects"],"summary":"Update Shared Slack","operationId":"update_shared_slack_api_asclepius_admin_projects_shared_slack_put","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/requests":{"get":{"tags":["projects"],"summary":"Admin Requests","operationId":"admin_requests_api_asclepius_admin_projects__project_id__requests_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":25,"title":"Limit"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/requests/{request_id}":{"get":{"tags":["projects"],"summary":"Admin Request Detail","operationId":"admin_request_detail_api_asclepius_admin_projects__project_id__requests__request_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/requests/{request_id}/respond":{"post":{"tags":["projects"],"summary":"Respond Request","operationId":"respond_request_api_asclepius_admin_projects__project_id__requests__request_id__respond_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/requests/{request_id}/retry-notifications":{"post":{"tags":["projects"],"summary":"Retry Notifications","operationId":"retry_notifications_api_asclepius_admin_projects__project_id__requests__request_id__retry_notifications_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/rate-reviews":{"get":{"tags":["projects"],"summary":"All Rate Reviews","operationId":"all_rate_reviews_api_asclepius_admin_projects_rate_reviews_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/rate-reviews":{"get":{"tags":["projects"],"summary":"Rate Reviews","operationId":"rate_reviews_api_asclepius_admin_projects__project_id__rate_reviews_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/rate-offers":{"post":{"tags":["projects"],"summary":"Publish Rate Offer","operationId":"publish_rate_offer_api_asclepius_admin_projects__project_id__members__member_id__rate_offers_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/notifications":{"get":{"tags":["projects"],"summary":"Project Notifications","operationId":"project_notifications_api_asclepius_admin_projects__project_id__notifications_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/notifications/{notice_id}/retry":{"post":{"tags":["projects"],"summary":"Retry Project Notification","operationId":"retry_project_notification_api_asclepius_admin_projects__project_id__notifications__notice_id__retry_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"notice_id","in":"path","required":true,"schema":{"type":"string","title":"Notice Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/entry-draft":{"post":{"tags":["projects"],"summary":"Entry Project Draft","operationId":"entry_project_draft_api_asclepius_admin_projects_entry_draft_post","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/simple-setup/{campaign}":{"get":{"tags":["projects"],"summary":"Simple Setup Readiness","operationId":"simple_setup_readiness_api_asclepius_admin_projects_simple_setup__campaign__get","parameters":[{"name":"campaign","in":"path","required":true,"schema":{"type":"string","title":"Campaign"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects"],"summary":"Simple Setup","operationId":"simple_setup_api_asclepius_admin_projects_simple_setup__campaign__post","parameters":[{"name":"campaign","in":"path","required":true,"schema":{"type":"string","title":"Campaign"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/nephro-setup":{"get":{"tags":["projects"],"summary":"Nephro Setup Readiness","description":"The read-only configuration check from scripts/setup_nephro.py, for operators without a container shell.","operationId":"nephro_setup_readiness_api_asclepius_admin_projects_nephro_setup_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects"],"summary":"Nephro Setup","description":"Prepare (and with activate=true, open) the reusable nephro campaign.\n\nSame repeatable helper as scripts/setup_nephro.py --apply [--activate]; reruns\nnever duplicate the project, template, campaign or rate, and activation is\nrefused while the readiness report lists blockers.","operationId":"nephro_setup_api_asclepius_admin_projects_nephro_setup_post","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/terms-source":{"get":{"tags":["projects"],"summary":"Project Terms Source","operationId":"project_terms_source_api_asclepius_admin_projects_terms_source_get","parameters":[{"name":"simple","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Simple"}},{"name":"project_id","in":"query","required":false,"schema":{"type":"string","default":"","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects":{"get":{"tags":["projects"],"summary":"Admin List","operationId":"admin_list_api_asclepius_admin_projects_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects"],"summary":"Create","operationId":"create_api_asclepius_admin_projects_post","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/nephrology-draft":{"post":{"tags":["projects"],"summary":"Nephrology","operationId":"nephrology_api_asclepius_admin_projects_nephrology_draft_post","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/agreement-source":{"get":{"tags":["projects"],"summary":"Source","operationId":"source_api_asclepius_admin_projects_agreement_source_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}":{"patch":{"tags":["projects"],"summary":"Update","operationId":"update_api_asclepius_admin_projects__project_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["projects"],"summary":"Admin Detail","operationId":"admin_detail_api_asclepius_admin_projects__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/roles":{"post":{"tags":["projects"],"summary":"Assign Project Role","operationId":"assign_project_role_api_asclepius_admin_projects__project_id__roles_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/publish-entry":{"post":{"tags":["projects"],"summary":"Publish Project Entry","operationId":"publish_project_entry_api_asclepius_admin_projects__project_id__publish_entry_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/agreement/download":{"get":{"tags":["projects"],"summary":"Download Member Agreement","operationId":"download_member_agreement_api_asclepius_admin_projects__project_id__members__member_id__agreement_download_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members":{"post":{"tags":["projects"],"summary":"Add Member","operationId":"add_member_api_asclepius_admin_projects__project_id__members_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/access-flag":{"post":{"tags":["projects"],"summary":"Member Access Flag","operationId":"member_access_flag_api_asclepius_admin_projects__project_id__members__member_id__access_flag_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/agreement":{"get":{"tags":["projects"],"summary":"Member Agreement","operationId":"member_agreement_api_asclepius_admin_projects__project_id__members__member_id__agreement_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/{action}":{"post":{"tags":["projects"],"summary":"Project Action","operationId":"project_action_api_asclepius_admin_projects__project_id___action__post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"action","in":"path","required":true,"schema":{"type":"string","title":"Action"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/compensation":{"get":{"tags":["projects"],"summary":"Compensation","operationId":"compensation_api_asclepius_admin_projects__project_id__members__member_id__compensation_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/members/{member_id}/rate-research":{"post":{"tags":["projects"],"summary":"Rate Research","operationId":"rate_research_api_asclepius_admin_projects__project_id__members__member_id__rate_research_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"member_id","in":"path","required":true,"schema":{"type":"string","title":"Member Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/{entity}/{identifier}/{action}":{"post":{"tags":["projects"],"summary":"Record Action","operationId":"record_action_api_asclepius_admin_projects__project_id___entity___identifier___action__post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"entity","in":"path","required":true,"schema":{"type":"string","title":"Entity"}},{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}},{"name":"action","in":"path","required":true,"schema":{"type":"string","title":"Action"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","maxLength":200,"title":"Idempotency-Key"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/admin/projects/{project_id}/export.csv":{"get":{"tags":["projects"],"summary":"Export","operationId":"export_api_asclepius_admin_projects__project_id__export_csv_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","default":"ledger","title":"Kind"}},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start"}},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End"}},{"name":"reporting_timezone","in":"query","required":false,"schema":{"type":"string","default":"America/Los_Angeles","title":"Reporting Timezone"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/projects/calendly/{integration_id}/webhook":{"post":{"tags":["projects"],"summary":"Webhook","operationId":"webhook_api_asclepius_projects_calendly__integration_id__webhook_post","parameters":[{"name":"integration_id","in":"path","required":true,"schema":{"type":"string","title":"Integration Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/asclepius/projects/calendly/{target_realm}/{integration_id}/webhook":{"post":{"tags":["projects"],"summary":"Realm Webhook","operationId":"realm_webhook_api_asclepius_projects_calendly__target_realm___integration_id__webhook_post","parameters":[{"name":"target_realm","in":"path","required":true,"schema":{"type":"string","title":"Target Realm"}},{"name":"integration_id","in":"path","required":true,"schema":{"type":"string","title":"Integration Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AccessBody":{"properties":{"username":{"type":"string","maxLength":128,"minLength":1,"title":"Username"},"password":{"type":"string","maxLength":1024,"minLength":1,"format":"password","title":"Password","writeOnly":true}},"additionalProperties":false,"type":"object","required":["username","password"],"title":"AccessBody"},"ActiveProblem":{"properties":{"icd10":{"type":"string","title":"Icd10"},"description":{"type":"string","title":"Description","default":""},"status":{"type":"string","enum":["ACTIVE","RESOLVED","CHRONIC"],"title":"Status","default":"ACTIVE"},"onset_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Onset Date"},"severity_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Severity Note"}},"type":"object","required":["icd10"],"title":"ActiveProblem"},"ActiveProblemsInput":{"properties":{"problems":{"items":{"$ref":"#/components/schemas/ActiveProblem"},"type":"array","title":"Problems"},"functional_status":{"type":"string","enum":["INDEPENDENT","PARTIALLY_DEPENDENT","TOTALLY_DEPENDENT","UNKNOWN"],"title":"Functional Status","default":"INDEPENDENT"},"bmi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Bmi"},"asa_class_if_documented":{"anyOf":[{"type":"integer","enum":[1,2,3,4,5]},{"type":"null"}],"title":"Asa Class If Documented"}},"type":"object","title":"ActiveProblemsInput"},"AddMemberBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"full_name":{"type":"string","title":"Full Name"},"email":{"type":"string","format":"email","title":"Email"},"role":{"type":"string","title":"Role"}},"type":"object","required":["token","full_name","email","role"],"title":"AddMemberBody"},"AdminLoginRequest":{"properties":{"username":{"type":"string","title":"Username"},"password":{"type":"string","title":"Password"}},"type":"object","required":["username","password"],"title":"AdminLoginRequest"},"AgreementSignRequest":{"properties":{"typed_name":{"type":"string","title":"Typed Name"},"signed_initials":{"type":"string","title":"Signed Initials"},"consent_esign":{"type":"boolean","title":"Consent Esign","default":false},"doc_sha256":{"type":"string","title":"Doc Sha256","default":""}},"type":"object","required":["typed_name","signed_initials"],"title":"AgreementSignRequest","description":"What a physician's clickwrap has to capture.\n\nNo `authority_affirmed`: a physician binds themselves and there is nothing\nto have authority over. `signed_initials` takes its place as the act of\nsigning, matching the onboarding form, where typing initials has always been\nwhat the copy calls an electronic signature."},"AllergiesInput":{"properties":{"allergies":{"items":{"$ref":"#/components/schemas/Allergy"},"type":"array","title":"Allergies"}},"type":"object","title":"AllergiesInput"},"Allergy":{"properties":{"substance":{"type":"string","title":"Substance"},"reaction_type":{"type":"string","enum":["ANAPHYLAXIS","RASH","GI","ANGIOEDEMA","OTHER","UNKNOWN"],"title":"Reaction Type","default":"UNKNOWN"},"severity":{"anyOf":[{"type":"string","enum":["MILD","MODERATE","SEVERE"]},{"type":"null"}],"title":"Severity"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["substance"],"title":"Allergy"},"AllergyItem":{"properties":{"substance":{"type":"string","title":"Substance"},"reaction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reaction"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"}},"additionalProperties":false,"type":"object","required":["substance"],"title":"AllergyItem"},"AllocateBody":{"properties":{"task_ids":{"items":{"type":"string"},"type":"array","title":"Task Ids"},"labels_per_case":{"type":"integer","maximum":5.0,"minimum":1.0,"title":"Labels Per Case","default":2},"reviewers_per_case":{"type":"integer","maximum":3.0,"minimum":0.0,"title":"Reviewers Per Case","default":1},"max_share":{"type":"number","maximum":1.0,"exclusiveMinimum":0.0,"title":"Max Share","default":0.35},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"due_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Due At"},"exclusive_hours":{"anyOf":[{"type":"integer","maximum":720.0,"minimum":1.0},{"type":"null"}],"title":"Exclusive Hours"},"user_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"User Ids"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"to_all":{"type":"boolean","title":"To All","default":false},"roles":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Roles"}},"type":"object","title":"AllocateBody","description":"Which cases to allocate, and to whom.\n\n``dry_run`` defaults to TRUE. Same shape as ingest promotion, and for the\nsame reason: an admin should be able to iterate on an allocation before a\nphysician is told to do anything."},"AnnotateRequest":{"properties":{"run_id":{"type":"string","title":"Run Id"},"portal_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Version"},"annotation":{"additionalProperties":true,"type":"object","title":"Annotation"}},"type":"object","required":["run_id"],"title":"AnnotateRequest"},"Approval":{"properties":{"fingerprint":{"type":"string","maxLength":64,"minLength":64,"title":"Fingerprint"}},"type":"object","required":["fingerprint"],"title":"Approval"},"ApproveBody":{"properties":{"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"agreement_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agreement Ref"}},"type":"object","title":"ApproveBody"},"ApproveEarningBody":{"properties":{"note":{"type":"string","maxLength":500,"title":"Note","default":""}},"type":"object","title":"ApproveEarningBody"},"ApproveForExportRequest":{"properties":{"submission_ids":{"items":{"type":"string"},"type":"array","maxItems":500,"title":"Submission Ids"}},"type":"object","title":"ApproveForExportRequest"},"ApproveRequest":{"properties":{"transcript_deid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript Deid"},"gold_note_deid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gold Note Deid"}},"type":"object","title":"ApproveRequest"},"AscPortalHandoffConsumeRequest":{"properties":{"handoff_code":{"type":"string","title":"Handoff Code"}},"type":"object","required":["handoff_code"],"title":"AscPortalHandoffConsumeRequest","description":"Trade a short-lived handoff code (minted by POST /auth/portal-handoff)\nfor the Asclepius session token it was issued for — see main.py's\ndoctor-portal handoff for the pattern this mirrors."},"AsclepiusAddMemberBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"full_name":{"type":"string","title":"Full Name"},"email":{"type":"string","format":"email","title":"Email"},"role":{"type":"string","title":"Role"}},"type":"object","required":["token","full_name","email","role"],"title":"AsclepiusAddMemberBody"},"AsclepiusAdminInviteRequest":{"properties":{"name":{"type":"string","title":"Name"},"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["name","email"],"title":"AsclepiusAdminInviteRequest"},"AsclepiusAttestationsBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"attestations":{"additionalProperties":true,"type":"object","title":"Attestations"}},"type":"object","required":["token","attestations"],"title":"AsclepiusAttestationsBody"},"AsclepiusCredentialsBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"credentials":{"additionalProperties":true,"type":"object","title":"Credentials"}},"type":"object","required":["token","credentials"],"title":"AsclepiusCredentialsBody"},"AsclepiusInstitutionBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"org_name":{"type":"string","title":"Org Name"},"specialty":{"type":"string","title":"Specialty"},"phone":{"type":"string","title":"Phone"}},"type":"object","required":["token","org_name","specialty","phone"],"title":"AsclepiusInstitutionBody"},"AsclepiusPasswordBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"password":{"type":"string","title":"Password"}},"type":"object","required":["token","password"],"title":"AsclepiusPasswordBody"},"AssignInitialTierRequest":{"properties":{"input":{"$ref":"#/components/schemas/InitialTierInput"}},"type":"object","required":["input"],"title":"AssignInitialTierRequest","description":"Wraps an `InitialTierInput` so future versions can attach metadata."},"AttestBody":{"properties":{"type":{"type":"string","title":"Type"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["type"],"title":"AttestBody"},"BatchDraft":{"properties":{"earning_ids":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Earning Ids"}},"type":"object","required":["earning_ids"],"title":"BatchDraft"},"BattleCardEngagement":{"properties":{"views":{"items":{"type":"integer"},"type":"array","title":"Views"}},"type":"object","title":"BattleCardEngagement","description":"Battle-card engagement state (PRD §6.2)."},"BattleCardEvent":{"properties":{"episode_id":{"type":"string","title":"Episode Id"},"dwell_ms":{"type":"integer","minimum":0.0,"title":"Dwell Ms","default":0},"scroll_depth_pct":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Scroll Depth Pct","default":0}},"type":"object","required":["episode_id"],"title":"BattleCardEvent"},"BillingCode":{"properties":{"system":{"type":"string","title":"System"},"code":{"type":"string","title":"Code"},"verified_by":{"type":"string","title":"Verified By","default":"clinician"}},"type":"object","required":["system","code"],"title":"BillingCode"},"Body_asclepius_cv_upload_api_onboarding_asclepius_cv_post":{"properties":{"token":{"type":"string","title":"Token"},"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["token","file"],"title":"Body_asclepius_cv_upload_api_onboarding_asclepius_cv_post"},"Body_create_eligibility_batch_api_eligibility_batches_post":{"properties":{"files":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Files"}},"type":"object","required":["files"],"title":"Body_create_eligibility_batch_api_eligibility_batches_post"},"Body_hs_upload_api_asclepius_hs_uploads_post":{"properties":{"files":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Files"},"request_id":{"type":"string","title":"Request Id","default":""}},"type":"object","required":["files"],"title":"Body_hs_upload_api_asclepius_hs_uploads_post"},"Body_ingest_image_asset_api_asclepius_assets_ingest_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"task_id":{"type":"string","title":"Task Id"},"modality":{"type":"string","title":"Modality"},"label":{"type":"string","title":"Label","default":""},"findings":{"type":"string","title":"Findings","default":""},"page":{"type":"integer","title":"Page","default":1}},"type":"object","required":["file","task_id","modality"],"title":"Body_ingest_image_asset_api_asclepius_assets_ingest_post"},"Body_partner_upload_api_asclepius_partner_uploads_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"description":{"type":"string","title":"Description","default":""}},"type":"object","required":["file"],"title":"Body_partner_upload_api_asclepius_partner_uploads_post"},"Body_provider_upload_api_asclepius_provider_uploads_post":{"properties":{"files":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Files"}},"type":"object","required":["files"],"title":"Body_provider_upload_api_asclepius_provider_uploads_post"},"Body_transcribe_audio_api_asclepius_transcribe_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_transcribe_audio_api_asclepius_transcribe_post"},"Body_upload_attachment_api_community_attachments_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_attachment_api_community_attachments_post"},"Body_upload_audio_api_gold_visits__visit_id__audio_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"difficulty_tags":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Difficulty Tags"},"languages":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Languages"}},"type":"object","required":["file"],"title":"Body_upload_audio_api_gold_visits__visit_id__audio_post"},"Body_upload_eligibility_document_api_eligibility_documents_post":{"properties":{"patientId":{"type":"string","title":"Patientid"},"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["patientId","file"],"title":"Body_upload_eligibility_document_api_eligibility_documents_post"},"Body_upload_intraop_pdf_api_episodes__patient_id__intraop_form_pdf_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_intraop_pdf_api_episodes__patient_id__intraop_form_pdf_post"},"Body_upload_my_avatar_api_asclepius_me_avatar_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_my_avatar_api_asclepius_me_avatar_post"},"Body_upload_my_document_api_asclepius_me_documents__kind__post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_my_document_api_asclepius_me_documents__kind__post"},"Body_upload_onboarding_demo_api_asclepius_admin_assets_onboarding_demo_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_onboarding_demo_api_asclepius_admin_assets_onboarding_demo_post"},"Body_upload_pdf_api_upload_pdf_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_pdf_api_upload_pdf_post"},"Body_upload_tasks_file_api_asclepius_tasks_upload_file_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_tasks_file_api_asclepius_tasks_upload_file_post"},"BookmarkIn":{"properties":{"title":{"type":"string","maxLength":120,"minLength":1,"title":"Title"},"url":{"type":"string","maxLength":1000,"minLength":1,"title":"Url"}},"type":"object","required":["title","url"],"title":"BookmarkIn"},"BuildBody":{"properties":{"upload_id":{"type":"string","maxLength":200,"minLength":1,"title":"Upload Id"}},"additionalProperties":false,"type":"object","required":["upload_id"],"title":"BuildBody"},"BuyerDeliveryRequest":{"properties":{"buyer_name":{"type":"string","title":"Buyer Name"},"buyer_email":{"type":"string","title":"Buyer Email"},"organizations":{"items":{"type":"string"},"type":"array","title":"Organizations","default":[]},"since":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"},"until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Until"},"profile":{"type":"string","title":"Profile","default":"default"},"data_format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Data Format"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"include_exported":{"type":"boolean","title":"Include Exported","default":true},"exclusive":{"type":"boolean","title":"Exclusive","default":false},"license_expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Expires At"}},"type":"object","required":["buyer_name","buyer_email"],"title":"BuyerDeliveryRequest","description":"Admin sends a dataset to a buyer's secure workspace. Scope the data by one\nor more organizations (checkbox multi-select) and/or a time window, package it\nwith the chosen profile/format, and deliver it to the buyer by email."},"CalibrationSubmitBody":{"properties":{"responses":{"additionalProperties":{"additionalProperties":true,"type":"object"},"type":"object","title":"Responses"}},"type":"object","required":["responses"],"title":"CalibrationSubmitBody"},"CandidateAnswer":{"properties":{"id":{"type":"string","title":"Id"},"text":{"type":"string","title":"Text"},"generator_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Generator Model"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"baseline_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Baseline Model"}},"type":"object","required":["id","text"],"title":"CandidateAnswer"},"CandidateGenRequest":{"properties":{"prompt":{"type":"string","title":"Prompt"},"specialty":{"type":"string","title":"Specialty","default":"general"},"difficulty":{"type":"string","title":"Difficulty","default":"medium"},"capture_reasoning":{"type":"boolean","title":"Capture Reasoning","default":false},"max_labels":{"type":"integer","title":"Max Labels","default":1},"grounding_mode":{"type":"string","title":"Grounding Mode","default":"optional"}},"type":"object","required":["prompt"],"title":"CandidateGenRequest"},"CareGoalRequest":{"properties":{"care_goal_changed":{"type":"boolean","title":"Care Goal Changed"}},"type":"object","required":["care_goal_changed"],"title":"CareGoalRequest"},"CareTeamMessageSendBody":{"properties":{"message":{"type":"string","title":"Message"},"escalation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Escalation Id"}},"type":"object","required":["message"],"title":"CareTeamMessageSendBody"},"CareTeamNotificationRequest":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"message":{"type":"string","title":"Message"}},"type":"object","required":["patient_id","message"],"title":"CareTeamNotificationRequest"},"CareTeamPatientReplyBody":{"properties":{"message":{"type":"string","title":"Message"},"recipient_email":{"type":"string","title":"Recipient Email"},"recipient_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Role"},"in_reply_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"In Reply To"}},"type":"object","required":["message","recipient_email"],"title":"CareTeamPatientReplyBody"},"CaseBundleRequest":{"properties":{"scope":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope"},"case_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Id"},"case_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Case Ids"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"annotator_id_hashed":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotator Id Hashed"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"buyer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Email"},"licensed_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Licensed To"},"exclusive":{"type":"boolean","title":"Exclusive","default":false},"license_expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Expires At"}},"type":"object","title":"CaseBundleRequest"},"CaseProvenance":{"properties":{"agents":{"items":{"type":"string"},"type":"array","title":"Agents"},"disclaimers":{"items":{"type":"string"},"type":"array","title":"Disclaimers"},"recorded":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recorded"}},"additionalProperties":false,"type":"object","title":"CaseProvenance","description":"Case-level provenance carried by a partner bundle (Buyer Response PRD §2 A3):\nthe FHIR ``Provenance.agent`` roles that authored/adjudicated the case and any\ndisclaimer extensions. Never an identity — roles and free-text disclaimers only."},"CaseSourceRef":{"properties":{"title":{"type":"string","title":"Title"},"identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identifier"},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type"},"role":{"type":"string","title":"Role","default":"source"}},"additionalProperties":false,"type":"object","required":["title"],"title":"CaseSourceRef","description":"A citation supplied by the CASE AUTHOR (partner or our generation engine),\ndistinct from an annotator's evidence_anchor (Buyer Response PRD §2 A3). Both\nship; they answer different buyer questions. This one: 'what grounds this\ncase?'. The anchor: 'what grounds this clinician's judgment?'. Collapsing them\nwould let case-level provenance inflate the grounded% that is supposed to\nmeasure clinician citation, so ``source_refs`` MUST NOT feed the annotator\n``grounded`` count (enforced in packaging/export)."},"ChangePasswordRequest":{"properties":{"current_password":{"type":"string","title":"Current Password"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"ChangePasswordRequest","description":"POST /auth/password/change — signed-in password change."},"ChatRequest":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"message":{"type":"string","title":"Message"},"conversation_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversation History","default":[]}},"type":"object","required":["patient_id","message"],"title":"ChatRequest"},"ChatResponse":{"properties":{"response":{"type":"string","title":"Response"},"patient_id":{"type":"string","title":"Patient Id"},"audio_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio Url"},"escalation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Escalation"}},"type":"object","required":["response","patient_id"],"title":"ChatResponse"},"ChosenRevision":{"properties":{"edited":{"type":"boolean","title":"Edited","default":false},"revised_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revised Text"},"why_better_tags":{"items":{"type":"string"},"type":"array","title":"Why Better Tags"},"why_better_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Why Better Notes"},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"}},"type":"object","title":"ChosenRevision"},"CiteRequest":{"properties":{"text":{"type":"string","title":"Text"},"specialty":{"type":"string","title":"Specialty","default":"nephrology"},"k":{"type":"integer","title":"K","default":3}},"type":"object","required":["text"],"title":"CiteRequest","description":"Ask for auto-suggested citations for a rationale or reasoning step\n(Seamless PRD WS3). ``text`` is the clinician's written rationale/step;\n``specialty`` scopes the citation library. Post-reveal, so no anti-peeking gate."},"ClinicalCase":{"properties":{"case_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Id"},"case_source":{"type":"string","title":"Case Source","default":"synthetic"},"specialty":{"type":"string","title":"Specialty","default":"general"},"demographics":{"$ref":"#/components/schemas/Demographics"},"problem_list":{"items":{"$ref":"#/components/schemas/ProblemItem"},"type":"array","title":"Problem List"},"medications":{"items":{"$ref":"#/components/schemas/MedicationItem"},"type":"array","title":"Medications"},"vitals":{"additionalProperties":true,"type":"object","title":"Vitals"},"lab_panels":{"items":{"$ref":"#/components/schemas/LabPanel"},"type":"array","title":"Lab Panels"},"notes":{"items":{"$ref":"#/components/schemas/ClinicalNote"},"type":"array","title":"Notes"},"encounters":{"items":{"$ref":"#/components/schemas/EncounterItem"},"type":"array","title":"Encounters"},"orders":{"items":{"$ref":"#/components/schemas/OrderItem"},"type":"array","title":"Orders"},"medication_events":{"items":{"$ref":"#/components/schemas/MedicationEvent"},"type":"array","title":"Medication Events"},"allergies":{"items":{"$ref":"#/components/schemas/AllergyItem"},"type":"array","title":"Allergies"},"studies":{"items":{"$ref":"#/components/schemas/Study"},"type":"array","title":"Studies"},"source_refs":{"items":{"$ref":"#/components/schemas/CaseSourceRef"},"type":"array","title":"Source Refs"},"case_provenance":{"anyOf":[{"$ref":"#/components/schemas/CaseProvenance"},{"type":"null"}]},"declared_difficulty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Declared Difficulty"},"required_modalities":{"items":{"type":"string"},"type":"array","title":"Required Modalities"},"study_findings_policy":{"type":"string","enum":["hidden","visible","post_hoc"],"title":"Study Findings Policy","default":"visible"},"medications_absent_on_record":{"type":"boolean","title":"Medications Absent On Record","default":false},"problems_absent_on_record":{"type":"boolean","title":"Problems Absent On Record","default":false},"completeness_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completeness Status"},"ground_truth":{"anyOf":[{"$ref":"#/components/schemas/GroundTruth"},{"type":"null"}]},"hard_hook":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hard Hook"},"reasoning_divergence":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reasoning Divergence"}},"additionalProperties":false,"type":"object","title":"ClinicalCase"},"ClinicalNote":{"properties":{"note_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note Id"},"note_type":{"type":"string","title":"Note Type","default":"Progress"},"author_role":{"type":"string","title":"Author Role","default":"clinician"},"text":{"type":"string","title":"Text","default":""},"model_visible":{"type":"boolean","title":"Model Visible","default":true},"withheld_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Withheld Reason"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"}},"additionalProperties":false,"type":"object","title":"ClinicalNote","description":"A de-identified narrative (FHIR DocumentReference). ``author_role`` is a\ngeneralized category (\"nephrology\", \"ICU\") — never a person's name."},"CloseSessionBody":{"properties":{"reason":{"type":"string","title":"Reason","default":"closed"}},"type":"object","title":"CloseSessionBody"},"CommunityInviteBody":{"properties":{"user_id":{"type":"string","title":"User Id"}},"type":"object","required":["user_id"],"title":"CommunityInviteBody"},"CommunityPersonaPostIn":{"properties":{"channel_slug":{"type":"string","maxLength":80,"minLength":1,"title":"Channel Slug"},"body":{"type":"string","maxLength":8000,"minLength":1,"title":"Body"},"announce":{"type":"boolean","title":"Announce","default":false}},"additionalProperties":false,"type":"object","required":["channel_slug","body"],"title":"CommunityPersonaPostIn"},"CompileBody":{"properties":{"dry_run":{"type":"boolean","title":"Dry Run","default":false}},"additionalProperties":false,"type":"object","title":"CompileBody"},"ConsentRequest":{"properties":{"consent_given":{"type":"boolean","title":"Consent Given"},"consent_method":{"type":"string","title":"Consent Method","default":"in_app_verbal"},"signature_image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature Image"},"patient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Name"}},"type":"object","required":["consent_given"],"title":"ConsentRequest"},"ContributorCredentialsIn":{"properties":{"organization":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization"},"role_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Title"},"blurb":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blurb"},"credentials_verified":{"type":"boolean","title":"Credentials Verified","default":false},"ship":{"additionalProperties":true,"type":"object","title":"Ship"},"verify":{"additionalProperties":true,"type":"object","title":"Verify"}},"type":"object","title":"ContributorCredentialsIn","description":"Admin upsert of a contributor's credential profile. ``ship`` is the Tier A\n(buyer-facing) attribute block; ``verify`` is the Tier B private vault."},"CreateCheckRequest":{"properties":{"patientId":{"type":"string","title":"Patientid"},"documentIds":{"items":{"type":"string"},"type":"array","title":"Documentids"},"freeformNotes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freeformnotes"},"surgeryDate":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Surgerydate"}},"type":"object","required":["patientId"],"title":"CreateCheckRequest"},"CreateEncounterBody":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"escalation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Escalation Id"},"scheduled_for":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled For"}},"type":"object","required":["patient_id"],"title":"CreateEncounterBody"},"CreateUserRequest":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"role":{"type":"string","title":"Role","default":"evaluator"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"board_cert":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Board Cert"},"years_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Years Experience"},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier"}},"type":"object","required":["email","password"],"title":"CreateUserRequest"},"CreateVisitRequest":{"properties":{"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"encounter_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Encounter Type"}},"type":"object","title":"CreateVisitRequest"},"CredentialCorrection":{"properties":{"npi":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Npi"},"licenseNumber":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}],"title":"Licensenumber"},"licenseState":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Licensestate"},"registrationNumber":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}],"title":"Registrationnumber"}},"additionalProperties":false,"type":"object","title":"CredentialCorrection","description":"PATCH /me/credentials — a PENDING applicant fixes an identifier they typed wrong.\n\nOnly the numbers a registry is checked against, and only while the\napplication is pending: the check that follows is what makes the correction\nsafe, and an approved account's identifiers stay as verified. Nothing here\nchanges a degree, a specialty or an attestation."},"CredentialSummaryRequest":{"properties":{"recipient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient"},"acknowledged":{"type":"boolean","title":"Acknowledged","default":false}},"type":"object","title":"CredentialSummaryRequest","description":"Generate a Further Credential Summary (verification dossier). ``acknowledged``\nmust be true — the §9 non-circumvention notice is a click-through gate."},"DailyCheckinAnswers":{"properties":{"pain_nrs":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Pain Nrs"},"pain_trajectory":{"type":"string","enum":["BETTER","SAME","WORSE"],"title":"Pain Trajectory"},"fever":{"type":"string","enum":["NO","YES_FELT","YES_MEASURED"],"title":"Fever"},"incision_change":{"type":"string","enum":["BETTER","SAME","WORSE"],"title":"Incision Change"},"incision_flags":{"items":{"type":"string","enum":["NEW_REDNESS_SPREADING","NEW_DRAINAGE","OPENING_OR_GAPING","BAD_SMELL","INCREASED_PAIN_AT_INCISION"]},"type":"array","title":"Incision Flags"},"nausea":{"type":"string","enum":["NONE","MILD","MODERATE","SEVERE"],"title":"Nausea"},"eating_drinking":{"type":"string","enum":["YES","SOME","ALMOST_NOTHING"],"title":"Eating Drinking"},"red_flag_symptoms":{"items":{"type":"string","enum":["CHEST_PAIN","SUDDEN_TROUBLE_BREATHING","SUDDEN_WEAKNESS_ONE_SIDE","SEVERE_OR_NEW_BLEEDING","CONFUSION_MENTAL_CHANGE","CALF_SWELLING_OR_PAIN","SEVERE_HEADACHE","FAINTING_OR_NEAR_FAINTING"]},"type":"array","title":"Red Flag Symptoms"},"walking":{"type":"string","enum":["YES","SOME","NO"],"title":"Walking"},"worry_level":{"type":"string","enum":["NOT_AT_ALL","A_LITTLE","MODERATELY","VERY","EXTREMELY"],"title":"Worry Level"},"free_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Free Text"}},"type":"object","required":["pain_nrs","pain_trajectory","fever","incision_change","nausea","eating_drinking","walking","worry_level"],"title":"DailyCheckinAnswers","description":"Patient submission shape (PRD §4.1)."},"DailyCheckinRequest":{"properties":{"episode_day":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Episode Day"},"answers":{"$ref":"#/components/schemas/DailyCheckinAnswers"}},"type":"object","required":["answers"],"title":"DailyCheckinRequest"},"DataProviderInviteRequest":{"properties":{"email":{"type":"string","title":"Email"},"org_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Org Name"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["email"],"title":"DataProviderInviteRequest","description":"Admin invites a data provider (Exports → Data Providers)."},"DayXSurveyAnswers":{"properties":{"section_a":{"additionalProperties":true,"type":"object","title":"Section A"},"section_b":{"additionalProperties":true,"type":"object","title":"Section B"},"section_c":{"additionalProperties":true,"type":"object","title":"Section C"},"section_d":{"additionalProperties":true,"type":"object","title":"Section D"},"free_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Free Text"}},"type":"object","title":"DayXSurveyAnswers","description":"Patient submission shape (PRD §5.1).\n\nEach section is an opaque dict the scorer interprets via the\nprocedure-family Section B mapping. We keep this loose because the\nsection content evolves with the procedure family without changing\nthe algorithm signature."},"DayXSurveyRequest":{"properties":{"answers":{"$ref":"#/components/schemas/DayXSurveyAnswers"}},"type":"object","required":["answers"],"title":"DayXSurveyRequest"},"DeactivateBody":{"properties":{"note":{"type":"string","maxLength":500,"minLength":3,"title":"Note"}},"additionalProperties":false,"type":"object","required":["note"],"title":"DeactivateBody"},"Declare":{"properties":{"collection":{"type":"string","maxLength":64,"minLength":1,"title":"Collection"},"token":{"type":"string","maxLength":128,"minLength":1,"title":"Token"},"path":{"type":"string","maxLength":1024,"minLength":1,"title":"Path"},"size":{"type":"integer","maximum":1099511627776.0,"exclusiveMinimum":0.0,"title":"Size"},"sha256":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}],"title":"Sha256"}},"additionalProperties":false,"type":"object","required":["collection","token","path","size"],"title":"Declare"},"Delivery":{"properties":{"files":{"items":{"type":"string"},"type":"array","maxItems":1000,"minItems":1,"title":"Files"},"buyer":{"type":"string","maxLength":128,"minLength":1,"title":"Buyer"}},"additionalProperties":false,"type":"object","required":["files","buyer"],"title":"Delivery"},"Demographics":{"properties":{"age_band":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Age Band"},"sex":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sex"}},"type":"object","title":"Demographics"},"DemographicsBody":{"properties":{"demographics":{"additionalProperties":true,"type":"object","title":"Demographics"}},"type":"object","required":["demographics"],"title":"DemographicsBody"},"DigestLeadIn":{"properties":{"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"urgent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Urgent"}},"type":"object","title":"DigestLeadIn","description":"The digest's admin override (Digest Design PRD §2.2).\n\nTwo decisions and no content: which story leads, and whether it carries a\nBREAKING badge. Every string on the card was written by the compose pass\nunder the contract and validated on the way in, so an override that could\nalso rewrite text would be a way to put unvalidated prose on a bot post."},"DischargeInput":{"properties":{"patient_name":{"type":"string","title":"Patient Name"},"discharge_notes":{"type":"string","title":"Discharge Notes"},"patient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"doctor_office_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doctor Office Phone"},"doctor_clinic_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doctor Clinic Code"},"resource_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Code"}},"type":"object","required":["patient_name","discharge_notes"],"title":"DischargeInput"},"DischargeRequest":{"properties":{"discharge_at":{"type":"string","title":"Discharge At","description":"ISO timestamp of post-op-day-0 discharge"}},"type":"object","required":["discharge_at"],"title":"DischargeRequest"},"DmMessageIn":{"properties":{"body":{"type":"string","maxLength":4000,"title":"Body","default":""},"attachment_ids":{"items":{"type":"string"},"type":"array","maxItems":5,"title":"Attachment Ids"}},"type":"object","title":"DmMessageIn"},"DmOpen":{"properties":{"user_id":{"type":"string","maxLength":64,"minLength":1,"title":"User Id"}},"type":"object","required":["user_id"],"title":"DmOpen"},"DoctorOnboard":{"properties":{"name":{"type":"string","title":"Name"},"email":{"type":"string","format":"email","title":"Email"},"office_phone":{"type":"string","title":"Office Phone"},"doctor_type":{"type":"string","title":"Doctor Type"},"hospital_affiliations":{"type":"string","title":"Hospital Affiliations"}},"type":"object","required":["name","email","office_phone","doctor_type","hospital_affiliations"],"title":"DoctorOnboard"},"DoctorProfileOut":{"properties":{"name":{"type":"string","title":"Name"},"email":{"type":"string","title":"Email"},"office_phone":{"type":"string","title":"Office Phone"},"doctor_type":{"type":"string","title":"Doctor Type"},"hospital_affiliations":{"type":"string","title":"Hospital Affiliations"},"clinic_code":{"type":"string","title":"Clinic Code"},"health_system_code":{"type":"string","title":"Health System Code","default":""},"tenant_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tenant Slug"},"is_team_director":{"type":"boolean","title":"Is Team Director","default":false},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"}},"type":"object","required":["name","email","office_phone","doctor_type","hospital_affiliations","clinic_code"],"title":"DoctorProfileOut"},"DocumentReviewBody":{"properties":{"decision":{"type":"string","title":"Decision"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"applicant_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Applicant Reason"}},"type":"object","required":["decision"],"title":"DocumentReviewBody"},"DocumentationBody":{"properties":{"documentation":{"type":"string","title":"Documentation","default":""}},"type":"object","title":"DocumentationBody"},"DraftPatientRequest":{"properties":{"name":{"type":"string","title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","default":""},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","default":""},"mbi":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mbi","default":""},"dob":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dob"},"scheduled_surgery_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Surgery Date"},"anchor_procedure":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anchor Procedure"}},"type":"object","required":["name"],"title":"DraftPatientRequest"},"EHRBundle":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"patient_name":{"type":"string","title":"Patient Name"},"phone_number":{"type":"string","title":"Phone Number"},"pmh":{"type":"string","title":"Pmh"},"procedure_context":{"type":"string","title":"Procedure Context"},"after_visit_summary":{"type":"string","title":"After Visit Summary"},"clinical_notes":{"type":"string","title":"Clinical Notes"},"medication_list":{"type":"string","title":"Medication List"},"allergies":{"type":"string","title":"Allergies"},"problem_list":{"type":"string","title":"Problem List"}},"type":"object","required":["patient_id","patient_name","phone_number","pmh","procedure_context","after_visit_summary","clinical_notes","medication_list","allergies","problem_list"],"title":"EHRBundle"},"EncounterItem":{"properties":{"encounter_ref":{"type":"string","title":"Encounter Ref"},"visit_type":{"type":"string","enum":["office","telehealth","procedure","hospital","other"],"title":"Visit Type","default":"office"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"},"note_ids":{"items":{"type":"string"},"type":"array","title":"Note Ids"}},"additionalProperties":false,"type":"object","required":["encounter_ref"],"title":"EncounterItem","description":"One de-identified visit, with an opaque per-case encounter reference."},"EndEncounterBody":{"properties":{"duration_seconds":{"type":"integer","title":"Duration Seconds","default":0},"outcome":{"type":"string","title":"Outcome","default":"COMPLETED"}},"type":"object","title":"EndEncounterBody"},"EnterpriseNoteBody":{"properties":{"note":{"type":"string","title":"Note"}},"type":"object","required":["note"],"title":"EnterpriseNoteBody"},"ErrorLabel":{"properties":{"type":{"type":"string","title":"Type"},"subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subtype"},"severity":{"type":"string","title":"Severity","default":"medium"},"section":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Section"},"original_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Original Text","default":""},"corrected_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Corrected Text","default":""},"clinician_verified":{"type":"boolean","title":"Clinician Verified","default":true}},"type":"object","required":["type"],"title":"ErrorLabel"},"EscalationConsentRequest":{"properties":{"escalation_id":{"type":"integer","title":"Escalation Id"},"consent":{"type":"string","title":"Consent"}},"type":"object","required":["escalation_id","consent"],"title":"EscalationConsentRequest"},"EscalationInterventionRequest":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"EscalationInterventionRequest"},"EscalationResolveRequest":{"properties":{"resolved":{"type":"boolean","title":"Resolved"}},"type":"object","required":["resolved"],"title":"EscalationResolveRequest"},"EventIn":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title"},"description":{"type":"string","maxLength":4000,"title":"Description","default":""},"starts_at":{"type":"string","maxLength":40,"minLength":1,"title":"Starts At"},"ends_at":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Ends At"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Timezone"},"location":{"type":"string","maxLength":500,"title":"Location","default":""},"host":{"type":"string","maxLength":200,"title":"Host","default":""},"channel_slug":{"type":"string","maxLength":64,"title":"Channel Slug","default":"events"}},"type":"object","required":["title","starts_at"],"title":"EventIn"},"EventTrackRequest":{"properties":{"event_type":{"type":"string","title":"Event Type"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload"}},"type":"object","required":["event_type"],"title":"EventTrackRequest"},"EvidenceAnchor":{"properties":{"citation_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Citation Text"},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type"},"identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identifier"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"citation_confirmed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Citation Confirmed"},"entry_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entry Method"}},"type":"object","title":"EvidenceAnchor","description":"A citation grounding a judgment/step in a clinical source.\n\n``{citation_text, source_type, identifier}`` — e.g. KDIGO 2024 §3.2, a PMID,\nor a DOI. Captured with one keystroke in the UI; carried onto every record so\ngrounded data can be filtered to a premium tier and verified by the critic."},"ExclusionBody":{"properties":{"upload_id":{"type":"string","maxLength":200,"minLength":1,"title":"Upload Id"},"user_id":{"type":"string","maxLength":200,"minLength":1,"title":"User Id"},"reason":{"type":"string","enum":["source_practice_clinician","family","other"],"title":"Reason"}},"additionalProperties":false,"type":"object","required":["upload_id","user_id","reason"],"title":"ExclusionBody"},"ExportBody":{"properties":{"split":{"type":"string","enum":["train","dev"],"title":"Split"},"buyer_jurisdiction":{"type":"string","maxLength":2,"minLength":2,"title":"Buyer Jurisdiction"},"buyer_not_covered_person":{"type":"boolean","title":"Buyer Not Covered Person"},"onward_transfer_clause":{"type":"boolean","title":"Onward Transfer Clause"},"buyer_ref":{"type":"string","maxLength":200,"minLength":1,"title":"Buyer Ref"}},"additionalProperties":false,"type":"object","required":["split","buyer_jurisdiction","buyer_not_covered_person","onward_transfer_clause","buyer_ref"],"title":"ExportBody"},"FailureTag":{"properties":{"mode":{"type":"string","title":"Mode","default":"other"},"evidence_step_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Evidence Step Id"},"criterion_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Criterion Id"},"note":{"type":"string","title":"Note","default":""},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier"}},"type":"object","title":"FailureTag","description":"A PHYSICIAN-VERIFIED label of HOW a model answer failed (Tier-1 PRD §D-2).\n\n``mode`` is a controlled-vocabulary id from ``FAILURE_MODES`` (anything else is\ncoerced to ``other`` and queued for reconciliation — never sold as a named mode).\nEach tag anchors to a specific reasoning-step or rubric ``criterion_id`` plus a\none-line verbatim rationale. The physician is BLIND to provider at capture; the tag\nattaches to the slot and provider is joined in only at export. ``tier`` is derived\nfrom the linked rubric criterion when present."},"FinalizeRequest":{"properties":{"decision":{"type":"string","title":"Decision"}},"type":"object","required":["decision"],"title":"FinalizeRequest"},"FinishBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"}},"type":"object","required":["token"],"title":"FinishBody"},"FirstRunUpdate":{"properties":{"action":{"type":"string","enum":["done","skip","skip_practice","defer","defer_all","dismiss","reset"],"title":"Action"},"stop":{"anyOf":[{"type":"string","enum":["welcome","start","practice","community","earnings","manual"]},{"type":"null"}],"title":"Stop"}},"type":"object","required":["action"],"title":"FirstRunUpdate","description":"PATCH /me/first-run — one transition on the caller's own walkthrough.\n\n``done`` closes a stop for good; it is monotonic and it is the only outcome a\nREQUIRED stop (welcome, start, practice) stores in its stops map.\n``skip_practice`` is an approved physician's separate practice-only opt-out;\nit records a timestamp without fabricating a completion or dismissing other stops.\n\n``defer`` is Welcome package v2 §1's replacement for ``skip`` on the three\nOPTIONAL stops, and the difference is the whole point of that PRD: a skip was\nterminal, so the product asked once and then never again, while a defer means\n\"asked, declined this session\" and may be rewritten every session. ``defer``\nagainst a required stop is a 400 — there is no skip control on those screens,\nand a client that invents one is refused rather than obeyed.\n\n``defer_all`` is the re-entry page's \"Go to my cases\": every optional stop\nstill open is deferred in one call, so leaving is one request rather than\nthree racing ones.\n\n``skip`` is kept ONLY as a compatibility alias for a cached client still\nrunning the previous bundle — it behaves as ``defer`` on an optional stop and\nis refused on a required one. Removing it outright would 422 every physician\nwith a stale tab open during the deploy.\n\n``dismiss`` collapses the whole checklist without marking the remaining stops\ndone, which is what the \"You're all set\" line reads from."},"ForgotPasswordRequest":{"properties":{"email":{"type":"string","title":"Email"},"onboarding_token":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Onboarding Token"}},"type":"object","required":["email"],"title":"ForgotPasswordRequest","description":"POST /auth/password/forgot — start a reset. Always answers the same way."},"FormUpsertRequest":{"properties":{"fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Fields"},"fieldOrigins":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Fieldorigins"},"procedureSpecific":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Procedurespecific"},"orStartedAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orstartedat"},"orEndedAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orendedat"},"orDurationMinutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ordurationminutes"}},"type":"object","title":"FormUpsertRequest"},"FromScratch":{"properties":{"ideal_answer":{"type":"string","title":"Ideal Answer","default":""},"approach_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approach Notes"},"reasoning_steps":{"items":{"$ref":"#/components/schemas/ReasoningStep"},"type":"array","title":"Reasoning Steps"},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"}},"type":"object","title":"FromScratch"},"GenerateRealCasesRequest":{"properties":{"dry_run":{"type":"boolean","title":"Dry Run","default":true},"background":{"type":"boolean","title":"Background","default":false},"max_cases":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Cases"},"min_gap_days":{"type":"integer","title":"Min Gap Days","default":7},"encounter_indices":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Encounter Indices"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"max_labels":{"type":"integer","title":"Max Labels","default":1},"grounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grounding Mode"},"independent_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Independent Mode"},"open_to_all_specialties":{"type":"boolean","title":"Open To All Specialties","default":false},"derive_questions":{"type":"boolean","title":"Derive Questions","default":true},"trajectory":{"type":"boolean","title":"Trajectory","default":false},"include_interval_points":{"type":"boolean","title":"Include Interval Points","default":true},"apply_density_gate":{"type":"boolean","title":"Apply Density Gate","default":true}},"type":"object","title":"GenerateRealCasesRequest","description":"Build V4 tasks from ONE ingested real chart (Real-Case Generation PRD §5).\n\n``dry_run`` is not optional in spirit and defaults to True here: an admin\ngenerating seven cases from a chart must be able to read every proposed\nquestion, index event, tag and difficulty band BEFORE any of it reaches a\nphysician. Generating a wrong question at scale is how you burn physician\ngoodwill, and the plan is cheap — the dry run makes no model call at all\nunless ``derive_questions`` asks for one."},"GenerateRequest":{"properties":{"n":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"N","default":5},"task_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Type"},"source":{"type":"string","title":"Source","default":"gold"}},"type":"object","title":"GenerateRequest"},"GenerationRequest":{"properties":{"count":{"type":"integer","title":"Count","default":10},"difficulty_mix":{"anyOf":[{"additionalProperties":{"type":"number"},"type":"object"},{"type":"null"}],"title":"Difficulty Mix"},"capture_reasoning":{"type":"boolean","title":"Capture Reasoning","default":false},"grounding_mode":{"type":"string","title":"Grounding Mode","default":"optional"},"independent_mode":{"type":"string","title":"Independent Mode","default":"stance"},"max_labels":{"type":"integer","title":"Max Labels","default":1},"buyer_request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Request Id"},"multimodal":{"type":"boolean","title":"Multimodal","default":false}},"type":"object","title":"GenerationRequest","description":"Admin \"Generate N nephrology tasks\" (Seedmaker, PRD §10)."},"GitPushRequest":{"properties":{"prompt_id":{"type":"string","title":"Prompt Id"},"commit_message":{"type":"string","title":"Commit Message"}},"type":"object","required":["prompt_id","commit_message"],"title":"GitPushRequest"},"GroundTruth":{"properties":{"answer":{"type":"string","title":"Answer","default":""},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale"},"evidence":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Evidence"},"key_data":{"items":{"type":"string"},"type":"array","title":"Key Data"}},"type":"object","title":"GroundTruth","description":"INTERNAL ONLY (generation/QA). The objectively correct, guideline/lab-\nanchored answer used to seed candidate answers + gate hardness. ``public_case``\nstrips this — it never reaches a blinded evaluator or a normal export."},"GroupCreate":{"properties":{"title":{"type":"string","maxLength":120,"minLength":1,"title":"Title"},"user_ids":{"items":{"type":"string"},"type":"array","maxItems":30,"title":"User Ids"}},"type":"object","required":["title"],"title":"GroupCreate","description":"A member-created group conversation.\n\nThe title is REQUIRED and is not derived from the roster. A group named by\nits members renames itself every time somebody is added, and a conversation\nthat renames itself is a different conversation to the person reading it --\nthe same reasoning the case-room ``title`` column was added under."},"GroupMembersIn":{"properties":{"user_ids":{"items":{"type":"string"},"type":"array","maxItems":30,"minItems":1,"title":"User Ids"}},"type":"object","required":["user_ids"],"title":"GroupMembersIn"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HandoffRedeem":{"properties":{"token":{"type":"string","maxLength":128,"minLength":1,"title":"Token"}},"type":"object","required":["token"],"title":"HandoffRedeem"},"HealthSystemReferralBody":{"properties":{"contact_name":{"type":"string","maxLength":120,"minLength":1,"title":"Contact Name"},"contact_email":{"type":"string","format":"email","title":"Contact Email"},"hs_name":{"type":"string","maxLength":160,"minLength":1,"title":"Hs Name"},"relationship":{"type":"string","maxLength":400,"minLength":1,"title":"Relationship"},"contact_role":{"type":"string","maxLength":120,"title":"Contact Role","default":""},"note":{"type":"string","maxLength":2000,"title":"Note","default":""},"consent":{"type":"boolean","title":"Consent","default":false}},"type":"object","required":["contact_name","contact_email","hs_name","relationship"],"title":"HealthSystemReferralBody"},"HeartbeatBody":{"properties":{"nonce":{"type":"string","title":"Nonce"},"seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seq"},"active":{"type":"boolean","title":"Active","default":true},"progress_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Progress Key"},"client_ts":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Ts"}},"type":"object","required":["nonce"],"title":"HeartbeatBody"},"HsAccessRequest":{"properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Username"},"active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Active"}},"type":"object","title":"HsAccessRequest"},"HsAgreementSignRequest":{"properties":{"typed_name":{"type":"string","title":"Typed Name"},"typed_title":{"type":"string","title":"Typed Title"},"authority_affirmed":{"type":"boolean","title":"Authority Affirmed","default":false},"consent_esign":{"type":"boolean","title":"Consent Esign","default":false},"doc_sha256":{"type":"string","title":"Doc Sha256","default":""}},"type":"object","required":["typed_name","typed_title"],"title":"HsAgreementSignRequest","description":"The four things a clickwrap has to capture, named separately.\n\nOne \"I agree\" boolean would be cheaper and would collapse two legally\ndistinct affirmations into one: authority to bind the organization, and\nconsent to transact electronically. Courts test them separately, so the\nrecord keeps them separate."},"HsApplicationRequest":{"properties":{"authority":{"type":"string","title":"Authority"},"deid_capability":{"type":"string","title":"Deid Capability"},"export_scope":{"type":"string","title":"Export Scope"},"scale_patients":{"type":"string","title":"Scale Patients"},"scale_years":{"type":"string","title":"Scale Years"},"scale_specialties":{"items":{"type":"string"},"type":"array","title":"Scale Specialties","default":[]}},"type":"object","required":["authority","deid_capability","export_scope","scale_patients","scale_years"],"title":"HsApplicationRequest","description":"An EXPLICIT field list, per the rule the upload declare model states: a\nfield the client invents is dropped by the model rather than reaching\nanything downstream."},"HsDataRequestBody":{"properties":{"message":{"type":"string","maxLength":4000,"title":"Message","default":""},"recipient_hs_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Recipient Hs Ids"},"title":{"type":"string","maxLength":140,"title":"Title","default":""},"specialty":{"type":"string","maxLength":80,"title":"Specialty","default":""},"case_count":{"type":"integer","maximum":1000000.0,"minimum":0.0,"title":"Case Count","default":0},"due_date":{"type":"string","maxLength":32,"title":"Due Date","default":""},"details":{"type":"string","maxLength":4000,"title":"Details","default":""}},"additionalProperties":false,"type":"object","title":"HsDataRequestBody","description":"One of two shapes (Case Generation Fix PRD §B4).\n\nThe console now sends a MESSAGE and a list of recipients: the message is the\nrequest, and the four structured fields (what / specialty / how many / by\nwhen) are optional colour. The original structured shape is still accepted\nunchanged, because the partner portal and the letter render those fields when\nthey are present, and nothing that sent them should start failing."},"HsDataRequestCloseBody":{"properties":{"reason":{"type":"string","maxLength":32,"minLength":1,"title":"Reason"}},"additionalProperties":false,"type":"object","required":["reason"],"title":"HsDataRequestCloseBody"},"HsIntakeRequest":{"properties":{"organization":{"type":"string","title":"Organization"},"size_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Size Type"},"data_held":{"type":"string","title":"Data Held"},"licensable":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Licensable"},"timeline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timeline"}},"type":"object","required":["organization","data_held"],"title":"HsIntakeRequest","description":"An EXPLICIT field list, per the rule the upload declare model states: a\nfield the client invents is dropped by the model rather than reaching\nanything downstream."},"HsInviteClaimRequest":{"properties":{"full_name":{"type":"string","title":"Full Name","default":""},"password":{"type":"string","title":"Password"}},"type":"object","required":["password"],"title":"HsInviteClaimRequest","description":"What the claim screen sends. NO EMAIL FIELD, deliberately.\n\nThe account's address is whatever the invite was minted against, and the\nbody is written by whoever holds the link. Letting it name the address would\nmake a forwarded invite a way to attach an account on somebody else's\norganization to an address of your choosing, which is the exact hole\n``/hs/members`` closes by taking the organization from the session."},"HsLoginRequest":{"properties":{"username":{"type":"string","title":"Username"},"password":{"type":"string","title":"Password"}},"type":"object","required":["username","password"],"title":"HsLoginRequest"},"HsMemberRequest":{"properties":{"emails":{"items":{"type":"string"},"type":"array","title":"Emails","default":[]}},"type":"object","title":"HsMemberRequest"},"HsPasswordRequest":{"properties":{"current_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Password"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["new_password"],"title":"HsPasswordRequest"},"HsSignupRequest":{"properties":{"full_name":{"type":"string","title":"Full Name"},"email":{"type":"string","title":"Email"},"organization":{"type":"string","title":"Organization"},"password":{"type":"string","title":"Password","default":""},"company_website":{"type":"string","title":"Company Website","default":""}},"type":"object","required":["full_name","email","organization"],"title":"HsSignupRequest"},"HsSignupResendRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"HsSignupResendRequest"},"HsSignupVerifyRequest":{"properties":{"email":{"type":"string","title":"Email"},"code":{"type":"string","title":"Code"}},"type":"object","required":["email","code"],"title":"HsSignupVerifyRequest"},"HsUploadDeclareRequest":{"properties":{"filename":{"type":"string","title":"Filename"},"size":{"type":"integer","exclusiveMinimum":0.0,"title":"Size"},"sha256":{"type":"string","title":"Sha256"},"content_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Type"},"request_id":{"type":"string","maxLength":64,"title":"Request Id","default":""}},"type":"object","required":["filename","size","sha256"],"title":"HsUploadDeclareRequest","description":"What the client declares up front — an EXPLICIT list, so a field the client\ninvents is dropped by the model rather than reaching anything."},"Import":{"properties":{"collection":{"type":"string","maxLength":64,"minLength":1,"title":"Collection"},"token":{"type":"string","maxLength":128,"minLength":1,"title":"Token"},"path":{"type":"string","maxLength":1024,"minLength":1,"title":"Path"},"source_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Id"},"source_key":{"type":"string","maxLength":1024,"minLength":1,"title":"Source Key"},"source_version":{"type":"string","maxLength":1024,"minLength":1,"title":"Source Version"}},"additionalProperties":false,"type":"object","required":["collection","token","path","source_id","source_key","source_version"],"title":"Import"},"IndependentAnswer":{"properties":{"text":{"type":"string","title":"Text","default":""},"kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"},"portal_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Version"},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"},"captured_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Captured At"}},"type":"object","title":"IndependentAnswer","description":"Stage-2 blind capture — written BEFORE the A/B candidates are revealed\n(Eval Flow Upgrade §3). ``kind`` (Speed Optimization §1) distinguishes the\ndefault quick ``stance`` (anti-anchoring signal; the gold SFT answer comes\nfrom the refined chosen answer) from a ``full`` blind ideal answer\n(uncontaminated premium SFT). The server stamps ``kind`` from the task's\n``independent_mode`` at reveal — it is never trusted from the client."},"IndependentAnswerRevision":{"properties":{"text":{"type":"string","title":"Text","default":""},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"},"capture_phase":{"type":"string","title":"Capture Phase","default":"after_model_reveal"},"revised_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revised At"}},"type":"object","title":"IndependentAnswerRevision","description":"Server-derived correction after reveal; never a blind training target."},"InitialTierInput":{"properties":{"procedure":{"$ref":"#/components/schemas/ProcedureInput"},"active_problems":{"$ref":"#/components/schemas/ActiveProblemsInput"},"medications":{"$ref":"#/components/schemas/MedicationsInput"},"allergies":{"$ref":"#/components/schemas/AllergiesInput"},"social_history":{"$ref":"#/components/schemas/SocialHistoryInput"},"recent_labs":{"$ref":"#/components/schemas/RecentLabsInput"}},"type":"object","required":["procedure"],"title":"InitialTierInput","description":"The full input the algorithm consumes — six categories per PRD §4."},"InitialTierOverrideRequest":{"properties":{"targetTier":{"type":"string","enum":["TIER_1","TIER_2","TIER_3"],"title":"Targettier","description":"TIER_1 | TIER_2 | TIER_3"},"reason":{"type":"string","minLength":30,"title":"Reason","description":"Free-text rationale (≥30 chars)"}},"type":"object","required":["targetTier","reason"],"title":"InitialTierOverrideRequest"},"IntakeAnswerRequest":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"message":{"type":"string","title":"Message"},"conversation_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversation History","default":[]}},"type":"object","required":["patient_id","message"],"title":"IntakeAnswerRequest"},"IntakeCompleteSectionBody":{"properties":{"section":{"type":"integer","title":"Section"},"acknowledgements":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Acknowledgements"},"forceComplete":{"type":"boolean","title":"Forcecomplete","default":false},"confirmReview":{"type":"boolean","title":"Confirmreview","default":false}},"type":"object","required":["section"],"title":"IntakeCompleteSectionBody"},"IntakeFormsCompleteInterviewBody":{"properties":{"transcript":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Transcript"},"duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration"},"audioBlobUrl":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audiobloburl"}},"type":"object","required":["transcript"],"title":"IntakeFormsCompleteInterviewBody"},"IntakeFormsPatchBody":{"properties":{"section":{"type":"string","title":"Section"},"field":{"type":"string","title":"Field"},"value":{"title":"Value"}},"type":"object","required":["section","field","value"],"title":"IntakeFormsPatchBody"},"IntakeFormsStartInterviewBody":{"properties":{"patientId":{"type":"string","title":"Patientid"},"surgeryId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Surgeryid"}},"type":"object","required":["patientId"],"title":"IntakeFormsStartInterviewBody"},"IntakeFormsSubmitBody":{"properties":{},"type":"object","title":"IntakeFormsSubmitBody"},"IntakeFrameworkUpdateRequest":{"properties":{"specialty":{"type":"string","title":"Specialty"},"prompt":{"type":"string","title":"Prompt"}},"type":"object","required":["specialty","prompt"],"title":"IntakeFrameworkUpdateRequest"},"IntakeResetSectionBody":{"properties":{"section":{"type":"integer","title":"Section"}},"type":"object","required":["section"],"title":"IntakeResetSectionBody"},"IntakeSectionMessageBody":{"properties":{"section":{"type":"integer","title":"Section"},"message":{"type":"string","title":"Message","default":""},"conversationHistory":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversationhistory","default":[]}},"type":"object","required":["section"],"title":"IntakeSectionMessageBody"},"IntakeStartRequest":{"properties":{"patient_id":{"type":"string","title":"Patient Id"}},"type":"object","required":["patient_id"],"title":"IntakeStartRequest"},"IntakeState":{"properties":{"status":{"type":"string","enum":["NOT_REQUIRED","NOT_STARTED","STARTED","COMPLETE"],"title":"Status","default":"NOT_STARTED"},"started_at_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Started At Hours"},"completed_at_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Completed At Hours"},"disclosures":{"items":{"type":"string"},"type":"array","title":"Disclosures"}},"type":"object","title":"IntakeState","description":"Live state of the intake interview at re-tier compute time."},"IntakeSubmitRequest":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"form_data":{"additionalProperties":true,"type":"object","title":"Form Data"}},"type":"object","required":["patient_id","form_data"],"title":"IntakeSubmitRequest"},"IntakeTemplateUpdateRequest":{"properties":{"specialty":{"type":"string","title":"Specialty"},"template_name":{"type":"string","title":"Template Name"},"header_fields":{"items":{"type":"string"},"type":"array","title":"Header Fields"},"sections":{"additionalProperties":true,"type":"object","title":"Sections"},"final_review_fields":{"items":{"type":"string"},"type":"array","title":"Final Review Fields"}},"type":"object","required":["specialty","template_name","header_fields","sections","final_review_fields"],"title":"IntakeTemplateUpdateRequest"},"LabPanel":{"properties":{"panel":{"type":"string","title":"Panel"},"collected_offset_days":{"type":"integer","title":"Collected Offset Days","default":0},"results":{"items":{"$ref":"#/components/schemas/asclepius__cases__LabResult"},"type":"array","title":"Results"}},"additionalProperties":false,"type":"object","required":["panel"],"title":"LabPanel","description":"A grouped Observation set (BMP, ABG, urine studies…). ``collected_offset_days``\nis a RELATIVE day (0 = index, negative = earlier) so a trend across panels is\npreserved while no calendar date exists."},"LeadBody":{"properties":{"source":{"type":"string","maxLength":32,"minLength":1,"title":"Source"},"email":{"type":"string","format":"email","title":"Email"},"message":{"type":"string","maxLength":5000,"minLength":1,"title":"Message"},"company_website":{"type":"string","maxLength":200,"title":"Company Website","default":""},"referral_token":{"type":"string","maxLength":128,"title":"Referral Token","default":""},"referral_code":{"type":"string","maxLength":64,"title":"Referral Code","default":""},"authority_answer":{"type":"string","maxLength":400,"title":"Authority Answer","default":""},"deidentification_answer":{"type":"string","maxLength":400,"title":"Deidentification Answer","default":""},"data_scale_answer":{"type":"string","maxLength":2000,"title":"Data Scale Answer","default":""}},"type":"object","required":["source","email","message"],"title":"LeadBody"},"LeieLoadBody":{"properties":{"csv_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Csv Text"},"source_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Note"}},"type":"object","title":"LeieLoadBody"},"LicenseReleaseRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"LicenseReleaseRequest"},"LocationBody":{"properties":{"location":{"type":"string","pattern":"^(HOME|FACILITY_OTHER)$","title":"Location"}},"type":"object","required":["location"],"title":"LocationBody"},"LoginRequest":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"LoginRequest"},"ManualReminderPreview":{"properties":{"kind":{"type":"string","enum":["examination","wizard"],"title":"Kind"},"target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target"},"email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Email"}},"type":"object","required":["kind"],"title":"ManualReminderPreview"},"MarkPaidBody":{"properties":{"payout_batch_id":{"type":"string","title":"Payout Batch Id","default":""},"earning_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Earning Ids"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},"type":"object","title":"MarkPaidBody"},"MedAdherenceRequest":{"properties":{"episode_day":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Episode Day"},"response":{"type":"string","enum":["YES","PARTIAL","NO","REPLY_LATER","MISSED_NON_RESPONSE"],"title":"Response"}},"type":"object","required":["response"],"title":"MedAdherenceRequest"},"Medication":{"properties":{"rxnorm_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rxnorm Code"},"name":{"type":"string","title":"Name"},"dose":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dose"},"route":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Route"},"frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frequency"},"start_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"},"indication":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Indication"}},"type":"object","required":["name"],"title":"Medication"},"MedicationEvent":{"properties":{"action":{"type":"string","enum":["start","stop","increase","decrease","hold","continue","switch"],"title":"Action"},"drug":{"type":"string","title":"Drug"},"rxnorm_ingredient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rxnorm Ingredient"},"dose":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dose"},"route":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Route"},"freq":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freq"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"encounter_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Encounter Ref"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"},"source":{"type":"string","enum":["structured","worksheet_extracted"],"title":"Source","default":"structured"},"source_span":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Span"}},"additionalProperties":false,"type":"object","required":["action","drug"],"title":"MedicationEvent"},"MedicationItem":{"properties":{"drug":{"type":"string","title":"Drug"},"dose":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dose"},"route":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Route"},"freq":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freq"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"start_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Start Offset Days"},"stop_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stop Offset Days"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"}},"type":"object","required":["drug"],"title":"MedicationItem"},"MedicationsInput":{"properties":{"medications":{"items":{"$ref":"#/components/schemas/Medication"},"type":"array","title":"Medications"}},"type":"object","title":"MedicationsInput"},"MemberAttestationsBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"attestations":{"additionalProperties":true,"type":"object","title":"Attestations"}},"type":"object","required":["token","attestations"],"title":"MemberAttestationsBody"},"MemberCredentialsBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"credentials":{"additionalProperties":true,"type":"object","title":"Credentials"}},"type":"object","required":["token","credentials"],"title":"MemberCredentialsBody"},"MessageEdit":{"properties":{"body":{"type":"string","maxLength":4000,"minLength":1,"title":"Body"},"mention_user_ids":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":20},{"type":"null"}],"title":"Mention User Ids"}},"type":"object","required":["body"],"title":"MessageEdit"},"MessageIn":{"properties":{"body":{"type":"string","maxLength":4000,"title":"Body","default":""},"parent_message_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Parent Message Id"},"mention_user_ids":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Mention User Ids"},"attachment_ids":{"items":{"type":"string"},"type":"array","maxItems":5,"title":"Attachment Ids"}},"type":"object","title":"MessageIn"},"MfaCodeBody":{"properties":{"code":{"type":"string","title":"Code"}},"type":"object","required":["code"],"title":"MfaCodeBody"},"MfaLoginBody":{"properties":{"mfa_token":{"type":"string","title":"Mfa Token"},"code":{"type":"string","title":"Code"}},"type":"object","required":["mfa_token","code"],"title":"MfaLoginBody"},"NotesConfirmRequest":{"properties":{"text":{"type":"string","title":"Text"}},"type":"object","required":["text"],"title":"NotesConfirmRequest"},"OnboardTokenBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"}},"type":"object","required":["token"],"title":"OnboardTokenBody"},"OpenSessionBody":{"properties":{"kind":{"type":"string","title":"Kind","default":"review"}},"type":"object","title":"OpenSessionBody"},"OrderItem":{"properties":{"kind":{"type":"string","enum":["lab","imaging","referral","procedure","follow_up","other"],"title":"Kind"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"code_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code System"},"text":{"type":"string","title":"Text","default":""},"encounter_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Encounter Ref"},"due_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Due Offset Days"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"},"source":{"type":"string","enum":["structured","worksheet_extracted"],"title":"Source","default":"structured"},"source_span":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Span"}},"additionalProperties":false,"type":"object","required":["kind"],"title":"OrderItem"},"OutreachBody":{"properties":{"kind":{"type":"string","enum":["examination","wizard","info_request","first_case"],"title":"Kind"},"recipients":{"items":{"$ref":"#/components/schemas/OutreachRecipient"},"type":"array","maxItems":200,"minItems":1,"title":"Recipients"},"campaign":{"type":"string","pattern":"^[a-z0-9-]{3,40}$","title":"Campaign","default":"outreach-2026-10"},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"additionalProperties":false,"type":"object","required":["kind","recipients"],"title":"OutreachBody"},"OutreachRecipient":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"},"health_system_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Health System Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"items":{"items":{"type":"string"},"type":"array","maxItems":10,"title":"Items"}},"additionalProperties":false,"type":"object","required":["email"],"title":"OutreachRecipient"},"OverrideRequest":{"properties":{"field":{"type":"string","title":"Field"},"to":{"type":"string","title":"To","default":"PASS"},"reason":{"type":"string","title":"Reason"}},"type":"object","required":["field","reason"],"title":"OverrideRequest"},"PCPReferralUpdateRequest":{"properties":{"pcp_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pcp Name"},"sent":{"type":"boolean","title":"Sent","default":true}},"type":"object","title":"PCPReferralUpdateRequest"},"PairReviewSubmitBody":{"properties":{"verdict":{"type":"string","title":"Verdict"},"stronger":{"type":"string","title":"Stronger"},"accepted_side":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Accepted Side"},"dimensions":{"additionalProperties":{"type":"string"},"type":"object","title":"Dimensions","default":{}},"corrections":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Corrections"},"reviewer_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewer Notes"},"time_spent_sec":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Time Spent Sec"},"step_divergence":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Step Divergence"},"draw_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Draw Token"}},"type":"object","required":["verdict","stronger"],"title":"PairReviewSubmitBody"},"PamResponse":{"properties":{"item_index":{"type":"integer","maximum":13.0,"minimum":1.0,"title":"Item Index"},"value":{"enum":[1,2,3,4,"N_A"],"title":"Value"}},"type":"object","required":["item_index","value"],"title":"PamResponse","description":"A single response on the 13-item PAM-style proxy (PRD §4.1)."},"PamResult":{"properties":{"raw_sum":{"type":"integer","title":"Raw Sum"},"items_scored":{"type":"integer","title":"Items Scored"},"raw_average":{"type":"number","title":"Raw Average"},"activation_score":{"type":"number","title":"Activation Score"},"level":{"type":"string","enum":["LOW","MODERATE","HIGH"],"title":"Level"},"is_complete":{"type":"boolean","title":"Is Complete"},"completed_at_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Completed At Hours"}},"type":"object","required":["raw_sum","items_scored","raw_average","activation_score","level","is_complete"],"title":"PamResult","description":"Output of `score_pam` (PRD §4.2). Stored on `PamAssessment` in v1+."},"PamSubmission":{"properties":{"responses":{"items":{"$ref":"#/components/schemas/PamResponse"},"type":"array","maxItems":13,"minItems":1,"title":"Responses","description":"1..13 PAM-13 proxy responses; items_scored ≥ 10 to be is_complete."}},"type":"object","required":["responses"],"title":"PamSubmission","description":"Body schema for the PAM-13 proxy submit. Validation is the same\none used by the algorithm-pure scorer (`triage.preop_retier.types.PamResponse`)."},"PasswordChange":{"properties":{"current_password":{"type":"string","maxLength":200,"minLength":1,"title":"Current Password"},"new_password":{"type":"string","maxLength":200,"minLength":8,"title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"PasswordChange","description":"POST /me/password — change a password from inside the product.\n\nThe current one is required: a session left open on a ward computer should\nnot be enough to take the account."},"PatientTypeBody":{"properties":{"patient_type":{"type":"string","pattern":"^(NEW|ESTABLISHED)$","title":"Patient Type"}},"type":"object","required":["patient_type"],"title":"PatientTypeBody"},"PatientUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"mbi":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mbi"},"dob":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dob"},"scheduled_surgery_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Surgery Date"},"anchor_procedure":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anchor Procedure"}},"type":"object","title":"PatientUpdateRequest"},"PayEarningsBody":{"properties":{"user_id":{"type":"string","title":"User Id"},"earning_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Earning Ids"},"payout_batch_id":{"type":"string","title":"Payout Batch Id","default":""}},"type":"object","required":["user_id"],"title":"PayEarningsBody"},"PollIn":{"properties":{"channel_slug":{"type":"string","maxLength":64,"minLength":1,"title":"Channel Slug"},"question":{"type":"string","maxLength":300,"minLength":1,"title":"Question"},"options":{"items":{"type":"string"},"type":"array","maxItems":6,"minItems":2,"title":"Options"}},"type":"object","required":["channel_slug","question","options"],"title":"PollIn"},"PortalHandoffConsumeRequest":{"properties":{"handoff_code":{"type":"string","title":"Handoff Code"}},"type":"object","required":["handoff_code"],"title":"PortalHandoffConsumeRequest"},"PortalHandoffCreateResponse":{"properties":{"handoff_code":{"type":"string","title":"Handoff Code"},"expires_in_seconds":{"type":"integer","title":"Expires In Seconds"}},"type":"object","required":["handoff_code","expires_in_seconds"],"title":"PortalHandoffCreateResponse"},"PracticeAction":{"properties":{"tool":{"type":"string","maxLength":80,"minLength":1,"title":"Tool"},"input":{"additionalProperties":true,"type":"object","title":"Input"}},"additionalProperties":false,"type":"object","required":["tool"],"title":"PracticeAction"},"PracticeAgentBody":{"properties":{"scenario_id":{"type":"string","maxLength":80,"minLength":1,"title":"Scenario Id"},"actions":{"items":{"$ref":"#/components/schemas/PracticeAction"},"type":"array","maxItems":40,"title":"Actions"},"driver":{"type":"string","enum":["scripted","model"],"title":"Driver","default":"scripted"},"model":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["scenario_id"],"title":"PracticeAgentBody"},"PracticeBody":{"properties":{"scenario_id":{"type":"string","maxLength":80,"minLength":1,"title":"Scenario Id"},"actions":{"items":{"$ref":"#/components/schemas/PracticeAction"},"type":"array","maxItems":40,"title":"Actions"}},"additionalProperties":false,"type":"object","required":["scenario_id"],"title":"PracticeBody"},"PracticeStepBody":{"properties":{"scenario_id":{"type":"string","maxLength":80,"minLength":1,"title":"Scenario Id"},"actions":{"items":{"$ref":"#/components/schemas/PracticeAction"},"type":"array","maxItems":40,"title":"Actions"},"action":{"$ref":"#/components/schemas/PracticeAction"}},"additionalProperties":false,"type":"object","required":["scenario_id","action"],"title":"PracticeStepBody"},"PreOpInput":{"properties":{"patient_name":{"type":"string","title":"Patient Name"},"preparation_notes":{"type":"string","title":"Preparation Notes"},"patient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"doctor_office_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doctor Office Phone"},"doctor_clinic_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doctor Clinic Code"},"resource_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Code"},"procedure_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Procedure Type"},"scheduled_surgery_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Surgery Date"}},"type":"object","required":["patient_name","preparation_notes"],"title":"PreOpInput"},"PreOpReTierInput":{"properties":{"initial_tier":{"type":"string","enum":["TIER_1","TIER_2","TIER_3"],"title":"Initial Tier"},"initial_tier_was_hard_escalator":{"type":"boolean","title":"Initial Tier Was Hard Escalator"},"hours_until_surgery":{"type":"integer","title":"Hours Until Surgery"},"pam":{"anyOf":[{"$ref":"#/components/schemas/PamResult"},{"type":"null"}]},"intake":{"$ref":"#/components/schemas/IntakeState"},"surveys":{"items":{"$ref":"#/components/schemas/SurveyWindowState"},"type":"array","title":"Surveys"},"video":{"$ref":"#/components/schemas/VideoEngagement"},"battle_card":{"$ref":"#/components/schemas/BattleCardEngagement"},"teachback_completed":{"type":"boolean","title":"Teachback Completed","default":false},"teachback_failed_med_hold":{"type":"boolean","title":"Teachback Failed Med Hold","default":false},"teachback_failed_fasting":{"type":"boolean","title":"Teachback Failed Fasting","default":false},"teachback_failed_critical":{"type":"boolean","title":"Teachback Failed Critical","default":false},"teachback_not_completed_by_t24":{"type":"boolean","title":"Teachback Not Completed By T24","default":false},"teachback_passed_all":{"type":"boolean","title":"Teachback Passed All","default":false}},"type":"object","required":["initial_tier","initial_tier_was_hard_escalator","hours_until_surgery"],"title":"PreOpReTierInput","description":"The full input the re-tier algorithm consumes — all five signal\nsources plus the initial-tier anchor (PRD §3)."},"PreOpReTierRunRequest":{"properties":{"triggered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By","description":"Optional trigger label for audit. Defaults to 'MANUAL:DOCTOR_UI' when called from the doctor recompute CTA."}},"type":"object","title":"PreOpReTierRunRequest"},"PreOpSurveySubmitBody":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"window":{"type":"string","title":"Window"},"answers":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Answers"}},"type":"object","required":["patient_id","window","answers"],"title":"PreOpSurveySubmitBody"},"PreOpVideoEvent":{"properties":{"episode_id":{"type":"string","title":"Episode Id"},"session_id":{"type":"string","title":"Session Id","description":"Client-side dedup key (e.g. window.crypto)"},"duration_sec":{"type":"integer","minimum":0.0,"title":"Duration Sec","default":0},"completed_session":{"type":"boolean","title":"Completed Session","default":false}},"type":"object","required":["episode_id","session_id"],"title":"PreOpVideoEvent"},"PreOpWindowActionBody":{"properties":{"action":{"type":"string","title":"Action"}},"type":"object","required":["action"],"title":"PreOpWindowActionBody"},"PrelabelRequest":{"properties":{"task_id":{"type":"string","title":"Task Id"}},"type":"object","required":["task_id"],"title":"PrelabelRequest","description":"Ask the critic for a pre-label suggestion on a task (Speed Optimization\n§2). Gated behind the independent-answer commit (anti-peeking)."},"PriorAuth":{"properties":{"drug_or_service":{"type":"string","title":"Drug Or Service"},"justification_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Justification Text","default":""},"outcome":{"type":"string","title":"Outcome","default":"pending"}},"type":"object","required":["drug_or_service"],"title":"PriorAuth"},"ProblemItem":{"properties":{"condition":{"type":"string","title":"Condition"},"since":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"}},"type":"object","required":["condition"],"title":"ProblemItem"},"ProcedureInput":{"properties":{"cpt_code":{"type":"string","title":"Cpt Code"},"anchor_procedure_family":{"type":"string","enum":["LEJR","CABG","SPINAL_FUSION","HIP_FEMUR_FRACTURE","MAJOR_BOWEL"],"title":"Anchor Procedure Family"},"scheduled_date":{"type":"string","title":"Scheduled Date"},"is_emergency":{"type":"boolean","title":"Is Emergency","default":false},"bilateral":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Bilateral"},"laterality":{"anyOf":[{"type":"string","enum":["LEFT","RIGHT","BILATERAL","N_A"]},{"type":"null"}],"title":"Laterality"},"approach":{"anyOf":[{"type":"string","enum":["OPEN","MIS","ROBOTIC","UNKNOWN"]},{"type":"null"}],"title":"Approach"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["cpt_code","anchor_procedure_family","scheduled_date"],"title":"ProcedureInput"},"ProcessResponse":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"pipeline_type":{"type":"string","title":"Pipeline Type"},"dashboard_url":{"type":"string","title":"Dashboard Url"},"voice_audio_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Voice Audio Url"},"battlecard_html":{"type":"string","title":"Battlecard Html"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"}},"type":"object","required":["patient_id","pipeline_type","dashboard_url","voice_audio_url","battlecard_html","avatar_url"],"title":"ProcessResponse"},"ProfileUpdate":{"properties":{"full_name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Full Name"},"phone":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}],"title":"Phone"},"linkedin_url":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Linkedin Url"},"specialty_niche":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Specialty Niche"}},"type":"object","title":"ProfileUpdate","description":"PATCH /me/profile — the fields a physician may correct about themselves.\n\nDeliberately short, and deliberately not the credential fields: those were\nchecked against a registry or attested to, and letting someone edit them\nafter approval would make the check meaningless. Every field is optional\nbecause a partial update is the normal case; ``None`` leaves a column\nalone, while an empty string clears it."},"PromoteCaseRequest":{"properties":{"question":{"type":"string","title":"Question"},"max_labels":{"type":"integer","title":"Max Labels","default":1},"grounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grounding Mode"},"independent_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Independent Mode"},"open_to_all_specialties":{"type":"boolean","title":"Open To All Specialties","default":false},"dry_run":{"type":"boolean","title":"Dry Run","default":false}},"type":"object","required":["question"],"title":"PromoteCaseRequest","description":"Promote an ingested real case to a gradable V4 task (EHR PRD §9)."},"PromptReview":{"properties":{"reviewed":{"type":"boolean","title":"Reviewed","default":false},"verdict":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verdict"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"reviewed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewed At"},"attest_clinically_valid":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Attest Clinically Valid"}},"type":"object","title":"PromptReview","description":"Stage-1 clinician sign-off on the prompt itself (Eval Flow Upgrade §2).\n\nA ``valid`` verdict upgrades provenance from AI-drafted to clinician-reviewed\nand carries onto every shipped record. A ``flagged`` verdict short-circuits\ncapture: the task is flagged for admin review and 0 records are produced."},"PromptUpdateRequest":{"properties":{"content":{"type":"string","title":"Content"}},"type":"object","required":["content"],"title":"PromptUpdateRequest"},"ProviderPasswordRequest":{"properties":{"new_password":{"type":"string","title":"New Password"},"current_password":{"type":"string","title":"Current Password","default":""}},"type":"object","required":["new_password"],"title":"ProviderPasswordRequest","description":"Provider forced/normal password reset. ``current_password`` is required for a\nnormal change; on the first forced reset the Bearer token is the proof (the\ntemp password was already consumed at login), so it may be blank."},"QADecisionRequest":{"properties":{"decision":{"type":"string","title":"Decision"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["decision"],"title":"QADecisionRequest"},"QuarantineOverrideRequest":{"properties":{"reason":{"type":"string","title":"Reason"}},"type":"object","required":["reason"],"title":"QuarantineOverrideRequest","description":"Documented admin override of verifier findings. The deidentify() hard\nguard still applies and cannot be overridden."},"ReactionIn":{"properties":{"emoji":{"type":"string","maxLength":16,"minLength":1,"title":"Emoji"}},"type":"object","required":["emoji"],"title":"ReactionIn"},"ReadIn":{"properties":{"last_read_message_id":{"type":"integer","minimum":0.0,"title":"Last Read Message Id"}},"type":"object","required":["last_read_message_id"],"title":"ReadIn"},"RealDataApprovalRequest":{"properties":{"approved":{"type":"boolean","title":"Approved"}},"type":"object","required":["approved"],"title":"RealDataApprovalRequest","description":"Grant/revoke a contributor's V4 real-case access (EHR PRD §9.5)."},"ReasoningSplitRequest":{"properties":{"text":{"type":"string","title":"Text"},"prompt":{"type":"string","title":"Prompt","default":""},"specialty":{"type":"string","title":"Specialty","default":"general"}},"type":"object","required":["text"],"title":"ReasoningSplitRequest","description":"Split a chosen/ideal answer into ordered reasoning steps for tap-to-grade\n(Eval Flow Upgrade §4). ``prompt``/``specialty`` give the splitter context."},"ReasoningStep":{"properties":{"step":{"type":"integer","title":"Step"},"text":{"type":"string","title":"Text"},"original_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Original Text"},"corrected":{"type":"boolean","title":"Corrected","default":false},"confirmed":{"type":"boolean","title":"Confirmed","default":false},"added":{"type":"boolean","title":"Added","default":false},"correction_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Correction Reason"},"step_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Note"},"step_error_tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Error Tag"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"step_reward":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Step Reward"},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"},"critique":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Critique"},"suggested_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Suggested Label"},"suggested_critique":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Suggested Critique"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag"}},"type":"object","required":["step","text"],"title":"ReasoningStep"},"ReassignPointBody":{"properties":{"task_id":{"type":"string","title":"Task Id"},"user_id":{"type":"string","title":"User Id"}},"type":"object","required":["task_id","user_id"],"title":"ReassignPointBody"},"RecentLabsInput":{"properties":{"labs":{"items":{"$ref":"#/components/schemas/triage__types__LabResult"},"type":"array","title":"Labs"},"studies":{"items":{"$ref":"#/components/schemas/StudyResult"},"type":"array","title":"Studies"}},"type":"object","title":"RecentLabsInput"},"Reconciliation":{"properties":{"tax_year":{"type":"integer","maximum":2100.0,"minimum":2020.0,"title":"Tax Year"},"totals_csv":{"type":"string","maxLength":1000000,"minLength":1,"title":"Totals Csv"}},"type":"object","required":["tax_year","totals_csv"],"title":"Reconciliation"},"ReferralBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["email"],"title":"ReferralBody"},"RejectBody":{"properties":{"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"applicant_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Applicant Reason"}},"type":"object","title":"RejectBody"},"RejectedCritique":{"properties":{"error_tags":{"items":{"type":"string"},"type":"array","title":"Error Tags"},"severities":{"additionalProperties":{"type":"string"},"type":"object","title":"Severities"},"why_worse":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Why Worse"},"error_tag_anchors":{"additionalProperties":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"object","title":"Error Tag Anchors"},"error_tag_reasons":{"additionalProperties":{"type":"string"},"type":"object","title":"Error Tag Reasons"},"failure_tags":{"items":{"$ref":"#/components/schemas/FailureTag"},"type":"array","title":"Failure Tags"}},"type":"object","title":"RejectedCritique"},"RelaySendBody":{"properties":{"trajectory_id":{"type":"string","title":"Trajectory Id"},"user_ids":{"items":{"type":"string"},"type":"array","title":"User Ids"},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed"},"due_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Due At"}},"type":"object","required":["trajectory_id"],"title":"RelaySendBody","description":"Send one whole trajectory as a care-team relay (§8.3)."},"ReleaseHoldBody":{"properties":{"pay_full_rate":{"type":"boolean","title":"Pay Full Rate","default":false},"note":{"type":"string","maxLength":500,"title":"Note","default":""}},"type":"object","title":"ReleaseHoldBody"},"ResendVerificationBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["email"],"title":"ResendVerificationBody"},"ResetBody":{"properties":{"confirm":{"type":"string","title":"Confirm","default":""},"fresh":{"type":"boolean","title":"Fresh","default":false}},"type":"object","title":"ResetBody"},"ResetPasswordRequest":{"properties":{"token":{"type":"string","title":"Token"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["token","new_password"],"title":"ResetPasswordRequest","description":"POST /auth/password/reset — redeem a mailed token for a new password."},"ResolveSelectionBody":{"properties":{"task_ids":{"items":{"type":"string"},"type":"array","title":"Task Ids"}},"type":"object","title":"ResolveSelectionBody"},"RestorePhysicianBody":{"properties":{"approve_verification":{"type":"boolean","title":"Approve Verification","default":false},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"additionalProperties":false,"type":"object","title":"RestorePhysicianBody","description":"Deliberate, itemised repair. Nothing here defaults to on: each field is a\ndecision an operator is making on the record, with their identity stamped."},"RetierBody":{"properties":{"tier":{"type":"string","title":"Tier"},"note":{"type":"string","title":"Note"}},"type":"object","required":["tier","note"],"title":"RetierBody"},"RetierRunRequest":{"properties":{"triggered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By"}},"type":"object","title":"RetierRunRequest"},"Review":{"properties":{"malware_evidence":{"type":"string","maxLength":2000,"minLength":1,"title":"Malware Evidence"},"privacy_evidence":{"type":"string","maxLength":2000,"minLength":1,"title":"Privacy Evidence"},"rights_evidence":{"type":"string","maxLength":2000,"minLength":1,"title":"Rights Evidence"},"approved":{"type":"boolean","title":"Approved"}},"additionalProperties":false,"type":"object","required":["malware_evidence","privacy_evidence","rights_evidence","approved"],"title":"Review"},"ReviewClearRequest":{"properties":{"note":{"type":"string","title":"Note"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["note"],"title":"ReviewClearRequest","description":"Admin clearance of a blocking review reason (Audit PRD §21.5). Clearing a\nburned-in-PHI flag is an affirmative human statement that the image carries no\nPHI, so a note is MANDATORY — it must be attributable, not a silent unblock."},"ReviewSubmitBody":{"properties":{"verdict":{"type":"string","title":"Verdict"},"dimensions":{"additionalProperties":{"type":"string"},"type":"object","title":"Dimensions","default":{}},"corrections":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Corrections"},"reviewer_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewer Notes"},"time_spent_sec":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Time Spent Sec"},"draw_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Draw Token"}},"type":"object","required":["verdict"],"title":"ReviewSubmitBody"},"RoleBody":{"properties":{"role":{"type":"string","title":"Role"}},"type":"object","required":["role"],"title":"RoleBody"},"RolloutRequest":{"properties":{"two_frontier":{"type":"boolean","title":"Two Frontier","default":false},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed"},"run_rubric":{"type":"boolean","title":"Run Rubric","default":true},"measure_difficulty":{"type":"boolean","title":"Measure Difficulty","default":false}},"type":"object","title":"RolloutRequest"},"RubricCriterion":{"properties":{"text":{"type":"string","title":"Text","default":""},"points":{"type":"number","title":"Points","default":0.0},"axes":{"items":{"type":"string"},"type":"array","title":"Axes"},"axis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Axis"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier"},"critical":{"type":"boolean","title":"Critical","default":false},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"specific":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Specific"}},"type":"object","title":"RubricCriterion","description":"One weighted criterion of a HealthBench-shaped scoring rubric (FEAT-2).\n\n``points`` is signed: POSITIVE for \"a correct answer must include this\",\nNEGATIVE for \"a correct answer must never say this\". ``axes`` is a non-empty\nlist drawn from RUBRIC_AXES — a criterion routinely scores on more than one\n(\"must never give thrombolytics in dissection\" is safety AND accuracy), so\nforcing a single pick discarded a real distinction (Eval UI Overhaul §11).\n``axis`` is the DEPRECATED single-value mirror of ``axes[0]``, kept so stored\nrecords and readers written against the old shape keep working.\n``source`` records how the criterion was seeded (e.g.\n``error_tag:dosing_error``, ``why_better:safer``, ``good_step``,\n``corrected_step``, or ``manual``) so a buyer can trace provenance. Nothing is\nauto-applied — the doctor confirms/edits every criterion before it ships.\n\n``tier`` (Two-Model PRD Workstream B, V3/V4) is the criticality band —\ncritical | important | helpful — derived from |points| when not supplied by the\nclient. ``critical`` is the derived convenience flag (tier == \"critical\"); a\n\"critical negative\" (critical + points<0) is the failure a correct answer must\nnever commit, and the grader hard-fails on it."},"RunBody":{"properties":{"task_ids":{"items":{"type":"string"},"type":"array","maxItems":500,"title":"Task Ids"},"split":{"anyOf":[{"type":"string","enum":["train","dev","heldout"]},{"type":"null"}],"title":"Split"},"model":{"type":"string","maxLength":120,"minLength":1,"title":"Model"},"k":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"K","default":1},"harness":{"type":"string","enum":["native_tools","json_protocol"],"title":"Harness","default":"native_tools"}},"additionalProperties":false,"type":"object","required":["model"],"title":"RunBody"},"RunRequest":{"properties":{"prompt_id":{"type":"string","title":"Prompt Id"},"system_prompt":{"type":"string","title":"System Prompt"},"discharge_notes":{"type":"string","title":"Discharge Notes"},"preview_words":{"type":"integer","title":"Preview Words","default":75},"voice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Voice Id"},"test_message":{"type":"string","title":"Test Message","default":"What medications should I be taking, and when?"}},"type":"object","required":["prompt_id","system_prompt","discharge_notes"],"title":"RunRequest"},"SavePromptRequest":{"properties":{"content":{"type":"string","title":"Content"}},"type":"object","required":["content"],"title":"SavePromptRequest"},"ScopedExportRequest":{"properties":{"profile":{"type":"string","title":"Profile","default":"default"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"include_exported":{"type":"boolean","title":"Include Exported","default":true},"since":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"},"until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Until"},"submission_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submission Id"}},"type":"object","title":"ScopedExportRequest","description":"Export Data scoped to one contributor or one organization. Always Tier A\nonly; the buyer profile + Tier B leak gate enforce the wall."},"SelectProductBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"product":{"type":"string","title":"Product"}},"type":"object","required":["token","product"],"title":"SelectProductBody"},"SelfFlagRequest":{"properties":{"free_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Free Text"}},"type":"object","title":"SelfFlagRequest"},"SelfFlagResolveRequest":{"properties":{"flag_id":{"type":"integer","title":"Flag Id"},"resolved_by":{"type":"string","title":"Resolved By"}},"type":"object","required":["flag_id","resolved_by"],"title":"SelfFlagResolveRequest"},"SelfServeBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"company_website":{"type":"string","maxLength":200,"title":"Company Website","default":""},"first_name":{"type":"string","maxLength":120,"title":"First Name","default":""},"last_name":{"type":"string","maxLength":120,"title":"Last Name","default":""},"referral_code":{"type":"string","maxLength":32,"title":"Referral Code","default":""},"flavor":{"type":"string","maxLength":20,"title":"Flavor","default":""},"project_slug":{"type":"string","maxLength":80,"title":"Project Slug","default":""},"project_invite":{"type":"string","maxLength":200,"title":"Project Invite","default":""},"campaign":{"type":"string","maxLength":40,"title":"Campaign","default":""}},"type":"object","required":["email"],"title":"SelfServeBody"},"Sign":{"properties":{"number":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Number"},"checksum":{"type":"string","maxLength":44,"minLength":44,"title":"Checksum"}},"additionalProperties":false,"type":"object","required":["number","checksum"],"title":"Sign"},"SigninLinkExchange":{"properties":{"token":{"type":"string","title":"Token"}},"type":"object","required":["token"],"title":"SigninLinkExchange","description":"POST /auth/signin-link/exchange, trade the emailed token for a session."},"SigninLinkRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"SigninLinkRequest","description":"POST /auth/signin-link, mail an applicant a way back in.\n\nAnswers identically whether or not the address has an account, for the\nsame reason the forgot-password door does."},"SignupResendRequest":{"properties":{"health_system_id":{"type":"string","title":"Health System Id"},"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["health_system_id","email"],"title":"SignupResendRequest"},"SocialHistoryInput":{"properties":{"smoking_status":{"type":"string","enum":["NEVER","FORMER","CURRENT","UNKNOWN"],"title":"Smoking Status","default":"UNKNOWN"},"pack_years":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pack Years"},"alcohol_use":{"type":"string","enum":["NONE","OCCASIONAL","MODERATE","HEAVY","AT_RISK_OR_AUDIT_POSITIVE","UNKNOWN"],"title":"Alcohol Use","default":"UNKNOWN"},"substance_use":{"items":{"$ref":"#/components/schemas/SubstanceUse"},"type":"array","title":"Substance Use"},"lives_alone":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Lives Alone"},"has_reliable_caregiver":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Reliable Caregiver"},"housing_status":{"type":"string","enum":["STABLE","UNSTABLE","HOMELESS","UNKNOWN"],"title":"Housing Status","default":"STABLE"},"food_security":{"type":"string","enum":["SECURE","INSECURE","UNKNOWN"],"title":"Food Security","default":"SECURE"},"transportation_barrier":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transportation Barrier"},"employment_status":{"anyOf":[{"type":"string","enum":["EMPLOYED","UNEMPLOYED","RETIRED","DISABLED","UNKNOWN"]},{"type":"null"}],"title":"Employment Status"},"primary_language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Language"},"needs_interpreter":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Interpreter"},"age":{"type":"integer","title":"Age","default":0}},"type":"object","title":"SocialHistoryInput"},"SsoRequest":{"properties":{"token":{"type":"string","title":"Token"}},"type":"object","required":["token"],"title":"SsoRequest","description":"A doctor-portal ``tenant_staff`` JWT, exchanged for an Asclepius session."},"StaffContext":{"properties":{"source":{"type":"string","title":"Source"},"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"type":"string","title":"Role"},"tenant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tenant Id"},"tenant_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tenant Slug"},"health_system_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Health System Code"},"is_team_director":{"type":"boolean","title":"Is Team Director","default":false}},"type":"object","required":["source","email","name","role","tenant_id","tenant_slug","health_system_code"],"title":"StaffContext"},"Step1Body":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"email":{"type":"string","format":"email","title":"Email"},"password":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Password"},"license_state":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"License State"}},"type":"object","required":["token","first_name","last_name","email"],"title":"Step1Body"},"Step3Body":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"health_system_name":{"type":"string","title":"Health System Name"},"surgery_department":{"type":"string","title":"Surgery Department"},"phone":{"type":"string","title":"Phone"}},"type":"object","required":["token","health_system_name","surgery_department","phone"],"title":"Step3Body"},"Study":{"properties":{"modality":{"type":"string","title":"Modality"},"label":{"type":"string","title":"Label","default":""},"findings":{"type":"string","title":"Findings","default":""},"measurements":{"items":{"$ref":"#/components/schemas/asclepius__cases__LabResult"},"type":"array","title":"Measurements"},"impression":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impression"},"asset":{"anyOf":[{"$ref":"#/components/schemas/StudyAsset"},{"type":"null"}]},"phi_screening":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Phi Screening"},"collected_offset_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Collected Offset Days"}},"additionalProperties":false,"type":"object","required":["modality"],"title":"Study","description":"A structured study report — the decisive signal in cardiology/oncology cases\noften lives here (PRD §3). ``findings`` is the structured report text (the\nreasoning anchor, always required even when an image ``asset`` is attached);\n``measurements`` reuse :class:`LabResult` so EF %, valve gradient, PET SUVmax, and\nmolecular VAF are structured + gradeable, not buried in prose."},"StudyAsset":{"properties":{"asset_id":{"type":"string","title":"Asset Id"},"mime":{"type":"string","title":"Mime"},"sha256":{"type":"string","title":"Sha256"},"width":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Height"},"byte_size":{"type":"integer","title":"Byte Size","default":0},"page":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Page"},"page_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Page Count"},"source":{"type":"string","title":"Source","default":"partner_deidentified"}},"additionalProperties":false,"type":"object","required":["asset_id","mime","sha256"],"title":"StudyAsset","description":"A reference to a real de-identified image asset attached to a Study (V4 Image\nPRD §2). The image BYTES are NEVER stored on the ClinicalCase or in asclepius.db —\nonly this opaque reference, resolved via the content-addressed asset store\n(:mod:`asclepius.assets`). ``sha256`` is identity, dedupe, AND the A/B integrity\ncheck (the same bytes must reach both frontier providers)."},"StudyResult":{"properties":{"type":{"type":"string","enum":["ECHO","ECG","PFT","CXR","STRESS_TEST","CARDIAC_CATH","OTHER"],"title":"Type","default":"OTHER"},"performed_at":{"type":"string","title":"Performed At","default":""},"summary":{"type":"string","title":"Summary","default":""},"ejection_fraction":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ejection Fraction"},"significant_findings":{"items":{"type":"string"},"type":"array","title":"Significant Findings"}},"type":"object","title":"StudyResult"},"SubmissionIn":{"properties":{"submission_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submission Id"},"task_id":{"type":"string","title":"Task Id"},"verdict":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verdict"},"prompt_review":{"anyOf":[{"$ref":"#/components/schemas/PromptReview"},{"type":"null"}]},"independent_answer":{"anyOf":[{"$ref":"#/components/schemas/IndependentAnswer"},{"type":"null"}]},"independent_answer_revision":{"anyOf":[{"$ref":"#/components/schemas/IndependentAnswerRevision"},{"type":"null"}]},"chosen_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chosen Id"},"rejected_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rejected Id"},"chosen_revision":{"anyOf":[{"$ref":"#/components/schemas/ChosenRevision"},{"type":"null"}]},"rejected_critique":{"anyOf":[{"$ref":"#/components/schemas/RejectedCritique"},{"type":"null"}]},"from_scratch":{"anyOf":[{"$ref":"#/components/schemas/FromScratch"},{"type":"null"}]},"reasoning_steps":{"items":{"$ref":"#/components/schemas/ReasoningStep"},"type":"array","title":"Reasoning Steps"},"rubric":{"items":{"$ref":"#/components/schemas/RubricCriterion"},"type":"array","title":"Rubric"},"confidence":{"type":"string","title":"Confidence","default":"medium"},"time_spent_sec":{"type":"integer","title":"Time Spent Sec","default":0},"assisted":{"items":{"type":"string"},"type":"array","title":"Assisted"},"portal_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Version"},"assist":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Assist"},"decisive_action":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Decisive Action"},"expected_trajectory":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Expected Trajectory"}},"type":"object","required":["task_id"],"title":"SubmissionIn"},"SubmitRequest":{"properties":{"gold_note":{"type":"string","title":"Gold Note"},"error_labels":{"items":{"$ref":"#/components/schemas/ErrorLabel"},"type":"array","title":"Error Labels"},"billing_codes":{"items":{"$ref":"#/components/schemas/BillingCode"},"type":"array","title":"Billing Codes"},"prior_auth":{"anyOf":[{"$ref":"#/components/schemas/PriorAuth"},{"type":"null"}]},"clinician_review_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Clinician Review Seconds"},"difficulty_tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Difficulty Tags"},"languages":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Languages"},"tasks":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tasks"}},"type":"object","required":["gold_note"],"title":"SubmitRequest"},"SubstanceUse":{"properties":{"substance":{"type":"string","enum":["OPIOIDS","STIMULANTS","CANNABIS","OTHER"],"title":"Substance"},"status":{"type":"string","enum":["ACTIVE","IN_RECOVERY","PRIOR","UNKNOWN"],"title":"Status","default":"UNKNOWN"}},"type":"object","required":["substance"],"title":"SubstanceUse"},"SurveySubmitRequest":{"properties":{"clinic_code":{"type":"string","title":"Clinic Code"},"resource_code":{"type":"string","title":"Resource Code"},"day":{"type":"integer","title":"Day"},"answers":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Answers"}},"type":"object","required":["clinic_code","resource_code","day","answers"],"title":"SurveySubmitRequest"},"SurveyWindowState":{"properties":{"window":{"type":"string","enum":["T_96","T_48","T_24"],"title":"Window"},"status":{"type":"string","enum":["PENDING","GREEN","ORANGE","RED","MISSED"],"title":"Status","default":"PENDING"},"has_critical_red_flag":{"type":"boolean","title":"Has Critical Red Flag","default":false}},"type":"object","required":["window"],"title":"SurveyWindowState","description":"Per-window survey result, mapped from `backend/preop_survey.py` output."},"SwitchToPostopRequest":{"properties":{"orStartedAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orstartedat"},"orEndedAt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Orendedat"}},"type":"object","title":"SwitchToPostopRequest"},"TaskIn":{"properties":{"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"},"specialty":{"type":"string","title":"Specialty","default":"general"},"difficulty":{"type":"string","title":"Difficulty","default":"medium"},"capture_reasoning":{"type":"boolean","title":"Capture Reasoning","default":false},"source":{"type":"string","title":"Source","default":"lab_supplied"},"prompt":{"type":"string","title":"Prompt"},"candidate_answers":{"items":{"$ref":"#/components/schemas/CandidateAnswer"},"type":"array","title":"Candidate Answers"},"max_labels":{"type":"integer","title":"Max Labels","default":1},"grounding_mode":{"type":"string","title":"Grounding Mode","default":"optional"},"independent_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Independent Mode"},"buyer_request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Request Id"},"value_tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value Tier"},"case":{"anyOf":[{"$ref":"#/components/schemas/ClinicalCase"},{"type":"null"}]},"modality":{"type":"string","title":"Modality","default":"text"}},"type":"object","required":["prompt"],"title":"TaskIn"},"TaskUploadRequest":{"properties":{"tasks":{"items":{"$ref":"#/components/schemas/TaskIn"},"type":"array","title":"Tasks"}},"type":"object","required":["tasks"],"title":"TaskUploadRequest"},"TaxReview":{"properties":{"tax_year":{"type":"integer","maximum":2100.0,"minimum":2020.0,"title":"Tax Year"},"form_type":{"type":"string","const":"1099-NEC","title":"Form Type","default":"1099-NEC"},"calculation_method":{"type":"string","enum":["payments_including_fees","payments_excluding_fees","payouts_only"],"title":"Calculation Method"},"platform_and_funding_checked":{"type":"boolean","title":"Platform And Funding Checked"},"tax_identity_and_w9_checked":{"type":"boolean","title":"Tax Identity And W9 Checked"},"delivery_and_consent_checked":{"type":"boolean","title":"Delivery And Consent Checked"},"state_filing_checked":{"type":"boolean","title":"State Filing Checked"}},"type":"object","required":["tax_year","calculation_method","platform_and_funding_checked","tax_identity_and_w9_checked","delivery_and_consent_checked","state_filing_checked"],"title":"TaxReview"},"TeachBackAnswerBody":{"properties":{"session_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Session Id"},"question_id":{"type":"string","title":"Question Id"},"answer":{"type":"string","title":"Answer","default":""}},"type":"object","required":["question_id"],"title":"TeachBackAnswerBody"},"TeachBackStartResponse":{"properties":{"ok":{"type":"boolean","title":"Ok"},"session_id":{"type":"integer","title":"Session Id"},"track":{"type":"string","title":"Track"},"questions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Questions"},"battlecard_html":{"type":"string","title":"Battlecard Html"}},"type":"object","required":["ok","session_id","track","questions","battlecard_html"],"title":"TeachBackStartResponse"},"TenantLoginBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"TenantLoginBody"},"TierOverrideBody":{"properties":{"tier":{"type":"string","title":"Tier"},"case_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Domain"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["tier"],"title":"TierOverrideBody"},"TrajectorySelfScore":{"properties":{"marks":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Marks"},"falsifier_fired":{"type":"boolean","title":"Falsifier Fired","default":false},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","title":"TrajectorySelfScore","description":"The physician grading their own sealed prediction (PRD §3.4 Phase 4).\n\n``marks`` is one entry per expectation they committed to:\n``{index, state: held|did_not_hold|not_assessable, note}``. ``falsifier_fired``\nis their assertion that their own stated falsifier fired in the revealed\nencounter — the §3.3 claim, recorded as the clinician's judgment about the\nchart and never derived from text matching.\n\nTheir own falsifier is the rubric. No reviewer grades this."},"TutorialConcern":{"properties":{"task_id":{"type":"string","title":"Task Id"},"note":{"type":"string","maxLength":8000,"minLength":1,"title":"Note"}},"type":"object","required":["task_id","note"],"title":"TutorialConcern"},"TutorialIndependentAnswer":{"properties":{"text":{"type":"string","title":"Text","default":""},"kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"},"portal_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Version"},"evidence_anchor":{"anyOf":[{"$ref":"#/components/schemas/EvidenceAnchor"},{"type":"null"}]},"evidence_anchors":{"items":{"$ref":"#/components/schemas/EvidenceAnchor"},"type":"array","title":"Evidence Anchors"},"captured_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Captured At"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"}},"type":"object","title":"TutorialIndependentAnswer"},"TutorialStateUpdate":{"properties":{"action":{"type":"string","enum":["start","advance","skip","complete","reset","resources_seen","welcome_seen","onboarding_choice","info_seen"],"title":"Action"},"step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step"},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version"},"choice":{"anyOf":[{"type":"string","enum":["email_me","start_now"]},{"type":"null"}],"title":"Choice"}},"type":"object","required":["action"],"title":"TutorialStateUpdate","description":"PATCH /me/tutorial — one transition on the caller's own tutorial state."},"UploadLinkRequest":{"properties":{"partner_id":{"type":"string","title":"Partner Id"},"partner_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Partner Label"},"specialty":{"type":"string","title":"Specialty","default":"nephrology"},"purpose":{"type":"string","title":"Purpose"},"expires_hours":{"type":"integer","title":"Expires Hours","default":72},"one_time":{"type":"boolean","title":"One Time","default":true},"max_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Bytes"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"}},"type":"object","required":["partner_id","purpose"],"title":"UploadLinkRequest","description":"Mint a tokenized, expiring partner upload link."},"UploadPromoteRequest":{"properties":{"question":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Question"},"max_labels":{"type":"integer","title":"Max Labels","default":1},"grounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grounding Mode"},"independent_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Independent Mode"},"open_to_all_specialties":{"type":"boolean","title":"Open To All Specialties","default":false}},"type":"object","title":"UploadPromoteRequest","description":"Upload-scoped promotion (prepare a sample, then promote the rest). The\nclinical question is OPTIONAL — when blank a sensible per-specialty default is\nused, so the admin can promote a whole partner file in one click."},"UploadSpecialtyRequest":{"properties":{"specialty":{"type":"string","title":"Specialty"}},"type":"object","required":["specialty"],"title":"UploadSpecialtyRequest"},"UserCreate":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"sms_consent_opt_in":{"type":"boolean","title":"Sms Consent Opt In","default":false}},"type":"object","required":["email","password"],"title":"UserCreate"},"UserLogin":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"UserLogin"},"UserOut":{"properties":{"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email_verified":{"type":"boolean","title":"Email Verified","default":false}},"type":"object","required":["email"],"title":"UserOut"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"ValidityFindingBody":{"properties":{"finding":{"type":"string","pattern":"^(false|upheld)$","title":"Finding"},"note":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Note"},"override_unsigned":{"type":"boolean","title":"Override Unsigned","default":false}},"type":"object","required":["finding"],"title":"ValidityFindingBody","description":"A person's determination about one physician's attestation.\n\n``note`` is required for a ``false`` finding and optional for ``upheld``,\nand that asymmetry is the point. Section 4.3 of the contributor agreement\npromises the physician is told WHICH case and WHY when a case is not paid.\nA finding with no reason cannot keep that promise, so the API refuses to\nrecord one rather than leaving a doctor with an unexplained zero."},"VerifyEmailCodeBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"code":{"type":"string","title":"Code"}},"type":"object","required":["email","code"],"title":"VerifyEmailCodeBody"},"VerifyOtpBody":{"properties":{"token":{"type":"string","minLength":10,"title":"Token"},"code":{"type":"string","maxLength":6,"minLength":6,"title":"Code"}},"type":"object","required":["token","code"],"title":"VerifyOtpBody"},"VerifyRequest":{"properties":{"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"}},"type":"object","title":"VerifyRequest"},"VideoEngagement":{"properties":{"sessions":{"items":{"type":"integer"},"type":"array","title":"Sessions"}},"type":"object","title":"VideoEngagement","description":"Pre-op video engagement state (PRD §6.1)."},"VideoEventRequest":{"properties":{"video_kind":{"type":"string","enum":["DIAGNOSIS_TREATMENT","RED_FLAG"],"title":"Video Kind"},"event_type":{"type":"string","enum":["PLAYED","COMPLETED"],"title":"Event Type"},"session_id":{"type":"string","title":"Session Id"},"occurred_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Occurred At"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Payload"}},"type":"object","required":["video_kind","event_type","session_id"],"title":"VideoEventRequest"},"VoidEarningBody":{"properties":{"reason":{"type":"string","maxLength":500,"minLength":3,"title":"Reason"}},"type":"object","required":["reason"],"title":"VoidEarningBody"},"VoteIn":{"properties":{"option_id":{"type":"integer","minimum":1.0,"title":"Option Id"}},"type":"object","required":["option_id"],"title":"VoteIn"},"WaiveBody":{"properties":{"reason":{"type":"string","maxLength":2000,"minLength":20,"title":"Reason"}},"additionalProperties":false,"type":"object","required":["reason"],"title":"WaiveBody"},"asclepius__cases__LabResult":{"properties":{"analyte":{"type":"string","title":"Analyte"},"loinc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Loinc"},"value":{"title":"Value"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"ref_low":{"anyOf":[{},{"type":"null"}],"title":"Ref Low"},"ref_high":{"anyOf":[{},{"type":"null"}],"title":"Ref High"},"flag":{"type":"string","title":"Flag","default":""},"ref_range_unusable":{"type":"boolean","title":"Ref Range Unusable","default":false}},"additionalProperties":false,"type":"object","required":["analyte","value"],"title":"LabResult"},"asclepius__schemas__ExportRequest":{"properties":{"profile":{"type":"string","title":"Profile","default":"default"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"difficulty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Difficulty"},"record_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Record Type"},"since":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"},"until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Until"},"grounded_only":{"type":"boolean","title":"Grounded Only","default":false},"confidence_floor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Confidence Floor"},"min_agreement":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Agreement"},"buyer_request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Request Id"},"portal_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Version"},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality"},"case_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Case Source"},"include_answer_key":{"type":"boolean","title":"Include Answer Key","default":false},"include_mock":{"type":"boolean","title":"Include Mock","default":false},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"include_exported":{"type":"boolean","title":"Include Exported","default":false},"licensed_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Licensed To"},"license_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Label"},"exclusive":{"type":"boolean","title":"Exclusive","default":false},"license_expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Expires At"},"license_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Note"}},"type":"object","title":"ExportRequest"},"routers__gold__ExportRequest":{"properties":{"visit_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Visit Ids"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"since":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Since"},"difficulty_tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Difficulty Tag"},"task":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task"},"destination_label":{"type":"string","title":"Destination Label","default":"manual-download"},"pseudonymize":{"type":"boolean","title":"Pseudonymize","default":true},"export_format":{"type":"string","title":"Export Format","default":"record"}},"type":"object","title":"ExportRequest"},"triage__types__LabResult":{"properties":{"loinc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Loinc"},"name":{"type":"string","title":"Name"},"value":{"type":"number","title":"Value"},"unit":{"type":"string","title":"Unit","default":""},"drawn_at":{"type":"string","title":"Drawn At","default":""},"reference_range":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Range"},"is_abnormal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Abnormal"}},"type":"object","required":["name","value"],"title":"LabResult"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}