@sentry/junior 0.193.0 → 0.195.0

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.
Files changed (99) hide show
  1. package/dist/{agent-hooks-DWY3MZZ7.js → agent-hooks-VIBTIP5F.js} +11 -11
  2. package/dist/api/activity.d.ts +9 -1
  3. package/dist/api/code/overview.d.ts +12 -0
  4. package/dist/api/conversations/aggregate.d.ts +2 -0
  5. package/dist/api/conversations/list.d.ts +1 -1
  6. package/dist/api/conversations/projection.d.ts +1 -1
  7. package/dist/api/locations/detail.d.ts +9 -1
  8. package/dist/api/locations/list.d.ts +5 -0
  9. package/dist/api/people/code.d.ts +6 -0
  10. package/dist/api/people/shared.d.ts +9 -1
  11. package/dist/api/reporting-window.d.ts +39 -1
  12. package/dist/api/schema/code.d.ts +12 -0
  13. package/dist/api/schema/conversation.d.ts +28 -3
  14. package/dist/api/schema/location.d.ts +14 -1
  15. package/dist/api/schema/person.d.ts +15 -1
  16. package/dist/api/schema/task.d.ts +83 -8
  17. package/dist/api/schema.d.ts +2 -2
  18. package/dist/api/schema.js +3 -1
  19. package/dist/api.js +320 -222
  20. package/dist/app.js +108 -39
  21. package/dist/{catalog-runtime-NAD44W5K.js → catalog-runtime-6E6SGRZK.js} +4 -4
  22. package/dist/chat/agent/resume.d.ts +2 -0
  23. package/dist/chat/config.d.ts +2 -0
  24. package/dist/chat/conversations/history.d.ts +4 -2
  25. package/dist/chat/event-tasks/store.d.ts +27 -17
  26. package/dist/chat/resource-events/notification.d.ts +2 -1
  27. package/dist/chat/services/automated-turn-limit.d.ts +110 -0
  28. package/dist/chat/services/turn-limit.d.ts +11 -1
  29. package/dist/chat/slack/automated-turn-limit-notice.d.ts +38 -0
  30. package/dist/chat/slack/{source-link.d.ts → location-url.d.ts} +1 -1
  31. package/dist/chat/task-execution/checkpoint.d.ts +2 -0
  32. package/dist/chat/task-execution/turn-cursor.d.ts +3 -0
  33. package/dist/chat/tasks/execution-stats.d.ts +15 -2
  34. package/dist/chat/tasks/read.d.ts +5 -2
  35. package/dist/chat/usage.d.ts +4 -0
  36. package/dist/{chunk-GUKGU6R7.js → chunk-3VWIZVK7.js} +1 -1
  37. package/dist/{chunk-THYNA2QN.js → chunk-5HNXLP4W.js} +1 -1
  38. package/dist/{chunk-GUMBIDDL.js → chunk-5NR7N567.js} +194 -43
  39. package/dist/{chunk-N6Q2PNSI.js → chunk-6GGDBXXP.js} +3 -3
  40. package/dist/{chunk-HMBTX5RK.js → chunk-6TRQLG3D.js} +1 -1
  41. package/dist/{chunk-IOUUS6H4.js → chunk-7MYXH5LA.js} +1 -1
  42. package/dist/{chunk-WH5VV2RW.js → chunk-7PQMTME5.js} +1 -1
  43. package/dist/{chunk-5E5SLAVD.js → chunk-7UED4D5T.js} +23 -25
  44. package/dist/{chunk-4UA5C7AM.js → chunk-BJZML4RT.js} +8 -8
  45. package/dist/{chunk-QDU5MW2R.js → chunk-C4NY6L7S.js} +1 -1
  46. package/dist/{chunk-DVU734PI.js → chunk-CE2P6TOV.js} +3 -3
  47. package/dist/{chunk-BFP3ZKG6.js → chunk-DTYOEHUP.js} +148 -19
  48. package/dist/{chunk-S5HS6WRH.js → chunk-FE3Y4KES.js} +5 -5
  49. package/dist/{chunk-PYBFVK6K.js → chunk-FEZIEEOP.js} +985 -569
  50. package/dist/{chunk-5S6AQFNG.js → chunk-FPQPYJEG.js} +23 -29
  51. package/dist/{chunk-42N6CDWF.js → chunk-HE5PZAPS.js} +4 -4
  52. package/dist/{chunk-QY2IU47O.js → chunk-HUQOXMDG.js} +1 -1
  53. package/dist/{chunk-IQCL5JGL.js → chunk-I4RH3KLJ.js} +1 -1
  54. package/dist/{chunk-LXRTHE43.js → chunk-JBSCMOLR.js} +5 -5
  55. package/dist/{chunk-OICYQPKP.js → chunk-KBPWC7NU.js} +1 -1
  56. package/dist/{chunk-2CYWEVOP.js → chunk-KQ3GZGBK.js} +88 -68
  57. package/dist/{chunk-GTXQHZ2O.js → chunk-KUQRWV53.js} +5 -5
  58. package/dist/{chunk-IBXXTO3J.js → chunk-L62JVQPL.js} +3 -3
  59. package/dist/{chunk-KWXZMHJS.js → chunk-LM7UE523.js} +3 -3
  60. package/dist/{chunk-WJJDQLVL.js → chunk-LMYRF6HX.js} +6 -2
  61. package/dist/{chunk-AZVDODSP.js → chunk-N67T4VY3.js} +9 -9
  62. package/dist/{chunk-D4XQZOHB.js → chunk-OQHO62VA.js} +8 -8
  63. package/dist/{chunk-FQ5HFSFR.js → chunk-PFQRZ4IB.js} +9 -6
  64. package/dist/{chunk-LG7Q4OW4.js → chunk-PYTRZZ4V.js} +8 -8
  65. package/dist/{chunk-THFNL3TL.js → chunk-QHJZSYKY.js} +2 -2
  66. package/dist/{chunk-5LEVZYXF.js → chunk-QKHZF2LH.js} +4 -4
  67. package/dist/{chunk-EYIMZY5O.js → chunk-QPZL2IYT.js} +100 -9
  68. package/dist/{chunk-D5YQPCEG.js → chunk-R5BGW4WR.js} +24 -2
  69. package/dist/{chunk-COCVPDWX.js → chunk-R5OHONYU.js} +6 -6
  70. package/dist/{chunk-DXFUYLHX.js → chunk-RKA22BQP.js} +1 -1
  71. package/dist/{chunk-3YZ2Q6AW.js → chunk-RQO67SAO.js} +2 -2
  72. package/dist/{chunk-ZFPEPWOO.js → chunk-RZ3PBNDV.js} +60 -29
  73. package/dist/{chunk-K47OVEO4.js → chunk-VYDIA2UL.js} +1 -1
  74. package/dist/{chunk-QWY4KI2V.js → chunk-X3PBQ4BK.js} +1 -1
  75. package/dist/cli/chat.js +33 -33
  76. package/dist/cli/check.js +5 -5
  77. package/dist/cli/plugins.js +12 -12
  78. package/dist/cli/snapshot-create.js +9 -9
  79. package/dist/cli/upgrade.js +6 -6
  80. package/dist/db/schema/event-tasks.d.ts +21 -0
  81. package/dist/db/schema.d.ts +19 -0
  82. package/dist/{db-H5MDRQEY.js → db-FVCSDROR.js} +6 -6
  83. package/dist/instrumentation.js +3 -3
  84. package/dist/nitro.js +6 -6
  85. package/dist/{oauth-callback-server-IOU3NUHT.js → oauth-callback-server-Z5PXTDOE.js} +29 -29
  86. package/dist/{runner-FZ5ZHLFG.js → runner-RHYU7OGV.js} +21 -21
  87. package/dist/{skills-AR3WD6BX.js → skills-QTN73DN5.js} +5 -5
  88. package/dist/spawn-R56OWLUH.js +42 -0
  89. package/dist/task-runner-LLJZTLRP.js +36 -0
  90. package/dist/{validation-VYE7TQY7.js → validation-2ZK7GA6N.js} +5 -5
  91. package/dist/version.js +1 -1
  92. package/dist/{work-CTQFWYKE.js → work-7IBKSZRU.js} +21 -21
  93. package/dist/{worker-6WQU3IT5.js → worker-RNVQVCO7.js} +10 -10
  94. package/migrations/0038_event_task_status.sql +5 -0
  95. package/migrations/meta/0038_snapshot.json +3323 -0
  96. package/migrations/meta/_journal.json +8 -1
  97. package/package.json +4 -4
  98. package/dist/spawn-ZU6JABR7.js +0 -42
  99. package/dist/task-runner-EEGGG2PM.js +0 -36
