import React, { FC } from "react";
import { IExternalData } from "./externalDataInterface";
export declare function formatJSON(val: string): string;
export declare const getObjectString: (o: Record<string, any>, s: string) => Record<string, any> | undefined;
type ExternalDataProviderProps = {
    children: React.ReactNode;
};
type TestResultsType = {
    status: number;
    data: string;
};
type ColumnInput = {
    name: string;
    type?: string;
    show?: boolean;
};
type UpdateColumnOption = {
    items: ColumnInput[];
    refetchTable?: boolean;
};
export type ExternalTableTabsType = {
    menu: "data" | "setting";
    setting: "header" | "body" | "qore-apps-params" | "test-results";
};
type Props = {
    setState: React.Dispatch<React.SetStateAction<Props["state"]>>;
    state: {
        tabs: ExternalTableTabsType;
        loadingSave: boolean;
        loadingTest: boolean;
        loadingFetchData: boolean;
        loadingSaveEditColumn: boolean;
        isFetchDataError: boolean;
        isTestResultError: boolean;
        isBodyValid: boolean;
        testResults?: TestResultsType;
        externalData: IExternalData;
    };
    data: {
        tableData: Record<any, string>[];
        dataTypes: {
            icon: JSX.Element;
            value: string;
            label: string;
        }[];
    };
    action: {
        handleChangeState: (props: (draft: Props["state"]) => void) => void;
        handleSaveSetting: (data?: IExternalData) => Promise<void>;
        handleTestEndpoint: () => Promise<void>;
        handleFetchData: () => Promise<void>;
        handleUpdateColumn: (options: UpdateColumnOption) => Promise<void>;
    };
};
declare const ExternalDataContext: React.Context<Props>;
declare const ExternalDataProvider: FC<ExternalDataProviderProps>;
export { ExternalDataContext, ExternalDataProvider };
