Werk #4023: WATO Web-API: Now able to add/edit/delete htpasswd users

TitelWATO Web-API: Now able to add/edit/delete htpasswd users
Datum2017-02-07 15:28:56
Checkmk EditionCheckmk Raw Edition (CRE)
Checkmk Version1.4.0b1
LevelProminent Change
KlasseNew Feature
KompatibilitätKompatibel - benötigt kein manuelles Eingreifen

New functions for the WATO Web-API have been introduced. You can now manage htpasswd users with automation calls.

The following (not very fleshed out) examples provide a quick overview. A more elaborate version will be written later on in our official manual.

Common url prefix:


To get a list of all supported attributes, you'll need to have a look in the actual config files ~/etc/check_mk/conf.d/wato/contacts.mk ~/etc/check_mk/multisite.d/wato/users.mk

Add users: curl {common_prefix}&action=add_users -d 'request={"users": {"klaus": {"alias": "mr. klaus", "password": "1234", "contactgroups": ["all"]}}}'

Edit users: curl {common_prefix}&action=edit_users -d 'request={"users": {"klaus": {"set_attributes": {"alias": "mr. santa"}, "unset_attributes": ["contactgroups"]}}}'

Delete users: curl {common_prefix}&action=delete_users -d 'request={"users": ["klaus", "guest12", "guest2332"]}'