import { AxiosError } from 'axios';
import Model from '@tripian/model';
/**
 * All successfully (axios response status code) resolved promises firstly handles by this function. easy.log calling.
 * If dataKey exist and httpResponse.data.success is true, httpResponse.data.data is saving  to tripian.data[dataKey]
 * @param {AxiosResponse} httpResponse axios response object
 * @param {string} dataKey
 * @returns {any} httpResponse.data axios httpResponse.data
 */
declare const handleHttpResponseSuccess: <T>(httpResponse: Model.SuccessResponse<T>, dataKey: string, lang: Model.LangCodeKey, params?: any, url?: string) => Model.DataPayload<T>;
/**
 * All failed (axios response status code) promises firstly handles by this function.
 * setting tripian.data.hasError to true
 *  easy.log calling.
 * If dataKey exist (and dataKey !== 'trip') and httpResponse.data.success is true, httpResponse.data.data is saving  to tripian.data[dataKey]
 * @param {AxiosError} errorResponse is axios error response object
 * @param {string} dataKey
 * @returns {AxiosError} errorResponse is axios error response object
 */
declare const handleHttpResponseError: (errorResponse: AxiosError<Model.ErrorResponse>, dataKey: string, params?: any) => never;
export { handleHttpResponseSuccess, handleHttpResponseError };
