using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
namespace API.Controllers.Requests;
public record CreateNotificationConnectorRecord
{
///
/// The Name of the Notification Connector
///
[Required]
[Description("The Name of the Notification Connector")]
public required string Name { get; init; }
///
/// The Url of the Instance
///
/// Formatting placeholders: "%title" and "%text" will be replaced when notifications are sent
[Required]
[Url]
[Description("The Url of the Instance")]
public required string Url { get; init; }
///
/// The HTTP Request Method to use for notifications
///
[Required]
[Description("The HTTP Request Method to use for notifications")]
public required string HttpMethod { get; init; }
///
/// The Request Body to use to send notifications
///
/// Formatting placeholders: "%title" and "%text" will be replaced when notifications are sent
[Required]
[Description("The Request Body to use to send notifications")]
public required string Body { get; init; }
///
/// The Request Headers to use to send notifications
///
/// Formatting placeholders: "%title" and "%text" will be replaced when notifications are sent
[Required]
[Description("The Request Headers to use to send notifications")]
public required Dictionary Headers { get; init; }
}