Audit usage for REST API in SharePoint 2013
Hi,
Is there any OOB way for SharePoint to log access in REST API so that it will track which application/user uses the REST API?
Thanks,
Kenny
Hi,
According to your post, my understanding is that you wanted to audit usage for REST API in SharePoint 2013.
Per my knowleadge, there is no out of the box way to accomplish this with SharePoint.
SharePoint 2013 introduces a Representational State Transfer (REST) service that is comparable to the existing SharePoint
client object models.
This means that developers can perform Create,
Read, Update, and Delete (CRUD) operations from their apps for SharePoint, solutions, and client applications, using REST web technologies and standard Open Data Protocol (OData) syntax.
More information:
REST API reference and samples
Thanks,
Linda Li
Forum Support
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
[email protected]
Linda Li
TechNet Community Support
Similar Messages
-
Document Set Creation in document library using REST API in Sharepoint 2013
Hi,
I want to create the document set using REST API call. Currently i am able to create the folder and able to upload the files using REST API's in the document library. Is there any way we can pass the contentype name or Id and create the document set using
REST API call. We need to create the document set along with metadata and upload the files inside the document set.
I need to create the document set along with meta data column values using REST API. Please let me know how we can achieve this through REST API.
Thank you,
MylsamyHi,
According to your post, my understanding is that you wanted to create document set along with managed metadata fields.
The REST API does not currently support working with Managed Metadata or Taxonomy fields.
As a workaround, we can use the JavaScript Client Object Model.
Create document set using JavaScript Client Object Model.
http://blogs.msdn.com/b/mittals/archive/2013/04/03/how-to-create-a-document-set-in-sharepoint-2013-using-javascript-client-side-object-model-jsom.aspx
http://social.technet.microsoft.com/Forums/sharepoint/en-US/aacd96dc-0fb2-4f0d-ab4c-f94ce819e3ed/create-document-sets-with-javascript-com-sharepoint-2010
Set managed metadata field with JavaScript Client Object Model.
http://sharepoint.stackexchange.com/questions/95933/add-list-item-with-managed-metadata-field-through-jsom
http://sharepointfieldnotes.blogspot.com/2013/06/sharepoint-2013-code-tips-setting.html
Thanks,
Jason
Forum Support
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
[email protected]
Jason Guo
TechNet Community Support -
Hi everyone,
Does anyone know how to use JSOM / REST APIs to retrieve the users that are following a specific document in SharePoint 2013?
Thanks in advance,
NamHi Nam,
Please use the sample code to get the followers for the document. Courtesy: Mokhtar
Bepari
using Microsoft.SharePoint.Client;
using Microsoft.SharePoint.Client.Social;
ClientContext clientContext = new ClientContext("http://URL");
SocialFollowingManager followingManager = new SocialFollowingManager(clientContext);
SocialActorInfo actorInfo = new SocialActorInfo();
actorInfo.ContentUri = "<documenturl>"; //set the document url.
actorInfo.ActorType = SocialActorType.Document;
//By using the GetFollowed method you can get the people who the current user is following.
ClientResult < SocialActor[] > followedResult = followingManager.GetFollowed(SocialActorTypes.Users);
//By using the GetFollowers() method you can get the people who are following the current user.
ClientResult < SocialActor[] > followersResult = followingManager.GetFollowers();
clientContext.ExecuteQuery();
Once you get the resultset you can iterate like below:
foreach(SocialActor actor in followedResult)
string name = actor.Name;
string imageURL = actor.ImageUri;
Please 'propose as answer' if it helped you, also 'vote helpful' if you like this reply. -
Create search refiner for list name in sharepoint 2013
Hi everybody!
How could I create a search refiner for list name in SharePoint 2013?? I think I can create a search refiner for list ID but how could I show list name base on list id to users in refinement webpart??you can create your custom Manged property and use content enrichment to fill the managed property
http://blogs.msdn.com/b/richard_dizeregas_blog/archive/2013/06/19/advanced-content-enrichment-in-sharepoint-2013-search.aspx
Hope that helps|Amr Fouad|MCTS,MCPD sharePoint 2010 -
Search suggestion not working for anonymous user in sharepoint 2013
Hi ,
Please help on this search suggestion not working for anonymous user in sharepoint 2013
shaikYou can create a search center site, and set the search center site to
allow anonymous access.
Also see this link - http://blog.mastykarz.nl/search-query-suggestions-anonymous-users-sharepoint-2013-mavention-query-suggestions/
(As this is regarding a 3rd party tool, I suggest that you direct it to the provider support.)
Please 'propose as answer' if it helped you, also 'vote helpful' if you like this reply. -
How to hide the Columns and Views for Login user in SharePoint 2013
Hi Friends,
How to hide the Columns and Views for Login user in SharePoint 2013? Is it possible using OOB features? If not possible how can we hide the Columns and Views for Login user?
Could you please help on this.
Thanks,
Tiru
TiruHello Tirupal,
There is no OOB way to do this.
Please check this codeplex solution to achieve the same.
https://sp2013columnpermission.codeplex.com/
My Blog- http://www.sharepoint-journey.com|
If a post answers your question, please click Mark As Answer on that post and Vote as Helpful -
Do multiple bindings still causing issues for PowerPivot workbook in SharePoint 2013
Do multiple bindings still causing issues for PowerPivot workbook in SharePoint 2013 as they did in SP2010? Here is the link about 2010 issue :
http://support.microsoft.com/kb/2712071Hi Norm,
I searched internally, and I couldn't find any information related to this issue applied to SharePoint 2013, it shouldn't exist in SharePoint 2013.
Thanks,
Daniel Yang
Forum Support
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
[email protected]
Daniel Yang
TechNet Community Support -
Security Groups for the alerts in SharePoint 2013?
By default Microsoft has blocked to add Security Groups for the alerts in SharePoint 2013. It can be enabled but need to change the SharePoint System page setting with the help
of below link:
http://thesharepointfarm.com/2013/10/setting-sharepoint-alerts-on-active-directory-security-groups/
So my query is if I change the page setting then in future if any SharePoint updates/ hotfixes deploy in system so will it cause a problem??I would wait as this is not a supported workaround (although it does work).
Trevor Seward
Follow or contact me at...
  
