/** * SLA Plugin Validation Functions * * This module contains validation functions that enforce conditional field requirements * for SLA definitions. Fields may be mandatory, optional, or restricted depending on * the values of control fields. * * @see ./SLA-VALIDATION-BEHAVIORS.md for detailed documentation of all 11 validation behaviors */ import type { Diagnostics, ObjectShape } from '@servicenow/sdk-build-core'; export declare const DEFAULT_WHEN_TO_RESUME = "on_condition"; export declare const DEFAULT_WHEN_TO_CANCEL = "on_condition"; export declare const DEFAULT_TIMEZONE_SOURCE = "task.caller_id.time_zone"; export declare const DEFAULT_RETROACTIVE_PAUSE = true; export declare const DEFAULT_NO_SCHEDULE_ID = "38fa64edc0a8016400f4a5724b0434b8"; export declare const ERROR_MESSAGES: { MANDATORY_FIELD: (field: string, reason: string) => string; RESTRICTED_FIELD: (field: string, reason: string) => string; RESTRICTED_WITH_DEFAULT: (field: string, reason: string, defaultValue: unknown) => string; WARNING_FIELD_PERSISTENCE: (field: string, reason: string) => string; }; /** * Validates user-specified duration fields (Behavior 1) */ export declare function validateUserSpecifiedDuration(config: ObjectShape, diagnostics: Diagnostics): void; /** * Validates relative duration restrictions (Behavior 2) */ export declare function validateRelativeDuration(config: ObjectShape, conditions: ObjectShape | undefined, diagnostics: Diagnostics): void; /** * Validates retroactive start requirements (Behaviors 6 & 8) */ export declare function validateRetroactiveStart(retroactive: ObjectShape, isUserSpecifiedDuration: boolean, diagnostics: Diagnostics): void; /** * Validates that retroactive.pause and retroactive.setStartTo are not set when retroactive.start is false (Behavior 7) */ export declare function validateRetroactiveFieldsWithoutStart(retroactive: ObjectShape | undefined, diagnostics: Diagnostics): void; /** * Validates no_schedule restrictions (Behavior 4) */ export declare function validateNoScheduleRestrictions(config: ObjectShape, diagnostics: Diagnostics): void; /** * Validates task_field schedule requirements (Behavior 5) */ export declare function validateTaskFieldSchedule(config: ObjectShape, diagnostics: Diagnostics): void; /** * Validates sla_definition schedule requirements (Behavior 3) */ export declare function validateSlaDefinitionSchedule(config: ObjectShape, diagnostics: Diagnostics): void; /** * Validates timezone source restrictions (Behavior 9) */ export declare function validateTimezoneSource(config: ObjectShape, timezoneSource: string | undefined, diagnostics: Diagnostics): void; /** * Validates no_match resume restrictions (Behavior 10) */ export declare function validateNoMatchResume(conditions: ObjectShape | undefined, diagnostics: Diagnostics): void; /** * Validates cancel condition restrictions (Behavior 11) */ export declare function validateCancelCondition(whenToCancel: string | undefined, conditions: ObjectShape | undefined, diagnostics: Diagnostics): void;