@withnicer/sdk 0.0.0 → 1.0.0-beta.1

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.
Files changed (80) hide show
  1. package/README.md +89 -4
  2. package/dist/_/codec.d.ts +93 -0
  3. package/dist/_/codec.js +298 -0
  4. package/dist/_/error.d.ts +27 -0
  5. package/dist/_/error.js +68 -0
  6. package/dist/_/hooks/envelope.d.ts +11 -0
  7. package/dist/_/hooks/envelope.js +15 -0
  8. package/dist/_/index.d.ts +3 -0
  9. package/dist/_/index.js +5 -0
  10. package/dist/_/transport.d.ts +146 -0
  11. package/dist/_/transport.js +220 -0
  12. package/dist/activity/client.d.ts +42 -0
  13. package/dist/activity/client.js +18 -0
  14. package/dist/activity/index.d.ts +5 -0
  15. package/dist/activity/index.js +4 -0
  16. package/dist/activity/models.d.ts +65 -0
  17. package/dist/activity/models.js +3 -0
  18. package/dist/client.d.ts +1680 -0
  19. package/dist/client.js +748 -0
  20. package/dist/crmSettings/client.d.ts +50 -0
  21. package/dist/crmSettings/client.js +25 -0
  22. package/dist/crmSettings/index.d.ts +5 -0
  23. package/dist/crmSettings/index.js +4 -0
  24. package/dist/crmSettings/models.d.ts +313 -0
  25. package/dist/crmSettings/models.js +3 -0
  26. package/dist/crmTrips/client.d.ts +100 -0
  27. package/dist/crmTrips/client.js +38 -0
  28. package/dist/crmTrips/index.d.ts +5 -0
  29. package/dist/crmTrips/index.js +4 -0
  30. package/dist/crmTrips/models.d.ts +193 -0
  31. package/dist/crmTrips/models.js +3 -0
  32. package/dist/crmTrips/travelers/client.d.ts +33 -0
  33. package/dist/crmTrips/travelers/client.js +18 -0
  34. package/dist/crmTrips/travelers/index.d.ts +5 -0
  35. package/dist/crmTrips/travelers/index.js +4 -0
  36. package/dist/crmTrips/travelers/models.d.ts +14 -0
  37. package/dist/crmTrips/travelers/models.js +3 -0
  38. package/dist/index.d.ts +5 -0
  39. package/dist/index.js +4 -0
  40. package/dist/me/client.d.ts +56 -0
  41. package/dist/me/client.js +25 -0
  42. package/dist/me/index.d.ts +5 -0
  43. package/dist/me/index.js +4 -0
  44. package/dist/me/models.d.ts +95 -0
  45. package/dist/me/models.js +3 -0
  46. package/dist/models.d.ts +9269 -0
  47. package/dist/models.js +4 -0
  48. package/dist/notes/client.d.ts +82 -0
  49. package/dist/notes/client.js +41 -0
  50. package/dist/notes/index.d.ts +5 -0
  51. package/dist/notes/index.js +4 -0
  52. package/dist/notes/models.d.ts +116 -0
  53. package/dist/notes/models.js +3 -0
  54. package/dist/options/index.d.ts +52 -0
  55. package/dist/options/index.js +53 -0
  56. package/dist/profileForms/client.d.ts +38 -0
  57. package/dist/profileForms/client.js +25 -0
  58. package/dist/profileForms/index.d.ts +5 -0
  59. package/dist/profileForms/index.js +4 -0
  60. package/dist/profileForms/models.d.ts +24 -0
  61. package/dist/profileForms/models.js +3 -0
  62. package/dist/taskTemplates/client.d.ts +36 -0
  63. package/dist/taskTemplates/client.js +18 -0
  64. package/dist/taskTemplates/index.d.ts +5 -0
  65. package/dist/taskTemplates/index.js +4 -0
  66. package/dist/taskTemplates/models.d.ts +15 -0
  67. package/dist/taskTemplates/models.js +3 -0
  68. package/dist/tasks/client.d.ts +105 -0
  69. package/dist/tasks/client.js +41 -0
  70. package/dist/tasks/index.d.ts +5 -0
  71. package/dist/tasks/index.js +4 -0
  72. package/dist/tasks/models.d.ts +59 -0
  73. package/dist/tasks/models.js +3 -0
  74. package/dist/travelers/client.d.ts +214 -0
  75. package/dist/travelers/client.js +76 -0
  76. package/dist/travelers/index.d.ts +5 -0
  77. package/dist/travelers/index.js +4 -0
  78. package/dist/travelers/models.d.ts +576 -0
  79. package/dist/travelers/models.js +3 -0
  80. package/package.json +35 -2
@@ -0,0 +1,1680 @@
1
+ import { type BaseClientOptions, type RequestOptions, Transport } from "./_/index.js";
2
+ import { type Client as ActivityClient } from "./activity/client.js";
3
+ import { type Client as CrmSettingsClient } from "./crmSettings/client.js";
4
+ import { type Client as CrmTripsClient } from "./crmTrips/client.js";
5
+ import { type Client as MeClient } from "./me/client.js";
6
+ import { type AddOfferBody, type AddOfferResponse as AddOfferResponse$, type AirportCode, type ApproveSegmentBody, type ApproveSegmentResponse as ApproveSegmentResponse$, type BalancesGetResponse as BalancesGetResponse$, type CarDiscoveryDetails, type CarDiscoveryResponse, type CarriersResponse, type ChatReplyBody, type ChatReplyResponse as ChatReplyResponse$, type CheckoutCreateBody, type CheckoutCreateResponse as CheckoutCreateResponse$, type CommissionExport, type CommissionExportCreateBody, type CommissionExportsListResponse as CommissionExportsListResponse$, type CommissionImport, type CommissionImportActionRunBody, type CommissionImportCreateBody, type CommissionImportCreateResponse as CommissionImportCreateResponse$, type CommissionImportGetResponse as CommissionImportGetResponse$, type CommissionItemActionRunBody, type CommissionItemActionRunResponse as CommissionItemActionRunResponse$, type CommissionItemDetail, type CommissionItemsListResponse as CommissionItemsListResponse$, type CommissionReport, type CommissionSummary, type CommissionTag, type CreateBookingSelectionBody, type CreateBookingSelectionResponse as CreateBookingSelectionResponse$, type CreateInsuranceQuotesBody, type CreateInsuranceQuotesResponse as CreateInsuranceQuotesResponse$, type CreateItineraryDocumentBody, type CreateItineraryDocumentResponse as CreateItineraryDocumentResponse$, type CreateQuoteRequest as CreateQuoteRequest$, type CreateTravelersTripBody, type CreateTravelersTripResponse as CreateTravelersTripResponse$, type CurrencyCode, type DeleteFavoriteResponse as DeleteFavoriteResponse$, type DiscoverHotelDetailsResponse as DiscoverHotelDetailsResponse$, type EarningsListResponse as EarningsListResponse$, type ExternalBooking, type ExternalBookingCreateBody, type ExternalBookingUpdateBody, type ExternalPaymentRecordBody, type Favorite, type FavoriteKind, type FlightDetailsResponse, type FlightDiscoveryResponse, type FlightLookupResponse, type FlightSort, type GetBookingSelectionResponse as GetBookingSelectionResponse$, type GetFavoritesShareResponse as GetFavoritesShareResponse$, type GetOfferRequirementsResponse as GetOfferRequirementsResponse$, type GetSharedFavoritesResponse as GetSharedFavoritesResponse$, type GetTravelersTripResponse as GetTravelersTripResponse$, type GetTripItineraryAgentViewResponse as GetTripItineraryAgentViewResponse$, type HotelDiscoveryResponse, type ListFavoritesResponse as ListFavoritesResponse$, type ListTravelersTripResponse as ListTravelersTripResponse$, type OrderActionRunBody, type OrderActionRunResponse as OrderActionRunResponse$, type OrderAdvisorAssignBody, type OrderAdvisorAssignResponse as OrderAdvisorAssignResponse$, type OrderConfirmationSendBody, type OrderConfirmationSendResponse as OrderConfirmationSendResponse$, type OrderCreateBody, type OrderCreateResponse as OrderCreateResponse$, type OrderGetResponse as OrderGetResponse$, type OrderPaymentSubmitBody, type OrderPaymentSubmitResponse as OrderPaymentSubmitResponse$, type OrdersListResponse as OrdersListResponse$, type PayeeActionRunBody, type PayeeActionRunResponse as PayeeActionRunResponse$, type PayeesListResponse as PayeesListResponse$, type PaymentMethodActionRunBody, type PaymentMethodCardLinkCompleteResponse, type PlaceDetails, type PlacesResponse, type QuoteOutcomeResponse, type RemittanceAction, type RemittanceBatchAction, type RemittanceBatchActionRunResponse as RemittanceBatchActionRunResponse$, type RemittanceBatchCreateBody, type RemittanceBatchCreateResponse as RemittanceBatchCreateResponse$, type RemittanceBatchGetResponse as RemittanceBatchGetResponse$, type RemittanceBatchesListResponse as RemittanceBatchesListResponse$, type RemittanceClaim, type RemittanceCreateBody, type RemittanceDetail, type RemittanceLineClaimBody, type RemittanceSuggestionsGetResponse as RemittanceSuggestionsGetResponse$, type RemittancesListResponse as RemittancesListResponse$, type SaveFavoriteBody, type SearchProductsBody, type SegmentOpBody, type SelectOptionBody, type SelectOptionResponse as SelectOptionResponse$, type SendTripItineraryBody, type ShareFavoritesBody, type ShareFavoritesResponse as ShareFavoritesResponse$, type StatementActionRunBody, type StatementActionRunResponse as StatementActionRunResponse$, type StatementDetail, type StatementsListResponse as StatementsListResponse$, type StopSharingFavoritesResponse as StopSharingFavoritesResponse$, type SupplierActionRunBody, type SupplierCreateBody, type SupplierDetail, type SuppliersSearchResponse as SuppliersSearchResponse$, type ToggleArchiveBody, type ToggleArchiveResponse as ToggleArchiveResponse$, type TravelersTripInviteBody, type TravelersTripToggleArchiveBody, type TravelersTripToggleArchiveResponse as TravelersTripToggleArchiveResponse$, type UpdateTravelersTripBody, type UpdateTripItineraryBody, type UpdateTripItineraryResponse as UpdateTripItineraryResponse$ } from "./models.js";
7
+ import { type Client as NotesClient } from "./notes/client.js";
8
+ import { type Client as ProfileFormsClient } from "./profileForms/client.js";
9
+ import { type Client as TaskTemplatesClient } from "./taskTemplates/client.js";
10
+ import { type Client as TasksClient } from "./tasks/client.js";
11
+ import { type Client as TravelersClient } from "./travelers/client.js";
12
+ export interface ClientOptions extends BaseClientOptions {
13
+ /**
14
+ * The URL the paths of the API are relative to.
15
+ */
16
+ baseUrl: string;
17
+ }
18
+ export interface Client {
19
+ /**
20
+ * Add a live offer to the itinerary
21
+ *
22
+ * Adds a live offer (hotel room, flight or car rental) to the itinerary as a
23
+ * bookable segment: it re-validates the offer with the provider, saves it as
24
+ * a booking selection and writes the segment, in one call. Adding the same
25
+ * offer to the same trip again returns the segment already there. `status` is
26
+ * `OK` with the segment id, or `UNAVAILABLE` when the offer is gone (search
27
+ * again). A Sabre offer with no DK to book with (the advisor has none and the
28
+ * agency has no default DK) is refused with 422 `BOOKING_SABRE_DK_REQUIRED`.
29
+ */
30
+ addOffer(request: AddOfferRequest, options?: RequestOptions): Promise<AddOfferResponse>;
31
+ /**
32
+ * Approve a segment from a shared link
33
+ *
34
+ * Marks one segment of a shared itinerary as approved by the traveler.
35
+ * Reachable without a token so it works from the traveler's itinerary link,
36
+ * where the itinerary id is the only credential, and rate-limited per IP
37
+ * address.
38
+ */
39
+ approveSegment(request: ApproveSegmentRequest, options?: RequestOptions): Promise<ApproveSegmentResponse>;
40
+ /**
41
+ * Get account balances
42
+ *
43
+ * Returns the company's ledger balances by beneficiary and currency,
44
+ * optionally narrowed to one beneficiary or to a beneficiary kind (advisor,
45
+ * company, traveler or the platform). A bucket below zero is money still
46
+ * owed: it counts as receivable, never as a negative balance. Advisors and
47
+ * travelers see their own; admins anyone's of the company, and Nicer staff
48
+ * anyone's of the company they name in `x-nicer-company` (each staff read is
49
+ * audited).
50
+ */
51
+ balancesGet(request?: BalancesGetRequest, options?: RequestOptions): Promise<BalancesGetResponse>;
52
+ /**
53
+ * Get a chat with messages and users
54
+ *
55
+ * Returns the chat view, a page of messages with per-participant seen flags,
56
+ * and the user records of participants, past authors and synthetic system
57
+ * senders, and marks the chat read for the caller. The caller must have
58
+ * access to the channel.
59
+ */
60
+ chatGet(request: ChatGetRequest, options?: RequestOptions): Promise<ChatGetResponse>;
61
+ /**
62
+ * List chats in the caller's inbox
63
+ *
64
+ * Lists chats ordered by last activity with participant summaries, unread
65
+ * counts, archive state and whether the trip has an open order. `fields`
66
+ * names the parts of a row to return (dotted for nested, `-` to remove one);
67
+ * omitted, a row carries everything but the trip's destination photo
68
+ * galleries, which are three quarters of the body and which no screen reads.
69
+ * The default scope is the caller's own chats; company scope requires a
70
+ * company admin and all-chats scope requires a superadmin, returning 403
71
+ * otherwise.
72
+ */
73
+ chatList(request?: ChatListRequest, options?: RequestOptions): Promise<ChatListResponse>;
74
+ /**
75
+ * Post a message to a chat
76
+ *
77
+ * Appends a message, text and/or attachment URLs, to the chat, updates the
78
+ * channel's last-message time and the author's read mark, and emits a
79
+ * conversation-created event. Requires message text or at least one asset;
80
+ * assets must be reachable HTTPS URLs and text is capped at 10,000
81
+ * characters. Returns the stored row with HTML stripped from the plain text
82
+ * and a rendered HTML copy.
83
+ */
84
+ chatReply(request: ChatReplyRequest, options?: RequestOptions): Promise<ChatReplyResponse>;
85
+ /**
86
+ * Prepare an unpaid checkout from an offer
87
+ *
88
+ * Turns a live search offer into an unpaid order: it re-validates the offer
89
+ * with the provider, prices it, and creates the order on the trip;
90
+ * `paymentUrl` is null, and `createPaymentLink` makes the link. Nothing is
91
+ * paid, held or reserved. Calling it twice for the same offer on the same
92
+ * trip returns the same order rather than a second one — the key is the offer
93
+ * and the trip, so no caller has to invent one. `status` is `OK` with the
94
+ * order, `PRICE_CHANGED` when the provider now charges something else (search
95
+ * again and use the new offer), or `UNAVAILABLE` when the offer is gone.
96
+ */
97
+ checkoutCreate(request: CheckoutCreateRequest, options?: RequestOptions): Promise<CheckoutCreateResponse>;
98
+ /**
99
+ * Export a commission list
100
+ *
101
+ * Queues an export of a commission list (items, payments, remittances,
102
+ * statements, suppliers, payees, payouts, commission invoices or earnings) as
103
+ * CSV, XLSX or PDF, with a preset or ad-hoc columns, or AGENCY: everything of
104
+ * the company in one ZIP archive, `<company> commission <YYYY-MM-DD>.zip`,
105
+ * with a CSV file of each list holding all of its columns (AGENCY takes
106
+ * nothing but its subject); and answers it QUEUED. A Rust worker pages
107
+ * through the rows and streams them to the file; GET the export until it is
108
+ * READY to receive a link that works for 15 minutes. The file is kept 7 days.
109
+ * Advisors export their own bookings and statements; agency admins and
110
+ * finance staff anything of the company (payees never with a legal name).
111
+ * Columns must belong to the subject (400), CSV holds 2,000,000 rows (so does
112
+ * each file of an archive), XLSX 1,048,575, PDF 10,000 and an archive 4 GiB
113
+ * (the export fails COMMISSION_EXPORT_TOO_LARGE past them). A company may
114
+ * have 3 exports queued or running, an archive counting as one (429
115
+ * COMMISSION_RATE_LIMITED). The request and its filter are audited.
116
+ */
117
+ commissionExportCreate(request: CommissionExportCreateRequest, options?: RequestOptions): Promise<CommissionExportCreateResponse>;
118
+ /**
119
+ * Get a commission export
120
+ *
121
+ * One export and its progress. While READY, each read signs a download link
122
+ * that works for 15 minutes and records the download in the audit log; after
123
+ * 7 days the export answers EXPIRED without a link. Advisors read the exports
124
+ * they requested; agency admins and finance staff any export of the company.
125
+ * Another company's export answers 404.
126
+ */
127
+ commissionExportGet(request: CommissionExportGetRequest, options?: RequestOptions): Promise<CommissionExportGetResponse>;
128
+ /**
129
+ * List commission exports
130
+ *
131
+ * The company's exports, newest first (25 by default, at most 100,
132
+ * keyset-paged), without download links. Advisors see the exports they
133
+ * requested; agency admins and finance staff all of the company's.
134
+ */
135
+ commissionExportsList(request?: CommissionExportsListRequest, options?: RequestOptions): Promise<CommissionExportsListResponse>;
136
+ /**
137
+ * Run an action on an import of bookings
138
+ *
139
+ * APPLY_MAPPING re-reads the rows with a new mapping (status PARSING, then
140
+ * READY); MAP_ADVISORS (admins and staff) replaces the emails-to-members map
141
+ * and re-reads the rows; SAVE_PRESET keeps the mapping for the company's next
142
+ * files; COMMIT creates one booking made elsewhere with its commission item
143
+ * per valid row, as a resumable job (status COMMITTING, then COMMITTED;
144
+ * duplicates are skipped and counted; a commit that failed stays COMMITTING
145
+ * and resumes when COMMIT is asked again); DISCARD drops a file that was not
146
+ * committed. Each action is audited.
147
+ */
148
+ commissionImportActionRun(request: CommissionImportActionRunRequest, options?: RequestOptions): Promise<CommissionImportActionRunResponse>;
149
+ /**
150
+ * Import a file of bookings
151
+ *
152
+ * Registers a file of bookings made elsewhere (CSV, TSV, TXT or XLSX, up to
153
+ * 100 MiB) and answers a presigned upload. Once S3 has the file, a worker
154
+ * reads it (status PARSING, then READY with the column names and the rows as
155
+ * the mapping reads them). The same file twice answers 409
156
+ * COMMISSION_FILE_ALREADY_IMPORTED. Poll `GET
157
+ * /commission-imports/{importId}`. Admins may map the emails a file names to
158
+ * members (`advisors`).
159
+ */
160
+ commissionImportCreate(request: CommissionImportCreateRequest, options?: RequestOptions): Promise<CommissionImportCreateResponse>;
161
+ /**
162
+ * Get an import of bookings
163
+ *
164
+ * An import with a page of its rows (50 by default, at most 200, in file
165
+ * order; `status` keeps one kind of row): the cells as read (cleared once the
166
+ * import is committed), the values the mapping makes of them, and why a row
167
+ * is invalid or a duplicate. An advisor gets their own imports only, and of
168
+ * the emails mapped to members (`advisors`) only those mapped to them.
169
+ * Another company's import answers 404.
170
+ */
171
+ commissionImportGet(request: CommissionImportGetRequest, options?: RequestOptions): Promise<CommissionImportGetResponse>;
172
+ /**
173
+ * Run an action on a commission item
174
+ *
175
+ * One action on a commission item. Advisors (on their own items), admins and
176
+ * staff: CHANGE_EXPECTED (on an item of a Nicer checkout it also clears
177
+ * `needsReview`, which such an item carries when its provider marked the rate
178
+ * commissionable without an amount), CHANGE_DATES (the due date follows
179
+ * unless it was set by hand; an item of a booking made elsewhere takes its
180
+ * dates from the booking's PUT, and this answers 400), SET_DUE_DATE, CANCEL,
181
+ * REOPEN a cancellation, CONFIRM_IMPORTED (an imported item only; a Nicer
182
+ * checkout item answers 409 COMMISSION_ITEM_NOT_IMPORTED), SET_FLAG,
183
+ * ADD_NOTE, SET_TAGS, ADD_ATTACHMENT (answers a presigned upload),
184
+ * REPORT_MISSING (after travel, while money is owed: the item is flagged and
185
+ * the note joins its notes, for whoever chases the supplier; 409
186
+ * COMMISSION_ITEM_NOT_CHASEABLE otherwise). Admins and staff:
187
+ * SET_COMMISSIONABLE (making a Nicer checkout item commissionable with
188
+ * nothing expected or received puts it in review, for its amount to be
189
+ * entered), WRITE_OFF, REOPEN a write-off, REASSIGN_ADVISOR. Changes to
190
+ * money, dates and parties send the `expectationVersion` read and write a
191
+ * revision; a newer change answers 409 COMMISSION_RECORD_CHANGED, a cancelled
192
+ * or written-off item 409 COMMISSION_ITEM_CLOSED, a new identifier once money
193
+ * arrived 409 COMMISSION_IDENTIFIER_LOCKED. An item Nicer collected
194
+ * (`collectedByNicer`: a planning fee, a Smith hotel) takes only SET_FLAG,
195
+ * ADD_NOTE, SET_TAGS and ADD_ATTACHMENT; anything else answers 409
196
+ * COMMISSION_ITEM_NICER_COLLECTED.
197
+ */
198
+ commissionItemActionRun(request: CommissionItemActionRunRequest, options?: RequestOptions): Promise<CommissionItemActionRunResponse>;
199
+ /**
200
+ * Get a commission item
201
+ *
202
+ * One commission item: its status and money, the booking facts, the
203
+ * identifier it was booked under, every revision, notes, attachments, and the
204
+ * actions the caller may run now. An advisor reads their own items; an admin
205
+ * the agency's, and a host the items it receives money for. Another company's
206
+ * item answers 404.
207
+ */
208
+ commissionItemGet(request: CommissionItemGetRequest, options?: RequestOptions): Promise<CommissionItemGetResponse>;
209
+ /**
210
+ * List commission items
211
+ *
212
+ * The commission list of every booking, whatever its source (Nicer checkout,
213
+ * GDS import, booked elsewhere, file import), with status, balance, due date
214
+ * and aging from `commission_item_status`. Keyset-paged on the date field
215
+ * (travel end by default), newest first; 25 per page, at most 100. Advisors
216
+ * see their own bookings; admins the agency's; `view=RECEIVABLES` lists what
217
+ * the agency receives as the owner of the identifier (a host sees its
218
+ * members' items; admins and staff). Finance staff may read any company,
219
+ * audited.
220
+ */
221
+ commissionItemsList(request?: CommissionItemsListRequest, options?: RequestOptions): Promise<CommissionItemsListResponse>;
222
+ /**
223
+ * Get a commission report
224
+ *
225
+ * A commission report of the company, keyset-paged (50 rows by default, at
226
+ * most 200), with totals per currency over the whole report.
227
+ * PRODUCTION_BY_SUPPLIER, PRODUCTION_BY_ADVISOR and PRODUCTION_BY_DESTINATION
228
+ * (by the supplier's country) add up the items of whole months, by when their
229
+ * travel ends (`basis` TRAVEL_END, the default), starts (TRAVEL_START, Sion's
230
+ * Check In) or they were booked (BOOKED, Sion's Created At), as they stand
231
+ * when read (an item booked with a supplier since merged counts under the
232
+ * survivor), largest expected first; PRODUCTION_BY_CLIENT reads the items by
233
+ * client name; RECEIVABLES_AGING is what suppliers owe today by aging bucket,
234
+ * largest balance first; RECONCILIATION_EXCEPTIONS lists unmatched and
235
+ * pending-review lines, overpaid items and pending claims, newest first;
236
+ * SUPPLIER_DIRECTORY lists every supplier the company sees (Nicer's shared
237
+ * directory and its own, merged ones under their survivor), first those with
238
+ * items in the period's whole months by revenue in the reporting currency (US
239
+ * dollars), then the others by name, filtered by name, supplier kind,
240
+ * verification, country and city, preferred programs and agency identifiers,
241
+ * with the totals of the period it compares with (`compare`: PREVIOUS_PERIOD,
242
+ * the default, the same number of whole months just before;
243
+ * SAME_PERIOD_LAST_YEAR the same days a year earlier; NONE none), and an
244
+ * exact count of the suppliers up to 10,000. Production and receivables rows
245
+ * also carry their amounts in the reporting currency (`reporting…`) and the
246
+ * report its `reportingTotals`, every currency added up, in
247
+ * `reportingCurrency`, counted as Sion counts them: each item converts on its
248
+ * own and rounds half up, its revenue at its frozen rate (the check-out
249
+ * day's, frozen when its first money arrived or it was written off; the
250
+ * latest rate on or before today until then), its commission what it received
251
+ * once paid (dollars as they arrived), else its expected amount at today's
252
+ * rate. An item that needs today's rate in a currency with none is left out,
253
+ * its row reads null and its currency is in `unconvertedCurrencies`. The
254
+ * period is the current year unless `from` or `to` is given. Advisors read
255
+ * production, receivables and the directory of their own bookings only; the
256
+ * other reports are for agency admins and finance staff (403 otherwise); a
257
+ * parameter the report does not take answers 400. Finance staff may read any
258
+ * company, audited.
259
+ */
260
+ commissionReportGet(request: CommissionReportGetRequest, options?: RequestOptions): Promise<CommissionReportGetResponse>;
261
+ /**
262
+ * Get the commission summary
263
+ *
264
+ * The commission dashboard for the same filter as the list: totals per
265
+ * currency (expected, received, balance, overdue, due in the next 30 days),
266
+ * counts and amounts by status and by aging bucket, and the ten suppliers
267
+ * that owe the most; and the same in the reporting currency
268
+ * (`reportingTotals`, `reportingByStatus` with the revenue,
269
+ * `reportingByAgingBucket`, `reportingTopSuppliers`, in `reportingCurrency`,
270
+ * US dollars, counted as Sion counts them: each item's revenue at its rate
271
+ * frozen when its first money arrived or it was written off, today's until
272
+ * then; its commission what it received once paid, else its expected amount
273
+ * at today's rate; items needing a rate their currency lacks are left out and
274
+ * named in `unconvertedCurrencies`). Without `from`/`to` the period is the
275
+ * current calendar year on the date field. Cancelled and written-off items
276
+ * count by status but not in balances; an item that earns nothing reads
277
+ * UPCOMING until its travel ends, then PAID.
278
+ */
279
+ commissionSummaryGet(request?: CommissionSummaryGetRequest, options?: RequestOptions): Promise<CommissionSummaryGetResponse>;
280
+ /**
281
+ * Save an offer as a booking selection
282
+ *
283
+ * Re-validates a live search offer with the provider and stores it as a
284
+ * selection that stays bookable until `bookableUntil` (retained 30 days).
285
+ * Requires an authenticated company user and an `Idempotency-Key`; replaying
286
+ * the key with a different body returns 409
287
+ * `BOOKING_SELECTION_IDEMPOTENCY_CONFLICT`, an expired or unknown offer
288
+ * returns 409 `BOOKING_OFFER_UNAVAILABLE`, and a Sabre offer with no DK to
289
+ * book with (the advisor has none and the agency has no default DK) returns
290
+ * 422 `BOOKING_SABRE_DK_REQUIRED`. Returns the selection id and a preview of
291
+ * product, price and payment terms; the preview carries the commercial
292
+ * snapshot (expected commission and earnings) only for the agency's advisors
293
+ * and admins and for Nicer staff, and leaves it out for travelers.
294
+ */
295
+ createBookingSelection(request: CreateBookingSelectionRequest, options?: RequestOptions): Promise<CreateBookingSelectionResponse>;
296
+ /**
297
+ * Quote travel insurance for a trip
298
+ *
299
+ * Requests travel-insurance quotes for the trip's insurable itinerary items
300
+ * plus any `customItems`, using the trip's start and end dates as coverage
301
+ * dates. Requires an authenticated company user with access to the trip, an
302
+ * `Idempotency-Key`, and a trip that has both dates (otherwise 409
303
+ * `INSURANCE_TRIP_DATES_REQUIRED`). Returns the quotes, which segments were
304
+ * insurable and selected, and the per-traveler fields still missing.
305
+ */
306
+ createInsuranceQuotes(request: CreateInsuranceQuotesRequest, options?: RequestOptions): Promise<CreateInsuranceQuotesResponse>;
307
+ /**
308
+ * Upload an itinerary PDF for import
309
+ *
310
+ * Starts importing an itinerary PDF: returns a presigned S3 form that the
311
+ * browser posts one PDF of up to 25 MB to. Once it is uploaded, the segments
312
+ * read from the PDF are added to the itinerary (mode merge) or replace its
313
+ * segments (mode replace). Requires the trip's advisor or an admin.
314
+ */
315
+ createItineraryDocument(request: CreateItineraryDocumentRequest, options?: RequestOptions): Promise<CreateItineraryDocumentResponse>;
316
+ /**
317
+ * Create a bookable quote from an offer
318
+ *
319
+ * Re-validates a live offer (by `offerReference`, or by an existing
320
+ * `bookingSelectionId`) against the provider and stores an immutable quote
321
+ * with price, payment terms and participant requirements. Requires an
322
+ * `Idempotency-Key` header and an `x-nicer-company` header; the caller may be
323
+ * anonymous. Returns `OK`, `PRICE_CHANGED` (with `previousPrice` and
324
+ * `requiresAcceptance`) or `UNAVAILABLE` with a `reasonCode`. The quote
325
+ * carries the commercial snapshot (expected commission and earnings) only for
326
+ * the agency's advisors and admins and for Nicer staff; travelers and
327
+ * anonymous callers get the quote without it. A Sabre offer books under the
328
+ * advisor's own DK, else the agency's default DK; with neither, the quote is
329
+ * refused with 422 `BOOKING_SABRE_DK_REQUIRED` before Sabre is called.
330
+ */
331
+ createQuote(request: CreateQuoteRequest, options?: RequestOptions): Promise<CreateQuoteResponse>;
332
+ /**
333
+ * Create a trip
334
+ *
335
+ * Opens a trip: the container every itinerary, proposal, message and order
336
+ * hangs off. Send at least a title, the travel dates and one destination. The
337
+ * trip is created together with its itinerary and its conversation, so a
338
+ * single call is enough to start planning. Dates accept any parseable date
339
+ * string and are stored as `YYYY-MM-DD`; the start date cannot be in the past
340
+ * and the end date must come after it.
341
+ */
342
+ createTravelersTrip(request: CreateTravelersTripRequest, options?: RequestOptions): Promise<CreateTravelersTripResponse>;
343
+ /**
344
+ * Remove a saved place
345
+ *
346
+ * Removes a saved place from the caller's list. Removing a place that is not
347
+ * saved succeeds too, so a double tap never errors.
348
+ */
349
+ deleteFavorite(request: DeleteFavoriteRequest, options?: RequestOptions): Promise<DeleteFavoriteResponse>;
350
+ /**
351
+ * Search tour destinations
352
+ *
353
+ * Text search over the activities provider destinations, optionally bounded
354
+ * by a radius, used to anchor an activity search to a place.
355
+ */
356
+ destinationsQuery(request: DestinationsQueryRequest, options?: RequestOptions): Promise<DestinationsQueryResponse>;
357
+ /**
358
+ * DiscoverCarRentalDetails
359
+ *
360
+ * JSON is the default; Accept: text/event-stream or format=stream requests
361
+ * SSE.
362
+ */
363
+ discoverCarRentalDetails(request: DiscoverCarRentalDetailsRequest, options?: RequestOptions): Promise<DiscoverCarRentalDetailsResponse>;
364
+ /**
365
+ * DiscoverCarRentals
366
+ *
367
+ * JSON is the default; Accept: text/event-stream or format=stream requests
368
+ * SSE.
369
+ */
370
+ discoverCarRentals(request: DiscoverCarRentalsRequest, options?: RequestOptions): Promise<DiscoverCarRentalsResponse>;
371
+ /**
372
+ * DiscoverFlightDetails
373
+ *
374
+ * JSON is the default; Accept: text/event-stream or format=stream requests
375
+ * SSE.
376
+ */
377
+ discoverFlightDetails(request: DiscoverFlightDetailsRequest, options?: RequestOptions): Promise<DiscoverFlightDetailsResponse>;
378
+ /**
379
+ * DiscoverFlights
380
+ *
381
+ * JSON is the default; Accept: text/event-stream or format=stream requests
382
+ * SSE.
383
+ */
384
+ discoverFlights(request?: DiscoverFlightsRequest, options?: RequestOptions): Promise<DiscoverFlightsResponse>;
385
+ /**
386
+ * DiscoverHotelDetails
387
+ *
388
+ * Public hotel API. Send x-nicer-company when an optional verified Cognito
389
+ * token does not identify one company. No trip or company-registration lookup
390
+ * is required. Accept selects JSON or SSE on this resource; repeat the same
391
+ * criteria URL after partial results. Search and details run in separate
392
+ * Lambdas. Hotel path identifiers are hotelReference values.
393
+ */
394
+ discoverHotelDetails(request: DiscoverHotelDetailsRequest, options?: RequestOptions): Promise<DiscoverHotelDetailsResponse>;
395
+ /**
396
+ * DiscoverHotels
397
+ *
398
+ * Public hotel API. Send x-nicer-company when an optional verified Cognito
399
+ * token does not identify one company. No trip or company-registration lookup
400
+ * is required. Accept selects JSON or SSE on this resource; repeat the same
401
+ * criteria URL after partial results. Search and details run in separate
402
+ * Lambdas. Hotel path identifiers are hotelReference values.
403
+ */
404
+ discoverHotels(request: DiscoverHotelsRequest, options?: RequestOptions): Promise<DiscoverHotelsResponse>;
405
+ /**
406
+ * List advisor earnings
407
+ *
408
+ * Lists the company's earning entries, the last changed first, optionally
409
+ * filtered by beneficiary and status: a page of `limit` (50 by default, 200
410
+ * at most), with `nextCursor` to send back as `cursor` while more remain.
411
+ * Advisors and travelers see their own; admins anyone's of the company, and
412
+ * Nicer staff anyone's of the company they name in `x-nicer-company` (each
413
+ * staff read is audited).
414
+ */
415
+ earningsList(request?: EarningsListRequest, options?: RequestOptions): Promise<EarningsListResponse>;
416
+ /**
417
+ * Record a booking made elsewhere
418
+ *
419
+ * Records a booking made outside Nicer (with a cruise line, a DMC, another
420
+ * platform) and the commission items it earns, in one transaction with their
421
+ * audit rows. The supplier is one from the directory or a name; the
422
+ * identifier defaults to the agency's (a host's for a hosted agency); payment
423
+ * terms resolve from the item, the agency's terms with the supplier, the
424
+ * supplier, the category, then the agency default. The same supplier and
425
+ * confirmation as a booking already tracked answers 409
426
+ * COMMISSION_DUPLICATE_BOOKING. An advisor books for themselves; admins and
427
+ * staff may name another advisor.
428
+ */
429
+ externalBookingCreate(request: ExternalBookingCreateRequest, options?: RequestOptions): Promise<ExternalBookingCreateResponse>;
430
+ /**
431
+ * Get a booking made elsewhere
432
+ *
433
+ * A booking made elsewhere with its commission items: what the edit form
434
+ * loads. An advisor reads their own bookings; another company's booking
435
+ * answers 404.
436
+ */
437
+ externalBookingGet(request: ExternalBookingGetRequest, options?: RequestOptions): Promise<ExternalBookingGetResponse>;
438
+ /**
439
+ * Edit a booking made elsewhere
440
+ *
441
+ * Edits the facts of a booking made elsewhere (supplier, confirmation,
442
+ * client, dates, quantity, identifier, advisor, trip) with the
443
+ * `bookingVersion` read and a reason. Every item of the booking follows in
444
+ * the same transaction, writing a revision; due dates move with the travel
445
+ * end unless they were set by hand. Money changes go through the item
446
+ * actions. A newer edit answers 409 COMMISSION_RECORD_CHANGED; a new
447
+ * identifier once money arrived 409 COMMISSION_IDENTIFIER_LOCKED.
448
+ */
449
+ externalBookingUpdate(request: ExternalBookingUpdateRequest, options?: RequestOptions): Promise<ExternalBookingUpdateResponse>;
450
+ /**
451
+ * Record or reverse an outside payment
452
+ *
453
+ * Books a payment that happened outside the platform, by bank transfer, cash,
454
+ * cheque or card, against an order or an itinerary item, with a receipt asset
455
+ * and its checksum; or reverses a previously recorded one with a reason.
456
+ * Requires an authenticated company user and an `Idempotency-Key`.
457
+ */
458
+ externalPaymentRecord(request: ExternalPaymentRecordRequest, options?: RequestOptions): Promise<ExternalPaymentRecordResponse>;
459
+ /**
460
+ * Read and re-price a booking selection
461
+ *
462
+ * Returns a stored selection and, when the last refresh is older than 15
463
+ * minutes, re-prices it against the provider, persists the new price and
464
+ * expiry, and projects them onto the linked itinerary item. Any refresh
465
+ * failure still serves the last stored offer; only a provider that no longer
466
+ * offers the product sets `availability` to `UNAVAILABLE`. Readable by
467
+ * whoever may open the trip it belongs to: the trip's travelers, its advisor
468
+ * of record (the assigned advisor, or the primary traveler of a self-booked
469
+ * trip without one), the agency's admins and Nicer staff; a selection outside
470
+ * any trip by the person who saved it, the agency's admins and Nicer staff.
471
+ * The preview carries the commercial snapshot (expected commission and
472
+ * earnings) only for the agency's advisors and admins and for Nicer staff.
473
+ * Returns 404 `BOOKING_SELECTION_NOT_FOUND` when missing, expired or not
474
+ * readable by the caller, checked before any provider call, and 409
475
+ * `BOOKING_SELECTION_TRAVEL_PAST` once the travel dates are more than a day
476
+ * past.
477
+ */
478
+ getBookingSelection(request: GetBookingSelectionRequest, options?: RequestOptions): Promise<GetBookingSelectionResponse>;
479
+ /**
480
+ * Get the caller's shared list link
481
+ *
482
+ * Returns the link id of the caller's shared list and the photo it greets
483
+ * with, or nulls when they are not sharing it.
484
+ */
485
+ getFavoritesShare(request?: GetFavoritesShareRequest, options?: RequestOptions): Promise<GetFavoritesShareResponse>;
486
+ /**
487
+ * List checkout requirements for an offer
488
+ *
489
+ * Returns the checkout data still required before a live search offer can be
490
+ * booked: primary guest for hotels, driver and license for car rentals,
491
+ * passenger assignments and travel documents for flights. Requires an
492
+ * `x-nicer-company` header and returns 404 `BOOKING_OFFER_NOT_FOUND` when the
493
+ * offer is missing or expired. Hotel member rates include membership
494
+ * requirements; unsupported conditions return `MANUAL_REVIEW`.
495
+ */
496
+ getOfferRequirements(request: GetOfferRequirementsRequest, options?: RequestOptions): Promise<GetOfferRequirementsResponse>;
497
+ /**
498
+ * Get place details
499
+ *
500
+ * The full record of one place from a places search: every image, amenities,
501
+ * description and reference data. Use it when creating a segment; the list is
502
+ * intentionally light. Anonymous calls share one budget across the search
503
+ * routes, 600 per hour per IP; a valid bearer token lifts it.
504
+ */
505
+ getPlace(request: GetPlaceRequest, options?: RequestOptions): Promise<GetPlaceResponse>;
506
+ /**
507
+ * Get a tour or activity
508
+ *
509
+ * Returns one the activities provider product by its product code, shaped as
510
+ * an itinerary activity segment. Because the provider's detail call carries
511
+ * no pricing, pass the price seen in search results to have it preserved on
512
+ * the segment.
513
+ */
514
+ getProduct(request: GetProductRequest, options?: RequestOptions): Promise<GetProductResponse>;
515
+ /**
516
+ * Get a shared saved list
517
+ *
518
+ * Returns a shared saved list, newest first, with its owner's first name and
519
+ * photo. Reachable without a token: the link id is the only credential, and
520
+ * it stops working the moment its owner stops sharing.
521
+ */
522
+ getSharedFavorites(request: GetSharedFavoritesRequest, options?: RequestOptions): Promise<GetSharedFavoritesResponse>;
523
+ /**
524
+ * Get a trip
525
+ *
526
+ * Returns a single trip with its destinations, dates, travelers and the ids
527
+ * of the itinerary and conversation attached to it. `status` is derived on
528
+ * read from the trip dates and whether anything has been booked yet, so it is
529
+ * always current. Readable by the people on the trip, its advisor of record,
530
+ * the admins of the agency that owns it and Nicer staff; anyone else is
531
+ * refused (ERROR_UNAUTHORIZED), whatever the id.
532
+ */
533
+ getTravelersTrip(request: GetTravelersTripRequest, options?: RequestOptions): Promise<GetTravelersTripResponse>;
534
+ /**
535
+ * Get a trip itinerary
536
+ *
537
+ * Returns an itinerary with each segment once — priced in USD, with its image
538
+ * URLs and the purchase behind it — plus the trip it belongs to and the
539
+ * policies that govern the traveler-facing view. Reachable without a token so
540
+ * a traveler can open a shared itinerary link, in which case the itinerary id
541
+ * is the only credential. A segment's commission (`commercialSnapshot`) and
542
+ * the provider's references are answered only to the agency's own advisors
543
+ * and admins and to Nicer staff, and which provider it comes from
544
+ * (`provider`, `metadata.provider`) only to Nicer staff.
545
+ */
546
+ getTripItinerary(request: GetTripItineraryRequest, options?: RequestOptions): Promise<GetTripItineraryResponse>;
547
+ /**
548
+ * Compact itinerary with lock reasons
549
+ *
550
+ * A compact view of one trip: its dates, destinations and travellers, plus
551
+ * one line per segment with the reason it is frozen when it is. A frozen
552
+ * segment has been paid for, held or booked — plan around it, never change or
553
+ * remove it. Carries no prices, commissions or provider payloads.
554
+ */
555
+ getTripItineraryAgentView(request: GetTripItineraryAgentViewRequest, options?: RequestOptions): Promise<GetTripItineraryAgentViewResponse>;
556
+ /**
557
+ * List the caller's saved places
558
+ *
559
+ * Returns the places the caller saved, newest first, optionally narrowed to
560
+ * one kind. Always the caller's own list — there is no way to read another
561
+ * user's.
562
+ */
563
+ listFavorites(request?: ListFavoritesRequest, options?: RequestOptions): Promise<ListFavoritesResponse>;
564
+ /**
565
+ * List trips
566
+ *
567
+ * Returns one page of the trips the caller belongs to, newest first — 20 by
568
+ * default, at most 100, with `nextToken` for the next page. Travelers see
569
+ * their own trips; advisors and staff see the trips of the company they are
570
+ * signed in to. Each item carries the same derived `status` and `isArchived`
571
+ * as the single-trip endpoint, and trips whose end date has passed are
572
+ * archived as they are listed.
573
+ */
574
+ listTravelersTrip(request?: ListTravelersTripRequest, options?: RequestOptions): Promise<ListTravelersTripResponse>;
575
+ /**
576
+ * List trip itineraries
577
+ *
578
+ * Returns the itineraries the caller can see, each paired with its trip: ids,
579
+ * name, status, mode, counts, cost and the trip's title and dates, newest
580
+ * first. One page of 20 by default (`limit`, at most 100; `nextToken` for the
581
+ * next), so a caller never receives the whole account at once. The plan
582
+ * itself is not included — ask for `fields=itinerary.segments` to add it, or
583
+ * fetch one itinerary with GET /trip-itinerary/{tripItineraryId}. Segments
584
+ * follow that route's rule: commission and the provider's references for the
585
+ * agency's own advisors and admins and Nicer staff, which provider a segment
586
+ * comes from for Nicer staff only. `fields` names the parts of an item to
587
+ * return (dotted for nested, `-` to remove one; `nextToken` is always
588
+ * answered), `filter` takes `field||$op||value` expressions and `search`
589
+ * matches the itinerary or trip title.
590
+ */
591
+ listTripItinerary(request?: ListTripItineraryRequest, options?: RequestOptions): Promise<ListTripItineraryResponse>;
592
+ /**
593
+ * Look up a flight by number
594
+ *
595
+ * Resolves a flight number and a date to its scheduled legs, with airports
596
+ * from the travel reference, so a flight can be added to an itinerary without
597
+ * running a full search. Anonymous calls share one budget across the search
598
+ * routes, 600 per hour per IP; a valid bearer token lifts it.
599
+ */
600
+ lookupFlight(request: LookupFlightRequest, options?: RequestOptions): Promise<LookupFlightResponse>;
601
+ /**
602
+ * Submit checkout or create a payment link
603
+ *
604
+ * Runs an authenticated order action. Requires a verified user session,
605
+ * access to the order and an Idempotency-Key. Payment links cannot create
606
+ * links or cancel reservations. Access covers the agency's admins, its
607
+ * advisors on orders they take part in, Nicer staff, and the order's
608
+ * travelers (payer, participants and the trip's people). Travelers may submit
609
+ * checkout, make links, renew, cancel an unpaid order and release a hold;
610
+ * cancelling a booked reservation is refused to them with 403
611
+ * ERROR_DO_NOT_HAVE_PERMISSION, because it is cancelled with the supplier and
612
+ * refunded. A link meant for another person is made with audience TRAVELER: a
613
+ * SELF link signs whoever opens it in the first minute into the pay page as
614
+ * its creator. RENEW_CHECKOUT reprices an unpaid checkout past its window
615
+ * into a successor order and returns its payment link.
616
+ */
617
+ orderActionRun(request: OrderActionRunRequest, options?: RequestOptions): Promise<OrderActionRunResponse>;
618
+ /**
619
+ * Assign an order's responsible advisor
620
+ *
621
+ * Admin-only local assignment with revision checks and audit. Does not call a
622
+ * provider, change its DK, or transfer earned commissions.
623
+ */
624
+ orderAdvisorAssign(request: OrderAdvisorAssignRequest, options?: RequestOptions): Promise<OrderAdvisorAssignResponse>;
625
+ /**
626
+ * Email an order confirmation
627
+ *
628
+ * Queues the order's confirmation email to up to ten recipient addresses,
629
+ * deduplicated. Requires an advisor in the order's company and an
630
+ * `Idempotency-Key`, and is rate-limited per company. Returns how many
631
+ * recipients were queued.
632
+ */
633
+ orderConfirmationSend(request: OrderConfirmationSendRequest, options?: RequestOptions): Promise<OrderConfirmationSendResponse>;
634
+ /**
635
+ * Create an order from a selection
636
+ *
637
+ * Creates an order from a quote, a direct product, or a hotel, flight or car
638
+ * offer. Offers are revalidated, with one bounded retry for transient
639
+ * hotel-provider failures; optional trip context also updates the itinerary.
640
+ * Optional paymentLink creates checkout in this same request without charging
641
+ * or booking. Each new hotel checkout bypasses cached rates and uses the
642
+ * current price of the exact selected room and rate; a price-only change does
643
+ * not block checkout, where the final amount is shown before confirmation.
644
+ * With reviewChanges, hotel-condition changes or price changes outside hotel
645
+ * checkout return PRICE_CHANGED with the previous price, current quote and
646
+ * termsChanged, without creating an order. Continue with acceptedQuoteId and
647
+ * a new Idempotency-Key to revalidate exactly that reviewed offer. The quote
648
+ * must belong to this actor and source and remain active. Changes requiring
649
+ * review retain 409 BOOKING_PRICE_CHANGED for callers without reviewChanges.
650
+ * Requires an authenticated company user and an Idempotency-Key; replaying
651
+ * that key with the same body returns the original order and active link, and
652
+ * with a different body returns 409 COMMERCE_IDEMPOTENCY_CONFLICT. The order
653
+ * is cut like Get an order for a caller who is not its payer: payment.methods
654
+ * lists only the saved cards the creator may pay with, the funding and wallet
655
+ * of the card that paid reach Nicer staff only, and a payment's Stripe client
656
+ * secret is never sent.
657
+ */
658
+ orderCreate(request: OrderCreateRequest, options?: RequestOptions): Promise<OrderCreateResponse>;
659
+ /**
660
+ * Get an order
661
+ *
662
+ * Returns the order with its items, participants, payment state and
663
+ * commercial terms. Reachable without a token so a traveler can open a
664
+ * checkout link, using a live, unrevoked capability for that exact order;
665
+ * authenticated callers need a relationship to the order or an eligible
666
+ * company role. Card data is cut by the server for each caller: everyone who
667
+ * may read the order gets each card's brand, last four digits and expiry;
668
+ * payment.methods lists only the saved cards the caller may pay with; the
669
+ * funding and wallet of the card that paid and a guarantee's holder name and
670
+ * contact go only to the order's payer and Nicer staff; the Stripe client
671
+ * secret of a payment waiting for an action goes only to the payer. The payer
672
+ * is a caller on the pay flow (through the order's payment link or checkout
673
+ * session) or the signed-in user the order records as its payer.
674
+ */
675
+ orderGet(request: OrderGetRequest, options?: RequestOptions): Promise<OrderGetResponse>;
676
+ /**
677
+ * Submit a payment for an order
678
+ *
679
+ * Submits a payment attempt against the order and returns the outcome,
680
+ * including any next action the client must perform, such as card
681
+ * authentication. Requires an `Idempotency-Key`. Reachable without a token so
682
+ * a traveler can pay from a checkout link.
683
+ */
684
+ orderPaymentSubmit(request: OrderPaymentSubmitRequest, options?: RequestOptions): Promise<OrderPaymentSubmitResponse>;
685
+ /**
686
+ * List and filter orders
687
+ *
688
+ * Lists orders for the caller's company with filters for status, product
689
+ * kind, advisor, participant, payer, provider locator, trip, creation date
690
+ * range and free text, plus paging and sorting. The default view is the
691
+ * caller's own orders; the company view returns everyone's and requires the
692
+ * company name.
693
+ */
694
+ ordersList(request?: OrdersListRequest, options?: RequestOptions): Promise<OrdersListResponse>;
695
+ /**
696
+ * Run a payee action
697
+ *
698
+ * One action on a payee of the company (an advisor's user id, or the agency's
699
+ * company name). SAVE_SETTINGS (statement cycle — one to four days of the
700
+ * month, 31 for its last day —, statements on or off and from which date,
701
+ * minimum payout, payout method, legal name, tax form status) against the
702
+ * version read, agency admins and finance staff. START_STRIPE_ONBOARDING
703
+ * creates the payee's Stripe Connect Express account when it has none and
704
+ * answers a hosted onboarding link; REFRESH_STRIPE_ACCOUNT reads back whether
705
+ * Stripe lets it receive transfers. The payee runs these two for themselves;
706
+ * admins and staff for anyone. Returns the payee.
707
+ */
708
+ payeeActionRun(request: PayeeActionRunRequest, options?: RequestOptions): Promise<PayeeActionRunResponse>;
709
+ /**
710
+ * List payees
711
+ *
712
+ * The company's payees with their statement cycle, payout method, legal name,
713
+ * tax form, Stripe Connect status, next cycle date and the earnings no
714
+ * statement holds yet (keyset-paged by payee, at most 100). An advisor sees
715
+ * only themselves, with the defaults before anything is configured; agency
716
+ * admins and finance staff see every configured payee.
717
+ */
718
+ payeesList(request?: PayeesListRequest, options?: RequestOptions): Promise<PayeesListResponse>;
719
+ /**
720
+ * List or set up payment methods
721
+ *
722
+ * Runs a payment-method action: listing the stored methods the caller may
723
+ * use, starting a card setup, creating the link a client opens to authorize a
724
+ * card to the advisor who makes it, or revoking a saved card or an
725
+ * authorization. Requires an `Idempotency-Key`. Requires a verified user
726
+ * session.
727
+ */
728
+ paymentMethodActionRun(request: PaymentMethodActionRunRequest, options?: RequestOptions): Promise<PaymentMethodActionRunResponse>;
729
+ /**
730
+ * Run an action on a remittance
731
+ *
732
+ * Runs one action on posted money: ALLOCATE a line's unallocated money to
733
+ * commission items, REVERSE_ALLOCATION (all or part; the earnings and
734
+ * journals reverse with it), MARK_DUPLICATE or VOID (every allocation is
735
+ * reversed and the deposit's journal mirrored), UNMARK_DUPLICATE, or
736
+ * APPROVE_CLAIM / REJECT_CLAIM a member's claim. Allocating answers 409
737
+ * COMMISSION_ALLOCATION_EXCEEDS_LINE past the line and 409
738
+ * COMMISSION_ALLOCATION_WRONG_RECEIVER for money owed to another company.
739
+ * Reversing, voiding and duplicates are finance staff only.
740
+ */
741
+ remittanceActionRun(request: RemittanceActionRunRequest, options?: RequestOptions): Promise<RemittanceActionRunResponse>;
742
+ /**
743
+ * Run an action on a remittance file
744
+ *
745
+ * Runs one action on a remittance file under review: APPLY_MAPPING (reads the
746
+ * file again), SAVE_PRESET, EDIT_LINE, EXCLUDE_LINE, INCLUDE_LINE, SET_MATCH
747
+ * (the items a line pays and how much), RESET_MATCHES, RERUN_MATCHING,
748
+ * RECONCILE (posts the money and allocates every chosen match as a resumable
749
+ * job), UNDO_RECONCILE (reverses every allocation and voids the remittances)
750
+ * and DISCARD (before reconciling). Jobs answer at once with `jobId`; poll
751
+ * the file (status COMMITTING while the reconcile runs, then COMMITTED; a
752
+ * reconcile that failed resumes when asked again). A file reconciled once
753
+ * cannot be reconciled again. Agency admins and finance staff; UNDO_RECONCILE
754
+ * Nicer staff only.
755
+ */
756
+ remittanceBatchActionRun(request: RemittanceBatchActionRunRequest, options?: RequestOptions): Promise<RemittanceBatchActionRunResponse>;
757
+ /**
758
+ * Upload a remittance file
759
+ *
760
+ * Registers a remittance file (CSV, TSV, TXT or XLSX, up to 100 MiB: a
761
+ * clearinghouse or chain statement, an EFT detail) and answers a presigned
762
+ * upload. Once S3 has the file, a worker reads it into draft remittances and
763
+ * lines and matches them (status PARSING, then READY); without a preset it
764
+ * stops at UPLOADED with the column names until APPLY_MAPPING. The same file
765
+ * twice answers 409 COMMISSION_FILE_ALREADY_IMPORTED. Poll `GET
766
+ * /remittance-batches/{batchId}`. Agency admins and finance staff.
767
+ */
768
+ remittanceBatchCreate(request: RemittanceBatchCreateRequest, options?: RequestOptions): Promise<RemittanceBatchCreateResponse>;
769
+ /**
770
+ * Get a remittance file
771
+ *
772
+ * A remittance file with a page of its lines (50 by default, at most 200, in
773
+ * file order; `matchState` keeps the lines of the review tabs), each with the
774
+ * engine's proposals, the chosen match and, once reconciled, its allocations
775
+ * (a line the reconcile matched, excluded or found zero keeps only its chosen
776
+ * proposals, and no cells). Agency admins and finance staff; another
777
+ * company's file answers 404.
778
+ */
779
+ remittanceBatchGet(request: RemittanceBatchGetRequest, options?: RequestOptions): Promise<RemittanceBatchGetResponse>;
780
+ /**
781
+ * List remittance files
782
+ *
783
+ * The company's remittance files, newest first (25 by default, at most 100,
784
+ * keyset-paged), each with its status and where its lines stand. Agency
785
+ * admins and finance staff.
786
+ */
787
+ remittanceBatchesList(request?: RemittanceBatchesListRequest, options?: RequestOptions): Promise<RemittanceBatchesListResponse>;
788
+ /**
789
+ * Record a payment
790
+ *
791
+ * Records a payment by hand: one remittance, posted, with up to 100 lines and
792
+ * where each line's money goes. One atomic write posts the deposit and its
793
+ * fee journal, the allocations, the earnings their split plan gives each
794
+ * party, the audit rows and the events; a line left unallocated stays
795
+ * claimable. Agency admins for the money they received, and finance staff.
796
+ */
797
+ remittanceCreate(request: RemittanceCreateRequest, options?: RequestOptions): Promise<RemittanceCreateResponse>;
798
+ /**
799
+ * Get a remittance
800
+ *
801
+ * One remittance with a page of its lines (100 by default, at most 500, in
802
+ * line order), each line's allocations and their frozen split, the claims on
803
+ * it, notes, tags and the actions the caller may run. Another company's
804
+ * remittance answers 404.
805
+ */
806
+ remittanceGet(request: RemittanceGetRequest, options?: RequestOptions): Promise<RemittanceGetResponse>;
807
+ /**
808
+ * Claim unmatched money
809
+ *
810
+ * Claims unmatched money for one of the caller's bookings
811
+ * (07-business-rules.md §12): a line of the caller's own company or of a host
812
+ * it is a member of, not archived for members, with money left. The receiving
813
+ * company approves or rejects the claim from the remittance. Advisors claim
814
+ * for their own bookings; a line the caller may not see answers 404.
815
+ */
816
+ remittanceLineClaim(request: RemittanceLineClaimRequest, options?: RequestOptions): Promise<RemittanceLineClaimResponse>;
817
+ /**
818
+ * Suggest matches for a line
819
+ *
820
+ * The commission items a line most likely pays, scored now by the matching
821
+ * engine (07-business-rules.md §6): five by default, at most ten, each with
822
+ * its score, the points every feature added and the amount the line would
823
+ * give it. Agency admins and finance staff of the company that received the
824
+ * money.
825
+ */
826
+ remittanceSuggestionsGet(request: RemittanceSuggestionsGetRequest, options?: RequestOptions): Promise<RemittanceSuggestionsGetResponse>;
827
+ /**
828
+ * List remittances
829
+ *
830
+ * The money the company received, newest first (25 by default, at most 100,
831
+ * keyset-paged by received date): posted, duplicate and void remittances and
832
+ * the drafts of batches under review, with allocated and unallocated totals
833
+ * computed on read. Agency admins and finance staff; staff reads of another
834
+ * company are audited.
835
+ */
836
+ remittancesList(request?: RemittancesListRequest, options?: RequestOptions): Promise<RemittancesListResponse>;
837
+ /**
838
+ * Save a place
839
+ *
840
+ * Saves a place for the caller, or refreshes its snapshot when it is already
841
+ * saved — saving twice never creates a second entry.
842
+ */
843
+ saveFavorite(request: SaveFavoriteRequest, options?: RequestOptions): Promise<SaveFavoriteResponse>;
844
+ /**
845
+ * Search airlines
846
+ *
847
+ * Airlines by name, IATA or ICAO code from the travel reference, ranked with
848
+ * exact codes first. Airlines that stopped flying are left out. Anonymous
849
+ * calls share one budget across the search routes, 600 per hour per IP; a
850
+ * valid bearer token lifts it.
851
+ */
852
+ searchCarriers(request: SearchCarriersRequest, options?: RequestOptions): Promise<SearchCarriersResponse>;
853
+ /**
854
+ * Search places
855
+ *
856
+ * Search hotels, cities, airports and places by text. Hotels come from the
857
+ * Smith and shared catalogs first, then Google; cities and airports from the
858
+ * travel reference. Anonymous calls share one budget across the search
859
+ * routes, 600 per hour per IP; a valid bearer token lifts it. `Accept:
860
+ * text/event-stream` streams ranked snapshots as sources finish.
861
+ */
862
+ searchPlaces(request: SearchPlacesRequest, options?: RequestOptions): Promise<SearchPlacesResponse>;
863
+ /**
864
+ * Search tours and activities
865
+ *
866
+ * Searches the the activities provider catalogue for tours and activities and
867
+ * returns them already shaped as itinerary activity segments, with paging and
868
+ * the currency the prices are quoted in.
869
+ */
870
+ searchProducts(request: SearchProductsRequest, options?: RequestOptions): Promise<SearchProductsResponse>;
871
+ /**
872
+ * Add, edit or remove segments
873
+ *
874
+ * Applies a list of operations to one itinerary's segments and
875
+ * re-synchronises the trip dates. `add` may omit the segment id — the API
876
+ * derives a stable one from the content, so repeating the same add is a no-op
877
+ * rather than a duplicate. A segment that is paid, held or booked is frozen:
878
+ * `update` and `delete` on it are refused. Prices are minor units (cents).
879
+ */
880
+ segmentOp(request: SegmentOpRequest, options?: RequestOptions): Promise<SegmentOpResponse>;
881
+ /**
882
+ * Choose an option from a shared link
883
+ *
884
+ * Records the traveler's choice among the options offered on a segment of a
885
+ * shared itinerary. Reachable without a token so it works from the traveler's
886
+ * itinerary link, where the itinerary id is the only credential, and
887
+ * rate-limited per IP address.
888
+ */
889
+ selectOption(request: SelectOptionRequest, options?: RequestOptions): Promise<SelectOptionResponse>;
890
+ /**
891
+ * Send an itinerary to travelers
892
+ *
893
+ * Emails the itinerary to the travelers and records the delivery, returning
894
+ * the itinerary together with the addresses it went to. Requires an advisor.
895
+ */
896
+ sendTripItinerary(request: SendTripItineraryRequest, options?: RequestOptions): Promise<SendTripItineraryResponse>;
897
+ /**
898
+ * Share the caller's saved list
899
+ *
900
+ * Shares the caller's saved list through a link and returns its id. One link
901
+ * per person: sharing again returns the same link, with the greeting name and
902
+ * photo refreshed. Anyone with the link can read the list.
903
+ */
904
+ shareFavorites(request?: ShareFavoritesRequest, options?: RequestOptions): Promise<ShareFavoritesResponse>;
905
+ /**
906
+ * Run a statement action
907
+ *
908
+ * One action on a statement. ADD_ADJUSTMENT and REMOVE_ADJUSTMENT (a credit
909
+ * or debit, unit amount times quantity, with a description) and RECOMPUTE
910
+ * (picks again the earnings its period covers) while it is OPEN or
911
+ * PENDING_APPROVAL; CLOSE moves an OPEN statement to approval; REOPEN takes
912
+ * it back; APPROVE releases its earnings and makes it payable — a negative
913
+ * total, or one under the payee's minimum payout, is carried to the next
914
+ * statement; VOID cancels an unapproved statement and frees its earnings.
915
+ * MARK_PAID records that an approved statement was paid outside Nicer (a
916
+ * check, a wire, another system) in one step: the day, optionally how and a
917
+ * reference; it becomes PAID with its payout and journal (409
918
+ * COMMISSION_STATEMENT_ALREADY_PAID once a payout run holds it).
919
+ * ADD_ATTACHMENT (any status but VOID) answers a presigned upload for a
920
+ * document such as the payment's receipt. ADD_NOTE (Markdown, as on an item)
921
+ * at any time. An approved statement accepts no other change (409
922
+ * COMMISSION_STATEMENT_FINAL). The payee may add notes; agency admins and
923
+ * finance staff run the rest. Returns the statement and, for ADD_ATTACHMENT,
924
+ * its upload link.
925
+ */
926
+ statementActionRun(request: StatementActionRunRequest, options?: RequestOptions): Promise<StatementActionRunResponse>;
927
+ /**
928
+ * Get a statement
929
+ *
930
+ * One statement with a page of its lines (100 by default, at most 500), each
931
+ * with the booking it was earned on, its adjustments and notes, its payout, a
932
+ * link to its PDF signed for minutes, and the actions the caller may run. An
933
+ * advisor reads only their own; another company's statement answers 404.
934
+ * Every staff read is audited.
935
+ */
936
+ statementGet(request: StatementGetRequest, options?: RequestOptions): Promise<StatementGetResponse>;
937
+ /**
938
+ * List statements
939
+ *
940
+ * The company's payee statements, newest cycle first (25 by default, at most
941
+ * 100, keyset-paged by cycle date): number, payee, cycle date and period,
942
+ * status, earnings, adjustments and total. Advisors see their own; agency
943
+ * admins every payee of the company; finance staff any company, audited.
944
+ */
945
+ statementsList(request?: StatementsListRequest, options?: RequestOptions): Promise<StatementsListResponse>;
946
+ /**
947
+ * Stop sharing the caller's saved list
948
+ *
949
+ * Stops sharing the caller's saved list: the link stops working at once, and
950
+ * sharing again creates a new one. Idempotent.
951
+ */
952
+ stopSharingFavorites(request?: StopSharingFavoritesRequest, options?: RequestOptions): Promise<StopSharingFavoritesResponse>;
953
+ /**
954
+ * Run an action on a supplier
955
+ *
956
+ * One action on a supplier: UPDATE its profile (agency admins, the company's
957
+ * own; global ones by staff), ADD_CONTACT / REMOVE_CONTACT, SET_PROGRAMS
958
+ * (staff), MERGE into another supplier (admins for their own, staff for
959
+ * global ones). Every action is audited and returns the supplier as the
960
+ * company sees it.
961
+ */
962
+ supplierActionRun(request: SupplierActionRunRequest, options?: RequestOptions): Promise<SupplierActionRunResponse>;
963
+ /**
964
+ * Create a supplier
965
+ *
966
+ * Creates a supplier private to the company (or, for Nicer staff, one in the
967
+ * verified directory). With a Google place id it first answers the supplier
968
+ * that place already names, so a type-ahead miss never creates a duplicate.
969
+ * Returns the supplier as the company sees it.
970
+ */
971
+ supplierCreate(request: SupplierCreateRequest, options?: RequestOptions): Promise<SupplierCreateResponse>;
972
+ /**
973
+ * Get a supplier
974
+ *
975
+ * One supplier as the company sees it: the shared profile, the company's own
976
+ * terms and contacts, preferred programs, other systems' ids, and what the
977
+ * company booked, received and is owed with it per currency. An advisor gets
978
+ * the production of the bookings attributed to them only. Another company's
979
+ * supplier answers 404.
980
+ */
981
+ supplierGet(request: SupplierGetRequest, options?: RequestOptions): Promise<SupplierGetResponse>;
982
+ /**
983
+ * Search suppliers
984
+ *
985
+ * Type-ahead over Nicer's global supplier directory and the company's own
986
+ * suppliers, best match first, with Sabre Global Property IDs where
987
+ * available. When fewer than three fit a query of three characters or more
988
+ * and there is no strong Sabre match, it also suggests up to five Google
989
+ * places (lodging for PROPERTY, car rental for CAR_RENTAL). Creating a
990
+ * supplier with a suggestion's `googlePlaceId` reuses the supplier that place
991
+ * already names. Google failing or slow (1.5 s) answers no suggestions, never
992
+ * an error.
993
+ */
994
+ suppliersSearch(request: SuppliersSearchRequest, options?: RequestOptions): Promise<SuppliersSearchResponse>;
995
+ /**
996
+ * Archive or unarchive a chat
997
+ *
998
+ * Sets the caller's own archive flag: on a trip chat it updates the caller's
999
+ * trip membership row, on a direct chat it adds or removes the caller in the
1000
+ * archived-by set. Other participants are unaffected. The caller must be a
1001
+ * participant. Echoes the requested state back.
1002
+ */
1003
+ toggleArchive(request: ToggleArchiveRequest, options?: RequestOptions): Promise<ToggleArchiveResponse>;
1004
+ /**
1005
+ * Invite a traveler to a trip
1006
+ *
1007
+ * Invites a travel companion to a trip. A phone number, an email address or a
1008
+ * name is enough. A person with a Nicer account joins the trip at once; a
1009
+ * person without one becomes a traveler of the agency on the trip in the CRM,
1010
+ * and joins the trip when they sign up, so a group can be assembled before
1011
+ * everyone has an account. Returns the trip.
1012
+ */
1013
+ travelersTripInvite(request: TravelersTripInviteRequest, options?: RequestOptions): Promise<TravelersTripInviteResponse>;
1014
+ /**
1015
+ * Archive or restore a trip
1016
+ *
1017
+ * Archives or restores a trip for the caller only. Archiving hides the trip
1018
+ * from their list and their inbox; everyone else on the trip keeps seeing it.
1019
+ * Nothing is deleted.
1020
+ */
1021
+ travelersTripToggleArchive(request: TravelersTripToggleArchiveRequest, options?: RequestOptions): Promise<TravelersTripToggleArchiveResponse>;
1022
+ /**
1023
+ * Update a trip
1024
+ *
1025
+ * Edits a trip in place. Every field is optional; only what you send changes.
1026
+ * Moving `tripStartDate` or `tripEndDate` is checked against the segments
1027
+ * already in the itinerary, so a date change that would orphan a booked
1028
+ * segment is rejected instead of silently breaking the trip.
1029
+ */
1030
+ updateTravelersTrip(request: UpdateTravelersTripRequest, options?: RequestOptions): Promise<UpdateTravelersTripResponse>;
1031
+ /**
1032
+ * Update a trip itinerary
1033
+ *
1034
+ * Changes the itinerary's status, mode, trip cost, notes or attachments, and
1035
+ * re-synchronizes the trip's start and end dates with the segments. A field
1036
+ * left out keeps its stored value; in AUTO mode the trip cost is always the
1037
+ * sum of the segments. Requires an advisor.
1038
+ */
1039
+ updateTripItinerary(request: UpdateTripItineraryRequest, options?: RequestOptions): Promise<UpdateTripItineraryResponse>;
1040
+ readonly activity: ActivityClient;
1041
+ readonly crmSettings: CrmSettingsClient;
1042
+ readonly crmTrips: CrmTripsClient;
1043
+ readonly me: MeClient;
1044
+ readonly notes: NotesClient;
1045
+ readonly profileForms: ProfileFormsClient;
1046
+ readonly taskTemplates: TaskTemplatesClient;
1047
+ readonly tasks: TasksClient;
1048
+ readonly travelers: TravelersClient;
1049
+ }
1050
+ export declare function createClient(options: ClientOptions): Client;
1051
+ export declare function bind(transport: Transport): Client;
1052
+ export type AddOfferRequest = {
1053
+ tripItineraryId: string;
1054
+ } & AddOfferBody;
1055
+ export type AddOfferResponse = AddOfferResponse$;
1056
+ export type ApproveSegmentRequest = {
1057
+ tripItineraryId: string;
1058
+ } & ApproveSegmentBody;
1059
+ export type ApproveSegmentResponse = ApproveSegmentResponse$;
1060
+ export interface BalancesGetRequest {
1061
+ beneficiaryId?: string;
1062
+ beneficiaryKind?: "ADVISOR" | "COMPANY" | "NICER" | "TRAVELER";
1063
+ }
1064
+ export type BalancesGetResponse = BalancesGetResponse$;
1065
+ export interface ChatGetRequest {
1066
+ chatId: string;
1067
+ }
1068
+ export type ChatGetResponse = void;
1069
+ export interface ChatListRequest {
1070
+ }
1071
+ export type ChatListResponse = void;
1072
+ export type ChatReplyRequest = {
1073
+ chatId: string;
1074
+ } & ChatReplyBody;
1075
+ export type ChatReplyResponse = ChatReplyResponse$;
1076
+ export type CheckoutCreateRequest = CheckoutCreateBody;
1077
+ export type CheckoutCreateResponse = CheckoutCreateResponse$;
1078
+ export type CommissionExportCreateRequest = CommissionExportCreateBody;
1079
+ export type CommissionExportCreateResponse = CommissionExport;
1080
+ export interface CommissionExportGetRequest {
1081
+ exportId: string;
1082
+ }
1083
+ export type CommissionExportGetResponse = CommissionExport;
1084
+ export interface CommissionExportsListRequest {
1085
+ cursor?: string;
1086
+ limit?: number;
1087
+ status?: string;
1088
+ }
1089
+ export type CommissionExportsListResponse = CommissionExportsListResponse$;
1090
+ export type CommissionImportActionRunRequest = {
1091
+ importId: string;
1092
+ } & CommissionImportActionRunBody;
1093
+ export type CommissionImportActionRunResponse = CommissionImport;
1094
+ export type CommissionImportCreateRequest = CommissionImportCreateBody;
1095
+ export type CommissionImportCreateResponse = CommissionImportCreateResponse$;
1096
+ export interface CommissionImportGetRequest {
1097
+ importId: string;
1098
+ cursor?: string;
1099
+ limit?: number;
1100
+ status?: "VALID" | "INVALID" | "DUPLICATE" | "COMMITTED" | "SKIPPED";
1101
+ }
1102
+ export type CommissionImportGetResponse = CommissionImportGetResponse$;
1103
+ export type CommissionItemActionRunRequest = {
1104
+ commissionItemId: string;
1105
+ } & CommissionItemActionRunBody;
1106
+ export type CommissionItemActionRunResponse = CommissionItemActionRunResponse$;
1107
+ export interface CommissionItemGetRequest {
1108
+ commissionItemId: string;
1109
+ }
1110
+ export type CommissionItemGetResponse = CommissionItemDetail;
1111
+ export interface CommissionItemsListRequest {
1112
+ advisorUserId?: string;
1113
+ agingBucket?: string;
1114
+ category?: string;
1115
+ dateField?: "TRAVEL_END" | "TRAVEL_START" | "BOOKED" | "DUE";
1116
+ from?: string;
1117
+ identifierId?: string;
1118
+ kind?: string;
1119
+ needsReview?: "true" | "false";
1120
+ q?: string;
1121
+ source?: string;
1122
+ status?: string;
1123
+ supplierId?: string;
1124
+ tag?: CommissionTag;
1125
+ to?: string;
1126
+ view?: "BOOKINGS" | "RECEIVABLES";
1127
+ cursor?: string;
1128
+ limit?: number;
1129
+ }
1130
+ export type CommissionItemsListResponse = CommissionItemsListResponse$;
1131
+ export interface CommissionReportGetRequest {
1132
+ reportKind: string;
1133
+ advisorUserId?: string;
1134
+ basis?: "TRAVEL_END" | "BOOKED" | "TRAVEL_START";
1135
+ category?: string;
1136
+ city?: string;
1137
+ compare?: "PREVIOUS_PERIOD" | "SAME_PERIOD_LAST_YEAR" | "NONE";
1138
+ countryCode?: string;
1139
+ currency?: CurrencyCode;
1140
+ cursor?: string;
1141
+ exception?: string;
1142
+ from?: string;
1143
+ hasBookings?: "true" | "false";
1144
+ identifierId?: string;
1145
+ kind?: string;
1146
+ limit?: number;
1147
+ programId?: string;
1148
+ q?: string;
1149
+ supplierId?: string;
1150
+ supplierKind?: string;
1151
+ to?: string;
1152
+ verified?: "true" | "false";
1153
+ }
1154
+ export type CommissionReportGetResponse = CommissionReport;
1155
+ export interface CommissionSummaryGetRequest {
1156
+ advisorUserId?: string;
1157
+ agingBucket?: string;
1158
+ category?: string;
1159
+ dateField?: "TRAVEL_END" | "TRAVEL_START" | "BOOKED" | "DUE";
1160
+ from?: string;
1161
+ identifierId?: string;
1162
+ kind?: string;
1163
+ needsReview?: "true" | "false";
1164
+ q?: string;
1165
+ source?: string;
1166
+ status?: string;
1167
+ supplierId?: string;
1168
+ tag?: CommissionTag;
1169
+ to?: string;
1170
+ view?: "BOOKINGS" | "RECEIVABLES";
1171
+ }
1172
+ export type CommissionSummaryGetResponse = CommissionSummary;
1173
+ export type CreateBookingSelectionRequest = CreateBookingSelectionBody;
1174
+ export type CreateBookingSelectionResponse = CreateBookingSelectionResponse$;
1175
+ export type CreateInsuranceQuotesRequest = {
1176
+ travelersTripId: string;
1177
+ } & CreateInsuranceQuotesBody;
1178
+ export type CreateInsuranceQuotesResponse = CreateInsuranceQuotesResponse$;
1179
+ export type CreateItineraryDocumentRequest = {
1180
+ tripItineraryId: string;
1181
+ } & CreateItineraryDocumentBody;
1182
+ export type CreateItineraryDocumentResponse = CreateItineraryDocumentResponse$;
1183
+ export type CreateQuoteRequest = CreateQuoteRequest$;
1184
+ export type CreateQuoteResponse = QuoteOutcomeResponse;
1185
+ export type CreateTravelersTripRequest = CreateTravelersTripBody;
1186
+ export type CreateTravelersTripResponse = CreateTravelersTripResponse$;
1187
+ export interface DeleteFavoriteRequest {
1188
+ kind: FavoriteKind;
1189
+ reference: string;
1190
+ }
1191
+ export type DeleteFavoriteResponse = DeleteFavoriteResponse$;
1192
+ export interface DestinationsQueryRequest {
1193
+ query: string;
1194
+ radiusKm?: number;
1195
+ limit?: number;
1196
+ }
1197
+ export type DestinationsQueryResponse = void;
1198
+ export interface DiscoverCarRentalDetailsRequest {
1199
+ offerReference: string;
1200
+ }
1201
+ export type DiscoverCarRentalDetailsResponse = CarDiscoveryDetails;
1202
+ export interface DiscoverCarRentalsRequest {
1203
+ pickup: string;
1204
+ dropoff?: string;
1205
+ pickupDate: string;
1206
+ dropoffDate: string;
1207
+ pickupTime?: string;
1208
+ dropoffTime?: string;
1209
+ pickupZone?: string;
1210
+ dropoffZone?: string;
1211
+ age?: number;
1212
+ currency?: CurrencyCode;
1213
+ suppliers?: string;
1214
+ transmission?: string;
1215
+ extras?: string;
1216
+ minPrice?: number;
1217
+ maxPrice?: number;
1218
+ minLuggage?: number;
1219
+ minCargo?: number;
1220
+ minSeats?: number;
1221
+ sort?: "price" | "-price" | "commission" | "-commission";
1222
+ page?: number;
1223
+ size?: number;
1224
+ }
1225
+ export type DiscoverCarRentalsResponse = CarDiscoveryResponse;
1226
+ export interface DiscoverFlightDetailsRequest {
1227
+ offerReference: string;
1228
+ }
1229
+ export type DiscoverFlightDetailsResponse = FlightDetailsResponse;
1230
+ export interface DiscoverFlightsRequest {
1231
+ from?: AirportCode;
1232
+ to?: AirportCode;
1233
+ departure?: string;
1234
+ return?: string;
1235
+ legs?: string;
1236
+ adults?: number;
1237
+ children?: number;
1238
+ infants?: number;
1239
+ cabin?: "economy" | "premium-economy" | "business" | "first";
1240
+ cabins?: string;
1241
+ currency?: CurrencyCode;
1242
+ airlines?: string;
1243
+ stops?: string;
1244
+ via?: string;
1245
+ excludeAirportChanges?: "true" | "false";
1246
+ maxConnections?: number;
1247
+ minPrice?: number;
1248
+ maxPrice?: number;
1249
+ maxDuration?: number;
1250
+ bags?: "true" | "false";
1251
+ refundable?: "true" | "false";
1252
+ commissionable?: "true" | "false";
1253
+ sameCabin?: "true" | "false";
1254
+ changeable?: "true" | "false";
1255
+ maxLayover?: number;
1256
+ departureTime?: string;
1257
+ arrivalTime?: string;
1258
+ /**
1259
+ * How results are listed: best match, price (or -price), shortest duration,
1260
+ * earliest (or latest, with -) departure or arrival, or fewest stops. best
1261
+ * weighs 10% over the lowest price like 20% over the shortest duration or one
1262
+ * more stop.
1263
+ */
1264
+ sort?: FlightSort;
1265
+ page?: number;
1266
+ size?: number;
1267
+ group?: "slice";
1268
+ slices?: string;
1269
+ chosenFrom?: string;
1270
+ }
1271
+ export type DiscoverFlightsResponse = FlightDiscoveryResponse;
1272
+ export interface DiscoverHotelDetailsRequest {
1273
+ hotelId: string;
1274
+ checkIn: string;
1275
+ checkOut: string;
1276
+ currency?: string;
1277
+ /**
1278
+ * Occupancy per room, not the room count. Format
1279
+ * adults[:childAge,childAge];nextRoom. One room for 2 adults is '2'; two
1280
+ * rooms for 2 adults each is '2;2'; 2 adults and a child age 7 is '2:7'.
1281
+ * Sabre multi-room rates require the same adult and child counts per room.
1282
+ * Search mixed occupancies separately; each result then covers only its
1283
+ * requested room.
1284
+ */
1285
+ rooms?: string;
1286
+ rateCodes?: string;
1287
+ include?: "content" | "rates" | "content,rates";
1288
+ refresh?: "true" | "false";
1289
+ }
1290
+ export type DiscoverHotelDetailsResponse = DiscoverHotelDetailsResponse$;
1291
+ export interface DiscoverHotelsRequest {
1292
+ checkIn: string;
1293
+ checkOut: string;
1294
+ currency?: string;
1295
+ /**
1296
+ * Occupancy per room, not the room count. Format
1297
+ * adults[:childAge,childAge];nextRoom. One room for 2 adults is '2'; two
1298
+ * rooms for 2 adults each is '2;2'; 2 adults and a child age 7 is '2:7'.
1299
+ * Sabre multi-room rates require the same adult and child counts per room.
1300
+ * Search mixed occupancies separately; each result then covers only its
1301
+ * requested room.
1302
+ */
1303
+ rooms?: string;
1304
+ lat?: number;
1305
+ lng?: number;
1306
+ radius?: number;
1307
+ placeId?: string;
1308
+ /**
1309
+ * Focused property or landmark name. When supplied, type is required: use
1310
+ * type='hotel' for a hotel or type='landmark' for a nearby landmark.
1311
+ */
1312
+ name?: string;
1313
+ /**
1314
+ * Required together with name. Use 'hotel' for a named property and
1315
+ * 'landmark' for proximity to a named landmark.
1316
+ */
1317
+ type?: "hotel" | "landmark";
1318
+ sort?: "distance" | "price" | "-price" | "recommended";
1319
+ rateCodes?: string;
1320
+ amenities?: string;
1321
+ chainNames?: string;
1322
+ /**
1323
+ * Comma-separated hotelReference values returned by prior hotel searches. Use
1324
+ * this filter to compare the same known property across dates or occupancies;
1325
+ * never invent references.
1326
+ */
1327
+ hotelReferences?: string;
1328
+ maximumDistanceKm?: number;
1329
+ maximumPriceMinor?: number;
1330
+ minimumPriceMinor?: number;
1331
+ minimumStars?: number;
1332
+ maximumStars?: number;
1333
+ breakfastIncludedOnly?: "true" | "false";
1334
+ refundableOnly?: "true" | "false";
1335
+ commissionableOnly?: "true" | "false";
1336
+ requireRateCodeMatch?: "true" | "false";
1337
+ expand?: "pins";
1338
+ page?: number;
1339
+ waitMs?: number;
1340
+ size?: number;
1341
+ minResults?: number;
1342
+ }
1343
+ export type DiscoverHotelsResponse = HotelDiscoveryResponse;
1344
+ export interface EarningsListRequest {
1345
+ beneficiaryId?: string;
1346
+ cursor?: string;
1347
+ limit?: number;
1348
+ status?: "PENDING" | "AVAILABLE" | "REVERSED";
1349
+ }
1350
+ export type EarningsListResponse = EarningsListResponse$;
1351
+ export type ExternalBookingCreateRequest = ExternalBookingCreateBody;
1352
+ export type ExternalBookingCreateResponse = ExternalBooking;
1353
+ export interface ExternalBookingGetRequest {
1354
+ externalBookingId: string;
1355
+ }
1356
+ export type ExternalBookingGetResponse = ExternalBooking;
1357
+ export type ExternalBookingUpdateRequest = {
1358
+ externalBookingId: string;
1359
+ } & ExternalBookingUpdateBody;
1360
+ export type ExternalBookingUpdateResponse = ExternalBooking;
1361
+ export type ExternalPaymentRecordRequest = ExternalPaymentRecordBody;
1362
+ export type ExternalPaymentRecordResponse = void;
1363
+ export interface GetBookingSelectionRequest {
1364
+ selectionId: string;
1365
+ }
1366
+ export type GetBookingSelectionResponse = GetBookingSelectionResponse$;
1367
+ export interface GetFavoritesShareRequest {
1368
+ }
1369
+ export type GetFavoritesShareResponse = GetFavoritesShareResponse$;
1370
+ export interface GetOfferRequirementsRequest {
1371
+ offerReference: string;
1372
+ }
1373
+ export type GetOfferRequirementsResponse = GetOfferRequirementsResponse$;
1374
+ export interface GetPlaceRequest {
1375
+ placeId: string;
1376
+ }
1377
+ export type GetPlaceResponse = PlaceDetails;
1378
+ export interface GetProductRequest {
1379
+ productCode: string;
1380
+ }
1381
+ export type GetProductResponse = void;
1382
+ export interface GetSharedFavoritesRequest {
1383
+ shareId: string;
1384
+ }
1385
+ export type GetSharedFavoritesResponse = GetSharedFavoritesResponse$;
1386
+ export interface GetTravelersTripRequest {
1387
+ travelersTripId: string;
1388
+ }
1389
+ export type GetTravelersTripResponse = GetTravelersTripResponse$;
1390
+ export interface GetTripItineraryRequest {
1391
+ tripItineraryId: string;
1392
+ /**
1393
+ * Comma-separated response fields to return, dotted for nested ones and
1394
+ * applied to every array element — for example
1395
+ * `status,tripCost,travelersTrip.tripTitle,itinerary.segments.purchase`. A
1396
+ * leading `-` removes a path from what is kept
1397
+ * (`itinerary.segments,-itinerary.segments.rate`). Only the reads those
1398
+ * fields need are made. Omit for the whole response.
1399
+ */
1400
+ fields?: string;
1401
+ }
1402
+ export type GetTripItineraryResponse = void;
1403
+ export interface GetTripItineraryAgentViewRequest {
1404
+ tripItineraryId: string;
1405
+ }
1406
+ export type GetTripItineraryAgentViewResponse = GetTripItineraryAgentViewResponse$;
1407
+ export interface ListFavoritesRequest {
1408
+ kind?: FavoriteKind;
1409
+ }
1410
+ export type ListFavoritesResponse = ListFavoritesResponse$;
1411
+ export interface ListTravelersTripRequest {
1412
+ /**
1413
+ * Comma-separated item fields to return, dotted for nested ones — for example
1414
+ * `travelersTripId,tripTitle,destinations.name`; a leading `-` removes a path
1415
+ * from what is kept. `nextToken` is always answered. Omitted, an item carries
1416
+ * every projected field except the destination photo galleries, which are
1417
+ * more than half the body: ask for `destinations.photos` to get them.
1418
+ */
1419
+ fields?: string;
1420
+ /**
1421
+ * URL-encoded `field=value` expressions joined by `&`, applied to the page
1422
+ * after it is read — for example `status=PROPOSAL&isArchived=false`.
1423
+ */
1424
+ filter?: string;
1425
+ /**
1426
+ * Trips per page. Defaults to 20, at most 100.
1427
+ */
1428
+ limit?: string;
1429
+ /**
1430
+ * Cursor from the previous response. Omit for the first page.
1431
+ */
1432
+ nextToken?: string;
1433
+ /**
1434
+ * Order by creation time. Defaults to newest first.
1435
+ */
1436
+ sort?: "asc" | "desc";
1437
+ }
1438
+ export type ListTravelersTripResponse = ListTravelersTripResponse$;
1439
+ export interface ListTripItineraryRequest {
1440
+ }
1441
+ export type ListTripItineraryResponse = void;
1442
+ export interface LookupFlightRequest {
1443
+ flightNumber: string;
1444
+ /**
1445
+ * Departure date, YYYY-MM-DD.
1446
+ */
1447
+ date: string;
1448
+ }
1449
+ export type LookupFlightResponse = FlightLookupResponse;
1450
+ export type OrderActionRunRequest = {
1451
+ orderId: string;
1452
+ } & OrderActionRunBody;
1453
+ export type OrderActionRunResponse = OrderActionRunResponse$;
1454
+ export type OrderAdvisorAssignRequest = {
1455
+ orderId: string;
1456
+ } & OrderAdvisorAssignBody;
1457
+ export type OrderAdvisorAssignResponse = OrderAdvisorAssignResponse$;
1458
+ export type OrderConfirmationSendRequest = {
1459
+ orderId: string;
1460
+ } & OrderConfirmationSendBody;
1461
+ export type OrderConfirmationSendResponse = OrderConfirmationSendResponse$;
1462
+ export type OrderCreateRequest = OrderCreateBody;
1463
+ export type OrderCreateResponse = OrderCreateResponse$;
1464
+ export interface OrderGetRequest {
1465
+ orderId: string;
1466
+ }
1467
+ export type OrderGetResponse = OrderGetResponse$;
1468
+ export type OrderPaymentSubmitRequest = {
1469
+ orderId: string;
1470
+ } & OrderPaymentSubmitBody;
1471
+ export type OrderPaymentSubmitResponse = OrderPaymentSubmitResponse$;
1472
+ export interface OrdersListRequest {
1473
+ advisorIds?: string;
1474
+ companyName?: string;
1475
+ createdFrom?: string;
1476
+ createdTo?: string;
1477
+ cursor?: string;
1478
+ hotelReference?: string;
1479
+ includeTemporary?: "false" | "true";
1480
+ limit?: number;
1481
+ originAirport?: string;
1482
+ participantEmail?: string;
1483
+ participantPhone?: string;
1484
+ participantUserId?: string;
1485
+ payerEmail?: string;
1486
+ payerPhone?: string;
1487
+ payerUserId?: string;
1488
+ page?: number;
1489
+ productKinds?: string;
1490
+ providerLocator?: string;
1491
+ search?: string;
1492
+ sort?: "createdAt_asc" | "createdAt_desc";
1493
+ statuses?: string;
1494
+ travelersTripId?: string;
1495
+ view?: "self" | "company";
1496
+ }
1497
+ export type OrdersListResponse = OrdersListResponse$;
1498
+ export type PayeeActionRunRequest = {
1499
+ payeeId: string;
1500
+ } & PayeeActionRunBody;
1501
+ export type PayeeActionRunResponse = PayeeActionRunResponse$;
1502
+ export interface PayeesListRequest {
1503
+ cursor?: string;
1504
+ limit?: number;
1505
+ payeeId?: string;
1506
+ payeeKind?: "ADVISOR" | "COMPANY";
1507
+ statementsEnabled?: "true" | "false";
1508
+ }
1509
+ export type PayeesListResponse = PayeesListResponse$;
1510
+ export type PaymentMethodActionRunRequest = PaymentMethodActionRunBody;
1511
+ export type PaymentMethodActionRunResponse = PaymentMethodCardLinkCompleteResponse;
1512
+ export type RemittanceActionRunRequest = {
1513
+ remittanceId: string;
1514
+ } & RemittanceAction;
1515
+ export type RemittanceActionRunResponse = RemittanceDetail;
1516
+ export type RemittanceBatchActionRunRequest = {
1517
+ batchId: string;
1518
+ } & RemittanceBatchAction;
1519
+ export type RemittanceBatchActionRunResponse = RemittanceBatchActionRunResponse$;
1520
+ export type RemittanceBatchCreateRequest = RemittanceBatchCreateBody;
1521
+ export type RemittanceBatchCreateResponse = RemittanceBatchCreateResponse$;
1522
+ export interface RemittanceBatchGetRequest {
1523
+ batchId: string;
1524
+ cursor?: string;
1525
+ limit?: number;
1526
+ matchState?: string;
1527
+ }
1528
+ export type RemittanceBatchGetResponse = RemittanceBatchGetResponse$;
1529
+ export interface RemittanceBatchesListRequest {
1530
+ channel?: string;
1531
+ cursor?: string;
1532
+ limit?: number;
1533
+ status?: string;
1534
+ }
1535
+ export type RemittanceBatchesListResponse = RemittanceBatchesListResponse$;
1536
+ export type RemittanceCreateRequest = RemittanceCreateBody;
1537
+ export type RemittanceCreateResponse = RemittanceDetail;
1538
+ export interface RemittanceGetRequest {
1539
+ remittanceId: string;
1540
+ cursor?: string;
1541
+ limit?: number;
1542
+ }
1543
+ export type RemittanceGetResponse = RemittanceDetail;
1544
+ export type RemittanceLineClaimRequest = {
1545
+ remittanceLineId: string;
1546
+ } & RemittanceLineClaimBody;
1547
+ export type RemittanceLineClaimResponse = RemittanceClaim;
1548
+ export interface RemittanceSuggestionsGetRequest {
1549
+ remittanceLineId: string;
1550
+ limit?: number;
1551
+ }
1552
+ export type RemittanceSuggestionsGetResponse = RemittanceSuggestionsGetResponse$;
1553
+ export interface RemittancesListRequest {
1554
+ batchId?: string;
1555
+ channel?: string;
1556
+ cursor?: string;
1557
+ from?: string;
1558
+ limit?: number;
1559
+ q?: string;
1560
+ state?: string;
1561
+ to?: string;
1562
+ unallocated?: "true" | "false";
1563
+ }
1564
+ export type RemittancesListResponse = RemittancesListResponse$;
1565
+ export type SaveFavoriteRequest = SaveFavoriteBody;
1566
+ export type SaveFavoriteResponse = Favorite;
1567
+ export interface SearchCarriersRequest {
1568
+ /**
1569
+ * An airline name, or its IATA or ICAO code.
1570
+ */
1571
+ q: string;
1572
+ /**
1573
+ * Maximum airlines after ranking.
1574
+ */
1575
+ limit?: number;
1576
+ }
1577
+ export type SearchCarriersResponse = CarriersResponse;
1578
+ export interface SearchPlacesRequest {
1579
+ /**
1580
+ * Free text: a hotel, city, airport or venue name.
1581
+ */
1582
+ q: string;
1583
+ /**
1584
+ * Comma-separated kinds to return: hotel, city, airport, place. All kinds
1585
+ * when omitted.
1586
+ */
1587
+ kinds?: string;
1588
+ /**
1589
+ * Google place type filter for `place` results, for example restaurant or
1590
+ * tourist_attraction.
1591
+ */
1592
+ type?: string;
1593
+ /**
1594
+ * Maximum items after ranking.
1595
+ */
1596
+ limit?: number;
1597
+ /**
1598
+ * Photos per item in the list. The place details resource carries the full
1599
+ * album.
1600
+ */
1601
+ photos?: number;
1602
+ }
1603
+ export type SearchPlacesResponse = PlacesResponse;
1604
+ export type SearchProductsRequest = SearchProductsBody;
1605
+ export type SearchProductsResponse = void;
1606
+ export interface SegmentOpRequest {
1607
+ tripItineraryId: string;
1608
+ body: SegmentOpBody;
1609
+ }
1610
+ export type SegmentOpResponse = void;
1611
+ export type SelectOptionRequest = {
1612
+ tripItineraryId: string;
1613
+ } & SelectOptionBody;
1614
+ export type SelectOptionResponse = SelectOptionResponse$;
1615
+ export type SendTripItineraryRequest = {
1616
+ tripItineraryId: string;
1617
+ } & SendTripItineraryBody;
1618
+ export type SendTripItineraryResponse = void;
1619
+ export type ShareFavoritesRequest = ShareFavoritesBody;
1620
+ export type ShareFavoritesResponse = ShareFavoritesResponse$;
1621
+ export type StatementActionRunRequest = {
1622
+ statementId: string;
1623
+ } & StatementActionRunBody;
1624
+ export type StatementActionRunResponse = StatementActionRunResponse$;
1625
+ export interface StatementGetRequest {
1626
+ statementId: string;
1627
+ cursor?: string;
1628
+ limit?: number;
1629
+ }
1630
+ export type StatementGetResponse = StatementDetail;
1631
+ export interface StatementsListRequest {
1632
+ currency?: CurrencyCode;
1633
+ cursor?: string;
1634
+ from?: string;
1635
+ limit?: number;
1636
+ payeeId?: string;
1637
+ payeeKind?: "ADVISOR" | "COMPANY";
1638
+ status?: string;
1639
+ to?: string;
1640
+ }
1641
+ export type StatementsListResponse = StatementsListResponse$;
1642
+ export interface StopSharingFavoritesRequest {
1643
+ }
1644
+ export type StopSharingFavoritesResponse = StopSharingFavoritesResponse$;
1645
+ export type SupplierActionRunRequest = {
1646
+ supplierId: string;
1647
+ } & SupplierActionRunBody;
1648
+ export type SupplierActionRunResponse = SupplierDetail;
1649
+ export type SupplierCreateRequest = SupplierCreateBody;
1650
+ export type SupplierCreateResponse = SupplierDetail;
1651
+ export interface SupplierGetRequest {
1652
+ supplierId: string;
1653
+ }
1654
+ export type SupplierGetResponse = SupplierDetail;
1655
+ export interface SuppliersSearchRequest {
1656
+ kind?: "PROPERTY" | "CRUISE_LINE" | "TOUR_OPERATOR" | "DMC" | "AIRLINE" | "CAR_RENTAL" | "RAIL" | "INSURANCE" | "TRANSFER" | "OTHER";
1657
+ limit?: number;
1658
+ q: string;
1659
+ }
1660
+ export type SuppliersSearchResponse = SuppliersSearchResponse$;
1661
+ export type ToggleArchiveRequest = {
1662
+ chatId: string;
1663
+ } & ToggleArchiveBody;
1664
+ export type ToggleArchiveResponse = ToggleArchiveResponse$;
1665
+ export type TravelersTripInviteRequest = {
1666
+ travelersTripId: string;
1667
+ } & TravelersTripInviteBody;
1668
+ export type TravelersTripInviteResponse = CreateTravelersTripResponse$;
1669
+ export type TravelersTripToggleArchiveRequest = {
1670
+ travelersTripId: string;
1671
+ } & TravelersTripToggleArchiveBody;
1672
+ export type TravelersTripToggleArchiveResponse = TravelersTripToggleArchiveResponse$;
1673
+ export type UpdateTravelersTripRequest = {
1674
+ travelersTripId: string;
1675
+ } & UpdateTravelersTripBody;
1676
+ export type UpdateTravelersTripResponse = CreateTravelersTripResponse$;
1677
+ export type UpdateTripItineraryRequest = {
1678
+ tripItineraryId: string;
1679
+ } & UpdateTripItineraryBody;
1680
+ export type UpdateTripItineraryResponse = UpdateTripItineraryResponse$;