@adventurelabs/scout-core 1.4.46 → 1.4.47
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/helpers/tags.d.ts
CHANGED
|
@@ -16,3 +16,9 @@ export declare function server_get_tags_for_artifact(artifactId: number, options
|
|
|
16
16
|
end_timestamp?: string | null;
|
|
17
17
|
max_elements?: number;
|
|
18
18
|
}): Promise<IWebResponseCompatible<ITagPrettyLocation[]>>;
|
|
19
|
+
/** Tags for an event with optional timestamp range and max items. */
|
|
20
|
+
export declare function server_get_tags_for_event(eventId: number, options?: {
|
|
21
|
+
start_timestamp?: string | null;
|
|
22
|
+
end_timestamp?: string | null;
|
|
23
|
+
max_elements?: number;
|
|
24
|
+
}): Promise<IWebResponseCompatible<ITagPrettyLocation[]>>;
|
package/dist/helpers/tags.js
CHANGED
|
@@ -480,3 +480,26 @@ export async function server_get_tags_for_artifact(artifactId, options) {
|
|
|
480
480
|
}
|
|
481
481
|
return IWebResponse.success(data ?? []).to_compatible();
|
|
482
482
|
}
|
|
483
|
+
/** Tags for an event with optional timestamp range and max items. */
|
|
484
|
+
export async function server_get_tags_for_event(eventId, options) {
|
|
485
|
+
const supabase = await newServerClient();
|
|
486
|
+
const { data, error } = await supabase.rpc("get_tags_for_event", {
|
|
487
|
+
event_id_caller: eventId,
|
|
488
|
+
max_elements_caller: options?.max_elements ?? 1000,
|
|
489
|
+
...(options?.start_timestamp != null && {
|
|
490
|
+
start_timestamp_caller: options.start_timestamp,
|
|
491
|
+
}),
|
|
492
|
+
...(options?.end_timestamp != null && {
|
|
493
|
+
end_timestamp_caller: options.end_timestamp,
|
|
494
|
+
}),
|
|
495
|
+
});
|
|
496
|
+
if (error) {
|
|
497
|
+
console.warn("Error fetching tags for event:", error.message);
|
|
498
|
+
return {
|
|
499
|
+
status: EnumWebResponse.ERROR,
|
|
500
|
+
msg: error.message,
|
|
501
|
+
data: [],
|
|
502
|
+
};
|
|
503
|
+
}
|
|
504
|
+
return IWebResponse.success(data ?? []).to_compatible();
|
|
505
|
+
}
|
|
@@ -302,6 +302,7 @@ export declare function useSupabase(): SupabaseClient<Database, "public", "publi
|
|
|
302
302
|
associated_station: string | null;
|
|
303
303
|
bandwidth_hz: number | null;
|
|
304
304
|
battery_percentage: number | null;
|
|
305
|
+
battery_volts: number | null;
|
|
305
306
|
device_id: number | null;
|
|
306
307
|
frequency_hz: number | null;
|
|
307
308
|
h11_index: string;
|
|
@@ -323,6 +324,7 @@ export declare function useSupabase(): SupabaseClient<Database, "public", "publi
|
|
|
323
324
|
associated_station?: string | null;
|
|
324
325
|
bandwidth_hz?: number | null;
|
|
325
326
|
battery_percentage?: number | null;
|
|
327
|
+
battery_volts?: number | null;
|
|
326
328
|
device_id?: number | null;
|
|
327
329
|
frequency_hz?: number | null;
|
|
328
330
|
h11_index: string;
|
|
@@ -344,6 +346,7 @@ export declare function useSupabase(): SupabaseClient<Database, "public", "publi
|
|
|
344
346
|
associated_station?: string | null;
|
|
345
347
|
bandwidth_hz?: number | null;
|
|
346
348
|
battery_percentage?: number | null;
|
|
349
|
+
battery_volts?: number | null;
|
|
347
350
|
device_id?: number | null;
|
|
348
351
|
frequency_hz?: number | null;
|
|
349
352
|
h11_index?: string;
|
|
@@ -2453,6 +2456,21 @@ export declare function useSupabase(): SupabaseClient<Database, "public", "publi
|
|
|
2453
2456
|
isSetofReturn: true;
|
|
2454
2457
|
};
|
|
2455
2458
|
};
|
|
2459
|
+
get_tags_for_event: {
|
|
2460
|
+
Args: {
|
|
2461
|
+
end_timestamp_caller?: string;
|
|
2462
|
+
event_id_caller: number;
|
|
2463
|
+
max_elements_caller?: number;
|
|
2464
|
+
start_timestamp_caller?: string;
|
|
2465
|
+
};
|
|
2466
|
+
Returns: Database["public"]["CompositeTypes"]["tags_pretty_location"][];
|
|
2467
|
+
SetofOptions: {
|
|
2468
|
+
from: "*";
|
|
2469
|
+
to: "tags_pretty_location";
|
|
2470
|
+
isOneToOne: false;
|
|
2471
|
+
isSetofReturn: true;
|
|
2472
|
+
};
|
|
2473
|
+
};
|
|
2456
2474
|
get_total_artifacts_for_herd: {
|
|
2457
2475
|
Args: {
|
|
2458
2476
|
herd_id_caller: number;
|
|
@@ -2647,6 +2665,7 @@ export declare function useSupabase(): SupabaseClient<Database, "public", "publi
|
|
|
2647
2665
|
bandwidth_hz: number | null;
|
|
2648
2666
|
associated_station: string | null;
|
|
2649
2667
|
mode: string | null;
|
|
2668
|
+
battery_volts: number | null;
|
|
2650
2669
|
};
|
|
2651
2670
|
device_heartbeat_analysis: {
|
|
2652
2671
|
device_id: number | null;
|
package/dist/types/supabase.d.ts
CHANGED
|
@@ -315,6 +315,7 @@ export type Database = {
|
|
|
315
315
|
associated_station: string | null;
|
|
316
316
|
bandwidth_hz: number | null;
|
|
317
317
|
battery_percentage: number | null;
|
|
318
|
+
battery_volts: number | null;
|
|
318
319
|
device_id: number | null;
|
|
319
320
|
frequency_hz: number | null;
|
|
320
321
|
h11_index: string;
|
|
@@ -336,6 +337,7 @@ export type Database = {
|
|
|
336
337
|
associated_station?: string | null;
|
|
337
338
|
bandwidth_hz?: number | null;
|
|
338
339
|
battery_percentage?: number | null;
|
|
340
|
+
battery_volts?: number | null;
|
|
339
341
|
device_id?: number | null;
|
|
340
342
|
frequency_hz?: number | null;
|
|
341
343
|
h11_index: string;
|
|
@@ -357,6 +359,7 @@ export type Database = {
|
|
|
357
359
|
associated_station?: string | null;
|
|
358
360
|
bandwidth_hz?: number | null;
|
|
359
361
|
battery_percentage?: number | null;
|
|
362
|
+
battery_volts?: number | null;
|
|
360
363
|
device_id?: number | null;
|
|
361
364
|
frequency_hz?: number | null;
|
|
362
365
|
h11_index?: string;
|
|
@@ -2538,6 +2541,21 @@ export type Database = {
|
|
|
2538
2541
|
isSetofReturn: true;
|
|
2539
2542
|
};
|
|
2540
2543
|
};
|
|
2544
|
+
get_tags_for_event: {
|
|
2545
|
+
Args: {
|
|
2546
|
+
end_timestamp_caller?: string;
|
|
2547
|
+
event_id_caller: number;
|
|
2548
|
+
max_elements_caller?: number;
|
|
2549
|
+
start_timestamp_caller?: string;
|
|
2550
|
+
};
|
|
2551
|
+
Returns: Database["public"]["CompositeTypes"]["tags_pretty_location"][];
|
|
2552
|
+
SetofOptions: {
|
|
2553
|
+
from: "*";
|
|
2554
|
+
to: "tags_pretty_location";
|
|
2555
|
+
isOneToOne: false;
|
|
2556
|
+
isSetofReturn: true;
|
|
2557
|
+
};
|
|
2558
|
+
};
|
|
2541
2559
|
get_total_artifacts_for_herd: {
|
|
2542
2560
|
Args: {
|
|
2543
2561
|
herd_id_caller: number;
|
|
@@ -2732,6 +2750,7 @@ export type Database = {
|
|
|
2732
2750
|
bandwidth_hz: number | null;
|
|
2733
2751
|
associated_station: string | null;
|
|
2734
2752
|
mode: string | null;
|
|
2753
|
+
battery_volts: number | null;
|
|
2735
2754
|
};
|
|
2736
2755
|
device_heartbeat_analysis: {
|
|
2737
2756
|
device_id: number | null;
|