none
Is it possible to save all Lync Users conversation history by using Administrator EWS account. RRS feed

  • Question

  • I am developing a application, in that am integrating Lync Client by using Lync SDK & EWS. Currently am saving the Lync User conversation history by invoking EWS web-service by giving username,password& domain name. Is it possible to save all Lync users Conversation History by using EWS Administrator account??
    Wednesday, October 12, 2016 10:58 AM

All replies

  • You can do it with any account that has access the mailbox folder in question. The Administrator account makes no difference as Administrator don't have access to mailbox content unless they are specially granted access by the user (eg using Outlook) or they give themselves rights to the Mailbox via Add-MailboxPermission or Add-MailboxFolderPermission. The other option is to use EWS impersonation see https://msdn.microsoft.com/en-us/library/office/dn722377(v=exchg.150).aspx (Also as a best practice thing don't use the Administrator account for doing this is better to create a service account and assigned it the rights you need).

    Cheers
    Glen

    Thursday, October 13, 2016 1:52 AM
  • Thanks Glen for answer. As i mentioned through EWS am pointing to Conversation History folder in outlook & fetching required conversations [reference link : https://msdn.microsoft.com/en-us/library/office/hh243707(v=office.14).aspx]. My doubt is through single EWS Administrator account whether we can able to fetch all other Lync users Conversations by invoking this EWS Web-Service. 
    Thursday, October 13, 2016 5:52 AM
  • >>My doubt is through single EWS Administrator account whether we can able to fetch all other Lync users Conversations by invoking this EWS Web-Service.

    You have to access each Mailbox individually and you need to have rights to each users conversation folder you want to access via EWS which you won't have by default not matter if its Administrator or not.

    For that example you point to you would need to change the code to use the FolderId overload to specify the mailbox you want to acesss eg

    FindFoldersResults findFolderResults = service.FindFolders(WellKnownFolderName.MsgFolderRoot, view);
    

    would need to become

    FolderId FolderToAccess = new FolderId(WellKnownFolderName.MsgFolderRoot, "MailboxToAccess@domain.com");
    FindFoldersResults findFolderResults = service.FindFolders(FolderToAccess, view);

    Etc for all instance this is used

    You can test this without using any code by using the EWSEditor and trying to bind to another user lync Conversation folder. If you have questions around code then you need to be more specific and post the code your trying to use and the error your getting and then somebody can explain why that's happening.

    Cheers
    Glen

     
    Friday, October 14, 2016 12:42 AM