import type { EventEmitter } from 'node:events'; import { type ShellRunner } from '../../lib/shell.js'; import { type DevboxProvider, type ProviderActionResult, type ProviderRequestContext } from '../types.js'; import { type CredentialResolutionOptions, type ScopeConfirmationBoundary, type VercelScope } from './auth.js'; import { type VercelSandboxClient } from './client.js'; import { type VercelLifecycle, type VercelLifecycleOptions } from './lifecycle.js'; import { type VercelTerminalAdapter, type VercelTerminalResult } from './terminal.js'; import { type AppPortPrompt } from './app-port-flow.js'; export type VercelLifecycleFactory = (options: VercelLifecycleOptions) => VercelLifecycle; export type VercelConfirmation = (scope: VercelScope, request: ProviderRequestContext) => boolean | Promise; export interface VercelConfirmationBoundary { render?: (scope: VercelScope) => string; confirm: (message: string, scope: VercelScope) => boolean | Promise; } export type VercelOpener = (url: string) => void | Promise; export interface VercelProviderOptions { runner?: ShellRunner; /** Resolve the Sandbox image reference; defaults to release pin or channel. */ resolveImage?: () => Promise; lifecycle?: VercelLifecycleFactory | VercelLifecycle; lifecycleFactory?: VercelLifecycleFactory; terminal?: VercelTerminalAdapter; confirmation?: VercelConfirmation | VercelConfirmationBoundary | ScopeConfirmationBoundary; opener?: VercelOpener; stateHome?: string; client?: VercelSandboxClient; credentialOptions?: Omit; signalSource?: EventEmitter; /** Injection seam for the public app-port confirmation prompt. */ appPortPrompt?: AppPortPrompt; } /** Create the production Vercel provider without doing auth or network work. */ export declare function createVercelProvider(options?: VercelProviderOptions): DevboxProvider; declare function requireScopeConfirmation(scope: VercelScope, request: ProviderRequestContext, confirmation: VercelProviderOptions['confirmation'], renderedScope?: string): Promise; declare function mapTerminalResult(result: VercelTerminalResult): ProviderActionResult; /** Exposed for provider-focused tests without coupling them to terminal internals. */ export declare const mapVercelTerminalResult: typeof mapTerminalResult; export declare const createVercelProviderConfirmation: typeof requireScopeConfirmation; export {};