shipmail 0.4.14 → 0.4.16

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
@@ -389,6 +389,7 @@ declare class BookingPages extends ApiResource {
389
389
  type CalendarEventStatus = "confirmed" | "tentative" | "cancelled";
390
390
  type CalendarFreeBusyStatus = "free" | "busy";
391
391
  type CalendarEventPrivacy = "public" | "private" | "secret";
392
+ type CalendarInvitationLanguage = "en" | "fr" | "es";
392
393
  type RecurrenceFrequency = "yearly" | "monthly" | "weekly" | "daily" | "hourly" | "minutely" | "secondly";
393
394
  type Weekday = "mo" | "tu" | "we" | "th" | "fr" | "sa" | "su";
394
395
  type RecurrenceNDay = {
@@ -423,6 +424,7 @@ type CalendarEvent = {
423
424
  readonly calendar_id: string | null;
424
425
  readonly uid: string | null;
425
426
  readonly title: string | null;
427
+ readonly invitation_language: CalendarInvitationLanguage;
426
428
  readonly description: string | null;
427
429
  readonly location: string | null;
428
430
  readonly video_url: string | null;
@@ -460,6 +462,7 @@ type CreateCalendarEventParams = {
460
462
  readonly mailbox: string;
461
463
  readonly calendar_id?: string | undefined;
462
464
  readonly title: string;
465
+ readonly invitation_language?: CalendarInvitationLanguage | undefined;
463
466
  readonly start: string;
464
467
  readonly description?: string | undefined;
465
468
  readonly timezone?: string | undefined;
@@ -478,6 +481,7 @@ type CreateCalendarEventParams = {
478
481
  type UpdateCalendarEventParams = {
479
482
  readonly mailbox: string;
480
483
  readonly title?: string | undefined;
484
+ readonly invitation_language?: CalendarInvitationLanguage | undefined;
481
485
  readonly description?: string | null | undefined;
482
486
  readonly start?: string | undefined;
483
487
  readonly timezone?: string | null | undefined;
@@ -1482,6 +1486,7 @@ type NewsletterPreflightStatus = "not_run" | "passed" | "warning" | "failed";
1482
1486
  type NewsletterPreflightItemStatus = "pass" | "warn" | "fail";
1483
1487
  type NewsletterTestSendStatus = "pending" | "sent" | "failed";
1484
1488
  type NewsletterAssetKind = "image" | "video";
1489
+ type NewsletterAssetContentType = "image/gif" | "image/jpeg" | "image/png" | "image/webp" | "video/mp4" | "video/quicktime" | "video/webm";
1485
1490
  type NewsletterUrlSource = "href" | "image_src" | "video_href" | "text";
1486
1491
  type NewsletterChangelogTone = "concise" | "friendly" | "technical";
1487
1492
  type NewsletterCalloutVariant = "accent" | "info" | "warning" | "success";
@@ -1537,6 +1542,7 @@ type Newsletter = {
1537
1542
  readonly body_text: string | null;
1538
1543
  readonly status: NewsletterStatus;
1539
1544
  readonly archive_visibility: NewsletterArchiveVisibility;
1545
+ readonly feed_entry_url: string | null;
1540
1546
  readonly styling_mode: NewsletterStylingMode;
1541
1547
  readonly preflight_status: NewsletterPreflightStatus;
1542
1548
  readonly preflight_results: Record<string, unknown>;
@@ -1624,6 +1630,7 @@ type CreateNewsletterParams = {
1624
1630
  readonly blocks?: readonly NewsletterBlock[] | undefined;
1625
1631
  readonly send_window_hours?: number | undefined;
1626
1632
  readonly archive_visibility?: NewsletterArchiveVisibility | undefined;
1633
+ readonly feed_entry_url?: string | null | undefined;
1627
1634
  readonly styling_mode?: NewsletterStylingMode | undefined;
1628
1635
  };
1629
1636
  type UpdateNewsletterParams = Partial<CreateNewsletterParams>;
@@ -1662,6 +1669,7 @@ type CreateNewsletterFromChangelogParams = {
1662
1669
  } | undefined;
1663
1670
  readonly send_window_hours?: number | undefined;
1664
1671
  readonly archive_visibility?: NewsletterArchiveVisibility | undefined;
1672
+ readonly feed_entry_url?: string | null | undefined;
1665
1673
  readonly styling_mode?: NewsletterStylingMode | undefined;
1666
1674
  };
1667
1675
  type ListNewsletterDomainsParams = PaginationParams;
@@ -1716,6 +1724,23 @@ type UploadNewsletterAssetParams = {
1716
1724
  readonly data: ArrayBuffer | Uint8Array;
1717
1725
  readonly content_type?: string | undefined;
1718
1726
  };
1727
+ type PrepareNewsletterAssetUploadParams = {
1728
+ readonly filename: string;
1729
+ readonly content_type: NewsletterAssetContentType;
1730
+ readonly size: number;
1731
+ readonly sha256: string;
1732
+ };
1733
+ type NewsletterAssetUpload = {
1734
+ readonly object: "newsletter_asset_upload";
1735
+ readonly kind: NewsletterAssetKind;
1736
+ readonly filename: string;
1737
+ readonly content_type: NewsletterAssetContentType;
1738
+ readonly size: number;
1739
+ readonly sha256: string;
1740
+ readonly upload_url: string;
1741
+ readonly upload_method: "POST";
1742
+ readonly expires_at: string;
1743
+ };
1719
1744
  type RegisterNewsletterAssetFromUrlParams = {
1720
1745
  readonly url: string;
1721
1746
  readonly filename?: string | undefined;
@@ -1810,6 +1835,7 @@ declare class NewsletterAssets extends ApiResource {
1810
1835
  list(params?: ListNewsletterAssetsParams, options?: MethodOptions): Promise<NewsletterAssetListResponse>;
1811
1836
  listAutoPaginating(params?: Omit<ListNewsletterAssetsParams, "cursor">): Page<NewsletterAsset>;
1812
1837
  upload(params: UploadNewsletterAssetParams, options?: MethodOptions): Promise<NewsletterAsset>;
1838
+ prepareUpload(params: PrepareNewsletterAssetUploadParams, options?: MethodOptions): Promise<NewsletterAssetUpload>;
1813
1839
  registerFromUrl(params: RegisterNewsletterAssetFromUrlParams, options?: MethodOptions): Promise<NewsletterAsset>;
1814
1840
  }
1815
1841
  declare class Newsletters extends ApiResource {
@@ -2244,4 +2270,4 @@ declare function verifyWebhook(body: string, headers: WebhookHeaders | Headers,
2244
2270
  readonly toleranceInSeconds?: number | undefined;
2245
2271
  }): Promise<WebhookEvent>;
2246
2272
 
2247
- export { type AddSubscriberParams, type AddSubscribersBatchParams, type AddSubscribersBatchResult, type ApiErrorBody, type Audience, type AudienceFeed, AuthenticationError, AuthorizationError, type Automation, type AutomationAction, type AutomationCondition, type AutomationDefinition, type AutomationRun, type AutomationRunStatus, type AutomationRunSummary, type AutomationStatus, type AutomationTrigger, type BookingPage, CONFERENCING_PROVIDER_IDS, type CalendarAvailability, type CalendarAvailabilityParams, type CalendarAvailabilitySlot, type CalendarEvent, type CalendarEventPrivacy, type CalendarEventStatus, type CalendarFreeBusyStatus, type CapabilitiesResponse, type CapabilityResourceConstraints, type ConferencingProviderId, ConflictError, ConnectionError, type ConsumePartnerMailboxCredentialGrantParams, type CreateAudienceParams, type CreateAutomationParams, type CreateBookingPageParams, type CreateCalendarEventParams, type CreateDomainParams, type CreateInboxReplyDraftParams, type CreateMailboxAppPasswordParams, type CreateMailboxFolderParams, type CreateMailboxParams, type CreateNewsletterFromChangelogParams, type CreateNewsletterParams, type CreatePartnerOrganizationParams, type CreateReplyScanParams, type CreateWebhookParams, type CreatedMailboxAppPassword, type CreatedPartnerOrganization, DOMAIN_STATUSES, type DataMode, type DeleteCalendarEventParams, type Domain, type DomainDnsRecord, type DomainDnsRecordKey, type DomainDnsRecordSet, type DomainDnsRecordStatus, type DomainRegistrationInfo, type DomainSearchResult, type DomainStatus, type DomainVerificationResult, type DownloadInboxAttachmentParams, type EmailAuthVerdict, type EmailAuthenticationResults, type EmailRecipient, type EmailRecipientInput, type ErrorType, type GetCalendarEventParams, type GetThreadParams, type InboxAttachment, type InboxBodyPart, type InboxBodyValue, type InboxEmailHeader, type InboxFullMessage, type InboxKeyword, type InboxMessage, type InboxMessageAction, type InboxMessages, type InboxReplyDraft, type InboxReplyDraftSend, type InboxThread, type InboxThreadReplyState, type InboxThreadReplyStateResult, type InboxThreadSummary, type InboxThreads, type InjectSandboxInboundParams, InternalServerError, type ListAudiencesParams, type ListAutomationsResponse, type ListBookingPagesParams, type ListCalendarEventsParams, type ListDeliveriesParams, type ListDomainsParams, type ListInboxMessagesParams, type ListInboxThreadsParams, type ListMailboxesParams, type ListMessageAnalyticsParams, type ListMessagesParams, type ListNewsletterAssetsParams, type ListNewsletterDomainsParams, type ListNewsletterSenderIdentitiesParams, type ListNewslettersParams, type ListReplyScanResultsParams, type ListScheduledMessagesParams, type ListSubscribersParams, type ListSuppressionsParams, type ListThreadsParams, type ListWebhooksParams, MESSAGE_SOURCES, MESSAGE_STATUSES, type Mailbox, type MailboxAppPassword, type MailboxAppPasswordList, type MailboxAppPasswordPurpose, type MailboxAppPasswordState, type MailboxExport, type MailboxExportErrorCode, type MailboxExportStatus, type MailboxFolder, type MailboxFolders, type MailboxIdentities, type MailboxIdentity, type MailboxRule, type MailboxRuleAction, type MailboxRuleCondition, type MailboxRuleFolder, type MailboxRuleMatchMode, type MailboxRuleMoveTarget, type MailboxRules, type MergeFields, type Message, type MessageAnalytics, type MessageAnalyticsPage, type MessageMetadata, type MessageRuleDisposition, type MessageSource, type MessageStatus, type MethodOptions, type MoveInboxMessageParams, type Newsletter, type NewsletterArchiveVisibility, type NewsletterAsset, type NewsletterAssetKind, type NewsletterAssetListResponse, type NewsletterAssetStorageUsage, type NewsletterBlock, type NewsletterButtonAlign, type NewsletterCalloutVariant, type NewsletterChangelogEntry, type NewsletterChangelogMedia, type NewsletterChangelogTone, type NewsletterColumnContent, type NewsletterColumnRatio, type NewsletterCountedUrl, type NewsletterDomain, type NewsletterDomainRecordStatus, type NewsletterDomainStatus, type NewsletterPreflight, type NewsletterPreflightItem, type NewsletterPreflightItemStatus, type NewsletterPreflightStatus, type NewsletterPreview, type NewsletterSenderIdentity, type NewsletterStatus, type NewsletterStylingMode, type NewsletterTestSend, type NewsletterTestSendStatus, type NewsletterUrlBreakdown, type NewsletterUrlSource, NotFoundError, type OneTimeSecretMethodOptions, type OutboundHeader, Page, type PaginatedResponse, type PaginationParams, type PartnerDataClassification, type PartnerMailboxCredential, type PartnerMailboxCredentialGrant, type PartnerMailboxCredentialGrantList, type PartnerOrganization, type PartnerOrganizationList, type PartnerOrganizationStatus, type PartnerOwnershipInvitation, type PartnerUsage, type PrepareStagedAttachmentUploadParams, QuotaExceededError, RateLimitError, type Recurrence, type RecurrenceFrequency, type RecurrenceNDay, type RegisterDomainParams, type RegisterNewsletterAssetFromUrlParams, type RegistrationContact, type Reminder, type ReplyScan, type ReplyScanCandidate, type ReplyScanResults, type ReplyScanStatus, type ReplyToMessageParams, type ReplyToThreadParams, type RequestOptions, type ResetMailboxPasswordParams, type RotateSecretResponse, type SandboxOutcome, type ScheduleNewsletterParams, type ScheduledMessage, type ScheduledMessageAttachment, type ScheduledMessageList, type ScheduledMessageRecipient, type ScheduledMessageUploadedAttachment, type SearchDomainsParams, type SendMessageParams, type SendNewsletterTestParams, ShipmailClient, type ShipmailConfig, ShipmailError, type StageAttachmentParams, type StagedAttachment, type StagedAttachmentUpload, type StatusResponse, type Subscriber, type SubscriberOutcome, type SubscriberResult, type SubscriberStatus, type Suppression, type TestWebhookResponse, type Thread, type TransactionalRecipientBudget, type UpdateAudienceFeedParams, type UpdateAudienceParams, type UpdateAutoReplyParams, type UpdateAutomationParams, type UpdateBookingPageParams, type UpdateCalendarEventParams, type UpdateDomainParams, type UpdateInboxMessageParams, type UpdateInboxThreadReplyStateParams, type UpdateMailboxFolderParams, type UpdateMailboxParams, type UpdateMailboxRulesParams, type UpdateNewsletterParams, type UpdatePartnerOrganizationParams, type UpdateScheduledMessageParams, type UpdateSpamFilterParams, type UpdateSubscriberParams, type UpdateWebhookParams, type UploadNewsletterAssetParams, ValidationError, WEBHOOK_DELIVERY_EVENT_TYPES, WEBHOOK_DELIVERY_STATUSES, WEBHOOK_EVENT_TYPES, type Webhook, type WebhookDelivery, type WebhookDeliveryDetail, type WebhookDeliveryEventType, type WebhookDeliveryStatus, type WebhookEvent, type WebhookEventType, WebhookVerificationError, type WebhookWithSecret, type Weekday, ShipmailClient as default, verifyWebhook };
2273
+ export { type AddSubscriberParams, type AddSubscribersBatchParams, type AddSubscribersBatchResult, type ApiErrorBody, type Audience, type AudienceFeed, AuthenticationError, AuthorizationError, type Automation, type AutomationAction, type AutomationCondition, type AutomationDefinition, type AutomationRun, type AutomationRunStatus, type AutomationRunSummary, type AutomationStatus, type AutomationTrigger, type BookingPage, CONFERENCING_PROVIDER_IDS, type CalendarAvailability, type CalendarAvailabilityParams, type CalendarAvailabilitySlot, type CalendarEvent, type CalendarEventPrivacy, type CalendarEventStatus, type CalendarFreeBusyStatus, type CalendarInvitationLanguage, type CapabilitiesResponse, type CapabilityResourceConstraints, type ConferencingProviderId, ConflictError, ConnectionError, type ConsumePartnerMailboxCredentialGrantParams, type CreateAudienceParams, type CreateAutomationParams, type CreateBookingPageParams, type CreateCalendarEventParams, type CreateDomainParams, type CreateInboxReplyDraftParams, type CreateMailboxAppPasswordParams, type CreateMailboxFolderParams, type CreateMailboxParams, type CreateNewsletterFromChangelogParams, type CreateNewsletterParams, type CreatePartnerOrganizationParams, type CreateReplyScanParams, type CreateWebhookParams, type CreatedMailboxAppPassword, type CreatedPartnerOrganization, DOMAIN_STATUSES, type DataMode, type DeleteCalendarEventParams, type Domain, type DomainDnsRecord, type DomainDnsRecordKey, type DomainDnsRecordSet, type DomainDnsRecordStatus, type DomainRegistrationInfo, type DomainSearchResult, type DomainStatus, type DomainVerificationResult, type DownloadInboxAttachmentParams, type EmailAuthVerdict, type EmailAuthenticationResults, type EmailRecipient, type EmailRecipientInput, type ErrorType, type GetCalendarEventParams, type GetThreadParams, type InboxAttachment, type InboxBodyPart, type InboxBodyValue, type InboxEmailHeader, type InboxFullMessage, type InboxKeyword, type InboxMessage, type InboxMessageAction, type InboxMessages, type InboxReplyDraft, type InboxReplyDraftSend, type InboxThread, type InboxThreadReplyState, type InboxThreadReplyStateResult, type InboxThreadSummary, type InboxThreads, type InjectSandboxInboundParams, InternalServerError, type ListAudiencesParams, type ListAutomationsResponse, type ListBookingPagesParams, type ListCalendarEventsParams, type ListDeliveriesParams, type ListDomainsParams, type ListInboxMessagesParams, type ListInboxThreadsParams, type ListMailboxesParams, type ListMessageAnalyticsParams, type ListMessagesParams, type ListNewsletterAssetsParams, type ListNewsletterDomainsParams, type ListNewsletterSenderIdentitiesParams, type ListNewslettersParams, type ListReplyScanResultsParams, type ListScheduledMessagesParams, type ListSubscribersParams, type ListSuppressionsParams, type ListThreadsParams, type ListWebhooksParams, MESSAGE_SOURCES, MESSAGE_STATUSES, type Mailbox, type MailboxAppPassword, type MailboxAppPasswordList, type MailboxAppPasswordPurpose, type MailboxAppPasswordState, type MailboxExport, type MailboxExportErrorCode, type MailboxExportStatus, type MailboxFolder, type MailboxFolders, type MailboxIdentities, type MailboxIdentity, type MailboxRule, type MailboxRuleAction, type MailboxRuleCondition, type MailboxRuleFolder, type MailboxRuleMatchMode, type MailboxRuleMoveTarget, type MailboxRules, type MergeFields, type Message, type MessageAnalytics, type MessageAnalyticsPage, type MessageMetadata, type MessageRuleDisposition, type MessageSource, type MessageStatus, type MethodOptions, type MoveInboxMessageParams, type Newsletter, type NewsletterArchiveVisibility, type NewsletterAsset, type NewsletterAssetContentType, type NewsletterAssetKind, type NewsletterAssetListResponse, type NewsletterAssetStorageUsage, type NewsletterAssetUpload, type NewsletterBlock, type NewsletterButtonAlign, type NewsletterCalloutVariant, type NewsletterChangelogEntry, type NewsletterChangelogMedia, type NewsletterChangelogTone, type NewsletterColumnContent, type NewsletterColumnRatio, type NewsletterCountedUrl, type NewsletterDomain, type NewsletterDomainRecordStatus, type NewsletterDomainStatus, type NewsletterPreflight, type NewsletterPreflightItem, type NewsletterPreflightItemStatus, type NewsletterPreflightStatus, type NewsletterPreview, type NewsletterSenderIdentity, type NewsletterStatus, type NewsletterStylingMode, type NewsletterTestSend, type NewsletterTestSendStatus, type NewsletterUrlBreakdown, type NewsletterUrlSource, NotFoundError, type OneTimeSecretMethodOptions, type OutboundHeader, Page, type PaginatedResponse, type PaginationParams, type PartnerDataClassification, type PartnerMailboxCredential, type PartnerMailboxCredentialGrant, type PartnerMailboxCredentialGrantList, type PartnerOrganization, type PartnerOrganizationList, type PartnerOrganizationStatus, type PartnerOwnershipInvitation, type PartnerUsage, type PrepareNewsletterAssetUploadParams, type PrepareStagedAttachmentUploadParams, QuotaExceededError, RateLimitError, type Recurrence, type RecurrenceFrequency, type RecurrenceNDay, type RegisterDomainParams, type RegisterNewsletterAssetFromUrlParams, type RegistrationContact, type Reminder, type ReplyScan, type ReplyScanCandidate, type ReplyScanResults, type ReplyScanStatus, type ReplyToMessageParams, type ReplyToThreadParams, type RequestOptions, type ResetMailboxPasswordParams, type RotateSecretResponse, type SandboxOutcome, type ScheduleNewsletterParams, type ScheduledMessage, type ScheduledMessageAttachment, type ScheduledMessageList, type ScheduledMessageRecipient, type ScheduledMessageUploadedAttachment, type SearchDomainsParams, type SendMessageParams, type SendNewsletterTestParams, ShipmailClient, type ShipmailConfig, ShipmailError, type StageAttachmentParams, type StagedAttachment, type StagedAttachmentUpload, type StatusResponse, type Subscriber, type SubscriberOutcome, type SubscriberResult, type SubscriberStatus, type Suppression, type TestWebhookResponse, type Thread, type TransactionalRecipientBudget, type UpdateAudienceFeedParams, type UpdateAudienceParams, type UpdateAutoReplyParams, type UpdateAutomationParams, type UpdateBookingPageParams, type UpdateCalendarEventParams, type UpdateDomainParams, type UpdateInboxMessageParams, type UpdateInboxThreadReplyStateParams, type UpdateMailboxFolderParams, type UpdateMailboxParams, type UpdateMailboxRulesParams, type UpdateNewsletterParams, type UpdatePartnerOrganizationParams, type UpdateScheduledMessageParams, type UpdateSpamFilterParams, type UpdateSubscriberParams, type UpdateWebhookParams, type UploadNewsletterAssetParams, ValidationError, WEBHOOK_DELIVERY_EVENT_TYPES, WEBHOOK_DELIVERY_STATUSES, WEBHOOK_EVENT_TYPES, type Webhook, type WebhookDelivery, type WebhookDeliveryDetail, type WebhookDeliveryEventType, type WebhookDeliveryStatus, type WebhookEvent, type WebhookEventType, WebhookVerificationError, type WebhookWithSecret, type Weekday, ShipmailClient as default, verifyWebhook };
package/dist/index.d.ts CHANGED
@@ -389,6 +389,7 @@ declare class BookingPages extends ApiResource {
389
389
  type CalendarEventStatus = "confirmed" | "tentative" | "cancelled";
390
390
  type CalendarFreeBusyStatus = "free" | "busy";
391
391
  type CalendarEventPrivacy = "public" | "private" | "secret";
392
+ type CalendarInvitationLanguage = "en" | "fr" | "es";
392
393
  type RecurrenceFrequency = "yearly" | "monthly" | "weekly" | "daily" | "hourly" | "minutely" | "secondly";
393
394
  type Weekday = "mo" | "tu" | "we" | "th" | "fr" | "sa" | "su";
394
395
  type RecurrenceNDay = {
@@ -423,6 +424,7 @@ type CalendarEvent = {
423
424
  readonly calendar_id: string | null;
424
425
  readonly uid: string | null;
425
426
  readonly title: string | null;
427
+ readonly invitation_language: CalendarInvitationLanguage;
426
428
  readonly description: string | null;
427
429
  readonly location: string | null;
428
430
  readonly video_url: string | null;
@@ -460,6 +462,7 @@ type CreateCalendarEventParams = {
460
462
  readonly mailbox: string;
461
463
  readonly calendar_id?: string | undefined;
462
464
  readonly title: string;
465
+ readonly invitation_language?: CalendarInvitationLanguage | undefined;
463
466
  readonly start: string;
464
467
  readonly description?: string | undefined;
465
468
  readonly timezone?: string | undefined;
@@ -478,6 +481,7 @@ type CreateCalendarEventParams = {
478
481
  type UpdateCalendarEventParams = {
479
482
  readonly mailbox: string;
480
483
  readonly title?: string | undefined;
484
+ readonly invitation_language?: CalendarInvitationLanguage | undefined;
481
485
  readonly description?: string | null | undefined;
482
486
  readonly start?: string | undefined;
483
487
  readonly timezone?: string | null | undefined;
@@ -1482,6 +1486,7 @@ type NewsletterPreflightStatus = "not_run" | "passed" | "warning" | "failed";
1482
1486
  type NewsletterPreflightItemStatus = "pass" | "warn" | "fail";
1483
1487
  type NewsletterTestSendStatus = "pending" | "sent" | "failed";
1484
1488
  type NewsletterAssetKind = "image" | "video";
1489
+ type NewsletterAssetContentType = "image/gif" | "image/jpeg" | "image/png" | "image/webp" | "video/mp4" | "video/quicktime" | "video/webm";
1485
1490
  type NewsletterUrlSource = "href" | "image_src" | "video_href" | "text";
1486
1491
  type NewsletterChangelogTone = "concise" | "friendly" | "technical";
1487
1492
  type NewsletterCalloutVariant = "accent" | "info" | "warning" | "success";
@@ -1537,6 +1542,7 @@ type Newsletter = {
1537
1542
  readonly body_text: string | null;
1538
1543
  readonly status: NewsletterStatus;
1539
1544
  readonly archive_visibility: NewsletterArchiveVisibility;
1545
+ readonly feed_entry_url: string | null;
1540
1546
  readonly styling_mode: NewsletterStylingMode;
1541
1547
  readonly preflight_status: NewsletterPreflightStatus;
1542
1548
  readonly preflight_results: Record<string, unknown>;
@@ -1624,6 +1630,7 @@ type CreateNewsletterParams = {
1624
1630
  readonly blocks?: readonly NewsletterBlock[] | undefined;
1625
1631
  readonly send_window_hours?: number | undefined;
1626
1632
  readonly archive_visibility?: NewsletterArchiveVisibility | undefined;
1633
+ readonly feed_entry_url?: string | null | undefined;
1627
1634
  readonly styling_mode?: NewsletterStylingMode | undefined;
1628
1635
  };
1629
1636
  type UpdateNewsletterParams = Partial<CreateNewsletterParams>;
@@ -1662,6 +1669,7 @@ type CreateNewsletterFromChangelogParams = {
1662
1669
  } | undefined;
1663
1670
  readonly send_window_hours?: number | undefined;
1664
1671
  readonly archive_visibility?: NewsletterArchiveVisibility | undefined;
1672
+ readonly feed_entry_url?: string | null | undefined;
1665
1673
  readonly styling_mode?: NewsletterStylingMode | undefined;
1666
1674
  };
1667
1675
  type ListNewsletterDomainsParams = PaginationParams;
@@ -1716,6 +1724,23 @@ type UploadNewsletterAssetParams = {
1716
1724
  readonly data: ArrayBuffer | Uint8Array;
1717
1725
  readonly content_type?: string | undefined;
1718
1726
  };
1727
+ type PrepareNewsletterAssetUploadParams = {
1728
+ readonly filename: string;
1729
+ readonly content_type: NewsletterAssetContentType;
1730
+ readonly size: number;
1731
+ readonly sha256: string;
1732
+ };
1733
+ type NewsletterAssetUpload = {
1734
+ readonly object: "newsletter_asset_upload";
1735
+ readonly kind: NewsletterAssetKind;
1736
+ readonly filename: string;
1737
+ readonly content_type: NewsletterAssetContentType;
1738
+ readonly size: number;
1739
+ readonly sha256: string;
1740
+ readonly upload_url: string;
1741
+ readonly upload_method: "POST";
1742
+ readonly expires_at: string;
1743
+ };
1719
1744
  type RegisterNewsletterAssetFromUrlParams = {
1720
1745
  readonly url: string;
1721
1746
  readonly filename?: string | undefined;
@@ -1810,6 +1835,7 @@ declare class NewsletterAssets extends ApiResource {
1810
1835
  list(params?: ListNewsletterAssetsParams, options?: MethodOptions): Promise<NewsletterAssetListResponse>;
1811
1836
  listAutoPaginating(params?: Omit<ListNewsletterAssetsParams, "cursor">): Page<NewsletterAsset>;
1812
1837
  upload(params: UploadNewsletterAssetParams, options?: MethodOptions): Promise<NewsletterAsset>;
1838
+ prepareUpload(params: PrepareNewsletterAssetUploadParams, options?: MethodOptions): Promise<NewsletterAssetUpload>;
1813
1839
  registerFromUrl(params: RegisterNewsletterAssetFromUrlParams, options?: MethodOptions): Promise<NewsletterAsset>;
1814
1840
  }
1815
1841
  declare class Newsletters extends ApiResource {
@@ -2244,4 +2270,4 @@ declare function verifyWebhook(body: string, headers: WebhookHeaders | Headers,
2244
2270
  readonly toleranceInSeconds?: number | undefined;
2245
2271
  }): Promise<WebhookEvent>;
2246
2272
 
2247
- export { type AddSubscriberParams, type AddSubscribersBatchParams, type AddSubscribersBatchResult, type ApiErrorBody, type Audience, type AudienceFeed, AuthenticationError, AuthorizationError, type Automation, type AutomationAction, type AutomationCondition, type AutomationDefinition, type AutomationRun, type AutomationRunStatus, type AutomationRunSummary, type AutomationStatus, type AutomationTrigger, type BookingPage, CONFERENCING_PROVIDER_IDS, type CalendarAvailability, type CalendarAvailabilityParams, type CalendarAvailabilitySlot, type CalendarEvent, type CalendarEventPrivacy, type CalendarEventStatus, type CalendarFreeBusyStatus, type CapabilitiesResponse, type CapabilityResourceConstraints, type ConferencingProviderId, ConflictError, ConnectionError, type ConsumePartnerMailboxCredentialGrantParams, type CreateAudienceParams, type CreateAutomationParams, type CreateBookingPageParams, type CreateCalendarEventParams, type CreateDomainParams, type CreateInboxReplyDraftParams, type CreateMailboxAppPasswordParams, type CreateMailboxFolderParams, type CreateMailboxParams, type CreateNewsletterFromChangelogParams, type CreateNewsletterParams, type CreatePartnerOrganizationParams, type CreateReplyScanParams, type CreateWebhookParams, type CreatedMailboxAppPassword, type CreatedPartnerOrganization, DOMAIN_STATUSES, type DataMode, type DeleteCalendarEventParams, type Domain, type DomainDnsRecord, type DomainDnsRecordKey, type DomainDnsRecordSet, type DomainDnsRecordStatus, type DomainRegistrationInfo, type DomainSearchResult, type DomainStatus, type DomainVerificationResult, type DownloadInboxAttachmentParams, type EmailAuthVerdict, type EmailAuthenticationResults, type EmailRecipient, type EmailRecipientInput, type ErrorType, type GetCalendarEventParams, type GetThreadParams, type InboxAttachment, type InboxBodyPart, type InboxBodyValue, type InboxEmailHeader, type InboxFullMessage, type InboxKeyword, type InboxMessage, type InboxMessageAction, type InboxMessages, type InboxReplyDraft, type InboxReplyDraftSend, type InboxThread, type InboxThreadReplyState, type InboxThreadReplyStateResult, type InboxThreadSummary, type InboxThreads, type InjectSandboxInboundParams, InternalServerError, type ListAudiencesParams, type ListAutomationsResponse, type ListBookingPagesParams, type ListCalendarEventsParams, type ListDeliveriesParams, type ListDomainsParams, type ListInboxMessagesParams, type ListInboxThreadsParams, type ListMailboxesParams, type ListMessageAnalyticsParams, type ListMessagesParams, type ListNewsletterAssetsParams, type ListNewsletterDomainsParams, type ListNewsletterSenderIdentitiesParams, type ListNewslettersParams, type ListReplyScanResultsParams, type ListScheduledMessagesParams, type ListSubscribersParams, type ListSuppressionsParams, type ListThreadsParams, type ListWebhooksParams, MESSAGE_SOURCES, MESSAGE_STATUSES, type Mailbox, type MailboxAppPassword, type MailboxAppPasswordList, type MailboxAppPasswordPurpose, type MailboxAppPasswordState, type MailboxExport, type MailboxExportErrorCode, type MailboxExportStatus, type MailboxFolder, type MailboxFolders, type MailboxIdentities, type MailboxIdentity, type MailboxRule, type MailboxRuleAction, type MailboxRuleCondition, type MailboxRuleFolder, type MailboxRuleMatchMode, type MailboxRuleMoveTarget, type MailboxRules, type MergeFields, type Message, type MessageAnalytics, type MessageAnalyticsPage, type MessageMetadata, type MessageRuleDisposition, type MessageSource, type MessageStatus, type MethodOptions, type MoveInboxMessageParams, type Newsletter, type NewsletterArchiveVisibility, type NewsletterAsset, type NewsletterAssetKind, type NewsletterAssetListResponse, type NewsletterAssetStorageUsage, type NewsletterBlock, type NewsletterButtonAlign, type NewsletterCalloutVariant, type NewsletterChangelogEntry, type NewsletterChangelogMedia, type NewsletterChangelogTone, type NewsletterColumnContent, type NewsletterColumnRatio, type NewsletterCountedUrl, type NewsletterDomain, type NewsletterDomainRecordStatus, type NewsletterDomainStatus, type NewsletterPreflight, type NewsletterPreflightItem, type NewsletterPreflightItemStatus, type NewsletterPreflightStatus, type NewsletterPreview, type NewsletterSenderIdentity, type NewsletterStatus, type NewsletterStylingMode, type NewsletterTestSend, type NewsletterTestSendStatus, type NewsletterUrlBreakdown, type NewsletterUrlSource, NotFoundError, type OneTimeSecretMethodOptions, type OutboundHeader, Page, type PaginatedResponse, type PaginationParams, type PartnerDataClassification, type PartnerMailboxCredential, type PartnerMailboxCredentialGrant, type PartnerMailboxCredentialGrantList, type PartnerOrganization, type PartnerOrganizationList, type PartnerOrganizationStatus, type PartnerOwnershipInvitation, type PartnerUsage, type PrepareStagedAttachmentUploadParams, QuotaExceededError, RateLimitError, type Recurrence, type RecurrenceFrequency, type RecurrenceNDay, type RegisterDomainParams, type RegisterNewsletterAssetFromUrlParams, type RegistrationContact, type Reminder, type ReplyScan, type ReplyScanCandidate, type ReplyScanResults, type ReplyScanStatus, type ReplyToMessageParams, type ReplyToThreadParams, type RequestOptions, type ResetMailboxPasswordParams, type RotateSecretResponse, type SandboxOutcome, type ScheduleNewsletterParams, type ScheduledMessage, type ScheduledMessageAttachment, type ScheduledMessageList, type ScheduledMessageRecipient, type ScheduledMessageUploadedAttachment, type SearchDomainsParams, type SendMessageParams, type SendNewsletterTestParams, ShipmailClient, type ShipmailConfig, ShipmailError, type StageAttachmentParams, type StagedAttachment, type StagedAttachmentUpload, type StatusResponse, type Subscriber, type SubscriberOutcome, type SubscriberResult, type SubscriberStatus, type Suppression, type TestWebhookResponse, type Thread, type TransactionalRecipientBudget, type UpdateAudienceFeedParams, type UpdateAudienceParams, type UpdateAutoReplyParams, type UpdateAutomationParams, type UpdateBookingPageParams, type UpdateCalendarEventParams, type UpdateDomainParams, type UpdateInboxMessageParams, type UpdateInboxThreadReplyStateParams, type UpdateMailboxFolderParams, type UpdateMailboxParams, type UpdateMailboxRulesParams, type UpdateNewsletterParams, type UpdatePartnerOrganizationParams, type UpdateScheduledMessageParams, type UpdateSpamFilterParams, type UpdateSubscriberParams, type UpdateWebhookParams, type UploadNewsletterAssetParams, ValidationError, WEBHOOK_DELIVERY_EVENT_TYPES, WEBHOOK_DELIVERY_STATUSES, WEBHOOK_EVENT_TYPES, type Webhook, type WebhookDelivery, type WebhookDeliveryDetail, type WebhookDeliveryEventType, type WebhookDeliveryStatus, type WebhookEvent, type WebhookEventType, WebhookVerificationError, type WebhookWithSecret, type Weekday, ShipmailClient as default, verifyWebhook };
2273
+ export { type AddSubscriberParams, type AddSubscribersBatchParams, type AddSubscribersBatchResult, type ApiErrorBody, type Audience, type AudienceFeed, AuthenticationError, AuthorizationError, type Automation, type AutomationAction, type AutomationCondition, type AutomationDefinition, type AutomationRun, type AutomationRunStatus, type AutomationRunSummary, type AutomationStatus, type AutomationTrigger, type BookingPage, CONFERENCING_PROVIDER_IDS, type CalendarAvailability, type CalendarAvailabilityParams, type CalendarAvailabilitySlot, type CalendarEvent, type CalendarEventPrivacy, type CalendarEventStatus, type CalendarFreeBusyStatus, type CalendarInvitationLanguage, type CapabilitiesResponse, type CapabilityResourceConstraints, type ConferencingProviderId, ConflictError, ConnectionError, type ConsumePartnerMailboxCredentialGrantParams, type CreateAudienceParams, type CreateAutomationParams, type CreateBookingPageParams, type CreateCalendarEventParams, type CreateDomainParams, type CreateInboxReplyDraftParams, type CreateMailboxAppPasswordParams, type CreateMailboxFolderParams, type CreateMailboxParams, type CreateNewsletterFromChangelogParams, type CreateNewsletterParams, type CreatePartnerOrganizationParams, type CreateReplyScanParams, type CreateWebhookParams, type CreatedMailboxAppPassword, type CreatedPartnerOrganization, DOMAIN_STATUSES, type DataMode, type DeleteCalendarEventParams, type Domain, type DomainDnsRecord, type DomainDnsRecordKey, type DomainDnsRecordSet, type DomainDnsRecordStatus, type DomainRegistrationInfo, type DomainSearchResult, type DomainStatus, type DomainVerificationResult, type DownloadInboxAttachmentParams, type EmailAuthVerdict, type EmailAuthenticationResults, type EmailRecipient, type EmailRecipientInput, type ErrorType, type GetCalendarEventParams, type GetThreadParams, type InboxAttachment, type InboxBodyPart, type InboxBodyValue, type InboxEmailHeader, type InboxFullMessage, type InboxKeyword, type InboxMessage, type InboxMessageAction, type InboxMessages, type InboxReplyDraft, type InboxReplyDraftSend, type InboxThread, type InboxThreadReplyState, type InboxThreadReplyStateResult, type InboxThreadSummary, type InboxThreads, type InjectSandboxInboundParams, InternalServerError, type ListAudiencesParams, type ListAutomationsResponse, type ListBookingPagesParams, type ListCalendarEventsParams, type ListDeliveriesParams, type ListDomainsParams, type ListInboxMessagesParams, type ListInboxThreadsParams, type ListMailboxesParams, type ListMessageAnalyticsParams, type ListMessagesParams, type ListNewsletterAssetsParams, type ListNewsletterDomainsParams, type ListNewsletterSenderIdentitiesParams, type ListNewslettersParams, type ListReplyScanResultsParams, type ListScheduledMessagesParams, type ListSubscribersParams, type ListSuppressionsParams, type ListThreadsParams, type ListWebhooksParams, MESSAGE_SOURCES, MESSAGE_STATUSES, type Mailbox, type MailboxAppPassword, type MailboxAppPasswordList, type MailboxAppPasswordPurpose, type MailboxAppPasswordState, type MailboxExport, type MailboxExportErrorCode, type MailboxExportStatus, type MailboxFolder, type MailboxFolders, type MailboxIdentities, type MailboxIdentity, type MailboxRule, type MailboxRuleAction, type MailboxRuleCondition, type MailboxRuleFolder, type MailboxRuleMatchMode, type MailboxRuleMoveTarget, type MailboxRules, type MergeFields, type Message, type MessageAnalytics, type MessageAnalyticsPage, type MessageMetadata, type MessageRuleDisposition, type MessageSource, type MessageStatus, type MethodOptions, type MoveInboxMessageParams, type Newsletter, type NewsletterArchiveVisibility, type NewsletterAsset, type NewsletterAssetContentType, type NewsletterAssetKind, type NewsletterAssetListResponse, type NewsletterAssetStorageUsage, type NewsletterAssetUpload, type NewsletterBlock, type NewsletterButtonAlign, type NewsletterCalloutVariant, type NewsletterChangelogEntry, type NewsletterChangelogMedia, type NewsletterChangelogTone, type NewsletterColumnContent, type NewsletterColumnRatio, type NewsletterCountedUrl, type NewsletterDomain, type NewsletterDomainRecordStatus, type NewsletterDomainStatus, type NewsletterPreflight, type NewsletterPreflightItem, type NewsletterPreflightItemStatus, type NewsletterPreflightStatus, type NewsletterPreview, type NewsletterSenderIdentity, type NewsletterStatus, type NewsletterStylingMode, type NewsletterTestSend, type NewsletterTestSendStatus, type NewsletterUrlBreakdown, type NewsletterUrlSource, NotFoundError, type OneTimeSecretMethodOptions, type OutboundHeader, Page, type PaginatedResponse, type PaginationParams, type PartnerDataClassification, type PartnerMailboxCredential, type PartnerMailboxCredentialGrant, type PartnerMailboxCredentialGrantList, type PartnerOrganization, type PartnerOrganizationList, type PartnerOrganizationStatus, type PartnerOwnershipInvitation, type PartnerUsage, type PrepareNewsletterAssetUploadParams, type PrepareStagedAttachmentUploadParams, QuotaExceededError, RateLimitError, type Recurrence, type RecurrenceFrequency, type RecurrenceNDay, type RegisterDomainParams, type RegisterNewsletterAssetFromUrlParams, type RegistrationContact, type Reminder, type ReplyScan, type ReplyScanCandidate, type ReplyScanResults, type ReplyScanStatus, type ReplyToMessageParams, type ReplyToThreadParams, type RequestOptions, type ResetMailboxPasswordParams, type RotateSecretResponse, type SandboxOutcome, type ScheduleNewsletterParams, type ScheduledMessage, type ScheduledMessageAttachment, type ScheduledMessageList, type ScheduledMessageRecipient, type ScheduledMessageUploadedAttachment, type SearchDomainsParams, type SendMessageParams, type SendNewsletterTestParams, ShipmailClient, type ShipmailConfig, ShipmailError, type StageAttachmentParams, type StagedAttachment, type StagedAttachmentUpload, type StatusResponse, type Subscriber, type SubscriberOutcome, type SubscriberResult, type SubscriberStatus, type Suppression, type TestWebhookResponse, type Thread, type TransactionalRecipientBudget, type UpdateAudienceFeedParams, type UpdateAudienceParams, type UpdateAutoReplyParams, type UpdateAutomationParams, type UpdateBookingPageParams, type UpdateCalendarEventParams, type UpdateDomainParams, type UpdateInboxMessageParams, type UpdateInboxThreadReplyStateParams, type UpdateMailboxFolderParams, type UpdateMailboxParams, type UpdateMailboxRulesParams, type UpdateNewsletterParams, type UpdatePartnerOrganizationParams, type UpdateScheduledMessageParams, type UpdateSpamFilterParams, type UpdateSubscriberParams, type UpdateWebhookParams, type UploadNewsletterAssetParams, ValidationError, WEBHOOK_DELIVERY_EVENT_TYPES, WEBHOOK_DELIVERY_STATUSES, WEBHOOK_EVENT_TYPES, type Webhook, type WebhookDelivery, type WebhookDeliveryDetail, type WebhookDeliveryEventType, type WebhookDeliveryStatus, type WebhookEvent, type WebhookEventType, WebhookVerificationError, type WebhookWithSecret, type Weekday, ShipmailClient as default, verifyWebhook };
package/dist/index.js CHANGED
@@ -1176,6 +1176,14 @@ var NewsletterAssets = class extends ApiResource {
1176
1176
  methodOptions: options
1177
1177
  });
1178
1178
  }
1179
+ prepareUpload(params, options) {
1180
+ return this.client.request({
1181
+ method: "POST",
1182
+ path: "/newsletter-assets/upload-tokens",
1183
+ body: params,
1184
+ methodOptions: options
1185
+ });
1186
+ }
1179
1187
  registerFromUrl(params, options) {
1180
1188
  return this.client.request({
1181
1189
  method: "POST",
@@ -1609,7 +1617,7 @@ var Webhooks = class extends ApiResource {
1609
1617
  };
1610
1618
 
1611
1619
  // src/version.ts
1612
- var VERSION = "0.4.14";
1620
+ var VERSION = "0.4.16";
1613
1621
 
1614
1622
  // src/client.ts
1615
1623
  var DEFAULT_BASE_URL = "https://shipmail.to/api/v1";