exchangewebservices

Python/exchangelib - How to access shared public folders and calendars

烂漫一生 提交于 2019-12-10 11:42:23
问题 How can I connect to a shared public folder using exchangelib? from exchangelib import DELEGATE, IMPERSONATION, Account, Credentials, ServiceAccount, \ EWSDateTime, EWSTimeZone, Configuration, NTLM, CalendarItem, Message, \ Mailbox, Attendee, Q, ExtendedProperty, FileAttachment, ItemAttachment, \ HTMLBody, Build, Version credentials = Credentials(username='DOMAIN\\username', password='password') config = Configuration(server='server', credentials=credentials, auth_type=NTLM, verify_ssl=False)

PHP-EWS “Soap client returned status of 404”

心不动则不痛 提交于 2019-12-10 11:17:20
问题 So, I'm using php-ews library to connect to my Microsoft Office 365 Exchange Email account to read emails. I've connected successfully to it and I have managed to retrieve a list of emails that I need. Now the problem is that I cannot get message body. Reading documentation about Exchange Web Services it says that body cannot be fetched with FindItem(), only with GetItem(), and that's okay. Now the problem I'm seeing is following: I tried all possible examples I could find about this, and the

How do I get the real email address with Exchange web services?

柔情痞子 提交于 2019-12-10 10:23:45
问题 I am trying to get the real email address of the sender of an email using Exchange web services, however the mailitem.Sender.Address contains something like - /O=EXCHANGELABS/OU=EXCHANGE ADMINISTRATIVE GROUP (...........)/CN=RECIPIENTS/CN=...........-..... How can I get to the real email address of the sender of this email? My code: Dim sf As SearchFilter = New SearchFilter.SearchFilterCollection(LogicalOperator.And, New SearchFilter.IsEqualTo(EmailMessageSchema.IsRead, False)) Dim

EWS SearchFilter.ContainsSubstring to filter on Sender Email Address

纵然是瞬间 提交于 2019-12-10 10:19:24
问题 I'm trying to filter emails on Exchange Web Services using SearchFilter.ContainsSubstring as follows: sfilter = New SearchFilter.ContainsSubstring(EmailMessageSchema.Sender, EmailAddress, ContainmentMode.Substring, ComparisonMode.IgnoreCase) MailItems = service.FindItems(Folder.Id, sfilter, view) Unfortunately this doesn't work, and I don't want to use Queries, because I can't guarantee that I can use features of Exchange Server 2013. Composing a variety of requests in Fiddler, I can observe

exchange web service error - the remote server returned an error 405 method not allowed

。_饼干妹妹 提交于 2019-12-10 03:59:45
问题 I'm trying to send a mail via the exchange web service. I looked into the msdn and find some help. Every time I try to run this code i'm getting the above error :( I try read almost everywhere... ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010); service.Credentials = new WebCredentials("My user name", "my pass"); System.Net.ServicePointManager.ServerCertificateValidationCallback = ((sender, certificate, chain, sslPolicyErrors) => true); service.Url = new Uri("my web

Download attachments using Exchange Web Services Java API?

*爱你&永不变心* 提交于 2019-12-10 03:57:54
问题 I am writing a Java application to download emails using Exchange Web Services. I am using Microsoft's ewsjava API for doing this. I am able to fetch email headers. But, I am not able to download email attachments using this API. Below is the code snippet. FolderId folderId = new FolderId(WellKnownFolderName.Inbox, "mailbox@example.com"); findResults = service.findItems(folderId, view); for(Item item : findResults.getItems()) { if (item.getHasAttachments()) { AttachmentCollection

How to force garbage collection of object you can't dereference?

江枫思渺然 提交于 2019-12-10 02:32:09
问题 We are using EWS Managed API which polls MS Exchange for new mail messages after a given interval. With each invocation of the polling call ( PullSubscription.GetEvents() ) - Microsofts API is failing to properly dispose the NetworkStream and causes memory to proportionately increase. This was previously discussed here, but never resolved. Using ANTS Profiler we were able to determine which objects were continuously growing in memory and isolate the issue. Now that the issue has been isolated

Exchange EWS not returning message body for calendar

南笙酒味 提交于 2019-12-09 19:18:42
问题 So i'm trying to fetch all the calendar event from office360.com . I am using ews to get the data. I sent a request of <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"> <soap:Body> <FindItem xmlns="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" Traversal="Shallow"> <ItemShape> <t

Slow search for items using extended property on Exchange

核能气质少年 提交于 2019-12-09 12:14:27
问题 Problem at hand Our C# Windows application uses EWS Managed API 2.0 to create appointments in a user's calendar. Each appointment has an extended property with a unique value. It later locates an appointment using FindItems and an ItemView. Users experience significant delays the first time this search is performed. Subsequent response times are entirely acceptable. ("first time" is a little vague here, because users may experience the delay again later in the day) // locate ID of appointment

How to to print mail body and subject from unread answer?

南笙酒味 提交于 2019-12-09 01:47:45
问题 I want to get the mail subject and body of only unread mails of my inbox. I want to read one unread mail at a time and mark it as read afterwards. I need the subject , from address and mail body . The below code shows gives me the mail IDs of all unread mails. require_once ('../mail3/php-ews-master/ExchangeWebServices.php'); require_once ('../mail3/php-ews-master/EWS_Exception.php'); require_once ('../mail3/php-ews-master/EWSType.php'); require_once ('../mail3/php-ews-master/NTLMSoapClient