@voyant-travel/finance 0.167.0 → 0.168.0

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 (196) hide show
  1. package/README.md +23 -9
  2. package/dist/action-ledger-drift.d.ts.map +1 -0
  3. package/dist/booking-lifecycle.d.ts.map +1 -0
  4. package/dist/booking-schedule/subscriber-runtime.d.ts.map +1 -0
  5. package/dist/booking-tax.d.ts +31 -19
  6. package/dist/booking-tax.d.ts.map +1 -0
  7. package/dist/booking-tax.js +48 -15
  8. package/dist/card-payment.d.ts.map +1 -0
  9. package/dist/checkout-routes.d.ts +294 -294
  10. package/dist/checkout-routes.d.ts.map +1 -0
  11. package/dist/checkout-service-plan.d.ts +2 -2
  12. package/dist/checkout-service-plan.d.ts.map +1 -0
  13. package/dist/checkout-service.d.ts.map +1 -0
  14. package/dist/checkout-validation.d.ts.map +1 -0
  15. package/dist/document-download.d.ts.map +1 -0
  16. package/dist/fx-money.d.ts.map +1 -0
  17. package/dist/index.d.ts +1 -1
  18. package/dist/index.d.ts.map +1 -0
  19. package/dist/index.js +3 -3
  20. package/dist/invoice-fx.d.ts.map +1 -0
  21. package/dist/invoice-number-errors.d.ts.map +1 -0
  22. package/dist/linkables.d.ts.map +1 -0
  23. package/dist/markets-ref.d.ts.map +1 -0
  24. package/dist/mcp-runtime.d.ts.map +1 -0
  25. package/dist/order-payment-sessions.d.ts.map +1 -0
  26. package/dist/payment-adapter-events.d.ts +3 -3
  27. package/dist/payment-link.d.ts.map +1 -0
  28. package/dist/payment-policy-cascade.d.ts.map +1 -0
  29. package/dist/payment-policy.d.ts.map +1 -0
  30. package/dist/payment-schedule/routes.d.ts +2 -2
  31. package/dist/payment-schedule/routes.d.ts.map +1 -0
  32. package/dist/route-runtime.d.ts.map +1 -0
  33. package/dist/routes-action-ledger.d.ts +25 -25
  34. package/dist/routes-action-ledger.d.ts.map +1 -0
  35. package/dist/routes-booking-billing.d.ts +95 -95
  36. package/dist/routes-booking-billing.d.ts.map +1 -0
  37. package/dist/routes-booking-create.d.ts.map +1 -0
  38. package/dist/routes-booking-reads.d.ts +13 -13
  39. package/dist/routes-booking-reads.d.ts.map +1 -0
  40. package/dist/routes-documents.d.ts +11 -11
  41. package/dist/routes-documents.d.ts.map +1 -0
  42. package/dist/routes-invoice-core.d.ts +87 -87
  43. package/dist/routes-invoice-core.d.ts.map +1 -0
  44. package/dist/routes-invoice-documents.d.ts +16 -16
  45. package/dist/routes-invoice-documents.d.ts.map +1 -0
  46. package/dist/routes-invoice-issue.d.ts.map +1 -0
  47. package/dist/routes-invoice-schemas.d.ts +20 -20
  48. package/dist/routes-invoice-schemas.d.ts.map +1 -0
  49. package/dist/routes-payment-processing.d.ts +152 -152
  50. package/dist/routes-payment-processing.d.ts.map +1 -0
  51. package/dist/routes-payment-schemas.d.ts +17 -17
  52. package/dist/routes-payment-schemas.d.ts.map +1 -0
  53. package/dist/routes-payments.d.ts +64 -64
  54. package/dist/routes-payments.d.ts.map +1 -0
  55. package/dist/routes-public-accountant.d.ts +19 -19
  56. package/dist/routes-public.d.ts +102 -102
  57. package/dist/routes-public.d.ts.map +1 -0
  58. package/dist/routes-reference-data.d.ts +33 -33
  59. package/dist/routes-reference-data.d.ts.map +1 -0
  60. package/dist/routes-reports.d.ts +11 -11
  61. package/dist/routes-reports.d.ts.map +1 -0
  62. package/dist/routes-runtime.d.ts +1 -1
  63. package/dist/routes-runtime.d.ts.map +1 -0
  64. package/dist/routes-settlement.d.ts +12 -12
  65. package/dist/routes-settlement.d.ts.map +1 -0
  66. package/dist/routes-shared.d.ts.map +1 -0
  67. package/dist/routes-supplier-invoices.d.ts +75 -75
  68. package/dist/routes-supplier-invoices.d.ts.map +1 -0
  69. package/dist/routes-travel-credits.d.ts +4 -4
  70. package/dist/routes-vouchers.d.ts +401 -0
  71. package/dist/routes-vouchers.d.ts.map +1 -0
  72. package/dist/routes-vouchers.js +176 -0
  73. package/dist/routes.d.ts +477 -477
  74. package/dist/routes.d.ts.map +1 -0
  75. package/dist/runtime-contributor.d.ts.map +1 -0
  76. package/dist/runtime-port.d.ts +20 -24
  77. package/dist/runtime-port.d.ts.map +1 -0
  78. package/dist/runtime-port.js +10 -11
  79. package/dist/runtime.d.ts.map +1 -0
  80. package/dist/schema/booking-billing.d.ts +5 -5
  81. package/dist/schema/booking-billing.d.ts.map +1 -0
  82. package/dist/schema/enums.d.ts.map +1 -0
  83. package/dist/schema/invoice-documents.d.ts +1 -1
  84. package/dist/schema/invoice-documents.d.ts.map +1 -0
  85. package/dist/schema/payment-instruments.d.ts +1 -1
  86. package/dist/schema/payment-instruments.d.ts.map +1 -0
  87. package/dist/schema/payment-processing.d.ts +3 -3
  88. package/dist/schema/payment-processing.d.ts.map +1 -0
  89. package/dist/schema/payment-sessions.d.ts +3 -3
  90. package/dist/schema/payment-sessions.d.ts.map +1 -0
  91. package/dist/schema/receivables.d.ts +3 -3
  92. package/dist/schema/receivables.d.ts.map +1 -0
  93. package/dist/schema/relations.d.ts.map +1 -0
  94. package/dist/schema/supplier-invoices.d.ts +5 -5
  95. package/dist/schema/supplier-invoices.d.ts.map +1 -0
  96. package/dist/schema/tax.d.ts +1 -1
  97. package/dist/schema/tax.d.ts.map +1 -0
  98. package/dist/schema/vouchers.d.ts +444 -0
  99. package/dist/schema/vouchers.d.ts.map +1 -0
  100. package/dist/schema/vouchers.js +64 -0
  101. package/dist/schema.d.ts.map +1 -0
  102. package/dist/service-accountant-shares.d.ts.map +1 -0
  103. package/dist/service-action-ledger-accounting.d.ts.map +1 -0
  104. package/dist/service-action-ledger-booking-payments.d.ts.map +1 -0
  105. package/dist/service-action-ledger-bookings.d.ts.map +1 -0
  106. package/dist/service-action-ledger-payment-authorizations.d.ts.map +1 -0
  107. package/dist/service-action-ledger-payment-sessions.d.ts.map +1 -0
  108. package/dist/service-action-ledger-supplier-invoices.d.ts.map +1 -0
  109. package/dist/service-action-ledger-supplier-payments.d.ts.map +1 -0
  110. package/dist/service-action-ledger.d.ts.map +1 -0
  111. package/dist/service-aggregates.d.ts.map +1 -0
  112. package/dist/service-booking-billing.d.ts +111 -111
  113. package/dist/service-booking-billing.d.ts.map +1 -0
  114. package/dist/service-booking-create.d.ts +11 -11
  115. package/dist/service-booking-create.d.ts.map +1 -0
  116. package/dist/service-booking-guarantees.d.ts +34 -34
  117. package/dist/service-booking-guarantees.d.ts.map +1 -0
  118. package/dist/service-booking-item-billing.d.ts +21 -21
  119. package/dist/service-booking-item-billing.d.ts.map +1 -0
  120. package/dist/service-booking-payment-schedules.d.ts +56 -56
  121. package/dist/service-booking-payment-schedules.d.ts.map +1 -0
  122. package/dist/service-bookings-dual-create.d.ts +22 -22
  123. package/dist/service-bookings-dual-create.d.ts.map +1 -0
  124. package/dist/service-boundary-sql.d.ts.map +1 -0
  125. package/dist/service-cost-categories.d.ts.map +1 -0
  126. package/dist/service-documents.d.ts.map +1 -0
  127. package/dist/service-invoice-artifacts.d.ts +24 -24
  128. package/dist/service-invoice-artifacts.d.ts.map +1 -0
  129. package/dist/service-invoice-core.d.ts +28 -28
  130. package/dist/service-invoice-core.d.ts.map +1 -0
  131. package/dist/service-invoice-credit-notes.d.ts +10 -10
  132. package/dist/service-invoice-credit-notes.d.ts.map +1 -0
  133. package/dist/service-invoice-from-booking.d.ts +19 -19
  134. package/dist/service-invoice-from-booking.d.ts.map +1 -0
  135. package/dist/service-invoice-line-items.d.ts +10 -10
  136. package/dist/service-invoice-line-items.d.ts.map +1 -0
  137. package/dist/service-invoice-numbering.d.ts +28 -28
  138. package/dist/service-invoice-numbering.d.ts.map +1 -0
  139. package/dist/service-invoice-payments.d.ts +20 -20
  140. package/dist/service-invoice-payments.d.ts.map +1 -0
  141. package/dist/service-invoices.d.ts +87 -87
  142. package/dist/service-invoices.d.ts.map +1 -0
  143. package/dist/service-issue.d.ts +38 -38
  144. package/dist/service-issue.d.ts.map +1 -0
  145. package/dist/service-payment-authorizations.d.ts +26 -26
  146. package/dist/service-payment-authorizations.d.ts.map +1 -0
  147. package/dist/service-payment-instruments.d.ts +10 -10
  148. package/dist/service-payment-instruments.d.ts.map +1 -0
  149. package/dist/service-payment-processing.d.ts +77 -77
  150. package/dist/service-payment-processing.d.ts.map +1 -0
  151. package/dist/service-payment-session-completion.d.ts +3 -3
  152. package/dist/service-payment-session-completion.d.ts.map +1 -0
  153. package/dist/service-payment-sessions.d.ts +38 -38
  154. package/dist/service-payment-sessions.d.ts.map +1 -0
  155. package/dist/service-profitability.d.ts.map +1 -0
  156. package/dist/service-public.d.ts +16 -16
  157. package/dist/service-public.d.ts.map +1 -0
  158. package/dist/service-reference-data.d.ts +23 -23
  159. package/dist/service-reference-data.d.ts.map +1 -0
  160. package/dist/service-rendition-wait.d.ts +1 -1
  161. package/dist/service-rendition-wait.d.ts.map +1 -0
  162. package/dist/service-reports.d.ts.map +1 -0
  163. package/dist/service-settlement.d.ts.map +1 -0
  164. package/dist/service-shared.d.ts +4 -4
  165. package/dist/service-shared.d.ts.map +1 -0
  166. package/dist/service-supplier-invoices.d.ts +20 -20
  167. package/dist/service-supplier-invoices.d.ts.map +1 -0
  168. package/dist/service-supplier-payments.d.ts +16 -16
  169. package/dist/service-supplier-payments.d.ts.map +1 -0
  170. package/dist/service-travel-credits.d.ts +10 -10
  171. package/dist/service-vouchers-migration.d.ts +51 -0
  172. package/dist/service-vouchers-migration.d.ts.map +1 -0
  173. package/dist/service-vouchers-migration.js +154 -0
  174. package/dist/service-vouchers.d.ts +157 -0
  175. package/dist/service-vouchers.d.ts.map +1 -0
  176. package/dist/service-vouchers.js +191 -0
  177. package/dist/service.d.ts +376 -376
  178. package/dist/service.d.ts.map +1 -0
  179. package/dist/stale-booking-holds-runtime.d.ts.map +1 -0
  180. package/dist/tools.d.ts +21 -21
  181. package/dist/tools.d.ts.map +1 -0
  182. package/dist/validation-billing.d.ts.map +1 -0
  183. package/dist/validation-payments.d.ts.map +1 -0
  184. package/dist/validation-public.d.ts.map +1 -0
  185. package/dist/validation-shared.d.ts.map +1 -0
  186. package/dist/validation-vouchers.d.ts +2 -0
  187. package/dist/validation-vouchers.d.ts.map +1 -0
  188. package/dist/validation-vouchers.js +1 -0
  189. package/dist/validation.d.ts.map +1 -0
  190. package/dist/voyant.d.ts +2 -1
  191. package/dist/voyant.d.ts.map +1 -0
  192. package/dist/voyant.js +43 -7
  193. package/openapi/admin/booking-tax-preview.json +33 -0
  194. package/openapi/admin/{booking-tax.json → booking-tax-settings.json} +7 -32
  195. package/package.json +205 -170
  196. package/LICENSE +0 -201
