Quantcast
Channel: Exchange Server Development forum
Viewing all 7132 articles
Browse latest View live

EWS - Appointment Response type

$
0
0

Hi Team, 

We're using ews service for getting the appointments from exchange. We're checking a condition before proceeding with our functionality that the appointment object MyResponseType property is Organizer or not. The appointment was created and updated by one of our client who is using office 365 account. And now we have experienced an issue in binding the appointments to our system and when we analysed the issue in detail, we understand that some of the appointments MyResponseType property is "Unknown" ans since it is not invoking our further functionality. I will attach some of the code segments below. Kindly check the same and let us know your thoughts on the same. As I mentioned the following condition "if (appointment.MyResponseType == MeetingResponseType.Organizer)" is breaking our functionality. 

Microsoft.Exchange.WebServices.Data.ExchangeService service = new Microsoft.Exchange.WebServices.Data.ExchangeService(ExchangeVersion.Exchange2016); service.Url = new Uri("https://outlook.office365.com/ews/Exchange.asmx"); service.Credentials = new NetworkCredential(mailaddress, password); PropertySet propertySet = new PropertySet(PropertySet.FirstClassProperties.BasePropertySet, ItemSchema.MimeContent) { RequestedBodyType = BodyType.Text }; SearchFilter.IsGreaterThanOrEqualTo restrictionStartDate = new SearchFilter.IsGreaterThanOrEqualTo(AppointmentSchema.Start, startdate.Date); SearchFilter.IsGreaterThanOrEqualTo restrictionEndDate = new SearchFilter.IsGreaterThanOrEqualTo(AppointmentSchema.End, startdate.Date); SearchFilter.SearchFilterCollection restrictionAppointments = new SearchFilter.SearchFilterCollection(Microsoft.Exchange.WebServices.Data.LogicalOperator.Or); restrictionAppointments.Add(restrictionStartDate); restrictionAppointments.Add(restrictionEndDate); ItemView view = new ItemView(1000, 0, Microsoft.Exchange.WebServices.Data.OffsetBasePoint.Beginning); var calenderItems = service.FindItems(WellKnownFolderName.Calendar, restrictionAppointments, view); for (int i = 0; i < calenderItems.Items.Count; i++) { if (calenderItems.Items[i] is Microsoft.Exchange.WebServices.Data.Appointment) { ''' var appointment = (Microsoft.Exchange.WebServices.Data.Appointment)calenderItems.Items[i]; appointment = Microsoft.Exchange.WebServices.Data.Appointment.Bind(service, appointment.Id, propertySet); if (appointment.MyResponseType == MeetingResponseType.Organizer) { ... } } }


Online Backup of Outlook Emails

$
0
0

Dear Concern,

I would like to ask, I want to take back up of my outlook user, how much time it will take for back up if i am doing it online.

message reject

$
0
0

hello , 

 when i send an email from my outlook 2007 , i get a reject message "recipient address rejected user unknown in virtual mailbox table" i need a help how  to solve this issue .

thank you

Exchange 2016 and 2019 coexistence.

$
0
0

Hello everyone!

Currently we have Exchange 2016 in our organization and planning to migrate to Exchange 2019.

There are about 200 clients are using Outlook 2010 and it's impossible to upgrade them to newer Outlook version right now.

How can we set autodiscover for Outlook 2010 clients pointing to Exchange 2016, while all other users will be using Exchange 2019? It will be temporarily solution until upgrading Outlook 2010 to newer version.

Sincerely,

Friend

how to/example convert 'event sinks' from pre 2016 to EWS/EAS/REST?

$
0
0

Looks like the mapi/cdo library is not available anymore[2]. Does anyone have an example like in [1] using the EWS/EAS/REST?

UPDATE:
For instance a script/program that is being executed when a item is created (moved) to a public folder

[1]
https://books.google.pl/books?id=AjNFn8RDDKkC&lpg=PA362&ots=JbRD_IPViC&dq=exchange%202003%20public%20folder%20visual%20basic&pg=PA362#v=onepage&q=Sample%20Event%20Sinks&f=false

[2]
https://docs.microsoft.com/en-us/Exchange/new-features/discontinued-features?redirectedfrom=MSDN&view=exchserver-2019


ErrorSchemaValidation error at messages:ParentItemId when trying to add an attachment to an existing letter through EWS

$
0
0
I'm kind of at my wit's end here. Trying to use example SOAP packet from the docs (EWS operations -> CreateAttachment operation, with appropriate ids and all) and it's simply complaining that ParentItemId is not part of the messages namespace.

Can't create a message with attachments because of ErrorInvalidPropertySet either, what am I supposed to do?

Otlook Email Related

$
0
0
How to get Delivery Report of outlook Email

Will ews-java-api continue to work after Basic Authentication is deprecated?

$
0
0
We have internally developed systems that rely on the ews-java-api project written by Microsoft devs.  The project has gone quiet since July of 2018, understandably given the emphasis on moving to the new Graph API.  My question is does the ews-java-api project rely on Basic Authentication to authenticate to EWS?  Since Basic Auth is being disabled in Oct of this year, if the project relies on Basic Auth, then it will no longer work at all and neither will our internal systems.  But EWS itself, despite being deemphasized, is still a supported production environment.  So does that mean the ews-java-api will continue to work after Oct of this year, either because it doesn't rely on Baic Auth anyway or because there are plans to update it prior to October?

How to authenticate EWS client application (not using EWSManagedAPI, directly accessing EWS SOAP Services) by using OAuth

$
0
0
Hello,

I am using EWS Soap services from my application to do various outlook exchange operations. This is not using EWS Managed API. This works well.
Now, I am trying to add support of Exchange online with my existing application and trying to authenticate using OAuth. I got below sample to authenticate ews application by using OAuth but that is using EWS Managed API. I am not getting similar example for EWS client application. Can you please suggest how we can do that and if you can point to some example like below then it would be great help. 

*https://docs.microsoft.com/en-us/exchange/client-developer/exchange-web-services/how-to-authenticate-an-ews-application-by-using-oauth*


Thanks,

ManojPatel

Want to delete meeting from multiple selective recipient via CSV import in Powershell

$
0
0

I am trying to run this command but it says "Identity" Null.

============================================

PS C:\WINDOWS\system32> $Users = import-csv "C:\Users\Manish Mandot\Desktop\people.csv"
>> ForEach ($i in $Users) {
>> $Search = 'Subject: "' + $i.Subject + '"'
>> If ($i.StartDate -ne $Null -and $i.EndDate -ne $Null) {
>> $Search = $Search + ' Received:"' + $i.Startdate + '..'+ $i.Enddate + '"'}
>> $Command = { Search-Mailbox -Identity $i.Name -SearchQuery "Subject: Class 5th Hindi By Mr. Vijay Baghel Sir." -TargetFolder Search -TargetMailbox CServices -LogLevel Full }
>> Write-Host "Searching" $i.Name "using query" $Search
>> Invoke-Command -ScriptBlock $Command }
>>                                                                                                                                                                                                                                                                  Searching  using query Subject: ""
Cannot bind argument to parameter 'Identity' because it is null.
    + CategoryInfo          : InvalidData: (:) [Search-Mailbox], ParameterBindingValidationException
    + FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Search-Mailbox
    + PSComputerName        : ps.outlook.com

Set and Update Custom Attributes on Exchange Online Mailbox using REST APIs

$
0
0

Hi,

We are able to get / update Custom Attributes in Exchange Online Mailbox using Set-Mailbox cmdlet

Get-Mailbox -Identity "Astei@xyz.onmicrosoft.com" | FL customAttribute*

Set-Mailbox -Identity "rsapta@xyz.onmicrosoft.com" -CustomAttribute4 "Added using Script"

Is there a way to achieve the same objective (i.e get / update Custom Attributes on Mailbox) using a REST API call instead of using a PowerShell cmdlet.

Any pointers on this would be very helpful

Many thanks!

Best regards,

Removing currupt accepted domain

$
0
0

Hi, we are working on a project to migrate to office 365 services. In the process we noticed that Exchange Online functionality is almost completely broken. Whatever change we try to do with user mailboxes we receive an error telling that multiple domain names found for this query. In mail-flow -> accepted domain options we noticed two domains present:

1) some.domain.com

2) "some.domain.com CNF:5bb3b3d8-add9-48dd-a427-a163635b4204"

Exchange online does not allow removend this accpeted domains. And from Azure AD side in Custom Domain there is only "some.domain.com" available.

We use on-premises active directory testing environment with synchronization to cloud. When we try configure user settings in "Active Directory Users and Computers" we get two possible domains with the same name: "some.domain.com" to select.

While doing a search I found that CNF AD objects are created when conflicting object with same name are created on different ADC. But we have only one on-premises ADC server.  Also I am unable to find any object containing "CNF:5bb3b3d8-add9-48dd-a427-a163635b4204" through search on AD. Does anybody has an idea how this could have happened and how to solve this issue?







Where do I find Microsoft.Exchange.WebServices version 2.2.1.0

$
0
0
A former coworker was developing a tool to help us grab calendar event entries from on premise Exchange (2016 I believe) to put into our CMS.  At the moment I keep running into a compiler error saying:

ErrorCS0012 The type 'Appointment' is defined in an assembly that is not referenced. You must add a reference to assembly 'Microsoft.Exchange.WebServices, Version=2.2.1.0, Culture=neutral, PublicKeyToken=null'.

I
've checked NuGet and the latest seems to be 2.2.0  I'm not sure where this dependency is coming from.  The plan was to communicate using Exchange Web Services to use Exchange as our master scheduler and create an api feed that other apps could tie into to get latest calendar entries.  (mainly websites)


I am finding this to be extremely frustrating.  

Some things I have already tried:  1. Cleaning NuGet Cache, and searching for it.  2. Checking project dependencies are in order.     I've also tried things like dotnet restore and dotnet build commands in powershell to no effect.   


Any suggestions would be greatly appreciated.

Getting AccountIsLockedException

$
0
0

To All:

I have a VB.Net  app that I am expanding from searching the local Outlook Inbox (for emails within a date-range and from/to specific email addresses…which after several starts and stops…is working fine with Outlook) to a Server Folder via ExchangeService (for messages older than 30 days…which I really need to access).

I have setup my test program to access it, but I’m receiving an AccountIsLockedException: This account is locked. Visit http://technet.microsoft.com/en-us/library/dn270518.aspx#howapppassword to unlock it.

I thought that I just had to treat this like other OAuth code that I previously used to access other non-MS accounts: Google, Dropbox, SoundCloud, etc. where I opened up a WebBrowser control with an OAuth Url and waited until I received the correct response and then stored the token returned in WebBrowser.Document to use later in the code.

Apparently…this isn’t the case, or it is…and I’m missing the point.

Here is the code that I’m working on:

Dim myExchangeService As New ExchangeService
Dim strURL As String = mpnNamespace.ExchangeMailboxServerName
myExchangeService.Credentials = New WebCredentials("<EMailAddress>", "<Password>")
myExchangeService.UseDefaultCredentials = False
myExchangeService.Url = New Uri(strURL)
Try
	myExchangeService.AutodiscoverUrl(mpnNamespace.Accounts(1).DisplayName, AddressOf fncRedirectionCallback)
Catch ex As AccountIsLockedException 			
	Debug.Print("AccountIsLockedException: " & ex.AccountUnlockUrl.ToString)
	Form2.SetRedirectionCallbackUrl = ex.AccountUnlockUrl.ToString
	Form2.ShowDialog()
	Form2.Dispose()
End Try

where Form2 contains the WebBrowser control.

Even though I’m able to logon to my account within the WebBrowser of Form2 (and use my cellphone for Microsoft Verification)…I don’t have a clue as to how to grant access to my vb.net app while it’s executing.

It does send: https://webshell.suite.office.com/iframe/TokenFactoryIframe?origin= &shsid= &apiver=oneshell&cshver=20200525.1

But I’m not sure what these tokens are and if they’re somehow supposed to be included in the next part of the process.

It also accesses:
https://webdir.online.lync.com/xframe
https://webdir1b.online.lync.com/Autodiscover/XFrame/XFrame.html#

https://webdir3a.online.lync.com/Autodiscover/AutodiscoverService.svc/root/xframe
https://webdir3a.online.lync.com/Autodiscover/XFrame/XFrame.html#
https://webdir3a.online.lync.com/Autodiscover/XFrame/XFrame.html#
https://webpoolsn23a13.infra.lync.com/Autodiscover/XFrame/XFrame.html#


After the form closes, it proceeds to the next stage, which is to build the Search Parameters (this comes from a well known example from MS):

Dim allFoldersType As ExtendedPropertyDefinition = New ExtendedPropertyDefinition(13825, MapiPropertyType.Integer)
Dim rootFolderId As FolderId = New FolderId(WellKnownFolderName.Root)
Dim folderView As FolderView = New FolderView(1000)
		folderView.Traversal = FolderTraversal.Shallow

Dim searchFilter1 As SearchFilter = New SearchFilter.IsEqualTo(allFoldersType, "2")
Dim searchFilter2 As SearchFilter = New SearchFilter.IsEqualTo(FolderSchema.DisplayName, "allitems")

Dim searchFilterCollection1 As SearchFilter.SearchFilterCollection = New SearchFilter.SearchFilterCollection(LogicalOperator.[And])
		searchFilterCollection1.Add(searchFilter1)
searchFilterCollection1.Add(searchFilter2)
Dim FoldersResults As FindFoldersResults
Try
	FoldersResults = myExchangeService.FindFolders(MailboxToAccess, searchFilterCollection1, folderView)
Catch ex As AccountIsLockedException
	Debug.Print("AccountIsLockedException: " & ex.Message)
End Try
It still trips the AccountIsLockedException, at this point…so I’m back to step 1.

Any suggestions would be greatly appreciated.

Thank you in advance for your time.

Paul Goldstein


Paul D. Goldstein Forceware Systems, Inc.

Application is over its MailboxConcurrency limit issue

$
0
0
Hi All,

We  have integrated our application with MS exchange online using graph api and while doing automation tests my tester created 500 draft emails messages every 15 min and ran test for 2 hr. We see response for this api call as  below error but Emails got created in the back end successfully . Any one has faced this issue ?  I dint find any  helpful text in limitations regarding Mail Box concurrency limit in official docs.  I found this link https://itconnect.uw.edu/connect/email/exchange-online/tips-tricks/limits-of-uw-exchange-online/ which mentions limit as 32. 

” {"status":429,"body":{"code":"ApplicationThrottled","message":"Application is over its MailboxConcurrency limit.","innerError":{"request-id":"473b75cc-e854-4ba6-b94f-e51d62e5fdaa","date":"2020-06-09T12:01:01"}}}

Sending Email from On-Prem Exchange 2019 with EWS Api

$
0
0

Good day,

     I have run into an issue that could either be an incorrect setup of Exchange or the code that I am using, but cannot determine which is wrong.  I am trying to send an email from an Exchange email account from an Asp.Net Core application.  The AutodiscoverConfiguration Request and Response are showing the correct trace information.  The EWS Request is showing the correct trace information, but the EWS Response does not.

Here is the output of the EWSResponseHttpHeaders:

<?xml version="1.0" encoding="utf-16"?><Trace Tag="EwsResponseHttpHeaders" Tid="13" Time="2020-06-05 15:28:01Z">
HTTP/1.1 200 OK
Cache-Control: no-store, no-cache
Pragma: no-cache
Server: Microsoft-IIS/10.0
request-id: d78a4945-e42f-4013-b078-c29b82b24e9e
X-Frame-Options: SAMEORIGIN
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Fri, 05 Jun 2020 15:28:00 GMT
Content-Type: text/html; charset=utf-8
Expires: -1
Content-Length: 58732</Trace>

Here is the output of the EWSResponse:

System.IO.MemoryStream


Here is the output of the EWSRequest:

<?xml version="1.0" encoding="utf-16"?><Trace Tag="EwsRequest" Tid="9" Time="2020-06-05 15:28:00Z" Version="15.0.913.15"><soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Header><t:RequestServerVersion Version="Exchange2016" /><t:ExchangeImpersonation><t:ConnectingSID><t:SmtpAddress>Administrator@mydomain.com</t:SmtpAddress></t:ConnectingSID></t:ExchangeImpersonation></soap:Header><soap:Body><m:CreateItem MessageDisposition="SendAndSaveCopy"><m:SavedItemFolderId><t:DistinguishedFolderId Id="sentitems" /></m:SavedItemFolderId><m:Items><t:Message><t:Subject>Test email from Controller</t:Subject><t:Body BodyType="HTML">This is a test email being sent from the Weather Forcast Controller on Get</t:Body><t:ToRecipients><t:Mailbox><t:EmailAddress>myuser@gmail.com</t:EmailAddress></t:Mailbox></t:ToRecipients><t:From><t:Mailbox><t:EmailAddress>Administrator@mydomain.com</t:EmailAddress></t:Mailbox></t:From></t:Message></m:Items></m:CreateItem></soap:Body></soap:Envelope></Trace>

Here is my SendEmail code: 

public class ExchangeEmailSender : IExchangeEmailSender
    {
        private readonly EmailConfiguration _emailConfiguration;

        //private readonly ExchangeService _service = new ExchangeService(ExchangeVersion.Exchange2016);

        //Construct with the readonly of configuration, which will be passed in on setup.
        public ExchangeEmailSender(EmailConfiguration emailConfiguration)
        {            
            _emailConfiguration = emailConfiguration;
        }

        //Takes an instance of ExchangeMessage(IEnumerable<string> mailTo, string subject, string content)
        public virtual string SendEmail(ExchangeMessage message)
        {
            //Get a message to send
            var emailMessage = CreateEmailMessage(message);

            //Send email
            emailMessage.SendAndSaveCopy();

            var result = "An email with the subject '" + emailMessage.Subject + "' has been sent to the following recipients '" + emailMessage.ToRecipients[0] + "'.";

            return result;
        }               

        //Takes an instance of ExchangeMessage(IEnumerable<string> mailTo, string subject, string content)
        private EmailMessage CreateEmailMessage(ExchangeMessage message)
        {
            //Get the user sending the email
            var user = _emailConfiguration.From;
            var password = _emailConfiguration.Password;
            var domain = "mydomain";

            //Initiate the service for Exchange
            var service = new ExchangeService(ExchangeVersion.Exchange2016)
            {
                Credentials = new NetworkCredential(user, password, domain),
                ImpersonatedUserId = new ImpersonatedUserId(ConnectingIdType.SmtpAddress, "Administrator@mydomain.com"),
                UseDefaultCredentials = true,
                TraceListener = new ExchangeTraceListener(),
                TraceEnabled = true,
                TraceFlags = TraceFlags.All
            };

            //Pass in the user that is sending
            service.AutodiscoverUrl(user, URLRedirection.RedirectionUrlValidationCallBack);

            Folder.Bind(service, WellKnownFolderName.SentItems);

            //Create a new EmailMessage to send using the service
            var emailMessage = new EmailMessage(service);
            emailMessage.From = new EmailAddress();
            emailMessage.From.Address = user;
            emailMessage.ToRecipients.AddRange(message.MailTo);
            emailMessage.Subject = message.Subject;
            emailMessage.Body = new TextBody() { Text = message.Content };

            //Pass the message back to where it is called from
            return emailMessage;
        }        
    }

Here is how it is being used in the controller:   

[ApiController]
    [Route("[controller]")]
    public class WeatherForecastController : ControllerBase
    {
        private static readonly string[] Summaries = new[]
        {"Freezing", "Bracing", "Chilly", "Cool", "Mild", "Warm", "Balmy", "Hot", "Sweltering", "Scorching"
        };
        private readonly ILogger<WeatherForecastController> _logger;
        private readonly IExchangeEmailSender _exchangeEmailSender;

        public WeatherForecastController(ILogger<WeatherForecastController> logger, IExchangeEmailSender exchangeEmailSender)
        {
            _logger = logger;
            _exchangeEmailSender = exchangeEmailSender;
        }

        [HttpPost]
        public async Task<IEnumerable<WeatherForecast>> Post()
        {
            var rng = new Random();

            var message = new ExchangeMessage(new string[] { "myuser@gmail.com" }, "Test email from Controller", "This is a test email being sent from the Weather Forcast Controller on Get");
            _exchangeEmailSender.SendEmail(message);

            return Enumerable.Range(1, 5).Select(index => new WeatherForecast
            {
                Date = DateTime.Now.AddDays(index),
                TemperatureC = rng.Next(-20, 55),
                Summary = Summaries[rng.Next(Summaries.Length)]
            })
            .ToArray();
        }
    }

Now it looks like everything is working as Postman is giving a 200 Ok on Post, but I know it is not sending the email and it is not placing it in the sent items folder.  I also do have the following rule set up in Exchange:   

Get-ManagementRoleAssignment -RoleAssignee "IdentityImpersonation" | fl


RunspaceId                   : 570467f1-adeb-4888-882c-9158e7435495
DataObject                   : ApplicationImpersonation-IdentityImpersonation
User                         : mydomain.com/Microsoft Exchange Security Groups/IdentityImpersonation
AssignmentMethod             : Direct
Identity                     : ApplicationImpersonation-IdentityImpersonation
EffectiveUserName            : All Group Members
AssignmentChain              :
RoleAssigneeType             : RoleGroup
RoleAssignee                 : mydomain.com/Microsoft Exchange Security Groups/IdentityImpersonation
Role                         : ApplicationImpersonation
RoleAssignmentDelegationType : Regular
CustomRecipientWriteScope    :
CustomConfigWriteScope       :
RecipientReadScope           : Organization
ConfigReadScope              : None
RecipientWriteScope          : Organization
ConfigWriteScope             : None
Enabled                      : True
RoleAssigneeName             : IdentityImpersonation
IsValid                      : True
ExchangeVersion              : 0.11 (14.0.550.0)
Name                         : ApplicationImpersonation-IdentityImpersonation
DistinguishedName            : CN=ApplicationImpersonation-IdentityImpersonation,CN=Role Assignments,CN=RBAC,CN=My Domain
                               ,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=MyDomain,DC=com
Guid                         : a3df5cb9-9e34-48c5-82b0-d3f221e50387
ObjectCategory               : Mydomain.com/Configuration/Schema/ms-Exch-Role-Assignment
ObjectClass                  : {top, msExchRoleAssignment}
WhenChanged                  : 6/5/2020 8:33:37 AM
WhenCreated                  : 6/5/2020 8:33:16 AM
WhenChangedUTC               : 6/5/2020 12:33:37 PM
WhenCreatedUTC               : 6/5/2020 12:33:16 PM
OrganizationId               :
Id                           : ApplicationImpersonation-IdentityImpersonation
OriginatingServer            : DC2.mydomain.com
ObjectState                  : Unchanged

This shows Members as Administrator.   

For my Exchange Web Services I am using the following from Nuget:  Microsoft.Exchange.WebServices.NETStandard version 1.1.3 ().  So I do not know where I have gone wrong, anyone have any thoughts as to why it is not sending an email?

 


Michael R. Mastro II

how to hide content below when using EWS to create meeting

$
0
0

 

When: Monday, February 25, 2013 7:21 PM-7:45 PM. UTC
Where: Edge Hall
~~*~*~*~*~*~*~*~*

Create calendar fails when color property is MaxColor

$
0
0

Hi Team,

I am integrating my app with Exchange online plan1 through Graph api's. We found strange issue where in if we create Calendar with property 'color' with value 'MaxColor'  we get error 500 An internal server error occurred. The operation failed.

Any idea why API behaves this way ? 


Internal Server Error (500) while calling Exchange Web Service for ExchangeOnline.

$
0
0

Hello,

I am trying to do various exchange operations (e.g get folder info or send email) using Exchange Web Services with exchange online (https://outlook.office365.com/EWS/Exchange.asmx) however, getting internal server error (500).

If I try same operations using EWSManagedAPI then it works fine. I have tried to make my request exactly similar to what xml request gets post using EWSManagedAPI but still same issue. 

Below i have added my code. Can you please take a look and suggest what could be wrong ? And what would be the best way to troubleshoot exact issue with web request.

/// This is the XML request that is sent to the Exchange server.
            var getFolderSOAPRequest ="<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +"<soap:Envelope xmlns:soap=\"https://schemas.xmlsoap.org/soap/envelope/\"\n" +"   xmlns:t=\"https://schemas.microsoft.com/exchange/services/2006/types\">\n" +"<soap:Header>\n" +"    <t:RequestServerVersion Version=\"Exchange2013_SP1\" />\n" +"    <t:ExchangeImpersonation>\n" +"     <t:ConnectingSID>\n" +"       <t:SmtpAddress>m.p@alpha.com</t:SmtpAddress> \n" +"     </t:ConnectingSID>\n" +"    </t:ExchangeImpersonation> \n" +"  </soap:Header>\n" +"  <soap:Body>\n" +"    <GetFolder xmlns=\"https://schemas.microsoft.com/exchange/services/2006/messages\"\n" +"               xmlns:t=\"https://schemas.microsoft.com/exchange/services/2006/types\">\n" +"      <FolderShape>\n" +"        <t:BaseShape>Default</t:BaseShape>\n" +"      </FolderShape>\n" +"      <FolderIds>\n" +"        <t:DistinguishedFolderId Id=\"inbox\"/>\n" +"      </FolderIds>\n" +"    </GetFolder>\n" +"  </soap:Body>\n" +"</soap:Envelope>\n";

//Add all the headers

// Write the get folder operation request to the console and log file. Tracing.WriteLine("Get folder operation request:"); Tracing.WriteLine(getFolderSOAPRequest); var getFolderRequest = WebRequest.CreateHttp(Office365WebServicesURL); getFolderRequest.Method = "POST"; getFolderRequest.ContentType = "text/xml; charset=utf-8"; getFolderRequest.Accept = "text/xml"; getFolderRequest.UserAgent = "ExchangeServicesClient/15.00.0847.030"; getFolderRequest.AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate; getFolderRequest.Headers.Add("X-AnchorMailbox", "m.p@alpha.com"); getFolderRequest.Headers.Add("Authorization", "Bearer " + accessToken)


try { var requestWriter = new StreamWriter(getFolderRequest.GetRequestStream()); requestWriter.Write(getFolderSOAPRequest); requestWriter.Close(); var getFolderResponse = (HttpWebResponse)(getFolderRequest.GetResponse()); if (getFolderResponse.StatusCode == HttpStatusCode.OK) { } } catch (WebException ex) {

//getting Internal Server Error (500) Tracing.WriteLine("Caught Web exception:"); Tracing.WriteLine(ex.Message); }


Thanks,


ManojPatel

Graph API will still be able to support Exchange 2013 and above in Office 365

$
0
0

Hi 

Does the Microsoft Graph API will  be able to support Exchange 2013 and above in Office 365, Cloud, third party cloud (like GoDaddy, Network Solutions, etc.) and on-premise installations. Will be really helpful if you could help me with this. Thanks

Viewing all 7132 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>