Class ExchangeService
- Namespace
- Microsoft.Exchange.WebServices.Data
- Assembly
- Microsoft.Exchange.WebServices.dll
Represents a binding to the Exchange Web Services.
public sealed class ExchangeService : ExchangeServiceBase
- Inheritance
-
ExchangeService
- Inherited Members
Constructors
ExchangeService()
Initializes a new instance of the ExchangeService class, targeting the latest supported version of EWS and scoped to the system's current time zone.
public ExchangeService()
ExchangeService(ExchangeVersion)
Initializes a new instance of the ExchangeService class, targeting the specified version of EWS and scoped to the system's current time zone.
public ExchangeService(ExchangeVersion requestedServerVersion)
Parameters
requestedServerVersionExchangeVersionThe version of EWS that the service targets.
ExchangeService(ExchangeVersion, TimeZoneInfo)
Initializes a new instance of the ExchangeService class, targeting the specified version of EWS and scoped to the specified time zone.
public ExchangeService(ExchangeVersion requestedServerVersion, TimeZoneInfo timeZone)
Parameters
requestedServerVersionExchangeVersionThe version of EWS that the service targets.
timeZoneTimeZoneInfoThe time zone to which the service is scoped.
ExchangeService(TimeZoneInfo)
Initializes a new instance of the ExchangeService class, targeting the latest supported version of EWS and scoped to the specified time zone.
public ExchangeService(TimeZoneInfo timeZone)
Parameters
timeZoneTimeZoneInfoThe time zone to which the service is scoped.
Properties
DateTimePrecision
Gets or sets the DateTime precision for DateTime values returned from Exchange Web Services.
public DateTimePrecision DateTimePrecision { get; set; }
Property Value
EnableScpLookup
Gets or sets a value indicating whether the AutodiscoverUrl method should perform SCP (Service Connection Point) record lookup when determining the Autodiscover service URL.
public bool EnableScpLookup { get; set; }
Property Value
FileAttachmentContentHandler
Gets or sets a file attachment content handler.
public IFileAttachmentContentHandler FileAttachmentContentHandler { get; set; }
Property Value
ImpersonatedUserId
Gets or sets the Id of the user that EWS should impersonate.
public ImpersonatedUserId ImpersonatedUserId { get; set; }
Property Value
ManagementRoles
public ManagementRoles ManagementRoles { get; set; }
Property Value
PreferredCulture
Gets or sets the preferred culture for messages returned by the Exchange Web Services.
public CultureInfo PreferredCulture { get; set; }
Property Value
TimeZone
Gets the time zone this service is scoped to.
public TimeZoneInfo TimeZone { get; }
Property Value
TraceEnablePrettyPrinting
Gets or sets a value indicating whether trace output is pretty printed.
public bool TraceEnablePrettyPrinting { get; set; }
Property Value
UnifiedMessaging
Provides access to the Unified Messaging functionalities.
public UnifiedMessaging UnifiedMessaging { get; }
Property Value
Url
Gets or sets the URL of the Exchange Web Services.
public Uri Url { get; set; }
Property Value
- Uri
Methods
AddDelegates(Mailbox, MeetingRequestsDeliveryScope?, params DelegateUser[])
Adds delegates to a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> AddDelegates(Mailbox mailbox, MeetingRequestsDeliveryScope? meetingRequestsDeliveryScope, params DelegateUser[] delegateUsers)
Parameters
mailboxMailboxThe mailbox to add delegates to.
meetingRequestsDeliveryScopeMeetingRequestsDeliveryScope?Indicates how meeting requests should be sent to delegates.
delegateUsersDelegateUser[]The delegate users to add.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
AddDelegates(Mailbox, MeetingRequestsDeliveryScope?, IEnumerable<DelegateUser>)
Adds delegates to a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> AddDelegates(Mailbox mailbox, MeetingRequestsDeliveryScope? meetingRequestsDeliveryScope, IEnumerable<DelegateUser> delegateUsers)
Parameters
mailboxMailboxThe mailbox to add delegates to.
meetingRequestsDeliveryScopeMeetingRequestsDeliveryScope?Indicates how meeting requests should be sent to delegates.
delegateUsersIEnumerable<DelegateUser>The delegate users to add.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
ArchiveItems(IEnumerable<ItemId>, FolderId)
Archives multiple items in a single call to EWS.
public ServiceResponseCollection<ArchiveItemResponse> ArchiveItems(IEnumerable<ItemId> itemIds, FolderId sourceFolderId)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to move.
sourceFolderIdFolderIdThe Id of the folder in primary corresponding to which items are being archived to.
Returns
- ServiceResponseCollection<ArchiveItemResponse>
A ServiceResponseCollection providing copy results for each of the specified item Ids.
AutodiscoverUrl(string)
Initializes the Url property to the Exchange Web Services URL for the specified e-mail address by calling the Autodiscover service.
public void AutodiscoverUrl(string emailAddress)
Parameters
emailAddressstringThe email address to use.
AutodiscoverUrl(string, AutodiscoverRedirectionUrlValidationCallback)
Initializes the Url property to the Exchange Web Services URL for the specified e-mail address by calling the Autodiscover service.
public void AutodiscoverUrl(string emailAddress, AutodiscoverRedirectionUrlValidationCallback validateRedirectionUrlCallback)
Parameters
emailAddressstringThe email address to use.
validateRedirectionUrlCallbackAutodiscoverRedirectionUrlValidationCallbackThe callback used to validate redirection URL.
BeginGetNonIndexableItemDetails(AsyncCallback, object, GetNonIndexableItemDetailsParameters)
Asynchronous call to get non indexable item details
public IAsyncResult BeginGetNonIndexableItemDetails(AsyncCallback callback, object state, GetNonIndexableItemDetailsParameters parameters)
Parameters
callbackAsyncCallbackcallback
stateobjectstate
parametersGetNonIndexableItemDetailsParametersGet non indexable item details parameters
Returns
- IAsyncResult
Async result
BeginGetNonIndexableItemStatistics(AsyncCallback, object, GetNonIndexableItemStatisticsParameters)
Asynchronous call to get non indexable item statistics
public IAsyncResult BeginGetNonIndexableItemStatistics(AsyncCallback callback, object state, GetNonIndexableItemStatisticsParameters parameters)
Parameters
callbackAsyncCallbackcallback
stateobjectstate
parametersGetNonIndexableItemStatisticsParametersGet non indexable item statistics parameters
Returns
- IAsyncResult
Async result
BeginSearchMailboxes(AsyncCallback, object, SearchMailboxesParameters)
Asynchronous call to search mailboxes
public IAsyncResult BeginSearchMailboxes(AsyncCallback callback, object state, SearchMailboxesParameters searchParameters)
Parameters
callbackAsyncCallbackcallback
stateobjectstate
searchParametersSearchMailboxesParameterssearch parameters
Returns
- IAsyncResult
Async result
BeginSubscribeToPullNotifications(AsyncCallback, object, IEnumerable<FolderId>, int, string, params EventType[])
Begins an asynchronous request to subscribes to pull notifications. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPullNotifications(AsyncCallback callback, object state, IEnumerable<FolderId> folderIds, int timeout, string watermark, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
timeoutintThe timeout, in minutes, after which the subscription expires. Timeout must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToPullNotificationsOnAllFolders(AsyncCallback, object, int, string, params EventType[])
Begins an asynchronous request to subscribe to pull notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPullNotificationsOnAllFolders(AsyncCallback callback, object state, int timeout, string watermark, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
timeoutintThe timeout, in minutes, after which the subscription expires. Timeout must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToPushNotifications(AsyncCallback, object, IEnumerable<FolderId>, Uri, int, string, params EventType[])
Begins an asynchronous request to subscribe to push notifications. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPushNotifications(AsyncCallback callback, object state, IEnumerable<FolderId> folderIds, Uri url, int frequency, string watermark, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToPushNotifications(AsyncCallback, object, IEnumerable<FolderId>, Uri, int, string, string, params EventType[])
Begins an asynchronous request to subscribe to push notifications. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPushNotifications(AsyncCallback callback, object state, IEnumerable<FolderId> folderIds, Uri url, int frequency, string watermark, string callerData, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
callerDatastringOptional caller data that will be returned the call back.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToPushNotificationsOnAllFolders(AsyncCallback, object, Uri, int, string, params EventType[])
Begins an asynchronous request to subscribe to push notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPushNotificationsOnAllFolders(AsyncCallback callback, object state, Uri url, int frequency, string watermark, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
urlUrifrequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToPushNotificationsOnAllFolders(AsyncCallback, object, Uri, int, string, string, params EventType[])
Begins an asynchronous request to subscribe to push notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToPushNotificationsOnAllFolders(AsyncCallback callback, object state, Uri url, int frequency, string watermark, string callerData, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
urlUrifrequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
callerDatastringOptional caller data that will be returned the call back.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToStreamingNotifications(AsyncCallback, object, IEnumerable<FolderId>, params EventType[])
Begins an asynchronous request to subscribe to streaming notifications. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToStreamingNotifications(AsyncCallback callback, object state, IEnumerable<FolderId> folderIds, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
eventTypesEventType[]The event types to subscribe to.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSubscribeToStreamingNotificationsOnAllFolders(AsyncCallback, object, params EventType[])
Begins an asynchronous request to subscribe to streaming notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public IAsyncResult BeginSubscribeToStreamingNotificationsOnAllFolders(AsyncCallback callback, object state, params EventType[] eventTypes)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
eventTypesEventType[]
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSyncFolderHierarchy(AsyncCallback, object, FolderId, PropertySet, string)
Begins an asynchronous request to synchronize the sub-folders of a specific folder. Calling this method results in a call to EWS.
public IAsyncResult BeginSyncFolderHierarchy(AsyncCallback callback, object state, FolderId syncFolderId, PropertySet propertySet, string syncState)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
syncFolderIdFolderIdThe Id of the folder containing the items to synchronize with. A null value indicates the root folder of the mailbox.
propertySetPropertySetThe set of properties to retrieve for synchronized items.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSyncFolderHierarchy(AsyncCallback, object, PropertySet, string)
Begins an asynchronous request to synchronize the entire folder hierarchy of the mailbox this Service is connected to. Calling this method results in a call to EWS.
public IAsyncResult BeginSyncFolderHierarchy(AsyncCallback callback, object state, PropertySet propertySet, string syncState)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
propertySetPropertySetThe set of properties to retrieve for synchronized items.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BeginSyncFolderItems(AsyncCallback, object, FolderId, PropertySet, IEnumerable<ItemId>, int, SyncFolderItemsScope, string)
Begins an asynchronous request to synchronize the items of a specific folder. Calling this method results in a call to EWS.
public IAsyncResult BeginSyncFolderItems(AsyncCallback callback, object state, FolderId syncFolderId, PropertySet propertySet, IEnumerable<ItemId> ignoredItemIds, int maxChangesReturned, SyncFolderItemsScope syncScope, string syncState)
Parameters
callbackAsyncCallbackThe AsyncCallback delegate.
stateobjectAn object that contains state information for this request.
syncFolderIdFolderIdThe Id of the folder containing the items to synchronize with.
propertySetPropertySetThe set of properties to retrieve for synchronized items.
ignoredItemIdsIEnumerable<ItemId>The optional list of item Ids that should be ignored.
maxChangesReturnedintThe maximum number of changes that should be returned.
syncScopeSyncFolderItemsScopeThe sync scope identifying items to include in the ChangeCollection.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- IAsyncResult
An IAsyncResult that references the asynchronous request.
BindToItems(IEnumerable<ItemId>, PropertySet)
Binds to multiple items in a single call to EWS.
public ServiceResponseCollection<GetItemResponse> BindToItems(IEnumerable<ItemId> itemIds, PropertySet propertySet)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to bind to.
propertySetPropertySetThe set of properties to load.
Returns
- ServiceResponseCollection<GetItemResponse>
A ServiceResponseCollection providing results for each of the specified item Ids.
ConvertId(AlternateIdBase, IdFormat)
Converts Id from one format to another in a single call to EWS.
public AlternateIdBase ConvertId(AlternateIdBase id, IdFormat destinationFormat)
Parameters
idAlternateIdBaseThe Id to convert.
destinationFormatIdFormatThe destination format.
Returns
- AlternateIdBase
The converted Id.
ConvertIds(IEnumerable<AlternateIdBase>, IdFormat)
Converts multiple Ids from one format to another in a single call to EWS.
public ServiceResponseCollection<ConvertIdResponse> ConvertIds(IEnumerable<AlternateIdBase> ids, IdFormat destinationFormat)
Parameters
idsIEnumerable<AlternateIdBase>The Ids to convert.
destinationFormatIdFormatThe destination format.
Returns
- ServiceResponseCollection<ConvertIdResponse>
A ServiceResponseCollection providing conversion results for each specified Ids.
CopyItems(IEnumerable<ItemId>, FolderId)
Copies multiple items in a single call to EWS.
public ServiceResponseCollection<MoveCopyItemResponse> CopyItems(IEnumerable<ItemId> itemIds, FolderId destinationFolderId)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to copy.
destinationFolderIdFolderIdThe Id of the folder to copy the items to.
Returns
- ServiceResponseCollection<MoveCopyItemResponse>
A ServiceResponseCollection providing copy results for each of the specified item Ids.
CopyItems(IEnumerable<ItemId>, FolderId, bool)
Copies multiple items in a single call to EWS.
public ServiceResponseCollection<MoveCopyItemResponse> CopyItems(IEnumerable<ItemId> itemIds, FolderId destinationFolderId, bool returnNewItemIds)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to copy.
destinationFolderIdFolderIdThe Id of the folder to copy the items to.
returnNewItemIdsboolFlag indicating whether service should return new ItemIds or not.
Returns
- ServiceResponseCollection<MoveCopyItemResponse>
A ServiceResponseCollection providing copy results for each of the specified item Ids.
CopyItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, FolderId)
Copies the items in the specified conversation to the specified destination folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> CopyItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, FolderId destinationFolderId)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should be copied and the date and time conversation was last synced (Items received after that date will not be copied).
contextFolderIdFolderIdThe context folder id.
destinationFolderIdFolderIdThe destination folder id.
Returns
CreateItems(IEnumerable<Item>, FolderId, MessageDisposition?, SendInvitationsMode?)
Creates multiple items in a single EWS call. Supported item classes are EmailMessage, Appointment, Contact, PostItem, Task and Item. CreateItems does not support items that have unsaved attachments.
public ServiceResponseCollection<ServiceResponse> CreateItems(IEnumerable<Item> items, FolderId parentFolderId, MessageDisposition? messageDisposition, SendInvitationsMode? sendInvitationsMode)
Parameters
itemsIEnumerable<Item>The items to create.
parentFolderIdFolderIdThe Id of the folder in which to place the newly created items. If null, items are created in their default folders.
messageDispositionMessageDisposition?Indicates the disposition mode for items of type EmailMessage. Required if items contains at least one EmailMessage instance.
sendInvitationsModeSendInvitationsMode?Indicates if and how invitations should be sent for items of type Appointment. Required if items contains at least one Appointment instance.
Returns
- ServiceResponseCollection<ServiceResponse>
A ServiceResponseCollection providing creation results for each of the specified items.
DeleteItems(IEnumerable<ItemId>, DeleteMode, SendCancellationsMode?, AffectedTaskOccurrence?)
Deletes multiple items in a single call to EWS.
public ServiceResponseCollection<ServiceResponse> DeleteItems(IEnumerable<ItemId> itemIds, DeleteMode deleteMode, SendCancellationsMode? sendCancellationsMode, AffectedTaskOccurrence? affectedTaskOccurrences)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to delete.
deleteModeDeleteModeThe deletion mode.
sendCancellationsModeSendCancellationsMode?Indicates whether cancellation messages should be sent. Required if any of the item Ids represents an Appointment.
affectedTaskOccurrencesAffectedTaskOccurrence?Indicates which instance of a recurring task should be deleted. Required if any of the item Ids represents a Task.
Returns
- ServiceResponseCollection<ServiceResponse>
A ServiceResponseCollection providing deletion results for each of the specified item Ids.
DeleteItems(IEnumerable<ItemId>, DeleteMode, SendCancellationsMode?, AffectedTaskOccurrence?, bool)
Deletes multiple items in a single call to EWS.
public ServiceResponseCollection<ServiceResponse> DeleteItems(IEnumerable<ItemId> itemIds, DeleteMode deleteMode, SendCancellationsMode? sendCancellationsMode, AffectedTaskOccurrence? affectedTaskOccurrences, bool suppressReadReceipt)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to delete.
deleteModeDeleteModeThe deletion mode.
sendCancellationsModeSendCancellationsMode?Indicates whether cancellation messages should be sent. Required if any of the item Ids represents an Appointment.
affectedTaskOccurrencesAffectedTaskOccurrence?Indicates which instance of a recurring task should be deleted. Required if any of the item Ids represents a Task.
suppressReadReceiptboolWhether to suppress read receipts
Returns
- ServiceResponseCollection<ServiceResponse>
A ServiceResponseCollection providing deletion results for each of the specified item Ids.
DeleteItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, DeleteMode)
Deletes the items in the specified conversation. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> DeleteItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, DeleteMode deleteMode)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should be deleted and the date and time conversation was last synced (Items received after that date will not be deleted).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
deleteModeDeleteModeThe deletion mode.
Returns
DisableAlwaysCategorizeItemsInConversations(IEnumerable<ConversationId>, bool)
Sets up a conversation so that any item received within that conversation is no longer categorized. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> DisableAlwaysCategorizeItemsInConversations(IEnumerable<ConversationId> conversationId, bool processSynchronously)
Parameters
conversationIdIEnumerable<ConversationId>The id of the conversation.
processSynchronouslyboolIndicates whether the method should return only once disabling this rule and removing the categories from existing items in the conversation is completely done. If processSynchronously is false, the method returns immediately.
Returns
DisableAlwaysDeleteItemsInConversations(IEnumerable<ConversationId>, bool)
Sets up a conversation so that any item received within that conversation is no longer moved to Deleted Items folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> DisableAlwaysDeleteItemsInConversations(IEnumerable<ConversationId> conversationId, bool processSynchronously)
Parameters
conversationIdIEnumerable<ConversationId>The id of the conversation.
processSynchronouslyboolIndicates whether the method should return only once disabling this rule and restoring the items in the conversation is completely done. If processSynchronously is false, the method returns immediately.
Returns
DisableAlwaysMoveItemsInConversations(IEnumerable<ConversationId>, bool)
Sets up a conversation so that any item received within that conversation is no longer moved to a specific folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> DisableAlwaysMoveItemsInConversations(IEnumerable<ConversationId> conversationIds, bool processSynchronously)
Parameters
conversationIdsIEnumerable<ConversationId>The conversation ids.
processSynchronouslyboolIndicates whether the method should return only once disabling this rule is completely done. If processSynchronously is false, the method returns immediately.
Returns
DisableApp(string, DisableReasonType)
Disable App.
public void DisableApp(string id, DisableReasonType disableReason)
Parameters
idstringApp ID
disableReasonDisableReasonTypeDisable reason
Remarks
Exception will be thrown for errors.
EnableAlwaysCategorizeItemsInConversations(IEnumerable<ConversationId>, IEnumerable<string>, bool)
Sets up a conversation so that any item received within that conversation is always categorized. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> EnableAlwaysCategorizeItemsInConversations(IEnumerable<ConversationId> conversationId, IEnumerable<string> categories, bool processSynchronously)
Parameters
conversationIdIEnumerable<ConversationId>The id of the conversation.
categoriesIEnumerable<string>The categories that should be stamped on items in the conversation.
processSynchronouslyboolIndicates whether the method should return only once enabling this rule and stamping existing items in the conversation is completely done. If processSynchronously is false, the method returns immediately.
Returns
EnableAlwaysDeleteItemsInConversations(IEnumerable<ConversationId>, bool)
Sets up a conversation so that any item received within that conversation is always moved to Deleted Items folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> EnableAlwaysDeleteItemsInConversations(IEnumerable<ConversationId> conversationId, bool processSynchronously)
Parameters
conversationIdIEnumerable<ConversationId>The id of the conversation.
processSynchronouslyboolIndicates whether the method should return only once enabling this rule and deleting existing items in the conversation is completely done. If processSynchronously is false, the method returns immediately.
Returns
EnableAlwaysMoveItemsInConversations(IEnumerable<ConversationId>, FolderId, bool)
Sets up a conversation so that any item received within that conversation is always moved to a specific folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> EnableAlwaysMoveItemsInConversations(IEnumerable<ConversationId> conversationId, FolderId destinationFolderId, bool processSynchronously)
Parameters
conversationIdIEnumerable<ConversationId>The id of the conversation.
destinationFolderIdFolderIdThe Id of the folder to which conversation items should be moved.
processSynchronouslyboolIndicates whether the method should return only once enabling this rule and moving existing items in the conversation is completely done. If processSynchronously is false, the method returns immediately.
Returns
EndGetNonIndexableItemDetails(IAsyncResult)
Asynchronous call to get non indexable item details
public GetNonIndexableItemDetailsResponse EndGetNonIndexableItemDetails(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResult
Returns
EndGetNonIndexableItemStatistics(IAsyncResult)
Asynchronous call to get non indexable item statistics
public GetNonIndexableItemStatisticsResponse EndGetNonIndexableItemStatistics(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResult
Returns
EndSearchMailboxes(IAsyncResult)
Asynchronous call to end search mailboxes
public ServiceResponseCollection<SearchMailboxesResponse> EndSearchMailboxes(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResult
Returns
EndSubscribeToPullNotifications(IAsyncResult)
Ends an asynchronous request to subscribe to pull notifications in the authenticated user's mailbox.
public PullSubscription EndSubscribeToPullNotifications(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResultAn IAsyncResult that references the asynchronous request.
Returns
- PullSubscription
A PullSubscription representing the new subscription.
EndSubscribeToPushNotifications(IAsyncResult)
Ends an asynchronous request to subscribe to push notifications in the authenticated user's mailbox.
public PushSubscription EndSubscribeToPushNotifications(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResultAn IAsyncResult that references the asynchronous request.
Returns
- PushSubscription
A PushSubscription representing the new subscription.
EndSubscribeToStreamingNotifications(IAsyncResult)
Ends an asynchronous request to subscribe to streaming notifications in the authenticated user's mailbox. Calling this method results in a call to EWS.
public StreamingSubscription EndSubscribeToStreamingNotifications(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResultAn IAsyncResult that references the asynchronous request.
Returns
- StreamingSubscription
A StreamingSubscription representing the new subscription.
EndSyncFolderHierarchy(IAsyncResult)
Ends an asynchronous request to synchronize the specified folder hierarchy of the mailbox this Service is connected to.
public ChangeCollection<FolderChange> EndSyncFolderHierarchy(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResultAn IAsyncResult that references the asynchronous request.
Returns
- ChangeCollection<FolderChange>
A ChangeCollection containing a list of changes that occurred in the specified folder.
EndSyncFolderItems(IAsyncResult)
Ends an asynchronous request to synchronize the items of a specific folder.
public ChangeCollection<ItemChange> EndSyncFolderItems(IAsyncResult asyncResult)
Parameters
asyncResultIAsyncResultAn IAsyncResult that references the asynchronous request.
Returns
- ChangeCollection<ItemChange>
A ChangeCollection containing a list of changes that occurred in the specified folder.
ExpandGroup(EmailAddress)
Expands a group by retrieving a list of its members. Calling this method results in a call to EWS.
public ExpandGroupResults ExpandGroup(EmailAddress emailAddress)
Parameters
emailAddressEmailAddressThe e-mail address of the group.
Returns
- ExpandGroupResults
An ExpandGroupResults containing the members of the group.
ExpandGroup(ItemId)
Expands a group by retrieving a list of its members. Calling this method results in a call to EWS.
public ExpandGroupResults ExpandGroup(ItemId groupId)
Parameters
groupIdItemIdThe Id of the group to expand.
Returns
- ExpandGroupResults
An ExpandGroupResults containing the members of the group.
ExpandGroup(string)
Expands a group by retrieving a list of its members. Calling this method results in a call to EWS.
public ExpandGroupResults ExpandGroup(string smtpAddress)
Parameters
smtpAddressstringThe SMTP address of the group to expand.
Returns
- ExpandGroupResults
An ExpandGroupResults containing the members of the group.
ExpandGroup(string, string)
Expands a group by retrieving a list of its members. Calling this method results in a call to EWS.
public ExpandGroupResults ExpandGroup(string address, string routingType)
Parameters
addressstringThe SMTP address of the group to expand.
routingTypestringThe routing type of the address of the group to expand.
Returns
- ExpandGroupResults
An ExpandGroupResults containing the members of the group.
FindAppointments(FolderId, CalendarView)
Obtains a list of appointments by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Appointment> FindAppointments(FolderId parentFolderId, CalendarView calendarView)
Parameters
parentFolderIdFolderIdThe id of the calendar folder in which to search for items.
calendarViewCalendarViewThe calendar view controlling the number of appointments returned.
Returns
- FindItemsResults<Appointment>
A collection of appointments representing the contents of the specified folder.
FindAppointments(WellKnownFolderName, CalendarView)
Obtains a list of appointments by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Appointment> FindAppointments(WellKnownFolderName parentFolderName, CalendarView calendarView)
Parameters
parentFolderNameWellKnownFolderNameThe name of the calendar folder in which to search for items.
calendarViewCalendarViewThe calendar view controlling the number of appointments returned.
Returns
- FindItemsResults<Appointment>
A collection of appointments representing the contents of the specified folder.
FindConversation(ViewBase, FolderId)
Retrieves a collection of all Conversations in the specified Folder.
public ICollection<Conversation> FindConversation(ViewBase view, FolderId folderId)
Parameters
viewViewBaseThe view controlling the number of conversations returned.
folderIdFolderIdThe Id of the folder in which to search for conversations.
Returns
- ICollection<Conversation>
Collection of conversations.
FindConversation(ViewBase, FolderId, string)
Retrieves a collection of all Conversations in the specified Folder.
public ICollection<Conversation> FindConversation(ViewBase view, FolderId folderId, string queryString)
Parameters
viewViewBaseThe view controlling the number of conversations returned.
folderIdFolderIdThe Id of the folder in which to search for conversations.
queryStringstringThe query string for which the search is being performed
Returns
- ICollection<Conversation>
Collection of conversations.
FindConversation(ViewBase, FolderId, string, bool)
Searches for and retrieves a collection of Conversations in the specified Folder. Along with conversations, a list of highlight terms are returned.
public FindConversationResults FindConversation(ViewBase view, FolderId folderId, string queryString, bool returnHighlightTerms)
Parameters
viewViewBaseThe view controlling the number of conversations returned.
folderIdFolderIdThe Id of the folder in which to search for conversations.
queryStringstringThe query string for which the search is being performed
returnHighlightTermsboolFlag indicating if highlight terms should be returned in the response
Returns
- FindConversationResults
FindConversation results.
FindConversation(ViewBase, FolderId, string, bool, MailboxSearchLocation?)
Searches for and retrieves a collection of Conversations in the specified Folder. Along with conversations, a list of highlight terms are returned.
public FindConversationResults FindConversation(ViewBase view, FolderId folderId, string queryString, bool returnHighlightTerms, MailboxSearchLocation? mailboxScope)
Parameters
viewViewBaseThe view controlling the number of conversations returned.
folderIdFolderIdThe Id of the folder in which to search for conversations.
queryStringstringThe query string for which the search is being performed
returnHighlightTermsboolFlag indicating if highlight terms should be returned in the response
mailboxScopeMailboxSearchLocation?The mailbox scope to reference.
Returns
- FindConversationResults
FindConversation results.
FindFolders(FolderId, FolderView)
Obtains a list of folders by searching the sub-folders of the specified folder.
public FindFoldersResults FindFolders(FolderId parentFolderId, FolderView view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for folders.
viewFolderViewThe view controlling the number of folders returned.
Returns
- FindFoldersResults
An object representing the results of the search operation.
FindFolders(FolderId, SearchFilter, FolderView)
Obtains a list of folders by searching the sub-folders of the specified folder.
public FindFoldersResults FindFolders(FolderId parentFolderId, SearchFilter searchFilter, FolderView view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for folders.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewFolderViewThe view controlling the number of folders returned.
Returns
- FindFoldersResults
An object representing the results of the search operation.
FindFolders(WellKnownFolderName, FolderView)
Obtains a list of folders by searching the sub-folders of the specified folder.
public FindFoldersResults FindFolders(WellKnownFolderName parentFolderName, FolderView view)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for folders.
viewFolderViewThe view controlling the number of folders returned.
Returns
- FindFoldersResults
An object representing the results of the search operation.
FindFolders(WellKnownFolderName, SearchFilter, FolderView)
Obtains a list of folders by searching the sub-folders of the specified folder.
public FindFoldersResults FindFolders(WellKnownFolderName parentFolderName, SearchFilter searchFilter, FolderView view)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for folders.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewFolderViewThe view controlling the number of folders returned.
Returns
- FindFoldersResults
An object representing the results of the search operation.
FindItems(FolderId, SearchFilter, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(FolderId parentFolderId, SearchFilter searchFilter, ViewBase view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(FolderId, SearchFilter, ViewBase, Grouping)
Obtains a grouped list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(FolderId parentFolderId, SearchFilter searchFilter, ViewBase view, Grouping groupBy)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
A list of items containing the contents of the specified folder.
FindItems(FolderId, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(FolderId parentFolderId, ViewBase view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(FolderId, ViewBase, Grouping)
Obtains a grouped list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(FolderId parentFolderId, ViewBase view, Grouping groupBy)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
A list of items containing the contents of the specified folder.
FindItems(FolderId, string, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(FolderId parentFolderId, string queryString, ViewBase view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
queryStringstringthe search string to be used for indexed search, if any.
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(FolderId, string, ViewBase, Grouping)
Obtains a grouped list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(FolderId parentFolderId, string queryString, ViewBase view, Grouping groupBy)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
queryStringstringquery string to be used for indexed search
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
A list of items containing the contents of the specified folder.
FindItems(FolderId, string, bool, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Along with conversations, a list of highlight terms are returned. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(FolderId parentFolderId, string queryString, bool returnHighlightTerms, ViewBase view)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
queryStringstringthe search string to be used for indexed search, if any.
returnHighlightTermsboolFlag indicating if highlight terms should be returned in the response
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(FolderId, string, bool, ViewBase, Grouping)
Obtains a list of items by searching the contents of a specific folder. Along with conversations, a list of highlight terms are returned. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(FolderId parentFolderId, string queryString, bool returnHighlightTerms, ViewBase view, Grouping groupBy)
Parameters
parentFolderIdFolderIdThe Id of the folder in which to search for items.
queryStringstringthe search string to be used for indexed search, if any.
returnHighlightTermsboolFlag indicating if highlight terms should be returned in the response
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
An object representing the results of the search operation.
FindItems(WellKnownFolderName, SearchFilter, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(WellKnownFolderName parentFolderName, SearchFilter searchFilter, ViewBase view)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for items.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(WellKnownFolderName, SearchFilter, ViewBase, Grouping)
Obtains a grouped list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(WellKnownFolderName parentFolderName, SearchFilter searchFilter, ViewBase view, Grouping groupBy)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for items.
searchFilterSearchFilterThe search filter. Available search filter classes include SearchFilter.IsEqualTo, SearchFilter.ContainsSubstring and SearchFilter.SearchFilterCollection
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
A collection of grouped items representing the contents of the specified.
FindItems(WellKnownFolderName, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(WellKnownFolderName parentFolderName, ViewBase view)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for items.
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(WellKnownFolderName, string, ViewBase)
Obtains a list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public FindItemsResults<Item> FindItems(WellKnownFolderName parentFolderName, string queryString, ViewBase view)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for items.
queryStringstringquery string to be used for indexed search
viewViewBaseThe view controlling the number of items returned.
Returns
- FindItemsResults<Item>
An object representing the results of the search operation.
FindItems(WellKnownFolderName, string, ViewBase, Grouping)
Obtains a grouped list of items by searching the contents of a specific folder. Calling this method results in a call to EWS.
public GroupedFindItemsResults<Item> FindItems(WellKnownFolderName parentFolderName, string queryString, ViewBase view, Grouping groupBy)
Parameters
parentFolderNameWellKnownFolderNameThe name of the folder in which to search for items.
queryStringstringquery string to be used for indexed search
viewViewBaseThe view controlling the number of items returned.
groupByGroupingThe group by clause.
Returns
- GroupedFindItemsResults<Item>
A collection of grouped items representing the contents of the specified.
GetAppManifests()
Get the app manifests.
public Collection<XmlDocument> GetAppManifests()
Returns
- Collection<XmlDocument>
Collection of manifests
GetAppManifests(string, string)
Get the app manifests. Works with Exchange 2013 SP1 or later EWS.
public Collection<ClientApp> GetAppManifests(string apiVersionSupported, string schemaVersionSupported)
Parameters
apiVersionSupportedstringThe api version supported by the client.
schemaVersionSupportedstringThe schema version supported by the client.
Returns
- Collection<ClientApp>
Collection of manifests
GetAppMarketplaceUrl()
Get App Marketplace Url.
public string GetAppMarketplaceUrl()
Returns
Remarks
Exception will be thrown for errors.
GetAppMarketplaceUrl(string, string)
Get App Marketplace Url. Works with Exchange 2013 SP1 or later EWS.
public string GetAppMarketplaceUrl(string apiVersionSupported, string schemaVersionSupported)
Parameters
apiVersionSupportedstringThe api version supported by the client.
schemaVersionSupportedstringThe schema version supported by the client.
Returns
Remarks
Exception will be thrown for errors.
GetAttachments(Attachment[], BodyType?, IEnumerable<PropertyDefinitionBase>)
Gets attachments.
public ServiceResponseCollection<GetAttachmentResponse> GetAttachments(Attachment[] attachments, BodyType? bodyType, IEnumerable<PropertyDefinitionBase> additionalProperties)
Parameters
attachmentsAttachment[]The attachments.
bodyTypeBodyType?Type of the body.
additionalPropertiesIEnumerable<PropertyDefinitionBase>The additional properties.
Returns
- ServiceResponseCollection<GetAttachmentResponse>
Service response collection.
GetAttachments(string[], BodyType?, IEnumerable<PropertyDefinitionBase>)
Gets attachments.
public ServiceResponseCollection<GetAttachmentResponse> GetAttachments(string[] attachmentIds, BodyType? bodyType, IEnumerable<PropertyDefinitionBase> additionalProperties)
Parameters
attachmentIdsstring[]The attachment ids.
bodyTypeBodyType?Type of the body.
additionalPropertiesIEnumerable<PropertyDefinitionBase>The additional properties.
Returns
- ServiceResponseCollection<GetAttachmentResponse>
Service response collection.
GetClientAccessToken(ClientAccessTokenRequest[])
GetClientAccessToken
public ServiceResponseCollection<GetClientAccessTokenResponse> GetClientAccessToken(ClientAccessTokenRequest[] tokenRequests)
Parameters
tokenRequestsClientAccessTokenRequest[]Token requests array
Returns
- ServiceResponseCollection<GetClientAccessTokenResponse>
A ServiceResponseCollection providing token results for each of the specified id and types.
GetClientAccessToken(IEnumerable<KeyValuePair<string, ClientAccessTokenType>>)
GetClientAccessToken
public ServiceResponseCollection<GetClientAccessTokenResponse> GetClientAccessToken(IEnumerable<KeyValuePair<string, ClientAccessTokenType>> idAndTypes)
Parameters
idAndTypesIEnumerable<KeyValuePair<string, ClientAccessTokenType>>Id and Types
Returns
- ServiceResponseCollection<GetClientAccessTokenResponse>
A ServiceResponseCollection providing token results for each of the specified id and types.
GetClientExtension(StringList, bool, bool, string, StringList, StringList, bool)
Get the client extension data. This method is used in server-to-server calls to retrieve ORG extensions for admin powershell/UMC access and user's powershell/UMC access as well as user's activation for OWA/Outlook. This is expected to never be used or called directly from user client.
public GetClientExtensionResponse GetClientExtension(StringList requestedExtensionIds, bool shouldReturnEnabledOnly, bool isUserScope, string userId, StringList userEnabledExtensionIds, StringList userDisabledExtensionIds, bool isDebug)
Parameters
requestedExtensionIdsStringListAn array of requested extension IDs to return.
shouldReturnEnabledOnlyboolWhether enabled extension only should be returned, e.g. for user's OWA/Outlook activation scenario.
isUserScopeboolWhether it's called from admin or user scope
userIdstringSpecifies optional (if called with user scope) user identity. This will allow to do proper filtering in cases where admin installs an extension for specific users only
userEnabledExtensionIdsStringListOptional list of org extension IDs which user enabled. This is necessary for proper result filtering on the server end. E.g. if admin installed N extensions but didn't enable them, it does not make sense to return manifests for those which user never enabled either. Used only when asked for enabled extension only (activation scenario).
userDisabledExtensionIdsStringListOptional list of org extension IDs which user disabled. This is necessary for proper result filtering on the server end. E.g. if admin installed N optional extensions and enabled them, it does not make sense to retrieve manifests for extensions which user disabled for him or herself. Used only when asked for enabled extension only (activation scenario).
isDebugboolOptional flag to indicate whether it is debug mode. If it is, org master table in arbitration mailbox will be returned for debugging purpose.
Returns
- GetClientExtensionResponse
Collection of ClientExtension objects
GetConversationItems(ConversationId, PropertySet, string, IEnumerable<FolderId>, ConversationSortOrder?)
Gets the items for a conversation.
public ConversationResponse GetConversationItems(ConversationId conversationId, PropertySet propertySet, string syncState, IEnumerable<FolderId> foldersToIgnore, ConversationSortOrder? sortOrder)
Parameters
conversationIdConversationIdThe conversation id.
propertySetPropertySetThe set of properties to load.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
foldersToIgnoreIEnumerable<FolderId>The folders to ignore.
sortOrderConversationSortOrder?Conversation item sort order.
Returns
- ConversationResponse
ConversationResponseType response.
GetConversationItems(IEnumerable<ConversationRequest>, PropertySet, IEnumerable<FolderId>, ConversationSortOrder?)
Gets the items for a set of conversations.
public ServiceResponseCollection<GetConversationItemsResponse> GetConversationItems(IEnumerable<ConversationRequest> conversations, PropertySet propertySet, IEnumerable<FolderId> foldersToIgnore, ConversationSortOrder? sortOrder)
Parameters
conversationsIEnumerable<ConversationRequest>Conversations with items to load.
propertySetPropertySetThe set of properties to load.
foldersToIgnoreIEnumerable<FolderId>The folders to ignore.
sortOrderConversationSortOrder?Conversation item sort order.
Returns
- ServiceResponseCollection<GetConversationItemsResponse>
GetConversationItems response.
GetConversationItems(IEnumerable<ConversationRequest>, PropertySet, IEnumerable<FolderId>, ConversationSortOrder?, MailboxSearchLocation?)
Gets the items for a set of conversations.
public ServiceResponseCollection<GetConversationItemsResponse> GetConversationItems(IEnumerable<ConversationRequest> conversations, PropertySet propertySet, IEnumerable<FolderId> foldersToIgnore, ConversationSortOrder? sortOrder, MailboxSearchLocation? mailboxScope)
Parameters
conversationsIEnumerable<ConversationRequest>Conversations with items to load.
propertySetPropertySetThe set of properties to load.
foldersToIgnoreIEnumerable<FolderId>The folders to ignore.
sortOrderConversationSortOrder?Conversation item sort order.
mailboxScopeMailboxSearchLocation?The mailbox scope to reference.
Returns
- ServiceResponseCollection<GetConversationItemsResponse>
GetConversationItems response.
GetDelegates(Mailbox, bool, params UserId[])
Retrieves the delegates of a specific mailbox. Calling this method results in a call to EWS.
public DelegateInformation GetDelegates(Mailbox mailbox, bool includePermissions, params UserId[] userIds)
Parameters
mailboxMailboxThe mailbox to retrieve the delegates of.
includePermissionsboolIndicates whether detailed permissions should be returned fro each delegate.
userIdsUserId[]The optional Ids of the delegate users to retrieve.
Returns
- DelegateInformation
A GetDelegateResponse providing the results of the operation.
GetDelegates(Mailbox, bool, IEnumerable<UserId>)
Retrieves the delegates of a specific mailbox. Calling this method results in a call to EWS.
public DelegateInformation GetDelegates(Mailbox mailbox, bool includePermissions, IEnumerable<UserId> userIds)
Parameters
mailboxMailboxThe mailbox to retrieve the delegates of.
includePermissionsboolIndicates whether detailed permissions should be returned fro each delegate.
userIdsIEnumerable<UserId>The optional Ids of the delegate users to retrieve.
Returns
- DelegateInformation
A GetDelegateResponse providing the results of the operation.
GetDiscoverySearchConfiguration(string, bool, bool)
Get dicovery search configuration
public GetDiscoverySearchConfigurationResponse GetDiscoverySearchConfiguration(string searchId, bool expandGroupMembership, bool inPlaceHoldConfigurationOnly)
Parameters
searchIdstringSearch Id
expandGroupMembershipboolTrue if want to expand group membership
inPlaceHoldConfigurationOnlyboolTrue if only want the inplacehold configuration
Returns
- GetDiscoverySearchConfigurationResponse
Service response object
GetEncryptionConfiguration()
Get the encryption configuration data. This method is used in server-to-server calls to retrieve encryption configuration
public GetEncryptionConfigurationResponse GetEncryptionConfiguration()
Returns
- GetEncryptionConfigurationResponse
Encryption Configuration response object
GetHoldOnMailboxes(string)
Get hold on mailboxes
public GetHoldOnMailboxesResponse GetHoldOnMailboxes(string holdId)
Parameters
holdIdstringHold id
Returns
- GetHoldOnMailboxesResponse
Service response object
GetInboxRules()
Retrieves inbox rules of the authenticated user.
public RuleCollection GetInboxRules()
Returns
- RuleCollection
A RuleCollection object containing the authenticated user's inbox rules.
GetInboxRules(string)
Retrieves the inbox rules of the specified user.
public RuleCollection GetInboxRules(string mailboxSmtpAddress)
Parameters
mailboxSmtpAddressstringThe SMTP address of the user whose inbox rules should be retrieved.
Returns
- RuleCollection
A RuleCollection object containing the inbox rules of the specified user.
GetNonIndexableItemDetails(GetNonIndexableItemDetailsParameters)
Get non indexable item details
public GetNonIndexableItemDetailsResponse GetNonIndexableItemDetails(GetNonIndexableItemDetailsParameters parameters)
Parameters
parametersGetNonIndexableItemDetailsParametersGet non indexable item details parameters
Returns
- GetNonIndexableItemDetailsResponse
Service response object
GetNonIndexableItemDetails(string[])
Get non indexable item details
public GetNonIndexableItemDetailsResponse GetNonIndexableItemDetails(string[] mailboxes)
Parameters
mailboxesstring[]Array of mailbox legacy DN
Returns
- GetNonIndexableItemDetailsResponse
Service response object
GetNonIndexableItemDetails(string[], int?, string, SearchPageDirection?)
Get non indexable item details
public GetNonIndexableItemDetailsResponse GetNonIndexableItemDetails(string[] mailboxes, int? pageSize, string pageItemReference, SearchPageDirection? pageDirection)
Parameters
mailboxesstring[]Array of mailbox legacy DN
pageSizeint?The page size
pageItemReferencestringPage item reference
pageDirectionSearchPageDirection?Page direction
Returns
- GetNonIndexableItemDetailsResponse
Service response object
GetNonIndexableItemStatistics(GetNonIndexableItemStatisticsParameters)
Get non indexable item statistics
public GetNonIndexableItemStatisticsResponse GetNonIndexableItemStatistics(GetNonIndexableItemStatisticsParameters parameters)
Parameters
parametersGetNonIndexableItemStatisticsParametersGet non indexable item statistics parameters
Returns
- GetNonIndexableItemStatisticsResponse
Service response object
GetNonIndexableItemStatistics(string[])
Get non indexable item statistics
public GetNonIndexableItemStatisticsResponse GetNonIndexableItemStatistics(string[] mailboxes)
Parameters
mailboxesstring[]Array of mailbox legacy DN
Returns
- GetNonIndexableItemStatisticsResponse
Service response object
GetPasswordExpirationDate(string)
Get the password expiration date
public DateTime? GetPasswordExpirationDate(string mailboxSmtpAddress)
Parameters
mailboxSmtpAddressstringThe e-mail address of the user.
Returns
- DateTime?
The password expiration date.
GetRoomLists()
Retrieves a collection of all room lists in the organization.
public EmailAddressCollection GetRoomLists()
Returns
- EmailAddressCollection
An EmailAddressCollection containing all the room lists in the organization.
GetRooms(EmailAddress)
Retrieves a collection of all rooms in the specified room list in the organization.
public Collection<EmailAddress> GetRooms(EmailAddress emailAddress)
Parameters
emailAddressEmailAddressThe e-mail address of the room list.
Returns
- Collection<EmailAddress>
A collection of EmailAddress objects representing all the rooms within the specifed room list.
GetSearchableMailboxes(string, bool)
Get searchable mailboxes
public GetSearchableMailboxesResponse GetSearchableMailboxes(string searchFilter, bool expandGroupMembership)
Parameters
searchFilterstringSearch filter
expandGroupMembershipboolTrue if want to expand group membership
Returns
- GetSearchableMailboxesResponse
Service response object
GetUserAvailability(IEnumerable<AttendeeInfo>, TimeWindow, AvailabilityData)
Gets detailed information about the availability of a set of users, rooms, and resources within a specified time window.
public GetUserAvailabilityResults GetUserAvailability(IEnumerable<AttendeeInfo> attendees, TimeWindow timeWindow, AvailabilityData requestedData)
Parameters
attendeesIEnumerable<AttendeeInfo>The attendees for which to retrieve availability information.
timeWindowTimeWindowThe time window in which to retrieve user availability information.
requestedDataAvailabilityDataThe requested data (free/busy and/or suggestions).
Returns
- GetUserAvailabilityResults
The availability information for each user appears in a unique FreeBusyResponse object. The order of users in the request determines the order of availability data for each user in the response.
GetUserAvailability(IEnumerable<AttendeeInfo>, TimeWindow, AvailabilityData, AvailabilityOptions)
Gets detailed information about the availability of a set of users, rooms, and resources within a specified time window.
public GetUserAvailabilityResults GetUserAvailability(IEnumerable<AttendeeInfo> attendees, TimeWindow timeWindow, AvailabilityData requestedData, AvailabilityOptions options)
Parameters
attendeesIEnumerable<AttendeeInfo>The attendees for which to retrieve availability information.
timeWindowTimeWindowThe time window in which to retrieve user availability information.
requestedDataAvailabilityDataThe requested data (free/busy and/or suggestions).
optionsAvailabilityOptionsThe options controlling the information returned.
Returns
- GetUserAvailabilityResults
The availability information for each user appears in a unique FreeBusyResponse object. The order of users in the request determines the order of availability data for each user in the response.
GetUserOofSettings(string)
Gets Out of Office (OOF) settings for a specific user. Calling this method results in a call to EWS.
public OofSettings GetUserOofSettings(string smtpAddress)
Parameters
smtpAddressstringThe SMTP address of the user for which to retrieve OOF settings.
Returns
- OofSettings
An OofSettings instance containing OOF information for the specified user.
GetUserRetentionPolicyTags()
Get user retention policy tags.
public GetUserRetentionPolicyTagsResponse GetUserRetentionPolicyTags()
Returns
- GetUserRetentionPolicyTagsResponse
Service response object.
InstallApp(Stream)
Install App.
public void InstallApp(Stream manifestStream)
Parameters
manifestStreamStreamThe manifest's plain text XML stream. Notice: Stream has state. If you want this function read from the expected position of the stream, please make sure set read position by manifestStream.Position = expectedPosition. Be aware read manifestStream.Lengh puts stream's Position at stream end. If you retrieve manifestStream.Lengh before call this function, nothing will be read. When this function succeeds, manifestStream is closed. This is by EWS design to release resource in timely manner.
Remarks
Exception will be thrown for errors.
LoadPropertiesForItems(IEnumerable<Item>, PropertySet)
Loads the properties of multiple items in a single call to EWS.
public ServiceResponseCollection<ServiceResponse> LoadPropertiesForItems(IEnumerable<Item> items, PropertySet propertySet)
Parameters
itemsIEnumerable<Item>The items to load the properties of.
propertySetPropertySetThe set of properties to load.
Returns
- ServiceResponseCollection<ServiceResponse>
A ServiceResponseCollection providing results for each of the specified items.
MarkAsJunk(IEnumerable<ItemId>, bool, bool)
Mark items as junk.
public ServiceResponseCollection<MarkAsJunkResponse> MarkAsJunk(IEnumerable<ItemId> itemIds, bool isJunk, bool moveItem)
Parameters
itemIdsIEnumerable<ItemId>ItemIds for the items to mark
isJunkboolWhether the items are junk. If true, senders are add to blocked sender list. If false, senders are removed.
moveItemboolWhether to move the item. Items are moved to junk folder if isJunk is true, inbox if isJunk is false.
Returns
- ServiceResponseCollection<MarkAsJunkResponse>
A ServiceResponseCollection providing itemIds for each of the moved items..
MoveItems(IEnumerable<ItemId>, FolderId)
Moves multiple items in a single call to EWS.
public ServiceResponseCollection<MoveCopyItemResponse> MoveItems(IEnumerable<ItemId> itemIds, FolderId destinationFolderId)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to move.
destinationFolderIdFolderIdThe Id of the folder to move the items to.
Returns
- ServiceResponseCollection<MoveCopyItemResponse>
A ServiceResponseCollection providing copy results for each of the specified item Ids.
MoveItems(IEnumerable<ItemId>, FolderId, bool)
Moves multiple items in a single call to EWS.
public ServiceResponseCollection<MoveCopyItemResponse> MoveItems(IEnumerable<ItemId> itemIds, FolderId destinationFolderId, bool returnNewItemIds)
Parameters
itemIdsIEnumerable<ItemId>The Ids of the items to move.
destinationFolderIdFolderIdThe Id of the folder to move the items to.
returnNewItemIdsboolFlag indicating whether service should return new ItemIds or not.
Returns
- ServiceResponseCollection<MoveCopyItemResponse>
A ServiceResponseCollection providing copy results for each of the specified item Ids.
MoveItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, FolderId)
Moves the items in the specified conversation to the specified destination folder. Calling this method results in a call to EWS.
public ServiceResponseCollection<ServiceResponse> MoveItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, FolderId destinationFolderId)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should be moved and the dateTime conversation was last synced (Items received after that dateTime will not be moved).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
destinationFolderIdFolderIdThe Id of the destination folder.
Returns
RemoveDelegates(Mailbox, params UserId[])
Removes delegates on a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> RemoveDelegates(Mailbox mailbox, params UserId[] userIds)
Parameters
mailboxMailboxThe mailbox to remove delegates from.
userIdsUserId[]The Ids of the delegate users to remove.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
RemoveDelegates(Mailbox, IEnumerable<UserId>)
Removes delegates on a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> RemoveDelegates(Mailbox mailbox, IEnumerable<UserId> userIds)
Parameters
mailboxMailboxThe mailbox to remove delegates from.
userIdsIEnumerable<UserId>The Ids of the delegate users to remove.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
ResolveName(string)
Finds contacts in the user's Contacts folder and the Global Address List (in that order) that have names that match the one passed as a parameter. Calling this method results in a call to EWS.
public NameResolutionCollection ResolveName(string nameToResolve)
Parameters
nameToResolvestringThe name to resolve.
Returns
- NameResolutionCollection
A collection of name resolutions whose names match the one passed as a parameter.
ResolveName(string, ResolveNameSearchLocation, bool)
Finds contacts in the Global Address List that have names that match the one passed as a parameter. Calling this method results in a call to EWS.
public NameResolutionCollection ResolveName(string nameToResolve, ResolveNameSearchLocation searchScope, bool returnContactDetails)
Parameters
nameToResolvestringThe name to resolve.
searchScopeResolveNameSearchLocationThe scope of the search.
returnContactDetailsboolIndicates whether full contact information should be returned for each of the found contacts.
Returns
- NameResolutionCollection
A collection of name resolutions whose names match the one passed as a parameter.
ResolveName(string, ResolveNameSearchLocation, bool, PropertySet)
Finds contacts in the Global Address List that have names that match the one passed as a parameter. Calling this method results in a call to EWS.
public NameResolutionCollection ResolveName(string nameToResolve, ResolveNameSearchLocation searchScope, bool returnContactDetails, PropertySet contactDataPropertySet)
Parameters
nameToResolvestringThe name to resolve.
searchScopeResolveNameSearchLocationThe scope of the search.
returnContactDetailsboolIndicates whether full contact information should be returned for each of the found contacts.
contactDataPropertySetPropertySetPropety set for contact details
Returns
- NameResolutionCollection
A collection of name resolutions whose names match the one passed as a parameter.
ResolveName(string, IEnumerable<FolderId>, ResolveNameSearchLocation, bool)
Finds contacts in the Global Address List and/or in specific contact folders that have names that match the one passed as a parameter. Calling this method results in a call to EWS.
public NameResolutionCollection ResolveName(string nameToResolve, IEnumerable<FolderId> parentFolderIds, ResolveNameSearchLocation searchScope, bool returnContactDetails)
Parameters
nameToResolvestringThe name to resolve.
parentFolderIdsIEnumerable<FolderId>The Ids of the contact folders in which to look for matching contacts.
searchScopeResolveNameSearchLocationThe scope of the search.
returnContactDetailsboolIndicates whether full contact information should be returned for each of the found contacts.
Returns
- NameResolutionCollection
A collection of name resolutions whose names match the one passed as a parameter.
ResolveName(string, IEnumerable<FolderId>, ResolveNameSearchLocation, bool, PropertySet)
Finds contacts in the Global Address List and/or in specific contact folders that have names that match the one passed as a parameter. Calling this method results in a call to EWS.
public NameResolutionCollection ResolveName(string nameToResolve, IEnumerable<FolderId> parentFolderIds, ResolveNameSearchLocation searchScope, bool returnContactDetails, PropertySet contactDataPropertySet)
Parameters
nameToResolvestringThe name to resolve.
parentFolderIdsIEnumerable<FolderId>The Ids of the contact folders in which to look for matching contacts.
searchScopeResolveNameSearchLocationThe scope of the search.
returnContactDetailsboolIndicates whether full contact information should be returned for each of the found contacts.
contactDataPropertySetPropertySetThe property set for the contct details
Returns
- NameResolutionCollection
A collection of name resolutions whose names match the one passed as a parameter.
SearchMailboxes(SearchMailboxesParameters)
Search mailboxes
public ServiceResponseCollection<SearchMailboxesResponse> SearchMailboxes(SearchMailboxesParameters searchParameters)
Parameters
searchParametersSearchMailboxesParametersSearch mailboxes parameters
Returns
- ServiceResponseCollection<SearchMailboxesResponse>
Collection of search mailboxes response object
SearchMailboxes(IEnumerable<MailboxQuery>, SearchResultType)
Search mailboxes
public ServiceResponseCollection<SearchMailboxesResponse> SearchMailboxes(IEnumerable<MailboxQuery> mailboxQueries, SearchResultType resultType)
Parameters
mailboxQueriesIEnumerable<MailboxQuery>Collection of query and mailboxes
resultTypeSearchResultTypeSearch result type
Returns
- ServiceResponseCollection<SearchMailboxesResponse>
Collection of search mailboxes response object
SearchMailboxes(IEnumerable<MailboxQuery>, SearchResultType, string, SortDirection, int, SearchPageDirection, string)
Search mailboxes
public ServiceResponseCollection<SearchMailboxesResponse> SearchMailboxes(IEnumerable<MailboxQuery> mailboxQueries, SearchResultType resultType, string sortByProperty, SortDirection sortOrder, int pageSize, SearchPageDirection pageDirection, string pageItemReference)
Parameters
mailboxQueriesIEnumerable<MailboxQuery>Collection of query and mailboxes
resultTypeSearchResultTypeSearch result type
sortByPropertystringSort by property name
sortOrderSortDirectionSort order
pageSizeintPage size
pageDirectionSearchPageDirectionPage navigation direction
pageItemReferencestringItem reference used for paging
Returns
- ServiceResponseCollection<SearchMailboxesResponse>
Collection of search mailboxes response object
SetClientExtension(List<SetClientExtensionAction>)
Set the client extension data. This method is used in server-to-server calls to install/uninstall/configure ORG extensions to support admin's management of ORG extensions via powershell/UMC.
public void SetClientExtension(List<SetClientExtensionAction> actions)
Parameters
actionsList<SetClientExtensionAction>List of actions to execute.
SetEncryptionConfiguration(string, string, string, string)
Set the encryption configuration data. This method is used in server-to-server calls to set encryption configuration
public void SetEncryptionConfiguration(string imageBase64, string emailText, string portalText, string disclaimerText)
Parameters
imageBase64stringThe base64 encoding of the image
emailTextstringThe email text
portalTextstringThe portal text
disclaimerTextstringThe disclaimer text
SetFlagStatusForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, Flag)
Sets flag status for items in conversation. Calling this method would result in call to EWS.
public ServiceResponseCollection<ServiceResponse> SetFlagStatusForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, Flag flagStatus)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should have their read state set and the date and time conversation was last synced (Items received after that date will not have their read state set).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
flagStatusFlagFlag status to apply to conversation items.
Returns
SetHoldOnMailboxes(SetHoldOnMailboxesParameters)
Set hold on mailboxes
public SetHoldOnMailboxesResponse SetHoldOnMailboxes(SetHoldOnMailboxesParameters parameters)
Parameters
parametersSetHoldOnMailboxesParametersSet hold parameters
Returns
- SetHoldOnMailboxesResponse
Service response object
SetHoldOnMailboxes(string, HoldAction, string, string)
Set hold on mailboxes
public SetHoldOnMailboxesResponse SetHoldOnMailboxes(string holdId, HoldAction actionType, string query, string inPlaceHoldIdentity)
Parameters
holdIdstringHold id
actionTypeHoldActionAction type
querystringQuery string
inPlaceHoldIdentitystringin-place hold identity
Returns
- SetHoldOnMailboxesResponse
Service response object
SetHoldOnMailboxes(string, HoldAction, string, string, string)
Set hold on mailboxes
public SetHoldOnMailboxesResponse SetHoldOnMailboxes(string holdId, HoldAction actionType, string query, string inPlaceHoldIdentity, string itemHoldPeriod)
Parameters
holdIdstringHold id
actionTypeHoldActionAction type
querystringQuery string
inPlaceHoldIdentitystringin-place hold identity
itemHoldPeriodstringitem hold period
Returns
- SetHoldOnMailboxesResponse
Service response object
SetHoldOnMailboxes(string, HoldAction, string, string[])
Set hold on mailboxes
public SetHoldOnMailboxesResponse SetHoldOnMailboxes(string holdId, HoldAction actionType, string query, string[] mailboxes)
Parameters
holdIdstringHold id
actionTypeHoldActionAction type
querystringQuery string
mailboxesstring[]Collection of mailboxes
Returns
- SetHoldOnMailboxesResponse
Service response object
SetReadStateForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, bool)
Sets the read state for items in conversation. Calling this method would result in call to EWS.
public ServiceResponseCollection<ServiceResponse> SetReadStateForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, bool isRead)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should have their read state set and the date and time conversation was last synced (Items received after that date will not have their read state set).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
isReadboolif set to
true, conversation items are marked as read; otherwise they are marked as unread.
Returns
SetReadStateForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, bool, bool)
Sets the read state for items in conversation. Calling this method would result in call to EWS.
public ServiceResponseCollection<ServiceResponse> SetReadStateForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, bool isRead, bool suppressReadReceipts)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should have their read state set and the date and time conversation was last synced (Items received after that date will not have their read state set).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
isReadboolif set to
true, conversation items are marked as read; otherwise they are marked as unread.suppressReadReceiptsboolif set to
trueread receipts are suppressed.
Returns
SetRetentionPolicyForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>>, FolderId, RetentionType, Guid?)
Sets the retention policy for items in conversation. Calling this method would result in call to EWS.
public ServiceResponseCollection<ServiceResponse> SetRetentionPolicyForItemsInConversations(IEnumerable<KeyValuePair<ConversationId, DateTime?>> idLastSyncTimePairs, FolderId contextFolderId, RetentionType retentionPolicyType, Guid? retentionPolicyTagId)
Parameters
idLastSyncTimePairsIEnumerable<KeyValuePair<ConversationId, DateTime?>>The pairs of Id of conversation whose items should have their retention policy set and the date and time conversation was last synced (Items received after that date will not have their retention policy set).
contextFolderIdFolderIdThe Id of the folder that contains the conversation.
retentionPolicyTypeRetentionTypeRetention policy type.
retentionPolicyTagIdGuid?Retention policy tag id. Null will clear the policy.
Returns
SetTeamMailbox(EmailAddress, Uri, TeamMailboxLifecycleState)
Set a TeamMailbox
public void SetTeamMailbox(EmailAddress emailAddress, Uri sharePointSiteUrl, TeamMailboxLifecycleState state)
Parameters
emailAddressEmailAddressTeamMailbox email address
sharePointSiteUrlUriSharePoint site URL
stateTeamMailboxLifecycleStateTeamMailbox lifecycle state
SetUserOofSettings(string, OofSettings)
Sets the Out of Office (OOF) settings for a specific mailbox. Calling this method results in a call to EWS.
public void SetUserOofSettings(string smtpAddress, OofSettings oofSettings)
Parameters
smtpAddressstringThe SMTP address of the user for which to set OOF settings.
oofSettingsOofSettingsThe OOF settings.
SubscribeToPullNotifications(IEnumerable<FolderId>, int, string, params EventType[])
Subscribes to pull notifications. Calling this method results in a call to EWS.
public PullSubscription SubscribeToPullNotifications(IEnumerable<FolderId> folderIds, int timeout, string watermark, params EventType[] eventTypes)
Parameters
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
timeoutintThe timeout, in minutes, after which the subscription expires. Timeout must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- PullSubscription
A PullSubscription representing the new subscription.
SubscribeToPullNotificationsOnAllFolders(int, string, params EventType[])
Subscribes to pull notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public PullSubscription SubscribeToPullNotificationsOnAllFolders(int timeout, string watermark, params EventType[] eventTypes)
Parameters
timeoutintThe timeout, in minutes, after which the subscription expires. Timeout must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- PullSubscription
A PullSubscription representing the new subscription.
SubscribeToPushNotifications(IEnumerable<FolderId>, Uri, int, string, params EventType[])
Subscribes to push notifications. Calling this method results in a call to EWS.
public PushSubscription SubscribeToPushNotifications(IEnumerable<FolderId> folderIds, Uri url, int frequency, string watermark, params EventType[] eventTypes)
Parameters
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- PushSubscription
A PushSubscription representing the new subscription.
SubscribeToPushNotifications(IEnumerable<FolderId>, Uri, int, string, string, params EventType[])
Subscribes to push notifications. Calling this method results in a call to EWS.
public PushSubscription SubscribeToPushNotifications(IEnumerable<FolderId> folderIds, Uri url, int frequency, string watermark, string callerData, params EventType[] eventTypes)
Parameters
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
callerDatastringOptional caller data that will be returned the call back.
eventTypesEventType[]The event types to subscribe to.
Returns
- PushSubscription
A PushSubscription representing the new subscription.
SubscribeToPushNotificationsOnAllFolders(Uri, int, string, params EventType[])
Subscribes to push notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public PushSubscription SubscribeToPushNotificationsOnAllFolders(Uri url, int frequency, string watermark, params EventType[] eventTypes)
Parameters
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
eventTypesEventType[]The event types to subscribe to.
Returns
- PushSubscription
A PushSubscription representing the new subscription.
SubscribeToPushNotificationsOnAllFolders(Uri, int, string, string, params EventType[])
Subscribes to push notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public PushSubscription SubscribeToPushNotificationsOnAllFolders(Uri url, int frequency, string watermark, string callerData, params EventType[] eventTypes)
Parameters
urlUriThe URL of the Web Service endpoint the Exchange server should push events to.
frequencyintThe frequency, in minutes, at which the Exchange server should contact the Web Service endpoint. Frequency must be between 1 and 1440.
watermarkstringAn optional watermark representing a previously opened subscription.
callerDatastringOptional caller data that will be returned the call back.
eventTypesEventType[]The event types to subscribe to.
Returns
- PushSubscription
A PushSubscription representing the new subscription.
SubscribeToStreamingNotifications(IEnumerable<FolderId>, params EventType[])
Subscribes to streaming notifications. Calling this method results in a call to EWS.
public StreamingSubscription SubscribeToStreamingNotifications(IEnumerable<FolderId> folderIds, params EventType[] eventTypes)
Parameters
folderIdsIEnumerable<FolderId>The Ids of the folder to subscribe to.
eventTypesEventType[]The event types to subscribe to.
Returns
- StreamingSubscription
A StreamingSubscription representing the new subscription.
SubscribeToStreamingNotificationsOnAllFolders(params EventType[])
Subscribes to streaming notifications on all folders in the authenticated user's mailbox. Calling this method results in a call to EWS.
public StreamingSubscription SubscribeToStreamingNotificationsOnAllFolders(params EventType[] eventTypes)
Parameters
eventTypesEventType[]The event types to subscribe to.
Returns
- StreamingSubscription
A StreamingSubscription representing the new subscription.
SyncFolderHierarchy(FolderId, PropertySet, string)
Synchronizes the sub-folders of a specific folder. Calling this method results in a call to EWS.
public ChangeCollection<FolderChange> SyncFolderHierarchy(FolderId syncFolderId, PropertySet propertySet, string syncState)
Parameters
syncFolderIdFolderIdThe Id of the folder containing the items to synchronize with. A null value indicates the root folder of the mailbox.
propertySetPropertySetThe set of properties to retrieve for synchronized items.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- ChangeCollection<FolderChange>
A ChangeCollection containing a list of changes that occurred in the specified folder.
SyncFolderHierarchy(PropertySet, string)
Synchronizes the entire folder hierarchy of the mailbox this Service is connected to. Calling this method results in a call to EWS.
public ChangeCollection<FolderChange> SyncFolderHierarchy(PropertySet propertySet, string syncState)
Parameters
propertySetPropertySetThe set of properties to retrieve for synchronized items.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- ChangeCollection<FolderChange>
A ChangeCollection containing a list of changes that occurred in the specified folder.
SyncFolderItems(FolderId, PropertySet, IEnumerable<ItemId>, int, SyncFolderItemsScope, string)
Synchronizes the items of a specific folder. Calling this method results in a call to EWS.
public ChangeCollection<ItemChange> SyncFolderItems(FolderId syncFolderId, PropertySet propertySet, IEnumerable<ItemId> ignoredItemIds, int maxChangesReturned, SyncFolderItemsScope syncScope, string syncState)
Parameters
syncFolderIdFolderIdThe Id of the folder containing the items to synchronize with.
propertySetPropertySetThe set of properties to retrieve for synchronized items.
ignoredItemIdsIEnumerable<ItemId>The optional list of item Ids that should be ignored.
maxChangesReturnedintThe maximum number of changes that should be returned.
syncScopeSyncFolderItemsScopeThe sync scope identifying items to include in the ChangeCollection.
syncStatestringThe optional sync state representing the point in time when to start the synchronization.
Returns
- ChangeCollection<ItemChange>
A ChangeCollection containing a list of changes that occurred in the specified folder.
UninstallApp(string)
Uninstall app.
public void UninstallApp(string id)
Parameters
idstringApp ID
Remarks
Exception will be thrown for errors.
UnpinTeamMailbox(EmailAddress)
Unpin a TeamMailbox
public void UnpinTeamMailbox(EmailAddress emailAddress)
Parameters
emailAddressEmailAddressTeamMailbox email address
UpdateDelegates(Mailbox, MeetingRequestsDeliveryScope?, params DelegateUser[])
Updates delegates on a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> UpdateDelegates(Mailbox mailbox, MeetingRequestsDeliveryScope? meetingRequestsDeliveryScope, params DelegateUser[] delegateUsers)
Parameters
mailboxMailboxThe mailbox to update delegates on.
meetingRequestsDeliveryScopeMeetingRequestsDeliveryScope?Indicates how meeting requests should be sent to delegates.
delegateUsersDelegateUser[]The delegate users to update.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
UpdateDelegates(Mailbox, MeetingRequestsDeliveryScope?, IEnumerable<DelegateUser>)
Updates delegates on a specific mailbox. Calling this method results in a call to EWS.
public Collection<DelegateUserResponse> UpdateDelegates(Mailbox mailbox, MeetingRequestsDeliveryScope? meetingRequestsDeliveryScope, IEnumerable<DelegateUser> delegateUsers)
Parameters
mailboxMailboxThe mailbox to update delegates on.
meetingRequestsDeliveryScopeMeetingRequestsDeliveryScope?Indicates how meeting requests should be sent to delegates.
delegateUsersIEnumerable<DelegateUser>The delegate users to update.
Returns
- Collection<DelegateUserResponse>
A collection of DelegateUserResponse objects providing the results of the operation.
UpdateInboxRules(IEnumerable<RuleOperation>, bool)
Updates the authenticated user's inbox rules by applying the specified operations.
public void UpdateInboxRules(IEnumerable<RuleOperation> operations, bool removeOutlookRuleBlob)
Parameters
operationsIEnumerable<RuleOperation>The operations that should be applied to the user's inbox rules.
removeOutlookRuleBlobboolIndicate whether or not to remove Outlook Rule Blob.
UpdateInboxRules(IEnumerable<RuleOperation>, bool, string)
Update the specified user's inbox rules by applying the specified operations.
public void UpdateInboxRules(IEnumerable<RuleOperation> operations, bool removeOutlookRuleBlob, string mailboxSmtpAddress)
Parameters
operationsIEnumerable<RuleOperation>The operations that should be applied to the user's inbox rules.
removeOutlookRuleBlobboolIndicate whether or not to remove Outlook Rule Blob.
mailboxSmtpAddressstringThe SMTP address of the user whose inbox rules should be updated.
UpdateItems(IEnumerable<Item>, FolderId, ConflictResolutionMode, MessageDisposition?, SendInvitationsOrCancellationsMode?)
Updates multiple items in a single EWS call. UpdateItems does not support items that have unsaved attachments.
public ServiceResponseCollection<UpdateItemResponse> UpdateItems(IEnumerable<Item> items, FolderId savedItemsDestinationFolderId, ConflictResolutionMode conflictResolution, MessageDisposition? messageDisposition, SendInvitationsOrCancellationsMode? sendInvitationsOrCancellationsMode)
Parameters
itemsIEnumerable<Item>The items to update.
savedItemsDestinationFolderIdFolderIdThe folder in which to save sent messages, meeting invitations or cancellations. If null, the messages, meeting invitation or cancellations are saved in the Sent Items folder.
conflictResolutionConflictResolutionModeThe conflict resolution mode.
messageDispositionMessageDisposition?Indicates the disposition mode for items of type EmailMessage. Required if items contains at least one EmailMessage instance.
sendInvitationsOrCancellationsModeSendInvitationsOrCancellationsMode?Indicates if and how invitations and/or cancellations should be sent for items of type Appointment. Required if items contains at least one Appointment instance.
Returns
- ServiceResponseCollection<UpdateItemResponse>
A ServiceResponseCollection providing update results for each of the specified items.
UpdateItems(IEnumerable<Item>, FolderId, ConflictResolutionMode, MessageDisposition?, SendInvitationsOrCancellationsMode?, bool)
Updates multiple items in a single EWS call. UpdateItems does not support items that have unsaved attachments.
public ServiceResponseCollection<UpdateItemResponse> UpdateItems(IEnumerable<Item> items, FolderId savedItemsDestinationFolderId, ConflictResolutionMode conflictResolution, MessageDisposition? messageDisposition, SendInvitationsOrCancellationsMode? sendInvitationsOrCancellationsMode, bool suppressReadReceipts)
Parameters
itemsIEnumerable<Item>The items to update.
savedItemsDestinationFolderIdFolderIdThe folder in which to save sent messages, meeting invitations or cancellations. If null, the messages, meeting invitation or cancellations are saved in the Sent Items folder.
conflictResolutionConflictResolutionModeThe conflict resolution mode.
messageDispositionMessageDisposition?Indicates the disposition mode for items of type EmailMessage. Required if items contains at least one EmailMessage instance.
sendInvitationsOrCancellationsModeSendInvitationsOrCancellationsMode?Indicates if and how invitations and/or cancellations should be sent for items of type Appointment. Required if items contains at least one Appointment instance.
suppressReadReceiptsboolWhether to suppress read receipts
Returns
- ServiceResponseCollection<UpdateItemResponse>
A ServiceResponseCollection providing update results for each of the specified items.