import { OpenApiConfigService, OperationObjectWithMetadata, SchemaValidationMixin } from '@rxap/open-api';
import { HttpClient } from '@angular/common/http';
import { KeyValue } from '@rxap/utilities';
import { BaseHttpDataSource, HttpDataSourceMetadata, HttpDataSourceOptions, HttpDataSourceViewer } from '@rxap/data-source/http';
import { Observable, Subject } from 'rxjs';
import * as i0 from "@angular/core";
export interface OpenApiDataSourceMetadata<PathParams = KeyValue, Body = any | null> extends Partial<HttpDataSourceMetadata<PathParams, Body>> {
    /**
     * The operation object with path and method
     */
    operation?: OperationObjectWithMetadata;
    /**
     * The index of the server object in the servers array in the open api config
     */
    serverIndex?: number;
    /**
     * The operation id
     */
    id: string;
    strict?: boolean;
}
export interface OpenApiDataSourceViewer<Parameters = any> extends HttpDataSourceViewer<any, any> {
    parameters?: Parameters;
}
export declare function RxapOpenApiDataSource(operationIdOrMetadata: string | OpenApiDataSourceMetadata, serverIndex?: number): (target: any) => void;
export interface OpenApiDataSource<Response = any, Parameters extends Record<string, any> | void = any> extends SchemaValidationMixin<Response, Parameters> {
}
export declare class OpenApiDataSource<Response = any, Parameters extends Record<string, any> | void = any> extends BaseHttpDataSource<Response> {
    private readonly openApiConfigService;
    protected readonly strict: boolean;
    protected readonly disableSchemaValidation: boolean;
    protected readonly disableValidation: boolean;
    constructor(http: HttpClient, openApiConfigService: OpenApiConfigService, metadata?: OpenApiDataSourceMetadata | null, refresh$?: Subject<HttpDataSourceOptions> | null, strict?: boolean | null, disableSchemaValidation?: boolean | null, disableValidation?: boolean | null);
    get operation(): OperationObjectWithMetadata;
    derive<D = Response>(id: string, metadata?: Partial<OpenApiDataSourceMetadata>, isolated?: boolean): OpenApiDataSource<D, Parameters>;
    connect(viewer: OpenApiDataSourceViewer<Parameters>): Observable<Response>;
    protected buildRequest(options: HttpDataSourceOptions): Observable<Response>;
    static ɵfac: i0.ɵɵFactoryDeclaration<OpenApiDataSource<any, any>, [null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }]>;
    static ɵprov: i0.ɵɵInjectableDeclaration<OpenApiDataSource<any, any>>;
}
