Class NotificationClient
Inherited Members
Namespace: System.Dynamic.ExpandoObject
Syntax
[GeneratedCode("NSwag", "13.20.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.0.0))")]
public class NotificationClient : ClientBase, INotificationClient
Constructors
NotificationClient(IPictureparkServiceSettings, HttpClient)
Declaration
public NotificationClient(IPictureparkServiceSettings configuration, HttpClient httpClient)
Parameters
IPictureparkServiceSettings configuration |
HttpClient httpClient |
Properties
JsonSerializerSettings
Declaration
protected JsonSerializerSettings JsonSerializerSettings { get; }
Property Value
JsonSerializerSettings |
ReadResponseAsString
Methods
AggregateAsync(NotificationAggregationRequest, CancellationToken)
Aggregate on notifications
Declaration
public virtual Task<ObjectAggregationResult> AggregateAsync(NotificationAggregationRequest request, CancellationToken cancellationToken = default)
Parameters
NotificationAggregationRequest
request
Notification aggregation request |
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<ObjectAggregationResult>
Aggregation result |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
GetAsync(string, CancellationToken)
Get notification
Declaration
public virtual Task<Notification> GetAsync(string id, CancellationToken cancellationToken = default)
Parameters
string
id
ID of notification |
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<Notification>
Notification |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
GetAvailableNotificationTypesAsync(CancellationToken)
Get notification types available for email settings.
Declaration
public virtual Task<IDictionary<string, ICollection<NotificationType>>> GetAvailableNotificationTypesAsync(CancellationToken cancellationToken = default)
Parameters
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<IDictionary<string, ICollection<NotificationType>>> |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
GetEmailNotificationSettingsAsync(CancellationToken)
Get email notification settings
Declaration
public virtual Task<EmailNotificationsSettings> GetEmailNotificationSettingsAsync(CancellationToken cancellationToken = default)
Parameters
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<EmailNotificationsSettings>
Email notification settings |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
MarkAllAsReadAsync(CancellationToken)
Mark all notifications as read
Declaration
public virtual Task MarkAllAsReadAsync(CancellationToken cancellationToken = default)
Parameters
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
MarkAsReadAsync(string, CancellationToken)
Mark notification as read
Declaration
public virtual Task<Notification> MarkAsReadAsync(string id, CancellationToken cancellationToken = default)
Parameters
string
id
ID of notification |
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<Notification>
Notification |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
PutEmailNotificationSettingsAsync(EmailNotificationsSettings, CancellationToken)
Update email notification settings
Declaration
public virtual Task<EmailNotificationsSettings> PutEmailNotificationSettingsAsync(EmailNotificationsSettings configuration, CancellationToken cancellationToken = default)
Parameters
EmailNotificationsSettings
configuration
Email notification settings |
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<EmailNotificationsSettings>
Email notification settings |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |
ReadObjectResponseAsync<T>(HttpResponseMessage, IReadOnlyDictionary<string, IEnumerable<string>>, CancellationToken)
Declaration
protected virtual Task<NotificationClient.ObjectResponseResult<T>> ReadObjectResponseAsync<T>(HttpResponseMessage response, IReadOnlyDictionary<string, IEnumerable<string>> headers, CancellationToken cancellationToken)
Parameters
HttpResponseMessage response |
IReadOnlyDictionary<string, IEnumerable<string>> headers |
CancellationToken cancellationToken |
Returns
Task<NotificationClient.ObjectResponseResult<T>> |
Type Parameters
T |
SearchAsync(NotificationSearchRequest, CancellationToken)
Search notifications
Declaration
public virtual Task<NotificationCompactResult> SearchAsync(NotificationSearchRequest request, CancellationToken cancellationToken = default)
Parameters
NotificationSearchRequest
request
Notification search request |
CancellationToken
cancellationToken
A cancellation token that can be used by other objects or threads to receive notice of cancellation. |
Returns
Task<NotificationCompactResult>
Notification search result |
Implements
Exceptions
ApiException
A server side error occurred. |
PictureparkValidationException
Validation exception |
PictureparkForbiddenException
Forbidden |
PictureparkNotFoundException
Entity not found |
PictureparkConflictException
Version conflict |
PictureparkTooManyRequestsException
Too many requests |
PictureparkException
Internal server error |