Can't register host via Self-Service API

Hello community,

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

Does anyone have a guess as what it could be?


Did you create an API key on a Host template in the Director (on the agent tab)? If yes, is it still valid?

Hello Dirk,

yes it is created and i have also recreated it several times.

Kind regards

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.

Hmm, do you know if there is a director logfile that can help me?

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.