@atzentis/booking-sdk 0.1.8 → 0.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1197,6 +1197,233 @@ declare class CategoriesService extends BaseService {
1197
1197
  delete(categoryId: string): Promise<void>;
1198
1198
  }
1199
1199
 
1200
+ /** Type of discount rule */
1201
+ type DiscountType = "coupon" | "early_bird" | "seasonal" | "last_minute";
1202
+ /** How the discount value is applied */
1203
+ type DiscountValueType = "percentage" | "fixed";
1204
+ /** Status of a discount rule */
1205
+ type DiscountRuleStatus = "active" | "expired" | "exhausted" | "disabled";
1206
+ /** Status of a coupon code */
1207
+ type CouponStatus = "active" | "redeemed" | "expired" | "disabled";
1208
+ /** Sort field for discount rules */
1209
+ type DiscountSortBy = "createdAt" | "name" | "value" | "redemptionCount";
1210
+ /** A discount rule defining eligibility and value */
1211
+ interface DiscountRule {
1212
+ id: string;
1213
+ propertyId: string;
1214
+ name: string;
1215
+ description: string | null;
1216
+ type: DiscountType;
1217
+ valueType: DiscountValueType;
1218
+ value: number;
1219
+ spaceTypes: string[] | null;
1220
+ minNights: number | null;
1221
+ maxNights: number | null;
1222
+ validFrom: string | null;
1223
+ validTo: string | null;
1224
+ bookingFrom: string | null;
1225
+ bookingTo: string | null;
1226
+ maxRedemptions: number | null;
1227
+ maxRedemptionsPerGuest: number | null;
1228
+ minBookingValue: number | null;
1229
+ stackable: boolean;
1230
+ enabled: boolean;
1231
+ status: DiscountRuleStatus;
1232
+ redemptionCount: number;
1233
+ totalDiscountAmount: number;
1234
+ metadata: Record<string, unknown> | null;
1235
+ createdAt: string;
1236
+ updatedAt: string;
1237
+ deletedAt: string | null;
1238
+ }
1239
+ /** A coupon code generated from a discount rule */
1240
+ interface Coupon {
1241
+ id: string;
1242
+ ruleId: string;
1243
+ code: string;
1244
+ status: CouponStatus;
1245
+ maxRedemptions: number | null;
1246
+ redemptionCount: number;
1247
+ expiresAt: string | null;
1248
+ createdAt: string;
1249
+ }
1250
+ /** Result of validating a coupon code */
1251
+ interface CouponValidation {
1252
+ valid: boolean;
1253
+ coupon: Coupon | null;
1254
+ rule: DiscountRule | null;
1255
+ discountAmount: number;
1256
+ finalPrice: number;
1257
+ reason: string | null;
1258
+ }
1259
+ /** Record of a discount being applied to a booking */
1260
+ interface DiscountApplication {
1261
+ id: string;
1262
+ bookingId: string;
1263
+ ruleId: string;
1264
+ couponId: string | null;
1265
+ code: string | null;
1266
+ discountAmount: number;
1267
+ originalPrice: number;
1268
+ finalPrice: number;
1269
+ appliedAt: string;
1270
+ }
1271
+ /** A single redemption record */
1272
+ interface DiscountRedemption {
1273
+ id: string;
1274
+ bookingId: string;
1275
+ guestId: string;
1276
+ couponId: string | null;
1277
+ code: string | null;
1278
+ discountAmount: number;
1279
+ redeemedAt: string;
1280
+ }
1281
+ /** Usage statistics and redemption history for a discount rule */
1282
+ interface DiscountUsage {
1283
+ ruleId: string;
1284
+ totalRedemptions: number;
1285
+ totalDiscountAmount: number;
1286
+ averageDiscountAmount: number;
1287
+ redemptions: DiscountRedemption[];
1288
+ cursor: string | null;
1289
+ hasMore: boolean;
1290
+ }
1291
+ /** Input for creating a discount rule */
1292
+ interface CreateDiscountRuleInput {
1293
+ propertyId: string;
1294
+ name: string;
1295
+ type: DiscountType;
1296
+ valueType: DiscountValueType;
1297
+ value: number;
1298
+ description?: string;
1299
+ spaceTypes?: string[];
1300
+ minNights?: number;
1301
+ maxNights?: number;
1302
+ validFrom?: string;
1303
+ validTo?: string;
1304
+ bookingFrom?: string;
1305
+ bookingTo?: string;
1306
+ maxRedemptions?: number;
1307
+ maxRedemptionsPerGuest?: number;
1308
+ minBookingValue?: number;
1309
+ stackable?: boolean;
1310
+ enabled?: boolean;
1311
+ metadata?: Record<string, unknown>;
1312
+ }
1313
+ /** Input for updating a discount rule */
1314
+ interface UpdateDiscountRuleInput {
1315
+ name?: string;
1316
+ description?: string;
1317
+ value?: number;
1318
+ validFrom?: string;
1319
+ validTo?: string;
1320
+ bookingFrom?: string;
1321
+ bookingTo?: string;
1322
+ maxRedemptions?: number;
1323
+ maxRedemptionsPerGuest?: number;
1324
+ minBookingValue?: number;
1325
+ stackable?: boolean;
1326
+ enabled?: boolean;
1327
+ metadata?: Record<string, unknown>;
1328
+ }
1329
+ /** Parameters for listing discount rules */
1330
+ interface ListDiscountRulesParams {
1331
+ propertyId: string;
1332
+ type?: DiscountType;
1333
+ status?: DiscountRuleStatus;
1334
+ enabled?: boolean;
1335
+ validOn?: string;
1336
+ sortBy?: DiscountSortBy;
1337
+ sortOrder?: "asc" | "desc";
1338
+ limit?: number;
1339
+ cursor?: string;
1340
+ }
1341
+ /** Input for generating coupons from a discount rule */
1342
+ interface GenerateCouponsInput {
1343
+ count?: number;
1344
+ prefix?: string;
1345
+ code?: string;
1346
+ expiresAt?: string;
1347
+ maxRedemptions?: number;
1348
+ }
1349
+ /** Input for validating a coupon code */
1350
+ interface ValidateCouponInput {
1351
+ code: string;
1352
+ propertyId: string;
1353
+ bookingValue: number;
1354
+ checkIn?: string;
1355
+ checkOut?: string;
1356
+ spaceType?: string;
1357
+ guestId?: string;
1358
+ }
1359
+ /** Input for applying a discount to a booking */
1360
+ interface ApplyDiscountInput {
1361
+ bookingId: string;
1362
+ code: string;
1363
+ guestId?: string;
1364
+ }
1365
+ /** Parameters for querying discount usage */
1366
+ interface DiscountUsageParams {
1367
+ from?: string;
1368
+ to?: string;
1369
+ limit?: number;
1370
+ cursor?: string;
1371
+ }
1372
+ /** Paginated list of discount rules */
1373
+ type PaginatedDiscountRules = Paginated<DiscountRule>;
1374
+
1375
+ /**
1376
+ * Service for discount and coupon management in the Atzentis Booking API.
1377
+ *
1378
+ * Provides discount rule CRUD, coupon generation and validation,
1379
+ * discount application, and usage tracking.
1380
+ *
1381
+ * @example
1382
+ * ```typescript
1383
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
1384
+ *
1385
+ * // Create a discount rule
1386
+ * const rule = await booking.discounts.createRule({
1387
+ * propertyId: "prop_1",
1388
+ * name: "Early Bird 15%",
1389
+ * type: "early_bird",
1390
+ * valueType: "percentage",
1391
+ * value: 15,
1392
+ * });
1393
+ *
1394
+ * // Generate coupon codes
1395
+ * const coupons = await booking.discounts.generateCoupons(rule.id, { count: 10 });
1396
+ *
1397
+ * // Validate a coupon
1398
+ * const result = await booking.discounts.validateCoupon({
1399
+ * code: coupons[0].code,
1400
+ * propertyId: "prop_1",
1401
+ * bookingValue: 500,
1402
+ * });
1403
+ * ```
1404
+ */
1405
+ declare class DiscountsService extends BaseService {
1406
+ protected readonly basePath = "/guest/v1";
1407
+ /** Create a discount rule */
1408
+ createRule(input: CreateDiscountRuleInput): Promise<DiscountRule>;
1409
+ /** Get a discount rule by ID */
1410
+ getRule(ruleId: string): Promise<DiscountRule>;
1411
+ /** List discount rules with optional filters */
1412
+ listRules(params: ListDiscountRulesParams): Promise<PaginatedDiscountRules>;
1413
+ /** Update a discount rule */
1414
+ updateRule(ruleId: string, input: UpdateDiscountRuleInput): Promise<DiscountRule>;
1415
+ /** Delete a discount rule */
1416
+ deleteRule(ruleId: string): Promise<void>;
1417
+ /** Generate coupon codes for a discount rule */
1418
+ generateCoupons(ruleId: string, input?: GenerateCouponsInput): Promise<Coupon[]>;
1419
+ /** Validate a coupon code against booking context */
1420
+ validateCoupon(input: ValidateCouponInput): Promise<CouponValidation>;
1421
+ /** Apply a discount to a booking */
1422
+ applyDiscount(input: ApplyDiscountInput): Promise<DiscountApplication>;
1423
+ /** Get usage statistics and redemption history for a discount rule */
1424
+ getUsage(ruleId: string, params?: DiscountUsageParams): Promise<DiscountUsage>;
1425
+ }
1426
+
1200
1427
  /** Supported distribution channel types */
1201
1428
  type ChannelType = "channex" | "ical" | "direct";
1202
1429
  /** Channel connection status */
