/**
 * @fileoverview Generic API client for making HTTP requests with authentication support
 */
import { type CustomAuthConfig } from '../auth';
import { type ApiClientConfig, type MockConfigArray, type RequestConfig } from './types';
export declare class ApiClient<T extends CustomAuthConfig> {
    private readonly config;
    private controller;
    private mockConfig?;
    constructor(config: ApiClientConfig<T>);
    /**
     * Sets the mock configurations for the API client.
     * @param mockConfig - Array of mock configurations.
     */
    setMockConfig(mockConfig: MockConfigArray): void;
    /**
     * Makes a GET request.
     */
    get<ResponseType>(endpoint: string, config?: RequestConfig): Promise<ResponseType>;
    /**
     * Makes a POST request.
     */
    post<ResponseType>(endpoint: string, data?: unknown, config?: RequestConfig): Promise<ResponseType>;
    /**
     * Makes a PUT request.
     */
    put<ResponseType>(endpoint: string, data?: unknown, config?: RequestConfig): Promise<ResponseType>;
    /**
     * Makes a PATCH request.
     */
    patch<ResponseType>(endpoint: string, data?: unknown, config?: RequestConfig): Promise<ResponseType>;
    /**
     * Makes a DELETE request.
     */
    delete<ResponseType>(endpoint: string, config?: RequestConfig): Promise<ResponseType>;
    /**
     * Aborts all ongoing requests.
     */
    abort(): void;
    /**
     * Sets a default header for all requests.
     */
    setDefaultHeader(key: string, value: string): void;
    /**
     * Finds a mock response that matches the request path, method, and params.
     * @param path - The API endpoint path.
     * @param method - The HTTP method.
     * @param params - The query parameters or payload.
     * @returns The mock response if a match is found, otherwise undefined.
     */
    private findMockResponse;
    /**
     * Normalizes request parameters or body into a plain object.
     * @param params - The query parameters or body.
     * @returns A plain object representation of the parameters or body.
     */
    private normalizeParams;
    /**
     * Creates a URL with query parameters.
     */
    private createUrl;
    /**
     * Handles a request by checking for a matching mock response.
     * If no mock is found, proceeds with the real API request.
     */
    private handleRequest;
    /**
     * Makes the actual HTTP request.
     */
    private makeRequest;
    /**
     * Handles the API response.
     */
    private handleResponse;
    /**
     * Handles API errors.
     */
    private handleError;
}
