@marlinjai/mail-sdk 0.15.2 → 0.16.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/index.d.mts +141 -10
- package/dist/index.d.ts +141 -10
- package/dist/index.js +11 -0
- package/dist/index.mjs +11 -0
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -382,7 +382,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
382
382
|
id: string;
|
|
383
383
|
details: Record<string, unknown>;
|
|
384
384
|
created_at: string;
|
|
385
|
-
action: "workspace.created" | "workspace.updated" | "workspace.company_changed" | "member.added" | "member.role_changed" | "member.removed" | "member.invited" | "invite.revoked" | "api_key.created" | "api_key.revoked" | "provider.created" | "provider.updated" | "provider.deleted" | "provider.events_registered" | "provider.events_secret_set" | "provider.bounces_halted" | "provider.anomaly_cleared" | "topic.created" | "topic.updated" | "topic.deleted" | "template.created" | "template.updated" | "template.deleted" | "template.inputs_declared" | "saved_section.created" | "saved_section.updated" | "saved_section.deleted" | "asset.uploaded" | "asset.imported" | "contact.erased" | "suppression.created" | "suppression.deleted" | "mailing.created" | "mailing.sent" | "mailing.paused" | "mailing.resumed" | "mailing.cancelled" | "mailing.deleted" | "mailing.retried" | "webhook.created" | "webhook.updated" | "webhook.deleted" | "webhook.secret_rotated" | "webhook.redelivered" | "contact.unsubscribed" | "tag.created" | "tag.deleted" | "tag.assigned" | "tag.unassigned" | "contact_property.created" | "contact_property.deleted" | "segment.created" | "segment.updated" | "segment.deleted" | "signup_form.created" | "signup_form.updated" | "signup_form.deleted" | "contact.subscribed" | "import.created" | "import.mapped" | "import.committed" | "import.cancelled" | "import.finished" | "mailing.scheduled" | "mailing.unscheduled" | "mailing.schedule_failed" | "mailing.ab_test_updated" | "mailing.ab_winner_selected" | "tracking.updated" | "billing.checkout_started" | "billing.subscription_changed" | "billing.exemption_changed" | "automation.created" | "automation.updated" | "automation.published" | "automation.paused" | "automation.resumed" | "automation.archived" | "automation.deleted" | "automation.duplicated" | "automation.enrolled" | "automation.run_ended" | "event.recorded";
|
|
385
|
+
action: "workspace.created" | "workspace.updated" | "workspace.company_changed" | "member.added" | "member.role_changed" | "member.removed" | "member.invited" | "invite.revoked" | "api_key.created" | "api_key.revoked" | "provider.created" | "provider.updated" | "provider.deleted" | "provider.events_registered" | "provider.events_secret_set" | "provider.bounces_halted" | "provider.anomaly_cleared" | "sending_domain.created" | "sending_domain.updated" | "sending_domain.checked" | "sending_domain.deleted" | "topic.created" | "topic.updated" | "topic.deleted" | "template.created" | "template.updated" | "template.deleted" | "template.inputs_declared" | "saved_section.created" | "saved_section.updated" | "saved_section.deleted" | "asset.uploaded" | "asset.imported" | "contact.erased" | "suppression.created" | "suppression.deleted" | "mailing.created" | "mailing.sent" | "mailing.paused" | "mailing.resumed" | "mailing.cancelled" | "mailing.deleted" | "mailing.retried" | "webhook.created" | "webhook.updated" | "webhook.deleted" | "webhook.secret_rotated" | "webhook.redelivered" | "contact.unsubscribed" | "tag.created" | "tag.deleted" | "tag.assigned" | "tag.unassigned" | "contact_property.created" | "contact_property.deleted" | "segment.created" | "segment.updated" | "segment.deleted" | "signup_form.created" | "signup_form.updated" | "signup_form.deleted" | "contact.subscribed" | "import.created" | "import.mapped" | "import.committed" | "import.cancelled" | "import.finished" | "mailing.scheduled" | "mailing.unscheduled" | "mailing.schedule_failed" | "mailing.ab_test_updated" | "mailing.ab_winner_selected" | "tracking.updated" | "billing.checkout_started" | "billing.subscription_changed" | "billing.exemption_changed" | "automation.created" | "automation.updated" | "automation.published" | "automation.paused" | "automation.resumed" | "automation.archived" | "automation.deleted" | "automation.duplicated" | "automation.enrolled" | "automation.run_ended" | "event.recorded";
|
|
386
386
|
actor: {
|
|
387
387
|
type: "member";
|
|
388
388
|
subject: string;
|
|
@@ -1314,7 +1314,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1314
1314
|
status: "active" | "needs_secret";
|
|
1315
1315
|
error: string | null;
|
|
1316
1316
|
url: string;
|
|
1317
|
-
source: "manual" | "automatic" | null;
|
|
1317
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1318
1318
|
unmatched: number;
|
|
1319
1319
|
};
|
|
1320
1320
|
})[];
|
|
@@ -1387,7 +1387,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1387
1387
|
status: "active" | "needs_secret";
|
|
1388
1388
|
error: string | null;
|
|
1389
1389
|
url: string;
|
|
1390
|
-
source: "manual" | "automatic" | null;
|
|
1390
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1391
1391
|
unmatched: number;
|
|
1392
1392
|
};
|
|
1393
1393
|
}>;
|
|
@@ -1458,7 +1458,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1458
1458
|
status: "active" | "needs_secret";
|
|
1459
1459
|
error: string | null;
|
|
1460
1460
|
url: string;
|
|
1461
|
-
source: "manual" | "automatic" | null;
|
|
1461
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1462
1462
|
unmatched: number;
|
|
1463
1463
|
};
|
|
1464
1464
|
}>;
|
|
@@ -1529,7 +1529,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1529
1529
|
status: "active" | "needs_secret";
|
|
1530
1530
|
error: string | null;
|
|
1531
1531
|
url: string;
|
|
1532
|
-
source: "manual" | "automatic" | null;
|
|
1532
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1533
1533
|
unmatched: number;
|
|
1534
1534
|
};
|
|
1535
1535
|
}>;
|
|
@@ -1614,7 +1614,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1614
1614
|
status: "active" | "needs_secret";
|
|
1615
1615
|
error: string | null;
|
|
1616
1616
|
url: string;
|
|
1617
|
-
source: "manual" | "automatic" | null;
|
|
1617
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1618
1618
|
unmatched: number;
|
|
1619
1619
|
};
|
|
1620
1620
|
}>;
|
|
@@ -1686,11 +1686,142 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1686
1686
|
status: "active" | "needs_secret";
|
|
1687
1687
|
error: string | null;
|
|
1688
1688
|
url: string;
|
|
1689
|
-
source: "manual" | "automatic" | null;
|
|
1689
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1690
1690
|
unmatched: number;
|
|
1691
1691
|
};
|
|
1692
1692
|
}>;
|
|
1693
1693
|
};
|
|
1694
|
+
/** Sending through Lumitra Mail from the workspace's own domain, registered and verified at Resend. */
|
|
1695
|
+
sendingDomains: {
|
|
1696
|
+
list: (query?: RouteQuery<"sendingDomains.list">, opts?: RequestOpts) => Promise<{
|
|
1697
|
+
data: {
|
|
1698
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1699
|
+
id: string;
|
|
1700
|
+
created_at: string;
|
|
1701
|
+
updated_at: string;
|
|
1702
|
+
provider_id: string | null;
|
|
1703
|
+
reply_to: string | null;
|
|
1704
|
+
last_error: string | null;
|
|
1705
|
+
from_name: string;
|
|
1706
|
+
from_email: string;
|
|
1707
|
+
domain: string;
|
|
1708
|
+
dns_mode: "manual" | "managed";
|
|
1709
|
+
records: {
|
|
1710
|
+
value: string;
|
|
1711
|
+
type: string;
|
|
1712
|
+
status: string;
|
|
1713
|
+
name: string;
|
|
1714
|
+
record: string;
|
|
1715
|
+
ttl: string;
|
|
1716
|
+
priority?: number | undefined;
|
|
1717
|
+
}[];
|
|
1718
|
+
checked_at: string | null;
|
|
1719
|
+
verified_at: string | null;
|
|
1720
|
+
}[];
|
|
1721
|
+
next_cursor: string | null;
|
|
1722
|
+
}>;
|
|
1723
|
+
create: (body: RouteBody<"sendingDomains.create">, opts?: RequestOpts) => Promise<{
|
|
1724
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1725
|
+
id: string;
|
|
1726
|
+
created_at: string;
|
|
1727
|
+
updated_at: string;
|
|
1728
|
+
provider_id: string | null;
|
|
1729
|
+
reply_to: string | null;
|
|
1730
|
+
last_error: string | null;
|
|
1731
|
+
from_name: string;
|
|
1732
|
+
from_email: string;
|
|
1733
|
+
domain: string;
|
|
1734
|
+
dns_mode: "manual" | "managed";
|
|
1735
|
+
records: {
|
|
1736
|
+
value: string;
|
|
1737
|
+
type: string;
|
|
1738
|
+
status: string;
|
|
1739
|
+
name: string;
|
|
1740
|
+
record: string;
|
|
1741
|
+
ttl: string;
|
|
1742
|
+
priority?: number | undefined;
|
|
1743
|
+
}[];
|
|
1744
|
+
checked_at: string | null;
|
|
1745
|
+
verified_at: string | null;
|
|
1746
|
+
}>;
|
|
1747
|
+
get: (id: string, opts?: RequestOpts) => Promise<{
|
|
1748
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1749
|
+
id: string;
|
|
1750
|
+
created_at: string;
|
|
1751
|
+
updated_at: string;
|
|
1752
|
+
provider_id: string | null;
|
|
1753
|
+
reply_to: string | null;
|
|
1754
|
+
last_error: string | null;
|
|
1755
|
+
from_name: string;
|
|
1756
|
+
from_email: string;
|
|
1757
|
+
domain: string;
|
|
1758
|
+
dns_mode: "manual" | "managed";
|
|
1759
|
+
records: {
|
|
1760
|
+
value: string;
|
|
1761
|
+
type: string;
|
|
1762
|
+
status: string;
|
|
1763
|
+
name: string;
|
|
1764
|
+
record: string;
|
|
1765
|
+
ttl: string;
|
|
1766
|
+
priority?: number | undefined;
|
|
1767
|
+
}[];
|
|
1768
|
+
checked_at: string | null;
|
|
1769
|
+
verified_at: string | null;
|
|
1770
|
+
}>;
|
|
1771
|
+
/** Changes the sender; a different domain is removed and added anew. */
|
|
1772
|
+
update: (id: string, body: RouteBody<"sendingDomains.update">, opts?: RequestOpts) => Promise<{
|
|
1773
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1774
|
+
id: string;
|
|
1775
|
+
created_at: string;
|
|
1776
|
+
updated_at: string;
|
|
1777
|
+
provider_id: string | null;
|
|
1778
|
+
reply_to: string | null;
|
|
1779
|
+
last_error: string | null;
|
|
1780
|
+
from_name: string;
|
|
1781
|
+
from_email: string;
|
|
1782
|
+
domain: string;
|
|
1783
|
+
dns_mode: "manual" | "managed";
|
|
1784
|
+
records: {
|
|
1785
|
+
value: string;
|
|
1786
|
+
type: string;
|
|
1787
|
+
status: string;
|
|
1788
|
+
name: string;
|
|
1789
|
+
record: string;
|
|
1790
|
+
ttl: string;
|
|
1791
|
+
priority?: number | undefined;
|
|
1792
|
+
}[];
|
|
1793
|
+
checked_at: string | null;
|
|
1794
|
+
verified_at: string | null;
|
|
1795
|
+
}>;
|
|
1796
|
+
/** Asks Resend to check the DNS records now and returns what it reports. */
|
|
1797
|
+
check: (id: string, opts?: RequestOpts) => Promise<{
|
|
1798
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1799
|
+
id: string;
|
|
1800
|
+
created_at: string;
|
|
1801
|
+
updated_at: string;
|
|
1802
|
+
provider_id: string | null;
|
|
1803
|
+
reply_to: string | null;
|
|
1804
|
+
last_error: string | null;
|
|
1805
|
+
from_name: string;
|
|
1806
|
+
from_email: string;
|
|
1807
|
+
domain: string;
|
|
1808
|
+
dns_mode: "manual" | "managed";
|
|
1809
|
+
records: {
|
|
1810
|
+
value: string;
|
|
1811
|
+
type: string;
|
|
1812
|
+
status: string;
|
|
1813
|
+
name: string;
|
|
1814
|
+
record: string;
|
|
1815
|
+
ttl: string;
|
|
1816
|
+
priority?: number | undefined;
|
|
1817
|
+
}[];
|
|
1818
|
+
checked_at: string | null;
|
|
1819
|
+
verified_at: string | null;
|
|
1820
|
+
}>;
|
|
1821
|
+
delete: (id: string, opts?: RequestOpts) => Promise<{
|
|
1822
|
+
ok: true;
|
|
1823
|
+
}>;
|
|
1824
|
+
};
|
|
1694
1825
|
topics: {
|
|
1695
1826
|
list: (query?: RouteQuery<"topics.list">, opts?: RequestOpts) => Promise<{
|
|
1696
1827
|
data: {
|
|
@@ -3441,11 +3572,11 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
3441
3572
|
webhook_endpoints: number | null;
|
|
3442
3573
|
active_automations: number | null;
|
|
3443
3574
|
automation_steps: number | null;
|
|
3575
|
+
sending_domains: number | null;
|
|
3444
3576
|
};
|
|
3445
3577
|
features: {
|
|
3446
3578
|
tracking: boolean;
|
|
3447
3579
|
ab_testing: boolean;
|
|
3448
|
-
custom_domains: boolean;
|
|
3449
3580
|
automations: boolean;
|
|
3450
3581
|
};
|
|
3451
3582
|
sellable: boolean;
|
|
@@ -3463,14 +3594,14 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
3463
3594
|
usage: (opts?: RequestOpts) => Promise<{
|
|
3464
3595
|
warnings: {
|
|
3465
3596
|
limit: number;
|
|
3466
|
-
metric: "contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "messages";
|
|
3597
|
+
metric: "contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "sending_domains" | "messages";
|
|
3467
3598
|
used: number;
|
|
3468
3599
|
level: "reached" | "approaching";
|
|
3469
3600
|
}[];
|
|
3470
3601
|
plan: "free" | "starter" | "growth" | "design_partner";
|
|
3471
3602
|
period_start: string;
|
|
3472
3603
|
period_end: string;
|
|
3473
|
-
metrics: Partial<Record<"contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "messages", {
|
|
3604
|
+
metrics: Partial<Record<"contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "sending_domains" | "messages", {
|
|
3474
3605
|
limit: number | null;
|
|
3475
3606
|
used: number;
|
|
3476
3607
|
}>>;
|
package/dist/index.d.ts
CHANGED
|
@@ -382,7 +382,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
382
382
|
id: string;
|
|
383
383
|
details: Record<string, unknown>;
|
|
384
384
|
created_at: string;
|
|
385
|
-
action: "workspace.created" | "workspace.updated" | "workspace.company_changed" | "member.added" | "member.role_changed" | "member.removed" | "member.invited" | "invite.revoked" | "api_key.created" | "api_key.revoked" | "provider.created" | "provider.updated" | "provider.deleted" | "provider.events_registered" | "provider.events_secret_set" | "provider.bounces_halted" | "provider.anomaly_cleared" | "topic.created" | "topic.updated" | "topic.deleted" | "template.created" | "template.updated" | "template.deleted" | "template.inputs_declared" | "saved_section.created" | "saved_section.updated" | "saved_section.deleted" | "asset.uploaded" | "asset.imported" | "contact.erased" | "suppression.created" | "suppression.deleted" | "mailing.created" | "mailing.sent" | "mailing.paused" | "mailing.resumed" | "mailing.cancelled" | "mailing.deleted" | "mailing.retried" | "webhook.created" | "webhook.updated" | "webhook.deleted" | "webhook.secret_rotated" | "webhook.redelivered" | "contact.unsubscribed" | "tag.created" | "tag.deleted" | "tag.assigned" | "tag.unassigned" | "contact_property.created" | "contact_property.deleted" | "segment.created" | "segment.updated" | "segment.deleted" | "signup_form.created" | "signup_form.updated" | "signup_form.deleted" | "contact.subscribed" | "import.created" | "import.mapped" | "import.committed" | "import.cancelled" | "import.finished" | "mailing.scheduled" | "mailing.unscheduled" | "mailing.schedule_failed" | "mailing.ab_test_updated" | "mailing.ab_winner_selected" | "tracking.updated" | "billing.checkout_started" | "billing.subscription_changed" | "billing.exemption_changed" | "automation.created" | "automation.updated" | "automation.published" | "automation.paused" | "automation.resumed" | "automation.archived" | "automation.deleted" | "automation.duplicated" | "automation.enrolled" | "automation.run_ended" | "event.recorded";
|
|
385
|
+
action: "workspace.created" | "workspace.updated" | "workspace.company_changed" | "member.added" | "member.role_changed" | "member.removed" | "member.invited" | "invite.revoked" | "api_key.created" | "api_key.revoked" | "provider.created" | "provider.updated" | "provider.deleted" | "provider.events_registered" | "provider.events_secret_set" | "provider.bounces_halted" | "provider.anomaly_cleared" | "sending_domain.created" | "sending_domain.updated" | "sending_domain.checked" | "sending_domain.deleted" | "topic.created" | "topic.updated" | "topic.deleted" | "template.created" | "template.updated" | "template.deleted" | "template.inputs_declared" | "saved_section.created" | "saved_section.updated" | "saved_section.deleted" | "asset.uploaded" | "asset.imported" | "contact.erased" | "suppression.created" | "suppression.deleted" | "mailing.created" | "mailing.sent" | "mailing.paused" | "mailing.resumed" | "mailing.cancelled" | "mailing.deleted" | "mailing.retried" | "webhook.created" | "webhook.updated" | "webhook.deleted" | "webhook.secret_rotated" | "webhook.redelivered" | "contact.unsubscribed" | "tag.created" | "tag.deleted" | "tag.assigned" | "tag.unassigned" | "contact_property.created" | "contact_property.deleted" | "segment.created" | "segment.updated" | "segment.deleted" | "signup_form.created" | "signup_form.updated" | "signup_form.deleted" | "contact.subscribed" | "import.created" | "import.mapped" | "import.committed" | "import.cancelled" | "import.finished" | "mailing.scheduled" | "mailing.unscheduled" | "mailing.schedule_failed" | "mailing.ab_test_updated" | "mailing.ab_winner_selected" | "tracking.updated" | "billing.checkout_started" | "billing.subscription_changed" | "billing.exemption_changed" | "automation.created" | "automation.updated" | "automation.published" | "automation.paused" | "automation.resumed" | "automation.archived" | "automation.deleted" | "automation.duplicated" | "automation.enrolled" | "automation.run_ended" | "event.recorded";
|
|
386
386
|
actor: {
|
|
387
387
|
type: "member";
|
|
388
388
|
subject: string;
|
|
@@ -1314,7 +1314,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1314
1314
|
status: "active" | "needs_secret";
|
|
1315
1315
|
error: string | null;
|
|
1316
1316
|
url: string;
|
|
1317
|
-
source: "manual" | "automatic" | null;
|
|
1317
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1318
1318
|
unmatched: number;
|
|
1319
1319
|
};
|
|
1320
1320
|
})[];
|
|
@@ -1387,7 +1387,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1387
1387
|
status: "active" | "needs_secret";
|
|
1388
1388
|
error: string | null;
|
|
1389
1389
|
url: string;
|
|
1390
|
-
source: "manual" | "automatic" | null;
|
|
1390
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1391
1391
|
unmatched: number;
|
|
1392
1392
|
};
|
|
1393
1393
|
}>;
|
|
@@ -1458,7 +1458,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1458
1458
|
status: "active" | "needs_secret";
|
|
1459
1459
|
error: string | null;
|
|
1460
1460
|
url: string;
|
|
1461
|
-
source: "manual" | "automatic" | null;
|
|
1461
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1462
1462
|
unmatched: number;
|
|
1463
1463
|
};
|
|
1464
1464
|
}>;
|
|
@@ -1529,7 +1529,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1529
1529
|
status: "active" | "needs_secret";
|
|
1530
1530
|
error: string | null;
|
|
1531
1531
|
url: string;
|
|
1532
|
-
source: "manual" | "automatic" | null;
|
|
1532
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1533
1533
|
unmatched: number;
|
|
1534
1534
|
};
|
|
1535
1535
|
}>;
|
|
@@ -1614,7 +1614,7 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1614
1614
|
status: "active" | "needs_secret";
|
|
1615
1615
|
error: string | null;
|
|
1616
1616
|
url: string;
|
|
1617
|
-
source: "manual" | "automatic" | null;
|
|
1617
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1618
1618
|
unmatched: number;
|
|
1619
1619
|
};
|
|
1620
1620
|
}>;
|
|
@@ -1686,11 +1686,142 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
1686
1686
|
status: "active" | "needs_secret";
|
|
1687
1687
|
error: string | null;
|
|
1688
1688
|
url: string;
|
|
1689
|
-
source: "manual" | "automatic" | null;
|
|
1689
|
+
source: "manual" | "automatic" | "managed" | null;
|
|
1690
1690
|
unmatched: number;
|
|
1691
1691
|
};
|
|
1692
1692
|
}>;
|
|
1693
1693
|
};
|
|
1694
|
+
/** Sending through Lumitra Mail from the workspace's own domain, registered and verified at Resend. */
|
|
1695
|
+
sendingDomains: {
|
|
1696
|
+
list: (query?: RouteQuery<"sendingDomains.list">, opts?: RequestOpts) => Promise<{
|
|
1697
|
+
data: {
|
|
1698
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1699
|
+
id: string;
|
|
1700
|
+
created_at: string;
|
|
1701
|
+
updated_at: string;
|
|
1702
|
+
provider_id: string | null;
|
|
1703
|
+
reply_to: string | null;
|
|
1704
|
+
last_error: string | null;
|
|
1705
|
+
from_name: string;
|
|
1706
|
+
from_email: string;
|
|
1707
|
+
domain: string;
|
|
1708
|
+
dns_mode: "manual" | "managed";
|
|
1709
|
+
records: {
|
|
1710
|
+
value: string;
|
|
1711
|
+
type: string;
|
|
1712
|
+
status: string;
|
|
1713
|
+
name: string;
|
|
1714
|
+
record: string;
|
|
1715
|
+
ttl: string;
|
|
1716
|
+
priority?: number | undefined;
|
|
1717
|
+
}[];
|
|
1718
|
+
checked_at: string | null;
|
|
1719
|
+
verified_at: string | null;
|
|
1720
|
+
}[];
|
|
1721
|
+
next_cursor: string | null;
|
|
1722
|
+
}>;
|
|
1723
|
+
create: (body: RouteBody<"sendingDomains.create">, opts?: RequestOpts) => Promise<{
|
|
1724
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1725
|
+
id: string;
|
|
1726
|
+
created_at: string;
|
|
1727
|
+
updated_at: string;
|
|
1728
|
+
provider_id: string | null;
|
|
1729
|
+
reply_to: string | null;
|
|
1730
|
+
last_error: string | null;
|
|
1731
|
+
from_name: string;
|
|
1732
|
+
from_email: string;
|
|
1733
|
+
domain: string;
|
|
1734
|
+
dns_mode: "manual" | "managed";
|
|
1735
|
+
records: {
|
|
1736
|
+
value: string;
|
|
1737
|
+
type: string;
|
|
1738
|
+
status: string;
|
|
1739
|
+
name: string;
|
|
1740
|
+
record: string;
|
|
1741
|
+
ttl: string;
|
|
1742
|
+
priority?: number | undefined;
|
|
1743
|
+
}[];
|
|
1744
|
+
checked_at: string | null;
|
|
1745
|
+
verified_at: string | null;
|
|
1746
|
+
}>;
|
|
1747
|
+
get: (id: string, opts?: RequestOpts) => Promise<{
|
|
1748
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1749
|
+
id: string;
|
|
1750
|
+
created_at: string;
|
|
1751
|
+
updated_at: string;
|
|
1752
|
+
provider_id: string | null;
|
|
1753
|
+
reply_to: string | null;
|
|
1754
|
+
last_error: string | null;
|
|
1755
|
+
from_name: string;
|
|
1756
|
+
from_email: string;
|
|
1757
|
+
domain: string;
|
|
1758
|
+
dns_mode: "manual" | "managed";
|
|
1759
|
+
records: {
|
|
1760
|
+
value: string;
|
|
1761
|
+
type: string;
|
|
1762
|
+
status: string;
|
|
1763
|
+
name: string;
|
|
1764
|
+
record: string;
|
|
1765
|
+
ttl: string;
|
|
1766
|
+
priority?: number | undefined;
|
|
1767
|
+
}[];
|
|
1768
|
+
checked_at: string | null;
|
|
1769
|
+
verified_at: string | null;
|
|
1770
|
+
}>;
|
|
1771
|
+
/** Changes the sender; a different domain is removed and added anew. */
|
|
1772
|
+
update: (id: string, body: RouteBody<"sendingDomains.update">, opts?: RequestOpts) => Promise<{
|
|
1773
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1774
|
+
id: string;
|
|
1775
|
+
created_at: string;
|
|
1776
|
+
updated_at: string;
|
|
1777
|
+
provider_id: string | null;
|
|
1778
|
+
reply_to: string | null;
|
|
1779
|
+
last_error: string | null;
|
|
1780
|
+
from_name: string;
|
|
1781
|
+
from_email: string;
|
|
1782
|
+
domain: string;
|
|
1783
|
+
dns_mode: "manual" | "managed";
|
|
1784
|
+
records: {
|
|
1785
|
+
value: string;
|
|
1786
|
+
type: string;
|
|
1787
|
+
status: string;
|
|
1788
|
+
name: string;
|
|
1789
|
+
record: string;
|
|
1790
|
+
ttl: string;
|
|
1791
|
+
priority?: number | undefined;
|
|
1792
|
+
}[];
|
|
1793
|
+
checked_at: string | null;
|
|
1794
|
+
verified_at: string | null;
|
|
1795
|
+
}>;
|
|
1796
|
+
/** Asks Resend to check the DNS records now and returns what it reports. */
|
|
1797
|
+
check: (id: string, opts?: RequestOpts) => Promise<{
|
|
1798
|
+
status: "failed" | "pending_dns" | "verifying" | "verified" | "temporary_failure";
|
|
1799
|
+
id: string;
|
|
1800
|
+
created_at: string;
|
|
1801
|
+
updated_at: string;
|
|
1802
|
+
provider_id: string | null;
|
|
1803
|
+
reply_to: string | null;
|
|
1804
|
+
last_error: string | null;
|
|
1805
|
+
from_name: string;
|
|
1806
|
+
from_email: string;
|
|
1807
|
+
domain: string;
|
|
1808
|
+
dns_mode: "manual" | "managed";
|
|
1809
|
+
records: {
|
|
1810
|
+
value: string;
|
|
1811
|
+
type: string;
|
|
1812
|
+
status: string;
|
|
1813
|
+
name: string;
|
|
1814
|
+
record: string;
|
|
1815
|
+
ttl: string;
|
|
1816
|
+
priority?: number | undefined;
|
|
1817
|
+
}[];
|
|
1818
|
+
checked_at: string | null;
|
|
1819
|
+
verified_at: string | null;
|
|
1820
|
+
}>;
|
|
1821
|
+
delete: (id: string, opts?: RequestOpts) => Promise<{
|
|
1822
|
+
ok: true;
|
|
1823
|
+
}>;
|
|
1824
|
+
};
|
|
1694
1825
|
topics: {
|
|
1695
1826
|
list: (query?: RouteQuery<"topics.list">, opts?: RequestOpts) => Promise<{
|
|
1696
1827
|
data: {
|
|
@@ -3441,11 +3572,11 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
3441
3572
|
webhook_endpoints: number | null;
|
|
3442
3573
|
active_automations: number | null;
|
|
3443
3574
|
automation_steps: number | null;
|
|
3575
|
+
sending_domains: number | null;
|
|
3444
3576
|
};
|
|
3445
3577
|
features: {
|
|
3446
3578
|
tracking: boolean;
|
|
3447
3579
|
ab_testing: boolean;
|
|
3448
|
-
custom_domains: boolean;
|
|
3449
3580
|
automations: boolean;
|
|
3450
3581
|
};
|
|
3451
3582
|
sellable: boolean;
|
|
@@ -3463,14 +3594,14 @@ declare function createNamespaces(config: CoreConfig): {
|
|
|
3463
3594
|
usage: (opts?: RequestOpts) => Promise<{
|
|
3464
3595
|
warnings: {
|
|
3465
3596
|
limit: number;
|
|
3466
|
-
metric: "contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "messages";
|
|
3597
|
+
metric: "contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "sending_domains" | "messages";
|
|
3467
3598
|
used: number;
|
|
3468
3599
|
level: "reached" | "approaching";
|
|
3469
3600
|
}[];
|
|
3470
3601
|
plan: "free" | "starter" | "growth" | "design_partner";
|
|
3471
3602
|
period_start: string;
|
|
3472
3603
|
period_end: string;
|
|
3473
|
-
metrics: Partial<Record<"contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "messages", {
|
|
3604
|
+
metrics: Partial<Record<"contacts" | "members" | "providers" | "webhook_endpoints" | "active_automations" | "sending_domains" | "messages", {
|
|
3474
3605
|
limit: number | null;
|
|
3475
3606
|
used: number;
|
|
3476
3607
|
}>>;
|
package/dist/index.js
CHANGED
|
@@ -537,6 +537,17 @@ function createNamespaces(config) {
|
|
|
537
537
|
/** Stores the signing secret of a Resend webhook registered by hand, so bounces and complaints are accepted. */
|
|
538
538
|
setEventsSecret: (id, body, opts) => execute(config, "providers.setEventsSecret", { params: { id }, body }, opts)
|
|
539
539
|
},
|
|
540
|
+
/** Sending through Lumitra Mail from the workspace's own domain, registered and verified at Resend. */
|
|
541
|
+
sendingDomains: {
|
|
542
|
+
list: (query, opts) => execute(config, "sendingDomains.list", { query }, opts),
|
|
543
|
+
create: (body, opts) => execute(config, "sendingDomains.create", { body }, opts),
|
|
544
|
+
get: (id, opts) => execute(config, "sendingDomains.get", { params: { id } }, opts),
|
|
545
|
+
/** Changes the sender; a different domain is removed and added anew. */
|
|
546
|
+
update: (id, body, opts) => execute(config, "sendingDomains.update", { params: { id }, body }, opts),
|
|
547
|
+
/** Asks Resend to check the DNS records now and returns what it reports. */
|
|
548
|
+
check: (id, opts) => execute(config, "sendingDomains.check", { params: { id } }, opts),
|
|
549
|
+
delete: (id, opts) => execute(config, "sendingDomains.delete", { params: { id } }, opts)
|
|
550
|
+
},
|
|
540
551
|
topics: {
|
|
541
552
|
list: (query, opts) => execute(config, "topics.list", { query }, opts),
|
|
542
553
|
create: (body, opts) => execute(config, "topics.create", { body }, opts),
|
package/dist/index.mjs
CHANGED
|
@@ -521,6 +521,17 @@ function createNamespaces(config) {
|
|
|
521
521
|
/** Stores the signing secret of a Resend webhook registered by hand, so bounces and complaints are accepted. */
|
|
522
522
|
setEventsSecret: (id, body, opts) => execute(config, "providers.setEventsSecret", { params: { id }, body }, opts)
|
|
523
523
|
},
|
|
524
|
+
/** Sending through Lumitra Mail from the workspace's own domain, registered and verified at Resend. */
|
|
525
|
+
sendingDomains: {
|
|
526
|
+
list: (query, opts) => execute(config, "sendingDomains.list", { query }, opts),
|
|
527
|
+
create: (body, opts) => execute(config, "sendingDomains.create", { body }, opts),
|
|
528
|
+
get: (id, opts) => execute(config, "sendingDomains.get", { params: { id } }, opts),
|
|
529
|
+
/** Changes the sender; a different domain is removed and added anew. */
|
|
530
|
+
update: (id, body, opts) => execute(config, "sendingDomains.update", { params: { id }, body }, opts),
|
|
531
|
+
/** Asks Resend to check the DNS records now and returns what it reports. */
|
|
532
|
+
check: (id, opts) => execute(config, "sendingDomains.check", { params: { id } }, opts),
|
|
533
|
+
delete: (id, opts) => execute(config, "sendingDomains.delete", { params: { id } }, opts)
|
|
534
|
+
},
|
|
524
535
|
topics: {
|
|
525
536
|
list: (query, opts) => execute(config, "topics.list", { query }, opts),
|
|
526
537
|
create: (body, opts) => execute(config, "topics.create", { body }, opts),
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.
|
|
6
|
+
"version": "0.16.0",
|
|
7
7
|
"description": "Typed client for the Lumitra Mail v1 API: Node and edge runtimes, retries with idempotency, cursor pagination, webhook verification",
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"repository": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"LICENSE"
|
|
33
33
|
],
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@marlinjai/mail-contract": "^0.
|
|
35
|
+
"@marlinjai/mail-contract": "^0.16.0"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
38
|
"zod": "^3.25.0"
|