export interface LambdaBundlerOptions {
    appEntryPoint: string;
    outDir?: string;
    minify?: boolean;
    sourcemap?: boolean;
}
/**
 * Options for building a microservice-specific Lambda Layer bundle.
 *
 * Each microservice gets its own Lambda Layer with its own MicroserviceBundle.
 * This follows the architectural principle: One Microservice = One Lambda Layer = One DI Container.
 */
export interface MicroserviceLayerOptions {
    /**
     * Name of the microservice (e.g., 'payments', 'users')
     */
    microserviceName: string;
    /**
     * Represents the current stage or phase of a process, workflow, or operation.
     * This variable holds a descriptive string indicating the stage, which may
     * correspond to predefined steps such as "development", "production", or "testing".
     */
    stage: string;
    /**
     * Absolute path to the core bundle (out/dist/lambda/bundle.js)
     * @note: defined by each microservice directly, by common format approach; internal automatic workflow
     */
    coreBundlePath: string;
    /**
     * Absolute path to the user's application entry point
     */
    appEntryPoint: string;
    /**
     * Output directory for the microservice layer bundle
     */
    outDir?: string;
    /**
     * Whether to minify the bundle
     * @default false
     */
    minify?: boolean;
    /**
     * Whether to generate sourcemaps
     * @default false
     */
    sourcemap?: boolean;
}
export interface LambdaBundlerResult {
    handlerPath: string;
    layerPath: string;
    handlerSize: number;
    layerSize: number;
    buildDuration: number;
}
export declare const AWS_SDK_V3_EXTERNALS: string[];
export declare const AWS_CDK_EXTERNALS: string[];
export declare const NODE_BUILTINS: string[];
export declare const REACT_STACK_EXTERNALS: string[];
export declare const BUILD_TOOLS_EXTERNALS: string[];
/**
 * Find the root directory of the user's project (not the runtime package)
 * Looks for package.json that is NOT @worktif/runtime
 */
export declare function findUserProjectRoot(): string | null;
/**
 * Find index.html in user's project (not in runtime package)
 */
export declare function findIndexHtml(): string | null;
/**
 * Bundles Lambda code with proper Layer architecture
 *
 * Lambda Layer (/opt/nodejs/):
 * - node_modules/ with React, ReactDOM, React Router (peer ties)
 * - bundle.js with user's app runtime
 *
 * Lambda Handler externalizes React stack, imports from Layer
 */
export declare function bundleLambdaCode(options: LambdaBundlerOptions): LambdaBundlerResult;
export declare function findRuntimePackageRoot(basicPath?: boolean): string;
export declare function validateLambdaBundle(bundlePath: string, options?: {
    lambdaLayer?: boolean;
}): void;
export interface BundleValidationResult {
    valid: boolean;
    hasAbsolutePaths: boolean;
    absolutePaths: string[];
    bundleSize: number;
    exceedsLimit: boolean;
}
export declare function validateBundleContent(bundlePath: string): BundleValidationResult;
/**
 * Result of building a microservice layer bundle.
 */
export interface MicroserviceLayerBundleResult {
    /**
     * Path to the generated bundle file
     */
    bundlePath: string;
    /**
     * Size of the bundle in bytes
     */
    bundleSize: number;
    /**
     * Build duration in milliseconds
     */
    buildDuration: number;
    /**
     * Name of the microservice
     */
    microserviceName: string;
}
