@elevasis/ui 1.3.5 → 1.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/hooks/published.d.ts +55 -539
- package/dist/types/index.d.ts +3800 -0
- package/dist/types/index.js +1 -0
- package/package.json +6 -2
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import * as react from 'react';
|
|
3
|
+
import { z } from 'zod';
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* Query key factory for executions TanStack Query hooks.
|
|
@@ -276,501 +277,6 @@ interface ExecutionLogMessage$1 {
|
|
|
276
277
|
context?: LogContext$1
|
|
277
278
|
}
|
|
278
279
|
|
|
279
|
-
/**
|
|
280
|
-
* Shared form field types for dynamic form generation
|
|
281
|
-
* Used by: Command Queue, Execution Runner UI, future form-based features
|
|
282
|
-
*/
|
|
283
|
-
|
|
284
|
-
/**
|
|
285
|
-
* Supported form field types for action payloads
|
|
286
|
-
* Maps to Mantine form components
|
|
287
|
-
*/
|
|
288
|
-
type FormFieldType$1 =
|
|
289
|
-
| 'text' // TextInput
|
|
290
|
-
| 'textarea' // Textarea
|
|
291
|
-
| 'number' // NumberInput
|
|
292
|
-
| 'select' // Select dropdown
|
|
293
|
-
| 'checkbox' // Checkbox
|
|
294
|
-
| 'radio' // Radio group
|
|
295
|
-
| 'richtext' // Rich text editor (TipTap)
|
|
296
|
-
|
|
297
|
-
/**
|
|
298
|
-
* Form field definition
|
|
299
|
-
*/
|
|
300
|
-
interface FormField {
|
|
301
|
-
/** Field key in payload object */
|
|
302
|
-
name: string
|
|
303
|
-
|
|
304
|
-
/** Field label for UI */
|
|
305
|
-
label: string
|
|
306
|
-
|
|
307
|
-
/** Field type (determines UI component) */
|
|
308
|
-
type: FormFieldType$1
|
|
309
|
-
|
|
310
|
-
/** Default value */
|
|
311
|
-
defaultValue?: unknown
|
|
312
|
-
|
|
313
|
-
/** Required field */
|
|
314
|
-
required?: boolean
|
|
315
|
-
|
|
316
|
-
/** Placeholder text */
|
|
317
|
-
placeholder?: string
|
|
318
|
-
|
|
319
|
-
/** Help text */
|
|
320
|
-
description?: string
|
|
321
|
-
|
|
322
|
-
/** Options for select/radio */
|
|
323
|
-
options?: Array<{
|
|
324
|
-
label: string
|
|
325
|
-
value: string | number
|
|
326
|
-
}>
|
|
327
|
-
|
|
328
|
-
/** Min/max for number */
|
|
329
|
-
min?: number
|
|
330
|
-
max?: number
|
|
331
|
-
|
|
332
|
-
/** Path to context value for pre-filling (dot notation, e.g., 'proposal.summary') */
|
|
333
|
-
defaultValueFromContext?: string
|
|
334
|
-
}
|
|
335
|
-
|
|
336
|
-
/**
|
|
337
|
-
* Form schema for action payload collection
|
|
338
|
-
*/
|
|
339
|
-
interface FormSchema {
|
|
340
|
-
/** Form title */
|
|
341
|
-
title?: string
|
|
342
|
-
|
|
343
|
-
/** Form description */
|
|
344
|
-
description?: string
|
|
345
|
-
|
|
346
|
-
/** Form fields */
|
|
347
|
-
fields: FormField[]
|
|
348
|
-
}
|
|
349
|
-
|
|
350
|
-
/**
|
|
351
|
-
* Error categories for observability grouping and classification.
|
|
352
|
-
* Used to categorize errors in the execution_errors table metadata.
|
|
353
|
-
*/
|
|
354
|
-
type ExecutionErrorCategory$1 = 'llm' | 'tool' | 'workflow' | 'agent' | 'validation' | 'system'
|
|
355
|
-
|
|
356
|
-
// ============================================================================
|
|
357
|
-
// API Request/Response Types (Dashboard Observability)
|
|
358
|
-
// ============================================================================
|
|
359
|
-
|
|
360
|
-
/**
|
|
361
|
-
* Time range selector for dashboard metrics
|
|
362
|
-
*/
|
|
363
|
-
type TimeRange$1 = '1h' | '24h' | '7d' | '30d'
|
|
364
|
-
|
|
365
|
-
/**
|
|
366
|
-
* Execution health metrics response
|
|
367
|
-
* Success rate, P95 duration, execution counts, and trend data
|
|
368
|
-
* trendData includes executionCount for throughput visualization (eliminates separate API call)
|
|
369
|
-
*/
|
|
370
|
-
interface ExecutionHealthMetrics$1 {
|
|
371
|
-
successRate: number
|
|
372
|
-
p95Duration: number
|
|
373
|
-
totalExecutions: number
|
|
374
|
-
trendData: Array<{
|
|
375
|
-
time: string
|
|
376
|
-
rate: number
|
|
377
|
-
successCount: number
|
|
378
|
-
errorCount: number
|
|
379
|
-
warningCount: number
|
|
380
|
-
executionCount: number
|
|
381
|
-
}>
|
|
382
|
-
statusCounts: { success: number; failed: number; pending: number; warning: number }
|
|
383
|
-
peakPeriod: string
|
|
384
|
-
granularity: 'hour' | 'day'
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
/**
|
|
388
|
-
* Error analysis metrics response
|
|
389
|
-
* Error categories and top failing resources
|
|
390
|
-
*/
|
|
391
|
-
interface ErrorAnalysisMetrics$1 {
|
|
392
|
-
totalErrors: number
|
|
393
|
-
errorsByCategory: Array<{
|
|
394
|
-
category: string
|
|
395
|
-
count: number
|
|
396
|
-
percentage: number
|
|
397
|
-
}>
|
|
398
|
-
topFailingResources: Array<{
|
|
399
|
-
resourceId: string
|
|
400
|
-
name: string
|
|
401
|
-
errorCount: number
|
|
402
|
-
failureRate: number
|
|
403
|
-
}>
|
|
404
|
-
}
|
|
405
|
-
|
|
406
|
-
/**
|
|
407
|
-
* Business impact metrics response
|
|
408
|
-
* ROI, labor savings, and cost analysis
|
|
409
|
-
*/
|
|
410
|
-
interface BusinessImpactMetrics$2 {
|
|
411
|
-
totalSavingsUsd: number
|
|
412
|
-
totalCostUsd: number
|
|
413
|
-
netSavingsUsd: number
|
|
414
|
-
roi: number
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
/**
|
|
418
|
-
* Cost breakdown metrics response
|
|
419
|
-
* Per-resource cost analysis
|
|
420
|
-
*/
|
|
421
|
-
interface CostBreakdownMetrics$1 {
|
|
422
|
-
resources: Array<{
|
|
423
|
-
resourceId: string
|
|
424
|
-
totalCostUsd: number
|
|
425
|
-
executionCount: number
|
|
426
|
-
avgCostUsd: number
|
|
427
|
-
}>
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
/**
|
|
431
|
-
* Dashboard metrics response
|
|
432
|
-
* Aggregates core observability metrics in a single response
|
|
433
|
-
* Note: Throughput data is now included in executionHealth.trendData.executionCount
|
|
434
|
-
*/
|
|
435
|
-
interface DashboardMetrics$1 {
|
|
436
|
-
executionHealth: ExecutionHealthMetrics$1
|
|
437
|
-
costBreakdown: CostBreakdownMetrics$1
|
|
438
|
-
businessImpact: BusinessImpactMetrics$2
|
|
439
|
-
/** ISO timestamp of the currently active deployment, or null if none */
|
|
440
|
-
activeDeploymentDate: string | null
|
|
441
|
-
/** Deployment version of the active deployment, or null if none */
|
|
442
|
-
activeDeploymentVersion: string | null
|
|
443
|
-
}
|
|
444
|
-
|
|
445
|
-
// ============================================================================
|
|
446
|
-
// Error Tracking Types
|
|
447
|
-
// ============================================================================
|
|
448
|
-
|
|
449
|
-
/**
|
|
450
|
-
* Error record for list view (ErrorBreakdownTable)
|
|
451
|
-
*/
|
|
452
|
-
interface ErrorRecord$1 {
|
|
453
|
-
id: string // execution_errors.id
|
|
454
|
-
timestamp: string // occurred_at
|
|
455
|
-
errorType: string // error_type
|
|
456
|
-
message: string // error_message
|
|
457
|
-
executionId: string // execution_id
|
|
458
|
-
resourceId: string // execution_logs.resource_id (via JOIN)
|
|
459
|
-
resourceName: string // execution_logs.resource_id (TODO: resolve via registry)
|
|
460
|
-
severity: 'critical' | 'warning' | 'info'
|
|
461
|
-
category: ExecutionErrorCategory$1 // error_category (moved from metadata to dedicated column)
|
|
462
|
-
resolved: boolean // resolved flag (human acknowledgment, does not affect execution status)
|
|
463
|
-
resolvedAt: string | null // timestamp when resolved
|
|
464
|
-
resolvedBy: string | null // user ID who resolved
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
/**
|
|
468
|
-
* Full error detail for modal view (ErrorDetailsModal)
|
|
469
|
-
*/
|
|
470
|
-
interface ErrorDetailFull$1 extends ErrorRecord$1 {
|
|
471
|
-
stackTrace?: string // error_stack_trace
|
|
472
|
-
retryAttempt?: number // metadata.retryAttempt
|
|
473
|
-
stepName?: string // metadata.stepName
|
|
474
|
-
stepSequence?: number // metadata.stepSequence
|
|
475
|
-
errorContext?: Record<string, unknown> // metadata.errorContext
|
|
476
|
-
executionContext?: Record<string, unknown> // metadata.executionContext
|
|
477
|
-
}
|
|
478
|
-
|
|
479
|
-
/**
|
|
480
|
-
* Error details API response (paginated)
|
|
481
|
-
*/
|
|
482
|
-
interface ErrorDetailResponse$1 {
|
|
483
|
-
errors: ErrorRecord$1[]
|
|
484
|
-
total: number
|
|
485
|
-
page: number
|
|
486
|
-
limit: number
|
|
487
|
-
}
|
|
488
|
-
|
|
489
|
-
/**
|
|
490
|
-
* Error trend data for time-series charts
|
|
491
|
-
*/
|
|
492
|
-
interface ErrorTrend$1 {
|
|
493
|
-
time: string // Time bucket (ISO timestamp)
|
|
494
|
-
errorCount: number // Total errors in bucket
|
|
495
|
-
criticalCount: number // Critical errors in bucket
|
|
496
|
-
warningCount: number // Warning errors in bucket
|
|
497
|
-
infoCount: number // Info errors in bucket
|
|
498
|
-
}
|
|
499
|
-
|
|
500
|
-
// ============================================================================
|
|
501
|
-
// Cost Analytics Types (Time-Series)
|
|
502
|
-
// ============================================================================
|
|
503
|
-
|
|
504
|
-
/**
|
|
505
|
-
* Cost trend data point for time-series charts
|
|
506
|
-
* Represents a single time bucket (hour or day)
|
|
507
|
-
*/
|
|
508
|
-
interface CostTrendDataPoint$1 {
|
|
509
|
-
time: string // ISO timestamp (bucket start)
|
|
510
|
-
totalCostUsd: number
|
|
511
|
-
executionCount: number
|
|
512
|
-
avgCostPerExecution: number
|
|
513
|
-
}
|
|
514
|
-
|
|
515
|
-
/**
|
|
516
|
-
* Cost trends response (time-series data)
|
|
517
|
-
*/
|
|
518
|
-
interface CostTrendsResponse$1 {
|
|
519
|
-
trendData: CostTrendDataPoint$1[]
|
|
520
|
-
granularity: 'hour' | 'day'
|
|
521
|
-
totalCostUsd: number
|
|
522
|
-
totalExecutions: number
|
|
523
|
-
}
|
|
524
|
-
|
|
525
|
-
/**
|
|
526
|
-
* Cost summary response with MTD and projections
|
|
527
|
-
*/
|
|
528
|
-
interface CostSummaryResponse$1 {
|
|
529
|
-
current: {
|
|
530
|
-
totalCostUsd: number
|
|
531
|
-
executionCount: number
|
|
532
|
-
}
|
|
533
|
-
previous: {
|
|
534
|
-
totalCostUsd: number
|
|
535
|
-
executionCount: number
|
|
536
|
-
}
|
|
537
|
-
mtd: {
|
|
538
|
-
totalCostUsd: number
|
|
539
|
-
daysElapsed: number
|
|
540
|
-
}
|
|
541
|
-
projection: {
|
|
542
|
-
monthlyCostUsd: number
|
|
543
|
-
confidence: 'low' | 'medium' | 'high'
|
|
544
|
-
}
|
|
545
|
-
trend: {
|
|
546
|
-
changePercent: number
|
|
547
|
-
direction: 'up' | 'down' | 'flat'
|
|
548
|
-
}
|
|
549
|
-
}
|
|
550
|
-
|
|
551
|
-
/**
|
|
552
|
-
* Cost by model data for model-level breakdown
|
|
553
|
-
*/
|
|
554
|
-
interface CostByModelData$1 {
|
|
555
|
-
model: string
|
|
556
|
-
totalCostUsd: number
|
|
557
|
-
callCount: number
|
|
558
|
-
totalInputTokens: number
|
|
559
|
-
totalOutputTokens: number
|
|
560
|
-
avgCostPerCall: number
|
|
561
|
-
}
|
|
562
|
-
|
|
563
|
-
/**
|
|
564
|
-
* Cost by model response
|
|
565
|
-
*/
|
|
566
|
-
interface CostByModelResponse$1 {
|
|
567
|
-
models: CostByModelData$1[]
|
|
568
|
-
totalCostUsd: number
|
|
569
|
-
totalCallCount: number
|
|
570
|
-
}
|
|
571
|
-
|
|
572
|
-
/**
|
|
573
|
-
* Action configuration for HITL tasks
|
|
574
|
-
* Defines available user actions and their behavior
|
|
575
|
-
*/
|
|
576
|
-
interface ActionConfig {
|
|
577
|
-
/** Unique action identifier (e.g., 'approve', 'retry', 'escalate') */
|
|
578
|
-
id: string
|
|
579
|
-
|
|
580
|
-
/** Display label for UI button */
|
|
581
|
-
label: string
|
|
582
|
-
|
|
583
|
-
/** Button variant/style */
|
|
584
|
-
type: 'primary' | 'secondary' | 'danger' | 'outline'
|
|
585
|
-
|
|
586
|
-
/** Tabler icon name (e.g., 'IconCheck', 'IconRefresh') */
|
|
587
|
-
icon?: string
|
|
588
|
-
|
|
589
|
-
/** Button color (Mantine theme colors) */
|
|
590
|
-
color?: string
|
|
591
|
-
|
|
592
|
-
/** Button variant (Mantine button variant, e.g., 'light', 'filled', 'outline') */
|
|
593
|
-
variant?: string
|
|
594
|
-
|
|
595
|
-
/** Execution target (agent/workflow to invoke) */
|
|
596
|
-
target?: {
|
|
597
|
-
resourceType: 'agent' | 'workflow'
|
|
598
|
-
resourceId: string
|
|
599
|
-
/**
|
|
600
|
-
* Optional session ID for agent continuation.
|
|
601
|
-
* If provided, invokes a new turn on the existing session instead of standalone execution.
|
|
602
|
-
* Only valid when resourceType is 'agent'.
|
|
603
|
-
*/
|
|
604
|
-
sessionId?: string
|
|
605
|
-
}
|
|
606
|
-
|
|
607
|
-
/** Form schema for collecting action-specific data */
|
|
608
|
-
form?: FormSchema
|
|
609
|
-
|
|
610
|
-
/** Payload template for pre-filling forms */
|
|
611
|
-
payloadTemplate?: unknown
|
|
612
|
-
|
|
613
|
-
/** Requires confirmation dialog */
|
|
614
|
-
requiresConfirmation?: boolean
|
|
615
|
-
|
|
616
|
-
/** Confirmation message */
|
|
617
|
-
confirmationMessage?: string
|
|
618
|
-
|
|
619
|
-
/** Help text / tooltip */
|
|
620
|
-
description?: string
|
|
621
|
-
}
|
|
622
|
-
|
|
623
|
-
/**
|
|
624
|
-
* Origin resource type - where an execution/task originated from.
|
|
625
|
-
* Used for audit trails and tracking execution lineage.
|
|
626
|
-
*/
|
|
627
|
-
type OriginResourceType$1 = 'agent' | 'workflow' | 'scheduler' | 'api'
|
|
628
|
-
|
|
629
|
-
/**
|
|
630
|
-
* Origin tracking metadata - who/what created this execution/task.
|
|
631
|
-
* Used by both TaskScheduler and CommandQueue for complete audit trails.
|
|
632
|
-
*/
|
|
633
|
-
interface OriginTracking {
|
|
634
|
-
originExecutionId: string
|
|
635
|
-
originResourceType: OriginResourceType$1
|
|
636
|
-
originResourceId: string
|
|
637
|
-
}
|
|
638
|
-
|
|
639
|
-
/**
|
|
640
|
-
* Command queue task with flexible action system
|
|
641
|
-
*/
|
|
642
|
-
interface Task extends OriginTracking {
|
|
643
|
-
id: string
|
|
644
|
-
organizationId: string
|
|
645
|
-
|
|
646
|
-
// NEW: Flexible action system
|
|
647
|
-
actions: ActionConfig[]
|
|
648
|
-
context: unknown
|
|
649
|
-
selectedAction?: string
|
|
650
|
-
actionPayload?: unknown
|
|
651
|
-
|
|
652
|
-
// Task metadata
|
|
653
|
-
description?: string
|
|
654
|
-
priority: number
|
|
655
|
-
|
|
656
|
-
/** Optional checkpoint identifier for grouping related human approval tasks */
|
|
657
|
-
humanCheckpoint?: string
|
|
658
|
-
|
|
659
|
-
// Status (updated to include 'completed')
|
|
660
|
-
status: TaskStatus
|
|
661
|
-
|
|
662
|
-
/**
|
|
663
|
-
* Target resource tracking — mirrors origin columns.
|
|
664
|
-
* Set when task is created; patchable to redirect execution to a different resource.
|
|
665
|
-
*/
|
|
666
|
-
targetResourceId?: string
|
|
667
|
-
targetResourceType?: 'agent' | 'workflow'
|
|
668
|
-
|
|
669
|
-
/**
|
|
670
|
-
* Execution ID for the action that runs AFTER user approval.
|
|
671
|
-
* NULL until execution starts.
|
|
672
|
-
*
|
|
673
|
-
* Naming distinction:
|
|
674
|
-
* - originExecutionId = Parent execution that CREATED the HITL task
|
|
675
|
-
* - targetExecutionId = Child execution that RUNS AFTER user approval
|
|
676
|
-
*/
|
|
677
|
-
targetExecutionId?: string
|
|
678
|
-
|
|
679
|
-
createdAt: Date
|
|
680
|
-
completedAt?: Date
|
|
681
|
-
completedBy?: string
|
|
682
|
-
expiresAt?: Date
|
|
683
|
-
idempotencyKey?: string | null
|
|
684
|
-
}
|
|
685
|
-
|
|
686
|
-
/**
|
|
687
|
-
* Task status values
|
|
688
|
-
* - pending: awaiting action
|
|
689
|
-
* - processing: execution in progress after user approval
|
|
690
|
-
* - completed: action was taken and execution succeeded
|
|
691
|
-
* - failed: execution failed, task can be retried
|
|
692
|
-
* - expired: timed out before action
|
|
693
|
-
*/
|
|
694
|
-
type TaskStatus = 'pending' | 'processing' | 'completed' | 'failed' | 'expired'
|
|
695
|
-
|
|
696
|
-
/**
|
|
697
|
-
* Parameters for patching mutable metadata on a task
|
|
698
|
-
*/
|
|
699
|
-
interface PatchTaskParams {
|
|
700
|
-
humanCheckpoint?: string | null
|
|
701
|
-
description?: string
|
|
702
|
-
priority?: number
|
|
703
|
-
context?: Record<string, unknown>
|
|
704
|
-
actions?: unknown[]
|
|
705
|
-
targetResourceId?: string | null
|
|
706
|
-
targetResourceType?: 'agent' | 'workflow' | null
|
|
707
|
-
targetExecutionId?: string
|
|
708
|
-
status?: 'pending' | 'failed' | 'completed'
|
|
709
|
-
}
|
|
710
|
-
|
|
711
|
-
/**
|
|
712
|
-
* Checkpoint list item for sidebar grouping
|
|
713
|
-
* The id field contains the resourceId of the human checkpoint
|
|
714
|
-
*/
|
|
715
|
-
interface CheckpointListItem {
|
|
716
|
-
/** Human checkpoint resourceId (or 'ungrouped' for tasks without checkpoint) */
|
|
717
|
-
id: string
|
|
718
|
-
/** Display name (same as id, or "Ungrouped" for null) */
|
|
719
|
-
name: string
|
|
720
|
-
/** Task count for this checkpoint */
|
|
721
|
-
count: number
|
|
722
|
-
}
|
|
723
|
-
|
|
724
|
-
/**
|
|
725
|
-
* Status counts for pie chart display
|
|
726
|
-
*/
|
|
727
|
-
interface StatusCounts {
|
|
728
|
-
pending: number
|
|
729
|
-
completed: number
|
|
730
|
-
expired: number
|
|
731
|
-
}
|
|
732
|
-
|
|
733
|
-
/**
|
|
734
|
-
* Priority counts for donut chart display
|
|
735
|
-
*/
|
|
736
|
-
interface PriorityCounts {
|
|
737
|
-
critical: number
|
|
738
|
-
high: number
|
|
739
|
-
medium: number
|
|
740
|
-
low: number
|
|
741
|
-
}
|
|
742
|
-
|
|
743
|
-
/**
|
|
744
|
-
* Response from GET /command-queue/checkpoints endpoint
|
|
745
|
-
*/
|
|
746
|
-
interface CheckpointListResponse {
|
|
747
|
-
checkpoints: CheckpointListItem[]
|
|
748
|
-
/** Total tasks across all checkpoints */
|
|
749
|
-
total: number
|
|
750
|
-
/** Breakdown by status for donut chart */
|
|
751
|
-
statusCounts: StatusCounts
|
|
752
|
-
/** Breakdown by priority for donut chart */
|
|
753
|
-
priorityCounts: PriorityCounts
|
|
754
|
-
}
|
|
755
|
-
|
|
756
|
-
/**
|
|
757
|
-
* Wire-format DTO for notification API responses.
|
|
758
|
-
* Dates are ISO 8601 strings (not Date objects like the domain Notification type).
|
|
759
|
-
* Used by frontend hooks that consume /api/notifications.
|
|
760
|
-
*/
|
|
761
|
-
interface NotificationDTO$1 {
|
|
762
|
-
id: string
|
|
763
|
-
userId: string
|
|
764
|
-
organizationId: string
|
|
765
|
-
category: string
|
|
766
|
-
title: string
|
|
767
|
-
message: string
|
|
768
|
-
actionUrl: string | null
|
|
769
|
-
read: boolean
|
|
770
|
-
readAt: string | null
|
|
771
|
-
createdAt: string
|
|
772
|
-
}
|
|
773
|
-
|
|
774
280
|
/**
|
|
775
281
|
* Resource Registry type definitions
|
|
776
282
|
*/
|
|
@@ -816,7 +322,7 @@ interface APIExecutionDetail$1 extends APIExecutionSummary$1 {
|
|
|
816
322
|
}
|
|
817
323
|
|
|
818
324
|
// API request/response types
|
|
819
|
-
interface APIExecutionListResponse
|
|
325
|
+
interface APIExecutionListResponse {
|
|
820
326
|
executions: APIExecutionSummary$1[]
|
|
821
327
|
}
|
|
822
328
|
|
|
@@ -833,7 +339,7 @@ interface APIExecutionListResponse$1 {
|
|
|
833
339
|
* // With status filter and limit
|
|
834
340
|
* const { data } = useExecutions(resourceId, 'running', 20)
|
|
835
341
|
*/
|
|
836
|
-
declare function useExecutions(resourceId: string, resourceStatus?: ResourceStatus$1 | 'all', limit?: number): _tanstack_react_query.UseQueryResult<APIExecutionListResponse
|
|
342
|
+
declare function useExecutions(resourceId: string, resourceStatus?: ResourceStatus$1 | 'all', limit?: number): _tanstack_react_query.UseQueryResult<APIExecutionListResponse, Error>;
|
|
837
343
|
|
|
838
344
|
/**
|
|
839
345
|
* Fetch a single execution detail.
|
|
@@ -3988,17 +3494,14 @@ interface APIExecutionDetail extends APIExecutionSummary {
|
|
|
3988
3494
|
resourceVersion?: string | null;
|
|
3989
3495
|
sdkVersion?: string | null;
|
|
3990
3496
|
}
|
|
3991
|
-
interface APIExecutionListResponse {
|
|
3992
|
-
executions: APIExecutionSummary[];
|
|
3993
|
-
}
|
|
3994
3497
|
|
|
3995
|
-
type ActivityType
|
|
3996
|
-
type ActivityStatus
|
|
3997
|
-
interface Activity
|
|
3498
|
+
type ActivityType = 'workflow_execution' | 'agent_run' | 'hitl_action' | 'webhook_received' | 'webhook_executed' | 'webhook_failed' | 'credential_change' | 'api_key_change' | 'deployment_change' | 'membership_change';
|
|
3499
|
+
type ActivityStatus = 'success' | 'failure' | 'pending' | 'approved' | 'rejected' | 'completed';
|
|
3500
|
+
interface Activity {
|
|
3998
3501
|
id: string;
|
|
3999
3502
|
organizationId: string;
|
|
4000
|
-
activityType: ActivityType
|
|
4001
|
-
status: ActivityStatus
|
|
3503
|
+
activityType: ActivityType;
|
|
3504
|
+
status: ActivityStatus;
|
|
4002
3505
|
title: string;
|
|
4003
3506
|
description: string | null;
|
|
4004
3507
|
entityType: string;
|
|
@@ -4011,6 +3514,50 @@ interface Activity$1 {
|
|
|
4011
3514
|
createdAt: Date;
|
|
4012
3515
|
}
|
|
4013
3516
|
|
|
3517
|
+
/**
|
|
3518
|
+
* Execution history item.
|
|
3519
|
+
* Represents a single execution triggered by a schedule.
|
|
3520
|
+
*/
|
|
3521
|
+
declare const ExecutionHistoryItemSchema: z.ZodObject<{
|
|
3522
|
+
id: z.ZodString;
|
|
3523
|
+
createdAt: z.ZodString;
|
|
3524
|
+
status: z.ZodEnum<{
|
|
3525
|
+
completed: "completed";
|
|
3526
|
+
failed: "failed";
|
|
3527
|
+
running: "running";
|
|
3528
|
+
cancelled: "cancelled";
|
|
3529
|
+
}>;
|
|
3530
|
+
step: z.ZodNullable<z.ZodNumber>;
|
|
3531
|
+
itemLabel: z.ZodNullable<z.ZodString>;
|
|
3532
|
+
duration: z.ZodNullable<z.ZodNumber>;
|
|
3533
|
+
error: z.ZodNullable<z.ZodString>;
|
|
3534
|
+
}, z.core.$strip>;
|
|
3535
|
+
/**
|
|
3536
|
+
* Execution history response.
|
|
3537
|
+
* Returned by GET /schedules/:id/executions with pagination.
|
|
3538
|
+
*/
|
|
3539
|
+
declare const ExecutionHistoryResponseSchema: z.ZodObject<{
|
|
3540
|
+
executions: z.ZodArray<z.ZodObject<{
|
|
3541
|
+
id: z.ZodString;
|
|
3542
|
+
createdAt: z.ZodString;
|
|
3543
|
+
status: z.ZodEnum<{
|
|
3544
|
+
completed: "completed";
|
|
3545
|
+
failed: "failed";
|
|
3546
|
+
running: "running";
|
|
3547
|
+
cancelled: "cancelled";
|
|
3548
|
+
}>;
|
|
3549
|
+
step: z.ZodNullable<z.ZodNumber>;
|
|
3550
|
+
itemLabel: z.ZodNullable<z.ZodString>;
|
|
3551
|
+
duration: z.ZodNullable<z.ZodNumber>;
|
|
3552
|
+
error: z.ZodNullable<z.ZodString>;
|
|
3553
|
+
}, z.core.$strip>>;
|
|
3554
|
+
total: z.ZodNumber;
|
|
3555
|
+
limit: z.ZodNumber;
|
|
3556
|
+
offset: z.ZodNumber;
|
|
3557
|
+
}, z.core.$strip>;
|
|
3558
|
+
type ExecutionHistoryItem = z.infer<typeof ExecutionHistoryItemSchema>;
|
|
3559
|
+
type ExecutionHistoryResponse = z.infer<typeof ExecutionHistoryResponseSchema>;
|
|
3560
|
+
|
|
4014
3561
|
/**
|
|
4015
3562
|
* Fetch all available Execution Engine resources (workflows, agents, pipelines).
|
|
4016
3563
|
*
|
|
@@ -4244,7 +3791,7 @@ declare function useDeleteSchedule(): _tanstack_react_query.UseMutationResult<vo
|
|
|
4244
3791
|
interface UseActivitiesParams {
|
|
4245
3792
|
limit?: number;
|
|
4246
3793
|
offset?: number;
|
|
4247
|
-
activityType?: ActivityType
|
|
3794
|
+
activityType?: ActivityType;
|
|
4248
3795
|
entityType?: string;
|
|
4249
3796
|
entityId?: string;
|
|
4250
3797
|
startDate?: string;
|
|
@@ -4253,7 +3800,7 @@ interface UseActivitiesParams {
|
|
|
4253
3800
|
search?: string;
|
|
4254
3801
|
}
|
|
4255
3802
|
interface ListActivitiesResponse {
|
|
4256
|
-
activities: Activity
|
|
3803
|
+
activities: Activity[];
|
|
4257
3804
|
total: number;
|
|
4258
3805
|
}
|
|
4259
3806
|
/**
|
|
@@ -4979,36 +4526,5 @@ declare function useSessionWebSocket(sessionId: string, apiUrl: string): {
|
|
|
4979
4526
|
lastTokenUsage: SessionTokenUsage | null;
|
|
4980
4527
|
};
|
|
4981
4528
|
|
|
4982
|
-
type ActivityType =
|
|
4983
|
-
| 'workflow_execution'
|
|
4984
|
-
| 'agent_run'
|
|
4985
|
-
| 'hitl_action'
|
|
4986
|
-
| 'webhook_received'
|
|
4987
|
-
| 'webhook_executed'
|
|
4988
|
-
| 'webhook_failed'
|
|
4989
|
-
| 'credential_change'
|
|
4990
|
-
| 'api_key_change'
|
|
4991
|
-
| 'deployment_change'
|
|
4992
|
-
| 'membership_change'
|
|
4993
|
-
|
|
4994
|
-
type ActivityStatus = 'success' | 'failure' | 'pending' | 'approved' | 'rejected' | 'completed'
|
|
4995
|
-
|
|
4996
|
-
interface Activity {
|
|
4997
|
-
id: string
|
|
4998
|
-
organizationId: string
|
|
4999
|
-
activityType: ActivityType
|
|
5000
|
-
status: ActivityStatus
|
|
5001
|
-
title: string
|
|
5002
|
-
description: string | null
|
|
5003
|
-
entityType: string
|
|
5004
|
-
entityId: string
|
|
5005
|
-
entityName: string | null
|
|
5006
|
-
metadata: Record<string, unknown> | null
|
|
5007
|
-
actorId: string | null
|
|
5008
|
-
actorType: string | null
|
|
5009
|
-
occurredAt: Date
|
|
5010
|
-
createdAt: Date
|
|
5011
|
-
}
|
|
5012
|
-
|
|
5013
4529
|
export { OperationsService, REFETCH_INTERVAL_RUNNING, WS_MAX_RETRIES_BEFORE_ERROR, WS_RECONNECT_BASE_DELAY, WS_RECONNECT_MAX_DELAY, createUseFeatureAccess, executionsKeys, observabilityKeys, scheduleKeys, sessionsKeys, sortData, useActivities, useActivityTrend, useArchiveSession, useBatchDelete, useBulkDeleteExecutions, useBusinessImpact, useCancelExecution, useCancelSchedule, useCostBreakdown, useCostByModel, useCostSummary, useCostTrends, useCreateSchedule, useCreateSession, useDashboardMetrics, useDeleteExecution, useDeleteSchedule, useDeleteSession, useErrorAnalysis, useErrorDetail, useErrorDetails, useErrorDistribution, useErrorNotification, useErrorTrends, useExecuteAsync, useExecution, useExecutionHealth, useExecutionLogs, useExecutions, useGetExecutionHistory, useGetSchedule, useListSchedules, useMarkAllAsRead, useMarkAsRead, useNotificationCount, useNotifications, usePaginationState, usePauseSchedule, useResolveAllErrors, useResolveError, useResolveErrorsByExecution, useResourceDefinition, useResources, useResumeSchedule, useRetryExecution, useSSEConnection, useSession, useSessionExecution, useSessionExecutions, useSessionMessages, useSessionWebSocket, useSessions, useSortedData, useSuccessNotification, useTableSelection, useTableSort, useTopFailingResources, useUnresolveError, useUpdateAnchor, useUpdateSchedule, useWarningNotification };
|
|
5014
|
-
export type {
|
|
4530
|
+
export type { ActivityTrendResponse, BulkDeleteExecutionsParams, BulkDeleteExecutionsResult, BusinessImpactMetrics, CancelExecutionParams, CancelExecutionResult, ChatMessage, CostBreakdownItem, CreateScheduleInput, CreateSessionResponse, DeleteExecutionParams, ErrorDistributionItem, ErrorDistributionParams, ErrorFilters, ErrorTrendsParams, ExecuteAsyncParams, ExecuteAsyncResult, ExecutionHistoryItem, ExecutionHistoryResponse, ExecutionLogsPageResponse, FailingResource, GetMessagesResponse, ListActivitiesResponse, ListSchedulesFilters, ListSchedulesResponse, MessageEvent, MessageType, ResourcesResponse, RetryExecutionParams, SessionDTO, SessionExecution, SessionExecutionsResponse, SessionListItem, SessionTokenUsage, SortDirection, SortState, TaskSchedule, TopFailingResourcesParams, UpdateScheduleInput, UseActivitiesParams, UseActivityTrendParams, UseExecutionHealthParams, UseExecutionLogsParams, UseSSEConnectionOptions, WebSocketState };
|