@magemetrics/ai 0.0.55 → 0.0.57

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.
@@ -5,20 +5,15 @@ import { ForwardRefExoticComponent } from 'react';
5
5
  import { InfiniteData } from '@tanstack/react-query';
6
6
  import { InfiniteQueryObserverResult } from '@tanstack/react-query';
7
7
  import { JSX } from 'react/jsx-runtime';
8
- import { objectOutputType } from 'zod';
9
8
  import { PropsWithChildren } from 'react';
10
9
  import { RefAttributes } from 'react';
11
10
  import type { Simplify } from 'type-fest';
11
+ import { SortingState } from '@tanstack/react-table';
12
12
  import { UseMutateAsyncFunction } from '@tanstack/react-query';
13
13
  import { UseMutateFunction } from '@tanstack/react-query';
14
14
  import { UseMutationOptions } from '@tanstack/react-query';
15
15
  import { UseQueryResult } from '@tanstack/react-query';
16
16
  import { z } from 'zod';
17
- import { ZodNullable } from 'zod';
18
- import { ZodNumber } from 'zod';
19
- import { ZodOptional } from 'zod';
20
- import { ZodString } from 'zod';
21
- import { ZodTypeAny } from 'zod';
22
17
 
23
18
  export declare type AuthState = "initializing" | "ready" | "error";
24
19
 
