API operation · cron group
PATCH
/users/{name}/cron
First published 3 Oct 2026
0.1.0Unchanged since publicationSet the email address for a customer's cron output
Who may call it
AdministratorResellerCustomer
Token scope, any of
filesallAnswers200 OK
UrbeStack replaces the first MAILTO line or adds one at the top if the crontab has none. Send an empty string or null as mailto to restore the default of sending no cron output by email. A job that runs every minute can fill a mailbox and use up the hourly sending limit.
Setting an email address requires the mail stack to be installed and enabled. The API returns 409 if the crontab is set aside. It returns 400 if mailto is missing or invalid, or if name identifies an administrator.
Customers can change their own settings, resellers can change their customers' settings, and administrators can change any customer's settings. The token must have the files scope.
As a command
Run as root on the serverParameters
namepath ·UsernameRequiredRequest body
JSON· 1 fieldmailtostring, up to 254 charactersRequiredOne email address of up to 254 characters, or an empty string to disable email delivery. The default is an empty string.
Example
See the API overview for how to set $API and $TOKEN.Request
curl -sS -X PATCH "$API/users/alice/cron" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"mailto": "text"
}'Response ·
200 OK{
"cron": {
"mailto": "text",
"user": "alice"
}
}Errors
11 errors, each a status and a sentence400--mailto is required400--user is required400<name> is an administrator: administrators have no system account, so no cron jobs400<what> must be text400Invalid email address400Invalid username: 2 to 32 lowercase letters, digits or underscores, starting with a letter400Nothing to change: mailto is the one field400This server has no mail stack: there is nowhere to send the output, so no address is taken400Username '<value>' is reserved401Authentication required404User '<user>' not foundNo error of this operation matches.
Generated from release 0.2.35 (current) · the API’s own descriptionThis entry has been unchanged since it was first published in release 0.1.0 on 3 Oct 2026.
urbestack.com/docs/api/patch-users-name-cron/