3

How to get json data from REST api in SharePoint 2013 list?

Regards,

2 Answers 2

2

Elaborating a bit on Roman's answer:

 jQuery.ajax({
    url: "http://thisRestServiceURL",
    type: "GET",
    headers: { 
        "accept": "application/json;odata=verbose",
        "content-type": "application/json;odata=verbose",
        "X-RequestDigest": $("#__REQUESTDIGEST").val(),
    },

This would work for JQuery sending/receiving JSON Data.

5
3

You should pass Accept header, for example: "accept": "application/json;odata=verbose"

2
  • Yes but can you give me more details?
    – Wilon
    Mar 18, 2015 at 19:56
  • Which type of object model do you use?
    – Roman
    Mar 19, 2015 at 15:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.