import { Hono } from 'hono';
import { C as CompilationService } from './service-qk1aChG9.js';
import '@lokascript/framework/ir';

/**
 * HTTP/Edge Wrapper for CompilationService
 *
 * Thin Hono server exposing CompilationService over HTTP.
 * Works on Node, Deno, Bun, and Cloudflare Workers.
 *
 * Usage:
 *   import { createApp } from '@lokascript/compilation-service/http';
 *   const app = createApp();
 *   // Use with any Hono-compatible server
 *
 *   import { serve } from '@lokascript/compilation-service/http';
 *   serve({ port: 3001 }); // Starts Node server
 */

interface HttpOptions {
    /** API key for authentication (optional — skips /health) */
    apiKey?: string;
    /** CORS origin (default '*') */
    corsOrigin?: string;
    /** Port for serve() (default 3001) */
    port?: number;
    /** Pre-created service instance (skips lazy init) */
    service?: CompilationService;
    /** Enable production middleware (body limit, timeout, logger) */
    production?: boolean;
    /** Max request body in bytes (default 50KB, requires production: true) */
    maxBodyBytes?: number;
    /** Request timeout in ms (default 10000, requires production: true) */
    timeoutMs?: number;
}
/**
 * Create a Hono app wrapping CompilationService.
 * Testable without starting a server — use `app.request()`.
 */
declare function createApp(options?: HttpOptions): Hono;
/**
 * Start a Node HTTP server with the compilation service.
 * Convenience for CLI usage; for production, use createApp() with your server.
 */
declare function serve(options?: HttpOptions): Promise<void>;

export { type HttpOptions, createApp, serve };
