import type { AnyApiReferenceConfiguration, HtmlRenderingConfiguration } from '@scalar/types/api-reference';
export type { AnyApiReferenceConfiguration, HtmlRenderingConfiguration };
/**
 * Default CDN URL for the @scalar/api-reference UMD standalone bundle.
 *
 * This is the classic build that registers a global `window.Scalar` and is loaded through a plain
 * `<script src="...">` tag. It is used when the UMD bundle is selected via `cdn` or `bundle: false`.
 */
export declare const DEFAULT_CDN = "https://cdn.jsdelivr.net/npm/@scalar/api-reference";
/**
 * Default CDN URL for the @scalar/api-reference ESM standalone build (added in #9871).
 *
 * This is the default: it is loaded as a `<script type="module">`, so the browser only downloads the
 * lazy chunks the rendered page needs instead of the whole monolithic UMD bundle.
 */
export declare const DEFAULT_ESM_CDN = "https://cdn.jsdelivr.net/npm/@scalar/api-reference/esm.js";
/**
 * Render the Scalar API Reference as a complete HTML document using the CDN.
 *
 * Generates static HTML that loads the @scalar/api-reference standalone bundle
 * from a CDN and renders client-side. No server-side dependencies required.
 *
 * For server-side rendering with hydration, use the server module instead.
 */
export declare function renderApiReference(options: {
    /** The API reference configuration. */
    config: AnyApiReferenceConfiguration;
    /** Page title. Defaults to "Scalar API Reference". */
    pageTitle?: string;
    /** CDN URL for the standalone bundle. Defaults to jsDelivr. */
    cdn?: string;
    /**
     * A Content Security Policy (CSP) nonce to apply to the generated inline `<script>` and `<style>`
     * tags (and the CDN `<script>` tag).
     *
     * When set, a `<meta property="csp-nonce">` tag is also emitted so the standalone bundle can apply
     * the same nonce to the stylesheet it injects at runtime. This lets the API Reference run under a
     * strict `script-src` with no `unsafe-inline` and no `unsafe-eval`.
     *
     * Note: `style-src` still needs `'unsafe-inline'`, because the reference renders inline
     * `style="..."` attributes that a CSP nonce cannot authorize.
     */
    nonce?: string;
    /**
     * Which build to load. The modern, code-split ESM build is the default.
     *
     * Pass a URL string to load a specific ESM build, or `false` to fall back to the classic UMD
     * bundle. When set, `bundle` takes precedence over both `cdn` and the `nonce` fallback.
     *
     * When a `nonce` is set (a strict, nonce-based CSP) the UMD bundle is used by default, because the
     * ESM build's `import`-loaded chunks cannot be nonced. Pass `bundle: true` to force the ESM build
     * if your CSP uses `'strict-dynamic'`.
     */
    bundle?: string | boolean;
}, customTheme?: string): string;
/**
 * Serialize a configuration object to a JavaScript object literal string.
 *
 * Unlike `JSON.stringify`, this preserves function-valued properties (for example `onBeforeRequest`
 * or the request hooks) by emitting them as literal JavaScript source via `Function.prototype.toString()`.
 * That is what lets callbacks survive being written into an inline `<script>` tag, or across any other
 * boundary that would otherwise JSON-serialize the configuration and silently drop functions.
 *
 * Function values are trusted executable code, not untrusted configuration data. Their source
 * must be safe to embed in an inline script.
 *
 * Note: functions must be arrow functions or `function` expressions. Object method shorthand
 * (`onBeforeRequest(request) {}`) does not serialize to a valid standalone expression.
 */
export declare function serializeConfigToJs(configuration: Record<string, unknown>): string;
/**
 * The script tag(s) to load the @scalar/api-reference package from the CDN and initialize it.
 *
 * By default this loads the modern, code-split ESM build as a `<script type="module">` that imports
 * `createApiReference` directly (from `DEFAULT_ESM_CDN`), so the browser only downloads the lazy
 * chunks the page needs rather than the whole monolithic UMD bundle before it can paint.
 *
 * The classic UMD bundle — loaded via `<script src>` and `Scalar.createApiReference`, exactly as
 * before — is used instead when it is the safer choice or is explicitly requested: when a `nonce` is
 * set (see below), when a `cdn` URL is given (for example to pin a version), or when `bundle: false`.
 * Set `bundle` to `true` or a URL string to force the ESM build in those cases; `bundle` takes
 * precedence over both `cdn` and the `nonce` fallback.
 *
 * A `nonce` signals a strict, nonce-based `script-src` CSP. The ESM build pulls its chunks with native
 * `import`, which cannot carry a nonce, so those requests are blocked under such a policy unless it
 * also has `'strict-dynamic'` (or allow-lists the CDN host). The single-file UMD bundle has no such
 * follow-up requests, so it is the safe default when a `nonce` is present.
 */
export declare function getScriptTags(configuration: Record<string, unknown>, cdn?: string, nonce?: string, bundle?: string | boolean): string;
/**
 * The configuration to pass to the @scalar/api-reference package.
 */
export declare const getConfiguration: (givenConfiguration: Partial<HtmlRenderingConfiguration> | Record<string, unknown>) => Record<string, unknown>;
//# sourceMappingURL=html-rendering.d.ts.map