shipmail 0.4.21 → 0.4.23
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/api-key-scopes.cjs +2 -0
- package/dist/api-key-scopes.cjs.map +1 -1
- package/dist/api-key-scopes.d.cts +1 -1
- package/dist/api-key-scopes.d.ts +1 -1
- package/dist/api-key-scopes.js +2 -0
- package/dist/api-key-scopes.js.map +1 -1
- package/dist/index.cjs +44 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +61 -1
- package/dist/index.d.ts +61 -1
- package/dist/index.js +44 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1443,6 +1443,46 @@ type UpdateAutoReplyParams = {
|
|
|
1443
1443
|
readonly from_date?: string | null | undefined;
|
|
1444
1444
|
readonly to_date?: string | null | undefined;
|
|
1445
1445
|
};
|
|
1446
|
+
type MailboxDeliveryDestination = {
|
|
1447
|
+
readonly id: string;
|
|
1448
|
+
readonly address: string;
|
|
1449
|
+
readonly display_name: string | null;
|
|
1450
|
+
readonly status: "available" | "out_of_office" | "suspended" | "archived" | "unavailable";
|
|
1451
|
+
readonly out_of_office_end_at: string | null;
|
|
1452
|
+
readonly responsible_member_count: number;
|
|
1453
|
+
readonly push_ready_member_count: number;
|
|
1454
|
+
};
|
|
1455
|
+
type MailboxDeliveryRouting = {
|
|
1456
|
+
readonly object: "mailbox_delivery_routing";
|
|
1457
|
+
readonly mailbox_id: string;
|
|
1458
|
+
readonly source_address: string;
|
|
1459
|
+
readonly destinations: readonly MailboxDeliveryDestination[];
|
|
1460
|
+
} & ({
|
|
1461
|
+
readonly mode: "keep";
|
|
1462
|
+
} | {
|
|
1463
|
+
readonly mode: "fixed";
|
|
1464
|
+
readonly destination_mailbox_id: string;
|
|
1465
|
+
readonly fallback_mailbox_id: string;
|
|
1466
|
+
readonly activation_state: "pending" | "active" | "failed";
|
|
1467
|
+
readonly activation_error: string | null;
|
|
1468
|
+
} | {
|
|
1469
|
+
readonly mode: "round_robin";
|
|
1470
|
+
readonly destination_mailbox_ids: readonly string[];
|
|
1471
|
+
readonly fallback_mailbox_id: string;
|
|
1472
|
+
readonly activation_state: "pending" | "active" | "failed";
|
|
1473
|
+
readonly activation_error: string | null;
|
|
1474
|
+
});
|
|
1475
|
+
type UpdateMailboxDeliveryRoutingParams = {
|
|
1476
|
+
readonly mode: "keep";
|
|
1477
|
+
} | {
|
|
1478
|
+
readonly mode: "fixed";
|
|
1479
|
+
readonly destination_mailbox_id: string;
|
|
1480
|
+
readonly fallback_mailbox_id: string;
|
|
1481
|
+
} | {
|
|
1482
|
+
readonly mode: "round_robin";
|
|
1483
|
+
readonly destination_mailbox_ids: readonly string[];
|
|
1484
|
+
readonly fallback_mailbox_id: string;
|
|
1485
|
+
};
|
|
1446
1486
|
type UpdateSpamFilterParams = {
|
|
1447
1487
|
readonly threshold: number;
|
|
1448
1488
|
};
|
|
@@ -1492,6 +1532,8 @@ declare class Mailboxes extends ApiResource {
|
|
|
1492
1532
|
createForwarding(id: string, params: CreateMailboxForwardingParams, options?: MethodOptions): Promise<MailboxForwarding>;
|
|
1493
1533
|
deleteForwarding(id: string, forwardingId: string, options?: MethodOptions): Promise<void>;
|
|
1494
1534
|
updateAutoReply(id: string, params: UpdateAutoReplyParams, options?: MethodOptions): Promise<Mailbox>;
|
|
1535
|
+
getDeliveryRouting(id: string, options?: MethodOptions): Promise<MailboxDeliveryRouting>;
|
|
1536
|
+
updateDeliveryRouting(id: string, params: UpdateMailboxDeliveryRoutingParams, options?: MethodOptions): Promise<MailboxDeliveryRouting>;
|
|
1495
1537
|
updateSpamFilter(id: string, params: UpdateSpamFilterParams, options?: MethodOptions): Promise<Mailbox>;
|
|
1496
1538
|
createImport(id: string, params: CreateMailboxImportParams, options?: MethodOptions): Promise<MailboxImport>;
|
|
1497
1539
|
listImports(id: string, options?: MethodOptions): Promise<MailboxImports>;
|
|
@@ -1505,6 +1547,23 @@ declare class Mailboxes extends ApiResource {
|
|
|
1505
1547
|
abortImportUpload(id: string, fileId: string, options?: MethodOptions): Promise<void>;
|
|
1506
1548
|
}
|
|
1507
1549
|
|
|
1550
|
+
type MemberRole = "owner" | "super_admin" | "admin" | "member";
|
|
1551
|
+
type Member = {
|
|
1552
|
+
readonly object: "member";
|
|
1553
|
+
readonly id: string;
|
|
1554
|
+
readonly email: string;
|
|
1555
|
+
readonly name: string;
|
|
1556
|
+
readonly role: MemberRole;
|
|
1557
|
+
readonly created_at: string;
|
|
1558
|
+
};
|
|
1559
|
+
type ListMembersParams = PaginationParams;
|
|
1560
|
+
|
|
1561
|
+
declare class Members extends ApiResource {
|
|
1562
|
+
list(params?: ListMembersParams, options?: MethodOptions): Promise<PaginatedResponse<Member>>;
|
|
1563
|
+
listAutoPaginating(params?: Omit<ListMembersParams, "cursor">): Page<Member>;
|
|
1564
|
+
get(id: string, options?: MethodOptions): Promise<Member>;
|
|
1565
|
+
}
|
|
1566
|
+
|
|
1508
1567
|
declare class Messages extends ApiResource {
|
|
1509
1568
|
send(params: SendMessageParams, options?: MethodOptions): Promise<Message>;
|
|
1510
1569
|
list(params: ListMessagesParams, options?: MethodOptions): Promise<PaginatedResponse<Message>>;
|
|
@@ -2230,6 +2289,7 @@ declare class ShipmailClient {
|
|
|
2230
2289
|
readonly calendar: Calendar;
|
|
2231
2290
|
readonly domains: Domains;
|
|
2232
2291
|
readonly mailboxes: Mailboxes;
|
|
2292
|
+
readonly members: Members;
|
|
2233
2293
|
readonly messages: Messages;
|
|
2234
2294
|
readonly newsletters: Newsletters;
|
|
2235
2295
|
readonly partner: Partner;
|
|
@@ -2323,4 +2383,4 @@ declare function verifyWebhook(body: string, headers: WebhookHeaders | Headers,
|
|
|
2323
2383
|
readonly toleranceInSeconds?: number | undefined;
|
|
2324
2384
|
}): Promise<WebhookEvent>;
|
|
2325
2385
|
|
|
2326
|
-
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 InboxThreadAttentionResult, type InboxThreadAttentionState, 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 UpdateInboxThreadAttentionParams, 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 };
|
|
2386
|
+
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 InboxThreadAttentionResult, type InboxThreadAttentionState, 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 ListMembersParams, 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 MailboxDeliveryDestination, type MailboxDeliveryRouting, 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 Member, type MemberRole, 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 UpdateInboxThreadAttentionParams, type UpdateMailboxDeliveryRoutingParams, 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
|
@@ -1443,6 +1443,46 @@ type UpdateAutoReplyParams = {
|
|
|
1443
1443
|
readonly from_date?: string | null | undefined;
|
|
1444
1444
|
readonly to_date?: string | null | undefined;
|
|
1445
1445
|
};
|
|
1446
|
+
type MailboxDeliveryDestination = {
|
|
1447
|
+
readonly id: string;
|
|
1448
|
+
readonly address: string;
|
|
1449
|
+
readonly display_name: string | null;
|
|
1450
|
+
readonly status: "available" | "out_of_office" | "suspended" | "archived" | "unavailable";
|
|
1451
|
+
readonly out_of_office_end_at: string | null;
|
|
1452
|
+
readonly responsible_member_count: number;
|
|
1453
|
+
readonly push_ready_member_count: number;
|
|
1454
|
+
};
|
|
1455
|
+
type MailboxDeliveryRouting = {
|
|
1456
|
+
readonly object: "mailbox_delivery_routing";
|
|
1457
|
+
readonly mailbox_id: string;
|
|
1458
|
+
readonly source_address: string;
|
|
1459
|
+
readonly destinations: readonly MailboxDeliveryDestination[];
|
|
1460
|
+
} & ({
|
|
1461
|
+
readonly mode: "keep";
|
|
1462
|
+
} | {
|
|
1463
|
+
readonly mode: "fixed";
|
|
1464
|
+
readonly destination_mailbox_id: string;
|
|
1465
|
+
readonly fallback_mailbox_id: string;
|
|
1466
|
+
readonly activation_state: "pending" | "active" | "failed";
|
|
1467
|
+
readonly activation_error: string | null;
|
|
1468
|
+
} | {
|
|
1469
|
+
readonly mode: "round_robin";
|
|
1470
|
+
readonly destination_mailbox_ids: readonly string[];
|
|
1471
|
+
readonly fallback_mailbox_id: string;
|
|
1472
|
+
readonly activation_state: "pending" | "active" | "failed";
|
|
1473
|
+
readonly activation_error: string | null;
|
|
1474
|
+
});
|
|
1475
|
+
type UpdateMailboxDeliveryRoutingParams = {
|
|
1476
|
+
readonly mode: "keep";
|
|
1477
|
+
} | {
|
|
1478
|
+
readonly mode: "fixed";
|
|
1479
|
+
readonly destination_mailbox_id: string;
|
|
1480
|
+
readonly fallback_mailbox_id: string;
|
|
1481
|
+
} | {
|
|
1482
|
+
readonly mode: "round_robin";
|
|
1483
|
+
readonly destination_mailbox_ids: readonly string[];
|
|
1484
|
+
readonly fallback_mailbox_id: string;
|
|
1485
|
+
};
|
|
1446
1486
|
type UpdateSpamFilterParams = {
|
|
1447
1487
|
readonly threshold: number;
|
|
1448
1488
|
};
|
|
@@ -1492,6 +1532,8 @@ declare class Mailboxes extends ApiResource {
|
|
|
1492
1532
|
createForwarding(id: string, params: CreateMailboxForwardingParams, options?: MethodOptions): Promise<MailboxForwarding>;
|
|
1493
1533
|
deleteForwarding(id: string, forwardingId: string, options?: MethodOptions): Promise<void>;
|
|
1494
1534
|
updateAutoReply(id: string, params: UpdateAutoReplyParams, options?: MethodOptions): Promise<Mailbox>;
|
|
1535
|
+
getDeliveryRouting(id: string, options?: MethodOptions): Promise<MailboxDeliveryRouting>;
|
|
1536
|
+
updateDeliveryRouting(id: string, params: UpdateMailboxDeliveryRoutingParams, options?: MethodOptions): Promise<MailboxDeliveryRouting>;
|
|
1495
1537
|
updateSpamFilter(id: string, params: UpdateSpamFilterParams, options?: MethodOptions): Promise<Mailbox>;
|
|
1496
1538
|
createImport(id: string, params: CreateMailboxImportParams, options?: MethodOptions): Promise<MailboxImport>;
|
|
1497
1539
|
listImports(id: string, options?: MethodOptions): Promise<MailboxImports>;
|
|
@@ -1505,6 +1547,23 @@ declare class Mailboxes extends ApiResource {
|
|
|
1505
1547
|
abortImportUpload(id: string, fileId: string, options?: MethodOptions): Promise<void>;
|
|
1506
1548
|
}
|
|
1507
1549
|
|
|
1550
|
+
type MemberRole = "owner" | "super_admin" | "admin" | "member";
|
|
1551
|
+
type Member = {
|
|
1552
|
+
readonly object: "member";
|
|
1553
|
+
readonly id: string;
|
|
1554
|
+
readonly email: string;
|
|
1555
|
+
readonly name: string;
|
|
1556
|
+
readonly role: MemberRole;
|
|
1557
|
+
readonly created_at: string;
|
|
1558
|
+
};
|
|
1559
|
+
type ListMembersParams = PaginationParams;
|
|
1560
|
+
|
|
1561
|
+
declare class Members extends ApiResource {
|
|
1562
|
+
list(params?: ListMembersParams, options?: MethodOptions): Promise<PaginatedResponse<Member>>;
|
|
1563
|
+
listAutoPaginating(params?: Omit<ListMembersParams, "cursor">): Page<Member>;
|
|
1564
|
+
get(id: string, options?: MethodOptions): Promise<Member>;
|
|
1565
|
+
}
|
|
1566
|
+
|
|
1508
1567
|
declare class Messages extends ApiResource {
|
|
1509
1568
|
send(params: SendMessageParams, options?: MethodOptions): Promise<Message>;
|
|
1510
1569
|
list(params: ListMessagesParams, options?: MethodOptions): Promise<PaginatedResponse<Message>>;
|
|
@@ -2230,6 +2289,7 @@ declare class ShipmailClient {
|
|
|
2230
2289
|
readonly calendar: Calendar;
|
|
2231
2290
|
readonly domains: Domains;
|
|
2232
2291
|
readonly mailboxes: Mailboxes;
|
|
2292
|
+
readonly members: Members;
|
|
2233
2293
|
readonly messages: Messages;
|
|
2234
2294
|
readonly newsletters: Newsletters;
|
|
2235
2295
|
readonly partner: Partner;
|
|
@@ -2323,4 +2383,4 @@ declare function verifyWebhook(body: string, headers: WebhookHeaders | Headers,
|
|
|
2323
2383
|
readonly toleranceInSeconds?: number | undefined;
|
|
2324
2384
|
}): Promise<WebhookEvent>;
|
|
2325
2385
|
|
|
2326
|
-
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 InboxThreadAttentionResult, type InboxThreadAttentionState, 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 UpdateInboxThreadAttentionParams, 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 };
|
|
2386
|
+
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 InboxThreadAttentionResult, type InboxThreadAttentionState, 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 ListMembersParams, 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 MailboxDeliveryDestination, type MailboxDeliveryRouting, 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 Member, type MemberRole, 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 UpdateInboxThreadAttentionParams, type UpdateMailboxDeliveryRoutingParams, 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
|
@@ -20,6 +20,7 @@ var API_KEY_SCOPES = [
|
|
|
20
20
|
"mailbox_forwarding:write",
|
|
21
21
|
"mailbox_rules:read",
|
|
22
22
|
"mailbox_rules:write",
|
|
23
|
+
"members:read",
|
|
23
24
|
"messages:read",
|
|
24
25
|
"messages:write",
|
|
25
26
|
"drafts:write",
|
|
@@ -58,6 +59,7 @@ var API_KEY_SCOPE_DESCRIPTIONS = {
|
|
|
58
59
|
"mailbox_forwarding:write": "Create and remove forwarding destinations for allowed mailboxes.",
|
|
59
60
|
"mailbox_rules:read": "List deterministic server-side rules for allowed mailboxes.",
|
|
60
61
|
"mailbox_rules:write": "Create, replace, and remove deterministic rules for allowed mailboxes.",
|
|
62
|
+
"members:read": "List and retrieve organization members.",
|
|
61
63
|
"messages:read": "List and retrieve messages.",
|
|
62
64
|
"messages:write": "Update, move, delete, and inject sandbox messages.",
|
|
63
65
|
"drafts:write": "Create agent-safe reply drafts with server-derived recipients.",
|
|
@@ -999,6 +1001,21 @@ var Mailboxes = class extends ApiResource {
|
|
|
999
1001
|
methodOptions: options
|
|
1000
1002
|
});
|
|
1001
1003
|
}
|
|
1004
|
+
getDeliveryRouting(id, options) {
|
|
1005
|
+
return this.client.request({
|
|
1006
|
+
method: "GET",
|
|
1007
|
+
path: `/mailboxes/${encodeURIComponent(id)}/delivery-routing`,
|
|
1008
|
+
methodOptions: options
|
|
1009
|
+
});
|
|
1010
|
+
}
|
|
1011
|
+
updateDeliveryRouting(id, params, options) {
|
|
1012
|
+
return this.client.request({
|
|
1013
|
+
method: "PATCH",
|
|
1014
|
+
path: `/mailboxes/${encodeURIComponent(id)}/delivery-routing`,
|
|
1015
|
+
body: params,
|
|
1016
|
+
methodOptions: options
|
|
1017
|
+
});
|
|
1018
|
+
}
|
|
1002
1019
|
updateSpamFilter(id, params, options) {
|
|
1003
1020
|
return this.client.request({
|
|
1004
1021
|
method: "PATCH",
|
|
@@ -1083,6 +1100,31 @@ var Mailboxes = class extends ApiResource {
|
|
|
1083
1100
|
}
|
|
1084
1101
|
};
|
|
1085
1102
|
|
|
1103
|
+
// src/resources/members.ts
|
|
1104
|
+
var Members = class extends ApiResource {
|
|
1105
|
+
list(params, options) {
|
|
1106
|
+
return this.client.request({
|
|
1107
|
+
method: "GET",
|
|
1108
|
+
path: "/members",
|
|
1109
|
+
query: {
|
|
1110
|
+
cursor: params?.cursor,
|
|
1111
|
+
limit: params?.limit
|
|
1112
|
+
},
|
|
1113
|
+
methodOptions: options
|
|
1114
|
+
});
|
|
1115
|
+
}
|
|
1116
|
+
listAutoPaginating(params) {
|
|
1117
|
+
return new Page(this.client, "/members", { limit: params?.limit });
|
|
1118
|
+
}
|
|
1119
|
+
get(id, options) {
|
|
1120
|
+
return this.client.request({
|
|
1121
|
+
method: "GET",
|
|
1122
|
+
path: `/members/${encodeURIComponent(id)}`,
|
|
1123
|
+
methodOptions: options
|
|
1124
|
+
});
|
|
1125
|
+
}
|
|
1126
|
+
};
|
|
1127
|
+
|
|
1086
1128
|
// src/resources/messages.ts
|
|
1087
1129
|
var Messages = class extends ApiResource {
|
|
1088
1130
|
send(params, options) {
|
|
@@ -1647,7 +1689,7 @@ var Webhooks = class extends ApiResource {
|
|
|
1647
1689
|
};
|
|
1648
1690
|
|
|
1649
1691
|
// src/version.ts
|
|
1650
|
-
var VERSION = "0.4.
|
|
1692
|
+
var VERSION = "0.4.23";
|
|
1651
1693
|
|
|
1652
1694
|
// src/client.ts
|
|
1653
1695
|
var DEFAULT_BASE_URL = "https://shipmail.to/api/v1";
|
|
@@ -1707,6 +1749,7 @@ var ShipmailClient = class {
|
|
|
1707
1749
|
this.calendar = new Calendar(this);
|
|
1708
1750
|
this.domains = new Domains(this);
|
|
1709
1751
|
this.mailboxes = new Mailboxes(this);
|
|
1752
|
+
this.members = new Members(this);
|
|
1710
1753
|
this.messages = new Messages(this);
|
|
1711
1754
|
this.newsletters = new Newsletters(this);
|
|
1712
1755
|
this.partner = new Partner(this);
|