File tree Expand file tree Collapse file tree 4 files changed +12
-0
lines changed
packages/clients/src/api/tem/v1alpha1 Expand file tree Collapse file tree 4 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -127,6 +127,7 @@ export class API extends ParentAPI {
127127 ) } /emails`,
128128 urlParams : urlParams (
129129 [ 'domain_id' , request . domainId ] ,
130+ [ 'flags' , request . flags ] ,
130131 [ 'mail_from' , request . mailFrom ] ,
131132 [ 'mail_rcpt' , request . mailRcpt ] ,
132133 [ 'mail_to' , request . mailTo ] ,
Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ export type {
1818 DomainStatistics ,
1919 DomainStatus ,
2020 Email ,
21+ EmailFlag ,
2122 EmailRcptType ,
2223 EmailStatus ,
2324 EmailTry ,
Original file line number Diff line number Diff line change @@ -118,6 +118,7 @@ export const unmarshalEmail = (data: unknown) => {
118118
119119 return {
120120 createdAt : unmarshalDate ( data . created_at ) ,
121+ flags : data . flags ,
121122 id : data . id ,
122123 lastTries : unmarshalArrayOfObject ( data . last_tries , unmarshalEmailTry ) ,
123124 mailFrom : data . mail_from ,
Original file line number Diff line number Diff line change @@ -17,6 +17,8 @@ export type DomainStatus =
1717 | 'revoked'
1818 | 'pending'
1919
20+ export type EmailFlag = 'unknown_flag' | 'soft_bounce' | 'hard_bounce'
21+
2022export type EmailRcptType = 'unknown_rcpt_type' | 'to' | 'cc' | 'bcc'
2123
2224export type EmailStatus =
@@ -165,6 +167,11 @@ export interface Email {
165167 tryCount : number
166168 /** Information about the last three attempts to send the email. */
167169 lastTries : EmailTry [ ]
170+ /**
171+ * Flags categorize emails. They allow you to obtain more information about
172+ * recurring errors, for example.
173+ */
174+ flags : EmailFlag [ ]
168175}
169176
170177/** Email. try. */
@@ -301,6 +308,8 @@ export type ListEmailsRequest = {
301308 search ?: string
302309 /** (Optional) List emails corresponding to specific criteria. */
303310 orderBy ?: ListEmailsRequestOrderBy
311+ /** (Optional) List emails containing only specific flags. */
312+ flags ?: EmailFlag [ ]
304313}
305314
306315export type GetStatisticsRequest = {
You can’t perform that action at this time.
0 commit comments