import { ActionsObservable, StateObservable } from 'redux-observable'; import { Observable } from 'rxjs'; import { RootState } from '../../rootStateTypes'; import { updateAiCardPolicyFormDraftFromUploadPlan } from '../../view/spendManagement/chargeCards/cardPolicy/createCardPolicy/createCardPolicyReducer'; import { ZeniAPI } from '../../zeniAPI'; import { updateAiCfoAnswerCardPolicyWizardPlan } from '../aiCfo/aiCfoReducer'; import { clearPolicyDocumentExtraction, fetchCardPolicyRecommendationFromUpload, updatePolicyRecommendationFromUploadFailure, updatePolicyRecommendationFromUploadSuccess } from './cardPolicyReducer'; export type ActionType = ReturnType | ReturnType | ReturnType | ReturnType | ReturnType | ReturnType; /** * Listens for `fetchCardPolicyRecommendationFromUpload` and POSTs the * just-extracted policy rules to the AI-CFO recommendation endpoint. * * On success — dispatches BOTH: * - `updatePolicyRecommendationFromUploadSuccess` (flips the * cardPolicy slice's recommendation lifecycle to `Completed`), and * - `updateAiCfoAnswerCardPolicyWizardPlan` (patches the in-flight AI * CFO answer's `CardPolicyInitialData` so the wizard can advance from * Step 1 → Step 2 in the upload variant). * * The reducer payload originally captured at kickoff (`answerId` + * `chatSessionId`) re-enters via the action so the patch can find the * right answer to merge into. */ export declare const policyRecommendationFromUploadEpic: (actions$: ActionsObservable, _state$: StateObservable, zeniAPI: ZeniAPI) => Observable;