// Copyright Epic Games, Inc. All Rights Reserved. using System; using System.Collections.Generic; using EpicGames.Horde.Common; using EpicGames.Horde.Server; #pragma warning disable CA2227 // Collection properties should be read only #pragma warning disable CA1056 // Change string to URI namespace EpicGames.Horde.Dashboard { /// /// Setting information required by dashboard /// public class GetDashboardConfigResponse { /// /// The name of the external issue service /// public string? ExternalIssueServiceName { get; set; } /// /// The url of the external issue service /// public string? ExternalIssueServiceUrl { get; set; } /// /// The url of the perforce swarm installation /// public string? PerforceSwarmUrl { get; set; } /// /// Url of Robomergem installation /// public string? RobomergeUrl { get; set; } /// /// Url of Commits Viewer /// public string? CommitsViewerUrl { get; set; } /// /// Help email address that users can contact with issues /// public string? HelpEmailAddress { get; set; } /// /// Help slack channel that users can use for issues /// public string? HelpSlackChannel { get; set; } /// /// The auth method in use /// public AuthMethod AuthMethod { get; set; } /// /// Device problem cooldown in minutes /// public int DeviceProblemCooldownMinutes { get; set; } /// /// Categories to display on the agents page /// public List AgentCategories { get; set; } = new List(); /// /// Categories to display on the pools page /// public List PoolCategories { get; set; } = new List(); /// /// Configured artifact types /// public List ArtifactTypes { get; set; } = new List(); /// /// Configured artifact type info /// public List ArtifactTypeInfo { get; set; } = new List(); } /// /// Describes an artifact type /// public class GetDashboardArtifactTypeResponse { /// /// Type of the artifact /// public string Type { get; set; } = "UnnamedArtifactType"; /// /// Number of days to retain artifacts of this type /// public int? KeepDays { get; set; } } /// /// Describes a category for the pools page /// public class GetDashboardPoolCategoryResponse { /// /// Title for the tab /// public string Name { get; set; } = "Unnamed"; /// /// Condition for pools to be included in this category /// public Condition? Condition { get; set; } } /// /// Describes a category for the agents page /// public class GetDashboardAgentCategoryResponse { /// /// Title for the tab /// public string Name { get; set; } = "Unnamed"; /// /// Condition for agents to be included in this category /// public Condition? Condition { get; set; } } /// /// /// public class CreateDashboardPreviewRequest { /// /// A summary of what the preview item changes /// public string Summary { get; set; } = String.Empty; /// /// The CL the preview was deployed in /// public int? DeployedCL { get; set; } /// /// An example of the preview site users can view the changes /// public string? ExampleLink { get; set; } /// /// Optional Link for discussion the preview item /// public string? DiscussionLink { get; set; } /// /// Optional Link for discussing the preview item /// public string? TrackingLink { get; set; } } /// /// /// public class UpdateDashboardPreviewRequest { /// /// The preview item to update /// public int Id { get; set; } /// /// A summary of what the preview item changes /// public string? Summary { get; set; } /// /// The CL the preview was deployed in /// public int? DeployedCL { get; set; } /// /// Whather the preview is under consideration, if false the preview item didn't pass muster /// public bool? Open { get; set; } /// /// An example of the preview site users can view the changes /// public string? ExampleLink { get; set; } /// /// Optional Link for discussion the preview item /// public string? DiscussionLink { get; set; } /// /// Optional Link for discussing the preview item /// public string? TrackingLink { get; set; } } /// /// Dashboard preview item response /// public class GetDashboardPreviewResponse { /// /// The unique ID of the preview item /// public int Id { get; set; } /// /// When the preview item was created /// public DateTime CreatedAt { get; set; } /// /// A summary of what the preview item changes /// public string Summary { get; set; } = String.Empty; /// /// The CL the preview was deployed in /// public int? DeployedCL { get; set; } /// /// Whather the preview is under consideration, if false the preview item didn't pass muster /// public bool Open { get; set; } /// /// An example of the preview site users can view the changes /// public string? ExampleLink { get; set; } /// /// Optional Link for discussion the preview item /// public string? DiscussionLink { get; set; } /// /// Optional Link for discussing the preview item /// public string? TrackingLink { get; set; } } /// /// Dashboard challenge response /// public class GetDashboardChallengeResponse { /// /// Whether first time setup needs to run /// public bool NeedsFirstTimeSetup { get; set; } = false; /// /// Whether the user needs to authorize /// public bool NeedsAuthorization { get; set; } = true; } }