import { NextResponse, NextRequest } from 'next/server'; import { CmssyConfig } from '@cmssy/core'; export { CMSSY_EDIT_HEADER, CmssyCspOptions, applyCmssyCsp } from '@cmssy/core'; interface CmssyProxyCookie { name: string; value: string; options?: Omit[2], "name" | "value">; } interface CmssyProxyOptions { stripLocalePrefix?: boolean; cookies?: (request: NextRequest) => Promise | CmssyProxyCookie[]; } declare function createCmssyProxy(config: CmssyConfig, options?: CmssyProxyOptions): (request: NextRequest) => Promise; declare const cmssyProxyMatcher: string[]; declare const CMSSY_EDIT_PATH_PREFIX = "/cmssy-edit"; declare function cmssyEditRewrite(request: NextRequest, config: { draftSecret: string; }, options?: { requestHeaders?: Headers; }): Promise; declare function createCmssyEditMiddleware(config: { draftSecret: string; }): (request: NextRequest) => Promise; interface EditRequestLike { cookies: { has: (name: string) => boolean; }; nextUrl: { searchParams: { getAll: (name: string) => string[]; get: (name: string) => string | null; }; }; } declare function isCmssyEditRequest(request: EditRequestLike, config: { draftSecret: string; }): Promise; export { CMSSY_EDIT_PATH_PREFIX, type CmssyProxyCookie, type CmssyProxyOptions, cmssyEditRewrite, cmssyProxyMatcher, createCmssyEditMiddleware, createCmssyProxy, isCmssyEditRequest };