11 lines
462 B
TypeScript
11 lines
462 B
TypeScript
import type { CreatePageInput, Page, UpdatePageInput } from './page.js';
|
|
|
|
export interface CmsRepository {
|
|
create(input: CreatePageInput): Promise<Page | undefined>;
|
|
update(id: string, patch: UpdatePageInput): Promise<Page | undefined>;
|
|
setStatus(id: string, status: 'draft' | 'published'): Promise<Page | undefined>;
|
|
findBySlug(slug: string): Promise<Page | undefined>;
|
|
findById(id: string): Promise<Page | undefined>;
|
|
listAll(): Promise<Page[]>;
|
|
}
|