Class NotificationClient
Inherited Members
Namespace: System.Dynamic.ExpandoObject
Syntax
public class NotificationClient : ClientBase
Constructors
NotificationClient(Contract.IPictureparkServiceSettings, Http.HttpClient)
Declaration
public NotificationClient(Contract.IPictureparkServiceSettings configuration, Http.HttpClient httpClient)
Parameters
Picturepark.SDK.V1.Contract.IPictureparkServiceSettings
configuration
|
System.Net.Http.HttpClient
httpClient
|
Properties
JsonSerializerSettings
Declaration
protected Newtonsoft.Json.JsonSerializerSettings JsonSerializerSettings { get; }
Property Value
Newtonsoft.Json.JsonSerializerSettings
|
ReadResponseAsString
Declaration
public bool ReadResponseAsString { get; set; }
Property Value
System.Boolean
|
Methods
AggregateAsync(NotificationAggregationRequest, CancellationToken)
Aggregate on notifications
Declaration
public virtual async Task<ObjectAggregationResult> AggregateAsync(NotificationAggregationRequest request, CancellationToken cancellationToken = default(CancellationToken))
Parameters
NotificationAggregationRequest
request
Notification aggregation request |
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<ObjectAggregationResult>
Aggregation result |
GetAsync(String, CancellationToken)
Get notification
Declaration
public virtual async Task<Notification> GetAsync(string id, CancellationToken cancellationToken = default(CancellationToken))
Parameters
System.String
id
ID of notification |
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<Notification>
Notification |
GetAvailableNotificationTypesAsync(CancellationToken)
Get notification types available for email settings.
Declaration
public virtual async Task<IDictionary<string, ICollection<NotificationType>>> GetAvailableNotificationTypesAsync(CancellationToken cancellationToken = default(CancellationToken))
Parameters
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<System.Collections.Generic.IDictionary<System.String, System.Collections.Generic.ICollection<NotificationType>>>
|
GetEmailNotificationSettingsAsync(CancellationToken)
Get email notification settings
Declaration
public virtual async Task<EmailNotificationsSettings> GetEmailNotificationSettingsAsync(CancellationToken cancellationToken = default(CancellationToken))
Parameters
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<EmailNotificationsSettings>
Email notification settings |
MarkAllAsReadAsync(CancellationToken)
Mark all notifications as read
Declaration
public virtual async Task MarkAllAsReadAsync(CancellationToken cancellationToken = default(CancellationToken))
Parameters
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task
|
MarkAsReadAsync(String, CancellationToken)
Mark notification as read
Declaration
public virtual async Task<Notification> MarkAsReadAsync(string id, CancellationToken cancellationToken = default(CancellationToken))
Parameters
System.String
id
ID of notification |
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<Notification>
Notification |
PutEmailNotificationSettingsAsync(EmailNotificationsSettings, CancellationToken)
Update email notification settings
Declaration
public virtual async Task<EmailNotificationsSettings> PutEmailNotificationSettingsAsync(EmailNotificationsSettings configuration, CancellationToken cancellationToken = default(CancellationToken))
Parameters
EmailNotificationsSettings
configuration
Email notification settings |
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<EmailNotificationsSettings>
Email notification settings |
ReadObjectResponseAsync<T>(Http.HttpResponseMessage, IReadOnlyDictionary<String, IEnumerable<String>>, CancellationToken)
Declaration
protected virtual async Task<NotificationClient.ObjectResponseResult<T>> ReadObjectResponseAsync<T>(Http.HttpResponseMessage response, IReadOnlyDictionary<string, IEnumerable<string>> headers, CancellationToken cancellationToken)
Parameters
System.Net.Http.HttpResponseMessage
response
|
System.Collections.Generic.IReadOnlyDictionary<System.String, System.Collections.Generic.IEnumerable<System.String>>
headers
|
System.Threading.CancellationToken
cancellationToken
|
Returns
System.Threading.Tasks.Task<NotificationClient.ObjectResponseResult<T>>
|
Type Parameters
T
|
SearchAsync(NotificationSearchRequest, CancellationToken)
Search notifications
Declaration
public virtual async Task<NotificationCompactResult> SearchAsync(NotificationSearchRequest request, CancellationToken cancellationToken = default(CancellationToken))
Parameters
NotificationSearchRequest
request
Notification search request |
System.Threading.CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
System.Threading.Tasks.Task<NotificationCompactResult>
Notification search result |