meyi-insight-ui-dev 1.0.2 → 1.0.4
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/components/common/PageSkeleton.d.ts +10 -0
- package/dist/components/data-table/toolbar.d.ts +3 -1
- package/dist/components/ui/badge.d.ts +1 -1
- package/dist/components/ui/button.d.ts +2 -2
- package/dist/components/ui/multi-select.d.ts +15 -0
- package/dist/components/ui/single-select.d.ts +15 -0
- package/dist/features/alerts/components/AlertFilters.d.ts +15 -0
- package/dist/features/alerts/components/ProcessingLifecycle.d.ts +5 -0
- package/dist/features/alerts/components/alerts-columns.d.ts +1 -0
- package/dist/features/alerts/components/alerts-table.d.ts +6 -9
- package/dist/features/alerts/detail.d.ts +7 -0
- package/dist/features/alerts/index.d.ts +2 -1
- package/dist/features/incidents/analytics.d.ts +1 -0
- package/dist/features/incidents/components/IncidentFilters.d.ts +4 -1
- package/dist/features/incidents/components/IncidentForm.d.ts +4 -0
- package/dist/features/incidents/components/InsightStatusBadge.d.ts +3 -0
- package/dist/features/incidents/components/incidents-columns.d.ts +0 -1
- package/dist/features/incidents/components/incidents-table.d.ts +3 -4
- package/dist/features/incidents/dashboard.d.ts +5 -0
- package/dist/features/pipeline/PipelineRuleEditor.d.ts +9 -0
- package/dist/features/pipeline/dedup.d.ts +4 -0
- package/dist/features/pipeline/editor-dedup.d.ts +4 -0
- package/dist/features/pipeline/editor-grouping.d.ts +4 -0
- package/dist/features/pipeline/editor-normalization.d.ts +4 -0
- package/dist/features/pipeline/grouping.d.ts +4 -0
- package/dist/features/pipeline/normalization.d.ts +1 -0
- package/dist/features/projects/components/ProjectFilters.d.ts +9 -0
- package/dist/features/projects/components/projects-table.d.ts +4 -3
- package/dist/features/settings/components/NotificationProvidersManager.d.ts +1 -0
- package/dist/features/settings/index.d.ts +5 -1
- package/dist/features/sop/components/SopFilters.d.ts +13 -0
- package/dist/features/sop/components/sop-table.d.ts +4 -7
- package/dist/features/sources/add-wizard/AddSourceConfigureStep.d.ts +8 -0
- package/dist/features/sources/add-wizard/AddSourceDeployStep.d.ts +11 -0
- package/dist/features/sources/add-wizard/AddSourceOverviewStep.d.ts +4 -0
- package/dist/features/sources/add-wizard/AddSourceSourceStep.d.ts +5 -0
- package/dist/features/{connectors/prometheus-wizard/PrometheusConnectorWizard.d.ts → sources/add-wizard/AddSourceWizard.d.ts} +1 -1
- package/dist/features/sources/add-wizard/add-source-options.d.ts +10 -0
- package/dist/features/sources/cloudwatch-wizard/CloudWatchSourceWizard.d.ts +8 -0
- package/dist/features/sources/components/InsightSourceDeleteDialog.d.ts +9 -0
- package/dist/features/sources/components/InsightSourceForm.d.ts +18 -0
- package/dist/features/{connectors/components/ConnectorAwsOnboardingDialog.d.ts → sources/components/SourceAwsOnboardingDialog.d.ts} +1 -1
- package/dist/features/{connectors/components/ConnectorDatadogSetupDialog.d.ts → sources/components/SourceDatadogSetupDialog.d.ts} +2 -2
- package/dist/features/sources/components/SourceDetailsDialog.d.ts +8 -0
- package/dist/features/sources/components/SourceFilters.d.ts +21 -0
- package/dist/features/{connectors/components/ConnectorGrafanaSetupDialog.d.ts → sources/components/SourceGrafanaSetupDialog.d.ts} +2 -2
- package/dist/features/sources/components/SourceGroupedList.d.ts +18 -0
- package/dist/features/{connectors/components/ConnectorPrometheusSetupDialog.d.ts → sources/components/SourcePrometheusSetupDialog.d.ts} +2 -2
- package/dist/features/sources/components/SourceTokenPolicyDialog.d.ts +11 -0
- package/dist/features/sources/components/WebhookSuccessModal.d.ts +6 -0
- package/dist/features/sources/detail/SourceAlarmsTab.d.ts +4 -0
- package/dist/features/sources/detail/SourceConfigurationTab.d.ts +10 -0
- package/dist/features/sources/detail/SourceDetailHeader.d.ts +11 -0
- package/dist/features/sources/detail/SourceDetailPage.d.ts +5 -0
- package/dist/features/sources/detail/SourceDetailTabs.d.ts +6 -0
- package/dist/features/sources/detail/SourceLogsTab.d.ts +6 -0
- package/dist/features/sources/detail/SourceOverviewTab.d.ts +4 -0
- package/dist/features/sources/detail/SourceSetupTab.d.ts +10 -0
- package/dist/features/sources/detail/SourceTestTab.d.ts +6 -0
- package/dist/features/sources/detail/source-detail-utils.d.ts +18 -0
- package/dist/features/sources/grafana-wizard/GrafanaSourceWizard.d.ts +7 -0
- package/dist/features/sources/index.d.ts +1 -0
- package/dist/features/sources/prometheus-wizard/PrometheusSourceWizard.d.ts +5 -0
- package/dist/features/sources/source-selection/SourceSourcePickerDialog.d.ts +6 -0
- package/dist/features/workflows/components/WorkflowFilters.d.ts +11 -0
- package/dist/features/workflows/components/WorkflowFormHelper.d.ts +6 -0
- package/dist/features/workflows/components/workflows-columns.d.ts +8 -0
- package/dist/features/workflows/components/workflows-table.d.ts +17 -0
- package/dist/features/workflows/editor.d.ts +4 -0
- package/dist/features/workflows/index.d.ts +4 -1
- package/dist/hooks/useInsightPolling.d.ts +1 -0
- package/dist/index.d.ts +17 -3
- package/dist/index.js +246 -112
- package/dist/index.mjs +71807 -73140
- package/dist/router.d.ts +1 -1
- package/dist/services/insight.d.ts +285 -21
- package/dist/services/workflow.d.ts +2 -1
- package/dist/style.css +1 -1
- package/dist/types.d.ts +128 -51
- package/package.json +4 -1
- package/dist/features/alerts/components/InsightAlertCard.d.ts +0 -13
- package/dist/features/connectors/cloudwatch-wizard/CloudWatchConnectorWizard.d.ts +0 -8
- package/dist/features/connectors/components/ConnectorDetailsDialog.d.ts +0 -8
- package/dist/features/connectors/components/ConnectorFilters.d.ts +0 -18
- package/dist/features/connectors/components/ConnectorTokenPolicyDialog.d.ts +0 -11
- package/dist/features/connectors/components/InsightConnectorCard.d.ts +0 -17
- package/dist/features/connectors/components/InsightConnectorDeleteDialog.d.ts +0 -9
- package/dist/features/connectors/components/InsightConnectorForm.d.ts +0 -18
- package/dist/features/connectors/components/WebhookSuccessModal.d.ts +0 -6
- package/dist/features/connectors/grafana-wizard/GrafanaConnectorWizard.d.ts +0 -7
- package/dist/features/connectors/index.d.ts +0 -1
- package/dist/features/connectors/source-selection/ConnectorSourcePickerDialog.d.ts +0 -6
- package/dist/features/incidents/components/InsightIncidentCard.d.ts +0 -8
- package/dist/features/workflows/components/WorkflowDiagramModal.d.ts +0 -6
- package/dist/features/workflows/components/WorkflowFormDialog.d.ts +0 -7
package/dist/types.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export type
|
|
2
|
-
export type
|
|
1
|
+
export type InsightSourceType = 'meyi_pulse' | 'grafana' | 'datadog' | 'prometheus' | 'cloudwatch' | 'cloudtrail' | 'pagerduty' | 'custom';
|
|
2
|
+
export type InsightSource = {
|
|
3
3
|
id: string;
|
|
4
4
|
name: string;
|
|
5
|
-
type:
|
|
5
|
+
type: InsightSourceType;
|
|
6
6
|
alertCount?: number;
|
|
7
7
|
description?: string;
|
|
8
8
|
isActive: boolean;
|
|
@@ -13,6 +13,7 @@ export type InsightConnector = {
|
|
|
13
13
|
awsRegion?: string | null;
|
|
14
14
|
awsSelectedAlarmNames?: string[];
|
|
15
15
|
awsSelectedMetricKeys?: string[];
|
|
16
|
+
awsCreateNewTrail?: boolean;
|
|
16
17
|
awsDeploymentStatus?: 'not_started' | 'pending' | 'deployed' | 'failed' | 'deleted' | string;
|
|
17
18
|
awsDeploymentStatusReason?: string | null;
|
|
18
19
|
awsStackName?: string | null;
|
|
@@ -47,7 +48,7 @@ export type InsightConnector = {
|
|
|
47
48
|
};
|
|
48
49
|
export type InsightWebhookFailureLog = {
|
|
49
50
|
id: string;
|
|
50
|
-
|
|
51
|
+
sourceId: string | null;
|
|
51
52
|
tokenPreview?: string | null;
|
|
52
53
|
errorCode: string;
|
|
53
54
|
errorMessage: string;
|
|
@@ -58,17 +59,49 @@ export type InsightWebhookFailureLog = {
|
|
|
58
59
|
payload?: any;
|
|
59
60
|
createdAt: string;
|
|
60
61
|
};
|
|
61
|
-
export type
|
|
62
|
+
export type InsightSourceTokenPolicy = {
|
|
62
63
|
mode: 'expires' | 'unlimited';
|
|
63
64
|
expiresAt: string | null;
|
|
64
65
|
defaultTtlDays: number;
|
|
65
66
|
};
|
|
67
|
+
export type InsightSourceOverview = {
|
|
68
|
+
source: InsightSource;
|
|
69
|
+
summary: {
|
|
70
|
+
status: string;
|
|
71
|
+
lastAlarmAt: string | null;
|
|
72
|
+
alarmsToday: number;
|
|
73
|
+
errorsLastHour: number;
|
|
74
|
+
weeklyRate: {
|
|
75
|
+
day: string;
|
|
76
|
+
count: number;
|
|
77
|
+
}[];
|
|
78
|
+
webhookEndpoint: string;
|
|
79
|
+
webhookPath?: string;
|
|
80
|
+
authTokenPreview: string | null;
|
|
81
|
+
};
|
|
82
|
+
};
|
|
83
|
+
export type InsightSourceLog = {
|
|
84
|
+
id: string;
|
|
85
|
+
timestamp: string;
|
|
86
|
+
httpStatus: number;
|
|
87
|
+
sourceIp: string;
|
|
88
|
+
payloadSize: number;
|
|
89
|
+
result: string;
|
|
90
|
+
};
|
|
91
|
+
export type InsightSourceTestResult = {
|
|
92
|
+
ok: boolean;
|
|
93
|
+
sourceId: string;
|
|
94
|
+
accepted: boolean;
|
|
95
|
+
createsAlarm?: boolean;
|
|
96
|
+
receivedAt: string;
|
|
97
|
+
envelope: Record<string, any>;
|
|
98
|
+
};
|
|
66
99
|
export type InsightCloudWatchDiscoverResult = {
|
|
67
100
|
ok: boolean;
|
|
68
|
-
|
|
101
|
+
source: {
|
|
69
102
|
id: string;
|
|
70
103
|
name: string;
|
|
71
|
-
type:
|
|
104
|
+
type: InsightSourceType;
|
|
72
105
|
};
|
|
73
106
|
aws: {
|
|
74
107
|
region: string;
|
|
@@ -91,10 +124,10 @@ export type InsightCloudWatchDiscoverResult = {
|
|
|
91
124
|
};
|
|
92
125
|
export type InsightCloudWatchSetupResult = {
|
|
93
126
|
ok: boolean;
|
|
94
|
-
|
|
127
|
+
source: {
|
|
95
128
|
id: string;
|
|
96
129
|
name: string;
|
|
97
|
-
type:
|
|
130
|
+
type: InsightSourceType;
|
|
98
131
|
};
|
|
99
132
|
setup: {
|
|
100
133
|
accessKeyId: string;
|
|
@@ -110,10 +143,10 @@ export type InsightCloudWatchSetupResult = {
|
|
|
110
143
|
};
|
|
111
144
|
export type InsightCloudWatchDeployResult = {
|
|
112
145
|
ok: boolean;
|
|
113
|
-
|
|
146
|
+
source: {
|
|
114
147
|
id: string;
|
|
115
148
|
name: string;
|
|
116
|
-
type:
|
|
149
|
+
type: InsightSourceType;
|
|
117
150
|
};
|
|
118
151
|
webhook: {
|
|
119
152
|
path: string;
|
|
@@ -148,10 +181,10 @@ export type InsightCloudWatchDeployResult = {
|
|
|
148
181
|
};
|
|
149
182
|
export type InsightCloudWatchConsoleDeployResult = {
|
|
150
183
|
ok: boolean;
|
|
151
|
-
|
|
184
|
+
source: {
|
|
152
185
|
id: string;
|
|
153
186
|
name: string;
|
|
154
|
-
type:
|
|
187
|
+
type: InsightSourceType;
|
|
155
188
|
};
|
|
156
189
|
webhook: {
|
|
157
190
|
path: string;
|
|
@@ -171,17 +204,42 @@ export type InsightCloudWatchConsoleDeployResult = {
|
|
|
171
204
|
resources: string[];
|
|
172
205
|
};
|
|
173
206
|
};
|
|
207
|
+
export type InsightCloudTrailConsoleDeploy = {
|
|
208
|
+
ok: boolean;
|
|
209
|
+
source: {
|
|
210
|
+
id: string;
|
|
211
|
+
name: string;
|
|
212
|
+
type: InsightSourceType;
|
|
213
|
+
};
|
|
214
|
+
webhook: {
|
|
215
|
+
path: string;
|
|
216
|
+
url: string;
|
|
217
|
+
};
|
|
218
|
+
deployment: {
|
|
219
|
+
method: string;
|
|
220
|
+
region: string;
|
|
221
|
+
stackName: string;
|
|
222
|
+
createNewTrail: boolean;
|
|
223
|
+
deploymentStatusUrl: string;
|
|
224
|
+
templateUrl: string;
|
|
225
|
+
templateDownloadUrl: string;
|
|
226
|
+
quickCreateUrl: string;
|
|
227
|
+
isPublicTemplateUrl: boolean;
|
|
228
|
+
canPrefillTemplateUrl?: boolean;
|
|
229
|
+
resources: string[];
|
|
230
|
+
};
|
|
231
|
+
};
|
|
174
232
|
export type InsightCloudWatchLambdaOnboarding = {
|
|
175
233
|
ok: boolean;
|
|
176
|
-
|
|
234
|
+
source: {
|
|
177
235
|
id: string;
|
|
178
236
|
name: string;
|
|
179
|
-
type:
|
|
237
|
+
type: InsightSourceType;
|
|
180
238
|
};
|
|
181
239
|
webhook: {
|
|
182
240
|
path: string;
|
|
183
241
|
url: string;
|
|
184
|
-
tokenPolicy?:
|
|
242
|
+
tokenPolicy?: InsightSourceTokenPolicy;
|
|
185
243
|
isPublicHint: boolean;
|
|
186
244
|
};
|
|
187
245
|
automation: {
|
|
@@ -197,15 +255,15 @@ export type InsightCloudWatchLambdaOnboarding = {
|
|
|
197
255
|
};
|
|
198
256
|
export type InsightGrafanaOnboarding = {
|
|
199
257
|
ok: boolean;
|
|
200
|
-
|
|
258
|
+
source: {
|
|
201
259
|
id: string;
|
|
202
260
|
name: string;
|
|
203
|
-
type:
|
|
261
|
+
type: InsightSourceType;
|
|
204
262
|
};
|
|
205
263
|
webhook: {
|
|
206
264
|
path: string;
|
|
207
265
|
url: string;
|
|
208
|
-
tokenPolicy?:
|
|
266
|
+
tokenPolicy?: InsightSourceTokenPolicy;
|
|
209
267
|
isPublicHint: boolean;
|
|
210
268
|
};
|
|
211
269
|
defaults: {
|
|
@@ -258,15 +316,15 @@ export type InsightGrafanaSaveResult = {
|
|
|
258
316
|
};
|
|
259
317
|
export type InsightPrometheusOnboarding = {
|
|
260
318
|
ok: boolean;
|
|
261
|
-
|
|
319
|
+
source: {
|
|
262
320
|
id: string;
|
|
263
321
|
name: string;
|
|
264
|
-
type:
|
|
322
|
+
type: InsightSourceType;
|
|
265
323
|
};
|
|
266
324
|
webhook: {
|
|
267
325
|
path: string;
|
|
268
326
|
url: string;
|
|
269
|
-
tokenPolicy?:
|
|
327
|
+
tokenPolicy?: InsightSourceTokenPolicy;
|
|
270
328
|
isPublicHint: boolean;
|
|
271
329
|
};
|
|
272
330
|
defaults: {
|
|
@@ -300,15 +358,15 @@ export type InsightPrometheusOnboarding = {
|
|
|
300
358
|
};
|
|
301
359
|
export type InsightDatadogOnboarding = {
|
|
302
360
|
ok: boolean;
|
|
303
|
-
|
|
361
|
+
source: {
|
|
304
362
|
id: string;
|
|
305
363
|
name: string;
|
|
306
|
-
type:
|
|
364
|
+
type: InsightSourceType;
|
|
307
365
|
};
|
|
308
366
|
webhook: {
|
|
309
367
|
path: string;
|
|
310
368
|
url: string;
|
|
311
|
-
tokenPolicy?:
|
|
369
|
+
tokenPolicy?: InsightSourceTokenPolicy;
|
|
312
370
|
isPublicHint: boolean;
|
|
313
371
|
};
|
|
314
372
|
defaults: {
|
|
@@ -335,9 +393,9 @@ export type InsightAlertStatus = 'open' | 'converted' | 'dismissed';
|
|
|
335
393
|
export type InsightAlert = {
|
|
336
394
|
id: string;
|
|
337
395
|
aliasId?: string;
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
396
|
+
sourceId?: string;
|
|
397
|
+
sourceName?: string;
|
|
398
|
+
sourceType?: string;
|
|
341
399
|
resourceId: string;
|
|
342
400
|
resourceName: string;
|
|
343
401
|
resourceType: string;
|
|
@@ -349,8 +407,16 @@ export type InsightAlert = {
|
|
|
349
407
|
incidentId?: string;
|
|
350
408
|
incidentAssigneeId?: string | null;
|
|
351
409
|
downTime: string;
|
|
410
|
+
dupCount?: number;
|
|
411
|
+
lastDupAt?: string | null;
|
|
352
412
|
createdAt: string;
|
|
353
413
|
updatedAt: string;
|
|
414
|
+
pipelineStatus?: string | null;
|
|
415
|
+
fingerprint?: string | null;
|
|
416
|
+
dedupKey?: string | null;
|
|
417
|
+
groupId?: string | null;
|
|
418
|
+
additionalConfiguration?: Record<string, any>;
|
|
419
|
+
rawPayload?: unknown;
|
|
354
420
|
};
|
|
355
421
|
export type InsightAlertSummary = {
|
|
356
422
|
total: number;
|
|
@@ -385,6 +451,9 @@ export type InsightNotificationProvider = {
|
|
|
385
451
|
provider_name: string;
|
|
386
452
|
display_name: string;
|
|
387
453
|
icon?: string;
|
|
454
|
+
is_enabled?: boolean;
|
|
455
|
+
config?: Record<string, any>;
|
|
456
|
+
description?: string;
|
|
388
457
|
};
|
|
389
458
|
export type InsightIncidentComment = {
|
|
390
459
|
id: string;
|
|
@@ -404,6 +473,7 @@ export type InsightIncident = {
|
|
|
404
473
|
projectTag?: string;
|
|
405
474
|
downTime: string | null;
|
|
406
475
|
resolvedAt?: string;
|
|
476
|
+
status: "open" | "in_progress" | "resolved" | "closed";
|
|
407
477
|
analysisStatus: "pending" | "triggered" | "processing" | "completed" | "failed";
|
|
408
478
|
progressPercent: number;
|
|
409
479
|
analysisTriggeredAt?: string | null;
|
|
@@ -415,9 +485,20 @@ export type InsightIncident = {
|
|
|
415
485
|
alertId?: string | null;
|
|
416
486
|
assigneeIds?: string[];
|
|
417
487
|
comments?: InsightIncidentComment[];
|
|
488
|
+
events?: InsightIncidentEvent[];
|
|
418
489
|
createdAt: string;
|
|
419
490
|
updatedAt: string;
|
|
420
491
|
};
|
|
492
|
+
export type InsightIncidentEvent = {
|
|
493
|
+
id: string;
|
|
494
|
+
incidentId: string;
|
|
495
|
+
type: "created" | "status_change" | "assigned" | "analysis" | "comment" | string;
|
|
496
|
+
actor?: string | null;
|
|
497
|
+
message?: string | null;
|
|
498
|
+
beforeValue?: string | null;
|
|
499
|
+
afterValue?: string | null;
|
|
500
|
+
createdAt: string;
|
|
501
|
+
};
|
|
421
502
|
export type InsightAnalysisResult = {
|
|
422
503
|
event_id: string;
|
|
423
504
|
instance_id: string;
|
|
@@ -489,6 +570,7 @@ export type InsightAnalysisResult = {
|
|
|
489
570
|
};
|
|
490
571
|
is_complete: boolean;
|
|
491
572
|
is_failed: boolean;
|
|
573
|
+
error?: string;
|
|
492
574
|
};
|
|
493
575
|
export type NewInsightAnalysisResult = {
|
|
494
576
|
summary?: string;
|
|
@@ -513,6 +595,7 @@ export type NewInsightAnalysisResult = {
|
|
|
513
595
|
dependency_impact?: string[];
|
|
514
596
|
probable_root_cause?: string;
|
|
515
597
|
recommended_actions?: string[];
|
|
598
|
+
error?: string;
|
|
516
599
|
};
|
|
517
600
|
export type NewRemediationSteps = {
|
|
518
601
|
immediate_actions?: string[];
|
|
@@ -520,10 +603,10 @@ export type NewRemediationSteps = {
|
|
|
520
603
|
rollback_steps?: string[];
|
|
521
604
|
communication_template?: string;
|
|
522
605
|
};
|
|
523
|
-
/** @deprecated Use
|
|
524
|
-
export type
|
|
606
|
+
/** @deprecated Use InsightSource */
|
|
607
|
+
export type CloudSource = InsightSource;
|
|
525
608
|
export type InsightSopSeverity = 'critical' | 'high' | 'medium' | 'low';
|
|
526
|
-
export type InsightSopStatus = 'draft' | 'pending' | 'approved' | 'generating';
|
|
609
|
+
export type InsightSopStatus = 'draft' | 'pending' | 'approved' | 'generating' | 'failed';
|
|
527
610
|
export type InsightSop = {
|
|
528
611
|
id: string;
|
|
529
612
|
sopId: string;
|
|
@@ -539,38 +622,32 @@ export type InsightSop = {
|
|
|
539
622
|
source?: string;
|
|
540
623
|
project?: string;
|
|
541
624
|
steps?: string;
|
|
625
|
+
error_response?: string | null;
|
|
542
626
|
createdBy?: string;
|
|
543
627
|
createdAt: string;
|
|
544
628
|
updatedAt: string;
|
|
545
629
|
};
|
|
546
|
-
export type InsightWorkflowConditionField = 'source' | 'resource' | 'severity' | 'project' | 'alertName';
|
|
547
|
-
export type InsightWorkflowConditionOperator = 'equals' | 'contains' | 'startsWith' | 'endsWith' | 'in';
|
|
548
|
-
export type InsightWorkflowConditionRule = {
|
|
549
|
-
field: InsightWorkflowConditionField;
|
|
550
|
-
operator: InsightWorkflowConditionOperator;
|
|
551
|
-
value: string | string[];
|
|
552
|
-
};
|
|
553
|
-
export type InsightWorkflowConditionGroup = {
|
|
554
|
-
groupId: string;
|
|
555
|
-
operator: 'AND' | 'OR';
|
|
556
|
-
rules: InsightWorkflowConditionRule[];
|
|
557
|
-
};
|
|
558
|
-
export type InsightWorkflowActionType = 'create_incident' | 'assign_incident' | 'generate_rca' | 'generate_sop' | 'send_notification' | 'skip_alert';
|
|
559
|
-
export type InsightWorkflowAction = {
|
|
560
|
-
type: InsightWorkflowActionType;
|
|
561
|
-
config: Record<string, any>;
|
|
562
|
-
};
|
|
563
630
|
export type InsightWorkflow = {
|
|
564
631
|
id: string;
|
|
565
632
|
name: string;
|
|
566
|
-
description: string | null;
|
|
567
633
|
isActive: boolean;
|
|
568
634
|
priority: number;
|
|
569
|
-
|
|
570
|
-
actions: InsightWorkflowAction[];
|
|
635
|
+
yamlDefinition: string;
|
|
571
636
|
createdAt: string;
|
|
572
637
|
updatedAt: string;
|
|
573
638
|
};
|
|
639
|
+
export type YamlParseResult = {
|
|
640
|
+
ok: boolean;
|
|
641
|
+
definition?: {
|
|
642
|
+
name: string;
|
|
643
|
+
description?: string;
|
|
644
|
+
priority: number;
|
|
645
|
+
active: boolean;
|
|
646
|
+
conditions: any[];
|
|
647
|
+
actions: any[];
|
|
648
|
+
};
|
|
649
|
+
errors?: string[];
|
|
650
|
+
};
|
|
574
651
|
export type InsightWorkflowExecution = {
|
|
575
652
|
id: string;
|
|
576
653
|
workflowId: string;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "meyi-insight-ui-dev",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.4",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"module": "./dist/index.mjs",
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
"react-dom": "^19.0.0"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
+
"@monaco-editor/react": "^4.7.0",
|
|
31
32
|
"@radix-ui/react-alert-dialog": "^1.1.16",
|
|
32
33
|
"@radix-ui/react-checkbox": "^1.3.4",
|
|
33
34
|
"@radix-ui/react-dialog": "^1.1.15",
|
|
@@ -51,6 +52,7 @@
|
|
|
51
52
|
"clsx": "^2.1.0",
|
|
52
53
|
"cmdk": "^1.1.1",
|
|
53
54
|
"date-fns": "^4.4.0",
|
|
55
|
+
"js-yaml": "^4.2.0",
|
|
54
56
|
"lucide-react": "^0.545.0",
|
|
55
57
|
"next-remove-imports": "^1.0.13",
|
|
56
58
|
"socket.io-client": "^4.8.1",
|
|
@@ -61,6 +63,7 @@
|
|
|
61
63
|
},
|
|
62
64
|
"devDependencies": {
|
|
63
65
|
"@tailwindcss/vite": "^4.1.0",
|
|
66
|
+
"@types/js-yaml": "^4.0.9",
|
|
64
67
|
"@types/node": "^20.0.0",
|
|
65
68
|
"@types/react": "^19.0.0",
|
|
66
69
|
"@types/react-dom": "^19.0.0",
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InsightAlert } from '../../../types.js';
|
|
2
|
-
interface InsightAlertCardProps {
|
|
3
|
-
alert: InsightAlert;
|
|
4
|
-
deletingId: string | null;
|
|
5
|
-
onViewIncident: (id: string) => void;
|
|
6
|
-
onConvert: (alert: InsightAlert) => void;
|
|
7
|
-
onGenerateSop?: (alert: InsightAlert) => void;
|
|
8
|
-
generatingSopId?: string | null;
|
|
9
|
-
sopId?: string | null;
|
|
10
|
-
onDelete: (id: string) => void;
|
|
11
|
-
}
|
|
12
|
-
export declare function InsightAlertCard({ alert, deletingId, onViewIncident, onConvert, onGenerateSop, generatingSopId, sopId, onDelete, }: InsightAlertCardProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
export {};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
export declare function CloudWatchConnectorWizard({ open, onOpenChange, onCreated, connector, onAccessKeyDeploy, }: {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onOpenChange: (open: boolean) => void;
|
|
5
|
-
onCreated: () => void;
|
|
6
|
-
connector?: InsightConnector | null;
|
|
7
|
-
onAccessKeyDeploy?: (connector: InsightConnector) => void;
|
|
8
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
interface ConnectorDetailsDialogProps {
|
|
3
|
-
open: boolean;
|
|
4
|
-
connector: InsightConnector | null;
|
|
5
|
-
onOpenChange: (open: boolean) => void;
|
|
6
|
-
}
|
|
7
|
-
export declare function ConnectorDetailsDialog({ open, connector, onOpenChange }: ConnectorDetailsDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
-
export {};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { InsightConnectorType } from '../../../types.js';
|
|
2
|
-
export type ConnectorFiltersState = {
|
|
3
|
-
sourceTypes: InsightConnectorType[];
|
|
4
|
-
};
|
|
5
|
-
interface Props {
|
|
6
|
-
search: string;
|
|
7
|
-
filters: ConnectorFiltersState;
|
|
8
|
-
loading?: boolean;
|
|
9
|
-
onSearchChange: (value: string) => void;
|
|
10
|
-
onFiltersChange: (filters: ConnectorFiltersState) => void;
|
|
11
|
-
onRefresh: () => void;
|
|
12
|
-
onAdd: () => void;
|
|
13
|
-
}
|
|
14
|
-
export declare function getDefaultConnectorFilters(): {
|
|
15
|
-
sourceTypes: InsightConnectorType[];
|
|
16
|
-
};
|
|
17
|
-
export declare function ConnectorFilters({ search, filters, loading, onSearchChange, onFiltersChange, onRefresh, onAdd, }: Props): import("react/jsx-runtime").JSX.Element;
|
|
18
|
-
export {};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
interface ConnectorTokenPolicyDialogProps {
|
|
3
|
-
open: boolean;
|
|
4
|
-
connector: InsightConnector | null;
|
|
5
|
-
loading?: boolean;
|
|
6
|
-
submitting?: boolean;
|
|
7
|
-
onOpenChange: (open: boolean) => void;
|
|
8
|
-
onSubmit: (mode: "expires" | "unlimited", ttlDays?: number) => Promise<void>;
|
|
9
|
-
}
|
|
10
|
-
export declare function ConnectorTokenPolicyDialog({ open, connector, loading, submitting, onOpenChange, onSubmit, }: ConnectorTokenPolicyDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
export {};
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
interface InsightConnectorCardProps {
|
|
3
|
-
connector: InsightConnector;
|
|
4
|
-
deletingId: string | null;
|
|
5
|
-
rotatingId: string | null;
|
|
6
|
-
onView: (connector: InsightConnector) => void;
|
|
7
|
-
onEdit: (connector: InsightConnector) => void;
|
|
8
|
-
onRotate: (id: string) => void;
|
|
9
|
-
onDelete: (id: string) => void;
|
|
10
|
-
onManageTokenPolicy: (connector: InsightConnector) => void;
|
|
11
|
-
onAwsSetup: (connector: InsightConnector) => void;
|
|
12
|
-
onGrafanaSetup: (connector: InsightConnector) => void;
|
|
13
|
-
onPrometheusSetup: (connector: InsightConnector) => void;
|
|
14
|
-
onDatadogSetup: (connector: InsightConnector) => void;
|
|
15
|
-
}
|
|
16
|
-
export declare function InsightConnectorCard({ connector, deletingId, rotatingId, onView, onEdit, onRotate, onDelete, onManageTokenPolicy, onAwsSetup, onGrafanaSetup, onPrometheusSetup, onDatadogSetup, }: InsightConnectorCardProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
interface InsightConnectorDeleteDialogProps {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onOpenChange: (open: boolean) => void;
|
|
5
|
-
connector: InsightConnector | null;
|
|
6
|
-
onConfirm: () => Promise<void>;
|
|
7
|
-
}
|
|
8
|
-
export declare function InsightConnectorDeleteDialog({ open, onOpenChange, connector, onConfirm, }: InsightConnectorDeleteDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export {};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { InsightConnector, InsightConnectorType } from '../../../types.js';
|
|
2
|
-
export declare const CONNECTOR_META: Record<InsightConnectorType, {
|
|
3
|
-
label: string;
|
|
4
|
-
Icon: any;
|
|
5
|
-
color: string;
|
|
6
|
-
}>;
|
|
7
|
-
interface InsightConnectorFormProps {
|
|
8
|
-
open: boolean;
|
|
9
|
-
connector: InsightConnector | null;
|
|
10
|
-
submitting: boolean;
|
|
11
|
-
onClose: () => void;
|
|
12
|
-
onSubmit: (name: string, type: InsightConnectorType, description?: string) => void;
|
|
13
|
-
createdWebhookUrl?: string | null;
|
|
14
|
-
onWebhookModalClose?: () => void;
|
|
15
|
-
initialType?: InsightConnectorType | null;
|
|
16
|
-
}
|
|
17
|
-
export declare function InsightConnectorForm({ open, connector, submitting, onClose, onSubmit, createdWebhookUrl, onWebhookModalClose, initialType, }: InsightConnectorFormProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
-
export {};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { InsightConnectorType } from '../../../types.js';
|
|
2
|
-
export declare function WebhookSuccessModal({ webhookUrl, connectorType, onClose, }: {
|
|
3
|
-
webhookUrl: string;
|
|
4
|
-
connectorType: InsightConnectorType;
|
|
5
|
-
onClose: () => void;
|
|
6
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { InsightConnector } from '../../../types.js';
|
|
2
|
-
export declare function GrafanaConnectorWizard({ open, connector, onOpenChange, onCreated, }: {
|
|
3
|
-
open: boolean;
|
|
4
|
-
connector?: InsightConnector | null;
|
|
5
|
-
onOpenChange: (open: boolean) => void;
|
|
6
|
-
onCreated: () => void;
|
|
7
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function InsightConnectorsPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { InsightConnectorType } from '../../../types.js';
|
|
2
|
-
export declare function ConnectorSourcePickerDialog({ open, onOpenChange, onSelect, }: {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onOpenChange: (open: boolean) => void;
|
|
5
|
-
onSelect: (type: InsightConnectorType) => void;
|
|
6
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { InsightIncident } from '../../../types.js';
|
|
2
|
-
interface Props {
|
|
3
|
-
incident: InsightIncident;
|
|
4
|
-
onViewResult: (id: string) => void;
|
|
5
|
-
onAssignClick: (incident: InsightIncident) => void;
|
|
6
|
-
}
|
|
7
|
-
export declare function InsightIncidentCard({ incident: init, onViewResult, onAssignClick }: Props): import("react/jsx-runtime").JSX.Element;
|
|
8
|
-
export {};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { InsightWorkflow } from '../../../types.js';
|
|
2
|
-
export declare function WorkflowDiagramModal({ open, onOpenChange, workflow, }: {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onOpenChange: (open: boolean) => void;
|
|
5
|
-
workflow?: InsightWorkflow;
|
|
6
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { InsightWorkflow } from '../../../types.js';
|
|
2
|
-
export declare function WorkflowFormDialog({ open, onOpenChange, workflow, onSaved, }: {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onOpenChange: (open: boolean) => void;
|
|
5
|
-
workflow?: InsightWorkflow;
|
|
6
|
-
onSaved: () => void;
|
|
7
|
-
}): import("react/jsx-runtime").JSX.Element;
|