import type { DualDocument, GetOptions, DocumentQuery, DbOperation } from './types.ts'; /** * Gets a document by path or id * * This function retrieves a document through the routing system: * - Finds the document by path (follows redirects) or by id * - Determines if this is a direct access or redirect (for path queries) * - Returns the appropriate version (draft or current) based on options * * Redirect Detection: * - Direct access: route.id === document.path_id (accessing via canonical path) * - Redirect: route.id !== document.path_id (accessing via old/alternate path) * - ID access: always returns redirect: false * * Query Filtering: * - published: true - only return published documents * - published: false - only return unpublished documents * - published: undefined - return both published and unpublished documents (no filter) * - draft: true - include draft version in response (if exists) * - draft: false or undefined - exclude draft version from response * * @param client Database client * @param query Document query (supports path string, id number, DualDocument, Route, etc.) * @param options Get options (draft, published) * @returns DualDocument with current/draft versions and redirect flag, or null if not found */ export declare const getDualDocument: DbOperation<[DocumentQuery, GetOptions?], DualDocument | null>; //# sourceMappingURL=getDualDocument.d.ts.map