canonical: https://jentic.com/apis/patientview.org/patientview-patientview

# PatientView

Jentic publishes the only available OpenAPI specification for PatientView, keeping it validated and agent-ready. PatientView exposes REST API endpoints for patient portal integration, enabling authentication, patient record access, clinical observation management, and patient administration. The API provides 15 endpoints for managing user sessions, recording health observations like blood pressure and weight, retrieving patient demographics, and administering patient group memberships across healthcare organizations.

## For AI agents

Manage patient portal sessions, record clinical observations, retrieve patient demographics, and administer patient group registrations for healthcare organizations.

## Scope

Does not handle prescriptions, appointment scheduling, or clinical decision support - use for patient portal access, observations, and administration only.

## Capabilities

- Authenticate users and manage secure session tokens for API access
- Query clinical observations by standardized code for individual patients
- Record patient-entered health measurements such as vitals and lab values
- Retrieve patient demographic data and group membership information
- List available observation headings configured for specific user accounts
- Validate and create patient identifier associations across healthcare groups
- Manage patient surgery records within organizational group contexts

## Use cases

### Patient Health Self-Reporting

Enable patients to submit their own health measurements through the PatientView API. The patient-entered observation endpoints accept values for configured clinical codes such as blood pressure, weight, and blood glucose. These self-reported values integrate into the patient's clinical timeline alongside clinician-recorded data.

Example prompt: Record a weight observation of 72.5 kg for user ID 12345 via POST `/user/{userId}/observations/{code}/patiententered` with code 'weight'

### Clinical Data Integration

Retrieve patient observation data from PatientView to integrate with external clinical systems or dashboards. The observation endpoints return time-series health data by clinical code, enabling trending, alerting, and cross-system data synchronization for healthcare IT platforms.

Example prompt: Retrieve all blood pressure observations for user 12345 via GET `/user/{userId}/observations/bloodpressure` and return the latest 5 readings with dates

### Multi-Site Patient Registration

Administer patient identifiers and group associations for healthcare organizations operating across multiple sites. The patient management endpoints validate identifier data and create associations between patients and organizational groups, supporting complex multi-facility patient identity management.

Example prompt: Validate patient data for user 12345 in group 'HOSP01' via GET `/patientmanagement/validate`, then register the identifier via POST `/patientmanagement/{userId}/group/{groupId}/identifier/{identifierId}`

### AI Agent Patient Portal Access

AI agents access PatientView endpoints through Jentic to automate patient data retrieval and observation recording without managing session token lifecycle. Agents search for healthcare operations and receive structured schemas with authentication handled by the Jentic credential vault.

Example prompt: Search Jentic for 'record a patient observation', load the schema for POST `/user/{userId}/observations/{code}/patiententered`, and execute with user ID, code, and value

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | `/auth/login` | Authenticate and get session token |
| GET | `/patient/{userId}/basic` | Retrieve patient demographics |
| GET | `/user/{userId}/observations/{code}` | Query observations by code |
| POST | `/user/{userId}/observations/{code}/patiententered` | Submit patient-entered observation |
| GET | `/user/{userId}/availableobservationheadings` | List observation types for user |
| GET | `/user/{userId}/patiententeredobservationheadings` | List patient-enterable observation types |

## Key resources

- **Authentication** — Manage user sessions with login, logout, and token-based user info retrieval
- **Patients** — Access basic patient demographics and group membership data
- **Observations** — Query and submit clinical observation values by standardized code
- **Observation Headings** — Discover configured observation types available per user
- **Patient Management** — Validate, register, and manage patient identifiers within groups

## Why Jentic

- **Setup:** Wiring the PatientView API by hand means learning its login-and-session-token auth, setting the patientview.org host, and building observation and heading parsing yourself. Through Jentic you install once, import PatientView from the API Directory, store the credential once, and your agent calls it.
- **Permission scoping:** PatientView puts the user id in the URL path (`/user/{userId}/observations/{code}`), so a rule can pin your agent to one user for reading observations and available headings. You choose the operations it may call, so writes like submitting a patient-entered observation are not included unless you add them.
- **Credential handling:** Your PatientView session credential is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'read a patient's health observations' or 'list available observation headings', and Jentic returns the matching PatientView operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **PatientView** — Primary slug for the same PatientView API surface
- **drchrono API** — Full EHR with clinical workflows, prescriptions, and scheduling
- **athenahealth API** — Enterprise healthcare platform with records and billing

## FAQ

### Why is there no official OpenAPI spec for PatientView?

PatientView does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call PatientView via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does PatientView use?

PatientView uses token-based session authentication. Clients authenticate via POST `/auth/login` with credentials and receive a token used in subsequent requests. Sessions are terminated via POST `/auth/logout/{token}.` Jentic manages the token lifecycle in its credential vault so agents do not handle raw login credentials.

### Can patients submit their own health observations?

Yes. The POST `/user/{userId}/observations/{code}/patiententered` endpoint accepts patient-entered values for any observation code configured for that user. Available codes can be discovered via GET `/user/{userId}/patiententeredobservationheadings` which returns the list of headings patients are allowed to self-report.

### What observation types are supported?

Available observation types are configured per user and retrieved via GET `/user/{userId}/availableobservationheadings.` Common types include blood pressure, weight, and blood glucose. The specific headings available depend on the patient's clinical group and condition.

### How do I retrieve patient observations through Jentic?

Search Jentic for 'get patient clinical observations by code', load the operation schema for GET `/user/{userId}/observations/{code}`, and execute with the user ID and observation code. Jentic injects the session token automatically. Install with pip install jentic.

### Does PatientView support multi-group patient management?

Yes. The /patientmanagement endpoints manage patient identifiers within specific healthcare groups. Patients can be associated with multiple groups, and the `/patientmanagement/validate` endpoint checks data validity before creating associations. Surgery records can also be managed per group context.

### Can I limit what my agent is allowed to do with the PatientView API?

Yes. Because you run Jentic One yourself, your own rules decide which PatientView operations and credentials the agent may use. Since PatientView puts the user id in the URL path, such as GET `/user/{userId}/observations/{code}`, you can pin the agent to a single user and grant only read operations like querying observations and listing available observation headings. Write operations such as POST `/user/{userId}/observations/{code}/patiententered` stay off limits unless you explicitly add them.
