s = JSON.parse(localDetails);
            updateAllCommands();
            highlightElement(document.getElementById('apiKeyValue'));
          }
          // addLog(`Provider set to ${provider}`);
      });

      saveApiDetailsBtn.addEventListener('click', () => {
          const fields = getProviderFields(provider);
          providerDetails = {};
          fields.forEach(field => {
              const input = document.getElementById(field.id);
              providerDetails[field.id] = input.value;
      