# urbestack-botmail-key-set

First published 18 Oct 2026 (release 0.2.10) · Unchanged since publication

UrbeStack release 0.2.35 command, run as root in the server shell.

## Usage

```
urbestack-botmail-key-set --id N [--name NAME] [--platform WORD] [--from-name NAME|''] [--may ...] [--send-mode self|drafts|known] [--folders-out ...] [--recipients ...] [--blocked ...] [--sends-per-hour N] [--sends-per-day N] [--recipients-per-message N] [--calls-per-minute N] [--copy-to ADDRESS|''] [--from-addresses ...] [--expires-days N|0] [--paused yes|no] [--owner USER]
```

## Description

Changes selected rules for a bot key, pauses it, or resumes it. Give the key ID with --id and supply at least one change option.

Use --may to set which operations the key can perform. --recipients sets the allowed recipients, and --blocked sets the blocked recipients. Use --from-addresses to set which IP addresses or CIDR networks the bot can call from. Supply up to 32 comma-separated entries.

--sends-per-hour accepts 1 to 1000, and --recipients-per-message accepts 1 to 50. --sends-per-day and --calls-per-minute each accept values from 1 up to the server's limit. The key name can be up to 64 characters.

Pass an empty --from-name to send with just the sender's email address, or an empty --copy-to to stop sending copies. --expires-days sets how many days the key is valid for. Use --expires-days 0 to remove its expiration.

Use --paused yes to pause the key and --paused no to resume it. With --owner, the key's mailbox must be on a domain owned by that user. Omit --owner to act as an administrator. Only an administrator can resume a key paused by an administrator.

## Same in the API

- [PATCH /botmail/keys/{id}](https://urbestack.com/docs/api/patch-botmail-keys-id.md): Update a bot key's rules or pause or resume the key

## Command family: botmail

- [urbestack-botmail-domain-list](https://urbestack.com/docs/commands/urbestack-botmail-domain-list.md): Lists domains whose mail is hosted on this server.
- [urbestack-botmail-domain-off](https://urbestack.com/docs/commands/urbestack-botmail-domain-off.md): Turns off BotMail for a domain and immediately revokes every BotMail key for its mailboxes.
- [urbestack-botmail-domain-on](https://urbestack.com/docs/commands/urbestack-botmail-domain-on.md): Turns on BotMail for a domain whose mail is hosted on this server or changes its BotMail hostname.
- [urbestack-botmail-events](https://urbestack.com/docs/commands/urbestack-botmail-events.md): Runs one round of BotMail webhook delivery, the same work the timer runs every minute.
- [urbestack-botmail-key-add](https://urbestack.com/docs/commands/urbestack-botmail-key-add.md): Creates a named BotMail key for the mailbox specified by --address.
- [urbestack-botmail-key-address](https://urbestack.com/docs/commands/urbestack-botmail-key-address.md): Issues a new MCP URL for an existing bot key by rotating its secret.
- [urbestack-botmail-key-del](https://urbestack.com/docs/commands/urbestack-botmail-key-del.md): Revokes a bot key immediately and removes its webhook.
- [urbestack-botmail-key-list](https://urbestack.com/docs/commands/urbestack-botmail-key-list.md): Lists all bot keys on the server by default.
- [urbestack-botmail-prune](https://urbestack.com/docs/commands/urbestack-botmail-prune.md): Deletes BotMail key activity, counters from expired rate-limit windows, and webhook events that have reached a final status when they are older than the retention period set by mail.botmail_activity_days.
- [urbestack-botmail-webhook-del](https://urbestack.com/docs/commands/urbestack-botmail-webhook-del.md): Removes a bot key's webhook and its stored bearer token, ending new-mail notifications for that key.
- [urbestack-botmail-webhook-resume](https://urbestack.com/docs/commands/urbestack-botmail-webhook-resume.md): Resumes a bot key's webhook after BotMail paused it following seven failed delivery attempts.
- [urbestack-botmail-webhook-set](https://urbestack.com/docs/commands/urbestack-botmail-webhook-set.md): Creates or updates the webhook for the bot key identified by --key.
- [urbestack-botmail-webhook-test](https://urbestack.com/docs/commands/urbestack-botmail-webhook-test.md): Sends an immediate test ping through BotMail to the webhook for the bot key identified by --key.
