How to get OOF text from Exchange 2003 using WebDAV

You may be able to get OOF text with WebDAV using a SEARCH.  However, its not supported in any way and there is no guarentee that it will always work.  The OOF text is stored inside of a hidden item in a mailbox.  Below is a sample of the request which is for educational purposes only.  Please note that modifying hidden items in a mailbox which your application does not own can cause corruption of items and such corruption could cuase servere issues with Outlook, OWA and activesync devices.

<?xml version='1.0'?> 

<D:searchrequest xmlns:D='DAV:'> 

  <D:sql>SELECT 

      "urn:schemas:httpmail:textdescription" ,

      "DAV:creationdate"

  FROM SCOPE ( 'SHALLOW TRAVERSAL OF "https://my2003server/exchange/administrator/Inbox/"' ) 

  WHERE ("DAV:isfolder"= FALSE) AND  ("https://schemas.microsoft.com/exchange/outlookmessageclass" like '%IPM.Note.Rules.OofTemplate.Microsoft%') 

  </D:sql>

</D:searchrequest>

 

Here is a sample response:

<?xml version="1.0"?>
<a:multistatus xmlns:b="urn:uuid:c2f41010-65b3-11d1-a29f-00aa00c14882/" xmlns:d="urn:schemas:httpmail:" xmlns:c="xml:" xmlns:a="DAV:">
  <a:response>
    <a:href>https://my2003server/exchange/administrator/Inbox/Out%20of%20Office%20AutoReply:%20test-2.EML</a:href>
      <a:propstat>
      <a:status>HTTP/1.1 200 OK</a:status>
      <a:prop>
        <d:textdescription>I was out of office but now i am back!</d:textdescription>
        <a:creationdate b:dt="dateTime.tz">2012-10-22T18:36:39.208Z</a:creationdate>
      </a:prop>
    </a:propstat>
  </a:response>
  <a:response>
    <a:href>https://my2003server/exchange/administrator/Inbox/Out%20of%20Office%20AutoReply:%20test.EML</a:href>
    <a:propstat>
      <a:status>HTTP/1.1 200 OK</a:status>
      <a:prop>
        <d:textdescription>I am out of office</d:textdescription>
        <a:creationdate b:dt="dateTime.tz">2012-10-22T18:00:31.936Z</a:creationdate>
      </a:prop>
    </a:propstat>
  </a:response>
  <a:response>
    <a:href>https://my2003server/exchange/administrator/Inbox/No%20Subject-3.EML</a:href>
    <a:propstat>
      <a:status>HTTP/1.1 200 OK</a:status>
      <a:prop>
        <d:textdescription>I was out of office but now i am back for the third time!!!</d:textdescription>
        <a:creationdate b:dt="dateTime.tz">2012-10-22T18:00:17.717Z</a:creationdate>
      </a:prop>
    </a:propstat>
  </a:response>
</a:multistatus>