Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/inbound/inbound.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ describe('Inbound', () => {
bcc: null,
cc: ['[email protected]'],
reply_to: ['[email protected]'],
headers: {
example: 'value',
},
attachments: [
{
id: 'att_123',
Expand Down Expand Up @@ -93,6 +96,9 @@ describe('Inbound', () => {
],
"createdAt": "2023-04-07T23:13:52.669661+00:00",
"from": "[email protected]",
"headers": {
"example": "value",
},
"html": "<p>hello world</p>",
"id": "67d9bcdb-5a02-42d7-8da9-0d6feea18cff",
"object": "inbound",
Expand Down Expand Up @@ -123,6 +129,7 @@ describe('Inbound', () => {
bcc: null,
cc: null,
reply_to: null,
headers: {},
attachments: [],
};

Expand All @@ -146,6 +153,7 @@ describe('Inbound', () => {
"cc": null,
"createdAt": "2023-04-07T23:13:52.669661+00:00",
"from": "[email protected]",
"headers": {},
"html": null,
"id": "67d9bcdb-5a02-42d7-8da9-0d6feea18cff",
"object": "inbound",
Expand Down
1 change: 1 addition & 0 deletions src/inbound/inbound.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export class Inbound {
replyTo: apiResponse.reply_to,
html: apiResponse.html,
text: apiResponse.text,
headers: apiResponse.headers,
attachments: apiResponse.attachments.map((attachment) => ({
id: attachment.id,
filename: attachment.filename,
Expand Down
1 change: 1 addition & 0 deletions src/inbound/interfaces/get-inbound-email.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ export interface GetInboundEmailApiResponse {
reply_to: string[] | null;
html: string | null;
text: string | null;
headers: Record<string, string>;
attachments: Array<{
id: string;
filename: string;
Expand Down
1 change: 1 addition & 0 deletions src/inbound/interfaces/inbound-email.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export interface InboundEmail {
replyTo: string[] | null;
html: string | null;
text: string | null;
headers: Record<string, string>;
attachments: InboundEmailAttachment[];
}

Expand Down
Loading