import type { ErrorObject } from 'ajv';
import type { ValidationError } from 'joi';
import { type ApiErrorSchema, UnleashError } from './unleash-error';
type ValidationErrorDescription = {
    description?: string;
    message: string;
    path?: string;
};
declare class BadDataError extends UnleashError {
    statusCode: number;
    details: ValidationErrorDescription[];
    constructor(message: string, errors?: [ValidationErrorDescription, ...ValidationErrorDescription[]]);
    toJSON(): ApiErrorSchema;
}
export default BadDataError;
export declare const fromOpenApiValidationError: (requestBody: object) => (validationError: ErrorObject) => ValidationErrorDescription;
export declare const fromOpenApiValidationErrors: (requestBody: object, validationErrors: [ErrorObject, ...ErrorObject[]]) => BadDataError;
export declare const fromJoiError: (err: ValidationError) => BadDataError;
//# sourceMappingURL=bad-data-error.d.ts.map