chaosbot/ChaosBot/WebServer/Models/CustomCommandResponse.cs

27 lines
689 B
C#

using System.ComponentModel.DataAnnotations;
using ChaosBot.Models;
namespace ChaosBot.WebServer.Models
{
class CustomCommandResponse
{
[Required]
public string DiscordGuildId { get; }
[Required]
[MaxLength(128)]
public string Command { get; }
[Required]
public CustomCommandType Type { get; }
[Required]
public string Content { get; }
public CustomCommandResponse(CustomCommand command)
{
DiscordGuildId = command.DiscordGuildId.ToString();
Command = command.Command;
Type = command.Type;
Content = command.Content;
}
}
}