mirror of
https://github.com/MAKS-IT-COM/maksit-certs-ui.git
synced 2025-12-31 04:00:03 +01:00
15 lines
525 B
C#
15 lines
525 B
C#
using MaksIT.Core.Abstractions.Webapi;
|
|
using System.ComponentModel.DataAnnotations;
|
|
|
|
namespace MaksIT.Models.LetsEncryptServer.CertsFlow.Requests
|
|
{
|
|
public class GetCertificatesRequest : RequestModelBase {
|
|
public required string[] Hostnames { get; set; }
|
|
|
|
public override IEnumerable<ValidationResult> Validate(ValidationContext validationContext) {
|
|
if (Hostnames == null || Hostnames.Length == 0)
|
|
yield return new ValidationResult("Hostnames is required", new[] { nameof(Hostnames) });
|
|
}
|
|
}
|
|
}
|