@@ -1450,7 +1677,7 @@ interface ListFoliosParams {
1450
1677
  /** Paginated list of folios */
1451
1678
  type PaginatedFolios = Paginated<Folio>;
1452
1679
  /** Type of charge applied to a folio */
1453
- type ChargeType = "room" | "minibar" | "restaurant" | "spa" | "parking" | "telephone" | "laundry" | "other";
1680
+ type ChargeType = "room" | "minibar" | "restaurant" | "spa" | "parking" | "telephone" | "laundry" | "pos" | "other";
1454
1681
  /** A charge on a folio */
1455
1682
  interface FolioCharge {
1456
1683
  id: string;
@@ -1568,6 +1795,56 @@ interface AccountingReportParams {
1568
1795
  to?: string;
1569
1796
  propertyId?: string;
1570
1797
  }
1798
+ /** A line item in a POS order */
1799
+ interface FolioPostItem {
1800
+ name: string;
1801
+ quantity: number;
1802
+ unitPrice: number;
1803
+ category: string;
1804
+ }
1805
+ /** Input for posting a POS charge to a folio */
1806
+ interface FolioPostInput {
1807
+ folioId: string;
1808
+ posOrderId: string;
1809
+ amount: number;
1810
+ posTerminalId?: string;
1811
+ items?: FolioPostItem[];
1812
+ description?: string;
1813
+ currency?: string;
1814
+ metadata?: Record<string, unknown>;
1815
+ }
1816
+ /** Result of posting a POS charge */
1817
+ interface FolioPostResult {
1818
+ chargeId: string;
1819
+ folioId: string;
1820
+ posOrderId: string;
1821
+ amount: number;
1822
+ status: "posted";
1823
+ postedAt: string;
1824
+ }
1825
+ /** A POS charge with full provenance metadata */
1826
+ interface FolioPostCharge {
1827
+ chargeId: string;
1828
+ folioId: string;
1829
+ posOrderId: string;
1830
+ posTerminalId: string | null;
1831
+ amount: number;
1832
+ description: string | null;
1833
+ items: FolioPostItem[];
1834
+ currency: string;
1835
+ postedAt: string;
1836
+ metadata: Record<string, unknown> | null;
1837
+ }
1838
+ /** Parameters for listing POS charges on a folio */
1839
+ interface ListFolioPostParams {
1840
+ posTerminalId?: string;
1841
+ from?: string;
1842
+ to?: string;
1843
+ limit?: number;
1844
+ cursor?: string;
1845
+ }
1846
+ /** Paginated list of POS charges */
1847
+ type PaginatedFolioPostCharges = Paginated<FolioPostCharge>;
1571
1848
 
1572
1849
  /**
1573
1850
  * Service for financial operations in the Atzentis Booking API.
@@ -1636,6 +1913,213 @@ declare class FinanceService extends BaseService {
1636
1913
  getRevenueReport(params?: AccountingReportParams): Promise<AccountingRevenueReport>;
1637
1914
  /** Get VAT accounting report */
1638
1915
  getVatReport(params?: AccountingReportParams): Promise<AccountingVatReport>;
1916
+ /** Post a POS charge to a guest folio */
1917
+ folioPost(input: FolioPostInput): Promise<FolioPostResult>;
1918
+ /** List POS charges on a folio */
1919
+ listFolioPostCharges(folioId: string, params?: ListFolioPostParams): Promise<PaginatedFolioPostCharges>;
1920
+ }
1921
+
1922
+ /** Type of group booking */
1923
+ type GroupType = "wedding" | "conference" | "corporate" | "tour" | "other";
1924
+ /** Status of a group booking */
1925
+ type GroupStatus = "tentative" | "definite" | "cancelled";
1926
+ /** A single date entry in a block with room count and rate */
1927
+ interface BlockDate {
1928
+ date: string;
1929
+ count: number;
1930
+ rate: number;
1931
+ }
1932
+ /** Summary of block allocation for a group */
1933
+ interface GroupBlockSummary {
1934
+ totalRooms: number;
1935
+ pickedUp: number;
1936
+ remaining: number;
1937
+ }
1938
+ /** A room block within a group booking */
1939
+ interface Block {
1940
+ id: string;
1941
+ groupId: string;
1942
+ categoryId: string;
1943
+ dates: BlockDate[];
1944
+ totalRooms: number;
1945
+ pickedUp: number;
1946
+ remaining: number;
1947
+ notes: string | null;
1948
+ metadata: Record<string, unknown> | null;
1949
+ createdAt: string;
1950
+ updatedAt: string;
1951
+ }
1952
+ /** A group booking entity */
1953
+ interface Group {
1954
+ id: string;
1955
+ propertyId: string;
1956
+ name: string;
1957
+ type: GroupType;
1958
+ status: GroupStatus;
1959
+ contactName: string | null;
1960
+ contactEmail: string | null;
1961
+ contactPhone: string | null;
1962
+ checkIn: string | null;
1963
+ checkOut: string | null;
1964
+ cutoffDate: string | null;
1965
+ blockSummary: GroupBlockSummary;
1966
+ folioId: string | null;
1967
+ notes: string | null;
1968
+ metadata: Record<string, unknown> | null;
1969
+ createdAt: string;
1970
+ updatedAt: string;
1971
+ }
1972
+ /** Pickup data broken down by category */
1973
+ interface CategoryPickup {
1974
+ categoryId: string;
1975
+ categoryName: string;
1976
+ blocked: number;
1977
+ pickedUp: number;
1978
+ remaining: number;
1979
+ }
1980
+ /** Pickup data broken down by date */
1981
+ interface DatePickup {
1982
+ date: string;
1983
+ blocked: number;
1984
+ pickedUp: number;
1985
+ remaining: number;
1986
+ }
1987
+ /** Pickup tracking data for a group */
1988
+ interface Pickup {
1989
+ groupId: string;
1990
+ totalBlocked: number;
1991
+ totalPickedUp: number;
1992
+ totalRemaining: number;
1993
+ pickupPercent: number;
1994
+ byCategory: CategoryPickup[];
1995
+ byDate: DatePickup[];
1996
+ }
1997
+ /** Result of a block release operation */
1998
+ interface ReleaseResult {
1999
+ groupId: string;
2000
+ releasedCount: number;
2001
+ remainingBlocked: number;
2002
+ releasedAt: string;
2003
+ }
2004
+ /** Result of creating a group folio */
2005
+ interface GroupFolioResult {
2006
+ groupId: string;
2007
+ folioId: string;
2008
+ status: string;
2009
+ createdAt: string;
2010
+ }
2011
+ /** Input for creating a group booking */
2012
+ interface CreateGroupInput {
2013
+ propertyId: string;
2014
+ name: string;
2015
+ type?: GroupType;
2016
+ contactName?: string;
2017
+ contactEmail?: string;
2018
+ contactPhone?: string;
2019
+ checkIn?: string;
2020
+ checkOut?: string;
2021
+ cutoffDate?: string;
2022
+ notes?: string;
2023
+ metadata?: Record<string, unknown>;
2024
+ }
2025
+ /** Input for updating a group booking */
2026
+ interface UpdateGroupInput {
2027
+ name?: string;
2028
+ type?: GroupType;
2029
+ status?: GroupStatus;
2030
+ contactName?: string;
2031
+ contactEmail?: string;
2032
+ contactPhone?: string;
2033
+ checkIn?: string;
2034
+ checkOut?: string;
2035
+ cutoffDate?: string;
2036
+ notes?: string;
2037
+ metadata?: Record<string, unknown>;
2038
+ }
2039
+ /** Input for creating a room block */
2040
+ interface CreateBlockInput {
2041
+ categoryId: string;
2042
+ dates: BlockDate[];
2043
+ notes?: string;
2044
+ metadata?: Record<string, unknown>;
2045
+ }
2046
+ /** Input for releasing blocks */
2047
+ interface ReleaseBlocksInput {
2048
+ count?: number;
2049
+ categoryId?: string;
2050
+ notes?: string;
2051
+ }
2052
+ /** Input for creating a group folio */
2053
+ interface CreateGroupFolioInput {
2054
+ billingName?: string;
2055
+ billingAddress?: string;
2056
+ notes?: string;
2057
+ }
2058
+ /** Parameters for listing groups */
2059
+ interface ListGroupsParams {
2060
+ propertyId: string;
2061
+ status?: GroupStatus | GroupStatus[];
2062
+ type?: GroupType | GroupType[];
2063
+ search?: string;
2064
+ limit?: number;
2065
+ cursor?: string;
2066
+ }
2067
+ /** Paginated list of groups */
2068
+ type PaginatedGroups = Paginated<Group>;
2069
+
2070
+ /**
2071
+ * Service for group booking operations in the Atzentis Booking API.
2072
+ *
2073
+ * Provides group CRUD, room block management, pickup tracking,
2074
+ * block release operations, and group folio creation.
2075
+ *
2076
+ * @example
2077
+ * ```typescript
2078
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
2079
+ *
2080
+ * // Create a conference group
2081
+ * const group = await booking.groups.create({
2082
+ * propertyId: "prop_abc123",
2083
+ * name: "Tech Conference 2025",
2084
+ * type: "conference",
2085
+ * });
2086
+ *
2087
+ * // Add a room block
2088
+ * const block = await booking.groups.createBlock(group.id, {
2089
+ * categoryId: "cat_std",
2090
+ * dates: [
2091
+ * { date: "2025-09-15", count: 20, rate: 12000 },
2092
+ * { date: "2025-09-16", count: 20, rate: 12000 },
2093
+ * ],
2094
+ * });
2095
+ *
2096
+ * // Track pickup and release remaining
2097
+ * const pickup = await booking.groups.getPickup(group.id);
2098
+ * await booking.groups.release(group.id, { count: 5 });
2099
+ * ```
2100
+ */
2101
+ declare class GroupsService extends BaseService {
2102
+ protected readonly basePath = "/booking/v1/groups";
2103
+ /** Create a group booking */
2104
+ create(input: CreateGroupInput): Promise<Group>;
2105
+ /** Get a group booking by ID */
2106
+ get(groupId: string): Promise<Group>;
2107
+ /** List group bookings with filters */
2108
+ list(params: ListGroupsParams): Promise<PaginatedGroups>;
2109
+ /** Update a group booking */
2110
+ update(groupId: string, input: UpdateGroupInput): Promise<Group>;
2111
+ /** Delete a group booking */
2112
+ delete(groupId: string): Promise<void>;
2113
+ /** Create a room block for a group */
2114
+ createBlock(groupId: string, input: CreateBlockInput): Promise<Block>;
2115
+ /** List blocks for a group */
2116
+ listBlocks(groupId: string): Promise<Block[]>;
2117
+ /** Get pickup tracking data for a group */
2118
+ getPickup(groupId: string): Promise<Pickup>;
2119
+ /** Release blocks back to inventory */
2120
+ release(groupId: string, input?: ReleaseBlocksInput): Promise<ReleaseResult>;
2121
+ /** Create a master folio for a group */
2122
+ createFolio(groupId: string, input?: CreateGroupFolioInput): Promise<GroupFolioResult>;
1639
2123
  }
1640
2124
 
1641
2125
  /** Guest address */
@@ -2213,83 +2697,550 @@ declare class GuestsService extends BaseService {
2213
2697
  private _buildHistoryQuery;
2214
2698
  }
2215
2699
 
2216
- /** Supported payment providers */
2217
- type PaymentProvider = "stripe" | "viva_wallet";
2218
- /** Status of a payment */
2219
- type PaymentStatus = "succeeded" | "pending" | "failed" | "requires_action";
2220
- /** A processed payment */
2221
- interface Payment {
2700
+ /** Housekeeping status of a space */
2701
+ type HousekeepingStatus = "dirty" | "clean" | "inspected" | "out_of_order" | "out_of_service";
2702
+ /** Occupancy status of a space */
2703
+ type OccupancyStatus = "vacant" | "occupied" | "due_out" | "due_in";
2704
+ /** Priority level for housekeeping tasks */
2705
+ type HousekeepingPriority = "normal" | "rush" | "vip";
2706
+ /** A single entry on the housekeeping board */
2707
+ interface HousekeepingBoardEntry {
2708
+ spaceId: string;
2709
+ spaceName: string;
2710
+ spaceType: string;
2711
+ floor: number;
2712
+ status: HousekeepingStatus;
2713
+ occupancyStatus: OccupancyStatus;
2714
+ priority: HousekeepingPriority;
2715
+ assignedTo: string | null;
2716
+ notes: string | null;
2717
+ lastStatusChange: string;
2718
+ }
2719
+ /** The housekeeping board for a property */
2720
+ interface HousekeepingBoard {
2721
+ spaces: HousekeepingBoardEntry[];
2722
+ propertyId: string;
2723
+ updatedAt: string;
2724
+ }
2725
+ /** Parameters for retrieving the housekeeping board */
2726
+ interface GetBoardParams {
2727
+ propertyId?: string;
2728
+ floor?: number;
2729
+ status?: HousekeepingStatus;
2730
+ assignedTo?: string;
2731
+ }
2732
+ /** Input for updating a space's housekeeping status */
2733
+ interface UpdateSpaceStatusInput {
2734
+ status: HousekeepingStatus;
2735
+ notes?: string;
2736
+ assignedTo?: string;
2737
+ priority?: HousekeepingPriority;
2738
+ }
2739
+ /** Type of housekeeping task */
2740
+ type HousekeepingTaskType = "cleaning" | "deep_cleaning" | "turnover" | "inspection" | "maintenance" | "other";
2741
+ /** Status of a housekeeping task */
2742
+ type HousekeepingTaskStatus = "pending" | "in_progress" | "completed" | "cancelled";
2743
+ /** A housekeeping task assigned to a space */
2744
+ interface HousekeepingTask {
2222
2745
  id: string;
2223
- bookingId: string;
2224
- amount: number;
2225
- currency: string;
2226
- status: PaymentStatus;
2227
- provider: PaymentProvider;
2228
- providerTransactionId: string | null;
2229
- paymentMethodId: string | null;
2746
+ spaceId: string;
2747
+ type: HousekeepingTaskType;
2748
+ status: HousekeepingTaskStatus;
2230
2749
  description: string | null;
2750
+ assignedTo: string | null;
2751
+ priority: HousekeepingPriority;
2752
+ dueAt: string | null;
2753
+ notes: string | null;
2231
2754
  metadata: Record<string, unknown> | null;
2232
2755
  createdAt: string;
2233
2756
  updatedAt: string;
2757
+ completedAt: string | null;
2234
2758
  }
2235
- /** Input for processing a payment */
2236
- interface ProcessPaymentInput {
2237
- bookingId: string;
2238
- amount: number;
2239
- currency: string;
2240
- paymentMethodId?: string;
2759
+ /** Input for creating a housekeeping task */
2760
+ interface CreateHousekeepingTaskInput {
2761
+ spaceId: string;
2762
+ type: HousekeepingTaskType;
2241
2763
  description?: string;
2764
+ assignedTo?: string;
2765
+ priority?: HousekeepingPriority;
2766
+ dueAt?: string;
2242
2767
  metadata?: Record<string, unknown>;
2243
2768
  }
2244
- /** Status of a refund */
2245
- type RefundStatus = "succeeded" | "pending" | "failed";
2246
- /** A refund applied to a payment */
2247
- interface Refund {
2248
- id: string;
2249
- paymentId: string;
2250
- amount: number;
2251
- status: RefundStatus;
2252
- reason: string | null;
2253
- createdAt: string;
2769
+ /** Input for updating a housekeeping task */
2770
+ interface UpdateHousekeepingTaskInput {
2771
+ status?: HousekeepingTaskStatus;
2772
+ description?: string;
2773
+ assignedTo?: string;
2774
+ priority?: HousekeepingPriority;
2775
+ dueAt?: string;
2776
+ notes?: string;
2777
+ metadata?: Record<string, unknown>;
2254
2778
  }
2255
- /** Input for refunding a payment */
2256
- interface RefundInput {
2257
- amount?: number;
2258
- reason?: string;
2779
+ /** Parameters for listing housekeeping tasks */
2780
+ interface ListHousekeepingTasksParams {
2781
+ spaceId?: string;
2782
+ status?: HousekeepingTaskStatus;
2783
+ type?: HousekeepingTaskType;
2784
+ assignedTo?: string;
2785
+ priority?: HousekeepingPriority;
2786
+ limit?: number;
2787
+ cursor?: string;
2259
2788
  }
2260
- /** Type of transaction */
2261
- type TransactionType = "payment" | "refund" | "authorization" | "capture";
2262
- /** A financial transaction record */
2263
- interface Transaction {
2264
- id: string;
2265
- type: TransactionType;
2266
- bookingId: string | null;
2267
- amount: number;
2789
+ /** Paginated list of housekeeping tasks */
2790
+ type PaginatedHousekeepingTasks = Paginated<HousekeepingTask>;
2791
+ /** Status of a night audit run */
2792
+ type NightAuditStatus = "pending" | "in_progress" | "completed" | "failed";
2793
+ /** Summary statistics from a night audit run */
2794
+ interface NightAuditSummary {
2795
+ totalChargesPosted: number;
2796
+ totalPaymentsReconciled: number;
2797
+ totalRevenue: number;
2268
2798
  currency: string;
2269
- status: string;
2270
- provider: PaymentProvider;
2271
- providerTransactionId: string | null;
2272
- metadata: Record<string, unknown> | null;
2799
+ discrepancyCount: number;
2800
+ }
2801
+ /** An error that occurred during a night audit run */
2802
+ interface NightAuditError {
2803
+ code: string;
2804
+ message: string;
2805
+ details: Record<string, unknown> | null;
2806
+ }
2807
+ /** A night audit run record */
2808
+ interface NightAuditRun {
2809
+ id: string;
2810
+ propertyId: string;
2811
+ businessDate: string;
2812
+ status: NightAuditStatus;
2813
+ summary: NightAuditSummary | null;
2814
+ startedAt: string;
2815
+ completedAt: string | null;
2816
+ notes: string | null;
2817
+ errors: NightAuditError[];
2818
+ dryRun: boolean;
2273
2819
  createdAt: string;
2274
2820
  }
2275
- /** Parameters for listing transactions */
2276
- interface ListTransactionsParams {
2277
- bookingId?: string;
2278
- status?: string;
2279
- provider?: PaymentProvider;
2280
- type?: TransactionType;
2281
- from?: string;
2282
- to?: string;
2821
+ /** Input for running a night audit */
2822
+ interface RunNightAuditInput {
2823
+ propertyId: string;
2824
+ businessDate?: string;
2825
+ dryRun?: boolean;
2826
+ notes?: string;
2827
+ }
2828
+ /** Parameters for retrieving night audit history */
2829
+ interface GetNightAuditHistoryParams {
2830
+ propertyId?: string;
2831
+ status?: NightAuditStatus;
2832
+ fromDate?: string;
2833
+ toDate?: string;
2283
2834
  limit?: number;
2284
2835
  cursor?: string;
2285
2836
  }
2286
- /** Paginated list of transactions */
2287
- type PaginatedTransactions = Paginated<Transaction>;
2288
- /** Card details for a stored payment method */
2289
- interface CardDetails {
2290
- last4: string;
2291
- brand: string;
2292
- expMonth: number;
2837
+ /** Paginated list of night audit runs */
2838
+ type PaginatedNightAuditRuns = Paginated<NightAuditRun>;
2839
+ /** Revenue breakdown by category */
2840
+ interface NightAuditRevenueBreakdown {
2841
+ category: string;
2842
+ amount: number;
2843
+ count: number;
2844
+ }
2845
+ /** Revenue section of a night audit report */
2846
+ interface NightAuditRevenue {
2847
+ totalRevenue: number;
2848
+ roomRevenue: number;
2849
+ fbRevenue: number;
2850
+ otherRevenue: number;
2851
+ currency: string;
2852
+ breakdown: NightAuditRevenueBreakdown[];
2853
+ }
2854
+ /** Occupancy statistics from a night audit */
2855
+ interface NightAuditOccupancy {
2856
+ totalSpaces: number;
2857
+ occupiedSpaces: number;
2858
+ occupancyRate: number;
2859
+ arrivals: number;
2860
+ departures: number;
2861
+ stayovers: number;
2862
+ noShows: number;
2863
+ }
2864
+ /** Payment method breakdown */
2865
+ interface NightAuditPaymentMethod {
2866
+ method: string;
2867
+ amount: number;
2868
+ count: number;
2869
+ }
2870
+ /** Payments section of a night audit report */
2871
+ interface NightAuditPayments {
2872
+ totalCollected: number;
2873
+ totalPending: number;
2874
+ totalRefunded: number;
2875
+ currency: string;
2876
+ byMethod: NightAuditPaymentMethod[];
2877
+ }
2878
+ /** A discrepancy found during night audit */
2879
+ interface NightAuditDiscrepancy {
2880
+ description: string;
2881
+ amount: number;
2882
+ currency: string;
2883
+ relatedId: string | null;
2884
+ relatedType: string | null;
2885
+ }
2886
+ /** Full night audit report with revenue, occupancy, payments, and discrepancies */
2887
+ interface NightAuditReport {
2888
+ auditId: string;
2889
+ propertyId: string;
2890
+ businessDate: string;
2891
+ revenue: NightAuditRevenue;
2892
+ occupancy: NightAuditOccupancy;
2893
+ payments: NightAuditPayments;
2894
+ discrepancies: NightAuditDiscrepancy[];
2895
+ generatedAt: string;
2896
+ }
2897
+ /** Category of a supply item */
2898
+ type SupplyCategory = "cleaning" | "toiletries" | "linens" | "food" | "beverage" | "maintenance" | "office" | "amenities" | "other";
2899
+ /** Unit of measurement for a supply item */
2900
+ type SupplyUnit = "piece" | "kg" | "liter" | "box" | "case" | "roll" | "pack" | "bottle" | "other";
2901
+ /** Type of stock movement */
2902
+ type MovementType = "received" | "consumed" | "adjustment" | "waste";
2903
+ /** A supply item tracked in inventory */
2904
+ interface SupplyItem {
2905
+ id: string;
2906
+ propertyId: string;
2907
+ name: string;
2908
+ description: string | null;
2909
+ category: SupplyCategory;
2910
+ unit: SupplyUnit;
2911
+ sku: string | null;
2912
+ currentLevel: number;
2913
+ reorderThreshold: number;
2914
+ preferredSupplier: string | null;
2915
+ costPerUnit: number | null;
2916
+ notes: string | null;
2917
+ metadata: Record<string, unknown> | null;
2918
+ createdAt: string;
2919
+ updatedAt: string;
2920
+ deletedAt: string | null;
2921
+ }
2922
+ /** Current stock level for a supply item */
2923
+ interface SupplyLevel {
2924
+ itemId: string;
2925
+ itemName: string;
2926
+ currentLevel: number;
2927
+ reorderThreshold: number;
2928
+ isLowStock: boolean;
2929
+ unit: SupplyUnit;
2930
+ lastMovementAt: string | null;
2931
+ }
2932
+ /** A recorded stock movement */
2933
+ interface SupplyMovement {
2934
+ id: string;
2935
+ itemId: string;
2936
+ itemName: string;
2937
+ type: MovementType;
2938
+ quantity: number;
2939
+ previousLevel: number;
2940
+ newLevel: number;
2941
+ reason: string | null;
2942
+ reference: string | null;
2943
+ performedBy: string | null;
2944
+ notes: string | null;
2945
+ metadata: Record<string, unknown> | null;
2946
+ createdAt: string;
2947
+ }
2948
+ /** Input for creating a supply item */
2949
+ interface CreateSupplyItemInput {
2950
+ propertyId: string;
2951
+ name: string;
2952
+ description?: string;
2953
+ category?: SupplyCategory;
2954
+ unit?: SupplyUnit;
2955
+ sku?: string;
2956
+ reorderThreshold?: number;
2957
+ preferredSupplier?: string;
2958
+ costPerUnit?: number;
2959
+ notes?: string;
2960
+ metadata?: Record<string, unknown>;
2961
+ }
2962
+ /** Input for updating a supply item */
2963
+ interface UpdateSupplyItemInput {
2964
+ name?: string;
2965
+ description?: string;
2966
+ category?: SupplyCategory;
2967
+ unit?: SupplyUnit;
2968
+ sku?: string;
2969
+ reorderThreshold?: number;
2970
+ preferredSupplier?: string;
2971
+ costPerUnit?: number;
2972
+ notes?: string;
2973
+ metadata?: Record<string, unknown>;
2974
+ }
2975
+ /** Parameters for listing supply items */
2976
+ interface ListSupplyItemsParams {
2977
+ propertyId: string;
2978
+ category?: SupplyCategory;
2979
+ search?: string;
2980
+ lowStockOnly?: boolean;
2981
+ limit?: number;
2982
+ cursor?: string;
2983
+ }
2984
+ /** Input for updating a stock level */
2985
+ interface UpdateSupplyLevelInput {
2986
+ currentLevel?: number;
2987
+ reorderThreshold?: number;
2988
+ }
2989
+ /** Parameters for listing supply levels */
2990
+ interface ListSupplyLevelsParams {
2991
+ propertyId: string;
2992
+ category?: SupplyCategory;
2993
+ lowStockOnly?: boolean;
2994
+ limit?: number;
2995
+ cursor?: string;
2996
+ }
2997
+ /** Input for creating a supply movement */
2998
+ interface CreateSupplyMovementInput {
2999
+ itemId: string;
3000
+ type: MovementType;
3001
+ quantity: number;
3002
+ reason?: string;
3003
+ reference?: string;
3004
+ performedBy?: string;
3005
+ notes?: string;
3006
+ metadata?: Record<string, unknown>;
3007
+ }
3008
+ /** Parameters for listing supply movements */
3009
+ interface ListSupplyMovementsParams {
3010
+ propertyId: string;
3011
+ itemId?: string;
3012
+ type?: MovementType;
3013
+ from?: string;
3014
+ to?: string;
3015
+ limit?: number;
3016
+ cursor?: string;
3017
+ }
3018
+ /** Parameters for listing low-stock items */
3019
+ interface ListLowStockParams {
3020
+ propertyId: string;
3021
+ category?: SupplyCategory;
3022
+ limit?: number;
3023
+ cursor?: string;
3024
+ }
3025
+ /** Paginated list of supply items */
3026
+ type PaginatedSupplyItems = Paginated<SupplyItem>;
3027
+ /** Paginated list of supply levels */
3028
+ type PaginatedSupplyLevels = Paginated<SupplyLevel>;
3029
+ /** Paginated list of supply movements */
3030
+ type PaginatedSupplyMovements = Paginated<SupplyMovement>;
3031
+ /** Status of an operational task */
3032
+ type TaskStatus = "open" | "in_progress" | "completed" | "cancelled";
3033
+ /** Priority of an operational task */
3034
+ type TaskPriority = "low" | "medium" | "high" | "urgent";
3035
+ /** A general operational task */
3036
+ interface OperationalTask {
3037
+ id: string;
3038
+ propertyId: string;
3039
+ title: string;
3040
+ description: string | null;
3041
+ status: TaskStatus;
3042
+ priority: TaskPriority;
3043
+ assignedTo: string | null;
3044
+ category: string | null;
3045
+ dueAt: string | null;
3046
+ notes: string | null;
3047
+ metadata: Record<string, unknown> | null;
3048
+ createdAt: string;
3049
+ updatedAt: string;
3050
+ completedAt: string | null;
3051
+ }
3052
+ /** Input for creating an operational task */
3053
+ interface CreateTaskInput {
3054
+ propertyId: string;
3055
+ title: string;
3056
+ description?: string;
3057
+ priority?: TaskPriority;
3058
+ assignedTo?: string;
3059
+ category?: string;
3060
+ dueAt?: string;
3061
+ metadata?: Record<string, unknown>;
3062
+ }
3063
+ /** Input for updating an operational task */
3064
+ interface UpdateTaskInput {
3065
+ title?: string;
3066
+ description?: string;
3067
+ status?: TaskStatus;
3068
+ priority?: TaskPriority;
3069
+ assignedTo?: string;
3070
+ category?: string;
3071
+ dueAt?: string;
3072
+ notes?: string;
3073
+ metadata?: Record<string, unknown>;
3074
+ }
3075
+ /** Parameters for listing operational tasks */
3076
+ interface ListTasksParams {
3077
+ propertyId?: string;
3078
+ status?: TaskStatus;
3079
+ priority?: TaskPriority;
3080
+ assignedTo?: string;
3081
+ category?: string;
3082
+ from?: string;
3083
+ to?: string;
3084
+ limit?: number;
3085
+ cursor?: string;
3086
+ }
3087
+ /** Paginated list of operational tasks */
3088
+ type PaginatedTasks = Paginated<OperationalTask>;
3089
+
3090
+ /**
3091
+ * Service for housekeeping operations in the Atzentis Booking API.
3092
+ *
3093
+ * Provides board retrieval with filtering, space status updates,
3094
+ * and housekeeping task CRUD with assignment and priority tracking.
3095
+ *
3096
+ * @example
3097
+ * ```typescript
3098
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
3099
+ *
3100
+ * // Get the housekeeping board for floor 2
3101
+ * const board = await booking.housekeeping.getBoard({ floor: 2 });
3102
+ *
3103
+ * // Mark a space as clean
3104
+ * await booking.housekeeping.updateSpaceStatus("space_1", {
3105
+ * status: "clean",
3106
+ * notes: "Deep cleaned",
3107
+ * });
3108
+ *
3109
+ * // Create a cleaning task
3110
+ * await booking.housekeeping.createTask({
3111
+ * spaceId: "space_1",
3112
+ * type: "turnover",
3113
+ * priority: "rush",
3114
+ * });
3115
+ * ```
3116
+ */
3117
+ declare class HousekeepingService extends BaseService {
3118
+ protected readonly basePath = "/operations/v1/housekeeping";
3119
+ /** Get the housekeeping board with optional filters */
3120
+ getBoard(params?: GetBoardParams): Promise<HousekeepingBoard>;
3121
+ /** Update the housekeeping status of a space */
3122
+ updateSpaceStatus(spaceId: string, input: UpdateSpaceStatusInput): Promise<HousekeepingBoardEntry>;
3123
+ /** Create a housekeeping task */
3124
+ createTask(input: CreateHousekeepingTaskInput): Promise<HousekeepingTask>;
3125
+ /** List housekeeping tasks with optional filters */
3126
+ listTasks(params?: ListHousekeepingTasksParams): Promise<PaginatedHousekeepingTasks>;
3127
+ /** Update a housekeeping task */
3128
+ updateTask(taskId: string, input: UpdateHousekeepingTaskInput): Promise<HousekeepingTask>;
3129
+ }
3130
+
3131
+ /**
3132
+ * Service for night audit operations in the Atzentis Booking API.
3133
+ *
3134
+ * Supports running night audits (with optional dry-run mode),
3135
+ * retrieving audit history, and generating detailed reports with
3136
+ * revenue, occupancy, payment, and discrepancy breakdowns.
3137
+ *
3138
+ * @example
3139
+ * ```typescript
3140
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
3141
+ *
3142
+ * // Run a night audit
3143
+ * const audit = await booking.nightAudit.run({
3144
+ * propertyId: "prop_abc123",
3145
+ * });
3146
+ *
3147
+ * // Dry-run to preview without committing
3148
+ * const preview = await booking.nightAudit.run({
3149
+ * propertyId: "prop_abc123",
3150
+ * dryRun: true,
3151
+ * });
3152
+ *
3153
+ * // Get the detailed report
3154
+ * const report = await booking.nightAudit.getReport(audit.id);
3155
+ * ```
3156
+ */
3157
+ declare class NightAuditService extends BaseService {
3158
+ protected readonly basePath = "/operations/v1/night-audit";
3159
+ /** Run a night audit for a property */
3160
+ run(input: RunNightAuditInput): Promise<NightAuditRun>;
3161
+ /** Get night audit history with optional filters */
3162
+ getHistory(params?: GetNightAuditHistoryParams): Promise<PaginatedNightAuditRuns>;
3163
+ /** Get the detailed report for a completed night audit */
3164
+ getReport(auditId: string): Promise<NightAuditReport>;
3165
+ }
3166
+
3167
+ /** Supported payment providers */
3168
+ type PaymentProvider = "stripe" | "viva_wallet";
3169
+ /** Status of a payment */
3170
+ type PaymentStatus = "succeeded" | "pending" | "failed" | "requires_action";
3171
+ /** A processed payment */
3172
+ interface Payment {
3173
+ id: string;
3174
+ bookingId: string;
3175
+ amount: number;
3176
+ currency: string;
3177
+ status: PaymentStatus;
3178
+ provider: PaymentProvider;
3179
+ providerTransactionId: string | null;
3180
+ paymentMethodId: string | null;
3181
+ description: string | null;
3182
+ metadata: Record<string, unknown> | null;
3183
+ createdAt: string;
3184
+ updatedAt: string;
3185
+ }
3186
+ /** Input for processing a payment */
3187
+ interface ProcessPaymentInput {
3188
+ bookingId: string;
3189
+ amount: number;
3190
+ currency: string;
3191
+ paymentMethodId?: string;
3192
+ description?: string;
3193
+ metadata?: Record<string, unknown>;
3194
+ }
3195
+ /** Status of a refund */
3196
+ type RefundStatus = "succeeded" | "pending" | "failed";
3197
+ /** A refund applied to a payment */
3198
+ interface Refund {
3199
+ id: string;
3200
+ paymentId: string;
3201
+ amount: number;
3202
+ status: RefundStatus;
3203
+ reason: string | null;
3204
+ createdAt: string;
3205
+ }
3206
+ /** Input for refunding a payment */
3207
+ interface RefundInput {
3208
+ amount?: number;
3209
+ reason?: string;
3210
+ }
3211
+ /** Type of transaction */
3212
+ type TransactionType = "payment" | "refund" | "authorization" | "capture";
3213
+ /** A financial transaction record */
3214
+ interface Transaction {
3215
+ id: string;
3216
+ type: TransactionType;
3217
+ bookingId: string | null;
3218
+ amount: number;
3219
+ currency: string;
3220
+ status: string;
3221
+ provider: PaymentProvider;
3222
+ providerTransactionId: string | null;
3223
+ metadata: Record<string, unknown> | null;
3224
+ createdAt: string;
3225
+ }
3226
+ /** Parameters for listing transactions */
3227
+ interface ListTransactionsParams {
3228
+ bookingId?: string;
3229
+ status?: string;
3230
+ provider?: PaymentProvider;
3231
+ type?: TransactionType;
3232
+ from?: string;
3233
+ to?: string;
3234
+ limit?: number;
3235
+ cursor?: string;
3236
+ }
3237
+ /** Paginated list of transactions */
3238
+ type PaginatedTransactions = Paginated<Transaction>;
3239
+ /** Card details for a stored payment method */
3240
+ interface CardDetails {
3241
+ last4: string;
3242
+ brand: string;
3243
+ expMonth: number;
2293
3244
  expYear: number;
2294
3245
  }
2295
3246
  /** Status of a payment account (stored card) */
@@ -2536,6 +3487,468 @@ declare class PropertiesService extends BaseService {
2536
3487
  delete(propertyId: string): Promise<void>;
2537
3488
  }
2538
3489
 
3490
+ /** Status of a rate plan */
3491
+ type RatePlanStatus = "active" | "inactive";
3492
+ /** A rate plan entity */
3493
+ interface RatePlan {
3494
+ id: string;
3495
+ propertyId: string;
3496
+ categoryId: string;
3497
+ name: string;
3498
+ description: string | null;
3499
+ status: RatePlanStatus;
3500
+ baseRate: number;
3501
+ currency: string;
3502
+ taxInclusive: boolean;
3503
+ metadata: Record<string, unknown> | null;
3504
+ createdAt: string;
3505
+ updatedAt: string;
3506
+ }
3507
+ /** Input for creating a rate plan */
3508
+ interface CreateRatePlanInput {
3509
+ propertyId: string;
3510
+ categoryId: string;
3511
+ name: string;
3512
+ baseRate: number;
3513
+ description?: string;
3514
+ currency?: string;
3515
+ taxInclusive?: boolean;
3516
+ metadata?: Record<string, unknown>;
3517
+ }
3518
+ /** Input for updating a rate plan */
3519
+ interface UpdateRatePlanInput {
3520
+ name?: string;
3521
+ description?: string;
3522
+ baseRate?: number;
3523
+ status?: RatePlanStatus;
3524
+ currency?: string;
3525
+ taxInclusive?: boolean;
3526
+ metadata?: Record<string, unknown>;
3527
+ }
3528
+ /** Parameters for listing rate plans */
3529
+ interface ListRatePlansParams {
3530
+ propertyId?: string;
3531
+ categoryId?: string;
3532
+ status?: RatePlanStatus;
3533
+ limit?: number;
3534
+ cursor?: string;
3535
+ }
3536
+ /** Paginated list of rate plans */
3537
+ type PaginatedRatePlans = Paginated<RatePlan>;
3538
+ /** A rate period with seasonal pricing */
3539
+ interface RatePeriod {
3540
+ id: string;
3541
+ planId: string;
3542
+ name: string;
3543
+ startDate: string;
3544
+ endDate: string;
3545
+ rate: number;
3546
+ adjustmentPercent: number | null;
3547
+ adjustmentAmount: number | null;
3548
+ minStay: number | null;
3549
+ metadata: Record<string, unknown> | null;
3550
+ createdAt: string;
3551
+ updatedAt: string;
3552
+ }
3553
+ /** Input for creating a rate period */
3554
+ interface CreateRatePeriodInput {
3555
+ name: string;
3556
+ startDate: string;
3557
+ endDate: string;
3558
+ rate: number;
3559
+ adjustmentPercent?: number;
3560
+ adjustmentAmount?: number;
3561
+ minStay?: number;
3562
+ metadata?: Record<string, unknown>;
3563
+ }
3564
+ /** Input for updating a rate period */
3565
+ interface UpdateRatePeriodInput {
3566
+ name?: string;
3567
+ startDate?: string;
3568
+ endDate?: string;
3569
+ rate?: number;
3570
+ adjustmentPercent?: number | null;
3571
+ adjustmentAmount?: number | null;
3572
+ minStay?: number | null;
3573
+ metadata?: Record<string, unknown>;
3574
+ }
3575
+ /** Parameters for listing rate periods */
3576
+ interface ListRatePeriodsParams {
3577
+ fromDate?: string;
3578
+ toDate?: string;
3579
+ limit?: number;
3580
+ cursor?: string;
3581
+ }
3582
+ /** Paginated list of rate periods */
3583
+ type PaginatedRatePeriods = Paginated<RatePeriod>;
3584
+ /** Booking restrictions on a rate plan */
3585
+ interface RateRestriction {
3586
+ planId: string;
3587
+ minStay: number | null;
3588
+ maxStay: number | null;
3589
+ closedToArrival: boolean;
3590
+ closedToDeparture: boolean;
3591
+ closeOutDates: string[];
3592
+ advanceBookingMin: number | null;
3593
+ advanceBookingMax: number | null;
3594
+ updatedAt: string;
3595
+ }
3596
+ /** Input for updating rate restrictions */
3597
+ interface UpdateRateRestrictionInput {
3598
+ minStay?: number | null;
3599
+ maxStay?: number | null;
3600
+ closedToArrival?: boolean;
3601
+ closedToDeparture?: boolean;
3602
+ closeOutDates?: string[];
3603
+ advanceBookingMin?: number | null;
3604
+ advanceBookingMax?: number | null;
3605
+ }
3606
+ /** Input for calculating a rate */
3607
+ interface CalculateRateInput {
3608
+ propertyId: string;
3609
+ categoryId: string;
3610
+ checkIn: string;
3611
+ checkOut: string;
3612
+ planId?: string;
3613
+ guests?: number;
3614
+ promoCode?: string;
3615
+ }
3616
+ /** A modifier applied to a nightly rate */
3617
+ interface RateModifier {
3618
+ name: string;
3619
+ type: "percent" | "fixed";
3620
+ value: number;
3621
+ }
3622
+ /** Nightly rate breakdown */
3623
+ interface NightlyRate {
3624
+ date: string;
3625
+ baseRate: number;
3626
+ finalRate: number;
3627
+ modifiers: RateModifier[];
3628
+ }
3629
+ /** An applied restriction with its status */
3630
+ interface AppliedRestriction {
3631
+ type: string;
3632
+ value: string | number | boolean;
3633
+ passed: boolean;
3634
+ message: string | null;
3635
+ }
3636
+ /** Result of a rate calculation */
3637
+ interface RateCalculation {
3638
+ planId: string;
3639
+ planName: string;
3640
+ totalAmount: number;
3641
+ currency: string;
3642
+ nights: number;
3643
+ averageNightlyRate: number;
3644
+ nightlyBreakdown: NightlyRate[];
3645
+ restrictions: AppliedRestriction[];
3646
+ taxAmount: number | null;
3647
+ taxInclusive: boolean;
3648
+ }
3649
+ /** Input for pushing rates to a portfolio */
3650
+ interface PushPortfolioRatesInput {
3651
+ sourcePlanId: string;
3652
+ targetPropertyIds: string[];
3653
+ adjustmentPercent?: number;
3654
+ adjustmentAmount?: number;
3655
+ periodIds?: string[];
3656
+ }
3657
+ /** Result for a single portfolio target property */
3658
+ interface PortfolioTargetResult {
3659
+ propertyId: string;
3660
+ success: boolean;
3661
+ planId: string | null;
3662
+ error: string | null;
3663
+ }
3664
+ /** Result of a portfolio rate push operation */
3665
+ interface PortfolioRatePushResult {
3666
+ sourcePlanId: string;
3667
+ results: PortfolioTargetResult[];
3668
+ totalPushed: number;
3669
+ totalFailed: number;
3670
+ }
3671
+ /** Input for comparing portfolio rates */
3672
+ interface ComparePortfolioRatesInput {
3673
+ portfolioId: string;
3674
+ categoryId: string;
3675
+ checkIn: string;
3676
+ checkOut: string;
3677
+ }
3678
+ /** Rate data for a single property in a portfolio comparison */
3679
+ interface PortfolioPropertyRate {
3680
+ propertyId: string;
3681
+ propertyName: string;
3682
+ planId: string;
3683
+ planName: string;
3684
+ totalAmount: number;
3685
+ averageNightlyRate: number;
3686
+ currency: string;
3687
+ }
3688
+ /** Result of a portfolio rate comparison */
3689
+ interface PortfolioRateComparison {
3690
+ portfolioId: string;
3691
+ categoryId: string;
3692
+ checkIn: string;
3693
+ checkOut: string;
3694
+ properties: PortfolioPropertyRate[];
3695
+ }
3696
+
3697
+ /**
3698
+ * Service for rate plan management in the Atzentis Booking API.
3699
+ *
3700
+ * Provides rate plan CRUD, rate period management with seasonal pricing,
3701
+ * restriction configuration, dynamic price calculation with nightly breakdown,
3702
+ * and portfolio-wide rate push and comparison.
3703
+ *
3704
+ * @example
3705
+ * ```typescript
3706
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
3707
+ *
3708
+ * // Create a rate plan
3709
+ * const plan = await booking.ratePlans.create({
3710
+ * propertyId: "prop_abc123",
3711
+ * categoryId: "cat_std",
3712
+ * name: "Standard Rate",
3713
+ * baseRate: 15000,
3714
+ * });
3715
+ *
3716
+ * // Calculate price for a stay
3717
+ * const price = await booking.ratePlans.calculate({
3718
+ * propertyId: "prop_abc123",
3719
+ * categoryId: "cat_std",
3720
+ * checkIn: "2025-07-01",
3721
+ * checkOut: "2025-07-05",
3722
+ * });
3723
+ * ```
3724
+ */
3725
+ declare class RatePlansService extends BaseService {
3726
+ protected readonly basePath = "/rate/v1";
3727
+ /** List rate plans with optional filters */
3728
+ list(params?: ListRatePlansParams): Promise<PaginatedRatePlans>;
3729
+ /** Get a rate plan by ID */
3730
+ get(planId: string): Promise<RatePlan>;
3731
+ /** Create a new rate plan */
3732
+ create(input: CreateRatePlanInput): Promise<RatePlan>;
3733
+ /** Update a rate plan */
3734
+ update(planId: string, input: UpdateRatePlanInput): Promise<RatePlan>;
3735
+ /** Delete a rate plan */
3736
+ delete(planId: string): Promise<void>;
3737
+ /** List rate periods for a plan */
3738
+ listPeriods(planId: string, params?: ListRatePeriodsParams): Promise<PaginatedRatePeriods>;
3739
+ /** Get a rate period by ID */
3740
+ getPeriod(planId: string, periodId: string): Promise<RatePeriod>;
3741
+ /** Create a rate period */
3742
+ createPeriod(planId: string, input: CreateRatePeriodInput): Promise<RatePeriod>;
3743
+ /** Update a rate period */
3744
+ updatePeriod(planId: string, periodId: string, input: UpdateRatePeriodInput): Promise<RatePeriod>;
3745
+ /** Get restrictions for a rate plan */
3746
+ getRestrictions(planId: string): Promise<RateRestriction>;
3747
+ /** Update restrictions for a rate plan */
3748
+ updateRestrictions(planId: string, input: UpdateRateRestrictionInput): Promise<RateRestriction>;
3749
+ /** Calculate price for a stay */
3750
+ calculate(input: CalculateRateInput): Promise<RateCalculation>;
3751
+ /** Push rates to portfolio properties */
3752
+ pushToPortfolio(input: PushPortfolioRatesInput): Promise<PortfolioRatePushResult>;
3753
+ /** Compare rates across portfolio properties */
3754
+ comparePortfolioRates(input: ComparePortfolioRatesInput): Promise<PortfolioRateComparison>;
3755
+ }
3756
+
3757
+ /** Status of a review */
3758
+ type ReviewStatus = "pending" | "published" | "rejected" | "flagged";
3759
+ /** Action to take when moderating a review */
3760
+ type ModerationAction = "approve" | "reject" | "flag";
3761
+ /** Sort field for reviews */
3762
+ type ReviewSortBy = "createdAt" | "rating" | "updatedAt";
3763
+ /** Channel for sending review requests */
3764
+ type ReviewRequestChannel = "email" | "sms" | "push";
3765
+ /** Status of a review request */
3766
+ type ReviewRequestStatus = "sent" | "scheduled" | "failed";
3767
+ /** Period for analytics aggregation */
3768
+ type AnalyticsPeriod = "day" | "week" | "month" | "year";
3769
+ /** An owner response to a review */
3770
+ interface ReviewResponse {
3771
+ id: string;
3772
+ reviewId: string;
3773
+ content: string;
3774
+ respondedBy: string | null;
3775
+ createdAt: string;
3776
+ updatedAt: string;
3777
+ }
3778
+ /** A trend data point in review analytics */
3779
+ interface ReviewTrend {
3780
+ period: string;
3781
+ startDate: string;
3782
+ endDate: string;
3783
+ averageRating: number;
3784
+ reviewCount: number;
3785
+ }
3786
+ /** A guest review */
3787
+ interface Review {
3788
+ id: string;
3789
+ propertyId: string;
3790
+ guestId: string;
3791
+ bookingId: string | null;
3792
+ rating: number;
3793
+ title: string;
3794
+ content: string;
3795
+ status: ReviewStatus;
3796
+ categories: Record<string, number> | null;
3797
+ language: string | null;
3798
+ response: ReviewResponse | null;
3799
+ moderationNotes: string | null;
3800
+ moderatedAt: string | null;
3801
+ moderatedBy: string | null;
3802
+ metadata: Record<string, unknown> | null;
3803
+ createdAt: string;
3804
+ updatedAt: string;
3805
+ deletedAt: string | null;
3806
+ }
3807
+ /** Aggregated review analytics for a property */
3808
+ interface ReviewAnalytics {
3809
+ propertyId: string;
3810
+ averageRating: number;
3811
+ totalReviews: number;
3812
+ ratingDistribution: Record<string, number>;
3813
+ categoryAverages: Record<string, number>;
3814
+ trends: ReviewTrend[];
3815
+ }
3816
+ /** A review request sent to a guest */
3817
+ interface ReviewRequest {
3818
+ id: string;
3819
+ propertyId: string;
3820
+ guestId: string;
3821
+ bookingId: string;
3822
+ channel: ReviewRequestChannel;
3823
+ status: ReviewRequestStatus;
3824
+ sentAt: string | null;
3825
+ scheduledAt: string | null;
3826
+ createdAt: string;
3827
+ }
3828
+ /** Input for creating a review */
3829
+ interface CreateReviewInput {
3830
+ propertyId: string;
3831
+ guestId: string;
3832
+ rating: number;
3833
+ title: string;
3834
+ content: string;
3835
+ bookingId?: string;
3836
+ categories?: Record<string, number>;
3837
+ language?: string;
3838
+ metadata?: Record<string, unknown>;
3839
+ }
3840
+ /** Input for updating a review */
3841
+ interface UpdateReviewInput {
3842
+ title?: string;
3843
+ content?: string;
3844
+ rating?: number;
3845
+ categories?: Record<string, number>;
3846
+ language?: string;
3847
+ metadata?: Record<string, unknown>;
3848
+ }
3849
+ /** Parameters for listing reviews */
3850
+ interface ListReviewsParams {
3851
+ propertyId: string;
3852
+ status?: ReviewStatus;
3853
+ guestId?: string;
3854
+ bookingId?: string;
3855
+ minRating?: number;
3856
+ maxRating?: number;
3857
+ from?: string;
3858
+ to?: string;
3859
+ sortBy?: ReviewSortBy;
3860
+ sortOrder?: "asc" | "desc";
3861
+ limit?: number;
3862
+ cursor?: string;
3863
+ }
3864
+ /** Input for moderating a review */
3865
+ interface ModerateReviewInput {
3866
+ action: ModerationAction;
3867
+ notes?: string;
3868
+ reason?: string;
3869
+ }
3870
+ /** Input for creating an owner response */
3871
+ interface CreateReviewResponseInput {
3872
+ content: string;
3873
+ respondedBy?: string;
3874
+ }
3875
+ /** Input for updating an owner response */
3876
+ interface UpdateReviewResponseInput {
3877
+ content?: string;
3878
+ }
3879
+ /** Parameters for review analytics */
3880
+ interface ReviewAnalyticsParams {
3881
+ propertyId: string;
3882
+ from?: string;
3883
+ to?: string;
3884
+ period?: AnalyticsPeriod;
3885
+ }
3886
+ /** Input for sending a review request */
3887
+ interface SendReviewRequestInput {
3888
+ propertyId: string;
3889
+ guestId: string;
3890
+ bookingId: string;
3891
+ channel?: ReviewRequestChannel;
3892
+ scheduledAt?: string;
3893
+ templateId?: string;
3894
+ metadata?: Record<string, unknown>;
3895
+ }
3896
+ /** Paginated list of reviews */
3897
+ type PaginatedReviews = Paginated<Review>;
3898
+
3899
+ /**
3900
+ * Service for guest review management in the Atzentis Booking API.
3901
+ *
3902
+ * Provides review CRUD, moderation workflow, owner responses,
3903
+ * analytics, and review request triggering.
3904
+ *
3905
+ * @example
3906
+ * ```typescript
3907
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
3908
+ *
3909
+ * // List published reviews
3910
+ * const reviews = await booking.reviews.listReviews({
3911
+ * propertyId: "prop_1",
3912
+ * status: "published",
3913
+ * sortBy: "rating",
3914
+ * });
3915
+ *
3916
+ * // Moderate a review
3917
+ * await booking.reviews.moderateReview("rev_1", { action: "approve" });
3918
+ *
3919
+ * // Get analytics
3920
+ * const analytics = await booking.reviews.getAnalytics({
3921
+ * propertyId: "prop_1",
3922
+ * period: "month",
3923
+ * });
3924
+ * ```
3925
+ */
3926
+ declare class ReviewsService extends BaseService {
3927
+ protected readonly basePath = "/guest/v1";
3928
+ /** Create a review */
3929
+ createReview(input: CreateReviewInput): Promise<Review>;
3930
+ /** Get a review by ID */
3931
+ getReview(reviewId: string): Promise<Review>;
3932
+ /** List reviews with optional filters */
3933
+ listReviews(params: ListReviewsParams): Promise<PaginatedReviews>;
3934
+ /** Update a review */
3935
+ updateReview(reviewId: string, input: UpdateReviewInput): Promise<Review>;
3936
+ /** Delete a review */
3937
+ deleteReview(reviewId: string): Promise<void>;
3938
+ /** Moderate a review (approve, reject, or flag) */
3939
+ moderateReview(reviewId: string, input: ModerateReviewInput): Promise<Review>;
3940
+ /** Create an owner response to a review */
3941
+ createResponse(reviewId: string, input: CreateReviewResponseInput): Promise<ReviewResponse>;
3942
+ /** Update an owner response */
3943
+ updateResponse(reviewId: string, input: UpdateReviewResponseInput): Promise<ReviewResponse>;
3944
+ /** Delete an owner response */
3945
+ deleteResponse(reviewId: string): Promise<void>;
3946
+ /** Get review analytics for a property */
3947
+ getAnalytics(params: ReviewAnalyticsParams): Promise<ReviewAnalytics>;
3948
+ /** Send a review request to a guest */
3949
+ sendReviewRequest(input: SendReviewRequestInput): Promise<ReviewRequest>;
3950
+ }
3951
+
2539
3952
  /**
2540
3953
  * Service for managing bookable spaces in the Atzentis Booking API.
2541
3954
  *
@@ -2665,6 +4078,239 @@ declare class SpacesService extends BaseService {
2665
4078
  linkPosTable(spaceId: string, input: LinkPosTableInput): Promise<Space>;
2666
4079
  }
2667
4080
 
4081
+ /** Department a staff member belongs to */
4082
+ type StaffDepartment = "front_desk" | "housekeeping" | "maintenance" | "food_beverage" | "management" | "spa" | "security" | "other";
4083
+ /** Role of a staff member */
4084
+ type StaffRole = "manager" | "supervisor" | "staff" | "intern" | "contractor";
4085
+ /** Employment status of a staff member */
4086
+ type StaffStatus = "active" | "inactive" | "on_leave";
4087
+ /** Type of shift */
4088
+ type ShiftType = "morning" | "afternoon" | "evening" | "night" | "custom";
4089
+ /** A staff member entity */
4090
+ interface Staff {
4091
+ id: string;
4092
+ propertyId: string;
4093
+ firstName: string;
4094
+ lastName: string;
4095
+ email: string | null;
4096
+ phone: string | null;
4097
+ department: StaffDepartment;
4098
+ role: StaffRole;
4099
+ status: StaffStatus;
4100
+ hireDate: string | null;
4101
+ notes: string | null;
4102
+ metadata: Record<string, unknown> | null;
4103
+ createdAt: string;
4104
+ updatedAt: string;
4105
+ }
4106
+ /** A staff shift record */
4107
+ interface StaffShift {
4108
+ id: string;
4109
+ staffId: string;
4110
+ propertyId: string;
4111
+ shiftType: ShiftType;
4112
+ startTime: string | null;
4113
+ endTime: string | null;
4114
+ date: string;
4115
+ notes: string | null;
4116
+ metadata: Record<string, unknown> | null;
4117
+ createdAt: string;
4118
+ updatedAt: string;
4119
+ }
4120
+ /** Input for creating a staff member */
4121
+ interface CreateStaffInput {
4122
+ propertyId: string;
4123
+ firstName: string;
4124
+ lastName: string;
4125
+ email?: string;
4126
+ phone?: string;
4127
+ department?: StaffDepartment;
4128
+ role?: StaffRole;
4129
+ status?: StaffStatus;
4130
+ hireDate?: string;
4131
+ notes?: string;
4132
+ metadata?: Record<string, unknown>;
4133
+ }
4134
+ /** Input for updating a staff member */
4135
+ interface UpdateStaffInput {
4136
+ firstName?: string;
4137
+ lastName?: string;
4138
+ email?: string;
4139
+ phone?: string;
4140
+ department?: StaffDepartment;
4141
+ role?: StaffRole;
4142
+ status?: StaffStatus;
4143
+ hireDate?: string;
4144
+ notes?: string;
4145
+ metadata?: Record<string, unknown>;
4146
+ }
4147
+ /** Parameters for listing staff members */
4148
+ interface ListStaffParams {
4149
+ propertyId: string;
4150
+ department?: StaffDepartment | StaffDepartment[];
4151
+ role?: StaffRole | StaffRole[];
4152
+ status?: StaffStatus;
4153
+ search?: string;
4154
+ limit?: number;
4155
+ cursor?: string;
4156
+ }
4157
+ /** Paginated list of staff members */
4158
+ type PaginatedStaff = Paginated<Staff>;
4159
+ /** Input for creating a shift */
4160
+ interface CreateShiftInput {
4161
+ date: string;
4162
+ shiftType: ShiftType;
4163
+ startTime?: string;
4164
+ endTime?: string;
4165
+ notes?: string;
4166
+ metadata?: Record<string, unknown>;
4167
+ }
4168
+ /** Parameters for listing shifts */
4169
+ interface ListShiftsParams {
4170
+ startDate?: string;
4171
+ endDate?: string;
4172
+ shiftType?: ShiftType | ShiftType[];
4173
+ limit?: number;
4174
+ cursor?: string;
4175
+ }
4176
+
4177
+ /**
4178
+ * Service for staff management in the Atzentis Booking API.
4179
+ *
4180
+ * Provides staff CRUD with department and role filtering,
4181
+ * shift management with scheduling support, and multi-value
4182
+ * filter serialization for department and role arrays.
4183
+ *
4184
+ * @example
4185
+ * ```typescript
4186
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
4187
+ *
4188
+ * // Create a staff member
4189
+ * const member = await booking.staff.create({
4190
+ * propertyId: "prop_abc123",
4191
+ * firstName: "Maria",
4192
+ * lastName: "Papadopoulos",
4193
+ * department: "front_desk",
4194
+ * role: "supervisor",
4195
+ * });
4196
+ *
4197
+ * // List housekeeping and maintenance staff
4198
+ * const staff = await booking.staff.list({
4199
+ * propertyId: "prop_abc123",
4200
+ * department: ["housekeeping", "maintenance"],
4201
+ * status: "active",
4202
+ * });
4203
+ *
4204
+ * // Schedule a morning shift
4205
+ * await booking.staff.createShift(member.id, {
4206
+ * date: "2025-07-01",
4207
+ * shiftType: "morning",
4208
+ * });
4209
+ * ```
4210
+ */
4211
+ declare class StaffService extends BaseService {
4212
+ protected readonly basePath = "/operations/v1/staff";
4213
+ /** Create a staff member */
4214
+ create(input: CreateStaffInput): Promise<Staff>;
4215
+ /** Get a staff member by ID */
4216
+ get(staffId: string): Promise<Staff>;
4217
+ /** List staff members with optional filters */
4218
+ list(params: ListStaffParams): Promise<PaginatedStaff>;
4219
+ /** Update a staff member */
4220
+ update(staffId: string, input: UpdateStaffInput): Promise<Staff>;
4221
+ /** Delete a staff member */
4222
+ delete(staffId: string): Promise<void>;
4223
+ /** Create a shift for a staff member */
4224
+ createShift(staffId: string, input: CreateShiftInput): Promise<StaffShift>;
4225
+ /** List shifts for a staff member */
4226
+ listShifts(staffId: string, params?: ListShiftsParams): Promise<StaffShift[]>;
4227
+ }
4228
+
4229
+ /**
4230
+ * Service for supply and inventory management in the Atzentis Booking API.
4231
+ *
4232
+ * Provides item CRUD, stock level tracking, movement recording,
4233
+ * and low-stock alert queries.
4234
+ *
4235
+ * @example
4236
+ * ```typescript
4237
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
4238
+ *
4239
+ * // Create a supply item
4240
+ * const item = await booking.supply.createItem({
4241
+ * propertyId: "prop_1",
4242
+ * name: "Bath Towels",
4243
+ * category: "linens",
4244
+ * unit: "piece",
4245
+ * });
4246
+ *
4247
+ * // Record a stock movement
4248
+ * await booking.supply.createMovement({
4249
+ * itemId: item.id,
4250
+ * type: "received",
4251
+ * quantity: 50,
4252
+ * });
4253
+ *
4254
+ * // Check low-stock items
4255
+ * const lowStock = await booking.supply.listLowStock({ propertyId: "prop_1" });
4256
+ * ```
4257
+ */
4258
+ declare class SupplyService extends BaseService {
4259
+ protected readonly basePath = "/operations/v1";
4260
+ /** Create a supply item */
4261
+ createItem(input: CreateSupplyItemInput): Promise<SupplyItem>;
4262
+ /** Get a supply item by ID */
4263
+ getItem(itemId: string): Promise<SupplyItem>;
4264
+ /** List supply items with optional filters */
4265
+ listItems(params: ListSupplyItemsParams): Promise<PaginatedSupplyItems>;
4266
+ /** Update a supply item */
4267
+ updateItem(itemId: string, input: UpdateSupplyItemInput): Promise<SupplyItem>;
4268
+ /** Delete a supply item */
4269
+ deleteItem(itemId: string): Promise<void>;
4270
+ /** Get the current stock level for a supply item */
4271
+ getLevel(itemId: string): Promise<SupplyLevel>;
4272
+ /** List stock levels with optional filters */
4273
+ listLevels(params: ListSupplyLevelsParams): Promise<PaginatedSupplyLevels>;
4274
+ /** Update a stock level manually */
4275
+ updateLevel(itemId: string, input: UpdateSupplyLevelInput): Promise<SupplyLevel>;
4276
+ /** Record a stock movement */
4277
+ createMovement(input: CreateSupplyMovementInput): Promise<SupplyMovement>;
4278
+ /** List supply movements with optional filters */
4279
+ listMovements(params: ListSupplyMovementsParams): Promise<PaginatedSupplyMovements>;
4280
+ /** List items whose stock is at or below reorder threshold */
4281
+ listLowStock(params: ListLowStockParams): Promise<PaginatedSupplyItems>;
4282
+ }
4283
+
4284
+ /**
4285
+ * Service for general operational tasks in the Atzentis Booking API.
4286
+ *
4287
+ * Provides task creation, listing with filters, and status updates.
4288
+ *
4289
+ * @example
4290
+ * ```typescript
4291
+ * const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
4292
+ *
4293
+ * // Create a task
4294
+ * const task = await booking.tasks.create({
4295
+ * propertyId: "prop_1",
4296
+ * title: "Restock minibar in room 204",
4297
+ * priority: "high",
4298
+ * });
4299
+ *
4300
+ * // Update task status
4301
+ * await booking.tasks.update(task.id, { status: "in_progress" });
4302
+ * ```
4303
+ */
4304
+ declare class TasksService extends BaseService {
4305
+ protected readonly basePath = "/operations/v1/tasks";
4306
+ /** Create an operational task */
4307
+ create(input: CreateTaskInput): Promise<OperationalTask>;
4308
+ /** List operational tasks with optional filters */
4309
+ list(params?: ListTasksParams): Promise<PaginatedTasks>;
4310
+ /** Update an operational task */
4311
+ update(taskId: string, input: UpdateTaskInput): Promise<OperationalTask>;
4312
+ }
4313
+
2668
4314
  /**
2669
4315
  * Main SDK client for the Atzentis Booking API.
2670
4316
  *
@@ -2678,13 +4324,22 @@ declare class BookingClient {
2678
4324
  readonly httpClient: HttpClient;
2679
4325
  private _availability?;
2680
4326
  private _bookings?;
4327
+ private _categories?;
4328
+ private _discounts?;
2681
4329
  private _distribution?;
2682
4330
  private _finance?;
4331
+ private _groups?;
2683
4332
  private _guests?;
4333
+ private _housekeeping?;
4334
+ private _nightAudit?;
2684
4335
  private _payments?;
2685
4336
  private _properties?;
2686
- private _categories?;
4337
+ private _ratePlans?;
4338
+ private _reviews?;
2687
4339
  private _spaces?;
4340
+ private _staff?;
4341
+ private _supply?;
4342
+ private _tasks?;
2688
4343
  constructor(config: BookingClientConfig);
2689
4344
  /** Availability service — lazy-initialized on first access */
2690
4345
  get availability(): AvailabilityService;
@@ -2694,16 +4349,34 @@ declare class BookingClient {
2694
4349
  get distribution(): DistributionService;
2695
4350
  /** Finance service — lazy-initialized on first access */
2696
4351
  get finance(): FinanceService;
4352
+ /** Groups service — lazy-initialized on first access */
4353
+ get groups(): GroupsService;
2697
4354
  /** Guests service — lazy-initialized on first access */
2698
4355
  get guests(): GuestsService;
4356
+ /** Housekeeping service — lazy-initialized on first access */
4357
+ get housekeeping(): HousekeepingService;
4358
+ /** Night audit service — lazy-initialized on first access */
4359
+ get nightAudit(): NightAuditService;
2699
4360
  /** Payments service — lazy-initialized on first access */
2700
4361
  get payments(): PaymentsService;
2701
4362
  /** Properties service — lazy-initialized on first access */
2702
4363
  get properties(): PropertiesService;
4364
+ /** Rate plans service — lazy-initialized on first access */
4365
+ get ratePlans(): RatePlansService;
2703
4366
  /** Categories service — lazy-initialized on first access */
2704
4367
  get categories(): CategoriesService;
4368
+ /** Discounts service — lazy-initialized on first access */
4369
+ get discounts(): DiscountsService;
4370
+ /** Reviews service — lazy-initialized on first access */
4371
+ get reviews(): ReviewsService;
2705
4372
  /** Spaces service — lazy-initialized on first access */
2706
4373
  get spaces(): SpacesService;
4374
+ /** Staff service — lazy-initialized on first access */
4375
+ get staff(): StaffService;
4376
+ /** Supply service — lazy-initialized on first access */
4377
+ get supply(): SupplyService;
4378
+ /** Tasks service — lazy-initialized on first access */
4379
+ get tasks(): TasksService;
2707
4380
  setApiKey(key: string): void;
2708
4381
  setTenantId(id: string): void;
2709
4382
  }
@@ -2786,4 +4459,4 @@ declare function firstPage<T>(fetcher: PageFetcher<T>, options?: PaginationOptio
2786
4459
 
2787
4460
  declare const VERSION = "0.1.0";
2788
4461
 
2789
- export { type AccountingDailyReport, type AccountingReportParams, type AccountingRevenueReport, type AccountingVatReport, type AssignSpaceInput, AuthenticationError, type Authorization, type AuthorizationStatus, type AuthorizeInput, type AvailabilityCheckParams, type AvailabilityPricing, type AvailabilityRestrictions, type AvailabilityResult, type AvailabilitySearchParams, type AvailabilitySearchResult, type AvailabilitySearchResultEntry, AvailabilityService, type AvailableSpace, BOOKING_STATUSES, BOOKING_TYPES, type Booking, BookingClient, type BookingClientConfig, BookingError, type BookingErrorOptions, type BookingGuest, type BookingPricing, type BookingSort, type BookingSpace, type BookingStatus, type BookingType, BookingsService, type BulkUpdateSpaceInput, type CalendarDay, type CalendarParams, type CancelBookingInput, type CaptureInput, type CardDetails, CategoriesService, type Channel, type ChannelCredentials, type ChannelMapping, type ChannelSettings, type ChannelStatus, type ChannelType, type ChargeType, type CheckInInput, type CheckOutInput, ConflictError, type Coordinates, type CreateBookingInput, type CreateCategoryInput, type CreateChannelInput, type CreateChargeInput, type CreateFolioInput, type CreateFolioPaymentInput, type CreateGuestInput, type CreateInvoiceInput, type CreateMappingInput, type CreatePaymentAccountInput, type CreatePropertyInput, type CreateSpaceInput, DEFAULT_MODULES, DistributionService, type DuplicateCandidate, FinanceService, type Folio, type FolioCharge, type FolioPayment, type FolioStatus, ForbiddenError, type Guest, type GuestAddress, type GuestBookingSummary, type GuestDuplicateResult, type GuestFolioSummary, type GuestHistoryParams, type GuestMatch, type GuestOrderSummary, type GuestPreferences, type GuestSearchResult, type GuestSort, GuestsService, HttpClient, type HttpClientOptions, type HttpMethod, type HttpResponse, type ICalExportResult, type ICalImportInput, type ICalImportResult, type Invoice, type InvoiceStatus, type IrisInitiateInput, type IrisTransfer, type IrisTransferStatus, type LinkPosTableInput, type ListBookingsParams, type ListCategoriesParams, type ListChannelsParams, type ListChargesParams, type ListFolioPaymentsParams, type ListFoliosParams, type ListGuestsParams, type ListMappingsParams, type ListPaymentAccountsParams, type ListPropertiesParams, type ListSpacesParams, type ListTransactionsParams, type Logger, type MergeGuestsInput, type MoveChargesInput, type NoShowInput, NotFoundError, PROPERTY_MODULES, type PageFetcher, type Paginated, type PaginatedBookings, type PaginatedChannels, type PaginatedCharges, type PaginatedFolioPayments, type PaginatedFolios, type PaginatedGuestBookings, type PaginatedGuestFolios, type PaginatedGuestOrders, type PaginatedGuests, type PaginatedMappings, type PaginatedPaymentAccounts, type PaginatedSyncLog, type PaginatedTransactions, type PaginationOptions, type Payment, type PaymentAccount, type PaymentAccountStatus, PaymentError, type PaymentProvider, type PaymentStatus, PaymentsService, type PriceRange, type PricingParams, type PricingResult, type ProcessPaymentInput, PropertiesService, type Property, type PropertyAddress, type PropertyModules, type PropertyStatus, type PropertyType, type PullSyncInput, type PushSyncInput, RateLimitError, type Refund, type RefundInput, type RefundStatus, type RequestOptions, type ResolvedBookingClientConfig, type RetryConfig, type RetryOptions, SPACE_STATUSES, SPACE_TYPES, type SearchGuestsParams, ServerError, type ServiceSlotParams, type ServiceTimeSlot, type Space, type SpaceCategory, type SpaceStatus, type SpaceType, SpacesService, type SyncError, type SyncLogParams, type SyncOperation, type SyncOperationStatus, type SyncOperationType, type SyncStats, type TableSlotParams, type TerminalAuthorizeInput, type TerminalTransaction, type TerminalTransactionStatus, type TimeSlot, TimeoutError, type Transaction, type TransactionType, type UpdateBookingInput, type UpdateCategoryInput, type UpdateChannelInput, type UpdateFolioInput, type UpdateGuestInput, type UpdateGuestPreferences, type UpdatePropertyInput, type UpdateSpaceInput, VERSION, ValidationError, type VatBreakdownEntry, bookingClientConfigSchema, createErrorFromResponse, firstPage, paginate };
4462
+ export { type AccountingDailyReport, type AccountingReportParams, type AccountingRevenueReport, type AccountingVatReport, type AnalyticsPeriod, type AppliedRestriction, type ApplyDiscountInput, type AssignSpaceInput, AuthenticationError, type Authorization, type AuthorizationStatus, type AuthorizeInput, type AvailabilityCheckParams, type AvailabilityPricing, type AvailabilityRestrictions, type AvailabilityResult, type AvailabilitySearchParams, type AvailabilitySearchResult, type AvailabilitySearchResultEntry, AvailabilityService, type AvailableSpace, BOOKING_STATUSES, BOOKING_TYPES, type Block, type BlockDate, type Booking, BookingClient, type BookingClientConfig, BookingError, type BookingErrorOptions, type BookingGuest, type BookingPricing, type BookingSort, type BookingSpace, type BookingStatus, type BookingType, BookingsService, type BulkUpdateSpaceInput, type CalculateRateInput, type CalendarDay, type CalendarParams, type CancelBookingInput, type CaptureInput, type CardDetails, CategoriesService, type CategoryPickup, type Channel, type ChannelCredentials, type ChannelMapping, type ChannelSettings, type ChannelStatus, type ChannelType, type ChargeType, type CheckInInput, type CheckOutInput, type ComparePortfolioRatesInput, ConflictError, type Coordinates, type Coupon, type CouponStatus, type CouponValidation, type CreateBlockInput, type CreateBookingInput, type CreateCategoryInput, type CreateChannelInput, type CreateChargeInput, type CreateDiscountRuleInput, type CreateFolioInput, type CreateFolioPaymentInput, type CreateGroupFolioInput, type CreateGroupInput, type CreateGuestInput, type CreateHousekeepingTaskInput, type CreateInvoiceInput, type CreateMappingInput, type CreatePaymentAccountInput, type CreatePropertyInput, type CreateRatePeriodInput, type CreateRatePlanInput, type CreateReviewInput, type CreateReviewResponseInput, type CreateShiftInput, type CreateSpaceInput, type CreateStaffInput, type CreateSupplyItemInput, type CreateSupplyMovementInput, type CreateTaskInput, DEFAULT_MODULES, type DatePickup, type DiscountApplication, type DiscountRedemption, type DiscountRule, type DiscountRuleStatus, type DiscountSortBy, type DiscountType, type DiscountUsage, type DiscountUsageParams, type DiscountValueType, DiscountsService, DistributionService, type DuplicateCandidate, FinanceService, type Folio, type FolioCharge, type FolioPayment, type FolioPostCharge, type FolioPostInput, type FolioPostItem, type FolioPostResult, type FolioStatus, ForbiddenError, type GenerateCouponsInput, type GetBoardParams, type GetNightAuditHistoryParams, type Group, type GroupBlockSummary, type GroupFolioResult, type GroupStatus, type GroupType, GroupsService, type Guest, type GuestAddress, type GuestBookingSummary, type GuestDuplicateResult, type GuestFolioSummary, type GuestHistoryParams, type GuestMatch, type GuestOrderSummary, type GuestPreferences, type GuestSearchResult, type GuestSort, GuestsService, type HousekeepingBoard, type HousekeepingBoardEntry, type HousekeepingPriority, HousekeepingService, type HousekeepingStatus, type HousekeepingTask, type HousekeepingTaskStatus, type HousekeepingTaskType, HttpClient, type HttpClientOptions, type HttpMethod, type HttpResponse, type ICalExportResult, type ICalImportInput, type ICalImportResult, type Invoice, type InvoiceStatus, type IrisInitiateInput, type IrisTransfer, type IrisTransferStatus, type LinkPosTableInput, type ListBookingsParams, type ListCategoriesParams, type ListChannelsParams, type ListChargesParams, type ListDiscountRulesParams, type ListFolioPaymentsParams, type ListFolioPostParams, type ListFoliosParams, type ListGroupsParams, type ListGuestsParams, type ListHousekeepingTasksParams, type ListLowStockParams, type ListMappingsParams, type ListPaymentAccountsParams, type ListPropertiesParams, type ListRatePeriodsParams, type ListRatePlansParams, type ListReviewsParams, type ListShiftsParams, type ListSpacesParams, type ListStaffParams, type ListSupplyItemsParams, type ListSupplyLevelsParams, type ListSupplyMovementsParams, type ListTasksParams, type ListTransactionsParams, type Logger, type MergeGuestsInput, type ModerateReviewInput, type ModerationAction, type MoveChargesInput, type MovementType, type NightAuditDiscrepancy, type NightAuditError, type NightAuditOccupancy, type NightAuditPaymentMethod, type NightAuditPayments, type NightAuditReport, type NightAuditRevenue, type NightAuditRevenueBreakdown, type NightAuditRun, NightAuditService, type NightAuditStatus, type NightAuditSummary, type NightlyRate, type NoShowInput, NotFoundError, type OccupancyStatus, type OperationalTask, PROPERTY_MODULES, type PageFetcher, type Paginated, type PaginatedBookings, type PaginatedChannels, type PaginatedCharges, type PaginatedDiscountRules, type PaginatedFolioPayments, type PaginatedFolioPostCharges, type PaginatedFolios, type PaginatedGroups, type PaginatedGuestBookings, type PaginatedGuestFolios, type PaginatedGuestOrders, type PaginatedGuests, type PaginatedHousekeepingTasks, type PaginatedMappings, type PaginatedNightAuditRuns, type PaginatedPaymentAccounts, type PaginatedRatePeriods, type PaginatedRatePlans, type PaginatedReviews, type PaginatedStaff, type PaginatedSupplyItems, type PaginatedSupplyLevels, type PaginatedSupplyMovements, type PaginatedSyncLog, type PaginatedTasks, type PaginatedTransactions, type PaginationOptions, type Payment, type PaymentAccount, type PaymentAccountStatus, PaymentError, type PaymentProvider, type PaymentStatus, PaymentsService, type Pickup, type PortfolioPropertyRate, type PortfolioRateComparison, type PortfolioRatePushResult, type PortfolioTargetResult, type PriceRange, type PricingParams, type PricingResult, type ProcessPaymentInput, PropertiesService, type Property, type PropertyAddress, type PropertyModules, type PropertyStatus, type PropertyType, type PullSyncInput, type PushPortfolioRatesInput, type PushSyncInput, type RateCalculation, RateLimitError, type RateModifier, type RatePeriod, type RatePlan, type RatePlanStatus, RatePlansService, type RateRestriction, type Refund, type RefundInput, type RefundStatus, type ReleaseBlocksInput, type ReleaseResult, type RequestOptions, type ResolvedBookingClientConfig, type RetryConfig, type RetryOptions, type Review, type ReviewAnalytics, type ReviewAnalyticsParams, type ReviewRequest, type ReviewRequestChannel, type ReviewRequestStatus, type ReviewResponse, type ReviewSortBy, type ReviewStatus, type ReviewTrend, ReviewsService, type RunNightAuditInput, SPACE_STATUSES, SPACE_TYPES, type SearchGuestsParams, type SendReviewRequestInput, ServerError, type ServiceSlotParams, type ServiceTimeSlot, type ShiftType, type Space, type SpaceCategory, type SpaceStatus, type SpaceType, SpacesService, type Staff, type StaffDepartment, type StaffRole, StaffService, type StaffShift, type StaffStatus, type SupplyCategory, type SupplyItem, type SupplyLevel, type SupplyMovement, SupplyService, type SupplyUnit, type SyncError, type SyncLogParams, type SyncOperation, type SyncOperationStatus, type SyncOperationType, type SyncStats, type TableSlotParams, type TaskPriority, type TaskStatus, TasksService, type TerminalAuthorizeInput, type TerminalTransaction, type TerminalTransactionStatus, type TimeSlot, TimeoutError, type Transaction, type TransactionType, type UpdateBookingInput, type UpdateCategoryInput, type UpdateChannelInput, type UpdateDiscountRuleInput, type UpdateFolioInput, type UpdateGroupInput, type UpdateGuestInput, type UpdateGuestPreferences, type UpdateHousekeepingTaskInput, type UpdatePropertyInput, type UpdateRatePeriodInput, type UpdateRatePlanInput, type UpdateRateRestrictionInput, type UpdateReviewInput, type UpdateReviewResponseInput, type UpdateSpaceInput, type UpdateSpaceStatusInput, type UpdateStaffInput, type UpdateSupplyItemInput, type UpdateSupplyLevelInput, type UpdateTaskInput, VERSION, type ValidateCouponInput, ValidationError, type VatBreakdownEntry, bookingClientConfigSchema, createErrorFromResponse, firstPage, paginate };