import type { PostgresJsDatabase } from "drizzle-orm/postgres-js"; import type { z } from "zod"; import type { bookingExtraListQuerySchema, insertBookingExtraSchema, updateBookingExtraSchema } from "./validation.js"; type BookingExtraListQuery = z.infer; type CreateBookingExtraInput = z.infer; type UpdateBookingExtraInput = z.infer; export declare const bookingsExtrasService: { getSlotExtraManifest(db: PostgresJsDatabase, slotId: string, query?: { includeInactiveExtras: boolean; }): Promise<{ status: "slot_not_found"; data?: undefined; } | { status: "ok"; data: { slot: { id: string; productId: string; optionId: string | null; facilityId: string | null; availabilityRuleId: string | null; startTimeId: string | null; dateLocal: string; startsAt: Date; endsAt: Date | null; timezone: string; status: "cancelled" | "open" | "closed" | "sold_out"; unlimited: boolean; initialPax: number | null; remainingPax: number | null; initialPickups: number | null; remainingPickups: number | null; remainingResources: number | null; pastCutoff: boolean; tooEarly: boolean; nights: number | null; days: number | null; notes: string | null; createdAt: Date; updatedAt: Date; }; extras: { id: string; productId: string; supplierId: string | null; code: string | null; name: string; description: string | null; selectionType: import("./product-extra-ref.js").ProductExtraSelectionType; pricingMode: import("./product-extra-ref.js").ProductExtraPricingMode; pricedPerPerson: boolean; collectionMode: import("./product-extra-ref.js").ProductExtraCollectionMode; showOnSlotManifest: boolean; minQuantity: number | null; maxQuantity: number | null; defaultQuantity: number | null; active: boolean; sortOrder: number; metadata: Record | null; createdAt: Date; updatedAt: Date; }[]; travelers: { fullName: string; id: string; bookingId: string; bookingNumber: string; bookingStatus: "draft" | "confirmed" | "cancelled" | "on_hold" | "awaiting_payment" | "in_progress" | "completed" | "expired"; participantType: "other" | "traveler" | "occupant"; travelerCategory: "other" | "adult" | "child" | "infant" | "senior" | null; firstName: string; lastName: string; email: string | null; phone: string | null; isPrimary: boolean; createdAt: Date; }[]; selections: { bookingId: string; travelerId: string; productExtraId: string; optionExtraConfigId: string | null; bookingItemId: string | null; status: "selected" | "cancelled" | "fulfilled" | "no_show"; selected: boolean; collectionMode: import("./product-extra-ref.js").ProductExtraCollectionMode; collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded"; collectionCurrency: string | null; collectionAmountCents: number | null; collectedAt: Date | null; collectedBy: string | null; notes: string | null; metadata: Record | null; source: string; }[]; }; }>; setSlotExtraSelection(db: PostgresJsDatabase, slotId: string, input: { bookingId: string; travelerId: string; productExtraId: string; status: "selected" | "cancelled" | "fulfilled" | "no_show"; optionExtraConfigId?: string | null | undefined; collectionStatus?: "not_required" | "pending" | "collected" | "waived" | "refunded" | undefined; collectionCurrency?: string | null | undefined; collectionAmountCents?: number | null | undefined; notes?: string | null | undefined; metadata?: Record | null | undefined; }, actorId?: string): Promise<{ status: "slot_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "extra_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "traveler_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "ok"; data: { id: string; status: "selected" | "cancelled" | "fulfilled" | "no_show"; createdAt: Date; bookingId: string; productExtraId: string; optionExtraConfigId: string | null; notes: string | null; metadata: Record | null; updatedAt: Date; bookingItemId: string | null; travelerId: string; collectionMode: "external" | "none" | "included" | "booking_total" | "cash_on_trip"; collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded"; collectionCurrency: string | null; collectionAmountCents: number | null; collectedAt: Date | null; collectedBy: string | null; } | null; }>; bulkSetSlotExtraSelections(db: PostgresJsDatabase, slotId: string, input: { selections: { bookingId: string; travelerId: string; productExtraId: string; status: "selected" | "cancelled" | "fulfilled" | "no_show"; optionExtraConfigId?: string | null | undefined; collectionStatus?: "not_required" | "pending" | "collected" | "waived" | "refunded" | undefined; collectionCurrency?: string | null | undefined; collectionAmountCents?: number | null | undefined; notes?: string | null | undefined; metadata?: Record | null | undefined; }[]; }, actorId?: string): Promise<{ status: "slot_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "extra_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "traveler_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "ok"; data: ({ id: string; status: "selected" | "cancelled" | "fulfilled" | "no_show"; createdAt: Date; bookingId: string; productExtraId: string; optionExtraConfigId: string | null; notes: string | null; metadata: Record | null; updatedAt: Date; bookingItemId: string | null; travelerId: string; collectionMode: "external" | "none" | "included" | "booking_total" | "cash_on_trip"; collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded"; collectionCurrency: string | null; collectionAmountCents: number | null; collectedAt: Date | null; collectedBy: string | null; } | null)[]; }>; bulkUpdateSlotExtraCollections(db: PostgresJsDatabase, slotId: string, input: { productExtraId: string; travelerIds: string[]; collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded"; collectionCurrency?: string | null | undefined; collectionAmountCents?: number | null | undefined; notes?: string | null | undefined; }, actorId?: string): Promise<{ status: "slot_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "extra_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "traveler_not_found"; slot?: undefined; extra?: undefined; booking?: undefined; } | { status: "slot_not_found"; data?: undefined; } | { status: "ok"; data: ({ id: string; status: "selected" | "cancelled" | "fulfilled" | "no_show"; createdAt: Date; bookingId: string; productExtraId: string; optionExtraConfigId: string | null; notes: string | null; metadata: Record | null; updatedAt: Date; bookingItemId: string | null; travelerId: string; collectionMode: "external" | "none" | "included" | "booking_total" | "cash_on_trip"; collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded"; collectionCurrency: string | null; collectionAmountCents: number | null; collectedAt: Date | null; collectedBy: string | null; } | null)[]; }>; listBookingExtras(db: PostgresJsDatabase, query: BookingExtraListQuery): Promise | null; createdAt: Date; updatedAt: Date; }>>; getBookingExtraById(db: PostgresJsDatabase, id: string): Promise<{ id: string; bookingId: string; productExtraId: string | null; optionExtraConfigId: string | null; name: string; description: string | null; status: "draft" | "selected" | "confirmed" | "cancelled" | "fulfilled"; pricingMode: "included" | "per_person" | "per_booking" | "quantity_based" | "on_request" | "free"; pricedPerPerson: boolean; quantity: number; sellCurrency: string; unitSellAmountCents: number | null; totalSellAmountCents: number | null; costCurrency: string | null; unitCostAmountCents: number | null; totalCostAmountCents: number | null; notes: string | null; metadata: Record | null; createdAt: Date; updatedAt: Date; } | null>; createBookingExtra(db: PostgresJsDatabase, data: CreateBookingExtraInput): Promise<{ id: string; status: "draft" | "selected" | "confirmed" | "cancelled" | "fulfilled"; createdAt: Date; name: string; bookingId: string; productExtraId: string | null; optionExtraConfigId: string | null; description: string | null; pricingMode: "included" | "per_person" | "per_booking" | "quantity_based" | "on_request" | "free"; pricedPerPerson: boolean; quantity: number; sellCurrency: string; unitSellAmountCents: number | null; totalSellAmountCents: number | null; costCurrency: string | null; unitCostAmountCents: number | null; totalCostAmountCents: number | null; notes: string | null; metadata: Record | null; updatedAt: Date; } | null>; updateBookingExtra(db: PostgresJsDatabase, id: string, data: UpdateBookingExtraInput): Promise<{ id: string; bookingId: string; productExtraId: string | null; optionExtraConfigId: string | null; name: string; description: string | null; status: "draft" | "selected" | "confirmed" | "cancelled" | "fulfilled"; pricingMode: "included" | "per_person" | "per_booking" | "quantity_based" | "on_request" | "free"; pricedPerPerson: boolean; quantity: number; sellCurrency: string; unitSellAmountCents: number | null; totalSellAmountCents: number | null; costCurrency: string | null; unitCostAmountCents: number | null; totalCostAmountCents: number | null; notes: string | null; metadata: Record | null; createdAt: Date; updatedAt: Date; } | null>; deleteBookingExtra(db: PostgresJsDatabase, id: string): Promise<{ id: string; } | null>; }; export {};