@connectedxm/admin 2.11.2 → 3.0.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.
package/dist/index.cjs CHANGED
@@ -143,7 +143,6 @@ __export(index_exports, {
143
143
  BENEFIT_QUERY_KEY: () => BENEFIT_QUERY_KEY,
144
144
  BENEFIT_TRANSLATIONS_QUERY_KEY: () => BENEFIT_TRANSLATIONS_QUERY_KEY,
145
145
  BENEFIT_TRANSLATION_QUERY_KEY: () => BENEFIT_TRANSLATION_QUERY_KEY,
146
- BOOKING_PAYMENTS_QUERY_KEY: () => BOOKING_PAYMENTS_QUERY_KEY,
147
146
  BOOKING_PLACES_QUERY_KEY: () => BOOKING_PLACES_QUERY_KEY,
148
147
  BOOKING_PLACE_BOOKINGS_QUERY_KEY: () => BOOKING_PLACE_BOOKINGS_QUERY_KEY,
149
148
  BOOKING_PLACE_QUERY_KEY: () => BOOKING_PLACE_QUERY_KEY,
@@ -678,6 +677,7 @@ __export(index_exports, {
678
677
  EVENT_ZPL_TEMPLATE_BADGE_FIELD_QUERY_KEY: () => EVENT_ZPL_TEMPLATE_BADGE_FIELD_QUERY_KEY,
679
678
  EmailReceiptStatus: () => EmailReceiptStatus,
680
679
  EventActivationType: () => EventActivationType,
680
+ EventAgendaVisibility: () => EventAgendaVisibility,
681
681
  EventEmailType: () => EventEmailType,
682
682
  EventGetPassTypeCoupons: () => EventGetPassTypeCoupons,
683
683
  EventReportDateType: () => EventReportDateType,
@@ -764,7 +764,6 @@ __export(index_exports, {
764
764
  GetBenefitTranslations: () => GetBenefitTranslations,
765
765
  GetBenefits: () => GetBenefits,
766
766
  GetBooking: () => GetBooking,
767
- GetBookingPayments: () => GetBookingPayments,
768
767
  GetBookingPlace: () => GetBookingPlace,
769
768
  GetBookingPlaceBookings: () => GetBookingPlaceBookings,
770
769
  GetBookingPlaceTranslation: () => GetBookingPlaceTranslation,
@@ -1038,8 +1037,6 @@ __export(index_exports, {
1038
1037
  GetInvoice: () => GetInvoice,
1039
1038
  GetInvoiceLineItem: () => GetInvoiceLineItem,
1040
1039
  GetInvoiceLineItems: () => GetInvoiceLineItems,
1041
- GetInvoicePayment: () => GetInvoicePayment,
1042
- GetInvoicePayments: () => GetInvoicePayments,
1043
1040
  GetInvoices: () => GetInvoices,
1044
1041
  GetLevel: () => GetLevel,
1045
1042
  GetLevelAccounts: () => GetLevelAccounts,
@@ -1176,8 +1173,6 @@ __export(index_exports, {
1176
1173
  INVOICES_QUERY_KEY: () => INVOICES_QUERY_KEY,
1177
1174
  INVOICE_LINE_ITEMS_QUERY_KEY: () => INVOICE_LINE_ITEMS_QUERY_KEY,
1178
1175
  INVOICE_LINE_ITEM_QUERY_KEY: () => INVOICE_LINE_ITEM_QUERY_KEY,
1179
- INVOICE_PAYMENTS_QUERY_KEY: () => INVOICE_PAYMENTS_QUERY_KEY,
1180
- INVOICE_PAYMENT_QUERY_KEY: () => INVOICE_PAYMENT_QUERY_KEY,
1181
1176
  INVOICE_QUERY_KEY: () => INVOICE_QUERY_KEY,
1182
1177
  ImageType: () => ImageType,
1183
1178
  ImpersonateAccount: () => ImpersonateAccount,
@@ -1237,6 +1232,7 @@ __export(index_exports, {
1237
1232
  PassTypeAccessLevel: () => PassTypeAccessLevel,
1238
1233
  PassTypeVisibility: () => PassTypeVisibility,
1239
1234
  PaymentIntegrationType: () => PaymentIntegrationType,
1235
+ PaymentLineItemType: () => PaymentLineItemType,
1240
1236
  PaymentType: () => PaymentType,
1241
1237
  PurchaseStatus: () => PurchaseStatus,
1242
1238
  PushDeviceAppType: () => PushDeviceAppType,
@@ -1373,7 +1369,6 @@ __export(index_exports, {
1373
1369
  SET_BENEFIT_QUERY_DATA: () => SET_BENEFIT_QUERY_DATA,
1374
1370
  SET_BENEFIT_TRANSLATIONS_QUERY_DATA: () => SET_BENEFIT_TRANSLATIONS_QUERY_DATA,
1375
1371
  SET_BENEFIT_TRANSLATION_QUERY_DATA: () => SET_BENEFIT_TRANSLATION_QUERY_DATA,
1376
- SET_BOOKING_PAYMENTS_QUERY_DATA: () => SET_BOOKING_PAYMENTS_QUERY_DATA,
1377
1372
  SET_BOOKING_PLACES_QUERY_DATA: () => SET_BOOKING_PLACES_QUERY_DATA,
1378
1373
  SET_BOOKING_PLACE_BOOKINGS_QUERY_DATA: () => SET_BOOKING_PLACE_BOOKINGS_QUERY_DATA,
1379
1374
  SET_BOOKING_PLACE_QUERY_DATA: () => SET_BOOKING_PLACE_QUERY_DATA,
@@ -1641,8 +1636,6 @@ __export(index_exports, {
1641
1636
  SET_INVOICES_QUERY_DATA: () => SET_INVOICES_QUERY_DATA,
1642
1637
  SET_INVOICE_LINE_ITEMS_QUERY_DATA: () => SET_INVOICE_LINE_ITEMS_QUERY_DATA,
1643
1638
  SET_INVOICE_LINE_ITEM_QUERY_DATA: () => SET_INVOICE_LINE_ITEM_QUERY_DATA,
1644
- SET_INVOICE_PAYMENTS_QUERY_DATA: () => SET_INVOICE_PAYMENTS_QUERY_DATA,
1645
- SET_INVOICE_PAYMENT_QUERY_DATA: () => SET_INVOICE_PAYMENT_QUERY_DATA,
1646
1639
  SET_INVOICE_QUERY_DATA: () => SET_INVOICE_QUERY_DATA,
1647
1640
  SET_LEVELS_QUERY_DATA: () => SET_LEVELS_QUERY_DATA,
1648
1641
  SET_LEVEL_ACCOUNTS_QUERY_DATA: () => SET_LEVEL_ACCOUNTS_QUERY_DATA,
@@ -2414,7 +2407,6 @@ __export(index_exports, {
2414
2407
  useGetBenefitTranslations: () => useGetBenefitTranslations,
2415
2408
  useGetBenefits: () => useGetBenefits,
2416
2409
  useGetBooking: () => useGetBooking,
2417
- useGetBookingPayments: () => useGetBookingPayments,
2418
2410
  useGetBookingPlace: () => useGetBookingPlace,
2419
2411
  useGetBookingPlaceBookings: () => useGetBookingPlaceBookings,
2420
2412
  useGetBookingPlaceTranslation: () => useGetBookingPlaceTranslation,
@@ -2686,8 +2678,6 @@ __export(index_exports, {
2686
2678
  useGetInvoice: () => useGetInvoice,
2687
2679
  useGetInvoiceLineItem: () => useGetInvoiceLineItem,
2688
2680
  useGetInvoiceLineItems: () => useGetInvoiceLineItems,
2689
- useGetInvoicePayment: () => useGetInvoicePayment,
2690
- useGetInvoicePayments: () => useGetInvoicePayments,
2691
2681
  useGetInvoices: () => useGetInvoices,
2692
2682
  useGetLevel: () => useGetLevel,
2693
2683
  useGetLevelAccounts: () => useGetLevelAccounts,
@@ -5283,49 +5273,6 @@ var useGetBooking = (bookingId = "", options = {}) => {
5283
5273
  );
5284
5274
  };
5285
5275
 
5286
- // src/queries/bookings/useGetBookingPayments.ts
5287
- var BOOKING_PAYMENTS_QUERY_KEY = (bookingId) => [
5288
- ...BOOKING_QUERY_KEY(bookingId),
5289
- "PAYMENTS"
5290
- ];
5291
- var SET_BOOKING_PAYMENTS_QUERY_DATA = (client, keyParams, response) => {
5292
- client.setQueryData(BOOKING_PAYMENTS_QUERY_KEY(...keyParams), response);
5293
- };
5294
- var GetBookingPayments = async ({
5295
- bookingId,
5296
- pageParam,
5297
- pageSize,
5298
- orderBy,
5299
- search,
5300
- adminApiParams
5301
- }) => {
5302
- const adminApi = await GetAdminAPI(adminApiParams);
5303
- const { data } = await adminApi.get(`/bookings/${bookingId}/payments`, {
5304
- params: {
5305
- page: pageParam || void 0,
5306
- pageSize: pageSize || void 0,
5307
- orderBy: orderBy || void 0,
5308
- search: search || void 0
5309
- }
5310
- });
5311
- return data;
5312
- };
5313
- var useGetBookingPayments = (bookingId = "", params = {}, options = {}) => {
5314
- return useConnectedInfiniteQuery(
5315
- BOOKING_PAYMENTS_QUERY_KEY(bookingId),
5316
- (params2) => GetBookingPayments({
5317
- ...params2,
5318
- bookingId
5319
- }),
5320
- params,
5321
- {
5322
- ...options,
5323
- enabled: !!bookingId && (options.enabled ?? true)
5324
- },
5325
- "bookings"
5326
- );
5327
- };
5328
-
5329
5276
  // src/queries/bookings/useGetBookingPlaces.ts
5330
5277
  var BOOKING_PLACES_QUERY_KEY = () => ["BOOKING_PLACES"];
5331
5278
  var SET_BOOKING_PLACES_QUERY_DATA = (client, keyParams, response) => {
@@ -15636,6 +15583,12 @@ var PassTypeAccessLevel = /* @__PURE__ */ ((PassTypeAccessLevel2) => {
15636
15583
  PassTypeAccessLevel2["vip"] = "vip";
15637
15584
  return PassTypeAccessLevel2;
15638
15585
  })(PassTypeAccessLevel || {});
15586
+ var EventAgendaVisibility = /* @__PURE__ */ ((EventAgendaVisibility2) => {
15587
+ EventAgendaVisibility2["everyone"] = "everyone";
15588
+ EventAgendaVisibility2["registered"] = "registered";
15589
+ EventAgendaVisibility2["hidden"] = "hidden";
15590
+ return EventAgendaVisibility2;
15591
+ })(EventAgendaVisibility || {});
15639
15592
  var GroupAccess = /* @__PURE__ */ ((GroupAccess2) => {
15640
15593
  GroupAccess2["public"] = "public";
15641
15594
  GroupAccess2["private"] = "private";
@@ -15914,6 +15867,18 @@ var PaymentIntegrationType = /* @__PURE__ */ ((PaymentIntegrationType2) => {
15914
15867
  PaymentIntegrationType2["manual"] = "manual";
15915
15868
  return PaymentIntegrationType2;
15916
15869
  })(PaymentIntegrationType || {});
15870
+ var PaymentLineItemType = /* @__PURE__ */ ((PaymentLineItemType2) => {
15871
+ PaymentLineItemType2["pass"] = "pass";
15872
+ PaymentLineItemType2["package"] = "package";
15873
+ PaymentLineItemType2["reservation"] = "reservation";
15874
+ PaymentLineItemType2["addOn"] = "addOn";
15875
+ PaymentLineItemType2["access"] = "access";
15876
+ PaymentLineItemType2["invoice"] = "invoice";
15877
+ PaymentLineItemType2["booking"] = "booking";
15878
+ PaymentLineItemType2["coupon"] = "coupon";
15879
+ PaymentLineItemType2["subscription"] = "subscription";
15880
+ return PaymentLineItemType2;
15881
+ })(PaymentLineItemType || {});
15917
15882
  var TaxIntegrationType = /* @__PURE__ */ ((TaxIntegrationType2) => {
15918
15883
  TaxIntegrationType2["stripe"] = "stripe";
15919
15884
  TaxIntegrationType2["taxjar"] = "taxjar";
@@ -17069,77 +17034,6 @@ var useGetInvoiceLineItem = (invoiceId = "", lineItemId = "", options = {}) => {
17069
17034
  );
17070
17035
  };
17071
17036
 
17072
- // src/queries/invoices/useGetInvoicePayments.ts
17073
- var INVOICE_PAYMENTS_QUERY_KEY = (invoiceId) => [
17074
- ...INVOICE_QUERY_KEY(invoiceId),
17075
- "PAYMENTS"
17076
- ];
17077
- var SET_INVOICE_PAYMENTS_QUERY_DATA = (client, keyParams, response) => {
17078
- client.setQueryData(INVOICE_PAYMENTS_QUERY_KEY(...keyParams), response);
17079
- };
17080
- var GetInvoicePayments = async ({
17081
- invoiceId,
17082
- pageParam,
17083
- pageSize,
17084
- orderBy,
17085
- search,
17086
- adminApiParams
17087
- }) => {
17088
- const adminApi = await GetAdminAPI(adminApiParams);
17089
- const { data } = await adminApi.get(`/invoices/${invoiceId}/payments`, {
17090
- params: {
17091
- page: pageParam || void 0,
17092
- pageSize: pageSize || void 0,
17093
- orderBy: orderBy || void 0,
17094
- search: search || void 0
17095
- }
17096
- });
17097
- return data;
17098
- };
17099
- var useGetInvoicePayments = (invoiceId = "", params = {}, options = {}) => {
17100
- return useConnectedInfiniteQuery(
17101
- INVOICE_PAYMENTS_QUERY_KEY(invoiceId),
17102
- (params2) => GetInvoicePayments({
17103
- ...params2,
17104
- invoiceId
17105
- }),
17106
- params,
17107
- {
17108
- ...options,
17109
- enabled: !!invoiceId && (options.enabled ?? true)
17110
- },
17111
- "invoices"
17112
- );
17113
- };
17114
-
17115
- // src/queries/invoices/useGetInvoicePayment.ts
17116
- var INVOICE_PAYMENT_QUERY_KEY = (invoiceId, paymentId) => [...INVOICE_PAYMENTS_QUERY_KEY(invoiceId), paymentId];
17117
- var SET_INVOICE_PAYMENT_QUERY_DATA = (client, keyParams, response) => {
17118
- client.setQueryData(INVOICE_PAYMENT_QUERY_KEY(...keyParams), response);
17119
- };
17120
- var GetInvoicePayment = async ({
17121
- invoiceId,
17122
- paymentId,
17123
- adminApiParams
17124
- }) => {
17125
- const adminApi = await GetAdminAPI(adminApiParams);
17126
- const { data } = await adminApi.get(
17127
- `/invoices/${invoiceId}/payments/${paymentId}`
17128
- );
17129
- return data;
17130
- };
17131
- var useGetInvoicePayment = (invoiceId = "", paymentId = "", options = {}) => {
17132
- return useConnectedSingleQuery(
17133
- INVOICE_PAYMENT_QUERY_KEY(invoiceId, paymentId),
17134
- (params) => GetInvoicePayment({ invoiceId, paymentId, ...params }),
17135
- {
17136
- ...options,
17137
- enabled: !!invoiceId && !!paymentId
17138
- },
17139
- "invoices"
17140
- );
17141
- };
17142
-
17143
17037
  // src/queries/levels/useGetLevels.ts
17144
17038
  var LEVELS_QUERY_KEY = () => ["LEVELS"];
17145
17039
  var SET_LEVELS_QUERY_DATA = (client, keyParams, response) => {
@@ -36015,16 +35909,14 @@ var useDeleteOrganizationWebhook = (options = {}) => {
36015
35909
  var RefundOrganizationPayment = async ({
36016
35910
  paymentId,
36017
35911
  eventId,
36018
- amount,
35912
+ lineItems,
36019
35913
  adminApiParams,
36020
35914
  queryClient
36021
35915
  }) => {
36022
35916
  const connectedXM = await GetAdminAPI(adminApiParams);
36023
35917
  const { data } = await connectedXM.post(
36024
35918
  `/payments/${paymentId}/refund`,
36025
- {
36026
- amount
36027
- }
35919
+ lineItems
36028
35920
  );
36029
35921
  if (queryClient && data.status === "ok") {
36030
35922
  queryClient.invalidateQueries({
@@ -36033,19 +35925,14 @@ var RefundOrganizationPayment = async ({
36033
35925
  queryClient.invalidateQueries({
36034
35926
  queryKey: PAYMENTS_QUERY_KEY()
36035
35927
  });
36036
- if (eventId && data.data?.registrationId) {
35928
+ if (eventId && data.data?.registration?.id) {
36037
35929
  queryClient.invalidateQueries({
36038
35930
  queryKey: EVENT_ATTENDEE_PAYMENTS_QUERY_KEY(
36039
35931
  eventId,
36040
- data.data.registrationId
35932
+ data.data.registration.id
36041
35933
  )
36042
35934
  });
36043
35935
  }
36044
- if (data.data?.bookingId) {
36045
- queryClient.invalidateQueries({
36046
- queryKey: BOOKING_PAYMENTS_QUERY_KEY(data.data.bookingId)
36047
- });
36048
- }
36049
35936
  }
36050
35937
  return data;
36051
35938
  };
@@ -39281,7 +39168,6 @@ var useUploadVideoCaptions = (options = {}) => {
39281
39168
  BENEFIT_QUERY_KEY,
39282
39169
  BENEFIT_TRANSLATIONS_QUERY_KEY,
39283
39170
  BENEFIT_TRANSLATION_QUERY_KEY,
39284
- BOOKING_PAYMENTS_QUERY_KEY,
39285
39171
  BOOKING_PLACES_QUERY_KEY,
39286
39172
  BOOKING_PLACE_BOOKINGS_QUERY_KEY,
39287
39173
  BOOKING_PLACE_QUERY_KEY,
@@ -39816,6 +39702,7 @@ var useUploadVideoCaptions = (options = {}) => {
39816
39702
  EVENT_ZPL_TEMPLATE_BADGE_FIELD_QUERY_KEY,
39817
39703
  EmailReceiptStatus,
39818
39704
  EventActivationType,
39705
+ EventAgendaVisibility,
39819
39706
  EventEmailType,
39820
39707
  EventGetPassTypeCoupons,
39821
39708
  EventReportDateType,
@@ -39902,7 +39789,6 @@ var useUploadVideoCaptions = (options = {}) => {
39902
39789
  GetBenefitTranslations,
39903
39790
  GetBenefits,
39904
39791
  GetBooking,
39905
- GetBookingPayments,
39906
39792
  GetBookingPlace,
39907
39793
  GetBookingPlaceBookings,
39908
39794
  GetBookingPlaceTranslation,
@@ -40176,8 +40062,6 @@ var useUploadVideoCaptions = (options = {}) => {
40176
40062
  GetInvoice,
40177
40063
  GetInvoiceLineItem,
40178
40064
  GetInvoiceLineItems,
40179
- GetInvoicePayment,
40180
- GetInvoicePayments,
40181
40065
  GetInvoices,
40182
40066
  GetLevel,
40183
40067
  GetLevelAccounts,
@@ -40314,8 +40198,6 @@ var useUploadVideoCaptions = (options = {}) => {
40314
40198
  INVOICES_QUERY_KEY,
40315
40199
  INVOICE_LINE_ITEMS_QUERY_KEY,
40316
40200
  INVOICE_LINE_ITEM_QUERY_KEY,
40317
- INVOICE_PAYMENTS_QUERY_KEY,
40318
- INVOICE_PAYMENT_QUERY_KEY,
40319
40201
  INVOICE_QUERY_KEY,
40320
40202
  ImageType,
40321
40203
  ImpersonateAccount,
@@ -40375,6 +40257,7 @@ var useUploadVideoCaptions = (options = {}) => {
40375
40257
  PassTypeAccessLevel,
40376
40258
  PassTypeVisibility,
40377
40259
  PaymentIntegrationType,
40260
+ PaymentLineItemType,
40378
40261
  PaymentType,
40379
40262
  PurchaseStatus,
40380
40263
  PushDeviceAppType,
@@ -40511,7 +40394,6 @@ var useUploadVideoCaptions = (options = {}) => {
40511
40394
  SET_BENEFIT_QUERY_DATA,
40512
40395
  SET_BENEFIT_TRANSLATIONS_QUERY_DATA,
40513
40396
  SET_BENEFIT_TRANSLATION_QUERY_DATA,
40514
- SET_BOOKING_PAYMENTS_QUERY_DATA,
40515
40397
  SET_BOOKING_PLACES_QUERY_DATA,
40516
40398
  SET_BOOKING_PLACE_BOOKINGS_QUERY_DATA,
40517
40399
  SET_BOOKING_PLACE_QUERY_DATA,
@@ -40779,8 +40661,6 @@ var useUploadVideoCaptions = (options = {}) => {
40779
40661
  SET_INVOICES_QUERY_DATA,
40780
40662
  SET_INVOICE_LINE_ITEMS_QUERY_DATA,
40781
40663
  SET_INVOICE_LINE_ITEM_QUERY_DATA,
40782
- SET_INVOICE_PAYMENTS_QUERY_DATA,
40783
- SET_INVOICE_PAYMENT_QUERY_DATA,
40784
40664
  SET_INVOICE_QUERY_DATA,
40785
40665
  SET_LEVELS_QUERY_DATA,
40786
40666
  SET_LEVEL_ACCOUNTS_QUERY_DATA,
@@ -41552,7 +41432,6 @@ var useUploadVideoCaptions = (options = {}) => {
41552
41432
  useGetBenefitTranslations,
41553
41433
  useGetBenefits,
41554
41434
  useGetBooking,
41555
- useGetBookingPayments,
41556
41435
  useGetBookingPlace,
41557
41436
  useGetBookingPlaceBookings,
41558
41437
  useGetBookingPlaceTranslation,
@@ -41824,8 +41703,6 @@ var useUploadVideoCaptions = (options = {}) => {
41824
41703
  useGetInvoice,
41825
41704
  useGetInvoiceLineItem,
41826
41705
  useGetInvoiceLineItems,
41827
- useGetInvoicePayment,
41828
- useGetInvoicePayments,
41829
41706
  useGetInvoices,
41830
41707
  useGetLevel,
41831
41708
  useGetLevelAccounts,