trash models added, first attempt for remainign issues

This commit is contained in:
IGNY8 VPS (Salman)
2026-01-12 13:39:42 +00:00
parent 28cb698579
commit 7d4d309677
20 changed files with 1084 additions and 106 deletions

View File

@@ -78,6 +78,12 @@ export interface ProcessingState {
remaining_count: number;
}
export interface CurrentProcessingResponse {
state: ProcessingState | null;
total_credits_used: number;
current_stage: number;
}
// NEW: Types for unified run_progress endpoint
export interface StageProgress {
number: number;
@@ -257,11 +263,12 @@ export const automationService = {
/**
* Get current processing state for active automation run
* Returns state with total_credits_used for real-time credits tracking
*/
getCurrentProcessing: async (
siteId: number,
runId: string
): Promise<ProcessingState | null> => {
): Promise<CurrentProcessingResponse | null> => {
const response = await fetchAPI(
buildUrl('/current_processing/', { site_id: siteId, run_id: runId })
);