I want to update the provisioning mechanism for my host and want to use the self-service API. Unfortunately I got an error:
[Error]: Failed to fetch host/template configuration from Icinga Director Self-Service API because of unhandled exception: 401
[Error]: Failed to connect to your Icinga Director at "https://monitor.icinga.intern/icingaweb2/director/". Please try again
Please re-enter your SelfService API Key for the Host-Template in case the key is no longer assigned to your host
Ok, re-creation could also be a problem as the scripts save the key (including an individual one for the host if it successfully created an object in the Director). But I can not remember the path and have no access to a windows system right now.
As the Director is part of Icinga Web 2 you could increase the loglevel for Icinga Web 2, but I am not sure if there will be more information about the 401 helping you find why it is unauthorized.
Any news here?
I have a similar problem caused by using single sign on for icinga which now produces the 401 error when trying to register hosts with the director serf-service-api.