shipmail 0.6.4 → 0.6.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1229,12 +1229,16 @@ type InboxFullMessage = Omit<InboxMessage, "object"> & {
1229
1229
  readonly text_body: readonly InboxBodyPart[];
1230
1230
  readonly html_body: readonly InboxBodyPart[];
1231
1231
  readonly attachments: readonly InboxAttachment[];
1232
+ /** What the sender newly wrote, without quoted history or signature. `null` when nothing is left. */
1233
+ readonly reply_text: string | null;
1232
1234
  };
1233
1235
  type InboxMessages = {
1234
1236
  readonly object: "inbox_messages";
1235
1237
  readonly mailbox_id: string;
1236
1238
  readonly address: string;
1237
1239
  readonly data: readonly InboxFullMessage[];
1240
+ /** Messages in Junk that match the other filters, when a folder filter leaves Junk out. Null otherwise. */
1241
+ readonly junk_total: number | null;
1238
1242
  readonly pagination: {
1239
1243
  readonly limit: number;
1240
1244
  readonly total: number;
@@ -1355,6 +1359,9 @@ type InboxMessageAction = {
1355
1359
  readonly address: string;
1356
1360
  readonly message_id: string;
1357
1361
  readonly ok: true;
1362
+ /** Folders and keywords read back after the change. Null when the message could not be read. */
1363
+ readonly folder_ids: readonly string[] | null;
1364
+ readonly keywords: Readonly<Record<string, boolean>> | null;
1358
1365
  };
1359
1366
  type MailboxRuleMatchMode = "all" | "any";
1360
1367
  type MailboxRuleCondition = {
@@ -1463,6 +1470,13 @@ type ListInboxMessagesParams = {
1463
1470
  readonly folder_id?: string | undefined;
1464
1471
  readonly folder_role?: "inbox" | "starred" | "sent" | "drafts" | "archive" | "junk" | "trash" | undefined;
1465
1472
  readonly search_text?: string | undefined;
1473
+ /** Matches the From name or address. */
1474
+ readonly from?: string | undefined;
1475
+ /** Matches the To recipients by name or address. Cc and Bcc are not searched. */
1476
+ readonly to?: string | undefined;
1477
+ readonly subject?: string | undefined;
1478
+ /** `true` for messages with an attachment, `false` for messages without one. */
1479
+ readonly has_attachment?: boolean | undefined;
1466
1480
  readonly cursor?: string | undefined;
1467
1481
  readonly after?: string | undefined;
1468
1482
  readonly before?: string | undefined;
@@ -1724,6 +1738,7 @@ type Newsletter = {
1724
1738
  readonly feed_entry_url: string | null;
1725
1739
  readonly styling_mode: NewsletterStylingMode;
1726
1740
  readonly track_engagement: boolean;
1741
+ readonly add_utm_tags: boolean;
1727
1742
  readonly opened_count: number | null;
1728
1743
  readonly clicked_count: number | null;
1729
1744
  readonly preflight_status: NewsletterPreflightStatus;
@@ -1815,6 +1830,7 @@ type CreateNewsletterParams = {
1815
1830
  readonly feed_entry_url?: string | null | undefined;
1816
1831
  readonly styling_mode?: NewsletterStylingMode | undefined;
1817
1832
  readonly track_engagement?: boolean | undefined;
1833
+ readonly add_utm_tags?: boolean | undefined;
1818
1834
  };
1819
1835
  type UpdateNewsletterParams = Partial<CreateNewsletterParams>;
1820
1836
  type NewsletterChangelogMedia = {
@@ -2225,6 +2241,9 @@ type Webhook = {
2225
2241
  readonly domain_ids: readonly string[] | null;
2226
2242
  readonly has_authorization: boolean;
2227
2243
  readonly has_standard_webhooks_secret: boolean;
2244
+ readonly include_reply_text: boolean;
2245
+ readonly authenticated_senders_only: boolean;
2246
+ readonly allowed_senders: readonly string[] | null;
2228
2247
  readonly created_at: string;
2229
2248
  readonly updated_at: string;
2230
2249
  };
@@ -2241,6 +2260,12 @@ type CreateWebhookParams = {
2241
2260
  readonly authorization?: string | null | undefined;
2242
2261
  /** A `whsec_` secret from the receiving service. Deliveries then carry Standard Webhooks signatures. Write-only. */
2243
2262
  readonly standard_webhooks_secret?: string | null | undefined;
2263
+ /** Add `reply_text` to `message.received` deliveries. The API key also needs `messages:read`. */
2264
+ readonly include_reply_text?: boolean | undefined;
2265
+ /** Skip `message.received` deliveries whose sender did not pass DMARC. */
2266
+ readonly authenticated_senders_only?: boolean | undefined;
2267
+ /** Deliver `message.received` only from these addresses or exact domains. At most 100. */
2268
+ readonly allowed_senders?: readonly string[] | null | undefined;
2244
2269
  };
2245
2270
  type UpdateWebhookParams = {
2246
2271
  readonly url?: string | undefined;
@@ -2253,6 +2278,12 @@ type UpdateWebhookParams = {
2253
2278
  readonly authorization?: string | null | undefined;
2254
2279
  /** A string replaces the Standard Webhooks signing secret, `null` removes it. */
2255
2280
  readonly standard_webhooks_secret?: string | null | undefined;
2281
+ /** Add `reply_text` to `message.received` deliveries. The API key also needs `messages:read`. */
2282
+ readonly include_reply_text?: boolean | undefined;
2283
+ /** Skip `message.received` deliveries whose sender did not pass DMARC. */
2284
+ readonly authenticated_senders_only?: boolean | undefined;
2285
+ /** Replaces the sender list. `null` or `[]` delivers every sender again. */
2286
+ readonly allowed_senders?: readonly string[] | null | undefined;
2256
2287
  };
2257
2288
  type ListWebhooksParams = PaginationParams;
2258
2289
  type RotateSecretResponse = {
package/dist/index.d.ts CHANGED
@@ -1229,12 +1229,16 @@ type InboxFullMessage = Omit<InboxMessage, "object"> & {
1229
1229
  readonly text_body: readonly InboxBodyPart[];
1230
1230
  readonly html_body: readonly InboxBodyPart[];
1231
1231
  readonly attachments: readonly InboxAttachment[];
1232
+ /** What the sender newly wrote, without quoted history or signature. `null` when nothing is left. */
1233
+ readonly reply_text: string | null;
1232
1234
  };
1233
1235
  type InboxMessages = {
1234
1236
  readonly object: "inbox_messages";
1235
1237
  readonly mailbox_id: string;
1236
1238
  readonly address: string;
1237
1239
  readonly data: readonly InboxFullMessage[];
1240
+ /** Messages in Junk that match the other filters, when a folder filter leaves Junk out. Null otherwise. */
1241
+ readonly junk_total: number | null;
1238
1242
  readonly pagination: {
1239
1243
  readonly limit: number;
1240
1244
  readonly total: number;
@@ -1355,6 +1359,9 @@ type InboxMessageAction = {
1355
1359
  readonly address: string;
1356
1360
  readonly message_id: string;
1357
1361
  readonly ok: true;
1362
+ /** Folders and keywords read back after the change. Null when the message could not be read. */
1363
+ readonly folder_ids: readonly string[] | null;
1364
+ readonly keywords: Readonly<Record<string, boolean>> | null;
1358
1365
  };
1359
1366
  type MailboxRuleMatchMode = "all" | "any";
1360
1367
  type MailboxRuleCondition = {
@@ -1463,6 +1470,13 @@ type ListInboxMessagesParams = {
1463
1470
  readonly folder_id?: string | undefined;
1464
1471
  readonly folder_role?: "inbox" | "starred" | "sent" | "drafts" | "archive" | "junk" | "trash" | undefined;
1465
1472
  readonly search_text?: string | undefined;
1473
+ /** Matches the From name or address. */
1474
+ readonly from?: string | undefined;
1475
+ /** Matches the To recipients by name or address. Cc and Bcc are not searched. */
1476
+ readonly to?: string | undefined;
1477
+ readonly subject?: string | undefined;
1478
+ /** `true` for messages with an attachment, `false` for messages without one. */
1479
+ readonly has_attachment?: boolean | undefined;
1466
1480
  readonly cursor?: string | undefined;
1467
1481
  readonly after?: string | undefined;
1468
1482
  readonly before?: string | undefined;
@@ -1724,6 +1738,7 @@ type Newsletter = {
1724
1738
  readonly feed_entry_url: string | null;
1725
1739
  readonly styling_mode: NewsletterStylingMode;
1726
1740
  readonly track_engagement: boolean;
1741
+ readonly add_utm_tags: boolean;
1727
1742
  readonly opened_count: number | null;
1728
1743
  readonly clicked_count: number | null;
1729
1744
  readonly preflight_status: NewsletterPreflightStatus;
@@ -1815,6 +1830,7 @@ type CreateNewsletterParams = {
1815
1830
  readonly feed_entry_url?: string | null | undefined;
1816
1831
  readonly styling_mode?: NewsletterStylingMode | undefined;
1817
1832
  readonly track_engagement?: boolean | undefined;
1833
+ readonly add_utm_tags?: boolean | undefined;
1818
1834
  };
1819
1835
  type UpdateNewsletterParams = Partial<CreateNewsletterParams>;
1820
1836
  type NewsletterChangelogMedia = {
@@ -2225,6 +2241,9 @@ type Webhook = {
2225
2241
  readonly domain_ids: readonly string[] | null;
2226
2242
  readonly has_authorization: boolean;
2227
2243
  readonly has_standard_webhooks_secret: boolean;
2244
+ readonly include_reply_text: boolean;
2245
+ readonly authenticated_senders_only: boolean;
2246
+ readonly allowed_senders: readonly string[] | null;
2228
2247
  readonly created_at: string;
2229
2248
  readonly updated_at: string;
2230
2249
  };
@@ -2241,6 +2260,12 @@ type CreateWebhookParams = {
2241
2260
  readonly authorization?: string | null | undefined;
2242
2261
  /** A `whsec_` secret from the receiving service. Deliveries then carry Standard Webhooks signatures. Write-only. */
2243
2262
  readonly standard_webhooks_secret?: string | null | undefined;
2263
+ /** Add `reply_text` to `message.received` deliveries. The API key also needs `messages:read`. */
2264
+ readonly include_reply_text?: boolean | undefined;
2265
+ /** Skip `message.received` deliveries whose sender did not pass DMARC. */
2266
+ readonly authenticated_senders_only?: boolean | undefined;
2267
+ /** Deliver `message.received` only from these addresses or exact domains. At most 100. */
2268
+ readonly allowed_senders?: readonly string[] | null | undefined;
2244
2269
  };
2245
2270
  type UpdateWebhookParams = {
2246
2271
  readonly url?: string | undefined;
@@ -2253,6 +2278,12 @@ type UpdateWebhookParams = {
2253
2278
  readonly authorization?: string | null | undefined;
2254
2279
  /** A string replaces the Standard Webhooks signing secret, `null` removes it. */
2255
2280
  readonly standard_webhooks_secret?: string | null | undefined;
2281
+ /** Add `reply_text` to `message.received` deliveries. The API key also needs `messages:read`. */
2282
+ readonly include_reply_text?: boolean | undefined;
2283
+ /** Skip `message.received` deliveries whose sender did not pass DMARC. */
2284
+ readonly authenticated_senders_only?: boolean | undefined;
2285
+ /** Replaces the sender list. `null` or `[]` delivers every sender again. */
2286
+ readonly allowed_senders?: readonly string[] | null | undefined;
2256
2287
  };
2257
2288
  type ListWebhooksParams = PaginationParams;
2258
2289
  type RotateSecretResponse = {
package/dist/index.js CHANGED
@@ -849,6 +849,10 @@ var Mailboxes = class extends ApiResource {
849
849
  folder_id: params?.folder_id,
850
850
  folder_role: params?.folder_role,
851
851
  search_text: params?.search_text,
852
+ from: params?.from,
853
+ to: params?.to,
854
+ subject: params?.subject,
855
+ has_attachment: params?.has_attachment,
852
856
  cursor: params?.cursor,
853
857
  after: params?.after,
854
858
  before: params?.before,
@@ -1661,7 +1665,7 @@ var Webhooks = class extends ApiResource {
1661
1665
  };
1662
1666
 
1663
1667
  // src/version.ts
1664
- var VERSION = "0.6.4";
1668
+ var VERSION = "0.6.5";
1665
1669
 
1666
1670
  // src/client.ts
1667
1671
  var DEFAULT_BASE_URL = "https://shipmail.to/api/v1";