@atzentis/booking-sdk 0.1.9 → 0.1.11
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.cjs +914 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1975 -50
- package/dist/index.d.ts +1975 -50
- package/dist/index.js +901 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1197,6 +1197,431 @@ declare class CategoriesService extends BaseService {
|
|
|
1197
1197
|
delete(categoryId: string): Promise<void>;
|
|
1198
1198
|
}
|
|
1199
1199
|
|
|
1200
|
+
type ConversationStatus = "active" | "escalated" | "resolved" | "closed";
|
|
1201
|
+
type MessageChannel = "chat" | "email" | "sms" | "whatsapp";
|
|
1202
|
+
type MessageRole = "guest" | "ai" | "staff";
|
|
1203
|
+
type EscalationPriority = "low" | "normal" | "high" | "urgent";
|
|
1204
|
+
type ConversationSortBy = "createdAt" | "updatedAt";
|
|
1205
|
+
interface ConversationMessage {
|
|
1206
|
+
id: string;
|
|
1207
|
+
conversationId: string;
|
|
1208
|
+
role: MessageRole;
|
|
1209
|
+
content: string;
|
|
1210
|
+
channel: MessageChannel;
|
|
1211
|
+
metadata: Record<string, unknown> | null;
|
|
1212
|
+
createdAt: string;
|
|
1213
|
+
}
|
|
1214
|
+
interface ConversationContextProperty {
|
|
1215
|
+
id: string;
|
|
1216
|
+
name: string;
|
|
1217
|
+
type: string;
|
|
1218
|
+
address: string;
|
|
1219
|
+
timezone: string;
|
|
1220
|
+
checkInTime: string;
|
|
1221
|
+
checkOutTime: string;
|
|
1222
|
+
}
|
|
1223
|
+
interface ConversationContextGuest {
|
|
1224
|
+
id: string;
|
|
1225
|
+
firstName: string;
|
|
1226
|
+
lastName: string;
|
|
1227
|
+
email: string;
|
|
1228
|
+
language: string;
|
|
1229
|
+
previousStays: number;
|
|
1230
|
+
}
|
|
1231
|
+
interface ConversationContextBooking {
|
|
1232
|
+
id: string;
|
|
1233
|
+
checkIn: string;
|
|
1234
|
+
checkOut: string;
|
|
1235
|
+
spaceName: string;
|
|
1236
|
+
status: string;
|
|
1237
|
+
}
|
|
1238
|
+
interface ConversationContextFaq {
|
|
1239
|
+
question: string;
|
|
1240
|
+
answer: string;
|
|
1241
|
+
}
|
|
1242
|
+
interface ConversationContext {
|
|
1243
|
+
conversationId: string;
|
|
1244
|
+
property: ConversationContextProperty;
|
|
1245
|
+
guest: ConversationContextGuest;
|
|
1246
|
+
booking: ConversationContextBooking | null;
|
|
1247
|
+
faq: ConversationContextFaq[];
|
|
1248
|
+
customInstructions: string | null;
|
|
1249
|
+
}
|
|
1250
|
+
interface Conversation {
|
|
1251
|
+
id: string;
|
|
1252
|
+
propertyId: string;
|
|
1253
|
+
guestId: string;
|
|
1254
|
+
status: ConversationStatus;
|
|
1255
|
+
channel: MessageChannel;
|
|
1256
|
+
subject: string | null;
|
|
1257
|
+
messages: ConversationMessage[];
|
|
1258
|
+
escalatedAt: string | null;
|
|
1259
|
+
resolvedAt: string | null;
|
|
1260
|
+
assignedTo: string | null;
|
|
1261
|
+
metadata: Record<string, unknown> | null;
|
|
1262
|
+
createdAt: string;
|
|
1263
|
+
updatedAt: string;
|
|
1264
|
+
}
|
|
1265
|
+
interface ConciergeTemplate {
|
|
1266
|
+
id: string;
|
|
1267
|
+
propertyId: string;
|
|
1268
|
+
name: string;
|
|
1269
|
+
content: string;
|
|
1270
|
+
category: string | null;
|
|
1271
|
+
language: string | null;
|
|
1272
|
+
variables: string[];
|
|
1273
|
+
metadata: Record<string, unknown> | null;
|
|
1274
|
+
createdAt: string;
|
|
1275
|
+
updatedAt: string;
|
|
1276
|
+
deletedAt: string | null;
|
|
1277
|
+
}
|
|
1278
|
+
interface SendMessageInput {
|
|
1279
|
+
content: string;
|
|
1280
|
+
role: MessageRole;
|
|
1281
|
+
channel?: MessageChannel;
|
|
1282
|
+
metadata?: Record<string, unknown>;
|
|
1283
|
+
}
|
|
1284
|
+
interface CreateConversationInput {
|
|
1285
|
+
propertyId: string;
|
|
1286
|
+
guestId: string;
|
|
1287
|
+
channel?: MessageChannel;
|
|
1288
|
+
initialMessage?: string;
|
|
1289
|
+
subject?: string;
|
|
1290
|
+
metadata?: Record<string, unknown>;
|
|
1291
|
+
}
|
|
1292
|
+
interface EscalateInput {
|
|
1293
|
+
reason?: string;
|
|
1294
|
+
assignTo?: string;
|
|
1295
|
+
priority?: EscalationPriority;
|
|
1296
|
+
}
|
|
1297
|
+
interface ResolveInput {
|
|
1298
|
+
note?: string;
|
|
1299
|
+
satisfactionRating?: number;
|
|
1300
|
+
}
|
|
1301
|
+
interface CreateTemplateInput {
|
|
1302
|
+
propertyId: string;
|
|
1303
|
+
name: string;
|
|
1304
|
+
content: string;
|
|
1305
|
+
category?: string;
|
|
1306
|
+
language?: string;
|
|
1307
|
+
variables?: string[];
|
|
1308
|
+
metadata?: Record<string, unknown>;
|
|
1309
|
+
}
|
|
1310
|
+
interface UpdateTemplateInput {
|
|
1311
|
+
name?: string;
|
|
1312
|
+
content?: string;
|
|
1313
|
+
category?: string;
|
|
1314
|
+
language?: string;
|
|
1315
|
+
variables?: string[];
|
|
1316
|
+
metadata?: Record<string, unknown>;
|
|
1317
|
+
}
|
|
1318
|
+
interface ListConversationsParams {
|
|
1319
|
+
propertyId: string;
|
|
1320
|
+
guestId?: string;
|
|
1321
|
+
status?: ConversationStatus;
|
|
1322
|
+
channel?: MessageChannel;
|
|
1323
|
+
from?: string;
|
|
1324
|
+
to?: string;
|
|
1325
|
+
sortBy?: ConversationSortBy;
|
|
1326
|
+
sortOrder?: "asc" | "desc";
|
|
1327
|
+
limit?: number;
|
|
1328
|
+
cursor?: string;
|
|
1329
|
+
}
|
|
1330
|
+
interface ListTemplatesParams {
|
|
1331
|
+
propertyId: string;
|
|
1332
|
+
category?: string;
|
|
1333
|
+
language?: string;
|
|
1334
|
+
sortBy?: string;
|
|
1335
|
+
sortOrder?: "asc" | "desc";
|
|
1336
|
+
limit?: number;
|
|
1337
|
+
cursor?: string;
|
|
1338
|
+
}
|
|
1339
|
+
type PaginatedConversations = Paginated<Conversation>;
|
|
1340
|
+
type PaginatedTemplates = Paginated<ConciergeTemplate>;
|
|
1341
|
+
|
|
1342
|
+
/**
|
|
1343
|
+
* Service for AI concierge conversations and response templates in the Atzentis Booking API.
|
|
1344
|
+
*
|
|
1345
|
+
* Provides conversation management, message sending, context retrieval,
|
|
1346
|
+
* escalation/resolution workflows, and template CRUD.
|
|
1347
|
+
*
|
|
1348
|
+
* @example
|
|
1349
|
+
* ```typescript
|
|
1350
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
1351
|
+
*
|
|
1352
|
+
* // Start a new conversation
|
|
1353
|
+
* const conversation = await booking.concierge.createConversation({
|
|
1354
|
+
* propertyId: "prop_1",
|
|
1355
|
+
* guestId: "guest_1",
|
|
1356
|
+
* channel: "chat",
|
|
1357
|
+
* initialMessage: "What time is check-in?",
|
|
1358
|
+
* });
|
|
1359
|
+
*
|
|
1360
|
+
* // Send a follow-up message
|
|
1361
|
+
* await booking.concierge.sendMessage(conversation.id, {
|
|
1362
|
+
* content: "Thank you, I will arrive at 3pm.",
|
|
1363
|
+
* role: "guest",
|
|
1364
|
+
* });
|
|
1365
|
+
*
|
|
1366
|
+
* // Escalate to staff
|
|
1367
|
+
* await booking.concierge.escalate(conversation.id, { priority: "high" });
|
|
1368
|
+
* ```
|
|
1369
|
+
*/
|
|
1370
|
+
declare class ConciergeService extends BaseService {
|
|
1371
|
+
protected readonly basePath = "/concierge/v1";
|
|
1372
|
+
/** Create a new guest conversation */
|
|
1373
|
+
createConversation(input: CreateConversationInput): Promise<Conversation>;
|
|
1374
|
+
/** Get a conversation by ID */
|
|
1375
|
+
getConversation(conversationId: string): Promise<Conversation>;
|
|
1376
|
+
/** List conversations with optional filters */
|
|
1377
|
+
listConversations(params: ListConversationsParams): Promise<PaginatedConversations>;
|
|
1378
|
+
/** Send a message in a conversation */
|
|
1379
|
+
sendMessage(conversationId: string, input: SendMessageInput): Promise<ConversationMessage>;
|
|
1380
|
+
/** Get the full context for a conversation (property, guest, booking, FAQ) */
|
|
1381
|
+
getContext(conversationId: string): Promise<ConversationContext>;
|
|
1382
|
+
/** Escalate a conversation to staff */
|
|
1383
|
+
escalate(conversationId: string, input?: EscalateInput): Promise<Conversation>;
|
|
1384
|
+
/** Resolve a conversation */
|
|
1385
|
+
resolve(conversationId: string, input?: ResolveInput): Promise<Conversation>;
|
|
1386
|
+
/** Create a response template */
|
|
1387
|
+
createTemplate(input: CreateTemplateInput): Promise<ConciergeTemplate>;
|
|
1388
|
+
/** Get a template by ID */
|
|
1389
|
+
getTemplate(templateId: string): Promise<ConciergeTemplate>;
|
|
1390
|
+
/** List templates with optional filters */
|
|
1391
|
+
listTemplates(params: ListTemplatesParams): Promise<PaginatedTemplates>;
|
|
1392
|
+
/** Update a template */
|
|
1393
|
+
updateTemplate(templateId: string, input: UpdateTemplateInput): Promise<ConciergeTemplate>;
|
|
1394
|
+
/** Delete a template */
|
|
1395
|
+
deleteTemplate(templateId: string): Promise<void>;
|
|
1396
|
+
}
|
|
1397
|
+
|
|
1398
|
+
/** Type of discount rule */
|
|
1399
|
+
type DiscountType = "coupon" | "early_bird" | "seasonal" | "last_minute";
|
|
1400
|
+
/** How the discount value is applied */
|
|
1401
|
+
type DiscountValueType = "percentage" | "fixed";
|
|
1402
|
+
/** Status of a discount rule */
|
|
1403
|
+
type DiscountRuleStatus = "active" | "expired" | "exhausted" | "disabled";
|
|
1404
|
+
/** Status of a coupon code */
|
|
1405
|
+
type CouponStatus = "active" | "redeemed" | "expired" | "disabled";
|
|
1406
|
+
/** Sort field for discount rules */
|
|
1407
|
+
type DiscountSortBy = "createdAt" | "name" | "value" | "redemptionCount";
|
|
1408
|
+
/** A discount rule defining eligibility and value */
|
|
1409
|
+
interface DiscountRule {
|
|
1410
|
+
id: string;
|
|
1411
|
+
propertyId: string;
|
|
1412
|
+
name: string;
|
|
1413
|
+
description: string | null;
|
|
1414
|
+
type: DiscountType;
|
|
1415
|
+
valueType: DiscountValueType;
|
|
1416
|
+
value: number;
|
|
1417
|
+
spaceTypes: string[] | null;
|
|
1418
|
+
minNights: number | null;
|
|
1419
|
+
maxNights: number | null;
|
|
1420
|
+
validFrom: string | null;
|
|
1421
|
+
validTo: string | null;
|
|
1422
|
+
bookingFrom: string | null;
|
|
1423
|
+
bookingTo: string | null;
|
|
1424
|
+
maxRedemptions: number | null;
|
|
1425
|
+
maxRedemptionsPerGuest: number | null;
|
|
1426
|
+
minBookingValue: number | null;
|
|
1427
|
+
stackable: boolean;
|
|
1428
|
+
enabled: boolean;
|
|
1429
|
+
status: DiscountRuleStatus;
|
|
1430
|
+
redemptionCount: number;
|
|
1431
|
+
totalDiscountAmount: number;
|
|
1432
|
+
metadata: Record<string, unknown> | null;
|
|
1433
|
+
createdAt: string;
|
|
1434
|
+
updatedAt: string;
|
|
1435
|
+
deletedAt: string | null;
|
|
1436
|
+
}
|
|
1437
|
+
/** A coupon code generated from a discount rule */
|
|
1438
|
+
interface Coupon {
|
|
1439
|
+
id: string;
|
|
1440
|
+
ruleId: string;
|
|
1441
|
+
code: string;
|
|
1442
|
+
status: CouponStatus;
|
|
1443
|
+
maxRedemptions: number | null;
|
|
1444
|
+
redemptionCount: number;
|
|
1445
|
+
expiresAt: string | null;
|
|
1446
|
+
createdAt: string;
|
|
1447
|
+
}
|
|
1448
|
+
/** Result of validating a coupon code */
|
|
1449
|
+
interface CouponValidation {
|
|
1450
|
+
valid: boolean;
|
|
1451
|
+
coupon: Coupon | null;
|
|
1452
|
+
rule: DiscountRule | null;
|
|
1453
|
+
discountAmount: number;
|
|
1454
|
+
finalPrice: number;
|
|
1455
|
+
reason: string | null;
|
|
1456
|
+
}
|
|
1457
|
+
/** Record of a discount being applied to a booking */
|
|
1458
|
+
interface DiscountApplication {
|
|
1459
|
+
id: string;
|
|
1460
|
+
bookingId: string;
|
|
1461
|
+
ruleId: string;
|
|
1462
|
+
couponId: string | null;
|
|
1463
|
+
code: string | null;
|
|
1464
|
+
discountAmount: number;
|
|
1465
|
+
originalPrice: number;
|
|
1466
|
+
finalPrice: number;
|
|
1467
|
+
appliedAt: string;
|
|
1468
|
+
}
|
|
1469
|
+
/** A single redemption record */
|
|
1470
|
+
interface DiscountRedemption {
|
|
1471
|
+
id: string;
|
|
1472
|
+
bookingId: string;
|
|
1473
|
+
guestId: string;
|
|
1474
|
+
couponId: string | null;
|
|
1475
|
+
code: string | null;
|
|
1476
|
+
discountAmount: number;
|
|
1477
|
+
redeemedAt: string;
|
|
1478
|
+
}
|
|
1479
|
+
/** Usage statistics and redemption history for a discount rule */
|
|
1480
|
+
interface DiscountUsage {
|
|
1481
|
+
ruleId: string;
|
|
1482
|
+
totalRedemptions: number;
|
|
1483
|
+
totalDiscountAmount: number;
|
|
1484
|
+
averageDiscountAmount: number;
|
|
1485
|
+
redemptions: DiscountRedemption[];
|
|
1486
|
+
cursor: string | null;
|
|
1487
|
+
hasMore: boolean;
|
|
1488
|
+
}
|
|
1489
|
+
/** Input for creating a discount rule */
|
|
1490
|
+
interface CreateDiscountRuleInput {
|
|
1491
|
+
propertyId: string;
|
|
1492
|
+
name: string;
|
|
1493
|
+
type: DiscountType;
|
|
1494
|
+
valueType: DiscountValueType;
|
|
1495
|
+
value: number;
|
|
1496
|
+
description?: string;
|
|
1497
|
+
spaceTypes?: string[];
|
|
1498
|
+
minNights?: number;
|
|
1499
|
+
maxNights?: number;
|
|
1500
|
+
validFrom?: string;
|
|
1501
|
+
validTo?: string;
|
|
1502
|
+
bookingFrom?: string;
|
|
1503
|
+
bookingTo?: string;
|
|
1504
|
+
maxRedemptions?: number;
|
|
1505
|
+
maxRedemptionsPerGuest?: number;
|
|
1506
|
+
minBookingValue?: number;
|
|
1507
|
+
stackable?: boolean;
|
|
1508
|
+
enabled?: boolean;
|
|
1509
|
+
metadata?: Record<string, unknown>;
|
|
1510
|
+
}
|
|
1511
|
+
/** Input for updating a discount rule */
|
|
1512
|
+
interface UpdateDiscountRuleInput {
|
|
1513
|
+
name?: string;
|
|
1514
|
+
description?: string;
|
|
1515
|
+
value?: number;
|
|
1516
|
+
validFrom?: string;
|
|
1517
|
+
validTo?: string;
|
|
1518
|
+
bookingFrom?: string;
|
|
1519
|
+
bookingTo?: string;
|
|
1520
|
+
maxRedemptions?: number;
|
|
1521
|
+
maxRedemptionsPerGuest?: number;
|
|
1522
|
+
minBookingValue?: number;
|
|
1523
|
+
stackable?: boolean;
|
|
1524
|
+
enabled?: boolean;
|
|
1525
|
+
metadata?: Record<string, unknown>;
|
|
1526
|
+
}
|
|
1527
|
+
/** Parameters for listing discount rules */
|
|
1528
|
+
interface ListDiscountRulesParams {
|
|
1529
|
+
propertyId: string;
|
|
1530
|
+
type?: DiscountType;
|
|
1531
|
+
status?: DiscountRuleStatus;
|
|
1532
|
+
enabled?: boolean;
|
|
1533
|
+
validOn?: string;
|
|
1534
|
+
sortBy?: DiscountSortBy;
|
|
1535
|
+
sortOrder?: "asc" | "desc";
|
|
1536
|
+
limit?: number;
|
|
1537
|
+
cursor?: string;
|
|
1538
|
+
}
|
|
1539
|
+
/** Input for generating coupons from a discount rule */
|
|
1540
|
+
interface GenerateCouponsInput {
|
|
1541
|
+
count?: number;
|
|
1542
|
+
prefix?: string;
|
|
1543
|
+
code?: string;
|
|
1544
|
+
expiresAt?: string;
|
|
1545
|
+
maxRedemptions?: number;
|
|
1546
|
+
}
|
|
1547
|
+
/** Input for validating a coupon code */
|
|
1548
|
+
interface ValidateCouponInput {
|
|
1549
|
+
code: string;
|
|
1550
|
+
propertyId: string;
|
|
1551
|
+
bookingValue: number;
|
|
1552
|
+
checkIn?: string;
|
|
1553
|
+
checkOut?: string;
|
|
1554
|
+
spaceType?: string;
|
|
1555
|
+
guestId?: string;
|
|
1556
|
+
}
|
|
1557
|
+
/** Input for applying a discount to a booking */
|
|
1558
|
+
interface ApplyDiscountInput {
|
|
1559
|
+
bookingId: string;
|
|
1560
|
+
code: string;
|
|
1561
|
+
guestId?: string;
|
|
1562
|
+
}
|
|
1563
|
+
/** Parameters for querying discount usage */
|
|
1564
|
+
interface DiscountUsageParams {
|
|
1565
|
+
from?: string;
|
|
1566
|
+
to?: string;
|
|
1567
|
+
limit?: number;
|
|
1568
|
+
cursor?: string;
|
|
1569
|
+
}
|
|
1570
|
+
/** Paginated list of discount rules */
|
|
1571
|
+
type PaginatedDiscountRules = Paginated<DiscountRule>;
|
|
1572
|
+
|
|
1573
|
+
/**
|
|
1574
|
+
* Service for discount and coupon management in the Atzentis Booking API.
|
|
1575
|
+
*
|
|
1576
|
+
* Provides discount rule CRUD, coupon generation and validation,
|
|
1577
|
+
* discount application, and usage tracking.
|
|
1578
|
+
*
|
|
1579
|
+
* @example
|
|
1580
|
+
* ```typescript
|
|
1581
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
1582
|
+
*
|
|
1583
|
+
* // Create a discount rule
|
|
1584
|
+
* const rule = await booking.discounts.createRule({
|
|
1585
|
+
* propertyId: "prop_1",
|
|
1586
|
+
* name: "Early Bird 15%",
|
|
1587
|
+
* type: "early_bird",
|
|
1588
|
+
* valueType: "percentage",
|
|
1589
|
+
* value: 15,
|
|
1590
|
+
* });
|
|
1591
|
+
*
|
|
1592
|
+
* // Generate coupon codes
|
|
1593
|
+
* const coupons = await booking.discounts.generateCoupons(rule.id, { count: 10 });
|
|
1594
|
+
*
|
|
1595
|
+
* // Validate a coupon
|
|
1596
|
+
* const result = await booking.discounts.validateCoupon({
|
|
1597
|
+
* code: coupons[0].code,
|
|
1598
|
+
* propertyId: "prop_1",
|
|
1599
|
+
* bookingValue: 500,
|
|
1600
|
+
* });
|
|
1601
|
+
* ```
|
|
1602
|
+
*/
|
|
1603
|
+
declare class DiscountsService extends BaseService {
|
|
1604
|
+
protected readonly basePath = "/guest/v1";
|
|
1605
|
+
/** Create a discount rule */
|
|
1606
|
+
createRule(input: CreateDiscountRuleInput): Promise<DiscountRule>;
|
|
1607
|
+
/** Get a discount rule by ID */
|
|
1608
|
+
getRule(ruleId: string): Promise<DiscountRule>;
|
|
1609
|
+
/** List discount rules with optional filters */
|
|
1610
|
+
listRules(params: ListDiscountRulesParams): Promise<PaginatedDiscountRules>;
|
|
1611
|
+
/** Update a discount rule */
|
|
1612
|
+
updateRule(ruleId: string, input: UpdateDiscountRuleInput): Promise<DiscountRule>;
|
|
1613
|
+
/** Delete a discount rule */
|
|
1614
|
+
deleteRule(ruleId: string): Promise<void>;
|
|
1615
|
+
/** Generate coupon codes for a discount rule */
|
|
1616
|
+
generateCoupons(ruleId: string, input?: GenerateCouponsInput): Promise<Coupon[]>;
|
|
1617
|
+
/** Validate a coupon code against booking context */
|
|
1618
|
+
validateCoupon(input: ValidateCouponInput): Promise<CouponValidation>;
|
|
1619
|
+
/** Apply a discount to a booking */
|
|
1620
|
+
applyDiscount(input: ApplyDiscountInput): Promise<DiscountApplication>;
|
|
1621
|
+
/** Get usage statistics and redemption history for a discount rule */
|
|
1622
|
+
getUsage(ruleId: string, params?: DiscountUsageParams): Promise<DiscountUsage>;
|
|
1623
|
+
}
|
|
1624
|
+
|
|
1200
1625
|
/** Supported distribution channel types */
|
|
1201
1626
|
type ChannelType = "channex" | "ical" | "direct";
|
|
1202
1627
|
/** Channel connection status */
|
|
@@ -1692,6 +2117,142 @@ declare class FinanceService extends BaseService {
|
|
|
1692
2117
|
listFolioPostCharges(folioId: string, params?: ListFolioPostParams): Promise<PaginatedFolioPostCharges>;
|
|
1693
2118
|
}
|
|
1694
2119
|
|
|
2120
|
+
type MyDataInvoiceType = "income" | "expense" | "credit_note";
|
|
2121
|
+
type MyDataSubmissionStatus = "pending" | "accepted" | "rejected";
|
|
2122
|
+
type QrCodeFormat = "png" | "svg";
|
|
2123
|
+
type TseClosureStatus = "completed" | "failed";
|
|
2124
|
+
type TseExportFormat = "json" | "csv";
|
|
2125
|
+
interface MyDataStatus {
|
|
2126
|
+
active: boolean;
|
|
2127
|
+
lastSyncAt: string | null;
|
|
2128
|
+
configuredAt: string | null;
|
|
2129
|
+
issueCount: number;
|
|
2130
|
+
issues: string[];
|
|
2131
|
+
}
|
|
2132
|
+
interface MyDataSubmission {
|
|
2133
|
+
id: string;
|
|
2134
|
+
invoiceId: string;
|
|
2135
|
+
type: MyDataInvoiceType;
|
|
2136
|
+
status: MyDataSubmissionStatus;
|
|
2137
|
+
mark: string | null;
|
|
2138
|
+
submittedAt: string;
|
|
2139
|
+
errors: string[];
|
|
2140
|
+
}
|
|
2141
|
+
interface MyDataQrResult {
|
|
2142
|
+
transactionId: string;
|
|
2143
|
+
qrCode: string;
|
|
2144
|
+
format: QrCodeFormat;
|
|
2145
|
+
generatedAt: string;
|
|
2146
|
+
}
|
|
2147
|
+
interface TseStatus {
|
|
2148
|
+
active: boolean;
|
|
2149
|
+
deviceSerial: string | null;
|
|
2150
|
+
certificateExpiry: string | null;
|
|
2151
|
+
transactionCount: number;
|
|
2152
|
+
lastTransactionAt: string | null;
|
|
2153
|
+
issues: string[];
|
|
2154
|
+
}
|
|
2155
|
+
interface TseTransaction {
|
|
2156
|
+
id: string;
|
|
2157
|
+
transactionNumber: number;
|
|
2158
|
+
amount: number;
|
|
2159
|
+
type: string;
|
|
2160
|
+
signature: string;
|
|
2161
|
+
createdAt: string;
|
|
2162
|
+
}
|
|
2163
|
+
interface TseDayClosure {
|
|
2164
|
+
id: string;
|
|
2165
|
+
date: string;
|
|
2166
|
+
transactionCount: number;
|
|
2167
|
+
status: TseClosureStatus;
|
|
2168
|
+
closedAt: string | null;
|
|
2169
|
+
error: string | null;
|
|
2170
|
+
}
|
|
2171
|
+
interface TseExport {
|
|
2172
|
+
data: string;
|
|
2173
|
+
format: TseExportFormat;
|
|
2174
|
+
from: string;
|
|
2175
|
+
to: string;
|
|
2176
|
+
recordCount: number;
|
|
2177
|
+
generatedAt: string;
|
|
2178
|
+
}
|
|
2179
|
+
interface SubmitMyDataInput {
|
|
2180
|
+
invoiceId: string;
|
|
2181
|
+
type: MyDataInvoiceType;
|
|
2182
|
+
}
|
|
2183
|
+
interface ListMyDataSubmissionsParams {
|
|
2184
|
+
status?: MyDataSubmissionStatus;
|
|
2185
|
+
from?: string;
|
|
2186
|
+
to?: string;
|
|
2187
|
+
limit?: number;
|
|
2188
|
+
cursor?: string;
|
|
2189
|
+
}
|
|
2190
|
+
interface ListTseTransactionsParams {
|
|
2191
|
+
from?: string;
|
|
2192
|
+
to?: string;
|
|
2193
|
+
limit?: number;
|
|
2194
|
+
cursor?: string;
|
|
2195
|
+
}
|
|
2196
|
+
interface TseDayClosureInput {
|
|
2197
|
+
date?: string;
|
|
2198
|
+
}
|
|
2199
|
+
interface TseExportParams {
|
|
2200
|
+
from: string;
|
|
2201
|
+
to: string;
|
|
2202
|
+
format?: TseExportFormat;
|
|
2203
|
+
}
|
|
2204
|
+
type PaginatedMyDataSubmissions = Paginated<MyDataSubmission>;
|
|
2205
|
+
type PaginatedTseTransactions = Paginated<TseTransaction>;
|
|
2206
|
+
|
|
2207
|
+
/**
|
|
2208
|
+
* Service for fiscal compliance integrations in the Atzentis Booking API.
|
|
2209
|
+
*
|
|
2210
|
+
* Provides myDATA (Greek AADE) submission management and TSE (German KassenSichV)
|
|
2211
|
+
* transaction signing, day closures, and DSFinV-K exports.
|
|
2212
|
+
*
|
|
2213
|
+
* @example
|
|
2214
|
+
* ```typescript
|
|
2215
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
2216
|
+
*
|
|
2217
|
+
* // Submit an invoice to myDATA
|
|
2218
|
+
* const submission = await booking.fiscal.submitMyData({
|
|
2219
|
+
* invoiceId: "inv_1",
|
|
2220
|
+
* type: "income",
|
|
2221
|
+
* });
|
|
2222
|
+
*
|
|
2223
|
+
* // Trigger a TSE day closure
|
|
2224
|
+
* const closure = await booking.fiscal.tseDayClosure({ date: "2024-12-31" });
|
|
2225
|
+
*
|
|
2226
|
+
* // Export DSFinV-K data
|
|
2227
|
+
* const exported = await booking.fiscal.tseExportDsfinvk({
|
|
2228
|
+
* from: "2024-01-01",
|
|
2229
|
+
* to: "2024-12-31",
|
|
2230
|
+
* format: "json",
|
|
2231
|
+
* });
|
|
2232
|
+
* ```
|
|
2233
|
+
*/
|
|
2234
|
+
declare class FiscalService extends BaseService {
|
|
2235
|
+
protected readonly basePath = "/fiscal/v1";
|
|
2236
|
+
/** Get the current myDATA integration status */
|
|
2237
|
+
getMyDataStatus(): Promise<MyDataStatus>;
|
|
2238
|
+
/** Submit an invoice to the Greek AADE myDATA platform */
|
|
2239
|
+
submitMyData(input: SubmitMyDataInput): Promise<MyDataSubmission>;
|
|
2240
|
+
/** List myDATA submissions with optional filters */
|
|
2241
|
+
listMyDataSubmissions(params?: ListMyDataSubmissionsParams): Promise<PaginatedMyDataSubmissions>;
|
|
2242
|
+
/** Get a single myDATA submission by ID */
|
|
2243
|
+
getMyDataSubmission(submissionId: string): Promise<MyDataSubmission>;
|
|
2244
|
+
/** Generate a QR code for a myDATA transaction */
|
|
2245
|
+
getMyDataQr(transactionId: string): Promise<MyDataQrResult>;
|
|
2246
|
+
/** Get the current TSE device status */
|
|
2247
|
+
getTseStatus(): Promise<TseStatus>;
|
|
2248
|
+
/** List TSE transactions with optional filters */
|
|
2249
|
+
listTseTransactions(params?: ListTseTransactionsParams): Promise<PaginatedTseTransactions>;
|
|
2250
|
+
/** Trigger a TSE day closure */
|
|
2251
|
+
tseDayClosure(input?: TseDayClosureInput): Promise<TseDayClosure>;
|
|
2252
|
+
/** Export DSFinV-K data for a date range */
|
|
2253
|
+
tseExportDsfinvk(params: TseExportParams): Promise<TseExport>;
|
|
2254
|
+
}
|
|
2255
|
+
|
|
1695
2256
|
/** Type of group booking */
|
|
1696
2257
|
type GroupType = "wedding" | "conference" | "corporate" | "tour" | "other";
|
|
1697
2258
|
/** Status of a group booking */
|
|
@@ -2667,54 +3228,489 @@ interface NightAuditReport {
|
|
|
2667
3228
|
discrepancies: NightAuditDiscrepancy[];
|
|
2668
3229
|
generatedAt: string;
|
|
2669
3230
|
}
|
|
2670
|
-
|
|
2671
|
-
|
|
2672
|
-
|
|
2673
|
-
|
|
2674
|
-
|
|
2675
|
-
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
3231
|
+
/** Category of a supply item */
|
|
3232
|
+
type SupplyCategory = "cleaning" | "toiletries" | "linens" | "food" | "beverage" | "maintenance" | "office" | "amenities" | "other";
|
|
3233
|
+
/** Unit of measurement for a supply item */
|
|
3234
|
+
type SupplyUnit = "piece" | "kg" | "liter" | "box" | "case" | "roll" | "pack" | "bottle" | "other";
|
|
3235
|
+
/** Type of stock movement */
|
|
3236
|
+
type MovementType = "received" | "consumed" | "adjustment" | "waste";
|
|
3237
|
+
/** A supply item tracked in inventory */
|
|
3238
|
+
interface SupplyItem {
|
|
3239
|
+
id: string;
|
|
3240
|
+
propertyId: string;
|
|
3241
|
+
name: string;
|
|
3242
|
+
description: string | null;
|
|
3243
|
+
category: SupplyCategory;
|
|
3244
|
+
unit: SupplyUnit;
|
|
3245
|
+
sku: string | null;
|
|
3246
|
+
currentLevel: number;
|
|
3247
|
+
reorderThreshold: number;
|
|
3248
|
+
preferredSupplier: string | null;
|
|
3249
|
+
costPerUnit: number | null;
|
|
3250
|
+
notes: string | null;
|
|
3251
|
+
metadata: Record<string, unknown> | null;
|
|
3252
|
+
createdAt: string;
|
|
3253
|
+
updatedAt: string;
|
|
3254
|
+
deletedAt: string | null;
|
|
3255
|
+
}
|
|
3256
|
+
/** Current stock level for a supply item */
|
|
3257
|
+
interface SupplyLevel {
|
|
3258
|
+
itemId: string;
|
|
3259
|
+
itemName: string;
|
|
3260
|
+
currentLevel: number;
|
|
3261
|
+
reorderThreshold: number;
|
|
3262
|
+
isLowStock: boolean;
|
|
3263
|
+
unit: SupplyUnit;
|
|
3264
|
+
lastMovementAt: string | null;
|
|
3265
|
+
}
|
|
3266
|
+
/** A recorded stock movement */
|
|
3267
|
+
interface SupplyMovement {
|
|
3268
|
+
id: string;
|
|
3269
|
+
itemId: string;
|
|
3270
|
+
itemName: string;
|
|
3271
|
+
type: MovementType;
|
|
3272
|
+
quantity: number;
|
|
3273
|
+
previousLevel: number;
|
|
3274
|
+
newLevel: number;
|
|
3275
|
+
reason: string | null;
|
|
3276
|
+
reference: string | null;
|
|
3277
|
+
performedBy: string | null;
|
|
3278
|
+
notes: string | null;
|
|
3279
|
+
metadata: Record<string, unknown> | null;
|
|
3280
|
+
createdAt: string;
|
|
3281
|
+
}
|
|
3282
|
+
/** Input for creating a supply item */
|
|
3283
|
+
interface CreateSupplyItemInput {
|
|
3284
|
+
propertyId: string;
|
|
3285
|
+
name: string;
|
|
3286
|
+
description?: string;
|
|
3287
|
+
category?: SupplyCategory;
|
|
3288
|
+
unit?: SupplyUnit;
|
|
3289
|
+
sku?: string;
|
|
3290
|
+
reorderThreshold?: number;
|
|
3291
|
+
preferredSupplier?: string;
|
|
3292
|
+
costPerUnit?: number;
|
|
3293
|
+
notes?: string;
|
|
3294
|
+
metadata?: Record<string, unknown>;
|
|
3295
|
+
}
|
|
3296
|
+
/** Input for updating a supply item */
|
|
3297
|
+
interface UpdateSupplyItemInput {
|
|
3298
|
+
name?: string;
|
|
3299
|
+
description?: string;
|
|
3300
|
+
category?: SupplyCategory;
|
|
3301
|
+
unit?: SupplyUnit;
|
|
3302
|
+
sku?: string;
|
|
3303
|
+
reorderThreshold?: number;
|
|
3304
|
+
preferredSupplier?: string;
|
|
3305
|
+
costPerUnit?: number;
|
|
3306
|
+
notes?: string;
|
|
3307
|
+
metadata?: Record<string, unknown>;
|
|
3308
|
+
}
|
|
3309
|
+
/** Parameters for listing supply items */
|
|
3310
|
+
interface ListSupplyItemsParams {
|
|
3311
|
+
propertyId: string;
|
|
3312
|
+
category?: SupplyCategory;
|
|
3313
|
+
search?: string;
|
|
3314
|
+
lowStockOnly?: boolean;
|
|
3315
|
+
limit?: number;
|
|
3316
|
+
cursor?: string;
|
|
3317
|
+
}
|
|
3318
|
+
/** Input for updating a stock level */
|
|
3319
|
+
interface UpdateSupplyLevelInput {
|
|
3320
|
+
currentLevel?: number;
|
|
3321
|
+
reorderThreshold?: number;
|
|
3322
|
+
}
|
|
3323
|
+
/** Parameters for listing supply levels */
|
|
3324
|
+
interface ListSupplyLevelsParams {
|
|
3325
|
+
propertyId: string;
|
|
3326
|
+
category?: SupplyCategory;
|
|
3327
|
+
lowStockOnly?: boolean;
|
|
3328
|
+
limit?: number;
|
|
3329
|
+
cursor?: string;
|
|
3330
|
+
}
|
|
3331
|
+
/** Input for creating a supply movement */
|
|
3332
|
+
interface CreateSupplyMovementInput {
|
|
3333
|
+
itemId: string;
|
|
3334
|
+
type: MovementType;
|
|
3335
|
+
quantity: number;
|
|
3336
|
+
reason?: string;
|
|
3337
|
+
reference?: string;
|
|
3338
|
+
performedBy?: string;
|
|
3339
|
+
notes?: string;
|
|
3340
|
+
metadata?: Record<string, unknown>;
|
|
3341
|
+
}
|
|
3342
|
+
/** Parameters for listing supply movements */
|
|
3343
|
+
interface ListSupplyMovementsParams {
|
|
3344
|
+
propertyId: string;
|
|
3345
|
+
itemId?: string;
|
|
3346
|
+
type?: MovementType;
|
|
3347
|
+
from?: string;
|
|
3348
|
+
to?: string;
|
|
3349
|
+
limit?: number;
|
|
3350
|
+
cursor?: string;
|
|
3351
|
+
}
|
|
3352
|
+
/** Parameters for listing low-stock items */
|
|
3353
|
+
interface ListLowStockParams {
|
|
3354
|
+
propertyId: string;
|
|
3355
|
+
category?: SupplyCategory;
|
|
3356
|
+
limit?: number;
|
|
3357
|
+
cursor?: string;
|
|
3358
|
+
}
|
|
3359
|
+
/** Paginated list of supply items */
|
|
3360
|
+
type PaginatedSupplyItems = Paginated<SupplyItem>;
|
|
3361
|
+
/** Paginated list of supply levels */
|
|
3362
|
+
type PaginatedSupplyLevels = Paginated<SupplyLevel>;
|
|
3363
|
+
/** Paginated list of supply movements */
|
|
3364
|
+
type PaginatedSupplyMovements = Paginated<SupplyMovement>;
|
|
3365
|
+
/** Status of an operational task */
|
|
3366
|
+
type TaskStatus = "open" | "in_progress" | "completed" | "cancelled";
|
|
3367
|
+
/** Priority of an operational task */
|
|
3368
|
+
type TaskPriority = "low" | "medium" | "high" | "urgent";
|
|
3369
|
+
/** A general operational task */
|
|
3370
|
+
interface OperationalTask {
|
|
3371
|
+
id: string;
|
|
3372
|
+
propertyId: string;
|
|
3373
|
+
title: string;
|
|
3374
|
+
description: string | null;
|
|
3375
|
+
status: TaskStatus;
|
|
3376
|
+
priority: TaskPriority;
|
|
3377
|
+
assignedTo: string | null;
|
|
3378
|
+
category: string | null;
|
|
3379
|
+
dueAt: string | null;
|
|
3380
|
+
notes: string | null;
|
|
3381
|
+
metadata: Record<string, unknown> | null;
|
|
3382
|
+
createdAt: string;
|
|
3383
|
+
updatedAt: string;
|
|
3384
|
+
completedAt: string | null;
|
|
3385
|
+
}
|
|
3386
|
+
/** Input for creating an operational task */
|
|
3387
|
+
interface CreateTaskInput {
|
|
3388
|
+
propertyId: string;
|
|
3389
|
+
title: string;
|
|
3390
|
+
description?: string;
|
|
3391
|
+
priority?: TaskPriority;
|
|
3392
|
+
assignedTo?: string;
|
|
3393
|
+
category?: string;
|
|
3394
|
+
dueAt?: string;
|
|
3395
|
+
metadata?: Record<string, unknown>;
|
|
3396
|
+
}
|
|
3397
|
+
/** Input for updating an operational task */
|
|
3398
|
+
interface UpdateTaskInput {
|
|
3399
|
+
title?: string;
|
|
3400
|
+
description?: string;
|
|
3401
|
+
status?: TaskStatus;
|
|
3402
|
+
priority?: TaskPriority;
|
|
3403
|
+
assignedTo?: string;
|
|
3404
|
+
category?: string;
|
|
3405
|
+
dueAt?: string;
|
|
3406
|
+
notes?: string;
|
|
3407
|
+
metadata?: Record<string, unknown>;
|
|
3408
|
+
}
|
|
3409
|
+
/** Parameters for listing operational tasks */
|
|
3410
|
+
interface ListTasksParams {
|
|
3411
|
+
propertyId?: string;
|
|
3412
|
+
status?: TaskStatus;
|
|
3413
|
+
priority?: TaskPriority;
|
|
3414
|
+
assignedTo?: string;
|
|
3415
|
+
category?: string;
|
|
3416
|
+
from?: string;
|
|
3417
|
+
to?: string;
|
|
3418
|
+
limit?: number;
|
|
3419
|
+
cursor?: string;
|
|
3420
|
+
}
|
|
3421
|
+
/** Paginated list of operational tasks */
|
|
3422
|
+
type PaginatedTasks = Paginated<OperationalTask>;
|
|
3423
|
+
/** Status of a portfolio */
|
|
3424
|
+
type PortfolioStatus = "active" | "archived";
|
|
3425
|
+
/** Search type for portfolio searches */
|
|
3426
|
+
type PortfolioSearchType = "guest" | "booking" | "all";
|
|
3427
|
+
/** A portfolio grouping multiple properties */
|
|
3428
|
+
interface Portfolio {
|
|
3429
|
+
id: string;
|
|
3430
|
+
name: string;
|
|
3431
|
+
description: string | null;
|
|
3432
|
+
propertyCount: number;
|
|
3433
|
+
status: PortfolioStatus;
|
|
3434
|
+
metadata: Record<string, unknown> | null;
|
|
3435
|
+
createdAt: string;
|
|
3436
|
+
updatedAt: string;
|
|
3437
|
+
}
|
|
3438
|
+
/** A property entry within a portfolio */
|
|
3439
|
+
interface PortfolioProperty {
|
|
3440
|
+
propertyId: string;
|
|
3441
|
+
propertyName: string;
|
|
3442
|
+
addedAt: string;
|
|
3443
|
+
}
|
|
3444
|
+
/** A portfolio with its associated properties */
|
|
3445
|
+
interface PortfolioWithProperties extends Portfolio {
|
|
3446
|
+
properties: PortfolioProperty[];
|
|
3447
|
+
}
|
|
3448
|
+
/** Performance metrics for a single property within a portfolio */
|
|
3449
|
+
interface PortfolioPropertyMetrics {
|
|
3450
|
+
propertyId: string;
|
|
3451
|
+
propertyName: string;
|
|
3452
|
+
bookings: number;
|
|
3453
|
+
occupancyRate: number;
|
|
3454
|
+
revenue: number;
|
|
3455
|
+
}
|
|
3456
|
+
/** Dashboard summary data for a portfolio */
|
|
3457
|
+
interface PortfolioDashboardData {
|
|
3458
|
+
portfolioId: string;
|
|
3459
|
+
propertyCount: number;
|
|
3460
|
+
totalBookings: number;
|
|
3461
|
+
totalOccupancy: number;
|
|
3462
|
+
averageOccupancyRate: number;
|
|
3463
|
+
properties: PortfolioPropertyMetrics[];
|
|
3464
|
+
period: {
|
|
3465
|
+
from: string;
|
|
3466
|
+
to: string;
|
|
3467
|
+
};
|
|
3468
|
+
}
|
|
3469
|
+
/** A single result from a portfolio search */
|
|
3470
|
+
interface PortfolioSearchResult {
|
|
3471
|
+
type: PortfolioSearchType;
|
|
3472
|
+
id: string;
|
|
3473
|
+
propertyId: string;
|
|
3474
|
+
propertyName: string;
|
|
3475
|
+
summary: string;
|
|
3476
|
+
matchedFields: string[];
|
|
3477
|
+
}
|
|
3478
|
+
/** Paginated response from a portfolio search */
|
|
3479
|
+
interface PortfolioSearchResponse {
|
|
3480
|
+
results: PortfolioSearchResult[];
|
|
3481
|
+
totalCount: number;
|
|
3482
|
+
cursor: string | null;
|
|
3483
|
+
hasMore: boolean;
|
|
3484
|
+
}
|
|
3485
|
+
/** Input for creating a portfolio */
|
|
3486
|
+
interface CreatePortfolioInput {
|
|
3487
|
+
name: string;
|
|
3488
|
+
description?: string;
|
|
3489
|
+
metadata?: Record<string, unknown>;
|
|
3490
|
+
}
|
|
3491
|
+
/** Input for updating a portfolio */
|
|
3492
|
+
interface UpdatePortfolioInput {
|
|
3493
|
+
name?: string;
|
|
3494
|
+
description?: string;
|
|
3495
|
+
metadata?: Record<string, unknown>;
|
|
3496
|
+
}
|
|
3497
|
+
/** Input for adding a property to a portfolio */
|
|
3498
|
+
interface AddPortfolioPropertyInput {
|
|
3499
|
+
propertyId: string;
|
|
3500
|
+
}
|
|
3501
|
+
/** Parameters for listing portfolios */
|
|
3502
|
+
interface ListPortfoliosParams {
|
|
3503
|
+
limit?: number;
|
|
3504
|
+
cursor?: string;
|
|
3505
|
+
search?: string;
|
|
3506
|
+
}
|
|
3507
|
+
/** Parameters for retrieving a portfolio dashboard */
|
|
3508
|
+
interface GetPortfolioDashboardDataParams {
|
|
3509
|
+
from?: string;
|
|
3510
|
+
to?: string;
|
|
3511
|
+
}
|
|
3512
|
+
/** Parameters for searching within a portfolio */
|
|
3513
|
+
interface PortfolioSearchParams {
|
|
3514
|
+
query: string;
|
|
3515
|
+
type?: PortfolioSearchType;
|
|
3516
|
+
limit?: number;
|
|
3517
|
+
cursor?: string;
|
|
3518
|
+
}
|
|
3519
|
+
/** Paginated list of portfolios */
|
|
3520
|
+
type PaginatedPortfolios = Paginated<Portfolio>;
|
|
3521
|
+
|
|
3522
|
+
/**
|
|
3523
|
+
* Service for housekeeping operations in the Atzentis Booking API.
|
|
3524
|
+
*
|
|
3525
|
+
* Provides board retrieval with filtering, space status updates,
|
|
3526
|
+
* and housekeeping task CRUD with assignment and priority tracking.
|
|
3527
|
+
*
|
|
3528
|
+
* @example
|
|
3529
|
+
* ```typescript
|
|
3530
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
3531
|
+
*
|
|
3532
|
+
* // Get the housekeeping board for floor 2
|
|
3533
|
+
* const board = await booking.housekeeping.getBoard({ floor: 2 });
|
|
3534
|
+
*
|
|
3535
|
+
* // Mark a space as clean
|
|
3536
|
+
* await booking.housekeeping.updateSpaceStatus("space_1", {
|
|
3537
|
+
* status: "clean",
|
|
3538
|
+
* notes: "Deep cleaned",
|
|
3539
|
+
* });
|
|
3540
|
+
*
|
|
3541
|
+
* // Create a cleaning task
|
|
3542
|
+
* await booking.housekeeping.createTask({
|
|
3543
|
+
* spaceId: "space_1",
|
|
3544
|
+
* type: "turnover",
|
|
3545
|
+
* priority: "rush",
|
|
3546
|
+
* });
|
|
3547
|
+
* ```
|
|
3548
|
+
*/
|
|
3549
|
+
declare class HousekeepingService extends BaseService {
|
|
3550
|
+
protected readonly basePath = "/operations/v1/housekeeping";
|
|
3551
|
+
/** Get the housekeeping board with optional filters */
|
|
3552
|
+
getBoard(params?: GetBoardParams): Promise<HousekeepingBoard>;
|
|
3553
|
+
/** Update the housekeeping status of a space */
|
|
3554
|
+
updateSpaceStatus(spaceId: string, input: UpdateSpaceStatusInput): Promise<HousekeepingBoardEntry>;
|
|
3555
|
+
/** Create a housekeeping task */
|
|
3556
|
+
createTask(input: CreateHousekeepingTaskInput): Promise<HousekeepingTask>;
|
|
3557
|
+
/** List housekeeping tasks with optional filters */
|
|
3558
|
+
listTasks(params?: ListHousekeepingTasksParams): Promise<PaginatedHousekeepingTasks>;
|
|
3559
|
+
/** Update a housekeeping task */
|
|
3560
|
+
updateTask(taskId: string, input: UpdateHousekeepingTaskInput): Promise<HousekeepingTask>;
|
|
3561
|
+
}
|
|
3562
|
+
|
|
3563
|
+
type DocumentType = "passport" | "national_id" | "driving_license";
|
|
3564
|
+
type ScanStatus = "processing" | "completed" | "failed";
|
|
3565
|
+
interface OcrResult {
|
|
3566
|
+
firstName?: string;
|
|
3567
|
+
lastName?: string;
|
|
3568
|
+
dateOfBirth?: string;
|
|
3569
|
+
nationality?: string;
|
|
3570
|
+
documentNumber?: string;
|
|
3571
|
+
expiryDate?: string;
|
|
3572
|
+
}
|
|
3573
|
+
interface IdScan {
|
|
3574
|
+
id: string;
|
|
3575
|
+
guestId: string;
|
|
3576
|
+
type: DocumentType;
|
|
3577
|
+
status: ScanStatus;
|
|
3578
|
+
result: OcrResult | null;
|
|
3579
|
+
error: string | null;
|
|
3580
|
+
createdAt: string;
|
|
3581
|
+
updatedAt: string;
|
|
3582
|
+
}
|
|
3583
|
+
interface UploadScanInput {
|
|
3584
|
+
guestId: string;
|
|
3585
|
+
file: Blob | File | ArrayBuffer;
|
|
3586
|
+
type: DocumentType;
|
|
3587
|
+
}
|
|
3588
|
+
interface ListScansParams {
|
|
3589
|
+
guestId: string;
|
|
3590
|
+
status?: ScanStatus;
|
|
3591
|
+
limit?: number;
|
|
3592
|
+
cursor?: string;
|
|
3593
|
+
}
|
|
3594
|
+
type PaginatedIdScans = Paginated<IdScan>;
|
|
3595
|
+
|
|
3596
|
+
/**
|
|
3597
|
+
* Service for ID document scanning in the Atzentis Booking API.
|
|
3598
|
+
*
|
|
3599
|
+
* Provides document upload with OCR processing, result retrieval,
|
|
3600
|
+
* and scan history listing for guest identity verification.
|
|
3601
|
+
*
|
|
3602
|
+
* @example
|
|
3603
|
+
* ```typescript
|
|
3604
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
3605
|
+
*
|
|
3606
|
+
* // Upload a passport for OCR
|
|
3607
|
+
* const scan = await booking.idScanning.upload({
|
|
3608
|
+
* guestId: "guest_1",
|
|
3609
|
+
* file: passportImageBlob,
|
|
3610
|
+
* type: "passport",
|
|
3611
|
+
* });
|
|
3612
|
+
*
|
|
3613
|
+
* // Poll for the OCR result
|
|
3614
|
+
* const result = await booking.idScanning.getResult(scan.id);
|
|
3615
|
+
*
|
|
3616
|
+
* // List all scans for a guest
|
|
3617
|
+
* const scans = await booking.idScanning.list({ guestId: "guest_1" });
|
|
3618
|
+
* ```
|
|
3619
|
+
*/
|
|
3620
|
+
declare class IdScanningService extends BaseService {
|
|
3621
|
+
protected readonly basePath = "/guest/v1/id-scans";
|
|
3622
|
+
/** Upload a document image for OCR processing */
|
|
3623
|
+
upload(input: UploadScanInput): Promise<IdScan>;
|
|
3624
|
+
/** Get the OCR result for a scan by ID */
|
|
3625
|
+
getResult(scanId: string): Promise<IdScan>;
|
|
3626
|
+
/** List ID scans with optional filters */
|
|
3627
|
+
list(params: ListScansParams): Promise<PaginatedIdScans>;
|
|
3628
|
+
}
|
|
3629
|
+
|
|
3630
|
+
type IntelligenceEventType = "pos_order" | "reservation" | "survey_response" | "review" | "complaint" | "preference_signal";
|
|
3631
|
+
type IntelligenceEventStatus = "pending" | "processed";
|
|
3632
|
+
interface GuestTag {
|
|
3633
|
+
name: string;
|
|
3634
|
+
score: number;
|
|
3635
|
+
category?: string;
|
|
3636
|
+
}
|
|
3637
|
+
interface GuestIntelligence {
|
|
3638
|
+
guestId: string;
|
|
3639
|
+
tags: GuestTag[];
|
|
3640
|
+
score: number;
|
|
3641
|
+
totalSpend: number;
|
|
3642
|
+
totalVisits: number;
|
|
3643
|
+
lastVisitAt: string | null;
|
|
3644
|
+
avgSpendPerVisit: number;
|
|
3645
|
+
}
|
|
3646
|
+
interface IntelligenceEvent {
|
|
3647
|
+
id: string;
|
|
3648
|
+
guestId: string;
|
|
3649
|
+
type: IntelligenceEventType;
|
|
3650
|
+
data: Record<string, unknown>;
|
|
3651
|
+
status: IntelligenceEventStatus;
|
|
3652
|
+
processedAt: string | null;
|
|
3653
|
+
createdAt: string;
|
|
3654
|
+
}
|
|
3655
|
+
interface IngestEventInput {
|
|
3656
|
+
guestId: string;
|
|
3657
|
+
type: IntelligenceEventType;
|
|
3658
|
+
data: Record<string, unknown>;
|
|
3659
|
+
}
|
|
3660
|
+
interface ListIntelligenceEventsParams {
|
|
3661
|
+
guestId: string;
|
|
3662
|
+
status?: IntelligenceEventStatus;
|
|
3663
|
+
type?: IntelligenceEventType;
|
|
3664
|
+
limit?: number;
|
|
3665
|
+
cursor?: string;
|
|
3666
|
+
}
|
|
3667
|
+
type PaginatedIntelligenceEvents = Paginated<IntelligenceEvent>;
|
|
3668
|
+
|
|
3669
|
+
/**
|
|
3670
|
+
* Service for guest intelligence in the Atzentis Booking API.
|
|
3671
|
+
*
|
|
3672
|
+
* Provides access to AI-computed guest profiles, tag scores, and
|
|
3673
|
+
* event ingestion for feeding the intelligence pipeline.
|
|
3674
|
+
*
|
|
3675
|
+
* @example
|
|
3676
|
+
* ```typescript
|
|
3677
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
3678
|
+
*
|
|
3679
|
+
* // Get a guest's intelligence profile
|
|
3680
|
+
* const profile = await booking.intelligence.getProfile("guest_1");
|
|
3681
|
+
*
|
|
3682
|
+
* // Ingest a POS order event
|
|
3683
|
+
* await booking.intelligence.ingestEvent({
|
|
3684
|
+
* guestId: "guest_1",
|
|
3685
|
+
* type: "pos_order",
|
|
3686
|
+
* data: { amount: 85.50, items: ["cocktail", "tapas"] },
|
|
3687
|
+
* });
|
|
3688
|
+
*
|
|
3689
|
+
* // List unprocessed events for a guest
|
|
3690
|
+
* const events = await booking.intelligence.listEvents({
|
|
3691
|
+
* guestId: "guest_1",
|
|
3692
|
+
* status: "pending",
|
|
3693
|
+
* });
|
|
3694
|
+
* ```
|
|
3695
|
+
*/
|
|
3696
|
+
declare class IntelligenceService extends BaseService {
|
|
3697
|
+
protected readonly basePath = "/guest/v1";
|
|
3698
|
+
/** Get the intelligence profile for a guest */
|
|
3699
|
+
getProfile(guestId: string): Promise<GuestIntelligence>;
|
|
3700
|
+
/** Trigger a refresh of the intelligence profile for a guest */
|
|
3701
|
+
refresh(guestId: string): Promise<GuestIntelligence>;
|
|
3702
|
+
/** Ingest a guest intelligence event for processing */
|
|
3703
|
+
ingestEvent(input: IngestEventInput): Promise<IntelligenceEvent>;
|
|
3704
|
+
/** List intelligence events for a guest with optional filters */
|
|
3705
|
+
listEvents(params: ListIntelligenceEventsParams): Promise<PaginatedIntelligenceEvents>;
|
|
3706
|
+
}
|
|
3707
|
+
|
|
3708
|
+
/**
|
|
3709
|
+
* Service for night audit operations in the Atzentis Booking API.
|
|
3710
|
+
*
|
|
3711
|
+
* Supports running night audits (with optional dry-run mode),
|
|
3712
|
+
* retrieving audit history, and generating detailed reports with
|
|
3713
|
+
* revenue, occupancy, payment, and discrepancy breakdowns.
|
|
2718
3714
|
*
|
|
2719
3715
|
* @example
|
|
2720
3716
|
* ```typescript
|
|
@@ -2745,6 +3741,165 @@ declare class NightAuditService extends BaseService {
|
|
|
2745
3741
|
getReport(auditId: string): Promise<NightAuditReport>;
|
|
2746
3742
|
}
|
|
2747
3743
|
|
|
3744
|
+
type WebhookEventType = "booking.created" | "booking.updated" | "booking.cancelled" | "guest.created" | "guest.updated" | "payment.completed" | "payment.failed" | "review.created" | "review.moderated";
|
|
3745
|
+
type WebhookDeliveryStatus = "success" | "failed" | "pending";
|
|
3746
|
+
interface WebhookSubscription {
|
|
3747
|
+
id: string;
|
|
3748
|
+
url: string;
|
|
3749
|
+
events: WebhookEventType[];
|
|
3750
|
+
secret: string;
|
|
3751
|
+
description: string | null;
|
|
3752
|
+
active: boolean;
|
|
3753
|
+
createdAt: string;
|
|
3754
|
+
updatedAt: string;
|
|
3755
|
+
}
|
|
3756
|
+
interface WebhookDelivery {
|
|
3757
|
+
id: string;
|
|
3758
|
+
subscriptionId: string;
|
|
3759
|
+
event: WebhookEventType;
|
|
3760
|
+
status: WebhookDeliveryStatus;
|
|
3761
|
+
httpStatus: number | null;
|
|
3762
|
+
attempts: number;
|
|
3763
|
+
lastAttemptAt: string | null;
|
|
3764
|
+
nextRetryAt: string | null;
|
|
3765
|
+
payload: Record<string, unknown>;
|
|
3766
|
+
}
|
|
3767
|
+
interface CreateWebhookSubscriptionInput {
|
|
3768
|
+
url: string;
|
|
3769
|
+
events: WebhookEventType[];
|
|
3770
|
+
description?: string;
|
|
3771
|
+
active?: boolean;
|
|
3772
|
+
}
|
|
3773
|
+
interface UpdateWebhookSubscriptionInput {
|
|
3774
|
+
url?: string;
|
|
3775
|
+
events?: WebhookEventType[];
|
|
3776
|
+
description?: string;
|
|
3777
|
+
active?: boolean;
|
|
3778
|
+
}
|
|
3779
|
+
interface ListWebhookSubscriptionsParams {
|
|
3780
|
+
active?: boolean;
|
|
3781
|
+
limit?: number;
|
|
3782
|
+
cursor?: string;
|
|
3783
|
+
}
|
|
3784
|
+
interface ListWebhookDeliveriesParams {
|
|
3785
|
+
subscriptionId?: string;
|
|
3786
|
+
status?: WebhookDeliveryStatus;
|
|
3787
|
+
from?: string;
|
|
3788
|
+
to?: string;
|
|
3789
|
+
limit?: number;
|
|
3790
|
+
cursor?: string;
|
|
3791
|
+
}
|
|
3792
|
+
type PaginatedWebhookSubscriptions = Paginated<WebhookSubscription>;
|
|
3793
|
+
type PaginatedWebhookDeliveries = Paginated<WebhookDelivery>;
|
|
3794
|
+
interface PropertyModule {
|
|
3795
|
+
name: string;
|
|
3796
|
+
enabled: boolean;
|
|
3797
|
+
configuredAt: string | null;
|
|
3798
|
+
}
|
|
3799
|
+
interface PropertySettings {
|
|
3800
|
+
propertyId: string;
|
|
3801
|
+
timezone: string;
|
|
3802
|
+
currency: string;
|
|
3803
|
+
defaultLanguage: string;
|
|
3804
|
+
modules: PropertyModule[];
|
|
3805
|
+
checkInTime: string;
|
|
3806
|
+
checkOutTime: string;
|
|
3807
|
+
metadata: Record<string, unknown> | null;
|
|
3808
|
+
updatedAt: string;
|
|
3809
|
+
}
|
|
3810
|
+
interface MyDataSettings {
|
|
3811
|
+
enabled: boolean;
|
|
3812
|
+
vatNumber: string | null;
|
|
3813
|
+
branchCode: string | null;
|
|
3814
|
+
autoSubmit: boolean;
|
|
3815
|
+
}
|
|
3816
|
+
interface TseSettings {
|
|
3817
|
+
enabled: boolean;
|
|
3818
|
+
deviceSerial: string | null;
|
|
3819
|
+
autoClose: boolean;
|
|
3820
|
+
}
|
|
3821
|
+
interface FiscalSettings {
|
|
3822
|
+
propertyId: string;
|
|
3823
|
+
mydata: MyDataSettings;
|
|
3824
|
+
tse: TseSettings;
|
|
3825
|
+
updatedAt: string;
|
|
3826
|
+
}
|
|
3827
|
+
interface UpdatePropertySettingsInput {
|
|
3828
|
+
timezone?: string;
|
|
3829
|
+
currency?: string;
|
|
3830
|
+
defaultLanguage?: string;
|
|
3831
|
+
checkInTime?: string;
|
|
3832
|
+
checkOutTime?: string;
|
|
3833
|
+
metadata?: Record<string, unknown>;
|
|
3834
|
+
}
|
|
3835
|
+
interface UpdateFiscalSettingsInput {
|
|
3836
|
+
mydata?: Partial<MyDataSettings>;
|
|
3837
|
+
tse?: Partial<TseSettings>;
|
|
3838
|
+
}
|
|
3839
|
+
type NotificationChannel = "email" | "sms" | "push" | "in_app";
|
|
3840
|
+
type NotificationCategory = "booking" | "payment" | "review" | "marketing" | "system";
|
|
3841
|
+
interface ChannelPreference {
|
|
3842
|
+
channel: NotificationChannel;
|
|
3843
|
+
enabled: boolean;
|
|
3844
|
+
}
|
|
3845
|
+
interface NotificationPreferences {
|
|
3846
|
+
guestId: string;
|
|
3847
|
+
channels: ChannelPreference[];
|
|
3848
|
+
categories: {
|
|
3849
|
+
category: NotificationCategory;
|
|
3850
|
+
enabled: boolean;
|
|
3851
|
+
}[];
|
|
3852
|
+
optedOutAt: string | null;
|
|
3853
|
+
updatedAt: string;
|
|
3854
|
+
}
|
|
3855
|
+
interface UpdateNotificationPreferencesInput {
|
|
3856
|
+
channels?: ChannelPreference[];
|
|
3857
|
+
categories?: {
|
|
3858
|
+
category: NotificationCategory;
|
|
3859
|
+
enabled: boolean;
|
|
3860
|
+
}[];
|
|
3861
|
+
}
|
|
3862
|
+
interface OptOutInput {
|
|
3863
|
+
guestId: string;
|
|
3864
|
+
channels?: NotificationChannel[];
|
|
3865
|
+
}
|
|
3866
|
+
interface OptOutResult {
|
|
3867
|
+
guestId: string;
|
|
3868
|
+
optedOutChannels: NotificationChannel[];
|
|
3869
|
+
optedOutAt: string;
|
|
3870
|
+
}
|
|
3871
|
+
|
|
3872
|
+
/**
|
|
3873
|
+
* Service for guest notification preference management in the Atzentis Booking API.
|
|
3874
|
+
*
|
|
3875
|
+
* Provides reading and updating per-guest channel and category preferences,
|
|
3876
|
+
* and processing global opt-out requests.
|
|
3877
|
+
*
|
|
3878
|
+
* @example
|
|
3879
|
+
* ```typescript
|
|
3880
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
3881
|
+
*
|
|
3882
|
+
* // Disable SMS for a guest
|
|
3883
|
+
* await booking.notifications.updatePreferences("guest_1", {
|
|
3884
|
+
* channels: [{ channel: "sms", enabled: false }],
|
|
3885
|
+
* });
|
|
3886
|
+
*
|
|
3887
|
+
* // Process a full opt-out request
|
|
3888
|
+
* const result = await booking.notifications.optOut({
|
|
3889
|
+
* guestId: "guest_1",
|
|
3890
|
+
* });
|
|
3891
|
+
* ```
|
|
3892
|
+
*/
|
|
3893
|
+
declare class NotificationsService extends BaseService {
|
|
3894
|
+
protected readonly basePath = "/notifications/v1";
|
|
3895
|
+
/** Get notification preferences for a guest */
|
|
3896
|
+
getPreferences(guestId: string): Promise<NotificationPreferences>;
|
|
3897
|
+
/** Update notification preferences for a guest */
|
|
3898
|
+
updatePreferences(guestId: string, input: UpdateNotificationPreferencesInput): Promise<NotificationPreferences>;
|
|
3899
|
+
/** Opt a guest out of notifications (all channels or specific ones) */
|
|
3900
|
+
optOut(input: OptOutInput): Promise<OptOutResult>;
|
|
3901
|
+
}
|
|
3902
|
+
|
|
2748
3903
|
/** Supported payment providers */
|
|
2749
3904
|
type PaymentProvider = "stripe" | "viva_wallet";
|
|
2750
3905
|
/** Status of a payment */
|
|
@@ -2989,6 +4144,56 @@ declare class PaymentsService extends BaseService {
|
|
|
2989
4144
|
irisStatus(transferId: string): Promise<IrisTransfer>;
|
|
2990
4145
|
}
|
|
2991
4146
|
|
|
4147
|
+
/**
|
|
4148
|
+
* Service for portfolio management in the Atzentis Booking API.
|
|
4149
|
+
*
|
|
4150
|
+
* Provides CRUD operations for portfolios, property membership management,
|
|
4151
|
+
* dashboard analytics, and cross-portfolio search.
|
|
4152
|
+
*
|
|
4153
|
+
* @example
|
|
4154
|
+
* ```typescript
|
|
4155
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
4156
|
+
*
|
|
4157
|
+
* // Create a portfolio
|
|
4158
|
+
* const portfolio = await booking.portfolios.create({
|
|
4159
|
+
* name: "Greek Island Properties",
|
|
4160
|
+
* description: "All island villa properties",
|
|
4161
|
+
* });
|
|
4162
|
+
*
|
|
4163
|
+
* // Add a property to the portfolio
|
|
4164
|
+
* await booking.portfolios.addProperty(portfolio.id, {
|
|
4165
|
+
* propertyId: "prop_1",
|
|
4166
|
+
* });
|
|
4167
|
+
*
|
|
4168
|
+
* // Get portfolio dashboard
|
|
4169
|
+
* const dashboard = await booking.portfolios.getDashboard(portfolio.id, {
|
|
4170
|
+
* from: "2025-01-01",
|
|
4171
|
+
* to: "2025-12-31",
|
|
4172
|
+
* });
|
|
4173
|
+
* ```
|
|
4174
|
+
*/
|
|
4175
|
+
declare class PortfoliosService extends BaseService {
|
|
4176
|
+
protected readonly basePath = "/operations/v1/portfolios";
|
|
4177
|
+
/** Create a new portfolio */
|
|
4178
|
+
create(input: CreatePortfolioInput): Promise<Portfolio>;
|
|
4179
|
+
/** Get a portfolio by ID including its properties */
|
|
4180
|
+
get(portfolioId: string): Promise<PortfolioWithProperties>;
|
|
4181
|
+
/** List portfolios with optional filters */
|
|
4182
|
+
list(params?: ListPortfoliosParams): Promise<PaginatedPortfolios>;
|
|
4183
|
+
/** Update a portfolio */
|
|
4184
|
+
update(portfolioId: string, input: UpdatePortfolioInput): Promise<Portfolio>;
|
|
4185
|
+
/** Delete a portfolio */
|
|
4186
|
+
delete(portfolioId: string): Promise<void>;
|
|
4187
|
+
/** Add a property to a portfolio */
|
|
4188
|
+
addProperty(portfolioId: string, input: AddPortfolioPropertyInput): Promise<PortfolioProperty>;
|
|
4189
|
+
/** Remove a property from a portfolio */
|
|
4190
|
+
removeProperty(portfolioId: string, propertyId: string): Promise<void>;
|
|
4191
|
+
/** Get aggregated dashboard data for a portfolio */
|
|
4192
|
+
getDashboard(portfolioId: string, params?: GetPortfolioDashboardDataParams): Promise<PortfolioDashboardData>;
|
|
4193
|
+
/** Search for guests, bookings, or all records within a portfolio */
|
|
4194
|
+
search(portfolioId: string, params: PortfolioSearchParams): Promise<PortfolioSearchResponse>;
|
|
4195
|
+
}
|
|
4196
|
+
|
|
2992
4197
|
/**
|
|
2993
4198
|
* Service for managing properties in the Atzentis Booking API.
|
|
2994
4199
|
*
|
|
@@ -3335,6 +4540,567 @@ declare class RatePlansService extends BaseService {
|
|
|
3335
4540
|
comparePortfolioRates(input: ComparePortfolioRatesInput): Promise<PortfolioRateComparison>;
|
|
3336
4541
|
}
|
|
3337
4542
|
|
|
4543
|
+
type KPIMetricName = "occupancy" | "adr" | "revpar" | "trevpar" | "goppar";
|
|
4544
|
+
type ComparisonPeriod = "prior_year" | "budget" | "none";
|
|
4545
|
+
type ReportGroupBy = "source" | "category" | "daily" | "weekly" | "monthly";
|
|
4546
|
+
type ReportGranularity = "daily" | "weekly" | "monthly";
|
|
4547
|
+
type ForecastModel = "historical" | "market" | "combined";
|
|
4548
|
+
type SuggestionStatus = "pending" | "applied" | "dismissed" | "expired";
|
|
4549
|
+
type SuggestionType = "increase" | "decrease" | "maintain";
|
|
4550
|
+
type PortfolioSortBy = "revenue" | "occupancy" | "adr" | "revpar";
|
|
4551
|
+
interface DateRange {
|
|
4552
|
+
from: string;
|
|
4553
|
+
to: string;
|
|
4554
|
+
}
|
|
4555
|
+
interface KPI {
|
|
4556
|
+
name: KPIMetricName;
|
|
4557
|
+
label: string;
|
|
4558
|
+
value: number;
|
|
4559
|
+
previousValue: number | null;
|
|
4560
|
+
change: number | null;
|
|
4561
|
+
changePercent: number | null;
|
|
4562
|
+
unit: string;
|
|
4563
|
+
}
|
|
4564
|
+
interface OccupancyData {
|
|
4565
|
+
rate: number;
|
|
4566
|
+
totalSpaces: number;
|
|
4567
|
+
occupiedSpaces: number;
|
|
4568
|
+
period: DateRange;
|
|
4569
|
+
}
|
|
4570
|
+
interface RevenueBySource {
|
|
4571
|
+
source: string;
|
|
4572
|
+
revenue: number;
|
|
4573
|
+
percentage: number;
|
|
4574
|
+
bookingCount: number;
|
|
4575
|
+
}
|
|
4576
|
+
interface RevenueDashboard {
|
|
4577
|
+
propertyId: string;
|
|
4578
|
+
kpis: KPI[];
|
|
4579
|
+
occupancy: OccupancyData;
|
|
4580
|
+
revenueBySource: RevenueBySource[];
|
|
4581
|
+
period: DateRange;
|
|
4582
|
+
comparisonPeriod: ComparisonPeriod | null;
|
|
4583
|
+
}
|
|
4584
|
+
interface KPIResponse {
|
|
4585
|
+
metrics: KPI[];
|
|
4586
|
+
period: DateRange;
|
|
4587
|
+
granularity: ReportGranularity | null;
|
|
4588
|
+
}
|
|
4589
|
+
interface RateSuggestion {
|
|
4590
|
+
id: string;
|
|
4591
|
+
propertyId: string;
|
|
4592
|
+
ratePlanId: string;
|
|
4593
|
+
ratePlanName: string;
|
|
4594
|
+
type: SuggestionType;
|
|
4595
|
+
currentRate: number;
|
|
4596
|
+
suggestedRate: number;
|
|
4597
|
+
reason: string;
|
|
4598
|
+
confidence: number;
|
|
4599
|
+
status: SuggestionStatus;
|
|
4600
|
+
dateRange: DateRange;
|
|
4601
|
+
appliedAt: string | null;
|
|
4602
|
+
dismissedAt: string | null;
|
|
4603
|
+
dismissReason: string | null;
|
|
4604
|
+
createdAt: string;
|
|
4605
|
+
}
|
|
4606
|
+
interface Competitor {
|
|
4607
|
+
id: string;
|
|
4608
|
+
propertyId: string;
|
|
4609
|
+
name: string;
|
|
4610
|
+
externalUrl: string | null;
|
|
4611
|
+
sources: string[];
|
|
4612
|
+
metadata: Record<string, unknown> | null;
|
|
4613
|
+
createdAt: string;
|
|
4614
|
+
updatedAt: string;
|
|
4615
|
+
}
|
|
4616
|
+
interface CompetitorRate {
|
|
4617
|
+
date: string;
|
|
4618
|
+
rate: number;
|
|
4619
|
+
source: string;
|
|
4620
|
+
roomType: string;
|
|
4621
|
+
currency: string;
|
|
4622
|
+
}
|
|
4623
|
+
interface CompetitorRateResponse {
|
|
4624
|
+
competitorId: string;
|
|
4625
|
+
competitorName: string;
|
|
4626
|
+
rates: CompetitorRate[];
|
|
4627
|
+
period: DateRange;
|
|
4628
|
+
}
|
|
4629
|
+
interface RevenueReportEntry {
|
|
4630
|
+
date: string;
|
|
4631
|
+
revenue: number;
|
|
4632
|
+
roomRevenue: number;
|
|
4633
|
+
otherRevenue: number;
|
|
4634
|
+
bookings: number;
|
|
4635
|
+
occupancyRate: number;
|
|
4636
|
+
}
|
|
4637
|
+
interface RevenueReport {
|
|
4638
|
+
propertyId: string;
|
|
4639
|
+
entries: RevenueReportEntry[];
|
|
4640
|
+
totals: {
|
|
4641
|
+
revenue: number;
|
|
4642
|
+
roomRevenue: number;
|
|
4643
|
+
otherRevenue: number;
|
|
4644
|
+
bookings: number;
|
|
4645
|
+
avgOccupancy: number;
|
|
4646
|
+
};
|
|
4647
|
+
period: DateRange;
|
|
4648
|
+
groupBy: ReportGroupBy;
|
|
4649
|
+
comparison: {
|
|
4650
|
+
entries: RevenueReportEntry[];
|
|
4651
|
+
totals: {
|
|
4652
|
+
revenue: number;
|
|
4653
|
+
roomRevenue: number;
|
|
4654
|
+
otherRevenue: number;
|
|
4655
|
+
bookings: number;
|
|
4656
|
+
avgOccupancy: number;
|
|
4657
|
+
};
|
|
4658
|
+
} | null;
|
|
4659
|
+
}
|
|
4660
|
+
interface ForecastEntry {
|
|
4661
|
+
date: string;
|
|
4662
|
+
predictedRevenue: number;
|
|
4663
|
+
predictedOccupancy: number;
|
|
4664
|
+
confidence: number;
|
|
4665
|
+
lowerBound: number;
|
|
4666
|
+
upperBound: number;
|
|
4667
|
+
}
|
|
4668
|
+
interface RevenueForecast {
|
|
4669
|
+
propertyId: string;
|
|
4670
|
+
entries: ForecastEntry[];
|
|
4671
|
+
model: ForecastModel;
|
|
4672
|
+
period: DateRange;
|
|
4673
|
+
}
|
|
4674
|
+
interface PaceReportEntry {
|
|
4675
|
+
date: string;
|
|
4676
|
+
currentBookings: number;
|
|
4677
|
+
priorBookings: number;
|
|
4678
|
+
currentRevenue: number;
|
|
4679
|
+
priorRevenue: number;
|
|
4680
|
+
variance: number;
|
|
4681
|
+
variancePercent: number;
|
|
4682
|
+
}
|
|
4683
|
+
interface PaceReport {
|
|
4684
|
+
propertyId: string;
|
|
4685
|
+
entries: PaceReportEntry[];
|
|
4686
|
+
period: DateRange;
|
|
4687
|
+
comparisonPeriod: DateRange;
|
|
4688
|
+
totals: {
|
|
4689
|
+
currentBookings: number;
|
|
4690
|
+
priorBookings: number;
|
|
4691
|
+
currentRevenue: number;
|
|
4692
|
+
priorRevenue: number;
|
|
4693
|
+
variance: number;
|
|
4694
|
+
variancePercent: number;
|
|
4695
|
+
};
|
|
4696
|
+
}
|
|
4697
|
+
interface PortfolioDashboard {
|
|
4698
|
+
portfolioId: string;
|
|
4699
|
+
kpis: KPI[];
|
|
4700
|
+
totalProperties: number;
|
|
4701
|
+
period: DateRange;
|
|
4702
|
+
}
|
|
4703
|
+
interface PortfolioBreakdownEntry {
|
|
4704
|
+
propertyId: string;
|
|
4705
|
+
propertyName: string;
|
|
4706
|
+
revenue: number;
|
|
4707
|
+
occupancyRate: number;
|
|
4708
|
+
adr: number;
|
|
4709
|
+
revpar: number;
|
|
4710
|
+
}
|
|
4711
|
+
interface PortfolioBreakdown {
|
|
4712
|
+
portfolioId: string;
|
|
4713
|
+
entries: PortfolioBreakdownEntry[];
|
|
4714
|
+
period: DateRange;
|
|
4715
|
+
}
|
|
4716
|
+
interface PortfolioForecastEntry {
|
|
4717
|
+
propertyId: string;
|
|
4718
|
+
propertyName: string;
|
|
4719
|
+
predictedRevenue: number;
|
|
4720
|
+
predictedOccupancy: number;
|
|
4721
|
+
confidence: number;
|
|
4722
|
+
}
|
|
4723
|
+
interface PortfolioForecast {
|
|
4724
|
+
portfolioId: string;
|
|
4725
|
+
entries: PortfolioForecastEntry[];
|
|
4726
|
+
model: ForecastModel;
|
|
4727
|
+
period: DateRange;
|
|
4728
|
+
}
|
|
4729
|
+
interface GetDashboardParams {
|
|
4730
|
+
propertyId: string;
|
|
4731
|
+
from?: string;
|
|
4732
|
+
to?: string;
|
|
4733
|
+
compareWith?: ComparisonPeriod;
|
|
4734
|
+
}
|
|
4735
|
+
interface GetKPIsParams {
|
|
4736
|
+
propertyId: string;
|
|
4737
|
+
from?: string;
|
|
4738
|
+
to?: string;
|
|
4739
|
+
metrics?: KPIMetricName[];
|
|
4740
|
+
granularity?: ReportGranularity;
|
|
4741
|
+
}
|
|
4742
|
+
interface ListSuggestionsParams {
|
|
4743
|
+
propertyId: string;
|
|
4744
|
+
status?: SuggestionStatus;
|
|
4745
|
+
ratePlanId?: string;
|
|
4746
|
+
from?: string;
|
|
4747
|
+
to?: string;
|
|
4748
|
+
limit?: number;
|
|
4749
|
+
cursor?: string;
|
|
4750
|
+
}
|
|
4751
|
+
interface DismissSuggestionInput {
|
|
4752
|
+
reason?: string;
|
|
4753
|
+
}
|
|
4754
|
+
interface ListCompetitorsParams {
|
|
4755
|
+
propertyId: string;
|
|
4756
|
+
limit?: number;
|
|
4757
|
+
cursor?: string;
|
|
4758
|
+
}
|
|
4759
|
+
interface GetCompetitorRatesParams {
|
|
4760
|
+
from?: string;
|
|
4761
|
+
to?: string;
|
|
4762
|
+
source?: string;
|
|
4763
|
+
}
|
|
4764
|
+
interface AddCompetitorInput {
|
|
4765
|
+
propertyId: string;
|
|
4766
|
+
name: string;
|
|
4767
|
+
externalUrl?: string;
|
|
4768
|
+
sources?: string[];
|
|
4769
|
+
metadata?: Record<string, unknown>;
|
|
4770
|
+
}
|
|
4771
|
+
interface GetRevenueReportParams {
|
|
4772
|
+
propertyId: string;
|
|
4773
|
+
from: string;
|
|
4774
|
+
to: string;
|
|
4775
|
+
groupBy?: ReportGroupBy;
|
|
4776
|
+
compareWith?: ComparisonPeriod;
|
|
4777
|
+
}
|
|
4778
|
+
interface GetForecastParams {
|
|
4779
|
+
propertyId: string;
|
|
4780
|
+
from: string;
|
|
4781
|
+
to: string;
|
|
4782
|
+
model?: ForecastModel;
|
|
4783
|
+
}
|
|
4784
|
+
interface GetPaceReportParams {
|
|
4785
|
+
propertyId: string;
|
|
4786
|
+
from: string;
|
|
4787
|
+
to: string;
|
|
4788
|
+
compareWith?: ComparisonPeriod;
|
|
4789
|
+
granularity?: ReportGranularity;
|
|
4790
|
+
}
|
|
4791
|
+
interface GetPortfolioDashboardParams {
|
|
4792
|
+
portfolioId: string;
|
|
4793
|
+
from?: string;
|
|
4794
|
+
to?: string;
|
|
4795
|
+
}
|
|
4796
|
+
interface GetPortfolioBreakdownParams {
|
|
4797
|
+
portfolioId: string;
|
|
4798
|
+
from?: string;
|
|
4799
|
+
to?: string;
|
|
4800
|
+
sortBy?: PortfolioSortBy;
|
|
4801
|
+
sortOrder?: "asc" | "desc";
|
|
4802
|
+
}
|
|
4803
|
+
interface GetPortfolioForecastParams {
|
|
4804
|
+
portfolioId: string;
|
|
4805
|
+
from?: string;
|
|
4806
|
+
to?: string;
|
|
4807
|
+
model?: ForecastModel;
|
|
4808
|
+
}
|
|
4809
|
+
type PaginatedSuggestions = Paginated<RateSuggestion>;
|
|
4810
|
+
type PaginatedCompetitors = Paginated<Competitor>;
|
|
4811
|
+
|
|
4812
|
+
/**
|
|
4813
|
+
* Service for revenue management and analytics in the Atzentis Booking API.
|
|
4814
|
+
*
|
|
4815
|
+
* Provides KPI dashboards, AI-driven rate suggestions, competitor rate tracking,
|
|
4816
|
+
* revenue/forecast/pace reports, and portfolio-level analytics.
|
|
4817
|
+
*
|
|
4818
|
+
* @example
|
|
4819
|
+
* ```typescript
|
|
4820
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
4821
|
+
*
|
|
4822
|
+
* // Get revenue dashboard
|
|
4823
|
+
* const dashboard = await booking.revenue.getDashboard({
|
|
4824
|
+
* propertyId: "prop_1",
|
|
4825
|
+
* from: "2025-01-01",
|
|
4826
|
+
* to: "2025-01-31",
|
|
4827
|
+
* compareWith: "prior_year",
|
|
4828
|
+
* });
|
|
4829
|
+
*
|
|
4830
|
+
* // Apply a rate suggestion
|
|
4831
|
+
* const suggestions = await booking.revenue.listSuggestions({ propertyId: "prop_1" });
|
|
4832
|
+
* await booking.revenue.applySuggestion(suggestions.data[0].id);
|
|
4833
|
+
*
|
|
4834
|
+
* // Get revenue forecast
|
|
4835
|
+
* const forecast = await booking.revenue.getForecast({
|
|
4836
|
+
* propertyId: "prop_1",
|
|
4837
|
+
* from: "2025-02-01",
|
|
4838
|
+
* to: "2025-02-28",
|
|
4839
|
+
* model: "combined",
|
|
4840
|
+
* });
|
|
4841
|
+
* ```
|
|
4842
|
+
*/
|
|
4843
|
+
declare class RevenueService extends BaseService {
|
|
4844
|
+
protected readonly basePath = "/revenue/v1";
|
|
4845
|
+
/** Get the revenue dashboard with KPIs, occupancy, and revenue breakdown */
|
|
4846
|
+
getDashboard(params: GetDashboardParams): Promise<RevenueDashboard>;
|
|
4847
|
+
/** Get individual KPI metrics with optional granularity breakdown */
|
|
4848
|
+
getKPIs(params: GetKPIsParams): Promise<KPIResponse>;
|
|
4849
|
+
/** List AI-generated rate suggestions with optional filters */
|
|
4850
|
+
listSuggestions(params: ListSuggestionsParams): Promise<PaginatedSuggestions>;
|
|
4851
|
+
/** Apply a rate suggestion, updating the associated rate plan */
|
|
4852
|
+
applySuggestion(suggestionId: string): Promise<RateSuggestion>;
|
|
4853
|
+
/** Dismiss a rate suggestion with an optional reason */
|
|
4854
|
+
dismissSuggestion(suggestionId: string, input?: DismissSuggestionInput): Promise<RateSuggestion>;
|
|
4855
|
+
/** List competitors tracked for a property */
|
|
4856
|
+
listCompetitors(params: ListCompetitorsParams): Promise<PaginatedCompetitors>;
|
|
4857
|
+
/** Get rate data scraped for a competitor over a date range */
|
|
4858
|
+
getCompetitorRates(competitorId: string, params?: GetCompetitorRatesParams): Promise<CompetitorRateResponse>;
|
|
4859
|
+
/** Add a competitor to track for a property */
|
|
4860
|
+
addCompetitor(input: AddCompetitorInput): Promise<Competitor>;
|
|
4861
|
+
/** Get a detailed revenue report with optional comparison period */
|
|
4862
|
+
getRevenueReport(params: GetRevenueReportParams): Promise<RevenueReport>;
|
|
4863
|
+
/** Get a revenue forecast for a future date range */
|
|
4864
|
+
getForecast(params: GetForecastParams): Promise<RevenueForecast>;
|
|
4865
|
+
/** Get a pace report comparing current bookings against a prior period */
|
|
4866
|
+
getPaceReport(params: GetPaceReportParams): Promise<PaceReport>;
|
|
4867
|
+
/** Get a portfolio-level dashboard with aggregated KPIs */
|
|
4868
|
+
getPortfolioDashboard(params: GetPortfolioDashboardParams): Promise<PortfolioDashboard>;
|
|
4869
|
+
/** Get a per-property breakdown of revenue metrics across a portfolio */
|
|
4870
|
+
getPortfolioBreakdown(params: GetPortfolioBreakdownParams): Promise<PortfolioBreakdown>;
|
|
4871
|
+
/** Get a revenue forecast for all properties in a portfolio */
|
|
4872
|
+
getPortfolioForecast(params: GetPortfolioForecastParams): Promise<PortfolioForecast>;
|
|
4873
|
+
}
|
|
4874
|
+
|
|
4875
|
+
/** Status of a review */
|
|
4876
|
+
type ReviewStatus = "pending" | "published" | "rejected" | "flagged";
|
|
4877
|
+
/** Action to take when moderating a review */
|
|
4878
|
+
type ModerationAction = "approve" | "reject" | "flag";
|
|
4879
|
+
/** Sort field for reviews */
|
|
4880
|
+
type ReviewSortBy = "createdAt" | "rating" | "updatedAt";
|
|
4881
|
+
/** Channel for sending review requests */
|
|
4882
|
+
type ReviewRequestChannel = "email" | "sms" | "push";
|
|
4883
|
+
/** Status of a review request */
|
|
4884
|
+
type ReviewRequestStatus = "sent" | "scheduled" | "failed";
|
|
4885
|
+
/** Period for analytics aggregation */
|
|
4886
|
+
type AnalyticsPeriod = "day" | "week" | "month" | "year";
|
|
4887
|
+
/** An owner response to a review */
|
|
4888
|
+
interface ReviewResponse {
|
|
4889
|
+
id: string;
|
|
4890
|
+
reviewId: string;
|
|
4891
|
+
content: string;
|
|
4892
|
+
respondedBy: string | null;
|
|
4893
|
+
createdAt: string;
|
|
4894
|
+
updatedAt: string;
|
|
4895
|
+
}
|
|
4896
|
+
/** A trend data point in review analytics */
|
|
4897
|
+
interface ReviewTrend {
|
|
4898
|
+
period: string;
|
|
4899
|
+
startDate: string;
|
|
4900
|
+
endDate: string;
|
|
4901
|
+
averageRating: number;
|
|
4902
|
+
reviewCount: number;
|
|
4903
|
+
}
|
|
4904
|
+
/** A guest review */
|
|
4905
|
+
interface Review {
|
|
4906
|
+
id: string;
|
|
4907
|
+
propertyId: string;
|
|
4908
|
+
guestId: string;
|
|
4909
|
+
bookingId: string | null;
|
|
4910
|
+
rating: number;
|
|
4911
|
+
title: string;
|
|
4912
|
+
content: string;
|
|
4913
|
+
status: ReviewStatus;
|
|
4914
|
+
categories: Record<string, number> | null;
|
|
4915
|
+
language: string | null;
|
|
4916
|
+
response: ReviewResponse | null;
|
|
4917
|
+
moderationNotes: string | null;
|
|
4918
|
+
moderatedAt: string | null;
|
|
4919
|
+
moderatedBy: string | null;
|
|
4920
|
+
metadata: Record<string, unknown> | null;
|
|
4921
|
+
createdAt: string;
|
|
4922
|
+
updatedAt: string;
|
|
4923
|
+
deletedAt: string | null;
|
|
4924
|
+
}
|
|
4925
|
+
/** Aggregated review analytics for a property */
|
|
4926
|
+
interface ReviewAnalytics {
|
|
4927
|
+
propertyId: string;
|
|
4928
|
+
averageRating: number;
|
|
4929
|
+
totalReviews: number;
|
|
4930
|
+
ratingDistribution: Record<string, number>;
|
|
4931
|
+
categoryAverages: Record<string, number>;
|
|
4932
|
+
trends: ReviewTrend[];
|
|
4933
|
+
}
|
|
4934
|
+
/** A review request sent to a guest */
|
|
4935
|
+
interface ReviewRequest {
|
|
4936
|
+
id: string;
|
|
4937
|
+
propertyId: string;
|
|
4938
|
+
guestId: string;
|
|
4939
|
+
bookingId: string;
|
|
4940
|
+
channel: ReviewRequestChannel;
|
|
4941
|
+
status: ReviewRequestStatus;
|
|
4942
|
+
sentAt: string | null;
|
|
4943
|
+
scheduledAt: string | null;
|
|
4944
|
+
createdAt: string;
|
|
4945
|
+
}
|
|
4946
|
+
/** Input for creating a review */
|
|
4947
|
+
interface CreateReviewInput {
|
|
4948
|
+
propertyId: string;
|
|
4949
|
+
guestId: string;
|
|
4950
|
+
rating: number;
|
|
4951
|
+
title: string;
|
|
4952
|
+
content: string;
|
|
4953
|
+
bookingId?: string;
|
|
4954
|
+
categories?: Record<string, number>;
|
|
4955
|
+
language?: string;
|
|
4956
|
+
metadata?: Record<string, unknown>;
|
|
4957
|
+
}
|
|
4958
|
+
/** Input for updating a review */
|
|
4959
|
+
interface UpdateReviewInput {
|
|
4960
|
+
title?: string;
|
|
4961
|
+
content?: string;
|
|
4962
|
+
rating?: number;
|
|
4963
|
+
categories?: Record<string, number>;
|
|
4964
|
+
language?: string;
|
|
4965
|
+
metadata?: Record<string, unknown>;
|
|
4966
|
+
}
|
|
4967
|
+
/** Parameters for listing reviews */
|
|
4968
|
+
interface ListReviewsParams {
|
|
4969
|
+
propertyId: string;
|
|
4970
|
+
status?: ReviewStatus;
|
|
4971
|
+
guestId?: string;
|
|
4972
|
+
bookingId?: string;
|
|
4973
|
+
minRating?: number;
|
|
4974
|
+
maxRating?: number;
|
|
4975
|
+
from?: string;
|
|
4976
|
+
to?: string;
|
|
4977
|
+
sortBy?: ReviewSortBy;
|
|
4978
|
+
sortOrder?: "asc" | "desc";
|
|
4979
|
+
limit?: number;
|
|
4980
|
+
cursor?: string;
|
|
4981
|
+
}
|
|
4982
|
+
/** Input for moderating a review */
|
|
4983
|
+
interface ModerateReviewInput {
|
|
4984
|
+
action: ModerationAction;
|
|
4985
|
+
notes?: string;
|
|
4986
|
+
reason?: string;
|
|
4987
|
+
}
|
|
4988
|
+
/** Input for creating an owner response */
|
|
4989
|
+
interface CreateReviewResponseInput {
|
|
4990
|
+
content: string;
|
|
4991
|
+
respondedBy?: string;
|
|
4992
|
+
}
|
|
4993
|
+
/** Input for updating an owner response */
|
|
4994
|
+
interface UpdateReviewResponseInput {
|
|
4995
|
+
content?: string;
|
|
4996
|
+
}
|
|
4997
|
+
/** Parameters for review analytics */
|
|
4998
|
+
interface ReviewAnalyticsParams {
|
|
4999
|
+
propertyId: string;
|
|
5000
|
+
from?: string;
|
|
5001
|
+
to?: string;
|
|
5002
|
+
period?: AnalyticsPeriod;
|
|
5003
|
+
}
|
|
5004
|
+
/** Input for sending a review request */
|
|
5005
|
+
interface SendReviewRequestInput {
|
|
5006
|
+
propertyId: string;
|
|
5007
|
+
guestId: string;
|
|
5008
|
+
bookingId: string;
|
|
5009
|
+
channel?: ReviewRequestChannel;
|
|
5010
|
+
scheduledAt?: string;
|
|
5011
|
+
templateId?: string;
|
|
5012
|
+
metadata?: Record<string, unknown>;
|
|
5013
|
+
}
|
|
5014
|
+
/** Paginated list of reviews */
|
|
5015
|
+
type PaginatedReviews = Paginated<Review>;
|
|
5016
|
+
|
|
5017
|
+
/**
|
|
5018
|
+
* Service for guest review management in the Atzentis Booking API.
|
|
5019
|
+
*
|
|
5020
|
+
* Provides review CRUD, moderation workflow, owner responses,
|
|
5021
|
+
* analytics, and review request triggering.
|
|
5022
|
+
*
|
|
5023
|
+
* @example
|
|
5024
|
+
* ```typescript
|
|
5025
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
5026
|
+
*
|
|
5027
|
+
* // List published reviews
|
|
5028
|
+
* const reviews = await booking.reviews.listReviews({
|
|
5029
|
+
* propertyId: "prop_1",
|
|
5030
|
+
* status: "published",
|
|
5031
|
+
* sortBy: "rating",
|
|
5032
|
+
* });
|
|
5033
|
+
*
|
|
5034
|
+
* // Moderate a review
|
|
5035
|
+
* await booking.reviews.moderateReview("rev_1", { action: "approve" });
|
|
5036
|
+
*
|
|
5037
|
+
* // Get analytics
|
|
5038
|
+
* const analytics = await booking.reviews.getAnalytics({
|
|
5039
|
+
* propertyId: "prop_1",
|
|
5040
|
+
* period: "month",
|
|
5041
|
+
* });
|
|
5042
|
+
* ```
|
|
5043
|
+
*/
|
|
5044
|
+
declare class ReviewsService extends BaseService {
|
|
5045
|
+
protected readonly basePath = "/guest/v1";
|
|
5046
|
+
/** Create a review */
|
|
5047
|
+
createReview(input: CreateReviewInput): Promise<Review>;
|
|
5048
|
+
/** Get a review by ID */
|
|
5049
|
+
getReview(reviewId: string): Promise<Review>;
|
|
5050
|
+
/** List reviews with optional filters */
|
|
5051
|
+
listReviews(params: ListReviewsParams): Promise<PaginatedReviews>;
|
|
5052
|
+
/** Update a review */
|
|
5053
|
+
updateReview(reviewId: string, input: UpdateReviewInput): Promise<Review>;
|
|
5054
|
+
/** Delete a review */
|
|
5055
|
+
deleteReview(reviewId: string): Promise<void>;
|
|
5056
|
+
/** Moderate a review (approve, reject, or flag) */
|
|
5057
|
+
moderateReview(reviewId: string, input: ModerateReviewInput): Promise<Review>;
|
|
5058
|
+
/** Create an owner response to a review */
|
|
5059
|
+
createResponse(reviewId: string, input: CreateReviewResponseInput): Promise<ReviewResponse>;
|
|
5060
|
+
/** Update an owner response */
|
|
5061
|
+
updateResponse(reviewId: string, input: UpdateReviewResponseInput): Promise<ReviewResponse>;
|
|
5062
|
+
/** Delete an owner response */
|
|
5063
|
+
deleteResponse(reviewId: string): Promise<void>;
|
|
5064
|
+
/** Get review analytics for a property */
|
|
5065
|
+
getAnalytics(params: ReviewAnalyticsParams): Promise<ReviewAnalytics>;
|
|
5066
|
+
/** Send a review request to a guest */
|
|
5067
|
+
sendReviewRequest(input: SendReviewRequestInput): Promise<ReviewRequest>;
|
|
5068
|
+
}
|
|
5069
|
+
|
|
5070
|
+
/**
|
|
5071
|
+
* Service for property and fiscal settings management in the Atzentis Booking API.
|
|
5072
|
+
*
|
|
5073
|
+
* Provides reading and updating property-level configuration (timezone, currency,
|
|
5074
|
+
* check-in/out times, modules) and fiscal compliance settings (myDATA, TSE).
|
|
5075
|
+
*
|
|
5076
|
+
* @example
|
|
5077
|
+
* ```typescript
|
|
5078
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
5079
|
+
*
|
|
5080
|
+
* // Update property timezone and currency
|
|
5081
|
+
* const settings = await booking.settings.updatePropertySettings({
|
|
5082
|
+
* timezone: "Europe/Athens",
|
|
5083
|
+
* currency: "EUR",
|
|
5084
|
+
* });
|
|
5085
|
+
*
|
|
5086
|
+
* // Enable myDATA auto-submission
|
|
5087
|
+
* await booking.settings.updateFiscalSettings({
|
|
5088
|
+
* mydata: { autoSubmit: true },
|
|
5089
|
+
* });
|
|
5090
|
+
* ```
|
|
5091
|
+
*/
|
|
5092
|
+
declare class SettingsService extends BaseService {
|
|
5093
|
+
protected readonly basePath = "/settings/v1";
|
|
5094
|
+
/** Get property-level settings */
|
|
5095
|
+
getPropertySettings(): Promise<PropertySettings>;
|
|
5096
|
+
/** Update property-level settings */
|
|
5097
|
+
updatePropertySettings(input: UpdatePropertySettingsInput): Promise<PropertySettings>;
|
|
5098
|
+
/** Get fiscal compliance settings (myDATA and TSE) */
|
|
5099
|
+
getFiscalSettings(): Promise<FiscalSettings>;
|
|
5100
|
+
/** Update fiscal compliance settings (myDATA and TSE) */
|
|
5101
|
+
updateFiscalSettings(input: UpdateFiscalSettingsInput): Promise<FiscalSettings>;
|
|
5102
|
+
}
|
|
5103
|
+
|
|
3338
5104
|
/**
|
|
3339
5105
|
* Service for managing bookable spaces in the Atzentis Booking API.
|
|
3340
5106
|
*
|
|
@@ -3612,6 +5378,126 @@ declare class StaffService extends BaseService {
|
|
|
3612
5378
|
listShifts(staffId: string, params?: ListShiftsParams): Promise<StaffShift[]>;
|
|
3613
5379
|
}
|
|
3614
5380
|
|
|
5381
|
+
/**
|
|
5382
|
+
* Service for supply and inventory management in the Atzentis Booking API.
|
|
5383
|
+
*
|
|
5384
|
+
* Provides item CRUD, stock level tracking, movement recording,
|
|
5385
|
+
* and low-stock alert queries.
|
|
5386
|
+
*
|
|
5387
|
+
* @example
|
|
5388
|
+
* ```typescript
|
|
5389
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
5390
|
+
*
|
|
5391
|
+
* // Create a supply item
|
|
5392
|
+
* const item = await booking.supply.createItem({
|
|
5393
|
+
* propertyId: "prop_1",
|
|
5394
|
+
* name: "Bath Towels",
|
|
5395
|
+
* category: "linens",
|
|
5396
|
+
* unit: "piece",
|
|
5397
|
+
* });
|
|
5398
|
+
*
|
|
5399
|
+
* // Record a stock movement
|
|
5400
|
+
* await booking.supply.createMovement({
|
|
5401
|
+
* itemId: item.id,
|
|
5402
|
+
* type: "received",
|
|
5403
|
+
* quantity: 50,
|
|
5404
|
+
* });
|
|
5405
|
+
*
|
|
5406
|
+
* // Check low-stock items
|
|
5407
|
+
* const lowStock = await booking.supply.listLowStock({ propertyId: "prop_1" });
|
|
5408
|
+
* ```
|
|
5409
|
+
*/
|
|
5410
|
+
declare class SupplyService extends BaseService {
|
|
5411
|
+
protected readonly basePath = "/operations/v1";
|
|
5412
|
+
/** Create a supply item */
|
|
5413
|
+
createItem(input: CreateSupplyItemInput): Promise<SupplyItem>;
|
|
5414
|
+
/** Get a supply item by ID */
|
|
5415
|
+
getItem(itemId: string): Promise<SupplyItem>;
|
|
5416
|
+
/** List supply items with optional filters */
|
|
5417
|
+
listItems(params: ListSupplyItemsParams): Promise<PaginatedSupplyItems>;
|
|
5418
|
+
/** Update a supply item */
|
|
5419
|
+
updateItem(itemId: string, input: UpdateSupplyItemInput): Promise<SupplyItem>;
|
|
5420
|
+
/** Delete a supply item */
|
|
5421
|
+
deleteItem(itemId: string): Promise<void>;
|
|
5422
|
+
/** Get the current stock level for a supply item */
|
|
5423
|
+
getLevel(itemId: string): Promise<SupplyLevel>;
|
|
5424
|
+
/** List stock levels with optional filters */
|
|
5425
|
+
listLevels(params: ListSupplyLevelsParams): Promise<PaginatedSupplyLevels>;
|
|
5426
|
+
/** Update a stock level manually */
|
|
5427
|
+
updateLevel(itemId: string, input: UpdateSupplyLevelInput): Promise<SupplyLevel>;
|
|
5428
|
+
/** Record a stock movement */
|
|
5429
|
+
createMovement(input: CreateSupplyMovementInput): Promise<SupplyMovement>;
|
|
5430
|
+
/** List supply movements with optional filters */
|
|
5431
|
+
listMovements(params: ListSupplyMovementsParams): Promise<PaginatedSupplyMovements>;
|
|
5432
|
+
/** List items whose stock is at or below reorder threshold */
|
|
5433
|
+
listLowStock(params: ListLowStockParams): Promise<PaginatedSupplyItems>;
|
|
5434
|
+
}
|
|
5435
|
+
|
|
5436
|
+
/**
|
|
5437
|
+
* Service for general operational tasks in the Atzentis Booking API.
|
|
5438
|
+
*
|
|
5439
|
+
* Provides task creation, listing with filters, and status updates.
|
|
5440
|
+
*
|
|
5441
|
+
* @example
|
|
5442
|
+
* ```typescript
|
|
5443
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
5444
|
+
*
|
|
5445
|
+
* // Create a task
|
|
5446
|
+
* const task = await booking.tasks.create({
|
|
5447
|
+
* propertyId: "prop_1",
|
|
5448
|
+
* title: "Restock minibar in room 204",
|
|
5449
|
+
* priority: "high",
|
|
5450
|
+
* });
|
|
5451
|
+
*
|
|
5452
|
+
* // Update task status
|
|
5453
|
+
* await booking.tasks.update(task.id, { status: "in_progress" });
|
|
5454
|
+
* ```
|
|
5455
|
+
*/
|
|
5456
|
+
declare class TasksService extends BaseService {
|
|
5457
|
+
protected readonly basePath = "/operations/v1/tasks";
|
|
5458
|
+
/** Create an operational task */
|
|
5459
|
+
create(input: CreateTaskInput): Promise<OperationalTask>;
|
|
5460
|
+
/** List operational tasks with optional filters */
|
|
5461
|
+
list(params?: ListTasksParams): Promise<PaginatedTasks>;
|
|
5462
|
+
/** Update an operational task */
|
|
5463
|
+
update(taskId: string, input: UpdateTaskInput): Promise<OperationalTask>;
|
|
5464
|
+
}
|
|
5465
|
+
|
|
5466
|
+
/**
|
|
5467
|
+
* Service for webhook subscription and delivery management in the Atzentis Booking API.
|
|
5468
|
+
*
|
|
5469
|
+
* Provides creating and updating webhook subscriptions and querying
|
|
5470
|
+
* delivery history with status filtering.
|
|
5471
|
+
*
|
|
5472
|
+
* @example
|
|
5473
|
+
* ```typescript
|
|
5474
|
+
* const booking = new BookingClient({ apiKey: "atz_io_live_xxxxx" });
|
|
5475
|
+
*
|
|
5476
|
+
* // Subscribe to booking events
|
|
5477
|
+
* const subscription = await booking.webhooks.createSubscription({
|
|
5478
|
+
* url: "https://example.com/webhooks",
|
|
5479
|
+
* events: ["booking.created", "booking.cancelled"],
|
|
5480
|
+
* });
|
|
5481
|
+
*
|
|
5482
|
+
* // List recent failed deliveries
|
|
5483
|
+
* const failures = await booking.webhooks.listDeliveries({
|
|
5484
|
+
* subscriptionId: subscription.id,
|
|
5485
|
+
* status: "failed",
|
|
5486
|
+
* });
|
|
5487
|
+
* ```
|
|
5488
|
+
*/
|
|
5489
|
+
declare class WebhooksService extends BaseService {
|
|
5490
|
+
protected readonly basePath = "/webhooks/v1";
|
|
5491
|
+
/** Create a new webhook subscription */
|
|
5492
|
+
createSubscription(input: CreateWebhookSubscriptionInput): Promise<WebhookSubscription>;
|
|
5493
|
+
/** List webhook subscriptions with optional filters */
|
|
5494
|
+
listSubscriptions(params?: ListWebhookSubscriptionsParams): Promise<PaginatedWebhookSubscriptions>;
|
|
5495
|
+
/** Update a webhook subscription */
|
|
5496
|
+
updateSubscription(subscriptionId: string, input: UpdateWebhookSubscriptionInput): Promise<WebhookSubscription>;
|
|
5497
|
+
/** List webhook delivery attempts with optional filters */
|
|
5498
|
+
listDeliveries(params?: ListWebhookDeliveriesParams): Promise<PaginatedWebhookDeliveries>;
|
|
5499
|
+
}
|
|
5500
|
+
|
|
3615
5501
|
/**
|
|
3616
5502
|
* Main SDK client for the Atzentis Booking API.
|
|
3617
5503
|
*
|
|
@@ -3625,47 +5511,86 @@ declare class BookingClient {
|
|
|
3625
5511
|
readonly httpClient: HttpClient;
|
|
3626
5512
|
private _availability?;
|
|
3627
5513
|
private _bookings?;
|
|
5514
|
+
private _categories?;
|
|
5515
|
+
private _concierge?;
|
|
5516
|
+
private _discounts?;
|
|
3628
5517
|
private _distribution?;
|
|
3629
5518
|
private _finance?;
|
|
5519
|
+
private _fiscal?;
|
|
3630
5520
|
private _groups?;
|
|
3631
5521
|
private _guests?;
|
|
3632
5522
|
private _housekeeping?;
|
|
5523
|
+
private _idScanning?;
|
|
5524
|
+
private _intelligence?;
|
|
3633
5525
|
private _nightAudit?;
|
|
5526
|
+
private _notifications?;
|
|
3634
5527
|
private _payments?;
|
|
5528
|
+
private _portfolios?;
|
|
3635
5529
|
private _properties?;
|
|
3636
5530
|
private _ratePlans?;
|
|
3637
|
-
private
|
|
5531
|
+
private _revenue?;
|
|
5532
|
+
private _reviews?;
|
|
5533
|
+
private _settings?;
|
|
3638
5534
|
private _spaces?;
|
|
3639
5535
|
private _staff?;
|
|
5536
|
+
private _supply?;
|
|
5537
|
+
private _tasks?;
|
|
5538
|
+
private _webhooks?;
|
|
3640
5539
|
constructor(config: BookingClientConfig);
|
|
3641
5540
|
/** Availability service — lazy-initialized on first access */
|
|
3642
5541
|
get availability(): AvailabilityService;
|
|
3643
5542
|
/** Bookings service — lazy-initialized on first access */
|
|
3644
5543
|
get bookings(): BookingsService;
|
|
5544
|
+
/** Concierge service — lazy-initialized on first access */
|
|
5545
|
+
get concierge(): ConciergeService;
|
|
3645
5546
|
/** Distribution service — lazy-initialized on first access */
|
|
3646
5547
|
get distribution(): DistributionService;
|
|
3647
5548
|
/** Finance service — lazy-initialized on first access */
|
|
3648
5549
|
get finance(): FinanceService;
|
|
5550
|
+
/** Fiscal service — lazy-initialized on first access */
|
|
5551
|
+
get fiscal(): FiscalService;
|
|
3649
5552
|
/** Groups service — lazy-initialized on first access */
|
|
3650
5553
|
get groups(): GroupsService;
|
|
3651
5554
|
/** Guests service — lazy-initialized on first access */
|
|
3652
5555
|
get guests(): GuestsService;
|
|
3653
5556
|
/** Housekeeping service — lazy-initialized on first access */
|
|
3654
5557
|
get housekeeping(): HousekeepingService;
|
|
5558
|
+
/** ID scanning service — lazy-initialized on first access */
|
|
5559
|
+
get idScanning(): IdScanningService;
|
|
5560
|
+
/** Intelligence service — lazy-initialized on first access */
|
|
5561
|
+
get intelligence(): IntelligenceService;
|
|
3655
5562
|
/** Night audit service — lazy-initialized on first access */
|
|
3656
5563
|
get nightAudit(): NightAuditService;
|
|
5564
|
+
/** Notifications service — lazy-initialized on first access */
|
|
5565
|
+
get notifications(): NotificationsService;
|
|
3657
5566
|
/** Payments service — lazy-initialized on first access */
|
|
3658
5567
|
get payments(): PaymentsService;
|
|
5568
|
+
/** Portfolios service — lazy-initialized on first access */
|
|
5569
|
+
get portfolios(): PortfoliosService;
|
|
3659
5570
|
/** Properties service — lazy-initialized on first access */
|
|
3660
5571
|
get properties(): PropertiesService;
|
|
3661
5572
|
/** Rate plans service — lazy-initialized on first access */
|
|
3662
5573
|
get ratePlans(): RatePlansService;
|
|
5574
|
+
/** Revenue service — lazy-initialized on first access */
|
|
5575
|
+
get revenue(): RevenueService;
|
|
3663
5576
|
/** Categories service — lazy-initialized on first access */
|
|
3664
5577
|
get categories(): CategoriesService;
|
|
5578
|
+
/** Discounts service — lazy-initialized on first access */
|
|
5579
|
+
get discounts(): DiscountsService;
|
|
5580
|
+
/** Reviews service — lazy-initialized on first access */
|
|
5581
|
+
get reviews(): ReviewsService;
|
|
5582
|
+
/** Settings service — lazy-initialized on first access */
|
|
5583
|
+
get settings(): SettingsService;
|
|
3665
5584
|
/** Spaces service — lazy-initialized on first access */
|
|
3666
5585
|
get spaces(): SpacesService;
|
|
3667
5586
|
/** Staff service — lazy-initialized on first access */
|
|
3668
5587
|
get staff(): StaffService;
|
|
5588
|
+
/** Supply service — lazy-initialized on first access */
|
|
5589
|
+
get supply(): SupplyService;
|
|
5590
|
+
/** Tasks service — lazy-initialized on first access */
|
|
5591
|
+
get tasks(): TasksService;
|
|
5592
|
+
/** Webhooks service — lazy-initialized on first access */
|
|
5593
|
+
get webhooks(): WebhooksService;
|
|
3669
5594
|
setApiKey(key: string): void;
|
|
3670
5595
|
setTenantId(id: string): void;
|
|
3671
5596
|
}
|
|
@@ -3748,4 +5673,4 @@ declare function firstPage<T>(fetcher: PageFetcher<T>, options?: PaginationOptio
|
|
|
3748
5673
|
|
|
3749
5674
|
declare const VERSION = "0.1.0";
|
|
3750
5675
|
|
|
3751
|
-
export { type AccountingDailyReport, type AccountingReportParams, type AccountingRevenueReport, type AccountingVatReport, type AppliedRestriction, 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 CreateBlockInput, type CreateBookingInput, type CreateCategoryInput, type CreateChannelInput, type CreateChargeInput, 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 CreateShiftInput, type CreateSpaceInput, type CreateStaffInput, DEFAULT_MODULES, type DatePickup, DistributionService, type DuplicateCandidate, FinanceService, type Folio, type FolioCharge, type FolioPayment, type FolioPostCharge, type FolioPostInput, type FolioPostItem, type FolioPostResult, type FolioStatus, ForbiddenError, 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 ListFolioPaymentsParams, type ListFolioPostParams, type ListFoliosParams, type ListGroupsParams, type ListGuestsParams, type ListHousekeepingTasksParams, type ListMappingsParams, type ListPaymentAccountsParams, type ListPropertiesParams, type ListRatePeriodsParams, type ListRatePlansParams, type ListShiftsParams, type ListSpacesParams, type ListStaffParams, type ListTransactionsParams, type Logger, type MergeGuestsInput, type MoveChargesInput, 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, PROPERTY_MODULES, type PageFetcher, type Paginated, type PaginatedBookings, type PaginatedChannels, type PaginatedCharges, 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 PaginatedStaff, type PaginatedSyncLog, 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 RunNightAuditInput, SPACE_STATUSES, SPACE_TYPES, type SearchGuestsParams, 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 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 UpdateGroupInput, type UpdateGuestInput, type UpdateGuestPreferences, type UpdateHousekeepingTaskInput, type UpdatePropertyInput, type UpdateRatePeriodInput, type UpdateRatePlanInput, type UpdateRateRestrictionInput, type UpdateSpaceInput, type UpdateSpaceStatusInput, type UpdateStaffInput, VERSION, ValidationError, type VatBreakdownEntry, bookingClientConfigSchema, createErrorFromResponse, firstPage, paginate };
|
|
5676
|
+
export { type AccountingDailyReport, type AccountingReportParams, type AccountingRevenueReport, type AccountingVatReport, type AddCompetitorInput, type AddPortfolioPropertyInput, 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 ChannelPreference, type ChannelSettings, type ChannelStatus, type ChannelType, type ChargeType, type CheckInInput, type CheckOutInput, type ComparePortfolioRatesInput, type ComparisonPeriod, type Competitor, type CompetitorRate, type CompetitorRateResponse, ConciergeService, type ConciergeTemplate, ConflictError, type Conversation, type ConversationContext, type ConversationContextBooking, type ConversationContextFaq, type ConversationContextGuest, type ConversationContextProperty, type ConversationMessage, type ConversationSortBy, type ConversationStatus, type Coordinates, type Coupon, type CouponStatus, type CouponValidation, type CreateBlockInput, type CreateBookingInput, type CreateCategoryInput, type CreateChannelInput, type CreateChargeInput, type CreateConversationInput, type CreateDiscountRuleInput, type CreateFolioInput, type CreateFolioPaymentInput, type CreateGroupFolioInput, type CreateGroupInput, type CreateGuestInput, type CreateHousekeepingTaskInput, type CreateInvoiceInput, type CreateMappingInput, type CreatePaymentAccountInput, type CreatePortfolioInput, type CreatePropertyInput, type CreateRatePeriodInput, type CreateRatePlanInput, type CreateReviewInput, type CreateReviewResponseInput, type CreateShiftInput, type CreateSpaceInput, type CreateStaffInput, type CreateSupplyItemInput, type CreateSupplyMovementInput, type CreateTaskInput, type CreateTemplateInput, type CreateWebhookSubscriptionInput, DEFAULT_MODULES, type DatePickup, type DateRange, type DiscountApplication, type DiscountRedemption, type DiscountRule, type DiscountRuleStatus, type DiscountSortBy, type DiscountType, type DiscountUsage, type DiscountUsageParams, type DiscountValueType, DiscountsService, type DismissSuggestionInput, DistributionService, type DocumentType, type DuplicateCandidate, type EscalateInput, type EscalationPriority, FinanceService, FiscalService, type FiscalSettings, type Folio, type FolioCharge, type FolioPayment, type FolioPostCharge, type FolioPostInput, type FolioPostItem, type FolioPostResult, type FolioStatus, ForbiddenError, type ForecastEntry, type ForecastModel, type GenerateCouponsInput, type GetBoardParams, type GetCompetitorRatesParams, type GetDashboardParams, type GetForecastParams, type GetKPIsParams, type GetNightAuditHistoryParams, type GetPaceReportParams, type GetPortfolioBreakdownParams, type GetPortfolioDashboardDataParams, type GetPortfolioDashboardParams, type GetPortfolioForecastParams, type GetRevenueReportParams, type Group, type GroupBlockSummary, type GroupFolioResult, type GroupStatus, type GroupType, GroupsService, type Guest, type GuestAddress, type GuestBookingSummary, type GuestDuplicateResult, type GuestFolioSummary, type GuestHistoryParams, type GuestIntelligence, type GuestMatch, type GuestOrderSummary, type GuestPreferences, type GuestSearchResult, type GuestSort, type GuestTag, 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 IdScan, IdScanningService, type IngestEventInput, type IntelligenceEvent, type IntelligenceEventStatus, type IntelligenceEventType, IntelligenceService, type Invoice, type InvoiceStatus, type IrisInitiateInput, type IrisTransfer, type IrisTransferStatus, type KPI, type KPIMetricName, type KPIResponse, type LinkPosTableInput, type ListBookingsParams, type ListCategoriesParams, type ListChannelsParams, type ListChargesParams, type ListCompetitorsParams, type ListConversationsParams, type ListDiscountRulesParams, type ListFolioPaymentsParams, type ListFolioPostParams, type ListFoliosParams, type ListGroupsParams, type ListGuestsParams, type ListHousekeepingTasksParams, type ListIntelligenceEventsParams, type ListLowStockParams, type ListMappingsParams, type ListMyDataSubmissionsParams, type ListPaymentAccountsParams, type ListPortfoliosParams, type ListPropertiesParams, type ListRatePeriodsParams, type ListRatePlansParams, type ListReviewsParams, type ListScansParams, type ListShiftsParams, type ListSpacesParams, type ListStaffParams, type ListSuggestionsParams, type ListSupplyItemsParams, type ListSupplyLevelsParams, type ListSupplyMovementsParams, type ListTasksParams, type ListTemplatesParams, type ListTransactionsParams, type ListTseTransactionsParams, type ListWebhookDeliveriesParams, type ListWebhookSubscriptionsParams, type Logger, type MergeGuestsInput, type MessageChannel, type MessageRole, type ModerateReviewInput, type ModerationAction, type MoveChargesInput, type MovementType, type MyDataInvoiceType, type MyDataQrResult, type MyDataSettings, type MyDataStatus, type MyDataSubmission, type MyDataSubmissionStatus, 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 NotificationCategory, type NotificationChannel, type NotificationPreferences, NotificationsService, type OccupancyData, type OccupancyStatus, type OcrResult, type OperationalTask, type OptOutInput, type OptOutResult, PROPERTY_MODULES, type PaceReport, type PaceReportEntry, type PageFetcher, type Paginated, type PaginatedBookings, type PaginatedChannels, type PaginatedCharges, type PaginatedCompetitors, type PaginatedConversations, type PaginatedDiscountRules, type PaginatedFolioPayments, type PaginatedFolioPostCharges, type PaginatedFolios, type PaginatedGroups, type PaginatedGuestBookings, type PaginatedGuestFolios, type PaginatedGuestOrders, type PaginatedGuests, type PaginatedHousekeepingTasks, type PaginatedIdScans, type PaginatedIntelligenceEvents, type PaginatedMappings, type PaginatedMyDataSubmissions, type PaginatedNightAuditRuns, type PaginatedPaymentAccounts, type PaginatedPortfolios, type PaginatedRatePeriods, type PaginatedRatePlans, type PaginatedReviews, type PaginatedStaff, type PaginatedSuggestions, type PaginatedSupplyItems, type PaginatedSupplyLevels, type PaginatedSupplyMovements, type PaginatedSyncLog, type PaginatedTasks, type PaginatedTemplates, type PaginatedTransactions, type PaginatedTseTransactions, type PaginatedWebhookDeliveries, type PaginatedWebhookSubscriptions, type PaginationOptions, type Payment, type PaymentAccount, type PaymentAccountStatus, PaymentError, type PaymentProvider, type PaymentStatus, PaymentsService, type Pickup, type Portfolio, type PortfolioBreakdown, type PortfolioBreakdownEntry, type PortfolioDashboard, type PortfolioDashboardData, type PortfolioForecast, type PortfolioForecastEntry, type PortfolioProperty, type PortfolioPropertyMetrics, type PortfolioPropertyRate, type PortfolioRateComparison, type PortfolioRatePushResult, type PortfolioSearchParams, type PortfolioSearchResponse, type PortfolioSearchResult, type PortfolioSearchType, type PortfolioSortBy, type PortfolioStatus, type PortfolioTargetResult, type PortfolioWithProperties, PortfoliosService, type PriceRange, type PricingParams, type PricingResult, type ProcessPaymentInput, PropertiesService, type Property, type PropertyAddress, type PropertyModule, type PropertyModules, type PropertySettings, type PropertyStatus, type PropertyType, type PullSyncInput, type PushPortfolioRatesInput, type PushSyncInput, type QrCodeFormat, type RateCalculation, RateLimitError, type RateModifier, type RatePeriod, type RatePlan, type RatePlanStatus, RatePlansService, type RateRestriction, type RateSuggestion, type Refund, type RefundInput, type RefundStatus, type ReleaseBlocksInput, type ReleaseResult, type ReportGranularity, type ReportGroupBy, type RequestOptions, type ResolveInput, type ResolvedBookingClientConfig, type RetryConfig, type RetryOptions, type RevenueBySource, type RevenueDashboard, type RevenueForecast, type RevenueReport, type RevenueReportEntry, RevenueService, 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 ScanStatus, type SearchGuestsParams, type SendMessageInput, type SendReviewRequestInput, ServerError, type ServiceSlotParams, type ServiceTimeSlot, SettingsService, type ShiftType, type Space, type SpaceCategory, type SpaceStatus, type SpaceType, SpacesService, type Staff, type StaffDepartment, type StaffRole, StaffService, type StaffShift, type StaffStatus, type SubmitMyDataInput, type SuggestionStatus, type SuggestionType, 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 TseClosureStatus, type TseDayClosure, type TseDayClosureInput, type TseExport, type TseExportFormat, type TseExportParams, type TseSettings, type TseStatus, type TseTransaction, type UpdateBookingInput, type UpdateCategoryInput, type UpdateChannelInput, type UpdateDiscountRuleInput, type UpdateFiscalSettingsInput, type UpdateFolioInput, type UpdateGroupInput, type UpdateGuestInput, type UpdateGuestPreferences, type UpdateHousekeepingTaskInput, type UpdateNotificationPreferencesInput, type UpdatePortfolioInput, type UpdatePropertyInput, type UpdatePropertySettingsInput, type UpdateRatePeriodInput, type UpdateRatePlanInput, type UpdateRateRestrictionInput, type UpdateReviewInput, type UpdateReviewResponseInput, type UpdateSpaceInput, type UpdateSpaceStatusInput, type UpdateStaffInput, type UpdateSupplyItemInput, type UpdateSupplyLevelInput, type UpdateTaskInput, type UpdateTemplateInput, type UpdateWebhookSubscriptionInput, type UploadScanInput, VERSION, type ValidateCouponInput, ValidationError, type VatBreakdownEntry, type WebhookDelivery, type WebhookDeliveryStatus, type WebhookEventType, type WebhookSubscription, WebhooksService, bookingClientConfigSchema, createErrorFromResponse, firstPage, paginate };
|