JSON or Javascript Object Notation, is a data format that has taken the web by storm. JSON is essentially a simpler, more compact and more easily readable XML which is the serialization format for javascript objects, so it works with both server and client side software.

We have developed relatively simple schemas for healthcare formats such as history and physical documents, radiology reports, operative reports etc. These leverage JSON formats used in healthcare namely FHIR.

In distinction to the HL7 standards, which represent the information in healthcare systems, these formats are intended to be simplified versions which represent the information used by healthcaare practitioners, yet including identifiers which can allow healthcare systems to obtain the full context from these simplified documents. For example a "rx" or presectiption needs to contain the patient's name and identifiers such as birthdate, and id as well as codes needed to definitively identify the prescribed drug, frequency of intake and length of time i.e. what used to be on a written script. Similarly a history and physical contains the information on the history and physical as well as patient identifying information but not necessarily all the metadata.

It is intended that healthcare organizations can exchange these documents with full HL7 compliant databases. Once data is in JSON format, its easy(er) to transform specific formats.

  operative_report : { 
	type : "Operative Report",
	patient:  {"Name": "John Doe", "id": "123456"},
	Date of Surgery: "2024-06-28",
	Surgeon: "Dr. Jane Smith",
	Assistant: "Dr. Emily Brown",
	Preoperative Diagnosis: "preop_diagnoses field ",
	Postoperative Diagnosis: "Same",
	Procedure: "procedures field",
	Indications: "either submitted in indications field or return detailed example Indications",
	Anesthesia: "General endotracheal anesthesia was administered.",
	Description of Procedure": "Return highly detailed example description of procedure", 
	Estimated Blood Loss : "ebl", 
	Findings : "example findings", 
	Specimens : "example specimens"
  }
	

This is what healthcare professionals recognize as an operaative report. It is essentially JSON. We can create a actual JSON schema to specify this:

operative_report_schema

{
	"$schema": "http://json-schema.org/draft-07/schema#",
	"$id": "http://json-healthcare.org/#operative_report_schema"
	"type": "object",
	"properties": {
    	"type" : {
      	"const" : "operative_report"
    },
    "patient" : patient_schema,
    "surgeon" : {
      "type" : "string",
      "description" : "surgeon or surgeon(s) name"
    },
    "assistant" : {
      "type" : "string",
      "description" : "assistants to surgeon"
    },
    "preop_diagnoses": {
      "type": "string",
      "description": "The preoperative diagnoses."
    },
    "postop_diagnoses": {
      "type": "string",
      "description": "The postoperative diagnoses."
    },
    "icd10_codes" : code_schema,
    "indications": {
      "type": "string",
      "description": "The indications for the surgery."
    },
    "procedures": {
      "type": "string",
      "description": "The procedures performed."
    },
    "cpt_codes" : code_schema,
    "procedure_description": {
      "type": "string",
      "description": "The detailed description of the procedure."
    },
    "findings": {
      "type": "string",
      "description": "The findings observed during the procedure."
    },
    "specimens": {
      "type": "string",
      "description": "Specimens obtained during the procedure."
    },
    "ebl": {
      "type": "string",
      "description": "Estimated blood loss during the procedure."
    },
    "complications": {
      "type": "string",
      "description": "Any complications that occurred during the procedure."
    }
  },
  "required": [
    "preop_diagnoses",
    "postop_diagnoses",
    "icd10_codes",
    "indications",
    "procedures",
    "cpt_codes",
    "procedure_description",
    "findings",
    "specimens",
    "ebl",
    "complications"
  ],
  "additionalProperties": false
};
	

patient schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id"  : "http://json-healthcare.org/#patient_schema",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "The identifier for the person with the application or example."
    },
    "identifier" : {
      "type" : "object",
      "properties" : {
        "use" : {
          "type" :"string",
          "enum" : ["official","usual","temp","secondary","old"],
          "description" : "identifier type, typically officual or usual if acive",
          //"default" : "usual"
        },
        "system" : {
          "type" : "string",
          "format" : "uri",
          "description" : "URI identifying issuer or identifier example: [https://chart.openhealth.org/identifier]",
          //"default" : "https://chart.openhealth.org/identifier"
        },
        "value" : {
          "type" : "string",
          "description" : "the identifier unique within the system namespace"
        }
      },
      "required" : ["value","system","use"],
      "additionalProperties" : false
    },
    "name": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "family": {
            "type": "string",
            "description": "The family name (last name) of the person."
          },
          "given": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "The given name(s) (first name, middle name) of the person."
            },
            "minItems": 1
          },
          "prefix": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "The prefixes (e.g. Mr.,Dr.) of the person name."
            },
          },
          "suffic": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "The suffixes (e.g. [III,PH.D.] of the person name."
            }
          }
        },
        "required": ["family", "given"],
        "additionalProperties": false
      }
    },
    "birthdate": {
      "type": "string",
      "format": "date",
      "description": "The birthdate of the person."
    },
    "age": {
      "type": "integer",
      "description": "The age of the person."
    },
    "gender": {
      "type": "string",
      "enum": ["male", "female", "other"],
      "description": "The gender of the person."
    }
  },
  "required": ["id","identifier","name", "gender"],
  "oneOf": [
    { "required": ["birthdate"] },
    { "required": ["age"] }
  ],
  "additionalProperties": false
};

code schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id"  : "http://json-healthcare.org/#code_schema",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "code": {
        "type": "string",
        "description": "The ICD10 or CPT code."
      },
      "description": {
        "type": "string",
        "description": "Description of the ICD10 or CPT code."
      }
    },
    "required": ["code", "description"],
    "additionalProperties": false
  }}

Coding Schema (array)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id"  : "http://json-healthcare.org/#coding_schema",
  "type": "object",
  "properties": {
    "comments": {
      "type": "string",
      "description": "Provide justification for codes."
    },
    "icd10_codes": {
      "type": ["array","null"],
      "items": code_schema
    },
    "cpt_codes": {
      "type": ["array","null"],
      "items": code_schema
    }
  },
  "required": ["comments","icd10_codes","cpt_codes"],
  "additionalProperties": false
};

Neurologic Exam

{
  "$schema": "https://json-schema.org/draft/2019-09/schema",
  "$id"  : "http://json-healthcare.org/#neurologic_exam_schema",
  "type": "object",
  "properties": {
    "exam" : {
      "const" : "neurological_exam"
    },
    "mental_status": {
      "type": ["object", "null"],
      "properties": {
        "level_of_consciousness": {
          "oneOf": [
            {
              "type": "string",
              "enum": ["alert", "lethargic", "stupor", "coma"],
              "description": "The patient's level of consciousness."
            },
            {
              "type": "object",
              "properties": {
                "eye_opening": {
                  "type": "integer",
                  "enum": [1, 2, 3, 4],
                  "description": "Eye-opening response, scored from 1 to 4."
                },
                "verbal_response": {
                  "type": "integer",
                  "enum": [1, 2, 3, 4, 5],
                  "description": "Verbal response, scored from 1 to 5."
                },
                "motor_response": {
                  "type": "integer",
                  "enum": [1, 2, 3, 4, 5, 6],
                  "description": "Motor response, scored from 1 to 6."
                },
                "total_score": {
                  "type": "integer",
                  "minimum": 3,
                  "maximum": 15,
                  "description": "Total Glasgow Coma Scale score, calculated from eye, verbal, and motor responses."
                }
              },
              "required": ["eye_opening", "verbal_response", "motor_response", "total_score"],
              "description": "Glasgow Coma Scale (GCS) scoring for level of consciousness."
            }
          ]
        },
        "orientation": {
          "type": ["array", "null"],
          "items": {
            "type": "string",
            "enum": ["person", "place", "time"],
            "description": "The patient's orientation to person, place, and time."
          },
          "description": "Array indicating the patient's orientation to person, place, and time."
        },
        "memory": {
          "type": ["string", "null"],
          "description": "The patient's memory assessment."
        },
        "attention": {
          "type": ["string", "null"],
          "description": "The patient's attention and concentration."
        },
        "speech": {
          "type": ["string", "null"],
          "description": "The patient's speech characteristics."
        }
      },
      "required": ["level_of_consciousness", "orientation", "memory", "attention", "speech"]
    },
    "cranial_nerves": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "CN_I": { "type": "string", "description": "Cranial Nerve I (Olfactory) function." },
            "CN_II": { "type": "string", "description": "Cranial Nerve II (Optic) function." },
            "CN_III": { "type": "string", "description": "Cranial Nerve III (Oculomotor) function." },
            "CN_IV": { "type": "string", "description": "Cranial Nerve IV (Trochlear) function." },
            "CN_V": { "type": "string", "description": "Cranial Nerve V (Trigeminal) function." },
            "CN_VI": { "type": "string", "description": "Cranial Nerve VI (Abducens) function." },
            "CN_VII": { "type": "string", "description": "Cranial Nerve VII (Facial) function." },
            "CN_VIII": { "type": "string", "description": "Cranial Nerve VIII (Vestibulocochlear) function." },
            "CN_IX": { "type": "string", "description": "Cranial Nerve IX (Glossopharyngeal) function." },
            "CN_X": { "type": "string", "description": "Cranial Nerve X (Vagus) function." },
            "CN_XI": { "type": "string", "description": "Cranial Nerve XI (Accessory) function." },
            "CN_XII": { "type": "string", "description": "Cranial Nerve XII (Hypoglossal) function." }
          },
          "required": ["CN_I", "CN_II", "CN_III", "CN_IV", "CN_V", "CN_VI", "CN_VII", "CN_VIII", "CN_IX", "CN_X", "CN_XI", "CN_XII"]
        },
        {
          "type": "string",
        }
      ]
    },
    "motor_function": {
      "type": "object",
      "properties": {
        "muscle_bulk": {
          "type": ["string", "null"],
          "description": "Assessment of muscle bulk."
        },
        "muscle_tone": {
          "type": ["string", "null"],
          "description": "Assessment of muscle tone."
        },
        "muscle_strength": {
          "oneOf": [
            {
              "type": "object",
              "properties" : {
                  "name": {
                    "type": "string",
                    "description": "The name of the muscle."
                  },
                  "strength": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 5,
                    "description": "The muscle strength on a scale of 0-5."
                  }
                },
                "required": ["name", "strength"],
                "additionalProperties": false
            },
            {
              "type": "string",
              "description" : "description of muscle strength"
            }
          ]
        },
        "involuntary_movements": {
          "type": ["string", "null"],
          "description": "Assessment of any involuntary movements."
        }
      },
      "required": ["muscle_bulk", "muscle_tone", "muscle_strength", "involuntary_movements"]
    },
    "reflexes": {
      "type": "object",
      "properties": {
        "deep_tendon_reflexes": {
          "type": "string",
          "description": "Assessment of deep tendon reflexes."
        },
        "plantar_reflex": {
          "type": "string",
          "description": "Assessment of the plantar reflex."
        }
      },
      "required": ["deep_tendon_reflexes", "plantar_reflex"]
    },
    "sensory_function": {
      "type": "object",
      "properties": {
        "light_touch": {
          "type": "string",
          "description": "Assessment of light touch sensation."
        },
        "pain": {
          "type": "string",
          "description": "Assessment of pain sensation."
        },
        "temperature": {
          "type": "string",
          "description": "Assessment of temperature sensation."
        },
        "vibration": {
          "type": "string",
          "description": "Assessment of vibration sensation."
        },
        "proprioception": {
          "type": "string",
          "description": "Assessment of proprioception."
        }
      },
      "required": ["light_touch", "pain", "temperature", "vibration", "proprioception"]
    },
    "coordination": {
      "type": ["object", "null"],
      "properties": {
        "finger_to_nose": {
          "type": "string",
          "description": "Assessment of finger-to-nose coordination."
        },
        "heel_to_shin": {
          "type": "string",
          "description": "Assessment of heel-to-shin coordination."
        },
        "rapid_alternating_movements": {
          "type": "string",
          "description": "Assessment of rapid alternating movements."
        }
      },
      "required": ["finger_to_nose", "heel_to_shin", "rapid_alternating_movements"]
    },
    "gait_and_stance": {
      "type": ["object", "null"],
      "properties": {
        "gait": {
          "type": "string",
          "description": "Assessment of gait."
        },
        "romberg_test": {
          "type": "string",
          "description": "Result of the Romberg test."
        }
      },
      "required": ["gait", "romberg_test"]
    },
    "additional_notes": {
      "type": "string",
      "description": "Any additional notes or observations during the exam."
    }
  },
  "required": [
    "mental_status",
    "cranial_nerves",
    "motor_function",
    "reflexes",
    "sensory_function",
    "coordination",
    "gait_and_stance"
  ],
  "additionalProperties": false
};

