import { o as MethodsRouter, l as Request, D as DefaultRequestDefinitions, R as Response, a5 as RouterOptionsType, S as ServerAdapter, i as ServerlessAdapter, q as DefaultRouterDefinitions } from '../index-CyBsO7TM.cjs';
import '@palmares/core';
import '../status-RlKnv8eR.cjs';
import '../response/utils.cjs';

declare function getErrorId(): string | undefined;
/**
 * When the user clicks on the error on the error handling page we can open the file where the bug occurred
 * on the editor. So we just call this endpoint and it will automatically open the file on the editor.
 *
 * There are some gotchas e need to be aware of:
 * 1 - The path should not clash with the user's routes, so we generate it automatically and randomized so we
 * don't have the problem of clashing route names.
 * 2 - We need to use a POST request because we need to send the file, line and column where the error occurred.
 */
declare function errorCaptureHandler(): Omit<MethodsRouter<undefined, [], [], `/${string}`, {
    post: {
        handler: (request: Request<`/${string}`, any, DefaultRequestDefinitions>) => Promise<Response<undefined, {
            status: 200;
        }>>;
        options?: RouterOptionsType<(ServerAdapter | ServerlessAdapter) & Palmares.PServerAdapter> | undefined;
    };
}, {
    [x: `/${string}`]: {
        post: {
            handler: (request: Request<`/${string}`, any, DefaultRequestDefinitions>) => Promise<Response<undefined, {
                status: 200;
            }>>;
            options?: RouterOptionsType<(ServerAdapter | ServerlessAdapter) & Palmares.PServerAdapter> | undefined;
        };
    };
}, DefaultRouterDefinitions>, "post" | "all">;

export { errorCaptureHandler, getErrorId };
