@zeniai/client-epic-state 5.0.65-betaML2 → 5.0.65-betaRR2

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 (121) hide show
  1. package/lib/common/aiCfo/aiCfoSuggestedQuestionsPageContext.d.ts +1 -1
  2. package/lib/entity/aiCfo/aiCfoPayload.d.ts +168 -1
  3. package/lib/entity/aiCfo/aiCfoReducer.js +186 -2
  4. package/lib/entity/aiCfo/aiCfoState.d.ts +164 -4
  5. package/lib/entity/aiCfo/aiCfoState.js +10 -1
  6. package/lib/entity/cardPolicy/cardPolicyPayload.d.ts +171 -0
  7. package/lib/entity/cardPolicy/cardPolicyPayload.js +112 -0
  8. package/lib/entity/cardPolicy/cardPolicyReducer.d.ts +13 -0
  9. package/lib/entity/cardPolicy/cardPolicyReducer.js +203 -0
  10. package/lib/entity/cardPolicy/cardPolicySelector.d.ts +28 -0
  11. package/lib/entity/cardPolicy/cardPolicySelector.js +86 -0
  12. package/lib/entity/cardPolicy/cardPolicyState.d.ts +162 -0
  13. package/lib/entity/cardPolicy/cardPolicyState.js +14 -0
  14. package/lib/entity/cardPolicy/extractPolicyDocumentEpic.d.ts +18 -0
  15. package/lib/entity/cardPolicy/extractPolicyDocumentEpic.js +54 -0
  16. package/lib/entity/cardPolicy/fetchCardPolicyVendorOptionsEpic.d.ts +26 -0
  17. package/lib/entity/cardPolicy/fetchCardPolicyVendorOptionsEpic.js +47 -0
  18. package/lib/entity/jeSchedules/jeSchedulesTypes.d.ts +1 -1
  19. package/lib/entity/monthEndCloseChecks/monthEndCloseChecksState.d.ts +1 -1
  20. package/lib/entity/tenant/clearAllEpic.d.ts +6 -2
  21. package/lib/entity/tenant/clearAllEpic.js +8 -0
  22. package/lib/epic.d.ts +9 -2
  23. package/lib/epic.js +9 -2
  24. package/lib/esm/entity/aiCfo/aiCfoReducer.js +187 -3
  25. package/lib/esm/entity/aiCfo/aiCfoState.js +7 -0
  26. package/lib/esm/entity/cardPolicy/cardPolicyPayload.js +101 -0
  27. package/lib/esm/entity/cardPolicy/cardPolicyReducer.js +199 -0
  28. package/lib/esm/entity/cardPolicy/cardPolicySelector.js +66 -0
  29. package/lib/esm/entity/cardPolicy/cardPolicyState.js +9 -0
  30. package/lib/esm/entity/cardPolicy/extractPolicyDocumentEpic.js +50 -0
  31. package/lib/esm/entity/cardPolicy/fetchCardPolicyVendorOptionsEpic.js +43 -0
  32. package/lib/esm/entity/tenant/clearAllEpic.js +8 -0
  33. package/lib/esm/epic.js +9 -2
  34. package/lib/esm/index.js +21 -7
  35. package/lib/esm/reducer.js +12 -0
  36. package/lib/esm/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +1 -21
  37. package/lib/esm/view/expenseAutomationView/reducers/transactionsViewReducer.js +14 -117
  38. package/lib/esm/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +0 -28
  39. package/lib/esm/view/recommendation/recommendationHelper.js +0 -29
  40. package/lib/esm/view/recommendation/recommendationReducer.js +1 -36
  41. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailReducer.js +70 -0
  42. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailSelector.js +22 -0
  43. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailState.js +1 -0
  44. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/fetchCardPolicyDetailEpic.js +44 -0
  45. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/updateCardPolicyEpic.js +49 -0
  46. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/archiveCardPolicyEpic.js +42 -0
  47. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListReducer.js +72 -0
  48. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListSelector.js +21 -0
  49. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListState.js +1 -0
  50. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/fetchCardPolicyListEpic.js +46 -0
  51. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyReducer.js +50 -0
  52. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicySelector.js +6 -0
  53. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyState.js +1 -0
  54. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyTemplateEpic.js +34 -0
  55. package/lib/esm/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/fetchCardPolicyMccCategoriesEpic.js +17 -0
  56. package/lib/esm/view/transactionDetail/transactionDetailReducer.js +1 -110
  57. package/lib/esm/view/transactionDetail/transactionDetailSelector.js +0 -22
  58. package/lib/index.d.ts +20 -8
  59. package/lib/index.js +119 -35
  60. package/lib/reducer.d.ts +12 -0
  61. package/lib/reducer.js +12 -0
  62. package/lib/view/companyHealthMetricView/companyHealthMetricViewSelector.d.ts +1 -1
  63. package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +0 -1
  64. package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +2 -23
  65. package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.d.ts +1 -14
  66. package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.js +14 -117
  67. package/lib/view/expenseAutomationView/selectorTypes/transactionsViewSelectorTypes.d.ts +0 -2
  68. package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.d.ts +0 -3
  69. package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +0 -29
  70. package/lib/view/expenseAutomationView/types/jeSchedulesViewState.d.ts +1 -1
  71. package/lib/view/expenseAutomationView/types/missingReceiptsViewState.d.ts +2 -2
  72. package/lib/view/expenseAutomationView/types/transactionsViewState.d.ts +1 -2
  73. package/lib/view/onboardingView/cockpitView/types/onboardingCockpitViewTypes.d.ts +1 -1
  74. package/lib/view/people/peopleTypes.d.ts +1 -1
  75. package/lib/view/recommendation/recommendationHelper.d.ts +0 -9
  76. package/lib/view/recommendation/recommendationHelper.js +1 -31
  77. package/lib/view/recommendation/recommendationReducer.d.ts +1 -18
  78. package/lib/view/recommendation/recommendationReducer.js +2 -37
  79. package/lib/view/scheduleView/scheduleListView/scheduleListTypes.d.ts +1 -1
  80. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailReducer.d.ts +14 -0
  81. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailReducer.js +74 -0
  82. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailSelector.d.ts +21 -0
  83. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailSelector.js +28 -0
  84. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailState.d.ts +25 -0
  85. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailState.js +2 -0
  86. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/fetchCardPolicyDetailEpic.d.ts +19 -0
  87. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/fetchCardPolicyDetailEpic.js +48 -0
  88. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/updateCardPolicyEpic.d.ts +18 -0
  89. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/updateCardPolicyEpic.js +53 -0
  90. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/archiveCardPolicyEpic.d.ts +16 -0
  91. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/archiveCardPolicyEpic.js +46 -0
  92. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListReducer.d.ts +15 -0
  93. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListReducer.js +76 -0
  94. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListSelector.d.ts +21 -0
  95. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListSelector.js +27 -0
  96. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListState.d.ts +19 -0
  97. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListState.js +2 -0
  98. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/fetchCardPolicyListEpic.d.ts +19 -0
  99. package/lib/view/spendManagement/chargeCards/cardPolicy/cardPolicyList/fetchCardPolicyListEpic.js +50 -0
  100. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyReducer.d.ts +12 -0
  101. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyReducer.js +54 -0
  102. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicySelector.d.ts +4 -0
  103. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicySelector.js +10 -0
  104. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyState.d.ts +15 -0
  105. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyState.js +2 -0
  106. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyTemplateEpic.d.ts +8 -0
  107. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyTemplateEpic.js +38 -0
  108. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/fetchCardPolicyMccCategoriesEpic.d.ts +15 -0
  109. package/lib/view/spendManagement/chargeCards/cardPolicy/createCardPolicy/fetchCardPolicyMccCategoriesEpic.js +21 -0
  110. package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardList.d.ts +1 -1
  111. package/lib/view/taskManager/taskListView/taskListReducer.d.ts +1 -1
  112. package/lib/view/transactionDetail/transactionDetailReducer.d.ts +1 -11
  113. package/lib/view/transactionDetail/transactionDetailReducer.js +2 -111
  114. package/lib/view/transactionDetail/transactionDetailSelector.d.ts +0 -2
  115. package/lib/view/transactionDetail/transactionDetailSelector.js +1 -24
  116. package/lib/view/transactionDetail/transactionDetailTypes.d.ts +0 -1
  117. package/package.json +1 -1
  118. package/lib/esm/view/recommendation/fetchEntityRecommendationsForLineUpdateEpic.js +0 -88
  119. package/lib/tsconfig.typecheck.tsbuildinfo +0 -1
  120. package/lib/view/recommendation/fetchEntityRecommendationsForLineUpdateEpic.d.ts +0 -9
  121. package/lib/view/recommendation/fetchEntityRecommendationsForLineUpdateEpic.js +0 -92
