4.5 Search for a Rights-Managed E-Mail Message by Using the Search Command

To search for a rights-managed e-mail message, the client sends the Search command and sets the RightsManagementSupport element to TRUE.

The response includes the rights-managed e-mail message.

Request

 <?xml version="1.0" encoding="utf-8"?>
 <Search xmlns:airsyncbase="AirSync:" xmlns:airsyncbase="AirSyncBase:" xmlns:rm="RightsManagement:" xmlns="Search:">
   <Store>
     <Name>Mailbox</Name>
     <Query>
       <And>
         <airsyncbase:CollectionId>5</airsyncbase:CollectionId>
         <FreeText>IRMEAS</FreeText>
         <airsyncbase:Class>Email</airsyncbase:Class>
       </And>
     </Query>
     <Options>
       <Range>0-0</Range>
       <RebuildResults/>
       <DeepTraversal/>
       <airsyncbase:BodyPreference>
         <airsyncbase:Type>1</airsyncbase:Type>
         <airsyncbase:TruncationSize>512</airsyncbase:TruncationSize>
       </airsyncbase:BodyPreference>
       <rm:RightsManagementSupport>1</rm:RightsManagementSupport>
     </Options>
   </Store>
 </Search>

Response

 <?xml version="1.0" encoding="utf-8"?>
 <Search xmlns:airsyncbase="AirSync:" xmlns:email="Email:" xmlns:airsyncbase="AirSyncBase:" xmlns:email2="Email2:" xmlns:rm="RightsManagement:" xmlns="Search:">
   <Status>1</Status>
   <Response>
     <Store>
       <Status>1</Status>
       <Result>
         <airsyncbase:Class>Email</airsyncbase:Class>
         <LongId>RgAAAAC56adCCdvKRYRrNA1IgBolBwB%2bSy6NhndsQ7ldDXB%2fCAqQAAAAbHbTAAB%2bSy6NhndsQ7ldDXB%2fCAqQAAAAbJ5XAAAJ</LongId>
         <airsyncbase:CollectionId>5</airsyncbase:CollectionId>
         <Properties>
           <email:To>"T0SyncUser3" &lt;T0SyncUser3@contoso.com&gt;</email:To>
           <email:From>"T0SyncUser1" &lt;T0SyncUser1@contoso.com&gt;</email:From>
           <email:Subject>DoNotForward</email:Subject>
           <email:DateReceived>2010-06-30T23:52:51.908Z</email:DateReceived>
           <email:DisplayTo>T0SyncUser3</email:DisplayTo>
           <email:ThreadTopic>DoNotForward</email:ThreadTopic>
           <email:Importance>1</email:Importance>
           <email:Read>0</email:Read>
           <airsyncbase:Body>
             <airsyncbase:Type>1</airsyncbase:Type>
             <airsyncbase:EstimatedDataSize>64</airsyncbase:EstimatedDataSize>
             <airsyncbase:Data>This is a test message that we want to use.</airsyncbase:Data>
           </airsyncbase:Body>
           <email:MessageClass>IPM.Note</email:MessageClass>
           <email:InternetCPID>28591</email:InternetCPID>
           <email:Flag />
           <email:ContentClass>urn:content-classes:message</email:ContentClass>
           <airsyncbase:NativeBodyType>1</airsyncbase:NativeBodyType>
           <email2:ConversationId>…</email2:ConversationId>
           <email2:ConversationIndex>…</email2:ConversationIndex>
           <email:Categories />
           <rm:RightsManagementLicense>
             <rm:Owner>0</rm:Owner>
             <rm:ContentOwner>T0SyncUser1@contoso.com</rm:ContentOwner>
             <rm:ReplyAllAllowed>1</rm:ReplyAllAllowed>
             <rm:EditAllowed>1</rm:EditAllowed>
             <rm:ReplyAllowed>1</rm:ReplyAllowed>
             <rm:ForwardAllowed>0</rm:ForwardAllowed>
             <rm:ExportAllowed>0</rm:ExportAllowed>
             <rm:ModifyRecipientsAllowed>0</rm:ModifyRecipientsAllowed>
             <rm:TemplateID>cf5cf348-a8d7-40d5-91ef-a600b88a395d</rm:TemplateID>
             <rm:ExtractAllowed>0</rm:ExtractAllowed>
             <rm:TemplateDescription>Recipients can read this message, but they can't forward, print, or copy content. The conversation owner has full permission to their message and all replies.</rm:TemplateDescription>
             <rm:ContentExpiryDate>9999-12-30T23:59:59.999Z</rm:ContentExpiryDate>
             <rm:TemplateName>Do Not Forward</rm:TemplateName>
             <rm:PrintAllowed>0</rm:PrintAllowed>
             <rm:ProgrammaticAccessAllowed>0</rm:ProgrammaticAccessAllowed>
           </rm:RightsManagementLicense>
           <email2:IsDraft>0</email2:IsDraft>
         </Properties>
       </Result>
       <Range>0-0</Range>
       <Total>1</Total>
     </Store>
   </Response>
 </Search>
Show: