groundmail 0.48.2 → 0.50.0
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/authjs.js +1 -1
- package/dist/better-auth.js +1 -1
- package/dist/{chunk-QL2SVEHL.js → chunk-V7U3TJZY.js} +13 -2
- package/dist/clerk.js +1 -1
- package/dist/{client-CGfDMp6Y.d.ts → client-BqaE8VYB.d.ts} +33 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/payload.js +1 -1
- package/package.json +1 -1
package/dist/authjs.js
CHANGED
package/dist/better-auth.js
CHANGED
|
@@ -1670,7 +1670,7 @@ function verifyWebhookSignature(secret, payload, header, toleranceSec = 300) {
|
|
|
1670
1670
|
}
|
|
1671
1671
|
|
|
1672
1672
|
// package.json
|
|
1673
|
-
var version = "0.
|
|
1673
|
+
var version = "0.50.0";
|
|
1674
1674
|
|
|
1675
1675
|
// src/automations.ts
|
|
1676
1676
|
var AutomationsResource = class {
|
|
@@ -2138,7 +2138,18 @@ var SmtpCredentialsResource = class {
|
|
|
2138
2138
|
method: "POST",
|
|
2139
2139
|
body: JSON.stringify({
|
|
2140
2140
|
...params.name ? { name: params.name } : {},
|
|
2141
|
-
...params.test ? { test: true } : {}
|
|
2141
|
+
...params.test ? { test: true } : {},
|
|
2142
|
+
...params.category !== void 0 ? { category: params.category } : {}
|
|
2143
|
+
})
|
|
2144
|
+
});
|
|
2145
|
+
}
|
|
2146
|
+
/** Rename a credential or change its category. The password stays the same. */
|
|
2147
|
+
async update(id, params) {
|
|
2148
|
+
return this.client.request(`/smtp-credentials/${encodeURIComponent(id)}`, {
|
|
2149
|
+
method: "PATCH",
|
|
2150
|
+
body: JSON.stringify({
|
|
2151
|
+
...params.name !== void 0 ? { name: params.name } : {},
|
|
2152
|
+
...params.category !== void 0 ? { category: params.category } : {}
|
|
2142
2153
|
})
|
|
2143
2154
|
});
|
|
2144
2155
|
}
|
package/dist/clerk.js
CHANGED
|
@@ -295,6 +295,13 @@ type InReplyToEmail = {
|
|
|
295
295
|
/** The tenant's external id when it was sent as a tenant, else null. */
|
|
296
296
|
tenant: string | null;
|
|
297
297
|
};
|
|
298
|
+
type ReceivedEmailForward = {
|
|
299
|
+
/** `rejected`: your URL answered 4xx and it wasn't retried. `failed`: retries ran out. */
|
|
300
|
+
status: 'pending' | 'delivered' | 'rejected' | 'failed';
|
|
301
|
+
attempts: number;
|
|
302
|
+
forwarded_at: string | null;
|
|
303
|
+
error: string | null;
|
|
304
|
+
};
|
|
298
305
|
type ReceivedEmail = {
|
|
299
306
|
id: string;
|
|
300
307
|
domain_id: string;
|
|
@@ -322,6 +329,8 @@ type ReceivedEmail = {
|
|
|
322
329
|
in_reply_to_email: InReplyToEmail | null;
|
|
323
330
|
attachment_count: number;
|
|
324
331
|
attachments: ReceivedEmailAttachment[];
|
|
332
|
+
/** Forwarding to the domain's URL; null when the domain had none when it arrived. */
|
|
333
|
+
forward?: ReceivedEmailForward | null;
|
|
325
334
|
text_body: string | null;
|
|
326
335
|
html_body: string | null;
|
|
327
336
|
auto_submitted: string | null;
|
|
@@ -480,12 +489,19 @@ type CreateApiKeyResult = {
|
|
|
480
489
|
token: string;
|
|
481
490
|
created_at: string;
|
|
482
491
|
};
|
|
492
|
+
type SmtpCredentialCategory = 'transactional' | 'product' | 'newsletter';
|
|
483
493
|
type SmtpCredential = {
|
|
484
494
|
id: string;
|
|
485
495
|
name: string;
|
|
486
496
|
password_prefix: string;
|
|
487
497
|
/** A test credential (`gmsmtp_test_…`): mail sent with it is simulated and never delivered. */
|
|
488
498
|
test: boolean;
|
|
499
|
+
/**
|
|
500
|
+
* The category every email sent with this credential gets, for apps that can't
|
|
501
|
+
* add headers. `null`: each email decides (an `X-Groundmail-Category` header, or
|
|
502
|
+
* transactional). A header on the email wins over this.
|
|
503
|
+
*/
|
|
504
|
+
category: SmtpCredentialCategory | null;
|
|
489
505
|
username: string;
|
|
490
506
|
host: string;
|
|
491
507
|
port: number;
|
|
@@ -508,6 +524,13 @@ type CreateSmtpCredentialParams = {
|
|
|
508
524
|
name?: string;
|
|
509
525
|
/** Create a test credential: mail sent with it is simulated and never delivered. */
|
|
510
526
|
test?: boolean;
|
|
527
|
+
/** The category every email sent with it gets. `newsletter` needs an approved account. */
|
|
528
|
+
category?: SmtpCredentialCategory | null;
|
|
529
|
+
};
|
|
530
|
+
type UpdateSmtpCredentialParams = {
|
|
531
|
+
name?: string;
|
|
532
|
+
/** `null` clears it: each email decides again. */
|
|
533
|
+
category?: SmtpCredentialCategory | null;
|
|
511
534
|
};
|
|
512
535
|
type CreateSmtpCredentialResult = SmtpCredential & {
|
|
513
536
|
password: string;
|
|
@@ -1262,6 +1285,10 @@ type Domain = {
|
|
|
1262
1285
|
inbound_spam_threshold?: number | null;
|
|
1263
1286
|
/** `flag` keeps spam with `spam_status: 'spam'`; `drop` discards it. */
|
|
1264
1287
|
inbound_spam_action?: 'flag' | 'drop';
|
|
1288
|
+
/** Received mail is also POSTed here as the raw message, with ?from= and ?to=. Null when not set. */
|
|
1289
|
+
inbound_forward_url?: string | null;
|
|
1290
|
+
/** Whether a forward secret is set (the secret is never returned). */
|
|
1291
|
+
inbound_forward_secret_set?: boolean;
|
|
1265
1292
|
/** Daily blocklist check of this domain and its main domain. */
|
|
1266
1293
|
blocklists?: DomainBlocklists;
|
|
1267
1294
|
/** The tenant that owns this domain (external id). Absent for an account-wide domain. */
|
|
@@ -1399,6 +1426,10 @@ type UpdateDomainParams = {
|
|
|
1399
1426
|
inbound_spam_threshold?: number | null;
|
|
1400
1427
|
/** What to do with received mail at or above the threshold. */
|
|
1401
1428
|
inbound_spam_action?: 'flag' | 'drop';
|
|
1429
|
+
/** An https:// URL to POST each received email to as the raw message; null stops forwarding. */
|
|
1430
|
+
inbound_forward_url?: string | null;
|
|
1431
|
+
/** Sent with each forward as `Authorization: Bearer`; null removes it. */
|
|
1432
|
+
inbound_forward_secret?: string | null;
|
|
1402
1433
|
};
|
|
1403
1434
|
type DnsProviderName = 'cloudflare' | 'godaddy' | 'vercel' | 'netlify' | 'digitalocean' | 'dnsimple';
|
|
1404
1435
|
type RemoteApplyDnsCredentials = {
|
|
@@ -2711,6 +2742,8 @@ declare class SmtpCredentialsResource {
|
|
|
2711
2742
|
constructor(client: Groundmail);
|
|
2712
2743
|
list(params?: ListSmtpCredentialsParams): Promise<ListSmtpCredentialsResult>;
|
|
2713
2744
|
create(params?: CreateSmtpCredentialParams): Promise<CreateSmtpCredentialResult>;
|
|
2745
|
+
/** Rename a credential or change its category. The password stays the same. */
|
|
2746
|
+
update(id: string, params: UpdateSmtpCredentialParams): Promise<SmtpCredential>;
|
|
2714
2747
|
remove(id: string): Promise<{
|
|
2715
2748
|
ok: boolean;
|
|
2716
2749
|
}>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as ApiErrorBody, D as DnsRecord } from './client-
|
|
2
|
-
export { a as ApiErrorCode, b as ApiKey, c as ApiKeyMigrationParams, d as ApiKeyScope, e as ApplyDnsParams, f as ApplyDnsRecordResult, g as ApplyDnsResult, h as Asset, i as Automation, j as AutomationBranchQuestion, k as AutomationBranchStep, l as AutomationInlineEmail, m as AutomationResult, n as AutomationRun, o as AutomationRunResponse, p as AutomationRunStatus, q as AutomationRunStep, r as AutomationRunStepStatus, s as AutomationSendEmailStep, t as AutomationStatus, u as AutomationStep, v as AutomationTemplateEmail, w as AutomationTrigger, B as Batch, x as BatchSendEmailResult, y as BounceType, z as Brand, C as BrandLogo, E as BrandSettings, F as BurrowGuardCheck, H as BurrowGuardReason, I as BurrowGuardResource, J as BurrowGuardSite, K as BurrowGuardSiteWithSecret, L as BurrowGuardVerifyParams, M as BurrowGuardVerifyResult, N as CancelBatchResult, O as CategoryOptOut, P as CategoryOptOutCategory, Q as CategoryUnsubscribedErrorDetails, R as ConnectTwilioParams, T as ContactWebhookEventPayload, U as CreateApiKeyParams, V as CreateApiKeyResult, W as CreateAutomationParams, X as CreateBurrowGuardSiteParams, Y as CreateDomainParams, Z as CreateDomainResult, _ as CreateMailboxParams, $ as CreateMigrationParams, a0 as CreateSenderParams, a1 as CreateSuppressionParams, a2 as CreateTemplateParams, a3 as CreateTenantParams, a4 as CreateWebhookParams, a5 as DEFAULT_API_BASE_URL, a6 as DailyRampLimitErrorDetails, a7 as DeleteMailboxResult, a8 as DeleteTenantResult, a9 as DeliverabilityBucket, aa as DeliverabilityDomainInsight, ab as DeliverabilityInsightsResult, ac as DeliverabilityMailServerRelay, ad as DeliverabilityWindow, ae as DmarcDailyPoint, af as DmarcMonitoring, ag as DmarcMonitoringDisabled, ah as DmarcReadiness, ai as DmarcReadinessVerdict, aj as DmarcSource, ak as DmarcSourceStatus, al as DmarcStatus, am as DnsProviderName, an as Domain, ao as DomainBimiAnalysis, ap as DomainBlocklistListing, aq as DomainBlocklistStatus, ar as DomainBlocklists, as as DomainDetailResult, at as DomainDmarcAnalysis, au as DomainDnsAnalysis, av as DomainStatus, aw as DomainTlsMode, ax as DomainTrackingDns, ay as DomainTrackingStatus, az as EmailDelivery, aA as EmailListItem, aB as EmailWebhookEventPayload, aC as EmailWebhookEventType, aD as EnableDmarcParams, aE as EnableDmarcResult, aF as EnrollmentSkip, aG as EventRecord, aH as ForwardMailboxParams, aI as GetMailboxThreadParams, G as Groundmail, aJ as GroundmailAccessToken, aK as GroundmailOptions, aL as GroundmailTokenOptions, aM as GroundmailTokenProvider, aN as HeldBackErrorDetails, aO as HeldBackReason, aP as HeldBackRecipient, aQ as InReplyToEmail, aR as InstantMailbox, aS as InstantMailboxParams, aT as ListApiKeysParams, aU as ListApiKeysResult, aV as ListAutomationRunsParams, aW as ListAutomationRunsResult, aX as ListAutomationsResult, aY as ListBurrowGuardChecksParams, aZ as ListBurrowGuardChecksResult, a_ as ListCategoryOptOutsParams, a$ as ListCategoryOptOutsResult, b0 as ListDomainsParams, b1 as ListDomainsResult, b2 as ListEmailsParams, b3 as ListEmailsResult, b4 as ListMailboxMessagesParams, b5 as ListMailboxMessagesResult, b6 as ListMailboxThreadsParams, b7 as ListMailboxThreadsResult, b8 as ListMailboxesParams, b9 as ListMailboxesResult, ba as ListReceivedEmailsParams, bb as ListReceivedEmailsResult, bc as ListSendersResult, bd as ListSuppressionsParams, be as ListSuppressionsResult, bf as ListTemplatesParams, bg as ListTemplatesResult, bh as ListTenantDomainsResult, bi as ListTenantsParams, bj as ListTenantsResult, bk as ListTestInboxEmailsParams, bl as ListTestInboxEmailsResult, bm as ListWebhookDeliveriesParams, bn as ListWebhookDeliveriesResult, bo as MAILBOX_WAIT_DEFAULT_MS, bp as MAILBOX_WAIT_MAX_SECONDS, bq as MailServerSigningStatus, br as MailStream, bs as Mailbox, bt as MailboxAttachment, bu as MailboxAttachmentDownload, bv as MailboxForwarding, bw as MailboxMessage, bx as MailboxMessageDetail, by as MailboxMessagesResource, bz as MailboxOutgoingAttachment, bA as MailboxSendResult, bB as MailboxStatus, bC as MailboxThread, bD as MailboxThreadDetail, bE as MailboxThreadsResource, bF as MailboxWebhookEventPayload, bG as MailboxesResource, bH as Migration, bI as MigrationDnsChange, bJ as MigrationDnsPlan, bK as MigrationDomainItem, bL as MigrationItemStatus, bM as MigrationProvider, bN as MigrationResource, bO as MigrationSummary, bP as MigrationTemplateItem, bQ as MigrationTotals, bR as MigrationWebhookItem, bS as ReceivedEmail, bT as ReceivedEmailAttachment, bU as ReceivedEmailAttachmentMeta, bV as RemoteApplyDnsCredentials, bW as RemoveCategoryOptOutOptions, bX as ReplyToMailboxMessageParams, bY as RunMigrationOptions, bZ as SendEmailParams, S as SendEmailResult, b_ as SendMailboxMessageParams, b$ as Sender, c0 as SesMigrationParams, c1 as StreamDeliverability, c2 as SuppressedErrorDetails, c3 as Suppression, c4 as TEST_INBOX_WAIT_DEFAULT_MS, c5 as TEST_INBOX_WAIT_MAX_SECONDS, c6 as Template, c7 as TemplateFormat, c8 as TemplateLintWarning, c9 as TemplateStarter, ca as TemplateStatus, cb as TemplateVersion, cc as Tenant, cd as TenantPauseSource, ce as TenantRamp, cf as TenantStats, cg as TenantStatsResult, ch as TenantStatus, ci as TenantStreamPolicy, cj as TestEmailWebhookParams, ck as TestEmailWebhookResult, cl as TestInbox, cm as TestInboxAddressOptions, cn as TestInboxEmail, co as TestInboxEmailDetail, cp as TestInboxHeader, cq as TestInboxResource, cr as TestInboxUsage, cs as TriggerEventParams, ct as TriggerEventResult, cu as TwilioIntegrationResponse, cv as TwilioIntegrationStatus, cw as UpdateAutomationParams, cx as UpdateBrandParams, cy as UpdateBurrowGuardSiteParams, cz as UpdateDomainParams, cA as UpdateEmailParams, cB as UpdateMailboxMessageParams, cC as UpdateMailboxParams, cD as UpdateMailboxThreadParams, cE as UpdateSenderParams, cF as UpdateTemplateParams, cG as UpdateTenantParams, cH as UpdateWebhookParams, cI as ValidateEmailResult, cJ as ValidationReason, cK as ValidationVerdict, cL as VerifyDomainResult, cM as WaitForMailboxMessageParams, cN as WaitForTestEmailParams, cO as WebhookDelivery, cP as WebhookDeliveryAttempt, cQ as WebhookDeliveryDetail, cR as WebhookDeliveryStatus, cS as WebhookEmailTag, cT as WebhookEndpoint, cU as WebhookEndpointHealth, cV as WebhookEndpointWithSecret, cW as WebhookEventType, cX as createInstantMailbox, cY as mergeMigrations, cZ as normalizeAccessToken } from './client-
|
|
1
|
+
import { A as ApiErrorBody, D as DnsRecord } from './client-BqaE8VYB.js';
|
|
2
|
+
export { a as ApiErrorCode, b as ApiKey, c as ApiKeyMigrationParams, d as ApiKeyScope, e as ApplyDnsParams, f as ApplyDnsRecordResult, g as ApplyDnsResult, h as Asset, i as Automation, j as AutomationBranchQuestion, k as AutomationBranchStep, l as AutomationInlineEmail, m as AutomationResult, n as AutomationRun, o as AutomationRunResponse, p as AutomationRunStatus, q as AutomationRunStep, r as AutomationRunStepStatus, s as AutomationSendEmailStep, t as AutomationStatus, u as AutomationStep, v as AutomationTemplateEmail, w as AutomationTrigger, B as Batch, x as BatchSendEmailResult, y as BounceType, z as Brand, C as BrandLogo, E as BrandSettings, F as BurrowGuardCheck, H as BurrowGuardReason, I as BurrowGuardResource, J as BurrowGuardSite, K as BurrowGuardSiteWithSecret, L as BurrowGuardVerifyParams, M as BurrowGuardVerifyResult, N as CancelBatchResult, O as CategoryOptOut, P as CategoryOptOutCategory, Q as CategoryUnsubscribedErrorDetails, R as ConnectTwilioParams, T as ContactWebhookEventPayload, U as CreateApiKeyParams, V as CreateApiKeyResult, W as CreateAutomationParams, X as CreateBurrowGuardSiteParams, Y as CreateDomainParams, Z as CreateDomainResult, _ as CreateMailboxParams, $ as CreateMigrationParams, a0 as CreateSenderParams, a1 as CreateSuppressionParams, a2 as CreateTemplateParams, a3 as CreateTenantParams, a4 as CreateWebhookParams, a5 as DEFAULT_API_BASE_URL, a6 as DailyRampLimitErrorDetails, a7 as DeleteMailboxResult, a8 as DeleteTenantResult, a9 as DeliverabilityBucket, aa as DeliverabilityDomainInsight, ab as DeliverabilityInsightsResult, ac as DeliverabilityMailServerRelay, ad as DeliverabilityWindow, ae as DmarcDailyPoint, af as DmarcMonitoring, ag as DmarcMonitoringDisabled, ah as DmarcReadiness, ai as DmarcReadinessVerdict, aj as DmarcSource, ak as DmarcSourceStatus, al as DmarcStatus, am as DnsProviderName, an as Domain, ao as DomainBimiAnalysis, ap as DomainBlocklistListing, aq as DomainBlocklistStatus, ar as DomainBlocklists, as as DomainDetailResult, at as DomainDmarcAnalysis, au as DomainDnsAnalysis, av as DomainStatus, aw as DomainTlsMode, ax as DomainTrackingDns, ay as DomainTrackingStatus, az as EmailDelivery, aA as EmailListItem, aB as EmailWebhookEventPayload, aC as EmailWebhookEventType, aD as EnableDmarcParams, aE as EnableDmarcResult, aF as EnrollmentSkip, aG as EventRecord, aH as ForwardMailboxParams, aI as GetMailboxThreadParams, G as Groundmail, aJ as GroundmailAccessToken, aK as GroundmailOptions, aL as GroundmailTokenOptions, aM as GroundmailTokenProvider, aN as HeldBackErrorDetails, aO as HeldBackReason, aP as HeldBackRecipient, aQ as InReplyToEmail, aR as InstantMailbox, aS as InstantMailboxParams, aT as ListApiKeysParams, aU as ListApiKeysResult, aV as ListAutomationRunsParams, aW as ListAutomationRunsResult, aX as ListAutomationsResult, aY as ListBurrowGuardChecksParams, aZ as ListBurrowGuardChecksResult, a_ as ListCategoryOptOutsParams, a$ as ListCategoryOptOutsResult, b0 as ListDomainsParams, b1 as ListDomainsResult, b2 as ListEmailsParams, b3 as ListEmailsResult, b4 as ListMailboxMessagesParams, b5 as ListMailboxMessagesResult, b6 as ListMailboxThreadsParams, b7 as ListMailboxThreadsResult, b8 as ListMailboxesParams, b9 as ListMailboxesResult, ba as ListReceivedEmailsParams, bb as ListReceivedEmailsResult, bc as ListSendersResult, bd as ListSuppressionsParams, be as ListSuppressionsResult, bf as ListTemplatesParams, bg as ListTemplatesResult, bh as ListTenantDomainsResult, bi as ListTenantsParams, bj as ListTenantsResult, bk as ListTestInboxEmailsParams, bl as ListTestInboxEmailsResult, bm as ListWebhookDeliveriesParams, bn as ListWebhookDeliveriesResult, bo as MAILBOX_WAIT_DEFAULT_MS, bp as MAILBOX_WAIT_MAX_SECONDS, bq as MailServerSigningStatus, br as MailStream, bs as Mailbox, bt as MailboxAttachment, bu as MailboxAttachmentDownload, bv as MailboxForwarding, bw as MailboxMessage, bx as MailboxMessageDetail, by as MailboxMessagesResource, bz as MailboxOutgoingAttachment, bA as MailboxSendResult, bB as MailboxStatus, bC as MailboxThread, bD as MailboxThreadDetail, bE as MailboxThreadsResource, bF as MailboxWebhookEventPayload, bG as MailboxesResource, bH as Migration, bI as MigrationDnsChange, bJ as MigrationDnsPlan, bK as MigrationDomainItem, bL as MigrationItemStatus, bM as MigrationProvider, bN as MigrationResource, bO as MigrationSummary, bP as MigrationTemplateItem, bQ as MigrationTotals, bR as MigrationWebhookItem, bS as ReceivedEmail, bT as ReceivedEmailAttachment, bU as ReceivedEmailAttachmentMeta, bV as RemoteApplyDnsCredentials, bW as RemoveCategoryOptOutOptions, bX as ReplyToMailboxMessageParams, bY as RunMigrationOptions, bZ as SendEmailParams, S as SendEmailResult, b_ as SendMailboxMessageParams, b$ as Sender, c0 as SesMigrationParams, c1 as StreamDeliverability, c2 as SuppressedErrorDetails, c3 as Suppression, c4 as TEST_INBOX_WAIT_DEFAULT_MS, c5 as TEST_INBOX_WAIT_MAX_SECONDS, c6 as Template, c7 as TemplateFormat, c8 as TemplateLintWarning, c9 as TemplateStarter, ca as TemplateStatus, cb as TemplateVersion, cc as Tenant, cd as TenantPauseSource, ce as TenantRamp, cf as TenantStats, cg as TenantStatsResult, ch as TenantStatus, ci as TenantStreamPolicy, cj as TestEmailWebhookParams, ck as TestEmailWebhookResult, cl as TestInbox, cm as TestInboxAddressOptions, cn as TestInboxEmail, co as TestInboxEmailDetail, cp as TestInboxHeader, cq as TestInboxResource, cr as TestInboxUsage, cs as TriggerEventParams, ct as TriggerEventResult, cu as TwilioIntegrationResponse, cv as TwilioIntegrationStatus, cw as UpdateAutomationParams, cx as UpdateBrandParams, cy as UpdateBurrowGuardSiteParams, cz as UpdateDomainParams, cA as UpdateEmailParams, cB as UpdateMailboxMessageParams, cC as UpdateMailboxParams, cD as UpdateMailboxThreadParams, cE as UpdateSenderParams, cF as UpdateTemplateParams, cG as UpdateTenantParams, cH as UpdateWebhookParams, cI as ValidateEmailResult, cJ as ValidationReason, cK as ValidationVerdict, cL as VerifyDomainResult, cM as WaitForMailboxMessageParams, cN as WaitForTestEmailParams, cO as WebhookDelivery, cP as WebhookDeliveryAttempt, cQ as WebhookDeliveryDetail, cR as WebhookDeliveryStatus, cS as WebhookEmailTag, cT as WebhookEndpoint, cU as WebhookEndpointHealth, cV as WebhookEndpointWithSecret, cW as WebhookEventType, cX as createInstantMailbox, cY as mergeMigrations, cZ as normalizeAccessToken } from './client-BqaE8VYB.js';
|
|
3
3
|
|
|
4
4
|
type GroundmailErrorOptions = {
|
|
5
5
|
code?: string;
|
package/dist/index.js
CHANGED
package/dist/payload.js
CHANGED