@@ -44,7 +39,6 @@ declare const ChatInput_2: React.FC<{
44
39
 
45
40
  export declare const ChatLayoutProvider: default_2.FC<{
46
41
  children: default_2.ReactNode;
47
- mobileBreakpoint?: string;
48
42
  }>;
49
43
 
50
44
  export declare const ChatMessages: React.FC<React.ComponentProps<typeof ChatMessages_2>>;
@@ -75,6 +69,121 @@ export declare interface Components {
75
69
 
76
70
  declare interface components {
77
71
  schemas: {
72
+ VisualizationData: {
73
+ [key: string]: string | (number | null) | unknown | null;
74
+ }[];
75
+ VisualizationWithData: {
76
+ id: number;
77
+ flow_data_id: number;
78
+ created_at: string;
79
+ bookmarked: boolean;
80
+ configuration: {
81
+ /** @enum {string} */
82
+ type: "bar";
83
+ title: string;
84
+ /** @enum {number} */
85
+ config_version: 2;
86
+ xAxisLabel: string;
87
+ yAxisLabel: string;
88
+ categoryColumn: string;
89
+ secondaryCategoryColumn?: string;
90
+ valueColumn: string;
91
+ } | {
92
+ /** @enum {string} */
93
+ type: "line/area";
94
+ /** @enum {number} */
95
+ config_version: 2;
96
+ title: string;
97
+ xAxisColumn: string;
98
+ valueColumns: string[];
99
+ yAxisLabels: string[];
100
+ } | {
101
+ /** @enum {string} */
102
+ type: "line/area-categorical";
103
+ title: string;
104
+ /** @enum {number} */
105
+ config_version: 2;
106
+ valueColumn: string;
107
+ xAxisColumn: string;
108
+ xAxisLabel: string;
109
+ yAxisLabel: string;
110
+ categoryColumn: string;
111
+ } | {
112
+ /** @enum {string} */
113
+ type: "scatter";
114
+ title: string;
115
+ /** @enum {number} */
116
+ config_version: 2;
117
+ xAxisLabel: string;
118
+ yAxisLabel: string;
119
+ xAxisValueColumn: string;
120
+ yAxisValueColumn: string;
121
+ } | {
122
+ /** @enum {string} */
123
+ type: "pie";
124
+ title: string;
125
+ /** @enum {number} */
126
+ config_version: 2;
127
+ categoryColumn: string;
128
+ valueColumn: string;
129
+ };
130
+ data: components["schemas"]["VisualizationData"];
131
+ _metadata?: {
132
+ wasSampled: boolean;
133
+ originalCount: number;
134
+ sampledCount: number;
135
+ };
136
+ } | {
137
+ id: number;
138
+ flow_data_id: number;
139
+ created_at: string;
140
+ bookmarked: boolean;
141
+ configuration: {
142
+ /** @enum {string} */
143
+ type: "bar";
144
+ title: string;
145
+ xAxisLabel: string;
146
+ yAxisLabel: string;
147
+ xAxisDataKey?: string;
148
+ yAxisDataKey?: string;
149
+ dimensionDataKey?: string;
150
+ valueColumns?: string[];
151
+ } | {
152
+ /** @enum {string} */
153
+ type: "line/area";
154
+ title: string;
155
+ xAxisLabel: string;
156
+ yAxisLabel: string;
157
+ xAxisDataKey?: string;
158
+ yAxisDataKey?: string;
159
+ dimensionDataKey?: string;
160
+ valueColumns?: string[];
161
+ } | {
162
+ /** @enum {string} */
163
+ type: "scatter";
164
+ title: string;
165
+ xAxisLabel: string;
166
+ yAxisLabel: string;
167
+ xAxisDataKey?: string;
168
+ yAxisDataKey?: string;
169
+ dimensionDataKey?: string;
170
+ valueColumns?: string[];
171
+ } | {
172
+ /** @enum {string} */
173
+ type: "pie";
174
+ title: string;
175
+ nameKey: string;
176
+ dataKey: string;
177
+ };
178
+ data: components["schemas"]["VisualizationData"];
179
+ _metadata?: {
180
+ wasSampled: boolean;
181
+ originalCount: number;
182
+ sampledCount: number;
183
+ };
184
+ };
185
+ /** Format: uuid */
186
+ DashboardId: string;
78
187
  ReportColumns: {
79
188
  name: string;
80
189
  data_type: string;
@@ -89,9 +198,6 @@ declare interface components {
89
198
  explanation: string;
90
199
  type: string;
91
200
  };
92
- VisualizationData: {
93
- [key: string]: string | (number | null) | unknown | null;
94
- }[];
95
201
  };
96
202
  responses: never;
97
203
  parameters: never;
@@ -496,14 +602,13 @@ declare const FrontendReportSchema: z.ZodObject<Omit<{
496
602
  }, z.ZodTypeAny, "passthrough">>;
497
603
  bookmarked: z.ZodBoolean;
498
604
  status: z.ZodNullable<z.ZodString>;
499
- }, "schema" | "sql" | "table" | "is_sample" | "data_sample">, "strip", z.ZodTypeAny, {
605
+ }, "schema" | "sql" | "table" | "data_sample" | "is_sample">, "strip", z.ZodTypeAny, {
500
606
  title: string;
501
607
  status: string | null;
502
608
  id: number;
503
609
  request: string | null;
504
610
  created_at: string;
505
611
  bookmarked: boolean;
506
- flow_id: string;
507
612
  data_summary: {
508
613
  columns: Record<string, z.objectOutputType<{
509
614
  position: z.ZodOptional<z.ZodNumber>;
@@ -515,6 +620,7 @@ declare const FrontendReportSchema: z.ZodObject<Omit<{
515
620
  } & {
516
621
  [k: string]: unknown;
517
622
  };
623
+ flow_id: string;
518
624
  }, {
519
625
  title: string;
520
626
  status: string | null;
@@ -522,7 +628,6 @@ declare const FrontendReportSchema: z.ZodObject<Omit<{
522
628
  request: string | null;
523
629
  created_at: string;
524
630
  bookmarked: boolean;
525
- flow_id: string;
526
631
  data_summary: {
527
632
  columns: Record<string, z.objectInputType<{
528
633
  position: z.ZodOptional<z.ZodNumber>;
@@ -534,6 +639,7 @@ declare const FrontendReportSchema: z.ZodObject<Omit<{
534
639
  } & {
535
640
  [k: string]: unknown;
536
641
  };
642
+ flow_id: string;
537
643
  }>;
538
644
 
539
645
  declare type FrontendVisualization = z.output<typeof FrontendVisualizationSchema>;
@@ -542,6 +648,12 @@ declare const FrontendVisualizationSchema: z.ZodObject<Omit<{
542
648
  id: z.ZodNumber;
543
649
  flow_data_id: z.ZodNumber;
544
650
  created_at: z.ZodString;
651
+ sql: z.ZodString;
652
+ bookmarked: z.ZodBoolean;
653
+ data_sample: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>, "many">;
654
+ is_sample: z.ZodBoolean;
655
+ data_summary: z.ZodRecord<z.ZodString, z.ZodUnknown>;
656
+ } & {
545
657
  configuration: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
546
658
  config_version: z.ZodLiteral<2>;
547
659
  xAxisLabel: z.ZodString;
@@ -660,12 +772,11 @@ declare const FrontendVisualizationSchema: z.ZodObject<Omit<{
660
772
  categoryColumn: string;
661
773
  valueColumn: string;
662
774
  }>]>;
663
- sql: z.ZodString;
664
- bookmarked: z.ZodBoolean;
665
- }, "sql">, "strip", z.ZodTypeAny, {
775
+ }, "sql" | "data_sample" | "is_sample" | "data_summary">, "strip", z.ZodTypeAny, {
666
776
  id: number;
667
777
  flow_data_id: number;
668
778
  created_at: string;
779
+ bookmarked: boolean;
669
780
  configuration: {
670
781
  type: "bar";
671
782
  title: string;
@@ -706,11 +817,11 @@ declare const FrontendVisualizationSchema: z.ZodObject<Omit<{
706
817
  categoryColumn: string;
707
818
  valueColumn: string;
708
819
  };
709
- bookmarked: boolean;
710
820
  }, {
711
821
  id: number;
712
822
  flow_data_id: number;
713
823
  created_at: string;
824
+ bookmarked: boolean;
714
825
  configuration: {
715
826
  type: "bar";
716
827
  title: string;
@@ -751,7 +862,6 @@ declare const FrontendVisualizationSchema: z.ZodObject<Omit<{
751
862
  categoryColumn: string;
752
863
  valueColumn: string;
753
864
  };
754
- bookmarked: boolean;
755
865
  }>;
756
866
 
757
867
  export declare type GenerateInsightParam = {
@@ -768,7 +878,7 @@ declare type InfiniteDataTableUIProps = {
768
878
  explainability: FrontendReportExplainability | null | undefined;
769
879
  isOpened: boolean;
770
880
  setIsOpened: (opened: boolean) => void;
771
- hasNextPage?: boolean;
881
+ hasNextPage: boolean | undefined;
772
882
  fetchNextPage: () => Promise<unknown>;
773
883
  isFetchingNextPage: boolean;
774
884
  isFetching: boolean;
@@ -797,6 +907,7 @@ export declare class MageMetricsClient extends EventTarget {
797
907
  updateExternalJwt(jwt: string): Promise<void>;
798
908
  get state(): AuthState;
799
909
  getAuthHeaders(): Promise<Record<string, string>>;
910
+ private clearStorage;
800
911
  logout(): Promise<void>;
801
912
  /**
802
913
  * Public API methods that automatically wait for authentication
@@ -810,81 +921,6 @@ export declare class MageMetricsClient extends EventTarget {
810
921
  request: string;
811
922
  user_id: string | null;
812
923
  }[]>;
813
- getFlowDataInsights: (flowId: string, { count }: {
814
- count: boolean;
815
- }) => Promise<{
816
- count: false;
817
- data_reports: {
818
- title: string;
819
- status: string | null;
820
- id: number;
821
- request: string | null;
822
- created_at: string;
823
- bookmarked: boolean;
824
- flow_id: string;
825
- data_summary: {
826
- columns: Record<string, objectOutputType< {
827
- position: ZodOptional<ZodNumber>;
828
- data_type: ZodString;
829
- null_count: ZodNullable<ZodNumber>;
830
- unique_count: ZodNullable<ZodNumber>;
831
- unique_percentage: ZodNullable<ZodNumber>;
832
- }, ZodTypeAny, "passthrough">>;
833
- } & {
834
- [k: string]: unknown;
835
- };
836
- }[];
837
- visualizations: {
838
- id: number;
839
- flow_data_id: number;
840
- created_at: string;
841
- configuration: {
842
- type: "bar";
843
- title: string;
844
- xAxisLabel: string;
845
- yAxisLabel: string;
846
- config_version: 2;
847
- categoryColumn: string;
848
- valueColumn: string;
849
- secondaryCategoryColumn?: string | undefined;
850
- } | {
851
- type: "line/area";
852
- title: string;
853
- valueColumns: string[];
854
- config_version: 2;
855
- xAxisColumn: string;
856
- yAxisLabels: string[];
857
- } | {
858
- type: "line/area-categorical";
859
- title: string;
860
- xAxisLabel: string;
861
- yAxisLabel: string;
862
- config_version: 2;
863
- categoryColumn: string;
864
- valueColumn: string;
865
- xAxisColumn: string;
866
- } | {
867
- type: "scatter";
868
- title: string;
869
- xAxisLabel: string;
870
- yAxisLabel: string;
871
- config_version: 2;
872
- xAxisValueColumn: string;
873
- yAxisValueColumn: string;
874
- } | {
875
- type: "pie";
876
- title: string;
877
- config_version: 2;
878
- categoryColumn: string;
879
- valueColumn: string;
880
- };
881
- bookmarked: boolean;
882
- }[];
883
- } | {
884
- count: true;
885
- data_reports: number;
886
- visualizations: number;
887
- }>;
888
924
  /**
889
925
  * @deprecated Use `createFlow` instead.
890
926
  * @param request the user request
@@ -914,6 +950,7 @@ export declare class MageMetricsClient extends EventTarget {
914
950
  colSpan: number;
915
951
  rowSpan: number;
916
952
  })[];
953
+ is_public: boolean;
917
954
  }>;
918
955
  exportReportData: (reportId: number, format?: "text" | "blob") => Promise<{
919
956
  filename: string;
@@ -959,12 +996,15 @@ export declare interface MageMetricsClientConfig {
959
996
  additionalHeaders?: Record<string, string>;
960
997
  }
961
998
 
962
- export declare const MageMetricsContextProvider: default_2.FC<MageMetricsContextProviderProps>;
999
+ export declare const MageMetricsContextProvider: default_2.FC<MageMetricsContextProviderProps & MageMetricsPublicContextProviderProps>;
963
1000
 
964
- export declare interface MageMetricsContextProviderProps extends MageMetricsClientConfig {
965
- children: default_2.ReactNode;
1001
+ export declare type MageMetricsContextProviderProps = PropsWithChildren<MageMetricsClientConfig>;
1002
+
1003
+ export declare const MageMetricsPublicContextProvider: default_2.FC<MageMetricsPublicContextProviderProps>;
1004
+
1005
+ declare type MageMetricsPublicContextProviderProps = PropsWithChildren<Pick<MageMetricsClientConfig, "apiUrl" | "apiKey"> & {
966
1006
  experimental_components?: Components;
967
- }
1007
+ }>;
968
1008
 
969
1009
  export declare const ManagedModal: React.FC<ManagedModalProps>;
970
1010
 
@@ -1133,81 +1173,107 @@ declare interface operations {
1133
1173
  };
1134
1174
  };
1135
1175
  };
1136
- runEnd2EndFlow: {
1176
+ PublicDashboardFetchVisualization: {
1137
1177
  parameters: {
1138
1178
  query?: never;
1139
- header: {
1140
- "sp-access-token": string;
1141
- "sp-refresh-token"?: string;
1179
+ header?: never;
1180
+ path: {
1181
+ visualization_id: string;
1182
+ dashboard_id: string;
1142
1183
  };
1143
- path?: never;
1144
1184
  cookie?: never;
1145
1185
  };
1146
- requestBody: {
1147
- content: {
1148
- "application/json": {
1149
- userQuery: string;
1150
- /** @default true */
1151
- isNewAnalysisGoal?: boolean;
1152
- /**
1153
- * @default complex
1154
- * @enum {string}
1155
- */
1156
- difficultyLevel?: "simple" | "moderate" | "complex";
1157
- };
1158
- };
1159
- };
1186
+ requestBody?: never;
1160
1187
  responses: {
1161
- /** @description Run the end2end flow */
1188
+ /** @description The content of the visualization */
1162
1189
  200: {
1190
+ headers: {
1191
+ [name: string]: unknown;
1192
+ };
1193
+ content: {
1194
+ "application/json": components["schemas"]["VisualizationWithData"];
1195
+ };
1196
+ };
1197
+ /** @description Invalid arguments to fetch visualization */
1198
+ 400: {
1199
+ headers: {
1200
+ [name: string]: unknown;
1201
+ };
1202
+ content: {
1203
+ "application/json": {
1204
+ error: string;
1205
+ };
1206
+ };
1207
+ };
1208
+ /** @description Unable to fetch visualization with this id */
1209
+ 404: {
1210
+ headers: {
1211
+ [name: string]: unknown;
1212
+ };
1213
+ content: {
1214
+ "application/json": {
1215
+ error: string;
1216
+ };
1217
+ };
1218
+ };
1219
+ /** @description Something wrong happened */
1220
+ 500: {
1163
1221
  headers: {
1164
1222
  [name: string]: unknown;
1165
1223
  };
1166
1224
  content: {
1167
1225
  "application/json": {
1168
- /** @enum {string} */
1169
- status: "error";
1170
1226
  error: string;
1171
- } | {
1172
- /** @enum {string} */
1173
- status: "success";
1174
- flowId: string;
1175
1227
  };
1176
1228
  };
1177
1229
  };
1178
1230
  };
1179
1231
  };
1180
- retrieveFlow: {
1232
+ retrievePublicDashboard: {
1181
1233
  parameters: {
1182
1234
  query?: never;
1183
- header: {
1184
- "sp-access-token": string;
1185
- "sp-refresh-token"?: string;
1186
- };
1235
+ header?: never;
1187
1236
  path: {
1188
- flowId: string;
1237
+ dashboard_id: components["schemas"]["DashboardId"];
1189
1238
  };
1190
1239
  cookie?: never;
1191
1240
  };
1192
1241
  requestBody?: never;
1193
1242
  responses: {
1194
- /** @description The flow with its steps */
1243
+ /** @description The dashboard with the given id */
1195
1244
  200: {
1196
1245
  headers: {
1197
1246
  [name: string]: unknown;
1198
1247
  };
1199
1248
  content: {
1200
1249
  "application/json": {
1201
- created_at: string;
1250
+ description: string | null;
1251
+ /** Format: uuid */
1202
1252
  id: string;
1203
- request: string;
1204
- user_id: string | null;
1205
- user_friendly_goal?: string;
1206
- has_chat_messages: boolean;
1253
+ name: string;
1254
+ positions: ({
1255
+ /** @enum {string} */
1256
+ type: "data-report";
1257
+ flowId: string;
1258
+ flowDataId: number;
1259
+ title: string;
1260
+ col: number;
1261
+ colSpan: number;
1262
+ rowSpan: number;
1263
+ } | {
1264
+ /** @enum {string} */
1265
+ type: "visualization";
1266
+ visualizationId: number;
1267
+ title: string;
1268
+ col: number;
1269
+ colSpan: number;
1270
+ rowSpan: number;
1271
+ })[];
1272
+ is_public: boolean;
1207
1273
  };
1208
1274
  };
1209
1275
  };
1210
- /** @description Unable to retrieve flow with this id */
1276
+ /** @description Unable to retrieve dashboard with this id */
1211
1277
  404: {
1212
1278
  headers: {
1213
1279
  [name: string]: unknown;
@@ -1231,32 +1297,88 @@ declare interface operations {
1231
1297
  };
1232
1298
  };
1233
1299
  };
1234
- retrieveRecentFlows: {
1300
+ getPublicDataReportColumns: {
1301
+ parameters: {
1302
+ query?: never;
1303
+ header?: never;
1304
+ path: {
1305
+ report_id: string;
1306
+ dashboard_id: components["schemas"]["DashboardId"];
1307
+ };
1308
+ cookie?: never;
1309
+ };
1310
+ requestBody?: never;
1311
+ responses: {
1312
+ /** @description A list containing the columns of the report */
1313
+ 200: {
1314
+ headers: {
1315
+ [name: string]: unknown;
1316
+ };
1317
+ content: {
1318
+ "application/json": components["schemas"]["ReportColumns"];
1319
+ };
1320
+ };
1321
+ /** @description Unable to retrieve report with this id */
1322
+ 404: {
1323
+ headers: {
1324
+ [name: string]: unknown;
1325
+ };
1326
+ content: {
1327
+ "application/json": {
1328
+ error: string;
1329
+ };
1330
+ };
1331
+ };
1332
+ /** @description Something wrong happened */
1333
+ 500: {
1334
+ headers: {
1335
+ [name: string]: unknown;
1336
+ };
1337
+ content: {
1338
+ "application/json": {
1339
+ error: string;
1340
+ };
1341
+ };
1342
+ };
1343
+ };
1344
+ };
1345
+ getPublicDataReportData: {
1235
1346
  parameters: {
1236
1347
  query?: {
1237
1348
  limit?: number;
1349
+ /** @example name:asc,date:desc */
1350
+ order?: string;
1351
+ cursor?: number;
1352
+ /** @example status:active,name:John%20Doe */
1353
+ filter?: string;
1238
1354
  };
1239
- header: {
1240
- "sp-access-token": string;
1241
- "sp-refresh-token"?: string;
1355
+ header?: never;
1356
+ path: {
1357
+ report_id: string;
1358
+ dashboard_id: components["schemas"]["DashboardId"];
1242
1359
  };
1243
- path?: never;
1244
1360
  cookie?: never;
1245
1361
  };
1246
1362
  requestBody?: never;
1247
1363
  responses: {
1248
- /** @description A list of recent flows */
1364
+ /** @description The content of the report */
1249
1365
  200: {
1366
+ headers: {
1367
+ [name: string]: unknown;
1368
+ };
1369
+ content: {
1370
+ "application/json": components["schemas"]["ReportData"];
1371
+ };
1372
+ };
1373
+ /** @description Unable to retrieve report with this id */
1374
+ 404: {
1250
1375
  headers: {
1251
1376
  [name: string]: unknown;
1252
1377
  };
1253
1378
  content: {
1254
1379
  "application/json": {
1255
- created_at: string;
1256
- id: string;
1257
- request: string;
1258
- user_id: string | null;
1259
- }[];
1380
+ error: string;
1381
+ };
1260
1382
  };
1261
1383
  };
1262
1384
  /** @description Something wrong happened */
@@ -1272,112 +1394,123 @@ declare interface operations {
1272
1394
  };
1273
1395
  };
1274
1396
  };
1275
- retrieveFlowDataInsights: {
1397
+ getPublicDataReportRowCount: {
1276
1398
  parameters: {
1277
- query?: {
1278
- count?: boolean;
1399
+ query?: never;
1400
+ header?: never;
1401
+ path: {
1402
+ report_id: string;
1403
+ dashboard_id: components["schemas"]["DashboardId"];
1279
1404
  };
1405
+ cookie?: never;
1406
+ };
1407
+ requestBody?: never;
1408
+ responses: {
1409
+ /** @description The total count of rows in the report */
1410
+ 200: {
1411
+ headers: {
1412
+ [name: string]: unknown;
1413
+ };
1414
+ content: {
1415
+ "application/json": {
1416
+ /** @description Total number of rows in the report */
1417
+ count: number;
1418
+ };
1419
+ };
1420
+ };
1421
+ /** @description Unable to retrieve report with this id */
1422
+ 404: {
1423
+ headers: {
1424
+ [name: string]: unknown;
1425
+ };
1426
+ content: {
1427
+ "application/json": {
1428
+ error: string;
1429
+ };
1430
+ };
1431
+ };
1432
+ /** @description Something wrong happened */
1433
+ 500: {
1434
+ headers: {
1435
+ [name: string]: unknown;
1436
+ };
1437
+ content: {
1438
+ "application/json": {
1439
+ error: string;
1440
+ };
1441
+ };
1442
+ };
1443
+ };
1444
+ };
1445
+ runEnd2EndFlow: {
1446
+ parameters: {
1447
+ query?: never;
1280
1448
  header: {
1281
1449
  "sp-access-token": string;
1282
- "sp-refresh-token"?: string;
1283
- };
1284
- path: {
1285
- flowId: string;
1286
1450
  };
1451
+ path?: never;
1287
1452
  cookie?: never;
1288
1453
  };
1289
- requestBody?: never;
1454
+ requestBody: {
1455
+ content: {
1456
+ "application/json": {
1457
+ userQuery: string;
1458
+ /** @default true */
1459
+ isNewAnalysisGoal?: boolean;
1460
+ /**
1461
+ * @default complex
1462
+ * @enum {string}
1463
+ */
1464
+ difficultyLevel?: "simple" | "moderate" | "complex";
1465
+ };
1466
+ };
1467
+ };
1290
1468
  responses: {
1291
- /** @description Flow data insights (data reports and visualizations) */
1469
+ /** @description Run the end2end flow */
1292
1470
  200: {
1293
1471
  headers: {
1294
1472
  [name: string]: unknown;
1295
1473
  };
1296
1474
  content: {
1297
1475
  "application/json": {
1298
- /** @enum {boolean} */
1299
- count: false;
1300
- data_reports: {
1301
- created_at: string;
1302
- flow_id: string;
1303
- id: number;
1304
- title: string;
1305
- request: string | null;
1306
- data_summary: {
1307
- columns: {
1308
- [key: string]: {
1309
- position?: number;
1310
- data_type: string;
1311
- null_count: number | null;
1312
- unique_count: number | null;
1313
- unique_percentage: number | null;
1314
- };
1315
- };
1316
- };
1317
- bookmarked: boolean;
1318
- status: string | null;
1319
- }[];
1320
- visualizations: {
1321
- id: number;
1322
- flow_data_id: number;
1323
- created_at: string;
1324
- configuration: {
1325
- /** @enum {string} */
1326
- type: "bar";
1327
- title: string;
1328
- /** @enum {number} */
1329
- config_version: 2;
1330
- xAxisLabel: string;
1331
- yAxisLabel: string;
1332
- categoryColumn: string;
1333
- secondaryCategoryColumn?: string;
1334
- valueColumn: string;
1335
- } | {
1336
- /** @enum {string} */
1337
- type: "line/area";
1338
- /** @enum {number} */
1339
- config_version: 2;
1340
- title: string;
1341
- xAxisColumn: string;
1342
- valueColumns: string[];
1343
- yAxisLabels: string[];
1344
- } | {
1345
- /** @enum {string} */
1346
- type: "line/area-categorical";
1347
- title: string;
1348
- /** @enum {number} */
1349
- config_version: 2;
1350
- valueColumn: string;
1351
- xAxisColumn: string;
1352
- xAxisLabel: string;
1353
- yAxisLabel: string;
1354
- categoryColumn: string;
1355
- } | {
1356
- /** @enum {string} */
1357
- type: "scatter";
1358
- title: string;
1359
- /** @enum {number} */
1360
- config_version: 2;
1361
- xAxisLabel: string;
1362
- yAxisLabel: string;
1363
- xAxisValueColumn: string;
1364
- yAxisValueColumn: string;
1365
- } | {
1366
- /** @enum {string} */
1367
- type: "pie";
1368
- title: string;
1369
- /** @enum {number} */
1370
- config_version: 2;
1371
- categoryColumn: string;
1372
- valueColumn: string;
1373
- };
1374
- bookmarked: boolean;
1375
- }[];
1476
+ /** @enum {string} */
1477
+ status: "error";
1478
+ error: string;
1376
1479
  } | {
1377
- /** @enum {boolean} */
1378
- count: true;
1379
- data_reports: number;
1380
- visualizations: number;
1480
+ /** @enum {string} */
1481
+ status: "success";
1482
+ flowId: string;
1483
+ };
1484
+ };
1485
+ };
1486
+ };
1487
+ };
1488
+ retrieveFlow: {
1489
+ parameters: {
1490
+ query?: never;
1491
+ header: {
1492
+ "sp-access-token": string;
1493
+ };
1494
+ path: {
1495
+ flowId: string;
1496
+ };
1497
+ cookie?: never;
1498
+ };
1499
+ requestBody?: never;
1500
+ responses: {
1501
+ /** @description The flow with its steps */
1502
+ 200: {
1503
+ headers: {
1504
+ [name: string]: unknown;
1505
+ };
1506
+ content: {
1507
+ "application/json": {
1508
+ created_at: string;
1509
+ id: string;
1510
+ request: string;
1511
+ user_id: string | null;
1512
+ user_friendly_goal?: string;
1513
+ has_chat_messages: boolean;
1381
1514
  };
1382
1515
  };
1383
1516
  };
@@ -1405,12 +1538,51 @@ declare interface operations {
1405
1538
  };
1406
1539
  };
1407
1540
  };
1541
+ retrieveRecentFlows: {
1542
+ parameters: {
1543
+ query?: {
1544
+ limit?: number;
1545
+ };
1546
+ header: {
1547
+ "sp-access-token": string;
1548
+ };
1549
+ path?: never;
1550
+ cookie?: never;
1551
+ };
1552
+ requestBody?: never;
1553
+ responses: {
1554
+ /** @description A list of recent flows */
1555
+ 200: {
1556
+ headers: {
1557
+ [name: string]: unknown;
1558
+ };
1559
+ content: {
1560
+ "application/json": {
1561
+ created_at: string;
1562
+ id: string;
1563
+ request: string;
1564
+ user_id: string | null;
1565
+ }[];
1566
+ };
1567
+ };
1568
+ /** @description Something wrong happened */
1569
+ 500: {
1570
+ headers: {
1571
+ [name: string]: unknown;
1572
+ };
1573
+ content: {
1574
+ "application/json": {
1575
+ error: string;
1576
+ };
1577
+ };
1578
+ };
1579
+ };
1580
+ };
1408
1581
  retrieveFlowDataReports: {
1409
1582
  parameters: {
1410
1583
  query?: never;
1411
1584
  header: {
1412
1585
  "sp-access-token": string;
1413
- "sp-refresh-token"?: string;
1414
1586
  };
1415
1587
  path: {
1416
1588
  flowId: string;
@@ -1476,7 +1648,6 @@ declare interface operations {
1476
1648
  query?: never;
1477
1649
  header: {
1478
1650
  "sp-access-token": string;
1479
- "sp-refresh-token"?: string;
1480
1651
  };
1481
1652
  path: {
1482
1653
  report_id: string;
@@ -1529,7 +1700,6 @@ declare interface operations {
1529
1700
  query?: never;
1530
1701
  header: {
1531
1702
  "sp-access-token": string;
1532
- "sp-refresh-token"?: string;
1533
1703
  };
1534
1704
  path: {
1535
1705
  report_id: string;
@@ -1571,7 +1741,6 @@ declare interface operations {
1571
1741
  query?: never;
1572
1742
  header: {
1573
1743
  "sp-access-token": string;
1574
- "sp-refresh-token"?: string;
1575
1744
  };
1576
1745
  path: {
1577
1746
  report_id: string;
@@ -1616,7 +1785,6 @@ declare interface operations {
1616
1785
  query?: never;
1617
1786
  header: {
1618
1787
  "sp-access-token": string;
1619
- "sp-refresh-token"?: string;
1620
1788
  };
1621
1789
  path: {
1622
1790
  flowId: string;
@@ -1665,7 +1833,6 @@ declare interface operations {
1665
1833
  query?: never;
1666
1834
  header: {
1667
1835
  "sp-access-token": string;
1668
- "sp-refresh-token"?: string;
1669
1836
  };
1670
1837
  path: {
1671
1838
  report_id: string;
@@ -1752,7 +1919,6 @@ declare interface operations {
1752
1919
  query?: never;
1753
1920
  header: {
1754
1921
  "sp-access-token": string;
1755
- "sp-refresh-token"?: string;
1756
1922
  };
1757
1923
  path?: never;
1758
1924
  cookie?: never;
@@ -1815,7 +1981,6 @@ declare interface operations {
1815
1981
  query?: never;
1816
1982
  header: {
1817
1983
  "sp-access-token": string;
1818
- "sp-refresh-token"?: string;
1819
1984
  };
1820
1985
  path?: never;
1821
1986
  cookie?: never;
@@ -1862,7 +2027,6 @@ declare interface operations {
1862
2027
  query?: never;
1863
2028
  header: {
1864
2029
  "sp-access-token": string;
1865
- "sp-refresh-token"?: string;
1866
2030
  };
1867
2031
  path: {
1868
2032
  report_id: string;
@@ -1909,7 +2073,6 @@ declare interface operations {
1909
2073
  query?: never;
1910
2074
  header: {
1911
2075
  "sp-access-token": string;
1912
- "sp-refresh-token"?: string;
1913
2076
  };
1914
2077
  path: {
1915
2078
  report_id: string;
@@ -1954,6 +2117,8 @@ declare interface operations {
1954
2117
  getDataReportData: {
1955
2118
  parameters: {
1956
2119
  query?: {
2120
+ /** @example name,date */
2121
+ columns?: string;
1957
2122
  limit?: number;
1958
2123
  /** @example name:asc,date:desc */
1959
2124
  order?: string;
@@ -1963,7 +2128,6 @@ declare interface operations {
1963
2128
  };
1964
2129
  header: {
1965
2130
  "sp-access-token": string;
1966
- "sp-refresh-token"?: string;
1967
2131
  };
1968
2132
  path: {
1969
2133
  report_id: string;
@@ -2010,7 +2174,6 @@ declare interface operations {
2010
2174
  query?: never;
2011
2175
  header: {
2012
2176
  "sp-access-token": string;
2013
- "sp-refresh-token"?: string;
2014
2177
  };
2015
2178
  path: {
2016
2179
  report_id: string;
@@ -2060,7 +2223,6 @@ declare interface operations {
2060
2223
  query?: never;
2061
2224
  header: {
2062
2225
  "sp-access-token": string;
2063
- "sp-refresh-token"?: string;
2064
2226
  };
2065
2227
  path: {
2066
2228
  report_id: string;
@@ -2098,6 +2260,7 @@ declare interface operations {
2098
2260
  id: number;
2099
2261
  flow_data_id: number;
2100
2262
  created_at: string;
2263
+ bookmarked: boolean;
2101
2264
  configuration: {
2102
2265
  /** @enum {string} */
2103
2266
  type: "bar";
@@ -2135,11 +2298,11 @@ declare interface operations {
2135
2298
  nameKey: string;
2136
2299
  dataKey: string;
2137
2300
  };
2138
- bookmarked: boolean;
2139
2301
  } | {
2140
2302
  id: number;
2141
2303
  flow_data_id: number;
2142
2304
  created_at: string;
2305
+ bookmarked: boolean;
2143
2306
  configuration: {
2144
2307
  /** @enum {string} */
2145
2308
  type: "bar";
@@ -2190,7 +2353,6 @@ declare interface operations {
2190
2353
  categoryColumn: string;
2191
2354
  valueColumn: string;
2192
2355
  };
2193
- bookmarked: boolean;
2194
2356
  })[];
2195
2357
  };
2196
2358
  };
@@ -2224,7 +2386,6 @@ declare interface operations {
2224
2386
  query?: never;
2225
2387
  header: {
2226
2388
  "sp-access-token": string;
2227
- "sp-refresh-token"?: string;
2228
2389
  };
2229
2390
  path?: never;
2230
2391
  cookie?: never;
@@ -2268,7 +2429,6 @@ declare interface operations {
2268
2429
  query?: never;
2269
2430
  header: {
2270
2431
  "sp-access-token": string;
2271
- "sp-refresh-token"?: string;
2272
2432
  };
2273
2433
  path: {
2274
2434
  flowId: string;
@@ -2334,7 +2494,6 @@ declare interface operations {
2334
2494
  query?: never;
2335
2495
  header: {
2336
2496
  "sp-access-token": string;
2337
- "sp-refresh-token"?: string;
2338
2497
  };
2339
2498
  path: {
2340
2499
  flowId: string;
@@ -2385,7 +2544,6 @@ declare interface operations {
2385
2544
  };
2386
2545
  header: {
2387
2546
  "sp-access-token": string;
2388
- "sp-refresh-token"?: string;
2389
2547
  };
2390
2548
  path?: never;
2391
2549
  cookie?: never;
@@ -2421,10 +2579,9 @@ declare interface operations {
2421
2579
  query?: never;
2422
2580
  header: {
2423
2581
  "sp-access-token": string;
2424
- "sp-refresh-token"?: string;
2425
2582
  };
2426
2583
  path: {
2427
- flowDataVisualizationId: string;
2584
+ visualization_id: string;
2428
2585
  };
2429
2586
  cookie?: never;
2430
2587
  };
@@ -2436,116 +2593,7 @@ declare interface operations {
2436
2593
  [name: string]: unknown;
2437
2594
  };
2438
2595
  content: {
2439
- "application/json": {
2440
- id: number;
2441
- flow_data_id: number;
2442
- created_at: string;
2443
- configuration: {
2444
- /** @enum {string} */
2445
- type: "bar";
2446
- title: string;
2447
- xAxisLabel: string;
2448
- yAxisLabel: string;
2449
- xAxisDataKey?: string;
2450
- yAxisDataKey?: string;
2451
- dimensionDataKey?: string;
2452
- valueColumns?: string[];
2453
- } | {
2454
- /** @enum {string} */
2455
- type: "line/area";
2456
- title: string;
2457
- xAxisLabel: string;
2458
- yAxisLabel: string;
2459
- xAxisDataKey?: string;
2460
- yAxisDataKey?: string;
2461
- dimensionDataKey?: string;
2462
- valueColumns?: string[];
2463
- } | {
2464
- /** @enum {string} */
2465
- type: "scatter";
2466
- title: string;
2467
- xAxisLabel: string;
2468
- yAxisLabel: string;
2469
- xAxisDataKey?: string;
2470
- yAxisDataKey?: string;
2471
- dimensionDataKey?: string;
2472
- valueColumns?: string[];
2473
- } | {
2474
- /** @enum {string} */
2475
- type: "pie";
2476
- title: string;
2477
- nameKey: string;
2478
- dataKey: string;
2479
- };
2480
- bookmarked: boolean;
2481
- data: components["schemas"]["VisualizationData"];
2482
- _metadata?: {
2483
- wasSampled: boolean;
2484
- originalCount: number;
2485
- sampledCount: number;
2486
- };
2487
- } | {
2488
- id: number;
2489
- flow_data_id: number;
2490
- created_at: string;
2491
- configuration: {
2492
- /** @enum {string} */
2493
- type: "bar";
2494
- title: string;
2495
- /** @enum {number} */
2496
- config_version: 2;
2497
- xAxisLabel: string;
2498
- yAxisLabel: string;
2499
- categoryColumn: string;
2500
- secondaryCategoryColumn?: string;
2501
- valueColumn: string;
2502
- } | {
2503
- /** @enum {string} */
2504
- type: "line/area";
2505
- /** @enum {number} */
2506
- config_version: 2;
2507
- title: string;
2508
- xAxisColumn: string;
2509
- valueColumns: string[];
2510
- yAxisLabels: string[];
2511
- } | {
2512
- /** @enum {string} */
2513
- type: "line/area-categorical";
2514
- title: string;
2515
- /** @enum {number} */
2516
- config_version: 2;
2517
- valueColumn: string;
2518
- xAxisColumn: string;
2519
- xAxisLabel: string;
2520
- yAxisLabel: string;
2521
- categoryColumn: string;
2522
- } | {
2523
- /** @enum {string} */
2524
- type: "scatter";
2525
- title: string;
2526
- /** @enum {number} */
2527
- config_version: 2;
2528
- xAxisLabel: string;
2529
- yAxisLabel: string;
2530
- xAxisValueColumn: string;
2531
- yAxisValueColumn: string;
2532
- } | {
2533
- /** @enum {string} */
2534
- type: "pie";
2535
- title: string;
2536
- /** @enum {number} */
2537
- config_version: 2;
2538
- categoryColumn: string;
2539
- valueColumn: string;
2540
- };
2541
- bookmarked: boolean;
2542
- data: components["schemas"]["VisualizationData"];
2543
- _metadata?: {
2544
- wasSampled: boolean;
2545
- originalCount: number;
2546
- sampledCount: number;
2547
- };
2548
- };
2596
+ "application/json": components["schemas"]["VisualizationWithData"];
2549
2597
  };
2550
2598
  };
2551
2599
  /** @description Invalid arguments to fetch visualization */
@@ -2590,7 +2638,6 @@ declare interface operations {
2590
2638
  };
2591
2639
  header: {
2592
2640
  "sp-access-token": string;
2593
- "sp-refresh-token"?: string;
2594
2641
  };
2595
2642
  path: {
2596
2643
  flowId: string;
@@ -2609,6 +2656,7 @@ declare interface operations {
2609
2656
  id: number;
2610
2657
  flow_data_id: number;
2611
2658
  created_at: string;
2659
+ bookmarked: boolean;
2612
2660
  configuration: {
2613
2661
  /** @enum {string} */
2614
2662
  type: "bar";
@@ -2659,7 +2707,6 @@ declare interface operations {
2659
2707
  categoryColumn: string;
2660
2708
  valueColumn: string;
2661
2709
  };
2662
- bookmarked: boolean;
2663
2710
  }[];
2664
2711
  };
2665
2712
  };
@@ -2703,7 +2750,6 @@ declare interface operations {
2703
2750
  query?: never;
2704
2751
  header: {
2705
2752
  "sp-access-token": string;
2706
- "sp-refresh-token"?: string;
2707
2753
  };
2708
2754
  path?: never;
2709
2755
  cookie?: never;
@@ -2777,10 +2823,9 @@ declare interface operations {
2777
2823
  query?: never;
2778
2824
  header: {
2779
2825
  "sp-access-token": string;
2780
- "sp-refresh-token"?: string;
2781
2826
  };
2782
2827
  path: {
2783
- dashboardId: string;
2828
+ dashboard_id: components["schemas"]["DashboardId"];
2784
2829
  };
2785
2830
  cookie?: never;
2786
2831
  };
@@ -2794,6 +2839,7 @@ declare interface operations {
2794
2839
  content: {
2795
2840
  "application/json": {
2796
2841
  description: string | null;
2842
+ /** Format: uuid */
2797
2843
  id: string;
2798
2844
  name: string;
2799
2845
  positions: ({
@@ -2814,6 +2860,7 @@ declare interface operations {
2814
2860
  colSpan: number;
2815
2861
  rowSpan: number;
2816
2862
  })[];
2863
+ is_public: boolean;
2817
2864
  };
2818
2865
  };
2819
2866
  };
@@ -3437,30 +3484,30 @@ declare interface paths {
3437
3484
  patch?: never;
3438
3485
  trace?: never;
3439
3486
  };
3440
- "/api/v1/end2end": {
3487
+ "/api/v1/public/dashboards/{dashboard_id}/visualizations/{visualization_id}": {
3441
3488
  parameters: {
3442
3489
  query?: never;
3443
3490
  header?: never;
3444
3491
  path?: never;
3445
3492
  cookie?: never;
3446
3493
  };
3447
- get?: never;
3494
+ get: operations["PublicDashboardFetchVisualization"];
3448
3495
  put?: never;
3449
- post: operations["runEnd2EndFlow"];
3496
+ post?: never;
3450
3497
  delete?: never;
3451
3498
  options?: never;
3452
3499
  head?: never;
3453
3500
  patch?: never;
3454
3501
  trace?: never;
3455
3502
  };
3456
- "/api/v1/flows/{flowId}": {
3503
+ "/api/v1/public/dashboards/{dashboard_id}": {
3457
3504
  parameters: {
3458
3505
  query?: never;
3459
3506
  header?: never;
3460
3507
  path?: never;
3461
3508
  cookie?: never;
3462
3509
  };
3463
- get: operations["retrieveFlow"];
3510
+ get: operations["retrievePublicDashboard"];
3464
3511
  put?: never;
3465
3512
  post?: never;
3466
3513
  delete?: never;
@@ -3469,14 +3516,78 @@ declare interface paths {
3469
3516
  patch?: never;
3470
3517
  trace?: never;
3471
3518
  };
3472
- "/api/v1/recent-flows": {
3519
+ "/api/v1/public/dashboards/{dashboard_id}/data-reports/{report_id}/columns": {
3473
3520
  parameters: {
3474
3521
  query?: never;
3475
3522
  header?: never;
3476
3523
  path?: never;
3477
3524
  cookie?: never;
3478
3525
  };
3479
- get: operations["retrieveRecentFlows"];
3526
+ get: operations["getPublicDataReportColumns"];
3527
+ put?: never;
3528
+ post?: never;
3529
+ delete?: never;
3530
+ options?: never;
3531
+ head?: never;
3532
+ patch?: never;
3533
+ trace?: never;
3534
+ };
3535
+ "/api/v1/public/dashboards/{dashboard_id}/data-reports/{report_id}/data": {
3536
+ parameters: {
3537
+ query?: never;
3538
+ header?: never;
3539
+ path?: never;
3540
+ cookie?: never;
3541
+ };
3542
+ get: operations["getPublicDataReportData"];
3543
+ put?: never;
3544
+ post?: never;
3545
+ delete?: never;
3546
+ options?: never;
3547
+ head?: never;
3548
+ patch?: never;
3549
+ trace?: never;
3550
+ };
3551
+ "/api/v1/public/dashboards/{dashboard_id}/data-reports/{report_id}/count": {
3552
+ parameters: {
3553
+ query?: never;
3554
+ header?: never;
3555
+ path?: never;
3556
+ cookie?: never;
3557
+ };
3558
+ get: operations["getPublicDataReportRowCount"];
3559
+ put?: never;
3560
+ post?: never;
3561
+ delete?: never;
3562
+ options?: never;
3563
+ head?: never;
3564
+ patch?: never;
3565
+ trace?: never;
3566
+ };
3567
+ "/api/v1/end2end": {
3568
+ parameters: {
3569
+ query?: never;
3570
+ header?: never;
3571
+ path?: never;
3572
+ cookie?: never;
3573
+ };
3574
+ get?: never;
3575
+ put?: never;
3576
+ post: operations["runEnd2EndFlow"];
3577
+ delete?: never;
3578
+ options?: never;
3579
+ head?: never;
3580
+ patch?: never;
3581
+ trace?: never;
3582
+ };
3583
+ "/api/v1/flows/{flowId}": {
3584
+ parameters: {
3585
+ query?: never;
3586
+ header?: never;
3587
+ path?: never;
3588
+ cookie?: never;
3589
+ };
3590
+ get: operations["retrieveFlow"];
3480
3591
  put?: never;
3481
3592
  post?: never;
3482
3593
  delete?: never;
@@ -3485,14 +3596,14 @@ declare interface paths {
3485
3596
  patch?: never;
3486
3597
  trace?: never;
3487
3598
  };
3488
- "/api/v1/flows/{flowId}/data-insights": {
3599
+ "/api/v1/recent-flows": {
3489
3600
  parameters: {
3490
3601
  query?: never;
3491
3602
  header?: never;
3492
3603
  path?: never;
3493
3604
  cookie?: never;
3494
3605
  };
3495
- get: operations["retrieveFlowDataInsights"];
3606
+ get: operations["retrieveRecentFlows"];
3496
3607
  put?: never;
3497
3608
  post?: never;
3498
3609
  delete?: never;
@@ -3741,7 +3852,7 @@ declare interface paths {
3741
3852
  patch?: never;
3742
3853
  trace?: never;
3743
3854
  };
3744
- "/api/v1/visualizations/{flowDataVisualizationId}": {
3855
+ "/api/v1/visualizations/{visualization_id}": {
3745
3856
  parameters: {
3746
3857
  query?: never;
3747
3858
  header?: never;
@@ -3789,7 +3900,7 @@ declare interface paths {
3789
3900
  patch?: never;
3790
3901
  trace?: never;
3791
3902
  };
3792
- "/api/v1/dashboard/{dashboardId}": {
3903
+ "/api/v1/dashboard/{dashboard_id}": {
3793
3904
  parameters: {
3794
3905
  query?: never;
3795
3906
  header?: never;
@@ -3969,6 +4080,13 @@ declare interface paths {
3969
4080
 
3970
4081
  declare type PersistenceOptions = "queryParam" | "none";
3971
4082
 
4083
+ export declare const PublicDashboard: React.FC<React.ComponentProps<typeof Dashboard_2>>;
4084
+
4085
+ export declare const PublicDataReport: React.FC<{
4086
+ dashboardId: string;
4087
+ reportId: number;
4088
+ }>;
4089
+
3972
4090
  declare type RemoveAuthHeader<PathSchema> = Simplify<{
3973
4091
  [Method in keyof PathSchema]: RemoveParams<PathSchema[Method], ToRemove>;
3974
4092
  }>;
@@ -3991,6 +4109,14 @@ declare type RemoveParamsConfig = Simplify<{
3991
4109
  cookie?: string;
3992
4110
  }>;
3993
4111
 
4112
+ declare type ReportDataFilters = {
4113
+ columns?: string[];
4114
+ limit: number;
4115
+ sorting: SortingState;
4116
+ filters: TableFilters;
4117
+ cursor?: number;
4118
+ };
4119
+
3994
4120
  export declare const StandaloneConversationModal: React.FC<StandaloneConversationModalProps>;
3995
4121
 
3996
4122
  declare type StandaloneConversationModalProps = {
@@ -4012,8 +4138,10 @@ declare type StartOptions = DisplayControlProps & {
4012
4138
  placeholders?: string[];
4013
4139
  };
4014
4140
 
4141
+ declare type TableFilters = Record<string, string | number>;
4142
+
4015
4143
  declare type ToRemove = Simplify<{
4016
- header: "sp-access-token" | "sp-refresh-token";
4144
+ header: "sp-access-token";
4017
4145
  }>;
4018
4146
 
4019
4147
  export declare const useCreateFlow: (options?: UseMutationOptions<{
@@ -4192,6 +4320,8 @@ export declare const useDataReport: (flowDataId: FrontendReport["id"]) => {
4192
4320
  infiniteData: InfiniteData<Record<string, unknown>[], unknown> | undefined;
4193
4321
  };
4194
4322
 
4323
+ export declare const useDataReportColumnValue: (reportId: number, filters: ReportDataFilters) => UseQueryResult<Record<string, unknown>[], Error>;
4324
+
4195
4325
  export declare const useDownloadReportData: (options?: UseMutationOptions<ExportReportDataResult, Error, ExportReportDataParams>) => {
4196
4326
  download: UseMutateFunction<ExportReportDataResult, Error, ExportReportDataParams, unknown>;
4197
4327
  data: undefined;
@@ -4266,82 +4396,6 @@ export declare const useDownloadReportData: (options?: UseMutationOptions<Export
4266
4396
  mutateAsync: UseMutateAsyncFunction<ExportReportDataResult, Error, ExportReportDataParams, unknown>;
4267
4397
  };
4268
4398
 
4269
- export declare const useFlowDataInsights: (flowId: string, enabled?: boolean) => UseQueryResult< {
4270
- count: false;
4271
- data_reports: {
4272
- title: string;
4273
- status: string | null;
4274
- id: number;
4275
- request: string | null;
4276
- created_at: string;
4277
- bookmarked: boolean;
4278
- flow_id: string;
4279
- data_summary: {
4280
- columns: Record<string, objectOutputType< {
4281
- position: ZodOptional<ZodNumber>;
4282
- data_type: ZodString;
4283
- null_count: ZodNullable<ZodNumber>;
4284
- unique_count: ZodNullable<ZodNumber>;
4285
- unique_percentage: ZodNullable<ZodNumber>;
4286
- }, ZodTypeAny, "passthrough">>;
4287
- } & {
4288
- [k: string]: unknown;
4289
- };
4290
- }[];
4291
- visualizations: {
4292
- id: number;
4293
- flow_data_id: number;
4294
- created_at: string;
4295
- configuration: {
4296
- type: "bar";
4297
- title: string;
4298
- xAxisLabel: string;
4299
- yAxisLabel: string;
4300
- config_version: 2;
4301
- categoryColumn: string;
4302
- valueColumn: string;
4303
- secondaryCategoryColumn?: string | undefined;
4304
- } | {
4305
- type: "line/area";
4306
- title: string;
4307
- valueColumns: string[];
4308
- config_version: 2;
4309
- xAxisColumn: string;
4310
- yAxisLabels: string[];
4311
- } | {
4312
- type: "line/area-categorical";
4313
- title: string;
4314
- xAxisLabel: string;
4315
- yAxisLabel: string;
4316
- config_version: 2;
4317
- categoryColumn: string;
4318
- valueColumn: string;
4319
- xAxisColumn: string;
4320
- } | {
4321
- type: "scatter";
4322
- title: string;
4323
- xAxisLabel: string;
4324
- yAxisLabel: string;
4325
- config_version: 2;
4326
- xAxisValueColumn: string;
4327
- yAxisValueColumn: string;
4328
- } | {
4329
- type: "pie";
4330
- title: string;
4331
- config_version: 2;
4332
- categoryColumn: string;
4333
- valueColumn: string;
4334
- };
4335
- bookmarked: boolean;
4336
- }[];
4337
- }, Error>;
4338
-
4339
- export declare const useFlowDataInsightsCount: (flowId: string) => UseQueryResult< {
4340
- count: true;
4341
- data_reports: number;
4342
- visualizations: number;
4343
- }, Error>;
4344
-
4345
4399
  export declare const useGenerateContextualInsight: (options?: UseMutationOptions<ExtractInsightResponse, Error, GenerateInsightParam>) => {
4346
4400
  generateInsight: UseMutateFunction< {
4347
4401
  type: "text";
@@ -4608,6 +4662,12 @@ declare const V1FrontendVisualizationSchema: z.ZodObject<Omit<{
4608
4662
  id: z.ZodNumber;
4609
4663
  flow_data_id: z.ZodNumber;
4610
4664
  created_at: z.ZodString;
4665
+ sql: z.ZodString;
4666
+ bookmarked: z.ZodBoolean;
4667
+ data_sample: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>, "many">;
4668
+ is_sample: z.ZodBoolean;
4669
+ data_summary: z.ZodRecord<z.ZodString, z.ZodUnknown>;
4670
+ } & {
4611
4671
  configuration: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4612
4672
  xAxisLabel: z.ZodString;
4613
4673
  yAxisLabel: z.ZodString;
@@ -4705,12 +4765,11 @@ declare const V1FrontendVisualizationSchema: z.ZodObject<Omit<{
4705
4765
  nameKey: string;
4706
4766
  dataKey: string;
4707
4767
  }>]>;
4708
- sql: z.ZodString;
4709
- bookmarked: z.ZodBoolean;
4710
- }, "sql">, "strip", z.ZodTypeAny, {
4768
+ }, "sql" | "data_sample" | "is_sample" | "data_summary">, "strip", z.ZodTypeAny, {
4711
4769
  id: number;
4712
4770
  flow_data_id: number;
4713
4771
  created_at: string;
4772
+ bookmarked: boolean;
4714
4773
  configuration: {
4715
4774
  type: "bar";
4716
4775
  title: string;
@@ -4744,11 +4803,11 @@ declare const V1FrontendVisualizationSchema: z.ZodObject<Omit<{
4744
4803
  nameKey: string;
4745
4804
  dataKey: string;
4746
4805
  };
4747
- bookmarked: boolean;
4748
4806
  }, {
4749
4807
  id: number;
4750
4808
  flow_data_id: number;
4751
4809
  created_at: string;
4810
+ bookmarked: boolean;
4752
4811
  configuration: {
4753
4812
  type: "bar";
4754
4813
  title: string;
@@ -4782,7 +4841,6 @@ declare const V1FrontendVisualizationSchema: z.ZodObject<Omit<{
4782
4841
  nameKey: string;
4783
4842
  dataKey: string;
4784
4843
  };
4785
- bookmarked: boolean;
4786
4844
  }>;
4787
4845
 
4788
4846
  export declare const Visualization: ForwardRefExoticComponent< {