{"modulePath":"github.com/obcode/plexams.go","version":"v1.247.0","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package model\n\n## Variables\n\n```go\nvar AllConflictDecision = []ConflictDecision{\n\tConflictDecisionAccept,\n\tConflictDecisionVeto,\n}\n```\n\n```go\nvar AllLogLevel = []LogLevel{\n\tLogLevelInfo,\n\tLogLevelWarn,\n\tLogLevelError,\n\tLogLevelProgress,\n\tLogLevelResult,\n\tLogLevelDone,\n}\n```\n\n```go\nvar AllPlanningGate = []PlanningGate{\n\tPlanningGateExams,\n\tPlanningGateRooms,\n\tPlanningGateInvigilations,\n}\n```\n\n```go\nvar AllPreplanRuleKind = []PreplanRuleKind{\n\tPreplanRuleKindHard,\n\tPreplanRuleKindSoft,\n}\n```\n\n```go\nvar AllRoomRequestType = []RoomRequestType{\n\tRoomRequestTypeNone,\n\tRoomRequestTypeAnny,\n\tRoomRequestTypeManagement,\n}\n```\n\n```go\nvar AllSlotTimeConstraintMode = []SlotTimeConstraintMode{\n\tSlotTimeConstraintModeAuto,\n\tSlotTimeConstraintModeWinter,\n\tSlotTimeConstraintModeSummer,\n\tSlotTimeConstraintModeOff,\n}\n```\n\n```go\nvar AllValidationLevel = []ValidationLevel{\n\tValidationLevelInfo,\n\tValidationLevelWarning,\n\tValidationLevelError,\n}\n```\n\n## Types\n\n```go\ntype AddedPrimussAncode struct {\n\tAncode        int               `json:\"ancode\"`\n\tPrimussAncode ZPAPrimussAncodes `json:\"primuss_ancodes\"`\n}\n```\n\n```go\ntype AdditionalExam struct {\n\tAncode int `json:\"ancode\"`\n\t// date in dd.mm.yyyy.\n\tDate string `json:\"date\"`\n\t// time in HH:MM.\n\tTime  string                `json:\"time\"`\n\tRooms []*AdditionalExamRoom `json:\"rooms\"`\n}\n```\n\n```go\ntype AdditionalExamInput struct {\n\tAncode int                        `json:\"ancode\"`\n\tDate   string                     `json:\"date\"`\n\tTime   string                     `json:\"time\"`\n\tRooms  []*AdditionalExamRoomInput `json:\"rooms\"`\n}\n```\n\n```go\ntype AdditionalExamRoom struct {\n\tRoomName      string `json:\"roomName\"`\n\tInvigilatorID int    `json:\"invigilatorID\"`\n\tDuration      int    `json:\"duration\"`\n\tIsReserve     bool   `json:\"isReserve\"`\n\tStudentCount  int    `json:\"studentCount\"`\n\tIsHandicap    bool   `json:\"isHandicap\"`\n}\n```\n\n```go\ntype AdditionalExamRoomInput struct {\n\tRoomName      string `json:\"roomName\"`\n\tInvigilatorID int    `json:\"invigilatorID\"`\n\tDuration      int    `json:\"duration\"`\n\tIsReserve     bool   `json:\"isReserve\"`\n\tStudentCount  int    `json:\"studentCount\"`\n\tIsHandicap    bool   `json:\"isHandicap\"`\n}\n```\n\n```go\ntype AnCode struct {\n\tAncode int `json:\"ancode\"`\n}\n```\n\n```go\ntype AnnyBooking struct {\n\tNumber                 string     `json:\"number\" bson:\"number\"`\n\tStartDate              time.Time  `json:\"startDate\" bson:\"start_date\"`\n\tEndDate                time.Time  `json:\"endDate\" bson:\"end_date\"`\n\tBlockerStartDate       time.Time  `json:\"blockerStartDate\" bson:\"blocker_start_date\"`\n\tBlockerEndDate         time.Time  `json:\"blockerEndDate\" bson:\"blocker_end_date\"`\n\tChargedDuration        int        `json:\"chargedDuration\" bson:\"charged_duration\"`\n\tDescription            string     `json:\"description\" bson:\"description\"`\n\tCreatedAt              time.Time  `json:\"createdAt\" bson:\"created_at\"`\n\tUpdatedAt              time.Time  `json:\"updatedAt\" bson:\"updated_at\"`\n\tCanceledAt             *time.Time `json:\"canceledAt,omitempty\" bson:\"canceled_at,omitempty\"`\n\tStatus                 string     `json:\"status\" bson:\"status\"`\n\tStatusReason           any        `json:\"-\" bson:\"status_reason,omitempty\"`\n\tIsBlocker              bool       `json:\"isBlocker\" bson:\"is_blocker\"`\n\tCanEdit                bool       `json:\"canEdit\" bson:\"can_edit\"`\n\tIsEditable             bool       `json:\"isEditable\" bson:\"is_editable\"`\n\tManuallyCreated        bool       `json:\"manuallyCreated\" bson:\"manually_created\"`\n\tNote                   string     `json:\"note\" bson:\"note\"`\n\tRoom                   string     `json:\"room,omitempty\" bson:\"room,omitempty\"`\n\tSelf                   string     `json:\"self\" bson:\"self\"`\n\tPersonalizationName    string     `json:\"personalizationName\" bson:\"personalization_name\"`\n\tBookingGroupIdentifier string     `json:\"bookingGroupIdentifier,omitempty\" bson:\"booking_group_identifier,omitempty\"`\n\tCancelableUntil        *time.Time `json:\"cancelableUntil,omitempty\" bson:\"cancelable_until,omitempty\"`\n\tHasCustomDescription   bool       `json:\"hasCustomDescription\" bson:\"has_custom_description\"`\n\tResourceID             string     `json:\"-\" bson:\"resource_id,omitempty\"`\n\t// Mine is computed at query time (not stored): true when PersonalizationName\n\t// matches one of the configured personalization names.\n\tMine bool `json:\"mine\" bson:\"-\"`\n}\n```\n\n```go\ntype AnnyConfig struct {\n\t// names whose bookings are flagged as ours (mine=true).\n\tPersonalizationNames []string `json:\"personalizationNames\"`\n}\n```\n\n```go\ntype ArgFilterInput struct {\n\tKey   string `json:\"key\"`\n\tValue string `json:\"value\"`\n}\n```\n\n```go\ntype AssembledExam struct {\n\tAncode           int                    `json:\"ancode\"`\n\tZpaExam          *ZPAExam               `json:\"zpaExam\"`\n\tPrimussExams     []*EnhancedPrimussExam `json:\"primussExams\"`\n\tConstraints      *Constraints           `json:\"constraints,omitempty\"`\n\tConflicts        []*ZPAConflict         `json:\"conflicts\"`\n\tStudentRegsCount int                    `json:\"studentRegsCount\"`\n\tNtas             []*NTA                 `json:\"ntas\"`\n\tMaxDuration      int                    `json:\"maxDuration\"`\n}\n```\n\n```go\ntype AssembledExamsChange struct {\n\tAncode int    `json:\"ancode\"`\n\tModule string `json:\"module\"`\n\t// added | removed | changed\n\tKind string `json:\"kind\"`\n\t// human-readable change descriptions, e.g. 'Anmeldungen 42 → 43'.\n\tDetails []string `json:\"details\"`\n}\n```\n\n```go\ntype AssembledExamsState struct {\n\t// true when the assembled exams are stale relative to their inputs.\n\tDirty bool `json:\"dirty\"`\n\t// the operation that last marked them stale (mutation/subscription name).\n\tReason *string `json:\"reason,omitempty\"`\n\t// when they were last marked stale or (re)generated.\n\tChangedAt *time.Time `json:\"changedAt,omitempty\"`\n}\n```\n\n```go\ntype BalanceReport struct {\n\tSatisfied       bool `json:\"satisfied\"`\n\tInvigilators    int  `json:\"invigilators\"`\n\tToleranceMin    int  `json:\"toleranceMin\"`\n\tWithinTolerance int  `json:\"withinTolerance\"`\n\tOver            int  `json:\"over\"`\n\tUnder           int  `json:\"under\"`\n\tMaxOver         int  `json:\"maxOver\"`\n\tMaxUnder        int  `json:\"maxUnder\"`\n}\n```\nBalanceReport: are all invigilators within ±tolerance of their target minutes.\n\n```go\ntype BlockedRoom struct {\n\tStarttime *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tRoom      string     `json:\"room\" bson:\"room\"`\n\tReason    *string    `json:\"reason,omitempty\" bson:\"reason,omitempty\"`\n}\n```\nBlockedRoom marks a room as not usable at one exam time (e.g. otherwise occupied). The absolute Starttime is the persisted source of truth.\n\n```go\ntype Conflict struct {\n\tAnCode        int `json:\"ancode\"`\n\tNumberOfStuds int `json:\"numberOfStuds\"`\n}\n```\n\n```go\ntype ConflictDecision string\n```\nConflictDecision is an explicit per-student override of the automatic handling: ACCEPT drops that student's proximity penalty; VETO forces it to count at full weight (overriding an automatic repeat down-weighting).\n\n```go\nconst (\n\tConflictDecisionAccept ConflictDecision = \"ACCEPT\"\n\tConflictDecisionVeto   ConflictDecision = \"VETO\"\n)\n```\n\n```go\nfunc (e ConflictDecision) IsValid() bool\n```\n\n```go\nfunc (e ConflictDecision) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e ConflictDecision) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e ConflictDecision) String() string\n```\n\n```go\nfunc (e *ConflictDecision) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *ConflictDecision) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype ConflictPerProgram struct {\n\tProgram   string      `json:\"program\"`\n\tConflicts []*Conflict `json:\"conflicts\"`\n}\n```\n\n```go\ntype ConflictStudent struct {\n\tMtknr string `json:\"mtknr\"`\n\tName  string `json:\"name\"`\n\t// the student's study program, e.g. \"IF\".\n\tProgram string `json:\"program\"`\n\t// the student's cohort/group, e.g. \"IF4B\".\n\tGroup string `json:\"group\"`\n\t// true if this is (heuristically) a repeat for this student (repeater exam or the student's semester is above the exam's) — auto down-weighted and accepted by default.\n\tAutoAccepted bool `json:\"autoAccepted\"`\n\t// explicit decision for this student, if any (overrides the automatic handling).\n\tDecision *ConflictDecision `json:\"decision,omitempty\"`\n\t// effective: penalty dropped for this student (explicit ACCEPT, or autoAccepted and not vetoed).\n\tAccepted bool `json:\"accepted\"`\n}\n```\n\n```go\ntype Conflicts struct {\n\tAnCode     int         `json:\"ancode\"`\n\tModule     string      `json:\"module\"`\n\tMainExamer string      `json:\"mainExamer\"`\n\tConflicts  []*Conflict `json:\"conflicts\"`\n}\n```\n\n```go\ntype ConflictsPerProgramAncode struct {\n\tProgram   string     `json:\"program\"`\n\tAncode    int        `json:\"ancode\"`\n\tConflicts *Conflicts `json:\"conflicts,omitempty\"`\n}\n```\n\n```go\ntype ConnectedExam struct {\n\tZpaExam           *ZPAExam       `json:\"zpaExam\"`\n\tPrimussExams      []*PrimussExam `json:\"primussExams\"`\n\tOtherPrimussExams []*PrimussExam `json:\"otherPrimussExams\"`\n\t// Findings from connecting ZPA and Primuss data, graded by level.\n\tWarnings []*ConnectedExamWarning `json:\"warnings\"`\n}\n```\n\n```go\ntype ConnectedExamWarning struct {\n\t// info | warning | error\n\tLevel   string `json:\"level\"`\n\tMessage string `json:\"message\"`\n\t// The Primuss program this finding refers to (for an add/fix/remove action), if any.\n\tProgram *string `json:\"program,omitempty\"`\n\t// The Primuss ancode this finding refers to, if any.\n\tAncode *int `json:\"ancode,omitempty\"`\n\t// The module/exam name of the referenced Primuss exam, if known.\n\tModule *string `json:\"module,omitempty\"`\n\t// The examer of the referenced Primuss exam, if known.\n\tExamer *string `json:\"examer,omitempty\"`\n}\n```\nA finding from connecting a ZPA exam to its Primuss registrations.\n\n```go\ntype ConstraintCost struct {\n\tName string  `json:\"name\"`\n\tCost float64 `json:\"cost\"`\n}\n```\n\n```go\ntype Constraints struct {\n\tAncode         int  `json:\"ancode\"`\n\tNotPlannedByMe bool `json:\"notPlannedByMe\"`\n\t// do not upload this exam to the ZPA when publishing the plan.\n\tDoNotPublish bool         `json:\"doNotPublish\"`\n\tExcludeDays  []*time.Time `json:\"excludeDays,omitempty\"`\n\tPossibleDays []*time.Time `json:\"possibleDays,omitempty\"`\n\tFixedDay     *time.Time   `json:\"fixedDay,omitempty\"`\n\tFixedTime    *time.Time   `json:\"fixedTime,omitempty\"`\n\tSameSlot     []int        `json:\"sameSlot,omitempty\"`\n\tOnline       bool         `json:\"online\"`\n\t// fixed exam location/campus, e.g. \"Campus Pasing\"; empty = default campus (Lothstraße). Used for a minimum travel gap between exams at different campuses.\n\tLocation *string `json:\"location,omitempty\"`\n\t// the faculty that plans this exam when notPlannedByMe (e.g. \"FK10\" for Pasing ZPA exams).\n\tNotPlannedByMeInFk *string          `json:\"notPlannedByMeInFK,omitempty\"`\n\tRoomConstraints    *RoomConstraints `json:\"roomConstraints,omitempty\"`\n}\n```\n\n```go\ntype ConstraintsInput struct {\n\tAllowedRooms   []string     `json:\"allowedRooms,omitempty\"`\n\tNotPlannedByMe *bool        `json:\"notPlannedByMe,omitempty\"`\n\tDoNotPublish   *bool        `json:\"doNotPublish,omitempty\"`\n\tExcludeDays    []*time.Time `json:\"excludeDays,omitempty\"`\n\tPossibleDays   []*time.Time `json:\"possibleDays,omitempty\"`\n\tFixedDay       *time.Time   `json:\"fixedDay,omitempty\"`\n\tFixedTime      *time.Time   `json:\"fixedTime,omitempty\"`\n\tSameSlot       []int        `json:\"sameSlot,omitempty\"`\n\tOnline         *bool        `json:\"online,omitempty\"`\n\tLocation       *string      `json:\"location,omitempty\"`\n\t// the faculty that plans this exam when notPlannedByMe (e.g. \"FK10\").\n\tNotPlannedByMeInFk *string `json:\"notPlannedByMeInFK,omitempty\"`\n\tPlacesWithSocket   *bool   `json:\"placesWithSocket,omitempty\"`\n\tLab                *bool   `json:\"lab,omitempty\"`\n\tExahm              *bool   `json:\"exahm,omitempty\"`\n\tSeb                *bool   `json:\"seb,omitempty\"`\n\tKdpJiraURL         *string `json:\"kdpJiraURL,omitempty\"`\n\tMaxStudents        *int    `json:\"maxStudents,omitempty\"`\n\tAdditionalSeats    *int    `json:\"additionalSeats,omitempty\"`\n\t// Lead time (Vorlauf) in minutes before the exam; total that replaces the default 15.\n\tPreExamMinutes *int `json:\"preExamMinutes,omitempty\"`\n\t// Trailing time (Nachlauf) in minutes after the exam; total that replaces the default 15.\n\tPostExamMinutes *int    `json:\"postExamMinutes,omitempty\"`\n\tComments        *string `json:\"comments,omitempty\"`\n}\n```\n\n```go\ntype CoverageReport struct {\n\tPositions int `json:\"positions\"`\n\tUnfilled  int `json:\"unfilled\"`\n}\n```\nCoverageReport: how many positions are filled.\n\n```go\ntype DistributionBucket struct {\n\tCount        int `json:\"count\"`\n\tInvigilators int `json:\"invigilators\"`\n}\n```\n\n```go\ntype DryRunTestMailStatus struct {\n\t// The active session override, or null when none is set (the configured default is used).\n\tOverride *string `json:\"override,omitempty\"`\n\t// The address dry-run mails currently go to (override, or the configured default).\n\tCurrent string `json:\"current\"`\n\t// The configured default (effective testMail) that a reset falls back to.\n\tDefault string `json:\"default\"`\n\t// True when an override is active and deviates from the default — the GUI should show a warning banner.\n\tOverridden bool `json:\"overridden\"`\n}\n```\nStatus of the per-session dry-run recipient override shown on the Probeläufe page.\n\n```go\ntype EmailAttachmentInfo struct {\n\tKind        string    `json:\"kind\"`\n\tKey         string    `json:\"key\"`\n\tFilename    string    `json:\"filename\"`\n\tContentType string    `json:\"contentType\"`\n\tSize        int       `json:\"size\"`\n\tUploadedAt  time.Time `json:\"uploadedAt\"`\n}\n```\nEmailAttachmentInfo describes one uploaded attachment (without its binary data). kind is e.g. \"cover-page\" or \"invigilation-image\"; key is the teacher / invigilator id the attachment belongs to. The binaries themselves are uploaded via the REST endpoints /upload/email-attachment and /upload/email-attachments-zip.\n\n```go\ntype EmailTemplate struct {\n\t// the template's file name, e.g. \"exahmEmail.md.tmpl\".\n\tName string `json:\"name\"`\n\t// a short human-readable purpose of this email (for the GUI list; not part of the mail).\n\tDescription string `json:\"description\"`\n\t// the effective Markdown: the stored override if any, otherwise the built-in default.\n\tMarkdown string `json:\"markdown\"`\n\t// true when no override is stored (the built-in default is in use).\n\tIsDefault bool `json:\"isDefault\"`\n\t// the built-in default Markdown (for preview and reset-to-default).\n\tDefaultMarkdown string `json:\"defaultMarkdown\"`\n\t// the variables (placeholders) this template may use, with a description and an example.\n\tVariables []*EmailTemplateVariable `json:\"variables\"`\n}\n```\nEmailTemplate is one editable email body template (a Markdown \\*.md.tmpl). The built-in embedded template is the default; a stored override replaces it. The layout templates (emailBaseHTML/jiraOnHTML) are not editable here.\n\n```go\ntype EmailTemplateFunction struct {\n\t// the function name, e.g. \"plural\".\n\tName string `json:\"name\"`\n\t// how to call it, e.g. \"{{ plural .N \\\"Platz\\\" \\\"Plätze\\\" }}\".\n\tUsage string `json:\"usage\"`\n\t// what it does, in plain language.\n\tDescription string `json:\"description\"`\n}\n```\nEmailTemplateFunction documents a helper function callable in every email template, e.g. \\`jiraURL\\` or \\`plural\\`. The list is global (all functions are available in all templates).\n\n```go\ntype EmailTemplatePreview struct {\n\t// the rendered HTML part (the shared layout is applied), for an in-GUI preview.\n\tHTML string `json:\"html\"`\n\t// the rendered plain-text part.\n\tText string `json:\"text\"`\n\t// the error message if the template does not parse/execute; null on success.\n\tError *string `json:\"error,omitempty\"`\n}\n```\nEmailTemplatePreview is the rendered result of a (possibly not-yet-saved) template against representative sample data. On a template error, \\`error\\` holds the message and html/text are empty — so the GUI can show parse/exec mistakes live while editing.\n\n```go\ntype EmailTemplateVariable struct {\n\t// how to write it in the template, e.g. \"{{ .Teacher.Fullname }}\".\n\tName string `json:\"name\"`\n\t// what the value is, in plain language.\n\tDescription string `json:\"description\"`\n\t// the value used for this placeholder in the live preview.\n\tExample string `json:\"example\"`\n}\n```\nEmailTemplateVariable documents one placeholder available in a template, e.g. \\`.Teacher.Fullname\\`. Meant to be shown next to the editor so a non-technical user knows which values exist and how to write them.\n\n```go\ntype Emails struct {\n\tProfs            string   `json:\"profs\"`\n\tLbas             string   `json:\"lbas\"`\n\tLbasLastSemester string   `json:\"lbasLastSemester\"`\n\tAdditionalExamer []string `json:\"additionalExamer\"`\n\tFs               string   `json:\"fs\"`\n\tSekr             string   `json:\"sekr\"`\n\t// Recipient for building-management room requests (Gebäudemanagement).\n\tRoomManagement string `json:\"roomManagement\"`\n\t// Recipient for the EXaHM/SEB room overview (KDP).\n\tKdp string `json:\"kdp\"`\n\t// Recipient for the overview of LBAs' repeat exams (Lehrbeauftragten-Beauftragte:r).\n\tLbaba string `json:\"lbaba\"`\n}\n```\n\n```go\ntype EmailsInput struct {\n\tProfs            string   `json:\"profs\"`\n\tLbas             string   `json:\"lbas\"`\n\tLbasLastSemester string   `json:\"lbasLastSemester\"`\n\tAdditionalExamer []string `json:\"additionalExamer\"`\n\tFs               string   `json:\"fs\"`\n\tSekr             string   `json:\"sekr\"`\n\tRoomManagement   string   `json:\"roomManagement\"`\n\tKdp              string   `json:\"kdp\"`\n\tLbaba            string   `json:\"lbaba\"`\n}\n```\n\n```go\ntype EnhancedPrimussExam struct {\n\tExam        *PrimussExam          `json:\"exam\"`\n\tStudentRegs []*EnhancedStudentReg `json:\"studentRegs\"`\n\tConflicts   []*Conflict           `json:\"conflicts\"`\n\tNtas        []*NTA                `json:\"ntas\"`\n}\n```\n\n```go\ntype EnhancedStudentReg struct {\n\tMtknr      string      `json:\"mtknr\"`\n\tAncode     int         `json:\"ancode\"`\n\tProgram    string      `json:\"program\"`\n\tGroup      string      `json:\"group\"`\n\tName       string      `json:\"name\"`\n\tPresence   string      `json:\"presence\"`\n\tZpaStudent *ZPAStudent `json:\"zpaStudent,omitempty\"`\n}\n```\n\n```go\ntype ExamDay struct {\n\tDate time.Time `json:\"date\"`\n}\n```\n\n```go\ntype ExamDurationOverride struct {\n\tAncode   int `json:\"ancode\"`\n\tDuration int `json:\"duration\"`\n}\n```\n\n```go\ntype ExamPair struct {\n\tAncode1     int    `json:\"ancode1\"`\n\tModule1     string `json:\"module1\"`\n\tMainExamer1 string `json:\"mainExamer1\"`\n\tAncode2     int    `json:\"ancode2\"`\n\tModule2     string `json:\"module2\"`\n\tMainExamer2 string `json:\"mainExamer2\"`\n}\n```\nExamPair is a pair of exams with display info (for canShareSlot lists/suggestions).\n\n```go\ntype ExamPlanningMailExam struct {\n\tAncode int    `json:\"ancode\"`\n\tModule string `json:\"module\"`\n\t// Human-readable exam type (ZPA full name).\n\tExamType    string       `json:\"examType\"`\n\tConstraints *Constraints `json:\"constraints,omitempty\"`\n}\n```\nOne exam I plan for an examer, for the planning info email (no slot/date).\n\n```go\ntype ExamPlanningMailRecipient struct {\n\tTeacher *Teacher `json:\"teacher\"`\n\t// withExams = I plan at least one of their exams; fk07NoExams = FK07 examer I plan nothing for.\n\tCategory string `json:\"category\"`\n\t// The exams I plan for this examer (empty for fk07NoExams).\n\tExams []*ExamPlanningMailExam `json:\"exams\"`\n}\n```\n\n```go\ntype ExamScheduleConflict struct {\n\tAncode1     int    `json:\"ancode1\"`\n\tModule1     string `json:\"module1\"`\n\tMainExamer1 string `json:\"mainExamer1\"`\n\t// the study groups exam 1 is offered for (e.g. [\"IF2A\"]).\n\tGroups1 []string `json:\"groups1\"`\n\t// true if exam 1 is a repeater exam.\n\tIsRepeaterExam1 bool `json:\"isRepeaterExam1\"`\n\t// exam 1's campus/location (empty = default campus Lothstraße).\n\tLocation1 string `json:\"location1\"`\n\t// the planned slot of exam 1.\n\tSlot1           *Slot    `json:\"slot1\"`\n\tAncode2         int      `json:\"ancode2\"`\n\tModule2         string   `json:\"module2\"`\n\tMainExamer2     string   `json:\"mainExamer2\"`\n\tGroups2         []string `json:\"groups2\"`\n\tIsRepeaterExam2 bool     `json:\"isRepeaterExam2\"`\n\tLocation2       string   `json:\"location2\"`\n\tSlot2           *Slot    `json:\"slot2\"`\n\t// number of students registered in both, in the plan.\n\tStudentCount int `json:\"studentCount\"`\n\t// worst time proximity across affected students: OVERLAP | TOO_CLOSE | SAME_DAY.\n\tProximity string `json:\"proximity\"`\n\t// true if the pair is declared can-share-slot.\n\tCanShareSlot bool `json:\"canShareSlot\"`\n\t// true if BOTH exams are external (planned by another faculty): information only.\n\tInfoOnly bool `json:\"infoOnly\"`\n\t// the affected students (registered in both); acceptance is set per student here.\n\tAffectedStudents []*ConflictStudent `json:\"affectedStudents\"`\n\t// status relative to the currently saved plan, only set in a generation report: \"new\"\n\t// (not in the saved plan), \"worse\"/\"better\" (proximity changed), \"unchanged\", or\n\t// \"resolved\" (was in the saved plan, gone now). Empty outside a diff context.\n\tDiffStatus string `json:\"diffStatus\"`\n}\n```\nExamScheduleConflict is a conflict in the CURRENT plan: two exams a student is registered in that ended up close in time, aggregated over all affected students. A conflict is only meaningful per student — the per-student acceptance lives on affectedStudents.\n\n```go\ntype ExamScheduleDiagnostics struct {\n\tStudents int `json:\"students\"`\n\tPairs    int `json:\"pairs\"`\n\t// Two of a student's exams overlap in time (a hard violation — should be 0).\n\tOverlaps int `json:\"overlaps\"`\n\t// Two of a student's exams are directly consecutive / too close in time.\n\tTooClose             int     `json:\"tooClose\"`\n\tSameDay              int     `json:\"sameDay\"`\n\tNextDay              int     `json:\"nextDay\"`\n\tWithin3              int     `json:\"within3\"`\n\tFurther              int     `json:\"further\"`\n\tStudentsWithTooClose int     `json:\"studentsWithTooClose\"`\n\tStudentsWithSameDay  int     `json:\"studentsWithSameDay\"`\n\tWorstStudentPenalty  float64 `json:\"worstStudentPenalty\"`\n\t// Peak concurrent seats across all start times.\n\tMaxSeatsAt int `json:\"maxSeatsAt\"`\n\t// Distinct start times holding at least one of our exams.\n\tStarttimesUsed     int `json:\"starttimesUsed\"`\n\tSlotsOverThreshold int `json:\"slotsOverThreshold\"`\n\t// Peak number of exams sharing a single start time.\n\tMaxExamsAt int `json:\"maxExamsAt\"`\n}\n```\nQuality report of a generated (or current) exam schedule.\n\n```go\ntype ExamScheduleReport struct {\n\tUnits            int               `json:\"units\"`\n\tFixed            int               `json:\"fixed\"`\n\tPlaced           int               `json:\"placed\"`\n\tUnplaced         int               `json:\"unplaced\"`\n\tUnplacedAncodes  []int             `json:\"unplacedAncodes\"`\n\tHardViolations   []string          `json:\"hardViolations\"`\n\tCost             float64           `json:\"cost\"`\n\tCostByConstraint []*ConstraintCost `json:\"costByConstraint\"`\n\tIterations       int               `json:\"iterations\"`\n\t// the seed used — pass it back to reproduce this exact plan.\n\tSeed         int                      `json:\"seed\"`\n\tStoppedEarly bool                     `json:\"stoppedEarly\"`\n\tWritten      bool                     `json:\"written\"`\n\tDiagnostics  *ExamScheduleDiagnostics `json:\"diagnostics\"`\n\t// conflicts of the generated schedule (to review/rate, also on a dry run). Each carries a diffStatus relative to the saved plan (new/worse/better/unchanged).\n\tConflicts []*ExamScheduleConflict `json:\"conflicts\"`\n\t// conflicts that were in the saved plan but are gone in the generated one (diffStatus \"resolved\").\n\tResolvedConflicts []*ExamScheduleConflict `json:\"resolvedConflicts\"`\n}\n```\n\n```go\ntype ExamTime struct {\n\tFrom  time.Time `json:\"from\"`\n\tUntil time.Time `json:\"until\"`\n}\n```\nExamTime is the time span of one exam an invigilator is the main examer of: from the start time of the slot until the end time (start + maxDuration of the exam, i.e. the longest exam in the slot including NTA extensions).\n\n```go\ntype ExamWithRegsAndRooms struct {\n\tExam              *PlannedExam   `json:\"exam\"`\n\tNormalRegsMtknr   []string       `json:\"normalRegsMtknr\"`\n\tNtasInNormalRooms []*NTA         `json:\"ntasInNormalRooms\"`\n\tNtasInAloneRooms  []*NTA         `json:\"ntasInAloneRooms\"`\n\tRooms             []*PlannedRoom `json:\"rooms\"`\n}\n```\n\n```go\ntype ExamerInPlan struct {\n\tMainExamer   string `json:\"mainExamer\"`\n\tMainExamerID int    `json:\"mainExamerID\"`\n}\n```\n\n```go\ntype FK07Program struct {\n\tName string `json:\"name\"`\n}\n```\n\n```go\ntype FairnessDistribution struct {\n\tKind    string                `json:\"kind\"`\n\tTotal   int                   `json:\"total\"`\n\tMax     int                   `json:\"max\"`\n\tBuckets []*DistributionBucket `json:\"buckets\"`\n}\n```\nFairnessDistribution: per-invigilator count histogram for one kind (reserve/nta). buckets reads as \"count:invigilators\", e.g. count 1 / invigilators 48.\n\n```go\ntype GenerateAssembledExamsResult struct {\n\t// the new state (dirty=false).\n\tState *AssembledExamsState `json:\"state\"`\n\t// what changed vs the previously cached assembled exams (empty = nothing changed).\n\tChanges []*AssembledExamsChange `json:\"changes\"`\n}\n```\n\n```go\ntype GeneratePreparationResult struct {\n\tAssembledExams *GenerateAssembledExamsResult `json:\"assembledExams\"`\n\tStudentRegs    *GenerateStudentRegsResult    `json:\"studentRegs\"`\n}\n```\n\n```go\ntype GenerateStudentRegsResult struct {\n\tState *StudentRegsState `json:\"state\"`\n\t// number of students with planned registrations after the (re)generation.\n\tStudentCount int `json:\"studentCount\"`\n}\n```\n\n```go\ntype GenerationConfig struct {\n\tIterations int     `json:\"iterations\"`\n\tStartTemp  float64 `json:\"startTemp\"`\n\tEndTemp    float64 `json:\"endTemp\"`\n\t// allowed deviation (minutes) from an invigilator's target workload.\n\tToleranceMin           int     `json:\"toleranceMin\"`\n\tMaxSpanHours           float64 `json:\"maxSpanHours\"`\n\tWeightMinuteBalance    float64 `json:\"weightMinuteBalance\"`\n\tWeightBeyondTolerance  float64 `json:\"weightBeyondTolerance\"`\n\tWeightOverTargetFactor float64 `json:\"weightOverTargetFactor\"`\n\tWeightCoverage         float64 `json:\"weightCoverage\"`\n\tWeightMaxDays          float64 `json:\"weightMaxDays\"`\n\tWeightPreferExamDays   float64 `json:\"weightPreferExamDays\"`\n\tWeightDistribution     float64 `json:\"weightDistribution\"`\n\tWeightDaySpan          float64 `json:\"weightDaySpan\"`\n\t// Terminplan: whether/how to weight exam start times (default AUTO by semester).\n\tSlotTimeMode SlotTimeConstraintMode `json:\"slotTimeMode\"`\n\t// Terminplan: start-time weight (penalty per registration, per hour of badness). 0 = use default.\n\tSlotTimeWeight float64 `json:\"slotTimeWeight\"`\n\t// Terminplan (winter): avoid a start time before this (HH:MM), e.g. 10:00. Ignored in summer (there earlier is always better).\n\tSlotTimeWinterEarliest string `json:\"slotTimeWinterEarliest\"`\n\t// spread: two exams of a student directly consecutive on the same day (very bad).\n\tExamAdjacent float64 `json:\"examAdjacent\"`\n\t// spread: two exams of a student on the same day but not consecutive.\n\tExamSameDay float64 `json:\"examSameDay\"`\n\t// spread across days: DayFactor · 24 / hours between the two exams.\n\tExamDayFactor float64 `json:\"examDayFactor\"`\n\t// convex term protecting the least well-spread student (+ WorstCase · P²).\n\tExamWorstCase float64 `json:\"examWorstCase\"`\n\t// down-weight applied to (likely) repeat-exam conflict pairs (0..1).\n\tExamRepeatFactor float64 `json:\"examRepeatFactor\"`\n\t// attract: pull parallel sections / small same-examer exams close together.\n\tExamAttract float64 `json:\"examAttract\"`\n\t// even distribution: convex penalty on the seat load per start time.\n\tExamSlotLoad float64 `json:\"examSlotLoad\"`\n\t// soft seat threshold per start time for the slot-load term.\n\tExamLoadThreshold int `json:\"examLoadThreshold\"`\n\t// penalty per unplaced exam (dominant — keep very high so all exams get placed).\n\tExamUnplaced float64 `json:\"examUnplaced\"`\n\t// extra penalty for a same-day student pair across campuses (travel gap).\n\tExamCrossCampus float64 `json:\"examCrossCampus\"`\n\t// per unused booked T-building seat in the EXaHM/SEB room phase (phase A only).\n\tExamTbauFill float64 `json:\"examTbauFill\"`\n\t// per empty start time between two occupied ones on the same day (bad for invigilation).\n\tExamHole float64 `json:\"examHole\"`\n\t// 0 = tiered/grid-equivalent same-day cost; \u003e0 = continuous falloff time constant (minutes) for finer start times.\n\tExamClosenessFalloffMin float64 `json:\"examClosenessFalloffMin\"`\n\t// Pre-plan (SEB/EXaHM): usable fraction of a slot's booked Anny seats (1.0 = fill completely).\n\tPreplanCapacityFactor float64 `json:\"preplanCapacityFactor\"`\n}\n```\n\n```go\ntype GenerationConfigInput struct {\n\tIterations              int                    `json:\"iterations\"`\n\tStartTemp               float64                `json:\"startTemp\"`\n\tEndTemp                 float64                `json:\"endTemp\"`\n\tToleranceMin            int                    `json:\"toleranceMin\"`\n\tMaxSpanHours            float64                `json:\"maxSpanHours\"`\n\tWeightMinuteBalance     float64                `json:\"weightMinuteBalance\"`\n\tWeightBeyondTolerance   float64                `json:\"weightBeyondTolerance\"`\n\tWeightOverTargetFactor  float64                `json:\"weightOverTargetFactor\"`\n\tWeightCoverage          float64                `json:\"weightCoverage\"`\n\tWeightMaxDays           float64                `json:\"weightMaxDays\"`\n\tWeightPreferExamDays    float64                `json:\"weightPreferExamDays\"`\n\tWeightDistribution      float64                `json:\"weightDistribution\"`\n\tWeightDaySpan           float64                `json:\"weightDaySpan\"`\n\tSlotTimeMode            SlotTimeConstraintMode `json:\"slotTimeMode\"`\n\tSlotTimeWeight          float64                `json:\"slotTimeWeight\"`\n\tSlotTimeWinterEarliest  string                 `json:\"slotTimeWinterEarliest\"`\n\tExamAdjacent            float64                `json:\"examAdjacent\"`\n\tExamSameDay             float64                `json:\"examSameDay\"`\n\tExamDayFactor           float64                `json:\"examDayFactor\"`\n\tExamWorstCase           float64                `json:\"examWorstCase\"`\n\tExamRepeatFactor        float64                `json:\"examRepeatFactor\"`\n\tExamAttract             float64                `json:\"examAttract\"`\n\tExamSlotLoad            float64                `json:\"examSlotLoad\"`\n\tExamLoadThreshold       int                    `json:\"examLoadThreshold\"`\n\tExamUnplaced            float64                `json:\"examUnplaced\"`\n\tExamCrossCampus         float64                `json:\"examCrossCampus\"`\n\tExamTbauFill            float64                `json:\"examTbauFill\"`\n\tExamHole                float64                `json:\"examHole\"`\n\tExamClosenessFalloffMin float64                `json:\"examClosenessFalloffMin\"`\n\tPreplanCapacityFactor   float64                `json:\"preplanCapacityFactor\"`\n}\n```\n\n```go\ntype ImportMucDaiResult struct {\n\t// programs (Studiengruppen) found in the CSV.\n\tPrograms []string `json:\"programs\"`\n\t// total exam rows imported into the mucdai_\u003cprogram\u003e collections.\n\tExamsImported int `json:\"examsImported\"`\n\t// new non-ZPA exams created (non-FK07, not existing yet).\n\tExamsCreated int `json:\"examsCreated\"`\n\t// non-FK07 exams that already existed (kept with their ancode).\n\tExamsExisting int `json:\"examsExisting\"`\n\t// FK07 exams skipped (they exist as ZPA exams, only linked).\n\tExamsSkippedFk07 int `json:\"examsSkippedFK07\"`\n\t// assembled exams of the imported programs removed because they are no longer in the CSV (or flipped to FK07).\n\tExamsRemoved int `json:\"examsRemoved\"`\n}\n```\n\n```go\ntype Invigilation struct {\n\t// Starttime is the absolute start time of the invigilation's slot.\n\tStarttime *time.Time `json:\"-\" bson:\"starttime,omitempty\"`\n\t// Slot is derived from Starttime on read (day/slot + start time); not persisted.\n\tSlot               *Slot   `json:\"slot\" bson:\"-\"`\n\tRoomName           *string `json:\"roomName,omitempty\" bson:\"roomname,omitempty\"`\n\tDuration           int     `json:\"duration\" bson:\"duration\"`\n\tInvigilatorID      int     `json:\"invigilatorID\" bson:\"invigilatorid\"`\n\tIsReserve          bool    `json:\"isReserve\" bson:\"isreserve\"`\n\tIsSelfInvigilation bool    `json:\"isSelfInvigilation\" bson:\"isselfinvigilation\"`\n\tPrePlanned         bool    `json:\"prePlanned\" bson:\"preplanned\"`\n}\n```\nInvigilation is one invigilator's duty in one room (or the reserve) at one exam time. The absolute Starttime is the persisted source of truth; the Slot (with day/slot) is rebuilt from it on read (see db decoration), mirroring PlanEntry / PlannedRoom.\n\n```go\ntype InvigilationReport struct {\n\tSeed          int                     `json:\"seed\"`\n\tIterations    int                     `json:\"iterations\"`\n\tIterationsRun int                     `json:\"iterationsRun\"`\n\tStoppedEarly  bool                    `json:\"stoppedEarly\"`\n\tBalance       *BalanceReport          `json:\"balance\"`\n\tCoverage      *CoverageReport         `json:\"coverage\"`\n\tMinutes       *MinutesReport          `json:\"minutes\"`\n\tOutliers      []*InvigilatorOutlier   `json:\"outliers\"`\n\tFairness      []*FairnessDistribution `json:\"fairness\"`\n\tSoftCost      *SoftCostReport         `json:\"softCost\"`\n}\n```\nInvigilationReport is the structured outcome of an invigilation generation run, mirroring the textual report. It is delivered once on the final RESULT line of the assignInvigilations subscription (also for dryRun, where nothing is written to the database).\n\n```go\ntype InvigilationSlot struct {\n\tReserve *Teacher `json:\"reserve,omitempty\"`\n\t// true if the reserve invigilation in this slot is pre-planned (fixed).\n\tReservePrePlanned     bool                   `json:\"reservePrePlanned\"`\n\tRoomsWithInvigilators []*RoomWithInvigilator `json:\"roomsWithInvigilators\"`\n}\n```\n\n```go\ntype InvigilationTimeWindow struct {\n\tDate  time.Time  `json:\"date\"`\n\tFrom  *time.Time `json:\"from,omitempty\"`\n\tUntil *time.Time `json:\"until,omitempty\"`\n}\n```\nInvigilationTimeWindow restricts, for one calendar date, the times an invigilator may invigilate. An assigned invigilation must start no earlier than from (if set) and end no later than until (if set). The check is sub-slot granular and NTA-aware, since the end time includes the room's (possibly NTA-extended) duration.\n\n```go\ntype InvigilationTimeWindowInput struct {\n\tDate  time.Time  `json:\"date\"`\n\tFrom  *time.Time `json:\"from,omitempty\"`\n\tUntil *time.Time `json:\"until,omitempty\"`\n}\n```\ndate is the calendar day; from/until are clock times on that day (at least one of from/until must be set).\n\n```go\ntype InvigilationTodos struct {\n\tSumExamRooms                        int            `json:\"sumExamRooms\"`\n\tSumReserve                          int            `json:\"sumReserve\"`\n\tSumOtherContributions               int            `json:\"sumOtherContributions\"`\n\tSumOtherContributionsOvertimeCutted int            `json:\"sumOtherContributionsOvertimeCutted\"`\n\tInvigilatorCount                    int            `json:\"invigilatorCount\"`\n\tTodoPerInvigilator                  int            `json:\"todoPerInvigilator\"`\n\tTodoPerInvigilatorOvertimeCutted    int            `json:\"todoPerInvigilatorOvertimeCutted\"`\n\tInvigilators                        []*Invigilator `json:\"invigilators\"`\n}\n```\n\n```go\ntype Invigilator struct {\n\tTeacher      *Teacher                 `json:\"teacher\"`\n\tRequirements *InvigilatorRequirements `json:\"requirements,omitempty\"`\n\tTodos        *InvigilatorTodos        `json:\"todos,omitempty\"`\n}\n```\n\n```go\ntype InvigilatorConstraints struct {\n\tTeacherID        int                       `json:\"teacherID\"`\n\tIsNotInvigilator bool                      `json:\"isNotInvigilator\"`\n\tExcludedDates    []time.Time               `json:\"excludedDates\"`\n\tTimeWindows      []*InvigilationTimeWindow `json:\"timeWindows\"`\n}\n```\nInvigilatorConstraints are the per-invigilator constraints kept in the DB and edited via the GUI, separate from the ZPA-sourced invigilator\\_requirements (which is overwritten on every ZPA pull). They are merged on top of the ZPA requirements when building an invigilator.\n\n```go\ntype InvigilatorConstraintsInput struct {\n\tTeacherID        int                            `json:\"teacherID\"`\n\tIsNotInvigilator bool                           `json:\"isNotInvigilator\"`\n\tExcludedDates    []*time.Time                   `json:\"excludedDates\"`\n\tTimeWindows      []*InvigilationTimeWindowInput `json:\"timeWindows\"`\n}\n```\n\n```go\ntype InvigilatorOutlier struct {\n\tInvigilatorID int     `json:\"invigilatorID\"`\n\tDoing         int     `json:\"doing\"`\n\tTarget        int     `json:\"target\"`\n\tOpen          int     `json:\"open\"`\n\tPercent       float64 `json:\"percent\"`\n}\n```\nInvigilatorOutlier: a person whose assigned minutes are furthest from target.\n\n```go\ntype InvigilatorRequirements struct {\n\tExcludedDates          []*time.Time `json:\"excludedDates\"`\n\tExcludedDays           []int        `json:\"excludedDays\"`\n\tExamTimes              []*ExamTime  `json:\"examTimes\"`\n\tExamDays               []int        `json:\"examDays\"`\n\tPartTime               float64      `json:\"partTime\"`\n\tOralExamsContribution  int          `json:\"oralExamsContribution\"`\n\tLiveCodingContribution int          `json:\"liveCodingContribution\"`\n\tMasterContribution     int          `json:\"masterContribution\"`\n\tFreeSemester           float64      `json:\"freeSemester\"`\n\tOvertimeLastSemester   float64      `json:\"overtimeLastSemester\"`\n\tOvertimeThisSemester   float64      `json:\"overtimeThisSemester\"`\n\tAllContributions       int          `json:\"allContributions\"`\n\tFactor                 float64      `json:\"factor\"`\n\t// fromZpa is false if the invigilator has not yet entered their requirements in\n\t// the ZPA. In that case default requirements (full time, no contributions) are\n\t// used and the invigilator still has to provide their real requirements.\n\tFromZpa     bool                      `json:\"fromZpa\"`\n\tTimeWindows []*InvigilationTimeWindow `json:\"timeWindows\"`\n}\n```\n\n```go\ntype InvigilatorTodos struct {\n\tTotalMinutes     int             `json:\"totalMinutes\"`\n\tDoingMinutes     int             `json:\"doingMinutes\"`\n\tEnough           bool            `json:\"enough\"`\n\tInvigilationDays []int           `json:\"invigilationDays,omitempty\"`\n\tInvigilations    []*Invigilation `json:\"invigilations,omitempty\"`\n}\n```\n\n```go\ntype InvigilatorsForDay struct {\n\tWant []*Invigilator `json:\"want\"`\n\tCan  []*Invigilator `json:\"can\"`\n}\n```\n\n```go\ntype JiraComment struct {\n\tAuthor  *JiraUser  `json:\"author,omitempty\"`\n\tBody    string     `json:\"body\"`\n\tCreated *time.Time `json:\"created,omitempty\"`\n}\n```\nA single comment on a Jira issue.\n\n```go\ntype JiraIssue struct {\n\tKey         string  `json:\"key\"`\n\tSummary     string  `json:\"summary\"`\n\tDescription *string `json:\"description,omitempty\"`\n\tStatus      *string `json:\"status,omitempty\"`\n\tIssueType   *string `json:\"issueType,omitempty\"`\n\t// The reporter/author. Populated in list and detail views.\n\tReporter *JiraUser `json:\"reporter,omitempty\"`\n\t// Creation time, when known.\n\tCreated *time.Time `json:\"created,omitempty\"`\n\t// The issue's comments, oldest first. Only populated by jiraIssue(key); empty in list views.\n\tComments []*JiraComment `json:\"comments\"`\n\t// Browse URL, e.g. https://jira.cc.hm.edu/browse/PLEX-42.\n\tURL string `json:\"url\"`\n}\n```\nA Jira issue (the subset plexams reads/writes).\n\n```go\ntype JiraIssueGroup struct {\n\tIssueType string       `json:\"issueType\"`\n\tIssues    []*JiraIssue `json:\"issues\"`\n}\n```\nOpen issues of one issue type — the grouping returned by jiraOpenIssuesByType.\n\n```go\ntype JiraRequestTypeGroup struct {\n\t// Customer request type name, or \"(kein Anfragetyp)\" for issues raised without one.\n\tRequestType string       `json:\"requestType\"`\n\tIssues      []*JiraIssue `json:\"issues\"`\n}\n```\nOpen issues of one JSM customer request type — returned by jiraOpenIssuesByRequestType (FK07PP is a service desk project).\n\n```go\ntype JiraTransition struct {\n\tID   string `json:\"id\"`\n\tName string `json:\"name\"`\n}\n```\nA workflow transition currently available on an issue; ids are workflow- and status-specific.\n\n```go\ntype JiraUser struct {\n\tName         string `json:\"name\"`\n\tDisplayName  string `json:\"displayName\"`\n\tEmailAddress string `json:\"emailAddress\"`\n}\n```\nAuthenticated Jira user — returned by jiraConnection to verify the configured PAT.\n\n```go\ntype LogLevel string\n```\nLogLevel classifies a streamed LogLine. PROGRESS lines are throttled optimizer snapshots and should be rendered in-place (like a spinner) instead of appended. DONE marks the final line of a stream.\n\n```go\nconst (\n\tLogLevelInfo     LogLevel = \"INFO\"\n\tLogLevelWarn     LogLevel = \"WARN\"\n\tLogLevelError    LogLevel = \"ERROR\"\n\tLogLevelProgress LogLevel = \"PROGRESS\"\n\tLogLevelResult   LogLevel = \"RESULT\"\n\tLogLevelDone     LogLevel = \"DONE\"\n)\n```\n\n```go\nfunc (e LogLevel) IsValid() bool\n```\n\n```go\nfunc (e LogLevel) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e LogLevel) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e LogLevel) String() string\n```\n\n```go\nfunc (e *LogLevel) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *LogLevel) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype LogLine struct {\n\tLevel      LogLevel            `json:\"level\"`\n\tText       string              `json:\"text\"`\n\tProgress   *OptimizerProgress  `json:\"progress,omitempty\"`\n\tReport     *InvigilationReport `json:\"report,omitempty\"`\n\tValidation *ValidationReport   `json:\"validation,omitempty\"`\n\tExamReport *ExamScheduleReport `json:\"examReport,omitempty\"`\n}\n```\nLogLine is one streamed line of output. text carries the rendered line including ANSI color codes, so a terminal-like frontend can display it verbatim. progress is only set when level is PROGRESS; report is only set on the final RESULT line of an invigilation generation and carries the structured outcome.\n\n```go\ntype MinutesReport struct {\n\tWithinTolerance int `json:\"withinTolerance\"`\n\tOver            int `json:\"over\"`\n\tUnder           int `json:\"under\"`\n\tToleranceMin    int `json:\"toleranceMin\"`\n}\n```\nMinutesReport: distribution of assigned vs. target minutes around the tolerance band.\n\n```go\ntype MucDaiExam struct {\n\tPrimussAncode  int    `json:\"primussAncode\"`\n\tModule         string `json:\"module\"`\n\tMainExamer     string `json:\"mainExamer\"`\n\tMainExamerID   *int   `json:\"mainExamerID,omitempty\"`\n\tExamType       string `json:\"examType\"`\n\tDuration       int    `json:\"duration\"`\n\tIsRepeaterExam bool   `json:\"isRepeaterExam\"`\n\tProgram        string `json:\"program\"`\n\t// the responsible faculty (Prüfungsplanung), e.g. FK07 / FK03 / FK08 / FK12.\n\tPlannedBy string `json:\"plannedBy\"`\n\t// Ancode of the created/linked exam: our ZPA ancode for FK07-planned exams, the\n\t// auto-assigned ancode for exams planned by other faculties. null if not yet\n\t// created/linked.\n\tAncode *int `json:\"ancode,omitempty\"`\n\t// Link status to our data: \"external\" (auto-created external exam, linked), \"zpa\"\n\t// (linked to a ZPA exam), or \"unresolved\" (FK07 exam with no clear ZPA match — needs\n\t// manual linking).\n\tLinkStatus string `json:\"linkStatus\"`\n\t// The plan entry, if planned: dayNumber/slotNumber = my time, externalTime = the other faculty's time.\n\tPlanEntry *PlanEntry `json:\"planEntry,omitempty\"`\n}\n```\n\n```go\ntype Mutation struct {\n}\n```\n\n```go\ntype MutationLogArg struct {\n\tKey   string `json:\"key\"`\n\tValue string `json:\"value\"`\n}\n```\n\n```go\ntype MutationLogEntry struct {\n\tTime time.Time `json:\"time\"`\n\t// GraphQL operation/field name, e.g. addPreplanExam.\n\tName string `json:\"name\"`\n\t// mutation | subscription | upload\n\tType string `json:\"type\"`\n\t// The operator (Prüfungsplaner) who triggered the operation; from the local operator.* config (empty for entries written before this was configured).\n\tUser *string `json:\"user,omitempty\"`\n\t// The call arguments, flattened to key/value pairs (nested input objects included).\n\tArgs []*MutationLogArg `json:\"args\"`\n\t// Ancodes referenced by the arguments (ancode / zpaAncode / primussAncode / …).\n\tAncodes []int `json:\"ancodes\"`\n\t// Set when the operation returned an error (for subscriptions only the start error, if any).\n\tError      *string `json:\"error,omitempty\"`\n\tDurationMs int     `json:\"durationMs\"`\n}\n```\n\n```go\ntype NTA struct {\n\tName                 string  `bson:\"name\"`\n\tEmail                *string `bson:\"email\"`\n\tMtknr                string  `bson:\"mtknr\"`\n\tCompensation         string  `bson:\"compensation\"`\n\tDeltaDurationPercent int     `bson:\"deltaDurationPercent\"`\n\tNeedsRoomAlone       bool    `bson:\"needsRoomAlone\"`\n\tNeedsHardware        bool    `bson:\"needsHardware\"`\n\tProgram              string  `bson:\"program\"`\n\tFrom                 string  `bson:\"from\"`\n\tUntil                string  `bson:\"until\"`\n\tLastSemester         *string `bson:\"lastSemester\"`\n\tDeactivated          bool    `bson:\"deactivated\"`\n}\n```\n\n```go\nfunc NtaInputToNta(ntaInput NTAInput) *NTA\n```\n\n```go\ntype NTAInput struct {\n\tName                 string  `json:\"name\"`\n\tEmail                *string `json:\"email,omitempty\"`\n\tMtknr                string  `json:\"mtknr\"`\n\tCompensation         string  `json:\"compensation\"`\n\tDeltaDurationPercent int     `json:\"deltaDurationPercent\"`\n\tNeedsRoomAlone       bool    `json:\"needsRoomAlone\"`\n\tNeedsHardware        bool    `json:\"needsHardware\"`\n\tProgram              string  `json:\"program\"`\n\tFrom                 string  `json:\"from\"`\n\tUntil                string  `json:\"until\"`\n}\n```\n\n```go\ntype NTAWithRegs struct {\n\tNta  *NTA                   `json:\"nta\"`\n\tRegs *StudentRegsPerStudent `json:\"regs,omitempty\"`\n}\n```\n\n```go\ntype NTAWithRegsByExam struct {\n\tExam *ZPAExam       `json:\"exam\"`\n\tNtas []*NTAWithRegs `json:\"ntas,omitempty\"`\n}\n```\n\n```go\ntype NTAWithRegsByExamAndTeacher struct {\n\tTeacher *Teacher             `json:\"teacher\"`\n\tExams   []*NTAWithRegsByExam `json:\"exams,omitempty\"`\n}\n```\n\n```go\ntype NtaRoomAloneWaiver struct {\n\tMtknr  string `json:\"mtknr\"`\n\tAncode int    `json:\"ancode\"`\n\tReason string `json:\"reason\"`\n}\n```\n\n```go\ntype OptimizerConstraint struct {\n\tName        string `json:\"name\"`\n\tTitle       string `json:\"title\"`\n\tDescription string `json:\"description\"`\n\t// hard | soft\n\tKind string `json:\"kind\"`\n\t// soft-constraint weight (0 for hard).\n\tWeight float64 `json:\"weight\"`\n\t// display priority (lower = more important).\n\tTier int `json:\"tier\"`\n}\n```\nOptimizerConstraint describes one applied constraint (for the read-only view).\n\n```go\ntype OptimizerProgress struct {\n\tIteration int     `json:\"iteration\"`\n\tTotal     int     `json:\"total\"`\n\tBestCost  float64 `json:\"bestCost\"`\n\tBalance   bool    `json:\"balance\"`\n\tUnfilled  int     `json:\"unfilled\"`\n}\n```\nOptimizerProgress is the structured payload of a PROGRESS LogLine, mirroring the simulated-annealing optimizer snapshot.\n\n```go\ntype PermanentNonInvigilator struct {\n\tTeacherID int `json:\"teacherID\"`\n\t// Name is a denormalized display name, so the entry stays readable even when\n\t// the teacher has left the FK07 invigilator pool (then they are no longer in\n\t// invigilatorCandidates and the GUI could not resolve a name).\n\tName   string `json:\"name\"`\n\tReason string `json:\"reason\"`\n}\n```\nPermanentNonInvigilator is a teacher who never does invigilation duty again (e.g. retired). Unlike the per-semester invigilator constraints, this lives in the global \"plexams\" database and therefore carries over from semester to semester. It always implies isNotInvigilator.\n\n```go\ntype PlanEntry struct {\n\t// Starttime is the absolute start time (nil = not planned). For our own exams it\n\t// equals the chosen slot's start time; for external exams it is the other\n\t// faculty's time (which may lie outside our exam period).\n\tStarttime *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tAncode    int        `json:\"ancode\" bson:\"ancode\"`\n\tLocked    bool       `json:\"locked\" bson:\"locked\"`\n\t// PhaseFixed marks an entry fixed by the EXaHM/SEB room phase (phase A) — distinct\n\t// from Locked (the user's explicit manual lock). Phase B treats it as immovable.\n\tPhaseFixed bool `json:\"phaseFixed\" bson:\"phasefixed\"`\n\t// External marks an entry whose time was set by another faculty (not planned by\n\t// us). Such entries are preserved when the generated plan is reset.\n\tExternal bool `json:\"external\" bson:\"external\"`\n}\n```\nPlanEntry is one exam's placement. The absolute Starttime is the persisted source of truth. External marks an entry placed by another faculty (kept on a plan reset).\n\n```go\nfunc (pe *PlanEntry) IsPlanned() bool\n```\nIsPlanned reports whether the entry has a start time (placed somewhere, inside or outside our exam period).\n\n```go\ntype Planer struct {\n\tName  string `json:\"name\"`\n\tEmail string `json:\"email\"`\n\t// Override for the dry-run recipient; null/empty =\u003e defaultMail.\n\tTestMail *string `json:\"testMail,omitempty\"`\n\t// Override for the Cc added to every real send; null/empty =\u003e defaultMail.\n\tCc *string `json:\"cc,omitempty\"`\n\t// Override for the noreply From/Reply-To address of JIRA-answered mails; null/empty =\u003e noreply+plexams@hm.edu.\n\tNoreplyMail *string `json:\"noreplyMail,omitempty\"`\n\t// Override for the noreply display name; null/empty =\u003e \"Prüfungsplanung FK07 (NOREPLY)\".\n\tNoreplyName *string `json:\"noreplyName,omitempty\"`\n\t// Derived default for testMail/cc: the planner email with +plexams (e.g. x+plexams@hm.edu).\n\tDefaultMail string `json:\"defaultMail\"`\n\t// The address dry-run mails actually go to (override → config → defaultMail).\n\tEffectiveTestMail string `json:\"effectiveTestMail\"`\n\t// The Cc actually added to real sends (override → config → defaultMail).\n\tEffectiveCc string `json:\"effectiveCc\"`\n\t// The noreply address actually used (override → config → noreply+plexams@hm.edu).\n\tEffectiveNoreplyMail string `json:\"effectiveNoreplyMail\"`\n\t// The noreply display name actually used (override → config → default).\n\tEffectiveNoreplyName string `json:\"effectiveNoreplyName\"`\n}\n```\n\n```go\ntype PlannedExam struct {\n\tAncode           int                    `json:\"ancode\"`\n\tZpaExam          *ZPAExam               `json:\"zpaExam\"`\n\tPrimussExams     []*EnhancedPrimussExam `json:\"primussExams\"`\n\tConstraints      *Constraints           `json:\"constraints,omitempty\"`\n\tConflicts        []*ZPAConflict         `json:\"conflicts\"`\n\tStudentRegsCount int                    `json:\"studentRegsCount\"`\n\tNtas             []*NTA                 `json:\"ntas\"`\n\tMaxDuration      int                    `json:\"maxDuration\"`\n\tPlanEntry        *PlanEntry             `json:\"planEntry,omitempty\"`\n\tPlannedRooms     []*PlannedRoom         `json:\"plannedRooms,omitempty\"`\n}\n```\n\n```go\ntype PlannedRoom struct {\n\t// Starttime is the absolute start time of the exam using this room.\n\tStarttime         *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tRoomName          string     `json:\"roomName\" bson:\"roomname\"`\n\tAncode            int        `json:\"ancode\" bson:\"ancode\"`\n\tDuration          int        `json:\"duration\" bson:\"duration\"`\n\tHandicap          bool       `json:\"handicap\" bson:\"handicap\"`\n\tHandicapRoomAlone bool       `json:\"handicapRoomAlone\" bson:\"handicaproomalone\"`\n\tReserve           bool       `json:\"reserve\" bson:\"reserve\"`\n\tStudentsInRoom    []string   `json:\"studentsInRoom\" bson:\"studentsinroom\"`\n\tNtaMtknr          *string    `json:\"ntaMtknr,omitempty\" bson:\"ntamtknr,omitempty\"`\n\tPrePlanned        bool       `json:\"prePlanned,omitempty\" bson:\"preplanned,omitempty\"`\n}\n```\nPlannedRoom is one room's use by one exam. The absolute Starttime (the exam's slot start) is the persisted source of truth.\n\n```go\ntype PlanningCondition struct {\n\tKey   string `json:\"key\"`\n\tTitle string `json:\"title\"`\n\tPhase string `json:\"phase\"`\n\t// true when the condition (milestone) is reached.\n\tDone bool `json:\"done\"`\n\t// If set, the area this condition gates while done (e.g. ROOMS, INVIGILATIONS); null if it is not a gate.\n\tGate *PlanningGate `json:\"gate,omitempty\"`\n}\n```\n\n```go\ntype PlanningGate string\n```\nAreas that can be locked by a published gate.\n\n```go\nconst (\n\tPlanningGateExams         PlanningGate = \"EXAMS\"\n\tPlanningGateRooms         PlanningGate = \"ROOMS\"\n\tPlanningGateInvigilations PlanningGate = \"INVIGILATIONS\"\n)\n```\n\n```go\nfunc (e PlanningGate) IsValid() bool\n```\n\n```go\nfunc (e PlanningGate) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e PlanningGate) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e PlanningGate) String() string\n```\n\n```go\nfunc (e *PlanningGate) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *PlanningGate) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype PlanningPhase struct {\n\tKey        string               `json:\"key\"`\n\tTitle      string               `json:\"title\"`\n\tConditions []*PlanningCondition `json:\"conditions\"`\n}\n```\n\n```go\ntype PlanningState struct {\n\tPhases []*PlanningPhase `json:\"phases\"`\n\t// Areas whose generation is currently locked because a gate condition is set.\n\tBlockedAreas []PlanningGate `json:\"blockedAreas\"`\n}\n```\n\n```go\ntype PreExam struct {\n\tZpaExam     *ZPAExam     `json:\"zpaExam\"`\n\tConstraints *Constraints `json:\"constraints,omitempty\"`\n\tPlanEntry   *PlanEntry   `json:\"planEntry,omitempty\"`\n}\n```\n\n```go\ntype PrePlannedInvigilation struct {\n\tStarttime     *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tInvigilatorID int        `json:\"invigilatorID\" bson:\"invigilatorid\"`\n\tRoomName      *string    `json:\"roomName,omitempty\" bson:\"roomname,omitempty\"`\n\tIsReserve     bool       `json:\"isReserve\" bson:\"isreserve\"`\n}\n```\nPrePlannedInvigilation fixes an invigilator for a room (or the reserve) at one exam time before the automatic invigilation planning runs. It is a user-entered seed that survives regeneration, so the absolute Starttime is the persisted source of truth.\n\n```go\ntype PrePlannedRoom struct {\n\tAncode   int     `json:\"ancode\"`\n\tRoomName string  `json:\"roomName\"`\n\tMtknr    *string `json:\"mtknr,omitempty\"`\n\tReserve  bool    `json:\"reserve\"`\n\t// Optional exact number of students planned for this room; taken verbatim when generating.\n\tSeats *int `json:\"seats,omitempty\"`\n}\n```\n\n```go\ntype PreplanExam struct {\n\t// ID is a synthetic per-semester key (assigned on creation).\n\tID       int    `json:\"id\" bson:\"id\"`\n\tExamKind string `json:\"examKind\" bson:\"examkind\"` // \"EXaHM\" | \"SEB\"\n\t// ExamerID links to a Teacher; ExamerName is a snapshot for display.\n\tExamerID         int      `json:\"examerID\" bson:\"examerid\"`\n\tExamerName       string   `json:\"examerName\" bson:\"examername\"`\n\tModule           string   `json:\"module\" bson:\"module\"`\n\tPrograms         []string `json:\"programs\" bson:\"programs\"` // StudyProgram shortnames\n\tExpectedStudents int      `json:\"expectedStudents\" bson:\"expectedstudents\"`\n\tDuration         *int     `json:\"duration,omitempty\" bson:\"duration,omitempty\"`\n\t// PlannedStarttime is the absolute start time the pre-exam is assigned to (nil = not\n\t// yet placed). This is the source of truth — there are no day/slot ordinals; a time\n\t// outside the (next) semester's period simply has no matching booked slot.\n\tPlannedStarttime *time.Time `json:\"plannedStarttime,omitempty\" bson:\"plannedstarttime,omitempty\"`\n\t// IsFixed pins the current slot: it survives a re-run of the automatic\n\t// assignment (which otherwise re-plans all non-fixed pre-exams).\n\tIsFixed bool `json:\"isFixed\" bson:\"isfixed\"`\n\t// NotSameSlot holds PRE-EXAM ids that should NOT run at the same time as this one\n\t// (same students, even when the study program does not show it). Kept symmetric.\n\t// Soft: the solver spreads them apart (different days, else max slot distance).\n\tNotSameSlot []int `json:\"notSameSlot,omitempty\" bson:\"notsameslot,omitempty\"`\n\t// CanShareSlot holds PRE-EXAM ids that MAY run at the same time / right after this\n\t// one despite sharing a study program (no common students). Kept symmetric. It\n\t// cancels the program-based spreading penalty for that pair.\n\tCanShareSlot []int `json:\"canShareSlot,omitempty\" bson:\"canshareslot,omitempty\"`\n\t// Ancode is set once the pre-exam is linked to a real ZPA exam (phase 4).\n\tAncode *int   `json:\"ancode,omitempty\" bson:\"ancode,omitempty\"`\n\tNotes  string `json:\"notes,omitempty\" bson:\"notes,omitempty\"`\n\t// Constraints captured during pre-planning (carried over to the ZPA exam on\n\t// linking). In Constraints.SameSlot the ints are PRE-EXAM ids, not ancodes.\n\tConstraints *Constraints `json:\"constraints,omitempty\" bson:\"constraints,omitempty\"`\n}\n```\nPreplanExam is a manually entered pseudo-exam for the SEB/EXaHM pre-planning of the (next) semester, captured before the ZPA exam list and Primuss data exist. It lives in the semester's own database (collection preplan\\_exams). Once the real ZPA exams are imported, a PreplanExam is linked to its ancode (phase 4).\n\n```go\ntype PreplanExamInput struct {\n\tExamKind         string   `json:\"examKind\"`\n\tExamerID         int      `json:\"examerID\"`\n\tModule           string   `json:\"module\"`\n\tPrograms         []string `json:\"programs\"`\n\tExpectedStudents int      `json:\"expectedStudents\"`\n\tDuration         *int     `json:\"duration,omitempty\"`\n\tNotes            *string  `json:\"notes,omitempty\"`\n}\n```\n\n```go\ntype PreplanFinding struct {\n\tLevel   ValidationLevel `json:\"level\"`\n\tMessage string          `json:\"message\"`\n}\n```\nOne graded finding of the pre-plan validation (same levels as ValidationFinding).\n\n```go\ntype PreplanKindNeed struct {\n\tExamCount   int `json:\"examCount\"`\n\tSeatsNeeded int `json:\"seatsNeeded\"`\n\t// Greedily suggested number of rooms of this kind to cover the seats.\n\tRoomsSuggested int `json:\"roomsSuggested\"`\n\t// Names of the suggested rooms (largest first).\n\tRooms []string `json:\"rooms\"`\n\t// Total seats available across all rooms of this kind (per slot ceiling).\n\tSeatsAvailable int `json:\"seatsAvailable\"`\n\t// Seats already booked in Anny for this slot (0 for the unslotted bucket).\n\tSeatsBooked int `json:\"seatsBooked\"`\n\t// Rooms still to book in Anny to cover the demand (largest first); empty when enough is booked.\n\tRoomsToBook []string `json:\"roomsToBook\"`\n}\n```\n\n```go\ntype PreplanOverview struct {\n\tSlots []*PreplanSlotNeed `json:\"slots\"`\n}\n```\n\n```go\ntype PreplanProgramConflict struct {\n\tProgram        string   `json:\"program\"`\n\tPreplanExamIDs []int    `json:\"preplanExamIDs\"`\n\tModules        []string `json:\"modules\"`\n}\n```\n\n```go\ntype PreplanRule struct {\n\tKind PreplanRuleKind `json:\"kind\"`\n\t// Short German title.\n\tTitle string `json:\"title\"`\n\t// One- or two-sentence German explanation, including the relevant values.\n\tDescription string `json:\"description\"`\n}\n```\n\n```go\ntype PreplanRuleKind string\n```\n\n```go\nconst (\n\t// Must always hold; a plan violating it is invalid.\n\tPreplanRuleKindHard PreplanRuleKind = \"HARD\"\n\t// Optimization goal; the solver trades these off (weighted).\n\tPreplanRuleKindSoft PreplanRuleKind = \"SOFT\"\n)\n```\n\n```go\nfunc (e PreplanRuleKind) IsValid() bool\n```\n\n```go\nfunc (e PreplanRuleKind) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e PreplanRuleKind) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e PreplanRuleKind) String() string\n```\n\n```go\nfunc (e *PreplanRuleKind) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *PreplanRuleKind) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype PreplanSameSlotGroup struct {\n\tMembers []*PreplanSameSlotMember `json:\"members\"`\n\t// true when every member is connected (the same-slot is fully carried over to the ZPA exams).\n\tComplete bool `json:\"complete\"`\n}\n```\n\n```go\ntype PreplanSameSlotMember struct {\n\tID       int    `json:\"id\"`\n\tModule   string `json:\"module\"`\n\tExamKind string `json:\"examKind\"`\n\t// true when this member is linked to a ZPA ancode.\n\tConnected bool `json:\"connected\"`\n\tAncode    *int `json:\"ancode,omitempty\"`\n}\n```\n\n```go\ntype PreplanSlotNeed struct {\n\t// null starttime = the bucket of pre-exams without a slot yet.\n\tStarttime *time.Time       `json:\"starttime,omitempty\"`\n\tExahm     *PreplanKindNeed `json:\"exahm\"`\n\tSeb       *PreplanKindNeed `json:\"seb\"`\n\t// Programs that appear in more than one pre-exam of this slot (possible clash).\n\tConflicts []*PreplanProgramConflict `json:\"conflicts\"`\n}\n```\n\n```go\ntype PreplanValidation struct {\n\t// True when there are no error-level findings; warnings and infos do not fail the validation.\n\tOk bool `json:\"ok\"`\n\t// True when the validation did not run because there are no SEB/EXaHM pre-exams yet.\n\t// Not a failure — render neutrally (\"übersprungen\"), not as a green pass.\n\tSkipped bool `json:\"skipped\"`\n\t// Why the validation was skipped, if skipped.\n\tSkipReason    *string `json:\"skipReason,omitempty\"`\n\tAssignedCount int     `json:\"assignedCount\"`\n\t// ids of pre-exams without a slot.\n\tUnassignedIDs []int `json:\"unassignedIDs\"`\n\t// Human-readable findings (German), flat text at all levels (kept for backward compatibility; prefer findings).\n\tMessages []string `json:\"messages\"`\n\t// Graded findings. Small SEB exams that fit the R-building (no Anny booking needed)\n\t// are warnings, real capacity shortfalls are errors.\n\tFindings []*PreplanFinding `json:\"findings\"`\n}\n```\n\n```go\ntype PrimussExam struct {\n\tAnCode     int    `bson:\"AnCode\"`\n\tModule     string `bson:\"Titel\"`\n\tMainExamer string `bson:\"pruefer\"`\n\tProgram    string `bson:\"Stg\"`\n\tExamType   string `bson:\"sonst\"`\n\tPresence   string `bson:\"ist_praesenz\"`\n}\n```\n\n```go\ntype PrimussExamAncode struct {\n\tAncode        int    `json:\"ancode\"`\n\tProgram       string `json:\"program\"`\n\tNumberOfStuds int    `json:\"numberOfStuds\"`\n}\n```\n\n```go\ntype PrimussExamByProgram struct {\n\tProgram string                  `json:\"program\"`\n\tExams   []*PrimussExamWithCount `json:\"exams\"`\n}\n```\n\n```go\ntype PrimussExamInput struct {\n\tAncode  int    `json:\"ancode\"`\n\tProgram string `json:\"program\"`\n}\n```\n\n```go\ntype PrimussExamWithCount struct {\n\tAncode           int    `json:\"ancode\"`\n\tModule           string `json:\"module\"`\n\tMainExamer       string `json:\"mainExamer\"`\n\tProgram          string `json:\"program\"`\n\tExamType         string `json:\"examType\"`\n\tPresence         string `json:\"presence\"`\n\tStudentRegsCount int    `json:\"studentRegsCount\"`\n\t// true if this Primuss exam is connected to a ZPA or external (MUC.DAI) exam.\n\tConnected bool `json:\"connected\"`\n\t// true if connected to a ZPA exam selected to be planned by us (a subset of connected; false for external/MUC.DAI links or not-to-plan ZPA exams).\n\tPlannedZpa bool `json:\"plannedZPA\"`\n}\n```\n\n```go\ntype Query struct {\n}\n```\n\n```go\ntype RegWithError struct {\n\tRegistration *ZPAStudentReg      `json:\"registration\"`\n\tError        *ZPAStudentRegError `json:\"error\"`\n}\n```\n\n```go\ntype RegWithProgram struct {\n\tProgram string `json:\"program\"`\n\tReg     int    `json:\"reg\"`\n}\n```\n\n```go\ntype RemovedPrimussExam struct {\n\tAnCode  int    `bson:\"AnCode\"`\n\tProgram string `bson:\"Stg\"`\n}\n```\n\n```go\ntype Room struct {\n\tName             string `json:\"name\"`\n\tSeats            int    `json:\"seats\"`\n\tHandicap         bool   `json:\"handicap\"`\n\tLab              bool   `json:\"lab\"`\n\tPlacesWithSocket bool   `json:\"placesWithSocket\"`\n\t// needsRequest is derived: true when requestWith is not NONE.\n\tNeedsRequest bool            `json:\"needsRequest\"`\n\tRequestWith  RoomRequestType `json:\"requestWith\"`\n\t// Lower number = preferred when generating room requests (e.g. R1.006/R1.046 = 1, R1.049 = 2).\n\tRequestPriority int  `json:\"requestPriority\"`\n\tExahm           bool `json:\"exahm\"`\n\tSeb             bool `json:\"seb\"`\n\tSebSeats        *int `json:\"sebSeats,omitempty\"`\n\tHmebSeats       *int `json:\"hmebSeats,omitempty\"`\n\tDeactivated     bool `json:\"deactivated\"`\n}\n```\n\n```go\ntype RoomAndExam struct {\n\tRoom *PlannedRoom `json:\"room\"`\n\tExam *ZPAExam     `json:\"exam\"`\n}\n```\n\n```go\ntype RoomConstraints struct {\n\tAllowedRooms     []string `json:\"allowedRooms,omitempty\"`\n\tPlacesWithSocket bool     `json:\"placesWithSocket\"`\n\tLab              bool     `json:\"lab\"`\n\tExahm            bool     `json:\"exahm\"`\n\tSeb              bool     `json:\"seb\"`\n\tKdpJiraURL       *string  `json:\"kdpJiraURL,omitempty\"`\n\tMaxStudents      *int     `json:\"maxStudents,omitempty\"`\n\t// extra seats to reserve on top of the registered students (capacity buffer).\n\tAdditionalSeats *int `json:\"additionalSeats,omitempty\"`\n\t// Lead time (Vorlauf) in minutes the rooms must be free BEFORE this exam starts, as a\n\t// total that REPLACES the default 15 min (null = default). Used for setup that exceeds the\n\t// ordinary turnaround, e.g. an EXaHM exam in the T-building.\n\tPreExamMinutes *int `json:\"preExamMinutes,omitempty\"`\n\t// Trailing time (Nachlauf) in minutes the rooms stay occupied AFTER this exam ends, total\n\t// that REPLACES the default 15 min (null = default).\n\tPostExamMinutes *int    `json:\"postExamMinutes,omitempty\"`\n\tComments        *string `json:\"comments,omitempty\"`\n}\n```\n\n```go\ntype RoomInSlotUsage struct {\n\tAncode       int    `json:\"ancode\"`\n\tModule       string `json:\"module\"`\n\tExamer       string `json:\"examer\"`\n\tStudentCount int    `json:\"studentCount\"`\n}\n```\nOne exam's use of a room in a slot.\n\n```go\ntype RoomInput struct {\n\tName             string          `json:\"name\"`\n\tSeats            int             `json:\"seats\"`\n\tHandicap         bool            `json:\"handicap\"`\n\tLab              bool            `json:\"lab\"`\n\tPlacesWithSocket bool            `json:\"placesWithSocket\"`\n\tRequestWith      RoomRequestType `json:\"requestWith\"`\n\t// Lower number = preferred when generating room requests. Optional; defaults to 0 (irrelevant when requestWith is NONE).\n\tRequestPriority int  `json:\"requestPriority\"`\n\tExahm           bool `json:\"exahm\"`\n\tSeb             bool `json:\"seb\"`\n\tSebSeats        *int `json:\"sebSeats,omitempty\"`\n\tHmebSeats       *int `json:\"hmebSeats,omitempty\"`\n}\n```\n\n```go\ntype RoomRequest struct {\n\tRoom      string     `json:\"room\" bson:\"room\"`\n\tStarttime *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tFrom      time.Time  `json:\"from\" bson:\"from\"`\n\tUntil     time.Time  `json:\"until\" bson:\"until\"`\n\tApproved  bool       `json:\"approved\" bson:\"approved\"`\n\tActive    bool       `json:\"active\" bson:\"active\"`\n}\n```\nRoomRequest is a building-management room request (per semester). It reserves a room for the exam at one absolute start time with a concrete time range. Starttime is the key (persisted in room\\_requests) and is exposed by the API.\n\n```go\ntype RoomRequestPreview struct {\n\tRoom              string         `json:\"room\"`\n\tStarttime         *time.Time     `json:\"starttime,omitempty\"`\n\tFrom              time.Time      `json:\"from\"`\n\tUntil             time.Time      `json:\"until\"`\n\tStudents          int            `json:\"students\"`\n\tSeats             int            `json:\"seats\"`\n\tExam              *PlannedExam   `json:\"exam\"`\n\tSimultaneousExams []*PlannedExam `json:\"simultaneousExams\"`\n}\n```\nRoomRequestPreview is one entry of the dry-run room-request generation. The API exposes the absolute \\`starttime\\`.\n\n```go\ntype RoomRequestType string\n```\nRoomRequestType says how a room that needs requesting must be requested: NONE = no request needed, ANNY = via the Anny website (T-building), MANAGEMENT = via the building management (Gebäudemanagement).\n\n```go\nconst (\n\tRoomRequestTypeNone       RoomRequestType = \"NONE\"\n\tRoomRequestTypeAnny       RoomRequestType = \"ANNY\"\n\tRoomRequestTypeManagement RoomRequestType = \"MANAGEMENT\"\n)\n```\n\n```go\nfunc (e RoomRequestType) IsValid() bool\n```\n\n```go\nfunc (e RoomRequestType) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e RoomRequestType) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e RoomRequestType) String() string\n```\n\n```go\nfunc (e *RoomRequestType) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *RoomRequestType) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype RoomWithFreeSeats struct {\n\tRoomName  string `json:\"roomName\"`\n\tSeats     int    `json:\"seats\"`\n\tUsedSeats int    `json:\"usedSeats\"`\n\tFreeSeats int    `json:\"freeSeats\"`\n\t// handicap = true: NTA room, only for NTAs (not for normal students / non-NTA reserve).\n\tHandicap bool `json:\"handicap\"`\n\tExahm    bool `json:\"exahm\"`\n\tLab      bool `json:\"lab\"`\n\tSeb      bool `json:\"seb\"`\n\t// The exams already using this room in the slot (empty if the room is still free).\n\tUsedBy []*RoomInSlotUsage `json:\"usedBy\"`\n}\n```\nA room allowed in a slot, with its free seats and the exams already using it.\n\n```go\ntype RoomWithInvigilator struct {\n\tName         string         `json:\"name\"`\n\tMaxDuration  int            `json:\"maxDuration\"`\n\tStudentCount int            `json:\"studentCount\"`\n\tRoomAndExams []*RoomAndExam `json:\"roomAndExams\"`\n\tInvigilator  *Teacher       `json:\"invigilator,omitempty\"`\n\t// true if the invigilation for this room in this slot is pre-planned (fixed).\n\tPrePlanned bool `json:\"prePlanned\"`\n}\n```\n\n```go\ntype RoomsForSlot struct {\n\tStarttime time.Time `json:\"starttime\"`\n\tRoomNames []string  `json:\"roomNames\"`\n}\n```\n\n```go\ntype SaveSemesterConfigResult struct {\n\tOk bool `json:\"ok\"`\n\t// Non-fatal warnings, e.g. changes that may invalidate an existing plan.\n\tWarnings []string `json:\"warnings\"`\n}\n```\n\n```go\ntype Semester struct {\n\t// the database label (e.g. '2026 SS' or a clone '2026 SS-Test'); selects the database.\n\tID string `json:\"id\"`\n\t// the logical semester used against external systems (ZPA), e.g. '2026 SS' — for a clone this stays the real semester, not the database name.\n\tSemester *string `json:\"semester,omitempty\"`\n\t// false for databases that cannot be used with this code (no semester config).\n\tCompatible bool `json:\"compatible\"`\n\t// true when the database is protected: it can be selected, but all mutations fail.\n\tReadOnly bool `json:\"readOnly\"`\n\t// data schema version of the database (null when unknown/never stamped).\n\tSchemaVersion *int `json:\"schemaVersion,omitempty\"`\n}\n```\n\n```go\ntype SemesterConfig struct {\n\tDays       []*ExamDay   `json:\"days\"`\n\tStarttimes []*Starttime `json:\"starttimes\"`\n\tSlots      []*Slot      `json:\"slots\"`\n\t// Absolute start times allowed for MUC.DAI exams (echo of the raw config).\n\tMucDaiAllowedTimes []*time.Time `json:\"mucDaiAllowedTimes,omitempty\"`\n\tMucDaiSlots        []*Slot      `json:\"mucDaiSlots\"`\n\tForbiddenSlots     []*Slot      `json:\"forbiddenSlots,omitempty\"`\n\tFrom               time.Time    `json:\"from\"`\n\tUntil              time.Time    `json:\"until\"`\n\tEmails             *Emails      `json:\"emails\"`\n\t// Effective travel/break buffer (minutes) between a student's consecutive exams.\n\tExamGapMinutes int `json:\"examGapMinutes\"`\n\t// Effective turnaround (minutes) between two uses of a room / between two invigilations.\n\tTimelagMin int `json:\"timelagMin\"`\n\t// Effective \"too close\" threshold (minutes, same day) for a student's two exams.\n\tNotTooCloseMinutes int `json:\"notTooCloseMinutes\"`\n\t// Effective max students examined at the same start time (0 = no limit).\n\tMaxSeatsPerSlot int `json:\"maxSeatsPerSlot\"`\n}\n```\n\n```go\ntype SemesterConfigInput struct {\n\t// From is the start of the planning period; day 1 = from. Exams of other\n\t// faculties may have earlier dates (or a negative day number); there is no\n\t// pre-period and no check for that.\n\tFrom  time.Time `json:\"from\" bson:\"from\"`\n\tUntil time.Time `json:\"until\" bson:\"until\"`\n\t// StartTimes are the allowed daily exam start times as \"HH:MM\".\n\tStartTimes []string `json:\"startTimes\" bson:\"startTimes\"`\n\t// ForbiddenDays are full days inside the planning window on which no exams may\n\t// be scheduled.\n\tForbiddenDays []time.Time `json:\"forbiddenDays,omitempty\" bson:\"forbiddenDays,omitempty\"`\n\t// MucDaiAllowedTimes are the absolute start times allowed for MUC.DAI exams\n\t// (currently \"morning vs afternoon\"; will become allowed/forbidden times).\n\tMucDaiAllowedTimes []time.Time `json:\"mucDaiAllowedTimes,omitempty\" bson:\"mucDaiAllowedTimes,omitempty\"`\n\tEmails             *Emails     `json:\"emails\" bson:\"emails\"`\n\t// ExamGapMinutes is the travel/break buffer a student needs between two of their\n\t// consecutive exams (nil = use the built-in default). See defaultExamGapMinutes.\n\tExamGapMinutes *int `json:\"examGapMinutes,omitempty\" bson:\"examGapMinutes,omitempty\"`\n\t// TimelagMin is the minimum turnaround (minutes) between two uses of a room /\n\t// between two invigilations (nil = use the built-in default).\n\tTimelagMin *int `json:\"timelagMin,omitempty\" bson:\"timelagMin,omitempty\"`\n\t// NotTooCloseMinutes is the threshold (minutes, same day) below which two of a\n\t// student's exams are flagged \"too close\" (nil = use the built-in default 120).\n\tNotTooCloseMinutes *int `json:\"notTooCloseMinutes,omitempty\" bson:\"notTooCloseMinutes,omitempty\"`\n\t// MaxSeatsPerSlot caps how many students may be examined at the same start time\n\t// (the configurable per-time capacity used by the Terminplan solver). nil or 0 =\n\t// no limit. With finer start times this keeps overlapping exams roomable.\n\tMaxSeatsPerSlot *int `json:\"maxSeatsPerSlot,omitempty\" bson:\"maxSeatsPerSlot,omitempty\"`\n}\n```\nSemesterConfigInput holds the raw, editable per-semester configuration — the values that used to live in \\\u003csemester\u003e.yaml. It is the source of truth from which the derived SemesterConfig (days, slots, MUC.DAI slots, forbidden slots) is computed in deriveSemesterConfig. It is persisted in the per-semester DB (collection semester\\_config\\_input).\n\n```go\ntype SemesterConfigInputData struct {\n\tFrom          time.Time    `json:\"from\"`\n\tUntil         time.Time    `json:\"until\"`\n\tStartTimes    []string     `json:\"startTimes\"`\n\tForbiddenDays []*time.Time `json:\"forbiddenDays,omitempty\"`\n\t// Absolute start times allowed for MUC.DAI exams (currently \"morning vs afternoon\"; will become allowed/forbidden times).\n\tMucDaiAllowedTimes []*time.Time `json:\"mucDaiAllowedTimes,omitempty\"`\n\tEmails             *EmailsInput `json:\"emails\"`\n\t// Travel/break buffer (minutes) a student needs between two consecutive exams (null = default).\n\tExamGapMinutes *int `json:\"examGapMinutes,omitempty\"`\n\t// Minimum turnaround (minutes) between two uses of a room / between two invigilations (null = default).\n\tTimelagMin *int `json:\"timelagMin,omitempty\"`\n\t// Two exams of a student closer than this (minutes, same day) are flagged as \"too close\" (null = default 120).\n\tNotTooCloseMinutes *int `json:\"notTooCloseMinutes,omitempty\"`\n\t// Max students examined at the same start time (configurable per-time capacity for the Terminplan solver; null/0 = no limit).\n\tMaxSeatsPerSlot *int `json:\"maxSeatsPerSlot,omitempty\"`\n}\n```\n\n```go\ntype ServerInfo struct {\n\t// plexams.go build version, e.g. \"1.99.0\" or \"dev\" for local builds.\n\tVersion string `json:\"version\"`\n\t// Git commit the binary was built from (\"none\" if unknown).\n\tCommit string `json:\"commit\"`\n\t// Build date (\"unknown\" if not set).\n\tDate string `json:\"date\"`\n\t// Who built the binary (\"unknown\" if not set).\n\tBuiltBy string `json:\"builtBy\"`\n\t// Link to the GitHub release for this version, or null for dev/unreleased\n\t// builds where no matching release exists.\n\tReleaseURL *string `json:\"releaseURL,omitempty\"`\n\t// The MongoDB host:port the server is connected to (credentials redacted).\n\tMongoHost string `json:\"mongoHost\"`\n\t// The MongoDB database (workspace) currently in use, e.g. \"2026-SS\".\n\tMongoDatabase string `json:\"mongoDatabase\"`\n}\n```\n\n```go\ntype Slot struct {\n\tStarttime time.Time `json:\"starttime\"`\n}\n```\nSlot is one candidate start time of the exam grid. The absolute Starttime is the only identity; any positional (day/slot) notion is derived locally from the sorted config start times where needed, never stored.\n\n```go\ntype SlotTimeConstraintMode string\n```\nWhen the exam-schedule generator (Terminplan) applies the start-time soft constraint, and which way. AUTO follows the semester (winter → avoid early starts before the morning limit; summer → prefer early starts, the later the worse, weighted by registrations so large exams go first); WINTER/SUMMER force one variant (for testing); OFF disables it. Default AUTO.\n\n```go\nconst (\n\tSlotTimeConstraintModeAuto   SlotTimeConstraintMode = \"AUTO\"\n\tSlotTimeConstraintModeWinter SlotTimeConstraintMode = \"WINTER\"\n\tSlotTimeConstraintModeSummer SlotTimeConstraintMode = \"SUMMER\"\n\tSlotTimeConstraintModeOff    SlotTimeConstraintMode = \"OFF\"\n)\n```\n\n```go\nfunc (e SlotTimeConstraintMode) IsValid() bool\n```\n\n```go\nfunc (e SlotTimeConstraintMode) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e SlotTimeConstraintMode) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e SlotTimeConstraintMode) String() string\n```\n\n```go\nfunc (e *SlotTimeConstraintMode) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *SlotTimeConstraintMode) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype SoftCostItem struct {\n\tName string  `json:\"name\"`\n\tCost float64 `json:\"cost\"`\n}\n```\n\n```go\ntype SoftCostReport struct {\n\tTotal     float64         `json:\"total\"`\n\tBreakdown []*SoftCostItem `json:\"breakdown\"`\n}\n```\nSoftCostReport: the weighted soft-constraint penalty score (lower is better).\n\n```go\ntype SpecialInterest struct {\n\tName string `json:\"name\"`\n\t// output file name for the generated PDF.\n\tFilename string `json:\"filename\"`\n\tAncodes  []int  `json:\"ancodes\"`\n}\n```\n\n```go\ntype SpecialInterestInput struct {\n\tName     string `json:\"name\"`\n\tFilename string `json:\"filename\"`\n\tAncodes  []int  `json:\"ancodes\"`\n}\n```\n\n```go\ntype Starttime struct {\n\tStart string `json:\"start\"`\n}\n```\n\n```go\ntype Step struct {\n\tNumber   int       `json:\"number\" mapstructure:\"number\"`\n\tName     string    `json:\"name\" mapstructure:\"step\"`\n\tDone     bool      `json:\"done\" mapstructure:\"done\"`\n\tDeadline time.Time `json:\"deadline\" mapstructure:\"deadline\"`\n}\n```\n\n```go\ntype Student struct {\n\tMtknr           string            `json:\"mtknr\"`\n\tProgram         string            `json:\"program\"`\n\tGroup           string            `json:\"group\"`\n\tName            string            `json:\"name\"`\n\tRegs            []int             `json:\"regs\"`\n\tRegsWithProgram []*RegWithProgram `json:\"regsWithProgram\"`\n\tZpaStudent      *ZPAStudent       `json:\"zpaStudent,omitempty\"`\n\tNta             *NTA              `json:\"nta,omitempty\"`\n}\n```\n\n```go\ntype StudentConflictDecision struct {\n\tAncode1  int              `json:\"ancode1\"`\n\tAncode2  int              `json:\"ancode2\"`\n\tMtknr    string           `json:\"mtknr\"`\n\tDecision ConflictDecision `json:\"decision\"`\n}\n```\nStudentConflictDecision is a stored explicit decision for one student's conflict pair.\n\n```go\ntype StudentReg struct {\n\tMtknr    string `bson:\"MTKNR\"`\n\tAnCode   int    `bson:\"AnCode\"`\n\tProgram  string `bson:\"Stg\"`\n\tGroup    string `bson:\"Stgru\"`\n\tName     string `bson:\"name\"`\n\tPresence string `bson:\"praesenz_fern\"`\n}\n```\n\n```go\ntype StudentRegsForAncode struct {\n\tExam        *ZPAExam                          `json:\"exam\"`\n\tStudentRegs []*StudentRegsPerAncodeAndProgram `json:\"studentRegs\"`\n}\n```\n\n```go\ntype StudentRegsPerAncode struct {\n\tAncode     int                               `json:\"ancode\"`\n\tPerProgram []*StudentRegsPerAncodeAndProgram `json:\"perProgram\"`\n}\n```\n\n```go\ntype StudentRegsPerAncodeAndProgram struct {\n\tProgram     string        `json:\"program\"`\n\tAncode      int           `json:\"ancode\"`\n\tStudentRegs []*StudentReg `json:\"studentRegs\"`\n}\n```\n\n```go\ntype StudentRegsPerStudent struct {\n\tStudent *Student `json:\"student\"`\n\tAncodes []int    `json:\"ancodes\"`\n}\n```\n\n```go\ntype StudentRegsState struct {\n\tDirty bool `json:\"dirty\"`\n\t// the operation that last marked them stale (mutation/subscription name).\n\tReason *string `json:\"reason,omitempty\"`\n\t// when they were last marked stale or (re)generated.\n\tChangedAt *time.Time `json:\"changedAt,omitempty\"`\n}\n```\n\n```go\ntype StudyProgram struct {\n\t// Shortname (Kürzel, e.g. \"IF\") is the unique key.\n\tShortname string `json:\"shortname\" bson:\"shortname\"`\n\tName      string `json:\"name\" bson:\"name\"`\n\t// Degree, e.g. \"Bachelor\" / \"Master\" (optional).\n\tDegree *string `json:\"degree,omitempty\" bson:\"degree,omitempty\"`\n\t// Category groups the program by origin: \"fk07\" | \"mucdai\" | \"misc\".\n\tCategory string `json:\"category\" bson:\"category\"`\n\tActive   bool   `json:\"active\" bson:\"active\"`\n\t// Retired marks a discontinued program. A retired fk07 program is treated as\n\t// an \"old program\" (no longer planned, but still relevant for old exams).\n\tRetired bool `json:\"retired\" bson:\"retired\"`\n\t// ExternalExamsBase is the base ancode for external (e.g. MUC.DAI) exams of this\n\t// program: the local ZPA ancode is base + primussAncode. Only relevant for\n\t// programs whose exams are imported externally (mucdai/misc).\n\tExternalExamsBase *int `json:\"externalExamsBase,omitempty\" bson:\"externalExamsBase,omitempty\"`\n}\n```\nStudyProgram (Studiengang) is a first-class, semester-independent entity. It lives in the global \"plexams\" database and is used e.g. by the SEB/EXaHM pre-planning to foresee program overlaps before Primuss data exists. Until now programs were only strings derived from primuss collections / config.\n\n```go\ntype StudyProgramInput struct {\n\tShortname         string  `json:\"shortname\"`\n\tName              string  `json:\"name\"`\n\tDegree            *string `json:\"degree,omitempty\"`\n\tCategory          string  `json:\"category\"`\n\tActive            bool    `json:\"active\"`\n\tRetired           bool    `json:\"retired\"`\n\tExternalExamsBase *int    `json:\"externalExamsBase,omitempty\"`\n}\n```\n\n```go\ntype Subscription struct {\n}\n```\n\n```go\ntype SyncChangeEntry struct {\n\tType   string             `json:\"type\"` // \"added\" | \"removed\" | \"changed\"\n\tName   string             `json:\"name\"`\n\tFields []*SyncFieldChange `json:\"fields,omitempty\"`\n}\n```\nSyncChangeEntry is one added / removed / changed entry of an import. Fields is only set for changed entries.\n\n```go\ntype SyncFieldChange struct {\n\tField string `json:\"field\"`\n\tOld   string `json:\"old\"`\n\tNew   string `json:\"new\"`\n}\n```\nSyncFieldChange is a single field that changed (old → new).\n\n```go\ntype SyncLogEntry struct {\n\tTime      time.Time `json:\"time\"`\n\tOperation string    `json:\"operation\"` // stable key, e.g. \"zpa-import-exams\", \"zpa-upload-rooms\", \"anny-import\"\n\tLabel     string    `json:\"label\"`     // human-readable label\n\tDirection string    `json:\"direction\"` // \"import\" | \"upload\"\n\tSystem    string    `json:\"system\"`    // \"ZPA\" | \"Anny\" | …\n\tOK        bool      `json:\"ok\"`\n\tSummary   string    `json:\"summary\"`\n\t// For imports: how many entries were added / changed / removed, and the\n\t// per-entry detail. Empty / nil for uploads.\n\tAdded   int                `json:\"added\"`\n\tChanged int                `json:\"changed\"`\n\tRemoved int                `json:\"removed\"`\n\tEntries []*SyncChangeEntry `json:\"entries,omitempty\"`\n}\n```\nSyncLogEntry records one external transfer (import from / upload to ZPA, Anny, …). The collection keeps the full history since the start of the semester, so the GUI can show the last sync per operation and a timeline.\n\n```go\ntype Teacher struct {\n\tShortname    string `json:\"person_shortname\"`\n\tFullname     string `json:\"person_fullname\"`\n\tIsProf       bool   `json:\"is_prof\"`\n\tIsLBA        bool   `json:\"is_lba\"`\n\tIsProfHC     bool   `json:\"is_profhc\"`\n\tIsStaff      bool   `json:\"is_staff\"`\n\tLastSemester string `json:\"last_semester\"`\n\tFK           string `json:\"fk\"`\n\tID           int    `json:\"person_id\"`\n\tEmail        string `json:\"email\"`\n\tIsActive     bool   `json:\"is_active\"`\n}\n```\n\n```go\ntype UnplacedExam struct {\n\tStarttime *time.Time `json:\"starttime,omitempty\" bson:\"starttime,omitempty\"`\n\tAncode    int        `json:\"ancode\" bson:\"ancode\"`\n\tMtknrs    []string   `json:\"mtknrs\" bson:\"mtknrs\"`\n\tNtaMtknr  *string    `json:\"ntaMtknr,omitempty\" bson:\"ntamtknr,omitempty\"`\n}\n```\nUnplacedExam records students of an exam that could not be assigned a real room in their slot during room generation. They are deliberately kept out of planned\\_rooms — which therefore only ever holds real rooms — and surfaced by the rooms validation (and the unplacedExams query) instead of a \"No Room\" placeholder room. Starttime is the persisted truth.\n\n```go\ntype ValidationFinding struct {\n\tLevel          ValidationLevel `json:\"level\"`\n\tMessage        string          `json:\"message\"`\n\tAncode         *int            `json:\"ancode,omitempty\"`\n\tRelatedAncodes []int           `json:\"relatedAncodes,omitempty\"`\n\tRoom           *string         `json:\"room,omitempty\"`\n\t// Absolute start time of the affected slot (derived; null when not slot-related).\n\tStarttime     *time.Time `json:\"starttime,omitempty\"`\n\tInvigilatorID *int       `json:\"invigilatorID,omitempty\"`\n\tStudentMtknr  *string    `json:\"studentMtknr,omitempty\"`\n}\n```\nValidationFinding is one problem (or note) found by a validator. message is clean text (no ANSI); the optional reference fields let the GUI link a finding to the affected exam / room / slot / invigilator / student and render it as a row.\n\n```go\ntype ValidationLevel string\n```\nValidationLevel classifies a single validation finding.\n\n```go\nconst (\n\tValidationLevelInfo    ValidationLevel = \"INFO\"\n\tValidationLevelWarning ValidationLevel = \"WARNING\"\n\tValidationLevelError   ValidationLevel = \"ERROR\"\n)\n```\n\n```go\nfunc (e ValidationLevel) IsValid() bool\n```\n\n```go\nfunc (e ValidationLevel) MarshalGQL(w io.Writer)\n```\n\n```go\nfunc (e ValidationLevel) MarshalJSON() ([]byte, error)\n```\n\n```go\nfunc (e ValidationLevel) String() string\n```\n\n```go\nfunc (e *ValidationLevel) UnmarshalGQL(v any) error\n```\n\n```go\nfunc (e *ValidationLevel) UnmarshalJSON(b []byte) error\n```\n\n```go\ntype ValidationReport struct {\n\tName string `json:\"name\"`\n\tOk   bool   `json:\"ok\"`\n\t// True when the validator did not run because the data it checks does not exist yet\n\t// (e.g. no exam plan, no rooms, no invigilations). Not a failure — render neutrally\n\t// (\"übersprungen\"), not as a green pass.\n\tSkipped bool `json:\"skipped\"`\n\t// Why the validator was skipped, if skipped.\n\tSkipReason   *string              `json:\"skipReason,omitempty\"`\n\tErrorCount   int                  `json:\"errorCount\"`\n\tWarningCount int                  `json:\"warningCount\"`\n\tInfoCount    int                  `json:\"infoCount\"`\n\tFindings     []*ValidationFinding `json:\"findings\"`\n}\n```\nValidationReport is the structured outcome of one validator. It is delivered on the final RESULT line of the validator's subscription (in LogLine.validation), while the human-readable lines stream before it.\n\n```go\ntype ZPAAncodes struct {\n\tSemester string `json:\"semester\"`\n\tAnCode   int    `json:\"anCode\"`\n}\n```\n\n```go\ntype ZPAConflict struct {\n\tAncode         int                  `json:\"ancode\"`\n\tNumberOfStuds  int                  `json:\"numberOfStuds\"`\n\tPrimussAncodes []*PrimussExamAncode `json:\"primussAncodes\"`\n}\n```\n\n```go\ntype ZPAExam struct {\n\tZpaID          int                 `json:\"id\"`\n\tSemester       string              `json:\"semester\"`\n\tAnCode         int                 `json:\"ancode\"`\n\tModule         string              `json:\"module\"`\n\tMainExamer     string              `json:\"main_examer\"`\n\tMainExamerID   int                 `json:\"main_examer_id\"`\n\tExamType       string              `json:\"exam_type\"`\n\tExamTypeFull   string              `json:\"full_name\"`\n\tDate           string              `json:\"date\"`\n\tStarttime      string              `json:\"start_time\"`\n\tDuration       int                 `json:\"duration\"`\n\tIsRepeaterExam bool                `json:\"is_repeater_exam\"`\n\tGroups         []string            `json:\"groups\"`\n\tPrimussAncodes []ZPAPrimussAncodes `json:\"primuss_ancodes\"`\n\t// Faculty is the responsible faculty (Prüfungsplanung), e.g. FK03/FK08/FK12 for\n\t// external MUC.DAI exams. Empty for our own FK07 exams (ZPA does not send it); it\n\t// is stamped onto generated external exams from the StudyProgram master data.\n\tFaculty string `json:\"faculty,omitempty\"`\n}\n```\n\n```go\ntype ZPAExamPlan struct {\n\tSemester             string             `json:\"semester\"`\n\tAnCode               int                `json:\"anCode\" bson:\"ancode\"`\n\tDate                 string             `json:\"date\"` // \"19.07.2022\"\n\tTime                 string             `json:\"time\"` // \"14:30\"\n\tStudentCount         int                `json:\"total_number\"`\n\tReserveInvigilatorID int                `json:\"reserveInvigilator_id\"`\n\tRooms                []*ZPAExamPlanRoom `json:\"rooms\"`\n}\n```\n\n```go\ntype ZPAExamPlanRoom struct {\n\tRoomName      string `json:\"room_name\"`\n\tInvigilatorID int    `json:\"invigilator_id\"`\n\tDuration      int    `json:\"duration\"`\n\tIsReserve     bool   `json:\"reserveRoom\"`\n\tStudentCount  int    `json:\"numberStudents\"`\n\tIsHandicap    bool   `json:\"handicapCompensation\"`\n}\n```\n\n```go\ntype ZPAExamWithConstraints struct {\n\tZpaExam     *ZPAExam     `json:\"zpaExam\"`\n\tConstraints *Constraints `json:\"constraints,omitempty\"`\n\tPlanEntry   *PlanEntry   `json:\"planEntry,omitempty\"`\n}\n```\n\n```go\ntype ZPAExamsForType struct {\n\tType  string     `json:\"type\"`\n\tExams []*ZPAExam `json:\"exams\"`\n}\n```\n\n```go\ntype ZPAInvigilator struct {\n\tTeacher                  *Teacher `json:\"teacher\"`\n\tHasSubmittedRequirements bool     `json:\"hasSubmittedRequirements\"`\n}\n```\n\n```go\ntype ZPAPrimussAncodes struct {\n\tProgram string `json:\"program\"`\n\tAncode  int    `json:\"ancode\"`\n}\n```\n\n```go\ntype ZPAStudent struct {\n\tMtknr     string `json:\"mtknr\"`\n\tGreeting  string `json:\"greeting\"`\n\tFirstName string `json:\"first_name\"`\n\tLastName  string `json:\"last_name\"`\n\tEmail     string `json:\"email\"`\n\tGender    string `json:\"gender\"`\n\tGroup     string `json:\"group\"`\n}\n```\n\n```go\ntype ZPAStudentReg struct {\n\tSemester string `json:\"semester\"`\n\tAnCode   int    `json:\"anCode\" bson:\"ancode\"`\n\tMtknr    string `json:\"matrikel\"`\n\tProgram  string `json:\"program\"`\n}\n```\n\n```go\ntype ZPAStudentRegError struct {\n\tSemester string `json:\"semester\"`\n\tAnCode   string `json:\"anCode\" bson:\"ancode\"`\n\tExam     string `json:\"exam\"`\n\tMtknr    string `json:\"mtknr\"`\n\tProgram  string `json:\"program\"`\n}\n```\n\n","path":"github.com/obcode/plexams.go/graph/model","name":"model","synopsis":"","isRedistributable":true}
