@oneuptime/common 11.5.8 → 11.5.10

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 (542) hide show
  1. package/Models/AnalyticsModels/Index.ts +13 -0
  2. package/Models/AnalyticsModels/MetricItemAggMV1mByContainer.ts +178 -0
  3. package/Models/AnalyticsModels/MetricItemAggMV1mByK8sCluster.ts +179 -0
  4. package/Models/AnalyticsModels/MetricItemAggMV1mByService.ts +179 -0
  5. package/Models/AnalyticsModels/NetworkFlow.ts +397 -0
  6. package/Models/DatabaseModels/AIAgentTaskPullRequest.ts +15 -6
  7. package/Models/DatabaseModels/AIRun.ts +37 -0
  8. package/Models/DatabaseModels/AIRunEvent.ts +34 -1
  9. package/Models/DatabaseModels/EnterpriseLicenseInstance.ts +18 -0
  10. package/Models/DatabaseModels/GlobalConfig.ts +36 -0
  11. package/Models/DatabaseModels/Index.ts +2 -0
  12. package/Models/DatabaseModels/MarketingConversion.ts +198 -0
  13. package/Models/DatabaseModels/MetricSavedView.ts +34 -0
  14. package/Models/DatabaseModels/MetricType.ts +74 -0
  15. package/Models/DatabaseModels/NetworkDevice.ts +332 -0
  16. package/Models/DatabaseModels/NetworkDeviceDiscoveryScan.ts +328 -0
  17. package/Models/DatabaseModels/NetworkInterface.ts +58 -0
  18. package/Models/DatabaseModels/Project.ts +62 -0
  19. package/Models/DatabaseModels/StatusPage.ts +42 -0
  20. package/Models/DatabaseModels/User.ts +37 -0
  21. package/Server/API/AIAgentTaskAPI.ts +38 -12
  22. package/Server/API/AIAgentTaskLogAPI.ts +49 -0
  23. package/Server/API/AIChatAPI.ts +16 -0
  24. package/Server/API/AIReadinessAPI.ts +84 -0
  25. package/Server/API/BaseAnalyticsAPI.ts +23 -0
  26. package/Server/API/CodeFixRunAPI.ts +182 -0
  27. package/Server/API/EnterpriseLicenseAPI.ts +14 -0
  28. package/Server/API/TelemetryExceptionAPI.ts +6 -1
  29. package/Server/EnvironmentConfig.ts +84 -0
  30. package/Server/Infrastructure/Postgres/SchemaMigrations/1784124919694-AddAITaskNumberAndRunTranscript.ts +95 -0
  31. package/Server/Infrastructure/Postgres/SchemaMigrations/1784135099754-AllowNullAiAgentOnPullRequest.ts +52 -0
  32. package/Server/Infrastructure/Postgres/SchemaMigrations/1784137457184-AddEnableMcpServerToStatusPage.ts +30 -0
  33. package/Server/Infrastructure/Postgres/SchemaMigrations/1784191414522-AddCounterSemanticsToMetricType.ts +38 -0
  34. package/Server/Infrastructure/Postgres/SchemaMigrations/1784191414600-AddViewTypeToMetricSavedView.ts +28 -0
  35. package/Server/Infrastructure/Postgres/SchemaMigrations/1784200000000-AddSnmpV3ColumnsToNetworkDeviceDiscoveryScan.ts +49 -0
  36. package/Server/Infrastructure/Postgres/SchemaMigrations/1784211212164-AddNetworkDeviceInventoryAndDiscoverySchedule.ts +108 -0
  37. package/Server/Infrastructure/Postgres/SchemaMigrations/1784218257664-AddEnterpriseLicenseNotificationColumns.ts +31 -0
  38. package/Server/Infrastructure/Postgres/SchemaMigrations/1784293516000-AddAttributionColumnsToUserAndProject.ts +29 -0
  39. package/Server/Infrastructure/Postgres/SchemaMigrations/1784298000000-AddMarketingConversionTable.ts +35 -0
  40. package/Server/Infrastructure/Postgres/SchemaMigrations/Index.ts +20 -0
  41. package/Server/Services/AIRunEventService.ts +15 -1
  42. package/Server/Services/AIRunService.ts +38 -1
  43. package/Server/Services/AnalyticsDatabaseService.ts +70 -1
  44. package/Server/Services/IncidentService.ts +13 -0
  45. package/Server/Services/Index.ts +10 -0
  46. package/Server/Services/LlmProviderService.ts +2 -0
  47. package/Server/Services/MarketingConversionService.ts +10 -0
  48. package/Server/Services/MetricItemAggMV1mByContainerService.ts +31 -0
  49. package/Server/Services/MetricItemAggMV1mByK8sClusterService.ts +31 -0
  50. package/Server/Services/MetricItemAggMV1mByServiceService.ts +31 -0
  51. package/Server/Services/MetricService.ts +970 -122
  52. package/Server/Services/MonitorService.ts +14 -0
  53. package/Server/Services/NetworkDeviceOwnerTeamService.ts +42 -0
  54. package/Server/Services/NetworkDeviceOwnerUserService.ts +106 -0
  55. package/Server/Services/NetworkFlowService.ts +11 -0
  56. package/Server/Services/OnCallDutyPolicyService.ts +11 -1
  57. package/Server/Services/ProjectService.ts +178 -0
  58. package/Server/Services/SpanService.ts +13 -9
  59. package/Server/Services/StatusPageService.ts +97 -0
  60. package/Server/Services/TeamMemberService.ts +11 -0
  61. package/Server/Services/TelemetryExceptionService.ts +19 -90
  62. package/Server/Services/UserService.ts +59 -0
  63. package/Server/Types/AnalyticsDatabase/AggregateBy.ts +37 -7
  64. package/Server/Types/Markdown.ts +9 -9
  65. package/Server/Types/MarkdownSlugify.ts +47 -0
  66. package/Server/Utils/AI/AIRunTranscript.ts +240 -0
  67. package/Server/Utils/AI/Chat/ChatAgentRunner.ts +9 -0
  68. package/Server/Utils/AI/Chat/ObservabilityChatPrompt.ts +119 -5
  69. package/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.ts +75 -0
  70. package/Server/Utils/AI/CodeFix/CodeFixReadiness.ts +235 -0
  71. package/Server/Utils/AI/SRE/Insights/FixRouting.ts +2 -3
  72. package/Server/Utils/AI/Toolbox/CodeTools.ts +883 -0
  73. package/Server/Utils/AI/Toolbox/CodeWriteTools.ts +519 -0
  74. package/Server/Utils/AI/Toolbox/Index.ts +27 -0
  75. package/Server/Utils/AI/Toolbox/ScheduledMaintenanceTools.ts +279 -0
  76. package/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.ts +19 -1
  77. package/Server/Utils/Attribution.ts +99 -0
  78. package/Server/Utils/CodeRepository/GitHub/GitHub.ts +600 -0
  79. package/Server/Utils/CodeRepository/StackTraceRepoResolver.ts +7 -2
  80. package/Server/Utils/LLM/LLMService.ts +397 -18
  81. package/Server/Utils/Marketing/ConversionUploadProvider.ts +103 -0
  82. package/Server/Utils/Marketing/ConversionUploadProviders.ts +22 -0
  83. package/Server/Utils/Marketing/Providers/GoogleAds.ts +270 -0
  84. package/Server/Utils/Marketing/Providers/LinkedIn.ts +147 -0
  85. package/Server/Utils/Marketing/Providers/Meta.ts +148 -0
  86. package/Server/Utils/Marketing/Providers/MicrosoftAds.ts +196 -0
  87. package/Server/Utils/Marketing/Providers/Reddit.ts +178 -0
  88. package/Server/Utils/Monitor/MonitorAlert.ts +71 -7
  89. package/Server/Utils/Monitor/MonitorCriteriaEvaluator.ts +31 -19
  90. package/Server/Utils/Monitor/MonitorIncident.ts +71 -7
  91. package/Server/Utils/Monitor/MonitorMetricUtil.ts +57 -0
  92. package/Server/Utils/Monitor/MonitorTemplateUtil.ts +94 -0
  93. package/Server/Utils/Monitor/NetworkDeviceHydrationUtil.ts +19 -11
  94. package/Server/Utils/Monitor/NetworkInventoryUtil.ts +125 -14
  95. package/Server/Utils/ProductAnalytics.ts +133 -0
  96. package/Server/Utils/Telemetry/Telemetry.ts +39 -0
  97. package/Server/Utils/Telemetry/TelemetryEntity.ts +21 -0
  98. package/Tests/Models/StatusPageEnableMcpServer.test.ts +125 -0
  99. package/Tests/Server/API/BaseAnalyticsAPI.test.ts +72 -0
  100. package/Tests/Server/Infrastructure/SemaphorePermit.test.ts +9 -1
  101. package/Tests/Server/Services/AnalyticsDatabaseService.test.ts +21 -2
  102. package/Tests/Server/Services/MetricEntityMVKeyParity.test.ts +173 -0
  103. package/Tests/Server/Services/MetricServiceAggregate.test.ts +1391 -0
  104. package/Tests/Server/Services/NetworkDeviceOwnerServices.test.ts +260 -0
  105. package/Tests/Server/Services/StatusPageServiceMcp.test.ts +223 -0
  106. package/Tests/Server/Services/TelemetryExceptionAIFixReadiness.test.ts +26 -3
  107. package/Tests/Server/Services/TelemetryExceptionCodeFixRun.test.ts +12 -0
  108. package/Tests/Server/Types/Markdown.test.ts +106 -0
  109. package/Tests/Server/Utils/AI/AIRunTranscript.test.ts +182 -0
  110. package/Tests/Server/Utils/AI/CodeFixReadiness.test.ts +411 -0
  111. package/Tests/Server/Utils/AI/CodeTools.test.ts +596 -0
  112. package/Tests/Server/Utils/AI/CodeWriteTools.test.ts +475 -0
  113. package/Tests/Server/Utils/AI/LLMServiceModelCompatibility.test.ts +548 -0
  114. package/Tests/Server/Utils/AI/ObservabilityChatPrompt.test.ts +142 -0
  115. package/Tests/Server/Utils/AI/ScheduledMaintenanceTools.test.ts +176 -0
  116. package/Tests/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.test.ts +63 -0
  117. package/Tests/Server/Utils/GitHubGetFileContent.test.ts +197 -0
  118. package/Tests/Server/Utils/Monitor/MonitorTemplateUtilNetworkDevice.test.ts +389 -0
  119. package/Tests/Server/Utils/Monitor/NetworkDeviceHydrationUtil.test.ts +502 -0
  120. package/Tests/Server/Utils/Monitor/NetworkInventoryUtil.test.ts +764 -0
  121. package/Tests/Types/AI/AIAgentTaskStatus.test.ts +7 -6
  122. package/Tests/Types/AI/AIChatPageContext.test.ts +0 -0
  123. package/Tests/Types/AI/AIRunStatus.test.ts +42 -0
  124. package/Tests/Types/BaseDatabase/AggregationIntervalUtil.test.ts +111 -2
  125. package/Tests/Types/Database/EndsWith.test.ts +64 -0
  126. package/Tests/Types/Database/GreaterThan.test.ts +62 -0
  127. package/Tests/Types/Database/GreaterThanOrEqual.test.ts +65 -0
  128. package/Tests/Types/Database/GreaterThanOrNull.test.ts +63 -0
  129. package/Tests/Types/Database/Includes.test.ts +65 -0
  130. package/Tests/Types/Database/IncludesAll.test.ts +65 -0
  131. package/Tests/Types/Database/IncludesNone.test.ts +65 -0
  132. package/Tests/Types/Database/IsNull.test.ts +44 -0
  133. package/Tests/Types/Database/LessThan.test.ts +62 -0
  134. package/Tests/Types/Database/LessThanOrEqual.test.ts +62 -0
  135. package/Tests/Types/Database/LessThanOrNull.test.ts +62 -0
  136. package/Tests/Types/Database/MultiSearch.test.ts +81 -0
  137. package/Tests/Types/Database/NotContains.test.ts +64 -0
  138. package/Tests/Types/Database/NotNull.test.ts +44 -0
  139. package/Tests/Types/Database/StartsWith.test.ts +64 -0
  140. package/Tests/Types/Log/LogSeverity.test.ts +78 -0
  141. package/Tests/Types/Monitor/MonitorStepSqlMonitor.test.ts +83 -1
  142. package/Tests/Types/Monitor/SnmpV3EnumParsing.test.ts +247 -0
  143. package/Tests/Types/Monitor/SnmpVendorTemplate.test.ts +263 -0
  144. package/Tests/UI/Components/BasicFormDropdownNormalization.test.tsx +167 -0
  145. package/Tests/UI/Components/Charts/AxisTickColor.test.tsx +66 -0
  146. package/Tests/UI/Components/XAxis.test.ts +5 -3
  147. package/Tests/UI/Utils/AIChatExport/ChatWidgetData.test.ts +319 -0
  148. package/Tests/UI/Utils/AIChatExport/ChatWidgetMarkdown.test.ts +188 -0
  149. package/Tests/Utils/EnterpriseLicenseUsage.test.ts +76 -0
  150. package/Tests/Utils/Metrics/MetricExplorerUrl.test.ts +622 -0
  151. package/Tests/Utils/Metrics/MetricFormulaEvaluator.test.ts +474 -0
  152. package/Tests/Utils/Telemetry/HeartbeatAvailability.test.ts +52 -4
  153. package/Types/AI/AIAgentTaskStatus.ts +13 -0
  154. package/Types/AI/AIChatPageContext.ts +137 -0
  155. package/Types/AI/AIChatTypes.ts +44 -0
  156. package/Types/AI/AIFixReadiness.ts +46 -0
  157. package/Types/AI/AIRunStatus.ts +11 -0
  158. package/Types/AnalyticsDatabase/AnalyticsTableName.ts +11 -0
  159. package/Types/BaseDatabase/AggregateBy.ts +31 -2
  160. package/Types/BaseDatabase/AggregatedResult.ts +22 -0
  161. package/Types/BaseDatabase/AggregationInterval.ts +11 -0
  162. package/Types/BaseDatabase/AggregationIntervalUtil.ts +30 -5
  163. package/Types/Dashboard/DashboardComponents/DashboardTraceChartComponent.ts +16 -0
  164. package/Types/Email/EmailTemplateType.ts +3 -0
  165. package/Types/Log/LogSeverity.ts +61 -0
  166. package/Types/Marketing/MarketingConversion.ts +11 -0
  167. package/Types/Metrics/MetricQueryConfigData.ts +21 -0
  168. package/Types/Metrics/MetricQueryData.ts +8 -0
  169. package/Types/Metrics/MetricViewData.ts +8 -0
  170. package/Types/Monitor/MonitorMetricType.ts +8 -0
  171. package/Types/Monitor/MonitorStep.ts +9 -0
  172. package/Types/Monitor/MonitorStepSqlMonitor.ts +12 -0
  173. package/Types/Monitor/MonitorType.ts +2 -1
  174. package/Types/Monitor/SSLMonitor/SslMonitorResponse.ts +17 -12
  175. package/Types/Monitor/SnmpMonitor/CdpNeighbor.ts +13 -0
  176. package/Types/Monitor/SnmpMonitor/NetworkTopology.ts +37 -3
  177. package/Types/Monitor/SnmpMonitor/SnmpAuthProtocol.ts +46 -0
  178. package/Types/Monitor/SnmpMonitor/SnmpEntityInfo.ts +15 -0
  179. package/Types/Monitor/SnmpMonitor/SnmpInterface.ts +8 -0
  180. package/Types/Monitor/SnmpMonitor/SnmpMonitorResponse.ts +17 -8
  181. package/Types/Monitor/SnmpMonitor/SnmpPrivProtocol.ts +53 -0
  182. package/Types/Monitor/SnmpMonitor/SnmpSecurityLevel.ts +43 -0
  183. package/Types/Monitor/SnmpMonitor/SnmpSystemInfo.ts +16 -0
  184. package/Types/Monitor/SnmpMonitor/SnmpVendorTemplate.ts +119 -3
  185. package/Types/Monitor/SnmpMonitor/SnmpVersion.ts +40 -0
  186. package/Types/NetFlow/NetworkFlowRecord.ts +25 -0
  187. package/Types/Syslog/SyslogMessage.ts +18 -0
  188. package/Types/Telemetry/TelemetrySavedViewState.ts +9 -0
  189. package/Types/Telemetry/TelemetrySavedViewType.ts +12 -0
  190. package/UI/Components/Charts/Area/AreaChart.tsx +51 -0
  191. package/UI/Components/Charts/Bar/BarChart.tsx +51 -1
  192. package/UI/Components/Charts/ChartGroup/ChartGroup.tsx +97 -26
  193. package/UI/Components/Charts/ChartLibrary/AreaChart/AreaChart.tsx +336 -3
  194. package/UI/Components/Charts/ChartLibrary/BarChart/BarChart.tsx +118 -1
  195. package/UI/Components/Charts/ChartLibrary/LineChart/LineChart.tsx +336 -3
  196. package/UI/Components/Charts/ChartLibrary/Types/ChartDataPoint.ts +7 -0
  197. package/UI/Components/Charts/ChartLibrary/Types/FormattedReferenceRegion.ts +15 -0
  198. package/UI/Components/Charts/ChartLibrary/Types/FormattedTimeReferenceLine.ts +13 -0
  199. package/UI/Components/Charts/Line/LineChart.tsx +51 -0
  200. package/UI/Components/Charts/Types/ReferenceRegionProps.ts +12 -0
  201. package/UI/Components/Charts/Types/TimeReferenceLineProps.ts +12 -0
  202. package/UI/Components/Charts/Types/XAxis/XAxisPrecision.ts +1 -0
  203. package/UI/Components/Charts/Utils/DataPoint.ts +0 -0
  204. package/UI/Components/Charts/Utils/TimeAnnotation.ts +169 -0
  205. package/UI/Components/Charts/Utils/XAxis.ts +28 -4
  206. package/UI/Components/Forms/BasicForm.tsx +26 -8
  207. package/UI/Components/Icon/Icon.tsx +33 -13
  208. package/UI/Components/Markdown.tsx/MarkdownViewer.tsx +9 -0
  209. package/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.ts +67 -0
  210. package/UI/Components/Page/ModelPage.tsx +6 -1
  211. package/UI/Components/TelemetryViewer/components/SavedViewsDropdown.tsx +33 -4
  212. package/UI/Styles/Theme.css +1324 -0
  213. package/UI/Utils/AIChatExport/ChatWidgetData.ts +316 -0
  214. package/UI/Utils/AIChatExport/ChatWidgetMarkdown.ts +349 -0
  215. package/UI/Utils/AIChatExport/ConversationMarkdown.ts +177 -0
  216. package/UI/Utils/AIChatExport/MarkdownBlocks.ts +327 -0
  217. package/UI/Utils/AIChatExport/MarkdownSafety.ts +215 -0
  218. package/UI/Utils/DownloadFile.ts +54 -0
  219. package/UI/Utils/User.ts +41 -2
  220. package/Utils/Analytics.ts +8 -6
  221. package/Utils/EnterpriseLicense/EnterpriseLicenseUsage.ts +74 -0
  222. package/Utils/Metrics/MetricExplorerUrl.ts +771 -0
  223. package/Utils/Metrics/MetricFormulaEvaluator.ts +410 -46
  224. package/Utils/Monitor/NetworkTopologyUtil.ts +261 -49
  225. package/Utils/ValueFormatter.ts +22 -1
  226. package/build/dist/Models/AnalyticsModels/Index.js +13 -0
  227. package/build/dist/Models/AnalyticsModels/Index.js.map +1 -1
  228. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByContainer.js +159 -0
  229. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByContainer.js.map +1 -0
  230. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByK8sCluster.js +158 -0
  231. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByK8sCluster.js.map +1 -0
  232. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByService.js +160 -0
  233. package/build/dist/Models/AnalyticsModels/MetricItemAggMV1mByService.js.map +1 -0
  234. package/build/dist/Models/AnalyticsModels/NetworkFlow.js +351 -0
  235. package/build/dist/Models/AnalyticsModels/NetworkFlow.js.map +1 -0
  236. package/build/dist/Models/DatabaseModels/AIAgentTaskPullRequest.js +15 -7
  237. package/build/dist/Models/DatabaseModels/AIAgentTaskPullRequest.js.map +1 -1
  238. package/build/dist/Models/DatabaseModels/AIRun.js +38 -0
  239. package/build/dist/Models/DatabaseModels/AIRun.js.map +1 -1
  240. package/build/dist/Models/DatabaseModels/AIRunEvent.js +31 -0
  241. package/build/dist/Models/DatabaseModels/AIRunEvent.js.map +1 -1
  242. package/build/dist/Models/DatabaseModels/EnterpriseLicenseInstance.js +19 -0
  243. package/build/dist/Models/DatabaseModels/EnterpriseLicenseInstance.js.map +1 -1
  244. package/build/dist/Models/DatabaseModels/GlobalConfig.js +38 -0
  245. package/build/dist/Models/DatabaseModels/GlobalConfig.js.map +1 -1
  246. package/build/dist/Models/DatabaseModels/Index.js +2 -0
  247. package/build/dist/Models/DatabaseModels/Index.js.map +1 -1
  248. package/build/dist/Models/DatabaseModels/MarketingConversion.js +219 -0
  249. package/build/dist/Models/DatabaseModels/MarketingConversion.js.map +1 -0
  250. package/build/dist/Models/DatabaseModels/MetricSavedView.js +35 -0
  251. package/build/dist/Models/DatabaseModels/MetricSavedView.js.map +1 -1
  252. package/build/dist/Models/DatabaseModels/MetricType.js +76 -0
  253. package/build/dist/Models/DatabaseModels/MetricType.js.map +1 -1
  254. package/build/dist/Models/DatabaseModels/NetworkDevice.js +341 -0
  255. package/build/dist/Models/DatabaseModels/NetworkDevice.js.map +1 -1
  256. package/build/dist/Models/DatabaseModels/NetworkDeviceDiscoveryScan.js +341 -0
  257. package/build/dist/Models/DatabaseModels/NetworkDeviceDiscoveryScan.js.map +1 -1
  258. package/build/dist/Models/DatabaseModels/NetworkInterface.js +60 -0
  259. package/build/dist/Models/DatabaseModels/NetworkInterface.js.map +1 -1
  260. package/build/dist/Models/DatabaseModels/Project.js +65 -0
  261. package/build/dist/Models/DatabaseModels/Project.js.map +1 -1
  262. package/build/dist/Models/DatabaseModels/StatusPage.js +43 -0
  263. package/build/dist/Models/DatabaseModels/StatusPage.js.map +1 -1
  264. package/build/dist/Models/DatabaseModels/User.js +38 -0
  265. package/build/dist/Models/DatabaseModels/User.js.map +1 -1
  266. package/build/dist/Server/API/AIAgentTaskAPI.js +37 -11
  267. package/build/dist/Server/API/AIAgentTaskAPI.js.map +1 -1
  268. package/build/dist/Server/API/AIAgentTaskLogAPI.js +32 -7
  269. package/build/dist/Server/API/AIAgentTaskLogAPI.js.map +1 -1
  270. package/build/dist/Server/API/AIChatAPI.js +9 -0
  271. package/build/dist/Server/API/AIChatAPI.js.map +1 -1
  272. package/build/dist/Server/API/AIReadinessAPI.js +57 -0
  273. package/build/dist/Server/API/AIReadinessAPI.js.map +1 -0
  274. package/build/dist/Server/API/BaseAnalyticsAPI.js +19 -0
  275. package/build/dist/Server/API/BaseAnalyticsAPI.js.map +1 -1
  276. package/build/dist/Server/API/CodeFixRunAPI.js +142 -0
  277. package/build/dist/Server/API/CodeFixRunAPI.js.map +1 -1
  278. package/build/dist/Server/API/EnterpriseLicenseAPI.js +8 -0
  279. package/build/dist/Server/API/EnterpriseLicenseAPI.js.map +1 -1
  280. package/build/dist/Server/API/TelemetryExceptionAPI.js +4 -0
  281. package/build/dist/Server/API/TelemetryExceptionAPI.js.map +1 -1
  282. package/build/dist/Server/EnvironmentConfig.js +51 -0
  283. package/build/dist/Server/EnvironmentConfig.js.map +1 -1
  284. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784124919694-AddAITaskNumberAndRunTranscript.js +80 -0
  285. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784124919694-AddAITaskNumberAndRunTranscript.js.map +1 -0
  286. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784135099754-AllowNullAiAgentOnPullRequest.js +37 -0
  287. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784135099754-AllowNullAiAgentOnPullRequest.js.map +1 -0
  288. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784137457184-AddEnableMcpServerToStatusPage.js +23 -0
  289. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784137457184-AddEnableMcpServerToStatusPage.js.map +1 -0
  290. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784191414522-AddCounterSemanticsToMetricType.js +27 -0
  291. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784191414522-AddCounterSemanticsToMetricType.js.map +1 -0
  292. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784191414600-AddViewTypeToMetricSavedView.js +21 -0
  293. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784191414600-AddViewTypeToMetricSavedView.js.map +1 -0
  294. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784200000000-AddSnmpV3ColumnsToNetworkDeviceDiscoveryScan.js +22 -0
  295. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784200000000-AddSnmpV3ColumnsToNetworkDeviceDiscoveryScan.js.map +1 -0
  296. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784211212164-AddNetworkDeviceInventoryAndDiscoverySchedule.js +47 -0
  297. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784211212164-AddNetworkDeviceInventoryAndDiscoverySchedule.js.map +1 -0
  298. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784218257664-AddEnterpriseLicenseNotificationColumns.js +16 -0
  299. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784218257664-AddEnterpriseLicenseNotificationColumns.js.map +1 -0
  300. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784293516000-AddAttributionColumnsToUserAndProject.js +18 -0
  301. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784293516000-AddAttributionColumnsToUserAndProject.js.map +1 -0
  302. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784298000000-AddMarketingConversionTable.js +20 -0
  303. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784298000000-AddMarketingConversionTable.js.map +1 -0
  304. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js +20 -0
  305. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js.map +1 -1
  306. package/build/dist/Server/Services/AIRunEventService.js +8 -0
  307. package/build/dist/Server/Services/AIRunEventService.js.map +1 -1
  308. package/build/dist/Server/Services/AIRunService.js +29 -0
  309. package/build/dist/Server/Services/AIRunService.js.map +1 -1
  310. package/build/dist/Server/Services/AnalyticsDatabaseService.js +58 -4
  311. package/build/dist/Server/Services/AnalyticsDatabaseService.js.map +1 -1
  312. package/build/dist/Server/Services/IncidentService.js +12 -0
  313. package/build/dist/Server/Services/IncidentService.js.map +1 -1
  314. package/build/dist/Server/Services/Index.js +10 -0
  315. package/build/dist/Server/Services/Index.js.map +1 -1
  316. package/build/dist/Server/Services/LlmProviderService.js +2 -0
  317. package/build/dist/Server/Services/LlmProviderService.js.map +1 -1
  318. package/build/dist/Server/Services/MarketingConversionService.js +9 -0
  319. package/build/dist/Server/Services/MarketingConversionService.js.map +1 -0
  320. package/build/dist/Server/Services/MetricItemAggMV1mByContainerService.js +29 -0
  321. package/build/dist/Server/Services/MetricItemAggMV1mByContainerService.js.map +1 -0
  322. package/build/dist/Server/Services/MetricItemAggMV1mByK8sClusterService.js +29 -0
  323. package/build/dist/Server/Services/MetricItemAggMV1mByK8sClusterService.js.map +1 -0
  324. package/build/dist/Server/Services/MetricItemAggMV1mByServiceService.js +29 -0
  325. package/build/dist/Server/Services/MetricItemAggMV1mByServiceService.js.map +1 -0
  326. package/build/dist/Server/Services/MetricService.js +761 -125
  327. package/build/dist/Server/Services/MetricService.js.map +1 -1
  328. package/build/dist/Server/Services/MonitorService.js +18 -5
  329. package/build/dist/Server/Services/MonitorService.js.map +1 -1
  330. package/build/dist/Server/Services/NetworkDeviceOwnerTeamService.js +44 -0
  331. package/build/dist/Server/Services/NetworkDeviceOwnerTeamService.js.map +1 -1
  332. package/build/dist/Server/Services/NetworkDeviceOwnerUserService.js +88 -0
  333. package/build/dist/Server/Services/NetworkDeviceOwnerUserService.js.map +1 -1
  334. package/build/dist/Server/Services/NetworkFlowService.js +9 -0
  335. package/build/dist/Server/Services/NetworkFlowService.js.map +1 -0
  336. package/build/dist/Server/Services/OnCallDutyPolicyService.js +15 -6
  337. package/build/dist/Server/Services/OnCallDutyPolicyService.js.map +1 -1
  338. package/build/dist/Server/Services/ProjectService.js +146 -6
  339. package/build/dist/Server/Services/ProjectService.js.map +1 -1
  340. package/build/dist/Server/Services/SpanService.js +8 -6
  341. package/build/dist/Server/Services/SpanService.js.map +1 -1
  342. package/build/dist/Server/Services/StatusPageService.js +91 -0
  343. package/build/dist/Server/Services/StatusPageService.js.map +1 -1
  344. package/build/dist/Server/Services/TeamMemberService.js +11 -0
  345. package/build/dist/Server/Services/TeamMemberService.js.map +1 -1
  346. package/build/dist/Server/Services/TelemetryExceptionService.js +14 -61
  347. package/build/dist/Server/Services/TelemetryExceptionService.js.map +1 -1
  348. package/build/dist/Server/Services/UserService.js +52 -0
  349. package/build/dist/Server/Services/UserService.js.map +1 -1
  350. package/build/dist/Server/Types/AnalyticsDatabase/AggregateBy.js +33 -7
  351. package/build/dist/Server/Types/AnalyticsDatabase/AggregateBy.js.map +1 -1
  352. package/build/dist/Server/Types/Markdown.js +8 -8
  353. package/build/dist/Server/Types/Markdown.js.map +1 -1
  354. package/build/dist/Server/Types/MarkdownSlugify.js +47 -0
  355. package/build/dist/Server/Types/MarkdownSlugify.js.map +1 -0
  356. package/build/dist/Server/Utils/AI/AIRunTranscript.js +180 -0
  357. package/build/dist/Server/Utils/AI/AIRunTranscript.js.map +1 -0
  358. package/build/dist/Server/Utils/AI/Chat/ChatAgentRunner.js +1 -0
  359. package/build/dist/Server/Utils/AI/Chat/ChatAgentRunner.js.map +1 -1
  360. package/build/dist/Server/Utils/AI/Chat/ObservabilityChatPrompt.js +103 -5
  361. package/build/dist/Server/Utils/AI/Chat/ObservabilityChatPrompt.js.map +1 -1
  362. package/build/dist/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.js +55 -0
  363. package/build/dist/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.js.map +1 -1
  364. package/build/dist/Server/Utils/AI/CodeFix/CodeFixReadiness.js +211 -0
  365. package/build/dist/Server/Utils/AI/CodeFix/CodeFixReadiness.js.map +1 -0
  366. package/build/dist/Server/Utils/AI/SRE/Insights/FixRouting.js.map +1 -1
  367. package/build/dist/Server/Utils/AI/Toolbox/CodeTools.js +654 -0
  368. package/build/dist/Server/Utils/AI/Toolbox/CodeTools.js.map +1 -0
  369. package/build/dist/Server/Utils/AI/Toolbox/CodeWriteTools.js +389 -0
  370. package/build/dist/Server/Utils/AI/Toolbox/CodeWriteTools.js.map +1 -0
  371. package/build/dist/Server/Utils/AI/Toolbox/Index.js +19 -0
  372. package/build/dist/Server/Utils/AI/Toolbox/Index.js.map +1 -1
  373. package/build/dist/Server/Utils/AI/Toolbox/ScheduledMaintenanceTools.js +239 -0
  374. package/build/dist/Server/Utils/AI/Toolbox/ScheduledMaintenanceTools.js.map +1 -0
  375. package/build/dist/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.js +19 -1
  376. package/build/dist/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.js.map +1 -1
  377. package/build/dist/Server/Utils/Attribution.js +74 -0
  378. package/build/dist/Server/Utils/Attribution.js.map +1 -0
  379. package/build/dist/Server/Utils/CodeRepository/GitHub/GitHub.js +439 -0
  380. package/build/dist/Server/Utils/CodeRepository/GitHub/GitHub.js.map +1 -1
  381. package/build/dist/Server/Utils/CodeRepository/StackTraceRepoResolver.js +1 -1
  382. package/build/dist/Server/Utils/CodeRepository/StackTraceRepoResolver.js.map +1 -1
  383. package/build/dist/Server/Utils/LLM/LLMService.js +275 -19
  384. package/build/dist/Server/Utils/LLM/LLMService.js.map +1 -1
  385. package/build/dist/Server/Utils/Marketing/ConversionUploadProvider.js +40 -0
  386. package/build/dist/Server/Utils/Marketing/ConversionUploadProvider.js.map +1 -0
  387. package/build/dist/Server/Utils/Marketing/ConversionUploadProviders.js +20 -0
  388. package/build/dist/Server/Utils/Marketing/ConversionUploadProviders.js.map +1 -0
  389. package/build/dist/Server/Utils/Marketing/Providers/GoogleAds.js +177 -0
  390. package/build/dist/Server/Utils/Marketing/Providers/GoogleAds.js.map +1 -0
  391. package/build/dist/Server/Utils/Marketing/Providers/LinkedIn.js +113 -0
  392. package/build/dist/Server/Utils/Marketing/Providers/LinkedIn.js.map +1 -0
  393. package/build/dist/Server/Utils/Marketing/Providers/Meta.js +109 -0
  394. package/build/dist/Server/Utils/Marketing/Providers/Meta.js.map +1 -0
  395. package/build/dist/Server/Utils/Marketing/Providers/MicrosoftAds.js +130 -0
  396. package/build/dist/Server/Utils/Marketing/Providers/MicrosoftAds.js.map +1 -0
  397. package/build/dist/Server/Utils/Marketing/Providers/Reddit.js +126 -0
  398. package/build/dist/Server/Utils/Marketing/Providers/Reddit.js.map +1 -0
  399. package/build/dist/Server/Utils/Monitor/MonitorAlert.js +53 -9
  400. package/build/dist/Server/Utils/Monitor/MonitorAlert.js.map +1 -1
  401. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js +21 -10
  402. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js.map +1 -1
  403. package/build/dist/Server/Utils/Monitor/MonitorIncident.js +54 -11
  404. package/build/dist/Server/Utils/Monitor/MonitorIncident.js.map +1 -1
  405. package/build/dist/Server/Utils/Monitor/MonitorMetricUtil.js +43 -3
  406. package/build/dist/Server/Utils/Monitor/MonitorMetricUtil.js.map +1 -1
  407. package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js +68 -0
  408. package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js.map +1 -1
  409. package/build/dist/Server/Utils/Monitor/NetworkDeviceHydrationUtil.js +17 -11
  410. package/build/dist/Server/Utils/Monitor/NetworkDeviceHydrationUtil.js.map +1 -1
  411. package/build/dist/Server/Utils/Monitor/NetworkInventoryUtil.js +100 -15
  412. package/build/dist/Server/Utils/Monitor/NetworkInventoryUtil.js.map +1 -1
  413. package/build/dist/Server/Utils/ProductAnalytics.js +111 -0
  414. package/build/dist/Server/Utils/ProductAnalytics.js.map +1 -0
  415. package/build/dist/Server/Utils/Telemetry/Telemetry.js +32 -5
  416. package/build/dist/Server/Utils/Telemetry/Telemetry.js.map +1 -1
  417. package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js +17 -0
  418. package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js.map +1 -1
  419. package/build/dist/Types/AI/AIAgentTaskStatus.js +12 -0
  420. package/build/dist/Types/AI/AIAgentTaskStatus.js.map +1 -1
  421. package/build/dist/Types/AI/AIChatPageContext.js +101 -0
  422. package/build/dist/Types/AI/AIChatPageContext.js.map +1 -0
  423. package/build/dist/Types/AI/AIChatTypes.js +2 -0
  424. package/build/dist/Types/AI/AIChatTypes.js.map +1 -1
  425. package/build/dist/Types/AI/AIFixReadiness.js +9 -0
  426. package/build/dist/Types/AI/AIFixReadiness.js.map +1 -0
  427. package/build/dist/Types/AI/AIRunStatus.js +11 -0
  428. package/build/dist/Types/AI/AIRunStatus.js.map +1 -1
  429. package/build/dist/Types/AnalyticsDatabase/AnalyticsTableName.js +11 -0
  430. package/build/dist/Types/AnalyticsDatabase/AnalyticsTableName.js.map +1 -1
  431. package/build/dist/Types/BaseDatabase/AggregationInterval.js +11 -0
  432. package/build/dist/Types/BaseDatabase/AggregationInterval.js.map +1 -1
  433. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js +33 -5
  434. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js.map +1 -1
  435. package/build/dist/Types/Email/EmailTemplateType.js +2 -0
  436. package/build/dist/Types/Email/EmailTemplateType.js.map +1 -1
  437. package/build/dist/Types/Log/LogSeverity.js +56 -0
  438. package/build/dist/Types/Log/LogSeverity.js.map +1 -1
  439. package/build/dist/Types/Marketing/MarketingConversion.js +13 -0
  440. package/build/dist/Types/Marketing/MarketingConversion.js.map +1 -0
  441. package/build/dist/Types/Monitor/MonitorMetricType.js +7 -0
  442. package/build/dist/Types/Monitor/MonitorMetricType.js.map +1 -1
  443. package/build/dist/Types/Monitor/MonitorStep.js +6 -0
  444. package/build/dist/Types/Monitor/MonitorStep.js.map +1 -1
  445. package/build/dist/Types/Monitor/MonitorStepSqlMonitor.js +3 -0
  446. package/build/dist/Types/Monitor/MonitorStepSqlMonitor.js.map +1 -1
  447. package/build/dist/Types/Monitor/MonitorType.js +2 -1
  448. package/build/dist/Types/Monitor/MonitorType.js.map +1 -1
  449. package/build/dist/Types/Monitor/SnmpMonitor/CdpNeighbor.js +2 -0
  450. package/build/dist/Types/Monitor/SnmpMonitor/CdpNeighbor.js.map +1 -0
  451. package/build/dist/Types/Monitor/SnmpMonitor/SnmpAuthProtocol.js +41 -0
  452. package/build/dist/Types/Monitor/SnmpMonitor/SnmpAuthProtocol.js.map +1 -1
  453. package/build/dist/Types/Monitor/SnmpMonitor/SnmpEntityInfo.js +2 -0
  454. package/build/dist/Types/Monitor/SnmpMonitor/SnmpEntityInfo.js.map +1 -0
  455. package/build/dist/Types/Monitor/SnmpMonitor/SnmpPrivProtocol.js +48 -0
  456. package/build/dist/Types/Monitor/SnmpMonitor/SnmpPrivProtocol.js.map +1 -1
  457. package/build/dist/Types/Monitor/SnmpMonitor/SnmpSecurityLevel.js +38 -0
  458. package/build/dist/Types/Monitor/SnmpMonitor/SnmpSecurityLevel.js.map +1 -1
  459. package/build/dist/Types/Monitor/SnmpMonitor/SnmpSystemInfo.js +2 -0
  460. package/build/dist/Types/Monitor/SnmpMonitor/SnmpSystemInfo.js.map +1 -0
  461. package/build/dist/Types/Monitor/SnmpMonitor/SnmpVendorTemplate.js +96 -3
  462. package/build/dist/Types/Monitor/SnmpMonitor/SnmpVendorTemplate.js.map +1 -1
  463. package/build/dist/Types/Monitor/SnmpMonitor/SnmpVersion.js +38 -0
  464. package/build/dist/Types/Monitor/SnmpMonitor/SnmpVersion.js.map +1 -1
  465. package/build/dist/Types/NetFlow/NetworkFlowRecord.js +2 -0
  466. package/build/dist/Types/NetFlow/NetworkFlowRecord.js.map +1 -0
  467. package/build/dist/Types/Syslog/SyslogMessage.js +2 -0
  468. package/build/dist/Types/Syslog/SyslogMessage.js.map +1 -0
  469. package/build/dist/Types/Telemetry/TelemetrySavedViewState.js +0 -7
  470. package/build/dist/Types/Telemetry/TelemetrySavedViewState.js.map +1 -1
  471. package/build/dist/Types/Telemetry/TelemetrySavedViewType.js +13 -0
  472. package/build/dist/Types/Telemetry/TelemetrySavedViewType.js.map +1 -0
  473. package/build/dist/UI/Components/Charts/Area/AreaChart.js +25 -1
  474. package/build/dist/UI/Components/Charts/Area/AreaChart.js.map +1 -1
  475. package/build/dist/UI/Components/Charts/Bar/BarChart.js +26 -2
  476. package/build/dist/UI/Components/Charts/Bar/BarChart.js.map +1 -1
  477. package/build/dist/UI/Components/Charts/ChartGroup/ChartGroup.js +36 -12
  478. package/build/dist/UI/Components/Charts/ChartGroup/ChartGroup.js.map +1 -1
  479. package/build/dist/UI/Components/Charts/ChartLibrary/AreaChart/AreaChart.js +217 -8
  480. package/build/dist/UI/Components/Charts/ChartLibrary/AreaChart/AreaChart.js.map +1 -1
  481. package/build/dist/UI/Components/Charts/ChartLibrary/BarChart/BarChart.js +55 -4
  482. package/build/dist/UI/Components/Charts/ChartLibrary/BarChart/BarChart.js.map +1 -1
  483. package/build/dist/UI/Components/Charts/ChartLibrary/LineChart/LineChart.js +217 -8
  484. package/build/dist/UI/Components/Charts/ChartLibrary/LineChart/LineChart.js.map +1 -1
  485. package/build/dist/UI/Components/Charts/ChartLibrary/Types/ChartDataPoint.js +6 -1
  486. package/build/dist/UI/Components/Charts/ChartLibrary/Types/ChartDataPoint.js.map +1 -1
  487. package/build/dist/UI/Components/Charts/ChartLibrary/Types/FormattedReferenceRegion.js +2 -0
  488. package/build/dist/UI/Components/Charts/ChartLibrary/Types/FormattedReferenceRegion.js.map +1 -0
  489. package/build/dist/UI/Components/Charts/ChartLibrary/Types/FormattedTimeReferenceLine.js +2 -0
  490. package/build/dist/UI/Components/Charts/ChartLibrary/Types/FormattedTimeReferenceLine.js.map +1 -0
  491. package/build/dist/UI/Components/Charts/Line/LineChart.js +25 -1
  492. package/build/dist/UI/Components/Charts/Line/LineChart.js.map +1 -1
  493. package/build/dist/UI/Components/Charts/Types/ReferenceRegionProps.js +2 -0
  494. package/build/dist/UI/Components/Charts/Types/ReferenceRegionProps.js.map +1 -0
  495. package/build/dist/UI/Components/Charts/Types/TimeReferenceLineProps.js +2 -0
  496. package/build/dist/UI/Components/Charts/Types/TimeReferenceLineProps.js.map +1 -0
  497. package/build/dist/UI/Components/Charts/Types/XAxis/XAxisPrecision.js +1 -0
  498. package/build/dist/UI/Components/Charts/Types/XAxis/XAxisPrecision.js.map +1 -1
  499. package/build/dist/UI/Components/Charts/Utils/DataPoint.js +0 -0
  500. package/build/dist/UI/Components/Charts/Utils/DataPoint.js.map +1 -1
  501. package/build/dist/UI/Components/Charts/Utils/TimeAnnotation.js +121 -0
  502. package/build/dist/UI/Components/Charts/Utils/TimeAnnotation.js.map +1 -0
  503. package/build/dist/UI/Components/Charts/Utils/XAxis.js +27 -4
  504. package/build/dist/UI/Components/Charts/Utils/XAxis.js.map +1 -1
  505. package/build/dist/UI/Components/Forms/BasicForm.js +24 -6
  506. package/build/dist/UI/Components/Forms/BasicForm.js.map +1 -1
  507. package/build/dist/UI/Components/Icon/Icon.js +15 -8
  508. package/build/dist/UI/Components/Icon/Icon.js.map +1 -1
  509. package/build/dist/UI/Components/Markdown.tsx/MarkdownViewer.js.map +1 -1
  510. package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js +58 -0
  511. package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js.map +1 -1
  512. package/build/dist/UI/Components/Page/ModelPage.js +7 -1
  513. package/build/dist/UI/Components/Page/ModelPage.js.map +1 -1
  514. package/build/dist/UI/Components/TelemetryViewer/components/SavedViewsDropdown.js +10 -4
  515. package/build/dist/UI/Components/TelemetryViewer/components/SavedViewsDropdown.js.map +1 -1
  516. package/build/dist/UI/Utils/AIChatExport/ChatWidgetData.js +217 -0
  517. package/build/dist/UI/Utils/AIChatExport/ChatWidgetData.js.map +1 -0
  518. package/build/dist/UI/Utils/AIChatExport/ChatWidgetMarkdown.js +234 -0
  519. package/build/dist/UI/Utils/AIChatExport/ChatWidgetMarkdown.js.map +1 -0
  520. package/build/dist/UI/Utils/AIChatExport/ConversationMarkdown.js +111 -0
  521. package/build/dist/UI/Utils/AIChatExport/ConversationMarkdown.js.map +1 -0
  522. package/build/dist/UI/Utils/AIChatExport/MarkdownBlocks.js +233 -0
  523. package/build/dist/UI/Utils/AIChatExport/MarkdownBlocks.js.map +1 -0
  524. package/build/dist/UI/Utils/AIChatExport/MarkdownSafety.js +134 -0
  525. package/build/dist/UI/Utils/AIChatExport/MarkdownSafety.js.map +1 -0
  526. package/build/dist/UI/Utils/DownloadFile.js +41 -0
  527. package/build/dist/UI/Utils/DownloadFile.js.map +1 -0
  528. package/build/dist/UI/Utils/User.js +35 -2
  529. package/build/dist/UI/Utils/User.js.map +1 -1
  530. package/build/dist/Utils/Analytics.js +8 -5
  531. package/build/dist/Utils/Analytics.js.map +1 -1
  532. package/build/dist/Utils/EnterpriseLicense/EnterpriseLicenseUsage.js +57 -0
  533. package/build/dist/Utils/EnterpriseLicense/EnterpriseLicenseUsage.js.map +1 -1
  534. package/build/dist/Utils/Metrics/MetricExplorerUrl.js +418 -0
  535. package/build/dist/Utils/Metrics/MetricExplorerUrl.js.map +1 -0
  536. package/build/dist/Utils/Metrics/MetricFormulaEvaluator.js +296 -37
  537. package/build/dist/Utils/Metrics/MetricFormulaEvaluator.js.map +1 -1
  538. package/build/dist/Utils/Monitor/NetworkTopologyUtil.js +176 -40
  539. package/build/dist/Utils/Monitor/NetworkTopologyUtil.js.map +1 -1
  540. package/build/dist/Utils/ValueFormatter.js +20 -1
  541. package/build/dist/Utils/ValueFormatter.js.map +1 -1
  542. package/package.json +6 -2
