Forum Discussion
sharepoint api link
hcl_nitin https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/get-to-know-the-sharepoint-rest-service?tabs=csom
I am not getting result when posting the request like http://<site url>/_api/web/lists in postman
whre site url = https://hclo365.sharepoint.com/Sites/
the full url is https://hclo365.sharepoint.com/Sites/_api/web/lists/getByTitle('SPlist').
Am I missing anything.
- Apr 28, 2020
hcl_nitin your url is not correct, /Sites/ its causing the problem. It needs to be the site url plus /_api/...
If using the root site collection:
https://hclo365.sharepoint.com/_api/web/lists/getByTitle('SPlist')
If using a different site collection:
https://hclo365.sharepoint.com/sites/TestSite/_api/web/lists/getByTitle('SPlist')
- hcl_nitinApr 28, 2020Copper Contributor
- Apr 28, 2020
Open a browser and access the 'SPList' list on that site. If you have permissions to see the list, you can also query it's data via the REST API. Ensure that the url is correct.
- hcl_nitinApr 28, 2020Copper Contributor
even when I am using
https://hclo365.sharepoint.com/sites/Deployment Tracker/_api/web/lists/
I am not getting anything. where "Deployment Tracker" is my site name
- Apr 28, 2020
hcl_nitin regarding the Deployment Site, ensure that the url to the site is correct. You have a space in the URL, which is not valid. Open that site and copy the url from the browser.
Perhaps it's better that you follow the link that Beau Cameron shared initially as it will help you a lot with the fundamentals
- hcl_nitinApr 28, 2020Copper Contributor
Joel Rodrigues Please help me. As I am new in usinf web api
while using https://hclo365.sharepoint.com/_api/web/lists/getByTitle('SPlist') i am getting
{"odata.error": {"code": "-2147024891, System.UnauthorizedAccessException","message": {"lang": "en-US","value": "Access denied. You do not have permission to perform this action or access this resource."how to get permission .