import { HttpInterceptor, HttpRequest, HttpHandler, HttpEvent, HttpContextToken, HttpHeaders, HttpParams, HttpContext, HttpResponse } from '@angular/common/http'; import { Observable } from 'rxjs'; import * as i0 from '@angular/core'; import { Provider, EnvironmentProviders } from '@angular/core'; import { ClassTransformOptions } from 'class-transformer'; import { ClassTransformOptions as ClassTransformOptions$1 } from 'class-transformer/types/interfaces/class-transformer-options.interface'; import * as i1 from '@angular/common'; declare class ClassTransformerHttpInterceptor implements HttpInterceptor { intercept(req: HttpRequest, next: HttpHandler): Observable>; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class ClassTransformerSerializeInterceptor implements HttpInterceptor { intercept(req: HttpRequest, next: HttpHandler): Observable>; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare function provideTypedHttpClient(): (Provider | EnvironmentProviders)[]; /** * When set to truthy, request bodies will be serialized with instanceToPlain. * - true -> use default class-transformer options * - object -> use provided ClassTransformOptions * - false (default) -> no serialization */ declare const SERIALIZE_REQUEST: HttpContextToken; type Ctor = new (...args: unknown[]) => T; /** Carries the target class type across request clones. */ declare const RESPONSE_TYPE_CLASS: HttpContextToken | null>; type HeaderInit = HttpHeaders | { [header: string]: string | string[]; }; type ParamInit = HttpParams | { [param: string]: string | number | boolean | ReadonlyArray; }; type RequestOptions = { headers?: HeaderInit; params?: ParamInit; context?: HttpContext; withCredentials?: boolean; reportProgress?: boolean; responseType?: 'json'; serialize?: boolean | ClassTransformOptions$1; }; declare class TypedHttpClient { private readonly httpClient; getResponse(url: string, ctor: Ctor, options?: RequestOptions): Observable>; postResponse(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable>; putResponse(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable>; patchResponse(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable>; deleteResponse(url: string, ctor: Ctor, options?: RequestOptions): Observable>; get(url: string, ctor: Ctor, options?: RequestOptions): Observable; post(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable; put(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable; patch(url: string, body: T, ctor: Ctor, options?: RequestOptions): Observable; delete(url: string, ctor: Ctor, options?: RequestOptions): Observable; private requestResponse; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class TypedHttpClientModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } export { ClassTransformerHttpInterceptor, ClassTransformerSerializeInterceptor, RESPONSE_TYPE_CLASS, SERIALIZE_REQUEST, TypedHttpClient, TypedHttpClientModule, provideTypedHttpClient }; export type { Ctor, RequestOptions };