Questions tagged [sharepoint-rest-api]

Using the Representational State Transfer (REST) interface provided by SharePoint

Filter by
Sorted by
Tagged with
0
votes
0answers
28 views

How to get an auth token and upload files via the SharePoint REST API?

A client shared a folder with me: I got a link looking like https://clientname-my.sharepoint.com/personal...?originalPath=(long string of k23jlkj2342)&id=(something looking like path to the folder)...
0
votes
1answer
64 views

filter column with last 4 digits using restapi

We have a column where the values are stored as '1002859817' and the Field Type is single line of text. The end goal here is to filter the column based on the last 4 digits i.e. '9817' Tried the ...
0
votes
1answer
45 views

Batch Update for 16K Items failing

We are trying to copy contents from one column to the other , However we get request digest error after 6K Items. Below is the code $(document).ready(function () { $("#btnSubmit").click(...
0
votes
0answers
15 views

get videos from Sharepoint 2019 online, video gallery and add show all those on page using jsom

I am trying to get all videos from SharePoint 2019 online video gallery and show them on a .aspx page using content editor web part. First issue is I am getting more items in the array where I only ...
0
votes
1answer
205 views

How to set field as hidden in list content type using API?

I need to set field as hidden (not visible on list form) using REST API. I don't know how to setup command. I found location of this parameter in xml but I don't know how to refer and update them, you ...
0
votes
2answers
66 views

Sharepoint /$value returns Gibberish / strange encoding

I am trying to access a word file from a sharepoint site with the $value which returns the content in unknown format. GET url is https://site.sharepoint.com/_api/Web/GetFileByServerRelativePath(...
0
votes
0answers
18 views

How to check if user belongs to a sharepoint AD group nested within a SPO group using REST/Javascript only?

I need to know if a user belongs to a specific SPO group using REST/Javascript. If the user has been added individually I can but if the user has been added to that SPO group via an AD group I can't ...
0
votes
1answer
41 views

PWA/Project Online - Setting Project ID dynamically with REST

I am trying to dynamically set the Project UID in an Angular app which is deployed to every subsite throughout my PWA. I need to be able to ideally, store the Project UID in a global variable which I ...
0
votes
0answers
16 views

Download file from SP in custom web part without <a></a> tag

I have a custom web part it needs to download a file from SharePoint document lib. I was using the tag combined with the file path, but this seems to break SharePoint. Is there another way to do it? ...
0
votes
1answer
43 views

How to get SharePoint users from list by Rest API

I have written my app, in SharePoint Framework, but in link I have got only name of list. How can I get user name and Surname of editor and creator? I want to have all user data. How can I get it by ...
0
votes
0answers
54 views

Get UPN or Azure AD User Id from SharePoint People or Group LookUp field

I'm using PnP JS to get the the values of a Person or Group field. Is there a way to retrieve the UPN or Azure AD User Id, using the SP Rest API? I have looked everywhere and I can't find an answer to ...
0
votes
1answer
95 views

List Dates Off by One Day

I am having issues with dates in a SharePoint 2013 list. At a high level I am archiving the dates of the selected item in List1, storing them in List 2. The dates in the selected item are updated to ...
1
vote
0answers
72 views

409 'Conflict' Changing ContentType property of Document Library

I have about 600 items in a document library. The library has 9 content types defined in it, which is part of a reorganization to take items out of folders and make it folderless. The library is a ...
0
votes
1answer
135 views

How to login using API to get delegated permissions for registered app

I managed to get the access token in postman (After registering the app on Azure on following the required steps), but the permission for the app is set to only allow logged in users to read from ...
0
votes
1answer
43 views

Getting all shared files and folders from a given site

Is it possible to get all files or folders that has been shared from a site in one batch, or do you need to iterate each single file and folder on the site?
0
votes
0answers
66 views

Rest api caml query not returning field in ViewFields

I have a CAML query that I am running through the REST api, the simple example below requests 2 fields - FileLeafRef and CustomField. Custom field is simple a text field, nothing special. CustomField ...
0
votes
1answer
101 views

Batch Update for 700+ items failing

I have written a code that gets all the URLs from the URL column in a document library , converts them into base64 and stores the resultant string in the respective column. The code works fine on a ...
0
votes
1answer
16 views

Returning REST response to calling function

Is it possible to return the value from a REST response back to the calling function? In the code below returneddata is always undefined. In the GetMyData function I can see the REST response and ...
0
votes
0answers
31 views

How to update workbook's named cell from rest API

I want to read and update a named cell from an excel workbook. If I reach the cell using graph api endpoint, it works: GET https://graph.microsoft.com/v1.0/sites/{siteid}/drives/{driveid}/items/{...
1
vote
1answer
48 views

Remove Role Definitions From SPO Group - Power Automate - MS Flow

I'm trying to remove full control role definitions from Site Owner Group, because I have added another permission level through Power Automate/MS Flow. From Microsoft docs - Below is the syntax for ...
0
votes
1answer
188 views

How to update list item using id in Sharepoint 2016 using rest api

I have two lists 'a' and 'b' with same titles but different ids. I retrieve the title from 'a' list to a html page. And, there is a 'b' list. Here, both the lists have different ids but has same ...
0
votes
1answer
29 views

Unable to store the list item value using session storage in Sharepoint 2016

I click on a link then it's updating the count column value in the list. But after reloading the site, the count column value becomes 0 in the list. I am updating the count value using count variable ...
1
vote
1answer
41 views

Unable to update the list item in list using REST API Sharepoint 2016

I've been working with this problem from one month but unable to solve this. I'm able to retrieve the list using GET method REST API. But I'm not able to update the items in the list using POST method ...
0
votes
1answer
26 views

SharePoint REST and DataTables.net (SP2013) Select Items

I had opened this thread in an other area of StackExchange, but then I found the SharePoint area, sorry for the duplicates. I am fairly new to SP and we are still using an old version, so looking for ...
0
votes
1answer
27 views

Unable to match a subtasks to its parent tasks REST API

I am able to get the tasks and subtasks from a SharePoint list using the REST API. How can I match a subtask with its parent task? The following JS inside an AngularJS controller returns two lists, ...
0
votes
0answers
26 views

Filter lookup field of multiple values using REST API 'getitems'

I am trying to retrieve items from a List, using CAML+RESTApi but when I try to $filter for a lookup column with multiple values it shows me: {"error":{"code":"-1, Microsoft....
1
vote
2answers
457 views

Retrieve SharePoint file with API using document ID from any document library

In site collection features there is an option to enable Document ID Service. After doing this, whenever a document is uploaded to a document library, a unique document id that is a link to the doc is ...
1
vote
3answers
194 views

Make html page with Sharepoint REST result

I'm new with javascript and HTML, so please be patient. I'm trying to make very simple HTML page displaying text with value stored in sharepoint 2013 list. I've made REST query in which I've item with ...
0
votes
1answer
63 views

Is there any API to retrieve data from Popularity Trends in Sharepoint Server 2016

I'm using SharePoint Server 2016 and as we know there is a feature called "Popularity Trends" which gives a report on number of hits and unique users with the graphs for the library. So, ...
0
votes
1answer
72 views

SharePoint REST API - Fetching folders from subsite

I am new to using SharePoint online REST API's. I started with basics by connecting to SharePoint online via Postman and list folders in a subsite. So I have achieved the first step of connecting to ...
0
votes
1answer
49 views

Register app-only access with REST API

Is there any way to reproduce the app-only access registration using REST process described here: https://docs.microsoft.com/en-us/sharepoint/dev/solution-guidance/security-apponly-azureacs More ...
0
votes
2answers
149 views

Rest api returns undefined

I am trying to get a random list item field from a sharepoint list. but the results return is undefined. The URL of the rest api is correct as i copy and past it directly to the browser it displays ...
0
votes
0answers
32 views

Can I get search summary from SharePoint search REST API?

For example when I search "SharePoint" thru REST API, beside the result documents' properties, I want to get a snippet of text which hitting my keyword. For example: "Beside Microsoft ...
0
votes
0answers
46 views

Update requestdigest value

I have a custom sp 2013 page with content editor webpart, js referred from site assets, I am using rest api to perform crud If I do a post request, I am passing the $("#__REQUESTDIGEST").val(...
0
votes
2answers
48 views

REST API data.d.results property error

I am trying to loop through my SharePoint list items retrieved using REST API but I get the following error: Uncaught TypeError: Cannot read property 'ID' of undefined function onQuerySucceeded(data)...
0
votes
1answer
41 views

How to get the number of clicks on a list item in SharePoint 2013 using REST API JavaScript?

I am new to SharePoint and using 2013 classic version. I have created a website and in it, it has list with items. So, I need to trace the number of clicks of each item individually. My code is not ...
1
vote
2answers
23 views

Using REST to show list of documents which match certain metadata

Apologies if REST isn't the right tool I need here. I currently have dozens of content query webparts all over our site. These pull in files from a single library which match a certain metadata which ...
0
votes
3answers
39 views

SharePoint REST limitation?

To all SharePoint folks, Have anyone noticed, when we apply OR operator in REST API filter having more than 5000 List items, it will throw error code 500 even if I return single item. FYI, All columns ...
0
votes
2answers
66 views

SharePoint Modern Client Side Page - Author is wrong

I used the below rest API to create a client side page from a template. https://mytenant.sharepoint.com/sites/xxx/_api/web/getfilebyserverrelativeurl('/sites/xxx/SitePages/templates/MyTemplate.aspx')/...
0
votes
1answer
278 views

SPFX File upload to List

This issue is related to a No Javascript Framework SPFx webpart with RestAPI on Sharepoint 2019. The webpart contains a 'text' and 'file upload' fields. The aim is to fill in the text field, select a ...
0
votes
0answers
17 views

Attempting to obtain Access Token in Sharepoint API 2.0 returns empty content

My ultimate goal is to set up programmatic access to our SharePoint file storage so that our code can write files to the site directly. To this end, I've been testing the SharePoint API under the ...
0
votes
2answers
109 views

Checking which users and groups has access to file or folder

Im trying to write rest to understand which users has access to a certain files and folder. What REST calls can I use to get which users has access to a file or folder?
0
votes
1answer
39 views

Tree-hierarchy for 3 sharepoint lists using the https://gijgo.com/tree .. any help please

I have the below 3 SharePoint lists, and using the REST APIs i am getting the data as follow:- 1- List named named "Department", here is the json for the items "value":[ {"...
0
votes
1answer
68 views

Ajax calls failing intermittently

We are trying to save an attachment to multiple list items created concurrently. The PDF files are created dynamically using jspdf and stored against the list items Below are the functions that create ...
0
votes
1answer
174 views

Sharepoint Online REST Item call returning empty array

I have a Sharepoint Online sitecollection http://tenant.sharepoint.com/sites/test and I have set up an app to be able to get the authentication tokens in Azure AD (Sites.FullControl.All for Sharepoint)...
0
votes
1answer
46 views

how to handle optional value in rest api post in Msflow

Hi i am updating people picker , managed metadata column in SharePoint using powerautoamte send http request to Sharepoint now few fields is optional when this fields go empty it throw error , how can ...
0
votes
2answers
850 views

Update People picker column using REST API in Power Automate

How to update people picker column using REST API in Power Automate? I have three people picker column in SharePoint.
2
votes
1answer
85 views

Add Sharepoint Online list item using pure JavaScript

I am trying to do the following: I have a Wordpress site where I have created a form. On submit event I want to send the data to my Sharepoint Online list. The problem I am facing is the fact that the ...
1
vote
1answer
93 views

Retrieve SharePoint Online change log for entire tenant

I'm using GetChanges REST end point to retrieve SP change log: https://mytenant.sharepoint.com/_api/site/GetChanges with request body like below: { "query": { "Add": ...
1
vote
1answer
27 views

Creating English-UK sites via Sharepoint Rest API

I am trying to create a new SharePoint Site collection via the REST API and trying to have that site be created using the English - United Kingdom Language rather than English - United States I ...

1 2 3
4
5
31