Click here to Skip to main content
13,195,379 members (66,901 online)
Click here to Skip to main content
Add your own
alternative version

Stats

5.7K views
4 bookmarked
Posted 29 Aug 2016

REST Client for SharePoint

, 29 Aug 2016
Rate this:
Please Sign up or sign in to vote.
Exploring the REST API of SharePoint. This tool will help to test HTTP request very easily.

Introduction

This is the overview of SharePoint REST Client. SharePoint REST Client is a Chrome Extension for testing/exploring REST API of SharePoint. It can be very useful for testing HTTP requests like GET, POST, UPDATE or DELETE. It works on SharePoint 2010, 2013, 2016 and online.

Current Problem

There are many free REST clients available on the internet like Fiddler, Advanced REST Client, Postman and so on. These REST Clients have very user friendly UI for making complex requests and analyzing response but they do not work seamlessly with SharePoint. Some of the issues from Advanced REST Client are mentioned below:

  • It asks for credentials though you are logged in. This happens at on-premise site.

    ask for credential

  • It does not ask for credentials at SharePoint Online. It shows the following error.

    online error

  • It is mandatory to pass FormDigestValue for testing POST, UPDATE and DELETE request.
  • It is also needed to other headers like “Accept” : “application/json;odata=verbose”, “content-Type” : “application/json;odata=verbose”, “X-Http-Method” : “PATCH”, “If-Match” : “*” and so on.

To avoid the above issues, I have come up with SharePoint REST Client which will work on SharePoint very seamlessly.

sp rest client

SharePoint REST Client

Any HTTP requests like GET, POST, UPDATE or DELETE can be made very easily using this REST Client. Some tips are given below for using this tool:

  • Download and install SharePoint REST Client from store
  • Navigate or login on your SharePoint Site
  • Click on the extension icon
  • Your SharePoint page will be hidden and you will get the following UI for testing REST API

sp rest client ui

To make GET or DELETE request, you just have to pass the URL. There is no need to include host web URL in the request URL (start from /_api/).

For POST and UPDATE request, specify the request body as stringify JSON. For example:

{
  "__metadata": { "type" : "SP.Data.EmployeeListItem" },
  "FirstName" : "Atish",
  "LastName" : "Dipongkor"
}

For UPDATE and DELETE, you will not get any response but in case of error, this tool will show you the whole error. For GET and POST, you will get nicely formatted JSON like the following:

response

Conclusion

I hope this tool will be your ultimate REST Client for SharePoint. Please feel free to let me know if you face any other issue. Most importantly, it is open source. Let me know if you are interested in contributing on it. Find the GitHub repository below:

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Atish Dipongkor
Software Developer BrainStation-23
Bangladesh Bangladesh
2016 Microsoft MVP

Currently, I am devoted to provide technical and development support to the SharePoint clients and also I am working on angularjs. I am experienced with C#, ASP.NET, SharePoint, SignalR, angularjs, MS SQL, Oracle 11g R2, Windows Phone, Firefox OS and so on. I have fallen in love with many technologies but never got married to any of them. I am evolving myself as full stack developer. I always like to share knowledge as much as to gather from you.

You may also be interested in...

Comments and Discussions

 
-- There are no messages in this forum --
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.171019.1 | Last Updated 29 Aug 2016
Article Copyright 2016 by Atish Dipongkor
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid