/** * WebrequestClient - Advanced configuration and global interceptors */ import type { IWebrequestOptions } from './webrequest.types.js'; import type { TRequestInterceptor, TResponseInterceptor, TErrorInterceptor } from './interceptors/interceptor.types.js'; export declare class WebrequestClient { private interceptorManager; private cacheManager; private deduplicator; private defaultOptions; constructor(options?: Partial); /** * Add a global request interceptor */ addRequestInterceptor(interceptor: TRequestInterceptor): void; /** * Add a global response interceptor */ addResponseInterceptor(interceptor: TResponseInterceptor): void; /** * Add a global error interceptor */ addErrorInterceptor(interceptor: TErrorInterceptor): void; /** * Remove a request interceptor */ removeRequestInterceptor(interceptor: TRequestInterceptor): void; /** * Remove a response interceptor */ removeResponseInterceptor(interceptor: TResponseInterceptor): void; /** * Remove an error interceptor */ removeErrorInterceptor(interceptor: TErrorInterceptor): void; /** * Clear all interceptors */ clearInterceptors(): void; /** * Clear the cache */ clearCache(): Promise; /** * Execute a request with all configured features */ request(url: string | Request, options?: IWebrequestOptions): Promise; /** * Internal request execution with caching and retry */ private executeRequest; /** * Convenience method: GET request returning JSON */ getJson(url: string, options?: IWebrequestOptions): Promise; /** * Convenience method: POST request with JSON body */ postJson(url: string, data: any, options?: IWebrequestOptions): Promise; /** * Convenience method: PUT request with JSON body */ putJson(url: string, data: any, options?: IWebrequestOptions): Promise; /** * Convenience method: DELETE request */ deleteJson(url: string, options?: IWebrequestOptions): Promise; }