@peektravel/app-utilities 0.9.2 → 0.9.4

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/docs/webhooks.md CHANGED
@@ -60,7 +60,7 @@ the full price breakdown, so one registration captures everything; the parser
60
60
  auto-detects whatever a given payload carries.
61
61
 
62
62
  ```
63
- { displayId id primaryGuest { name email phone optinMarketing optinSms isGdpr postalCode } activitySnapshot { type name id } ticketQuantities { quantity resourceOptionSnapshot { name id } } reservationStatus checkinStatus returnStatus fulfillmentStatusOverride { status } timeSnapshot { id legacyId } purchasedAt purchasedAtUtc startsAt startsAtUtc endsAt endsAtUtc availabilityTimeId bookingPortalUrl operatorNotes value { convenienceFee { amount formatted } deposit { amount formatted } discount { amount formatted } discountedPrice { amount formatted } fees { amount formatted } flatPartnerFee { amount formatted } price { amount formatted } retailPrice { amount formatted } taxes { amount formatted } tips { amount formatted } total { formatted amount } } balance { total { amount formatted } } tips { price { amount formatted } } order { displayId id promoCodes { code } channelSnapshot { id name agent { name } } initialQuote { source { actor { app name } } } } questionAnswers { answer questionText questionLocationSnapshot { latitude longitude } } tickets { questionAnswers { answer questionText } } resourcePoolAssignments { quantity resourcePool { name shortName resources { name } } resourceAssignments { resource { id name } } } bookingGuests { id name country dateOfBirth email isGdpr isParticipant optinSms optinMarketing phone postalCode fieldResponses { id text fieldLocation { field { name } } } } primaryGuest { id name country dateOfBirth email isGdpr isParticipant optinSms optinMarketing phone postalCode fieldResponses { id text fieldLocation { field { name } } } } }
63
+ { displayId id primaryGuest { name email phone optinMarketing optinSms isGdpr postalCode } activitySnapshot { type name id } ticketQuantities { quantity resourceOptionSnapshot { name id } } reservationStatus checkinStatus returnStatus fulfillmentStatusOverride { status } timeSnapshot { id legacyId } purchasedAt purchasedAtUtc startsAt startsAtUtc endsAt endsAtUtc availabilityTimeId bookingPortalUrl operatorNotes operatorStatus value { convenienceFee { amount formatted } deposit { amount formatted } discount { amount formatted } discountedPrice { amount formatted } fees { amount formatted } flatPartnerFee { amount formatted } price { amount formatted } retailPrice { amount formatted } taxes { amount formatted } tips { amount formatted } total { formatted amount } } balance { total { amount formatted } } tips { price { amount formatted } } order { displayId id promoCodes { code } channelSnapshot { id name agent { name } } initialQuote { source { actor { app name } } } } questionAnswers { answer questionText questionLocationSnapshot { latitude longitude } } tickets { questionAnswers { answer questionText } } resourcePoolAssignments { quantity resourcePool { name shortName resources { name } } resourceAssignments { resource { id name } } } bookingGuests { id name country dateOfBirth email isGdpr isParticipant optinSms optinMarketing phone postalCode fieldResponses { id text fieldLocation { field { name } } } } primaryGuest { id name country dateOfBirth email isGdpr isParticipant optinSms optinMarketing phone postalCode fieldResponses { id text fieldLocation { field { name } } } } }
64
64
  ```
65
65
 
66
66
  > This package owns this string internally and snapshots it in
package/llms.txt CHANGED
@@ -133,12 +133,34 @@ final authority and may still reject the request.
133
133
  - `getDailyNoteService()` — `getToday()`, `update(note)`
134
134
  - `getAvailabilityService()` — `getAvailabilityTimes({activityId, date, resourceOptionQuantities})`
135
135
  - `getMembershipService()` — `getAll()`, `purchase(input)`
136
- - `getBookingService()` — `getById(id, opts?)`, `searchByTimeRange(input)`,
137
- `searchByTimeslot(id, opts?)`, `getGuests(id)`, `getPaymentsOnFile(id)`,
138
- `appendNote(id, note, mode?)`, `setCheckinStatus(id, checkedIn)`, `cancel(id, notes?)`,
136
+ - `getBookingService(integrator?)` — `getById(id, opts?)`, `searchByTimeRange(input)`,
137
+ `searchByTimeslot(id, opts?)`, `getGuests(id)`,
138
+ `getMetaData(id)` → `MetaData[]` (booking custom-field responses, `[]` when not
139
+ found; each `MetaData` carries a typed `value: MetaDataValue | null` discriminated
140
+ union plus a display-safe `displayValue` string on the `MetaData` itself (the
141
+ `html` value's is HTML-escaped); returns only fields whose slug starts with
142
+ `integrators:<integrator>:`,
143
+ that prefix stripped). The `integrator` arg on the accessor scopes
144
+ `getMetaData` — **do not set it** unless Peek engineering created a custom
145
+ integrator id for this integration.
146
+ Eight metadata setters (fixed `fieldName`, caller supplies the value;
147
+ integrator-scoped; return `SetMetaDataResult {success, bookingId, message}`;
148
+ not PII-gated): `setMetaDataGuest(id, guests: SetMetaDataGuestInput[])`
149
+ (name+email required), `setMetaDataAttachment(id, attachments:
150
+ SetMetaDataAttachmentInput[])` (name+attachmentUrl required),
151
+ `setMetaDataManifestUrl(id, url)`, `setMetaDataReservationId(id, reservationId)`,
152
+ `setMetaDataBookingStatus(id, status)`, `setMetaDataAssignedProduct(id, productName)`,
153
+ `setMetaDataAssignedEmployee(id, employeeName)`,
154
+ `setMetaDataInsurancePurchased(id, insurancePurchased)`. `getPaymentsOnFile(id)`,
155
+ `appendNote(id, note, mode?)`, `setCheckinStatus(id, checkedIn)`,
156
+ `updateCustomStatus(id, customStatus)` → `boolean` (sets the operator custom
157
+ status; not PII-gated), `cancel(id, notes?)`,
139
158
  `makePayment(input)`, `refund(input)`, `createInvoiceLink(id)`,
140
159
  `listAddons(id)`, `addAddon(id, {addonOptionId, quantity})`,
141
- `removeAddon(id, {addonOptionId, quantity})`, `create(input)`
160
+ `removeAddon(id, {addonOptionId, quantity})`, `create(input)` (optional
161
+ `input.listPrice` — total booking price string, commas allowed; split evenly
162
+ across tickets with the remainder cent on the last, sent per ticket in the
163
+ activity currency, fallback USD)
142
164
  - `getReviewService()` — `getReviews(productId, reviewCount?, reviewOffset?)`
143
165
  (single newest-first page of `Review`s, count 1–50, offset ≥ 0);
144
166
  `getAllReviewSummaries()` → `ProductReviewSummary[]` (one per activity:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@peektravel/app-utilities",
3
- "version": "0.9.2",
3
+ "version": "0.9.4",
4
4
  "description": "GraphQL JS mapping utilities extracted from the Peek Pro Autopilot connector.",
5
5
  "license": "MIT",
6
6
  "repository": {