@easybits.cloud/mailmask 0.4.6 → 0.4.7
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/README.md +7 -0
- package/dist/index.cjs +18 -0
- package/dist/index.d.cts +98 -1
- package/dist/index.d.ts +98 -1
- package/dist/index.js +18 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -62,6 +62,13 @@ await mm.send.send(domainId, {
|
|
|
62
62
|
inReplyTo: "<abc@mail.example.com>", references: "<abc@mail.example.com>",
|
|
63
63
|
}, { idempotencyKey: `invoice-42` });
|
|
64
64
|
|
|
65
|
+
// Account: identity + usage, and a full JSON export
|
|
66
|
+
const me = await mm.account.me();
|
|
67
|
+
const backup = await mm.account.export();
|
|
68
|
+
|
|
69
|
+
// Upload an image to embed in an outgoing email (returns a public url)
|
|
70
|
+
const { url } = await mm.domains.uploadImage(domainId, imageBlob);
|
|
71
|
+
|
|
65
72
|
// Suppression list (hard bounces / complaints)
|
|
66
73
|
await mm.suppressions.list(domainId);
|
|
67
74
|
await mm.suppressions.remove(domainId, "fixed@example.com");
|
package/dist/index.cjs
CHANGED
|
@@ -120,6 +120,12 @@ var DomainsResource = class {
|
|
|
120
120
|
removeLogo(id) {
|
|
121
121
|
return this.req(`/api/domains/${id}/logo`, { method: "DELETE" });
|
|
122
122
|
}
|
|
123
|
+
/** Imagen para incrustar en un correo saliente (PNG, JPG, GIF o WebP; máx. 2 MB). Efímera: se borra tras enviarse o por el barrido diario. */
|
|
124
|
+
uploadImage(id, file, filename = "imagen") {
|
|
125
|
+
const form = new FormData();
|
|
126
|
+
form.append("file", file, filename);
|
|
127
|
+
return this.req(`/api/domains/${id}/images`, { method: "POST", body: form });
|
|
128
|
+
}
|
|
123
129
|
};
|
|
124
130
|
var DnsResource = class {
|
|
125
131
|
constructor(req) {
|
|
@@ -448,6 +454,18 @@ var AccountResource = class {
|
|
|
448
454
|
constructor(req) {
|
|
449
455
|
this.req = req;
|
|
450
456
|
}
|
|
457
|
+
/**
|
|
458
|
+
* Identidad y uso de la cuenta: dominios, derechos por dominio, add-ons y cuotas.
|
|
459
|
+
* Sustituto de `whoami` mientras no exista un endpoint de identidad más chico — ver
|
|
460
|
+
* `docs/agents/mailmask-cli.md`.
|
|
461
|
+
*/
|
|
462
|
+
me() {
|
|
463
|
+
return this.req("/api/auth/me");
|
|
464
|
+
}
|
|
465
|
+
/** Todo tu dato (alias, reglas y logs de cada dominio) como JSON exportable. */
|
|
466
|
+
export() {
|
|
467
|
+
return this.req("/api/export");
|
|
468
|
+
}
|
|
451
469
|
getProfile() {
|
|
452
470
|
return this.req("/api/profile");
|
|
453
471
|
}
|
package/dist/index.d.cts
CHANGED
|
@@ -535,6 +535,93 @@ interface AccountProfile {
|
|
|
535
535
|
/** Ruta relativa al host de MailMask (`/api/avatar/...`), o null sin foto. */
|
|
536
536
|
avatarUrl: string | null;
|
|
537
537
|
}
|
|
538
|
+
/** Derechos y uso de UN dominio, dentro de `AccountMe.porDominio`. */
|
|
539
|
+
interface AccountMeDomainUsage {
|
|
540
|
+
id: string;
|
|
541
|
+
domain: string;
|
|
542
|
+
/** Límites del dominio (sends, aliases, dominios, etc.), por plan y add-ons. */
|
|
543
|
+
derechos: Record<string, unknown>;
|
|
544
|
+
addons: Addon[];
|
|
545
|
+
uso: {
|
|
546
|
+
aliases: {
|
|
547
|
+
current: number;
|
|
548
|
+
limit: number;
|
|
549
|
+
};
|
|
550
|
+
rules: {
|
|
551
|
+
current: number;
|
|
552
|
+
limit: number;
|
|
553
|
+
};
|
|
554
|
+
sends: {
|
|
555
|
+
current: number;
|
|
556
|
+
limit: number;
|
|
557
|
+
};
|
|
558
|
+
forwards: {
|
|
559
|
+
current: number;
|
|
560
|
+
limit: number;
|
|
561
|
+
};
|
|
562
|
+
mailboxBytes: {
|
|
563
|
+
current: number;
|
|
564
|
+
limit: number;
|
|
565
|
+
};
|
|
566
|
+
};
|
|
567
|
+
}
|
|
568
|
+
/** Respuesta de `account.me()`: identidad de la cuenta y su uso, por dominio y total. */
|
|
569
|
+
interface AccountMe extends AccountProfile {
|
|
570
|
+
isAdmin: boolean;
|
|
571
|
+
assistant: boolean;
|
|
572
|
+
domainsCount: number;
|
|
573
|
+
emailVerified: boolean;
|
|
574
|
+
forwards: {
|
|
575
|
+
current: number;
|
|
576
|
+
limit: number;
|
|
577
|
+
};
|
|
578
|
+
subscription: {
|
|
579
|
+
plan: string;
|
|
580
|
+
status: string;
|
|
581
|
+
currentPeriodEnd: string | null;
|
|
582
|
+
planLabel: string;
|
|
583
|
+
[k: string]: unknown;
|
|
584
|
+
};
|
|
585
|
+
porDominio: AccountMeDomainUsage[];
|
|
586
|
+
addons: Addon[];
|
|
587
|
+
planPriceCents: number | null;
|
|
588
|
+
addonCatalog: Record<string, {
|
|
589
|
+
price: number;
|
|
590
|
+
label: string;
|
|
591
|
+
}>;
|
|
592
|
+
addonsForSale: string[];
|
|
593
|
+
lastOrder: Order | null;
|
|
594
|
+
usage: {
|
|
595
|
+
domains: {
|
|
596
|
+
current: number;
|
|
597
|
+
limit: number | null;
|
|
598
|
+
};
|
|
599
|
+
aliasesPerDomain: unknown[];
|
|
600
|
+
rulesPerDomain: unknown[];
|
|
601
|
+
sendsPerDomain: unknown[];
|
|
602
|
+
};
|
|
603
|
+
referralSlug?: string | null;
|
|
604
|
+
referralStats: ReferralStats;
|
|
605
|
+
}
|
|
606
|
+
/** Respuesta de `account.export()`: todo el dato del usuario, listo para descargar. */
|
|
607
|
+
interface AccountExport {
|
|
608
|
+
email: string;
|
|
609
|
+
exportedAt: string;
|
|
610
|
+
domains: {
|
|
611
|
+
domain: string;
|
|
612
|
+
domainId: string;
|
|
613
|
+
verified: boolean;
|
|
614
|
+
aliases: Alias[];
|
|
615
|
+
rules: Rule[];
|
|
616
|
+
logs: EmailLog[];
|
|
617
|
+
}[];
|
|
618
|
+
}
|
|
619
|
+
/** Respuesta de `domains.uploadImage()`. */
|
|
620
|
+
interface UploadedEmailImage {
|
|
621
|
+
ok: boolean;
|
|
622
|
+
/** Efímera: se borra tras enviarse (o la barre el aseo diario si nunca se usó). */
|
|
623
|
+
url: string;
|
|
624
|
+
}
|
|
538
625
|
type InboxStatus = "open" | "snoozed" | "closed";
|
|
539
626
|
interface InboxConversation {
|
|
540
627
|
id: string;
|
|
@@ -730,6 +817,8 @@ declare class DomainsResource {
|
|
|
730
817
|
removeLogo(id: string): Promise<{
|
|
731
818
|
ok: boolean;
|
|
732
819
|
}>;
|
|
820
|
+
/** Imagen para incrustar en un correo saliente (PNG, JPG, GIF o WebP; máx. 2 MB). Efímera: se borra tras enviarse o por el barrido diario. */
|
|
821
|
+
uploadImage(id: string, file: Blob, filename?: string): Promise<UploadedEmailImage>;
|
|
733
822
|
}
|
|
734
823
|
declare class DnsResource {
|
|
735
824
|
private req;
|
|
@@ -985,6 +1074,14 @@ declare class CannedResource {
|
|
|
985
1074
|
declare class AccountResource {
|
|
986
1075
|
private req;
|
|
987
1076
|
constructor(req: Req);
|
|
1077
|
+
/**
|
|
1078
|
+
* Identidad y uso de la cuenta: dominios, derechos por dominio, add-ons y cuotas.
|
|
1079
|
+
* Sustituto de `whoami` mientras no exista un endpoint de identidad más chico — ver
|
|
1080
|
+
* `docs/agents/mailmask-cli.md`.
|
|
1081
|
+
*/
|
|
1082
|
+
me(): Promise<AccountMe>;
|
|
1083
|
+
/** Todo tu dato (alias, reglas y logs de cada dominio) como JSON exportable. */
|
|
1084
|
+
export(): Promise<AccountExport>;
|
|
988
1085
|
getProfile(): Promise<AccountProfile>;
|
|
989
1086
|
/** Nombre visible (máx. 60 caracteres). Cadena vacía lo borra. */
|
|
990
1087
|
updateProfile(input: {
|
|
@@ -1077,4 +1174,4 @@ interface WebhookSignatureHeaders {
|
|
|
1077
1174
|
*/
|
|
1078
1175
|
declare function verifyWebhookSignature(secret: string, headers: WebhookSignatureHeaders, rawBody: string, toleranceMs?: number): Promise<boolean>;
|
|
1079
1176
|
|
|
1080
|
-
export { type AccountProfile, type Addon, type AddonsResponse, type Address, type AddressCreated, type Alias, type AliasCreated, type ApiKey, type AttachmentRef, type BillingStatus, type BulkJob, type BulkJobCreated, type BulkSendInput, type CannedReply, type CheckoutLink, type CreateAddressInput, type CreateAliasInput, type CreateRuleInput, type CreateWebhookInput, type DnsChangeResult, type DnsDelegation, type DnsImportResult, type DnsListResponse, type DnsPreset, type DnsRRSet, type DnsRRSetAnotado, type DnsRecord, type DnsRecordType, type DnsSetup, type DnsSetupRecord, type DnsZoneCreated, type DnsZoneState, type Domain, type DomainCreated, type DomainInvite, type DomainMember, type DomainRegistration, type DomainRegistrationCreated, type DomainSearchResult, type DomainVerification, type EmailLog, type InboxAttachment, type InboxComposeInput, type InboxConversation, type InboxConversationDetail, type InboxListOptions, type InboxMessage, type InboxNote, type InboxPage, type InboxReplyInput, type InboxStatus, type InboxUpdateInput, MailMask, type MailMaskConfig, MailMaskError, type MailboxCreated, type Order, type OrdersPage, type ReferralStats, type RenewalLink, type Rule, type RuleAction, type RuleField, type RuleMatch, type SendEmailInput, type SendOptions, type SmtpCredential, type SmtpCredentialCreated, type Suppression, type TldPrice, type TransferCheck, type TransferDnsInventory, type TransferRequirement, type UpdateAddressInput, type UpdateAliasInput, type UpdateRuleInput, type UpdateWebhookInput, type UploadAttachmentInput, type UploadedAttachment, type Webhook, type WebhookCreated, type WebhookDelivery, type WebhookEvent, type WebhookPayload, type WebhookSignatureHeaders, verifyWebhookSignature };
|
|
1177
|
+
export { type AccountExport, type AccountMe, type AccountMeDomainUsage, type AccountProfile, type Addon, type AddonsResponse, type Address, type AddressCreated, type Alias, type AliasCreated, type ApiKey, type AttachmentRef, type BillingStatus, type BulkJob, type BulkJobCreated, type BulkSendInput, type CannedReply, type CheckoutLink, type CreateAddressInput, type CreateAliasInput, type CreateRuleInput, type CreateWebhookInput, type DnsChangeResult, type DnsDelegation, type DnsImportResult, type DnsListResponse, type DnsPreset, type DnsRRSet, type DnsRRSetAnotado, type DnsRecord, type DnsRecordType, type DnsSetup, type DnsSetupRecord, type DnsZoneCreated, type DnsZoneState, type Domain, type DomainCreated, type DomainInvite, type DomainMember, type DomainRegistration, type DomainRegistrationCreated, type DomainSearchResult, type DomainVerification, type EmailLog, type InboxAttachment, type InboxComposeInput, type InboxConversation, type InboxConversationDetail, type InboxListOptions, type InboxMessage, type InboxNote, type InboxPage, type InboxReplyInput, type InboxStatus, type InboxUpdateInput, MailMask, type MailMaskConfig, MailMaskError, type MailboxCreated, type Order, type OrdersPage, type ReferralStats, type RenewalLink, type Rule, type RuleAction, type RuleField, type RuleMatch, type SendEmailInput, type SendOptions, type SmtpCredential, type SmtpCredentialCreated, type Suppression, type TldPrice, type TransferCheck, type TransferDnsInventory, type TransferRequirement, type UpdateAddressInput, type UpdateAliasInput, type UpdateRuleInput, type UpdateWebhookInput, type UploadAttachmentInput, type UploadedAttachment, type UploadedEmailImage, type Webhook, type WebhookCreated, type WebhookDelivery, type WebhookEvent, type WebhookPayload, type WebhookSignatureHeaders, verifyWebhookSignature };
|
package/dist/index.d.ts
CHANGED
|
@@ -535,6 +535,93 @@ interface AccountProfile {
|
|
|
535
535
|
/** Ruta relativa al host de MailMask (`/api/avatar/...`), o null sin foto. */
|
|
536
536
|
avatarUrl: string | null;
|
|
537
537
|
}
|
|
538
|
+
/** Derechos y uso de UN dominio, dentro de `AccountMe.porDominio`. */
|
|
539
|
+
interface AccountMeDomainUsage {
|
|
540
|
+
id: string;
|
|
541
|
+
domain: string;
|
|
542
|
+
/** Límites del dominio (sends, aliases, dominios, etc.), por plan y add-ons. */
|
|
543
|
+
derechos: Record<string, unknown>;
|
|
544
|
+
addons: Addon[];
|
|
545
|
+
uso: {
|
|
546
|
+
aliases: {
|
|
547
|
+
current: number;
|
|
548
|
+
limit: number;
|
|
549
|
+
};
|
|
550
|
+
rules: {
|
|
551
|
+
current: number;
|
|
552
|
+
limit: number;
|
|
553
|
+
};
|
|
554
|
+
sends: {
|
|
555
|
+
current: number;
|
|
556
|
+
limit: number;
|
|
557
|
+
};
|
|
558
|
+
forwards: {
|
|
559
|
+
current: number;
|
|
560
|
+
limit: number;
|
|
561
|
+
};
|
|
562
|
+
mailboxBytes: {
|
|
563
|
+
current: number;
|
|
564
|
+
limit: number;
|
|
565
|
+
};
|
|
566
|
+
};
|
|
567
|
+
}
|
|
568
|
+
/** Respuesta de `account.me()`: identidad de la cuenta y su uso, por dominio y total. */
|
|
569
|
+
interface AccountMe extends AccountProfile {
|
|
570
|
+
isAdmin: boolean;
|
|
571
|
+
assistant: boolean;
|
|
572
|
+
domainsCount: number;
|
|
573
|
+
emailVerified: boolean;
|
|
574
|
+
forwards: {
|
|
575
|
+
current: number;
|
|
576
|
+
limit: number;
|
|
577
|
+
};
|
|
578
|
+
subscription: {
|
|
579
|
+
plan: string;
|
|
580
|
+
status: string;
|
|
581
|
+
currentPeriodEnd: string | null;
|
|
582
|
+
planLabel: string;
|
|
583
|
+
[k: string]: unknown;
|
|
584
|
+
};
|
|
585
|
+
porDominio: AccountMeDomainUsage[];
|
|
586
|
+
addons: Addon[];
|
|
587
|
+
planPriceCents: number | null;
|
|
588
|
+
addonCatalog: Record<string, {
|
|
589
|
+
price: number;
|
|
590
|
+
label: string;
|
|
591
|
+
}>;
|
|
592
|
+
addonsForSale: string[];
|
|
593
|
+
lastOrder: Order | null;
|
|
594
|
+
usage: {
|
|
595
|
+
domains: {
|
|
596
|
+
current: number;
|
|
597
|
+
limit: number | null;
|
|
598
|
+
};
|
|
599
|
+
aliasesPerDomain: unknown[];
|
|
600
|
+
rulesPerDomain: unknown[];
|
|
601
|
+
sendsPerDomain: unknown[];
|
|
602
|
+
};
|
|
603
|
+
referralSlug?: string | null;
|
|
604
|
+
referralStats: ReferralStats;
|
|
605
|
+
}
|
|
606
|
+
/** Respuesta de `account.export()`: todo el dato del usuario, listo para descargar. */
|
|
607
|
+
interface AccountExport {
|
|
608
|
+
email: string;
|
|
609
|
+
exportedAt: string;
|
|
610
|
+
domains: {
|
|
611
|
+
domain: string;
|
|
612
|
+
domainId: string;
|
|
613
|
+
verified: boolean;
|
|
614
|
+
aliases: Alias[];
|
|
615
|
+
rules: Rule[];
|
|
616
|
+
logs: EmailLog[];
|
|
617
|
+
}[];
|
|
618
|
+
}
|
|
619
|
+
/** Respuesta de `domains.uploadImage()`. */
|
|
620
|
+
interface UploadedEmailImage {
|
|
621
|
+
ok: boolean;
|
|
622
|
+
/** Efímera: se borra tras enviarse (o la barre el aseo diario si nunca se usó). */
|
|
623
|
+
url: string;
|
|
624
|
+
}
|
|
538
625
|
type InboxStatus = "open" | "snoozed" | "closed";
|
|
539
626
|
interface InboxConversation {
|
|
540
627
|
id: string;
|
|
@@ -730,6 +817,8 @@ declare class DomainsResource {
|
|
|
730
817
|
removeLogo(id: string): Promise<{
|
|
731
818
|
ok: boolean;
|
|
732
819
|
}>;
|
|
820
|
+
/** Imagen para incrustar en un correo saliente (PNG, JPG, GIF o WebP; máx. 2 MB). Efímera: se borra tras enviarse o por el barrido diario. */
|
|
821
|
+
uploadImage(id: string, file: Blob, filename?: string): Promise<UploadedEmailImage>;
|
|
733
822
|
}
|
|
734
823
|
declare class DnsResource {
|
|
735
824
|
private req;
|
|
@@ -985,6 +1074,14 @@ declare class CannedResource {
|
|
|
985
1074
|
declare class AccountResource {
|
|
986
1075
|
private req;
|
|
987
1076
|
constructor(req: Req);
|
|
1077
|
+
/**
|
|
1078
|
+
* Identidad y uso de la cuenta: dominios, derechos por dominio, add-ons y cuotas.
|
|
1079
|
+
* Sustituto de `whoami` mientras no exista un endpoint de identidad más chico — ver
|
|
1080
|
+
* `docs/agents/mailmask-cli.md`.
|
|
1081
|
+
*/
|
|
1082
|
+
me(): Promise<AccountMe>;
|
|
1083
|
+
/** Todo tu dato (alias, reglas y logs de cada dominio) como JSON exportable. */
|
|
1084
|
+
export(): Promise<AccountExport>;
|
|
988
1085
|
getProfile(): Promise<AccountProfile>;
|
|
989
1086
|
/** Nombre visible (máx. 60 caracteres). Cadena vacía lo borra. */
|
|
990
1087
|
updateProfile(input: {
|
|
@@ -1077,4 +1174,4 @@ interface WebhookSignatureHeaders {
|
|
|
1077
1174
|
*/
|
|
1078
1175
|
declare function verifyWebhookSignature(secret: string, headers: WebhookSignatureHeaders, rawBody: string, toleranceMs?: number): Promise<boolean>;
|
|
1079
1176
|
|
|
1080
|
-
export { type AccountProfile, type Addon, type AddonsResponse, type Address, type AddressCreated, type Alias, type AliasCreated, type ApiKey, type AttachmentRef, type BillingStatus, type BulkJob, type BulkJobCreated, type BulkSendInput, type CannedReply, type CheckoutLink, type CreateAddressInput, type CreateAliasInput, type CreateRuleInput, type CreateWebhookInput, type DnsChangeResult, type DnsDelegation, type DnsImportResult, type DnsListResponse, type DnsPreset, type DnsRRSet, type DnsRRSetAnotado, type DnsRecord, type DnsRecordType, type DnsSetup, type DnsSetupRecord, type DnsZoneCreated, type DnsZoneState, type Domain, type DomainCreated, type DomainInvite, type DomainMember, type DomainRegistration, type DomainRegistrationCreated, type DomainSearchResult, type DomainVerification, type EmailLog, type InboxAttachment, type InboxComposeInput, type InboxConversation, type InboxConversationDetail, type InboxListOptions, type InboxMessage, type InboxNote, type InboxPage, type InboxReplyInput, type InboxStatus, type InboxUpdateInput, MailMask, type MailMaskConfig, MailMaskError, type MailboxCreated, type Order, type OrdersPage, type ReferralStats, type RenewalLink, type Rule, type RuleAction, type RuleField, type RuleMatch, type SendEmailInput, type SendOptions, type SmtpCredential, type SmtpCredentialCreated, type Suppression, type TldPrice, type TransferCheck, type TransferDnsInventory, type TransferRequirement, type UpdateAddressInput, type UpdateAliasInput, type UpdateRuleInput, type UpdateWebhookInput, type UploadAttachmentInput, type UploadedAttachment, type Webhook, type WebhookCreated, type WebhookDelivery, type WebhookEvent, type WebhookPayload, type WebhookSignatureHeaders, verifyWebhookSignature };
|
|
1177
|
+
export { type AccountExport, type AccountMe, type AccountMeDomainUsage, type AccountProfile, type Addon, type AddonsResponse, type Address, type AddressCreated, type Alias, type AliasCreated, type ApiKey, type AttachmentRef, type BillingStatus, type BulkJob, type BulkJobCreated, type BulkSendInput, type CannedReply, type CheckoutLink, type CreateAddressInput, type CreateAliasInput, type CreateRuleInput, type CreateWebhookInput, type DnsChangeResult, type DnsDelegation, type DnsImportResult, type DnsListResponse, type DnsPreset, type DnsRRSet, type DnsRRSetAnotado, type DnsRecord, type DnsRecordType, type DnsSetup, type DnsSetupRecord, type DnsZoneCreated, type DnsZoneState, type Domain, type DomainCreated, type DomainInvite, type DomainMember, type DomainRegistration, type DomainRegistrationCreated, type DomainSearchResult, type DomainVerification, type EmailLog, type InboxAttachment, type InboxComposeInput, type InboxConversation, type InboxConversationDetail, type InboxListOptions, type InboxMessage, type InboxNote, type InboxPage, type InboxReplyInput, type InboxStatus, type InboxUpdateInput, MailMask, type MailMaskConfig, MailMaskError, type MailboxCreated, type Order, type OrdersPage, type ReferralStats, type RenewalLink, type Rule, type RuleAction, type RuleField, type RuleMatch, type SendEmailInput, type SendOptions, type SmtpCredential, type SmtpCredentialCreated, type Suppression, type TldPrice, type TransferCheck, type TransferDnsInventory, type TransferRequirement, type UpdateAddressInput, type UpdateAliasInput, type UpdateRuleInput, type UpdateWebhookInput, type UploadAttachmentInput, type UploadedAttachment, type UploadedEmailImage, type Webhook, type WebhookCreated, type WebhookDelivery, type WebhookEvent, type WebhookPayload, type WebhookSignatureHeaders, verifyWebhookSignature };
|
package/dist/index.js
CHANGED
|
@@ -92,6 +92,12 @@ var DomainsResource = class {
|
|
|
92
92
|
removeLogo(id) {
|
|
93
93
|
return this.req(`/api/domains/${id}/logo`, { method: "DELETE" });
|
|
94
94
|
}
|
|
95
|
+
/** Imagen para incrustar en un correo saliente (PNG, JPG, GIF o WebP; máx. 2 MB). Efímera: se borra tras enviarse o por el barrido diario. */
|
|
96
|
+
uploadImage(id, file, filename = "imagen") {
|
|
97
|
+
const form = new FormData();
|
|
98
|
+
form.append("file", file, filename);
|
|
99
|
+
return this.req(`/api/domains/${id}/images`, { method: "POST", body: form });
|
|
100
|
+
}
|
|
95
101
|
};
|
|
96
102
|
var DnsResource = class {
|
|
97
103
|
constructor(req) {
|
|
@@ -420,6 +426,18 @@ var AccountResource = class {
|
|
|
420
426
|
constructor(req) {
|
|
421
427
|
this.req = req;
|
|
422
428
|
}
|
|
429
|
+
/**
|
|
430
|
+
* Identidad y uso de la cuenta: dominios, derechos por dominio, add-ons y cuotas.
|
|
431
|
+
* Sustituto de `whoami` mientras no exista un endpoint de identidad más chico — ver
|
|
432
|
+
* `docs/agents/mailmask-cli.md`.
|
|
433
|
+
*/
|
|
434
|
+
me() {
|
|
435
|
+
return this.req("/api/auth/me");
|
|
436
|
+
}
|
|
437
|
+
/** Todo tu dato (alias, reglas y logs de cada dominio) como JSON exportable. */
|
|
438
|
+
export() {
|
|
439
|
+
return this.req("/api/export");
|
|
440
|
+
}
|
|
423
441
|
getProfile() {
|
|
424
442
|
return this.req("/api/profile");
|
|
425
443
|
}
|