@@ -0,0 +1,137 @@
1
+ import { JSONObject } from "../JSON";
2
+
3
+ /*
4
+ * "Page context" makes Ask AI aware of what the user is looking at in the
5
+ * dashboard. The client detects the current page (an incident, a monitor, a
6
+ * trace waterfall, the logs explorer, …) and attaches this small descriptor to
7
+ * each message it sends; the server folds it into the system prompt so "this
8
+ * incident" resolves to the entity on screen. It is a per-turn hint, never
9
+ * persisted — the user can detach it in the composer at any time.
10
+ */
11
+ enum AIChatPageContextType {
12
+ // Entity pages — carry the entity's id (and usually a display title).
13
+ Incident = "Incident",
14
+ Alert = "Alert",
15
+ Monitor = "Monitor",
16
+ ScheduledMaintenanceEvent = "ScheduledMaintenanceEvent",
17
+ TelemetryService = "TelemetryService",
18
+ Trace = "Trace",
19
+ Exception = "Exception",
20
+
21
+ // Area pages — no id; the user is browsing a list or an explorer.
22
+ IncidentsList = "IncidentsList",
23
+ AlertsList = "AlertsList",
24
+ MonitorsList = "MonitorsList",
25
+ ScheduledMaintenanceList = "ScheduledMaintenanceList",
26
+ LogsExplorer = "LogsExplorer",
27
+ TracesExplorer = "TracesExplorer",
28
+ MetricsExplorer = "MetricsExplorer",
29
+ ExceptionsList = "ExceptionsList",
30
+ }
31
+
32
+ export default AIChatPageContextType;
33
+
34
+ export interface AIChatPageContext {
35
+ type: AIChatPageContextType;
36
+ // The entity on screen (UUID, or a hex trace id). Only set for entity types.
37
+ entityId?: string | undefined;
38
+ // Display title of the entity (incident title, monitor name, …). Optional.
39
+ entityTitle?: string | undefined;
40
+ }
41
+
42
+ /*
43
+ * Ids are OneUptime ObjectIDs (UUIDs) — except traces, whose ids are
44
+ * OpenTelemetry hex strings. Anything else is rejected: the id is echoed into
45
+ * the LLM prompt and into tool suggestions, so it must never carry free-form
46
+ * text (e.g. a static route segment like "overview" that a :id URL wildcard
47
+ * can capture).
48
+ */
49
+ const UUID_REGEX: RegExp =
50
+ /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
51
+ const TRACE_ID_REGEX: RegExp = /^[0-9a-fA-F]{8,64}$/;
52
+
53
+ const MAX_ENTITY_TITLE_LENGTH: number = 200;
54
+
55
+ const ENTITY_TYPES: Array<AIChatPageContextType> = [
56
+ AIChatPageContextType.Incident,
57
+ AIChatPageContextType.Alert,
58
+ AIChatPageContextType.Monitor,
59
+ AIChatPageContextType.ScheduledMaintenanceEvent,
60
+ AIChatPageContextType.TelemetryService,
61
+ AIChatPageContextType.Trace,
62
+ AIChatPageContextType.Exception,
63
+ ];
64
+
65
+ export class AIChatPageContextHelper {
66
+ public static isValidType(
67
+ value: string | undefined,
68
+ ): value is AIChatPageContextType {
69
+ return Object.values(AIChatPageContextType).includes(
70
+ value as AIChatPageContextType,
71
+ );
72
+ }
73
+
74
+ // Entity types point at one specific record and require an entityId.
75
+ public static isEntityType(type: AIChatPageContextType): boolean {
76
+ return ENTITY_TYPES.includes(type);
77
+ }
78
+
79
+ /*
80
+ * Validate and sanitize an untrusted client-supplied page context. Returns
81
+ * undefined when the payload is missing or invalid — page context is a hint,
82
+ * so a bad one is dropped rather than failing the message.
83
+ */
84
+ public static sanitize(
85
+ json: JSONObject | undefined | null,
86
+ ): AIChatPageContext | undefined {
87
+ if (!json || typeof json !== "object" || Array.isArray(json)) {
88
+ return undefined;
89
+ }
90
+
91
+ const type: string | undefined =
92
+ typeof json["type"] === "string" ? (json["type"] as string) : undefined;
93
+
94
+ if (!this.isValidType(type)) {
95
+ return undefined;
96
+ }
97
+
98
+ const context: AIChatPageContext = { type: type };
99
+
100
+ if (this.isEntityType(type)) {
101
+ const entityId: string =
102
+ typeof json["entityId"] === "string"
103
+ ? (json["entityId"] as string).trim()
104
+ : "";
105
+
106
+ const idRegex: RegExp =
107
+ type === AIChatPageContextType.Trace ? TRACE_ID_REGEX : UUID_REGEX;
108
+
109
+ // An entity context without a usable id is meaningless — drop it whole.
110
+ if (!idRegex.test(entityId)) {
111
+ return undefined;
112
+ }
113
+
114
+ context.entityId = entityId;
115
+
116
+ if (typeof json["entityTitle"] === "string") {
117
+ /*
118
+ * The title is echoed into the system prompt: collapse whitespace and
119
+ * control characters so it cannot introduce new lines or fake
120
+ * prompt structure, and cap the length.
121
+ */
122
+ const entityTitle: string = (json["entityTitle"] as string)
123
+ // eslint-disable-next-line no-control-regex
124
+ .replace(/[\u0000-\u001F\u007F]+/g, " ")
125
+ .replace(/\s+/g, " ")
126
+ .trim()
127
+ .substring(0, MAX_ENTITY_TITLE_LENGTH);
128
+
129
+ if (entityTitle) {
130
+ context.entityTitle = entityTitle;
131
+ }
132
+ }
133
+ }
134
+
135
+ return context;
136
+ }
137
+ }
@@ -22,6 +22,8 @@ export enum AIChatCitationTargetType {
22
22
  AlertView = "AlertView",
23
23
  Monitors = "Monitors",
24
24
  MonitorView = "MonitorView",
25
+ ScheduledMaintenanceEvents = "ScheduledMaintenanceEvents",
26
+ ScheduledMaintenanceView = "ScheduledMaintenanceView",
25
27
  }