This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs. -
How can I access user permission for specific items in Sharepoint 2013 via REST API?
I want to access user permissions for specific items like lists, documents, folders etc. via the REST API.
Currently I am hitting the following endpoint:
http://win-5a8pp4v402g/sharepoint_test/site_1/_api/web/getUserEffectivePermissions('win-5a8pp4v402g\\Sharepoint User 2')
However the response looks like this:
"d":
"GetUserEffectivePermissions":
"__metadata":
"type": "SP.BasePermissions"
"High": "0",
"Low": "0"
I cant understand why high and low are both 0? I have added the user to a specific group. Also this is the same result for each of the users. Another thing to note is that I havent added the "Guest" user in the sharepoint server. So when I hit the endpoint for the Guest user, it still shows the same response. So I know there is something I am doing wrong.I want to access permission of a user for a specific item, say a document using the REST API. Can someone tell me how? What would be the endpoint?Thanks for the reply. Although this works for Lists, I need to get permissions of documents too. Here is what I have tried:
http://win-5a8pp4v402g/sharepoint_test/site_1/_api/web/GetFileByServerRelativeUrl('/sharepoint_test/site_1/Documents/file1.txt')/GetUserEffectivePermissions(@user)?@user='i%3A0%23%2Ew%7Cwin-5a8pp4v402g%5Csharepoint%20user%201'
And the response is:
"error":
"code": "-1, Microsoft.SharePoint.Client.ResourceNotFoundException",
"message":
"lang": "en-US",
"value": "Cannot find resource for the request GetUserEffectivePermissions."
Clearly this doesnt work for a file. Whats wrong? -
Get link (Document Share) API in SharePoint 2013
Hi there,
We need a way to identify the automation or API for getting the anonymous link to a document in SharePoint 2013. We have a system where we query a given SharePoint site and show the user the document libraries and based on the document library selection,
we are showing the documents in the library. We have to give the share -> Get Link option to be automated through API, so they use that link to share with external users. But, as far as I know, I don't find any API to generate that link SharePoint is doing
today. Any ideas?
-Praveen.At this time, there are not any official documents including sharing documents with external users by using calling APIs.
However, about the application of the APIs in SharePoint Online, like List and Library APIs and REST API, you may check detailed information in
SharePoint Online service description which including all of the features available in SharePoint Online.
For the requirements mentioned above, you are welcome to
submit feedback to our product team.
Many features of current programs have been designed and upgraded based on customers’ feedback. We always appreciate customers who can take the time to give us their constructive opinions.
http://community.office365.com/en-us/f/154/t/190212.aspx -
How to update and delete using rest services in SharePoint 2013..
I am looking to create,update and delete data in SharePoint list where i am using below code for creating data..I should be performing three operations on single button click how can i achieve this.Below is the code i am using for creating data to list and
displaying in CEWP.
<html>
<head>
<style type="text/css">
#mytable{
border : 1px solid;
</style>
<script type="text/javascript" src="https://sharepointapp28.sharepoint.com/sites/Dev2013/SiteAssets/Scripts/jquery-1.11.1.min.js" ></script>
<script type="text/javascript">
var ListName;
var webUrl;
$(document).ready(function(){
SP.SOD.executeFunc('sp.js', 'SP.ClientContext', sharePointReady);//Doubt
function sharePointReady() {
webUrl = _spPageContextInfo.siteAbsoluteUrl;
ListName = "test";
$('#btnSub').click(function () {
updateItem();
function updateItem() {
var name = $('#txtName').val();
var Desc = $('#txtDesc').val();
var city = $('#txtCity').val();
var itemType = GetItemTypeForListName(ListName);
var item;
item = {
'__metadata': { "type": itemType },
'Name': name,
'Description': Desc,
'City': city
var xmethod = 'POST';
jQuery.ajax({
url: webUrl + "/_api/web/lists/getbytitle('" + ListName + "')/items",
type: "POST",
data: JSON.stringify(item),
contentType: "application/json;odata=verbose",
headers: {
"Accept": "application/json;odata=verbose",
"X-RequestDigest": $("#__REQUESTDIGEST").val()
success: onUpdateMSOPProcessSuccess,
error: onUpdateMSOPProcesFail
function onUpdateMSOPProcessSuccess(data) {
alert('successfully updated to MyList!!!')
function onUpdateMSOPProcesFail(data) {
alert(data.d.err);
function GetItemTypeForListName(name) {
return "SP.Data." + name + "ListItem";
</script>
</head>
<body>
<table style="width:500px" id="mytable">
<tr><td colspan="3"> </td></tr>
<tr><th colspan="3">Rest API</th></tr>
<tr><td colspan="3"> </td></tr>
<tr><th>Name</th> <td> : </td> <td> <input type="text" id="txtName" /> </td></tr>
<tr><th>Description</th> <td> : </td> <td> <input type="text" id="txtDesc" /> </td></tr>
<tr><th>City</th> <td> : </td> <td> <input type="text" id="txtCity" /> </td></tr>
<tr><td colspan="3"> </td></tr>
<tr><th></th><td colspan="2" align="left"><input type="button" value="submit" id="btnSub" /></th></tr>
<tr><td colspan="3"> </td></tr>
</table>
</body>
</html>Hello,
With one button you want to perform 3(Create, Update and Delete) operation
To create:
First check whether the data exist with full combination of Name,Desc and City.
If not exist you can execute the create function.
If exist, get confirmation to delete the item by pop up. Using item ID you can perform Delete operation
To Update:
How you want to update the item, by keeping unique value or combination of columns?
based on that you can perform the update operation.
Whenever you see a reply and if you think is helpful, click "Alternate TextVote As Helpful"! And whenever you see a reply being an answer to the question of the thread, click "Alternate TextMark As Answer -
Third party tool for document preview in sharepoint 2013
Hello,
we are looking for third party tool which provide preview of any documents in documnet library in sharepoint 2013. So when users just hover over the document, they can see the preview. Do
any of you please provide a good suggetion in case if you have used in the past? In my research I came across
Knowledgelake and harepoint. Also I think there is one Metalogix but I know for sure it a way too costly. So please help if you know who does this job with a fair amount of price.
Thanks.I've found Ontolica Preview to be adequate for this. Reasonable product and supports a lot of formats
http://www.sharepointreviews.com/component/content/article/69-sharepoint-auditing/202-Ontolica-BehaviorTracking-for-SPS-2003-.pdf
Might also be worth spending some time on SharePointreviews.com for other suggestions
http://www.sharepointreviews.com/
Steven Andrews
SharePoint Business Analyst: LiveNation Entertainment
Blog: baron72.wordpress.com
Twitter: Follow @backpackerd00d
My Wiki Articles:
CodePlex Corner Series
Please remember to mark your question as "answered" if this solves (or helps) your problem. -
How to import the JSON data that comes from REST API into Excel 2013?
HI,
Is there a way to import the JSON data that REST API returns into Excel 2013? If so how?
Could you please let me know this?
If you need to know any more info please let me know.
Thanks,
VinayI got this. We need to use power query add in for this.
EXCEL 2013 -> POWER QUERY -> From Web
Enter the URL for the REST end point and click ok. Power Query editor will show up with the URL and list of your data.
click on the list -> Right click->drill down
You will see the no of records the API returned.
Right Click on List in that table -> To Table and say ok in the next dialog.
On the displayed columns, there will be a double sided arrow, click on that and select the rows you want to import.
There you go. You will all the data.
Click on Apply and close. This will import the data into your excel file. -
Public IP address requirerement for a Public facing SharePoint 2013 website.
I am planning to implement a public facing website on SharePoint 2013 platform. Following are the proposed server setup.
2 x Web Front End (WFE) hosting SharePoint 2013 (Load Balanced)
2 x Search and Application server hosting SharePoint 2013 (Load Balanced)
2 x Application Server (non-SharePoint with separate .NET web applications linked through SharePoint site)
2 x SQL 2012 Servers (Clustered with two instances for SharePoint and .NET applications)
I understand that SQL servers will not require a public IP. What about other servers? Also, there is no tight integration between the Application (# 3) and SharePoint servers. It is just a hyperlink provided on the WFE website. In
this scenario, do we need public IPs for # 2 and 3?
Thanks in advance!
LMHi,
In your scenario, if your Application servers run apps that need to be accessed from the Internet, these need to be published as well. Your Search And Application hosting SharePoint 2013 (SharePoint app servers) don't need to be connected to the internet.
So all in all, make sure you publish your WFE's (using your load-balancer IP) and your Application (Non-SharePoint, through load-balancer).
The best way to do this is using a reverse proxy to publish your SharePoint and application servers. This means you only need 1 public IP address in this scenario.
If you need more guidance, let us know.
Nico Martens
SharePoint/Office365/Azure Consultant -
Excel Data Connection problem for posting Excel on SharePoint 2013
Hi there,
I tried to post an Excel file to a SharePoint 2013 site. The file has a column with VLOOKUP formula to look for data from another Excel file posted on the same site. However, once I open the file, it'll show the following message:
"We can't connect to '[link to file on onedrive/sharepoint]'. Please make sure you're using the correct
web address"
I don't recognize the website on this error message and there is no data linked to it. If I click OK, it'll show the following error message:
"Microsoft Excel cannot access the file '[link to file on onedrive/sharepoint]'. There are several possible reasons:
- The file name or path does not exist
- The file is being used by another program
- The workbook you are trying to save has the same name as a currently open workbook"
I tried to create another Library and post the file but it still shows me the same error message. I urgently need to fix this error as the file is viewed by several directors. Can someone help??? Thanks a lot!!Currently, when a workbook that contains a Data Model is published to a library in Office 365, data refresh is unavailable.
However, you can use a PowerShell script to configure a workaround.
donwload this white paper for workaround:
http://technet.microsoft.com/en-us/library/jj992650.aspx
Please remember to mark your question as answered &Vote helpful,if this solves/helps your problem. ****************************************************************************************** Thanks -WS MCITP(SharePoint 2010, 2013) Blog: http://wscheema.com/blog
Maybe you are looking for
-
Ok so I have an iPhone and an iPod which share the same iCloud/appleID. I did this today when I got my new iPhone I put in my iCloud details which put everything I had on my iPod onto my iPhone(I was unaware this happened). I'm happy with all the app
-
My ipod touch 4th gen won't pair with bluetooth audio receiver?
My ipod touch 4th gen won't pair with my aluratech istream universal bluetooth audio receiver. It automatically paired the first time I used it, but now will not pair. I removed the bluetooth receiver from the ipod because it kept saying make sure
-
Graph range problem with tab control
Hello. I am using LabVIEW 8.2.1 I have five XY-graphs in a tab control, with five tabs. One graph in each tab. When running, theese graphs is constantly written to, but the user is only allowed to watch one at a time. The program also contain a maxim
-
I want to have icons on my menu. I am using the Windows look and feel. On most native windows menus the icons appear in a separate column on the left. When I use icons in java menus they appear much too far to the right and the text doesn't align pro
-
Cannot view data on physical layer on Oracle BI administration tool
Hi everyone I have a schema1 and table1, table2, table3. I have connect in odbc using the schema username and password and it was successful. I can view the data using toad and sql oracle developer with schema username and password. I also import the