Class BatchEmailRequest
Represents request object used to send email batch.
public sealed record BatchEmailRequest : IValidatable, IEquatable<BatchEmailRequest>
- Inheritance
-
BatchEmailRequest
- Implements
- Extension Methods
Properties
Base
Gets or sets an object with general properties of all emails in the batch.
Each of them can be overridden in requests for individual emails.
[JsonPropertyName("base")]
[JsonPropertyOrder(1)]
public EmailRequest Base { get; set; }
Property Value
- EmailRequest
Contains object with general properties of all emails in the batch.
Requests
Gets or sets the list of email requests.
Each of them requires recipients (one of to, cc, or bcc).
Each email inherits properties from base but can override them.
[JsonPropertyName("requests")]
[JsonPropertyOrder(2)]
[JsonObjectCreationHandling(JsonObjectCreationHandling.Populate)]
public IList<SendEmailRequest> Requests { get; set; }
Property Value
- IList<SendEmailRequest>
Contains the list of email requests to be sent in the batch.
Remarks
Please note that requests must not exceed the count of 500 and 50 MB overall payload size, including attachments.
Methods
Create()
Factory method that creates a new instance of BatchEmailRequest request.
public static BatchEmailRequest Create()
Returns
- BatchEmailRequest
New BatchEmailRequest instance.
Validate()
Validates the current instance.
public ValidationResult Validate()
Returns
- ValidationResult
Object containing validation errors, if any.