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.
2,332
questions
0
votes
2
answers
37
views
Copy SPO items with version history
Is there a way to copy the list items to another list(similar list) along with version history using power automate.
I have complete copying the list items successfully, but I did not get version ...
0
votes
0
answers
14
views
I'm having reliability issues with using C# REST Sharepoint API for bulk updates on a list
My calls to the Sharepoint REST API with my C# application are working. Some of the time. Other times I will call ExecuteQuery and they throw exceptions with unhelpful messages like "Could not ...
0
votes
0
answers
53
views
Rest API to list contents of a directory
There are a series of documents that get uploaded to a SharePoint instance. These documents need to be uploaded elsewhere and quite a few places. Currently this is a manual action that is error prone ...
0
votes
0
answers
23
views
Metadata / schemas for HtmlContent1
I am struggling to find an official schema/metadata/EDMX description of the data contained in a SharePoint page's HtmlContent1 or JsonContent1, for example:
{
"controlType": 4,
"...
0
votes
1
answer
50
views
Creating SharePoint folder with "title" property via Boomi
How would I populate the "title" property of a SharePoint folder when creating the folder via Boomi (with an HTTP request)?
I can't seem to find the full JSON to do this.
This is all I have ...
0
votes
1
answer
20
views
What exactly does the error "LookupTableSortOrderMustComeAfterParentSortOrder" mean?
I'm trying to create an enterprise lookup table in Project Server using the REST API.
If I use the following code (some stuff omitted for brevity and clarity):
const lookupDef = {
name: 'My Table ...
1
vote
2
answers
388
views
How Can I Use Site ID To Make API Calls?
Problem
I'd like to use the SharePoint API (cannot be the Graph API) to get information from site resources, and I would like to do this in one call to avoid problems with URL changes to the site in ...
0
votes
2
answers
37
views
REST Call Returns Tons of Unnecessary Metadata. How do I Just Get the Column Values?
I want to get the values stored in my List. Is there a way to make a call that only returns a string like:
[
item1 [ID, Title ...]
,item2 [ID, Title ...]
,item3 [ID, Title ...]
...
]
When I make ...
0
votes
1
answer
14
views
GetSiteDesign Does not retrieve Document Sets Content Type
I am using CSOM, trying to create a template where the site already has document sets enabled. However, when I get the site script from the template site and I apply it to a different site, applying ...
0
votes
1
answer
143
views
How to get published version of site pages in SharePoint online
Is there any way to get the all site pages last published version using rest api camlquery.
Thank you in advance
0
votes
1
answer
484
views
How to get items from Personal Microsoft Lists (Not Sharepoint Lists) using Graph REST API?
I'm trying to query my personal Microsoft Lists with Microsoft Graph API without success.
My list is a Microsoft List located in https://lists.live.com/.
My list's URL shown in my browser is https://...
0
votes
1
answer
38
views
Add custom properties in a SharePoint list template (.stp)?
I am using a custom list template in SharePoint Server (2019). How can I add a custom property (with a default/fixed value) in the manifest.xml file that will be available for all the lists that are ...
0
votes
0
answers
284
views
Opening a SharePoint file or folder in a browser, by its GUID
In my app, outside of SharePoint, I want to construct a URL to take me straight to a SharePoint file or folder in a browser. My app's database has a table containing the unique IDs (GUIDs) of some SP ...
1
vote
1
answer
248
views
Getting an item with image field not working
I wrote this code to get items from a SharePoint list that contains an image field:
private _getApps(): Promise<void> {
if (this.properties.listId) {
return this.context.spHttpClient....
0
votes
1
answer
217
views
Sharepoint REST api HTTP Error 403: Forbidden getting versions
I'm able to get the value of the file:
url = sharepoint_app_url + "_api/web/GetFileByServerRelativeUrl('" + file_path + "')/$value"
However when I want to get the versions or a ...
0
votes
1
answer
22
views
API does not return updated date for calendar event
Situation
A user creates calendar events in SPO. We use PowerAutomate to send an email once a week with a listing of the events that will take place in the next two weeks.
Problem
Sometimes, the date ...
0
votes
0
answers
79
views
Programmatically downloading all files from a folder
I need to create a script to download all files from a certain folder on my Sharepoint, or alternatively download using a wildcard (there will only be one file in this folder but its filename changes.
...
0
votes
0
answers
28
views
Sharepoint Online - REST Call takes almost one minute to complete
API Call to get all documents to display them in custom list takes about 55 sec to complete and it's irritating to customer that everytime they have to wait such period.
I'm interested into why and ...
1
vote
0
answers
65
views
Calling HTTP endpoints via On-premises data gateway
I have a requirement to get information from an old legacy system thats on premise.
If they have an API that is exposed can I use data gateway and a custom connector?
I need to use Power Automate to ...
0
votes
0
answers
13
views
Is there a way to create subsite based on another one, copying lists and workflows for them,..?
In Sharepoint Online, I'm trying to create a button that will trigger creating subsite and have all the lists and workflows based on one main list in root site.
E.g. there is two lists in root that ...
0
votes
0
answers
56
views
REST filtering large list by lookup field value
Is it possible to search in large list by lookup filed value with 'substringof'
like:
_api/web/lists/getbytitle('Obchodné Prípady')/items?$select=*,Investor/Title&$expand=Investor/ID&$top=100&...
0
votes
0
answers
94
views
Download File Using URL using NodeJS
So I implemented google drive url download feature recently and It starts downloading the publicly shared file directly without any authentication.
When I tried the same with SharePoint, I got 403 ...
0
votes
2
answers
224
views
Get a list of files in a sub folder in the Documents Library of Sharepoint site
I am trying to find the best way to get files inside a specific sub folder in the sharepoint website, but the only links I find relate to the root folders.
I have a Sharepoint site which is really ...
0
votes
0
answers
36
views
Querying, analyzing, and displaying data from external API in SharePoint
I am a new SharePoint developer and I am tasked with displaying trends in data from Zendesk in SharePoint. I have been reading the Microsoft documentations and from what I have been reading the ...
0
votes
2
answers
2k
views
How to get file metadata by REST API?
I have a video file named simpleVideo2 (360p).mp4 in folder Video Assets(It's document library), and I want to know if it's possible to fetch file metadata through the REST API to get the video's ...
1
vote
1
answer
748
views
Read Data from SharePoint Online using REST Api for Specific Item
I am successfully connected with SharePoint Online and successfully Updated the List using Rest Api.
Now I am trying to Get item details using ItemID using the following C# Code:
try
{
Uri uri = ...
1
vote
1
answer
119
views
How to get SharePoint Custom Workflow Status With REST
I have a SharePoint document library and I've created two custom workflow. Then i attached those workflows to a document library. What i'm trying to do is getting workflow status and URL with single ...
0
votes
1
answer
679
views
Update SharePoint List item using Rest API in C#
I am writing an API in Web API 2.0 on C# to perform various Actions with SharePoint List items.
I have tried the following code to update the Status Column of a List item:
HttpWebRequest ...
0
votes
1
answer
235
views
Get a List View via REST API with custom formatting and display it
I have a List with a View on it that has custom formatting. I am trying to pull the list via REST API and display the items according to that view within a SPFX-webpart with the custom formatting ...
1
vote
0
answers
337
views
Accessing the recycle bin with the SharePoint REST API results in an error "Access is denied."
I would like to access the recycle bin via the SharePoint REST API, but I get the following error.
{
error: {
code: '-2147024891, System.UnauthorizedAccessException',
message: {
lang:...
0
votes
1
answer
66
views
Accessing External Rest API from Sharepoint Modern site in Sharepoint Server 2019
I want to access external API through sharepoint server 2019 modern teams/communication site hosted on-premises. Is there any out-of-the-box web part that enables the access to the external API?
1
vote
1
answer
202
views
Hide a content type via REST for Power Automate
Trying to hide content types in a SharePoint library using REST in Power Automate but it doesn't seem to be changing the value, however, I get no errors.
I found this for the REST endpoint
https://...
0
votes
1
answer
855
views
Read large lists with Office365-REST-Python-Client
I am currently trying to read only the last week's entries of a few lists, and I accomplish this by using filter("Modified gt datetime{date_in_isoformat}') or order_by("Modified desc")....
0
votes
2
answers
175
views
Recycled item missing Name in Recycle bin
I made REST API call to recycle the item, which works successfully:
var requestDigestValue = $("#__REQUESTDIGEST").val();
if (requestDigestValue) {
$.ajax({
type: "POST",
...
0
votes
1
answer
628
views
Retrieve Site Assets library from SharePoint Team Site through REST API
I'd like a Power Automate flow to configure read permissions on the Site Assets library for a SharePoint group that contains external users.
However, I'm having a hard time retrieving the Site Assets ...
0
votes
1
answer
573
views
Is it safer to use "ge" and "le" to get items created on specific dates using the REST API, rather than using "eq"
I have a custom list with field of type DateOnly named ExpiryDate:-
Here is the site regional settings:-
now i have noted if we change the ExpiryDate to accept Date-&-time then we change it back ...
0
votes
1
answer
638
views
How Retrieve all the files and folders recursively in a specific folder using SPFX REST API post method
How Retrieve all the files and folders recursively in a specific folder using SPFx REST API post method?
private _spApi(): void {
this.context.spHttpClient
.post(`${this.context.pageContext....
0
votes
1
answer
143
views
How to select custom template on site collection creation
I'm trying to create a new site collection in sharepoint 2019 with the api _api/SPSiteManager/create. The only template i can choose are STS#3 and SITEPUBLISHING#0. If I choose any other template it ...
0
votes
1
answer
195
views
SPFX Form Customizer extension, how to prevent edits via REST etc
SPFX runs in context of the user, user has to have Write permissions to the list.
If user has write permissions, the REST API will reflect that, so the user could just bypass and form customizations ...
0
votes
0
answers
229
views
Why do I get empty lists when listing files/folders in a folder using API?
I've just created a folder "import" in sharepoint, where I've created :
1 emtpy folder "testdir"
2 emtpy files "test1.csv" and "test2.csv".
When I query this &...
0
votes
0
answers
274
views
In JavaScript, how do I create a SharePoint 2019 (on Premise) publishing page?
I am trying to find a way to create (and later update) a SharePoint 2019 publishing page via JavaScript. There seems to be a lack of documentation specifically directed at SP 2019, but plenty of SP ...
0
votes
1
answer
252
views
Is there anyway to Disable or remove Shared Link for particular user in SharePoint Online using Rest API, CSOM or PNP
I am looking for some mechanism to remove a specific user from a ShareLink in SharePoint Online via Rest API, CSOM or PNP, whilst leaving the ShareLink active and available for other users.
I want to ...
0
votes
1
answer
2k
views
403 Forbidden when uploading file to sharepoint using REST API. Permission issue or missing header?
I am new to Sharepoint and REST APIs and am currently having an issue uploading a file using REST API. I am getting error System.UnauthorizedAccessException","message":{"lang":...
0
votes
1
answer
998
views
SharePoint Online - Issue with REST API call on a List exceeded the threshold limit
I have a List in a SharePoint Online site collection which has exceeded 5000 items. I have indexed the columns that are needed in the REST API filter query during list creation itself.
Below is the ...
0
votes
1
answer
2k
views
Trying to upload files to sharepoint using REST API ,Python using Postman
import requests
url = "https://xxxxxx.sharepoint.com/sites/QE/Shared%20Documents/_api/GetFolderByServerRelativeUrl('product-xxxxx-metrics/xxxxx-dashboard-automation')/Files/add(url='test.csv',...
0
votes
1
answer
309
views
Authentication for custom REST API invoked from SharePoint online pages
I have a modern UI web part in SharePoint Online. This component needs to invoke a custom REST API that will be hosted in an Azure web app (not SharePoint REST API). I may also call this API directly ...
0
votes
0
answers
53
views
How do I set a person or group field via the API V1 using Rails with Faraday?
I've seen several similar questions and the crux of the answer seems to be that I should add "Id" to the field name and pass the user's id. Here for instance:
How to update "Person or ...
0
votes
1
answer
239
views
SharePoint Online Managed Path
Does anyone know how to get this information through rest API or PowerShell? I wanted to know if the tenant I am working with is using "/teams/" or "/sites/". I am creating an ...
0
votes
3
answers
292
views
Error Gibberish download file from sharepoint using rest api
I need to download a file from a sharepoint list using the rest api, the endpoint I use is the following:
https://mysite.sharepoint.com/sites/testsite/_api/web/GetFolderByServerRelativeUrl('/sites/...
0
votes
1
answer
351
views
Help with SPFx and Dataverse
I'm trying to do CRUD functionality on a Dataverse table from an SPFx app. I keep getting the same error:
To view the information on this page, ask a Global or SharePoint Administrator in your ...