import "@sanity/types";
import { CliConfig, CliConfig as CliConfig$1, UserViteConfig } from "@sanity/cli-core";
import { ClientConfig, SanityClient } from "@sanity/client";
import { loadEnv } from "vite";
import { AssetSourceView, DefineAppInput, DefineAssetSourceViewInput, DefineMediaLibraryInput, DefinePanelViewInput, DefineTileViewInput, DefineWebWorkerInput, DefineWindowViewInput, MediaLibraryField, PanelView, TileView, ViewDeclaration, WebWorker, WindowView, defineApplication, defineApplication as unstable_defineApp, defineAssetSourceView, definePanelView, defineTileView, defineWebWorker, defineWindowView, unstable_defineMediaLibrary } from "@sanity/workbench-cli";
/**
 * @public
 */
interface GraphQLAPIConfig {
  /**
   * Suffix to use for generated filter types.
   *
   * Optional, Defaults to `Filter`.
   *
   */
  filterSuffix?: string;
  /**
   * Generation of API to deploy
   *
   * Optional, defaults to `gen3` (which is the only option, currently)
   */
  generation?: 'gen1' | 'gen2' | 'gen3';
  /**
   * ID of GraphQL API. Only (currently) required when using the `--api` flag
   * for `sanity graphql deploy`, in order to only deploy a specific API.
   */
  id?: string;
  /**
   * Whether or not to enable the GraphQL v2021-10-21 query semantics
   */
  nonNullDocumentFields?: boolean;
  /**
   * Whether or not to enable the GraphQL Playground for this API
   *
   * Optional, defaults to `true` in development mode,  `false` otherwise
   */
  playground?: boolean;
  /**
   * Name of source containing the schema to deploy, within the configured workspace
   *
   * Optional, defaults to `default` (eg the one used if no `name` is defined)
   */
  source?: string;
  /**
   * API tag for this API - allows deploying multiple different APIs to a single dataset
   *
   * Optional, defaults to `default`
   */
  tag?: string;
  /**
   * Name of workspace containing the schema to deploy
   *
   * Optional, defaults to `default` (eg the one used if no `name` is defined)
   */
  workspace?: string;
}
/**
 * @deprecated Use `defineCliConfig` instead
 * @public
 */
declare function createCliConfig(config: CliConfig$1): CliConfig$1;
/** @beta */
declare function defineCliConfig(config: CliConfig$1): CliConfig$1;
/**
 * @public
 */
interface CliApiConfig {
  dataset?: string;
  projectId?: string;
}
/**
 * @public
 */
interface CliClientOptions extends ClientConfig {
  /**
   * If no `projectId` or `dataset` is provided, `getCliClient` will try to
   * resolve these from the `sanity.cli.ts` configuration file. Use this option
   * to specify the directory to look for this file.
   */
  cwd?: string;
}
/**
 * @public
 *
 * @param options - The options to use for the client.
 * @returns A configured Sanity API client.
 */
declare const getCliClient: CliClientGetter;
type CliClientGetter = ((options?: CliClientOptions) => SanityClient) & {
  /**
   * @deprecated This is only for INTERNAL use, and should not be relied upon outside of official Sanity modules
   * @returns A token to use when constructing a client without a `token` explicitly defined, or undefined
   * @internal
   */
  __internal__getToken: () => string | undefined;
};
export { type AssetSourceView, type CliApiConfig, type CliClientOptions, type CliConfig, type DefineAppInput, type DefineAssetSourceViewInput, type DefineMediaLibraryInput, type DefinePanelViewInput, type DefineTileViewInput, type DefineWebWorkerInput, type DefineWindowViewInput, type GraphQLAPIConfig, type MediaLibraryField, type PanelView, type TileView, type UserViteConfig, type ViewDeclaration, type WebWorker, type WindowView, createCliConfig, defineApplication, defineAssetSourceView, defineCliConfig, definePanelView, defineTileView, defineWebWorker, defineWindowView, getCliClient, loadEnv, unstable_defineApp, unstable_defineMediaLibrary };
//# sourceMappingURL=index.d.ts.map