import type { AuthContext, MeegoClient } from 'meeglesdk'; import { type CommandMeta } from './auth-policy.js'; import type { CliProfile } from '../types/config.js'; export interface RuntimeOptions { profile?: string; userKey?: string; compatAuth?: boolean; yes?: boolean; forceBatch?: boolean; } export interface GuardContext { profileName: string; profile: CliProfile; client: MeegoClient; auth: AuthContext; userKey?: string; } export interface RiskPreview { lines?: string[]; confirmPhrase?: string; targetCount?: number; } export interface GuardHooks { riskPreview?: (ctx: GuardContext) => Promise; } export declare function runGuarded(meta: CommandMeta, runtime: RuntimeOptions, action: (ctx: GuardContext) => Promise, hooks?: GuardHooks): Promise;