{
  "resourceType": "StructureDefinition",
  "id": "patient-validation",
  "url": "https://ny.sepsis.ipro.org/fhir/StructureDefinition/patient-validation",
  "version": "1.0.0",
  "name": "PatientTestValidation",
  "title": "Patient Profile for test validation",
  "status": "draft",
  "date": "2025-05-12",
  "publisher": "ipro.org",
  "description": "Profile enforcing constraints on Patient resource.",
  "fhirVersion": "4.0.1",
  "kind": "resource",
  "abstract": false,
  "type": "Patient",
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Patient",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Patient",
        "path": "Patient"
      },
      {
        "id": "Patient.name.text",
        "path": "Patient.name.text",
        "constraint": [
          {
            "key": "pt-name",
            "severity": "error",
            "human": "Name must consist of exactly two words, and the first word must not start with 'X' or 'x'.",
            "expression": "matches('^(?![Xx])[A-Za-z]+ [A-Za-z]+$')"
          }
        ]
      }
    ]
  }
}