@connectedxm/admin 6.9.4 → 6.9.6

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
@@ -448,6 +448,7 @@ __export(index_exports, {
448
448
  DeleteSelfApiKey: () => DeleteSelfApiKey,
449
449
  DeleteSeries: () => DeleteSeries,
450
450
  DeleteSeriesRegistration: () => DeleteSeriesRegistration,
451
+ DeleteSeriesTranslation: () => DeleteSeriesTranslation,
451
452
  DeleteStreamInput: () => DeleteStreamInput,
452
453
  DeleteStreamInputOutput: () => DeleteStreamInputOutput,
453
454
  DeleteSupportTicket: () => DeleteSupportTicket,
@@ -1154,9 +1155,13 @@ __export(index_exports, {
1154
1155
  GetSeries: () => GetSeries,
1155
1156
  GetSeriesEvents: () => GetSeriesEvents,
1156
1157
  GetSeriesList: () => GetSeriesList,
1158
+ GetSeriesPayments: () => GetSeriesPayments,
1157
1159
  GetSeriesRegistration: () => GetSeriesRegistration,
1158
1160
  GetSeriesRegistrationPasses: () => GetSeriesRegistrationPasses,
1161
+ GetSeriesRegistrationPayments: () => GetSeriesRegistrationPayments,
1159
1162
  GetSeriesRegistrations: () => GetSeriesRegistrations,
1163
+ GetSeriesTranslation: () => GetSeriesTranslation,
1164
+ GetSeriesTranslations: () => GetSeriesTranslations,
1160
1165
  GetStreamInput: () => GetStreamInput,
1161
1166
  GetStreamInputOutput: () => GetStreamInputOutput,
1162
1167
  GetStreamInputOutputs: () => GetStreamInputOutputs,
@@ -1444,10 +1449,14 @@ __export(index_exports, {
1444
1449
  SELF_QUERY_KEY: () => SELF_QUERY_KEY,
1445
1450
  SERIES_EVENTS_QUERY_KEY: () => SERIES_EVENTS_QUERY_KEY,
1446
1451
  SERIES_LIST_QUERY_KEY: () => SERIES_LIST_QUERY_KEY,
1452
+ SERIES_PAYMENTS_QUERY_KEY: () => SERIES_PAYMENTS_QUERY_KEY,
1447
1453
  SERIES_QUERY_KEY: () => SERIES_QUERY_KEY,
1448
1454
  SERIES_REGISTRATIONS_QUERY_KEY: () => SERIES_REGISTRATIONS_QUERY_KEY,
1449
1455
  SERIES_REGISTRATION_PASSES_QUERY_KEY: () => SERIES_REGISTRATION_PASSES_QUERY_KEY,
1456
+ SERIES_REGISTRATION_PAYMENTS_QUERY_KEY: () => SERIES_REGISTRATION_PAYMENTS_QUERY_KEY,
1450
1457
  SERIES_REGISTRATION_QUERY_KEY: () => SERIES_REGISTRATION_QUERY_KEY,
1458
+ SERIES_TRANSLATIONS_QUERY_KEY: () => SERIES_TRANSLATIONS_QUERY_KEY,
1459
+ SERIES_TRANSLATION_QUERY_KEY: () => SERIES_TRANSLATION_QUERY_KEY,
1451
1460
  SET_ACCOUNTS_QUERY_DATA: () => SET_ACCOUNTS_QUERY_DATA,
1452
1461
  SET_ACCOUNT_ACTIVITIES_QUERY_DATA: () => SET_ACCOUNT_ACTIVITIES_QUERY_DATA,
1453
1462
  SET_ACCOUNT_ADDRESSES_QUERY_DATA: () => SET_ACCOUNT_ADDRESSES_QUERY_DATA,
@@ -1865,6 +1874,8 @@ __export(index_exports, {
1865
1874
  SET_SERIES_LIST_QUERY_DATA: () => SET_SERIES_LIST_QUERY_DATA,
1866
1875
  SET_SERIES_QUERY_DATA: () => SET_SERIES_QUERY_DATA,
1867
1876
  SET_SERIES_REGISTRATION_QUERY_DATA: () => SET_SERIES_REGISTRATION_QUERY_DATA,
1877
+ SET_SERIES_TRANSLATIONS_QUERY_DATA: () => SET_SERIES_TRANSLATIONS_QUERY_DATA,
1878
+ SET_SERIES_TRANSLATION_QUERY_DATA: () => SET_SERIES_TRANSLATION_QUERY_DATA,
1868
1879
  SET_STREAM_INPUTS_QUERY_DATA: () => SET_STREAM_INPUTS_QUERY_DATA,
1869
1880
  SET_STREAM_INPUT_OUTPUTS_QUERY_DATA: () => SET_STREAM_INPUT_OUTPUTS_QUERY_DATA,
1870
1881
  SET_STREAM_INPUT_OUTPUT_QUERY_DATA: () => SET_STREAM_INPUT_OUTPUT_QUERY_DATA,
@@ -2172,6 +2183,7 @@ __export(index_exports, {
2172
2183
  UpdateSelf: () => UpdateSelf,
2173
2184
  UpdateSeries: () => UpdateSeries,
2174
2185
  UpdateSeriesRegistration: () => UpdateSeriesRegistration,
2186
+ UpdateSeriesTranslation: () => UpdateSeriesTranslation,
2175
2187
  UpdateStream: () => UpdateStream,
2176
2188
  UpdateStreamInputConfig: () => UpdateStreamInputConfig,
2177
2189
  UpdateStreamInputOutput: () => UpdateStreamInputOutput,
@@ -2523,6 +2535,7 @@ __export(index_exports, {
2523
2535
  useDeleteSelfApiKey: () => useDeleteSelfApiKey,
2524
2536
  useDeleteSeries: () => useDeleteSeries,
2525
2537
  useDeleteSeriesRegistration: () => useDeleteSeriesRegistration,
2538
+ useDeleteSeriesTranslation: () => useDeleteSeriesTranslation,
2526
2539
  useDeleteStreamInput: () => useDeleteStreamInput,
2527
2540
  useDeleteStreamInputOutput: () => useDeleteStreamInputOutput,
2528
2541
  useDeleteSupportTicket: () => useDeleteSupportTicket,
@@ -2983,9 +2996,13 @@ __export(index_exports, {
2983
2996
  useGetSeries: () => useGetSeries,
2984
2997
  useGetSeriesEvents: () => useGetSeriesEvents,
2985
2998
  useGetSeriesList: () => useGetSeriesList,
2999
+ useGetSeriesPayments: () => useGetSeriesPayments,
2986
3000
  useGetSeriesRegistration: () => useGetSeriesRegistration,
2987
3001
  useGetSeriesRegistrationPasses: () => useGetSeriesRegistrationPasses,
3002
+ useGetSeriesRegistrationPayments: () => useGetSeriesRegistrationPayments,
2988
3003
  useGetSeriesRegistrations: () => useGetSeriesRegistrations,
3004
+ useGetSeriesTranslation: () => useGetSeriesTranslation,
3005
+ useGetSeriesTranslations: () => useGetSeriesTranslations,
2989
3006
  useGetStreamInput: () => useGetStreamInput,
2990
3007
  useGetStreamInputOutput: () => useGetStreamInputOutput,
2991
3008
  useGetStreamInputOutputs: () => useGetStreamInputOutputs,
@@ -3301,6 +3318,7 @@ __export(index_exports, {
3301
3318
  useUpdateSelf: () => useUpdateSelf,
3302
3319
  useUpdateSeries: () => useUpdateSeries,
3303
3320
  useUpdateSeriesRegistration: () => useUpdateSeriesRegistration,
3321
+ useUpdateSeriesTranslation: () => useUpdateSeriesTranslation,
3304
3322
  useUpdateStreamInput: () => useUpdateStreamInput,
3305
3323
  useUpdateStreamInputConfig: () => useUpdateStreamInputConfig,
3306
3324
  useUpdateStreamInputOutput: () => useUpdateStreamInputOutput,
@@ -3855,6 +3873,7 @@ var PaymentLineItemType = /* @__PURE__ */ ((PaymentLineItemType2) => {
3855
3873
  PaymentLineItemType2["invoice"] = "invoice";
3856
3874
  PaymentLineItemType2["booking"] = "booking";
3857
3875
  PaymentLineItemType2["coupon"] = "coupon";
3876
+ PaymentLineItemType2["series"] = "series";
3858
3877
  PaymentLineItemType2["refund"] = "refund";
3859
3878
  return PaymentLineItemType2;
3860
3879
  })(PaymentLineItemType || {});
@@ -20966,6 +20985,116 @@ var useGetSeriesRegistrationPasses = (seriesId = "", registrationId = "", params
20966
20985
  );
20967
20986
  };
20968
20987
 
20988
+ // src/queries/series/registrations/useGetSeriesRegistrationPayments.ts
20989
+ var SERIES_REGISTRATION_PAYMENTS_QUERY_KEY = (seriesId, registrationId) => [...SERIES_REGISTRATION_QUERY_KEY(seriesId, registrationId), "PAYMENTS"];
20990
+ var GetSeriesRegistrationPayments = async ({
20991
+ seriesId,
20992
+ registrationId,
20993
+ pageParam,
20994
+ pageSize,
20995
+ orderBy,
20996
+ search,
20997
+ adminApiParams
20998
+ }) => {
20999
+ const adminApi = await GetAdminAPI(adminApiParams);
21000
+ const { data } = await adminApi.get(
21001
+ `/series/${seriesId}/registrations/${registrationId}/payments`,
21002
+ {
21003
+ params: {
21004
+ page: pageParam || void 0,
21005
+ pageSize: pageSize || void 0,
21006
+ orderBy: orderBy || void 0,
21007
+ search: search || void 0
21008
+ }
21009
+ }
21010
+ );
21011
+ return data;
21012
+ };
21013
+ var useGetSeriesRegistrationPayments = (seriesId = "", registrationId = "", params = {}, options = {}) => {
21014
+ return useConnectedInfiniteQuery(
21015
+ SERIES_REGISTRATION_PAYMENTS_QUERY_KEY(seriesId, registrationId),
21016
+ (params2) => GetSeriesRegistrationPayments({ seriesId, registrationId, ...params2 }),
21017
+ params,
21018
+ {
21019
+ ...options,
21020
+ enabled: !!seriesId && !!registrationId && (options?.enabled ?? true)
21021
+ }
21022
+ );
21023
+ };
21024
+
21025
+ // src/queries/series/translations/useGetSeriesTranslations.ts
21026
+ var SERIES_TRANSLATIONS_QUERY_KEY = (seriesId) => [
21027
+ ...SERIES_QUERY_KEY(seriesId),
21028
+ "TRANSLATIONS"
21029
+ ];
21030
+ var SET_SERIES_TRANSLATIONS_QUERY_DATA = (client, keyParams, response) => {
21031
+ client.setQueryData(SERIES_TRANSLATIONS_QUERY_KEY(...keyParams), response);
21032
+ };
21033
+ var GetSeriesTranslations = async ({
21034
+ pageParam,
21035
+ pageSize,
21036
+ orderBy,
21037
+ search,
21038
+ seriesId,
21039
+ adminApiParams
21040
+ }) => {
21041
+ const adminApi = await GetAdminAPI(adminApiParams);
21042
+ const { data } = await adminApi.get(`/series/${seriesId}/translations`, {
21043
+ params: {
21044
+ page: pageParam || void 0,
21045
+ pageSize: pageSize || void 0,
21046
+ orderBy: orderBy || void 0,
21047
+ search: search || void 0
21048
+ }
21049
+ });
21050
+ return data;
21051
+ };
21052
+ var useGetSeriesTranslations = (seriesId = "", params = {}, options = {}) => {
21053
+ return useConnectedInfiniteQuery(
21054
+ SERIES_TRANSLATIONS_QUERY_KEY(seriesId),
21055
+ (params2) => GetSeriesTranslations({
21056
+ ...params2,
21057
+ seriesId
21058
+ }),
21059
+ params,
21060
+ {
21061
+ ...options,
21062
+ enabled: !!seriesId && (options.enabled ?? true)
21063
+ }
21064
+ );
21065
+ };
21066
+
21067
+ // src/queries/series/translations/useGetSeriesTranslation.ts
21068
+ var SERIES_TRANSLATION_QUERY_KEY = (seriesId, locale) => [...SERIES_TRANSLATIONS_QUERY_KEY(seriesId), locale];
21069
+ var SET_SERIES_TRANSLATION_QUERY_DATA = (client, keyParams, response) => {
21070
+ client.setQueryData(SERIES_TRANSLATION_QUERY_KEY(...keyParams), response);
21071
+ };
21072
+ var GetSeriesTranslation = async ({
21073
+ seriesId,
21074
+ locale,
21075
+ adminApiParams
21076
+ }) => {
21077
+ const adminApi = await GetAdminAPI(adminApiParams);
21078
+ const { data } = await adminApi.get(
21079
+ `/series/${seriesId}/translations/${locale}`
21080
+ );
21081
+ return data;
21082
+ };
21083
+ var useGetSeriesTranslation = (seriesId = "", locale = "", options = {}) => {
21084
+ return useConnectedSingleQuery(
21085
+ SERIES_TRANSLATION_QUERY_KEY(seriesId, locale),
21086
+ (params) => GetSeriesTranslation({
21087
+ seriesId,
21088
+ locale,
21089
+ ...params
21090
+ }),
21091
+ {
21092
+ ...options,
21093
+ enabled: !!seriesId && !!locale && locale !== "en" && (options?.enabled ?? true)
21094
+ }
21095
+ );
21096
+ };
21097
+
20969
21098
  // src/queries/series/useGetSeriesEvents.ts
20970
21099
  var SERIES_EVENTS_QUERY_KEY = (seriesId) => [
20971
21100
  ...EVENT_QUERY_KEY(seriesId),
@@ -21008,6 +21137,45 @@ var useGetSeriesEvents = (seriesId = "", params = {}, options = {}) => {
21008
21137
  );
21009
21138
  };
21010
21139
 
21140
+ // src/queries/series/useGetSeriesPayments.ts
21141
+ var SERIES_PAYMENTS_QUERY_KEY = (seriesId) => [
21142
+ ...SERIES_QUERY_KEY(seriesId),
21143
+ "PAYMENTS"
21144
+ ];
21145
+ var GetSeriesPayments = async ({
21146
+ seriesId,
21147
+ pageParam,
21148
+ pageSize,
21149
+ orderBy,
21150
+ search,
21151
+ adminApiParams
21152
+ }) => {
21153
+ const adminApi = await GetAdminAPI(adminApiParams);
21154
+ const { data } = await adminApi.get(`/series/${seriesId}/payments`, {
21155
+ params: {
21156
+ page: pageParam || void 0,
21157
+ pageSize: pageSize || void 0,
21158
+ orderBy: orderBy || void 0,
21159
+ search: search || void 0
21160
+ }
21161
+ });
21162
+ return data;
21163
+ };
21164
+ var useGetSeriesPayments = (seriesId = "", params = {}, options = {}) => {
21165
+ return useConnectedInfiniteQuery(
21166
+ SERIES_PAYMENTS_QUERY_KEY(seriesId),
21167
+ (params2) => GetSeriesPayments({
21168
+ seriesId,
21169
+ ...params2
21170
+ }),
21171
+ params,
21172
+ {
21173
+ ...options,
21174
+ enabled: !!seriesId && (options.enabled ?? true)
21175
+ }
21176
+ );
21177
+ };
21178
+
21011
21179
  // src/queries/sponsors/useGetLevels.ts
21012
21180
  var LEVELS_QUERY_KEY = () => ["LEVELS"];
21013
21181
  var SET_LEVELS_QUERY_DATA = (client, keyParams, response) => {
@@ -37445,6 +37613,60 @@ var useUpdateSeriesRegistration = (options = {}) => {
37445
37613
  return useConnectedMutation(UpdateSeriesRegistration, options);
37446
37614
  };
37447
37615
 
37616
+ // src/mutations/series/translations/useDeleteSeriesTranslation.ts
37617
+ var DeleteSeriesTranslation = async ({
37618
+ seriesId,
37619
+ locale,
37620
+ adminApiParams,
37621
+ queryClient
37622
+ }) => {
37623
+ const connectedXM = await GetAdminAPI(adminApiParams);
37624
+ const { data } = await connectedXM.delete(
37625
+ `/series/${seriesId}/translations/${locale}`
37626
+ );
37627
+ if (queryClient && data.status === "ok") {
37628
+ queryClient.invalidateQueries({
37629
+ queryKey: SERIES_TRANSLATIONS_QUERY_KEY(seriesId)
37630
+ });
37631
+ queryClient.invalidateQueries({
37632
+ queryKey: SERIES_TRANSLATION_QUERY_KEY(seriesId, locale)
37633
+ });
37634
+ }
37635
+ return data;
37636
+ };
37637
+ var useDeleteSeriesTranslation = (options = {}) => {
37638
+ return useConnectedMutation(DeleteSeriesTranslation, options);
37639
+ };
37640
+
37641
+ // src/mutations/series/translations/useUpdateSeriesTranslation.ts
37642
+ var UpdateSeriesTranslation = async ({
37643
+ seriesId,
37644
+ seriesTranslation,
37645
+ adminApiParams,
37646
+ locale,
37647
+ queryClient
37648
+ }) => {
37649
+ const connectedXM = await GetAdminAPI(adminApiParams);
37650
+ const { data } = await connectedXM.put(
37651
+ `/series/${seriesId}/translations/${locale}`,
37652
+ seriesTranslation
37653
+ );
37654
+ if (queryClient && data.status === "ok") {
37655
+ queryClient.invalidateQueries({
37656
+ queryKey: SERIES_TRANSLATIONS_QUERY_KEY(seriesId)
37657
+ });
37658
+ SET_SERIES_TRANSLATION_QUERY_DATA(
37659
+ queryClient,
37660
+ [seriesId, locale],
37661
+ data
37662
+ );
37663
+ }
37664
+ return data;
37665
+ };
37666
+ var useUpdateSeriesTranslation = (options = {}) => {
37667
+ return useConnectedMutation(UpdateSeriesTranslation, options);
37668
+ };
37669
+
37448
37670
  // src/mutations/series/useAddSeriesEvent.ts
37449
37671
  var AddSeriesEvent = async ({
37450
37672
  seriesId,
@@ -40472,6 +40694,7 @@ var useUpdateTier = (options = {}) => {
40472
40694
  DeleteSelfApiKey,
40473
40695
  DeleteSeries,
40474
40696
  DeleteSeriesRegistration,
40697
+ DeleteSeriesTranslation,
40475
40698
  DeleteStreamInput,
40476
40699
  DeleteStreamInputOutput,
40477
40700
  DeleteSupportTicket,
@@ -41178,9 +41401,13 @@ var useUpdateTier = (options = {}) => {
41178
41401
  GetSeries,
41179
41402
  GetSeriesEvents,
41180
41403
  GetSeriesList,
41404
+ GetSeriesPayments,
41181
41405
  GetSeriesRegistration,
41182
41406
  GetSeriesRegistrationPasses,
41407
+ GetSeriesRegistrationPayments,
41183
41408
  GetSeriesRegistrations,
41409
+ GetSeriesTranslation,
41410
+ GetSeriesTranslations,
41184
41411
  GetStreamInput,
41185
41412
  GetStreamInputOutput,
41186
41413
  GetStreamInputOutputs,
@@ -41468,10 +41695,14 @@ var useUpdateTier = (options = {}) => {
41468
41695
  SELF_QUERY_KEY,
41469
41696
  SERIES_EVENTS_QUERY_KEY,
41470
41697
  SERIES_LIST_QUERY_KEY,
41698
+ SERIES_PAYMENTS_QUERY_KEY,
41471
41699
  SERIES_QUERY_KEY,
41472
41700
  SERIES_REGISTRATIONS_QUERY_KEY,
41473
41701
  SERIES_REGISTRATION_PASSES_QUERY_KEY,
41702
+ SERIES_REGISTRATION_PAYMENTS_QUERY_KEY,
41474
41703
  SERIES_REGISTRATION_QUERY_KEY,
41704
+ SERIES_TRANSLATIONS_QUERY_KEY,
41705
+ SERIES_TRANSLATION_QUERY_KEY,
41475
41706
  SET_ACCOUNTS_QUERY_DATA,
41476
41707
  SET_ACCOUNT_ACTIVITIES_QUERY_DATA,
41477
41708
  SET_ACCOUNT_ADDRESSES_QUERY_DATA,
@@ -41889,6 +42120,8 @@ var useUpdateTier = (options = {}) => {
41889
42120
  SET_SERIES_LIST_QUERY_DATA,
41890
42121
  SET_SERIES_QUERY_DATA,
41891
42122
  SET_SERIES_REGISTRATION_QUERY_DATA,
42123
+ SET_SERIES_TRANSLATIONS_QUERY_DATA,
42124
+ SET_SERIES_TRANSLATION_QUERY_DATA,
41892
42125
  SET_STREAM_INPUTS_QUERY_DATA,
41893
42126
  SET_STREAM_INPUT_OUTPUTS_QUERY_DATA,
41894
42127
  SET_STREAM_INPUT_OUTPUT_QUERY_DATA,
@@ -42196,6 +42429,7 @@ var useUpdateTier = (options = {}) => {
42196
42429
  UpdateSelf,
42197
42430
  UpdateSeries,
42198
42431
  UpdateSeriesRegistration,
42432
+ UpdateSeriesTranslation,
42199
42433
  UpdateStream,
42200
42434
  UpdateStreamInputConfig,
42201
42435
  UpdateStreamInputOutput,
@@ -42547,6 +42781,7 @@ var useUpdateTier = (options = {}) => {
42547
42781
  useDeleteSelfApiKey,
42548
42782
  useDeleteSeries,
42549
42783
  useDeleteSeriesRegistration,
42784
+ useDeleteSeriesTranslation,
42550
42785
  useDeleteStreamInput,
42551
42786
  useDeleteStreamInputOutput,
42552
42787
  useDeleteSupportTicket,
@@ -43007,9 +43242,13 @@ var useUpdateTier = (options = {}) => {
43007
43242
  useGetSeries,
43008
43243
  useGetSeriesEvents,
43009
43244
  useGetSeriesList,
43245
+ useGetSeriesPayments,
43010
43246
  useGetSeriesRegistration,
43011
43247
  useGetSeriesRegistrationPasses,
43248
+ useGetSeriesRegistrationPayments,
43012
43249
  useGetSeriesRegistrations,
43250
+ useGetSeriesTranslation,
43251
+ useGetSeriesTranslations,
43013
43252
  useGetStreamInput,
43014
43253
  useGetStreamInputOutput,
43015
43254
  useGetStreamInputOutputs,
@@ -43325,6 +43564,7 @@ var useUpdateTier = (options = {}) => {
43325
43564
  useUpdateSelf,
43326
43565
  useUpdateSeries,
43327
43566
  useUpdateSeriesRegistration,
43567
+ useUpdateSeriesTranslation,
43328
43568
  useUpdateStreamInput,
43329
43569
  useUpdateStreamInputConfig,
43330
43570
  useUpdateStreamInputOutput,