Opthalmic Exam Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id" : "http://json.healthcare.org/#opthalmic_exam_schema"
  "type": "object",
  "properties": {
    "visual_acuity": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "right_eye": {
              "type": "string",
              "description": "Visual acuity in the right eye."
            },
            "left_eye": {
              "type": "string",
              "description": "Visual acuity in the left eye."
            },
            "both_eyes": {
              "type": "string",
              "description": "Visual acuity in both eyes together."
            }
          },
          "required": ["right_eye", "left_eye", "both_eyes"]
        },
        {
          "type": "string",
          "description": "A simplified description of visual acuity."
        }
      ]
    },
    "pupillary_reaction": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normal", "sluggish", "non-reactive"],
          "description": "Assessment of pupillary reaction to light."
        },
        {
          "type": "null",
          "description": "No pupillary reaction assessment recorded."
        }
      ]
    },
    "ocular_alignment": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normal", "esotropia", "exotropia", "hypertropia", "hypotropia"],
          "description": "Assessment of ocular alignment."
        },
        {
          "type": "null",
          "description": "No ocular alignment assessment recorded."
        }
      ]
    },
    "extraocular_movements": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["intact", "restricted"],
          "description": "Assessment of extraocular movements."
        },
        {
          "type": "null",
          "description": "No extraocular movements assessment recorded."
        }
      ]
    },
    "visual_fields": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["full", "restricted"],
          "description": "Assessment of visual fields."
        },
        {
          "type": "null",
          "description": "No visual fields assessment recorded."
        }
      ]
    },
    "fundoscopy": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "optic_disc": {
              "type": "string",
              "enum": ["normal", "pale", "hyperemic", "edematous"],
              "description": "Assessment of the optic disc."
            },
            "macula": {
              "type": "string",
              "enum": ["normal", "hemorrhage", "exudates", "drusen"],
              "description": "Assessment of the macula."
            },
            "vessels": {
              "type": "string",
              "enum": ["normal", "narrowed", "dilated", "tortuous"],
              "description": "Assessment of retinal vessels."
            },
            "retina": {
              "type": "string",
              "enum": ["normal", "detached", "hemorrhage", "exudates"],
              "description": "Assessment of the retina."
            }
          },
          "required": ["optic_disc", "macula", "vessels", "retina"]
        },
        {
          "type": "string",
          "description": "A simplified description of fundoscopy findings."
        }
      ]
    },
    "intraocular_pressure": {
      "oneOf": [
        {
          "type": "string",
          "description": "Assessment of intraocular pressure."
        },
        {
          "type": "null",
          "description": "No intraocular pressure assessment recorded."
        }
      ]
    },
    "additional_notes": {
      "oneOf": [
        {
          "type": "string",
          "description": "Any additional notes or observations during the ophthalmic exam."
        },
        {
          "type": "null",
          "description": "No additional notes recorded."
        }
      ]
    }
  },
  "required": [
    "visual_acuity",
    "pupillary_reaction",
    "ocular_alignment",
    "extraocular_movements",
    "visual_fields",
    "fundoscopy"
  ],
  "additionalProperties": false
}

HEENT Exam Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id" : "http://json.healthcare.org/#HEENT_exam_schema"
  "type": "object",
  "properties": {
    "head": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normocephalic", "atraumatic", "abnormal"],
          "description": "Assessment of the head."
        },
        {
          "type": "null",
          "description": "No head assessment recorded."
        }
      ]
    },
    "eyes": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "conjunctiva": {
              "type": "string",
              "enum": ["clear", "injected", "pale"],
              "description": "Assessment of the conjunctiva."
            },
            "sclera": {
              "type": "string",
              "enum": ["normal", "icteric"],
              "description": "Assessment of the sclera."
            },
            "pupils": {
              "type": "string",
              "enum": ["equal", "unequal", "reactive", "non-reactive"],
              "description": "Assessment of pupil size and reactivity."
            },
            "extraocular_movements": {
              "type": "string",
              "enum": ["intact", "restricted"],
              "description": "Assessment of extraocular movements."
            }
          },
          "required": ["conjunctiva", "sclera", "pupils", "extraocular_movements"]
        },
        {
          "type": "string",
          "description": "A simplified description of the eye exam."
        }
      ]
    },
    "ears": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "canals": {
              "type": "string",
              "enum": ["clear", "obstructed"],
              "description": "Assessment of the ear canals."
            },
            "tympanic_membranes": {
              "type": "string",
              "enum": ["intact", "perforated", "retracted", "bulging"],
              "description": "Assessment of the tympanic membranes."
            },
            "hearing": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of hearing."
            }
          },
          "required": ["canals", "tympanic_membranes", "hearing"]
        },
        {
          "type": "string",
          "description": "A simplified description of the ear exam."
        }
      ]
    },
    "nose": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "nares": {
              "type": "string",
              "enum": ["patent", "obstructed"],
              "description": "Assessment of the nares."
            },
            "mucosa": {
              "type": "string",
              "enum": ["normal", "inflamed", "pale"],
              "description": "Assessment of the nasal mucosa."
            },
            "discharge": {
              "type": "string",
              "enum": ["none", "clear", "purulent", "bloody"],
              "description": "Description of any nasal discharge."
            }
          },
          "required": ["nares", "mucosa", "discharge"]
        },
        {
          "type": "string",
          "description": "A simplified description of the nose exam."
        }
      ]
    },
    "throat": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "oropharynx": {
              "type": "string",
              "enum": ["clear", "erythematous", "exudative"],
              "description": "Assessment of the oropharynx."
            },
            "tonsils": {
              "type": "string",
              "enum": ["normal", "enlarged", "absent"],
              "description": "Assessment of the tonsils."
            },
            "uvula": {
              "type": "string",
              "enum": ["midline", "deviated"],
              "description": "Assessment of the uvula."
            },
            "dentition": {
              "type": "string",
              "enum": ["normal", "poor", "absent"],
              "description": "Assessment of dentition."
            }
          },
          "required": ["oropharynx", "tonsils", "uvula", "dentition"]
        },
        {
          "type": "string",
          "description": "A simplified description of the throat exam."
        }
      ]
    },
    "neck": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "trachea": {
              "type": "string",
              "enum": ["midline", "deviated"],
              "description": "Assessment of tracheal position."
            },
            "thyroid": {
              "type": "string",
              "enum": ["normal", "enlarged", "nodular"],
              "description": "Assessment of the thyroid."
            },
            "lymph_nodes": {
              "type": "string",
              "enum": ["nonpalpable", "palpable", "tender", "nontender"],
              "description": "Assessment of neck lymph nodes."
            }
          },
          "required": ["trachea", "thyroid", "lymph_nodes"]
        },
        {
          "type": "string",
          "description": "A simplified description of the neck exam."
        }
      ]
    },
    "additional_notes": {
      "oneOf": [
        {
          "type": "string",
          "description": "Any additional notes or observations during the HEENT exam."
        },
        {
          "type": "null",
          "description": "No additional notes recorded."
        }
      ]
    }
  },
  "required": [
    "head",
    "eyes",
    "ears",
    "nose",
    "throat",
    "neck"
  ],
  "additionalProperties": false
}

Abdominal Exam Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id" : "http://json.healthcare.org/#abdominal_exam_schema"
  "type": "object",
  "properties": {
    "bowel_sounds": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normal", "hyperactive", "hypoactive", "absent"],
          "description": "Assessment of bowel sounds."
        },
        {
          "type": "null",
          "description": "No bowel sounds assessment recorded."
        }
      ]
    },
    "tenderness": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "location": {
              "type": "string",
              "description": "Location of tenderness, if present."
            },
            "severity": {
              "type": "string",
              "enum": ["mild", "moderate", "severe"],
              "description": "Severity of tenderness."
            }
          },
          "required": ["location", "severity"]
        },
        {
          "type": "string",
          "enum": ["none"],
          "description": "A simplified description indicating no tenderness."
        }
      ]
    },
    "distension": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["none", "mild", "moderate", "severe"],
          "description": "Assessment of abdominal distension."
        },
        {
          "type": "null",
          "description": "No distension assessment recorded."
        }
      ]
    },
    "guarding": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["present", "absent"],
          "description": "Assessment of abdominal guarding."
        },
        {
          "type": "null",
          "description": "No guarding assessment recorded."
        }
      ]
    },
    "rebound_tenderness": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["present", "absent"],
          "description": "Assessment of rebound tenderness."
        },
        {
          "type": "null",
          "description": "No rebound tenderness assessment recorded."
        }
      ]
    },
    "liver_size": {
      "oneOf": [
        {
          "type": "string",
          "description": "Description of liver size and span."
        },
        {
          "type": "null",
          "description": "No liver size assessment recorded."
        }
      ]
    },
    "spleen_size": {
      "oneOf": [
        {
          "type": "string",
          "description": "Description of spleen size."
        },
        {
          "type": "null",
          "description": "No spleen size assessment recorded."
        }
      ]
    },
    "masses": {
      "oneOf": [
        {
          "type": "string",
          "description": "Description of any palpable masses."
        },
        {
          "type": "null",
          "description": "No masses assessed or recorded."
        }
      ]
    },
    "additional_notes": {
      "oneOf": [
        {
          "type": "string",
          "description": "Any additional notes or observations during the abdominal exam."
        },
        {
          "type": "null",
          "description": "No additional notes recorded."
        }
      ]
    }
  },
  "required": [
    "bowel_sounds",
    "tenderness",
    "distension",
    "guarding",
    "rebound_tenderness",
    "liver_size",
    "spleen_size",
    "masses"
  ],
  "additionalProperties": false
}

