.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!



Home >> Articles >> SharePoint >> Post New Resource Bookmark and Share   

 Subscribe to Articles

More REST Examples

Posted By:Jean Paul       Posted Date: April 30, 2016    Points: 200    Category: SharePoint    URL: http://www.dotnetspark.com  

In this article we have explored few REST examples using browser URL box.
 

Get a List by Title

We can get List information using the Title of the list. Make sure you have a list named Contacts.

URL: http://server/_api/Web/Lists/GetByTitle('Contacts')

image

Please note that REST API is provided using the context _api.

Using chrome browser I received the following output.

image

Although IE 11 hesitated to show the output, giving an error message.

image

But in IE too, we can view the output using View Source option.

image

image

By default XML format result is provided by SharePoint REST services. In programmatic way, we can format these results to JSON format.

Getting List Items

We can try getting the list items using REST.

URL: http://sharepoint/_api/Web/Lists/GetByTitle('Contacts')/Items

Using chrome browser I was able to view the following results.

image

However In IE the result summary was shown.

image

image

Please note that REST is trending as a replacement for JSOM in SharePoint world. REST provides much easier, less-coded ways of working with client-side object model.

References

https://msdn.microsoft.com/EN-US/library/office/jj164022.aspx

Summary

In this article we have explored few REST examples using browser URL box.


 Subscribe to Articles

     

Further Readings:

Responses

No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More Articles on C#, ASP.Net, Vb.Net, SQL Server and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend