code: def check_uri_security(uri):
      
      if urlparse(uri).scheme != 'https':
          warning_message = (
              'WARNING: this client is sending a request to an insecure'
              ' API endpoint. Any API request you make may expose your API key and'
              ' secret to third parties. Consider using the default endpoint:\n\n'
              '  %s\n') % uri
          warnings.warn(warning_message, UserWarning)
      return uri
docs: Warns if the URL is insecure.