@@ -0,0 +1,199 @@
1
+ import { createSlice } from '@reduxjs/toolkit';
2
+ import { toCardPolicyTemplate, toCardPolicyVendorSearchOption, toExtractedCardPolicyRules, toMccCategory, } from './cardPolicyPayload';
3
+ /**
4
+ * Defensive predicate for vendor / merchant names that flow into
5
+ * `buildVendorChipId(name)` (in `@zeniai/web-components`). That helper
6
+ * calls `name.trim().toLowerCase()`, so a null / undefined / whitespace-
7
+ * only value would throw at render time, and an empty string would
8
+ * collapse every nameless row into a single colliding `vendor-` chip-id.
9
+ * Used at the redux ingestion boundary for both the vendor-search results
10
+ * and the BE-suggested merchant seed arrays.
11
+ */
12
+ const isUsableMerchantName = (name) => typeof name === 'string' && name.trim() !== '';
13
+ const initialPolicyDocumentExtractionState = {
14
+ fetchState: 'Not-Started',
15
+ error: undefined,
16
+ extractedRules: undefined,
17
+ uploadedFileName: undefined,
18
+ };
19
+ const initialVendorSearchState = {
20
+ fetchState: 'Not-Started',
21
+ searchString: '',
22
+ vendors: [],
23
+ error: undefined,
24
+ };
25
+ export const initialState = {
26
+ cardPolicyTemplateById: {},
27
+ mccCategories: [],
28
+ mccCategoriesError: undefined,
29
+ mccCategoriesFetchState: 'Not-Started',
30
+ policyDocumentExtraction: initialPolicyDocumentExtractionState,
31
+ suggestedAllowCategories: [],
32
+ suggestedAllowMerchants: [],
33
+ suggestedBlockCategories: [],
34
+ suggestedBlockMerchants: [],
35
+ vendorSearch: initialVendorSearchState,
36
+ cardPolicyStats: undefined,
37
+ };
38
+ const cardPolicy = createSlice({
39
+ name: 'cardPolicy',
40
+ initialState,
41
+ reducers: {
42
+ fetchCardPolicyMccCategories(draft) {
43
+ draft.mccCategoriesFetchState = 'In-Progress';
44
+ draft.mccCategoriesError = undefined;
45
+ },
46
+ updateCardPolicyMccCategories(draft, action) {
47
+ draft.mccCategories = (action.payload.categories ?? []).map(toMccCategory);
48
+ // Persist BE-suggested allow / block seeds alongside the universe.
49
+ // Both flows (manual create page + AI CFO interactive form) read
50
+ // these to pre-populate the chip cloud body before the user edits.
51
+ // Drop empty / nullish merchant names defensively — they feed
52
+ // `buildVendorChipId(name)` (in @zeniai/web-components) which calls
53
+ // `.trim().toLowerCase()` and would crash the chip-picker render
54
+ // path if any entry slipped through as undefined / "".
55
+ draft.suggestedAllowMerchants = (action.payload.suggested_allow_merchants ?? []).filter(isUsableMerchantName);
56
+ draft.suggestedBlockMerchants = (action.payload.suggested_block_merchants ?? []).filter(isUsableMerchantName);
57
+ draft.suggestedAllowCategories = (action.payload.suggested_allow_catagories ?? []).map(toMccCategory);
58
+ draft.suggestedBlockCategories = (action.payload.suggested_block_catagories ?? []).map(toMccCategory);
59
+ draft.mccCategoriesFetchState = 'Completed';
60
+ draft.mccCategoriesError = undefined;
61
+ },
62
+ updateCardPolicyMccCategoriesFailure(draft, action) {
63
+ draft.mccCategoriesFetchState = 'Error';
64
+ draft.mccCategoriesError = action.payload;
65
+ },
66
+ /**
67
+ * Store a newly-created (or refreshed) card-policy template keyed by
68
+ * `templateId`. Dispatched by the create / list / get epics; consumed
69
+ * by both manual and AI-CFO policy flows via `getCardPolicyTemplateById`.
70
+ */
71
+ updateCreatedCardPolicyTemplate(draft, action) {
72
+ const template = toCardPolicyTemplate(action.payload);
73
+ draft.cardPolicyTemplateById[template.templateId] = template;
74
+ },
75
+ /**
76
+ * Replace the entity store's `cardPolicyTemplateById` map with the
77
+ * full list returned by the templates-list endpoint. Full replace is
78
+ * intentional — templates that no longer exist on the server should be
79
+ * dropped from local state too. The view slice keeps the server-order
80
+ * ID list separately for stable list rendering.
81
+ */
82
+ updateCardPolicyTemplates(draft, action) {
83
+ const byId = {};
84
+ for (const template of action.payload) {
85
+ byId[template.templateId] = template;
86
+ }
87
+ draft.cardPolicyTemplateById = byId;
88
+ },
89
+ /**
90
+ * Drop a single template from the entity map. Dispatched by the
91
+ * archive (DELETE) epic on success; also usable by any future flow
92
+ * that needs to evict a template (e.g. AI-CFO rejection).
93
+ */
94
+ removeCardPolicyTemplate(draft, action) {
95
+ delete draft.cardPolicyTemplateById[action.payload];
96
+ },
97
+ /**
98
+ * Replace the tenant-wide policy stats. Dispatched alongside
99
+ * `updateCardPolicyTemplates` from the list epic, but lives on the
100
+ * entity slice so any consumer can read it without re-fetching the
101
+ * list.
102
+ */
103
+ updateCardPolicyStats(draft, action) {
104
+ draft.cardPolicyStats = action.payload;
105
+ },
106
+ /**
107
+ * Kick off the `POST /cards/1.0/policy-documents/extract` request.
108
+ *
109
+ * Synchronously flips the sub-slice to `In-Progress` and captures the
110
+ * first uploaded file's name (used by the manual `CardPolicyCreatePage`
111
+ * to render the "Policy.pdf ×" pill once the request completes) so
112
+ * downstream callers don't have to keep their own file refs.
113
+ *
114
+ * The accompanying `extractPolicyDocumentEpic` listens for this action,
115
+ * POSTs multipart form-data to the cards micro-service, and dispatches
116
+ * either `updatePolicyDocumentExtractionSuccess` or
117
+ * `updatePolicyDocumentExtractionFailure`.
118
+ *
119
+ * Designed to be dispatched from both the manual create page and a
120
+ * future AI CFO composer/upload surface — selectors return a single
121
+ * source of truth.
122
+ */
123
+ extractPolicyDocument: {
124
+ reducer(draft, action) {
125
+ draft.policyDocumentExtraction.fetchState = 'In-Progress';
126
+ draft.policyDocumentExtraction.error = undefined;
127
+ draft.policyDocumentExtraction.extractedRules = undefined;
128
+ draft.policyDocumentExtraction.uploadedFileName =
129
+ action.meta.uploadedFileName;
130
+ },
131
+ prepare(files) {
132
+ return {
133
+ payload: { files },
134
+ meta: { uploadedFileName: files[0]?.name },
135
+ };
136
+ },
137
+ },
138
+ updatePolicyDocumentExtractionSuccess(draft, action) {
139
+ draft.policyDocumentExtraction.fetchState = 'Completed';
140
+ draft.policyDocumentExtraction.error = undefined;
141
+ draft.policyDocumentExtraction.extractedRules =
142
+ toExtractedCardPolicyRules(action.payload);
143
+ },
144
+ updatePolicyDocumentExtractionFailure(draft, action) {
145
+ draft.policyDocumentExtraction.fetchState = 'Error';
146
+ draft.policyDocumentExtraction.error = action.payload;
147
+ draft.policyDocumentExtraction.extractedRules = undefined;
148
+ },
149
+ clearPolicyDocumentExtraction(draft) {
150
+ draft.policyDocumentExtraction = {
151
+ ...initialPolicyDocumentExtractionState,
152
+ };
153
+ },
154
+ /**
155
+ * Kick off `GET /accounting/1.0/vendors` (card-policy mode). When
156
+ * `searchString` is empty the BE returns the top vendors sorted by
157
+ * year-to-date spend; with a non-empty value it filters server-side.
158
+ *
159
+ * The accompanying `fetchCardPolicyVendorOptionsEpic` listens for
160
+ * this action, builds the `query` JSON (matching `fetchVendorsList`'s
161
+ * `view: "vendor_list"` shape) and dispatches success / failure.
162
+ *
163
+ * Designed to be dispatched from both the manual `CardPolicyCreate /
164
+ * EditScreen` (on mount + on every chip-picker keystroke, debounced)
165
+ * and the AI CFO interactive form's vendor step.
166
+ */
167
+ fetchCardPolicyVendorOptions: {
168
+ reducer(draft, action) {
169
+ draft.vendorSearch.fetchState = 'In-Progress';
170
+ draft.vendorSearch.searchString = action.payload.searchString;
171
+ draft.vendorSearch.error = undefined;
172
+ },
173
+ prepare(searchString) {
174
+ return { payload: { searchString: searchString ?? '' } };
175
+ },
176
+ },
177
+ updateCardPolicyVendorOptions(draft, action) {
178
+ // Drop rows with no usable name. The chip-picker keys vendors by
179
+ // `buildVendorChipId(name)` (in @zeniai/web-components), which calls
180
+ // `name.trim().toLowerCase()`. A null / undefined / whitespace-only
181
+ // name would either throw at render time or collapse every nameless
182
+ // row into a single colliding `vendor-` chip-id.
183
+ draft.vendorSearch.vendors = (action.payload.vendors ?? [])
184
+ .map(toCardPolicyVendorSearchOption)
185
+ .filter((vendor) => isUsableMerchantName(vendor.name));
186
+ draft.vendorSearch.fetchState = 'Completed';
187
+ draft.vendorSearch.error = undefined;
188
+ },
189
+ updateCardPolicyVendorOptionsFailure(draft, action) {
190
+ draft.vendorSearch.fetchState = 'Error';
191
+ draft.vendorSearch.error = action.payload;
192
+ },
193
+ clearCardPolicy(draft) {
194
+ Object.assign(draft, initialState);
195
+ },
196
+ },
197
+ });
198
+ export const { fetchCardPolicyMccCategories, fetchCardPolicyVendorOptions, updateCardPolicyMccCategories, updateCardPolicyMccCategoriesFailure, updateCardPolicyVendorOptions, updateCardPolicyVendorOptionsFailure, updateCreatedCardPolicyTemplate, updateCardPolicyTemplates, removeCardPolicyTemplate, updateCardPolicyStats, extractPolicyDocument, updatePolicyDocumentExtractionSuccess, updatePolicyDocumentExtractionFailure, clearPolicyDocumentExtraction, clearCardPolicy, } = cardPolicy.actions;
199
+ export default cardPolicy.reducer;
@@ -0,0 +1,66 @@
1
+ export function getCardPolicyMccCategories(state) {
2
+ return state.mccCategories;
3
+ }
4
+ export function getCardPolicyMccCategoriesFetchState(state) {
5
+ return state.mccCategoriesFetchState;
6
+ }
7
+ export function getCardPolicyMccCategoriesError(state) {
8
+ return state.mccCategoriesError;
9
+ }
10
+ export function getCardPolicyTemplateById(state, templateId) {
11
+ return state.cardPolicyTemplateById[templateId];
12
+ }
13
+ export function getAllCardPolicyTemplates(state) {
14
+ return Object.values(state.cardPolicyTemplateById);
15
+ }
16
+ /**
17
+ * Resolve an ordered list of `templateId`s against the entity store and
18
+ * return the corresponding `CardPolicyTemplate[]` in the same order.
19
+ * Missing IDs (e.g. stale local state during a refetch) are silently
20
+ * dropped. Pair with `getCardPolicyTemplateIds` from the view slice to
21
+ * render the Policy List page in server order.
22
+ */
23
+ export function getCardPolicyTemplatesByIds(state, templateIds) {
24
+ return templateIds
25
+ .map((id) => state.cardPolicyTemplateById[id])
26
+ .filter((template) => template != null);
27
+ }
28
+ export function getCardPolicyStats(state) {
29
+ return state.cardPolicyStats;
30
+ }
31
+ // ── Policy document extraction ───────────────────────────────────────
32
+ export function getPolicyDocumentExtractionFetchState(state) {
33
+ return state.policyDocumentExtraction.fetchState;
34
+ }
35
+ export function getPolicyDocumentExtractionError(state) {
36
+ return state.policyDocumentExtraction.error;
37
+ }
38
+ export function getExtractedCardPolicyRules(state) {
39
+ return state.policyDocumentExtraction.extractedRules;
40
+ }
41
+ export function getUploadedPolicyDocumentFileName(state) {
42
+ return state.policyDocumentExtraction.uploadedFileName;
43
+ }
44
+ // ── Suggested allow / block seeds (shipped alongside MCC categories) ─
45
+ export function getCardPolicySuggestedAllowMerchants(state) {
46
+ return state.suggestedAllowMerchants;
47
+ }
48
+ export function getCardPolicySuggestedBlockMerchants(state) {
49
+ return state.suggestedBlockMerchants;
50
+ }
51
+ export function getCardPolicySuggestedAllowCategories(state) {
52
+ return state.suggestedAllowCategories;
53
+ }
54
+ export function getCardPolicySuggestedBlockCategories(state) {
55
+ return state.suggestedBlockCategories;
56
+ }
57
+ // ── Vendor search dropdown ───────────────────────────────────────────
58
+ export function getCardPolicyVendorSearchOptions(state) {
59
+ return state.vendorSearch.vendors;
60
+ }
61
+ export function getCardPolicyVendorSearchFetchState(state) {
62
+ return state.vendorSearch.fetchState;
63
+ }
64
+ export function getCardPolicyVendorSearchString(state) {
65
+ return state.vendorSearch.searchString;
66
+ }
@@ -0,0 +1,9 @@
1
+ import { stringToUnion } from '../../commonStateTypes/stringToUnion';
2
+ export const ALL_CARD_POLICY_TEMPLATE_MODES = ['strict', 'flexible'];
3
+ export const toCardPolicyTemplateMode = (v) => stringToUnion(v, ALL_CARD_POLICY_TEMPLATE_MODES);
4
+ export const ALL_CARD_POLICY_TEMPLATE_STATUSES = [
5
+ 'active',
6
+ 'inactive',
7
+ 'archived',
8
+ ];
9
+ export const toCardPolicyTemplateStatus = (v) => stringToUnion(v, ALL_CARD_POLICY_TEMPLATE_STATUSES);
@@ -0,0 +1,50 @@
1
+ import { of } from 'rxjs';
2
+ import { catchError, filter, mergeMap } from 'rxjs/operators';
3
+ import { createZeniAPIStatus, isSuccessStatus } from '../../responsePayload';
4
+ import { extractPolicyDocument, updatePolicyDocumentExtractionFailure, updatePolicyDocumentExtractionSuccess, } from './cardPolicyReducer';
5
+ /**
6
+ * Build a multipart `FormData` body for `POST /cards/1.0/policy-documents/extract`.
7
+ *
8
+ * Uses the same `attachment_file_<i>` / `attachment_json_<i>` field-naming
9
+ * convention as the charge-card receipt upload (`uploadReceipts.ts` in
10
+ * `web-components`) so backends that already support that wire shape
11
+ * accept this endpoint without bespoke parsing.
12
+ */
13
+ const buildPolicyDocumentFormData = (files) => {
14
+ const data = new FormData();
15
+ files.forEach((file, index) => {
16
+ data.append(`attachment_file_${index}`, file);
17
+ const attachmentJson = JSON.stringify({
18
+ file_name: file.name,
19
+ content_type: file.type,
20
+ size: file.size,
21
+ });
22
+ data.append(`attachment_json_${index}`, attachmentJson);
23
+ });
24
+ return data;
25
+ };
26
+ /**
27
+ * Listens for `extractPolicyDocument`, POSTs the file(s) as multipart
28
+ * form-data to the cards micro-service's policy-document extract endpoint,
29
+ * and dispatches success / failure into the entity slice.
30
+ *
31
+ * Consumed by:
32
+ * - Manual `CardPolicyCreatePage` (read result via
33
+ * `getExtractedCardPolicyRules` then pre-fill the RHF form via
34
+ * `applyExtractedPolicyRulesToFormValues` from `@zeniai/web-components`).
35
+ * - (Future) AI CFO upload surface — same action + selector contract.
36
+ */
37
+ export const extractPolicyDocumentEpic = (actions$, _state$, zeniAPI) => actions$.pipe(filter(extractPolicyDocument.match), mergeMap((action) => {
38
+ const formData = buildPolicyDocumentFormData(action.payload.files);
39
+ return zeniAPI
40
+ .postFormData(`${zeniAPI.apiEndPoints.cardMicroServiceBaseUrl}/1.0/policy-documents/extract`, formData)
41
+ .pipe(mergeMap((response) => {
42
+ if (isSuccessStatus(response) &&
43
+ response.data != null &&
44
+ response.data.extracted_rules != null) {
45
+ return of(updatePolicyDocumentExtractionSuccess(response.data.extracted_rules));
46
+ }
47
+ return of(updatePolicyDocumentExtractionFailure(response.status));
48
+ }), catchError((error) => of(updatePolicyDocumentExtractionFailure(createZeniAPIStatus('Unexpected Error', 'Extract card-policy document REST API call errored out' +
49
+ JSON.stringify(error))))));
50
+ }));
@@ -0,0 +1,43 @@
1
+ import { of } from 'rxjs';
2
+ import { catchError, filter, switchMap } from 'rxjs/operators';
3
+ import { createZeniAPIStatus, isSuccessStatus } from '../../responsePayload';
4
+ import { fetchCardPolicyVendorOptions, updateCardPolicyVendorOptions, updateCardPolicyVendorOptionsFailure, } from './cardPolicyReducer';
5
+ const buildQuery = (searchString) => ({
6
+ view: 'vendor_list',
7
+ page_token: null,
8
+ sort_by: 'year_to_date_spend',
9
+ sort_order: 'desc',
10
+ search_text: searchString,
11
+ vendor_name: searchString,
12
+ });
13
+ /**
14
+ * Card-policy vendor search.
15
+ *
16
+ * Listens for `fetchCardPolicyVendorOptions` and hits the same
17
+ * `/accounting/1.0/vendors` endpoint the Vendors-tab uses, but writes
18
+ * results onto the dedicated `cardPolicyState.vendorSearch` slice — no
19
+ * fan-out to the global `vendor` / `account` / `class` / `vendorList`
20
+ * entities. That isolation is important: the user may be configuring a
21
+ * card policy in parallel with browsing the Vendors tab, and we don't
22
+ * want either flow to clobber the other's list state.
23
+ *
24
+ * Uses `switchMap` so the latest typed search wins — earlier in-flight
25
+ * requests are abandoned, which is the right semantics for a
26
+ * search-as-you-type UX.
27
+ *
28
+ * Consumers:
29
+ * - Manual `CardPolicyCreate / EditScreen`
30
+ * - AI CFO `CardPolicyInteractiveForm` (vendor step)
31
+ */
32
+ export const fetchCardPolicyVendorOptionsEpic = (actions$, _state$, zeniAPI) => actions$.pipe(filter(fetchCardPolicyVendorOptions.match), switchMap((action) => {
33
+ const query = buildQuery(action.payload.searchString);
34
+ const apiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/vendors` +
35
+ `?query=${encodeURIComponent(JSON.stringify(query))}`;
36
+ return zeniAPI.getJSON(apiUrl).pipe(switchMap((response) => {
37
+ if (isSuccessStatus(response) && response.data != null) {
38
+ return of(updateCardPolicyVendorOptions(response.data));
39
+ }
40
+ return of(updateCardPolicyVendorOptionsFailure(response.status));
41
+ }), catchError((error) => of(updateCardPolicyVendorOptionsFailure(createZeniAPIStatus('Unexpected Error', 'Fetch card policy vendor options REST API call errored out' +
42
+ JSON.stringify(error))))));
43
+ }));
@@ -97,6 +97,9 @@ import { clearInternationalWire } from '../../view/spendManagement/billPay/inter
97
97
  import { clearInternationalVerificationView } from '../../view/spendManagement/billPay/internationalWireVerification/internationalWireVerificationReducer';
98
98
  import { clearPreviousBills } from '../../view/spendManagement/billPay/previousBills/previousBillsReducer';
99
99
  import { clearWiseRedirectStatus } from '../../view/spendManagement/billPay/wiseRedirectView/wiseRedirectReducer';
100
+ import { clearCardPolicyDetail } from '../../view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/cardPolicyDetailReducer';
101
+ import { clearCardPolicyList } from '../../view/spendManagement/chargeCards/cardPolicy/cardPolicyList/cardPolicyListReducer';
102
+ import { clearCreateCardPolicy } from '../../view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyReducer';
100
103
  import { clearCardUserOnboarding } from '../../view/spendManagement/chargeCards/cardUserOnboarding/cardUserOnboardingReducer';
101
104
  import { clearCashbackDetail } from '../../view/spendManagement/chargeCards/cashbackDetail/cashbackDetailReducer';
102
105
  import { clearChargeCardConfig } from '../../view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigReducer';
@@ -167,6 +170,7 @@ import { clearAllBillTransactions } from '../billPay/billTransaction/billTransac
167
170
  import { clearContacts } from '../billPay/contact/contactReducer';
168
171
  import { clearAllRecurringBills } from '../billPay/recurringBills/recurringBillsReducer';
169
172
  import { clearAllCardPayments } from '../cardPayment/cardPaymentReducer';
173
+ import { clearCardPolicy } from '../cardPolicy/cardPolicyReducer';
170
174
  import { clearAllChargeCards } from '../chargeCard/chargeCardReducer';
171
175
  import { clearAllChargeCardRepayments } from '../chargeCardRepayment/chargeCardRepaymentReducer';
172
176
  import { clearAllChargeCardTransactions } from '../chargeCardTransaction/chargeCardTransactionReducer';
@@ -243,6 +247,8 @@ export const clearAllEpic = (actions$) => actions$.pipe(filter(clearAll.match),
243
247
  clearBillPaySetupView(),
244
248
  clearCardBalance(),
245
249
  clearCardPaymentView(),
250
+ clearCardPolicyDetail(),
251
+ clearCardPolicyList(),
246
252
  clearCardUserOnboarding(),
247
253
  clearCashbackDetail(),
248
254
  clearCashBalance(),
@@ -262,6 +268,7 @@ export const clearAllEpic = (actions$) => actions$.pipe(filter(clearAll.match),
262
268
  clearCompanyMonthEndReportView(),
263
269
  clearCompanyTaskManagerView(),
264
270
  clearCompanyView(),
271
+ clearCreateCardPolicy(),
265
272
  clearAllCreditAgent(),
266
273
  clearCreditAgentView(),
267
274
  clearDashboard(),
@@ -422,6 +429,7 @@ export const clearAllEpic = (actions$) => actions$.pipe(filter(clearAll.match),
422
429
  clearAllVendorExpenseTrends(),
423
430
  clearAllVendors(),
424
431
  clearCannedResponses(),
432
+ clearCardPolicy(),
425
433
  clearClassList(),
426
434
  clearContacts(),
427
435
  clearCountryList(),
package/lib/esm/epic.js CHANGED
@@ -263,7 +263,6 @@ import { fetchProfitAndLossForTimeframeProjectViewEpic, } from './view/profitAnd
263
263
  import { fetchProfitAndLossProjectViewEpic, } from './view/profitAndLossProjectView/profitAndLossProjectViewEpic';
264
264
  import { fetchProjectListEpic, } from './view/projectList/fetchProjectListEpic';
265
265
  import { fetchEntityRecommendationsByTransactionIdEpic, } from './view/recommendation/fetchEntityRecommendationsByTransactionIdEpic';
266
- import { fetchEntityRecommendationsForLineUpdateEpic, } from './view/recommendation/fetchEntityRecommendationsForLineUpdateEpic';
267
266
  import { fetchRecommendationByEntityIdEpic, } from './view/recommendation/fetchRecommendationByEntityIdEpic';
268
267
  import { fetchRecommendationByEntityNameEpic, } from './view/recommendation/fetchRecommendationByEntityNameEpic';
269
268
  import { fetchReferralsEpic, } from './view/referralView/epics/fetchReferralsEpic';
@@ -376,6 +375,14 @@ import { fetchPreviousBillsEpic, } from './view/spendManagement/billPay/previous
376
375
  import { wiseRedirectEpic, } from './view/spendManagement/billPay/wiseRedirectView/wiseRedirectEpic';
377
376
  import { initializeCardUserOnboardingLocalDataEpic, } from './view/spendManagement/chargeCards/cardUserOnboarding/epics/initializeCardUserOnboardingLocalDataEpic';
378
377
  import { saveCardOnboardingUserDetailsEpic, } from './view/spendManagement/chargeCards/cardUserOnboarding/epics/saveCardOnboardingUserDetailsEpic';
378
+ import { fetchCardPolicyMccCategoriesEpic, } from './view/spendManagement/chargeCards/cardPolicy/createCardPolicy/fetchCardPolicyMccCategoriesEpic';
379
+ import { createCardPolicyTemplateEpic, } from './view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyTemplateEpic';
380
+ import { extractPolicyDocumentEpic, } from './entity/cardPolicy/extractPolicyDocumentEpic';
381
+ import { fetchCardPolicyVendorOptionsEpic, } from './entity/cardPolicy/fetchCardPolicyVendorOptionsEpic';
382
+ import { fetchCardPolicyListEpic, } from './view/spendManagement/chargeCards/cardPolicy/cardPolicyList/fetchCardPolicyListEpic';
383
+ import { archiveCardPolicyEpic, } from './view/spendManagement/chargeCards/cardPolicy/cardPolicyList/archiveCardPolicyEpic';
384
+ import { fetchCardPolicyDetailEpic, } from './view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/fetchCardPolicyDetailEpic';
385
+ import { updateCardPolicyEpic, } from './view/spendManagement/chargeCards/cardPolicy/cardPolicyDetail/updateCardPolicyEpic';
379
386
  import { fetchCashbackDetailEpic, } from './view/spendManagement/chargeCards/cashbackDetail/fetchCashbackDetailEpic';
380
387
  import { fetchChargeCardConfigEpic, } from './view/spendManagement/chargeCards/chargeCardConfig/fetchChargeCardConfigEpic';
381
388
  import { closeChargeCardEpic, } from './view/spendManagement/chargeCards/chargeCardDetail/closeChargeCardEpic';
@@ -579,7 +586,7 @@ import { fetchZeniAccStatementPageEpic, } from './view/zeniAccStatementList/fetc
579
586
  import { fetchZeniAccountsPromoCardEpic, } from './view/zeniAccountsPromoCard/zeniAccountsPromoCardEpic';
580
587
  import { approveOAuthConsentEpic, } from './view/zeniOAuthView/epics/approveOAuthConsentEpic';
581
588
  // Note: Please maintain strict alphabetical order
582
- const combinedEpics = combineEpics(acceptBillPayTermsEpic, acceptBillPayUpdatedTermsEpic, acceptChargeCardTermsEpic, acceptEmployeeRemiTermsEpic, acceptMasterTOSEpic, acceptRemiTermsEpic, acceptTreasuryTermsEpic, acceptZeniAccountTermsEpic, addCardPaymentSourceEpic, approveOAuthConsentEpic, approveOrRejectBillEpic, approveOrRejectBillsBulkActionEpic, approveOrRejectRemiEpic, approveOrRejectRemisBulkActionEpic, approveVendorGlobalReviewEpic, archiveTaskEpic, backgroundRefetchReviewTabEpic, bulkUpdateTaskListEpic, cancelAiAccountantOnboardingEpic, cancelAndDeleteBillEpic, cancelAndDeleteRemiEpic, cancelOrDeleteBillsBulkActionEpic, cancelOrDeleteRemisBulkActionEpic, cancelScheduleAccruedJournalEntryEpic, changeZeniPersonRolesEpic, checkDepositEpic, clearAllEpic, closeChargeCardEpic, closeChargeCardsEpic, companyManagementSavePendingUpdatesEpic, companyManagementSaveUpdatesEpic, confirmCardSetupIntentEpic, convertAmountToHomeCurrencyEpic, createAddressEpic, createAutoTransferRuleEpic, createBankAccountEpic, createCardSetupIntentEpic, createCheckingAccountEpic, createCompanyAddressEpic, createCompanyOfficersEpic, createCompanyUserAddressEpic, createGlobalMerchantEpic, createInternationalBankAccountEpic, createNewSchedulesAccruedEpic, createNewSchedulesEpic, createNewTaskGroupEpic, createPaymentInstrumentEpic, createSessionAndSubmitEpic, createSessionEpic, createTagEpic, createTaskFromTaskGroupTemplateEpic, createUserBankAccountEpic, deleteAccountStatementEpic, deleteAutoTransferRuleEpic, excludeAccountFromReconciliationEpic, includeAccountInReconciliationEpic, deleteBankAccountEpic, deleteBillEpic, deleteChatSessionEpic, deleteConnectionEpic, deleteBillPayApprovalRuleEpic, deleteFileEpic, deleteFileListEpic, deleteInternationalBankAccountEpic, deletePaymentInstrumentEpic, deletePersonEpic, deleteRemiApprovalRuleEpic, deleteRemiEpic, deleteScheduleAccruedDetailEpic, deleteScheduleDetailEpic, deleteTagEpic, deleteTaskEpic, snoozeTaskEpic, unsnoozeTaskEpic, deleteTaskGroupEpic, deleteTransactionAttachmentEpic, deleteUserBankAccountEpic, doMagicLinkSignInEpic, doSignInEpic, doSignOutEpic, sendEmailMagicLinkToUserEpic, sessionHeartbeatEpic, verifyDeviceWithTwoFAEpic, downloadAccountingProviderAttachmentEpic, dragNDropTasksEpic, enableChargeCardAutoPayEpic, enableSetupEpic, establishOnboardingPlaidConnectionEpic, establishPlaidConnectionEpic, expressInterestChargeCardEpic, fetchAccountListEpic, fetchAccountListForAccountTypesEpic, fetchAccountSettingsListForAccountTypesEpic, fetchAccruedScheduleListEpic, fetchActiveTenantEpic, fetchAddressEpic, fetchAiAccountantCustomersEpic, fetchAiAccountantJobsEpic, fetchAllCockpitViewsEpic, fetchAllExpenseAutomationTabsEpic, fetchAllPeopleRequiredViewsEpic, fetchAllTagsEpic, fetchAllTaskGroupsEpic, fetchAllTenantsEpic, fetchAndUpdateVendorRecommendationsEpic, fetchAggregatedReportEpic, fetchApAgingDetailEpic, fetchApAgingEpic, fetchArAgingDetailEpic, fetchArAgingEpic, fetchAuditReportGroupViewEpic, fetchAuditRuleGroupViewEpic, fetchAutoTransferReviewDetailEpic, fetchAutoTransferRuleHistoryEpic, fetchAutoTransferRulesEpic, fetchBalanceSheetEpic, fetchBalanceSheetForTimeframeEpic, fetchBankAccountsListEpic, fetchBankConnectionsViewEpic, fetchBankCountryNameByIbanEpic, fetchBankNameByRoutingEpic, fetchBankNameBySwiftEpic, fetchBillAndInitializeLocalStoreEpic, fetchBillDetailEpic, fetchBillingAccountsListEpic, fetchBillListEpic, fetchBillListPerTabEpic, fetchBillPayApproversDetailsEpic, fetchBillPayApproversListEpic, fetchBillPayCardEpic, fetchBillPayConfigEpic, fetchBillPaySetupApproverViewEpic, fetchBillPaySetupViewEpic, fetchCardBalanceEpic, fetchCardProfilesEpic, fetchCashbackDetailEpic, fetchCashBalanceEpic, fetchCashFlowEpic, fetchCashFlowForTimeframeEpic, fetchCashInCashOutEpic, fetchCashPositionEpic, fetchChargeCardConfigEpic, fetchChargeCardDetailEpic, fetchChargeCardDetailPageEpic, fetchChargeCardListEpic, fetchChargeCardListPageEpic, fetchChargeCardPaymentPageEpic, fetchChargeCardRepaymentDetailEpic, fetchChargeCardPaymentHistoryEpic, fetchChargeCardSetupViewEpic, fetchChargeCardStatementListEpic, fetchChargeCardTransactionAttachmentsEpic, fetchChargeCardTransactionListEpic, fetchChargeCardTransactionStatisticsEpic, fetchChargeCardsRecurringExpensesEpic, fetchChatHistoryEpic, fetchChatSessionsForUserEpic, fetchClassListEpic, fetchCollaborationAuthTokenEpic, fetchCompanyBillingAddressEpic, fetchCompanyConfigEpic, fetchCompanyHealthMetricConfigEpic, fetchCompanyHealthMetricViewEpic, fetchCompanyManagementViewEpic, fetchCompanyMetaDataEpic, fetchCompanyMonthEndReportHistoricDataEpic, fetchCompanyMonthEndReportHistoricDatesEpic, fetchCompanyMonthEndReportTemplatesEpic, fetchCompanyMonthEndReportViewEpic, fetchCompanyOnboardingViewEpic, fetchCompanyPassportViewEpic, fetchCompanyPortfolioViewEpic, fetchCompanyTaskManagerViewEpic, fetchTaskManagerMetricsEpic, fetchCreditAccountEpic, fetchCreditAccountRepaymentEpic, fetchCreditAgentAccessEpic, fetchCreditAgentMacroEpic, fetchCurrencyConversionValueEpic, fetchDashboardEpic, fetchDashboardLayoutEpic, fetchDebitCardSummaryEpic, fetchDepositAccountDetailEpic, fetchDepositAccountEpic, fetchDepositAccountHistoryEpic, fetchDepositAccountLimitEpic, fetchDepositAccountListEpic, fetchDepositAccountListForCardsEpic, fetchDepositAccountTransactionListEpic, fetchDownloadSchedulesEpic, fetchDuplicateBillPayReviewEpic, fetchDuplicateReimbursementEpic, fetchEditBillDetailPageEpic, fetchEditRemiDetailPageEpic, fetchEligibleActionsForBillEpic, fetchEntityAutoCompleteEpic, fetchEntityHistoryEpic, fetchEntityRecommendationsByTransactionIdEpic, fetchEntityRecommendationsForLineUpdateEpic, fetchExcludedResourcesEpic, fetchExpenseAutomationFluxAnalysisViewEpic, fetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataEpic, fetchExpenseAutomationJeSchedulesEpic, fetchExpenseAutomationJESchedulesPageEpic, fetchExpenseAutomationMarkTransactionAsNotMiscategorizedEpic, fetchExpenseAutomationMissingReceiptsEpic, bulkUploadReceiptsEpic, confirmBulkUploadMatchEpic, fetchBulkUploadBatchDetailsEpic, fetchMultipleBatchDetailsEpic, fetchMoreBatchDetailsEpic, fetchBulkUploadBatchesEpic, fetchCompletedTransactionsEpic, refetchCompletedTransactionsOnBulkUploadSortEpic, bulkUploadAutomatchingTimeoutEpic, bulkUploadMatchResultToastEpic, pollBulkUploadBatchStatusEpic, pusherBatchStatusCompletionEpic, restoreBulkUploadAutomatchingOnMountEpic, searchTransactionsForManualMatchEpic, fetchExpenseAutomationReconciliationsViewEpic, fetchExpenseAutomationSaveTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationViewEpic, fetchExpenseAutomationUpdateTransactionCategorizationEpic, fetchExpenseTrendEpic, fetchExpressPayInitialDetailsEpic, fetchExternalConnectionsEpic, fetchFileEpic, fetchFileListEpic, fetchFinanceStatementEpic, fetchForecastListEpic, initiateReportsClassViewRefetchingEpic, reportsResyncEpic, fetchGlobalMerchantAutoCompleteViewEpic, fetchGlobalMerchantRecommendationEpic, fetchIncomeTrendEpic, fetchInsightsCardEpic, fetchInternationalWireDynamicFormEpic, fetchIntlVerificationFormEpic, fetchIssueCardPageEpic, fetchMagicLinkBankNameByRoutingEpic, fetchMagicLinkBankNameBySwiftEpic, fetchMagicLinkBillEpic, fetchMagicLinkTenantEpic, fetchManagementViewEpic, fetchMerchantListEpic, fetchMonthClosePerformanceTrendEpic, fetchMonthEndCloseChecksEpic, fetchMyProfileEpic, fetchMyProfileViewEpic, fetchNetBurnOrIncomeClassesViewEpic, fetchNetBurnOrIncomeEpic, fetchNetBurnOrIncomeForTimeframeClassesViewEpic, fetchNetBurnOrIncomeForTimeframeEpic, fetchNetBurnOrIncomeStoryCardEpic, fetchNetBurnOrIncomeWithForecastEpic, fetchNotificationSettingsEpic, fetchNotificationSettingsViewEpic, fetchNotificationUnreadCountEpic, fetchNotificationViewEpic, fetchRegisteredInterestsEpic, fetchOnboardingCompletedCompaniesEpic, fetchOnboardingCustomerSetupViewEpic, fetchOnboardingCustomerViewEpic, fetchOnboardingViewEpic, fetchOpExByVendorEpic, fetchOpExByVendorReportForTimeframeEpic, fetchOpExByVendorReportSummaryEpic, fetchOpExClassesViewEpic, fetchOpExEpic, fetchOpExForTimeframeClassesViewEpic, fetchOpExReportForTimeframeEpic, fetchOpExWithForecastEpic, fetchOwnerListEpic, fetchParentSubsidiaryManagementViewEpic, fetchPaymentAccountBalanceEpic, fetchPaymentAccountListEpic, fetchPaymentSourcesEpic, fetchPeopleEpic, fetchPeoplePageEpic, fetchPortfolioViewEpic, fetchPreviousBillsEpic, fetchProfitAndLossClassesViewEpic, fetchProfitAndLossEpic, fetchProfitAndLossForTimeframeClassesViewEpic, fetchProfitAndLossForTimeframeProjectViewEpic, fetchProfitAndLossForTimeframeEpic, fetchProfitAndLossProjectViewEpic, fetchProjectListEpic, fetchQBOConnectionPoolEpic, fetchRecommendationByEntityIdEpic, fetchRecommendationByEntityNameEpic, fetchRecommendationForAccountSettingsEpic, fetchRecommendationForAccountTypeEpic, fetchRecommendationsAndUpdateMerchantRecommendationsEpic, fetchRecommendedTransactionRowIndexEpic, fetchReferralsEpic, fetchReimbursementCardEpic, fetchReimbursementConfigEpic, fetchRemiAndInitializeLocalStoreEpic, fetchRemiApproversDetailsEpic, fetchRemiApproversListEpic, fetchRemiDetailEpic, fetchRemiListEpic, fetchRemiListPerTabEpic, fetchRemiSetupApproverViewEpic, fetchRemiSetupViewEpic, fetchRevenueClassesViewEpic, fetchRevenueEpic, fetchRevenueForTimeframeClassesViewEpic, fetchRevenueForTimeframeEpic, fetchRevenueWithForecastEpic, fetchReviewCompanyViewEpic, fetchReviewTransferDetailEpic, fetchRewardsPlanEpic, fetchScheduleAccruedDetailsEpic, fetchScheduleAccruedDetailsPageEpic, fetchScheduleDetailsEpic, fetchScheduleDetailsPageEpic, fetchScheduleListEpic, fetchSchedulesAccountEpic, fetchSubscriptionAddOnsEpic, fetchSubscriptionCouponsEpic, fetchSubscriptionCreateEstimateEpic, fetchSubscriptionDetailsEpic, fetchSubscriptionListEpic, fetchSubscriptionPlansEpic, fetchSubscriptionSummaryForTenantEpic, fetchSubscriptionUpdateEstimateEpic, fetchSubscriptionViewEpic, fetchSuggestedQuestionsEpic, fetchTaskDetailEpic, fetchTaskDetailPageEpic, fetchTaskGroupTemplatesEpic, fetchTaskHistoryEpic, fetchTaskListEpic, fetchTaskListPageEpic, fetchTasksCardEpic, fetchTopExEpic, fetchTransactionActivityLogEpic, fetchTransactionDetailEpic, fetchTransactionListByAccountEpic, fetchTransactionListByClassEpic, fetchTransactionListByProjectEpic, fetchTransactionListByEntityEpic, fetchTransactionsForEntityEpic, fetchTransactionsListByCategoryTypeEpic, fetchTreasuryDetailEpic, fetchTreasuryFundsEpic, fetchTreasuryHistoryEpic, fetchTreasurySetupViewEpic, fetchTreasuryStatementListEpic, fetchTreasuryTaxLetterListEpic, fetchTreasuryTransactionListEpic, updatePortfolioAllocationEpic, fetchPortfolioAllocationEpic, fetchTrendForEntityEpic, fetchUserDetailEpic, fetchUserFinancialAccountEpic, fetchUserListByTypeEpic, fetchUserRoleConfigEpic, fetchVendor1099TypeListEpic, fetchVendorAndUpdateBillLocalDataEpic, fetchVendorByNameAndParseInvoiceEpic, fetchVendorDetailsEpic, fetchVendorEpic, fetchVendorFirstReviewAttachmentsEpic, fetchVendorFirstReviewViewEpic, fetchVendorGlobalReviewViewEpic, fetchVendorsFiling1099AllEpic, fetchVendorsFiling1099DownloadEpic, fetchVendorsFiling1099ListEpic, fetchVendorsListEpic, fetchVendorsTabVendorDetailPageViewEpic, fetchVendorsTabVendorDetailsEpic, fetchVendorsTabVendorEpic, fetchVendorTabViewEpic, fetchVendorTypeListEpic, fetchZeniAccountListEpic, fetchZeniAccountsConfigEpic, fetchZeniAccountSetupViewEpic, fetchZeniAccountsPromoCardEpic, fetchZeniAccStatementListEpic, fetchZeniAccStatementPageEpic, fetchZeniUsersEpic, getOnboardingEmailGroupEpic, getOnboardingPlaidLinkTokenEpic, getPaymentAccountsEpic, getPlaidLinkTokenEpic, ignoreExpenseAutomationJEScheduleEpic, improveUsingZeniGPTEpic, initialiseExpenseAutomationReconciliationLocalDataForSelectedAccountIdEpic, initializeAccountMappingViewEpic, initializeAccountSettingsViewEpic, initializeBillPaySetupApproverViewUpdateDataEpic, initializeBillToLocalStoreEpic, initializeCardUserOnboardingLocalDataEpic, initializeCompanyHealthMetricViewLocalDataEpic, initializeDynamicFormEpic, initializeEditPersonEpic, initializeExpenseAutomationJeScheduleLocalDataEpic, initializeInternationalWireLocalDataEpic, initializeIntlVerificationFormEpic, initializeMyProfileLocalDataEpic, initializeOnboardingCustomerViewUpdateDataEpic, initializeRemiSetupApproverViewUpdateDataEpic, initializeRemiToLocalStoreEpic, initializeScheduleAccruedDetailLocalDataEpic, initializeScheduleDetailLocalDataEpic, initializeSubscriptionLocalDataEpic, initializeTaskToLocalStoreEpic, initializeTransactionDetailLocalDataEpic, initializeVendorAddressEpic, initiateChargeCardRepaymentEpic, invitePeopleEpic, inviteZeniPeopleEpic, issueChargeCardEpic, lockChargeCardEpic, lockChargeCardsEpic, markAsCompleteScheduleDetailEpic, markTransactionAsNotMiscategorizedEpic, notifyMeForFeatureEpic, parallelFetchAccountTransactionListEpic, parallelFetchClassTransactionListEpic, parallelFetchProjectTransactionListEpic, parallelFetchEntityTransactionListEpic, parallelFetchTransactionListByCategoryTypeEpic, parseInvoiceToBillEpic, parseReceiptsToRemiEpic, peopleSaveUpdatesEpic, pushToastNotificationEpic, refreshExpenseAutomationCurrentTabEpic, refreshIntegrationsDataEpic, rejectVendorGlobalReviewEpic, resendCardInviteEpic, resendInviteEpic, resendOtpEpic, resendVerifyDeviceOTPEpic, resendReferralInviteEpic, resetTransactionVendorLocalDataEpic, resetVendorDetailLocalDataEpic, resetVendorsTabVendorDetailLocalDataEpic, retryBankAccountConnectionEpic, retryBankAccountConnectionForOnboardingEpic, retryExpenseAutomationJEScheduleEpic, retryOrRefundBillEpic, validateBillsBulkActionEpic, reviewDraftRemisBulkActionEpic, reviewExpenseAutomationFluxAnalysisViewEpic, revokeCardInviteEpic, revokeChargeCardsInviteEpic, saveAccountMappingViewEpic, saveAccountSettingsViewEpic, saveAPIKeyConnectionEpic, saveBillDetailEpic, saveBillPaySetupApproverViewUpdatesEpic, saveCardOnboardingUserDetailsEpic, saveCompanyBillingAddressEpic, saveCompanyHealthMetricByIdEpic, saveCompanyMonthEndReportEpic, saveCompanyPassportDetailsEpic, saveConnectorCredentialsEpic, saveCreditAgentMacroEpic, saveExpenseAutomationReconciliationDetailsEpic, saveExpenseAutomationReconciliationReviewEpic, saveExternalConnectionEpic, saveMagicLinkBankAccountEpic, saveNewAddressEpic, saveNotificationSettingsEpic, saveOAuthConnectionEpic, saveOnboardingCustomerCompletedStatusEpic, saveOnboardingCustomerNotesEpic, saveOnboardingCustomerViewUpdatesEpic, saveRealTimeApprovalEpic, saveReasonForAuditRuleEpic, saveRemiDetailEpic, saveRemiSetupApproverViewUpdatesEpic, saveScheduleAccruedDetailsEpic, saveScheduleDetailsEpic, saveSubscriptionNotesUpdatesEpic, saveSubscriptionUpdatesEpic, saveTaskDetailEpic, saveTransactionDetailEpic, saveTransactionVendorEpic, saveVendorDetailsViewEpic, saveVendorEpic, saveVendorFirstReviewViewEpic, saveVendorsTabVendorEpic, scheduleTenantCreditScoreCronEpic, sendCompanyMonthEndReportEpic, sendOnboardingCustomerViewInviteEpic, sendOtpEpic, sendReferralInviteEpic, statementCloseDayEpic, stopSubmitEpic, stopSubmitQuestionEpic, submitDraftBillsBulkActionEpic, submitDraftRemisBulkActionEpic, submitExpressPayEpic, submitIntlVerificationEpic, submitQuestionEpic, toggleReportUIOptionForecastModeEpic, transferMoneyEpic, treasuryTransferMoneyEpic, triggerAiAccountantJobEpic, triggerReviewTabRefetchEpic, unlinkPaymentAccountEpic, unlockChargeCardEpic, unlockChargeCardsEpic, updateAccruedJESchedulesEpic, updateAddressEpic, updateAmountsInScheduleAccruedDetailEpic, updateAmountsInScheduleDetailEpic, updateAutoTransferRuleEpic, updateBusinessVerificationDetailsEpic, updateCardProfileEpic, updateChargeCardDetailEpic, updateChargeCardLimitEpic, updateChargeCardNameEpic, updateChargeCardsLimitEpic, updateAccountingClassesEnabledEpic, updateCompanyDetailsEpic, updateCompanyOfficerEpic, updateCompanyPassportLocalStoreDataEpic, updateDashboardLayoutEpic, updateDebitCardPinAttemptEpic, updateDepositAccountEpic, updateExpenseAutomationReconciliationBalanceLocalDataEpic, updateFileNameEpic, updateFilesMetadataEpic, updateJESchedulesEpic, updateMappedCashAccountEpic, updateMileageDetailsEpic, updateMyProfileEpic, updateNetBurnOrIncomeStoryCardSettingsEpic, updateNotificationViewAllNotificationsStatusEpic, updateNotificationViewNotificationStatusEpic, updateOnboardingCustomerViewCompleteStatusEpic, updateOnboardingCustomerViewDashboardLoadedEpic, updateOnboardingCustomerViewEpic, updateOnboardingCustomerViewLocalStoreDataEpic, updateOnboardingPaymentAccountLoginStatusEpic, updateOnboardingPaymentAccountStatusEpic, updatePaymentAccountEpic, updatePaymentAccountLoginStatusEpic, updatePaymentAccountStatusEpic, updatePhysicalChargeCardAttemptEpic, updatePrimaryContactEpic, updatePrimaryFundingAccountEpic, updateQBOConnectionPoolExternalConnectionEpic, updateReferViewedEpic, updateRemiSetupViewLocalStoreDataEpic, updateReportUIOptionCOABalancesRangeEpic, updateReportUIOptionIsCompareModeEpic, updateReportUIOptionIsCompareModeOnEpic, updateReportUIOptionThisPeriodEpic, updateReportUIOptionTimeFrameEpic, updateSectionAccountsViewEpic, updateSectionClassesViewEpicV2, updateSectionProjectViewEpic, updateSelectedVendorForCreateFlowEpic, updateSetupViewLocalStoreDataEpic, updateTaskFromListViewEpic, updateTaskGroupNameEpic, fetchCannedResponsesEpic, saveCannedResponseEpic, deleteCannedResponseEpic, updateTransactionDetailEpic, updateTreasuryVideoViewedEpic, updateVendorContactEpic, uploadAccountStatementEpic, uploadMissingAttachmentSuccessEpic, uploadMissingReceiptSuccessEpic, uploadTransactionReceiptSuccessEpic, vendorFiling1099UploadDetailsSaveEpic, verifyOtpEpic, verifyUserEpic, waitForBillDetailThenInitializeLocalStoreEpic, waitForForecastListThenFetchNetBurnOrIncomeWithForecastEpic, waitForForecastListThenFetchOpExWithForecastEpic, waitForForecastListThenFetchRevenueWithForecastEpic, waitForMerchantRecommendationFetchThenUpdateRecommendationInMerchantEpic, waitForVendorByIdThenSaveBillUpdatetoLocalStoreEpic, waitForVendorByNameThenParsetoLocalStoreEpic, waitForVendorByNameThenUpdateBillDetailEpic, waitForVendorRecommendationFetchThenUpdateRecommendationInBillEpic, wiseRedirectEpic);
589
+ const combinedEpics = combineEpics(acceptBillPayTermsEpic, acceptBillPayUpdatedTermsEpic, acceptChargeCardTermsEpic, acceptEmployeeRemiTermsEpic, acceptMasterTOSEpic, acceptRemiTermsEpic, acceptTreasuryTermsEpic, acceptZeniAccountTermsEpic, addCardPaymentSourceEpic, approveOAuthConsentEpic, approveOrRejectBillEpic, approveOrRejectBillsBulkActionEpic, approveOrRejectRemiEpic, approveOrRejectRemisBulkActionEpic, approveVendorGlobalReviewEpic, archiveTaskEpic, backgroundRefetchReviewTabEpic, bulkUpdateTaskListEpic, cancelAiAccountantOnboardingEpic, cancelAndDeleteBillEpic, cancelAndDeleteRemiEpic, cancelOrDeleteBillsBulkActionEpic, cancelOrDeleteRemisBulkActionEpic, cancelScheduleAccruedJournalEntryEpic, changeZeniPersonRolesEpic, checkDepositEpic, clearAllEpic, closeChargeCardEpic, closeChargeCardsEpic, companyManagementSavePendingUpdatesEpic, companyManagementSaveUpdatesEpic, confirmCardSetupIntentEpic, convertAmountToHomeCurrencyEpic, createAddressEpic, createAutoTransferRuleEpic, createBankAccountEpic, createCardSetupIntentEpic, createCheckingAccountEpic, createCompanyAddressEpic, createCompanyOfficersEpic, createCompanyUserAddressEpic, createGlobalMerchantEpic, createInternationalBankAccountEpic, createNewSchedulesAccruedEpic, createNewSchedulesEpic, createNewTaskGroupEpic, createPaymentInstrumentEpic, createSessionAndSubmitEpic, createSessionEpic, createTagEpic, createTaskFromTaskGroupTemplateEpic, createUserBankAccountEpic, deleteAccountStatementEpic, deleteAutoTransferRuleEpic, excludeAccountFromReconciliationEpic, includeAccountInReconciliationEpic, deleteBankAccountEpic, deleteBillEpic, deleteChatSessionEpic, deleteConnectionEpic, deleteBillPayApprovalRuleEpic, deleteFileEpic, deleteFileListEpic, deleteInternationalBankAccountEpic, deletePaymentInstrumentEpic, deletePersonEpic, deleteRemiApprovalRuleEpic, deleteRemiEpic, deleteScheduleAccruedDetailEpic, deleteScheduleDetailEpic, deleteTagEpic, deleteTaskEpic, snoozeTaskEpic, unsnoozeTaskEpic, deleteTaskGroupEpic, deleteTransactionAttachmentEpic, deleteUserBankAccountEpic, doMagicLinkSignInEpic, doSignInEpic, doSignOutEpic, sendEmailMagicLinkToUserEpic, sessionHeartbeatEpic, verifyDeviceWithTwoFAEpic, downloadAccountingProviderAttachmentEpic, dragNDropTasksEpic, enableChargeCardAutoPayEpic, enableSetupEpic, establishOnboardingPlaidConnectionEpic, establishPlaidConnectionEpic, expressInterestChargeCardEpic, fetchAccountListEpic, fetchAccountListForAccountTypesEpic, fetchAccountSettingsListForAccountTypesEpic, fetchAccruedScheduleListEpic, fetchActiveTenantEpic, fetchAddressEpic, fetchAiAccountantCustomersEpic, fetchAiAccountantJobsEpic, fetchAllCockpitViewsEpic, fetchAllExpenseAutomationTabsEpic, fetchAllPeopleRequiredViewsEpic, fetchAllTagsEpic, fetchAllTaskGroupsEpic, fetchAllTenantsEpic, fetchAndUpdateVendorRecommendationsEpic, fetchAggregatedReportEpic, fetchApAgingDetailEpic, fetchApAgingEpic, fetchArAgingDetailEpic, fetchArAgingEpic, fetchAuditReportGroupViewEpic, fetchAuditRuleGroupViewEpic, fetchAutoTransferReviewDetailEpic, fetchAutoTransferRuleHistoryEpic, fetchAutoTransferRulesEpic, fetchBalanceSheetEpic, fetchBalanceSheetForTimeframeEpic, fetchBankAccountsListEpic, fetchBankConnectionsViewEpic, fetchBankCountryNameByIbanEpic, fetchBankNameByRoutingEpic, fetchBankNameBySwiftEpic, fetchBillAndInitializeLocalStoreEpic, fetchBillDetailEpic, fetchBillingAccountsListEpic, fetchBillListEpic, fetchBillListPerTabEpic, fetchBillPayApproversDetailsEpic, fetchBillPayApproversListEpic, fetchBillPayCardEpic, fetchBillPayConfigEpic, fetchBillPaySetupApproverViewEpic, fetchBillPaySetupViewEpic, fetchCardBalanceEpic, archiveCardPolicyEpic, createCardPolicyTemplateEpic, extractPolicyDocumentEpic, fetchCardPolicyDetailEpic, fetchCardPolicyListEpic, fetchCardPolicyMccCategoriesEpic, fetchCardPolicyVendorOptionsEpic, fetchCardProfilesEpic, updateCardPolicyEpic, fetchCashbackDetailEpic, fetchCashBalanceEpic, fetchCashFlowEpic, fetchCashFlowForTimeframeEpic, fetchCashInCashOutEpic, fetchCashPositionEpic, fetchChargeCardConfigEpic, fetchChargeCardDetailEpic, fetchChargeCardDetailPageEpic, fetchChargeCardListEpic, fetchChargeCardListPageEpic, fetchChargeCardPaymentPageEpic, fetchChargeCardRepaymentDetailEpic, fetchChargeCardPaymentHistoryEpic, fetchChargeCardSetupViewEpic, fetchChargeCardStatementListEpic, fetchChargeCardTransactionAttachmentsEpic, fetchChargeCardTransactionListEpic, fetchChargeCardTransactionStatisticsEpic, fetchChargeCardsRecurringExpensesEpic, fetchChatHistoryEpic, fetchChatSessionsForUserEpic, fetchClassListEpic, fetchCollaborationAuthTokenEpic, fetchCompanyBillingAddressEpic, fetchCompanyConfigEpic, fetchCompanyHealthMetricConfigEpic, fetchCompanyHealthMetricViewEpic, fetchCompanyManagementViewEpic, fetchCompanyMetaDataEpic, fetchCompanyMonthEndReportHistoricDataEpic, fetchCompanyMonthEndReportHistoricDatesEpic, fetchCompanyMonthEndReportTemplatesEpic, fetchCompanyMonthEndReportViewEpic, fetchCompanyOnboardingViewEpic, fetchCompanyPassportViewEpic, fetchCompanyPortfolioViewEpic, fetchCompanyTaskManagerViewEpic, fetchTaskManagerMetricsEpic, fetchCreditAccountEpic, fetchCreditAccountRepaymentEpic, fetchCreditAgentAccessEpic, fetchCreditAgentMacroEpic, fetchCurrencyConversionValueEpic, fetchDashboardEpic, fetchDashboardLayoutEpic, fetchDebitCardSummaryEpic, fetchDepositAccountDetailEpic, fetchDepositAccountEpic, fetchDepositAccountHistoryEpic, fetchDepositAccountLimitEpic, fetchDepositAccountListEpic, fetchDepositAccountListForCardsEpic, fetchDepositAccountTransactionListEpic, fetchDownloadSchedulesEpic, fetchDuplicateBillPayReviewEpic, fetchDuplicateReimbursementEpic, fetchEditBillDetailPageEpic, fetchEditRemiDetailPageEpic, fetchEligibleActionsForBillEpic, fetchEntityAutoCompleteEpic, fetchEntityHistoryEpic, fetchEntityRecommendationsByTransactionIdEpic, fetchExcludedResourcesEpic, fetchExpenseAutomationFluxAnalysisViewEpic, fetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataEpic, fetchExpenseAutomationJeSchedulesEpic, fetchExpenseAutomationJESchedulesPageEpic, fetchExpenseAutomationMarkTransactionAsNotMiscategorizedEpic, fetchExpenseAutomationMissingReceiptsEpic, bulkUploadReceiptsEpic, confirmBulkUploadMatchEpic, fetchBulkUploadBatchDetailsEpic, fetchMultipleBatchDetailsEpic, fetchMoreBatchDetailsEpic, fetchBulkUploadBatchesEpic, fetchCompletedTransactionsEpic, refetchCompletedTransactionsOnBulkUploadSortEpic, bulkUploadAutomatchingTimeoutEpic, bulkUploadMatchResultToastEpic, pollBulkUploadBatchStatusEpic, pusherBatchStatusCompletionEpic, restoreBulkUploadAutomatchingOnMountEpic, searchTransactionsForManualMatchEpic, fetchExpenseAutomationReconciliationsViewEpic, fetchExpenseAutomationSaveTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationViewEpic, fetchExpenseAutomationUpdateTransactionCategorizationEpic, fetchExpenseTrendEpic, fetchExpressPayInitialDetailsEpic, fetchExternalConnectionsEpic, fetchFileEpic, fetchFileListEpic, fetchFinanceStatementEpic, fetchForecastListEpic, initiateReportsClassViewRefetchingEpic, reportsResyncEpic, fetchGlobalMerchantAutoCompleteViewEpic, fetchGlobalMerchantRecommendationEpic, fetchIncomeTrendEpic, fetchInsightsCardEpic, fetchInternationalWireDynamicFormEpic, fetchIntlVerificationFormEpic, fetchIssueCardPageEpic, fetchMagicLinkBankNameByRoutingEpic, fetchMagicLinkBankNameBySwiftEpic, fetchMagicLinkBillEpic, fetchMagicLinkTenantEpic, fetchManagementViewEpic, fetchMerchantListEpic, fetchMonthClosePerformanceTrendEpic, fetchMonthEndCloseChecksEpic, fetchMyProfileEpic, fetchMyProfileViewEpic, fetchNetBurnOrIncomeClassesViewEpic, fetchNetBurnOrIncomeEpic, fetchNetBurnOrIncomeForTimeframeClassesViewEpic, fetchNetBurnOrIncomeForTimeframeEpic, fetchNetBurnOrIncomeStoryCardEpic, fetchNetBurnOrIncomeWithForecastEpic, fetchNotificationSettingsEpic, fetchNotificationSettingsViewEpic, fetchNotificationUnreadCountEpic, fetchNotificationViewEpic, fetchRegisteredInterestsEpic, fetchOnboardingCompletedCompaniesEpic, fetchOnboardingCustomerSetupViewEpic, fetchOnboardingCustomerViewEpic, fetchOnboardingViewEpic, fetchOpExByVendorEpic, fetchOpExByVendorReportForTimeframeEpic, fetchOpExByVendorReportSummaryEpic, fetchOpExClassesViewEpic, fetchOpExEpic, fetchOpExForTimeframeClassesViewEpic, fetchOpExReportForTimeframeEpic, fetchOpExWithForecastEpic, fetchOwnerListEpic, fetchParentSubsidiaryManagementViewEpic, fetchPaymentAccountBalanceEpic, fetchPaymentAccountListEpic, fetchPaymentSourcesEpic, fetchPeopleEpic, fetchPeoplePageEpic, fetchPortfolioViewEpic, fetchPreviousBillsEpic, fetchProfitAndLossClassesViewEpic, fetchProfitAndLossEpic, fetchProfitAndLossForTimeframeClassesViewEpic, fetchProfitAndLossForTimeframeProjectViewEpic, fetchProfitAndLossForTimeframeEpic, fetchProfitAndLossProjectViewEpic, fetchProjectListEpic, fetchQBOConnectionPoolEpic, fetchRecommendationByEntityIdEpic, fetchRecommendationByEntityNameEpic, fetchRecommendationForAccountSettingsEpic, fetchRecommendationForAccountTypeEpic, fetchRecommendationsAndUpdateMerchantRecommendationsEpic, fetchRecommendedTransactionRowIndexEpic, fetchReferralsEpic, fetchReimbursementCardEpic, fetchReimbursementConfigEpic, fetchRemiAndInitializeLocalStoreEpic, fetchRemiApproversDetailsEpic, fetchRemiApproversListEpic, fetchRemiDetailEpic, fetchRemiListEpic, fetchRemiListPerTabEpic, fetchRemiSetupApproverViewEpic, fetchRemiSetupViewEpic, fetchRevenueClassesViewEpic, fetchRevenueEpic, fetchRevenueForTimeframeClassesViewEpic, fetchRevenueForTimeframeEpic, fetchRevenueWithForecastEpic, fetchReviewCompanyViewEpic, fetchReviewTransferDetailEpic, fetchRewardsPlanEpic, fetchScheduleAccruedDetailsEpic, fetchScheduleAccruedDetailsPageEpic, fetchScheduleDetailsEpic, fetchScheduleDetailsPageEpic, fetchScheduleListEpic, fetchSchedulesAccountEpic, fetchSubscriptionAddOnsEpic, fetchSubscriptionCouponsEpic, fetchSubscriptionCreateEstimateEpic, fetchSubscriptionDetailsEpic, fetchSubscriptionListEpic, fetchSubscriptionPlansEpic, fetchSubscriptionSummaryForTenantEpic, fetchSubscriptionUpdateEstimateEpic, fetchSubscriptionViewEpic, fetchSuggestedQuestionsEpic, fetchTaskDetailEpic, fetchTaskDetailPageEpic, fetchTaskGroupTemplatesEpic, fetchTaskHistoryEpic, fetchTaskListEpic, fetchTaskListPageEpic, fetchTasksCardEpic, fetchTopExEpic, fetchTransactionActivityLogEpic, fetchTransactionDetailEpic, fetchTransactionListByAccountEpic, fetchTransactionListByClassEpic, fetchTransactionListByProjectEpic, fetchTransactionListByEntityEpic, fetchTransactionsForEntityEpic, fetchTransactionsListByCategoryTypeEpic, fetchTreasuryDetailEpic, fetchTreasuryFundsEpic, fetchTreasuryHistoryEpic, fetchTreasurySetupViewEpic, fetchTreasuryStatementListEpic, fetchTreasuryTaxLetterListEpic, fetchTreasuryTransactionListEpic, updatePortfolioAllocationEpic, fetchPortfolioAllocationEpic, fetchTrendForEntityEpic, fetchUserDetailEpic, fetchUserFinancialAccountEpic, fetchUserListByTypeEpic, fetchUserRoleConfigEpic, fetchVendor1099TypeListEpic, fetchVendorAndUpdateBillLocalDataEpic, fetchVendorByNameAndParseInvoiceEpic, fetchVendorDetailsEpic, fetchVendorEpic, fetchVendorFirstReviewAttachmentsEpic, fetchVendorFirstReviewViewEpic, fetchVendorGlobalReviewViewEpic, fetchVendorsFiling1099AllEpic, fetchVendorsFiling1099DownloadEpic, fetchVendorsFiling1099ListEpic, fetchVendorsListEpic, fetchVendorsTabVendorDetailPageViewEpic, fetchVendorsTabVendorDetailsEpic, fetchVendorsTabVendorEpic, fetchVendorTabViewEpic, fetchVendorTypeListEpic, fetchZeniAccountListEpic, fetchZeniAccountsConfigEpic, fetchZeniAccountSetupViewEpic, fetchZeniAccountsPromoCardEpic, fetchZeniAccStatementListEpic, fetchZeniAccStatementPageEpic, fetchZeniUsersEpic, getOnboardingEmailGroupEpic, getOnboardingPlaidLinkTokenEpic, getPaymentAccountsEpic, getPlaidLinkTokenEpic, ignoreExpenseAutomationJEScheduleEpic, improveUsingZeniGPTEpic, initialiseExpenseAutomationReconciliationLocalDataForSelectedAccountIdEpic, initializeAccountMappingViewEpic, initializeAccountSettingsViewEpic, initializeBillPaySetupApproverViewUpdateDataEpic, initializeBillToLocalStoreEpic, initializeCardUserOnboardingLocalDataEpic, initializeCompanyHealthMetricViewLocalDataEpic, initializeDynamicFormEpic, initializeEditPersonEpic, initializeExpenseAutomationJeScheduleLocalDataEpic, initializeInternationalWireLocalDataEpic, initializeIntlVerificationFormEpic, initializeMyProfileLocalDataEpic, initializeOnboardingCustomerViewUpdateDataEpic, initializeRemiSetupApproverViewUpdateDataEpic, initializeRemiToLocalStoreEpic, initializeScheduleAccruedDetailLocalDataEpic, initializeScheduleDetailLocalDataEpic, initializeSubscriptionLocalDataEpic, initializeTaskToLocalStoreEpic, initializeTransactionDetailLocalDataEpic, initializeVendorAddressEpic, initiateChargeCardRepaymentEpic, invitePeopleEpic, inviteZeniPeopleEpic, issueChargeCardEpic, lockChargeCardEpic, lockChargeCardsEpic, markAsCompleteScheduleDetailEpic, markTransactionAsNotMiscategorizedEpic, notifyMeForFeatureEpic, parallelFetchAccountTransactionListEpic, parallelFetchClassTransactionListEpic, parallelFetchProjectTransactionListEpic, parallelFetchEntityTransactionListEpic, parallelFetchTransactionListByCategoryTypeEpic, parseInvoiceToBillEpic, parseReceiptsToRemiEpic, peopleSaveUpdatesEpic, pushToastNotificationEpic, refreshExpenseAutomationCurrentTabEpic, refreshIntegrationsDataEpic, rejectVendorGlobalReviewEpic, resendCardInviteEpic, resendInviteEpic, resendOtpEpic, resendVerifyDeviceOTPEpic, resendReferralInviteEpic, resetTransactionVendorLocalDataEpic, resetVendorDetailLocalDataEpic, resetVendorsTabVendorDetailLocalDataEpic, retryBankAccountConnectionEpic, retryBankAccountConnectionForOnboardingEpic, retryExpenseAutomationJEScheduleEpic, retryOrRefundBillEpic, validateBillsBulkActionEpic, reviewDraftRemisBulkActionEpic, reviewExpenseAutomationFluxAnalysisViewEpic, revokeCardInviteEpic, revokeChargeCardsInviteEpic, saveAccountMappingViewEpic, saveAccountSettingsViewEpic, saveAPIKeyConnectionEpic, saveBillDetailEpic, saveBillPaySetupApproverViewUpdatesEpic, saveCardOnboardingUserDetailsEpic, saveCompanyBillingAddressEpic, saveCompanyHealthMetricByIdEpic, saveCompanyMonthEndReportEpic, saveCompanyPassportDetailsEpic, saveConnectorCredentialsEpic, saveCreditAgentMacroEpic, saveExpenseAutomationReconciliationDetailsEpic, saveExpenseAutomationReconciliationReviewEpic, saveExternalConnectionEpic, saveMagicLinkBankAccountEpic, saveNewAddressEpic, saveNotificationSettingsEpic, saveOAuthConnectionEpic, saveOnboardingCustomerCompletedStatusEpic, saveOnboardingCustomerNotesEpic, saveOnboardingCustomerViewUpdatesEpic, saveRealTimeApprovalEpic, saveReasonForAuditRuleEpic, saveRemiDetailEpic, saveRemiSetupApproverViewUpdatesEpic, saveScheduleAccruedDetailsEpic, saveScheduleDetailsEpic, saveSubscriptionNotesUpdatesEpic, saveSubscriptionUpdatesEpic, saveTaskDetailEpic, saveTransactionDetailEpic, saveTransactionVendorEpic, saveVendorDetailsViewEpic, saveVendorEpic, saveVendorFirstReviewViewEpic, saveVendorsTabVendorEpic, scheduleTenantCreditScoreCronEpic, sendCompanyMonthEndReportEpic, sendOnboardingCustomerViewInviteEpic, sendOtpEpic, sendReferralInviteEpic, statementCloseDayEpic, stopSubmitEpic, stopSubmitQuestionEpic, submitDraftBillsBulkActionEpic, submitDraftRemisBulkActionEpic, submitExpressPayEpic, submitIntlVerificationEpic, submitQuestionEpic, toggleReportUIOptionForecastModeEpic, transferMoneyEpic, treasuryTransferMoneyEpic, triggerAiAccountantJobEpic, triggerReviewTabRefetchEpic, unlinkPaymentAccountEpic, unlockChargeCardEpic, unlockChargeCardsEpic, updateAccruedJESchedulesEpic, updateAddressEpic, updateAmountsInScheduleAccruedDetailEpic, updateAmountsInScheduleDetailEpic, updateAutoTransferRuleEpic, updateBusinessVerificationDetailsEpic, updateCardProfileEpic, updateChargeCardDetailEpic, updateChargeCardLimitEpic, updateChargeCardNameEpic, updateChargeCardsLimitEpic, updateAccountingClassesEnabledEpic, updateCompanyDetailsEpic, updateCompanyOfficerEpic, updateCompanyPassportLocalStoreDataEpic, updateDashboardLayoutEpic, updateDebitCardPinAttemptEpic, updateDepositAccountEpic, updateExpenseAutomationReconciliationBalanceLocalDataEpic, updateFileNameEpic, updateFilesMetadataEpic, updateJESchedulesEpic, updateMappedCashAccountEpic, updateMileageDetailsEpic, updateMyProfileEpic, updateNetBurnOrIncomeStoryCardSettingsEpic, updateNotificationViewAllNotificationsStatusEpic, updateNotificationViewNotificationStatusEpic, updateOnboardingCustomerViewCompleteStatusEpic, updateOnboardingCustomerViewDashboardLoadedEpic, updateOnboardingCustomerViewEpic, updateOnboardingCustomerViewLocalStoreDataEpic, updateOnboardingPaymentAccountLoginStatusEpic, updateOnboardingPaymentAccountStatusEpic, updatePaymentAccountEpic, updatePaymentAccountLoginStatusEpic, updatePaymentAccountStatusEpic, updatePhysicalChargeCardAttemptEpic, updatePrimaryContactEpic, updatePrimaryFundingAccountEpic, updateQBOConnectionPoolExternalConnectionEpic, updateReferViewedEpic, updateRemiSetupViewLocalStoreDataEpic, updateReportUIOptionCOABalancesRangeEpic, updateReportUIOptionIsCompareModeEpic, updateReportUIOptionIsCompareModeOnEpic, updateReportUIOptionThisPeriodEpic, updateReportUIOptionTimeFrameEpic, updateSectionAccountsViewEpic, updateSectionClassesViewEpicV2, updateSectionProjectViewEpic, updateSelectedVendorForCreateFlowEpic, updateSetupViewLocalStoreDataEpic, updateTaskFromListViewEpic, updateTaskGroupNameEpic, fetchCannedResponsesEpic, saveCannedResponseEpic, deleteCannedResponseEpic, updateTransactionDetailEpic, updateTreasuryVideoViewedEpic, updateVendorContactEpic, uploadAccountStatementEpic, uploadMissingAttachmentSuccessEpic, uploadMissingReceiptSuccessEpic, uploadTransactionReceiptSuccessEpic, vendorFiling1099UploadDetailsSaveEpic, verifyOtpEpic, verifyUserEpic, waitForBillDetailThenInitializeLocalStoreEpic, waitForForecastListThenFetchNetBurnOrIncomeWithForecastEpic, waitForForecastListThenFetchOpExWithForecastEpic, waitForForecastListThenFetchRevenueWithForecastEpic, waitForMerchantRecommendationFetchThenUpdateRecommendationInMerchantEpic, waitForVendorByIdThenSaveBillUpdatetoLocalStoreEpic, waitForVendorByNameThenParsetoLocalStoreEpic, waitForVendorByNameThenUpdateBillDetailEpic, waitForVendorRecommendationFetchThenUpdateRecommendationInBillEpic, wiseRedirectEpic);
583
590
  const rootEpic = (action$, store$, dependencies) => combinedEpics(action$, store$, dependencies).pipe(map(identity), catchError((error, source) => {
584
591
  console.error(error);
585
592
  return source;