@@ -13,26 +13,26 @@ import {
13
13
  getPlugins,
14
14
  setPlugins,
15
15
  validatePlugins
16
- } from "./chunk-FQ5HFSFR.js";
16
+ } from "./chunk-PFQRZ4IB.js";
17
17
  import "./chunk-3Y47VMHV.js";
18
- import "./chunk-2CYWEVOP.js";
19
- import "./chunk-5S6AQFNG.js";
20
- import "./chunk-KWXZMHJS.js";
21
- import "./chunk-IOUUS6H4.js";
18
+ import "./chunk-KQ3GZGBK.js";
19
+ import "./chunk-FPQPYJEG.js";
20
+ import "./chunk-LM7UE523.js";
21
+ import "./chunk-7MYXH5LA.js";
22
22
  import "./chunk-GFBR4S3Q.js";
23
23
  import "./chunk-VFUK3X5B.js";
24
- import "./chunk-WJJDQLVL.js";
24
+ import "./chunk-LMYRF6HX.js";
25
25
  import "./chunk-D4YV5TDV.js";
26
- import "./chunk-OICYQPKP.js";
27
- import "./chunk-DXFUYLHX.js";
28
- import "./chunk-QWY4KI2V.js";
26
+ import "./chunk-KBPWC7NU.js";
27
+ import "./chunk-RKA22BQP.js";
28
+ import "./chunk-X3PBQ4BK.js";
29
29
  import "./chunk-CEMMLV5L.js";
30
30
  import "./chunk-N7TMSOZH.js";
31
31
  import "./chunk-DWPN6SCH.js";
32
32
  import "./chunk-TXKUKMVO.js";
33
- import "./chunk-QY2IU47O.js";
33
+ import "./chunk-HUQOXMDG.js";
34
34
  import "./chunk-PEQXYSSE.js";
35
- import "./chunk-QDU5MW2R.js";
35
+ import "./chunk-C4NY6L7S.js";
36
36
  export {
37
37
  PluginHookDeniedError,
38
38
  applyPluginFormatMarkdown,
@@ -12,5 +12,13 @@ export type DailyConversationActivity = z.infer<typeof dailyConversationActivity
12
12
  export declare function emptyActivityDay(date: string): DailyConversationActivity;
13
13
  /** Fill a fixed UTC day window from sparse conversation activity. */
14
14
  export declare function activityDays(days: Map<string, DailyConversationActivity>, nowMs: number, count: number): DailyConversationActivity[];
15
- /** Fill the trailing UTC hour window from sparse conversation activity. */
15
+ /**
16
+ * Fill the trailing 7-day UTC hour window from known hour rows.
17
+ * 24h charts use the last 24 points. 7d charts sum hours into 6-hour buckets.
18
+ */
16
19
  export declare function activityHours(hours: Map<string, DailyConversationActivity>, nowMs: number): DailyConversationActivity[];
20
+ /**
21
+ * Fill trailing 6-hour buckets from hour keys or hour rows.
22
+ * Hour keys must be summed into 6-hour keys first.
23
+ */
24
+ export declare function activitySixHours(hours: Map<string, DailyConversationActivity> | readonly DailyConversationActivity[], nowMs: number): DailyConversationActivity[];
@@ -49,6 +49,12 @@ export declare function readCodeOverview(nowMs?: number): Promise<{
49
49
  date: string;
50
50
  merged: number;
51
51
  }[] | undefined;
52
+ activitySixHours?: {
53
+ closed: number;
54
+ created: number;
55
+ date: string;
56
+ merged: number;
57
+ }[] | undefined;
52
58
  }>;
