import { nothing, TemplateResult } from 'lit';
import { type IRequestLog, RequestLog as CoreRequestLog } from '@api-client/core/models/RequestLog.js';
import { RequestTime } from '@api-client/core/models/RequestTime.js';
import type { ResponseRedirect } from '@api-client/core/models/ResponseRedirect.js';
import { Headers } from '@api-client/core/lib/headers/Headers.js';
import type { AssertionResult } from '@api-client/core/models/http-flows/HttpAssertion.js';
import type { AssertionError } from '@api-client/core/models/http-flows/AssertionError.js';
import ApiElement from '../ApiElement.js';
import { TabSelectionDetail } from '../../md/tabs/internals/Tabs.js';
import '../../define/http/http-log-headers.js';
import '../../define/http/http-log-body.js';
import '../../define/http/http-log-timings.js';
import '../../md/tabs/ui-tab.js';
import '../../md/tabs/ui-tabs.js';
import '../../md/divider/ui-divider.js';
export declare enum RequestLogView {
    headers = "headers",
    payload = "payload",
    preview = "preview",
    response = "response",
    timings = "timings",
    redirects = "redirects",
    assertions = "assertions"
}
/**
 * An element that renders the view for a core's `IRequestLog`.
 */
export default class RequestLog extends ApiElement {
    protected httpLogInternal?: IRequestLog | CoreRequestLog;
    /**
     * This property is set when the `httpLog` is set.
     * It always represent an instance of the `RequestLog` (or undefined) regardless of the input format.
     */
    protected effectiveLog?: CoreRequestLog;
    /**
     * The request log to render. When not set it renders nothing.
     */
    get httpLog(): IRequestLog | CoreRequestLog | undefined;
    set httpLog(value: IRequestLog | CoreRequestLog | undefined);
    /**
     * Currently rendered view.
     * @attribute
     */
    accessor view: RequestLogView;
    /**
     * Returns `true` when the request has a payload message.
     */
    get hasRequestPayload(): boolean;
    /**
     * Returns `true` when the response has a payload message.
     */
    get hasResponsePayload(): boolean;
    get hasResponse(): boolean;
    protected accessor isErrorResponse: boolean;
    protected accessor timingsData: RequestTime[] | undefined;
    protected accessor redirectsData: ResponseRedirect[] | undefined;
    /**
     * Reads the payload to the original format for both the request and the response.
     */
    protected processPayload(): Promise<void>;
    protected handleViewSelect(e: CustomEvent<TabSelectionDetail>): void;
    protected render(): TemplateResult;
    protected renderTabs(effectiveLog?: CoreRequestLog): TemplateResult;
    protected renderAssertionsBadge(effectiveLog?: CoreRequestLog): TemplateResult | typeof nothing;
    protected renderContent(effectiveLog?: CoreRequestLog): TemplateResult;
    /**
     * Renders basic information about the request:
     * - request method & URL
     * - request headers
     * - response headers
     */
    protected renderHeaders(info: CoreRequestLog): TemplateResult;
    /**
     * @returns The template for the "raw" response body view.
     */
    protected renderPayload(info: CoreRequestLog): TemplateResult;
    /**
     * @returns The template for the parsed response body view.
     */
    protected renderPreview(info: CoreRequestLog): TemplateResult;
    protected renderResponse(info: CoreRequestLog): TemplateResult;
    protected renderTimings(): TemplateResult;
    protected renderRedirects(): TemplateResult;
    protected renderRedirect(item: ResponseRedirect, index: number): TemplateResult;
    protected renderHeadersRaw(header: Headers): TemplateResult | string;
    protected _noDataTemplate(arialLabelledBy: string, id: string): TemplateResult;
    protected renderAssertions(info: CoreRequestLog): TemplateResult;
    renderAssertion(item: AssertionResult): TemplateResult;
    renderOkAssertion(description: string): TemplateResult;
    renderFailedAssertion(description: string, error: AssertionError): TemplateResult;
}
//# sourceMappingURL=RequestLog.d.ts.map