UNPKG

@agility/cli

Version:

Agility CLI for working with your content. (Public Beta)

34 lines (33 loc) 1.31 kB
import * as mgmtApi from "@agility/management-sdk"; import { BatchProcessingResult, ContentBatchConfig } from "./util/types"; import { Logs } from "core/logs"; /****** * USAGE PATTERN: * 1. Filter content items BEFORE creating the batch processor using filterContentItemsForProcessing() * 2. Create the batch processor with pre - filtered items * 3. Call processBatches() with the filtered items * * This ensures consistent use of the new versioning logic and eliminates duplicate filtering. */ export declare class ContentBatchProcessor { private config; constructor(config: ContentBatchConfig); /** * Process content items in batches using saveContentItems API * NOTE: Content items should already be filtered by the caller using filterContentItemsForProcessing() */ processBatches(contentItems: mgmtApi.ContentItem[], logger: Logs, batchType?: string): Promise<BatchProcessingResult>; /** * Create batches of content items for bulk processing */ private createContentBatches; /** * Prepare content payloads for bulk upload API * Uses the same payload structure as individual content pusher */ private prepareContentPayloads; /** * Update content ID mappings in reference mapper */ private updateContentIdMappings; }