nextmail domains
Every command in this namespace, with its arguments, flags and examples.
Commands
Custom domains attached to the workspace: add and remove them, read the DNS records to publish, check whether they can receive and send, manage their addresses and their photos, and set the catch-all, the tracking and files domains, the DMARC policy, the sender name and the brand logo.
Every command here also takes the global flags, such as --json, --profile and --dry-run. See the global flags
domains listdomains getdomains createdomains verifydomains updatedomains deletedomains get-logodomains set-logodomains remove-logodomains set-logo-certificatedomains remove-logo-certificatedomains list-addressesdomains create-addressdomains get-addressdomains update-addressdomains set-address-photodomains remove-address-photodomains start-gravatar-publishdomains delete-addressdomains list-address-forwardsdomains add-address-forwardsdomains update-address-forwarddomains delete-address-forwarddomains resend-address-forward-consentdomains list-address-membersdomains get-address-logindomains set-address-logindomains delete-address-logindomains get-mail-app-settingsdomains update-mail-app-settingsdomains get-address-limitsdomains update-address-limitsdomains list-app-passwordsdomains create-app-passworddomains update-app-passworddomains delete-app-passworddomains send-mail-app-setupdomains create-mail-app-profile-linkdomains get-dnsdomains set-dns-zonedomains sync-dnsdomains list-routesdomains create-routedomains get-routedomains update-routedomains delete-routedomains test-routedomains list-group-membersdomains add-group-membersdomains remove-group-member
nextmail domains list
List the workspace's domains and their receiving state
lsUsage
nextmail domains list [flags]
Returns one page of the domains added to the workspace, alphabetically by domain. receiving reports the inbound checks: verified is true once verifiedAt is set, catchAll is the domain's catch all setting, lastCheckedAt is the most recent check and error is the last verification failure.
receiving and sending are independent. A verified domain can receive mail, and that says nothing about whether outbound mail from it is signed. sending.status is the signing state as the last check saw it, one of verified, pending, failed, no_identity or unknown, sending.canSend says whether a send from the domain would be accepted right now, sending.checkedAt dates that verdict, and sending.error carries the last failure. A negative verdict older than a day is treated as unknown rather than as a refusal, so canSend can be true while status is pending.
tracking reports the domain's custom tracking domain, set with update, and only a tracking.status of active means tracked links and the open pixel in new mail from the domain use its host instead of the default Nextmail host. storage reports the domain's custom files domain the same way, and only a storage.status of active means the download links for files sent from the domain use its host.
Add --all to walk every page: a table on a terminal, one JSON object per line when piped or with --ndjson, and one { items, hasMore, nextCursor } document with --json. --max <n> stops after that many items.
Flags
--limit <n>Page size, from 1 to 100. The server defaults to 25.
Default25--cursor <value>The
nextCursorof the previous page. Leave it out for the first page.--q <value>Narrows to domains whose name or id matches, up to 200 characters. Every word has to appear in one of them, ignoring case and accents, and when nothing matches exactly the search allows for a typo instead.
--allFetch every page and stream the items as they arrive.
--max <n>Stop after this many items. Implies
--all.--ndjsonPrint every item as one JSON object per line. Implies
--all
Examples
nextmail domains listnextmail domains list --all --max 100nextmail domains list --all > domains.ndjsonAlso available in
- API
GET /domains- TypeScript
domains.list()- Python
domains.list()- Ruby
domains.list- PHP
domains->list- Go
Domains.List- Java
domains().list- C#
Domains.ListAsync
nextmail domains get
Read one domain with its addresses, DNS records and DMARC reading
showviewUsage
nextmail domains get <id> [flags]
Returns the same receiving and sending blocks as list, plus addresses: every address on the domain as a full lower cased address with its enabled flag. Disabled addresses are listed too. listAddresses returns the same addresses with their ids and labels. It also carries the tracking and storage blocks described on list, whose record is the CNAME record to add at your DNS provider for the tracking domain and for the files domain.
records is every DNS record the domain uses, each with type, name, value, priority on an MX record, a purpose written to be shown to a person, and status: found when the last check saw it in public DNS, missing when it did not, and null when it has not been checked yet. found lists what public DNS answered at that name, and problem names the usual reason a record does not match, such as the domain added to the name twice, a value saved with its quote marks or a proxied CNAME, with a message to show a person. Publish each one exactly as given, since the values are specific to this domain. autodiscoveryRecords lists the SRV and TXT records that let mail apps set themselves up, while autodiscovery is true. dmarc is the domain's DMARC record as public DNS has it, with its stage, any issues, and whether a policy stricter than p=none is safe yet. It is null until the domain is verified.
Reading an unverified domain checks its DNS again when the last check is more than 20 seconds old, so polling get is one way to wait for verification. verify checks straight away.
The id must belong to the calling workspace. Another workspace's domain id is a 404, the same as an id that does not exist, and the domain name is not accepted in its place.
Arguments
<id>RequiredDomain id from
list, a UUID.
Examples
nextmail domains get b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains get b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --jsonAlso available in
- API
GET /domains/{id}- TypeScript
domains.get()- Python
domains.get()- Ruby
domains.get- PHP
domains->get- Go
Domains.Get- Java
domains().get- C#
Domains.GetAsync
nextmail domains create
Add a domain to the workspace
newaddUsage
nextmail domains create --domain <value> [flags] nextmail domains create --data <json|@file|-> [flags]
Adds a domain and returns it with every DNS record to publish, in the same shape as get. The first DNS check runs during the call, so records[].status already says what public DNS answers with.
The domain receives mail once public DNS answers with its MX records and its ownership TXT record, and it can send once its signing records are in place. Publish every entry in records exactly as given, since the values are specific to this domain, then call verify or poll get until receiving.verified is true.
A new domain starts with its catch-all on and no addresses. Create addresses with createAddress, or turn the catch-all off with update.
Flags
--domain <value>A bare domain such as
example.com. It is trimmed, lower cased and converted to its ASCII form, so an internationalised name is stored as punycode. Required, here or in--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains create --domain example.comnextmail domains create --data @domain.jsonAlso available in
- API
POST /domains- TypeScript
domains.create()- Python
domains.create()- Ruby
domains.create- PHP
domains->create- Go
Domains.Create- Java
domains().create- C#
Domains.CreateAsync
nextmail domains verify
Check a domain's DNS now
Usage
nextmail domains verify <id> [flags]
Checks the DNS of the domain straight away and returns it in the same shape as get. On an unverified domain it looks for the records that verify it, and receiving.verified comes back true when they are found. On a verified domain it checks the signing and return path records again and asks whether mail from the domain can be sent, so sending is fresh.
When the last check ran less than 10 seconds ago, nothing new is checked and the domain comes back as it stands, so calling it faster than that gains nothing. A record published a moment ago can take a few minutes to show up in public DNS.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Examples
nextmail domains verify b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains verify b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --jsonAlso available in
- API
POST /domains/{id}/verify- TypeScript
domains.verify()- Python
domains.verify()- Ruby
domains.verify- PHP
domains->verify- Go
Domains.Verify- Java
domains().verify- C#
Domains.VerifyAsync
nextmail domains update
Turn the catch-all on or off, set or remove the tracking and files domains, set the DMARC policy and the sender name, offer the records mail apps set themselves up from, and make the domain an alias
editUsage
nextmail domains update <id> [flags]
--catch-all true accepts mail to any address on the domain that nobody created, and the address shows up in listAddresses from its first message on. False refuses mail to every address that was not created by hand, including the ones the catch-all picked up before. It applies to the whole domain, so only a key that holds the whole domain may change it.
--tracking-host and --storage-host set the two custom names a domain can carry once it is verified or its ownership TXT record is published, each of them a subdomain of it. --tracking-host, such as links.example.com, is the name tracked links and the open pixel use. --storage-host, such as files.example.com, is the name the download links for files sent from the domain use. All seven fields are optional and independent: a field left out is left alone, and for either host null removes that name and a string sets it. A patch carrying none of them changes nothing and answers with the domain as it stands. Each value is trimmed and lower cased, and a leading https:// or http://, any path, query or fragment and any trailing dots are stripped.
A new host is validated, saved and checked in the same call, so the response already carries the result of that first check. --tracking-host reports into the tracking block and --storage-host into storage, and the two blocks carry the same fields. The check asks the host over HTTPS for an answer signed by Nextmail, on /t/v/<nonce> for a tracking domain and /f/v/<nonce> for a files domain, so the host needs a CNAME record named record.name with the value record.value, with any proxying turned off. That value, also reported as target, is an address prepared for this host alone. When it could not be prepared during the call, record is null, target is an empty string and error says so, and it is finished within a few minutes without another call. Until a check passes, status is pending and new mail keeps using the default Nextmail host. Once one passes, status is active and new mail from the domain uses the host.
Sending a host the domain already has runs the check again, unless the last check was less than 30 seconds ago, in which case the stored state comes back unchanged. A different host replaces the current one at once, so new mail uses the default host until the new one passes a check. null removes that name, and its block then reports status as none with host and record null.
--dmarc-policy is what the domain's DMARC record tells receivers to do with mail that fails its checks: none only monitors, quarantine sends it to spam and reject refuses it. Inboxes show the domain logo only at quarantine or reject, and where Nextmail writes the DNS for the domain the record is updated during the call, keeping its other tags such as rua, while elsewhere you publish the DMARC record records lists.
--sender-name is the name recipients see beside every address on the domain that has no name of its own, such as Acme Support. Mail sent without a name in from goes out under the name of the address, then this one, then the name of the workspace. It is trimmed, and null or a string that is empty once trimmed removes it.
autodiscovery true offers the SRV and TXT records that let mail, calendar and contacts apps find the servers from an address on the domain alone, for IMAP, SMTP, POP3, CalDAV and CardDAV. They are listed in autodiscoveryRecords with what the last check found, and none of them is needed to verify the domain or to send from it. Where Nextmail writes the DNS for the domain they are written during the call and false takes them down again, while elsewhere you publish them yourself.
--alias-of makes the domain an alias of another domain of the workspace. Mail to local@ the alias is then handled exactly as local@ the primary domain, through its addresses, routes, group addresses and catch-all, and local@ the alias may be used as a From address wherever local@ the primary may. null stops it being an alias. The domain then reads --alias-of, and the primary lists it in aliases.
Arguments
<id>RequiredDomain id from
list, a UUID.
Flags
--catch-allTrue accepts mail to any address on the domain that nobody created, false refuses it. Leaving the field out leaves the catch-all alone.
--tracking-host <value>A subdomain of the domain of at most 512 characters, such as
links.example.com. Null removes the tracking domain, and leaving the field out leaves it alone.--storage-host <value>A subdomain of the domain of at most 512 characters, such as
files.example.com. Null removes the files domain, and leaving the field out leaves it alone.--dmarc-policy <value>none,quarantineorreject. A policy stricter thannoneneeds mail from the domain to be signed first. Leaving the field out leaves the policy alone.--sender-name <value>The name mail from the domain goes out under when the address has no name of its own, at most 120 characters once trimmed, such as
Acme Support. Null removes it, and leaving the field out leaves it alone.--autodiscoveryTrue offers the SRV and TXT records that let mail, calendar and contacts apps find the servers from an address on the domain alone, false stops offering them. They are listed in
autodiscoveryRecords, and where the DNS of the domain is written for it they are written or taken down at once. Leaving the field out leaves it alone.--alias-of <value>The id of another domain hosted in this workspace to make this domain an alias of, or null to stop it being one. The other domain may not be an alias itself, this domain may not have aliases of its own, and it may not hold addresses created by hand or routes. Leaving the field out leaves it alone.
--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --tracking-host links.example.com --storage-host files.example.comnextmail domains update b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --tracking-host links.example.com --storage-host files.example.com --jsonAlso available in
- API
PATCH /domains/{id}- TypeScript
domains.update()- Python
domains.update()- Ruby
domains.update- PHP
domains->update- Go
Domains.Update- Java
domains().update- C#
Domains.UpdateAsync
nextmail domains delete
Remove a domain from the workspace
rmdelremoveUsage
nextmail domains delete <id> [flags]
Removes the domain. Mail to it stops being accepted and nothing can be sent from it. Every address on it goes with it, their password sign-ins are revoked, its signing key is released, its tracking and files domains are retired, and the domain.deleted webhook fires. Mail already received stays in the mailbox, unless this is the last domain of the workspace.
Where Nextmail wrote the DNS for this domain itself, it takes those records back, and any it could not take back are listed in leftBehind for you to remove at your DNS provider. Records you published yourself are never touched, so remove them too once the domain is gone.
Removing the last domain of a workspace deletes the whole mailbox with it, every message for good, as removing it in the app does, so it needs --confirm, the name of the domain, the way the app asks the person to type it. mailboxPurged in the result says whether the mailbox went with it.
There is no undo. Adding the domain again starts it from scratch.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--confirm <value>The name of the domain, which removing the last domain of the workspace needs, because that deletes the whole mailbox with it. Letter case and the spaces around it do not matter, and a name that does not match is refused whichever domain it is. Sent as a query parameter.
Examples
nextmail domains delete b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains delete b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --yesAlso available in
- API
DELETE /domains/{id}- TypeScript
domains.delete()- Python
domains.delete()- Ruby
domains.delete- PHP
domains->delete- Go
Domains.Delete- Java
domains().delete- C#
Domains.DeleteAsync
nextmail domains get-logo
Read the brand logo of a domain and what public DNS publishes for it
Usage
nextmail domains get-logo <id> [flags]
Returns the logo inboxes show next to mail from the domain through BIMI, with its mark certificate and DMARC policy, and asks public DNS what default._bimi.<domain> holds right now: published.ours turns true once the record pointing at the logo is live. For a subdomain, parentDmarc reports the DMARC record of the domain it belongs to, because inboxes show the logo only when its p= and sp= both quarantine or reject at 100 percent.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Examples
nextmail domains get-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains get-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --jsonAlso available in
nextmail domains set-logo
Upload the brand logo inboxes show for a domain
Usage
nextmail domains set-logo <id> --svg <value> [flags] nextmail domains set-logo <id> --data <json|@file|-> [flags]
Converts the SVG to the SVG Tiny PS format inboxes require, replaces any logo the domain had, and publishes the BIMI record where Nextmail writes the DNS for the domain. Inboxes show the logo once dmarcPolicy is quarantine or reject, which update sets, and Gmail also needs a mark certificate from setLogoCertificate.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--svg <value>The logo as SVG markup, up to 1 MB. A file that is SVG Tiny PS already is kept byte for byte, so it stays the same as the copy inside a mark certificate. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains set-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --svg examplenextmail domains set-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains remove-logo
Remove the brand logo of a domain
Usage
nextmail domains remove-logo <id> [flags]
Removes the logo and deletes the stored file, and takes the BIMI record down where Nextmail writes the DNS for the domain. Elsewhere remove the record yourself. Any mark certificate stays, ready for the next logo.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Examples
nextmail domains remove-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains remove-logo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --yesAlso available in
nextmail domains set-logo-certificate
Upload the mark certificate for a domain logo
Usage
nextmail domains set-logo-certificate <id> --certificate <value> [flags] nextmail domains set-logo-certificate <id> --data <json|@file|-> [flags]
Stores the Verified Mark Certificate (VMC) or Common Mark Certificate (CMC) a certificate authority issued for the domain, replacing any there was, and points the BIMI record at it. Gmail shows the logo only with one and Apple Mail only with a VMC, and when the logo inside the certificate differs from the published one, it becomes the published one and logoFromCertificate is true.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--certificate <value>The file the certificate authority sent, up to 128 KB: PEM text as it came, which can hold the whole chain, or a DER or PKCS #7 file encoded as base64. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains set-logo-certificate b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --certificate examplenextmail domains set-logo-certificate b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains remove-logo-certificate
Remove the mark certificate of a domain logo
Usage
nextmail domains remove-logo-certificate <id> [flags]
Removes the mark certificate and deletes the stored file, while the logo stays. The BIMI record no longer points at a certificate, so Gmail and Apple Mail stop showing the logo.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Examples
nextmail domains remove-logo-certificate b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains remove-logo-certificate b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --yesAlso available in
nextmail domains list-addresses
List one page of the addresses on a domain
Usage
nextmail domains list-addresses <id> [flags]
Returns one page of the addresses on the domain, alphabetically by address, with each one's id, label, enabled and lastReceivedAt. That covers the addresses created by hand or through the API and the ones the catch-all picked up when mail first arrived for them. Disabled addresses are listed. Removed addresses and the catch-all itself are not: the catch-all is receiving.catchAll on the domain.
Add --all to walk every page: a table on a terminal, one JSON object per line when piped or with --ndjson, and one { items, hasMore, nextCursor } document with --json. --max <n> stops after that many items.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--limit <n>Page size, from 1 to 100. The server defaults to 25.
Default25--cursor <value>The
nextCursorof the previous page. Leave it out for the first page.--allFetch every page and stream the items as they arrive.
--max <n>Stop after this many items. Implies
--all.--ndjsonPrint every item as one JSON object per line. Implies
--all
Examples
nextmail domains list-addresses b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains list-addresses b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --limit 100nextmail domains list-addresses b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --all --max 100nextmail domains list-addresses b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --all > domains.ndjsonAlso available in
nextmail domains create-address
Create an address on a domain
Usage
nextmail domains create-address <id> --local-part <value> [flags] nextmail domains create-address <id> --data <json|@file|-> [flags]
Creates an address on the domain, enabled, and returns it. The domain does not have to be verified yet, but the address receives nothing until it is.
When the domain has its catch-all on, the new address starts with the per-address settings of the catch-all, such as its signature and tracking, apart from the privacy settings. They are copied once, not kept in step.
Creating an address that already exists, or one that was removed, is not an error: it comes back enabled, with the label you sent or none, and keeps its id. An address the catch-all picked up becomes one created by hand, so it keeps receiving when the catch-all is turned off.
The address can start with where its mail goes, an expiry and group settings, the same fields updateAddress takes.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--local-part <value>The part in front of the @, 1 to 64 characters once trimmed, lower cased. Letters, digits, the backtick and ! # $ % & ' * + / = ? ^ _ { | } ~ - are allowed, and so are dots between them.
*on its own is how the catch-all is written and is refused. Required, here or in--data.--label <value>A name for the address shown in the app, trimmed, up to 120 characters. Leave it out, or send null, for none.
--keep-originalTrue keeps every message the address receives byte for byte as it arrived, which
threads.getRawMessagethen returns. Left out, it stays off for a new address and as it is for one that already exists.--destination <value>mailbox, the default, keeps the mail here,webhooksends every message to the endpoint in--webhook-id, andgroupsends it to the group members.forwardneeds a forwarding destination that is on, which a new address never has.--webhook-id <value>A webhook endpoint of this workspace mail goes to, sent with
destination: 'webhook'. Needsthreads:read.--tap-webhook-ids <a,b>RepeatableUp to 5 webhook endpoints of this workspace that also get every message the address receives. Naming any needs
threads:read.--expires-at <value>An RFC 3339 time from 60 seconds to 10 years ahead when the address expires. Left out or null, it never expires.
--on-expiry <value>stop, the default, switches the address off when it expires and keeps its mail.deleteremoves it and the conversations delivered to it, which needsthreads:write.--group-posting <value>Who may send to a group address:
anyone, the default,membersorworkspace.--group-keep-copyTrue keeps each message sent to a group in the group address's own mailbox too.
--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains create-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --local-part supportnextmail domains create-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --local-part support --label Supportnextmail domains create-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains get-address
Read one address on a domain
Usage
nextmail domains get-address <id> <address-id> [flags]
Returns one address on the domain with its label, enabled, lastReceivedAt and timestamps.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains get-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains get-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains update-address
Rename an address, turn it off and on, choose where its mail goes, set when it expires or keep its originals
Usage
nextmail domains update-address <id> <address-id> [flags]
Changes the fields you send and leaves the rest alone. label renames the address, and null removes the name. enabled false stops the address taking mail: mail to it is refused while the sending server is still connected, so the sender gets a bounce, and nothing can be sent from it. It keeps its mail, its settings and the people who can reach it, so enabled true picks up where it left off. That is the difference from deleteAddress.
destination chooses where the mail of the address goes: mailbox keeps a copy here, as an address does by default, and forward only sends it on to the destinations from addAddressForwards, keeping nothing here. forward needs at least one destination that is switched on. webhook sends every message to the endpoint in --webhook-id and keeps none here, and group sends it to the group members of the address, with --group-posting deciding who may post and --group-keep-copy whether the group keeps a copy. --tap-webhook-ids copies every message the address receives to up to 5 endpoints as well.
--expires-at gives the address a time to expire: from then on it takes no mail and sends none, and within a minute it is switched off, or deleted with the conversations delivered to it when --on-expiry is delete. A later --expires-at, null, or enabled true turns an expired address back on.
--keep-original true keeps every message the address receives from then on byte for byte as it arrived, for threads.getRawMessage.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--label <value>A new name, trimmed, up to 120 characters. Null removes it.
--enabledFalse stops the address taking mail, true takes mail again.
--destination <value>mailboxkeeps a copy of the mail here,forwardonly forwards it,webhooksends every message to the endpoint in--webhook-idand keeps none here, andgroupsends it to the group members.--keep-originalTrue keeps every message the address receives from now on byte for byte as it arrived, which
threads.getRawMessagethen returns. False stops keeping new ones, and the originals already kept stay with their messages.--webhook-id <value>A webhook endpoint of this workspace mail goes to, sent with
destination: 'webhook'or alone to change the endpoint of an address that already sends to one. Needsthreads:read.--tap-webhook-ids <a,b>RepeatableUp to 5 webhook endpoints of this workspace that also get every message the address receives. Replaces the list, and an empty array or null clears it. Naming any needs
threads:read.--expires-at <value>An RFC 3339 time from 60 seconds to 10 years ahead when the address expires. Null clears it, and on an expired address a later time or null turns it back on.
--on-expiry <value>stop, the default, switches the address off when it expires and keeps its mail.deleteremoves it and the conversations delivered to it, which needsthreads:write.--group-posting <value>Who may send to a group address:
anyone,membersorworkspace.--group-keep-copyTrue keeps each message sent to a group in the group address's own mailbox too.
--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --no-enablednextmail domains update-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --no-enabled --jsonAlso available in
nextmail domains set-address-photo
Upload the photo shown for an address
Usage
nextmail domains set-address-photo <id> <address-id> <data> [flags]
Sends the image bytes as the request body, replacing any photo the address had: PNG, JPEG, WebP or GIF up to 100 MB, cropped to a 512 pixel square, stored as JPEG or PNG and shown for the address in Nextmail in place of the domain logo. The type is read from --content-type, or from a Blob's own type when that is left out, and without either the server refuses the bytes with 422 invalid_image.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<data>RequiredThe image: a
Blob,ArrayBufferorUint8Array.
Flags
--content-type <value>image/png,image/jpeg,image/webporimage/gif. Required unlessdatais aBlobwith a type.--crop <json|@file|->The part of the image to keep, as
{ x, y, width, height }, each a fraction of the image from 0 to 1, measured from its top left as it shows upright. Leave it out to keep the whole image. JSON shaped asImageCrop, inline or from a file with @path.
Examples
nextmail domains set-address-photo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 ./photo.jpgnextmail domains set-address-photo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 ./photo.jpg --content-type image/jpegAlso available in
nextmail domains remove-address-photo
Remove the photo of an address
Usage
nextmail domains remove-address-photo <id> <address-id> [flags]
Removes the photo of the address and deletes the stored image, so the domain logo is shown for it again.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains remove-address-photo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains remove-address-photo b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --yesAlso available in
nextmail domains start-gravatar-publish
Start publishing the photo of an address to Gravatar
Usage
nextmail domains start-gravatar-publish <id> <address-id> [flags]
Resolves with the url that publishes the photo of the address to Gravatar, so other mail apps and sites show it too. The person the key or app acts for, the workspace owner for an API key, opens it in a browser signed in to Nextmail: Gravatar asks them to sign in to the WordPress.com account that owns the address, and the photo is published when Gravatar sends them back, which takes that signed-in browser session and never this credential.
The link works for 10 minutes. The address needs a photo first, from setAddressPhoto.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains start-gravatar-publish b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains start-gravatar-publish b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
- API
POST /domains/{id}/addresses/{addressId}/photo/gravatar- TypeScript
domains.startGravatarPublish()- Python
domains.start_gravatar_publish()- Ruby
domains.start_gravatar_publish- PHP
domains->startGravatarPublish- Go
Domains.StartGravatarPublish- Java
domains().startGravatarPublish- C#
Domains.StartGravatarPublishAsync
nextmail domains delete-address
Remove an address from a domain
Usage
nextmail domains delete-address <id> <address-id> [flags]
Removes the address. Mail to it is refused from then on, even when the catch-all on the domain is on. Its forwarding stops, its settings are deleted, the people who were given access to it lose that access, and its password sign-in is revoked. Mail it already received stays in the mailbox.
Creating the same address again with createAddress brings it back with the same id, enabled, but without its old settings or access.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains delete-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains delete-address b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --yesAlso available in
nextmail domains list-address-forwards
List where the mail of an address is forwarded
Usage
nextmail domains list-address-forwards <id> <address-id> [flags]
Returns every place the mail of the address is forwarded to, oldest first, as the Forwarding section of the address in the app lists them. Each destination says whether it is switched on (enabled) and where it stands (status): only a live destination, one that confirmed by email that it wants this mail, receives anything.
destination on the list says whether the address also keeps a copy of its mail here (mailbox) or only forwards it (forward), and max is how many destinations one address may have.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains list-address-forwards b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains list-address-forwards b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains add-address-forwards
Forward the mail of an address to more places
Usage
nextmail domains add-address-forwards <id> <address-id> --emails <a,b> [flags] nextmail domains add-address-forwards <id> <address-id> --data <json|@file|-> [flags]
Adds places the mail of the address goes to, as adding a destination in the app does. Each new destination is sent an email asking it to confirm, and receives nothing until it does, so it comes back pending and turns live once its owner confirms.
An address hosted here, one already on the list, one that would make a loop, one past the limit of 10 and one that refused mail from this workspace before are not added. Each is named in skipped with the reason, and the rest are still added.
The address keeps a copy of its mail here as before. To stop keeping one, set destination to forward with updateAddress once a destination is switched on.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--emails <a,b>RepeatableThe addresses to forward to, 1 to 10 of them. Each is trimmed and lowercased. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains add-address-forwards b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --emails [email protected]nextmail domains add-address-forwards b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
nextmail domains update-address-forward
Pause a forwarding destination or switch it back on
Usage
nextmail domains update-address-forward <id> <address-id> <forward-id> --enabled [flags] nextmail domains update-address-forward <id> <address-id> <forward-id> --data <json|@file|-> [flags]
enabled false pauses the destination: nothing is forwarded to it until it is switched on again. It keeps its confirmation, so switching it back on needs no new one, and switching it on clears the failures recorded against it.
When the last destination that is on is paused, the address goes back to keeping its mail here. destination in the result says where the mail of the address goes now.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<forward-id>RequiredA destination id from
listAddressForwardsoraddAddressForwards. It has to be a destination of the address named byaddressId.
Flags
--enabledFalse pauses the destination, true switches it back on. Required, here or in
--data.--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-address-forward b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5b --no-enablednextmail domains update-address-forward b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5b --data @domain.jsonAlso available in
- API
PATCH /domains/{id}/addresses/{addressId}/forwards/{forwardId}- TypeScript
domains.updateAddressForward()- Python
domains.update_address_forward()- Ruby
domains.update_address_forward- PHP
domains->updateAddressForward- Go
Domains.UpdateAddressForward- Java
domains().updateAddressForward- C#
Domains.UpdateAddressForwardAsync
nextmail domains delete-address-forward
Stop forwarding to a destination
Usage
nextmail domains delete-address-forward <id> <address-id> <forward-id> [flags]
Removes the destination, so nothing more is forwarded to it. When it was the last destination that was on, the address goes back to keeping its mail here, and destination in the result says where the mail of the address goes now.
To stop forwarding for a while instead, pause the destination with updateAddressForward, which keeps its confirmation.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<forward-id>RequiredA destination id from
listAddressForwardsoraddAddressForwards. It has to be a destination of the address named byaddressId.
Examples
nextmail domains delete-address-forward b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5bnextmail domains delete-address-forward b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5b --yesAlso available in
- API
DELETE /domains/{id}/addresses/{addressId}/forwards/{forwardId}- TypeScript
domains.deleteAddressForward()- Python
domains.delete_address_forward()- Ruby
domains.delete_address_forward- PHP
domains->deleteAddressForward- Go
Domains.DeleteAddressForward- Java
domains().deleteAddressForward- C#
Domains.DeleteAddressForwardAsync
nextmail domains resend-address-forward-consent
Ask a forwarding destination to confirm again
Usage
nextmail domains resend-address-forward-consent <id> <address-id> <forward-id> [flags]
Sends the confirmation email to the destination once more, for when the first one was lost or ignored. status says what became of the request: sent, already-confirmed when the destination has confirmed and needs nothing, too-soon when the last email went out moments ago, revoked when the destination refused mail from this workspace, and send-failed when the email could not be sent.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<forward-id>RequiredA destination id from
listAddressForwardsoraddAddressForwards. It has to be a destination of the address named byaddressId.
Examples
nextmail domains resend-address-forward-consent b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5bnextmail domains resend-address-forward-consent b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 5e8f1a2b-3c4d-4e5f-8a9b-0c1d2e3f4a5b --jsonAlso available in
- API
POST /domains/{id}/addresses/{addressId}/forwards/{forwardId}/resend- TypeScript
domains.resendAddressForwardConsent()- Python
domains.resend_address_forward_consent()- Ruby
domains.resend_address_forward_consent- PHP
domains->resendAddressForwardConsent- Go
Domains.ResendAddressForwardConsent- Java
domains().resendAddressForwardConsent- C#
Domains.ResendAddressForwardConsentAsync
nextmail domains list-address-members
List who can reach an address
Usage
nextmail domains list-address-members <id> <address-id> [flags]
Returns everybody who can read the mail of the address and how each one reaches it, in via: owner for the owner of the workspace, every-address for a role that reaches every address, whole-domain for a grant of the whole domain named in viaDomain, and direct for a grant of the address itself. Each person appears once.
access is member for somebody who reads and sends from the address and viewer for somebody who only reads it. removable is true for a grant of the address itself that the caller may take back with members.revokeAddress, which for a key or an app also takes members:write and no address or domain limit. The others come from the role or a domain grant, and change there. The member who connected a mailbox at the address keeps their grant while they are in the workspace, so theirs is never removable.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains list-address-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains list-address-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains get-address-login
Read the password sign-in of an address
Usage
nextmail domains get-address-login <id> <address-id> [flags]
Says whether the address has a password of its own, which lets somebody sign in to Nextmail as that address alone and read and send only its mail. login is null when it has none, and otherwise says who set the password and when, and when it was last used to sign in.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains get-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains get-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains set-address-login
Give an address a password, or replace it
Usage
nextmail domains set-address-login <id> <address-id> --password <value> [flags] nextmail domains set-address-login <id> <address-id> --data <json|@file|-> [flags]
Sets the password somebody uses to sign in to Nextmail as this address alone. Whoever holds it reads and sends only the mail of the address and reaches nothing else in the workspace. Nextmail sends the password to nobody, so hand it over yourself.
Calling it again replaces the password, signs out everybody who signed in with the old one and removes the forwarding destinations they added. created says whether the sign-in is new.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--password <value>At least 8 characters, with a lowercase letter, an uppercase letter, a number and a special character. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains set-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --password examplenextmail domains set-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
nextmail domains delete-address-login
Remove the password sign-in of an address
Usage
nextmail domains delete-address-login <id> <address-id> [flags]
Takes the password away and signs out everybody who signed in with it. The address, its mail and the people who reach it otherwise stay as they are, and the forwarding destinations added by whoever signed in as the address are removed with it.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains delete-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains delete-address-login b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --yesAlso available in
nextmail domains get-mail-app-settings
Read the mail app settings of an address
Usage
nextmail domains get-mail-app-settings <id> <address-id> [flags]
Returns what to enter in Apple Mail, Gmail, Outlook, Thunderbird or any other mail app to add the address to it: the IMAP, SMTP and POP3 servers, each with its host, port and security, and the username to sign in with, which is the address itself. Each of those three encrypts the connection from the first byte, so its security is ssl-tls. smtpSubmission is the same SMTP server on port 587 for apps, devices and libraries that only offer STARTTLS: its security is starttls, the connection is upgraded before the sign-in, and it takes the same username and password.
caldav is the server that puts the calendar of the address into Apple Calendar, Thunderbird, DAVx5 on Android or any other CalDAV app, and carddav the one that puts the contacts of the workspace into Apple Contacts or any other CardDAV app. Each has a url to enter, with the same username and password, a principalUrl for apps that ask for the account address on the server, and host, port and security like the others.
protocols says which of these connections the address accepts, as true or false for imap, smtp, pop3, caldav and carddav. updateMailAppSettings changes them.
The password is an app password of the address, such as one createAppPassword makes, or the password setAddressLogin set when the address has a sign-in of its own without two-factor.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains get-mail-app-settings b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains get-mail-app-settings b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains update-mail-app-settings
Turn mail app connections on or off for an address
Usage
nextmail domains update-mail-app-settings <id> <address-id> [flags]
Switches each kind of connection the address accepts on or off: imap, smtp and pop3 for mail, caldav for its calendar and carddav for contacts. Send only the ones to change, and the rest stay as they are. Every kind is on until it is switched off.
A switched-off kind refuses every sign-in to it, whatever the password, with a message that says it is turned off. Mail apps and calendar or contacts apps that are already connected over it are signed out within minutes. App passwords stay as they are, so switching a kind back on lets them in again.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--imapIMAP, which keeps folders and read state in step with Nextmail.
--smtpSMTP, for sending from a mail app, on port 465 and on port 587 alike.
--pop3POP3, for apps that only download the inbox.
--caldavCalDAV, which puts the calendar of the address into calendar apps.
--carddavCardDAV, which puts the contacts of the workspace into contacts apps.
--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-mail-app-settings b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --no-pop3nextmail domains update-mail-app-settings b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --no-pop3 --jsonAlso available in
- API
PATCH /domains/{id}/addresses/{addressId}/mail-apps- TypeScript
domains.updateMailAppSettings()- Python
domains.update_mail_app_settings()- Ruby
domains.update_mail_app_settings- PHP
domains->updateMailAppSettings- Go
Domains.UpdateMailAppSettings- Java
domains().updateMailAppSettings- C#
Domains.UpdateMailAppSettingsAsync
nextmail domains get-address-limits
Read the sending and receiving limits of an address
Usage
nextmail domains get-address-limits <id> <address-id> [flags]
Returns what the address may send and receive, what it has sent and received so far, and when each count goes down.
sending holds hold, the caps perHour, perDay and perMonth on messages, recipientsPerHour, recipientsPerDay and recipientsPerMonth on recipients, recipientsPerMessage, and the lists allowedRecipients and blockedRecipients. receiving holds hold, the caps perHour, perDay and perMonth, the storage quota storageBytes, and allowedSenders. A field is null until somebody sets it, and null means the address has no limit of its own there: the plan of the workspace still applies.
usage counts sent, recipients and received for the current clock hour, the last 24 clock hours and the calendar month, all in UTC, and usage.storage holds the bytes and messages of the mail the address keeps, counted since storage counting began and without mail routed to a webhook. resets says when each of those counts next goes down. updatedAt is when the limits last changed, or null while the address has none. updateAddressLimits changes them.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains get-address-limits b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains get-address-limits b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains update-address-limits
Change the sending and receiving limits of an address
Usage
nextmail domains update-address-limits <id> <address-id> [flags]
Sets, changes or clears the limits of the address. Send only the fields to change, inside sending and receiving: a field left out stays as it is, and null clears it. Caps take whole numbers from 1 to 10,000,000, receiving.storageBytes takes a storage quota from 1 MiB to 1 TiB, and each list takes up to 100 entries, each an exact address ([email protected]), a domain (client.com) or every subdomain of one (*.client.com).
The limits hold on every way mail leaves the address, the API, the SMTP relay, the app, the assistant, forms, broadcasts, automations and bookings alike, and on every way mail arrives. A send over a cap is refused with 429 address_limit_reached, whose param names the cap and whose retryAfterSeconds says when it lifts. A paused address refuses new sends with 429 address_sending_paused and holds queued or scheduled mail until it is resumed, and a disabled one refuses them with 403 address_sending_disabled and fails queued or scheduled mail. Mail that arrives over a receiving cap, or while receiving is paused, is turned away with a temporary bounce, and mail while receiving is disabled, from a sender allowedSenders leaves out, or that would take the address past its storage quota, with a permanent one. Deleting mail for good makes room under the quota again.
Messages count when they are accepted, so a scheduled message counts the moment it is scheduled, and recipients counts every address in to, cc and bcc. A plus tag counts toward the address it belongs to.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--sending-hold <value>pausedholds sending anddisabledstops it. Null sends as usual.--sending-per-hour <n>Messages it may send in the current clock hour, in UTC.
--sending-per-day <n>Messages it may send in the last 24 clock hours.
--sending-per-month <n>Messages it may send in the calendar month, in UTC.
--sending-recipients-per-hour <n>Recipients it may send to in the current clock hour.
--sending-recipients-per-day <n>Recipients it may send to in the last 24 clock hours.
--sending-recipients-per-month <n>Recipients it may send to in the calendar month.
--sending-recipients-per-message <n>Recipients one message may have, a 403
too_many_recipientspast it.--sending-allowed-recipients <a,b>RepeatableThe only recipients it may send to. Null is anyone, and an empty list nobody.
--sending-blocked-recipients <a,b>RepeatableRecipients it may never send to.
--receiving-hold <value>pausedturns mail away with a temporary bounce anddisabledwith a permanent one. Null receives as usual.--receiving-per-hour <n>Messages it accepts in the current clock hour, in UTC.
--receiving-per-day <n>Messages it accepts in the last 24 clock hours.
--receiving-per-month <n>Messages it accepts in the calendar month, in UTC.
--receiving-storage-bytes <n>The most mail it may keep, in bytes, from 1 MiB (1048576) to 1 TiB (1099511627776). A message that would take it past the quota gets a permanent bounce (5.2.2). Null removes the quota.
--receiving-allowed-senders <a,b>RepeatableThe only senders it accepts mail from, matched against the From header and the envelope sender. Null is anyone, and an empty list nobody.
--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-address-limits b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --sending-per-day 500 --sending-blocked-recipients competitor.com --receiving-per-day 500nextmail domains update-address-limits b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --sending-per-day 500 --sending-blocked-recipients competitor.com --receiving-per-day 500 --jsonAlso available in
nextmail domains list-app-passwords
List the app passwords of an address
Usage
nextmail domains list-app-passwords <id> <address-id> [flags]
Returns every app password a mail app can sign in to the address with, newest first. Each one has the name it was given, last4, the last four letters of the password, to tell them apart, owner, the person it signs in as, and origin, which says where it was made: settings in the app, api through createAppPassword, and setup-link by opening an emailed setup link, such as one sendMailAppSetup sends.
lastUsedAt and lastUsedProtocol say when an app last signed in with it and over which of imap, smtp, pop3, caldav and carddav, and lastUsedClient names the mail app when it named itself. The passwords themselves are shown only when they are made, and revoked ones are left out.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Examples
nextmail domains list-app-passwords b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains list-app-passwords b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --jsonAlso available in
nextmail domains create-app-password
Create an app password for an address
Usage
nextmail domains create-app-password <id> <address-id> --name <value> [flags] nextmail domains create-app-password <id> <address-id> --data <json|@file|-> [flags]
Makes a password a mail app signs in to the address with, using the address as the username, and returns it in password with the server settings in servers. That is the only time the password is shown, so hand it over or store it then.
The password signs in as the caller for this address alone: an API key makes it for the workspace owner, and an access token for the person who connected the app. A mail app using it reaches the mail of the address with what that person may do there, and nothing else in the workspace. It is 16 letters in four groups joined by dashes, and the dashes, or spaces in their place, can be left out when it is typed.
Besides members:write, the key or access token has to hold itself every mail, calendar and contacts scope the password carries (threads:read, threads:write, emails:send, drafts:write, labels:write, calendar:read, calendar:write, contacts:read and contacts:write; for an access token, those of them its person's role holds). Without one of them the call is refused with 403 insufficient_authority.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--name <value>What to call the password, such as the device it is for, 1 to 64 characters. It is trimmed. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains create-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --name 'Front desk iPad'nextmail domains create-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
nextmail domains update-app-password
Rename an app password
Usage
nextmail domains update-app-password <id> <address-id> <password-id> --name <value> [flags] nextmail domains update-app-password <id> <address-id> <password-id> --data <json|@file|-> [flags]
Changes the name shown for the app password, such as when the device it is for changes hands. The password itself stays the same, and a mail app signed in with it stays signed in.
A person renames the app passwords they hold. The workspace owner, and someone whose role manages members, rename anyone's.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<password-id>RequiredAn app password id from
listAppPasswordsorcreateAppPassword. It has to be an app password of the address named byaddressId.
Flags
--name <value>The new name, 1 to 64 characters. It is trimmed. Required, here or in
--data.--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 map_3f9a1c7e5b2d4f6a8c0e1b3d --name 'Reception iPad'nextmail domains update-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 map_3f9a1c7e5b2d4f6a8c0e1b3d --data @domain.jsonAlso available in
nextmail domains delete-app-password
Revoke an app password
Usage
nextmail domains delete-app-password <id> <address-id> <password-id> [flags]
Revokes the app password, so no mail app can sign in with it again, and a mail app that is signed in with it is signed out within minutes. The address, its mail and its other app passwords stay as they are.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<password-id>RequiredAn app password id from
listAppPasswordsorcreateAppPassword. It has to be an app password of the address named byaddressId.
Examples
nextmail domains delete-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 map_3f9a1c7e5b2d4f6a8c0e1b3dnextmail domains delete-app-password b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 map_3f9a1c7e5b2d4f6a8c0e1b3d --yesAlso available in
nextmail domains send-mail-app-setup
Email a mail app setup link for an address
Usage
nextmail domains send-mail-app-setup <id> <address-id> --recipient <value> [flags] nextmail domains send-mail-app-setup <id> <address-id> --data <json|@file|-> [flags]
Emails the recipient a link that sets the address up in a mail app. Opening it makes an app password named after the recipient, shows it once with the server settings, and offers a profile that sets up an Apple device in one step. The link works once and expires in three days, at expiresAt.
The app password it makes signs in as the caller, as one from createAppPassword does: an API key makes it for the workspace owner, and an access token for the person who connected the app. It then appears in listAppPasswords with origin set to setup-link.
Besides members:write, the key or access token has to hold itself every mail, calendar and contacts scope the password carries (threads:read, threads:write, emails:send, drafts:write, labels:write, calendar:read, calendar:write, contacts:read and contacts:write; for an access token, those of them its person's role holds). Without one of them the call is refused with 403 insufficient_authority.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--recipient <value>The email address to send the link to, such as the person who will use the mail app. It is trimmed and lowercased. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains send-mail-app-setup b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --recipient [email protected]nextmail domains send-mail-app-setup b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
nextmail domains create-mail-app-profile-link
Make a link that sets an address up on an Apple device
Usage
nextmail domains create-mail-app-profile-link <id> <address-id> --name <value> --display-name <value> --description <value> [flags] nextmail domains create-mail-app-profile-link <id> <address-id> --data <json|@file|-> [flags]
Makes a one-time link that sets the address up on an iPhone, iPad or Mac. Opened there, url downloads an Apple configuration profile with a new app password inside, named --name, which signs in as the caller for this address alone: an API key makes it for the workspace owner, and an access token for the person who connected the app. --display-name and --description are what the device shows for the profile.
The password is made when the link is opened, not before, so nothing appears in listAppPasswords until then. The link works once and stops working at expiresAt, five minutes later, so open it on the device straight away and keep it secret until then: it holds what makes the password.
Besides members:write, the key or access token has to hold itself every mail, calendar and contacts scope the password carries (threads:read, threads:write, emails:send, drafts:write, labels:write, calendar:read, calendar:write, contacts:read and contacts:write; for an access token, those of them its person's role holds). Without one of them the call is refused with 403 insufficient_authority.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--name <value>What to call the app password the link makes, such as the device it is for, 1 to 64 characters. It is trimmed. Required, here or in
--data.--display-name <value>The name the device shows for the profile, 1 to 160 characters. It is trimmed. Required, here or in
--data.--description <value>The description the device shows for the profile, 1 to 160 characters. It is trimmed. Required, here or in
--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains create-mail-app-profile-link b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --name 'Front desk iPad' --display-name 'Support mailbox' --description 'Mail, calendar and contacts for [email protected]'nextmail domains create-mail-app-profile-link b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
- API
POST /domains/{id}/addresses/{addressId}/mail-app-profile-link- TypeScript
domains.createMailAppProfileLink()- Python
domains.create_mail_app_profile_link()- Ruby
domains.create_mail_app_profile_link- PHP
domains->createMailAppProfileLink- Go
Domains.CreateMailAppProfileLink- Java
domains().createMailAppProfileLink- C#
Domains.CreateMailAppProfileLinkAsync
nextmail domains get-dns
Read how the DNS of a domain is set up
Usage
nextmail domains get-dns <id> [flags]
Returns whether Nextmail writes the records of the domain itself (managing), through which connection and zone, where each kind of record stands in steps, and the records left behind to delete by hand.
zone says which connected zone answers for the domain: one is resolved, several are ambiguous and need setDnsZone, none holds it, with the reason, or the connections could not be asked (unusable). The answer is kept for a few minutes, and refresh asks the providers again.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--refreshTrue asks the providers again which zone answers for the domain.
Examples
nextmail domains get-dns b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains get-dns b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --refreshnextmail domains get-dns b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --jsonAlso available in
- API
GET /domains/{id}/dns- TypeScript
domains.getDns()- Python
domains.get_dns()- Ruby
domains.get_dns- PHP
domains->getDns- Go
Domains.GetDNS- Java
domains().getDns- C#
Domains.GetDnsAsync
nextmail domains set-dns-zone
Choose the zone a domain is set up through
Usage
nextmail domains set-dns-zone <id> --connection-id <value> --zone-id <value> [flags] nextmail domains set-dns-zone <id> --data <json|@file|-> [flags]
Attaches the domain to a zone of a connection, when several connected zones could answer for it. The zone has to cover the domain, be active at the provider and take a test record. Nothing is written yet: call syncDns to write the records.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--connection-id <value>The connection that holds the zone, from
dnsConnections.list. Required, here or in--data.--zone-id <value>The zone, as
zone.candidatesofgetDnslists it. Required, here or in--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains set-dns-zone b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --connection-id example --zone-id examplenextmail domains set-dns-zone b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains sync-dns
Write the DNS records of a domain
Usage
nextmail domains sync-dns <id> [flags]
Writes or repairs every record the domain needs through the connected zone that answers for it, as Sync does in the app. When exactly one zone answers it is attached first, and attached says so. With purpose, only that kind of record is written. A domain that was waiting for its records is verified once they are in place.
When no single zone answers, nothing is written: outcome is refused, message says why and zone shows the zones to choose from with setDnsZone.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--purpose <value>Only this kind of record:
dmarc,tracking,storage,bimiorapp-host.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains sync-dns b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains sync-dns b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --jsonAlso available in
nextmail domains list-routes
List one page of the pattern routes of a domain
Usage
nextmail domains list-routes <id> [flags]
Returns one page of the routes of the domain in the order they are tried: lowest priority first, then the longest literal text, then the oldest. A route catches mail to addresses nobody created whose local part matches its pattern, after the addresses that exist and before the catch-all, and active says whether it takes mail now, with the reason in inactiveReason when it does not.
Add --all to walk every page: a table on a terminal, one JSON object per line when piped or with --ndjson, and one { items, hasMore, nextCursor } document with --json. --max <n> stops after that many items.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--limit <n>Page size, from 1 to 100. The server defaults to 25.
Default25--cursor <value>The
nextCursorof the previous page. Leave it out for the first page.--allFetch every page and stream the items as they arrive.
--max <n>Stop after this many items. Implies
--all.--ndjsonPrint every item as one JSON object per line. Implies
--all
Examples
nextmail domains list-routes b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6fnextmail domains list-routes b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --all --max 100nextmail domains list-routes b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --all > domains.ndjsonAlso available in
nextmail domains create-route
Add a pattern route to a domain
Usage
nextmail domains create-route <id> --pattern <value> --action <value> [flags] nextmail domains create-route <id> --data <json|@file|-> [flags]
Adds a route that catches mail to addresses nobody created whose local part matches pattern, such as support-*, and acts on it. deliver files it at --target-address-id, whose own destination then applies. forward sends it on to --forward-to once that address confirms, so the route reads forwardStatus: 'pending' until it does. webhook posts it to --webhook-id as the email.routed event. rewrite reads it as the same local part on --rewrite-domain-id, once.
Send the field of the action and leave the other three out. A domain holds at most 100 routes, and a domain that is an alias takes the routes of its primary domain instead.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--pattern <value>The local part to catch, 1 to 64 of the letters a to z, digits,
.,_,-,+and*, with at most three*wildcards. Lowercased, and unique on the domain. Required, here or in--data.--action <value>deliver,forward,webhookorrewrite. Required, here or in--data.--target-address-id <value>For
deliver: an address id of this workspace, on any of its domains.--forward-to <value>For
forward: an address at another provider, which is asked by email to confirm before it receives anything.--webhook-id <value>For
webhook: a webhook endpoint id of this workspace.--rewrite-domain-id <value>For
rewrite: the id of another domain hosted in this workspace.--priority <n>0 to 1000, lowest tried first. Defaults to 100.
--enabledFalse keeps the route without catching mail. Defaults to true.
--description <value>A note for people, up to 200 characters.
--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains create-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --pattern 'support-*' --action delivernextmail domains create-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --pattern 'support-*' --action deliver --target-address-id 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains create-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains get-route
Read one pattern route of a domain
Usage
nextmail domains get-route <id> <route-id> [flags]
Returns the route with what it catches, what it does, and whether it takes mail now in active, with the reason in inactiveReason when it does not. A webhook route whose endpoint was deleted reads webhook_deleted, and a forward route waiting for its destination to confirm reads forward_pending.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<route-id>RequiredRoute id from
listRoutesorcreateRoute, startingrte_. It has to be a route of the domain named byid.
Examples
nextmail domains get-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9nextmail domains get-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9 --jsonAlso available in
nextmail domains update-route
Change a pattern route
Usage
nextmail domains update-route <id> <route-id> [flags]
Changes the route. Send only the fields to change. Changing action needs the field of the new action unless the route already holds it, and the fields of the old action are cleared. Sending --forward-to again asks that address to confirm once more when it has not. enabled: false keeps the route but stops it catching mail.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<route-id>RequiredRoute id from
listRoutesorcreateRoute, startingrte_. It has to be a route of the domain named byid.
Flags
--pattern <value>The local part to catch, 1 to 64 of the letters a to z, digits,
.,_,-,+and*, with at most three*wildcards. Lowercased, and unique on the domain.--action <value>deliver,forward,webhookorrewrite.--target-address-id <value>For
deliver: an address id of this workspace, on any of its domains.--forward-to <value>For
forward: an address at another provider, which is asked by email to confirm before it receives anything.--webhook-id <value>For
webhook: a webhook endpoint id of this workspace.--rewrite-domain-id <value>For
rewrite: the id of another domain hosted in this workspace.--priority <n>0 to 1000, lowest tried first. Defaults to 100.
--enabledFalse keeps the route without catching mail. Defaults to true.
--description <value>A note for people, up to 200 characters.
--data <json|@file|->The whole
patchas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains update-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9 --priority 10nextmail domains update-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9 --priority 10 --jsonAlso available in
nextmail domains delete-route
Delete a pattern route
Usage
nextmail domains delete-route <id> <route-id> [flags]
Deletes the route. Mail it caught then goes to the next route that matches, or to the catch-all.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<route-id>RequiredRoute id from
listRoutesorcreateRoute, startingrte_. It has to be a route of the domain named byid.
Examples
nextmail domains delete-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9nextmail domains delete-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f rte_8f2c1d9a4b7e6f30a5c2d1e9 --yesAlso available in
nextmail domains test-route
Test where mail to an address goes
Usage
nextmail domains test-route <id> --address <value> [flags] nextmail domains test-route <id> --data <json|@file|-> [flags]
Answers which step decides mail to an address, without sending anything. step is address when an address that exists takes it, alias when the domain is an alias and its primary decides, route when a pattern route catches it, catch_all when the catch-all takes it and none when it would be turned away. route is the route that decided, target where the mail would end up, a mailbox, a forward, a webhook or a group with the address it is filed at, and reason why mail would be turned away.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.
Flags
--address <value>A local part such as
support-eu, read on this domain, or a whole address on this domain or one of its aliases. Required, here or in--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains test-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --address support-eunextmail domains test-route b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f --data @domain.jsonAlso available in
nextmail domains list-group-members
List one page of the group members of a group address
Usage
nextmail domains list-group-members <id> <address-id> [flags]
Returns one page of the group members of the address, oldest first: the addresses of the workspace and the addresses at other providers its mail goes to while its destination is group. These are not the people who can read the address, which listAddressMembers lists. An outside member reads pending until it confirms, live once it has and refused when it said no, and a member of the workspace reads live, or paused while it is switched off.
Add --all to walk every page: a table on a terminal, one JSON object per line when piped or with --ndjson, and one { items, hasMore, nextCursor } document with --json. --max <n> stops after that many items.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--limit <n>Page size, from 1 to 100. The server defaults to 25.
Default25--cursor <value>The
nextCursorof the previous page. Leave it out for the first page.--allFetch every page and stream the items as they arrive.
--max <n>Stop after this many items. Implies
--all.--ndjsonPrint every item as one JSON object per line. Implies
--all
Examples
nextmail domains list-group-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70nextmail domains list-group-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --all --max 100nextmail domains list-group-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --all > domains.ndjsonAlso available in
nextmail domains add-group-members
Add group members to a group address
Usage
nextmail domains add-group-members <id> <address-id> --members <json|@file|-> [flags] nextmail domains add-group-members <id> <address-id> --data <json|@file|-> [flags]
Adds up to 100 group members to the address, each { addressId } for an address of the workspace or { email } for an address at another provider. An email hosted in this workspace is added as that address. An outside address is sent an email asking it to confirm and receives nothing until it does, and sending one that has not confirmed yet asks it again.
The address has to be a group address already, so set its destination to group with updateAddress first. A group holds at most 1,000 group members, and groups nest at most 3 deep. A member already in the group, and an outside address that refused mail from this workspace or whose email could not be sent, comes back in skipped with the reason.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.
Flags
--members <json|@file|->1 to 100 entries, each
{ addressId }for an address of this workspace or{ email }for an address at another provider. JSON shaped asArray<GroupMemberInput>, inline or from a file with @path. Required, here or in--data.--data <json|@file|->The whole
bodyas JSON, inline, from a file with @path, or - for standard input. Flags override its keys.
Examples
nextmail domains add-group-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --members @members.jsonnextmail domains add-group-members b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 --data @domain.jsonAlso available in
nextmail domains remove-group-member
Remove a group member from a group address
Usage
nextmail domains remove-group-member <id> <address-id> <member-id> [flags]
Removes one group member, so the mail of the group stops going there. An outside address keeps its confirmation, so adding it back needs no new one.
Arguments
<id>RequiredDomain id from
listorcreate, a UUID.<address-id>RequiredAddress id from
listAddressesorcreateAddress, a UUID. It has to be an address on the domain named byid.<member-id>RequiredGroup member id from
listGroupMembersoraddGroupMembers, startinggrm_. It has to be a group member of the address named byaddressId.
Examples
nextmail domains remove-group-member b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 grm_3a7d9c1e5b2f8a4d6c0e1b9fnextmail domains remove-group-member b3e1f0a4-6c2d-4e8a-9f17-2d5c8a0b4e6f 7c9d2e41-0b8f-4a63-9e25-1f4d6a8b3c70 grm_3a7d9c1e5b2f8a4d6c0e1b9f --yes