import Dict = NodeJS.Dict;
import { SummaryTemplate, Template } from './Templates';
import { ChildReportExecutionData } from './ExecutionData';
import { components } from './api';
export interface StoredReportData {
    reportId: string;
    variantId?: string;
    id: string;
    executionId?: string | undefined;
    tableId?: string | undefined;
    reportName: string;
    variantName?: string;
    name: string;
    description: string;
    status?: RequestStatus;
    timestamp: AsyncReportsTimestamp;
    dataProductDefinitionsPath?: string;
    dpdPathFromQuery?: boolean;
    query?: AsyncReportQueryData;
    interactiveQuery?: AsyncReportQueryData;
    url?: AsyncReportUrlData;
    type: ReportType;
    loadType?: LoadType;
    childExecutionData?: Array<ChildReportExecutionData>;
}
export interface RequestedReport extends StoredReportData {
    template: Template;
    errorMessage?: string;
    filters: ParamsConfig;
    sortBy: ParamsConfig;
}
export interface RequestedDashboard extends StoredReportData {
    metrics: {
        name: string;
    }[];
}
export type RecentlyViewedReport = StoredReportData;
export type UserReportData = RequestedReport | RecentlyViewedReport | StoredReportData | RequestedDashboard;
export interface AsyncReportUrlData {
    origin: string;
    request?: AsyncReportUrlItemData;
    report?: AsyncReportUrlItemData;
    polling?: AsyncReportUrlItemData;
}
export interface AsyncReportUrlItemData {
    pathname?: string | undefined;
    fullUrl?: string | undefined;
    search?: string;
    default?: string;
}
export interface AsyncReportQueryData {
    data: Dict<string | string[]>;
    summary: Array<Dict<string>>;
}
export interface ParamsConfig {
    data: Dict<string>;
    queryString: string;
}
export declare enum RequestStatus {
    SUBMITTED = "SUBMITTED",
    STARTED = "STARTED",
    PICKED = "PICKED",
    FINISHED = "FINISHED",
    FAILED = "FAILED",
    ABORTED = "ABORTED",
    EXPIRED = "EXPIRED",
    READY = "READY",
    ALL = "ALL"
}
export declare enum ReportType {
    REPORT = "report",
    DASHBOARD = "dashboard",
    UNAVAILABLE = "unavailable"
}
export interface AsyncReportsTimestamp {
    lastViewed?: Date;
    requested?: Date;
    completed?: Date;
    expired?: Date;
    failed?: Date;
    retried?: Date;
    aborted?: Date;
    refresh?: Date;
}
export interface AsyncSummary {
    id: string;
    template: SummaryTemplate;
    fields: Array<components['schemas']['SummaryField']>;
    data: Array<Record<string, string>>;
}
export interface FormattedUserReportData {
    id?: string | undefined;
    href?: string | undefined;
    text: string;
    reportName: string;
    description: string;
    timestamp?: string;
    tag?: string;
    status?: string | undefined;
    type: ReportType;
    summary?: {
        name: string;
        value: string;
    }[];
    interactiveSummary?: {
        name: string;
        value: string;
    }[];
    meta: meta;
}
export interface FormattedBookmarkData {
    id?: string;
    href?: string;
    text: string;
    reportName: string;
    description: string;
    timestamp?: string;
    tag?: string;
    status?: string;
    type: ReportType;
    summary?: {
        name: string;
        value: string;
    }[];
    interactiveSummary?: {
        name: string;
        value: string;
    }[];
}
export interface meta {
    reportId: string;
    id: string;
    executionId?: string | undefined;
    tableId?: string | undefined;
    status?: string | undefined;
    type: ReportType;
    requestedAt?: Date | undefined;
    dataProductDefinitionsPath?: string | undefined;
    pollingUrl?: string | undefined;
    reportUrl?: string | undefined;
    endpoint?: string;
}
export interface RequestFormData {
    dataProductDefinitionsPath: string;
    _csrf: string;
    reportId: string;
    name: string;
    reportName: string;
    description: string;
    type: string;
    pathname: string;
    origin: string;
    href: string;
    search: string;
    id: string;
    variantId?: string;
    template?: string;
    metrics?: {
        name: string;
    }[];
}
export declare enum LoadType {
    SYNC = "sync",
    ASYNC = "async",
    SCHEDULED = "scheduled"
}
export interface DefinitionData {
    reportName: string;
    reportId: string;
    id: string;
    name: string;
    description?: string;
    type: ReportType;
    reportDescription?: string;
    loadType: LoadType;
    authorised: boolean;
    isMissing?: boolean;
}
