import { SiteSkeleton } from '../../api/classic/SiteApi';
import { State } from '../../shared/State';
import { ExportMetaData } from '../OpsTypes';
export type Site = {
    /**
     * Create an empty site export template
     * @returns {SiteExportInterface} an empty site export template
     */
    createSiteExportTemplate(): SiteExportInterface;
    /**
     * Read site by id
     * @param {string} siteId Site id
     * @returns {Promise<SiteSkeleton>} a promise that resolves to a site object
     */
    readSite(siteId: string): Promise<SiteSkeleton>;
    /**
     * Read all sites.
     * @returns {Promise<SiteSkeleton[]>} a promise that resolves to an array of site objects
     */
    readSites(): Promise<SiteSkeleton[]>;
    /**
     * Export a single site by id. The response can be saved to file as is.
     * @param {string} siteId Site id
     * @returns {Promise<SiteExportInterface>} Promise resolving to a SiteExportInterface object.
     */
    exportSite(siteId: string): Promise<SiteExportInterface>;
    /**
     * Export all sites. The response can be saved to file as is.
     * @returns {Promise<SiteExportInterface>} Promise resolving to a SiteExportInterface object.
     */
    exportSites(): Promise<SiteExportInterface>;
    /**
     * Update site
     * @param {string} siteId site id
     * @param {SiteSkeleton} siteData site data
     * @returns {Promise<SiteSkeleton>} a promise resolving to a site object
     */
    updateSite(siteId: string, siteData: SiteSkeleton): Promise<SiteSkeleton>;
    /**
     * Import sites
     * @param {SiteExportInterface} importData site import data
     * @param {string} siteId Optional site id. If supplied, only the site of that id is imported. Takes priority over siteUrl if both are provided.
     * @param {string} siteUrl Optional site url. If supplied, only the site of that url is imported.
     * @returns {Promise<SiteSkeleton[]>} the imported sites
     */
    importSites(importData: SiteExportInterface, siteId?: string, siteUrl?: string): Promise<SiteSkeleton[]>;
};
declare const _default: (state: State) => Site;
export default _default;
export interface SiteExportInterface {
    meta?: ExportMetaData;
    site: Record<string, SiteSkeleton>;
}
/**
 * Create an empty site export template
 * @returns {SiteExportInterface} an empty site export template
 */
export declare function createSiteExportTemplate({ state, }: {
    state: State;
}): SiteExportInterface;
/**
 * Read site by id
 * @param {string} siteId Site id
 * @returns {Promise<SiteSkeleton>} a promise that resolves to a site object
 */
export declare function readSite({ siteId, state, }: {
    siteId: string;
    state: State;
}): Promise<SiteSkeleton>;
/**
 * Read all sites.
 * @returns {Promise<SiteSkeleton[]>} a promise that resolves to an array of site objects
 */
export declare function readSites({ state, }: {
    state: State;
}): Promise<SiteSkeleton[]>;
/**
 * Export a single site by id. The response can be saved to file as is.
 * @param {string} siteId Site id
 * @returns {Promise<SiteExportInterface>} Promise resolving to a SiteExportInterface object.
 */
export declare function exportSite({ siteId, state, }: {
    siteId: string;
    state: State;
}): Promise<SiteExportInterface>;
/**
 * Export all sites. The response can be saved to file as is.
 * @returns {Promise<SiteExportInterface>} Promise resolving to a SiteExportInterface object.
 */
export declare function exportSites({ state, }: {
    state: State;
}): Promise<SiteExportInterface>;
/**
 * Update site
 * @param {string} siteId site id
 * @param {SiteSkeleton} siteData site config object
 * @returns {Promise<SiteSkeleton>} a promise that resolves to a site object
 */
export declare function updateSite({ siteId, siteData, state, }: {
    siteId: string;
    siteData: SiteSkeleton;
    state: State;
}): Promise<SiteSkeleton>;
/**
 * Import sites
 * @param {string} siteId Optional site id. If supplied, only the site of that id is imported. Takes priority over siteUrl if both are provided.
 * @param {string} siteUrl Optional site url. If supplied, only the site of that url is imported.
 * @param {SiteExportInterface} importData site import data
 * @returns {Promise<SiteSkeleton[]>} the imported sites
 */
export declare function importSites({ siteId, siteUrl, importData, state, }: {
    siteId?: string;
    siteUrl?: string;
    importData: SiteExportInterface;
    state: State;
}): Promise<SiteSkeleton[]>;
//# sourceMappingURL=SiteOps.d.ts.map