@marlinjai/mail-sdk 0.22.0 → 0.23.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 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" | "sending_domain.created" | "sending_domain.updated" | "sending_domain.checked" | "sending_domain.records_written" | "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" | "billing.extra_sending_domains_changed" | "billing.terms_accepted" | "domain_order.created" | "domain_order.paid" | "domain_order.registered" | "domain_order.ready" | "domain_order.needs_attention" | "domain_order.kind_changed" | "domain_order.refunded" | "domain_order.cancelled" | "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.records_written" | "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" | "billing.extra_sending_domains_changed" | "billing.terms_accepted" | "domain_order.created" | "domain_order.paid" | "domain_order.registered" | "domain_order.ready" | "domain_order.needs_attention" | "domain_order.kind_changed" | "domain_order.refunded" | "domain_order.cancelled" | "domain_record.created" | "domain_record.updated" | "domain_record.deleted" | "domain_leave.requested" | "domain_leave.done" | "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;
@@ -3718,6 +3718,95 @@ declare function createNamespaces(config: CoreConfig): {
3718
3718
  registered_at: string | null;
3719
3719
  }>;
3720
3720
  };
3721
+ boughtDomains: {
3722
+ list: (opts?: RequestOpts) => Promise<{
3723
+ data: {
3724
+ id: string;
3725
+ kind: "sending" | "domain_only";
3726
+ expires_at: string | null;
3727
+ currency: "EUR";
3728
+ domain: string;
3729
+ renewal_price_cents: number;
3730
+ registrant_name: string;
3731
+ registered_at: string;
3732
+ no_charge: boolean;
3733
+ move_account_from: string;
3734
+ transfer_from: string;
3735
+ leave: {
3736
+ id: string;
3737
+ state: "cancelled" | "requested" | "done";
3738
+ way: "cloudflare_account" | "transfer";
3739
+ target_account_id: string | null;
3740
+ auth_code: string | null;
3741
+ requested_at: string;
3742
+ done_at: string | null;
3743
+ } | null;
3744
+ left: boolean;
3745
+ }[];
3746
+ }>;
3747
+ records: (id: string, opts?: RequestOpts) => Promise<{
3748
+ data: {
3749
+ type: string;
3750
+ id: string;
3751
+ name: string;
3752
+ ttl: number;
3753
+ priority: number | null;
3754
+ content: string;
3755
+ proxied: boolean;
3756
+ locked: boolean;
3757
+ }[];
3758
+ }>;
3759
+ createRecord: (id: string, body: RouteBody<"boughtDomains.createRecord">, opts?: RequestOpts) => Promise<{
3760
+ type: string;
3761
+ id: string;
3762
+ name: string;
3763
+ ttl: number;
3764
+ priority: number | null;
3765
+ content: string;
3766
+ proxied: boolean;
3767
+ locked: boolean;
3768
+ }>;
3769
+ updateRecord: (id: string, recordId: string, body: RouteBody<"boughtDomains.updateRecord">, opts?: RequestOpts) => Promise<{
3770
+ type: string;
3771
+ id: string;
3772
+ name: string;
3773
+ ttl: number;
3774
+ priority: number | null;
3775
+ content: string;
3776
+ proxied: boolean;
3777
+ locked: boolean;
3778
+ }>;
3779
+ deleteRecord: (id: string, recordId: string, opts?: RequestOpts) => Promise<{
3780
+ ok: true;
3781
+ }>;
3782
+ zoneFile: (id: string, opts?: RequestOpts) => Promise<{
3783
+ domain: string;
3784
+ zone_file: string;
3785
+ }>;
3786
+ leave: (id: string, body: RouteBody<"boughtDomains.leave">, opts?: RequestOpts) => Promise<{
3787
+ id: string;
3788
+ kind: "sending" | "domain_only";
3789
+ expires_at: string | null;
3790
+ currency: "EUR";
3791
+ domain: string;
3792
+ renewal_price_cents: number;
3793
+ registrant_name: string;
3794
+ registered_at: string;
3795
+ no_charge: boolean;
3796
+ move_account_from: string;
3797
+ transfer_from: string;
3798
+ leave: {
3799
+ id: string;
3800
+ state: "cancelled" | "requested" | "done";
3801
+ way: "cloudflare_account" | "transfer";
3802
+ target_account_id: string | null;
3803
+ auth_code: string | null;
3804
+ requested_at: string;
3805
+ done_at: string | null;
3806
+ } | null;
3807
+ left: boolean;
3808
+ }>;
3809
+ };
3721
3810
  automations: {
3722
3811
  list: (query?: RouteQuery<"automations.list">, opts?: RequestOpts) => Promise<{
3723
3812
  data: {
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" | "sending_domain.created" | "sending_domain.updated" | "sending_domain.checked" | "sending_domain.records_written" | "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" | "billing.extra_sending_domains_changed" | "billing.terms_accepted" | "domain_order.created" | "domain_order.paid" | "domain_order.registered" | "domain_order.ready" | "domain_order.needs_attention" | "domain_order.kind_changed" | "domain_order.refunded" | "domain_order.cancelled" | "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.records_written" | "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" | "billing.extra_sending_domains_changed" | "billing.terms_accepted" | "domain_order.created" | "domain_order.paid" | "domain_order.registered" | "domain_order.ready" | "domain_order.needs_attention" | "domain_order.kind_changed" | "domain_order.refunded" | "domain_order.cancelled" | "domain_record.created" | "domain_record.updated" | "domain_record.deleted" | "domain_leave.requested" | "domain_leave.done" | "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;
@@ -3718,6 +3718,95 @@ declare function createNamespaces(config: CoreConfig): {
3718
3718
  registered_at: string | null;
3719
3719
  }>;
3720
3720
  };
3721
+ boughtDomains: {
3722
+ list: (opts?: RequestOpts) => Promise<{
3723
+ data: {
3724
+ id: string;
3725
+ kind: "sending" | "domain_only";
3726
+ expires_at: string | null;
3727
+ currency: "EUR";
3728
+ domain: string;
3729
+ renewal_price_cents: number;
3730
+ registrant_name: string;
3731
+ registered_at: string;
3732
+ no_charge: boolean;
3733
+ move_account_from: string;
3734
+ transfer_from: string;
3735
+ leave: {
3736
+ id: string;
3737
+ state: "cancelled" | "requested" | "done";
3738
+ way: "cloudflare_account" | "transfer";
3739
+ target_account_id: string | null;
3740
+ auth_code: string | null;
3741
+ requested_at: string;
3742
+ done_at: string | null;
3743
+ } | null;
3744
+ left: boolean;
3745
+ }[];
3746
+ }>;
3747
+ records: (id: string, opts?: RequestOpts) => Promise<{
3748
+ data: {
3749
+ type: string;
3750
+ id: string;
3751
+ name: string;
3752
+ ttl: number;
3753
+ priority: number | null;
3754
+ content: string;
3755
+ proxied: boolean;
3756
+ locked: boolean;
3757
+ }[];
3758
+ }>;
3759
+ createRecord: (id: string, body: RouteBody<"boughtDomains.createRecord">, opts?: RequestOpts) => Promise<{
3760
+ type: string;
3761
+ id: string;
3762
+ name: string;
3763
+ ttl: number;
3764
+ priority: number | null;
3765
+ content: string;
3766
+ proxied: boolean;
3767
+ locked: boolean;
3768
+ }>;
3769
+ updateRecord: (id: string, recordId: string, body: RouteBody<"boughtDomains.updateRecord">, opts?: RequestOpts) => Promise<{
3770
+ type: string;
3771
+ id: string;
3772
+ name: string;
3773
+ ttl: number;
3774
+ priority: number | null;
3775
+ content: string;
3776
+ proxied: boolean;
3777
+ locked: boolean;
3778
+ }>;
3779
+ deleteRecord: (id: string, recordId: string, opts?: RequestOpts) => Promise<{
3780
+ ok: true;
3781
+ }>;
3782
+ zoneFile: (id: string, opts?: RequestOpts) => Promise<{
3783
+ domain: string;
3784
+ zone_file: string;
3785
+ }>;
3786
+ leave: (id: string, body: RouteBody<"boughtDomains.leave">, opts?: RequestOpts) => Promise<{
3787
+ id: string;
3788
+ kind: "sending" | "domain_only";
3789
+ expires_at: string | null;
3790
+ currency: "EUR";
3791
+ domain: string;
3792
+ renewal_price_cents: number;
3793
+ registrant_name: string;
3794
+ registered_at: string;
3795
+ no_charge: boolean;
3796
+ move_account_from: string;
3797
+ transfer_from: string;
3798
+ leave: {
3799
+ id: string;
3800
+ state: "cancelled" | "requested" | "done";
3801
+ way: "cloudflare_account" | "transfer";
3802
+ target_account_id: string | null;
3803
+ auth_code: string | null;
3804
+ requested_at: string;
3805
+ done_at: string | null;
3806
+ } | null;
3807
+ left: boolean;
3808
+ }>;
3809
+ };
3721
3810
  automations: {
3722
3811
  list: (query?: RouteQuery<"automations.list">, opts?: RequestOpts) => Promise<{
3723
3812
  data: {
package/dist/index.js CHANGED
@@ -693,6 +693,16 @@ function createNamespaces(config) {
693
693
  list: (query, opts) => execute(config, "domainOrders.list", { query }, opts),
694
694
  get: (id, opts) => execute(config, "domainOrders.get", { params: { id } }, opts)
695
695
  },
696
+ // Bought domains, managed by their holder: dates, DNS records, the zone file, leaving.
697
+ boughtDomains: {
698
+ list: (opts) => execute(config, "boughtDomains.list", {}, opts),
699
+ records: (id, opts) => execute(config, "boughtDomains.records", { params: { id } }, opts),
700
+ createRecord: (id, body, opts) => execute(config, "boughtDomains.createRecord", { params: { id }, body }, opts),
701
+ updateRecord: (id, recordId, body, opts) => execute(config, "boughtDomains.updateRecord", { params: { id, record_id: recordId }, body }, opts),
702
+ deleteRecord: (id, recordId, opts) => execute(config, "boughtDomains.deleteRecord", { params: { id, record_id: recordId } }, opts),
703
+ zoneFile: (id, opts) => execute(config, "boughtDomains.zoneFile", { params: { id } }, opts),
704
+ leave: (id, body, opts) => execute(config, "boughtDomains.leave", { params: { id }, body }, opts)
705
+ },
696
706
  // A1: automations.
697
707
  automations: {
698
708
  list: (query, opts) => execute(config, "automations.list", { query }, opts),
package/dist/index.mjs CHANGED
@@ -677,6 +677,16 @@ function createNamespaces(config) {
677
677
  list: (query, opts) => execute(config, "domainOrders.list", { query }, opts),
678
678
  get: (id, opts) => execute(config, "domainOrders.get", { params: { id } }, opts)
679
679
  },
680
+ // Bought domains, managed by their holder: dates, DNS records, the zone file, leaving.
681
+ boughtDomains: {
682
+ list: (opts) => execute(config, "boughtDomains.list", {}, opts),
683
+ records: (id, opts) => execute(config, "boughtDomains.records", { params: { id } }, opts),
684
+ createRecord: (id, body, opts) => execute(config, "boughtDomains.createRecord", { params: { id }, body }, opts),
685
+ updateRecord: (id, recordId, body, opts) => execute(config, "boughtDomains.updateRecord", { params: { id, record_id: recordId }, body }, opts),
686
+ deleteRecord: (id, recordId, opts) => execute(config, "boughtDomains.deleteRecord", { params: { id, record_id: recordId } }, opts),
687
+ zoneFile: (id, opts) => execute(config, "boughtDomains.zoneFile", { params: { id } }, opts),
688
+ leave: (id, body, opts) => execute(config, "boughtDomains.leave", { params: { id }, body }, opts)
689
+ },
680
690
  // A1: automations.
681
691
  automations: {
682
692
  list: (query, opts) => execute(config, "automations.list", { query }, opts),
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.22.0",
6
+ "version": "0.23.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.22.0"
35
+ "@marlinjai/mail-contract": "^0.23.0"
36
36
  },
37
37
  "peerDependencies": {
38
38
  "zod": "^3.25.0"