Cardiac Exam Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id" : "http://json.healthcare.org/#cardiac_exam_schema"
  "type": "object",
  "properties": {
    "heart_rate": {
      "oneOf": [
        {
          "type": "integer",
          "description": "The patient's heart rate in beats per minute."
        },
        {
          "type": "string",
          "enum": ["regular", "tachy", "brady"],
          "description": "The patient's heart rate description."
        }
      ]
    },
    "rhythm": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["regular", "irregular", "irregularly irregular"],
          "description": "The rhythm of the heart."
        },
        {
          "type": "null",
          "description": "No rhythm assessment recorded."
        }
      ]
    },
    "heart_sounds": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "s1": {
              "type": "string",
              "enum": ["normal", "accentuated", "diminished"],
              "description": "Assessment of the first heart sound (S1)."
            },
            "s2": {
              "type": "string",
              "enum": ["normal", "accentuated", "diminished", "split"],
              "description": "Assessment of the second heart sound (S2)."
            },
            "s3": {
              "type": "string",
              "enum": ["present", "absent"],
              "description": "Assessment of the third heart sound (S3)."
            },
            "s4": {
              "type": "string",
              "enum": ["present", "absent"],
              "description": "Assessment of the fourth heart sound (S4)."
            },
            "additional_sounds": {
              "type": "string",
              "description": "Description of any additional heart sounds."
            }
          },
          "required": ["s1", "s2", "s3", "s4"]
        },
        {
          "type": "string",
          "description": "A simplified description of heart sounds."
        }
      ]
    },
    "murmurs": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "presence": {
              "type": "string",
              "enum": ["none", "present"],
              "description": "Indicates whether a murmur is present."
            },
            "type": {
              "type": "string",
              "enum": ["systolic", "diastolic", "continuous"],
              "description": "Type of murmur, if present."
            },
            "grade": {
              "type": "integer",
              "minimum": 1,
              "maximum": 6,
              "description": "Grade of the murmur on a scale of 1 to 6."
            },
            "location": {
              "type": "string",
              "description": "Location where the murmur is best heard."
            },
            "radiation": {
              "type": "string",
              "description": "Radiation of the murmur to other areas."
            },
            "description": {
              "type": "string",
              "description": "Detailed description of the murmur."
            }
          },
          "required": ["presence"]
        },
        {
          "type": "null",
          "description": "No murmur assessed or recorded."
        }
      ]
    },
    "peripheral_pulses": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "carotid": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of the carotid pulse."
            },
            "radial": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of the radial pulse."
            },
            "femoral": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of the femoral pulse."
            },
            "dorsalis_pedis": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of the dorsalis pedis pulse."
            },
            "posterior_tibial": {
              "type": "string",
              "enum": ["normal", "diminished", "absent"],
              "description": "Assessment of the posterior tibial pulse."
            }
          },
          "required": ["carotid", "radial", "femoral", "dorsalis_pedis", "posterior_tibial"]
        },
        {
          "type": "null",
          "description": "No peripheral pulse assessment."
        }
      ]
    },
    "blood_pressure": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "systolic": {
              "type": "integer",
              "description": "The systolic blood pressure in mmHg."
            },
            "diastolic": {
              "type": "integer",
              "description": "The diastolic blood pressure in mmHg."
            },
            "position": {
              "type": "string",
              "enum": ["sitting", "standing", "lying down"],
              "description": "The position of the patient during blood pressure measurement."
            }
          },
          "required": ["systolic", "diastolic", "position"]
        },
        {
          "type": "string",
          "description": "A simplified description of blood pressure."
        }
      ]
    },
    "jugular_venous_pressure": {
      "oneOf": [
        {
          "type": "string",
          "description": "Assessment of the jugular venous pressure (JVP)."
        },
        {
          "type": "null",
          "description": "No JVP assessment recorded."
        }
      ]
    },
    "edema": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["none", "mild", "moderate", "severe"],
          "description": "Assessment of peripheral edema."
        },
        {
          "type": "null",
          "description": "No edema assessment recorded."
        }
      ]
    },
    "additional_notes": {
      "oneOf": [
        {
          "type": "string",
          "description": "Any additional notes or observations during the heart exam."
        },
        {
          "type": "null",
          "description": "No additional notes recorded."
        }
      ]
    }
  },
  "required": [
    "heart_rate",
    "rhythm",
    "heart_sounds",
    "murmurs",
    "peripheral_pulses",
    "blood_pressure",
    "jugular_venous_pressure",
    "edema"
  ],
  "additionalProperties": false
}

Pulmonary Exam Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id" : "http://json.healthcare.org/#pulmonary_exam_schema"
  "type": "object",
  "properties": {
    "respiratory_rate": {
      "oneOf": [
        {
          "type": "integer",
          "description": "The patient's respiratory rate in breaths per minute."
        },
        {
          "type": "string",
          "enum": ["normal", "tachypnea", "bradypnea"],
          "description": "A simplified description of the respiratory rate."
        }
      ]
    },
    "breath_sounds": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "vesicular": {
              "type": "string",
              "enum": ["normal", "diminished"],
              "description": "Assessment of vesicular breath sounds."
            },
            "bronchial": {
              "type": "string",
              "enum": ["normal", "increased", "decreased"],
              "description": "Assessment of bronchial breath sounds."
            },
            "crackles": {
              "type": "string",
              "enum": ["present", "absent"],
              "description": "Assessment of crackles."
            },
            "wheezes": {
              "type": "string",
              "enum": ["present", "absent"],
              "description": "Assessment of wheezes."
            },
            "rhonchi": {
              "type": "string",
              "enum": ["present", "absent"],
              "description": "Assessment of rhonchi."
            }
          },
          "required": ["vesicular", "bronchial", "crackles", "wheezes", "rhonchi"]
        },
        {
          "type": "string",
          "description": "A simplified description of breath sounds."
        }
      ]
    },
    "chest_expansion": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normal", "decreased"],
          "description": "Assessment of chest expansion."
        },
        {
          "type": "null",
          "description": "No chest expansion assessment recorded."
        }
      ]
    },
    "percussion": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["resonant", "dull", "hyperresonant"],
          "description": "Assessment of chest percussion."
        },
        {
          "type": "null",
          "description": "No percussion assessment recorded."
        }
      ]
    },
    "tactile_fremitus": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["normal", "increased", "decreased"],
          "description": "Assessment of tactile fremitus."
        },
        {
          "type": "null",
          "description": "No tactile fremitus assessment recorded."
        }
      ]
    },
    "egophony": {
      "oneOf": [
        {
          "type": "string",
          "enum": ["present", "absent"],
          "description": "Assessment of egophony."
        },
        {
          "type": "null",
          "description": "No egophony assessment recorded."
        }
      ]
    },
    "additional_notes": {
      "oneOf": [
        {
          "type": "string",
          "description": "Any additional notes or observations during the chest/pulmonary exam."
        },
        {
          "type": "null",
          "description": "No additional notes recorded."
        }
      ]
    }
  },
  "required": [
    "respiratory_rate",
    "breath_sounds",
    "chest_expansion",
    "percussion",
    "tactile_fremitus",
    "egophony"
  ],
  "additionalProperties": false
}

