import { Result } from "@webiny/feature/api"; import type { CmsEntry, CmsEntryValues, CmsModel } from "../../../types/index.js"; import type { EntryNotAuthorizedError, EntryPersistenceError } from "../../../domain/contentEntry/errors.js"; /** * GetRevisionsByEntryId Use Case - Fetches all revisions for a given entry ID. * Returns array of entry revisions. */ export interface IGetRevisionsByEntryIdUseCase { execute(model: CmsModel, entryId: string): Promise[], UseCaseError>>; } export interface IGetRevisionsByEntryIdUseCaseErrors { notAuthorized: EntryNotAuthorizedError; storage: EntryPersistenceError; } type UseCaseError = IGetRevisionsByEntryIdUseCaseErrors[keyof IGetRevisionsByEntryIdUseCaseErrors]; /** Retrieve all revisions of an entry. */ export declare const GetRevisionsByEntryIdUseCase: import("@webiny/di").Abstraction; export declare namespace GetRevisionsByEntryIdUseCase { type Interface = IGetRevisionsByEntryIdUseCase; type Error = UseCaseError; type Return = Promise[], UseCaseError>>; } /** * GetRevisionsByEntryIdRepository - Fetches entry revisions from storage. */ export interface IGetRevisionsByEntryIdRepository { execute(model: CmsModel, entryId: string): Promise[], RepositoryError>>; } export interface IGetRevisionsByEntryIdRepositoryErrors { storage: EntryPersistenceError; } type RepositoryError = IGetRevisionsByEntryIdRepositoryErrors[keyof IGetRevisionsByEntryIdRepositoryErrors]; export declare const GetRevisionsByEntryIdRepository: import("@webiny/di").Abstraction; export declare namespace GetRevisionsByEntryIdRepository { type Interface = IGetRevisionsByEntryIdRepository; type Error = RepositoryError; } export {};