@oneuptime/common 14.0.104 → 14.0.106
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Models/AnalyticsModels/CloudCost.d.mts +2 -0
- package/Models/AnalyticsModels/CloudCost.d.ts +2 -0
- package/Models/AnalyticsModels/CloudCost.js +27 -0
- package/Models/AnalyticsModels/Index.js +8 -0
- package/Models/AnalyticsModels/RumProductAnalyticsSession.d.mts +14 -0
- package/Models/AnalyticsModels/RumProductAnalyticsSession.d.ts +14 -0
- package/Models/AnalyticsModels/RumProductAnalyticsSession.js +410 -0
- package/Models/AnalyticsModels/RumProductAnalyticsSession.mjs +11 -0
- package/Models/AnalyticsModels/RumProductAnalyticsUser.d.mts +4 -0
- package/Models/AnalyticsModels/RumProductAnalyticsUser.d.ts +4 -0
- package/Models/AnalyticsModels/RumProductAnalyticsUser.js +210 -0
- package/Models/AnalyticsModels/RumProductAnalyticsUser.mjs +2 -0
- package/Models/AnalyticsModels/RumSession.js +66 -12
- package/Models/AnalyticsModels/RumSessionChunk.js +30 -2
- package/Models/DatabaseModels/AIAgentTaskPullRequest.js +24 -9
- package/Models/DatabaseModels/AIRun.d.mts +4 -0
- package/Models/DatabaseModels/AIRun.d.ts +4 -0
- package/Models/DatabaseModels/AIRun.js +107 -0
- package/Models/DatabaseModels/Alert.d.mts +2 -0
- package/Models/DatabaseModels/Alert.d.ts +2 -0
- package/Models/DatabaseModels/Alert.js +70 -0
- package/Models/DatabaseModels/AlertEpisodeOnCallRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/AlertEpisodeOnCallRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/AlertEpisodeOnCallRuleOwningTeam.js +456 -0
- package/Models/DatabaseModels/AlertEpisodeOnCallRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/AlertGroupingRule.d.mts +2 -0
- package/Models/DatabaseModels/AlertGroupingRule.d.ts +2 -0
- package/Models/DatabaseModels/AlertGroupingRule.js +85 -0
- package/Models/DatabaseModels/AlertOnCallRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/AlertOnCallRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/AlertOnCallRuleOwningTeam.js +456 -0
- package/Models/DatabaseModels/AlertOnCallRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/AuditLogExport.d.mts +1 -0
- package/Models/DatabaseModels/AuditLogExport.d.ts +1 -0
- package/Models/DatabaseModels/AuditLogExport.js +32 -0
- package/Models/DatabaseModels/AutoRemediationSuggestion.d.mts +4 -0
- package/Models/DatabaseModels/AutoRemediationSuggestion.d.ts +4 -0
- package/Models/DatabaseModels/AutoRemediationSuggestion.js +109 -0
- package/Models/DatabaseModels/CephCluster.d.mts +1 -0
- package/Models/DatabaseModels/CephCluster.d.ts +1 -0
- package/Models/DatabaseModels/CephCluster.js +36 -0
- package/Models/DatabaseModels/CloudAccount.d.mts +2 -0
- package/Models/DatabaseModels/CloudAccount.d.ts +2 -0
- package/Models/DatabaseModels/CloudAccount.js +48 -0
- package/Models/DatabaseModels/CloudBudget.d.mts +1 -0
- package/Models/DatabaseModels/CloudBudget.d.ts +1 -0
- package/Models/DatabaseModels/CloudBudget.js +38 -3
- package/Models/DatabaseModels/CloudConnection.d.mts +1 -0
- package/Models/DatabaseModels/CloudConnection.d.ts +1 -0
- package/Models/DatabaseModels/CloudConnection.js +27 -6
- package/Models/DatabaseModels/CloudCostRecommendation.d.mts +2 -0
- package/Models/DatabaseModels/CloudCostRecommendation.d.ts +2 -0
- package/Models/DatabaseModels/CloudCostRecommendation.js +30 -2
- package/Models/DatabaseModels/CodeRepository.js +23 -6
- package/Models/DatabaseModels/DataStoreFinding.js +8 -2
- package/Models/DatabaseModels/DatabaseBaseModel/DatabaseBaseModel.d.mts +2 -1
- package/Models/DatabaseModels/DatabaseBaseModel/DatabaseBaseModel.d.ts +2 -1
- package/Models/DatabaseModels/DatabaseBaseModel/DatabaseBaseModel.js +21 -0
- package/Models/DatabaseModels/DatabaseBaseModel/OnCallRuleBaseModel.d.mts +2 -0
- package/Models/DatabaseModels/DatabaseBaseModel/OnCallRuleBaseModel.d.ts +2 -0
- package/Models/DatabaseModels/DatabaseBaseModel/OnCallRuleBaseModel.js +35 -1
- package/Models/DatabaseModels/DatabaseServer.d.mts +1 -0
- package/Models/DatabaseModels/DatabaseServer.d.ts +1 -0
- package/Models/DatabaseModels/DatabaseServer.js +36 -0
- package/Models/DatabaseModels/DetectionRule.js +8 -7
- package/Models/DatabaseModels/DockerHost.d.mts +1 -0
- package/Models/DatabaseModels/DockerHost.d.ts +1 -0
- package/Models/DatabaseModels/DockerHost.js +36 -0
- package/Models/DatabaseModels/DockerSwarmCluster.d.mts +1 -0
- package/Models/DatabaseModels/DockerSwarmCluster.d.ts +1 -0
- package/Models/DatabaseModels/DockerSwarmCluster.js +36 -0
- package/Models/DatabaseModels/GlobalConfig.d.mts +36 -1
- package/Models/DatabaseModels/GlobalConfig.d.ts +36 -1
- package/Models/DatabaseModels/GlobalConfig.js +635 -2
- package/Models/DatabaseModels/Host.d.mts +1 -0
- package/Models/DatabaseModels/Host.d.ts +1 -0
- package/Models/DatabaseModels/Host.js +36 -0
- package/Models/DatabaseModels/Incident.d.mts +2 -0
- package/Models/DatabaseModels/Incident.d.ts +2 -0
- package/Models/DatabaseModels/Incident.js +70 -0
- package/Models/DatabaseModels/IncidentEpisodeFeed.d.mts +2 -1
- package/Models/DatabaseModels/IncidentEpisodeFeed.d.ts +2 -1
- package/Models/DatabaseModels/IncidentEpisodeFeed.js +7 -0
- package/Models/DatabaseModels/IncidentEpisodeOnCallRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/IncidentEpisodeOnCallRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/IncidentEpisodeOnCallRuleOwningTeam.js +456 -0
- package/Models/DatabaseModels/IncidentEpisodeOnCallRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/IncidentEpisodePublicNote.d.mts +5 -0
- package/Models/DatabaseModels/IncidentEpisodePublicNote.d.ts +5 -0
- package/Models/DatabaseModels/IncidentEpisodePublicNote.js +185 -0
- package/Models/DatabaseModels/IncidentFeed.d.mts +2 -1
- package/Models/DatabaseModels/IncidentFeed.d.ts +2 -1
- package/Models/DatabaseModels/IncidentFeed.js +7 -0
- package/Models/DatabaseModels/IncidentGroupingRule.d.mts +2 -0
- package/Models/DatabaseModels/IncidentGroupingRule.d.ts +2 -0
- package/Models/DatabaseModels/IncidentGroupingRule.js +85 -0
- package/Models/DatabaseModels/IncidentOnCallRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/IncidentOnCallRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/IncidentOnCallRuleOwningTeam.js +456 -0
- package/Models/DatabaseModels/IncidentOnCallRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/IncidentOwnerRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/IncidentOwnerRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/IncidentOwnerRuleOwningTeam.js +456 -0
- package/Models/DatabaseModels/IncidentOwnerRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/IncidentPublicNote.d.mts +5 -0
- package/Models/DatabaseModels/IncidentPublicNote.d.ts +5 -0
- package/Models/DatabaseModels/IncidentPublicNote.js +185 -0
- package/Models/DatabaseModels/Index.js +24 -0
- package/Models/DatabaseModels/KubernetesCluster.d.mts +1 -0
- package/Models/DatabaseModels/KubernetesCluster.d.ts +1 -0
- package/Models/DatabaseModels/KubernetesCluster.js +36 -0
- package/Models/DatabaseModels/LlmProvider.d.mts +1 -0
- package/Models/DatabaseModels/LlmProvider.d.ts +1 -0
- package/Models/DatabaseModels/LlmProvider.js +39 -0
- package/Models/DatabaseModels/Monitor.d.mts +2 -0
- package/Models/DatabaseModels/Monitor.d.ts +2 -0
- package/Models/DatabaseModels/Monitor.js +98 -2
- package/Models/DatabaseModels/NetworkDeviceDiscoveryImport.js +11 -6
- package/Models/DatabaseModels/NetworkEndpoint.d.mts +1 -0
- package/Models/DatabaseModels/NetworkEndpoint.d.ts +1 -0
- package/Models/DatabaseModels/NetworkEndpoint.js +48 -0
- package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.d.mts +1 -0
- package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.d.ts +1 -0
- package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.js +54 -0
- package/Models/DatabaseModels/OpenStackCloud.d.mts +1 -0
- package/Models/DatabaseModels/OpenStackCloud.d.ts +1 -0
- package/Models/DatabaseModels/OpenStackCloud.js +27 -0
- package/Models/DatabaseModels/PacketCapture.js +3 -1
- package/Models/DatabaseModels/PodmanHost.d.mts +1 -0
- package/Models/DatabaseModels/PodmanHost.d.ts +1 -0
- package/Models/DatabaseModels/PodmanHost.js +36 -0
- package/Models/DatabaseModels/Project.d.mts +19 -0
- package/Models/DatabaseModels/Project.d.ts +19 -0
- package/Models/DatabaseModels/Project.js +541 -0
- package/Models/DatabaseModels/ProjectSmtpConfig.d.mts +10 -0
- package/Models/DatabaseModels/ProjectSmtpConfig.d.ts +10 -0
- package/Models/DatabaseModels/ProjectSmtpConfig.js +335 -1
- package/Models/DatabaseModels/ProxmoxCluster.d.mts +1 -0
- package/Models/DatabaseModels/ProxmoxCluster.d.ts +1 -0
- package/Models/DatabaseModels/ProxmoxCluster.js +36 -0
- package/Models/DatabaseModels/PublicNoteApprovalRequest.d.mts +29 -0
- package/Models/DatabaseModels/PublicNoteApprovalRequest.d.ts +29 -0
- package/Models/DatabaseModels/PublicNoteApprovalRequest.js +460 -0
- package/Models/DatabaseModels/PublicNoteApprovalRequest.mjs +3 -0
- package/Models/DatabaseModels/PublicNoteApprovalStep.d.mts +19 -0
- package/Models/DatabaseModels/PublicNoteApprovalStep.d.ts +19 -0
- package/Models/DatabaseModels/PublicNoteApprovalStep.js +363 -0
- package/Models/DatabaseModels/PublicNoteApprovalStep.mjs +2 -0
- package/Models/DatabaseModels/RumApplication.d.mts +6 -0
- package/Models/DatabaseModels/RumApplication.d.ts +6 -0
- package/Models/DatabaseModels/RumApplication.js +202 -2
- package/Models/DatabaseModels/ScheduledMaintenance.d.mts +2 -0
- package/Models/DatabaseModels/ScheduledMaintenance.d.ts +2 -0
- package/Models/DatabaseModels/ScheduledMaintenance.js +63 -0
- package/Models/DatabaseModels/ScheduledMaintenanceFeed.d.mts +2 -1
- package/Models/DatabaseModels/ScheduledMaintenanceFeed.d.ts +2 -1
- package/Models/DatabaseModels/ScheduledMaintenanceFeed.js +7 -0
- package/Models/DatabaseModels/ScheduledMaintenancePublicNote.d.mts +5 -0
- package/Models/DatabaseModels/ScheduledMaintenancePublicNote.d.ts +5 -0
- package/Models/DatabaseModels/ScheduledMaintenancePublicNote.js +185 -0
- package/Models/DatabaseModels/ServerlessFunction.js +10 -2
- package/Models/DatabaseModels/ServiceLevelObjective.d.mts +5 -0
- package/Models/DatabaseModels/ServiceLevelObjective.d.ts +5 -0
- package/Models/DatabaseModels/ServiceLevelObjective.js +174 -3
- package/Models/DatabaseModels/ServiceLevelObjectiveBurnRateRule.js +1 -1
- package/Models/DatabaseModels/ServiceLevelObjectiveErrorBudgetPolicyTier.d.mts +54 -0
- package/Models/DatabaseModels/ServiceLevelObjectiveErrorBudgetPolicyTier.d.ts +54 -0
- package/Models/DatabaseModels/ServiceLevelObjectiveErrorBudgetPolicyTier.js +1674 -0
- package/Models/DatabaseModels/ServiceLevelObjectiveErrorBudgetPolicyTier.mjs +2 -0
- package/Models/DatabaseModels/ServiceLevelObjectiveFeed.d.mts +8 -1
- package/Models/DatabaseModels/ServiceLevelObjectiveFeed.d.ts +8 -1
- package/Models/DatabaseModels/ServiceLevelObjectiveFeed.js +14 -0
- package/Models/DatabaseModels/TelemetryIngestionKey.d.mts +10 -0
- package/Models/DatabaseModels/TelemetryIngestionKey.d.ts +10 -0
- package/Models/DatabaseModels/TelemetryIngestionKey.js +199 -0
- package/Models/DatabaseModels/TelemetryIngestionKeyRefusal.d.mts +19 -0
- package/Models/DatabaseModels/TelemetryIngestionKeyRefusal.d.ts +19 -0
- package/Models/DatabaseModels/TelemetryIngestionKeyRefusal.js +297 -0
- package/Models/DatabaseModels/TelemetryIngestionKeyRefusal.mjs +2 -0
- package/Models/DatabaseModels/TelemetryUsageBilling.js +35 -122
- package/Models/DatabaseModels/User.d.mts +1 -0
- package/Models/DatabaseModels/User.d.ts +1 -0
- package/Models/DatabaseModels/User.js +29 -0
- package/Models/DatabaseModels/UserSession.js +10 -4
- package/Models/DatabaseModels/VMwareVCenter.d.mts +1 -0
- package/Models/DatabaseModels/VMwareVCenter.d.ts +1 -0
- package/Models/DatabaseModels/VMwareVCenter.js +36 -0
- package/Models/DatabaseModels/Workflow.d.mts +1 -0
- package/Models/DatabaseModels/Workflow.d.ts +1 -0
- package/Models/DatabaseModels/Workflow.js +45 -0
- package/Models/DatabaseModels/WorkflowVersion.d.mts +24 -0
- package/Models/DatabaseModels/WorkflowVersion.d.ts +24 -0
- package/Models/DatabaseModels/WorkflowVersion.js +529 -0
- package/Models/DatabaseModels/WorkflowVersion.mjs +2 -0
- package/Models/DatabaseModels/WorkspaceNotificationRuleOwningTeam.d.mts +18 -0
- package/Models/DatabaseModels/WorkspaceNotificationRuleOwningTeam.d.ts +18 -0
- package/Models/DatabaseModels/WorkspaceNotificationRuleOwningTeam.js +499 -0
- package/Models/DatabaseModels/WorkspaceNotificationRuleOwningTeam.mjs +2 -0
- package/Models/DatabaseModels/WorkspacePublicNoteApprovalMessage.d.mts +31 -0
- package/Models/DatabaseModels/WorkspacePublicNoteApprovalMessage.d.ts +31 -0
- package/Models/DatabaseModels/WorkspacePublicNoteApprovalMessage.js +537 -0
- package/Models/DatabaseModels/WorkspacePublicNoteApprovalMessage.mjs +2 -0
- package/Server/Services/DatabaseService.d.mts +4 -0
- package/Server/Services/DatabaseService.d.ts +4 -0
- package/Server/Types/Database/UpdateByID.d.mts +1 -0
- package/Server/Types/Database/UpdateByID.d.ts +1 -0
- package/Server/Types/Database/UpdateOneBy.d.mts +1 -0
- package/Server/Types/Database/UpdateOneBy.d.ts +1 -0
- package/Server/Utils/Workspace/WorkspaceBase.d.mts +7 -1
- package/Server/Utils/Workspace/WorkspaceBase.d.ts +7 -1
- package/Types/AI/AIActionWords.d.mts +16 -0
- package/Types/AI/AIActionWords.d.ts +16 -0
- package/Types/AI/AIActionWords.js +105 -1
- package/Types/AI/AIActionWords.mjs +3 -0
- package/Types/AI/AIAgentRunLimits.d.mts +76 -13
- package/Types/AI/AIAgentRunLimits.d.ts +76 -13
- package/Types/AI/AIAgentRunLimits.js +434 -51
- package/Types/AI/AIAgentRunLimits.mjs +10 -2
- package/Types/AI/AIChatRecordSeen.d.mts +49 -0
- package/Types/AI/AIChatRecordSeen.d.ts +49 -0
- package/Types/AI/AIChatRecordSeen.js +337 -0
- package/Types/AI/AIChatRecordSeen.mjs +12 -0
- package/Types/AI/AIChatTypes.d.mts +7 -0
- package/Types/AI/AIChatTypes.d.ts +7 -0
- package/Types/AI/AIChatTypes.js +15 -1
- package/Types/AI/AIChatTypes.mjs +1 -0
- package/Types/AI/AIRunAttempt.d.mts +30 -0
- package/Types/AI/AIRunAttempt.d.ts +30 -0
- package/Types/AI/AIRunAttempt.js +175 -0
- package/Types/AI/AIRunAttempt.mjs +5 -0
- package/Types/AI/AIRunEventType.d.mts +3 -0
- package/Types/AI/AIRunEventType.d.ts +3 -0
- package/Types/AI/AIRunEventType.js +28 -0
- package/Types/AI/AIRunStatus.d.mts +2 -0
- package/Types/AI/AIRunStatus.d.ts +2 -0
- package/Types/AI/AIRunStatus.js +12 -0
- package/Types/AI/AgentLoopDetector.d.mts +29 -0
- package/Types/AI/AgentLoopDetector.d.ts +29 -0
- package/Types/AI/AgentLoopDetector.js +196 -0
- package/Types/AI/AgentLoopDetector.mjs +9 -0
- package/Types/AI/CodeAgentRunLimits.d.mts +28 -0
- package/Types/AI/CodeAgentRunLimits.d.ts +28 -0
- package/Types/AI/CodeAgentRunLimits.js +163 -0
- package/Types/AI/CodeAgentRunLimits.mjs +2 -0
- package/Types/AI/CodeFixTaskContext.d.mts +2 -0
- package/Types/AI/CodeFixTaskContext.d.ts +2 -0
- package/Types/AI/CodeTask.d.mts +20 -0
- package/Types/AI/CodeTask.d.ts +20 -0
- package/Types/AI/CodeTask.js +23 -1
- package/Types/AI/CodeTask.mjs +4 -0
- package/Types/AI/CodeTaskRetry.d.mts +21 -0
- package/Types/AI/CodeTaskRetry.d.ts +21 -0
- package/Types/AI/CodeTaskRetry.js +61 -0
- package/Types/AI/CodeTaskRetry.mjs +4 -0
- package/Types/AI/CodeTaskStage.d.mts +19 -0
- package/Types/AI/CodeTaskStage.d.ts +19 -0
- package/Types/AI/CodeTaskStage.js +78 -0
- package/Types/AI/CodeTaskStage.mjs +3 -0
- package/Types/AI/ExternalMcpServer/ExternalMcpServerLimits.d.mts +0 -1
- package/Types/AI/ExternalMcpServer/ExternalMcpServerLimits.d.ts +0 -1
- package/Types/AI/ExternalMcpServer/ExternalMcpServerLimits.js +6 -4
- package/Types/AI/ExternalMcpServer/ExternalMcpServerLimits.mjs +0 -1
- package/Types/AI/ProjectAiRunLimits.d.mts +24 -0
- package/Types/AI/ProjectAiRunLimits.d.ts +24 -0
- package/Types/AI/ProjectAiRunLimits.js +137 -0
- package/Types/AI/ProjectAiRunLimits.mjs +9 -0
- package/Types/AI/ResourceAiAccessApi.d.mts +1 -0
- package/Types/AI/ResourceAiAccessApi.d.ts +1 -0
- package/Types/AI/ResourceAiAccessApi.js +6 -1
- package/Types/AI/ResourceAiAccessApi.mjs +1 -0
- package/Types/AI/ResourceAiAccessPermissions.d.mts +2 -0
- package/Types/AI/ResourceAiAccessPermissions.d.ts +2 -0
- package/Types/AI/ResourceAiAccessPermissions.js +13 -0
- package/Types/AI/ResourceAiAccessPermissions.mjs +2 -0
- package/Types/AI/TransientAIFailure.d.mts +16 -0
- package/Types/AI/TransientAIFailure.d.ts +16 -0
- package/Types/AI/TransientAIFailure.js +228 -0
- package/Types/AI/TransientAIFailure.mjs +4 -0
- package/Types/Accounts/AccountsLanguage.js +1 -0
- package/Types/AdminDashboard/AdminDashboardLanguage.js +1 -0
- package/Types/AnalyticsDatabase/AnalyticsTableName.d.mts +3 -1
- package/Types/AnalyticsDatabase/AnalyticsTableName.d.ts +3 -1
- package/Types/AnalyticsDatabase/AnalyticsTableName.js +16 -0
- package/Types/AuditLog/AuditLogCoverage.d.mts +40 -0
- package/Types/AuditLog/AuditLogCoverage.d.ts +40 -0
- package/Types/AuditLog/AuditLogCoverage.js +804 -0
- package/Types/AuditLog/AuditLogCoverage.mjs +17 -0
- package/Types/AuditLog/Export/AuditLogExportDestinationCatalog.d.mts +13 -1
- package/Types/AuditLog/Export/AuditLogExportDestinationCatalog.d.ts +13 -1
- package/Types/AuditLog/Export/AuditLogExportDestinationCatalog.js +92 -8
- package/Types/AuditLog/Export/AuditLogExportDestinationCatalog.mjs +5 -0
- package/Types/AuditLog/Export/AuditLogExportRecord.d.mts +14 -4
- package/Types/AuditLog/Export/AuditLogExportRecord.d.ts +14 -4
- package/Types/AuditLog/Export/AuditLogExportRecord.js +86 -29
- package/Types/AuditLog/Export/AuditLogExportRecord.mjs +7 -0
- package/Types/AutoRemediation/RemediationApprovals.d.mts +16 -0
- package/Types/AutoRemediation/RemediationApprovals.d.ts +16 -0
- package/Types/AutoRemediation/RemediationApprovals.js +92 -0
- package/Types/AutoRemediation/RemediationApprovals.mjs +7 -0
- package/Types/AutoRemediation/RemediationRound.d.mts +56 -0
- package/Types/AutoRemediation/RemediationRound.d.ts +56 -0
- package/Types/AutoRemediation/RemediationRound.js +242 -0
- package/Types/AutoRemediation/RemediationRound.mjs +22 -0
- package/Types/BaseDatabase/DatabaseCommonInteractionProps.d.mts +2 -0
- package/Types/BaseDatabase/DatabaseCommonInteractionProps.d.ts +2 -0
- package/Types/BaseDatabase/EnableAuditLogOn.d.mts +1 -0
- package/Types/BaseDatabase/EnableAuditLogOn.d.ts +1 -0
- package/Types/BaseDatabase/WriteSource.d.mts +6 -0
- package/Types/BaseDatabase/WriteSource.d.ts +6 -0
- package/Types/BaseDatabase/WriteSource.js +25 -0
- package/Types/BaseDatabase/WriteSource.mjs +4 -0
- package/Types/Cloud/CloudCommitments.d.mts +74 -0
- package/Types/Cloud/CloudCommitments.d.ts +74 -0
- package/Types/Cloud/CloudCommitments.js +294 -0
- package/Types/Cloud/CloudCommitments.mjs +17 -0
- package/Types/Cloud/CloudConnectionTelemetry.d.mts +3 -0
- package/Types/Cloud/CloudConnectionTelemetry.d.ts +3 -0
- package/Types/Cloud/CloudConnectionTelemetry.js +28 -0
- package/Types/Cloud/CloudConnectionTelemetry.mjs +3 -0
- package/Types/Cloud/CloudCost.d.mts +30 -0
- package/Types/Cloud/CloudCost.d.ts +30 -0
- package/Types/Cloud/CloudCost.js +163 -1
- package/Types/Cloud/CloudCost.mjs +8 -0
- package/Types/Cloud/CloudCostAnomaly.d.mts +34 -0
- package/Types/Cloud/CloudCostAnomaly.d.ts +34 -0
- package/Types/Cloud/CloudCostAnomaly.js +236 -0
- package/Types/Cloud/CloudCostAnomaly.mjs +18 -0
- package/Types/Cloud/CloudKeyMetrics.d.mts +13 -0
- package/Types/Cloud/CloudKeyMetrics.d.ts +13 -0
- package/Types/Cloud/CloudKeyMetrics.js +174 -1
- package/Types/Cloud/CloudKeyMetrics.mjs +10 -0
- package/Types/Cloud/CloudLogGroups.d.mts +33 -2
- package/Types/Cloud/CloudLogGroups.d.ts +33 -2
- package/Types/Cloud/CloudLogGroups.js +245 -8
- package/Types/Cloud/CloudLogGroups.mjs +12 -0
- package/Types/Cloud/CloudMonitoredResource.d.mts +1 -0
- package/Types/Cloud/CloudMonitoredResource.d.ts +1 -0
- package/Types/Cloud/CloudMonitoredResource.js +23 -0
- package/Types/Cloud/CloudMonitoredResource.mjs +1 -0
- package/Types/Cloud/CloudPlatform.js +9 -8
- package/Types/Cloud/CloudPlatformCosts.d.mts +54 -0
- package/Types/Cloud/CloudPlatformCosts.d.ts +54 -0
- package/Types/Cloud/CloudPlatformCosts.js +249 -0
- package/Types/Cloud/CloudPlatformCosts.mjs +7 -0
- package/Types/Cloud/CloudResourceCatalog.js +10 -0
- package/Types/Cloud/CloudResourceHealth.d.mts +1 -0
- package/Types/Cloud/CloudResourceHealth.d.ts +1 -0
- package/Types/Cloud/CloudResourceHealth.js +4 -1
- package/Types/Cloud/CloudResourceMetricAggregation.d.mts +21 -0
- package/Types/Cloud/CloudResourceMetricAggregation.d.ts +21 -0
- package/Types/Cloud/CloudResourceMetricAggregation.js +140 -0
- package/Types/Cloud/CloudResourceMetricAggregation.mjs +4 -0
- package/Types/Cloud/CloudRightSizing.d.mts +140 -0
- package/Types/Cloud/CloudRightSizing.d.ts +140 -0
- package/Types/Cloud/CloudRightSizing.js +867 -0
- package/Types/Cloud/CloudRightSizing.mjs +53 -0
- package/Types/Cloud/CloudWatchLogSeverity.d.mts +7 -0
- package/Types/Cloud/CloudWatchLogSeverity.d.ts +7 -0
- package/Types/Cloud/CloudWatchLogSeverity.js +182 -0
- package/Types/Cloud/CloudWatchLogSeverity.mjs +4 -0
- package/Types/Cloud/RdsConnectionLimits.d.mts +53 -0
- package/Types/Cloud/RdsConnectionLimits.d.ts +53 -0
- package/Types/Cloud/RdsConnectionLimits.js +404 -0
- package/Types/Cloud/RdsConnectionLimits.mjs +24 -0
- package/Types/CloudConnection/AwsStackSets.d.mts +51 -0
- package/Types/CloudConnection/AwsStackSets.d.ts +51 -0
- package/Types/CloudConnection/AwsStackSets.js +188 -0
- package/Types/CloudConnection/AwsStackSets.mjs +15 -0
- package/Types/CloudConnection/CloudAiAgentKey.d.mts +65 -0
- package/Types/CloudConnection/CloudAiAgentKey.d.ts +65 -0
- package/Types/CloudConnection/CloudAiAgentKey.js +289 -0
- package/Types/CloudConnection/CloudAiAgentKey.mjs +18 -0
- package/Types/CloudConnection/CloudAiAgentSetupCommands.d.mts +38 -2
- package/Types/CloudConnection/CloudAiAgentSetupCommands.d.ts +38 -2
- package/Types/CloudConnection/CloudAiAgentSetupCommands.js +580 -94
- package/Types/CloudConnection/CloudAiAgentSetupCommands.mjs +20 -1
- package/Types/CloudConnection/CloudConnectionCatalog.d.mts +3 -0
- package/Types/CloudConnection/CloudConnectionCatalog.d.ts +3 -0
- package/Types/CloudConnection/CloudConnectionCatalog.js +31 -1
- package/Types/CloudConnection/CloudConnectionCatalog.mjs +2 -0
- package/Types/CloudConnection/CloudConnectionSetupCommands.js +24 -7
- package/Types/CloudConnection/CloudOrganizationAgents.d.mts +45 -0
- package/Types/CloudConnection/CloudOrganizationAgents.d.ts +45 -0
- package/Types/CloudConnection/CloudOrganizationAgents.js +182 -0
- package/Types/CloudConnection/CloudOrganizationAgents.mjs +12 -0
- package/Types/CloudConnection/CloudStream.d.mts +50 -1
- package/Types/CloudConnection/CloudStream.d.ts +50 -1
- package/Types/CloudConnection/CloudStream.js +333 -23
- package/Types/CloudConnection/CloudStream.mjs +35 -0
- package/Types/CloudConnection/CloudStreamAzure.d.mts +60 -0
- package/Types/CloudConnection/CloudStreamAzure.d.ts +60 -0
- package/Types/CloudConnection/CloudStreamAzure.js +418 -0
- package/Types/CloudConnection/CloudStreamAzure.mjs +35 -0
- package/Types/CloudConnection/CloudStreamGcp.d.mts +55 -0
- package/Types/CloudConnection/CloudStreamGcp.d.ts +55 -0
- package/Types/CloudConnection/CloudStreamGcp.js +247 -0
- package/Types/CloudConnection/CloudStreamGcp.mjs +25 -0
- package/Types/CloudConnection/CloudStreamOrganization.d.mts +17 -0
- package/Types/CloudConnection/CloudStreamOrganization.d.ts +17 -0
- package/Types/CloudConnection/CloudStreamOrganization.js +176 -0
- package/Types/CloudConnection/CloudStreamOrganization.mjs +9 -0
- package/Types/CloudConnection/CloudStreamTemplate.d.mts +5 -5
- package/Types/CloudConnection/CloudStreamTemplate.d.ts +5 -5
- package/Types/CloudConnection/CloudStreamTemplate.js +99 -26
- package/Types/CloudConnection/CloudStreamTemplate.mjs +2 -0
- package/Types/CodeRepository/CodeChangeProposedOnKey.d.mts +1 -0
- package/Types/CodeRepository/CodeChangeProposedOnKey.d.ts +1 -0
- package/Types/CodeRepository/CodeChangeProposedOnKey.js +12 -0
- package/Types/CodeRepository/CodeChangeProposedOnKey.mjs +2 -0
- package/Types/CodeRepository/CodeFileSeen.d.mts +106 -0
- package/Types/CodeRepository/CodeFileSeen.d.ts +106 -0
- package/Types/CodeRepository/CodeFileSeen.js +523 -0
- package/Types/CodeRepository/CodeFileSeen.mjs +17 -0
- package/Types/CodeRepository/CodeFileValuesHidden.d.mts +21 -0
- package/Types/CodeRepository/CodeFileValuesHidden.d.ts +21 -0
- package/Types/CodeRepository/CodeFileValuesHidden.js +135 -0
- package/Types/CodeRepository/CodeFileValuesHidden.mjs +6 -0
- package/Types/CodeRepository/CodeHost.d.mts +15 -0
- package/Types/CodeRepository/CodeHost.d.ts +15 -0
- package/Types/CodeRepository/CodeHost.js +195 -6
- package/Types/CustomNotificationChannel/CustomNotificationChannelPayload.d.mts +1 -0
- package/Types/CustomNotificationChannel/CustomNotificationChannelPayload.d.ts +1 -0
- package/Types/CustomNotificationChannel/CustomNotificationChannelPayload.js +3 -0
- package/Types/Dashboard/DashboardComponentType.d.mts +2 -0
- package/Types/Dashboard/DashboardComponentType.d.ts +2 -0
- package/Types/Dashboard/DashboardComponentType.js +24 -1
- package/Types/Dashboard/DashboardComponentType.mjs +2 -0
- package/Types/Dashboard/DashboardLanguage.js +1 -0
- package/Types/Dashboard/PublicDashboardServedSettings.d.mts +19 -0
- package/Types/Dashboard/PublicDashboardServedSettings.d.ts +19 -0
- package/Types/Dashboard/PublicDashboardServedSettings.js +501 -0
- package/Types/Dashboard/PublicDashboardServedSettings.mjs +12 -0
- package/Types/DataObservability/DataObservabilityApiTypes.d.mts +17 -0
- package/Types/DataObservability/DataObservabilityApiTypes.d.ts +17 -0
- package/Types/DataObservability/DataObservabilityApiTypes.js +5 -1
- package/Types/DataObservability/DataObservabilityApiTypes.mjs +1 -0
- package/Types/DataObservability/DataObservabilityAttention.d.mts +78 -0
- package/Types/DataObservability/DataObservabilityAttention.d.ts +78 -0
- package/Types/DataObservability/DataObservabilityAttention.js +163 -0
- package/Types/DataObservability/DataObservabilityAttention.mjs +12 -0
- package/Types/Database/AccessControl/PermissionScopeNarrowing.js +4 -0
- package/Types/Database/EnableAuditLog.js +3 -0
- package/Types/Date.d.mts +9 -0
- package/Types/Date.d.ts +9 -0
- package/Types/Date.js +57 -8
- package/Types/DateLanguage.d.mts +3 -0
- package/Types/DateLanguage.d.ts +3 -0
- package/Types/DateLanguage.js +59 -10
- package/Types/DateLanguage.mjs +3 -0
- package/Types/Email/EmailServer.d.mts +7 -0
- package/Types/Email/EmailServer.d.ts +7 -0
- package/Types/Email/EmailTemplateType.d.mts +2 -0
- package/Types/Email/EmailTemplateType.d.ts +2 -0
- package/Types/Email/EmailTemplateType.js +3 -0
- package/Types/Email/MailTransportType.d.mts +29 -9
- package/Types/Email/MailTransportType.d.ts +29 -9
- package/Types/Email/MailTransportType.js +56 -8
- package/Types/Email/MailTransportType.mjs +4 -0
- package/Types/Email/MailgunDomain.d.mts +2 -0
- package/Types/Email/MailgunDomain.d.ts +2 -0
- package/Types/Email/MailgunDomain.js +57 -0
- package/Types/Email/MailgunDomain.mjs +3 -0
- package/Types/Email/MailgunRegion.d.mts +8 -0
- package/Types/Email/MailgunRegion.d.ts +8 -0
- package/Types/Email/MailgunRegion.js +32 -0
- package/Types/Email/MailgunRegion.mjs +5 -0
- package/Types/Exception/ConflictException.d.mts +6 -0
- package/Types/Exception/ConflictException.d.ts +6 -0
- package/Types/Exception/ConflictException.js +30 -0
- package/Types/Exception/ConflictException.mjs +2 -0
- package/Types/Exception/ExceptionCode.d.mts +1 -0
- package/Types/Exception/ExceptionCode.d.ts +1 -0
- package/Types/Exception/ExceptionCode.js +2 -0
- package/Types/InstallScripts/InstallScripts.js +1 -1
- package/Types/Kubernetes/KubernetesClusterAiAccess.d.mts +0 -1
- package/Types/Kubernetes/KubernetesClusterAiAccess.d.ts +0 -1
- package/Types/Kubernetes/KubernetesClusterAiAccess.js +7 -6
- package/Types/Kubernetes/KubernetesClusterAiAccess.mjs +0 -1
- package/Types/Kubernetes/KubernetesEvent.js +5 -4
- package/Types/LlmObservability/LlmConnectionCatalog.d.mts +5 -0
- package/Types/LlmObservability/LlmConnectionCatalog.d.ts +5 -0
- package/Types/LlmObservability/LlmConnectionCatalog.js +35 -0
- package/Types/LlmObservability/LlmConnectionProvider.d.mts +1 -0
- package/Types/LlmObservability/LlmConnectionProvider.d.ts +1 -0
- package/Types/LlmObservability/LlmConnectionProvider.js +4 -2
- package/Types/LlmObservability/LlmConnectionRecords.d.mts +7 -0
- package/Types/LlmObservability/LlmConnectionRecords.d.ts +7 -0
- package/Types/LlmObservability/LlmConnectionTest.d.mts +1 -0
- package/Types/LlmObservability/LlmConnectionTest.d.ts +1 -0
- package/Types/Log/LogEventName.d.mts +6 -0
- package/Types/Log/LogEventName.d.ts +6 -0
- package/Types/Log/LogEventName.js +59 -0
- package/Types/Log/LogEventName.mjs +4 -0
- package/Types/MessageQueue/MessageQueueCloudConnectionMetrics.d.mts +15 -0
- package/Types/MessageQueue/MessageQueueCloudConnectionMetrics.d.ts +15 -0
- package/Types/MessageQueue/MessageQueueCloudConnectionMetrics.js +51 -0
- package/Types/MessageQueue/MessageQueueCloudConnectionMetrics.mjs +4 -0
- package/Types/MessageQueue/MessageQueueMetricCatalog.d.mts +1 -1
- package/Types/MessageQueue/MessageQueueMetricCatalog.d.ts +1 -1
- package/Types/MessageQueue/MessageQueueMetricCatalog.js +64 -0
- package/Types/MessageQueue/MessageQueueSpanPopulation.d.mts +65 -0
- package/Types/MessageQueue/MessageQueueSpanPopulation.d.ts +65 -0
- package/Types/MessageQueue/MessageQueueSpanPopulation.js +326 -0
- package/Types/MessageQueue/MessageQueueSpanPopulation.mjs +22 -0
- package/Types/MessageQueue/MessageQueueTopology.d.mts +59 -0
- package/Types/MessageQueue/MessageQueueTopology.d.ts +59 -0
- package/Types/MessageQueue/MessageQueueTopology.js +211 -0
- package/Types/MessageQueue/MessageQueueTopology.mjs +8 -0
- package/Types/MessageQueue/MessagingSystem.js +6 -2
- package/Types/Metrics/MetricsQuery.d.mts +1 -0
- package/Types/Metrics/MetricsQuery.d.ts +1 -0
- package/Types/Monitor/CloudAlertTemplates.d.mts +122 -0
- package/Types/Monitor/CloudAlertTemplates.d.ts +122 -0
- package/Types/Monitor/CloudAlertTemplates.js +2003 -0
- package/Types/Monitor/CloudAlertTemplates.mjs +26 -0
- package/Types/Monitor/CloudAppAlertTemplates.d.mts +34 -0
- package/Types/Monitor/CloudAppAlertTemplates.d.ts +34 -0
- package/Types/Monitor/CloudAppAlertTemplates.js +331 -0
- package/Types/Monitor/CloudAppAlertTemplates.mjs +8 -0
- package/Types/Monitor/IncomingMonitor/IncomingMonitorRequest.d.mts +1 -0
- package/Types/Monitor/IncomingMonitor/IncomingMonitorRequest.d.ts +1 -0
- package/Types/Monitor/MessageQueueAlertTemplates.js +3 -0
- package/Types/Monitor/MetricMonitor/MetricMonitorResponse.d.mts +1 -0
- package/Types/Monitor/MetricMonitor/MetricMonitorResponse.d.ts +1 -0
- package/Types/Monitor/MonitorEvaluationDetails.d.mts +80 -0
- package/Types/Monitor/MonitorEvaluationDetails.d.ts +80 -0
- package/Types/Monitor/MonitorEvaluationDetails.js +41 -0
- package/Types/Monitor/MonitorEvaluationDetails.mjs +3 -0
- package/Types/Monitor/MonitorStepMetricMonitor.d.mts +2 -0
- package/Types/Monitor/MonitorStepMetricMonitor.d.ts +2 -0
- package/Types/Monitor/MonitorStepMetricMonitor.js +4 -0
- package/Types/Monitor/MonitorSummarySnapshot.d.mts +1 -0
- package/Types/Monitor/MonitorSummarySnapshot.d.ts +1 -0
- package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.d.mts +1 -1
- package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.d.ts +1 -1
- package/Types/Monitor/Recommendation/MonitorRecommendationCatalog.js +113 -13
- package/Types/Monitor/Recommendation/MonitorRecommendationTypes.d.mts +16 -1
- package/Types/Monitor/Recommendation/MonitorRecommendationTypes.d.ts +16 -1
- package/Types/Monitor/Recommendation/MonitorRecommendationTypes.js +18 -0
- package/Types/Monitor/Recommendation/MonitorRecommendationUtil.d.mts +10 -0
- package/Types/Monitor/Recommendation/MonitorRecommendationUtil.d.ts +10 -0
- package/Types/Monitor/Recommendation/MonitorRecommendationUtil.js +54 -1
- package/Types/Monitor/TelemetryAlertRule.js +19 -1
- package/Types/NetFlow/NetworkTrafficUsage.d.mts +56 -0
- package/Types/NetFlow/NetworkTrafficUsage.d.ts +56 -0
- package/Types/NetFlow/NetworkTrafficUsage.js +171 -1
- package/Types/NetFlow/NetworkTrafficUsage.mjs +11 -0
- package/Types/NetworkController/NetworkControllerApplianceLink.d.mts +43 -0
- package/Types/NetworkController/NetworkControllerApplianceLink.d.ts +43 -0
- package/Types/NetworkController/NetworkControllerApplianceLink.js +107 -0
- package/Types/NetworkController/NetworkControllerApplianceLink.mjs +8 -0
- package/Types/NetworkDevice/DiscoveredDevice.d.mts +105 -0
- package/Types/NetworkDevice/DiscoveredDevice.d.ts +105 -0
- package/Types/NetworkDevice/DiscoveredDevice.js +407 -0
- package/Types/NetworkDevice/DiscoveredDevice.mjs +23 -0
- package/Types/NetworkDevice/DiscoveredDeviceRetention.d.mts +10 -0
- package/Types/NetworkDevice/DiscoveredDeviceRetention.d.ts +10 -0
- package/Types/NetworkDevice/DiscoveredDeviceRetention.js +93 -0
- package/Types/NetworkDevice/DiscoveredDeviceRetention.mjs +11 -0
- package/Types/NetworkDevice/DiscoveryImport.d.mts +12 -0
- package/Types/NetworkDevice/DiscoveryImport.d.ts +12 -0
- package/Types/NetworkDevice/DiscoveryImport.js +53 -1
- package/Types/NetworkDevice/DiscoveryImport.mjs +2 -0
- package/Types/NetworkDevice/NetworkDeviceTelemetryAttribute.d.mts +2 -0
- package/Types/NetworkDevice/NetworkDeviceTelemetryAttribute.d.ts +2 -0
- package/Types/NetworkDevice/NetworkDeviceTelemetryAttribute.js +19 -0
- package/Types/NetworkDevice/NetworkDeviceTelemetryAttribute.mjs +3 -0
- package/Types/NotificationSetting/NotificationEmailRollupCategory.js +8 -0
- package/Types/NotificationSetting/NotificationEmailRollupPolicy.js +7 -0
- package/Types/NotificationSetting/NotificationSettingEventType.d.mts +2 -0
- package/Types/NotificationSetting/NotificationSettingEventType.d.ts +2 -0
- package/Types/NotificationSetting/NotificationSettingEventType.js +9 -0
- package/Types/OnCallDutyPolicy/OnCallAcknowledgementTimeout.d.mts +5 -3
- package/Types/OnCallDutyPolicy/OnCallAcknowledgementTimeout.d.ts +5 -3
- package/Types/OnCallDutyPolicy/OnCallAcknowledgementTimeout.js +98 -11
- package/Types/OnCallDutyPolicy/OnCallObserverPage.d.mts +61 -0
- package/Types/OnCallDutyPolicy/OnCallObserverPage.d.ts +61 -0
- package/Types/OnCallDutyPolicy/OnCallObserverPage.js +331 -0
- package/Types/OnCallDutyPolicy/OnCallObserverPage.mjs +24 -0
- package/Types/OnCallDutyPolicy/OnCallPageAs.d.mts +5 -0
- package/Types/OnCallDutyPolicy/OnCallPageAs.d.ts +5 -0
- package/Types/OnCallDutyPolicy/OnCallPageAs.js +21 -0
- package/Types/OnCallDutyPolicy/OnCallPageAs.mjs +2 -0
- package/Types/OnCallDutyPolicy/OnCallPagePassOn.d.mts +1 -0
- package/Types/OnCallDutyPolicy/OnCallPagePassOn.d.ts +1 -0
- package/Types/OnCallDutyPolicy/OnCallPageWords.d.mts +59 -0
- package/Types/OnCallDutyPolicy/OnCallPageWords.d.ts +59 -0
- package/Types/OnCallDutyPolicy/OnCallPageWords.js +388 -0
- package/Types/OnCallDutyPolicy/OnCallPageWords.mjs +24 -0
- package/Types/OnCallDutyPolicy/OnCallPersonPage.d.mts +10 -3
- package/Types/OnCallDutyPolicy/OnCallPersonPage.d.ts +10 -3
- package/Types/OnCallDutyPolicy/OnCallPersonPage.js +172 -37
- package/Types/OnCallDutyPolicy/OnCallPersonPage.mjs +2 -0
- package/Types/Permission.d.mts +28 -0
- package/Types/Permission.d.ts +28 -0
- package/Types/Permission.js +288 -0
- package/Types/ProviderLogo/AllProviderLogoMarks.js +2 -0
- package/Types/ProviderLogo/Marks/cursor.d.mts +3 -0
- package/Types/ProviderLogo/Marks/cursor.d.ts +3 -0
- package/Types/ProviderLogo/Marks/cursor.js +12 -0
- package/Types/ProviderLogo/Marks/cursor.mjs +2 -0
- package/Types/ProviderLogo/ProviderLogo.d.mts +1 -0
- package/Types/ProviderLogo/ProviderLogo.d.ts +1 -0
- package/Types/ProviderLogo/ProviderLogo.js +2 -0
- package/Types/ProviderLogo/ProviderLogoMarks.js +1 -0
- package/Types/PushNotification/PushNotificationCategory.d.mts +4 -0
- package/Types/PushNotification/PushNotificationCategory.d.ts +4 -0
- package/Types/PushNotification/PushNotificationCategory.js +36 -12
- package/Types/PushNotification/PushNotificationCategory.mjs +2 -0
- package/Types/ReadingDirection.js +2 -2
- package/Types/ResourceAiAgent/CloudAiAgentNames.d.mts +10 -0
- package/Types/ResourceAiAgent/CloudAiAgentNames.d.ts +10 -0
- package/Types/ResourceAiAgent/CloudAiAgentNames.js +42 -3
- package/Types/ResourceAiAgent/CloudAiAgentNames.mjs +7 -0
- package/Types/ResourceAiAgent/ResourceAiAccess.d.mts +4 -2
- package/Types/ResourceAiAgent/ResourceAiAccess.d.ts +4 -2
- package/Types/ResourceAiAgent/ResourceAiAccess.js +25 -7
- package/Types/ResourceAiAgent/ResourceAiAccess.mjs +3 -1
- package/Types/Rum/ProductAnalytics.d.mts +153 -0
- package/Types/Rum/ProductAnalytics.d.ts +153 -0
- package/Types/Rum/ProductAnalytics.js +204 -0
- package/Types/Rum/ProductAnalytics.mjs +36 -0
- package/Types/Rum/RumApplicationStatus.d.mts +30 -0
- package/Types/Rum/RumApplicationStatus.d.ts +30 -0
- package/Types/Rum/RumApplicationStatus.js +147 -0
- package/Types/Rum/RumApplicationStatus.mjs +14 -0
- package/Types/Rum/RumTelemetrySignal.d.mts +7 -0
- package/Types/Rum/RumTelemetrySignal.d.ts +7 -0
- package/Types/Rum/RumTelemetrySignal.js +30 -0
- package/Types/Rum/RumTelemetrySignal.mjs +3 -0
- package/Types/Rum/SessionReplay.d.mts +6 -0
- package/Types/Rum/SessionReplay.d.ts +6 -0
- package/Types/Rum/SessionReplayApi.d.mts +7 -0
- package/Types/Rum/SessionReplayApi.d.ts +7 -0
- package/Types/Rum/SessionReplayCustomEvents.d.mts +11 -0
- package/Types/Rum/SessionReplayCustomEvents.d.ts +11 -0
- package/Types/Rum/SessionReplayCustomEvents.js +11 -0
- package/Types/Rum/SessionReplayCustomEvents.mjs +1 -0
- package/Types/Rum/SessionReplayFrustrationSignals.d.mts +90 -0
- package/Types/Rum/SessionReplayFrustrationSignals.d.ts +90 -0
- package/Types/Rum/SessionReplayFrustrationSignals.js +349 -0
- package/Types/Rum/SessionReplayFrustrationSignals.mjs +22 -0
- package/Types/SecurityCase/SecurityCaseContext.d.mts +2 -1
- package/Types/SecurityCase/SecurityCaseContext.d.ts +2 -1
- package/Types/SecurityCase/SecurityConnection.d.mts +11 -1
- package/Types/SecurityCase/SecurityConnection.d.ts +11 -1
- package/Types/SecurityEvent/RealTimeDetection.d.mts +14 -5
- package/Types/SecurityEvent/RealTimeDetection.d.ts +14 -5
- package/Types/SecurityEvent/RealTimeDetection.js +75 -25
- package/Types/SecurityEvent/RealTimeDetection.mjs +3 -3
- package/Types/SecurityEvent/SecurityEventScope.d.mts +12 -0
- package/Types/SecurityEvent/SecurityEventScope.d.ts +12 -0
- package/Types/SecurityEvent/SecurityEventScope.js +109 -0
- package/Types/SecurityEvent/SecurityEventScope.mjs +8 -0
- package/Types/SecurityPlaybook/SecurityPlaybookAction.d.mts +4 -2
- package/Types/SecurityPlaybook/SecurityPlaybookAction.d.ts +4 -2
- package/Types/SecurityPlaybook/SecurityPlaybookAction.js +22 -3
- package/Types/SecurityPlaybook/SecurityPlaybookStep.d.mts +7 -2
- package/Types/SecurityPlaybook/SecurityPlaybookStep.d.ts +7 -2
- package/Types/SecurityPlaybook/SecurityPlaybookStep.js +96 -39
- package/Types/SecurityPlaybook/SecurityPlaybookStep.mjs +2 -0
- package/Types/SecurityPlaybook/SecurityPlaybookStepCondition.d.mts +17 -2
- package/Types/SecurityPlaybook/SecurityPlaybookStepCondition.d.ts +17 -2
- package/Types/SecurityPlaybook/SecurityPlaybookStepCondition.js +174 -33
- package/Types/SecurityPlaybook/SecurityPlaybookStepCondition.mjs +7 -0
- package/Types/Serverless/ServerlessFunctionStatus.d.mts +30 -0
- package/Types/Serverless/ServerlessFunctionStatus.d.ts +30 -0
- package/Types/Serverless/ServerlessFunctionStatus.js +153 -0
- package/Types/Serverless/ServerlessFunctionStatus.mjs +14 -0
- package/Types/Service/ServiceTelemetryStatus.d.mts +32 -0
- package/Types/Service/ServiceTelemetryStatus.d.ts +32 -0
- package/Types/Service/ServiceTelemetryStatus.js +138 -0
- package/Types/Service/ServiceTelemetryStatus.mjs +15 -0
- package/Types/StatusPage/PublicNoteApproval.d.mts +146 -0
- package/Types/StatusPage/PublicNoteApproval.d.ts +146 -0
- package/Types/StatusPage/PublicNoteApproval.js +473 -0
- package/Types/StatusPage/PublicNoteApproval.mjs +8 -0
- package/Types/StatusPage/StateChangeSubscriberNotification.d.mts +9 -0
- package/Types/StatusPage/StateChangeSubscriberNotification.d.ts +9 -0
- package/Types/StatusPage/StateChangeSubscriberNotification.js +16 -0
- package/Types/StatusPage/StatusPageLanguage.js +1 -0
- package/Types/StatusPage/StatusPageReport.d.mts +3 -0
- package/Types/StatusPage/StatusPageReport.d.ts +3 -0
- package/Types/StatusPage/SubscriberNotificationResend.d.mts +1 -0
- package/Types/StatusPage/SubscriberNotificationResend.d.ts +1 -0
- package/Types/StatusPage/SubscriberNotificationResend.js +2 -0
- package/Types/Table/DefaultTableColumns.d.mts +22 -0
- package/Types/Table/DefaultTableColumns.d.ts +22 -0
- package/Types/Table/DefaultTableColumns.js +166 -0
- package/Types/Table/DefaultTableColumns.mjs +6 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleHeld.d.mts +15 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleHeld.d.ts +15 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleHeld.js +96 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleHeld.mjs +2 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleKinds.d.mts +12 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleKinds.d.ts +12 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleKinds.js +72 -0
- package/Types/TeamOwnedRule/TeamOwnedRuleKinds.mjs +4 -0
- package/Types/Telemetry/LlmConventions.d.mts +5 -0
- package/Types/Telemetry/LlmConventions.d.ts +5 -0
- package/Types/Telemetry/LlmConventions.js +51 -3
- package/Types/Telemetry/LlmConventions.mjs +5 -0
- package/Types/Telemetry/LlmConversationApi.d.mts +7 -0
- package/Types/Telemetry/LlmConversationApi.d.ts +7 -0
- package/Types/Telemetry/LlmConversationApi.js +37 -1
- package/Types/Telemetry/LlmConversationApi.mjs +2 -0
- package/Types/Telemetry/LlmMetricConventions.d.mts +10 -0
- package/Types/Telemetry/LlmMetricConventions.d.ts +10 -0
- package/Types/Telemetry/LlmMetricConventions.js +84 -14
- package/Types/Telemetry/LlmMetricConventions.mjs +3 -0
- package/Types/Telemetry/LlmMetricUsageApi.d.mts +27 -0
- package/Types/Telemetry/LlmMetricUsageApi.d.ts +27 -0
- package/Types/Telemetry/LlmMetricUsageApi.js +73 -0
- package/Types/Telemetry/LlmMetricUsageApi.mjs +7 -0
- package/Types/Telemetry/LlmProviders.d.mts +23 -0
- package/Types/Telemetry/LlmProviders.d.ts +23 -0
- package/Types/Telemetry/LlmProviders.js +288 -0
- package/Types/Telemetry/LlmProviders.mjs +16 -0
- package/Types/Telemetry/LlmSetupCheckApi.d.mts +93 -0
- package/Types/Telemetry/LlmSetupCheckApi.d.ts +93 -0
- package/Types/Telemetry/LlmSetupCheckApi.js +269 -0
- package/Types/Telemetry/LlmSetupCheckApi.mjs +11 -0
- package/Types/Telemetry/LlmUsageApi.d.mts +49 -0
- package/Types/Telemetry/LlmUsageApi.d.ts +49 -0
- package/Types/Telemetry/LlmUsageApi.js +131 -0
- package/Types/Telemetry/LlmUsageApi.mjs +10 -0
- package/Types/Telemetry/ScrubRule.js +2 -1
- package/Types/Telemetry/TelemetryIngestRefusal.d.mts +23 -0
- package/Types/Telemetry/TelemetryIngestRefusal.d.ts +23 -0
- package/Types/Telemetry/TelemetryIngestRefusal.js +81 -0
- package/Types/Telemetry/TelemetryIngestRefusal.mjs +7 -0
- package/Types/Telemetry/TelemetryIngestionBudget.d.mts +160 -0
- package/Types/Telemetry/TelemetryIngestionBudget.d.ts +160 -0
- package/Types/Telemetry/TelemetryIngestionBudget.js +600 -0
- package/Types/Telemetry/TelemetryIngestionBudget.mjs +52 -0
- package/Types/Telemetry/TelemetryIngestionBudgetMetricType.d.mts +7 -0
- package/Types/Telemetry/TelemetryIngestionBudgetMetricType.d.ts +7 -0
- package/Types/Telemetry/TelemetryIngestionBudgetMetricType.js +50 -0
- package/Types/Telemetry/TelemetryIngestionBudgetMetricType.mjs +2 -0
- package/Types/Telemetry/TelemetryIngestionKeyPolicy.d.mts +2 -0
- package/Types/Telemetry/TelemetryIngestionKeyPolicy.d.ts +2 -0
- package/Types/Telemetry/TelemetryQuery.d.mts +3 -0
- package/Types/Telemetry/TelemetryQuery.d.ts +3 -0
- package/Types/Telemetry/TelemetryUsage.d.mts +79 -0
- package/Types/Telemetry/TelemetryUsage.d.ts +79 -0
- package/Types/Telemetry/TelemetryUsage.js +176 -0
- package/Types/Telemetry/TelemetryUsage.mjs +22 -0
- package/Types/Trace/TraceScrubPatternType.js +2 -1
- package/Types/Translator.d.mts +6 -0
- package/Types/Translator.d.ts +6 -0
- package/Types/Translator.js +113 -12
- package/Types/Translator.mjs +6 -0
- package/Types/UserLanguage.d.mts +7 -0
- package/Types/UserLanguage.d.ts +7 -0
- package/Types/UserLanguage.js +78 -0
- package/Types/UserLanguage.mjs +5 -0
- package/Types/Workflow/Components/OnCall.js +28 -1
- package/Types/Workflow/Components/OnCallPageSettings.d.mts +3 -0
- package/Types/Workflow/Components/OnCallPageSettings.d.ts +3 -0
- package/Types/Workflow/Components/OnCallPageSettings.js +25 -0
- package/Types/Workflow/Components/OnCallPageSettings.mjs +1 -0
- package/Types/Workflow/WorkflowDraft.d.mts +2 -0
- package/Types/Workflow/WorkflowDraft.d.ts +2 -0
- package/Types/Workflow/WorkflowDraft.js +32 -23
- package/Types/Workflow/WorkflowDraft.mjs +1 -0
- package/Types/Workflow/WorkflowDraftProposedOnKey.d.mts +1 -0
- package/Types/Workflow/WorkflowDraftProposedOnKey.d.ts +1 -0
- package/Types/Workflow/WorkflowDraftProposedOnKey.js +11 -0
- package/Types/Workflow/WorkflowDraftProposedOnKey.mjs +2 -0
- package/Types/Workflow/WorkflowDraftRebase.d.mts +74 -0
- package/Types/Workflow/WorkflowDraftRebase.d.ts +74 -0
- package/Types/Workflow/WorkflowDraftRebase.js +447 -0
- package/Types/Workflow/WorkflowDraftRebase.mjs +9 -0
- package/Types/Workflow/WorkflowDraftSeen.d.mts +39 -0
- package/Types/Workflow/WorkflowDraftSeen.d.ts +39 -0
- package/Types/Workflow/WorkflowDraftSeen.js +161 -0
- package/Types/Workflow/WorkflowDraftSeen.mjs +6 -0
- package/Types/Workflow/WorkflowGraphRevision.d.mts +2 -0
- package/Types/Workflow/WorkflowGraphRevision.d.ts +2 -0
- package/Types/Workflow/WorkflowGraphRevision.js +45 -0
- package/Types/Workflow/WorkflowGraphRevision.mjs +3 -0
- package/Types/Workflow/WorkflowVersion.d.mts +11 -0
- package/Types/Workflow/WorkflowVersion.d.ts +11 -0
- package/Types/Workflow/WorkflowVersion.js +63 -0
- package/Types/Workflow/WorkflowVersion.mjs +7 -0
- package/Utils/AI/InvestigationImpactNumbers.d.mts +33 -0
- package/Utils/AI/InvestigationImpactNumbers.d.ts +33 -0
- package/Utils/AI/InvestigationImpactNumbers.js +307 -0
- package/Utils/AI/InvestigationImpactNumbers.mjs +9 -0
- package/Utils/AI/InvestigationReport.d.mts +14 -0
- package/Utils/AI/InvestigationReport.d.ts +14 -0
- package/Utils/AI/InvestigationReport.js +136 -3
- package/Utils/AI/InvestigationReport.mjs +4 -0
- package/Utils/AiRemediation/CloudChangeWords.js +6 -0
- package/Utils/AiRemediation/DeclaredCodeChange.d.mts +106 -0
- package/Utils/AiRemediation/DeclaredCodeChange.d.ts +106 -0
- package/Utils/AiRemediation/DeclaredCodeChange.js +451 -0
- package/Utils/AiRemediation/DeclaredCodeChange.mjs +16 -0
- package/Utils/AiRemediation/Resource/CloudCommandPolicy.js +4 -0
- package/Utils/AiRemediation/Resource/CloudOperationCatalog.d.mts +1 -0
- package/Utils/AiRemediation/Resource/CloudOperationCatalog.d.ts +1 -0
- package/Utils/AiRemediation/Resource/CloudOperationCatalog.js +144 -11
- package/Utils/AiRemediation/Resource/CloudOperationCatalog.mjs +1 -0
- package/Utils/AuditLog/AuditLogTypedValues.d.mts +23 -0
- package/Utils/AuditLog/AuditLogTypedValues.d.ts +23 -0
- package/Utils/AuditLog/AuditLogTypedValues.js +331 -0
- package/Utils/AuditLog/AuditLogTypedValues.mjs +8 -0
- package/Utils/AuditLog/AuditLogValues.d.mts +25 -0
- package/Utils/AuditLog/AuditLogValues.d.ts +25 -0
- package/Utils/AuditLog/AuditLogValues.js +398 -0
- package/Utils/AuditLog/AuditLogValues.mjs +15 -0
- package/Utils/CronScheduleText.js +2 -2
- package/Utils/Dashboard/DashboardWidgetIds.d.mts +9 -0
- package/Utils/Dashboard/DashboardWidgetIds.d.ts +9 -0
- package/Utils/Dashboard/DashboardWidgetIds.js +136 -0
- package/Utils/Dashboard/DashboardWidgetIds.mjs +4 -0
- package/Utils/Dashboard/DashboardWidgetSorts.js +7 -1
- package/Utils/Dashboard/LabelVariable.js +12 -2
- package/Utils/Dashboard/SloWidgetSource.d.mts +2 -2
- package/Utils/Dashboard/SloWidgetSource.d.ts +2 -2
- package/Utils/Dashboard/SloWidgetSource.js +14 -3
- package/Utils/Dashboard/StoredDashboardViewConfig.d.mts +7 -0
- package/Utils/Dashboard/StoredDashboardViewConfig.d.ts +7 -0
- package/Utils/Dashboard/StoredDashboardViewConfig.js +124 -22
- package/Utils/Episode/EpisodeOpeningThreshold.d.mts +9 -0
- package/Utils/Episode/EpisodeOpeningThreshold.d.ts +9 -0
- package/Utils/Episode/EpisodeOpeningThreshold.js +64 -0
- package/Utils/Episode/EpisodeOpeningThreshold.mjs +7 -0
- package/Utils/LLM/LlmProviderResponseTimeout.d.mts +4 -0
- package/Utils/LLM/LlmProviderResponseTimeout.d.ts +4 -0
- package/Utils/LLM/LlmProviderResponseTimeout.js +24 -0
- package/Utils/LLM/LlmProviderResponseTimeout.mjs +4 -0
- package/Utils/LinearRegExp/PatternWork.d.mts +1 -0
- package/Utils/LinearRegExp/PatternWork.d.ts +1 -0
- package/Utils/LinearRegExp/PatternWork.js +10 -4
- package/Utils/LinearRegExp/PatternWork.mjs +1 -0
- package/Utils/Markdown/Base64Data.d.mts +8 -0
- package/Utils/Markdown/Base64Data.d.ts +8 -0
- package/Utils/Markdown/Base64Data.js +130 -0
- package/Utils/Markdown/Base64Data.mjs +4 -0
- package/Utils/Metrics/MetricExplorerUrl.d.mts +1 -0
- package/Utils/Metrics/MetricExplorerUrl.d.ts +1 -0
- package/Utils/Metrics/MetricExplorerUrl.js +14 -3
- package/Utils/Metrics/MetricFormulaEvaluator.d.mts +18 -0
- package/Utils/Metrics/MetricFormulaEvaluator.d.ts +18 -0
- package/Utils/Metrics/MetricFormulaEvaluator.js +112 -0
- package/Utils/Metrics/MetricQueryCloudAggregation.d.mts +62 -0
- package/Utils/Metrics/MetricQueryCloudAggregation.d.ts +62 -0
- package/Utils/Metrics/MetricQueryCloudAggregation.js +335 -0
- package/Utils/Metrics/MetricQueryCloudAggregation.mjs +2 -0
- package/Utils/Metrics/MetricQueryServices.d.mts +14 -0
- package/Utils/Metrics/MetricQueryServices.d.ts +14 -0
- package/Utils/Metrics/MetricQueryServices.js +121 -0
- package/Utils/Metrics/MetricQueryServices.mjs +2 -0
- package/Utils/Metrics/MetricWholeWindow.d.mts +11 -0
- package/Utils/Metrics/MetricWholeWindow.d.ts +11 -0
- package/Utils/Metrics/MetricWholeWindow.js +50 -0
- package/Utils/Metrics/MetricWholeWindow.mjs +2 -0
- package/Utils/Monitor/MetricTelemetrySnapshot.d.mts +23 -0
- package/Utils/Monitor/MetricTelemetrySnapshot.d.ts +23 -0
- package/Utils/Monitor/MetricTelemetrySnapshot.js +154 -0
- package/Utils/Monitor/MetricTelemetrySnapshot.mjs +2 -0
- package/Utils/Monitor/MonitorAutoResolveTemplates.d.mts +13 -0
- package/Utils/Monitor/MonitorAutoResolveTemplates.d.ts +13 -0
- package/Utils/Monitor/MonitorAutoResolveTemplates.js +59 -0
- package/Utils/Monitor/MonitorAutoResolveTemplates.mjs +2 -0
- package/Utils/Monitor/MonitorEvaluationDetailsUtil.d.mts +8 -0
- package/Utils/Monitor/MonitorEvaluationDetailsUtil.d.ts +8 -0
- package/Utils/Monitor/MonitorEvaluationDetailsUtil.js +81 -0
- package/Utils/Monitor/MonitorEvaluationDetailsUtil.mjs +2 -0
- package/Utils/Monitor/MonitorGroupMonitoring.d.mts +25 -0
- package/Utils/Monitor/MonitorGroupMonitoring.d.ts +25 -0
- package/Utils/Monitor/MonitorGroupMonitoring.js +78 -0
- package/Utils/Monitor/MonitorGroupMonitoring.mjs +3 -0
- package/Utils/Monitor/MonitorOverviewFamily.d.mts +2 -1
- package/Utils/Monitor/MonitorOverviewFamily.d.ts +2 -1
- package/Utils/Monitor/MonitorOverviewFamily.js +35 -3
- package/Utils/Monitor/MonitorOverviewPresentationUtil.d.mts +1 -0
- package/Utils/Monitor/MonitorOverviewPresentationUtil.d.ts +1 -0
- package/Utils/Monitor/MonitorOverviewPresentationUtil.js +5 -0
- package/Utils/Monitor/MonitorStepMetricQueries.d.mts +61 -0
- package/Utils/Monitor/MonitorStepMetricQueries.d.ts +61 -0
- package/Utils/Monitor/MonitorStepMetricQueries.js +616 -0
- package/Utils/Monitor/MonitorStepMetricQueries.mjs +6 -0
- package/Utils/Monitor/MonitorStepMetricThresholds.d.mts +62 -0
- package/Utils/Monitor/MonitorStepMetricThresholds.d.ts +62 -0
- package/Utils/Monitor/MonitorStepMetricThresholds.js +415 -0
- package/Utils/Monitor/MonitorStepMetricThresholds.mjs +4 -0
- package/Utils/Monitor/NetworkTopologyUtil.d.mts +1 -0
- package/Utils/Monitor/NetworkTopologyUtil.d.ts +1 -0
- package/Utils/Monitor/NetworkTopologyUtil.js +27 -7
- package/Utils/Monitor/NetworkTopologyUtil.mjs +1 -0
- package/Utils/Monitor/NotOperationalMonitorQuery.d.mts +5 -0
- package/Utils/Monitor/NotOperationalMonitorQuery.d.ts +5 -0
- package/Utils/Monitor/NotOperationalMonitorQuery.js +37 -0
- package/Utils/Monitor/NotOperationalMonitorQuery.mjs +2 -0
- package/Utils/NameBreaks.js +44 -12
- package/Utils/NetworkDevice/DeviceNameLikeness.d.mts +33 -0
- package/Utils/NetworkDevice/DeviceNameLikeness.d.ts +33 -0
- package/Utils/NetworkDevice/DeviceNameLikeness.js +279 -0
- package/Utils/NetworkDevice/DeviceNameLikeness.mjs +14 -0
- package/Utils/NetworkDevice/DiscoveredDeviceIdentity.d.mts +13 -0
- package/Utils/NetworkDevice/DiscoveredDeviceIdentity.d.ts +13 -0
- package/Utils/NetworkDevice/DiscoveredDeviceIdentity.js +104 -0
- package/Utils/NetworkDevice/DiscoveredDeviceIdentity.mjs +6 -0
- package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.d.mts +12 -0
- package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.d.ts +12 -0
- package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.js +92 -0
- package/Utils/NetworkDiscovery/DiscoveredEndpointDeviceBuilder.mjs +3 -0
- package/Utils/Project/ProjectBilling.d.mts +1 -0
- package/Utils/Project/ProjectBilling.d.ts +1 -0
- package/Utils/Project/ProjectBilling.js +27 -3
- package/Utils/Project/ProjectBilling.mjs +1 -0
- package/Utils/Rum/SessionReplayFrustrationSettingsValidation.d.mts +9 -0
- package/Utils/Rum/SessionReplayFrustrationSettingsValidation.d.ts +9 -0
- package/Utils/Rum/SessionReplayFrustrationSettingsValidation.js +337 -0
- package/Utils/Rum/SessionReplayFrustrationSettingsValidation.mjs +5 -0
- package/Utils/Rum/UserFlow.js +6 -2
- package/Utils/Runbook/RunbookStepExecutionChanges.d.mts +32 -0
- package/Utils/Runbook/RunbookStepExecutionChanges.d.ts +32 -0
- package/Utils/Runbook/RunbookStepExecutionChanges.js +264 -0
- package/Utils/Runbook/RunbookStepExecutionChanges.mjs +11 -0
- package/Utils/SecurityCase/SecurityCaseMarkdown.d.mts +5 -0
- package/Utils/SecurityCase/SecurityCaseMarkdown.d.ts +5 -0
- package/Utils/SecurityCase/SecurityCaseMarkdown.js +10 -0
- package/Utils/SecurityCase/SecurityCaseMarkdown.mjs +1 -0
- package/Utils/SecurityCase/SecurityConnectionMatch.d.mts +1 -0
- package/Utils/SecurityCase/SecurityConnectionMatch.d.ts +1 -0
- package/Utils/SecurityCase/SecurityConnectionMatch.js +33 -0
- package/Utils/SecurityCase/SecurityConnectionMatch.mjs +1 -0
- package/Utils/SecurityEvent/LogParsers/DatabaseServerLogLine.d.mts +5 -0
- package/Utils/SecurityEvent/LogParsers/DatabaseServerLogLine.d.ts +5 -0
- package/Utils/SecurityEvent/LogParsers/DatabaseServerLogLine.js +458 -0
- package/Utils/SecurityEvent/LogParsers/DatabaseServerLogLine.mjs +6 -0
- package/Utils/SecurityEvent/LogParsers/SecurityLogLine.d.mts +1 -0
- package/Utils/SecurityEvent/LogParsers/SecurityLogLine.d.ts +1 -0
- package/Utils/SecurityEvent/LogParsers/SecurityLogLine.js +30 -0
- package/Utils/SecurityEvent/LogParsers/SecurityLogLine.mjs +1 -0
- package/Utils/SecurityEvent/LogParsers/SecurityLogParser.js +9 -0
- package/Utils/SecurityEvent/LogParsers/WebAttackLogParser.d.mts +3 -0
- package/Utils/SecurityEvent/LogParsers/WebAttackLogParser.d.ts +3 -0
- package/Utils/SecurityEvent/LogParsers/WebAttackLogParser.js +223 -33
- package/Utils/SecurityEvent/LogParsers/WebAttackLogParser.mjs +3 -0
- package/Utils/SecurityEvent/SecurityScanWords.d.mts +2 -0
- package/Utils/SecurityEvent/SecurityScanWords.d.ts +2 -0
- package/Utils/SecurityEvent/SecurityScanWords.js +122 -0
- package/Utils/SecurityEvent/SecurityScanWords.mjs +3 -0
- package/Utils/Slo/SloBulkRecommendedBurnRateRules.d.mts +42 -0
- package/Utils/Slo/SloBulkRecommendedBurnRateRules.d.ts +42 -0
- package/Utils/Slo/SloBulkRecommendedBurnRateRules.js +207 -0
- package/Utils/Slo/SloBulkRecommendedBurnRateRules.mjs +10 -0
- package/Utils/Slo/SloBurnRateTemplate.d.mts +23 -3
- package/Utils/Slo/SloBurnRateTemplate.d.ts +23 -3
- package/Utils/Slo/SloBurnRateTemplate.js +96 -17
- package/Utils/Slo/SloBurnRateTemplate.mjs +6 -0
- package/Utils/Slo/SloErrorBudgetPolicy.d.mts +99 -0
- package/Utils/Slo/SloErrorBudgetPolicy.d.ts +99 -0
- package/Utils/Slo/SloErrorBudgetPolicy.js +398 -0
- package/Utils/Slo/SloErrorBudgetPolicy.mjs +25 -0
- package/Utils/Slo/SloEvaluation.d.mts +22 -0
- package/Utils/Slo/SloEvaluation.d.ts +22 -0
- package/Utils/Slo/SloEvaluation.js +43 -1
- package/Utils/Slo/SloEvaluation.mjs +4 -0
- package/Utils/Slo/SloFeedMarkdown.d.mts +27 -0
- package/Utils/Slo/SloFeedMarkdown.d.ts +27 -0
- package/Utils/Slo/SloFeedMarkdown.js +118 -3
- package/Utils/Slo/SloFeedMarkdown.mjs +2 -0
- package/Utils/Slo/SloRecommendedBurnRateRules.d.mts +73 -0
- package/Utils/Slo/SloRecommendedBurnRateRules.d.ts +73 -0
- package/Utils/Slo/SloRecommendedBurnRateRules.js +348 -0
- package/Utils/Slo/SloRecommendedBurnRateRules.mjs +28 -0
- package/Utils/Slo/SloRecordOutputColumns.d.mts +25 -0
- package/Utils/Slo/SloRecordOutputColumns.d.ts +25 -0
- package/Utils/Slo/SloRecordOutputColumns.js +87 -0
- package/Utils/Slo/SloRecordOutputColumns.mjs +9 -0
- package/Utils/Slo/SloStatusColor.d.mts +6 -0
- package/Utils/Slo/SloStatusColor.d.ts +6 -0
- package/Utils/Slo/SloStatusColor.js +23 -1
- package/Utils/Slo/SloStatusColor.mjs +2 -0
- package/Utils/Slo/SloUtil.d.mts +4 -0
- package/Utils/Slo/SloUtil.d.ts +4 -0
- package/Utils/Slo/SloUtil.js +8 -2
- package/Utils/Sms/OnCallPageSms.d.mts +18 -0
- package/Utils/Sms/OnCallPageSms.d.ts +18 -0
- package/Utils/Sms/OnCallPageSms.js +88 -6
- package/Utils/StatusPage/Report.js +2 -0
- package/Utils/StatusPage/ReportPeriod.d.mts +4 -4
- package/Utils/StatusPage/ReportPeriod.d.ts +4 -4
- package/Utils/StatusPage/ReportPeriod.js +23 -47
- package/Utils/StatusPage/ReportText.d.mts +33 -0
- package/Utils/StatusPage/ReportText.d.ts +33 -0
- package/Utils/StatusPage/ReportText.js +266 -0
- package/Utils/StatusPage/ReportText.mjs +3 -0
- package/Utils/Telemetry/CloudChangeTitle.d.mts +37 -0
- package/Utils/Telemetry/CloudChangeTitle.d.ts +37 -0
- package/Utils/Telemetry/CloudChangeTitle.js +315 -3
- package/Utils/Telemetry/CloudChangeTitle.mjs +13 -0
- package/Utils/Telemetry/CloudHealthDescription.d.mts +53 -0
- package/Utils/Telemetry/CloudHealthDescription.d.ts +53 -0
- package/Utils/Telemetry/CloudHealthDescription.js +310 -0
- package/Utils/Telemetry/CloudHealthDescription.mjs +13 -0
- package/Utils/Telemetry/LlmCallCounting.d.mts +30 -0
- package/Utils/Telemetry/LlmCallCounting.d.ts +30 -0
- package/Utils/Telemetry/LlmCallCounting.js +109 -0
- package/Utils/Telemetry/LlmCallCounting.mjs +2 -0
- package/Utils/Telemetry/LlmConversationTranscript.js +12 -6
- package/Utils/Telemetry/LlmLogEvents.d.mts +45 -0
- package/Utils/Telemetry/LlmLogEvents.d.ts +45 -0
- package/Utils/Telemetry/LlmLogEvents.js +613 -0
- package/Utils/Telemetry/LlmLogEvents.mjs +4 -0
- package/Utils/Telemetry/LlmMessageParser.d.mts +1 -0
- package/Utils/Telemetry/LlmMessageParser.d.ts +1 -0
- package/Utils/Telemetry/LlmMessageParser.js +60 -2
- package/Utils/Telemetry/LlmMetricUsage.d.mts +27 -0
- package/Utils/Telemetry/LlmMetricUsage.d.ts +27 -0
- package/Utils/Telemetry/LlmMetricUsage.js +189 -0
- package/Utils/Telemetry/LlmMetricUsage.mjs +2 -0
- package/Utils/Telemetry/LlmUsage.d.mts +51 -0
- package/Utils/Telemetry/LlmUsage.d.ts +51 -0
- package/Utils/Telemetry/LlmUsage.js +266 -0
- package/Utils/Telemetry/LlmUsage.mjs +3 -0
- package/Utils/Telemetry/ScrubNestedValues.d.mts +14 -0
- package/Utils/Telemetry/ScrubNestedValues.d.ts +14 -0
- package/Utils/Telemetry/ScrubNestedValues.js +302 -0
- package/Utils/Telemetry/ScrubNestedValues.mjs +4 -0
- package/Utils/Telemetry/TelemetryIngestionBudgetMetricType.d.mts +18 -0
- package/Utils/Telemetry/TelemetryIngestionBudgetMetricType.d.ts +18 -0
- package/Utils/Telemetry/TelemetryIngestionBudgetMetricType.js +141 -0
- package/Utils/Telemetry/TelemetryIngestionBudgetMetricType.mjs +9 -0
- package/Utils/Workflow/WorkflowGraphChanges.d.mts +65 -0
- package/Utils/Workflow/WorkflowGraphChanges.d.ts +65 -0
- package/Utils/Workflow/WorkflowGraphChanges.js +530 -0
- package/Utils/Workflow/WorkflowGraphChanges.mjs +8 -0
- package/Utils/Workflow/WorkflowGraphSnapshot.d.mts +12 -0
- package/Utils/Workflow/WorkflowGraphSnapshot.d.ts +12 -0
- package/Utils/Workflow/WorkflowGraphSnapshot.js +214 -0
- package/Utils/Workflow/WorkflowGraphSnapshot.mjs +6 -0
- package/package.json +1 -1
|
@@ -36,19 +36,31 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.GCP_CLOUD_AI_AGENT_KEY_READER = exports.GCP_CLOUD_AI_AGENT_VM_REFUSED_MESSAGE = exports.GCP_CLOUD_AI_AGENT_RUN_DIRECTORY = exports.GCP_CLOUD_AI_AGENT_LOG_WRITER_ROLE = exports.GCP_CLOUD_AI_AGENT_STARTUP_FILE = exports.GCP_CLOUD_AI_AGENT_SUBNET_RANGE = exports.GCP_CLOUD_AI_AGENT_IMAGE_PROJECT = exports.GCP_CLOUD_AI_AGENT_IMAGE_FAMILY = exports.GCP_CLOUD_AI_AGENT_BOOT_DISK_TYPE = exports.GCP_CLOUD_AI_AGENT_BOOT_DISK_GB = exports.GCP_CLOUD_AI_AGENT_MACHINE_TYPE = exports.AWS_CLOUD_AI_AGENT_LOG_RETENTION_DAYS = exports.GCP_CLOUD_AI_AGENT_DEPLOY_RETRY_MESSAGE = exports.GCP_CLOUD_AI_AGENT_DEPLOY_RETRY_SECONDS = exports.GCP_CLOUD_AI_AGENT_DEPLOY_ATTEMPTS = exports.GCP_SECRET_ACCESSOR_ROLE = exports.GCP_CLOUD_AI_AGENT_KEY_FILE_END = exports.GCP_CLOUD_AI_AGENT_SECRET_NAME = exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME = exports.GCP_CLOUD_AI_AGENT_KEY_FILE = exports.GCP_CLOUD_AI_AGENT_ENV_FILE = exports.AWS_CLOUD_AI_AGENT_TEMPLATE_FILE = exports.CLOUD_AI_AGENT_HEALTH_HOST_ENV = exports.
|
|
39
|
+
exports.CLOUD_AI_AGENT_ORGANIZATION_ACCOUNT_FAILED_MESSAGE = exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_ACCOUNTS_FILE = exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_TEMPLATE_FILE = exports.CLOUD_AI_AGENT_ORGANIZATION_MAX_ACCOUNTS = exports.AWS_CLOUD_AI_AGENT_SUBNET_CIDR = exports.AWS_CLOUD_AI_AGENT_VPC_CIDR = exports.GCP_CLOUD_AI_AGENT_KEY_READER = exports.GCP_CLOUD_AI_AGENT_VM_REFUSED_MESSAGE = exports.GCP_CLOUD_AI_AGENT_RUN_DIRECTORY = exports.GCP_CLOUD_AI_AGENT_LOG_WRITER_ROLE = exports.GCP_CLOUD_AI_AGENT_STARTUP_FILE = exports.GCP_CLOUD_AI_AGENT_SUBNET_RANGE = exports.GCP_CLOUD_AI_AGENT_IMAGE_PROJECT = exports.GCP_CLOUD_AI_AGENT_IMAGE_FAMILY = exports.GCP_CLOUD_AI_AGENT_BOOT_DISK_TYPE = exports.GCP_CLOUD_AI_AGENT_BOOT_DISK_GB = exports.GCP_CLOUD_AI_AGENT_MACHINE_TYPE = exports.AWS_CLOUD_AI_AGENT_LOG_RETENTION_DAYS = exports.GCP_CLOUD_AI_AGENT_DEPLOY_RETRY_MESSAGE = exports.GCP_CLOUD_AI_AGENT_DEPLOY_RETRY_SECONDS = exports.GCP_CLOUD_AI_AGENT_DEPLOY_ATTEMPTS = exports.GCP_TOKEN_CREATOR_ROLE = exports.GCP_SECRET_ACCESSOR_ROLE = exports.GCP_CLOUD_AI_AGENT_KEY_FILE_END = exports.GCP_CLOUD_AI_AGENT_SECRET_NAME = exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME = exports.GCP_CLOUD_AI_AGENT_KEY_FILE = exports.GCP_CLOUD_AI_AGENT_ENV_FILE = exports.AWS_CLOUD_AI_AGENT_TEMPLATE_FILE = exports.CLOUD_AI_AGENT_HEALTH_HOST_ENV = exports.CLOUD_AI_AGENT_KEY_ENV = exports.CLOUD_AI_AGENT_ONEUPTIME_URL_ENV = exports.CLOUD_AI_AGENT_STARTED_MESSAGE = exports.CLOUD_AI_AGENT_SIZES = exports.CLOUD_AI_AGENT_DEFAULT_REGIONS = exports.CLOUD_AI_AGENT_IMAGE_TAG = exports.CLOUD_AI_AGENT_DEFAULT_FIXES_MODE = exports.CLOUD_AI_AGENT_FIXES_MODES = void 0;
|
|
40
40
|
exports.getCloudAiAgentChangeOperations = getCloudAiAgentChangeOperations;
|
|
41
41
|
exports.isReadableCloudAiAgentProtectedTarget = isReadableCloudAiAgentProtectedTarget;
|
|
42
42
|
exports.getCloudAiAgentMaxProtectedTargets = getCloudAiAgentMaxProtectedTargets;
|
|
43
43
|
exports.describeCloudAiAgentSetupProblem = describeCloudAiAgentSetupProblem;
|
|
44
44
|
exports.getCloudAiAgentImage = getCloudAiAgentImage;
|
|
45
45
|
exports.getAwsCloudAiAgentWriteRoleArn = getAwsCloudAiAgentWriteRoleArn;
|
|
46
|
+
exports.getGcpCloudAiAgentWriteServiceAccount = getGcpCloudAiAgentWriteServiceAccount;
|
|
46
47
|
exports.getCloudAiAgentEnvironment = getCloudAiAgentEnvironment;
|
|
47
48
|
exports.getCloudAiAgentRolePermissions = getCloudAiAgentRolePermissions;
|
|
49
|
+
exports.getGcpCloudAiAgentReaderPermissions = getGcpCloudAiAgentReaderPermissions;
|
|
48
50
|
exports.getAwsCloudAiAgentTemplate = getAwsCloudAiAgentTemplate;
|
|
49
51
|
exports.getAwsCloudAiAgentSetupCommand = getAwsCloudAiAgentSetupCommand;
|
|
52
|
+
exports.describeCloudAiAgentOrganizationSetupProblem = describeCloudAiAgentOrganizationSetupProblem;
|
|
53
|
+
exports.getAwsOrganizationCloudAiAgentTemplate = getAwsOrganizationCloudAiAgentTemplate;
|
|
54
|
+
exports.getCloudAiAgentOrganizationWrongAccountMessage = getCloudAiAgentOrganizationWrongAccountMessage;
|
|
55
|
+
exports.getCloudAiAgentOrganizationStartedMessage = getCloudAiAgentOrganizationStartedMessage;
|
|
56
|
+
exports.getAwsOrganizationCloudAiAgentSetupCommand = getAwsOrganizationCloudAiAgentSetupCommand;
|
|
57
|
+
exports.getAwsOrganizationCloudAiAgentInstancesCommand = getAwsOrganizationCloudAiAgentInstancesCommand;
|
|
58
|
+
exports.getAwsOrganizationCloudAiAgentRemoveCommand = getAwsOrganizationCloudAiAgentRemoveCommand;
|
|
50
59
|
exports.getAzureCloudAiAgentRoleName = getAzureCloudAiAgentRoleName;
|
|
60
|
+
exports.getAzureCloudAiAgentReaderRoleName = getAzureCloudAiAgentReaderRoleName;
|
|
61
|
+
exports.getAzureCloudAiAgentReaderPermissions = getAzureCloudAiAgentReaderPermissions;
|
|
51
62
|
exports.getAzureCloudAiAgentRoleDefinition = getAzureCloudAiAgentRoleDefinition;
|
|
63
|
+
exports.getAzureCloudAiAgentReaderRoleDefinition = getAzureCloudAiAgentReaderRoleDefinition;
|
|
52
64
|
exports.getAzureCloudAiAgentSetupCommand = getAzureCloudAiAgentSetupCommand;
|
|
53
65
|
exports.getGcpCloudAiAgentServices = getGcpCloudAiAgentServices;
|
|
54
66
|
exports.getGcpCloudAiAgentSetupCommand = getGcpCloudAiAgentSetupCommand;
|
|
@@ -61,6 +73,8 @@ const AiResourceType_1 = __importStar(require("../ResourceAiAgent/AiResourceType
|
|
|
61
73
|
const CloudAiAgentNames_1 = require("../ResourceAiAgent/CloudAiAgentNames");
|
|
62
74
|
const ResourceAiAccess_1 = require("../ResourceAiAgent/ResourceAiAccess");
|
|
63
75
|
const ShellWord_1 = require("../Runbook/ShellWord");
|
|
76
|
+
const CloudAiAgentKey_1 = require("./CloudAiAgentKey");
|
|
77
|
+
const AwsStackSets_1 = require("./AwsStackSets");
|
|
64
78
|
const CloudOperationCatalog_1 = require("../../Utils/AiRemediation/Resource/CloudOperationCatalog");
|
|
65
79
|
/*
|
|
66
80
|
* "Ask me first" (the default), "Fix safe problems on its own", and under
|
|
@@ -96,19 +110,17 @@ exports.CLOUD_AI_AGENT_STARTED_MESSAGE = "The Cloud AI agent is starting. It con
|
|
|
96
110
|
/*
|
|
97
111
|
* Variables the agent's Config reads (agents/ResourceAIAgent/Config.ts:
|
|
98
112
|
* ONEUPTIME_URL_ENV and HEALTH_HOST_ENV; the health port is PORT, which
|
|
99
|
-
* Cloud Run sets from --port). The key goes in the
|
|
100
|
-
* RESOURCE_AI_AGENT_API_KEY_ENVS that names an
|
|
113
|
+
* Cloud Run sets from --port). The key goes in the first of
|
|
114
|
+
* RESOURCE_AI_AGENT_API_KEY_ENVS, the one that names an agent's own key.
|
|
101
115
|
*/
|
|
102
116
|
exports.CLOUD_AI_AGENT_ONEUPTIME_URL_ENV = "ONEUPTIME_URL";
|
|
103
|
-
exports.
|
|
104
|
-
return name === "ONEUPTIME_TELEMETRY_INGESTION_KEY";
|
|
105
|
-
}) || "ONEUPTIME_TELEMETRY_INGESTION_KEY";
|
|
117
|
+
exports.CLOUD_AI_AGENT_KEY_ENV = ResourceAiAccess_1.RESOURCE_AI_AGENT_KEY_ENV;
|
|
106
118
|
exports.CLOUD_AI_AGENT_HEALTH_HOST_ENV = "ONEUPTIME_AI_AGENT_HEALTH_HOST";
|
|
107
119
|
// What the commands write in the shell's directory, and the secrets' names.
|
|
108
120
|
exports.AWS_CLOUD_AI_AGENT_TEMPLATE_FILE = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}.json`;
|
|
109
121
|
exports.GCP_CLOUD_AI_AGENT_ENV_FILE = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}.env.yaml`;
|
|
110
122
|
exports.GCP_CLOUD_AI_AGENT_KEY_FILE = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}.key`;
|
|
111
|
-
exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME = "
|
|
123
|
+
exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME = "agent-key";
|
|
112
124
|
exports.GCP_CLOUD_AI_AGENT_SECRET_NAME = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}-key`;
|
|
113
125
|
/*
|
|
114
126
|
* The line that ends the key file's here-document in the Google Cloud
|
|
@@ -118,6 +130,12 @@ exports.GCP_CLOUD_AI_AGENT_SECRET_NAME = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_N
|
|
|
118
130
|
exports.GCP_CLOUD_AI_AGENT_KEY_FILE_END = "KEY ENDS";
|
|
119
131
|
// What lets the Google Cloud agent's service account read its one secret.
|
|
120
132
|
exports.GCP_SECRET_ACCESSOR_ROLE = "roles/secretmanager.secretAccessor";
|
|
133
|
+
/*
|
|
134
|
+
* What lets the agent's own service account ask for a token of the write
|
|
135
|
+
* account: granted on the write account alone, never the project, so it
|
|
136
|
+
* acts as no other account of the project.
|
|
137
|
+
*/
|
|
138
|
+
exports.GCP_TOKEN_CREATOR_ROLE = "roles/iam.serviceAccountTokenCreator";
|
|
121
139
|
/*
|
|
122
140
|
* Cloud Run checks, as it deploys, that the service account may read the
|
|
123
141
|
* key's secret, and access granted a moment before can take a minute or
|
|
@@ -200,6 +218,11 @@ exports.GCP_CLOUD_AI_AGENT_KEY_READER = [
|
|
|
200
218
|
// The role's title on Azure and Google Cloud.
|
|
201
219
|
const ROLE_TITLE = "OneUptime AI Agent";
|
|
202
220
|
const ROLE_DESCRIPTION = "What the OneUptime Cloud AI agent may change: the operations turned on for it";
|
|
221
|
+
// Google Cloud's second role: what the agent's own account reads.
|
|
222
|
+
const READER_ROLE_TITLE = "OneUptime AI Agent (reads)";
|
|
223
|
+
const READER_ROLE_DESCRIPTION = "What the OneUptime Cloud AI agent reads before and without a change; its changes run as its write account";
|
|
224
|
+
// Azure's second role: what the agent's own identity reads.
|
|
225
|
+
const AZURE_READER_ROLE_DESCRIPTION = "What the OneUptime Cloud AI agent reads before and without a change; its changes run as its write identity";
|
|
203
226
|
// The read every agent runs for Test connection.
|
|
204
227
|
const WHOAMI = "whoami";
|
|
205
228
|
// The cloud each CloudProvider is in the catalog, and the agent's resource type.
|
|
@@ -248,8 +271,6 @@ const TAG_KEY_PATTERN = /^[A-Za-z0-9][A-Za-z0-9_.:+@-]{0,127}$/;
|
|
|
248
271
|
const TAG_VALUE_PATTERN = /^[A-Za-z0-9_.:/+@-]{1,256}$/;
|
|
249
272
|
const GCP_LABEL_KEY_PATTERN = /^[a-z][a-z0-9_-]{0,62}$/;
|
|
250
273
|
const GCP_LABEL_VALUE_PATTERN = /^[a-z0-9_-]{1,63}$/;
|
|
251
|
-
// The longest ingestion key taken.
|
|
252
|
-
const MAX_INGESTION_KEY_LENGTH = 256;
|
|
253
274
|
function isLetterOrDigit(char) {
|
|
254
275
|
return ((char >= "a" && char <= "z") ||
|
|
255
276
|
(char >= "A" && char <= "Z") ||
|
|
@@ -271,8 +292,6 @@ function holdsOnly(value, others) {
|
|
|
271
292
|
* commands write holds one.
|
|
272
293
|
*/
|
|
273
294
|
const URL_CHARACTERS = "-._~:/?#[]@$&'()*+,;=%";
|
|
274
|
-
// What an ingestion key may hold.
|
|
275
|
-
const KEY_CHARACTERS = "-._~+/=:";
|
|
276
295
|
/*
|
|
277
296
|
* What a protected-target pattern may hold: what an ARN, an Azure resource
|
|
278
297
|
* ID or a Google Cloud resource name holds, and "*". Never a comma (the
|
|
@@ -421,18 +440,21 @@ function readSetup(options) {
|
|
|
421
440
|
if (urlProblem) {
|
|
422
441
|
return urlProblem;
|
|
423
442
|
}
|
|
424
|
-
const key = typeof options.ingestionKey === "string" ? options.ingestionKey.trim() : "";
|
|
425
|
-
if (!key ||
|
|
426
|
-
key.length > MAX_INGESTION_KEY_LENGTH ||
|
|
427
|
-
!holdsOnly(key, KEY_CHARACTERS)) {
|
|
428
|
-
return "The ingestion key is not one OneUptime issues: copy it again from Project Settings, under Telemetry Ingestion Keys.";
|
|
429
|
-
}
|
|
430
443
|
const cloudAccountId = typeof options.cloudAccountId === "string"
|
|
431
444
|
? options.cloudAccountId.trim().toLowerCase()
|
|
432
445
|
: "";
|
|
433
446
|
if (!UUID_PATTERN.test(cloudAccountId)) {
|
|
434
447
|
return "The cloud account's OneUptime id is not an id: open the account's page under Cloud → Accounts and set the agent up from there.";
|
|
435
448
|
}
|
|
449
|
+
// The account's own key, and this account's: no other key is written.
|
|
450
|
+
const key = typeof options.agentKey === "string" ? options.agentKey.trim() : "";
|
|
451
|
+
const parsedKey = (0, CloudAiAgentKey_1.parseCloudAiAgentKey)(key);
|
|
452
|
+
if (!parsedKey) {
|
|
453
|
+
return "The agent's key is not one OneUptime made: open Let AI fix problems on the account's page again, which makes a new one.";
|
|
454
|
+
}
|
|
455
|
+
if (parsedKey.cloudAccountId !== cloudAccountId) {
|
|
456
|
+
return "This key was made for another cloud account's agent: open Let AI fix problems on this account's own page, which makes one for it.";
|
|
457
|
+
}
|
|
436
458
|
const accountId = typeof options.accountId === "string"
|
|
437
459
|
? provider === CloudPlatform_1.CloudProvider.Azure
|
|
438
460
|
? options.accountId.trim().toLowerCase()
|
|
@@ -480,7 +502,7 @@ function readSetup(options) {
|
|
|
480
502
|
return {
|
|
481
503
|
provider,
|
|
482
504
|
oneuptimeUrl: url,
|
|
483
|
-
|
|
505
|
+
agentKey: key,
|
|
484
506
|
cloudAccountId,
|
|
485
507
|
accountId,
|
|
486
508
|
fixesMode: options.fixesMode,
|
|
@@ -524,6 +546,13 @@ function getCloudAiAgentImage(imageTag = exports.CLOUD_AI_AGENT_IMAGE_TAG) {
|
|
|
524
546
|
function getAwsCloudAiAgentWriteRoleArn(accountId) {
|
|
525
547
|
return `arn:aws:iam::${accountId}:role/${CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_WRITE_ROLE_NAME}`;
|
|
526
548
|
}
|
|
549
|
+
// The Google Cloud write account, whose token each change asks for.
|
|
550
|
+
function getGcpCloudAiAgentWriteServiceAccount(projectId) {
|
|
551
|
+
return (0, CloudAiAgentNames_1.getGcpServiceAccountEmail)({
|
|
552
|
+
serviceAccountId: CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_WRITE_SERVICE_ACCOUNT_ID,
|
|
553
|
+
projectId,
|
|
554
|
+
});
|
|
555
|
+
}
|
|
527
556
|
function environmentOf(setup) {
|
|
528
557
|
const variable = (name, value, isSecret = false) => {
|
|
529
558
|
return { name, value, isSecret };
|
|
@@ -531,7 +560,7 @@ function environmentOf(setup) {
|
|
|
531
560
|
const environment = [
|
|
532
561
|
variable(ResourceAiAccess_1.RESOURCE_AI_AGENT_RESOURCE_TYPE_ENV, AiResourceType_1.AI_RESOURCE_TYPE_INFO[RESOURCE_TYPES[setup.provider]].agentAlias),
|
|
533
562
|
variable(exports.CLOUD_AI_AGENT_ONEUPTIME_URL_ENV, setup.oneuptimeUrl),
|
|
534
|
-
variable(exports.
|
|
563
|
+
variable(exports.CLOUD_AI_AGENT_KEY_ENV, setup.agentKey, true),
|
|
535
564
|
variable(ResourceAiAccess_1.RESOURCE_AI_CLOUD_ACCOUNT_ID_ENV, setup.cloudAccountId),
|
|
536
565
|
variable(ResourceAiAccess_1.RESOURCE_AI_ALLOW_WRITES_ENV, "true"),
|
|
537
566
|
variable(AgentAiSettings_1.AI_INVESTIGATION_ENV, "true"),
|
|
@@ -550,10 +579,19 @@ function environmentOf(setup) {
|
|
|
550
579
|
if (setup.provider === CloudPlatform_1.CloudProvider.AWS) {
|
|
551
580
|
environment.push(variable(ResourceAiAccess_1.RESOURCE_AI_AWS_WRITE_ROLE_ARN_ENV, getAwsCloudAiAgentWriteRoleArn(setup.accountId)));
|
|
552
581
|
}
|
|
553
|
-
// The
|
|
582
|
+
// The account each change runs as, through a token for that change alone.
|
|
583
|
+
if (setup.provider === CloudPlatform_1.CloudProvider.GCP) {
|
|
584
|
+
environment.push(variable(ResourceAiAccess_1.RESOURCE_AI_GCP_WRITE_SERVICE_ACCOUNT_ENV, getGcpCloudAiAgentWriteServiceAccount(setup.accountId)));
|
|
585
|
+
}
|
|
586
|
+
/*
|
|
587
|
+
* The one subscription the agent acts in, so it never has to guess among
|
|
588
|
+
* several, and the identity each change runs as, with a token the agent
|
|
589
|
+
* asks for that change: by its resource ID, which names the subscription
|
|
590
|
+
* it belongs to and needs no lookup of an id Azure makes up.
|
|
591
|
+
*/
|
|
554
592
|
if (setup.provider === CloudPlatform_1.CloudProvider.Azure) {
|
|
555
593
|
environment.push(variable(AiResourceType_1.AI_RESOURCE_TYPE_INFO[AiResourceType_1.default.AzureSubscription]
|
|
556
|
-
.identityEnvVars[0], setup.accountId));
|
|
594
|
+
.identityEnvVars[0], setup.accountId), variable(ResourceAiAccess_1.RESOURCE_AI_AZURE_WRITE_IDENTITY_ENV, (0, CloudAiAgentNames_1.getAzureCloudAiAgentWriteIdentityId)(setup.accountId)));
|
|
557
595
|
}
|
|
558
596
|
/*
|
|
559
597
|
* Cloud Run starts an instance only once it accepts connections on its
|
|
@@ -572,7 +610,7 @@ function environmentOf(setup) {
|
|
|
572
610
|
}
|
|
573
611
|
/*
|
|
574
612
|
* Every variable the agent needs, for a team that runs it its own way: the
|
|
575
|
-
* same the cloud's command gives it. The
|
|
613
|
+
* same the cloud's command gives it. The agent's key is the one secret.
|
|
576
614
|
*/
|
|
577
615
|
function getCloudAiAgentEnvironment(options) {
|
|
578
616
|
return environmentOf(checkedSetup(options));
|
|
@@ -623,7 +661,22 @@ function getCloudAiAgentRolePermissions(provider, enabledOperations) {
|
|
|
623
661
|
const GCP_OPERATION_READS = [
|
|
624
662
|
["compute", ["compute.zoneOperations.get", "compute.regionOperations.get"]],
|
|
625
663
|
["run", ["run.operations.get"]],
|
|
664
|
+
["appengine", ["appengine.operations.get"]],
|
|
626
665
|
];
|
|
666
|
+
// The verbs of a Google Cloud permission (service.resource.verb) that only read.
|
|
667
|
+
const GCP_READ_VERBS = ["get", "list"];
|
|
668
|
+
/*
|
|
669
|
+
* What the Google Cloud agent's own service account holds: the reads of the
|
|
670
|
+
* changes turned on (what a dry run reads, and what the agent reads before
|
|
671
|
+
* a change to check it), never a change - each change runs as the write
|
|
672
|
+
* account (getCloudAiAgentRolePermissions), through a token for that change
|
|
673
|
+
* alone. Sorted, each once.
|
|
674
|
+
*/
|
|
675
|
+
function getGcpCloudAiAgentReaderPermissions(enabledOperations) {
|
|
676
|
+
return getCloudAiAgentRolePermissions(CloudPlatform_1.CloudProvider.GCP, enabledOperations).filter((permission) => {
|
|
677
|
+
return GCP_READ_VERBS.includes(permission.substring(permission.lastIndexOf(".") + 1));
|
|
678
|
+
});
|
|
679
|
+
}
|
|
627
680
|
/*
|
|
628
681
|
* What the agent reads to check a required tag where the resource's own
|
|
629
682
|
* read does not return its tags (a Lambda function's, an SQS queue's).
|
|
@@ -631,6 +684,8 @@ const GCP_OPERATION_READS = [
|
|
|
631
684
|
const AWS_TAG_READ_ACTIONS = [
|
|
632
685
|
"lambda:ListTags",
|
|
633
686
|
"sqs:ListQueueTags",
|
|
687
|
+
"apprunner:ListTagsForResource",
|
|
688
|
+
"elasticbeanstalk:ListTagsForResource",
|
|
634
689
|
];
|
|
635
690
|
// ---- AWS ------------------------------------------------------------------------
|
|
636
691
|
// CloudFormation's own values, for Fn::Sub.
|
|
@@ -694,12 +749,77 @@ function getAwsWritePolicy(setup) {
|
|
|
694
749
|
});
|
|
695
750
|
return { Version: "2012-10-17", Statement: statements };
|
|
696
751
|
}
|
|
697
|
-
|
|
752
|
+
// The own network: room for the one task, apart from every other range.
|
|
753
|
+
exports.AWS_CLOUD_AI_AGENT_VPC_CIDR = "10.249.0.0/24";
|
|
754
|
+
exports.AWS_CLOUD_AI_AGENT_SUBNET_CIDR = "10.249.0.0/28";
|
|
755
|
+
// The resources of the own network, by their logical ids.
|
|
756
|
+
function getAwsOwnNetworkResources() {
|
|
757
|
+
const tag = (name) => {
|
|
758
|
+
return [{ Key: "Name", Value: `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}-${name}` }];
|
|
759
|
+
};
|
|
760
|
+
return {
|
|
761
|
+
Vpc: {
|
|
762
|
+
Type: "AWS::EC2::VPC",
|
|
763
|
+
Properties: {
|
|
764
|
+
CidrBlock: exports.AWS_CLOUD_AI_AGENT_VPC_CIDR,
|
|
765
|
+
EnableDnsSupport: true,
|
|
766
|
+
EnableDnsHostnames: true,
|
|
767
|
+
Tags: tag("vpc"),
|
|
768
|
+
},
|
|
769
|
+
},
|
|
770
|
+
InternetGateway: {
|
|
771
|
+
Type: "AWS::EC2::InternetGateway",
|
|
772
|
+
Properties: { Tags: tag("igw") },
|
|
773
|
+
},
|
|
774
|
+
GatewayAttachment: {
|
|
775
|
+
Type: "AWS::EC2::VPCGatewayAttachment",
|
|
776
|
+
Properties: {
|
|
777
|
+
VpcId: { Ref: "Vpc" },
|
|
778
|
+
InternetGatewayId: { Ref: "InternetGateway" },
|
|
779
|
+
},
|
|
780
|
+
},
|
|
781
|
+
Subnet: {
|
|
782
|
+
Type: "AWS::EC2::Subnet",
|
|
783
|
+
Properties: {
|
|
784
|
+
VpcId: { Ref: "Vpc" },
|
|
785
|
+
CidrBlock: exports.AWS_CLOUD_AI_AGENT_SUBNET_CIDR,
|
|
786
|
+
AvailabilityZone: { "Fn::Select": [0, { "Fn::GetAZs": "" }] },
|
|
787
|
+
MapPublicIpOnLaunch: false,
|
|
788
|
+
Tags: tag("subnet"),
|
|
789
|
+
},
|
|
790
|
+
},
|
|
791
|
+
RouteTable: {
|
|
792
|
+
Type: "AWS::EC2::RouteTable",
|
|
793
|
+
Properties: { VpcId: { Ref: "Vpc" }, Tags: tag("routes") },
|
|
794
|
+
},
|
|
795
|
+
// Out to OneUptime, the AWS APIs and the image registry; nothing comes in.
|
|
796
|
+
InternetRoute: {
|
|
797
|
+
Type: "AWS::EC2::Route",
|
|
798
|
+
DependsOn: "GatewayAttachment",
|
|
799
|
+
Properties: {
|
|
800
|
+
RouteTableId: { Ref: "RouteTable" },
|
|
801
|
+
DestinationCidrBlock: "0.0.0.0/0",
|
|
802
|
+
GatewayId: { Ref: "InternetGateway" },
|
|
803
|
+
},
|
|
804
|
+
},
|
|
805
|
+
SubnetRoutes: {
|
|
806
|
+
Type: "AWS::EC2::SubnetRouteTableAssociation",
|
|
807
|
+
Properties: {
|
|
808
|
+
SubnetId: { Ref: "Subnet" },
|
|
809
|
+
RouteTableId: { Ref: "RouteTable" },
|
|
810
|
+
},
|
|
811
|
+
},
|
|
812
|
+
};
|
|
813
|
+
}
|
|
814
|
+
function getAwsTemplate(setup, network = "default-vpc") {
|
|
815
|
+
const isOwnNetwork = network === "own-vpc";
|
|
698
816
|
/*
|
|
699
817
|
* The key is a parameter, never in the template, and reaches the task
|
|
700
818
|
* from Secrets Manager (Secrets), never as one of its variables: those
|
|
701
819
|
* are shown to anyone who may describe the task definition. The write
|
|
702
|
-
* role's ARN is the role's own.
|
|
820
|
+
* role's ARN is the role's own. In an organization's template the
|
|
821
|
+
* OneUptime cloud account the agent is for is a parameter too: each
|
|
822
|
+
* account's stack names its own.
|
|
703
823
|
*/
|
|
704
824
|
const containerEnvironment = environmentOf(setup)
|
|
705
825
|
.filter((variable) => {
|
|
@@ -712,6 +832,9 @@ function getAwsTemplate(setup) {
|
|
|
712
832
|
Value: { "Fn::GetAtt": ["WriteRole", "Arn"] },
|
|
713
833
|
};
|
|
714
834
|
}
|
|
835
|
+
if (isOwnNetwork && variable.name === ResourceAiAccess_1.RESOURCE_AI_CLOUD_ACCOUNT_ID_ENV) {
|
|
836
|
+
return { Name: variable.name, Value: { Ref: "CloudAccountId" } };
|
|
837
|
+
}
|
|
715
838
|
return { Name: variable.name, Value: variable.value };
|
|
716
839
|
});
|
|
717
840
|
const containerSecrets = environmentOf(setup)
|
|
@@ -719,52 +842,66 @@ function getAwsTemplate(setup) {
|
|
|
719
842
|
return variable.isSecret;
|
|
720
843
|
})
|
|
721
844
|
.map((variable) => {
|
|
722
|
-
return { Name: variable.name, ValueFrom: { Ref: "
|
|
845
|
+
return { Name: variable.name, ValueFrom: { Ref: "AgentKeySecret" } };
|
|
723
846
|
});
|
|
724
847
|
const size = exports.CLOUD_AI_AGENT_SIZES[CloudPlatform_1.CloudProvider.AWS];
|
|
725
848
|
const ecsTasks = { Service: "ecs-tasks.amazonaws.com" };
|
|
726
849
|
return {
|
|
727
850
|
AWSTemplateFormatVersion: "2010-09-09",
|
|
728
|
-
Description:
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
851
|
+
Description: isOwnNetwork
|
|
852
|
+
? "OneUptime Cloud AI agent, in every account of an AWS Organization: one ECS Fargate task in a small network of its own that makes the changes OneUptime AI asks for in its account, with a role that holds only the operations turned on for it."
|
|
853
|
+
: "OneUptime Cloud AI agent: one ECS Fargate task that makes the changes OneUptime AI asks for in this account, with a role that holds only the operations turned on for it.",
|
|
854
|
+
Parameters: Object.assign(Object.assign(Object.assign({}, (isOwnNetwork
|
|
855
|
+
? {}
|
|
856
|
+
: {
|
|
857
|
+
VpcId: {
|
|
858
|
+
Type: "AWS::EC2::VPC::Id",
|
|
859
|
+
Description: "The VPC the agent runs in: the Region's default VPC.",
|
|
860
|
+
},
|
|
861
|
+
SubnetIds: {
|
|
862
|
+
Type: "List<AWS::EC2::Subnet::Id>",
|
|
863
|
+
Description: "The default VPC's default subnets.",
|
|
864
|
+
},
|
|
865
|
+
})), { AgentKey: {
|
|
739
866
|
Type: "String",
|
|
740
867
|
NoEcho: true,
|
|
741
868
|
MinLength: 1,
|
|
742
|
-
Description: "The
|
|
743
|
-
},
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
869
|
+
Description: "The key the agent registers with: this account's own, which connects its agent and nothing else.",
|
|
870
|
+
} }), (isOwnNetwork
|
|
871
|
+
? {
|
|
872
|
+
CloudAccountId: {
|
|
873
|
+
Type: "String",
|
|
874
|
+
MinLength: 1,
|
|
875
|
+
Description: "The OneUptime cloud account this account's agent is for: the one its key names.",
|
|
876
|
+
},
|
|
877
|
+
}
|
|
878
|
+
: {})),
|
|
879
|
+
Resources: Object.assign(Object.assign({}, (isOwnNetwork ? getAwsOwnNetworkResources() : {})), { Cluster: {
|
|
747
880
|
Type: "AWS::ECS::Cluster",
|
|
748
881
|
Properties: {
|
|
749
882
|
ClusterName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_CLUSTER_NAME,
|
|
750
883
|
ClusterSettings: [{ Name: "containerInsights", Value: "disabled" }],
|
|
751
884
|
},
|
|
752
|
-
},
|
|
753
|
-
LogGroup: {
|
|
885
|
+
}, LogGroup: {
|
|
754
886
|
Type: "AWS::Logs::LogGroup",
|
|
755
887
|
Properties: {
|
|
756
888
|
LogGroupName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_LOG_GROUP_NAME,
|
|
757
889
|
RetentionInDays: exports.AWS_CLOUD_AI_AGENT_LOG_RETENTION_DAYS,
|
|
758
890
|
},
|
|
759
|
-
},
|
|
760
|
-
|
|
761
|
-
|
|
891
|
+
},
|
|
892
|
+
/*
|
|
893
|
+
* The key the agent registers with, which only ECS reads, as the task
|
|
894
|
+
* starts. A secret of its own name: the one an earlier version of this
|
|
895
|
+
* template kept the project's ingestion key in (IngestionKeySecret) is
|
|
896
|
+
* removed with the update that makes this one.
|
|
897
|
+
*/
|
|
898
|
+
AgentKeySecret: {
|
|
762
899
|
Type: "AWS::SecretsManager::Secret",
|
|
763
900
|
Properties: {
|
|
764
|
-
Description: "The
|
|
765
|
-
SecretString: { Ref: "
|
|
901
|
+
Description: "The key the OneUptime Cloud AI agent registers with: this account's own.",
|
|
902
|
+
SecretString: { Ref: "AgentKey" },
|
|
766
903
|
},
|
|
767
|
-
},
|
|
904
|
+
},
|
|
768
905
|
// What ECS pulls the image, writes the logs and reads the key with.
|
|
769
906
|
ExecutionRole: {
|
|
770
907
|
Type: "AWS::IAM::Role",
|
|
@@ -786,21 +923,21 @@ function getAwsTemplate(setup) {
|
|
|
786
923
|
],
|
|
787
924
|
Policies: [
|
|
788
925
|
{
|
|
789
|
-
PolicyName: "
|
|
926
|
+
PolicyName: "ReadTheAgentKey",
|
|
790
927
|
PolicyDocument: {
|
|
791
928
|
Version: "2012-10-17",
|
|
792
929
|
Statement: [
|
|
793
930
|
{
|
|
794
931
|
Effect: "Allow",
|
|
795
932
|
Action: "secretsmanager:GetSecretValue",
|
|
796
|
-
Resource: { Ref: "
|
|
933
|
+
Resource: { Ref: "AgentKeySecret" },
|
|
797
934
|
},
|
|
798
935
|
],
|
|
799
936
|
},
|
|
800
937
|
},
|
|
801
938
|
],
|
|
802
939
|
},
|
|
803
|
-
},
|
|
940
|
+
},
|
|
804
941
|
// The agent's own credentials: they can only assume the write role.
|
|
805
942
|
TaskRole: {
|
|
806
943
|
Type: "AWS::IAM::Role",
|
|
@@ -845,7 +982,7 @@ function getAwsTemplate(setup) {
|
|
|
845
982
|
},
|
|
846
983
|
],
|
|
847
984
|
},
|
|
848
|
-
},
|
|
985
|
+
},
|
|
849
986
|
// What a change runs as, assumed once per job with that job's session policy.
|
|
850
987
|
WriteRole: {
|
|
851
988
|
Type: "AWS::IAM::Role",
|
|
@@ -868,13 +1005,13 @@ function getAwsTemplate(setup) {
|
|
|
868
1005
|
},
|
|
869
1006
|
],
|
|
870
1007
|
},
|
|
871
|
-
},
|
|
1008
|
+
},
|
|
872
1009
|
// Nothing comes in: the agent asks OneUptime for its work.
|
|
873
1010
|
SecurityGroup: {
|
|
874
1011
|
Type: "AWS::EC2::SecurityGroup",
|
|
875
1012
|
Properties: {
|
|
876
1013
|
GroupDescription: "OneUptime Cloud AI agent: outbound only",
|
|
877
|
-
VpcId: { Ref: "VpcId" },
|
|
1014
|
+
VpcId: { Ref: isOwnNetwork ? "Vpc" : "VpcId" },
|
|
878
1015
|
SecurityGroupEgress: [
|
|
879
1016
|
{
|
|
880
1017
|
IpProtocol: "-1",
|
|
@@ -883,8 +1020,7 @@ function getAwsTemplate(setup) {
|
|
|
883
1020
|
},
|
|
884
1021
|
],
|
|
885
1022
|
},
|
|
886
|
-
},
|
|
887
|
-
TaskDefinition: {
|
|
1023
|
+
}, TaskDefinition: {
|
|
888
1024
|
Type: "AWS::ECS::TaskDefinition",
|
|
889
1025
|
Properties: {
|
|
890
1026
|
Family: CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME,
|
|
@@ -916,10 +1052,9 @@ function getAwsTemplate(setup) {
|
|
|
916
1052
|
},
|
|
917
1053
|
],
|
|
918
1054
|
},
|
|
919
|
-
},
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
Properties: {
|
|
1055
|
+
}, Service: Object.assign(Object.assign({ Type: "AWS::ECS::Service" }, (isOwnNetwork
|
|
1056
|
+
? { DependsOn: ["InternetRoute", "SubnetRoutes"] }
|
|
1057
|
+
: {})), { Properties: {
|
|
923
1058
|
ServiceName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_SERVICE_NAME,
|
|
924
1059
|
Cluster: { Ref: "Cluster" },
|
|
925
1060
|
TaskDefinition: { Ref: "TaskDefinition" },
|
|
@@ -942,13 +1077,13 @@ function getAwsTemplate(setup) {
|
|
|
942
1077
|
* a NAT gateway. The security group still lets nothing in.
|
|
943
1078
|
*/
|
|
944
1079
|
AssignPublicIp: "ENABLED",
|
|
945
|
-
Subnets:
|
|
1080
|
+
Subnets: isOwnNetwork
|
|
1081
|
+
? [{ Ref: "Subnet" }]
|
|
1082
|
+
: { Ref: "SubnetIds" },
|
|
946
1083
|
SecurityGroups: [{ "Fn::GetAtt": ["SecurityGroup", "GroupId"] }],
|
|
947
1084
|
},
|
|
948
1085
|
},
|
|
949
|
-
},
|
|
950
|
-
},
|
|
951
|
-
},
|
|
1086
|
+
} }) }),
|
|
952
1087
|
Outputs: {
|
|
953
1088
|
WriteRoleArn: { Value: { "Fn::GetAtt": ["WriteRole", "Arn"] } },
|
|
954
1089
|
},
|
|
@@ -957,7 +1092,7 @@ function getAwsTemplate(setup) {
|
|
|
957
1092
|
/*
|
|
958
1093
|
* The CloudFormation template the AWS command deploys, as JSON: also what a
|
|
959
1094
|
* team that keeps its infrastructure in CloudFormation deploys itself, with
|
|
960
|
-
* VpcId, SubnetIds and
|
|
1095
|
+
* VpcId, SubnetIds and AgentKey as its parameters.
|
|
961
1096
|
*/
|
|
962
1097
|
function getAwsCloudAiAgentTemplate(options) {
|
|
963
1098
|
return JSON.stringify(getAwsTemplate(checkedSetup(options, CloudPlatform_1.CloudProvider.AWS)));
|
|
@@ -989,10 +1124,253 @@ function writeAwsCommand(setup) {
|
|
|
989
1124
|
` echo "This Region has no default VPC with default subnets for the agent to run in. Run the command in a Region that has one, or create it with: aws ec2 create-default-vpc"`,
|
|
990
1125
|
"else",
|
|
991
1126
|
` [ "$(aws cloudformation describe-stacks ${stack} --query "Stacks[0].StackStatus" --output text 2> /dev/null)" = ROLLBACK_COMPLETE ] && aws cloudformation delete-stack ${stack} && aws cloudformation wait stack-delete-complete ${stack}`,
|
|
992
|
-
` aws cloudformation deploy ${stack} --template-file ${exports.AWS_CLOUD_AI_AGENT_TEMPLATE_FILE} --capabilities CAPABILITY_NAMED_IAM --no-fail-on-empty-changeset --parameter-overrides VpcId="$VPC" SubnetIds="$SUBNETS"
|
|
1127
|
+
` aws cloudformation deploy ${stack} --template-file ${exports.AWS_CLOUD_AI_AGENT_TEMPLATE_FILE} --capabilities CAPABILITY_NAMED_IAM --no-fail-on-empty-changeset --parameter-overrides VpcId="$VPC" SubnetIds="$SUBNETS" AgentKey=${(0, ShellWord_1.shellQuote)(setup.agentKey)} && echo "${exports.CLOUD_AI_AGENT_STARTED_MESSAGE}"`,
|
|
993
1128
|
"fi",
|
|
994
1129
|
].join("\n");
|
|
995
1130
|
}
|
|
1131
|
+
// ---- AWS: every account of an organization -----------------------------------------
|
|
1132
|
+
/*
|
|
1133
|
+
* EVERY ACCOUNT OF AN AWS ORGANIZATION, IN ONE COMMAND.
|
|
1134
|
+
*
|
|
1135
|
+
* An organization read by one cloud connection (its management account's
|
|
1136
|
+
* role, and the same role in each member account) has one OneUptime cloud
|
|
1137
|
+
* account per AWS account. Setting each one's agent up by hand would be one
|
|
1138
|
+
* command per account; this is one command for all of them, run in the
|
|
1139
|
+
* management account's CloudShell:
|
|
1140
|
+
*
|
|
1141
|
+
* - every agent runs the same template as one account's, with the same
|
|
1142
|
+
* least-privilege roles - the task role that may only assume the write
|
|
1143
|
+
* role, the write role holding the changes turned on - in a small
|
|
1144
|
+
* network of its own (AwsCloudAiAgentNetwork "own-vpc"), since a member
|
|
1145
|
+
* account's default VPC cannot be looked up from the management account
|
|
1146
|
+
* and is often gone;
|
|
1147
|
+
* - each account's agent still registers with a key of its own cloud
|
|
1148
|
+
* account's, made for it when the dialog asks for the organization's
|
|
1149
|
+
* keys, exactly as one account's is: a StackSet instance per member
|
|
1150
|
+
* account carries its key (AgentKey, NoEcho) and the OneUptime cloud
|
|
1151
|
+
* account it is for (CloudAccountId) as parameter overrides, so an
|
|
1152
|
+
* agent's key connects that account's agent and nothing else, and the
|
|
1153
|
+
* registration's checks hold it to that account as before - the key
|
|
1154
|
+
* names its cloud account, and the agent's own AWS account must be that
|
|
1155
|
+
* account's;
|
|
1156
|
+
* - the member accounts' stacks come from one StackSet
|
|
1157
|
+
* (AWS_CLOUD_AI_AGENT_STACK_SET_NAME, AwsStackSets), deployed one
|
|
1158
|
+
* account at a time with its own overrides; accounts added to the
|
|
1159
|
+
* organization later are not set up on their own (their keys do not
|
|
1160
|
+
* exist yet): run the command again once OneUptime reads them;
|
|
1161
|
+
* - the management account, which StackSets never deploys to, gets the
|
|
1162
|
+
* same template as a stack of its own, when it is one of the accounts;
|
|
1163
|
+
* - every agent runs in one Region, the StackSet's home: the one chosen,
|
|
1164
|
+
* or US East (N. Virginia) - not CloudShell's, so running the command
|
|
1165
|
+
* again from anywhere finds the StackSet it made.
|
|
1166
|
+
*
|
|
1167
|
+
* Only the accounts the command is given are set up: the dialog names the
|
|
1168
|
+
* ones it could make keys for, and says why it left any out.
|
|
1169
|
+
*/
|
|
1170
|
+
// The most accounts one command sets up: one StackSet operation each.
|
|
1171
|
+
exports.CLOUD_AI_AGENT_ORGANIZATION_MAX_ACCOUNTS = 500;
|
|
1172
|
+
// What the organization's command writes in the shell's directory.
|
|
1173
|
+
exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_TEMPLATE_FILE = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}-organization.json`;
|
|
1174
|
+
exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_ACCOUNTS_FILE = `${CloudAiAgentNames_1.CLOUD_AI_AGENT_NAME}-accounts.txt`;
|
|
1175
|
+
// The shell variable the agents' Region is in: the StackSet's home too.
|
|
1176
|
+
const AGENT_REGION_VARIABLE = "AGENT_REGION";
|
|
1177
|
+
const AGENT_REGION = `"$${AGENT_REGION_VARIABLE}"`;
|
|
1178
|
+
function readOrganizationSetup(options) {
|
|
1179
|
+
if (!options || typeof options !== "object") {
|
|
1180
|
+
return "Say which accounts of the organization the agents are for.";
|
|
1181
|
+
}
|
|
1182
|
+
const management = typeof options.managementAccountId === "string"
|
|
1183
|
+
? options.managementAccountId.trim()
|
|
1184
|
+
: "";
|
|
1185
|
+
if (!ACCOUNT_ID_PATTERNS[CloudPlatform_1.CloudProvider.AWS].test(management)) {
|
|
1186
|
+
return `${JSON.stringify(management.slice(0, 64))} is not the AWS account id (12 digits) of the organization's management account.`;
|
|
1187
|
+
}
|
|
1188
|
+
const accounts = Array.isArray(options.accounts)
|
|
1189
|
+
? options.accounts
|
|
1190
|
+
: [];
|
|
1191
|
+
if (accounts.length === 0) {
|
|
1192
|
+
return "No account of the organization has a key for its agent yet: open Let AI fix problems again, which makes them.";
|
|
1193
|
+
}
|
|
1194
|
+
if (accounts.length > exports.CLOUD_AI_AGENT_ORGANIZATION_MAX_ACCOUNTS) {
|
|
1195
|
+
return `${accounts.length} accounts are more than one command sets up: at most ${exports.CLOUD_AI_AGENT_ORGANIZATION_MAX_ACCOUNTS}.`;
|
|
1196
|
+
}
|
|
1197
|
+
const setups = [];
|
|
1198
|
+
const seen = new Set();
|
|
1199
|
+
for (const account of accounts) {
|
|
1200
|
+
const setup = readSetup({
|
|
1201
|
+
provider: CloudPlatform_1.CloudProvider.AWS,
|
|
1202
|
+
oneuptimeUrl: options.oneuptimeUrl,
|
|
1203
|
+
agentKey: account && account.agentKey,
|
|
1204
|
+
cloudAccountId: account && account.cloudAccountId,
|
|
1205
|
+
accountId: account && account.accountId,
|
|
1206
|
+
fixesMode: options.fixesMode,
|
|
1207
|
+
enabledOperations: options.enabledOperations,
|
|
1208
|
+
protectedTargets: options.protectedTargets,
|
|
1209
|
+
requiredTag: options.requiredTag,
|
|
1210
|
+
region: options.region,
|
|
1211
|
+
imageTag: options.imageTag,
|
|
1212
|
+
});
|
|
1213
|
+
if (typeof setup === "string") {
|
|
1214
|
+
return setup;
|
|
1215
|
+
}
|
|
1216
|
+
if (seen.has(setup.accountId)) {
|
|
1217
|
+
return `AWS account ${setup.accountId} is named twice: each account gets one agent.`;
|
|
1218
|
+
}
|
|
1219
|
+
seen.add(setup.accountId);
|
|
1220
|
+
setups.push(setup);
|
|
1221
|
+
}
|
|
1222
|
+
return {
|
|
1223
|
+
managementAccountId: management,
|
|
1224
|
+
shared: setups[0],
|
|
1225
|
+
members: setups.filter((setup) => {
|
|
1226
|
+
return setup.accountId !== management;
|
|
1227
|
+
}),
|
|
1228
|
+
management: setups.find((setup) => {
|
|
1229
|
+
return setup.accountId === management;
|
|
1230
|
+
}) || null,
|
|
1231
|
+
};
|
|
1232
|
+
}
|
|
1233
|
+
/*
|
|
1234
|
+
* What is wrong with the organization's options, in words the dialog can
|
|
1235
|
+
* show, or null when its command can be written.
|
|
1236
|
+
*/
|
|
1237
|
+
function describeCloudAiAgentOrganizationSetupProblem(options) {
|
|
1238
|
+
const setup = readOrganizationSetup(options);
|
|
1239
|
+
return typeof setup === "string" ? setup : null;
|
|
1240
|
+
}
|
|
1241
|
+
function checkedOrganizationSetup(options) {
|
|
1242
|
+
const setup = readOrganizationSetup(options);
|
|
1243
|
+
if (typeof setup === "string") {
|
|
1244
|
+
throw new BadDataException_1.default(setup);
|
|
1245
|
+
}
|
|
1246
|
+
return setup;
|
|
1247
|
+
}
|
|
1248
|
+
/*
|
|
1249
|
+
* The template every account of the organization runs, as JSON: one
|
|
1250
|
+
* account's, in a network of its own, with the agent's key and its
|
|
1251
|
+
* OneUptime cloud account as parameters (AgentKey, CloudAccountId). Also
|
|
1252
|
+
* what a team that keeps its StackSets in code deploys itself.
|
|
1253
|
+
*/
|
|
1254
|
+
function getAwsOrganizationCloudAiAgentTemplate(options) {
|
|
1255
|
+
return JSON.stringify(getAwsTemplate(checkedOrganizationSetup(options).shared, "own-vpc"));
|
|
1256
|
+
}
|
|
1257
|
+
// What the command says when it is pasted into another account's shell.
|
|
1258
|
+
function getCloudAiAgentOrganizationWrongAccountMessage(managementAccountId) {
|
|
1259
|
+
return `This command is for your AWS Organization's management account ${managementAccountId}, and this shell is signed in to another one. Open CloudShell in AWS account ${managementAccountId} and run the command there.`;
|
|
1260
|
+
}
|
|
1261
|
+
// What it prints once every account's stack is on its way.
|
|
1262
|
+
function getCloudAiAgentOrganizationStartedMessage(count) {
|
|
1263
|
+
return `The Cloud AI agents are starting in ${count} ${count === 1 ? "account" : "accounts"}. Each connects to OneUptime on its own, so there is nothing to paste back: the dialog shows which have.`;
|
|
1264
|
+
}
|
|
1265
|
+
// What it says of an account StackSets would not take.
|
|
1266
|
+
exports.CLOUD_AI_AGENT_ORGANIZATION_ACCOUNT_FAILED_MESSAGE = "StackSets did not take the agent's stack for this account; the other accounts go on.";
|
|
1267
|
+
// The line that sets AGENT_REGION: the Region chosen, or the StackSet's default home.
|
|
1268
|
+
function getOrganizationRegionLine(region) {
|
|
1269
|
+
return (0, AwsStackSets_1.getAwsStackSetHomeRegionLine)({
|
|
1270
|
+
variable: AGENT_REGION_VARIABLE,
|
|
1271
|
+
region,
|
|
1272
|
+
});
|
|
1273
|
+
}
|
|
1274
|
+
/*
|
|
1275
|
+
* A Region the person chose, as the commands write it, or null: one that
|
|
1276
|
+
* is not an AWS Region is left out.
|
|
1277
|
+
*/
|
|
1278
|
+
function readOrganizationRegion(region) {
|
|
1279
|
+
const text = typeof region === "string" ? region.trim() : "";
|
|
1280
|
+
return text && REGION_PATTERNS[CloudPlatform_1.CloudProvider.AWS].test(text) ? text : null;
|
|
1281
|
+
}
|
|
1282
|
+
/*
|
|
1283
|
+
* AWS, in the management account's CloudShell: the template and the
|
|
1284
|
+
* accounts' keys written to files the shell does not expand, then - in the
|
|
1285
|
+
* management account, and only there - StackSets' access to the
|
|
1286
|
+
* organization, the StackSet, one instance per member account with its own
|
|
1287
|
+
* key, and the management account's own stack when it is one of the
|
|
1288
|
+
* accounts. The accounts' file is removed once read.
|
|
1289
|
+
*/
|
|
1290
|
+
function getAwsOrganizationCloudAiAgentSetupCommand(options) {
|
|
1291
|
+
const setup = checkedOrganizationSetup(options);
|
|
1292
|
+
const template = exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_TEMPLATE_FILE;
|
|
1293
|
+
const accountsFile = exports.AWS_CLOUD_AI_AGENT_ORGANIZATION_ACCOUNTS_FILE;
|
|
1294
|
+
const managementStack = `--stack-name ${CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_NAME} --region ${AGENT_REGION}`;
|
|
1295
|
+
const lines = [
|
|
1296
|
+
"ACCOUNT=$(aws sts get-caller-identity --query Account --output text)",
|
|
1297
|
+
`cat > ${template} <<'TEMPLATE'`,
|
|
1298
|
+
JSON.stringify(getAwsTemplate(setup.shared, "own-vpc")),
|
|
1299
|
+
"TEMPLATE",
|
|
1300
|
+
`cat > ${accountsFile} <<'ACCOUNTS'`,
|
|
1301
|
+
...setup.members.map((member) => {
|
|
1302
|
+
return `${member.accountId} ${member.cloudAccountId} ${member.agentKey}`;
|
|
1303
|
+
}),
|
|
1304
|
+
"ACCOUNTS",
|
|
1305
|
+
`if [ "$ACCOUNT" != ${setup.managementAccountId} ]; then`,
|
|
1306
|
+
` echo "${getCloudAiAgentOrganizationWrongAccountMessage(setup.managementAccountId)}"`,
|
|
1307
|
+
"else",
|
|
1308
|
+
` ${getOrganizationRegionLine(setup.shared.region)}`,
|
|
1309
|
+
];
|
|
1310
|
+
if (setup.members.length > 0) {
|
|
1311
|
+
lines.push(...(0, AwsStackSets_1.getAwsOrganizationStartLines)().map((line) => {
|
|
1312
|
+
return ` ${line}`;
|
|
1313
|
+
}), ` ${(0, AwsStackSets_1.getAwsStackSetDeployLine)({
|
|
1314
|
+
stackSetName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_SET_NAME,
|
|
1315
|
+
homeRegion: AGENT_REGION,
|
|
1316
|
+
templateFile: template,
|
|
1317
|
+
stackSetDescription: "OneUptime Cloud AI agent: the agent of each account of the organization, with its own key.",
|
|
1318
|
+
capabilities: "CAPABILITY_NAMED_IAM",
|
|
1319
|
+
parameters: [
|
|
1320
|
+
{ key: "AgentKey", value: null },
|
|
1321
|
+
{ key: "CloudAccountId", value: null },
|
|
1322
|
+
],
|
|
1323
|
+
autoDeployment: false,
|
|
1324
|
+
})}`,
|
|
1325
|
+
// One account a line: its id, its OneUptime cloud account, its key (fd 3, so no call reads them).
|
|
1326
|
+
" while read -r MEMBER CLOUD_ACCOUNT KEY <&3; do", ` ${(0, AwsStackSets_1.getAwsStackSetOneAccountLine)({
|
|
1327
|
+
stackSetName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_SET_NAME,
|
|
1328
|
+
homeRegion: AGENT_REGION,
|
|
1329
|
+
accountVariable: "MEMBER",
|
|
1330
|
+
region: AGENT_REGION,
|
|
1331
|
+
overrides: [
|
|
1332
|
+
{ key: "AgentKey", shellVariable: "KEY" },
|
|
1333
|
+
{ key: "CloudAccountId", shellVariable: "CLOUD_ACCOUNT" },
|
|
1334
|
+
],
|
|
1335
|
+
failedMessage: exports.CLOUD_AI_AGENT_ORGANIZATION_ACCOUNT_FAILED_MESSAGE,
|
|
1336
|
+
})}`, ` done 3< ${accountsFile}`);
|
|
1337
|
+
}
|
|
1338
|
+
// The management account, which StackSets never deploys to: a stack of its own.
|
|
1339
|
+
if (setup.management) {
|
|
1340
|
+
lines.push(` [ "$(aws cloudformation describe-stacks ${managementStack} --query "Stacks[0].StackStatus" --output text 2> /dev/null)" = ROLLBACK_COMPLETE ] && aws cloudformation delete-stack ${managementStack} && aws cloudformation wait stack-delete-complete ${managementStack}`, ` aws cloudformation deploy ${managementStack} --template-file ${template} --capabilities CAPABILITY_NAMED_IAM --no-fail-on-empty-changeset --parameter-overrides AgentKey=${(0, ShellWord_1.shellQuote)(setup.management.agentKey)} CloudAccountId=${setup.management.cloudAccountId} > /dev/null || echo "${setup.managementAccountId}: ${exports.CLOUD_AI_AGENT_ORGANIZATION_ACCOUNT_FAILED_MESSAGE}"`);
|
|
1341
|
+
}
|
|
1342
|
+
lines.push(` echo "${getCloudAiAgentOrganizationStartedMessage(setup.members.length + (setup.management ? 1 : 0))}"`, "fi", `rm -f ${accountsFile}`);
|
|
1343
|
+
return lines.join("\n");
|
|
1344
|
+
}
|
|
1345
|
+
/*
|
|
1346
|
+
* Where each member account's stack stands - its status and, for one that
|
|
1347
|
+
* failed, why - in the management account's CloudShell.
|
|
1348
|
+
*/
|
|
1349
|
+
function getAwsOrganizationCloudAiAgentInstancesCommand(region) {
|
|
1350
|
+
return [
|
|
1351
|
+
getOrganizationRegionLine(readOrganizationRegion(region)),
|
|
1352
|
+
(0, AwsStackSets_1.getAwsStackSetInstancesCommand)({
|
|
1353
|
+
stackSetName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_SET_NAME,
|
|
1354
|
+
homeRegion: AGENT_REGION,
|
|
1355
|
+
}),
|
|
1356
|
+
].join("\n");
|
|
1357
|
+
}
|
|
1358
|
+
/*
|
|
1359
|
+
* Every account's agent removed, in the management account's CloudShell:
|
|
1360
|
+
* each member account's stack and then the StackSet, then the management
|
|
1361
|
+
* account's own stack. Their keys stop working with Reset agent.
|
|
1362
|
+
*/
|
|
1363
|
+
function getAwsOrganizationCloudAiAgentRemoveCommand(region) {
|
|
1364
|
+
return [
|
|
1365
|
+
getOrganizationRegionLine(readOrganizationRegion(region)),
|
|
1366
|
+
...(0, AwsStackSets_1.getAwsStackSetDeleteLines)({
|
|
1367
|
+
stackSetName: CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_SET_NAME,
|
|
1368
|
+
homeRegion: AGENT_REGION,
|
|
1369
|
+
regions: AGENT_REGION,
|
|
1370
|
+
}),
|
|
1371
|
+
`aws cloudformation delete-stack --stack-name ${CloudAiAgentNames_1.AWS_CLOUD_AI_AGENT_STACK_NAME} --region ${AGENT_REGION}`,
|
|
1372
|
+
].join("\n");
|
|
1373
|
+
}
|
|
996
1374
|
// ---- Azure ----------------------------------------------------------------------
|
|
997
1375
|
/*
|
|
998
1376
|
* Custom role names are unique in a whole tenant, so each subscription's
|
|
@@ -1002,11 +1380,29 @@ function writeAwsCommand(setup) {
|
|
|
1002
1380
|
function getAzureCloudAiAgentRoleName(subscriptionId) {
|
|
1003
1381
|
return `${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_ROLE_NAME} (${subscriptionId.trim().toLowerCase()})`;
|
|
1004
1382
|
}
|
|
1383
|
+
// The agent's own identity's role: the same, for the reads alone.
|
|
1384
|
+
function getAzureCloudAiAgentReaderRoleName(subscriptionId) {
|
|
1385
|
+
return `${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_READER_ROLE_NAME} (${subscriptionId.trim().toLowerCase()})`;
|
|
1386
|
+
}
|
|
1387
|
+
// An Azure RBAC action that only reads (Microsoft.Web/sites/read).
|
|
1388
|
+
function isAzureReadAction(action) {
|
|
1389
|
+
return action.toLowerCase().endsWith("/read");
|
|
1390
|
+
}
|
|
1391
|
+
/*
|
|
1392
|
+
* What the Azure agent's own identity holds: the reads of the changes
|
|
1393
|
+
* turned on (what a dry run reads, and Test connection's read of the
|
|
1394
|
+
* subscription), never a change - each change runs as the write identity
|
|
1395
|
+
* (getCloudAiAgentRolePermissions), signed in for that change. Sorted,
|
|
1396
|
+
* each once.
|
|
1397
|
+
*/
|
|
1398
|
+
function getAzureCloudAiAgentReaderPermissions(enabledOperations) {
|
|
1399
|
+
return getCloudAiAgentRolePermissions(CloudPlatform_1.CloudProvider.Azure, enabledOperations).filter(isAzureReadAction);
|
|
1400
|
+
}
|
|
1005
1401
|
/*
|
|
1006
1402
|
* The custom role, as `az role definition create` and `update` take it:
|
|
1007
|
-
* the operations' actions on the one subscription
|
|
1008
|
-
* agent's own resource group out of
|
|
1009
|
-
* protects it (getCloudAiAgentOwnTargets).
|
|
1403
|
+
* the operations' actions on the one subscription - what the write
|
|
1404
|
+
* identity holds. RBAC cannot leave the agent's own resource group out of
|
|
1405
|
+
* a subscription's role; the agent protects it (getCloudAiAgentOwnTargets).
|
|
1010
1406
|
*/
|
|
1011
1407
|
function getAzureCloudAiAgentRoleDefinition(options) {
|
|
1012
1408
|
return azureRoleDefinitionOf(checkedSetup(options, CloudPlatform_1.CloudProvider.Azure));
|
|
@@ -1023,16 +1419,54 @@ function azureRoleDefinitionOf(setup) {
|
|
|
1023
1419
|
AssignableScopes: [`/subscriptions/${setup.accountId}`],
|
|
1024
1420
|
};
|
|
1025
1421
|
}
|
|
1422
|
+
/*
|
|
1423
|
+
* The second custom role, the agent's own identity's: the reads of the
|
|
1424
|
+
* same operations, on the same subscription, and no change.
|
|
1425
|
+
*/
|
|
1426
|
+
function getAzureCloudAiAgentReaderRoleDefinition(options) {
|
|
1427
|
+
return azureReaderRoleDefinitionOf(checkedSetup(options, CloudPlatform_1.CloudProvider.Azure));
|
|
1428
|
+
}
|
|
1429
|
+
function azureReaderRoleDefinitionOf(setup) {
|
|
1430
|
+
return {
|
|
1431
|
+
Name: getAzureCloudAiAgentReaderRoleName(setup.accountId),
|
|
1432
|
+
IsCustom: true,
|
|
1433
|
+
Description: AZURE_READER_ROLE_DESCRIPTION,
|
|
1434
|
+
Actions: getAzureCloudAiAgentReaderPermissions(setup.operations),
|
|
1435
|
+
NotActions: [],
|
|
1436
|
+
DataActions: [],
|
|
1437
|
+
NotDataActions: [],
|
|
1438
|
+
AssignableScopes: [`/subscriptions/${setup.accountId}`],
|
|
1439
|
+
};
|
|
1440
|
+
}
|
|
1026
1441
|
/*
|
|
1027
1442
|
* Azure, in Cloud Shell, in the subscription the command was written for
|
|
1028
1443
|
* (every call names it, so the shell's default subscription does not
|
|
1029
|
-
* matter):
|
|
1030
|
-
*
|
|
1031
|
-
*
|
|
1032
|
-
*
|
|
1033
|
-
*
|
|
1034
|
-
*
|
|
1035
|
-
*
|
|
1444
|
+
* matter):
|
|
1445
|
+
*
|
|
1446
|
+
* - the two roles, created or updated: the changes', and their reads
|
|
1447
|
+
* alone;
|
|
1448
|
+
* - the resource group, the write identity (a user-assigned managed
|
|
1449
|
+
* identity, made once and the same identity every run after) and the
|
|
1450
|
+
* Container Apps environment, created when they are not there;
|
|
1451
|
+
* - the app, which `az containerapp create` writes whole each time - its
|
|
1452
|
+
* image, secret, variables and size - with its own system-assigned
|
|
1453
|
+
* identity, and the write identity attached to it and to nothing else:
|
|
1454
|
+
* Azure gives a managed identity's token only to code running where the
|
|
1455
|
+
* identity is attached, so this app is the only place a token of the
|
|
1456
|
+
* write identity can come from;
|
|
1457
|
+
* - the reads' role for the app's own identity, and the changes' role
|
|
1458
|
+
* for the write identity, on the subscription (`az role assignment
|
|
1459
|
+
* create` is a no-op when the assignment is there); and the changes'
|
|
1460
|
+
* role taken from the app's own identity, which held it in an agent set
|
|
1461
|
+
* up before.
|
|
1462
|
+
*
|
|
1463
|
+
* The roles are assigned by their ids and the identities by their object
|
|
1464
|
+
* ids, which needs no lookup of a role or an identity made a minute
|
|
1465
|
+
* before. Nothing grants the agent's own identity anything on the write
|
|
1466
|
+
* identity: neither Managed Identity Operator, which would let it attach
|
|
1467
|
+
* the identity to a resource it may write, nor a federated credential,
|
|
1468
|
+
* which Azure lets a user-assigned identity hold only for an issuer outside
|
|
1469
|
+
* Entra ID.
|
|
1036
1470
|
*/
|
|
1037
1471
|
function getAzureCloudAiAgentSetupCommand(options) {
|
|
1038
1472
|
return writeAzureCommand(checkedSetup(options, CloudPlatform_1.CloudProvider.Azure));
|
|
@@ -1042,30 +1476,49 @@ function writeAzureCommand(setup) {
|
|
|
1042
1476
|
const location = setup.region;
|
|
1043
1477
|
const subscription = '--subscription "$SUBSCRIPTION"';
|
|
1044
1478
|
const group = `--resource-group ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_RESOURCE_GROUP}`;
|
|
1479
|
+
const scope = '--scope "/subscriptions/$SUBSCRIPTION"';
|
|
1480
|
+
const writeIdentity = `--name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_WRITE_IDENTITY_NAME} ${group}`;
|
|
1045
1481
|
const variables = environmentOf(setup).map((variable) => {
|
|
1046
1482
|
return variable.isSecret
|
|
1047
1483
|
? `${variable.name}=secretref:${exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME}`
|
|
1048
1484
|
: `${variable.name}=${(0, ShellWord_1.shellQuote)(variable.value)}`;
|
|
1049
1485
|
});
|
|
1486
|
+
// The same flags whether a role is created or updated.
|
|
1487
|
+
const role = (definition) => {
|
|
1488
|
+
return `${subscription} --role-definition "$${definition}" --query name --output tsv`;
|
|
1489
|
+
};
|
|
1050
1490
|
return [
|
|
1051
1491
|
`SUBSCRIPTION=${setup.accountId}`,
|
|
1052
1492
|
`DEFINITION=${(0, ShellWord_1.shellQuote)(JSON.stringify(azureRoleDefinitionOf(setup)))}`,
|
|
1493
|
+
`READER_DEFINITION=${(0, ShellWord_1.shellQuote)(JSON.stringify(azureReaderRoleDefinitionOf(setup)))}`,
|
|
1053
1494
|
"az extension add --name containerapp --upgrade -y --only-show-errors",
|
|
1054
|
-
`ROLE=$(az role definition create ${
|
|
1495
|
+
`ROLE=$(az role definition create ${role("DEFINITION")} 2> /dev/null || az role definition update ${role("DEFINITION")})`,
|
|
1496
|
+
`READER_ROLE=$(az role definition create ${role("READER_DEFINITION")} 2> /dev/null || az role definition update ${role("READER_DEFINITION")})`,
|
|
1055
1497
|
`az provider register ${subscription} --namespace Microsoft.App --wait`,
|
|
1498
|
+
`az provider register ${subscription} --namespace Microsoft.ManagedIdentity --wait`,
|
|
1056
1499
|
`az group show ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_RESOURCE_GROUP} > /dev/null 2>&1 || az group create ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_RESOURCE_GROUP} --location ${location} --output none`,
|
|
1500
|
+
// The identity each change runs as: made the first time, the same one every time after.
|
|
1501
|
+
`WRITE_PRINCIPAL=$(az identity show ${subscription} ${writeIdentity} --query principalId --output tsv 2> /dev/null || az identity create ${subscription} ${writeIdentity} --location ${location} --query principalId --output tsv)`,
|
|
1057
1502
|
`az containerapp env show ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_ENVIRONMENT_NAME} ${group} > /dev/null 2>&1 || az containerapp env create ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_ENVIRONMENT_NAME} ${group} --location ${location} --logs-destination none --output none`,
|
|
1058
|
-
|
|
1503
|
+
/*
|
|
1504
|
+
* The app with its own identity and the write identity, their roles,
|
|
1505
|
+
* and the line that says so: each only when the one before worked.
|
|
1506
|
+
*/
|
|
1059
1507
|
[
|
|
1060
|
-
`az containerapp create ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_APP_NAME} ${group}`,
|
|
1508
|
+
`[ -n "$WRITE_PRINCIPAL" ] && az containerapp create ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_APP_NAME} ${group}`,
|
|
1061
1509
|
`--environment ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_ENVIRONMENT_NAME} --image ${setup.image}`,
|
|
1062
|
-
`--cpu ${size.vcpu} --memory ${size.memoryGiB}Gi --min-replicas 1 --max-replicas 1
|
|
1063
|
-
`--
|
|
1510
|
+
`--cpu ${size.vcpu} --memory ${size.memoryGiB}Gi --min-replicas 1 --max-replicas 1`,
|
|
1511
|
+
`--system-assigned --user-assigned ${(0, CloudAiAgentNames_1.getAzureCloudAiAgentWriteIdentityId)(setup.accountId)}`,
|
|
1512
|
+
`--secrets ${exports.AZURE_CLOUD_AI_AGENT_SECRET_NAME}=${(0, ShellWord_1.shellQuote)(setup.agentKey)}`,
|
|
1064
1513
|
`--env-vars ${variables.join(" ")}`,
|
|
1065
1514
|
"--output none &&",
|
|
1066
1515
|
].join(" "),
|
|
1067
1516
|
` PRINCIPAL=$(az containerapp show ${subscription} --name ${CloudAiAgentNames_1.AZURE_CLOUD_AI_AGENT_APP_NAME} ${group} --query identity.principalId --output tsv) &&`,
|
|
1068
|
-
|
|
1517
|
+
// The agent's own identity reads; the write identity holds the changes.
|
|
1518
|
+
` az role assignment create ${subscription} --assignee-object-id "$PRINCIPAL" --assignee-principal-type ServicePrincipal --role "$READER_ROLE" ${scope} --output none &&`,
|
|
1519
|
+
` az role assignment create ${subscription} --assignee-object-id "$WRITE_PRINCIPAL" --assignee-principal-type ServicePrincipal --role "$ROLE" ${scope} --output none &&`,
|
|
1520
|
+
// An agent set up before held the changes' role itself: no longer.
|
|
1521
|
+
` { az role assignment delete ${subscription} --assignee "$PRINCIPAL" --role "$ROLE" ${scope} --output none 2> /dev/null || true; } &&`,
|
|
1069
1522
|
` echo "${exports.CLOUD_AI_AGENT_STARTED_MESSAGE}"`,
|
|
1070
1523
|
].join("\n");
|
|
1071
1524
|
}
|
|
@@ -1075,12 +1528,14 @@ const GCP_PERMISSION_APIS = {
|
|
|
1075
1528
|
run: "run.googleapis.com",
|
|
1076
1529
|
compute: "compute.googleapis.com",
|
|
1077
1530
|
cloudsql: "sqladmin.googleapis.com",
|
|
1531
|
+
appengine: "appengine.googleapis.com",
|
|
1078
1532
|
};
|
|
1079
1533
|
/*
|
|
1080
1534
|
* The APIs the Google Cloud command turns on: what the agent runs on
|
|
1081
1535
|
* (Compute Engine and Cloud Logging for its VM, or Cloud Run), IAM and
|
|
1082
|
-
* Resource Manager (the
|
|
1083
|
-
*
|
|
1536
|
+
* Resource Manager (the roles, the service accounts and their bindings),
|
|
1537
|
+
* IAM Credentials (each change's token of the write account), Secret
|
|
1538
|
+
* Manager (the key), and those of the operations turned on.
|
|
1084
1539
|
*/
|
|
1085
1540
|
function getGcpCloudAiAgentServices(enabledOperations, gcpHost = CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_DEFAULT_HOST) {
|
|
1086
1541
|
const services = [
|
|
@@ -1088,6 +1543,7 @@ function getGcpCloudAiAgentServices(enabledOperations, gcpHost = CloudAiAgentNam
|
|
|
1088
1543
|
? ["run.googleapis.com"]
|
|
1089
1544
|
: ["compute.googleapis.com", "logging.googleapis.com"]),
|
|
1090
1545
|
"iam.googleapis.com",
|
|
1546
|
+
"iamcredentials.googleapis.com",
|
|
1091
1547
|
"cloudresourcemanager.googleapis.com",
|
|
1092
1548
|
"secretmanager.googleapis.com",
|
|
1093
1549
|
];
|
|
@@ -1101,10 +1557,15 @@ function getGcpCloudAiAgentServices(enabledOperations, gcpHost = CloudAiAgentNam
|
|
|
1101
1557
|
}
|
|
1102
1558
|
/*
|
|
1103
1559
|
* Google Cloud, in Cloud Shell, in the project the command was written for
|
|
1104
|
-
* (every call names it): the APIs
|
|
1105
|
-
* exactly these permissions)
|
|
1106
|
-
*
|
|
1107
|
-
*
|
|
1560
|
+
* (every call names it): the APIs; the two roles (created, or updated to
|
|
1561
|
+
* exactly these permissions) - the changes' for the write account, their
|
|
1562
|
+
* reads alone for the agent's own; the two service accounts (created when
|
|
1563
|
+
* they are not there) and their bindings, with the agent's own account
|
|
1564
|
+
* allowed to ask for a token of the write account and of no other (and no
|
|
1565
|
+
* longer holding the changes' role, as an agent set up before did); the key
|
|
1566
|
+
* as a new version of a Secret Manager secret only the agent's own account
|
|
1567
|
+
* may read - every older version destroyed once the new one is in - then
|
|
1568
|
+
* the agent on its host:
|
|
1108
1569
|
*
|
|
1109
1570
|
* - compute-engine (the default): a network of its own whose firewall
|
|
1110
1571
|
* lets nothing in (a VPC denies every connection in until a rule
|
|
@@ -1130,6 +1591,8 @@ function getGcpCloudAiAgentSetupCommand(options) {
|
|
|
1130
1591
|
}
|
|
1131
1592
|
// The service account the agent runs as, in the command's shell.
|
|
1132
1593
|
const GCP_MEMBER = `${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_SERVICE_ACCOUNT_ID}@$PROJECT_ID.iam.gserviceaccount.com`;
|
|
1594
|
+
// The service account its changes run as.
|
|
1595
|
+
const GCP_WRITE_MEMBER = `${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_WRITE_SERVICE_ACCOUNT_ID}@$PROJECT_ID.iam.gserviceaccount.com`;
|
|
1133
1596
|
const GCP_PROJECT_FLAG = '--project "$PROJECT_ID"';
|
|
1134
1597
|
/*
|
|
1135
1598
|
* Whether an API is on in the project, as a shell condition: a list call
|
|
@@ -1140,7 +1603,7 @@ const GCP_PROJECT_FLAG = '--project "$PROJECT_ID"';
|
|
|
1140
1603
|
function gcpApiIsOn(api) {
|
|
1141
1604
|
return `gcloud services list ${GCP_PROJECT_FLAG} --enabled --filter "config.name=${api}" --format "value(config.name)" --quiet 2> /dev/null | grep -q .`;
|
|
1142
1605
|
}
|
|
1143
|
-
// What both hosts share: the APIs, the
|
|
1606
|
+
// What both hosts share: the APIs, the roles and their accounts, and the key.
|
|
1144
1607
|
function writeGcpCommandStart(setup) {
|
|
1145
1608
|
// The same title, description and permissions whether it creates or updates.
|
|
1146
1609
|
const role = [
|
|
@@ -1148,21 +1611,44 @@ function writeGcpCommandStart(setup) {
|
|
|
1148
1611
|
`--description ${(0, ShellWord_1.shellQuote)(ROLE_DESCRIPTION)}`,
|
|
1149
1612
|
'--permissions "$PERMISSIONS" --stage GA --quiet',
|
|
1150
1613
|
].join(" ");
|
|
1614
|
+
const readerRole = [
|
|
1615
|
+
`--title ${(0, ShellWord_1.shellQuote)(READER_ROLE_TITLE)}`,
|
|
1616
|
+
`--description ${(0, ShellWord_1.shellQuote)(READER_ROLE_DESCRIPTION)}`,
|
|
1617
|
+
'--permissions "$READ_PERMISSIONS" --stage GA --quiet',
|
|
1618
|
+
].join(" ");
|
|
1151
1619
|
const secret = exports.GCP_CLOUD_AI_AGENT_SECRET_NAME;
|
|
1152
1620
|
return [
|
|
1153
1621
|
`PROJECT_ID=${setup.accountId}`,
|
|
1154
1622
|
`PERMISSIONS=${(0, ShellWord_1.shellQuote)(getCloudAiAgentRolePermissions(CloudPlatform_1.CloudProvider.GCP, setup.operations).join(","))}`,
|
|
1623
|
+
`READ_PERMISSIONS=${(0, ShellWord_1.shellQuote)(getGcpCloudAiAgentReaderPermissions(setup.operations).join(","))}`,
|
|
1155
1624
|
`gcloud services enable ${getGcpCloudAiAgentServices(setup.operations, setup.gcpHost).join(" ")} ${GCP_PROJECT_FLAG}`,
|
|
1156
1625
|
`gcloud iam roles create ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_ROLE_ID} ${GCP_PROJECT_FLAG} ${role} > /dev/null 2>&1 || gcloud iam roles update ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_ROLE_ID} ${GCP_PROJECT_FLAG} ${role} > /dev/null`,
|
|
1626
|
+
`gcloud iam roles create ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_READER_ROLE_ID} ${GCP_PROJECT_FLAG} ${readerRole} > /dev/null 2>&1 || gcloud iam roles update ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_READER_ROLE_ID} ${GCP_PROJECT_FLAG} ${readerRole} > /dev/null`,
|
|
1157
1627
|
`gcloud iam service-accounts create ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_SERVICE_ACCOUNT_ID} ${GCP_PROJECT_FLAG} --display-name ${(0, ShellWord_1.shellQuote)("OneUptime Cloud AI agent")} > /dev/null 2>&1 || true`,
|
|
1158
|
-
`gcloud
|
|
1628
|
+
`gcloud iam service-accounts create ${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_WRITE_SERVICE_ACCOUNT_ID} ${GCP_PROJECT_FLAG} --display-name ${(0, ShellWord_1.shellQuote)("OneUptime Cloud AI agent: changes")} > /dev/null 2>&1 || true`,
|
|
1629
|
+
// The changes' role is the write account's; the agent's own account reads.
|
|
1630
|
+
`gcloud projects add-iam-policy-binding "$PROJECT_ID" --member "serviceAccount:${GCP_WRITE_MEMBER}" --role "projects/$PROJECT_ID/roles/${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_ROLE_ID}" --condition=None > /dev/null`,
|
|
1631
|
+
`gcloud projects add-iam-policy-binding "$PROJECT_ID" --member "serviceAccount:${GCP_MEMBER}" --role "projects/$PROJECT_ID/roles/${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_READER_ROLE_ID}" --condition=None > /dev/null`,
|
|
1632
|
+
// A token of the write account, for a change: the agent's own account may ask for one, on that account alone.
|
|
1633
|
+
`gcloud iam service-accounts add-iam-policy-binding "${GCP_WRITE_MEMBER}" ${GCP_PROJECT_FLAG} --member "serviceAccount:${GCP_MEMBER}" --role ${exports.GCP_TOKEN_CREATOR_ROLE} --condition=None > /dev/null`,
|
|
1634
|
+
// An agent set up before held the changes' role itself: no longer.
|
|
1635
|
+
`gcloud projects remove-iam-policy-binding "$PROJECT_ID" --member "serviceAccount:${GCP_MEMBER}" --role "projects/$PROJECT_ID/roles/${CloudAiAgentNames_1.GCP_CLOUD_AI_AGENT_ROLE_ID}" --condition=None > /dev/null 2>&1 || true`,
|
|
1159
1636
|
// The key: a secret only the agent's service account may read.
|
|
1160
1637
|
`cat > ${exports.GCP_CLOUD_AI_AGENT_KEY_FILE} <<'${exports.GCP_CLOUD_AI_AGENT_KEY_FILE_END}'`,
|
|
1161
|
-
setup.
|
|
1638
|
+
setup.agentKey,
|
|
1162
1639
|
exports.GCP_CLOUD_AI_AGENT_KEY_FILE_END,
|
|
1163
1640
|
`gcloud secrets create ${secret} ${GCP_PROJECT_FLAG} --replication-policy automatic > /dev/null 2>&1 || true`,
|
|
1164
|
-
`tr -d '\\n' < ${exports.GCP_CLOUD_AI_AGENT_KEY_FILE} | gcloud secrets versions add ${secret} ${GCP_PROJECT_FLAG} --data-file=-
|
|
1641
|
+
`KEY_VERSION=$(tr -d '\\n' < ${exports.GCP_CLOUD_AI_AGENT_KEY_FILE} | gcloud secrets versions add ${secret} ${GCP_PROJECT_FLAG} --data-file=- --format "value(name.basename())")`,
|
|
1165
1642
|
`rm ${exports.GCP_CLOUD_AI_AGENT_KEY_FILE}`,
|
|
1643
|
+
/*
|
|
1644
|
+
* Every older version of the secret is destroyed once the new one is in:
|
|
1645
|
+
* the agent reads the latest, and an older one holds a key that no
|
|
1646
|
+
* longer connects anything (or, from before agents had keys of their
|
|
1647
|
+
* own, the project's ingestion key) for its service account to read.
|
|
1648
|
+
* Only when the new version was added: a run that failed to add it
|
|
1649
|
+
* leaves the one that works.
|
|
1650
|
+
*/
|
|
1651
|
+
`if [ -n "$KEY_VERSION" ]; then for VERSION in $(gcloud secrets versions list ${secret} ${GCP_PROJECT_FLAG} --filter "state:ENABLED OR state:DISABLED" --format "value(name.basename())" --quiet); do [ "$VERSION" = "$KEY_VERSION" ] || gcloud secrets versions destroy "$VERSION" --secret ${secret} ${GCP_PROJECT_FLAG} --quiet > /dev/null; done; fi`,
|
|
1166
1652
|
`gcloud secrets add-iam-policy-binding ${secret} ${GCP_PROJECT_FLAG} --member "serviceAccount:${GCP_MEMBER}" --role ${exports.GCP_SECRET_ACCESSOR_ROLE} --condition=None > /dev/null`,
|
|
1167
1653
|
];
|
|
1168
1654
|
}
|
|
@@ -1184,7 +1670,7 @@ function writeGcpStartupScript(setup) {
|
|
|
1184
1670
|
const variables = environmentOf(setup);
|
|
1185
1671
|
const keyVariable = ((_a = variables.find((variable) => {
|
|
1186
1672
|
return variable.isSecret;
|
|
1187
|
-
})) === null || _a === void 0 ? void 0 : _a.name) || exports.
|
|
1673
|
+
})) === null || _a === void 0 ? void 0 : _a.name) || exports.CLOUD_AI_AGENT_KEY_ENV;
|
|
1188
1674
|
const run = exports.GCP_CLOUD_AI_AGENT_RUN_DIRECTORY;
|
|
1189
1675
|
/*
|
|
1190
1676
|
* No #! line: the guest environment runs a startup script with bash, and
|