Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Make your voice heard. Take the 2019 Developer Survey now

Questions tagged [rest]

The REST (Representational State Transfer) interface in provides access to lists and libraries as a relational data service. A core concept of any RESTful interface is the resource, and in SharePoint Foundation, lists and items are represented as HTTP resources that can be addressed by remote URLs.

0
votes
0answers
8 views

How to extract metadata including whole file content in sharepoint REST api

Now, I want to extract file content using sharepoint REST api. My goal is: extract file metadata and entire file content (just pure content, no structures). After searching online, I notice I can use ...
0
votes
1answer
24 views

Change approval status after insert item via Sharepoint REST API

I recently noticed that by modifying the column of an item in a list with active versioning, however much the item is approved, it changes the status to draft. When faced with this problem I decided ...
1
vote
2answers
33 views

Rest Search API SharePoint

I am trying to retrieve images using REST SEARCH API from multiple Picture Libraries distributed across sub-sites(sub-sites are all under a single site collection https://xyz/site/*) .I also need to ...
0
votes
0answers
29 views

Sharepoint Online REST: ListItemAllFields response DateTime timezones

On some websites, when I get an item by <site-url>/_api/Web/GetFolderByServerRelativePath(decodedurl='<folder-path>/')/listitemallfields , the API returns the Created and Modified ...
0
votes
0answers
16 views

Change Security Group Name(Title) using REST in 2013 Workflow [closed]

Sorry for the cross-pollenation, but didn't get any traction in TechNet. But, please review here: https://social.msdn.microsoft.com/Forums/office/en-US/35758186-d8b0-4938-82bb-5d27fda0f7ae/change-...
0
votes
2answers
26 views

Why the AJAX function is only executed in the end?

I've this code below: jQuery(document).ready(function() { jQuery.ajax({ url: "https://test.sharepoint.com/sites/test/Negocio/OfertaParticulares/_api/web/folders('Dinamico')/...
1
vote
0answers
19 views

Rest queries on ProjectOnline should use _API/ProjectData or _API/ProjectServer?

I've been trying to identify what is the correct way to get data from Project Online for some time now (I just want to get data, not update it). I can find documentation on ProjectData and a lot of ...
0
votes
2answers
15 views

Data from Sharepoint REST API is returning undefined

I've this code below: jQuery(document).ready(function() { jQuery.ajax({ url: "https://test.sharepoint.com/sites/test/Negocio/_api/web/folders('Historico')/folders?$...
1
vote
1answer
30 views

Show the SubFolders in DIV using Sharepoint REST API

I have this code bellow: jQuery.ajax({ url: "https://test.sharepoint.com/sites/test/Negocio/_api/web/Folders('Historico')/Folders", method: "GET", ...
3
votes
0answers
26 views

Sharepoint Online REST: retrieving ServerRelativeUrl of deleted file?

After using getChanges to get deleted files/folders, is there a way to get the deleted file's original ServerRelativeUrl (path) even if the file is not in the recycle bin (ex: it was directly deleted ...
0
votes
1answer
26 views

I would like to know how to display the data on the website after being fetched via ajax

$.ajax({ url: "http://bc-net/Sandbox/juandev/_api/web/lists/GetByTitle('Qlinks')/items", method: "GET", headers: { "Accept": "application/json; odata=...
3
votes
1answer
32 views

SP .trim() and jQuery.trim() are fighting

I'm using a jQuery plugin Datatables to create my own views of information retrieved from a list and it is mostly working. Datatables is built on top of jQuery and relies on a lot of its features. ...
5
votes
4answers
183 views

Filter Created in SP REST API

I have this code below: jQuery.ajax({ url: res3 + "/_api/web/lists('" + normlistid + "')/items('" + normid +"')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu", method: ...
0
votes
1answer
18 views

How to create a Custom List in Sharepoint 2013 from a Template using SPServices REST API

I have made two custom list templates for 2013 and I want to create lists using those templates Dynamically. Something like using a page in which I choose the name and description of the custom list ...
0
votes
0answers
17 views

Create Page .aspx in a list using SP REST API [duplicate]

I've this code below: var fields = { "__metadata": { 'type': "SP.Data.PagesItem"}, "Title": "test" } jQuery.ajax({ url: "https://.../sites/intranet/jobs/_api/web/lists/GetByTitle('Pages')/...
4
votes
0answers
57 views

Get SubFolders using Sharepoint REST API and show them in HTML DIV

I want to retrieve Subfolders using SP REST API and check if there is any created folder and If it exists, display HTML content like: <label>SubFolder Title</label> for each SubFolder. All ...
0
votes
0answers
22 views

FirstName and LastName are not available for expanding in SharePoint rest api

I used rest api to get FirstName and LastName of a user field. The code hasn't been updated for a long time now and it was working fine until last month, but now it doesn't seem to work Here is the ...
0
votes
1answer
43 views

SharePoint API and VBA - Access Denied

I'm trying to retrieve items from a SharePoint list using the SharePoint Web API. I'm coding in VBA, because a need to display the information in a Word document. However I'm getting the Access Denied ...
1
vote
1answer
44 views

Can't retrieve all Items from all lists that reside on a single subsite

SP Community, I am absolutely stumped and desperate for help. I have been up and down StackExchange trying to get 3 separate attempts to - 1. query all of the lists within a subsite and to then - 2. ...
1
vote
2answers
41 views

Sharepoint Online REST: API not returning correct info if site collection created before certain time

On older websites (ex: 2018/10), the GET https://msdn.microsoft.com/en-us/library/office/dn499819.aspx#bk_WebEndpoint and GET https://msdn.microsoft.com/en-us/library/office/dn531433.aspx#...
0
votes
0answers
39 views

Site collection through REST API on SP 2019

Can we create site collection through REST API on SP 2019 on-premise environment?
0
votes
1answer
24 views

Sharepoint Rest API Error 403

i have a sharepoint farm with two different web applications. When i'm trying to access the second web application with java script from a page of the first web application, i always get an http error ...
1
vote
1answer
36 views

SharePoint server REST: Find folder by attribute

I am developing an integration between several systems and in one point I have to find the files inside a folder using the SharePoint REST API. The data I have to look for the folder is the List were ...
0
votes
2answers
26 views

REST API: I want to display all items with a certain value first, even though they are not in order alphabetically (asc and desc won't work)

I'm essentially wanting to implement a custom sort order. I have a list of items with a 'Status' choice column. The status choices are 'New Item', 'Funded', and 'Pending'. In my query, I'd like to ...
0
votes
3answers
24 views

What is the proper REST call to get m:properties --> d:Id, d:ID but not the GUID ID XML elements?

Please see attached JPEG to demonstrate what I'm asking. Thanks
3
votes
1answer
34 views

How can I check if an ID belongs to a user or a group?

I've got a SharePoint list with a field where authorized users and/or groups are listed. I know I can use CanCurrentUserViewMembership to check if the user belongs to a specific group, but if the ID I ...
0
votes
0answers
11 views

Create a reference thread using Social Feed REST API (e.g. rating notifiation)

We are using SharePoint Social Feed as a social component in our company network, but without using the SharePoint UI. All things are done in a modern React based webapp using the REST API. In the ...
1
vote
2answers
43 views

Sharepoint Online REST: field property names in Item response JSON

Is there an exhaustive document of how (possibly user-added) field values are returned in the Sharepoint REST ListItem GET endpoint's response? Afaik, most field values are returned by its ...
1
vote
2answers
60 views

SharePoint Online Create Site Collection using REST api?

Is it possible to create a site collection using the SharePoint Online REST api? I found some old notes about using admin.asmx in 2007/2010/2013 but I can't find anything related to SharePoint online ...
1
vote
1answer
29 views

Getting objects with today's date in Rest API

I need to fetch task objects which are completing today using Rest API , Can anyone please suggest how can we use today option to filer the data? I am using below query: /api/Objects/Task?$filter=...
1
vote
1answer
28 views

Attach File to Document Set via REST

Is there a way to upload files using Sharepoint REST API to my created Document Set? Document Set: Inside "Test" woud be: I can upload files via browser but how do I do it via REST?
3
votes
1answer
46 views

How to get a list's new Name after changing it with the REST API on SPO?

On SPO, after changing a list's Name in 'List Settings' > 'List name, description and navigation', the list's Name in the SPO webpages gets immediately updated, but the GET /_api/Web/Lists(guid'my-...
1
vote
2answers
44 views

SharePoint Online Rest: Lookup Values visible in list, ID column does not reveal the Ids of the item

I have an odd issue today. When looking at a list I can see the lookup field is populated with an item, this is one of a few lookup fields on the list. However when I look at the results of a rest ...
2
votes
1answer
45 views

SharePoint 2013 REST API filters

As part of our requirement, i created one BCS connection which retrieves data from a SQL stored procedure which acceppts two input paramaters. I was able to create a external list out of it. But when ...
3
votes
2answers
75 views

PnPJS - Check if site collection exists

With PnPJS, is there a way to check if a site collection exists given several URL? Something like this: import {Site} from '@pnp/sp'; const sitesToCheck = [ 'myspsite.net/sites/sc1' // exists '...
1
vote
1answer
34 views

Error reading syndication item: 'Data at the root level is invalid. Line 1, position 1.'

First time playing in this environment: Sharepoint 2010. I have access to very limited tools: browser, notepad and the Internets. Feeling a bit rusty, haven't programmed in a while and I'm having a ...
1
vote
1answer
61 views

I need to return the number of views a document was viewed?

I saw about the ViewsLifeTime and ViewsRecent properties. The two return empty. How do I work?
1
vote
1answer
66 views

Upload file to SharePoint online with HTTP REST calls

According to the following link: Working with folders and files with REST I can add a file using url: http://site url/_api/web/GetFolderByServerRelativeUrl('/Folder Name')/Files/add(url='a.txt',...
1
vote
1answer
48 views

Sharepoint 2013 rest api group subtask with respective main task?

Want to display Task and sub-task using the rest api jquery. My query string displays task and sub-task as individual unrelated task.
1
vote
1answer
54 views

AJAX REST call to POST to SharePoint list generates error

I am having difficulties with the JQuery implementation of AJAX to make REST calls to POST data to add items to my SharePoint list. Using 'GET' to retrieve information gives me no issues. Given the ...
1
vote
2answers
84 views

Using Javascript REST API to do asynchronous batch POST to multiple SharePoint lists

I'm in a bit of a quandry as I'm just learning how to do development in SharePoint 2016 / SharePoint Online and using Javascript to perform REST calls. I have a form that is using REST to successfully ...
1
vote
1answer
74 views

C# - How to add document with REST API in SharePoint 2016 On-Premise

I want to GET documents With SSOM in SP2007 and upload with REST to SP2016 This SSOM code for create doc library: (Working): private void CreateList() { var digest = GetFormDigest(); var ...
2
votes
1answer
22 views

Extract sub site logo with MS Graph (or any other way)

I need to extract sub sites logo and show it in a list. This is something I thought could be made with MS Graph, but in MS explorer I can't find the picture element. Only site ID, members, etc. ...
1
vote
1answer
70 views

Is there a way to get CSOM ClientContext by having cookies and a Form Digest?

I have been trying to do an interesting proof-of-concept/experiment Get SharePoint user's cookies from the browser Pass these cookies to an Azure Function By having cookies only - determine who the ...
0
votes
0answers
27 views

REST call for fields: “Type cannot be null”

I'm making rest calls to get a lists fields in a custom JS application. For some reason it's failing when I make the call through the app but when I do it in the console it works fine. I'm using ...
0
votes
1answer
13 views

Provide user a filtered set of managed metadata column values for filtering on a list view

Background/Problem Our customer recently switched from a choice column to using a managed metadata field to capture data in a list. They really love the ability to add new values on the fly, as well ...
0
votes
0answers
15 views

How to create Web API controller in SharePoint 2010 Farm solution

I am trying to build the services in SharePoint 2010 farm solution which would connect to SQL database and return the response in JSON. I tried exploring and all I could find was that I can build Web ...
1
vote
0answers
12 views

I want authors to be able to edit some items on the site using REST api

I am new at using REST api and fairly new to sharepoint. I got assigned a project to design a home page, which I already did and my boss wants the authors to be able to edit some of the fields on the ...
1
vote
1answer
30 views

How can I get current user roles for specific document in a document library?

I can add a role to a document with this code: var REST = globalvars.absoluteUrl + "/_api/SP.Sharing.DocumentSharingManager.UpdateDocumentSharingInfo"; var data = JSON.stringify({ '...
0
votes
1answer
55 views

REST API couldn't create list field

I am trying to create list fields using REST api. But when I call the code given below many times, it creates some of the fields and not all of them. code: function addnewfield(name){ $.ajax({ ...