react-semaphor 0.1.204 → 0.1.206
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/chunks/dashboard-controls-C4k6KdEB.js +42 -0
- package/dist/chunks/dashboard-controls-IqiP9Ced.js +1584 -0
- package/dist/chunks/{dashboard-json-Dh8csIFq.js → dashboard-json-BJPB6xym.js} +1 -1
- package/dist/chunks/{dashboard-json-Cwh8kbV9.js → dashboard-json-c0VOKYtt.js} +5 -5
- package/dist/chunks/{dashboard-summary-settings-dialog-BL4vn4lZ.js → dashboard-summary-settings-dialog-Dah4-mPH.js} +55 -55
- package/dist/chunks/{dashboard-summary-settings-dialog-_3iUVFkC.js → dashboard-summary-settings-dialog-VQizO_RC.js} +1 -1
- package/dist/chunks/{edit-dashboard-visual-DEc3lB9j.js → edit-dashboard-visual-CKzW9rIq.js} +928 -914
- package/dist/chunks/{edit-dashboard-visual-RiCeBX0X.js → edit-dashboard-visual-DR_akSsE.js} +9 -9
- package/dist/chunks/{editor-action-buttons-BfLWRprW.js → editor-action-buttons-B37Prd2u.js} +1 -1
- package/dist/chunks/{editor-action-buttons-DovtyKKL.js → editor-action-buttons-BNtBfjRb.js} +65 -65
- package/dist/chunks/index-Blxyx1RI.js +1104 -0
- package/dist/chunks/{index-DaQXz6Oi.js → index-WddCUrXL.js} +33783 -29921
- package/dist/chunks/{notification-bell-Cn3-W-S3.js → notification-bell-BTyIV2CU.js} +309 -311
- package/dist/chunks/notification-bell-Cg8FpAHU.js +11 -0
- package/dist/chunks/{resource-management-panel-qsbMXn91.js → resource-management-panel-B5mqCUlS.js} +188 -188
- package/dist/chunks/{resource-management-panel-DBnpAHFb.js → resource-management-panel-CAi_lrWp.js} +1 -1
- package/dist/chunks/{use-role-aware-display-preferences-B22nZN2c.js → use-role-aware-display-preferences-BcJJSdZI.js} +1 -1
- package/dist/chunks/{use-role-aware-display-preferences-CnipXO4k.js → use-role-aware-display-preferences-_P6XHADA.js} +1 -1
- package/dist/chunks/{use-visual-utils-JlfPxiXq.js → use-visual-utils-BH_uSsT6.js} +1 -1
- package/dist/chunks/{use-visual-utils-B9X7-yfe.js → use-visual-utils-CGo5Mdwh.js} +28 -28
- package/dist/dashboard/index.cjs +1 -1
- package/dist/dashboard/index.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +258 -173
- package/dist/style.css +1 -1
- package/dist/surfboard/index.cjs +1 -1
- package/dist/surfboard/index.js +2 -2
- package/dist/types/main.d.ts +826 -3
- package/dist/types/types.d.ts +222 -0
- package/package.json +2 -1
- package/dist/chunks/dashboard-controls-D5VrI40y.js +0 -42
- package/dist/chunks/dashboard-controls-p7I_UrIz.js +0 -1661
- package/dist/chunks/index-CpnMO9b6.js +0 -1087
- package/dist/chunks/notification-bell-DsJcuxld.js +0 -11
package/dist/types/main.d.ts
CHANGED
|
@@ -1,19 +1,23 @@
|
|
|
1
1
|
import { Chart as Chart_2 } from 'chart.js';
|
|
2
2
|
import { ChartConfiguration } from 'chart.js';
|
|
3
|
+
import { ClassProp } from 'class-variance-authority/types';
|
|
3
4
|
import { ColumnSizingState } from '@tanstack/react-table';
|
|
4
5
|
import { DateRange } from 'react-day-picker';
|
|
5
6
|
import { default as default_2 } from 'react-grid-layout';
|
|
7
|
+
import { FetchStatus } from '@tanstack/react-query';
|
|
6
8
|
import { FontSpec } from 'chart.js';
|
|
7
9
|
import { JSX } from 'react/jsx-runtime';
|
|
8
10
|
import { JSX as JSX_2 } from 'react';
|
|
9
|
-
import { QueryObserverResult } from '@tanstack/query
|
|
11
|
+
import { QueryObserverResult } from '@tanstack/react-query';
|
|
10
12
|
import * as React_2 from 'react';
|
|
11
|
-
import { RefetchOptions } from '@tanstack/query
|
|
13
|
+
import { RefetchOptions } from '@tanstack/react-query';
|
|
12
14
|
import { StoreApi } from 'zustand';
|
|
13
15
|
import { UseBoundStore } from 'zustand';
|
|
14
16
|
import { UseMutateAsyncFunction } from '@tanstack/react-query';
|
|
15
17
|
import { UseMutateFunction } from '@tanstack/react-query';
|
|
18
|
+
import { UseMutationResult } from '@tanstack/react-query';
|
|
16
19
|
import { UseQueryResult } from '@tanstack/react-query';
|
|
20
|
+
import { VariantProps } from 'class-variance-authority';
|
|
17
21
|
import { WritableDraft } from 'immer';
|
|
18
22
|
|
|
19
23
|
declare type Actions = {
|
|
@@ -303,6 +307,248 @@ export declare type AIScopeTable = {
|
|
|
303
307
|
datamodelName: string;
|
|
304
308
|
};
|
|
305
309
|
|
|
310
|
+
export declare interface Alert {
|
|
311
|
+
id: string;
|
|
312
|
+
kind?: 'ALERT';
|
|
313
|
+
name: string;
|
|
314
|
+
description?: string | null;
|
|
315
|
+
status: AlertStatus;
|
|
316
|
+
scheduleExpr: string;
|
|
317
|
+
timezone: string;
|
|
318
|
+
nextRunAt?: string | null;
|
|
319
|
+
lastRunAt?: string | null;
|
|
320
|
+
lastRunStatus?: string | null;
|
|
321
|
+
sourceHealth?: 'OK' | 'SOURCE_MISSING' | 'SOURCE_ERROR' | 'STALE';
|
|
322
|
+
alertState?: AlertState | null;
|
|
323
|
+
jobConfig: AlertJobConfig;
|
|
324
|
+
deliveryConfig: {
|
|
325
|
+
recipients: AlertRecipient[];
|
|
326
|
+
channels: AlertDeliveryChannel[];
|
|
327
|
+
subject?: string;
|
|
328
|
+
message?: string;
|
|
329
|
+
};
|
|
330
|
+
createdAt: string;
|
|
331
|
+
updatedAt: string;
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
export declare interface AlertBacktestResult {
|
|
335
|
+
ruleId?: string;
|
|
336
|
+
evaluationCount: number;
|
|
337
|
+
transitionsWithoutDampening: number;
|
|
338
|
+
transitionsWithDampening: number;
|
|
339
|
+
recommendation?: string | null;
|
|
340
|
+
firingEpisodes?: Array<{
|
|
341
|
+
triggeredAt: string;
|
|
342
|
+
recoveredAt: string | null;
|
|
343
|
+
durationMinutes: number;
|
|
344
|
+
peakValue: number;
|
|
345
|
+
}>;
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
export declare type AlertConditionOperator = 'gt' | 'gte' | 'lt' | 'lte' | 'eq' | 'neq' | 'pct_change_gt' | 'pct_change_lt';
|
|
349
|
+
|
|
350
|
+
export declare type AlertContextAuthoringMode = 'basic' | 'conversational' | 'manual';
|
|
351
|
+
|
|
352
|
+
export declare interface AlertContextInterpretResponse {
|
|
353
|
+
workflowDef: Record<string, unknown>;
|
|
354
|
+
contextSources: ContextSource[];
|
|
355
|
+
explanation?: string;
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
export declare type AlertContextSourceKind = 'trend_window' | 'peer_comparison' | 'related_metric' | 'breakdown' | 'custom_query';
|
|
359
|
+
|
|
360
|
+
export declare function AlertCreationDialog({ open, onOpenChange, prefilledSource, prefilledSeries, onCreated, contextBuilderEnabled, }: AlertCreationDialogProps): JSX.Element;
|
|
361
|
+
|
|
362
|
+
declare type AlertCreationDialogProps = {
|
|
363
|
+
open: boolean;
|
|
364
|
+
onOpenChange: (open: boolean) => void;
|
|
365
|
+
prefilledSource?: AlertSource;
|
|
366
|
+
prefilledSeries?: BacktestPoint[];
|
|
367
|
+
onCreated?: (alertId: string) => void;
|
|
368
|
+
contextBuilderEnabled?: boolean;
|
|
369
|
+
};
|
|
370
|
+
|
|
371
|
+
export declare interface AlertDeliverablePreview {
|
|
372
|
+
mode: 'standard_fallback' | 'custom';
|
|
373
|
+
html: string;
|
|
374
|
+
warnings?: string[];
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
export declare type AlertDeliveryChannel = 'EMAIL' | 'WEBHOOK' | 'SLACK' | 'IN_APP';
|
|
378
|
+
|
|
379
|
+
declare type AlertDraft = Partial<CreateAlertRequest> & {
|
|
380
|
+
contextSources?: ContextSource[];
|
|
381
|
+
presentationPrompt?: string;
|
|
382
|
+
};
|
|
383
|
+
|
|
384
|
+
declare type AlertFilters = {
|
|
385
|
+
status: 'all' | 'ACTIVE' | 'PAUSED' | 'DISABLED';
|
|
386
|
+
query: string;
|
|
387
|
+
};
|
|
388
|
+
|
|
389
|
+
export declare interface AlertHistoryResponse {
|
|
390
|
+
ruleId: string;
|
|
391
|
+
windowDays: number;
|
|
392
|
+
totalFirings: number;
|
|
393
|
+
averageFiringDurationMinutes: number;
|
|
394
|
+
longestFiring: {
|
|
395
|
+
triggeredAt: string;
|
|
396
|
+
recoveredAt: string | null;
|
|
397
|
+
durationMinutes: number;
|
|
398
|
+
triggerValue: number | null;
|
|
399
|
+
recoveryValue: number | null;
|
|
400
|
+
} | null;
|
|
401
|
+
shortestFiring: {
|
|
402
|
+
triggeredAt: string;
|
|
403
|
+
recoveredAt: string | null;
|
|
404
|
+
durationMinutes: number;
|
|
405
|
+
triggerValue: number | null;
|
|
406
|
+
recoveryValue: number | null;
|
|
407
|
+
} | null;
|
|
408
|
+
totalFiringMinutes: number;
|
|
409
|
+
firingPercentage: number;
|
|
410
|
+
episodes: Array<{
|
|
411
|
+
triggeredAt: string;
|
|
412
|
+
recoveredAt: string | null;
|
|
413
|
+
durationMinutes: number;
|
|
414
|
+
triggerValue: number | null;
|
|
415
|
+
recoveryValue: number | null;
|
|
416
|
+
}>;
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
export declare type AlertJobConfig = {
|
|
420
|
+
kind: 'ALERT';
|
|
421
|
+
source: AlertSource;
|
|
422
|
+
operator: AlertConditionOperator;
|
|
423
|
+
threshold: number;
|
|
424
|
+
severity: AlertSeverity;
|
|
425
|
+
consecutiveCount?: number;
|
|
426
|
+
notifyPolicy: 'on_state_change';
|
|
427
|
+
contextAuthoringMode?: AlertContextAuthoringMode;
|
|
428
|
+
contextSources?: ContextSource[];
|
|
429
|
+
presentationPrompt?: string;
|
|
430
|
+
};
|
|
431
|
+
|
|
432
|
+
export declare function AlertManagementPage({ scope, prefilledSource, }: AlertManagementPageProps): JSX.Element;
|
|
433
|
+
|
|
434
|
+
declare type AlertManagementPageProps = {
|
|
435
|
+
scope?: AlertManagementScope;
|
|
436
|
+
prefilledSource?: AlertSource;
|
|
437
|
+
};
|
|
438
|
+
|
|
439
|
+
declare type AlertManagementScope = {
|
|
440
|
+
dashboardId?: string;
|
|
441
|
+
cardId?: string;
|
|
442
|
+
};
|
|
443
|
+
|
|
444
|
+
export declare interface AlertQuotaPolicy {
|
|
445
|
+
maxActiveAlerts: number;
|
|
446
|
+
minCadenceMinutes: number;
|
|
447
|
+
maxContextSources: number;
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
export declare interface AlertQuotaRecord {
|
|
451
|
+
tenantId: string | null;
|
|
452
|
+
policy: AlertQuotaPolicy;
|
|
453
|
+
activeAlerts: number;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
export declare type AlertRecipient = {
|
|
457
|
+
type: 'email';
|
|
458
|
+
address: string;
|
|
459
|
+
name?: string;
|
|
460
|
+
} | {
|
|
461
|
+
type: 'user';
|
|
462
|
+
userId: string;
|
|
463
|
+
} | {
|
|
464
|
+
type: 'tenant_user';
|
|
465
|
+
tenantUserId: string;
|
|
466
|
+
} | {
|
|
467
|
+
type: 'group';
|
|
468
|
+
groupId: string;
|
|
469
|
+
};
|
|
470
|
+
|
|
471
|
+
export declare interface AlertRun {
|
|
472
|
+
id: string;
|
|
473
|
+
ruleId: string;
|
|
474
|
+
status: 'QUEUED' | 'RUNNING' | 'SUCCESS' | 'FAILED';
|
|
475
|
+
scheduledFor: string;
|
|
476
|
+
startedAt?: string | null;
|
|
477
|
+
completedAt?: string | null;
|
|
478
|
+
error?: string | null;
|
|
479
|
+
result?: Record<string, unknown> | null;
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
export declare class AlertsApiError extends Error {
|
|
483
|
+
readonly status: number;
|
|
484
|
+
readonly details?: unknown | undefined;
|
|
485
|
+
constructor(message: string, status: number, details?: unknown | undefined);
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
export declare type AlertSeverity = 'LOW' | 'MEDIUM' | 'HIGH' | 'CRITICAL';
|
|
489
|
+
|
|
490
|
+
export declare type AlertSource = {
|
|
491
|
+
type: 'saved_metric';
|
|
492
|
+
metricId: string;
|
|
493
|
+
title?: string;
|
|
494
|
+
} | {
|
|
495
|
+
type: 'dashboard_metric';
|
|
496
|
+
dashboardId: string;
|
|
497
|
+
visualId: string;
|
|
498
|
+
cardId: string;
|
|
499
|
+
title?: string;
|
|
500
|
+
executionSnapshot: {
|
|
501
|
+
queryConfig: Record<string, unknown>;
|
|
502
|
+
filterContext: Record<string, unknown>;
|
|
503
|
+
formattingContext: Record<string, unknown>;
|
|
504
|
+
connectionId: string;
|
|
505
|
+
calendarContext?: {
|
|
506
|
+
tz: string;
|
|
507
|
+
weekStart: number;
|
|
508
|
+
};
|
|
509
|
+
};
|
|
510
|
+
};
|
|
511
|
+
|
|
512
|
+
export declare interface AlertState {
|
|
513
|
+
currentState: AlertStateValue;
|
|
514
|
+
lastEvaluatedAt?: string | null;
|
|
515
|
+
lastValue?: string | null;
|
|
516
|
+
lastTriggeredAt?: string | null;
|
|
517
|
+
lastRecoveredAt?: string | null;
|
|
518
|
+
consecutiveTrue: number;
|
|
519
|
+
consecutiveFalse: number;
|
|
520
|
+
firingDurationMinutes?: number | null;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
export declare type AlertStateValue = 'OK' | 'FIRING';
|
|
524
|
+
|
|
525
|
+
export declare type AlertStatus = 'ACTIVE' | 'PAUSED' | 'DISABLED';
|
|
526
|
+
|
|
527
|
+
export declare type AlertStore = AlertStoreState & {
|
|
528
|
+
actions: AlertStoreActions;
|
|
529
|
+
};
|
|
530
|
+
|
|
531
|
+
declare type AlertStoreActions = {
|
|
532
|
+
upsertAlerts: (alerts: Alert[]) => void;
|
|
533
|
+
upsertAlert: (alert: Alert) => void;
|
|
534
|
+
removeAlert: (id: string) => void;
|
|
535
|
+
selectAlert: (id: string | null) => void;
|
|
536
|
+
setCreateDialogOpen: (open: boolean) => void;
|
|
537
|
+
setFilters: (filters: Partial<AlertFilters>) => void;
|
|
538
|
+
setDraft: (draft: Partial<AlertDraft>) => void;
|
|
539
|
+
resetDraft: () => void;
|
|
540
|
+
patchAlert: (id: string, patch: UpdateAlertRequest) => void;
|
|
541
|
+
};
|
|
542
|
+
|
|
543
|
+
declare type AlertStoreState = {
|
|
544
|
+
alertsById: Record<string, Alert>;
|
|
545
|
+
cardAlertMap: Map<string, string[]>;
|
|
546
|
+
selectedAlertId: string | null;
|
|
547
|
+
createDialogOpen: boolean;
|
|
548
|
+
filters: AlertFilters;
|
|
549
|
+
draft: AlertDraft;
|
|
550
|
+
};
|
|
551
|
+
|
|
306
552
|
export declare type AssistantId = 'dashboard-assistant' | 'editor-assistant';
|
|
307
553
|
|
|
308
554
|
export declare type AuthToken = {
|
|
@@ -348,6 +594,13 @@ export declare type AxisConfig = {
|
|
|
348
594
|
};
|
|
349
595
|
};
|
|
350
596
|
|
|
597
|
+
export declare function backtestAlert(apiServiceUrl: string, token: string, id: string | undefined, payload?: Record<string, unknown>): Promise<AlertBacktestResult>;
|
|
598
|
+
|
|
599
|
+
declare type BacktestPoint = {
|
|
600
|
+
at: string;
|
|
601
|
+
value: number;
|
|
602
|
+
};
|
|
603
|
+
|
|
351
604
|
export declare interface BaseColumn {
|
|
352
605
|
id: string;
|
|
353
606
|
name: string;
|
|
@@ -380,6 +633,15 @@ export declare interface BaseInteractionEvent {
|
|
|
380
633
|
|
|
381
634
|
export declare type Breakpoint = 'lg' | 'md' | 'sm' | 'xs' | 'xxs';
|
|
382
635
|
|
|
636
|
+
declare interface ButtonProps extends React_2.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
637
|
+
asChild?: boolean;
|
|
638
|
+
}
|
|
639
|
+
|
|
640
|
+
declare const buttonVariants: (props?: ({
|
|
641
|
+
variant?: "default" | "link" | "outline" | "destructive" | "secondary" | "ghost" | null | undefined;
|
|
642
|
+
size?: "default" | "lg" | "sm" | "icon" | null | undefined;
|
|
643
|
+
} & ClassProp) | undefined) => string;
|
|
644
|
+
|
|
383
645
|
export declare type CacheConfig = {
|
|
384
646
|
ttl: string;
|
|
385
647
|
status: 'on' | 'on-refresh' | 'off';
|
|
@@ -492,6 +754,12 @@ declare interface CalendarPreferencesDialogProps {
|
|
|
492
754
|
*/
|
|
493
755
|
export declare function cancelExport(apiServiceUrl: string, token: string, exportId: string): Promise<void>;
|
|
494
756
|
|
|
757
|
+
export declare function CardAlertIndicator({ cardId }: CardAlertIndicatorProps): JSX.Element | null;
|
|
758
|
+
|
|
759
|
+
declare type CardAlertIndicatorProps = {
|
|
760
|
+
cardId: string;
|
|
761
|
+
};
|
|
762
|
+
|
|
495
763
|
export declare interface CardConfig {
|
|
496
764
|
groupByColumns?: GroupByField[];
|
|
497
765
|
metricColumns?: MetricField[];
|
|
@@ -770,6 +1038,35 @@ export declare type ConnectionType = 'GoogleSheets' | 'FileUpload' | 'MySQL' | '
|
|
|
770
1038
|
|
|
771
1039
|
export declare type ContainerId = 'groupBy' | 'metrics' | 'pivotBy' | 'sortBy' | 'detailColumns' | 'source';
|
|
772
1040
|
|
|
1041
|
+
export declare type ContextSource = {
|
|
1042
|
+
kind: AlertContextSourceKind;
|
|
1043
|
+
config: Record<string, unknown>;
|
|
1044
|
+
outputAs?: string;
|
|
1045
|
+
};
|
|
1046
|
+
|
|
1047
|
+
export declare function createAlert(apiServiceUrl: string, token: string, payload: CreateAlertRequest): Promise<{
|
|
1048
|
+
alert: Alert;
|
|
1049
|
+
}>;
|
|
1050
|
+
|
|
1051
|
+
export declare interface CreateAlertRequest {
|
|
1052
|
+
kind?: 'ALERT';
|
|
1053
|
+
name: string;
|
|
1054
|
+
description?: string;
|
|
1055
|
+
scheduleExpr: string;
|
|
1056
|
+
timezone?: string;
|
|
1057
|
+
source: AlertSource;
|
|
1058
|
+
operator: AlertConditionOperator;
|
|
1059
|
+
threshold: number;
|
|
1060
|
+
severity?: AlertSeverity;
|
|
1061
|
+
consecutiveCount?: number;
|
|
1062
|
+
recipients: AlertRecipient[];
|
|
1063
|
+
channels?: AlertDeliveryChannel[];
|
|
1064
|
+
contextAuthoringMode?: AlertContextAuthoringMode;
|
|
1065
|
+
contextSources?: ContextSource[];
|
|
1066
|
+
presentationPrompt?: string;
|
|
1067
|
+
workflowDef?: Record<string, unknown>;
|
|
1068
|
+
}
|
|
1069
|
+
|
|
773
1070
|
/**
|
|
774
1071
|
* Factory function to create empty KPI card configuration
|
|
775
1072
|
* Returns a fresh config with new array instances to prevent shared references
|
|
@@ -1039,6 +1336,10 @@ declare type DateUnit = 'day' | 'week' | 'month' | 'quarter' | 'year';
|
|
|
1039
1336
|
*/
|
|
1040
1337
|
export declare const DEFAULT_CALENDAR_CONTEXT: CalendarContext;
|
|
1041
1338
|
|
|
1339
|
+
export declare function deleteAlert(apiServiceUrl: string, token: string, id: string): Promise<{
|
|
1340
|
+
success: boolean;
|
|
1341
|
+
}>;
|
|
1342
|
+
|
|
1042
1343
|
/**
|
|
1043
1344
|
* Field configuration for detail table columns.
|
|
1044
1345
|
* Unlike GroupByField, DetailField does not support aggregation or granularity.
|
|
@@ -1805,6 +2106,44 @@ export declare interface FormatSpec {
|
|
|
1805
2106
|
suffix?: string;
|
|
1806
2107
|
}
|
|
1807
2108
|
|
|
2109
|
+
export declare function getAlert(apiServiceUrl: string, token: string, id: string): Promise<{
|
|
2110
|
+
alert: Alert;
|
|
2111
|
+
}>;
|
|
2112
|
+
|
|
2113
|
+
export declare function getAlertContextSources(apiServiceUrl: string, token: string, alertId: string): Promise<{
|
|
2114
|
+
ruleId: string;
|
|
2115
|
+
contextSources: Array<Record<string, unknown>>;
|
|
2116
|
+
}>;
|
|
2117
|
+
|
|
2118
|
+
export declare function getAlertHistory(apiServiceUrl: string, token: string, id: string, params?: {
|
|
2119
|
+
windowDays?: 7 | 30 | 90;
|
|
2120
|
+
}): Promise<AlertHistoryResponse>;
|
|
2121
|
+
|
|
2122
|
+
export declare function getAlertQuotaUsage(apiServiceUrl: string, token: string): Promise<{
|
|
2123
|
+
usage: AlertQuotaRecord[];
|
|
2124
|
+
}>;
|
|
2125
|
+
|
|
2126
|
+
export declare function getAlertRunDeliveries(apiServiceUrl: string, token: string, id: string, runId: string): Promise<{
|
|
2127
|
+
attempts: Array<Record<string, unknown>>;
|
|
2128
|
+
}>;
|
|
2129
|
+
|
|
2130
|
+
export declare function getAlertRuns(apiServiceUrl: string, token: string, id: string, params?: {
|
|
2131
|
+
cursor?: string;
|
|
2132
|
+
limit?: number;
|
|
2133
|
+
}): Promise<{
|
|
2134
|
+
runs: AlertRun[];
|
|
2135
|
+
nextCursor: string | null;
|
|
2136
|
+
total: number;
|
|
2137
|
+
}>;
|
|
2138
|
+
|
|
2139
|
+
export declare function getAlertRunSteps(apiServiceUrl: string, token: string, id: string, runId: string): Promise<{
|
|
2140
|
+
steps: Array<Record<string, unknown>>;
|
|
2141
|
+
}>;
|
|
2142
|
+
|
|
2143
|
+
export declare function getAlertState(apiServiceUrl: string, token: string, id: string): Promise<{
|
|
2144
|
+
state: AlertState;
|
|
2145
|
+
}>;
|
|
2146
|
+
|
|
1808
2147
|
export declare function getColumnDataType(column: TDataColumn): string;
|
|
1809
2148
|
|
|
1810
2149
|
export declare type GetDashboardResponse = {
|
|
@@ -2027,6 +2366,11 @@ export declare interface InteractionTrigger {
|
|
|
2027
2366
|
field: Field;
|
|
2028
2367
|
}
|
|
2029
2368
|
|
|
2369
|
+
export declare function interpretAlertContext(apiServiceUrl: string, token: string, payload: {
|
|
2370
|
+
intent: string;
|
|
2371
|
+
ruleId?: string;
|
|
2372
|
+
}): Promise<AlertContextInterpretResponse>;
|
|
2373
|
+
|
|
2030
2374
|
export declare function invalidateToken(apiServiceUrl: string): Promise<any>;
|
|
2031
2375
|
|
|
2032
2376
|
export declare function isBooleanDataType(dataType: string): boolean;
|
|
@@ -2123,6 +2467,20 @@ declare interface LinkFormat {
|
|
|
2123
2467
|
openInNewTab: boolean;
|
|
2124
2468
|
}
|
|
2125
2469
|
|
|
2470
|
+
export declare function listAlertQuotas(apiServiceUrl: string, token: string): Promise<{
|
|
2471
|
+
quotas: AlertQuotaRecord[];
|
|
2472
|
+
}>;
|
|
2473
|
+
|
|
2474
|
+
export declare function listAlerts(apiServiceUrl: string, token: string, params?: {
|
|
2475
|
+
status?: string;
|
|
2476
|
+
cursor?: string;
|
|
2477
|
+
limit?: number;
|
|
2478
|
+
}): Promise<{
|
|
2479
|
+
alerts: Alert[];
|
|
2480
|
+
nextCursor: string | null;
|
|
2481
|
+
total: number;
|
|
2482
|
+
}>;
|
|
2483
|
+
|
|
2126
2484
|
export declare type LoadingProps = {
|
|
2127
2485
|
message?: string;
|
|
2128
2486
|
};
|
|
@@ -2326,6 +2684,8 @@ export declare type Placeholders = {
|
|
|
2326
2684
|
|
|
2327
2685
|
export declare type PluginType = 'custom' | 'standard';
|
|
2328
2686
|
|
|
2687
|
+
export declare function previewAlertDeliverable(apiServiceUrl: string, token: string, payload: Record<string, unknown>, alertId?: string): Promise<AlertDeliverablePreview>;
|
|
2688
|
+
|
|
2329
2689
|
/**
|
|
2330
2690
|
* Print state structure exposed to window for Lambda/Puppeteer access.
|
|
2331
2691
|
*/
|
|
@@ -2465,8 +2825,9 @@ export declare enum ResourceType {
|
|
|
2465
2825
|
VISUAL = "visual"
|
|
2466
2826
|
}
|
|
2467
2827
|
|
|
2468
|
-
export declare function ScheduleDashboard({ triggerButtonClassName, }: {
|
|
2828
|
+
export declare function ScheduleDashboard({ triggerButtonClassName, variant, }: {
|
|
2469
2829
|
triggerButtonClassName?: string;
|
|
2830
|
+
variant?: ButtonProps['variant'];
|
|
2470
2831
|
}): JSX.Element | null;
|
|
2471
2832
|
|
|
2472
2833
|
export declare type SchemaItem = DropdownItem;
|
|
@@ -3129,6 +3490,8 @@ export declare type TDbCapabilities = {
|
|
|
3129
3490
|
supportsFilterClause?: boolean;
|
|
3130
3491
|
};
|
|
3131
3492
|
|
|
3493
|
+
export declare function TenantQuotaPage(): JSX.Element;
|
|
3494
|
+
|
|
3132
3495
|
export declare type TEvent = {
|
|
3133
3496
|
type: 'success' | 'error' | 'info' | 'warning';
|
|
3134
3497
|
message: any;
|
|
@@ -3560,6 +3923,11 @@ export declare type TokenSecurityPolicy = {
|
|
|
3560
3923
|
/** Point style options supported by Chart.js */
|
|
3561
3924
|
export declare type TPointStyle = 'circle' | 'cross' | 'crossRot' | 'dash' | 'line' | 'rect' | 'rectRounded' | 'rectRot' | 'star' | 'triangle';
|
|
3562
3925
|
|
|
3926
|
+
export declare function triggerAlertNow(apiServiceUrl: string, token: string, ruleId: string): Promise<{
|
|
3927
|
+
accepted: boolean;
|
|
3928
|
+
runId?: string;
|
|
3929
|
+
}>;
|
|
3930
|
+
|
|
3563
3931
|
export declare type TSelectedRecord = ComboBoxOption;
|
|
3564
3932
|
|
|
3565
3933
|
export declare type TSheet = {
|
|
@@ -3615,6 +3983,39 @@ declare type UnsavedChangesAlertProps = {
|
|
|
3615
3983
|
isSaving: boolean;
|
|
3616
3984
|
};
|
|
3617
3985
|
|
|
3986
|
+
export declare function updateAlert(apiServiceUrl: string, token: string, id: string, payload: UpdateAlertRequest): Promise<{
|
|
3987
|
+
alert: Alert;
|
|
3988
|
+
}>;
|
|
3989
|
+
|
|
3990
|
+
export declare function updateAlertContextSources(apiServiceUrl: string, token: string, alertId: string, contextSources: Array<Record<string, unknown>>): Promise<{
|
|
3991
|
+
ruleId: string;
|
|
3992
|
+
contextSources: Array<Record<string, unknown>>;
|
|
3993
|
+
workflowDef: Record<string, unknown>;
|
|
3994
|
+
}>;
|
|
3995
|
+
|
|
3996
|
+
export declare function updateAlertQuota(apiServiceUrl: string, token: string, tenantId: string, payload: Partial<AlertQuotaRecord['policy']>): Promise<{
|
|
3997
|
+
quota: AlertQuotaRecord;
|
|
3998
|
+
}>;
|
|
3999
|
+
|
|
4000
|
+
export declare interface UpdateAlertRequest {
|
|
4001
|
+
name?: string;
|
|
4002
|
+
description?: string | null;
|
|
4003
|
+
scheduleExpr?: string;
|
|
4004
|
+
timezone?: string;
|
|
4005
|
+
status?: AlertStatus;
|
|
4006
|
+
source?: AlertSource;
|
|
4007
|
+
operator?: AlertConditionOperator;
|
|
4008
|
+
threshold?: number;
|
|
4009
|
+
severity?: AlertSeverity;
|
|
4010
|
+
consecutiveCount?: number;
|
|
4011
|
+
recipients?: AlertRecipient[];
|
|
4012
|
+
channels?: AlertDeliveryChannel[];
|
|
4013
|
+
contextAuthoringMode?: AlertContextAuthoringMode;
|
|
4014
|
+
contextSources?: ContextSource[];
|
|
4015
|
+
presentationPrompt?: string;
|
|
4016
|
+
workflowDef?: Record<string, unknown> | null;
|
|
4017
|
+
}
|
|
4018
|
+
|
|
3618
4019
|
declare interface UpdateDashboardTemplateRequest {
|
|
3619
4020
|
template: TDashboard;
|
|
3620
4021
|
}
|
|
@@ -3658,6 +4059,424 @@ export declare interface URLParameter {
|
|
|
3658
4059
|
|
|
3659
4060
|
export declare const useActiveExports: () => Map<string, ActiveExport>;
|
|
3660
4061
|
|
|
4062
|
+
export declare const useAlertActions: () => AlertStoreActions;
|
|
4063
|
+
|
|
4064
|
+
export declare function useAlertBacktest(alertId?: string): UseMutationResult<AlertBacktestResult, Error, Record<string, unknown> | undefined, unknown>;
|
|
4065
|
+
|
|
4066
|
+
export declare function useAlertContextBuilder(ruleId?: string): UseMutationResult<AlertContextInterpretResponse, Error, string, unknown>;
|
|
4067
|
+
|
|
4068
|
+
export declare function useAlertDeliveries(alertId: string | undefined, runId: string | undefined): UseQueryResult< {
|
|
4069
|
+
attempts: Array<Record<string, unknown>>;
|
|
4070
|
+
}, Error>;
|
|
4071
|
+
|
|
4072
|
+
export declare function useAlertDetail(alertId?: string): UseQueryResult< {
|
|
4073
|
+
alert: Alert;
|
|
4074
|
+
}, Error>;
|
|
4075
|
+
|
|
4076
|
+
export declare const useAlertDraft: () => AlertDraft;
|
|
4077
|
+
|
|
4078
|
+
export declare const useAlertFilters: () => AlertFilters;
|
|
4079
|
+
|
|
4080
|
+
export declare function useAlertHistory(alertId: string | undefined, windowDays?: 7 | 30 | 90): UseQueryResult<AlertHistoryResponse, Error>;
|
|
4081
|
+
|
|
4082
|
+
export declare function useAlertQuotas(): {
|
|
4083
|
+
quotasQuery: UseQueryResult< {
|
|
4084
|
+
quotas: AlertQuotaRecord[];
|
|
4085
|
+
}, Error>;
|
|
4086
|
+
usageQuery: UseQueryResult< {
|
|
4087
|
+
usage: AlertQuotaRecord[];
|
|
4088
|
+
}, Error>;
|
|
4089
|
+
updateQuota: UseMutateAsyncFunction< {
|
|
4090
|
+
quota: AlertQuotaRecord;
|
|
4091
|
+
}, Error, {
|
|
4092
|
+
tenantId: string;
|
|
4093
|
+
policy: {
|
|
4094
|
+
maxActiveAlerts?: number;
|
|
4095
|
+
minCadenceMinutes?: number;
|
|
4096
|
+
maxContextSources?: number;
|
|
4097
|
+
};
|
|
4098
|
+
}, unknown>;
|
|
4099
|
+
isUpdatingQuota: boolean;
|
|
4100
|
+
};
|
|
4101
|
+
|
|
4102
|
+
export declare function useAlertRuns(alertId: string | undefined, limit?: number): UseQueryResult< {
|
|
4103
|
+
runs: AlertRun[];
|
|
4104
|
+
nextCursor: string | null;
|
|
4105
|
+
total: number;
|
|
4106
|
+
}, Error>;
|
|
4107
|
+
|
|
4108
|
+
export declare function useAlerts(options?: {
|
|
4109
|
+
enabled?: boolean;
|
|
4110
|
+
limit?: number;
|
|
4111
|
+
}): {
|
|
4112
|
+
alerts: Alert[];
|
|
4113
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4114
|
+
alert: Alert;
|
|
4115
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4116
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4117
|
+
alert: Alert;
|
|
4118
|
+
}, Error, {
|
|
4119
|
+
id: string;
|
|
4120
|
+
payload: UpdateAlertRequest;
|
|
4121
|
+
}, unknown>;
|
|
4122
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4123
|
+
success: boolean;
|
|
4124
|
+
}, Error, string, unknown>;
|
|
4125
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4126
|
+
accepted: boolean;
|
|
4127
|
+
runId?: string;
|
|
4128
|
+
}, Error, string, unknown>;
|
|
4129
|
+
isCreating: boolean;
|
|
4130
|
+
isUpdating: boolean;
|
|
4131
|
+
isDeleting: boolean;
|
|
4132
|
+
isTriggering: boolean;
|
|
4133
|
+
data: {
|
|
4134
|
+
alerts: Alert[];
|
|
4135
|
+
nextCursor: string | null;
|
|
4136
|
+
total: number;
|
|
4137
|
+
};
|
|
4138
|
+
error: Error;
|
|
4139
|
+
isError: true;
|
|
4140
|
+
isPending: false;
|
|
4141
|
+
isLoading: false;
|
|
4142
|
+
isLoadingError: false;
|
|
4143
|
+
isRefetchError: true;
|
|
4144
|
+
isSuccess: false;
|
|
4145
|
+
isPlaceholderData: false;
|
|
4146
|
+
status: "error";
|
|
4147
|
+
dataUpdatedAt: number;
|
|
4148
|
+
errorUpdatedAt: number;
|
|
4149
|
+
failureCount: number;
|
|
4150
|
+
failureReason: Error | null;
|
|
4151
|
+
errorUpdateCount: number;
|
|
4152
|
+
isFetched: boolean;
|
|
4153
|
+
isFetchedAfterMount: boolean;
|
|
4154
|
+
isFetching: boolean;
|
|
4155
|
+
isInitialLoading: boolean;
|
|
4156
|
+
isPaused: boolean;
|
|
4157
|
+
isRefetching: boolean;
|
|
4158
|
+
isStale: boolean;
|
|
4159
|
+
isEnabled: boolean;
|
|
4160
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4161
|
+
alerts: Alert[];
|
|
4162
|
+
nextCursor: string | null;
|
|
4163
|
+
total: number;
|
|
4164
|
+
}, Error>>;
|
|
4165
|
+
fetchStatus: FetchStatus;
|
|
4166
|
+
promise: Promise<{
|
|
4167
|
+
alerts: Alert[];
|
|
4168
|
+
nextCursor: string | null;
|
|
4169
|
+
total: number;
|
|
4170
|
+
}>;
|
|
4171
|
+
} | {
|
|
4172
|
+
alerts: Alert[];
|
|
4173
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4174
|
+
alert: Alert;
|
|
4175
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4176
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4177
|
+
alert: Alert;
|
|
4178
|
+
}, Error, {
|
|
4179
|
+
id: string;
|
|
4180
|
+
payload: UpdateAlertRequest;
|
|
4181
|
+
}, unknown>;
|
|
4182
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4183
|
+
success: boolean;
|
|
4184
|
+
}, Error, string, unknown>;
|
|
4185
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4186
|
+
accepted: boolean;
|
|
4187
|
+
runId?: string;
|
|
4188
|
+
}, Error, string, unknown>;
|
|
4189
|
+
isCreating: boolean;
|
|
4190
|
+
isUpdating: boolean;
|
|
4191
|
+
isDeleting: boolean;
|
|
4192
|
+
isTriggering: boolean;
|
|
4193
|
+
data: {
|
|
4194
|
+
alerts: Alert[];
|
|
4195
|
+
nextCursor: string | null;
|
|
4196
|
+
total: number;
|
|
4197
|
+
};
|
|
4198
|
+
error: null;
|
|
4199
|
+
isError: false;
|
|
4200
|
+
isPending: false;
|
|
4201
|
+
isLoading: false;
|
|
4202
|
+
isLoadingError: false;
|
|
4203
|
+
isRefetchError: false;
|
|
4204
|
+
isSuccess: true;
|
|
4205
|
+
isPlaceholderData: false;
|
|
4206
|
+
status: "success";
|
|
4207
|
+
dataUpdatedAt: number;
|
|
4208
|
+
errorUpdatedAt: number;
|
|
4209
|
+
failureCount: number;
|
|
4210
|
+
failureReason: Error | null;
|
|
4211
|
+
errorUpdateCount: number;
|
|
4212
|
+
isFetched: boolean;
|
|
4213
|
+
isFetchedAfterMount: boolean;
|
|
4214
|
+
isFetching: boolean;
|
|
4215
|
+
isInitialLoading: boolean;
|
|
4216
|
+
isPaused: boolean;
|
|
4217
|
+
isRefetching: boolean;
|
|
4218
|
+
isStale: boolean;
|
|
4219
|
+
isEnabled: boolean;
|
|
4220
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4221
|
+
alerts: Alert[];
|
|
4222
|
+
nextCursor: string | null;
|
|
4223
|
+
total: number;
|
|
4224
|
+
}, Error>>;
|
|
4225
|
+
fetchStatus: FetchStatus;
|
|
4226
|
+
promise: Promise<{
|
|
4227
|
+
alerts: Alert[];
|
|
4228
|
+
nextCursor: string | null;
|
|
4229
|
+
total: number;
|
|
4230
|
+
}>;
|
|
4231
|
+
} | {
|
|
4232
|
+
alerts: Alert[];
|
|
4233
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4234
|
+
alert: Alert;
|
|
4235
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4236
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4237
|
+
alert: Alert;
|
|
4238
|
+
}, Error, {
|
|
4239
|
+
id: string;
|
|
4240
|
+
payload: UpdateAlertRequest;
|
|
4241
|
+
}, unknown>;
|
|
4242
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4243
|
+
success: boolean;
|
|
4244
|
+
}, Error, string, unknown>;
|
|
4245
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4246
|
+
accepted: boolean;
|
|
4247
|
+
runId?: string;
|
|
4248
|
+
}, Error, string, unknown>;
|
|
4249
|
+
isCreating: boolean;
|
|
4250
|
+
isUpdating: boolean;
|
|
4251
|
+
isDeleting: boolean;
|
|
4252
|
+
isTriggering: boolean;
|
|
4253
|
+
data: undefined;
|
|
4254
|
+
error: Error;
|
|
4255
|
+
isError: true;
|
|
4256
|
+
isPending: false;
|
|
4257
|
+
isLoading: false;
|
|
4258
|
+
isLoadingError: true;
|
|
4259
|
+
isRefetchError: false;
|
|
4260
|
+
isSuccess: false;
|
|
4261
|
+
isPlaceholderData: false;
|
|
4262
|
+
status: "error";
|
|
4263
|
+
dataUpdatedAt: number;
|
|
4264
|
+
errorUpdatedAt: number;
|
|
4265
|
+
failureCount: number;
|
|
4266
|
+
failureReason: Error | null;
|
|
4267
|
+
errorUpdateCount: number;
|
|
4268
|
+
isFetched: boolean;
|
|
4269
|
+
isFetchedAfterMount: boolean;
|
|
4270
|
+
isFetching: boolean;
|
|
4271
|
+
isInitialLoading: boolean;
|
|
4272
|
+
isPaused: boolean;
|
|
4273
|
+
isRefetching: boolean;
|
|
4274
|
+
isStale: boolean;
|
|
4275
|
+
isEnabled: boolean;
|
|
4276
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4277
|
+
alerts: Alert[];
|
|
4278
|
+
nextCursor: string | null;
|
|
4279
|
+
total: number;
|
|
4280
|
+
}, Error>>;
|
|
4281
|
+
fetchStatus: FetchStatus;
|
|
4282
|
+
promise: Promise<{
|
|
4283
|
+
alerts: Alert[];
|
|
4284
|
+
nextCursor: string | null;
|
|
4285
|
+
total: number;
|
|
4286
|
+
}>;
|
|
4287
|
+
} | {
|
|
4288
|
+
alerts: Alert[];
|
|
4289
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4290
|
+
alert: Alert;
|
|
4291
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4292
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4293
|
+
alert: Alert;
|
|
4294
|
+
}, Error, {
|
|
4295
|
+
id: string;
|
|
4296
|
+
payload: UpdateAlertRequest;
|
|
4297
|
+
}, unknown>;
|
|
4298
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4299
|
+
success: boolean;
|
|
4300
|
+
}, Error, string, unknown>;
|
|
4301
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4302
|
+
accepted: boolean;
|
|
4303
|
+
runId?: string;
|
|
4304
|
+
}, Error, string, unknown>;
|
|
4305
|
+
isCreating: boolean;
|
|
4306
|
+
isUpdating: boolean;
|
|
4307
|
+
isDeleting: boolean;
|
|
4308
|
+
isTriggering: boolean;
|
|
4309
|
+
data: undefined;
|
|
4310
|
+
error: null;
|
|
4311
|
+
isError: false;
|
|
4312
|
+
isPending: true;
|
|
4313
|
+
isLoading: true;
|
|
4314
|
+
isLoadingError: false;
|
|
4315
|
+
isRefetchError: false;
|
|
4316
|
+
isSuccess: false;
|
|
4317
|
+
isPlaceholderData: false;
|
|
4318
|
+
status: "pending";
|
|
4319
|
+
dataUpdatedAt: number;
|
|
4320
|
+
errorUpdatedAt: number;
|
|
4321
|
+
failureCount: number;
|
|
4322
|
+
failureReason: Error | null;
|
|
4323
|
+
errorUpdateCount: number;
|
|
4324
|
+
isFetched: boolean;
|
|
4325
|
+
isFetchedAfterMount: boolean;
|
|
4326
|
+
isFetching: boolean;
|
|
4327
|
+
isInitialLoading: boolean;
|
|
4328
|
+
isPaused: boolean;
|
|
4329
|
+
isRefetching: boolean;
|
|
4330
|
+
isStale: boolean;
|
|
4331
|
+
isEnabled: boolean;
|
|
4332
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4333
|
+
alerts: Alert[];
|
|
4334
|
+
nextCursor: string | null;
|
|
4335
|
+
total: number;
|
|
4336
|
+
}, Error>>;
|
|
4337
|
+
fetchStatus: FetchStatus;
|
|
4338
|
+
promise: Promise<{
|
|
4339
|
+
alerts: Alert[];
|
|
4340
|
+
nextCursor: string | null;
|
|
4341
|
+
total: number;
|
|
4342
|
+
}>;
|
|
4343
|
+
} | {
|
|
4344
|
+
alerts: Alert[];
|
|
4345
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4346
|
+
alert: Alert;
|
|
4347
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4348
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4349
|
+
alert: Alert;
|
|
4350
|
+
}, Error, {
|
|
4351
|
+
id: string;
|
|
4352
|
+
payload: UpdateAlertRequest;
|
|
4353
|
+
}, unknown>;
|
|
4354
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4355
|
+
success: boolean;
|
|
4356
|
+
}, Error, string, unknown>;
|
|
4357
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4358
|
+
accepted: boolean;
|
|
4359
|
+
runId?: string;
|
|
4360
|
+
}, Error, string, unknown>;
|
|
4361
|
+
isCreating: boolean;
|
|
4362
|
+
isUpdating: boolean;
|
|
4363
|
+
isDeleting: boolean;
|
|
4364
|
+
isTriggering: boolean;
|
|
4365
|
+
data: undefined;
|
|
4366
|
+
error: null;
|
|
4367
|
+
isError: false;
|
|
4368
|
+
isPending: true;
|
|
4369
|
+
isLoadingError: false;
|
|
4370
|
+
isRefetchError: false;
|
|
4371
|
+
isSuccess: false;
|
|
4372
|
+
isPlaceholderData: false;
|
|
4373
|
+
status: "pending";
|
|
4374
|
+
dataUpdatedAt: number;
|
|
4375
|
+
errorUpdatedAt: number;
|
|
4376
|
+
failureCount: number;
|
|
4377
|
+
failureReason: Error | null;
|
|
4378
|
+
errorUpdateCount: number;
|
|
4379
|
+
isFetched: boolean;
|
|
4380
|
+
isFetchedAfterMount: boolean;
|
|
4381
|
+
isFetching: boolean;
|
|
4382
|
+
isLoading: boolean;
|
|
4383
|
+
isInitialLoading: boolean;
|
|
4384
|
+
isPaused: boolean;
|
|
4385
|
+
isRefetching: boolean;
|
|
4386
|
+
isStale: boolean;
|
|
4387
|
+
isEnabled: boolean;
|
|
4388
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4389
|
+
alerts: Alert[];
|
|
4390
|
+
nextCursor: string | null;
|
|
4391
|
+
total: number;
|
|
4392
|
+
}, Error>>;
|
|
4393
|
+
fetchStatus: FetchStatus;
|
|
4394
|
+
promise: Promise<{
|
|
4395
|
+
alerts: Alert[];
|
|
4396
|
+
nextCursor: string | null;
|
|
4397
|
+
total: number;
|
|
4398
|
+
}>;
|
|
4399
|
+
} | {
|
|
4400
|
+
alerts: Alert[];
|
|
4401
|
+
createAlert: UseMutateAsyncFunction< {
|
|
4402
|
+
alert: Alert;
|
|
4403
|
+
}, Error, CreateAlertRequest, unknown>;
|
|
4404
|
+
updateAlert: UseMutateAsyncFunction< {
|
|
4405
|
+
alert: Alert;
|
|
4406
|
+
}, Error, {
|
|
4407
|
+
id: string;
|
|
4408
|
+
payload: UpdateAlertRequest;
|
|
4409
|
+
}, unknown>;
|
|
4410
|
+
deleteAlert: UseMutateAsyncFunction< {
|
|
4411
|
+
success: boolean;
|
|
4412
|
+
}, Error, string, unknown>;
|
|
4413
|
+
triggerAlert: UseMutateAsyncFunction< {
|
|
4414
|
+
accepted: boolean;
|
|
4415
|
+
runId?: string;
|
|
4416
|
+
}, Error, string, unknown>;
|
|
4417
|
+
isCreating: boolean;
|
|
4418
|
+
isUpdating: boolean;
|
|
4419
|
+
isDeleting: boolean;
|
|
4420
|
+
isTriggering: boolean;
|
|
4421
|
+
data: {
|
|
4422
|
+
alerts: Alert[];
|
|
4423
|
+
nextCursor: string | null;
|
|
4424
|
+
total: number;
|
|
4425
|
+
};
|
|
4426
|
+
isError: false;
|
|
4427
|
+
error: null;
|
|
4428
|
+
isPending: false;
|
|
4429
|
+
isLoading: false;
|
|
4430
|
+
isLoadingError: false;
|
|
4431
|
+
isRefetchError: false;
|
|
4432
|
+
isSuccess: true;
|
|
4433
|
+
isPlaceholderData: true;
|
|
4434
|
+
status: "success";
|
|
4435
|
+
dataUpdatedAt: number;
|
|
4436
|
+
errorUpdatedAt: number;
|
|
4437
|
+
failureCount: number;
|
|
4438
|
+
failureReason: Error | null;
|
|
4439
|
+
errorUpdateCount: number;
|
|
4440
|
+
isFetched: boolean;
|
|
4441
|
+
isFetchedAfterMount: boolean;
|
|
4442
|
+
isFetching: boolean;
|
|
4443
|
+
isInitialLoading: boolean;
|
|
4444
|
+
isPaused: boolean;
|
|
4445
|
+
isRefetching: boolean;
|
|
4446
|
+
isStale: boolean;
|
|
4447
|
+
isEnabled: boolean;
|
|
4448
|
+
refetch: (options?: RefetchOptions) => Promise<QueryObserverResult< {
|
|
4449
|
+
alerts: Alert[];
|
|
4450
|
+
nextCursor: string | null;
|
|
4451
|
+
total: number;
|
|
4452
|
+
}, Error>>;
|
|
4453
|
+
fetchStatus: FetchStatus;
|
|
4454
|
+
promise: Promise<{
|
|
4455
|
+
alerts: Alert[];
|
|
4456
|
+
nextCursor: string | null;
|
|
4457
|
+
total: number;
|
|
4458
|
+
}>;
|
|
4459
|
+
};
|
|
4460
|
+
|
|
4461
|
+
export declare function useAlertsBootstrap(): UseQueryResult< {
|
|
4462
|
+
alerts: Alert[];
|
|
4463
|
+
nextCursor: null;
|
|
4464
|
+
total: number;
|
|
4465
|
+
}, Error>;
|
|
4466
|
+
|
|
4467
|
+
export declare const useAlertsById: () => Record<string, Alert>;
|
|
4468
|
+
|
|
4469
|
+
export declare const useAlertsForCard: (cardId: string) => Alert[];
|
|
4470
|
+
|
|
4471
|
+
export declare function useAlertState(alertId: string | undefined): UseQueryResult< {
|
|
4472
|
+
state: AlertState;
|
|
4473
|
+
}, Error>;
|
|
4474
|
+
|
|
4475
|
+
export declare const useAlertStore: UseBoundStore<Omit<StoreApi<AlertStore>, "setState"> & {
|
|
4476
|
+
setState(nextStateOrUpdater: AlertStore | Partial<AlertStore> | ((state: WritableDraft<AlertStore>) => void), shouldReplace?: false): void;
|
|
4477
|
+
setState(nextStateOrUpdater: AlertStore | ((state: WritableDraft<AlertStore>) => void), shouldReplace: true): void;
|
|
4478
|
+
}>;
|
|
4479
|
+
|
|
3661
4480
|
export declare function useCard(cardId: string): {
|
|
3662
4481
|
data: any;
|
|
3663
4482
|
card: TCard;
|
|
@@ -3673,6 +4492,8 @@ export declare function useCard(cardId: string): {
|
|
|
3673
4492
|
comparisonMetadata: ComparisonMetadataMap | undefined;
|
|
3674
4493
|
};
|
|
3675
4494
|
|
|
4495
|
+
export declare const useCardAlertMap: () => Map<string, string[]>;
|
|
4496
|
+
|
|
3676
4497
|
export declare function useCardSummary(card: TCard, options?: UseCardSummaryOptions): {
|
|
3677
4498
|
data: SummaryResponse | undefined;
|
|
3678
4499
|
isLoading: boolean;
|
|
@@ -3928,6 +4749,8 @@ export declare interface UserPreference {
|
|
|
3928
4749
|
updatedAt: string;
|
|
3929
4750
|
}
|
|
3930
4751
|
|
|
4752
|
+
export declare const useSelectedAlertId: () => string | null;
|
|
4753
|
+
|
|
3931
4754
|
export declare function useTextFilterHook(filterId: string): {
|
|
3932
4755
|
isLoading: boolean;
|
|
3933
4756
|
isFetching: boolean;
|