title: Which python library can perform a complex `wget` operation?
body: <p>I'm connecting to Zabbix, but since it doesn't provide an API for one of the resources I want, I had to use <code>wget</code> to get the job done.</p>
  
  <p>Which python library would allow me to perform a "complex" <code>wget</code> operation?</p>
  
  <p>By "complex," I mean:</p>
  
  <pre><code> # Logging in to Zabbix
   wget -4 --no-check-certificate --save-cookies=z.coo -4 --keep-session-cookies -O - -S --post-data='name=username&amp;password=somepassword&amp;enter=Sign in&amp;autologin=1&amp;request=' 'https://some.zabbix-site.com:50100/index.php?login=1'
  
   # Grabbing the network image
   wget -4 --no-check-certificate --load-cookies=z.coo -O result.png 'https://some.zabbix-site.com:50100/map.php?sysmapid=5&amp;severity_min=0'
  </code></pre>
  
  <p>Not sure if <a href="http://docs.python-requests.org/en/master/" rel="nofollow noreferrer">requests</a> would get the job done? I need to 1) login and save the returned cookies, 2) use the returned cookie to authenticate and retrieve the image.</p>