Raise an error if the API key is not set