@agility/cli
Version:
Agility CLI for working with your content. (Public Beta)
69 lines (68 loc) • 2.72 kB
TypeScript
/**
* Entity-specific modified date extractors for incremental pull operations
*
* Based on analysis of all 7 entity types from Task 26.3:
* - Models: lastModifiedDate (ISO 8601)
* - Containers: lastModifiedDate (Human-readable: "03/05/2025 08:11AM")
* - Content Items: properties.modified (ISO 8601)
* - Assets: dateModified (ISO 8601)
* - Pages: properties.modified (ISO 8601)
* - Galleries: modifiedOn (ISO 8601)
* - Templates: NO MODIFIED DATE FIELDS - always requires full refresh
*/
/**
* Extract modified date from Model entity
* @param model Model entity object
* @returns ISO 8601 date string or null if not found
*/
export declare function extractModelModifiedDate(model: any): string | null;
/**
* Extract modified date from Container entity
* @param container Container entity object
* @returns ISO 8601 date string or null if not found
*/
export declare function extractContainerModifiedDate(container: any): string | null;
/**
* Extract modified date from Content Item entity
* @param contentItem Content item entity object
* @returns ISO 8601 date string or null if not found
*/
export declare function extractContentItemModifiedDate(contentItem: any): string | null;
/**
* Extract modified date from Asset entity
* @param asset Asset entity object
* @returns ISO 8601 date string or null if not found
*/
export declare function extractAssetModifiedDate(asset: any): string | null;
/**
* Extract modified date from Page entity
* @param page Page entity object
* @returns ISO 8601 date string or null if not found
*/
export declare function extractPageModifiedDate(page: any): string | null;
/**
* Extract modified date from Gallery entity
* @param gallery Gallery entity object (from assetMediaGroupings array)
* @returns ISO 8601 date string or null if not found
*/
export declare function extractGalleryModifiedDate(gallery: any): string | null;
/**
* Templates have NO modified date fields - always return null
* @param template Template entity object
* @returns Always null - templates require full refresh
*/
export declare function extractTemplateModifiedDate(template: any): string | null;
/**
* Get the appropriate date extractor function for an entity type
* @param entityType The entity type name
* @returns Date extractor function or null if no dates available
*/
export declare function getDateExtractorForEntityType(entityType: string): ((entity: any) => string | null) | null;
/**
* Entity types that support incremental pulling (have modified dates)
*/
export declare const INCREMENTAL_SUPPORTED_TYPES: string[];
/**
* Entity types that require full refresh (no modified dates)
*/
export declare const FULL_REFRESH_REQUIRED_TYPES: string[];