Advertisement
Guest User

Untitled

a guest
Aug 25th, 2016
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. import requests
  2. from requests.auth import HTTPBasicAuth
  3. USERNAME = "username"
  4. PASSWORD = "password"
  5. response = requests.get("https://server.sharepoint.com/dept/cs/docs/AllItems.aspx/", auth=HTTPBasicAuth(USERNAME, PASSWORD))
  6.  
  7. print (response.status_code)
  8. ...
  9. 403
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement