import { IProperty } from './Property.js';
import { IMultipartBody, ISafePayload } from '../lib/transformers/PayloadSerializer.js';
import { RequestUiMeta as LegacyRequestUiMeta } from './legacy/request/ArcRequest.js';
export declare const Kind = "Core#RequestUiMeta";
/**
 * URL editor meta data.
 */
export interface IUrlMeta {
    /**
     * The model generated for the URL parameters.
     */
    model?: IProperty[];
    /**
     * The query params delimiter. By default it is `&`.
     */
    delimiter?: string;
}
/**
 * Headers editor meta data.
 */
export interface IHeadersMeta {
    /**
     * The model generated for the headers editor.
     */
    model?: IProperty[];
    /**
     * Whether the source editor is opened.
     */
    source?: boolean;
}
export interface IAuthMeta {
    /**
     * The index of the selected authorization method.
     */
    selected?: number;
}
export interface IResponseUiMeta {
    /**
     * The list of activated panels in the response view.
     */
    activePanels?: string[];
    /**
     * The name of the selected response panel.
     */
    selectedPanel?: string;
}
/**
 * The body editor may produce multiple view models
 * for the UI. Each editor can store it's data in here
 * to restore it after opening a request,
 */
export interface IBodyMetaModel {
    /**
     * The id of the editor. Each editor in API Client has own id.
     */
    type: string;
    /**
     * Generated view model.
     */
    viewModel: (IProperty | ISafePayload | IMultipartBody | IRawBody | IUrlEncodedBodyMeta)[];
}
export interface IUrlEncodedBodyMeta {
    /**
     * Whether the body should be automatically encoded before sending the value.
     */
    autoEncode?: boolean;
    /**
     * The model generated for the body editor.
     */
    model?: IProperty[];
}
/**
 * Body editor meta data.
 */
export interface IBodyMeta {
    /**
     * The model generated for the body editor.
     */
    model?: IBodyMetaModel[];
    /**
     * The selected editor
     */
    selected?: string;
}
export interface IRawBody {
    /**
     * The last used body value.
     */
    value: string;
    /**
     * True when the generator was used to build the value
     */
    isGenerator?: boolean;
    /**
     * The schema for the generator. Work in progress.
     */
    generatorSchema?: unknown;
}
/**
 * UI configuration for the request.
 */
export interface IRequestUiMeta {
    kind?: typeof Kind;
    /**
     * Body editor metadata.
     */
    body?: IBodyMeta;
    /**
     * URL editor metadata.
     */
    url?: IUrlMeta;
    /**
     * Headers editor metadata.
     */
    headers?: IHeadersMeta;
    /**
     * Authorization editor meta.
     */
    authorization?: IAuthMeta;
    /**
     * The currently selected editor in the request editor UI.
     */
    selectedEditor?: string;
    /**
     * Optional configuration of the response view
     */
    response?: IResponseUiMeta;
}
export declare class RequestUiMeta {
    kind: string;
    /**
     * Body editor metadata.
     */
    body?: IBodyMeta;
    /**
     * URL editor metadata.
     */
    url?: IUrlMeta;
    /**
     * Headers editor metadata.
     */
    headers?: IHeadersMeta;
    /**
     * Authorization editor meta.
     */
    authorization?: IAuthMeta;
    /**
     * The currently selected editor in the request editor UI.
     */
    selectedEditor?: string;
    /**
     * Optional configuration of the response view
     */
    response?: IResponseUiMeta;
    static fromLegacy(old: LegacyRequestUiMeta): RequestUiMeta;
    /**
     * @param input The project item definition used to restore the state.
     */
    constructor(input?: string | IRequestUiMeta);
    /**
     * Creates a new object clearing anything that is so far defined.
     */
    new(init: IRequestUiMeta): void;
    toJSON(): IRequestUiMeta;
}
//# sourceMappingURL=RequestUiMeta.d.ts.map