use by default Autodetect API + cleanup

When the user press the JSIT button, no API key is set and the user is
logged on JSIT (and an API key is generated), a message will ask the
user if he wants to use the key autodetected. + removed some useless
portions of code related to the former button option.