NAME
Email::Folder::Exchange::EWS - Email::Folder access to exchange folders via Web Services [SOAP]
SYNOPSIS
use Email::Folder::Exchange::EWS;
my $folder = Email::Folder::Exchange::EWS->new('http://owa.myorg.com', 'user', 'password');
for my $message ($folder->messages) {
print "subject: " . $subject->header('Subject');
}
for my $folder ($folder->folders) {
print "folder uri: " . $folder->uri->as_string;
print " contains " . scalar($folder->messages) . " messages";
print " contains " . scalar($folder->folders) . " folders";
}
DESCRIPTION
Add access to Microsoft Exchange to Email::Folder. Contains API enhancements to allow folder browsing.
new($url, [$username, $password])
Create Email::Folder::Exchange::EWS object and login to OWA site.
- url
-
URL of the main OWA site, usually in the form of "https://owa.myorg.com"
- username
-
Username to authenticate as. Generally in the form of 'domain\username'. Overrides URL-supplied username if given.
- password
-
Password to authenticate with. Overrides URL-supplied password.
messages()
Return a list containing all of the messages in the folder. Can only be called once as it drains the iterator.
next_message()
Return next message as Email::Simple object from folder. Acts as iterator. Returns undef at end of folder contents.
folders()
Return a list of Email::Folder::Exchange objects contained within base folder. Can only be called once as it drains the iterator.
next_folder()
Return next folder under base folder as Email::Folder::Exchange object. Acts as iterator. Returns undef at end of list.
uri()
Return URI locator object for current folder.
soap()
Returns SOAP::Lite underlying SOAP object for custom queries.
folder_id()
Returns Exchange binary folder ID
display_name()
Returns folder's user-friendly display name
child_folder_count()
Returns the number of child folders
unread_count()
Returns the number of unread messages in the current folder.
total_count()
Returns the number of messages in the current folder.
CAVEATS
Can't locate object method "new" via package "LWP::Protocol::https::Socket"
Install the Crypt::SSLeay module in order to support SSL URLs
The server cannot service this request right now. Try again later.
This error indicates the mailbox is has too many messages or the specified message is too large to retrieve via web services.
SEE ALSO
Email::Folder::Exchange, Email::Folder, URI, Email::Simple, Crypt::SSLeay
AUTHOR
Warren Smith <lt>wsmith@cpan.org<gt>
COPYRIGHT AND LICENSE
Copyright (C) 2011 by Warren Smith
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.4 or, at your option, any later version of Perl 5 you may have available.