package observation

import "time"

type ObservationRequest struct {
	PatientID         string    `json:"patient_id" binding:"required"`
	PatientName       string    `json:"patient_name" binding:"required"`
	EncounterID       string    `json:"encounter_id" binding:"required"`
	Status            string    `json:"status" binding:"required,oneof=registered preliminary final amended"` // registered, preliminary, final, amended
	CategoryCode      string    `json:"category_code" binding:"required"`                                     // vital-signs, laboratory
	CategoryDisplay   string    `json:"category_display" binding:"required"`
	Code              string    `json:"code" binding:"required"`    // LOINC code (e.g., 8867-4 for Heart rate)
	Display           string    `json:"display" binding:"required"` // Heart rate
	Value             float64   `json:"value" binding:"required"`
	Unit              string    `json:"unit" binding:"required"`
	UnitCode          string    `json:"unit_code" binding:"required"` // UCUM code (e.g., /min)
	EffectiveDateTime time.Time `json:"effective_date_time" binding:"required"`
}

type ObservationPatchRequest []map[string]interface{}
