import type { Agent, Dispatcher } from 'undici'; import type { BaseHttpClient, HttpClient, HttpClientInterceptor } from '@tramvai/http-client'; import type { TinkoffRequestOptions } from '@tramvai/tinkoff-request-http-client-adapter'; export type HttpClientFactoryOptions = TinkoffRequestOptions & { name: string; }; /** * @description * Factory of HTTP clients with minimal base settings */ export declare const HTTP_CLIENT_FACTORY: ((options: HttpClientFactoryOptions) => HttpClient) & { __type?: "base token" | undefined; }; /** * @description * Default options for factory of HTTP clients */ export declare const DEFAULT_HTTP_CLIENT_FACTORY_OPTIONS: Partial & { __type?: "base token" | undefined; }; /** * @description * Interceptors will be added to default options for factory of HTTP clients */ export declare const DEFAULT_HTTP_CLIENT_INTERCEPTORS: HttpClientInterceptor & { __type?: "multi token" | undefined; }; /** * @description * Universal HTTP client for arbitrary requests */ export declare const HTTP_CLIENT: HttpClient & { __type?: "base token" | undefined; }; /** * @description * Global HTTP and HTTPS agents for all fetch requests * @see https://undici.nodejs.org/#/docs/api/Dispatcher.md * @see https://undici.nodejs.org/#/docs/api/Agent.md */ export declare const HTTP_CLIENT_AGENT: { http: Dispatcher; https: Dispatcher; } & { __type?: "base token" | undefined; }; /** * @description * Global agent options * @see https://undici.nodejs.org/#/docs/api/Agent?id=parameter-agentoptions */ export declare const HTTP_CLIENT_AGENT_OPTIONS: Agent.Options & { __type?: "base token" | undefined; }; /** * @description * Interceptors for global agent * @see https://undici.nodejs.org/#/docs/api/Dispatcher?id=dispatchercomposeinterceptors-interceptor */ export declare const HTTP_CLIENT_AGENT_INTERCEPTORS: Dispatcher.DispatcherComposeInterceptor & { __type?: "multi token" | undefined; }; /** * @description * List of HTTP headers that are proxied from app request to all of the backend API */ export declare const API_CLIENT_PASS_HEADERS: (string & { __type?: "multi token" | undefined; }) | (string[] & { __type?: "multi token" | undefined; }); /** * @description * Internal api for app server. * Uses the value of `APP_INFO_TOKEN` from di for constructing the request address */ export declare const PAPI_SERVICE: BaseHttpClient & { __type?: "base token" | undefined; }; /** * @description * Enable or disable circuit breaker */ export declare const DISABLE_CIRCUIT_BREAKER: (false & { __type?: "base token" | undefined; }) | (true & { __type?: "base token" | undefined; }); //# sourceMappingURL=index.d.ts.map