Werk #20196: REST API: configure the global time picker per user
| Component | REST API | ||
| Title | REST API: configure the global time picker per user | ||
| Date | Jul 29, 2026 | ||
| Level | Trivial Change | ||
| Class | New Feature | ||
| Compatibility | Compatible - no manual interaction needed | ||
| Checkmk versions & editions |
|
You can now set a user's global time picker preferences through the
user_config endpoints. These are the same three settings a user finds under
Edit profile > User interface settings, so you can roll out sensible
defaults when creating users instead of asking everybody to adjust their own
profile.
The settings belong to a user's interface options, grouped in a new
time_picker object:
start_of_weeksets the first day of the week in the picker's calendar:browser_locale(the default, taken from the browser's language settings),saturday,sundayormonday.default_time_rangesets the time range the picker starts with. Use{"option": "default"}for the first entry of the global setting Custom graph time ranges, or{"option": "individual", "duration": 14400}to preselect one of the configured ranges, given in seconds.default_refresh_timesets the interval preselected in the picker's refresh control, either{"option": "default"}or{"option": "individual", "interval": 60}with 30, 60 or 90 seconds. This only preselects the interval, it does not start refreshing on its own.
For example, creating a user whose calendar weeks start on Monday and whose graphs open on the last four hours:
POST /domain-types/user_config/collections/all
{
"username": "harry",
"fullname": "Harry Hirsch",
"interface_options": {
"time_picker": {
"start_of_week": "monday",
"default_time_range": {"option": "individual", "duration": 14400}
}
}
}
Leave the object out and nothing changes for that user: the calendar follows the browser locale and the picker opens on the first configured graph time range.
If somebody later removes a time range from Custom graph time ranges, users who preferred it keep working. The API still accepts the value, and the picker falls back to the first configured range.