New answers tagged

1

You can use TaxCatchAll in REST API to get the Managed Metadata column values . Refer this article having detailed steps to get metadata column value.


0

The catalogs are still lists, so you can still reach them by /lists/getbytitle(). But you do have to know the "title", which may not be what is in the URL. For instance the URL to the Composed Looks catalog is: https://server-url/sites/mysite/_catalogs/design/AllItems.aspx But the "title" of that list is actually "Composed Looks&...


1

You can use it something as below: fetch(url, options) .then((data) => { if(data.ok){ data.json().then(value => { const id = value.d.Id; }); } });


0

SharePoint admins don't have automatic access to all sites, but they can give themselves access to any site. You could go to the SharePoint admin center, add yourself as site admins for that site. https://docs.microsoft.com/en-us/sharepoint/manage-sites-in-new-admin-center


1

As per my understanding (by seeing the screenshots you attached), I think it is causing this issue because of using incorrect internal name of your Folder column. Please check the internal name of your column using this method: Find the internal name of SharePoint column Then you can use the REST endpoint like below: <site-url>/_api/web/lists/...


0

Try the below Rest API call, it should work for you: /_api/web/lists/getByTitle('list')/items(1)/FieldValuesAsHtml?$select=Title,Folder


1

As both columns are Single Line of texts, the simple REST call should return their values. However, try below REST API call to get specific columns only (Use internal names) - /_api/web/lists/getByTitle('Tags')/items?$select=Title,Folder


0

As I was writing this, I found a potential lead: the "additional" column definition (RelatedRecord:ID) has a PrimaryFieldId property which references the column I actually created (RelatedRecord). Using this, I can build the $select argument for the lookup column: const selects = []; const expands = []; fieldDefinitions.forEach(field => { if (...


0

Not all user profile properties that we could get from people column. https://social.technet.microsoft.com/wiki/contents/articles/31210.sharepoint-2013-get-user-details-from-person-or-group-field-using-rest-api.aspx


0

It was a silly mistake. The /$value suffix works, I just wasn't escaping the $ with a backslash on the (Linux) command line.


1

Per my test, I got the same result as yours on my end. And if you rejected the pending item, IsCurrentVersion would also be true for this rejected item. So there should be two vesions that IsCurrentVersion is true(the last approved version and not approved vesion). For users who can only see approved version(read permission), they cannot see not approved ...


0

You shouldn't specify the complete URL of the file in here: .../files/add(url='{ fileFullPath }', overwrite=true)"; Just specify the filename within the folder. ex.: document.docx.


1

Videos in an asset library are "hidden" in folders in an otherwise ordinary document library. The name you see in the library is the name of the folder, not the video. As you have probably already found the SharePoint library REST APIs, you just need to add the folder to the path. See if this helps to find those details: https://techtrainingnotes....


0

In your discussion list, click the "Message" content type. You would see the ContentTypeId in the url:


0

I will suggest to use GetFolderByServerRelativeUrl() like this https://<site url>/_api/web/GetFolderByServerRelativeUrl('Documents/test folder1/folder inside test folder/folder3')/files/add(url='test.txt',overwrite=true)


0

Yeah, I've found that: https://mycompany.sharepoint.com/sites/MySite/_api/web/GetFileByServerRelativeUrl('/sites/MySite/Shared%20Documents/MyDocument.docx')/$value Also, only returns the XML metadata for the file and not the actual file. That or a 404 error for platform independent clients that may not be able to process both the content and the metadata ...


0

Below endpoint is for file downloading. https://abc.sharepoint.com/sites/s01/_api/Web/GetFileByServerRelativePath(decodedurl='/sites/s01/Shared%20Documents/file-example_PDF_500_kB.pdf')/$value You can take a reference of the API doc: https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/working-with-folders-and-files-with-rest#working-with-files-by-...


0

This is just not possible. If the users donot have access to the admin center, they can only create site collections with modern template(communication sites and team sites). The rest api you used is only available for Communication sites and non-group associated Team Sites.https://docs.microsoft.com/en-us/sharepoint/dev/apis/site-creation-rest To create ...


0

This is the work around we did. It sets a Group as the Owner of another group. private SetOwner = (groupId,ownerGroupId) : Promise<SPHttpClientResponse> => { var siteUrl //set this var siteId //set this var endpoint = siteUrl + `/_vti_bin/client.svc/ProcessQuery`; const body = `<...


1

There is no such rest api to get all items from all subsites. You have to loop through the 5 subsites in SPFX, then get all items in each subsite.


0

The url should be like: https://sharepointDomain/sites/<app_name>/_api/web/getFileByServerRelativeUrl('/sites/SourceFoldername/test.xlsx')/moveto(newurl='/sites/DestinationFolderName/Test.xlsx',flags=1)?@target=sharepointDomain" My test code: function MoveFile(){ var oUrl = _spPageContextInfo.webAbsoluteUrl +"/_api/web/...


0

Try to use this : /SitePages/checklist.aspx?($filter=ChecklistID/DueBusinessDay eq -1)&$expand=ChecklistID My test code: /_api/web/lists/getbytitle('test4')/items?$select=nun,Owner/ID&($filter=Owner/ID ge -1)&$expand=Owner Owner is a people column. Test result:


2

Try using below REST query: <site-url>/_api/web/lists/getbytitle('Documents')/items?$select=FileLeafRef,CheckoutUserId&$filter=(CheckoutUserId ne null and CheckoutUserId eq 10) Replace 10 by user ID of your System Account.


0

I know this is old but with SharePoint 2010 workflows going away, I thought someone else may need this. This is the same call that CSOM would make. When a HTTP Request is received. Schema: { "type": "object", "properties": { "web": { "type": "string" }, &...


0

SharePoint uses some hidden columns to indicate if an item is a record. Since, you have specified SharePoint online, typically, you would be setting a retention label or a compliance label to a document, hence you can check if _ComplianceTag (this is the internal name of the compliance label column) is not null or empty. However, it is not mandatory that a ...


0

Try to use the GetFolderByServerRelativeUrl endpoint to return all files and sub-folder from a specific folder URL: https://server/_api/web/GetFolderByServerRelativeUrl('/Goverance Library/SOP')?$expand=Folders,Files To return only all files from a specific folder URL you can use: https://server/_api/web/GetFolderByServerRelativeUrl('/Goverance Library/SOP')...


2

Since you are using jQuery, you can use the jQuery Deferred object, which is similar to a regular javascript Promise, in order to control the execution flow of your multiple requests. What you need to do is return a deferred.promise() from the functions where you make the ajax calls, and only resolve() the promise when you are satisfied that the next call ...


0

Check if this can help you, its used against SharePoint Rest API https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/make-batch-requests-with-the-rest-apis https://docs.microsoft.com/en-us/odata/client/batch-operations


Top 50 recent answers are included