title: Python 3 script to upload a file to a REST URL (multipart request)
body: <p>I am fairly new to Python and using Python 3.2. I am trying to write a python script that will pick a file from user machine (such as an image file) and submit it to a server using REST based invocation. The Python script should invoke a REST URL and submit the file when the script is called.</p>
  
  <p>This is similar to multipart POST that is done by browser when uploading a file; but here I want to do it through Python script.</p>
  
  <p>If possible do not want to add any external libraries to Python and would like to keep it fairly simple python script using the core Python install.</p>
  
  <p>Can some one guide me? or share some script example that achieve what I want?</p>