53
59
  /**
54
60
  * Read person-scoped code activity linked through conversation actors on
@@ -83,4 +89,10 @@ export declare function readPersonCodeOverview(args: {
83
89
  date: string;
84
90
  merged: number;
85
91
  }[] | undefined;
92
+ activitySixHours?: {
93
+ closed: number;
94
+ created: number;
95
+ date: string;
96
+ merged: number;
97
+ }[] | undefined;
86
98
  }>;
@@ -5,6 +5,8 @@ interface ConversationAggregateSource {
5
5
  executionStatus: AnyPgColumn;
6
6
  usage: AnyPgColumn;
7
7
  }
8
+ /** Read one conversation row's usage cost as a SQL expression. */
9
+ export declare function conversationUsageCostExpr(usage: AnyPgColumn): import("drizzle-orm").SQL<number | null>;
8
10
  /** Select complete conversation metrics inside the database instead of materializing source rows. */
9
11
  export declare function conversationAggregateColumns(sources?: {
10
12
  metrics: ConversationAggregateSource;
@@ -92,7 +92,7 @@ declare function conversationRows(db: JuniorDatabase, limit: number, status: "ac
92
92
  } | null;
93
93
  metricRunId: string | null;
94
94
  };
95
- destination: {
95
+ location: {
96
96
  id: string;
97
97
  provider: string;
98
98
  providerTenantId: string;
@@ -1,7 +1,7 @@
1
1
  import type { Conversation as StoredConversation } from "@/chat/conversations/store";
2
2
  import type { ConversationEventHistory, ConversationSummaryReport, ConversationUsage } from "../schema/conversation";
3
3
  import type { ConversationAccess } from "./access";
4
- type ConversationProjectionSource = Pick<StoredConversation, "actor" | "channelName" | "conversationId" | "createdAtMs" | "execution" | "lastActivityAtMs" | "source" | "sessionSource" | "title" | "updatedAtMs">;
4
+ type ConversationProjectionSource = Pick<StoredConversation, "actor" | "channelName" | "conversationId" | "createdAtMs" | "execution" | "lastActivityAtMs" | "location" | "source" | "title" | "updatedAtMs">;
5
5
  /** Describe whether a viewer can read one conversation's retained events. */
6
6
  export declare function conversationEventHistory(args: {
7
7
  canExposePayload: boolean;
@@ -86,7 +86,7 @@ export declare function readLocationDetail(locationId: string, options?: {
86
86
  channelNameRedacted?: boolean | undefined;
87
87
  locationId?: string | undefined;
88
88
  sentryTraceUrl?: string | undefined;
89
- sourceUrl?: string | undefined;
89
+ locationUrl?: string | undefined;
90
90
  traceId?: string | undefined;
91
91
  annotations?: ({
92
92
  kind: "resource_link";
@@ -123,4 +123,12 @@ export declare function readLocationDetail(locationId: string, options?: {
123
123
  failed: number;
124
124
  tokens?: number | undefined;
125
125
  }[] | undefined;
126
+ activitySixHours?: {
127
+ active: number;
128
+ conversations: number;
129
+ date: string;
130
+ durationMs: number;
131
+ failed: number;
132
+ tokens?: number | undefined;
133
+ }[] | undefined;
126
134
  } | undefined>;
@@ -39,4 +39,9 @@ export declare function readLocationDirectory(): Promise<{
39
39
  privateConversations: number;
40
40
  publicConversations: number;
41
41
  }[] | undefined;
42
+ activitySixHours?: {
43
+ date: string;
44
+ privateConversations: number;
45
+ publicConversations: number;
46
+ }[] | undefined;
42
47
  }>;
@@ -25,4 +25,10 @@ export declare function readPeopleCode(email: string): Promise<{
25
25
  date: string;
26
26
  merged: number;
27
27
  }[] | undefined;
28
+ activitySixHours?: {
29
+ closed: number;
30
+ created: number;
31
+ date: string;
32
+ merged: number;
33
+ }[] | undefined;
28
34
  }>;
@@ -1319,8 +1319,16 @@ export declare function emptyTotals(): ActorTotalsReport;
1319
1319
  export declare function emptyActivityDay(date: string): ActorActivityDayReport;
1320
1320
  /** Fill the fixed people profile activity window from sparse day totals. */
1321
1321
  export declare function activityDays(days: Map<string, ActorActivityDayReport>, nowMs: number): ActorActivityDayReport[];
1322
- /** Fill the trailing 24-hour people activity window from sparse hour totals. */
1322
+ /**
1323
+ * Fill the trailing 7-day people activity hour window from known hour totals.
1324
+ * 24h charts use the last 24 points. 7d charts sum hours into 6-hour buckets.
1325
+ */
1323
1326
  export declare function activityHours(hours: Map<string, ActorActivityDayReport>, nowMs: number): ActorActivityDayReport[];
1327
+ /**
1328
+ * Fill trailing 6-hour people activity buckets from hour keys or hour rows.
1329
+ * Hour keys must be summed into 6-hour keys first.
1330
+ */
1331
+ export declare function activitySixHours(hours: Map<string, ActorActivityDayReport> | readonly ActorActivityDayReport[], nowMs: number): ActorActivityDayReport[];
1324
1332
  /** Return deterministic stats rows for people API responses. */
1325
1333
  export declare function statsItems(map: Map<string, ConversationStatsItem>): {
1326
1334
  label: string;
@@ -1,15 +1,28 @@
1
- /** Shared UTC day/hour windows for dashboard activity series. */
1
+ /** Shared UTC day/hour/six-hour windows for dashboard activity series. */
2
2
  export declare const HOUR_MS: number;
3
+ export declare const SIX_HOUR_MS: number;
3
4
  export declare const DAY_MS: number;
5
+ /** Trailing hours kept for 24h charts. */
4
6
  export declare const WINDOW_HOURS = 24;
7
+ /**
8
+ * Trailing hours kept so 7d charts can roll hours into 6h buckets.
9
+ * 7 days * 24 hours = 168 inclusive hour points ending on the current hour.
10
+ */
11
+ export declare const WINDOW_SEVEN_DAY_HOURS: number;
12
+ /** Trailing 6h buckets for 7d charts (7 * 4). */
13
+ export declare const WINDOW_SIX_HOURS: number;
5
14
  /** Start of the UTC calendar day containing `valueMs`. */
6
15
  export declare function startOfUtcDay(valueMs: number): Date;
7
16
  /** Start of the UTC hour containing `valueMs`. */
8
17
  export declare function startOfUtcHour(valueMs: number): Date;
18
+ /** Start of the UTC 6-hour bucket containing `valueMs` (00/06/12/18). */
19
+ export declare function startOfUtcSixHour(valueMs: number): Date;
9
20
  /** UTC day key `YYYY-MM-DD`. */
10
21
  export declare function utcDayKey(value: Date | number): string;
11
22
  /** UTC hour key `YYYY-MM-DDTHH`. */
12
23
  export declare function utcHourKey(value: Date | number): string;
24
+ /** UTC 6-hour bucket key `YYYY-MM-DDTHH` at 00/06/12/18. */
25
+ export declare function utcSixHourKey(value: Date | number): string;
13
26
  /** Inclusive trailing UTC day window ending on today's UTC day. */
14
27
  export declare function trailingUtcDayWindow(nowMs: number, dayCount: number): {
15
28
  end: Date;
@@ -20,6 +33,11 @@ export declare function trailingUtcHourWindow(nowMs: number, hourCount?: number)
20
33
  end: Date;
21
34
  start: Date;
22
35
  };
36
+ /** Inclusive trailing UTC 6-hour window ending on the current 6h bucket. */
37
+ export declare function trailingUtcSixHourWindow(nowMs: number, bucketCount?: number): {
38
+ end: Date;
39
+ start: Date;
40
+ };
23
41
  /** Fill a fixed UTC day window from a sparse map. */
24
42
  export declare function fillUtcDays<T>(args: {
25
43
  count: number;
@@ -34,6 +52,26 @@ export declare function fillUtcHours<T>(args: {
34
52
  nowMs: number;
35
53
  rows: Map<string, T>;
36
54
  }): T[];
55
+ /** Fill a fixed UTC 6-hour window from a map of known rows. */
56
+ export declare function fillUtcSixHours<T>(args: {
57
+ count?: number;
58
+ empty(date: string): T;
59
+ nowMs: number;
60
+ rows: Map<string, T>;
61
+ }): T[];
62
+ /**
63
+ * Sum hour rows into trailing 6-hour buckets.
64
+ * Adds number fields. Keeps other fields from the first row in the bucket.
65
+ * Sets `date` to the 6-hour bucket key.
66
+ */
67
+ export declare function sumUtcHoursIntoSixHours<T extends {
68
+ date: string;
69
+ }>(args: {
70
+ empty(date: string): T;
71
+ hours: readonly T[];
72
+ nowMs: number;
73
+ count?: number;
74
+ }): T[];
37
75
  /** PostgreSQL TO_CHAR pattern for UTC day keys. */
38
76
  export declare const PG_UTC_DAY = "YYYY-MM-DD";
39
77
  /** PostgreSQL TO_CHAR pattern for UTC hour keys. */
@@ -58,6 +58,12 @@ export declare const codeOverviewReportSchema: z.ZodObject<{
58
58
  date: z.ZodString;
59
59
  merged: z.ZodNumber;
60
60
  }, z.core.$strict>>>;
61
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
62
+ closed: z.ZodNumber;
63
+ created: z.ZodNumber;
64
+ date: z.ZodString;
65
+ merged: z.ZodNumber;
66
+ }, z.core.$strict>>>;
61
67
  changes: z.ZodArray<z.ZodObject<{
62
68
  closedAt: z.ZodOptional<z.ZodString>;
63
69
  id: z.ZodString;
@@ -114,6 +120,12 @@ export declare const codePersonReportSchema: z.ZodObject<{
114
120
  date: z.ZodString;
115
121
  merged: z.ZodNumber;
116
122
  }, z.core.$strict>>>;
123
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
124
+ closed: z.ZodNumber;
125
+ created: z.ZodNumber;
126
+ date: z.ZodString;
127
+ merged: z.ZodNumber;
128
+ }, z.core.$strict>>>;
117
129
  generatedAt: z.ZodString;
118
130
  summary: z.ZodObject<{
119
131
  closed: z.ZodNumber;
@@ -245,7 +245,7 @@ export declare const conversationSummaryReportSchema: z.ZodObject<{
245
245
  channelNameRedacted: z.ZodOptional<z.ZodBoolean>;
246
246
  locationId: z.ZodOptional<z.ZodString>;
247
247
  sentryTraceUrl: z.ZodOptional<z.ZodString>;
248
- sourceUrl: z.ZodOptional<z.ZodString>;
248
+ locationUrl: z.ZodOptional<z.ZodString>;
249
249
  traceId: z.ZodOptional<z.ZodString>;
250
250
  annotations: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodDiscriminatedUnion<[z.ZodObject<{
251
251
  kind: z.ZodLiteral<"resource_link">;
@@ -799,7 +799,7 @@ export declare const conversationDetailReportSchema: z.ZodObject<{
799
799
  channelNameRedacted: z.ZodOptional<z.ZodBoolean>;
800
800
  locationId: z.ZodOptional<z.ZodString>;
801
801
  sentryTraceUrl: z.ZodOptional<z.ZodString>;
802
- sourceUrl: z.ZodOptional<z.ZodString>;
802
+ locationUrl: z.ZodOptional<z.ZodString>;
803
803
  traceId: z.ZodOptional<z.ZodString>;
804
804
  annotations: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodDiscriminatedUnion<[z.ZodObject<{
805
805
  kind: z.ZodLiteral<"resource_link">;
@@ -1380,7 +1380,7 @@ export declare const conversationFeedSchema: z.ZodObject<{
1380
1380
  channelNameRedacted: z.ZodOptional<z.ZodBoolean>;
1381
1381
  locationId: z.ZodOptional<z.ZodString>;
1382
1382
  sentryTraceUrl: z.ZodOptional<z.ZodString>;
1383
- sourceUrl: z.ZodOptional<z.ZodString>;
1383
+ locationUrl: z.ZodOptional<z.ZodString>;
1384
1384
  traceId: z.ZodOptional<z.ZodString>;
1385
1385
  annotations: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodDiscriminatedUnion<[z.ZodObject<{
1386
1386
  kind: z.ZodLiteral<"resource_link">;
@@ -1469,6 +1469,14 @@ export declare const guardianStatsSchema: z.ZodObject<{
1469
1469
  deny: z.ZodNumber;
1470
1470
  requests: z.ZodNumber;
1471
1471
  }, z.core.$strict>>>;
1472
+ metricSixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
1473
+ allow: z.ZodNumber;
1474
+ ask: z.ZodNumber;
1475
+ costUsd: z.ZodOptional<z.ZodNumber>;
1476
+ date: z.ZodString;
1477
+ deny: z.ZodNumber;
1478
+ requests: z.ZodNumber;
1479
+ }, z.core.$strict>>>;
1472
1480
  requests: z.ZodNumber;
1473
1481
  }, z.core.$strict>;
1474
1482
  export declare const conversationStatsReportSchema: z.ZodObject<{
@@ -1499,6 +1507,14 @@ export declare const conversationStatsReportSchema: z.ZodObject<{
1499
1507
  deny: z.ZodNumber;
1500
1508
  requests: z.ZodNumber;
1501
1509
  }, z.core.$strict>>>;
1510
+ metricSixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
1511
+ allow: z.ZodNumber;
1512
+ ask: z.ZodNumber;
1513
+ costUsd: z.ZodOptional<z.ZodNumber>;
1514
+ date: z.ZodString;
1515
+ deny: z.ZodNumber;
1516
+ requests: z.ZodNumber;
1517
+ }, z.core.$strict>>>;
1502
1518
  requests: z.ZodNumber;
1503
1519
  }, z.core.$strict>;
1504
1520
  metricDays: z.ZodArray<z.ZodObject<{
@@ -1519,6 +1535,15 @@ export declare const conversationStatsReportSchema: z.ZodObject<{
1519
1535
  inputTokens: z.ZodOptional<z.ZodNumber>;
1520
1536
  tokens: z.ZodOptional<z.ZodNumber>;
1521
1537
  }, z.core.$strict>>>;
1538
+ metricSixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
1539
+ cachedInputTokens: z.ZodOptional<z.ZodNumber>;
1540
+ conversations: z.ZodNumber;
1541
+ costUsd: z.ZodOptional<z.ZodNumber>;
1542
+ date: z.ZodString;
1543
+ durationMs: z.ZodNumber;
1544
+ inputTokens: z.ZodOptional<z.ZodNumber>;
1545
+ tokens: z.ZodOptional<z.ZodNumber>;
1546
+ }, z.core.$strict>>>;
1522
1547
  locations: z.ZodArray<z.ZodObject<{
1523
1548
  active: z.ZodNumber;
1524
1549
  conversations: z.ZodNumber;
@@ -58,6 +58,11 @@ export declare const locationDirectoryReportSchema: z.ZodObject<{
58
58
  privateConversations: z.ZodNumber;
59
59
  publicConversations: z.ZodNumber;
60
60
  }, z.core.$strict>>>;
61
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
62
+ date: z.ZodString;
63
+ privateConversations: z.ZodNumber;
64
+ publicConversations: z.ZodNumber;
65
+ }, z.core.$strict>>>;
61
66
  generatedAt: z.ZodString;
62
67
  locations: z.ZodArray<z.ZodObject<{
63
68
  active: z.ZodNumber;
@@ -133,6 +138,14 @@ export declare const locationDetailReportSchema: z.ZodObject<{
133
138
  failed: z.ZodNumber;
134
139
  tokens: z.ZodOptional<z.ZodNumber>;
135
140
  }, z.core.$strict>>>;
141
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
142
+ active: z.ZodNumber;
143
+ conversations: z.ZodNumber;
144
+ date: z.ZodString;
145
+ durationMs: z.ZodNumber;
146
+ failed: z.ZodNumber;
147
+ tokens: z.ZodOptional<z.ZodNumber>;
148
+ }, z.core.$strict>>>;
136
149
  actors: z.ZodArray<z.ZodObject<{
137
150
  active: z.ZodNumber;
138
151
  conversations: z.ZodNumber;
@@ -208,7 +221,7 @@ export declare const locationDetailReportSchema: z.ZodObject<{
208
221
  channelNameRedacted: z.ZodOptional<z.ZodBoolean>;
209
222
  locationId: z.ZodOptional<z.ZodString>;
210
223
  sentryTraceUrl: z.ZodOptional<z.ZodString>;
211
- sourceUrl: z.ZodOptional<z.ZodString>;
224
+ locationUrl: z.ZodOptional<z.ZodString>;
212
225
  traceId: z.ZodOptional<z.ZodString>;
213
226
  annotations: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodDiscriminatedUnion<[z.ZodObject<{
214
227
  kind: z.ZodLiteral<"resource_link">;
@@ -128,6 +128,11 @@ export declare const actorDirectoryReportSchema: z.ZodObject<{
128
128
  conversations: z.ZodNumber;
129
129
  date: z.ZodString;
130
130
  }, z.core.$strict>>>;
131
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
132
+ activePeople: z.ZodNumber;
133
+ conversations: z.ZodNumber;
134
+ date: z.ZodString;
135
+ }, z.core.$strict>>>;
131
136
  generatedAt: z.ZodString;
132
137
  people: z.ZodArray<z.ZodObject<{
133
138
  active: z.ZodNumber;
@@ -194,6 +199,15 @@ export declare const actorProfileReportSchema: z.ZodObject<{
194
199
  failed: z.ZodNumber;
195
200
  tokens: z.ZodOptional<z.ZodNumber>;
196
201
  }, z.core.$strict>>>;
202
+ activitySixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
203
+ active: z.ZodNumber;
204
+ conversations: z.ZodNumber;
205
+ costUsd: z.ZodOptional<z.ZodNumber>;
206
+ date: z.ZodString;
207
+ durationMs: z.ZodNumber;
208
+ failed: z.ZodNumber;
209
+ tokens: z.ZodOptional<z.ZodNumber>;
210
+ }, z.core.$strict>>>;
197
211
  generatedAt: z.ZodString;
198
212
  locations: z.ZodArray<z.ZodObject<{
199
213
  label: z.ZodString;
@@ -262,7 +276,7 @@ export declare const actorProfileReportSchema: z.ZodObject<{
262
276
  channelNameRedacted: z.ZodOptional<z.ZodBoolean>;
263
277
  locationId: z.ZodOptional<z.ZodString>;
264
278
  sentryTraceUrl: z.ZodOptional<z.ZodString>;
265
- sourceUrl: z.ZodOptional<z.ZodString>;
279
+ locationUrl: z.ZodOptional<z.ZodString>;
266
280
  traceId: z.ZodOptional<z.ZodString>;
267
281
  annotations: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodDiscriminatedUnion<[z.ZodObject<{
268
282
  kind: z.ZodLiteral<"resource_link">;
@@ -1,4 +1,11 @@
1
1
  import { z } from "zod";
2
+ /** Task run counts for the dashboard range control (24h/7d/30d/90d). */
3
+ export declare const taskRunWindowsSchema: z.ZodObject<{
4
+ 1: z.ZodNumber;
5
+ 7: z.ZodNumber;
6
+ 30: z.ZodNumber;
7
+ 90: z.ZodNumber;
8
+ }, z.core.$strict>;
2
9
  export declare const scheduledTaskSummarySchema: z.ZodObject<{
3
10
  createdAt: z.ZodString;
4
11
  createdBy: z.ZodString;
@@ -17,7 +24,12 @@ export declare const scheduledTaskSummarySchema: z.ZodObject<{
17
24
  lastConversationId: z.ZodOptional<z.ZodString>;
18
25
  lastRunAt: z.ZodOptional<z.ZodString>;
19
26
  ownedByViewer: z.ZodBoolean;
20
- runsLast7Days: z.ZodNumber;
27
+ runs: z.ZodObject<{
28
+ 1: z.ZodNumber;
29
+ 7: z.ZodNumber;
30
+ 30: z.ZodNumber;
31
+ 90: z.ZodNumber;
32
+ }, z.core.$strict>;
21
33
  title: z.ZodString;
22
34
  totalRuns: z.ZodNumber;
23
35
  kind: z.ZodLiteral<"scheduled">;
@@ -47,7 +59,12 @@ export declare const eventTaskSummarySchema: z.ZodObject<{
47
59
  lastConversationId: z.ZodOptional<z.ZodString>;
48
60
  lastRunAt: z.ZodOptional<z.ZodString>;
49
61
  ownedByViewer: z.ZodBoolean;
50
- runsLast7Days: z.ZodNumber;
62
+ runs: z.ZodObject<{
63
+ 1: z.ZodNumber;
64
+ 7: z.ZodNumber;
65
+ 30: z.ZodNumber;
66
+ 90: z.ZodNumber;
67
+ }, z.core.$strict>;
51
68
  title: z.ZodString;
52
69
  totalRuns: z.ZodNumber;
53
70
  events: z.ZodArray<z.ZodString>;
@@ -74,7 +91,12 @@ export declare const taskSummarySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
74
91
  lastConversationId: z.ZodOptional<z.ZodString>;
75
92
  lastRunAt: z.ZodOptional<z.ZodString>;
76
93
  ownedByViewer: z.ZodBoolean;
77
- runsLast7Days: z.ZodNumber;
94
+ runs: z.ZodObject<{
95
+ 1: z.ZodNumber;
96
+ 7: z.ZodNumber;
97
+ 30: z.ZodNumber;
98
+ 90: z.ZodNumber;
99
+ }, z.core.$strict>;
78
100
  title: z.ZodString;
79
101
  totalRuns: z.ZodNumber;
80
102
  kind: z.ZodLiteral<"scheduled">;
@@ -103,7 +125,12 @@ export declare const taskSummarySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
103
125
  lastConversationId: z.ZodOptional<z.ZodString>;
104
126
  lastRunAt: z.ZodOptional<z.ZodString>;
105
127
  ownedByViewer: z.ZodBoolean;
106
- runsLast7Days: z.ZodNumber;
128
+ runs: z.ZodObject<{
129
+ 1: z.ZodNumber;
130
+ 7: z.ZodNumber;
131
+ 30: z.ZodNumber;
132
+ 90: z.ZodNumber;
133
+ }, z.core.$strict>;
107
134
  title: z.ZodString;
108
135
  totalRuns: z.ZodNumber;
109
136
  events: z.ZodArray<z.ZodString>;
@@ -116,17 +143,26 @@ export declare const taskSummarySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
116
143
  export declare const taskMetricBucketSchema: z.ZodString;
117
144
  /** One UTC day/hour of completed task executions stacked by task type. */
118
145
  export declare const taskExecutionDaySchema: z.ZodObject<{
146
+ costUsd: z.ZodNumber;
119
147
  date: z.ZodString;
120
148
  event: z.ZodNumber;
121
149
  scheduled: z.ZodNumber;
122
150
  }, z.core.$strict>;
123
151
  export declare const taskListSchema: z.ZodObject<{
124
152
  executionDays: z.ZodArray<z.ZodObject<{
153
+ costUsd: z.ZodNumber;
125
154
  date: z.ZodString;
126
155
  event: z.ZodNumber;
127
156
  scheduled: z.ZodNumber;
128
157
  }, z.core.$strict>>;
129
158
  executionHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
159
+ costUsd: z.ZodNumber;
160
+ date: z.ZodString;
161
+ event: z.ZodNumber;
162
+ scheduled: z.ZodNumber;
163
+ }, z.core.$strict>>>;
164
+ executionSixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
165
+ costUsd: z.ZodNumber;
130
166
  date: z.ZodString;
131
167
  event: z.ZodNumber;
132
168
  scheduled: z.ZodNumber;
@@ -149,7 +185,12 @@ export declare const taskListSchema: z.ZodObject<{
149
185
  lastConversationId: z.ZodOptional<z.ZodString>;
150
186
  lastRunAt: z.ZodOptional<z.ZodString>;
151
187
  ownedByViewer: z.ZodBoolean;
152
- runsLast7Days: z.ZodNumber;
188
+ runs: z.ZodObject<{
189
+ 1: z.ZodNumber;
190
+ 7: z.ZodNumber;
191
+ 30: z.ZodNumber;
192
+ 90: z.ZodNumber;
193
+ }, z.core.$strict>;
153
194
  title: z.ZodString;
154
195
  totalRuns: z.ZodNumber;
155
196
  kind: z.ZodLiteral<"scheduled">;
@@ -178,7 +219,12 @@ export declare const taskListSchema: z.ZodObject<{
178
219
  lastConversationId: z.ZodOptional<z.ZodString>;
179
220
  lastRunAt: z.ZodOptional<z.ZodString>;
180
221
  ownedByViewer: z.ZodBoolean;
181
- runsLast7Days: z.ZodNumber;
222
+ runs: z.ZodObject<{
223
+ 1: z.ZodNumber;
224
+ 7: z.ZodNumber;
225
+ 30: z.ZodNumber;
226
+ 90: z.ZodNumber;
227
+ }, z.core.$strict>;
182
228
  title: z.ZodString;
183
229
  totalRuns: z.ZodNumber;
184
230
  events: z.ZodArray<z.ZodString>;
@@ -203,6 +249,8 @@ export declare const taskExecutionStatusSchema: z.ZodEnum<{
203
249
  }>;
204
250
  export declare const taskExecutionSchema: z.ZodObject<{
205
251
  conversationId: z.ZodOptional<z.ZodString>;
252
+ costUsd: z.ZodOptional<z.ZodNumber>;
253
+ durationMs: z.ZodOptional<z.ZodNumber>;
206
254
  executedAt: z.ZodString;
207
255
  executionId: z.ZodString;
208
256
  status: z.ZodEnum<{
@@ -211,6 +259,7 @@ export declare const taskExecutionSchema: z.ZodObject<{
211
259
  blocked: "blocked";
212
260
  }>;
213
261
  title: z.ZodOptional<z.ZodString>;
262
+ totalTokens: z.ZodOptional<z.ZodNumber>;
214
263
  }, z.core.$strict>;
215
264
  /** One UTC day/hour of terminal executions for a single task, stacked by status. */
216
265
  export declare const taskExecutionStatusDaySchema: z.ZodObject<{
@@ -232,8 +281,16 @@ export declare const taskExecutionListSchema: z.ZodObject<{
232
281
  date: z.ZodString;
233
282
  failed: z.ZodNumber;
234
283
  }, z.core.$strict>>>;
284
+ executionSixHours: z.ZodOptional<z.ZodArray<z.ZodObject<{
285
+ blocked: z.ZodNumber;
286
+ completed: z.ZodNumber;
287
+ date: z.ZodString;
288
+ failed: z.ZodNumber;
289
+ }, z.core.$strict>>>;
235
290
  executions: z.ZodArray<z.ZodObject<{
236
291
  conversationId: z.ZodOptional<z.ZodString>;
292
+ costUsd: z.ZodOptional<z.ZodNumber>;
293
+ durationMs: z.ZodOptional<z.ZodNumber>;
237
294
  executedAt: z.ZodString;
238
295
  executionId: z.ZodString;
239
296
  status: z.ZodEnum<{
@@ -242,6 +299,7 @@ export declare const taskExecutionListSchema: z.ZodObject<{
242
299
  blocked: "blocked";
243
300
  }>;
244
301
  title: z.ZodOptional<z.ZodString>;
302
+ totalTokens: z.ZodOptional<z.ZodNumber>;
245
303
  }, z.core.$strict>>;
246
304
  task: z.ZodDiscriminatedUnion<[z.ZodObject<{
247
305
  createdAt: z.ZodString;
@@ -261,7 +319,12 @@ export declare const taskExecutionListSchema: z.ZodObject<{
261
319
  lastConversationId: z.ZodOptional<z.ZodString>;
262
320
  lastRunAt: z.ZodOptional<z.ZodString>;
263
321
  ownedByViewer: z.ZodBoolean;
264
- runsLast7Days: z.ZodNumber;
322
+ runs: z.ZodObject<{
323
+ 1: z.ZodNumber;
324
+ 7: z.ZodNumber;
325
+ 30: z.ZodNumber;
326
+ 90: z.ZodNumber;
327
+ }, z.core.$strict>;
265
328
  title: z.ZodString;
266
329
  totalRuns: z.ZodNumber;
267
330
  kind: z.ZodLiteral<"scheduled">;
@@ -290,7 +353,12 @@ export declare const taskExecutionListSchema: z.ZodObject<{
290
353
  lastConversationId: z.ZodOptional<z.ZodString>;
291
354
  lastRunAt: z.ZodOptional<z.ZodString>;
292
355
  ownedByViewer: z.ZodBoolean;
293
- runsLast7Days: z.ZodNumber;
356
+ runs: z.ZodObject<{
357
+ 1: z.ZodNumber;
358
+ 7: z.ZodNumber;
359
+ 30: z.ZodNumber;
360
+ 90: z.ZodNumber;
361
+ }, z.core.$strict>;
294
362
  title: z.ZodString;
295
363
  totalRuns: z.ZodNumber;
296
364
  events: z.ZodArray<z.ZodString>;
@@ -303,6 +371,8 @@ export declare const taskExecutionListSchema: z.ZodObject<{
303
371
  }, z.core.$strict>;
304
372
  export declare const taskRunSchema: z.ZodObject<{
305
373
  conversationId: z.ZodOptional<z.ZodString>;
374
+ costUsd: z.ZodOptional<z.ZodNumber>;
375
+ durationMs: z.ZodOptional<z.ZodNumber>;
306
376
  executedAt: z.ZodString;
307
377
  executionId: z.ZodString;
308
378
  status: z.ZodEnum<{
@@ -311,6 +381,7 @@ export declare const taskRunSchema: z.ZodObject<{
311
381
  blocked: "blocked";
312
382
  }>;
313
383
  title: z.ZodOptional<z.ZodString>;
384
+ totalTokens: z.ZodOptional<z.ZodNumber>;
314
385
  kind: z.ZodEnum<{
315
386
  scheduled: "scheduled";
316
387
  event: "event";
@@ -321,6 +392,8 @@ export declare const taskRunSchema: z.ZodObject<{
321
392
  export declare const taskRunListSchema: z.ZodObject<{
322
393
  runs: z.ZodArray<z.ZodObject<{
323
394
  conversationId: z.ZodOptional<z.ZodString>;
395
+ costUsd: z.ZodOptional<z.ZodNumber>;
396
+ durationMs: z.ZodOptional<z.ZodNumber>;
324
397
  executedAt: z.ZodString;
325
398
  executionId: z.ZodString;
326
399
  status: z.ZodEnum<{
@@ -329,6 +402,7 @@ export declare const taskRunListSchema: z.ZodObject<{
329
402
  blocked: "blocked";
330
403
  }>;
331
404
  title: z.ZodOptional<z.ZodString>;
405
+ totalTokens: z.ZodOptional<z.ZodNumber>;
332
406
  kind: z.ZodEnum<{
333
407
  scheduled: "scheduled";
334
408
  event: "event";
@@ -344,5 +418,6 @@ export type TaskExecution = z.output<typeof taskExecutionSchema>;
344
418
  export type TaskExecutionList = z.output<typeof taskExecutionListSchema>;
345
419
  export type TaskRun = z.output<typeof taskRunSchema>;
346
420
  export type TaskRunList = z.output<typeof taskRunListSchema>;
421
+ export type TaskRunWindows = z.output<typeof taskRunWindowsSchema>;
347
422
  export type TaskSummary = z.output<typeof taskSummarySchema>;
348
423
  export type TaskList = z.output<typeof taskListSchema>;
@@ -14,8 +14,8 @@ export { createPersonalTokenBodySchema, createdPersonalTokenSchema, personalToke
14
14
  export type { PersonalTokenMetadata } from "./schema/personal-token";
15
15
  export { baselineSnapshotSchema, deleteWorkspaceResponseSchema, workspaceBodySchema, workspaceListSchema, workspaceParamsSchema, workspaceRepoSchema, workspaceSchema, } from "./schema/workspace";
16
16
  export type { BaselineSnapshotReport, WorkspaceReport, } from "./schema/workspace";
17
- export { eventTaskSummarySchema, scheduledTaskSummarySchema, taskExecutionListSchema, taskExecutionSchema, taskExecutionStatusDaySchema, taskExecutionStatusSchema, taskListSchema, taskParamsSchema, taskRunListSchema, taskRunSchema, taskSummarySchema, } from "./schema/task";
18
- export type { TaskExecution, TaskExecutionDay, TaskExecutionList, TaskExecutionStatusDay, TaskList, TaskRun, TaskRunList, TaskSummary, } from "./schema/task";
17
+ export { eventTaskSummarySchema, scheduledTaskSummarySchema, taskExecutionListSchema, taskExecutionSchema, taskExecutionStatusDaySchema, taskExecutionStatusSchema, taskListSchema, taskParamsSchema, taskRunListSchema, taskRunSchema, taskRunWindowsSchema, taskSummarySchema, } from "./schema/task";
18
+ export type { TaskExecution, TaskExecutionDay, TaskExecutionList, TaskExecutionStatusDay, TaskList, TaskRun, TaskRunList, TaskRunWindows, TaskSummary, } from "./schema/task";
19
19
  export { statSchema, statsReportSchema } from "./schema/stats";
20
20
  export type { StatReport, StatsReport } from "./schema/stats";
21
21
  export { healthReportSchema, pluginOperationalReportFeedSchema, pluginOperationalReportSchema, pluginPackageContentItemReportSchema, pluginPackageContentReportSchema, pluginSchema, pluginsSchema, runtimeInfoReportSchema, skillReportSchema, skillReportsSchema, } from "../reporting-schema";