/** * Route invalidation for content published outside Next.js. * * The editor publishes through the P1 backend, not through this app, so nothing * in the request path tells Next.js that a route's content changed. The public * page segment is statically renderable (see create-published-page.tsx), which * means a render is cached and served again — including the `notFound()` render * cached at a path whose page did not exist yet. Publishing that page then left * the cached 404 in place for the whole revalidate window, and any CDN in front * of the app was told it could keep serving it while revalidating. * * So the editor calls this after a successful publish. It only invalidates — * the content itself is already in the backend, and re-persisting it here would * give the same page two write paths. */ import { NextResponse } from "next/server"; export { postRevalidate as POST }; /** * Dynamic segments that may render public pages, as Next.js names them for * revalidatePath: the required and the optional catch-all. An app whose * catch-all directory is neither names its own. */ export declare const DEFAULT_PUBLIC_PAGE_SEGMENTS: readonly string[]; /** * Invalidate every cached route the content at `path` can be served through. * * Shared with the publish route so the two cannot drift: a publish that * persists through this app and one that reaches the backend directly have to * invalidate the same set, or one of them serves stale pages. */ export declare function revalidatePublishedPath(path: string, publicPageSegment?: string): Promise; export declare function postRevalidate(request: Request, { publicPageSegment }?: { publicPageSegment?: string; }): Promise | NextResponse<{ status: string; }>>;