/** * Status Command Types * * Type definitions for the status command working context, * implementation session display, and dashboard analytics. */ /** * Status command options from Commander */ export interface StatusOptions { /** Output as JSON */ json?: boolean; /** Output as TOON format */ toon?: boolean; /** Show full project dashboard with analytics */ dashboard?: boolean; /** Show Agent Teams progress */ teams?: boolean; } /** * Project summary for status display */ export interface ProjectSummary { /** Project ID */ id: string; /** Project name */ name: string; } /** * Specification summary for status display */ export interface SpecificationSummary { /** Specification ID */ id: string; /** Specification title */ title: string; /** Specification status */ status?: string; } /** * Epic summary for status display */ export interface EpicSummary { /** Epic ID */ id: string; /** Epic title */ title: string; /** Epic number */ epicNumber?: number; } /** * Ticket summary for status display */ export interface TicketSummary { /** Ticket ID */ id: string; /** Ticket title */ title: string; /** Ticket number */ ticketNumber: number; /** Ticket status */ status?: string; /** Ticket priority */ priority?: string; } /** * Working context representing current location in hierarchy */ export interface WorkingContext { /** Current project */ project?: ProjectSummary; /** Current specification */ specification?: SpecificationSummary; /** Current epic */ epic?: EpicSummary; /** Current ticket */ ticket?: TicketSummary; } /** * Implementation session statistics */ export interface SessionStats { /** Number of completed tickets */ completed: number; /** Number of failed tickets */ failed: number; /** Number of skipped tickets */ skipped: number; /** Total number of tickets in scope */ total: number; } /** * Implementation session summary */ export interface ImplementationSession { /** Session ID */ id: string; /** Session status */ status: SessionStatus; /** When the session was started */ startedAt: string; /** Specification ID this session is for */ specificationId: string; /** Specification title (for display) */ specificationTitle?: string; /** Session statistics */ stats: SessionStats; /** Current ticket being worked on */ currentTicket?: TicketSummary; } /** * Valid session statuses */ export type SessionStatus = 'active' | 'paused' | 'completed' | 'failed'; /** * Next actionable ticket suggestion */ export interface NextActionable { /** Ticket ID */ id: string; /** Ticket title */ title: string; /** Ticket number */ ticketNumber: number; /** Ticket priority */ priority: string; /** Epic this ticket belongs to */ epicTitle?: string; } /** * Complete status response */ export interface StatusResponse { /** Current working context */ workingContext: WorkingContext; /** Active implementation session (if any) */ implementationSession?: ImplementationSession; /** Next suggested ticket to work on */ nextActionable?: NextActionable; /** Timestamp of status fetch */ timestamp: string; } /** * API response from get_working_context */ export interface WorkingContextApiResponse { project?: { id: string; name: string; }; specification?: { id: string; title: string; status?: string; }; epic?: { id: string; title: string; epicNumber?: number; }; ticket?: { id: string; title: string; ticketNumber: number; status?: string; }; implementationSession?: { id: string; status: string; startedAt: string; specificationId: string; ticketsCompleted?: number; ticketsFailed?: number; ticketsSkipped?: number; totalTickets?: number; currentTicket?: { id: string; title: string; ticketNumber: number; }; }; } /** * API response from list_tickets */ export interface ListTicketsApiResponse { items: Array<{ id: string; title: string; ticketNumber: number; priority: string; status: string; epicTitle?: string; }>; total: number; } /** * Format a ticket number with padding * @param ticketNumber The ticket number * @param prefix The prefix (default: "TKT") * @param padding The padding length (default: 3) */ export declare function formatTicketNumber(ticketNumber: number, prefix?: string, padding?: number): string; /** * Format duration from ISO timestamp to human-readable string * @param startedAt ISO timestamp string */ export declare function formatDuration(startedAt: string): string; /** * Check if working context has any data */ export declare function hasWorkingContext(context: WorkingContext): boolean; /** * Check if session has any activity */ export declare function hasSessionActivity(session: ImplementationSession): boolean; /** * Calculate session progress percentage */ export declare function calculateSessionProgress(session: ImplementationSession): number; /** * Transform API response to StatusResponse */ export declare function transformApiResponse(contextResponse: WorkingContextApiResponse, ticketsResponse?: ListTicketsApiResponse): StatusResponse; /** * Dashboard data for comprehensive project analytics view */ export interface DashboardData { project: { id: string; name: string; updatedAt: string; }; specification: { id: string; title: string; status: string; }; /** Overall progress metrics */ overallProgress: OverallProgress; /** Time-related metrics and projections */ timeMetrics: TimeMetrics; /** Breakdown by specification */ specifications: SpecificationProgress[]; /** Epic status within current specification */ epics: EpicProgress[]; /** Ticket priority distribution */ priorityDistribution: PriorityDistribution; /** Ticket complexity distribution */ complexityDistribution: ComplexityDistribution; /** Active implementation session (if any) */ session?: DashboardSession; /** Next actionable tickets */ nextActionable: NextActionableTicket[]; /** Blocked tickets */ blockers: BlockerInfo[]; /** Failed tickets */ failedTickets: FailedTicketInfo[]; } /** * Overall progress metrics */ export interface OverallProgress { total: number; completed: number; inProgress: number; pending: number; failed: number; blocked: number; percentComplete: number; } /** * Time metrics and projections */ export interface TimeMetrics { estimatedHours: number; actualHours: number; remainingHours: number; velocityPerDay: number; avgHoursPerTicket: number; onTrack: boolean; estimatedCompletion: string; } /** * Specification progress summary */ export interface SpecificationProgress { id: string; title: string; completed: number; total: number; percentComplete: number; } /** * Epic progress summary */ export interface EpicProgress { id: string; code: string; title: string; completed: number; total: number; percentComplete: number; } /** * Ticket priority distribution */ export interface PriorityDistribution { critical: number; high: number; medium: number; low: number; } /** * Ticket complexity distribution */ export interface ComplexityDistribution { xs: number; s: number; m: number; l: number; xl: number; } /** * Dashboard session info */ export interface DashboardSession { status: string; duration: string; mode: string; currentTicket?: { id: string; title: string; ticketNumber: number; }; completed: number; failed: number; skipped: number; total: number; } /** * Next actionable ticket in dashboard */ export interface NextActionableTicket { id: string; ticketNumber: number; title: string; priority: string; complexity: string; estimatedHours: number; } /** * Blocker information */ export interface BlockerInfo { ticket: { id: string; ticketNumber: number; title: string; }; blockedBy?: { id: string; ticketNumber: number; title: string; status: string; }; reason?: string; } /** * Failed ticket information */ export interface FailedTicketInfo { ticket: { id: string; ticketNumber: number; title: string; }; reason?: string; } /** * Transform API response to DashboardData */ export declare function transformToDashboardData(contextResponse: WorkingContextApiResponse, dashboardResponse: any): DashboardData; //# sourceMappingURL=status.types.d.ts.map