Table of Contents

Class InboundAttachment

Namespace
Mailtrap.Inbound.Models
Assembly
Mailtrap.Abstractions.dll

Represents attachment metadata on a received message.
DownloadUrl and DownloadUrlExpiresAt are populated only on get-by-id and thread responses.

public sealed record InboundAttachment : IEquatable<InboundAttachment>
Inheritance
InboundAttachment
Implements

Properties

AttachmentId

Gets or sets the attachment identifier.

[JsonPropertyName("attachment_id")]
public string? AttachmentId { get; set; }

Property Value

string

Attachment identifier.

ContentDisposition

Gets or sets the content disposition of the attachment.

[JsonPropertyName("content_disposition")]
public string? ContentDisposition { get; set; }

Property Value

string

Content disposition of the attachment.

ContentId

Gets or sets the content identifier of the attachment.

[JsonPropertyName("content_id")]
public string? ContentId { get; set; }

Property Value

string

Content identifier of the attachment.

ContentType

Gets or sets the MIME type of the attachment.

[JsonPropertyName("content_type")]
public string? ContentType { get; set; }

Property Value

string

MIME type of the attachment.

DownloadUrl

Gets or sets the signed URL to download the attachment.

[JsonPropertyName("download_url")]
public string? DownloadUrl { get; set; }

Property Value

string

Signed download URL.

DownloadUrlExpiresAt

Gets or sets the expiration timestamp of the signed download URL.

[JsonPropertyName("download_url_expires_at")]
public DateTimeOffset? DownloadUrlExpiresAt { get; set; }

Property Value

DateTimeOffset?

Expiration timestamp of the signed download URL.

FileName

Gets or sets the attachment file name.

[JsonPropertyName("filename")]
public string? FileName { get; set; }

Property Value

string

Attachment file name.

Size

Gets or sets the attachment size, in bytes.

[JsonPropertyName("size")]
public int? Size { get; set; }

Property Value

int?

Attachment size, in bytes.