Class EmailCampaignStateMetadata
- Namespace
- Mailtrap.EmailCampaigns.Models
- Assembly
- Mailtrap.Abstractions.dll
Represents metadata about the most recent state transition of an email campaign.
public sealed record EmailCampaignStateMetadata : IEquatable<EmailCampaignStateMetadata>
- Inheritance
-
EmailCampaignStateMetadata
- Implements
Properties
Error
Gets or sets the last error message recorded for a failed campaign.
[JsonPropertyName("error")]
[JsonPropertyOrder(2)]
public string? Error { get; set; }
Property Value
- string
Last error message.
Errors
Gets the per-recipient errors recorded when sending failed.
[JsonPropertyName("errors")]
[JsonPropertyOrder(3)]
[JsonObjectCreationHandling(JsonObjectCreationHandling.Populate)]
public IList<EmailCampaignStateError> Errors { get; }
Property Value
- IList<EmailCampaignStateError>
Collection of per-recipient errors.
Reason
Gets or sets the reason for the most recent state transition.
[JsonPropertyName("reason")]
[JsonPropertyOrder(1)]
public string? Reason { get; set; }
Property Value
- string
State transition reason.
ScheduledAt
Gets or sets the time the campaign is scheduled to send at.
Present in the Scheduled state.
[JsonPropertyName("scheduled_at")]
[JsonPropertyOrder(4)]
public DateTimeOffset? ScheduledAt { get; set; }
Property Value
- DateTimeOffset?
Scheduled time, or null when not scheduled.