package/dist/service.d.ts CHANGED
@@ -29,17 +29,17 @@ export declare const financeService: {
29
29
  updatedAt: Date;
30
30
  } | null>;
31
31
  createTaxRegime(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateTaxRegimeInput): Promise<{
32
- active: boolean;
33
32
  id: string;
34
- name: string;
35
33
  metadata: unknown;
36
- createdAt: Date;
37
- updatedAt: Date;
38
- description: string | null;
39
34
  code: "other" | "standard" | "reduced" | "exempt" | "reverse_charge" | "margin_scheme_art311" | "zero_rated" | "out_of_scope";
35
+ description: string | null;
36
+ name: string;
37
+ active: boolean;
40
38
  jurisdiction: string | null;
39
+ createdAt: Date;
41
40
  ratePercent: number | null;
42
41
  legalReference: string | null;
42
+ updatedAt: Date;
43
43
  } | null>;
44
44
  updateTaxRegime(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateTaxRegimeInput): Promise<{
45
45
  id: string;
@@ -86,18 +86,18 @@ export declare const financeService: {
86
86
  updatedAt: Date;
87
87
  } | null>;
88
88
  createTaxClass(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateTaxClassInput): Promise<{
89
- active: boolean;
90
89
  id: string;
90
+ code: string;
91
+ description: string | null;
91
92
  label: string;
93
+ active: boolean;
92
94
  createdAt: Date;
93
- updatedAt: Date;
94
- description: string | null;
95
- code: string;
96
95
  defaultRegimeId: string | null;
97
96
  lines: {
98
97
  regime_id: string;
99
98
  applies_to: "base" | "addon" | "accommodation" | "all";
100
99
  }[] | null;
100
+ updatedAt: Date;
101
101
  } | null>;
102
102
  updateTaxClass(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateTaxClassInput): Promise<{
103
103
  id: string;
@@ -137,14 +137,14 @@ export declare const financeService: {
137
137
  updatedAt: Date;
138
138
  } | null>;
139
139
  createTaxPolicyProfile(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateTaxPolicyProfileInput): Promise<{
140
- active: boolean;
141
140
  id: string;
141
+ code: string;
142
+ description: string | null;
142
143
  name: string;
144
+ active: boolean;
145
+ jurisdiction: string | null;
143
146
  createdAt: Date;
144
147
  updatedAt: Date;
145
- description: string | null;
146
- code: string;
147
- jurisdiction: string | null;
148
148
  } | null>;
149
149
  updateTaxPolicyProfile(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateTaxPolicyProfileInput): Promise<{
150
150
  id: string;
@@ -165,7 +165,7 @@ export declare const financeService: {
165
165
  side: "sell" | "buy";
166
166
  priority: number;
167
167
  name: string;
168
- appliesTo: "accommodation" | "base" | "addon" | "all";
168
+ appliesTo: "base" | "addon" | "accommodation" | "all";
169
169
  condition: Record<string, unknown> | null;
170
170
  taxRegimeId: string;
171
171
  active: boolean;
@@ -178,7 +178,7 @@ export declare const financeService: {
178
178
  side: "sell" | "buy";
179
179
  priority: number;
180
180
  name: string;
181
- appliesTo: "accommodation" | "base" | "addon" | "all";
181
+ appliesTo: "base" | "addon" | "accommodation" | "all";
182
182
  condition: Record<string, unknown> | null;
183
183
  taxRegimeId: string;
184
184
  active: boolean;
@@ -186,17 +186,17 @@ export declare const financeService: {
186
186
  updatedAt: Date;
187
187
  } | null>;
188
188
  createTaxPolicyRule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateTaxPolicyRuleInput): Promise<{
189
- active: boolean;
190
189
  id: string;
191
190
  name: string;
191
+ active: boolean;
192
192
  createdAt: Date;
193
- updatedAt: Date;
194
- taxRegimeId: string;
195
193
  profileId: string;
196
194
  side: "sell" | "buy";
197
195
  priority: number;
198
- appliesTo: "accommodation" | "base" | "addon" | "all";
196
+ appliesTo: "base" | "addon" | "accommodation" | "all";
199
197
  condition: Record<string, unknown> | null;
198
+ taxRegimeId: string;
199
+ updatedAt: Date;
200
200
  } | null>;
201
201
  updateTaxPolicyRule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateTaxPolicyRuleInput): Promise<{
202
202
  id: string;
@@ -204,7 +204,7 @@ export declare const financeService: {
204
204
  side: "sell" | "buy";
205
205
  priority: number;
206
206
  name: string;
207
- appliesTo: "accommodation" | "base" | "addon" | "all";
207
+ appliesTo: "base" | "addon" | "accommodation" | "all";
208
208
  condition: Record<string, unknown> | null;
209
209
  taxRegimeId: string;
210
210
  active: boolean;
@@ -229,18 +229,18 @@ export declare const financeService: {
229
229
  updatedAt: Date;
230
230
  }[]>;
231
231
  registerInvoiceExternalRef(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateInvoiceExternalRefInput): Promise<{
232
+ provider: string;
232
233
  id: string;
233
234
  status: string | null;
234
- provider: string;
235
235
  metadata: unknown;
236
- createdAt: Date;
237
- updatedAt: Date;
238
236
  invoiceId: string;
237
+ createdAt: Date;
239
238
  externalId: string | null;
240
239
  externalNumber: string | null;
241
240
  externalUrl: string | null;
242
241
  syncedAt: Date | null;
243
242
  syncError: string | null;
243
+ updatedAt: Date;
244
244
  } | null>;
245
245
  deleteInvoiceExternalRef(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<{
246
246
  id: string;
@@ -276,19 +276,19 @@ export declare const financeService: {
276
276
  updatedAt: Date;
277
277
  } | null>;
278
278
  createInvoiceTemplate(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceTemplateInput): Promise<{
279
- active: boolean;
280
279
  id: string;
281
- name: string;
282
280
  metadata: unknown;
283
- createdAt: Date;
284
- updatedAt: Date;
285
- language: string;
281
+ name: string;
282
+ active: boolean;
286
283
  jurisdiction: string | null;
284
+ createdAt: Date;
287
285
  isDefault: boolean;
286
+ language: string;
288
287
  slug: string;
289
288
  bodyFormat: "html" | "markdown" | "lexical_json";
290
289
  body: string;
291
290
  cssStyles: string | null;
291
+ updatedAt: Date;
292
292
  } | null>;
293
293
  updateInvoiceTemplate(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateInvoiceTemplateInput): Promise<{
294
294
  id: string;
@@ -312,7 +312,7 @@ export declare const financeService: {
312
312
  id: string;
313
313
  invoiceId: string;
314
314
  templateId: string | null;
315
- format: "html" | "pdf" | "xml" | "json";
315
+ format: "json" | "xml" | "pdf" | "html";
316
316
  status: "pending" | "failed" | "ready" | "stale";
317
317
  storageKey: string | null;
318
318
  fileSize: number | null;
@@ -328,7 +328,7 @@ export declare const financeService: {
328
328
  id: string;
329
329
  invoiceId: string;
330
330
  templateId: string | null;
331
- format: "html" | "pdf" | "xml" | "json";
331
+ format: "json" | "xml" | "pdf" | "html";
332
332
  status: "pending" | "failed" | "ready" | "stale";
333
333
  storageKey: string | null;
334
334
  fileSize: number | null;
@@ -344,23 +344,23 @@ export declare const financeService: {
344
344
  id: string;
345
345
  status: "pending" | "failed" | "ready" | "stale";
346
346
  metadata: unknown;
347
+ format: "json" | "xml" | "pdf" | "html";
348
+ invoiceId: string;
347
349
  createdAt: Date;
348
- updatedAt: Date;
349
- templateId: string | null;
350
350
  language: string | null;
351
- invoiceId: string;
352
- format: "html" | "pdf" | "xml" | "json";
351
+ templateId: string | null;
353
352
  storageKey: string | null;
354
353
  fileSize: number | null;
355
354
  checksum: string | null;
356
355
  errorMessage: string | null;
357
356
  generatedAt: Date | null;
357
+ updatedAt: Date;
358
358
  } | null>;
359
359
  updateInvoiceRendition(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateInvoiceRenditionInput): Promise<{
360
360
  id: string;
361
361
  invoiceId: string;
362
362
  templateId: string | null;
363
- format: "html" | "pdf" | "xml" | "json";
363
+ format: "json" | "xml" | "pdf" | "html";
364
364
  status: "pending" | "failed" | "ready" | "stale";
365
365
  storageKey: string | null;
366
366
  fileSize: number | null;
@@ -380,24 +380,24 @@ export declare const financeService: {
380
380
  status: "bound";
381
381
  invoice: {
382
382
  id: string;
383
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
383
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
384
384
  invoiceType: "invoice" | "proforma" | "credit_note";
385
385
  };
386
386
  rendition: {
387
387
  id: string;
388
388
  status: "pending" | "failed" | "ready" | "stale";
389
389
  metadata: unknown;
390
+ format: "json" | "xml" | "pdf" | "html";
391
+ invoiceId: string;
390
392
  createdAt: Date;
391
- updatedAt: Date;
392
- templateId: string | null;
393
393
  language: string | null;
394
- invoiceId: string;
395
- format: "html" | "pdf" | "xml" | "json";
394
+ templateId: string | null;
396
395
  storageKey: string | null;
397
396
  fileSize: number | null;
398
397
  checksum: string | null;
399
398
  errorMessage: string | null;
400
399
  generatedAt: Date | null;
400
+ updatedAt: Date;
401
401
  };
402
402
  }>;
403
403
  deleteInvoiceRendition(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<{
@@ -429,14 +429,14 @@ export declare const financeService: {
429
429
  } | null>;
430
430
  createInvoiceAttachment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateInvoiceAttachmentInput): Promise<{
431
431
  id: string;
432
- name: string;
433
432
  metadata: unknown;
434
- createdAt: Date;
433
+ name: string;
435
434
  invoiceId: string;
435
+ createdAt: Date;
436
+ kind: string;
436
437
  storageKey: string | null;
437
438
  fileSize: number | null;
438
439
  checksum: string | null;
439
- kind: string;
440
440
  mimeType: string | null;
441
441
  } | null>;
442
442
  updateInvoiceAttachment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, id: string, data: import("./service-shared.js").UpdateInvoiceAttachmentInput): Promise<{
@@ -463,17 +463,17 @@ export declare const financeService: {
463
463
  id: string;
464
464
  status: "pending" | "failed" | "ready" | "stale";
465
465
  metadata: unknown;
466
+ format: "json" | "xml" | "pdf" | "html";
467
+ invoiceId: string;
466
468
  createdAt: Date;
467
- updatedAt: Date;
468
- templateId: string | null;
469
469
  language: string | null;
470
- invoiceId: string;
471
- format: "html" | "pdf" | "xml" | "json";
470
+ templateId: string | null;
472
471
  storageKey: string | null;
473
472
  fileSize: number | null;
474
473
  checksum: string | null;
475
474
  errorMessage: string | null;
476
475
  generatedAt: Date | null;
476
+ updatedAt: Date;
477
477
  } | null;
478
478
  }>;
479
479
  listInvoiceNumberSeries(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, query: import("./service-shared.js").InvoiceNumberSeriesListQuery): Promise<import("@voyant-travel/types").ListResponse<{
@@ -531,13 +531,12 @@ export declare const financeService: {
531
531
  updatedAt: Date;
532
532
  } | null>;
533
533
  ensureExternalInvoiceNumberSeries(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, inputs: import("./service-shared.js").EnsureExternalInvoiceNumberSeriesInput[]): Promise<{
534
- active: boolean;
535
534
  id: string;
536
- name: string;
537
- createdAt: Date;
538
- updatedAt: Date;
539
535
  code: string;
536
+ name: string;
537
+ active: boolean;
540
538
  scope: "invoice" | "proforma" | "credit_note";
539
+ createdAt: Date;
541
540
  prefix: string;
542
541
  separator: string;
543
542
  padLength: number;
@@ -547,15 +546,15 @@ export declare const financeService: {
547
546
  isDefault: boolean;
548
547
  externalProvider: string | null;
549
548
  externalConfigKey: string | null;
549
+ updatedAt: Date;
550
550
  }[]>;
551
551
  createInvoiceNumberSeries(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceNumberSeriesInput): Promise<{
552
- active: boolean;
553
552
  id: string;
554
- name: string;
555
- createdAt: Date;
556
- updatedAt: Date;
557
553
  code: string;
554
+ name: string;
555
+ active: boolean;
558
556
  scope: "invoice" | "proforma" | "credit_note";
557
+ createdAt: Date;
559
558
  prefix: string;
560
559
  separator: string;
561
560
  padLength: number;
@@ -565,6 +564,7 @@ export declare const financeService: {
565
564
  isDefault: boolean;
566
565
  externalProvider: string | null;
567
566
  externalConfigKey: string | null;
567
+ updatedAt: Date;
568
568
  } | null>;
569
569
  updateInvoiceNumberSeries(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateInvoiceNumberSeriesInput): Promise<{
570
570
  id: string;
@@ -624,7 +624,7 @@ export declare const financeService: {
624
624
  bookingId: string;
625
625
  personId: string | null;
626
626
  organizationId: string | null;
627
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
627
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
628
628
  currency: string;
629
629
  baseCurrency: string | null;
630
630
  fxRateSetId: string | null;
@@ -652,40 +652,40 @@ export declare const financeService: {
652
652
  status: "applied";
653
653
  invoice: {
654
654
  id: string;
655
+ currency: string;
656
+ invoiceType: "invoice" | "proforma" | "credit_note";
657
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
658
+ notes: string | null;
659
+ bookingId: string;
655
660
  personId: string | null;
656
661
  organizationId: string | null;
657
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
658
- notes: string | null;
662
+ voidedAt: Date | null;
663
+ dueDate: string;
659
664
  createdAt: Date;
660
- updatedAt: Date;
661
- invoiceNumber: string;
662
- invoiceType: "invoice" | "proforma" | "credit_note";
663
- convertedFromInvoiceId: string | null;
664
- seriesId: string | null;
665
- sequence: number | null;
666
- templateId: string | null;
667
- taxRegimeId: string | null;
668
- language: string | null;
669
- bookingId: string;
670
- currency: string;
671
665
  baseCurrency: string | null;
672
666
  fxRateSetId: string | null;
667
+ invoiceNumber: string;
668
+ totalCents: number;
669
+ paidCents: number;
670
+ balanceDueCents: number;
671
+ issueDate: string;
673
672
  subtotalCents: number;
674
673
  baseSubtotalCents: number | null;
675
674
  taxCents: number;
676
675
  baseTaxCents: number | null;
677
- totalCents: number;
678
676
  baseTotalCents: number | null;
679
- paidCents: number;
680
677
  basePaidCents: number | null;
681
- balanceDueCents: number;
682
678
  baseBalanceDueCents: number | null;
683
679
  commissionPercent: number | null;
684
680
  commissionAmountCents: number | null;
685
- issueDate: string;
686
- dueDate: string;
687
- voidedAt: Date | null;
681
+ seriesId: string | null;
682
+ convertedFromInvoiceId: string | null;
683
+ language: string | null;
684
+ templateId: string | null;
685
+ taxRegimeId: string | null;
686
+ sequence: number | null;
688
687
  voidReason: string | null;
688
+ updatedAt: Date;
689
689
  };
690
690
  }>;
691
691
  listCreditNotes(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string): Omit<import("drizzle-orm/pg-core").PgSelectBase<"credit_notes", {
@@ -1164,18 +1164,18 @@ export declare const financeService: {
1164
1164
  } | null>;
1165
1165
  createCreditNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateCreditNoteInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
1166
1166
  id: string;
1167
+ currency: string;
1167
1168
  status: "draft" | "issued" | "applied";
1169
+ amountCents: number;
1168
1170
  notes: string | null;
1171
+ invoiceId: string;
1169
1172
  createdAt: Date;
1170
- updatedAt: Date;
1171
- currency: string;
1172
1173
  baseCurrency: string | null;
1173
- fxRateSetId: string | null;
1174
- invoiceId: string;
1175
- amountCents: number;
1176
1174
  baseAmountCents: number | null;
1177
- creditNoteNumber: string;
1175
+ fxRateSetId: string | null;
1178
1176
  reason: string;
1177
+ creditNoteNumber: string;
1178
+ updatedAt: Date;
1179
1179
  } | null | undefined>;
1180
1180
  updateCreditNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, creditNoteId: string, data: import("./service-shared.js").UpdateCreditNoteInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
1181
1181
  id: string;
@@ -1478,12 +1478,12 @@ export declare const financeService: {
1478
1478
  }>, "where" | "orderBy">;
1479
1479
  createCreditNoteLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, creditNoteId: string, data: import("./service-shared.js").CreateCreditNoteLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
1480
1480
  id: string;
1481
+ description: string;
1482
+ sortOrder: number;
1481
1483
  createdAt: Date;
1482
1484
  totalCents: number;
1483
- description: string;
1484
1485
  quantity: number;
1485
1486
  unitPriceCents: number;
1486
- sortOrder: number;
1487
1487
  creditNoteId: string;
1488
1488
  } | null>;
1489
1489
  listNotes(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string): Omit<import("drizzle-orm/pg-core").PgSelectBase<"finance_notes", {
@@ -1667,10 +1667,10 @@ export declare const financeService: {
1667
1667
  }>, "where" | "orderBy">;
1668
1668
  createNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, userId: string, data: import("./service-shared.js").CreateFinanceNoteInput): Promise<{
1669
1669
  id: string;
1670
- createdAt: Date;
1670
+ content: string;
1671
1671
  invoiceId: string;
1672
+ createdAt: Date;
1672
1673
  authorId: string;
1673
- content: string;
1674
1674
  } | null | undefined>;
1675
1675
  listPayments(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string): Omit<import("drizzle-orm/pg-core").PgSelectBase<"payments", {
1676
1676
  id: import("drizzle-orm/pg-core").PgColumn<{
@@ -1797,7 +1797,7 @@ export declare const financeService: {
1797
1797
  tableName: "payments";
1798
1798
  dataType: "string";
1799
1799
  columnType: "PgEnumColumn";
1800
- data: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
1800
+ data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
1801
1801
  driverParam: string;
1802
1802
  notNull: true;
1803
1803
  hasDefault: false;
@@ -1865,7 +1865,7 @@ export declare const financeService: {
1865
1865
  tableName: "payments";
1866
1866
  dataType: "string";
1867
1867
  columnType: "PgEnumColumn";
1868
- data: "pending" | "completed" | "failed" | "refunded";
1868
+ data: "pending" | "failed" | "completed" | "refunded";
1869
1869
  driverParam: string;
1870
1870
  notNull: true;
1871
1871
  hasDefault: true;
@@ -1970,11 +1970,11 @@ export declare const financeService: {
1970
1970
  baseCurrency: string | null;
1971
1971
  baseAmountCents: number | null;
1972
1972
  fxRateSetId: string | null;
1973
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
1973
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
1974
1974
  paymentInstrumentId: string | null;
1975
1975
  paymentAuthorizationId: string | null;
1976
1976
  paymentCaptureId: string | null;
1977
- status: "pending" | "completed" | "failed" | "refunded";
1977
+ status: "pending" | "failed" | "completed" | "refunded";
1978
1978
  referenceNumber: string | null;
1979
1979
  paymentDate: string;
1980
1980
  notes: string | null;
@@ -2105,7 +2105,7 @@ export declare const financeService: {
2105
2105
  tableName: "payments";
2106
2106
  dataType: "string";
2107
2107
  columnType: "PgEnumColumn";
2108
- data: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
2108
+ data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
2109
2109
  driverParam: string;
2110
2110
  notNull: true;
2111
2111
  hasDefault: false;
@@ -2173,7 +2173,7 @@ export declare const financeService: {
2173
2173
  tableName: "payments";
2174
2174
  dataType: "string";
2175
2175
  columnType: "PgEnumColumn";
2176
- data: "pending" | "completed" | "failed" | "refunded";
2176
+ data: "pending" | "failed" | "completed" | "refunded";
2177
2177
  driverParam: string;
2178
2178
  notNull: true;
2179
2179
  hasDefault: true;
@@ -2280,22 +2280,22 @@ export declare const financeService: {
2280
2280
  getPaymentById(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<import("./service-shared.js").UnifiedPaymentRow | null>;
2281
2281
  createPayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreatePaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2282
2282
  id: string;
2283
- status: "pending" | "completed" | "failed" | "refunded";
2284
- notes: string | null;
2285
- createdAt: Date;
2286
- updatedAt: Date;
2287
2283
  currency: string;
2288
- baseCurrency: string | null;
2289
- fxRateSetId: string | null;
2290
- invoiceId: string;
2284
+ status: "pending" | "failed" | "completed" | "refunded";
2291
2285
  amountCents: number;
2292
- baseAmountCents: number | null;
2293
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
2286
+ notes: string | null;
2287
+ invoiceId: string;
2294
2288
  paymentInstrumentId: string | null;
2295
2289
  paymentAuthorizationId: string | null;
2296
2290
  paymentCaptureId: string | null;
2297
- referenceNumber: string | null;
2291
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
2298
2292
  paymentDate: string;
2293
+ referenceNumber: string | null;
2294
+ createdAt: Date;
2295
+ baseCurrency: string | null;
2296
+ baseAmountCents: number | null;
2297
+ fxRateSetId: string | null;
2298
+ updatedAt: Date;
2299
2299
  } | null>;
2300
2300
  updatePayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdatePaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2301
2301
  id: string;
@@ -2305,11 +2305,11 @@ export declare const financeService: {
2305
2305
  baseCurrency: string | null;
2306
2306
  baseAmountCents: number | null;
2307
2307
  fxRateSetId: string | null;
2308
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
2308
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
2309
2309
  paymentInstrumentId: string | null;
2310
2310
  paymentAuthorizationId: string | null;
2311
2311
  paymentCaptureId: string | null;
2312
- status: "pending" | "completed" | "failed" | "refunded";
2312
+ status: "pending" | "failed" | "completed" | "refunded";
2313
2313
  referenceNumber: string | null;
2314
2314
  paymentDate: string;
2315
2315
  notes: string | null;
@@ -2324,11 +2324,11 @@ export declare const financeService: {
2324
2324
  baseCurrency: string | null;
2325
2325
  baseAmountCents: number | null;
2326
2326
  fxRateSetId: string | null;
2327
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
2327
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
2328
2328
  paymentInstrumentId: string | null;
2329
2329
  paymentAuthorizationId: string | null;
2330
2330
  paymentCaptureId: string | null;
2331
- status: "pending" | "completed" | "failed" | "refunded";
2331
+ status: "pending" | "failed" | "completed" | "refunded";
2332
2332
  referenceNumber: string | null;
2333
2333
  paymentDate: string;
2334
2334
  notes: string | null;
@@ -2726,16 +2726,16 @@ export declare const financeService: {
2726
2726
  }>, "where" | "orderBy">;
2727
2727
  createInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateInvoiceLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2728
2728
  id: string;
2729
- createdAt: Date;
2730
- totalCents: number;
2729
+ description: string;
2731
2730
  invoiceId: string;
2732
- bookingItemId: string | null;
2733
2731
  bookingPaymentScheduleId: string | null;
2734
- description: string;
2732
+ bookingItemId: string | null;
2733
+ sortOrder: number;
2734
+ createdAt: Date;
2735
+ totalCents: number;
2735
2736
  quantity: number;
2736
2737
  unitPriceCents: number;
2737
2738
  taxRate: number | null;
2738
- sortOrder: number;
2739
2739
  } | null>;
2740
2740
  updateInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, lineId: string, data: import("./service-shared.js").UpdateInvoiceLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2741
2741
  id: string;
@@ -2752,53 +2752,53 @@ export declare const financeService: {
2752
2752
  } | null>;
2753
2753
  deleteInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, lineId: string, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2754
2754
  id: string;
2755
- createdAt: Date;
2756
- totalCents: number;
2755
+ description: string;
2757
2756
  invoiceId: string;
2758
- bookingItemId: string | null;
2759
2757
  bookingPaymentScheduleId: string | null;
2760
- description: string;
2758
+ bookingItemId: string | null;
2759
+ sortOrder: number;
2760
+ createdAt: Date;
2761
+ totalCents: number;
2761
2762
  quantity: number;
2762
2763
  unitPriceCents: number;
2763
2764
  taxRate: number | null;
2764
- sortOrder: number;
2765
2765
  } | null>;
2766
2766
  createInvoiceFromBooking(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceFromBookingInput, bookingData: import("./service-shared.js").InvoiceFromBookingData, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
2767
2767
  id: string;
2768
+ currency: string;
2769
+ invoiceType: "invoice" | "proforma" | "credit_note";
2770
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2771
+ notes: string | null;
2772
+ bookingId: string;
2768
2773
  personId: string | null;
2769
2774
  organizationId: string | null;
2770
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2771
- notes: string | null;
2775
+ voidedAt: Date | null;
2776
+ dueDate: string;
2772
2777
  createdAt: Date;
2773
- updatedAt: Date;
2774
- invoiceNumber: string;
2775
- invoiceType: "invoice" | "proforma" | "credit_note";
2776
- convertedFromInvoiceId: string | null;
2777
- seriesId: string | null;
2778
- sequence: number | null;
2779
- templateId: string | null;
2780
- taxRegimeId: string | null;
2781
- language: string | null;
2782
- bookingId: string;
2783
- currency: string;
2784
2778
  baseCurrency: string | null;
2785
2779
  fxRateSetId: string | null;
2780
+ invoiceNumber: string;
2781
+ totalCents: number;
2782
+ paidCents: number;
2783
+ balanceDueCents: number;
2784
+ issueDate: string;
2786
2785
  subtotalCents: number;
2787
2786
  baseSubtotalCents: number | null;
2788
2787
  taxCents: number;
2789
2788
  baseTaxCents: number | null;
2790
- totalCents: number;
2791
2789
  baseTotalCents: number | null;
2792
- paidCents: number;
2793
2790
  basePaidCents: number | null;
2794
- balanceDueCents: number;
2795
2791
  baseBalanceDueCents: number | null;
2796
2792
  commissionPercent: number | null;
2797
2793
  commissionAmountCents: number | null;
2798
- issueDate: string;
2799
- dueDate: string;
2800
- voidedAt: Date | null;
2794
+ seriesId: string | null;
2795
+ convertedFromInvoiceId: string | null;
2796
+ language: string | null;
2797
+ templateId: string | null;
2798
+ taxRegimeId: string | null;
2799
+ sequence: number | null;
2801
2800
  voidReason: string | null;
2801
+ updatedAt: Date;
2802
2802
  } | null>;
2803
2803
  listInvoices(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, query: import("./service-shared.js").InvoiceListQuery): Promise<{
2804
2804
  data: {
@@ -2815,7 +2815,7 @@ export declare const financeService: {
2815
2815
  bookingId: string;
2816
2816
  personId: string | null;
2817
2817
  organizationId: string | null;
2818
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2818
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2819
2819
  currency: string;
2820
2820
  baseCurrency: string | null;
2821
2821
  fxRateSetId: string | null;
@@ -2845,40 +2845,40 @@ export declare const financeService: {
2845
2845
  }>;
2846
2846
  createInvoice(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceInput): Promise<{
2847
2847
  id: string;
2848
+ currency: string;
2849
+ invoiceType: "invoice" | "proforma" | "credit_note";
2850
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2851
+ notes: string | null;
2852
+ bookingId: string;
2848
2853
  personId: string | null;
2849
2854
  organizationId: string | null;
2850
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2851
- notes: string | null;
2855
+ voidedAt: Date | null;
2856
+ dueDate: string;
2852
2857
  createdAt: Date;
2853
- updatedAt: Date;
2854
- invoiceNumber: string;
2855
- invoiceType: "invoice" | "proforma" | "credit_note";
2856
- convertedFromInvoiceId: string | null;
2857
- seriesId: string | null;
2858
- sequence: number | null;
2859
- templateId: string | null;
2860
- taxRegimeId: string | null;
2861
- language: string | null;
2862
- bookingId: string;
2863
- currency: string;
2864
2858
  baseCurrency: string | null;
2865
2859
  fxRateSetId: string | null;
2860
+ invoiceNumber: string;
2861
+ totalCents: number;
2862
+ paidCents: number;
2863
+ balanceDueCents: number;
2864
+ issueDate: string;
2866
2865
  subtotalCents: number;
2867
2866
  baseSubtotalCents: number | null;
2868
2867
  taxCents: number;
2869
2868
  baseTaxCents: number | null;
2870
- totalCents: number;
2871
2869
  baseTotalCents: number | null;
2872
- paidCents: number;
2873
2870
  basePaidCents: number | null;
2874
- balanceDueCents: number;
2875
2871
  baseBalanceDueCents: number | null;
2876
2872
  commissionPercent: number | null;
2877
2873
  commissionAmountCents: number | null;
2878
- issueDate: string;
2879
- dueDate: string;
2880
- voidedAt: Date | null;
2874
+ seriesId: string | null;
2875
+ convertedFromInvoiceId: string | null;
2876
+ language: string | null;
2877
+ templateId: string | null;
2878
+ taxRegimeId: string | null;
2879
+ sequence: number | null;
2881
2880
  voidReason: string | null;
2881
+ updatedAt: Date;
2882
2882
  } | undefined>;
2883
2883
  getInvoiceById(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<{
2884
2884
  convertedToInvoiceId: string | null;
@@ -2895,7 +2895,7 @@ export declare const financeService: {
2895
2895
  bookingId: string;
2896
2896
  personId: string | null;
2897
2897
  organizationId: string | null;
2898
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2898
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2899
2899
  currency: string;
2900
2900
  baseCurrency: string | null;
2901
2901
  fxRateSetId: string | null;
@@ -2932,7 +2932,7 @@ export declare const financeService: {
2932
2932
  bookingId: string;
2933
2933
  personId: string | null;
2934
2934
  organizationId: string | null;
2935
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2935
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2936
2936
  currency: string;
2937
2937
  baseCurrency: string | null;
2938
2938
  fxRateSetId: string | null;
@@ -2981,7 +2981,7 @@ export declare const financeService: {
2981
2981
  bookingId: string;
2982
2982
  personId: string | null;
2983
2983
  organizationId: string | null;
2984
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
2984
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
2985
2985
  currency: string;
2986
2986
  baseCurrency: string | null;
2987
2987
  fxRateSetId: string | null;
@@ -3020,7 +3020,7 @@ export declare const financeService: {
3020
3020
  bookingId: string;
3021
3021
  personId: string | null;
3022
3022
  organizationId: string | null;
3023
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
3023
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
3024
3024
  currency: string;
3025
3025
  baseCurrency: string | null;
3026
3026
  fxRateSetId: string | null;
@@ -3059,7 +3059,7 @@ export declare const financeService: {
3059
3059
  bookingId: string;
3060
3060
  personId: string | null;
3061
3061
  organizationId: string | null;
3062
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
3062
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
3063
3063
  currency: string;
3064
3064
  baseCurrency: string | null;
3065
3065
  fxRateSetId: string | null;
@@ -3098,7 +3098,7 @@ export declare const financeService: {
3098
3098
  bookingId: string;
3099
3099
  personId: string | null;
3100
3100
  organizationId: string | null;
3101
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
3101
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
3102
3102
  currency: string;
3103
3103
  baseCurrency: string | null;
3104
3104
  fxRateSetId: string | null;
@@ -3137,7 +3137,7 @@ export declare const financeService: {
3137
3137
  bookingId: string;
3138
3138
  personId: string | null;
3139
3139
  organizationId: string | null;
3140
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
3140
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
3141
3141
  currency: string;
3142
3142
  baseCurrency: string | null;
3143
3143
  fxRateSetId: string | null;
@@ -3176,7 +3176,7 @@ export declare const financeService: {
3176
3176
  bookingId: string;
3177
3177
  personId: string | null;
3178
3178
  organizationId: string | null;
3179
- status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue" | "void";
3179
+ status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
3180
3180
  currency: string;
3181
3181
  baseCurrency: string | null;
3182
3182
  fxRateSetId: string | null;
@@ -3213,9 +3213,9 @@ export declare const financeService: {
3213
3213
  baseCurrency: string | null;
3214
3214
  baseAmountCents: number | null;
3215
3215
  fxRateSetId: string | null;
3216
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
3216
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
3217
3217
  paymentInstrumentId: string | null;
3218
- status: "pending" | "completed" | "failed" | "refunded";
3218
+ status: "pending" | "failed" | "completed" | "refunded";
3219
3219
  referenceNumber: string | null;
3220
3220
  paymentDate: string;
3221
3221
  notes: string | null;
@@ -3228,23 +3228,23 @@ export declare const financeService: {
3228
3228
  }>;
3229
3229
  createSupplierPayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateSupplierPaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
3230
3230
  id: string;
3231
- supplierId: string | null;
3232
- status: "pending" | "completed" | "failed" | "refunded";
3233
- notes: string | null;
3234
- createdAt: Date;
3235
- updatedAt: Date;
3236
- bookingId: string | null;
3237
3231
  currency: string;
3238
- baseCurrency: string | null;
3239
- fxRateSetId: string | null;
3232
+ status: "pending" | "failed" | "completed" | "refunded";
3240
3233
  amountCents: number;
3241
- baseAmountCents: number | null;
3242
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
3234
+ notes: string | null;
3235
+ bookingId: string | null;
3236
+ supplierId: string | null;
3243
3237
  paymentInstrumentId: string | null;
3244
- referenceNumber: string | null;
3238
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
3245
3239
  paymentDate: string;
3246
- bookingSupplierStatusId: string | null;
3240
+ referenceNumber: string | null;
3247
3241
  supplierInvoiceId: string | null;
3242
+ createdAt: Date;
3243
+ bookingSupplierStatusId: string | null;
3244
+ baseCurrency: string | null;
3245
+ baseAmountCents: number | null;
3246
+ fxRateSetId: string | null;
3247
+ updatedAt: Date;
3248
3248
  } | null>;
3249
3249
  updateSupplierPayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdateSupplierPaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
3250
3250
  id: string;
@@ -3257,9 +3257,9 @@ export declare const financeService: {
3257
3257
  baseCurrency: string | null;
3258
3258
  baseAmountCents: number | null;
3259
3259
  fxRateSetId: string | null;
3260
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other";
3260
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
3261
3261
  paymentInstrumentId: string | null;
3262
- status: "pending" | "completed" | "failed" | "refunded";
3262
+ status: "pending" | "failed" | "completed" | "refunded";
3263
3263
  referenceNumber: string | null;
3264
3264
  paymentDate: string;
3265
3265
  notes: string | null;
@@ -3795,19 +3795,19 @@ export declare const financeService: {
3795
3795
  }>, "where" | "orderBy">;
3796
3796
  createBookingItemTaxLine(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingItemId: string, data: import("./service-shared.js").CreateBookingItemTaxLineInput): Promise<{
3797
3797
  id: string;
3798
- name: string;
3799
- createdAt: Date;
3800
- updatedAt: Date;
3801
3798
  currency: string;
3802
- bookingItemId: string;
3803
- amountCents: number;
3804
- sortOrder: number;
3805
3799
  code: string | null;
3800
+ name: string;
3801
+ amountCents: number;
3802
+ bookingItemId: string;
3806
3803
  jurisdiction: string | null;
3807
3804
  scope: "included" | "excluded" | "withheld";
3808
3805
  rateBasisPoints: number | null;
3809
3806
  includedInPrice: boolean;
3810
3807
  remittanceParty: string | null;
3808
+ sortOrder: number;
3809
+ createdAt: Date;
3810
+ updatedAt: Date;
3811
3811
  } | null>;
3812
3812
  updateBookingItemTaxLine(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, taxLineId: string, data: import("./service-shared.js").UpdateBookingItemTaxLineInput): Promise<{
3813
3813
  id: string;
@@ -3902,7 +3902,7 @@ export declare const financeService: {
3902
3902
  tableName: "booking_item_commissions";
3903
3903
  dataType: "string";
3904
3904
  columnType: "PgEnumColumn";
3905
- data: "percentage" | "fixed" | "markup" | "net";
3905
+ data: "fixed" | "percentage" | "markup" | "net";
3906
3906
  driverParam: string;
3907
3907
  notNull: true;
3908
3908
  hasDefault: true;
@@ -3970,7 +3970,7 @@ export declare const financeService: {
3970
3970
  tableName: "booking_item_commissions";
3971
3971
  dataType: "string";
3972
3972
  columnType: "PgEnumColumn";
3973
- data: "paid" | "void" | "pending" | "accrued" | "payable";
3973
+ data: "void" | "paid" | "pending" | "accrued" | "payable";
3974
3974
  driverParam: string;
3975
3975
  notNull: true;
3976
3976
  hasDefault: true;
@@ -4072,11 +4072,11 @@ export declare const financeService: {
4072
4072
  bookingItemId: string;
4073
4073
  channelId: string | null;
4074
4074
  recipientType: "other" | "supplier" | "channel" | "agency" | "internal" | "affiliate" | "agent";
4075
- commissionModel: "percentage" | "fixed" | "markup" | "net";
4075
+ commissionModel: "fixed" | "percentage" | "markup" | "net";
4076
4076
  currency: string | null;
4077
4077
  amountCents: number | null;
4078
4078
  rateBasisPoints: number | null;
4079
- status: "paid" | "void" | "pending" | "accrued" | "payable";
4079
+ status: "void" | "paid" | "pending" | "accrued" | "payable";
4080
4080
  payableAt: string | null;
4081
4081
  paidAt: string | null;
4082
4082
  notes: string | null;
@@ -4156,7 +4156,7 @@ export declare const financeService: {
4156
4156
  tableName: "booking_item_commissions";
4157
4157
  dataType: "string";
4158
4158
  columnType: "PgEnumColumn";
4159
- data: "percentage" | "fixed" | "markup" | "net";
4159
+ data: "fixed" | "percentage" | "markup" | "net";
4160
4160
  driverParam: string;
4161
4161
  notNull: true;
4162
4162
  hasDefault: true;
@@ -4224,7 +4224,7 @@ export declare const financeService: {
4224
4224
  tableName: "booking_item_commissions";
4225
4225
  dataType: "string";
4226
4226
  columnType: "PgEnumColumn";
4227
- data: "paid" | "void" | "pending" | "accrued" | "payable";
4227
+ data: "void" | "paid" | "pending" | "accrued" | "payable";
4228
4228
  driverParam: string;
4229
4229
  notNull: true;
4230
4230
  hasDefault: true;
@@ -4324,30 +4324,30 @@ export declare const financeService: {
4324
4324
  }>, "where" | "orderBy">;
4325
4325
  createBookingItemCommission(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingItemId: string, data: import("./service-shared.js").CreateBookingItemCommissionInput): Promise<{
4326
4326
  id: string;
4327
- channelId: string | null;
4328
- status: "paid" | "void" | "pending" | "accrued" | "payable";
4329
- notes: string | null;
4330
- createdAt: Date;
4331
- updatedAt: Date;
4332
4327
  currency: string | null;
4333
- bookingItemId: string;
4328
+ status: "void" | "paid" | "pending" | "accrued" | "payable";
4334
4329
  amountCents: number | null;
4330
+ notes: string | null;
4331
+ channelId: string | null;
4332
+ bookingItemId: string;
4335
4333
  rateBasisPoints: number | null;
4336
4334
  recipientType: "other" | "supplier" | "channel" | "agency" | "internal" | "affiliate" | "agent";
4337
- commissionModel: "percentage" | "fixed" | "markup" | "net";
4335
+ commissionModel: "fixed" | "percentage" | "markup" | "net";
4338
4336
  payableAt: string | null;
4339
4337
  paidAt: string | null;
4338
+ createdAt: Date;
4339
+ updatedAt: Date;
4340
4340
  } | null>;
4341
4341
  updateBookingItemCommission(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, commissionId: string, data: import("./service-shared.js").UpdateBookingItemCommissionInput): Promise<{
4342
4342
  id: string;
4343
4343
  bookingItemId: string;
4344
4344
  channelId: string | null;
4345
4345
  recipientType: "other" | "supplier" | "channel" | "agency" | "internal" | "affiliate" | "agent";
4346
- commissionModel: "percentage" | "fixed" | "markup" | "net";
4346
+ commissionModel: "fixed" | "percentage" | "markup" | "net";
4347
4347
  currency: string | null;
4348
4348
  amountCents: number | null;
4349
4349
  rateBasisPoints: number | null;
4350
- status: "paid" | "void" | "pending" | "accrued" | "payable";
4350
+ status: "void" | "paid" | "pending" | "accrued" | "payable";
4351
4351
  payableAt: string | null;
4352
4352
  paidAt: string | null;
4353
4353
  notes: string | null;
@@ -4431,7 +4431,7 @@ export declare const financeService: {
4431
4431
  tableName: "booking_guarantees";
4432
4432
  dataType: "string";
4433
4433
  columnType: "PgEnumColumn";
4434
- data: "bank_transfer" | "credit_card" | "other" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4434
+ data: "other" | "credit_card" | "bank_transfer" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4435
4435
  driverParam: string;
4436
4436
  notNull: true;
4437
4437
  hasDefault: false;
@@ -4448,7 +4448,7 @@ export declare const financeService: {
4448
4448
  tableName: "booking_guarantees";
4449
4449
  dataType: "string";
4450
4450
  columnType: "PgEnumColumn";
4451
- data: "pending" | "failed" | "cancelled" | "expired" | "active" | "released";
4451
+ data: "expired" | "active" | "pending" | "failed" | "cancelled" | "released";
4452
4452
  driverParam: string;
4453
4453
  notNull: true;
4454
4454
  hasDefault: true;
@@ -4669,8 +4669,8 @@ export declare const financeService: {
4669
4669
  bookingId: string;
4670
4670
  bookingPaymentScheduleId: string | null;
4671
4671
  bookingItemId: string | null;
4672
- guaranteeType: "bank_transfer" | "credit_card" | "other" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4673
- status: "pending" | "failed" | "cancelled" | "expired" | "active" | "released";
4672
+ guaranteeType: "other" | "credit_card" | "bank_transfer" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4673
+ status: "expired" | "active" | "pending" | "failed" | "cancelled" | "released";
4674
4674
  paymentInstrumentId: string | null;
4675
4675
  paymentAuthorizationId: string | null;
4676
4676
  currency: string | null;
@@ -4757,7 +4757,7 @@ export declare const financeService: {
4757
4757
  tableName: "booking_guarantees";
4758
4758
  dataType: "string";
4759
4759
  columnType: "PgEnumColumn";
4760
- data: "bank_transfer" | "credit_card" | "other" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4760
+ data: "other" | "credit_card" | "bank_transfer" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
4761
4761
  driverParam: string;
4762
4762
  notNull: true;
4763
4763
  hasDefault: false;
@@ -4774,7 +4774,7 @@ export declare const financeService: {
4774
4774
  tableName: "booking_guarantees";
4775
4775
  dataType: "string";
4776
4776
  columnType: "PgEnumColumn";
4777
- data: "pending" | "failed" | "cancelled" | "expired" | "active" | "released";
4777
+ data: "expired" | "active" | "pending" | "failed" | "cancelled" | "released";
4778
4778
  driverParam: string;
4779
4779
  notNull: true;
4780
4780
  hasDefault: true;
@@ -4992,53 +4992,51 @@ export declare const financeService: {
4992
4992
  }, {}, {}>;
4993
4993
  }>, "where" | "orderBy">;
4994
4994
  createBookingGuarantee(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingId: string, data: import("./service-shared.js").CreateBookingGuaranteeInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
4995
- id: string;
4996
- status: "pending" | "failed" | "cancelled" | "expired" | "active" | "released";
4997
4995
  provider: string | null;
4998
- notes: string | null;
4999
- createdAt: Date;
5000
- updatedAt: Date;
5001
- bookingId: string;
4996
+ id: string;
5002
4997
  currency: string | null;
5003
- bookingItemId: string | null;
4998
+ status: "expired" | "active" | "pending" | "failed" | "cancelled" | "released";
5004
4999
  amountCents: number | null;
5000
+ expiresAt: Date | null;
5001
+ notes: string | null;
5002
+ bookingId: string;
5005
5003
  bookingPaymentScheduleId: string | null;
5006
5004
  paymentInstrumentId: string | null;
5007
- expiresAt: Date | null;
5008
5005
  paymentAuthorizationId: string | null;
5009
5006
  referenceNumber: string | null;
5010
- guaranteeType: "bank_transfer" | "credit_card" | "other" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
5007
+ bookingItemId: string | null;
5008
+ guaranteeType: "other" | "credit_card" | "bank_transfer" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
5011
5009
  guaranteedAt: Date | null;
5012
5010
  releasedAt: Date | null;
5011
+ createdAt: Date;
5012
+ updatedAt: Date;
5013
5013
  } | null>;
5014
5014
  createPaymentSessionFromBookingGuarantee(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, guaranteeId: string, data: import("./service-shared.js").CreatePaymentSessionFromGuaranteeInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5015
- id: string;
5016
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5017
5015
  provider: string | null;
5018
- notes: string | null;
5016
+ id: string;
5017
+ currency: string;
5018
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5019
5019
  metadata: Record<string, unknown> | null;
5020
- createdAt: Date;
5021
- updatedAt: Date;
5020
+ idempotencyKey: string | null;
5021
+ amountCents: number;
5022
+ expiresAt: Date | null;
5023
+ notes: string | null;
5022
5024
  bookingId: string | null;
5023
- currency: string;
5025
+ paymentId: string | null;
5024
5026
  invoiceId: string | null;
5025
- amountCents: number;
5026
5027
  bookingPaymentScheduleId: string | null;
5027
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5028
- paymentInstrumentId: string | null;
5029
- orderId: string | null;
5030
5028
  bookingGuaranteeId: string | null;
5031
- expiresAt: Date | null;
5032
- paymentAuthorizationId: string | null;
5033
- paymentCaptureId: string | null;
5034
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5035
- targetId: string | null;
5036
- paymentId: string | null;
5029
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5037
5030
  providerSessionId: string | null;
5038
5031
  providerPaymentId: string | null;
5039
5032
  externalReference: string | null;
5040
- idempotencyKey: string | null;
5041
5033
  clientReference: string | null;
5034
+ orderId: string | null;
5035
+ targetId: string | null;
5036
+ paymentInstrumentId: string | null;
5037
+ paymentAuthorizationId: string | null;
5038
+ paymentCaptureId: string | null;
5039
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5042
5040
  payerPersonId: string | null;
5043
5041
  payerOrganizationId: string | null;
5044
5042
  payerEmail: string | null;
@@ -5054,14 +5052,16 @@ export declare const financeService: {
5054
5052
  failureCode: string | null;
5055
5053
  failureMessage: string | null;
5056
5054
  providerPayload: Record<string, unknown> | null;
5055
+ createdAt: Date;
5056
+ updatedAt: Date;
5057
5057
  } | null>;
5058
5058
  updateBookingGuarantee(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, guaranteeId: string, data: import("./service-shared.js").UpdateBookingGuaranteeInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5059
5059
  id: string;
5060
5060
  bookingId: string;
5061
5061
  bookingPaymentScheduleId: string | null;
5062
5062
  bookingItemId: string | null;
5063
- guaranteeType: "bank_transfer" | "credit_card" | "other" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
5064
- status: "pending" | "failed" | "cancelled" | "expired" | "active" | "released";
5063
+ guaranteeType: "other" | "credit_card" | "bank_transfer" | "deposit" | "preauth" | "card_on_file" | "voucher" | "agency_letter";
5064
+ status: "expired" | "active" | "pending" | "failed" | "cancelled" | "released";
5065
5065
  paymentInstrumentId: string | null;
5066
5066
  paymentAuthorizationId: string | null;
5067
5067
  currency: string | null;
@@ -5152,7 +5152,7 @@ export declare const financeService: {
5152
5152
  tableName: "booking_payment_schedules";
5153
5153
  dataType: "string";
5154
5154
  columnType: "PgEnumColumn";
5155
- data: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5155
+ data: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5156
5156
  driverParam: string;
5157
5157
  notNull: true;
5158
5158
  hasDefault: true;
@@ -5271,7 +5271,7 @@ export declare const financeService: {
5271
5271
  bookingId: string;
5272
5272
  bookingItemId: string | null;
5273
5273
  scheduleType: "other" | "deposit" | "installment" | "balance" | "hold";
5274
- status: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5274
+ status: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5275
5275
  dueDate: string;
5276
5276
  currency: string;
5277
5277
  amountCents: number;
@@ -5352,7 +5352,7 @@ export declare const financeService: {
5352
5352
  tableName: "booking_payment_schedules";
5353
5353
  dataType: "string";
5354
5354
  columnType: "PgEnumColumn";
5355
- data: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5355
+ data: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5356
5356
  driverParam: string;
5357
5357
  notNull: true;
5358
5358
  hasDefault: true;
@@ -5469,16 +5469,16 @@ export declare const financeService: {
5469
5469
  }>, "where" | "orderBy">;
5470
5470
  createBookingPaymentSchedule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingId: string, data: import("./service-shared.js").CreateBookingPaymentScheduleInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5471
5471
  id: string;
5472
- status: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5472
+ currency: string;
5473
+ status: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5474
+ amountCents: number;
5473
5475
  notes: string | null;
5474
- createdAt: Date;
5475
- updatedAt: Date;
5476
5476
  bookingId: string;
5477
- currency: string;
5478
- dueDate: string;
5479
5477
  bookingItemId: string | null;
5480
5478
  scheduleType: "other" | "deposit" | "installment" | "balance" | "hold";
5481
- amountCents: number;
5479
+ dueDate: string;
5480
+ createdAt: Date;
5481
+ updatedAt: Date;
5482
5482
  } | null>;
5483
5483
  applyComputedPaymentSchedule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingId: string, entries: Array<{
5484
5484
  scheduleType: "deposit" | "balance" | "installment" | "hold" | "other" | "full";
@@ -5490,36 +5490,36 @@ export declare const financeService: {
5490
5490
  replace?: boolean;
5491
5491
  }): Promise<{
5492
5492
  id: string;
5493
- status: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5493
+ currency: string;
5494
+ status: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5495
+ amountCents: number;
5494
5496
  notes: string | null;
5495
- createdAt: Date;
5496
- updatedAt: Date;
5497
5497
  bookingId: string;
5498
- currency: string;
5499
- dueDate: string;
5500
5498
  bookingItemId: string | null;
5501
5499
  scheduleType: "other" | "deposit" | "installment" | "balance" | "hold";
5502
- amountCents: number;
5500
+ dueDate: string;
5501
+ createdAt: Date;
5502
+ updatedAt: Date;
5503
5503
  }[] | null>;
5504
5504
  applyDefaultBookingPaymentPlan(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingId: string, data: import("./service-shared.js").ApplyDefaultBookingPaymentPlanInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5505
5505
  id: string;
5506
- status: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5506
+ currency: string;
5507
+ status: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5508
+ amountCents: number;
5507
5509
  notes: string | null;
5508
- createdAt: Date;
5509
- updatedAt: Date;
5510
5510
  bookingId: string;
5511
- currency: string;
5512
- dueDate: string;
5513
5511
  bookingItemId: string | null;
5514
5512
  scheduleType: "other" | "deposit" | "installment" | "balance" | "hold";
5515
- amountCents: number;
5513
+ dueDate: string;
5514
+ createdAt: Date;
5515
+ updatedAt: Date;
5516
5516
  }[] | null>;
5517
5517
  updateBookingPaymentSchedule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, scheduleId: string, data: import("./service-shared.js").UpdateBookingPaymentScheduleInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5518
5518
  id: string;
5519
5519
  bookingId: string;
5520
5520
  bookingItemId: string | null;
5521
5521
  scheduleType: "other" | "deposit" | "installment" | "balance" | "hold";
5522
- status: "paid" | "pending" | "cancelled" | "expired" | "due" | "waived";
5522
+ status: "paid" | "expired" | "pending" | "cancelled" | "due" | "waived";
5523
5523
  dueDate: string;
5524
5524
  currency: string;
5525
5525
  amountCents: number;
@@ -5531,33 +5531,31 @@ export declare const financeService: {
5531
5531
  id: string;
5532
5532
  } | null>;
5533
5533
  createPaymentSessionFromBookingSchedule(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, scheduleId: string, data: import("./service-shared.js").CreatePaymentSessionFromScheduleInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5534
- id: string;
5535
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5536
5534
  provider: string | null;
5537
- notes: string | null;
5535
+ id: string;
5536
+ currency: string;
5537
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5538
5538
  metadata: Record<string, unknown> | null;
5539
- createdAt: Date;
5540
- updatedAt: Date;
5539
+ idempotencyKey: string | null;
5540
+ amountCents: number;
5541
+ expiresAt: Date | null;
5542
+ notes: string | null;
5541
5543
  bookingId: string | null;
5542
- currency: string;
5544
+ paymentId: string | null;
5543
5545
  invoiceId: string | null;
5544
- amountCents: number;
5545
5546
  bookingPaymentScheduleId: string | null;
5546
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5547
- paymentInstrumentId: string | null;
5548
- orderId: string | null;
5549
5547
  bookingGuaranteeId: string | null;
5550
- expiresAt: Date | null;
5551
- paymentAuthorizationId: string | null;
5552
- paymentCaptureId: string | null;
5553
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5554
- targetId: string | null;
5555
- paymentId: string | null;
5548
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5556
5549
  providerSessionId: string | null;
5557
5550
  providerPaymentId: string | null;
5558
5551
  externalReference: string | null;
5559
- idempotencyKey: string | null;
5560
5552
  clientReference: string | null;
5553
+ orderId: string | null;
5554
+ targetId: string | null;
5555
+ paymentInstrumentId: string | null;
5556
+ paymentAuthorizationId: string | null;
5557
+ paymentCaptureId: string | null;
5558
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5561
5559
  payerPersonId: string | null;
5562
5560
  payerOrganizationId: string | null;
5563
5561
  payerEmail: string | null;
@@ -5573,35 +5571,35 @@ export declare const financeService: {
5573
5571
  failureCode: string | null;
5574
5572
  failureMessage: string | null;
5575
5573
  providerPayload: Record<string, unknown> | null;
5574
+ createdAt: Date;
5575
+ updatedAt: Date;
5576
5576
  } | null>;
5577
5577
  createPaymentSessionFromInvoice(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreatePaymentSessionFromInvoiceInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5578
- id: string;
5579
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5580
5578
  provider: string | null;
5581
- notes: string | null;
5579
+ id: string;
5580
+ currency: string;
5581
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5582
5582
  metadata: Record<string, unknown> | null;
5583
- createdAt: Date;
5584
- updatedAt: Date;
5583
+ idempotencyKey: string | null;
5584
+ amountCents: number;
5585
+ expiresAt: Date | null;
5586
+ notes: string | null;
5585
5587
  bookingId: string | null;
5586
- currency: string;
5588
+ paymentId: string | null;
5587
5589
  invoiceId: string | null;
5588
- amountCents: number;
5589
5590
  bookingPaymentScheduleId: string | null;
5590
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5591
- paymentInstrumentId: string | null;
5592
- orderId: string | null;
5593
5591
  bookingGuaranteeId: string | null;
5594
- expiresAt: Date | null;
5595
- paymentAuthorizationId: string | null;
5596
- paymentCaptureId: string | null;
5597
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5598
- targetId: string | null;
5599
- paymentId: string | null;
5592
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5600
5593
  providerSessionId: string | null;
5601
5594
  providerPaymentId: string | null;
5602
5595
  externalReference: string | null;
5603
- idempotencyKey: string | null;
5604
5596
  clientReference: string | null;
5597
+ orderId: string | null;
5598
+ targetId: string | null;
5599
+ paymentInstrumentId: string | null;
5600
+ paymentAuthorizationId: string | null;
5601
+ paymentCaptureId: string | null;
5602
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5605
5603
  payerPersonId: string | null;
5606
5604
  payerOrganizationId: string | null;
5607
5605
  payerEmail: string | null;
@@ -5617,6 +5615,8 @@ export declare const financeService: {
5617
5615
  failureCode: string | null;
5618
5616
  failureMessage: string | null;
5619
5617
  providerPayload: Record<string, unknown> | null;
5618
+ createdAt: Date;
5619
+ updatedAt: Date;
5620
5620
  } | null>;
5621
5621
  settleCoveredBookingPaymentSchedules(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, bookingId: string): Promise<import("./service-booking-payment-schedules.js").SettleBookingPaymentSchedulesResult>;
5622
5622
  listPaymentAuthorizations(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, query: import("./service-shared.js").PaymentAuthorizationListQuery): Promise<import("@voyant-travel/types").ListResponse<{
@@ -5626,8 +5626,8 @@ export declare const financeService: {
5626
5626
  invoiceId: string | null;
5627
5627
  bookingGuaranteeId: string | null;
5628
5628
  paymentInstrumentId: string | null;
5629
- status: "pending" | "failed" | "authorized" | "expired" | "partially_captured" | "captured" | "voided";
5630
- captureMode: "automatic" | "manual";
5629
+ status: "expired" | "pending" | "failed" | "authorized" | "partially_captured" | "captured" | "voided";
5630
+ captureMode: "manual" | "automatic";
5631
5631
  currency: string;
5632
5632
  amountCents: number;
5633
5633
  provider: string | null;
@@ -5647,8 +5647,8 @@ export declare const financeService: {
5647
5647
  invoiceId: string | null;
5648
5648
  bookingGuaranteeId: string | null;
5649
5649
  paymentInstrumentId: string | null;
5650
- status: "pending" | "failed" | "authorized" | "expired" | "partially_captured" | "captured" | "voided";
5651
- captureMode: "automatic" | "manual";
5650
+ status: "expired" | "pending" | "failed" | "authorized" | "partially_captured" | "captured" | "voided";
5651
+ captureMode: "manual" | "automatic";
5652
5652
  currency: string;
5653
5653
  amountCents: number;
5654
5654
  provider: string | null;
@@ -5662,25 +5662,25 @@ export declare const financeService: {
5662
5662
  updatedAt: Date;
5663
5663
  } | null>;
5664
5664
  createPaymentAuthorization(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreatePaymentAuthorizationInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5665
- id: string;
5666
- status: "pending" | "failed" | "authorized" | "expired" | "partially_captured" | "captured" | "voided";
5667
5665
  provider: string | null;
5666
+ id: string;
5667
+ currency: string;
5668
+ status: "expired" | "pending" | "failed" | "authorized" | "partially_captured" | "captured" | "voided";
5669
+ amountCents: number;
5670
+ expiresAt: Date | null;
5668
5671
  notes: string | null;
5669
- createdAt: Date;
5670
- updatedAt: Date;
5671
5672
  bookingId: string | null;
5672
- currency: string;
5673
- voidedAt: Date | null;
5674
5673
  invoiceId: string | null;
5675
- amountCents: number;
5676
- paymentInstrumentId: string | null;
5677
- orderId: string | null;
5678
5674
  bookingGuaranteeId: string | null;
5679
- captureMode: "automatic" | "manual";
5675
+ orderId: string | null;
5676
+ paymentInstrumentId: string | null;
5677
+ captureMode: "manual" | "automatic";
5680
5678
  externalAuthorizationId: string | null;
5681
5679
  approvalCode: string | null;
5682
5680
  authorizedAt: Date | null;
5683
- expiresAt: Date | null;
5681
+ voidedAt: Date | null;
5682
+ createdAt: Date;
5683
+ updatedAt: Date;
5684
5684
  } | null>;
5685
5685
  updatePaymentAuthorization(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdatePaymentAuthorizationInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5686
5686
  id: string;
@@ -5689,8 +5689,8 @@ export declare const financeService: {
5689
5689
  invoiceId: string | null;
5690
5690
  bookingGuaranteeId: string | null;
5691
5691
  paymentInstrumentId: string | null;
5692
- status: "pending" | "failed" | "authorized" | "expired" | "partially_captured" | "captured" | "voided";
5693
- captureMode: "automatic" | "manual";
5692
+ status: "expired" | "pending" | "failed" | "authorized" | "partially_captured" | "captured" | "voided";
5693
+ captureMode: "manual" | "automatic";
5694
5694
  currency: string;
5695
5695
  amountCents: number;
5696
5696
  provider: string | null;
@@ -5710,7 +5710,7 @@ export declare const financeService: {
5710
5710
  id: string;
5711
5711
  paymentAuthorizationId: string | null;
5712
5712
  invoiceId: string | null;
5713
- status: "pending" | "completed" | "failed" | "refunded" | "voided";
5713
+ status: "pending" | "failed" | "voided" | "completed" | "refunded";
5714
5714
  currency: string;
5715
5715
  amountCents: number;
5716
5716
  provider: string | null;
@@ -5725,7 +5725,7 @@ export declare const financeService: {
5725
5725
  id: string;
5726
5726
  paymentAuthorizationId: string | null;
5727
5727
  invoiceId: string | null;
5728
- status: "pending" | "completed" | "failed" | "refunded" | "voided";
5728
+ status: "pending" | "failed" | "voided" | "completed" | "refunded";
5729
5729
  currency: string;
5730
5730
  amountCents: number;
5731
5731
  provider: string | null;
@@ -5737,25 +5737,25 @@ export declare const financeService: {
5737
5737
  updatedAt: Date;
5738
5738
  } | null>;
5739
5739
  createPaymentCapture(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreatePaymentCaptureInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5740
- id: string;
5741
- status: "pending" | "completed" | "failed" | "refunded" | "voided";
5742
5740
  provider: string | null;
5743
- notes: string | null;
5744
- createdAt: Date;
5745
- updatedAt: Date;
5741
+ id: string;
5746
5742
  currency: string;
5747
- invoiceId: string | null;
5743
+ status: "pending" | "failed" | "voided" | "completed" | "refunded";
5748
5744
  amountCents: number;
5745
+ notes: string | null;
5746
+ invoiceId: string | null;
5749
5747
  paymentAuthorizationId: string | null;
5750
5748
  externalCaptureId: string | null;
5751
5749
  capturedAt: Date | null;
5752
5750
  settledAt: Date | null;
5751
+ createdAt: Date;
5752
+ updatedAt: Date;
5753
5753
  } | null>;
5754
5754
  updatePaymentCapture(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdatePaymentCaptureInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5755
5755
  id: string;
5756
5756
  paymentAuthorizationId: string | null;
5757
5757
  invoiceId: string | null;
5758
- status: "pending" | "completed" | "failed" | "refunded" | "voided";
5758
+ status: "pending" | "failed" | "voided" | "completed" | "refunded";
5759
5759
  currency: string;
5760
5760
  amountCents: number;
5761
5761
  provider: string | null;
@@ -5771,7 +5771,7 @@ export declare const financeService: {
5771
5771
  } | null>;
5772
5772
  completePaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").CompletePaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5773
5773
  id: string;
5774
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5774
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5775
5775
  targetId: string | null;
5776
5776
  bookingId: string | null;
5777
5777
  orderId: string | null;
@@ -5782,7 +5782,7 @@ export declare const financeService: {
5782
5782
  paymentAuthorizationId: string | null;
5783
5783
  paymentCaptureId: string | null;
5784
5784
  paymentId: string | null;
5785
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5785
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5786
5786
  provider: string | null;
5787
5787
  providerSessionId: string | null;
5788
5788
  providerPaymentId: string | null;
@@ -5791,7 +5791,7 @@ export declare const financeService: {
5791
5791
  clientReference: string | null;
5792
5792
  currency: string;
5793
5793
  amountCents: number;
5794
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5794
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5795
5795
  payerPersonId: string | null;
5796
5796
  payerOrganizationId: string | null;
5797
5797
  payerEmail: string | null;
@@ -5815,7 +5815,7 @@ export declare const financeService: {
5815
5815
  } | null>;
5816
5816
  listPaymentSessions(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, query: import("./service-shared.js").PaymentSessionListQuery): Promise<import("@voyant-travel/types").ListResponse<{
5817
5817
  id: string;
5818
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5818
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5819
5819
  targetId: string | null;
5820
5820
  bookingId: string | null;
5821
5821
  orderId: string | null;
@@ -5826,7 +5826,7 @@ export declare const financeService: {
5826
5826
  paymentAuthorizationId: string | null;
5827
5827
  paymentCaptureId: string | null;
5828
5828
  paymentId: string | null;
5829
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5829
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5830
5830
  provider: string | null;
5831
5831
  providerSessionId: string | null;
5832
5832
  providerPaymentId: string | null;
@@ -5835,7 +5835,7 @@ export declare const financeService: {
5835
5835
  clientReference: string | null;
5836
5836
  currency: string;
5837
5837
  amountCents: number;
5838
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5838
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5839
5839
  payerPersonId: string | null;
5840
5840
  payerOrganizationId: string | null;
5841
5841
  payerEmail: string | null;
@@ -5859,7 +5859,7 @@ export declare const financeService: {
5859
5859
  }>>;
5860
5860
  getPaymentSessionById(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<{
5861
5861
  id: string;
5862
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5862
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5863
5863
  targetId: string | null;
5864
5864
  bookingId: string | null;
5865
5865
  orderId: string | null;
@@ -5870,7 +5870,7 @@ export declare const financeService: {
5870
5870
  paymentAuthorizationId: string | null;
5871
5871
  paymentCaptureId: string | null;
5872
5872
  paymentId: string | null;
5873
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5873
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5874
5874
  provider: string | null;
5875
5875
  providerSessionId: string | null;
5876
5876
  providerPaymentId: string | null;
@@ -5879,7 +5879,7 @@ export declare const financeService: {
5879
5879
  clientReference: string | null;
5880
5880
  currency: string;
5881
5881
  amountCents: number;
5882
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5882
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5883
5883
  payerPersonId: string | null;
5884
5884
  payerOrganizationId: string | null;
5885
5885
  payerEmail: string | null;
@@ -5902,33 +5902,31 @@ export declare const financeService: {
5902
5902
  updatedAt: Date;
5903
5903
  } | null>;
5904
5904
  createPaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreatePaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5905
- id: string;
5906
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5907
5905
  provider: string | null;
5908
- notes: string | null;
5906
+ id: string;
5907
+ currency: string;
5908
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5909
5909
  metadata: Record<string, unknown> | null;
5910
- createdAt: Date;
5911
- updatedAt: Date;
5910
+ idempotencyKey: string | null;
5911
+ amountCents: number;
5912
+ expiresAt: Date | null;
5913
+ notes: string | null;
5912
5914
  bookingId: string | null;
5913
- currency: string;
5915
+ paymentId: string | null;
5914
5916
  invoiceId: string | null;
5915
- amountCents: number;
5916
5917
  bookingPaymentScheduleId: string | null;
5917
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5918
- paymentInstrumentId: string | null;
5919
- orderId: string | null;
5920
5918
  bookingGuaranteeId: string | null;
5921
- expiresAt: Date | null;
5922
- paymentAuthorizationId: string | null;
5923
- paymentCaptureId: string | null;
5924
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5925
- targetId: string | null;
5926
- paymentId: string | null;
5919
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5927
5920
  providerSessionId: string | null;
5928
5921
  providerPaymentId: string | null;
5929
5922
  externalReference: string | null;
5930
- idempotencyKey: string | null;
5931
5923
  clientReference: string | null;
5924
+ orderId: string | null;
5925
+ targetId: string | null;
5926
+ paymentInstrumentId: string | null;
5927
+ paymentAuthorizationId: string | null;
5928
+ paymentCaptureId: string | null;
5929
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5932
5930
  payerPersonId: string | null;
5933
5931
  payerOrganizationId: string | null;
5934
5932
  payerEmail: string | null;
@@ -5944,10 +5942,12 @@ export declare const financeService: {
5944
5942
  failureCode: string | null;
5945
5943
  failureMessage: string | null;
5946
5944
  providerPayload: Record<string, unknown> | null;
5945
+ createdAt: Date;
5946
+ updatedAt: Date;
5947
5947
  } | null>;
5948
5948
  updatePaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdatePaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5949
5949
  id: string;
5950
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5950
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5951
5951
  targetId: string | null;
5952
5952
  bookingId: string | null;
5953
5953
  orderId: string | null;
@@ -5958,7 +5958,7 @@ export declare const financeService: {
5958
5958
  paymentAuthorizationId: string | null;
5959
5959
  paymentCaptureId: string | null;
5960
5960
  paymentId: string | null;
5961
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
5961
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
5962
5962
  provider: string | null;
5963
5963
  providerSessionId: string | null;
5964
5964
  providerPaymentId: string | null;
@@ -5967,7 +5967,7 @@ export declare const financeService: {
5967
5967
  clientReference: string | null;
5968
5968
  currency: string;
5969
5969
  amountCents: number;
5970
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
5970
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
5971
5971
  payerPersonId: string | null;
5972
5972
  payerOrganizationId: string | null;
5973
5973
  payerEmail: string | null;
@@ -5991,7 +5991,7 @@ export declare const financeService: {
5991
5991
  } | null>;
5992
5992
  markPaymentSessionRequiresRedirect(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").MarkPaymentSessionRequiresRedirectInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
5993
5993
  id: string;
5994
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5994
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
5995
5995
  targetId: string | null;
5996
5996
  bookingId: string | null;
5997
5997
  orderId: string | null;
@@ -6002,7 +6002,7 @@ export declare const financeService: {
6002
6002
  paymentAuthorizationId: string | null;
6003
6003
  paymentCaptureId: string | null;
6004
6004
  paymentId: string | null;
6005
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
6005
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
6006
6006
  provider: string | null;
6007
6007
  providerSessionId: string | null;
6008
6008
  providerPaymentId: string | null;
@@ -6011,7 +6011,7 @@ export declare const financeService: {
6011
6011
  clientReference: string | null;
6012
6012
  currency: string;
6013
6013
  amountCents: number;
6014
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
6014
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
6015
6015
  payerPersonId: string | null;
6016
6016
  payerOrganizationId: string | null;
6017
6017
  payerEmail: string | null;
@@ -6035,7 +6035,7 @@ export declare const financeService: {
6035
6035
  } | null>;
6036
6036
  failPaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").FailPaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
6037
6037
  id: string;
6038
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6038
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6039
6039
  targetId: string | null;
6040
6040
  bookingId: string | null;
6041
6041
  orderId: string | null;
@@ -6046,7 +6046,7 @@ export declare const financeService: {
6046
6046
  paymentAuthorizationId: string | null;
6047
6047
  paymentCaptureId: string | null;
6048
6048
  paymentId: string | null;
6049
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
6049
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
6050
6050
  provider: string | null;
6051
6051
  providerSessionId: string | null;
6052
6052
  providerPaymentId: string | null;
@@ -6055,7 +6055,7 @@ export declare const financeService: {
6055
6055
  clientReference: string | null;
6056
6056
  currency: string;
6057
6057
  amountCents: number;
6058
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
6058
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
6059
6059
  payerPersonId: string | null;
6060
6060
  payerOrganizationId: string | null;
6061
6061
  payerEmail: string | null;
@@ -6079,7 +6079,7 @@ export declare const financeService: {
6079
6079
  } | null>;
6080
6080
  cancelPaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").CancelPaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
6081
6081
  id: string;
6082
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6082
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6083
6083
  targetId: string | null;
6084
6084
  bookingId: string | null;
6085
6085
  orderId: string | null;
@@ -6090,7 +6090,7 @@ export declare const financeService: {
6090
6090
  paymentAuthorizationId: string | null;
6091
6091
  paymentCaptureId: string | null;
6092
6092
  paymentId: string | null;
6093
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
6093
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
6094
6094
  provider: string | null;
6095
6095
  providerSessionId: string | null;
6096
6096
  providerPaymentId: string | null;
@@ -6099,7 +6099,7 @@ export declare const financeService: {
6099
6099
  clientReference: string | null;
6100
6100
  currency: string;
6101
6101
  amountCents: number;
6102
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
6102
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
6103
6103
  payerPersonId: string | null;
6104
6104
  payerOrganizationId: string | null;
6105
6105
  payerEmail: string | null;
@@ -6123,7 +6123,7 @@ export declare const financeService: {
6123
6123
  } | null>;
6124
6124
  expirePaymentSession(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").ExpirePaymentSessionInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
6125
6125
  id: string;
6126
- targetType: "other" | "booking" | "order" | "invoice" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6126
+ targetType: "invoice" | "other" | "booking" | "order" | "booking_payment_schedule" | "booking_guarantee" | "flight_order";
6127
6127
  targetId: string | null;
6128
6128
  bookingId: string | null;
6129
6129
  orderId: string | null;
@@ -6134,7 +6134,7 @@ export declare const financeService: {
6134
6134
  paymentAuthorizationId: string | null;
6135
6135
  paymentCaptureId: string | null;
6136
6136
  paymentId: string | null;
6137
- status: "paid" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled" | "expired";
6137
+ status: "paid" | "expired" | "pending" | "failed" | "requires_redirect" | "processing" | "authorized" | "cancelled";
6138
6138
  provider: string | null;
6139
6139
  providerSessionId: string | null;
6140
6140
  providerPaymentId: string | null;
@@ -6143,7 +6143,7 @@ export declare const financeService: {
6143
6143
  clientReference: string | null;
6144
6144
  currency: string;
6145
6145
  amountCents: number;
6146
- paymentMethod: "bank_transfer" | "credit_card" | "debit_card" | "cash" | "cheque" | "wallet" | "direct_bill" | "travel_credit" | "other" | null;
6146
+ paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque" | null;
6147
6147
  payerPersonId: string | null;
6148
6148
  payerOrganizationId: string | null;
6149
6149
  payerEmail: string | null;
@@ -6172,7 +6172,7 @@ export declare const financeService: {
6172
6172
  organizationId: string | null;
6173
6173
  supplierId: string | null;
6174
6174
  channelId: string | null;
6175
- instrumentType: "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "other" | "bank_account";
6175
+ instrumentType: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_account";
6176
6176
  status: "expired" | "active" | "inactive" | "revoked" | "failed_verification";
6177
6177
  label: string;
6178
6178
  provider: string | null;
@@ -6198,7 +6198,7 @@ export declare const financeService: {
6198
6198
  organizationId: string | null;
6199
6199
  supplierId: string | null;
6200
6200
  channelId: string | null;
6201
- instrumentType: "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "other" | "bank_account";
6201
+ instrumentType: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_account";
6202
6202
  status: "expired" | "active" | "inactive" | "revoked" | "failed_verification";
6203
6203
  label: string;
6204
6204
  provider: string | null;
@@ -6218,17 +6218,19 @@ export declare const financeService: {
6218
6218
  updatedAt: Date;
6219
6219
  } | null>;
6220
6220
  createPaymentInstrument(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreatePaymentInstrumentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
6221
+ provider: string | null;
6221
6222
  id: string;
6222
- brand: string | null;
6223
+ status: "expired" | "active" | "inactive" | "revoked" | "failed_verification";
6224
+ metadata: unknown;
6225
+ label: string;
6226
+ notes: string | null;
6223
6227
  ownerType: "other" | "client" | "supplier" | "channel" | "agency" | "internal";
6224
6228
  personId: string | null;
6225
6229
  organizationId: string | null;
6226
6230
  supplierId: string | null;
6227
6231
  channelId: string | null;
6228
- instrumentType: "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "other" | "bank_account";
6229
- status: "expired" | "active" | "inactive" | "revoked" | "failed_verification";
6230
- label: string;
6231
- provider: string | null;
6232
+ instrumentType: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_account";
6233
+ brand: string | null;
6232
6234
  last4: string | null;
6233
6235
  holderName: string | null;
6234
6236
  expiryMonth: number | null;
@@ -6238,8 +6240,6 @@ export declare const financeService: {
6238
6240
  billingEmail: string | null;
6239
6241
  billingAddress: string | null;
6240
6242
  directBillReference: string | null;
6241
- notes: string | null;
6242
- metadata: unknown;
6243
6243
  createdAt: Date;
6244
6244
  updatedAt: Date;
6245
6245
  } | null>;
@@ -6250,7 +6250,7 @@ export declare const financeService: {
6250
6250
  organizationId: string | null;
6251
6251
  supplierId: string | null;
6252
6252
  channelId: string | null;
6253
- instrumentType: "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "other" | "bank_account";
6253
+ instrumentType: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_account";
6254
6254
  status: "expired" | "active" | "inactive" | "revoked" | "failed_verification";
6255
6255
  label: string;
6256
6256
  provider: string | null;
@@ -6352,22 +6352,22 @@ export declare const financeService: {
6352
6352
  notes?: string | null | undefined;
6353
6353
  }, issuedByUserId?: string): Promise<{
6354
6354
  id: string;
6355
- status: "void" | "expired" | "active" | "redeemed";
6356
- notes: string | null;
6357
- createdAt: Date;
6358
- updatedAt: Date;
6359
6355
  currency: string;
6360
- expiresAt: Date | null;
6356
+ status: "void" | "expired" | "active" | "redeemed";
6361
6357
  code: string;
6362
6358
  seriesCode: string | null;
6363
- initialAmountCents: number;
6364
- remainingAmountCents: number;
6365
6359
  issuedToPersonId: string | null;
6366
6360
  issuedToOrganizationId: string | null;
6367
6361
  sourceType: "manual" | "refund" | "cancellation_credit" | "gift" | "goodwill" | "promotion";
6368
6362
  sourceBookingId: string | null;
6369
6363
  sourcePaymentId: string | null;
6370
6364
  validFrom: Date | null;
6365
+ expiresAt: Date | null;
6366
+ notes: string | null;
6367
+ createdAt: Date;
6368
+ updatedAt: Date;
6369
+ initialAmountCents: number;
6370
+ remainingAmountCents: number;
6371
6371
  issuedByUserId: string | null;
6372
6372
  } | null>;
6373
6373
  update(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, input: {
@@ -6426,11 +6426,11 @@ export declare const financeService: {
6426
6426
  };
6427
6427
  redemption: {
6428
6428
  id: string;
6429
- createdAt: Date;
6430
- bookingId: string;
6429
+ idempotencyKey: string | null;
6431
6430
  amountCents: number;
6431
+ bookingId: string;
6432
6432
  paymentId: string | null;
6433
- idempotencyKey: string | null;
6433
+ createdAt: Date;
6434
6434
  travelCreditId: string;
6435
6435
  createdByUserId: string | null;
6436
6436
  } | null;