Plan Schema

this is intended to be incorpated into document schemas

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://json-healthcare/#plan_schema"
  "$defs" : {
  // the following should be defined at the top document level in order to avoid multiple definitions
  //  "Patient": patient_schema,
  //  "ICD10Codes": code_schema,
  //  "CPTCodes": code_schema,
    "LaboratoryOrder": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "Laboratory Order"
        },
        "order": {
          "type": "object",
          "properties": {
            "date": {
              "type": "string",
              "format": "date"
            },
            "reason_for_test": {
              "type": "string"
            },
            "clinical_indications": {
              "type": "string"
            },
            "tests_ordered": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/CPTCodes",
              }
            }
          },
          "required": ["date", "reason_for_test", "clinical_indications", "tests_ordered"]
        }
      },
      "required": ["type", "order"] //"patient"
    },
    "RadiologyOrder": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "Radiology Order"
        },
        "order": {
          "type": "object",
          "properties": {
            "date": {
              "type": "string",
              "format": "date"
            },
            "reason_for_test": {
              "type": "string"
            },
            "clinical_indications": {
              "type": "string"
            },
            "tests_ordered": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/CPTCodes",
              }
            }
          },
          "required": ["date", "reason_for_test", "clinical_indications", "tests_ordered"]
        }
      },
      "required": ["type", "order"]
    },
    "FollowupAppointment": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "Followup Appointment"
        },
        "reason": {
          "type": "string"
        }
      },
      "required": ["type", "reason"]
    },
    "PhysicalTherapyReferral": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "Physical Therapy Referral"
        },
        //"patient": { "$ref": "#/$defs/Patient"},
        "referral": {
          "type": "object",
          "properties": {
            "date": {
              "type": "string",
              "format": "date"
            },
            //"referring_physician": {"type": "string"},
            "reason_for_referral": {
              "type": "string"
            },
            "clinical_indications": {
              "type": "string"
            },
            "services_requested": {
              "type": "string"
            },
            "icd10_codes": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/ICD10Codes"
              },
              "description" : "ICD10 Codes for diagnoses being referred to PT"
            }
          },
          "required": ["date", "reason_for_referral", "clinical_indications", "services_requested", "icd10_codes"] // "referring_physician", 
        }
      },
      "required": ["type", "referral"] // "patient", 
    },
    "Referral" : {
          "type": "object",
          "properties": {
              "type": {
                "type": "string",
                "const": "Referral"
              },
              "date": {
                "type": "string",
                "format": "date"
              },
              //"referring_provider": { "type": "string"},
              "reason_for_referral": {
                "type": "string"
              },
              "suspected_diagnoses": {
                "type": "array",
                "items": {
                  "$ref" : "#/$defs/ICD10Codes"
                }
              },
              "procedures_requested": {
                "type": ["array","null"],
                "items": {
                  "$ref" : "#/$defs/CPTCodes"
                }
              },
              "clinical_indications": {
                "type": "string"
              },
              "specialist_requested": {
                "type": "string"
              }
            },
            "required": ["date", "reason_for_referral", "suspected_diagnoses", "clinical_indications", "specialist_requested","procedures_requested"] //"referring_provider",
    },
    "Prescription" : {
      "type": "object",
      "properties": {
      "type": {
        "type": "string",
        "const": "Prescription"
      },
      // "patient": {"$ref": "#/$defs/Patient"},
    //"prescribing_physician": {"type": "string"},
      "prescription_date": {
      "type": "string",
      "format": "date"
      },
     "medications": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
          "drug_name": {
            "type": "string"
          },
          "dosage": {
            "type": "string"
          },
          "frequency": {
            "type": "string"
          },
          "route_of_administration": {
            "type": "string"
          },
          "duration": {
            "type": "string"
          }
        },
        "required": ["drug_name", "dosage", "frequency", "route_of_administration", "duration"]
      }
    },
    "special_instructions": {
      "type": ["string","null"]
    },
    "refills": {
      "type": "integer",
      "minimum": 0
    }
  },
  "required": [
    "type",
//    "patient",
//    "prescribing_physician",
    "prescription_date",
    "medications",
    "special_instructions",
    "refills"
  ]
},
"Discussion" : {
  "type" : "object",
  "properties" : {
  "type": {
                "type": "string",
                "const": "Discussion"
              },    
    "discussion" : {
      "type" : "string"
      },
    "minutes" : {
      "type" : "integer"
    }
  }
},
"Instructions" : {
  "type" : "object",
  "properties" : {
    "type": {
                "type": "string",
                "const": "Instructions"
              },    
    "instructions" : {
      "type" : "string"
      },
  }
}},
  "type": "array",
  "items": {
        "oneOf": [
          { "$ref": "#/$defs/RadiologyOrder"},
          { "$ref": "#/$defs/LaboratoryOrder" },
          { "$ref": "#/$defs/FollowupAppointment" },
          { "$ref": "#/$defs/PhysicalTherapyReferral" },
          { "$ref": "#/$defs/Referral" },
          { "$ref": "#/$defs/Presecription" },
          { "$ref": "#/$defs/Discussion" },
          { "$ref": "#/$defs/Instructions"}
        ]
      }
}

Initial Consultation Schema

{
  "$schema": "https://json-schema.org/draft/2020-012/schema",
  "$id": "https://json-healthcare.org/#initial_consultation_schema",
  "type": "object",
  "$defs" : {
    "Patient": { "$ref" : "/patient_schema"},
    "ICD10Codes": { "$ref" : "/code_schema"},
    "CPTCodes": { "$ref" : "/code_schema"}
    },
  "properties": {
    "type": {
      "type": "string",
      "const": "initial_consultation"
    },
    "specialty" : {
      "type" : "string",
      "description" : "type of specialist performing consulation"
    },
    "patient": { "$ref" : "#/$defs/Patient" },
    "Date_of_Consultation": {
      "type": "string",
      "format": "date"
    },
    "Consultant": {
      "type": "string"
    },
    "Referring_Provider": {
      "type": "string"
    },
    "Chief_Complaint": {
      "type": "string"
    },
    "History_of_Present_Illness": {
      "type": "string"
    },
    "Past_Medical_History": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "Surgical_History": {
      "type": "string"
    },
    "Family_History": {
      "type": "string"
    },
    "Social_History": {
      "type": "object",
      "properties": {
        "Smoking": {
          "type": "string"
        },
        "Alcohol": {
          "type": "string"
        },
        "Drug_Use": {
          "type": "string"
        }
      },
      "required": ["Smoking", "Alcohol", "Drug_Use"],
      "additionalProperties" : false
    },
    "Medications": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "Allergies": {
      "type": "string"
    },
    "Review_of_Systems": {
      "type": "object",
      "properties": {
        "General": {
          "type": "string"
        },
        "HEENT": {
          "type": "string"
        },
        "Cardiovascular": {
          "type": "string"
        },
        "Respiratory": {
          "type": "string"
        },
        "Gastrointestinal": {
          "type": "string"
        },
        "Genitourinary": {
          "type": "string"
        },
        "Neurological": {
          "type": "string"
        },
        "Musculoskeletal": {
          "type": "string"
        }
      },
      "required": ["General", "HEENT", "Cardiovascular", "Respiratory", "Gastrointestinal", "Genitourinary", "Neurological", "Musculoskeletal"],
      "additioanlProperties" : false
    },
    "Physical_Examination": { "$ref" : "/physical_exam_schema" },
    "Assessment": {
      "type": "object",
      "properties": {
        "impression": {
          "type": "string",
          "description" : "text description of the reasoning and findings leading to assessment"
        },
        "icd10_codes": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/ICD10Codes"
          },
          "description" : "Assessment diagnoses as CPT codes"
        }
      },
      "required": ["impression", "icd10_codes"],
      "additonalProperties" : false
    },
    "Plan": { "$ref" : "/plan_schema },
    "Consultant_Signature": {
      "type": "string"
    }
  },
  "required": [
    "type",
    "patient",
    "Date_of_Consultation",
    "Consultant",
    "Chief_Complaint",
    "History_of_Present_Illness",
    "Past_Medical_History",
    "Surgical_History",
    "Family_History",
    "Social_History",
    "Medications",
    "Allergies",
    "Review_of_Systems",
    "Physical_Examination",
    "Assessment",
    "Plan",
    "Consultant_Signature"
  ],
  "additionalProperties" : false
}