You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After successful login via Sharepy I try to fetch two URL's from the SharePoint where the home leads to 403 and the api leads to 200? What is going on here? It seems I am successfully authenticated but still cannot access stuff?
s = sharepy.connect('https://company.sharepoint.com','[email protected]','somepassword')
# Returns no errors or warnings
s.get("https://company.sharepoint.com/")
# results in 403
s.get("https://company.sharepoint.com/_api/")
# results in 200
Furthermore, s.auth.cookie and s.auth.digest have content, i.e., not none.
If I add headers s.get("https://company.sharepoint.com/",headers={'Authorization': f'Bearer {s.auth.digest}'}) it results in 401.
The text was updated successfully, but these errors were encountered:
@JonathanHolvey that is indeed true, and I should have been more complete. In the browser with the credentials used I have no problems to access https://company.sharepoint.com/, but when trying to access it programmatically it results in problems and it is difficult to find out where the problem is. For one I am not sure if sharepy even connects correctly since I do not receive any feedback. Any ideas?
After successful login via Sharepy I try to fetch two URL's from the SharePoint where the home leads to 403 and the api leads to 200? What is going on here? It seems I am successfully authenticated but still cannot access stuff?
Furthermore,
s.auth.cookie
ands.auth.digest
have content, i.e., not none.If I add headers
s.get("https://company.sharepoint.com/",headers={'Authorization': f'Bearer {s.auth.digest}'})
it results in 401.The text was updated successfully, but these errors were encountered: