import { ResponseParameters, TelegramErrorResponse } from "./types/telegram";
import { AxiosResponse, Method } from "axios";
export declare const ERROR_TELEBOT_ALREADY_RUNNING = "Telebot is already running. Terminate instance for safety.";
export declare const ERROR_TELEBOT_MAXIMUM_RETRY = "Maximum retries exceeded. Terminate instance for safety.";
export declare class TeleBotError<T = {}> extends Error {
    name: string;
    data: T;
    constructor(error: string, data?: T);
}
export declare class TelegramError extends Error {
    name: string;
    code: number;
    description: string;
    parameters?: ResponseParameters;
    constructor({ error_code, description, parameters }: TelegramErrorResponse);
}
export declare class TeleBotRequestError extends Error {
    name: string;
    request: {
        url?: string;
        method?: Method;
        data?: any;
    };
    response: TelegramErrorResponse;
    constructor(response: AxiosResponse<TelegramErrorResponse>);
}
export declare function handleTelegramResponse(error: any): any;
