Skip to content

SunCharts EHR API

Practice administration

EHR API as of 26.11.11.41 4 operations openapi.json ↓

# Read current staff access policy and module permissions

GET /api/v1/practice/access-policy/current

Authenticated bootstrap metadata. No assignment means native role authorization; flags never grant authority beyond native checks.

Access OAuth 2.0 access tokenclinical.read

Responses

200 Tenant-scoped policy result. Cache-Control: no-store.

Example call

curl "$EHR_URL/api/v1/practice/access-policy/current" -H "Authorization: Bearer $ACCESS_TOKEN"

# Oldest unfinished native encounters across all dates

GET /api/v1/practice/worklist

Staff-only, tenant-scoped saved encounter work. Returns up to 100 rows, exact total and has_more from one database snapshot. No note or vitals content. All staff can read the queue; clinical staff write an encounter's note and a clinician or the owner signs it. Signing removes it from this list; this is not a checkout task system.

Access OAuth 2.0 access tokenclinical.read

Responses

200 Unfinished encounters application/json
Fields object · 18
Field Type Details
has_more required boolean
items required array of object items ≤ 100
appointment_id required string (uuid)
clinician_id required string (uuid)
created_at required string (date-time)
facility required string
mrn required string
note_saved required boolean
patient_id required string (uuid)
patient_name required string
provider_label required string
room required string
starts_at required string (date-time)
title required string
version required integer value ≥ 1
visit_id required string (uuid)
vitals_saved required boolean
total required integer value ≥ 0
Example response placeholder values
{
  "has_more": true,
  "items": [
    {
      "appointment_id": "00000000-0000-4000-8000-000000000000",
      "clinician_id": "00000000-0000-4000-8000-000000000000",
      "created_at": "2026-01-15T15:30:00Z",
      "facility": "string",
      "mrn": "string",
      "note_saved": true,
      "patient_id": "00000000-0000-4000-8000-000000000000",
      "patient_name": "string",
      "provider_label": "string",
      "room": "string",
      "starts_at": "2026-01-15T15:30:00Z",
      "title": "string",
      "version": 1,
      "visit_id": "00000000-0000-4000-8000-000000000000",
      "vitals_saved": true
    }
  ],
  "total": 0
}
401 Authentication required
403 Staff access required

Example call

curl "$EHR_URL/api/v1/practice/worklist" -H "Authorization: Bearer $ACCESS_TOKEN"

# Read versioned practice navigation and chart configuration

GET /api/v1/practice/workspace-settings

Authenticated staff bootstrap metadata. Hidden presentation never substitutes for native role or custom-policy authorization.

Access OAuth 2.0 access tokenclinical.read

Responses

200 Version, content, updated_by and updated_at.

Example call

curl "$EHR_URL/api/v1/practice/workspace-settings" -H "Authorization: Bearer $ACCESS_TOKEN"

# Save a versioned workspace configuration with an audit reason

PUT /api/v1/practice/workspace-settings

Owner only. Does not modify role policy, patient records or workflow definitions.

Access OAuth 2.0 access tokenclinical.read

Parameters

Name In Type Details
If-Match required header string Quoted version; "0" for first configuration.

Request body application/json · required

Fields object · 8
Field Type Details
content required PracticeWorkspaceConfiguration
chart_tabs required array of string Native chart area keys; overview required. Omitted areas remain hidden. Functional status and specialty care are independently selectable built-in areas; no specialty bundle is required.
module_order required array of string All supported module keys once. Legacy layouts missing only the four formerly fixed tools are normalized on read/write.
hidden_modules array of string
module_groups object
module_labels object
specialty_workspaces array of any Legacy presentation input, accepted for compatibility. An empty array preserves the previously hidden specialty navigation entry by adding specialty to hidden_modules. New requests use hidden_modules and chart_tabs independently. Normalized responses and new revisions omit this field; existing stored revisions remain unchanged.
reason required string length 1–1000
Example request body placeholder values
{
  "content": {
    "chart_tabs": [
      "string"
    ],
    "module_order": [
      "practice"
    ],
    "hidden_modules": [
      "practice"
    ],
    "module_groups": {},
    "module_labels": {},
    "specialty_workspaces": [
      "spasticity_movement"
    ]
  },
  "reason": "string"
}

Responses

200 Saved version and configuration.
400 Invalid configuration.
403 Owner authority required.
409 Configuration version changed.

Example call

curl -X PUT "$EHR_URL/api/v1/practice/workspace-settings" -H "Authorization: Bearer $ACCESS_TOKEN" -H "Content-Type: application/json" -d @body.json