import type { Brand } from './branded';
import { type Result } from './result';
export type BookingTimeZone = Brand<string, 'BookingTimeZone'>;
export type UtcIsoDateTimeString = Brand<string, 'UtcIsoDateTimeString'>;
export type BookingLocalDateKey = Brand<string, 'BookingLocalDateKey'>;
export type UtcIsoDateTimeStringParseError = 'missing-timezone-offset' | 'invalid-date-time';
export type BookingUtcDateWindow = Readonly<{
    timeZone: BookingTimeZone;
    startLocalDate: LocalScheduleDate;
    endLocalDate: LocalScheduleDate;
    startAt: Date;
    endExclusive: Date;
}>;
export type LocalScheduleDate = Readonly<{
    year: number;
    month: number;
    day: number;
}>;
export type LocalScheduleTime = Readonly<{
    hour: number;
    minute: number;
    second: number;
}>;
/**
 * Edge input for formatting a single scheduled booking instant.
 * Callers should normalize to `ScheduledBookingDateTime` when the value crosses
 * into shared domain logic.
 */
export type BookingDateFormatInput = Readonly<{
    startsAt: string;
    timeZone: string;
    locale?: string;
}>;
/**
 * Edge input for formatting a scheduled booking range.
 * Callers should normalize to `ScheduledBookingDateRange` when the value crosses
 * into shared domain logic.
 */
export type BookingRangeFormatInput = Readonly<{
    startsAt: string;
    endsAt?: string | null;
    timeZone: string;
    locale?: string;
}>;
export type ScheduledBookingDateTime = Readonly<{
    startsAt: UtcIsoDateTimeString;
    timeZone: BookingTimeZone;
    locale?: string;
}>;
export type ScheduledBookingDateRange = Readonly<{
    startsAt: UtcIsoDateTimeString;
    endsAt?: UtcIsoDateTimeString | null;
    timeZone: BookingTimeZone;
    locale?: string;
}>;
export type ScheduledBookingParseError = Readonly<{
    ok: false;
    field: 'startsAt';
    reason: 'invalid_starts_at';
    value: string;
}> | Readonly<{
    ok: false;
    field: 'endsAt';
    reason: 'invalid_ends_at';
    value: string | null | undefined;
}> | Readonly<{
    ok: false;
    field: 'timeZone';
    reason: 'invalid_time_zone';
    value: string;
}>;
export type ParseScheduledBookingDateTimeResult = Readonly<{
    ok: true;
    value: ScheduledBookingDateTime;
}> | ScheduledBookingParseError;
export type ParseScheduledBookingDateRangeResult = Readonly<{
    ok: true;
    value: ScheduledBookingDateRange;
}> | ScheduledBookingParseError;
export type BookingDateFormatParts = Readonly<{
    date: string;
    time: string;
}>;
export type ParseBookingUtcDateWindowResult = Readonly<{
    ok: true;
    value: BookingUtcDateWindow;
}> | Readonly<{
    ok: false;
    field: 'startDate' | 'endDate';
    reason: 'invalid_date_format' | 'invalid_date_range';
    value: string;
}>;
type BookingInstantFormatOptions = Readonly<{
    locale?: string;
    timeZone?: string | null;
    format: Intl.DateTimeFormatOptions;
}>;
export declare function toBookingTimeZone(timeZone: string | null | undefined): BookingTimeZone;
export declare const DEFAULT_BOOKING_TIME_ZONE: BookingTimeZone;
export declare function resolveBookingTimezone(venueTimezone: string | null | undefined, siteDefaultTimezone: string): string;
export declare function resolveBookingTimeZoneId(...candidates: Array<string | null | undefined>): BookingTimeZone;
export declare function parseUtcIsoDateTimeString(value: string): Result<UtcIsoDateTimeString, UtcIsoDateTimeStringParseError>;
export declare function toUtcIsoDateTimeString(value: string): UtcIsoDateTimeString;
export declare function parseScheduledBookingDateTime(input: BookingDateFormatInput): ParseScheduledBookingDateTimeResult;
export declare function parseScheduledBookingDateRange(input: BookingRangeFormatInput): ParseScheduledBookingDateRangeResult;
export declare function toScheduledBookingDateTime(input: BookingDateFormatInput): ScheduledBookingDateTime;
export declare function toScheduledBookingDateRange(input: BookingRangeFormatInput): ScheduledBookingDateRange;
export declare function formatBookingInstant(isoString: string, options: BookingInstantFormatOptions): string;
export declare function formatBookingDate(input: ScheduledBookingDateTime, format?: Intl.DateTimeFormatOptions): string;
export declare function formatBookingTime(input: ScheduledBookingDateTime, format?: Intl.DateTimeFormatOptions): string;
export declare function formatBookingDateTime(input: ScheduledBookingDateTime, format?: Intl.DateTimeFormatOptions): string;
export declare function formatBookingDateParts(input: ScheduledBookingDateRange, options?: Readonly<{
    dateFormat?: Intl.DateTimeFormatOptions;
    timeFormat?: Intl.DateTimeFormatOptions;
}>): BookingDateFormatParts;
export declare function getBookingLocalDateKey(input: ScheduledBookingDateTime): BookingLocalDateKey;
export declare function compareLocalScheduleDates(left: LocalScheduleDate, right: LocalScheduleDate): number;
export declare function parseBookingLocalDate(value: string): LocalScheduleDate;
export declare function parseBookingUtcDateWindow(input: Readonly<{
    startDate: string;
    endDate: string;
    timeZone: string | null | undefined;
}>): ParseBookingUtcDateWindowResult;
export declare function buildBookingUtcDateWindow(input: Readonly<{
    startDate: string;
    endDate: string;
    timeZone: string | null | undefined;
}>): BookingUtcDateWindow;
export declare function formatBookingRange(input: ScheduledBookingDateRange, options?: Readonly<{
    dateFormat?: Intl.DateTimeFormatOptions;
    timeFormat?: Intl.DateTimeFormatOptions;
}>): string;
export declare function parseLocalScheduleTime(value: string): LocalScheduleTime;
export declare function getLocalScheduleDate(date: Date, timeZone: BookingTimeZone | string | null | undefined): LocalScheduleDate;
export declare function getLocalScheduleTime(date: Date, timeZone: BookingTimeZone | string | null | undefined): LocalScheduleTime;
export declare function formatLocalScheduleDate(date: LocalScheduleDate): string;
export declare function getDaysInLocalMonth(year: number, month: number): number;
export declare function addLocalScheduleDays(date: LocalScheduleDate, days: number): LocalScheduleDate;
export declare function addLocalScheduleMonths(date: LocalScheduleDate, months: number): LocalScheduleDate;
export declare function getLocalScheduleDayOfWeek(date: LocalScheduleDate): number;
export declare function localScheduleDateTimeToUtcDate(localDate: LocalScheduleDate, localTime: LocalScheduleTime, timeZone: BookingTimeZone | string): Date;
export {};