26
28
 
27
29
  export interface AIChatCitationTarget {
@@ -197,6 +199,48 @@ export interface AIRunEventResultSummary {
197
199
  severity?: string | undefined;
198
200
  }
199
201
 
202
+ /*
203
+ * The verbatim content behind one run event — the raw material for debugging
204
+ * a bad run: exactly what was sent to the model, exactly what it said back,
205
+ * and exactly what a tool returned.
206
+ *
207
+ * This is the ONLY place a code-fix run's LLM content is persisted. It lives
208
+ * on AIRunEvent.contentPayload, whose read ACL is empty precisely because
209
+ * this content embeds customer source code: LlmLog deliberately redacts the
210
+ * same content (CodeFixAgentCompletion passes storeContentPreviews: false)
211
+ * because LlmLog is readable project-wide, and that redaction stays. Reach it
212
+ * only through GET /code-fix-run/logs, which gates on ProjectOwner or
213
+ * ProjectAdmin — the same "sensitive content behind a narrow endpoint" shape
214
+ * AIRun.pausedState and AIRun.taskContext already use.
215
+ *
216
+ * Every field is capped at write time (see AIRunTranscript.ts) so one run can
217
+ * never write an unbounded row.
218
+ */
219
+ export interface AIRunEventContentPayload {
220
+ // Messages newly sent to the model on this call — not the whole history.
221
+ requestMessages?: Array<{
222
+ role: string;
223
+ content: string;
224
+ }>;
225
+ // The model's verbatim reply.
226
+ responseContent?: string | undefined;
227
+ // Tool calls the model asked for, with their full arguments.
228
+ responseToolCalls?: Array<{
229
+ id?: string | undefined;
230
+ name: string;
231
+ arguments?: JSONObject | undefined;
232
+ }>;
233
+ // A tool's verbatim return value (for tool events).
234
+ toolResult?: string | undefined;
235
+ modelName?: string | undefined;
236
+ stopReason?: string | undefined;
237
+ promptTokens?: number | undefined;
238
+ completionTokens?: number | undefined;
239
+ totalTokens?: number | undefined;
240
+ // Set when any field above was clipped to its cap.
241
+ isTruncated?: boolean | undefined;
242
+ }
243
+
200
244
  // What was sent to which LLM during a run — the per-run egress manifest.
201
245
  export interface AIRunEgressManifestToolEntry {
202
246
  toolName: string;
@@ -0,0 +1,46 @@
1
+ /*
2
+ * What a CodeFix run needs before it can complete, as a wire contract shared
3
+ * by the server checks and every UI that renders them. Two surfaces consume
4
+ * this today: the per-exception "Fix with AI Agent" panel
5
+ * (GET /telemetry-exception/ai-fix-readiness/:id) and the project-wide AI
6
+ * Tasks page (POST /ai-readiness/code-fix).
7
+ */
8
+
9
+ /*
10
+ * The repository gate comes in two strengths, and they are deliberately
11
+ * distinct ids — a UI that conflates them would promise more than the check
12
+ * verified:
13
+ *
14
+ * - repositoryResolved: a repository matches THIS exception's stack trace.
15
+ * Per-exception, and the stronger claim.
16
+ * - repositoryConnected: the project has at least one GitHub-App-connected
17
+ * repository. Project-wide, and all a page-level check can honestly assert
18
+ * — it says nothing about whether any given exception will resolve.
19
+ */
20
+ export type AIFixReadinessCheckId =
21
+ | "llmProvider"
22
+ | "repositoryResolved"
23
+ | "repositoryConnected"
24
+ | "agentAvailable";
25
+
26
+ export interface AIFixReadinessCheck {
27
+ id: AIFixReadinessCheckId;
28
+ ok: boolean;
29
+ /*
30
+ * The gate's headline. Checks fill in what they actually found where that
31
+ * is useful ("Repository resolved: acme/api"), so this is not a fixed
32
+ * label per id.
33
+ */
34
+ title: string;
35
+ /*
36
+ * When ok is false: exactly what to do next. When ok is true: what is
37
+ * configured, so the user can tell a project-owned provider from the
38
+ * shared one without leaving the page. May be empty.
39
+ */
40
+ detail: string;
41
+ }
42
+
43
+ export interface AIFixReadiness {
44
+ ready: boolean;
45
+ checks: Array<AIFixReadinessCheck>;
46
+ }
@@ -18,6 +18,16 @@ enum AIRunStatus {
18
18
  */
19
19
  WaitingForApproval = "WaitingForApproval",
20
20
  Completed = "Completed",
21
+ /*
22
+ * The run did its job and concluded there was nothing to change — the agent
23
+ * read the code and found no fix worth proposing, so it opened no pull
24
+ * request. A negative result, NOT a failure: nothing broke, and retrying the
25
+ * same run unchanged would likely reach the same conclusion. Kept distinct
26
+ * from Error so a quiet "no fix" never lands in an error rate, an alert, or
27
+ * a red pill. Contrast with Error, which means the run could not finish
28
+ * (clone failed, LLM errored, no repository resolved).
29
+ */
30
+ NoFixFound = "NoFixFound",
21
31
  Error = "Error",
22
32
  Cancelled = "Cancelled",
23
33
  Stale = "Stale",
@@ -29,6 +39,7 @@ export class AIRunStatusHelper {
29
39
  public static isTerminalStatus(status: AIRunStatus): boolean {
30
40
  return (
31
41
  status === AIRunStatus.Completed ||
42
+ status === AIRunStatus.NoFixFound ||
32
43
  status === AIRunStatus.Error ||
33
44
  status === AIRunStatus.Cancelled ||
34
45
  status === AIRunStatus.Stale
@@ -4,6 +4,7 @@ enum AnalyticsTableName {
4
4
  ExceptionInstance = "ExceptionItemV3",
5
5
  Span = "SpanItemV3",
6
6
  MonitorLog = "MonitorLogV3",
7
+ NetworkFlow = "NetworkFlowV1",
7
8
  Profile = "ProfileItemV3",
8
9
  ProfileSample = "ProfileSampleItemV3",
9
10
  AuditLog = "AuditLogV2",
@@ -20,6 +21,16 @@ enum AnalyticsTableName {
20
21
  * hostEntityKey instead of the raw host.name spelling.
21
22
  */
22
23
  MetricItemAggMV1mByHostV2 = "MetricItemAggMV1mByHostV2",
24
+ /*
25
+ * Entity-keyed siblings of MetricItemAggMV1mByHostV2 — same layout,
26
+ * keyed by the other ingest-stamped scalar entity-key columns
27
+ * (serviceEntityKey / k8sClusterEntityKey / containerEntityKey) so
28
+ * entity-scoped chart queries can be served from a pre-aggregated
29
+ * rollup instead of scanning MetricItemV3.
30
+ */
31
+ MetricItemAggMV1mByService = "MetricItemAggMV1mByService",
32
+ MetricItemAggMV1mByK8sCluster = "MetricItemAggMV1mByK8sCluster",
33
+ MetricItemAggMV1mByContainer = "MetricItemAggMV1mByContainer",
23
34
  MetricBaselineHourly = "MetricBaselineHourly",
24
35
  MutableMetric = "MutableMetricItem",
25
36
  }
@@ -10,8 +10,9 @@ export default interface AggregateBy<TBaseModel extends GenericObject> {
10
10
  aggregationType: AggregationType;
11
11
  /**
12
12
  * Optional explicit time-bucket size. When omitted (the default), the
13
- * bucket size is derived from the query window (≤3h → minute, ≤7d
14
- * hour, ≤6wday, …) see AggregationIntervalUtil. Set this to pin a
13
+ * bucket size is derived from the query window (≤3h → minute, ≤12h
14
+ * 5 minutes, ≤24h15 minutes, ≤3d 30 minutes, ≤7d hour, ≤6w
15
+ * day, …) — see AggregationIntervalUtil. Set this to pin a
15
16
  * granularity independent of the window (e.g. `Day` buckets over a
16
17
  * one-week window), or to `Total` to aggregate the whole window into a
17
18
  * single value per group (no time bucketing). Invalid values are
@@ -38,4 +39,32 @@ export default interface AggregateBy<TBaseModel extends GenericObject> {
38
39
  * `attributes` object containing exactly these keys.
39
40
  */
40
41
  groupByAttributeKeys?: Array<string> | undefined;
42
+ /**
43
+ * Server-side Top-K group selection for grouped aggregations. When
44
+ * set (and the aggregation is grouped via `groupBy` /
45
+ * `groupByAttributeKeys`), the server ranks groups by `rankBy`
46
+ * (max or avg of the aggregated column) over the WHOLE query window,
47
+ * keeps only the top `count` groups, and reports the total number of
48
+ * matching groups via `AggregatedResult.totalGroups` — so a chart can
49
+ * plot the top 10 series without fetching every bucket of every
50
+ * group. Ignored for ungrouped aggregations. Plain JSON so it
51
+ * round-trips the API's serialize/deserialize unchanged.
52
+ */
53
+ topK?:
54
+ | {
55
+ count: number;
56
+ rankBy: "max" | "avg";
57
+ }
58
+ | undefined;
59
+ /**
60
+ * What ClickHouse does when the aggregate's execution-time cap fires.
61
+ * 'break' (the default when omitted) returns the partial buckets
62
+ * computed so far — acceptable for chart rendering. Callers that
63
+ * ALERT on the result (the metric-monitor worker) must pass 'throw'
64
+ * so a timed-out evaluation fails loudly instead of silently scoring
65
+ * partial data as if it were complete. The server allow-lists the
66
+ * value before it reaches SQL: anything other than the exact string
67
+ * "throw" is treated as 'break'.
68
+ */
69
+ timeoutOverflowMode?: "break" | "throw" | undefined;
41
70
  }
@@ -2,4 +2,26 @@ import AggregatedModel from "./AggregatedModel";
2
2
 
3
3
  export default interface AggregatedResult {
4
4
  data: Array<AggregatedModel>;
5
+ /**
6
+ * Total number of distinct groups matching the query window, counted
7
+ * in the Top-K ranking phase. Only present for grouped aggregations
8
+ * executed with `AggregateBy.topK`; compare against `topK.count` to
9
+ * know how many series were left out.
10
+ */
11
+ totalGroups?: number | undefined;
12
+ /**
13
+ * True when the result is known (or heuristically likely) to be
14
+ * incomplete: the row count hit the applied LIMIT, or Top-K dropped
15
+ * groups (`totalGroups > topK.count`). Additive — absent/false means
16
+ * the window was fully served.
17
+ */
18
+ truncated?: boolean | undefined;
19
+ /**
20
+ * Human-readable reason this result carries no data — e.g. a metric
21
+ * formula that failed structural validation (bad syntax, unknown
22
+ * variable, disjoint groups). Only set by client-side evaluation
23
+ * layers; never returned by the server. Chart layers should render it
24
+ * in place of the empty chart instead of showing a silent "no data".
25
+ */
26
+ errorMessage?: string | undefined;
5
27
  }
@@ -1,5 +1,16 @@
1
1
  export enum AggregationInterval {
2
2
  Minute = "Minute",
3
+ /*
4
+ * The sub-hour tiers are served from the same 1-minute rollup as
5
+ * `Minute` (any bucket that is a whole multiple of a minute is >= the
6
+ * MV's resolution). Unlike the calendar units they are NOT valid
7
+ * ClickHouse `date_trunc`/INTERVAL-1 units, so SQL builders must go
8
+ * through AggregateUtil.buildBucketTimestampExpression instead of
9
+ * lowercasing the enum value into the statement.
10
+ */
11
+ FiveMinutes = "FiveMinutes",
12
+ FifteenMinutes = "FifteenMinutes",
13
+ ThirtyMinutes = "ThirtyMinutes",
3
14
  Hour = "Hour",
4
15
  Day = "Day",
5
16
  Week = "Week",
@@ -36,9 +36,23 @@ export class AggregationIntervalUtil {
36
36
 
37
37
  const diff: number = endDate.getTime() - startDate.getTime();
38
38
 
39
+ /*
40
+ * ~180-point budget per chart: each tier keeps the rendered point
41
+ * count in the tens-to-hundreds instead of collapsing a 4h window
42
+ * to ~4 hourly points or exploding a 12h window into 720 minutes.
43
+ */
39
44
  if (diff <= 1000 * 60 * 60 * 3) {
40
45
  // if less than 3 hours, then get minute precision
41
46
  return AggregationInterval.Minute;
47
+ } else if (diff <= 1000 * 60 * 60 * 12) {
48
+ // 12 hours
49
+ return AggregationInterval.FiveMinutes;
50
+ } else if (diff <= 1000 * 60 * 60 * 24) {
51
+ // 24 hours
52
+ return AggregationInterval.FifteenMinutes;
53
+ } else if (diff <= 1000 * 60 * 60 * 24 * 3) {
54
+ // 3 days
55
+ return AggregationInterval.ThirtyMinutes;
42
56
  } else if (diff <= 1000 * 60 * 60 * 24 * 7) {
43
57
  // 7 days
44
58
  return AggregationInterval.Hour;
@@ -69,6 +83,12 @@ export class AggregationIntervalUtil {
69
83
  switch (interval) {
70
84
  case AggregationInterval.Minute:
71
85
  return 1000 * 60;
86
+ case AggregationInterval.FiveMinutes:
87
+ return 1000 * 60 * 5;
88
+ case AggregationInterval.FifteenMinutes:
89
+ return 1000 * 60 * 15;
90
+ case AggregationInterval.ThirtyMinutes:
91
+ return 1000 * 60 * 30;
72
92
  case AggregationInterval.Hour:
73
93
  return 1000 * 60 * 60;
74
94
  case AggregationInterval.Day:
@@ -102,11 +122,13 @@ export class AggregationIntervalUtil {
102
122
  * (the first bucket is partial and its timestamp falls before the axis
103
123
  * origin).
104
124
  *
105
- * Only Minute/Hour/Day are aligned: for those the fixed-ms epoch grid is
106
- * an EXACT match for ClickHouse's UTC bucketing (epoch-day == UTC
107
- * midnight), and these are the windows where the leading gap is actually
108
- * visible. Week/Month/Year snap to calendar boundaries (Monday / 1st /
109
- * Jan-1) server-side, which a fixed-ms grid can't reproduce, so those (and
125
+ * Only the sub-day intervals (Minute through Hour, plus Day) are aligned:
126
+ * for those the fixed-ms epoch grid is an EXACT match for ClickHouse's
127
+ * UTC bucketing (5/15/30-minute `toStartOfInterval` grids are counted in
128
+ * whole intervals since the epoch, and epoch-day == UTC midnight), and
129
+ * these are the windows where the leading gap is actually visible.
130
+ * Week/Month/Year snap to calendar boundaries (Monday / 1st / Jan-1)
131
+ * server-side, which a fixed-ms grid can't reproduce, so those (and
110
132
  * `Total`) are returned UNCHANGED rather than risk shifting the gap for
111
133
  * long windows — their pre-existing behavior is preserved.
112
134
  */
@@ -117,6 +139,9 @@ export class AggregationIntervalUtil {
117
139
  const ms: number = OneUptimeDate.fromString(date).getTime();
118
140
  const alignableIntervals: Array<AggregationInterval> = [
119
141
  AggregationInterval.Minute,
142
+ AggregationInterval.FiveMinutes,
143
+ AggregationInterval.FifteenMinutes,
144
+ AggregationInterval.ThirtyMinutes,
120
145
  AggregationInterval.Hour,
121
146
  AggregationInterval.Day,
122
147
  ];
@@ -33,6 +33,22 @@ export default interface DashboardTraceChartComponent extends BaseComponent {
33
33
  groupByAttribute?: string | undefined;
34
34
  // Cap on the number of series when split (default 10).
35
35
  topLimit?: number | undefined;
36
+ /*
37
+ * Optional user-chosen lead color for the chart, stored as a hex string
38
+ * (e.g. "#6366f1"). Single-series → the series color; split charts → the
39
+ * first unpinned series, with the rest following the default palette.
40
+ * Same semantics as MetricQueryConfigData.color on the metric Chart
41
+ * widget. Unset = Auto (default palette).
42
+ */
43
+ color?: string | undefined;
44
+ /*
45
+ * Per-series color pins for split charts, keyed by "key=value" segment
46
+ * (e.g. { "url.host=api.example.com": "#10b981" }) — the same storage
47
+ * shape as MetricQueryConfigData.colorsByGroup, so the shared
48
+ * SeriesGroupColorSelector editor works unchanged. Unpinned series fall
49
+ * back to `color` (lead) then the default palette.
50
+ */
51
+ colorsByGroup?: Record<string, string> | undefined;
36
52
  /*
37
53
  * Include non-root spans. Off by default so "Request Count" matches the
38
54
  * traces explorer, which is root-spans-only.
@@ -86,6 +86,9 @@ enum EmailTemplateType {
86
86
  Invoice = "Invoice.hbs",
87
87
 
88
88
  ClickhouseCapacityWarning = "ClickhouseCapacityWarning.hbs",
89
+
90
+ EnterpriseLicenseUserLimitBreach = "EnterpriseLicenseUserLimitBreach.hbs",
91
+ EnterpriseLicenseExpiryReminder = "EnterpriseLicenseExpiryReminder.hbs",
89
92
  }
90
93
 
91
94
  export default EmailTemplateType;
@@ -8,4 +8,65 @@ enum LogSeverity {
8
8
  Fatal = "Fatal",
9
9
  }
10
10
 
11
+ /*
12
+ * The OTLP severity number stored alongside each level.
13
+ *
14
+ * These are the low end of each OTLP range (Trace 1-4, Debug 5-8, Info 9-12,
15
+ * Warn 13-16, Error 17-20, Fatal 21-24), so they are the inverse of the
16
+ * bucketing OtelLogsIngestService.getSeverityText applies on ingest. Anything
17
+ * that writes severityText must take the number from here too, or the row says
18
+ * one thing in its text and another in its number.
19
+ *
20
+ * https://opentelemetry.io/docs/specs/otel/logs/data-model/#field-severitynumber
21
+ */
22
+ export const LogSeverityNumber: Record<LogSeverity, number> = {
23
+ [LogSeverity.Unspecified]: 0,
24
+ [LogSeverity.Trace]: 1,
25
+ [LogSeverity.Debug]: 5,
26
+ [LogSeverity.Information]: 9,
27
+ [LogSeverity.Warning]: 13,
28
+ [LogSeverity.Error]: 17,
29
+ [LogSeverity.Fatal]: 21,
30
+ };
31
+
32
+ /*
33
+ * Loose severity text -> the enum member actually stored on a log row.
34
+ *
35
+ * Only these seven strings ever reach the database: ingest discards whatever
36
+ * severityText a client sent and re-derives it from severityNumber. So a value
37
+ * that is merely severity-shaped ("INFO", "warn") matches nothing — and since
38
+ * `=` and `IN` are case-sensitive, it fails silently rather than erroring.
39
+ *
40
+ * This exists because the filter and severity-remapper dropdowns spent a long
41
+ * time emitting TRACE/DEBUG/INFO/WARNING/ERROR/FATAL. Those values are still
42
+ * sitting in saved pipeline configs, so the remapper normalises through here on
43
+ * the way in rather than trusting what was stored.
44
+ *
45
+ * Returns null for anything unrecognised. Callers decide what to do about it —
46
+ * guessing a severity is worse than admitting we cannot tell.
47
+ */
48
+ export function normalizeLogSeverity(text: string): LogSeverity | null {
49
+ const normalized: string = (text || "").trim().toUpperCase();
50
+
51
+ if (!normalized) {
52
+ return null;
53
+ }
54
+
55
+ const aliases: Record<string, LogSeverity> = {
56
+ UNSPECIFIED: LogSeverity.Unspecified,
57
+ TRACE: LogSeverity.Trace,
58
+ DEBUG: LogSeverity.Debug,
59
+ // INFO and WARN are the two the old dropdowns got wrong by more than case.
60
+ INFO: LogSeverity.Information,
61
+ INFORMATION: LogSeverity.Information,
62
+ WARN: LogSeverity.Warning,
63
+ WARNING: LogSeverity.Warning,
64
+ ERR: LogSeverity.Error,
65
+ ERROR: LogSeverity.Error,
66
+ FATAL: LogSeverity.Fatal,
67
+ };
68
+
69
+ return aliases[normalized] || null;
70
+ }
71
+
11
72
  export default LogSeverity;
@@ -0,0 +1,11 @@
1
+ export enum MarketingConversionType {
2
+ SignUp = "SignUp",
3
+ PaidSubscription = "PaidSubscription",
4
+ }
5
+
6
+ export enum MarketingConversionUploadStatus {
7
+ Uploaded = "Uploaded",
8
+ Failed = "Failed",
9
+ // No click id relevant to this ad platform — nothing to upload.
10
+ Skipped = "Skipped",
11
+ }
@@ -13,6 +13,16 @@ export interface ChartSeries {
13
13
  }
14
14
 
15
15
  export default interface MetricQueryConfigData {
16
+ /*
17
+ * Stable identity for this query, independent of its position in the
18
+ * queryConfigs array. Chart layers key per-chart UI state (hidden
19
+ * series, search, Top-N, sort) on this id so removing/reordering
20
+ * queries doesn't transfer one chart's state to another. Assigned at
21
+ * query-creation sites (ObjectID-based); older persisted configs won't
22
+ * have it, so consumers must tolerate its absence. Intentionally NOT
23
+ * part of the explorer URL serialization.
24
+ */
25
+ id?: string | undefined;
16
26
  metricAliasData?: MetricAliasData | undefined;
17
27
  metricQueryData: MetricQueryData;
18
28
  getSeries?: ((data: AggregatedModel) => ChartSeries) | undefined;
@@ -59,4 +69,15 @@ export default interface MetricQueryConfigData {
59
69
  * on agent restart) are clamped to 0.
60
70
  */
61
71
  transformAsRate?: boolean | undefined;
72
+ /*
73
+ * When true, this query is drawn on the PREVIOUS query's chart panel,
74
+ * sharing its axes, instead of getting a panel of its own. Consecutive
75
+ * flagged queries chain onto the same panel. Has no effect on the
76
+ * first query, or when the previous query produced no result (the
77
+ * query then falls back to its own panel). Both queries are evaluated
78
+ * over the SAME time window — this is a same-window visual overlay,
79
+ * not a period-over-period time shift. Plain persisted data like the
80
+ * fields above (dashboards, saved views, explorer URLs).
81
+ */
82
+ overlayWithPreviousQuery?: boolean | undefined;
62
83
  }
@@ -17,4 +17,12 @@ export default interface MetricQueryData {
17
17
  * whatever) incident creation from a single metric monitor.
18
18
  */
19
19
  groupByAttributeKeys?: Array<string> | undefined;
20
+ /**
21
+ * How many series (groups) to plot for a grouped query. Passed to the
22
+ * server as `AggregateBy.topK.count` so only the top-N groups (ranked
23
+ * by max over the window) are fetched, and used as the client-side
24
+ * display cap. Unset = the default cap (10). Plain persisted data —
25
+ * saved views and dashboards carry it like any other query field.
26
+ */
27
+ topN?: number | undefined;
20
28
  }
@@ -3,4 +3,12 @@ import MetricsViewConfig from "./MetricsViewConfig";
3
3
 
4
4
  export default interface MetricViewData extends MetricsViewConfig {
5
5
  startAndEndDate: InBetween<Date> | null;
6
+ /*
7
+ * Optional relative-time token (a Range enum value from
8
+ * Common/Types/Time/TimeRange, e.g. "Past 1 Hour"). When set, the
9
+ * resolved startAndEndDate re-anchors to "now" on fetch/refresh instead
10
+ * of staying pinned to the instant it was first resolved. Custom /
11
+ * pinned absolute windows carry no token.
12
+ */
13
+ rangeToken?: string | undefined;
6
14
  }
@@ -34,6 +34,14 @@ enum MonitorMetricType {
34
34
  SnmpInterfaceUtilizationPercent = "oneuptime.monitor.snmp.interface.utilization.percent",
35
35
  SnmpInterfaceErrorsPerSecond = "oneuptime.monitor.snmp.interface.errors.per.second",
36
36
 
37
+ /*
38
+ * One series per polled OID that returned a numeric value (oid / oidName
39
+ * attributes) — CPU, memory, temperature from vendor templates and any
40
+ * custom OID a user adds. This is what makes polled OIDs chartable and
41
+ * evaluable over time.
42
+ */
43
+ SnmpOidValue = "oneuptime.monitor.snmp.oid.value",
44
+
37
45
  /*
38
46
  * Extended server/VM metrics. Emitted when the agent payload contains them;
39
47
  * absent for older agents, which keeps the pipeline backwards-compatible.
@@ -47,6 +47,7 @@ import MonitorStepDnssecMonitor, {
47
47
  import MonitorStepSqlMonitor, {
48
48
  MonitorStepSqlMonitorUtil,
49
49
  } from "./MonitorStepSqlMonitor";
50
+ import SqlDatabaseType from "./SqlDatabaseType";
50
51
  import MonitorStepExternalStatusPageMonitor, {
51
52
  MonitorStepExternalStatusPageMonitorUtil,
52
53
  } from "./MonitorStepExternalStatusPageMonitor";
@@ -780,6 +781,14 @@ export default class MonitorStep extends DatabaseProperty {
780
781
  if (!value.data.sqlMonitor.query || !value.data.sqlMonitor.query.trim()) {
781
782
  return "SQL query is required";
782
783
  }
784
+
785
+ if (
786
+ value.data.sqlMonitor.useWindowsIntegratedAuthentication &&
787
+ value.data.sqlMonitor.databaseType !==
788
+ SqlDatabaseType.MicrosoftSqlServer
789
+ ) {
790
+ return "Windows Integrated Authentication is only supported for Microsoft SQL Server";
791
+ }
783
792
  }
784
793
 
785
794
  if (monitorType === MonitorType.ExternalStatusPage) {