Skip to content

Instantly share code, notes, and snippets.

@davidread
Created August 7, 2015 09:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidread/bf10082d19ecc43618e9 to your computer and use it in GitHub Desktop.
Save davidread/bf10082d19ecc43618e9 to your computer and use it in GitHub Desktop.
>>> requests.get('http://uk-air.defra.gov.uk/datastore/pcb/2010_TOMPs_PCB_Data.xlsx', headers={'User-agent': 'python-requests'})
<Response [403]>
>>> requests.get('http://uk-air.defra.gov.uk/datastore/pcb/2010_TOMPs_PCB_Data.xlsx', headers={'User-agent': 'python-request'})
<Response [200]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment