0
votes

I have a need of connecting (http) to sharepoint from python.

Before going deep, I tried accessing via POSTMAN and followed steps in https://www.c-sharpcorner.com/article/access-sharepoint-online-rest-api-via-postman-with-user-context/

I was able to get security token and rtFa, FedAuth cookies.

However as next step when I try to get request digest by doing a POST request on /_api/contextinfo, I receive a 403 FORBIDDEN response.

I tried just doing some GET requests /_api/title and also at sites level /sites//_api/title. Again same 403 FORBIDDEN response.

I have taken care to run these in POSTMAN with very less time gap just in case tokens/cookies get expired.

Please kindly advise if I am missing any step ? (I did read about newappreg and granting access but I am unsure if its required for user Auth)

Thanks,

1

1 Answers

1
votes

Make sure you use correct value of the cookies, red part in first screenshot not need:

enter image description here enter image description here