{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/api-evangelist/elation-health/main/json-schema/elation-health-letter-schema.json", "title": "Letter", "x-generated": "2026-10-12", "x-method": "derived", "x-generator": "derive-json-schema.py", "x-source": "openapi/elation-health-referrals-api-openapi.yml#/components/schemas/Letter", "properties": { "attachments": { "items": { "$ref": "#/$defs/LetterAttachment" }, "type": "array" }, "body": { "description": "The body of the letter.", "type": "string" }, "created_date": { "format": "date-time", "readOnly": true, "type": [ "string", "null" ] }, "deleted_date": { "format": "date-time", "readOnly": true, "type": [ "string", "null" ] }, "delivery_date": { "format": "date-time", "type": [ "string", "null" ] }, "delivery_method": { "$ref": "#/$defs/DeliveryMethodEnum" }, "direct_message_status": { "readOnly": true, "type": [ "string", "null" ] }, "direct_message_to": { "maxLength": 200, "type": [ "string", "null" ] }, "display_to": { "readOnly": true, "type": [ "string", "null" ] }, "document_date": { "format": "date-time", "type": "string" }, "email_to": { "maxLength": 200, "type": [ "string", "null" ] }, "failure_unacknowledged": { "type": "string" }, "fax_attachments": { "type": "boolean" }, "fax_status": { "readOnly": true, "type": "string" }, "fax_to": { "maxLength": 20, "type": [ "string", "null" ] }, "id": { "readOnly": true, "type": "integer" }, "is_processed": { "readOnly": true, "type": "boolean" }, "letter_type": { "readOnly": true, "type": "string" }, "patient": { "format": "int64", "type": "integer" }, "practice": { "format": "int64", "type": "integer" }, "referral_order": { "format": "int64", "type": [ "integer", "null" ] }, "send_out": { "type": "boolean" }, "send_to_contact": { "$ref": "#/$defs/SendToContact" }, "send_to_elation_user": { "description": "If a letter is sent to another elation user, this will be that user's id.", "readOnly": true, "type": "integer" }, "send_to_name": { "maxLength": 200, "type": [ "string", "null" ] }, "sign_date": { "format": "date-time", "type": [ "string", "null" ] }, "signed_by": { "description": "The user who signed the letter.", "format": "int64", "type": [ "integer", "null" ] }, "subject": { "description": "The subject of the letter (Not needed with referral_order).", "maxLength": 200, "type": "string" }, "tags": { "description": "A list of Document Tags associated with the letter.", "items": { "format": "int64", "type": "integer" }, "type": "array" }, "to_number": { "readOnly": true, "type": [ "string", "null" ] }, "viewed_at": { "format": "date-time", "type": [ "string", "null" ] }, "with_archive": { "type": "boolean" } }, "required": [ "patient", "practice", "send_to_contact" ], "type": "object", "$defs": { "AttachmentTypeEnum": { "description": "* `Entity` - Entity\n* `RefPanel` - RefPanel\n* `PatientDemog` - PatientDemog\n* `ImmHistory` - ImmHistory\n* `MedsList` - MedsList\n* `CompMedsList` - CompMedsList\n* `WhoHeightChart` - WhoHeightChart\n* `WhoWeightChart` - WhoWeightChart\n* `WhoHcChart` - WhoHcChart\n* `WhoWflChart` - WhoWflChart\n* `CdcHeightChart` - CdcHeightChart\n* `CdcWeightChart` - CdcWeightChart\n* `CdcBmiChart` - CdcBmiChart\n* `CdcHcChart` - CdcHcChart\n* `PremieHeightChart` - PremieHeightChart\n* `PremieWeightChart` - PremieWeightChart\n* `PremieHcChart` - PremieHcChart\n* `DsinfantHeightChart` - DsinfantHeightChart\n* `DsinfantWeightChart` - DsinfantWeightChart\n* `DsinfantHcChart` - DsinfantHcChart\n* `DsHeightChart` - DsHeightChart\n* `DsWeightChart` - DsWeightChart\n* `DsBmiChart` - DsBmiChart\n* `DsHcChart` - DsHcChart", "enum": [ "Entity", "RefPanel", "PatientDemog", "ImmHistory", "MedsList", "CompMedsList", "WhoHeightChart", "WhoWeightChart", "WhoHcChart", "WhoWflChart", "CdcHeightChart", "CdcWeightChart", "CdcBmiChart", "CdcHcChart", "PremieHeightChart", "PremieWeightChart", "PremieHcChart", "DsinfantHeightChart", "DsinfantWeightChart", "DsinfantHcChart", "DsHeightChart", "DsWeightChart", "DsBmiChart", "DsHcChart" ], "type": "string" }, "DeliveryMethodEnum": { "enum": [ "direct", "email", "emr", "fax", "passport", "printed" ], "type": "string" }, "LetterAttachment": { "properties": { "attachment_type": { "$ref": "#/$defs/AttachmentTypeEnum" }, "entity_date": { "format": "date-time", "type": [ "string", "null" ] }, "entity_description": { "type": [ "string", "null" ] }, "entity_id": { "format": "int64", "type": "integer" }, "entity_type": { "readOnly": true, "type": [ "integer", "null" ] }, "handout": { "format": "int64", "type": [ "integer", "null" ] }, "id": { "readOnly": true, "type": "integer" }, "summary": { "type": [ "string", "null" ] } }, "required": [ "attachment_type" ], "type": "object" }, "SendToContact": { "properties": { "first_name": { "maxLength": 50, "type": "string" }, "id": { "format": "int64", "type": "integer" }, "last_name": { "maxLength": 60, "type": "string" }, "middle_name": { "maxLength": 50, "title": "MiddleName", "type": "string" }, "npi": { "maxLength": 20, "type": [ "string", "null" ] }, "org_name": { "maxLength": 100, "type": [ "string", "null" ] }, "specialties": { "items": {}, "type": "array" } }, "required": [ "id" ], "type": "object" } } }