Email subscribers

The subscribers in Notification service are used to provide information to the notification message receiver. The Notification service contract requires an ISubscriberRequest to subscribe or unsubscribe a recipient of the messages. The system provides a SubscriberRequestProxy class that implements it.
For more information, see Working with subscriber's ID and ResolveKey.

Use the following sample to create a subscriber. The sample use ISubscriberRequest and ISubscriberResponse objects. In general, an ISubscriberRequest object contains all information needed for creating a subscriber. In case you want to work with an already persisted subscriber, you must use an ISubscriberResponse object, which contains all the information related to an already persisted subscriber.

Working with subscriber's ID and ResolveKey

The Notification service provides GetSubscriber() methods that you can use to obtain a persisted subscriber by subscriber.Id or by subscriber.ResolveKey.

There is a difference between subscriber.Id and by subscriber.ResolveKey. The subscriber.ResolveKey is a unique identifier used by external systems to synchronize notification subscribers to external entities. For example, one can use a username or login ID for resolve key to match external system membership user entity. The ID of the subscriber is unique across the notification system and is generated when creating the subscriber – it cannot be set with the subscriber request. 

How to get an existing subscriber by ID

The following sample shows how to get the existing subscriber by ID.

Getting an existing subscriber by ResolveKey

The following sample shows how to get the existing subscriber by ResolveKey.

Increase your Sitefinity skills by signing up for our free trainings. Get Sitefinity-certified at Progress Education Community to boost your credentials.

Web Security for Sitefinity Administrators

The free standalone Web Security lesson teaches administrators how to protect your websites and Sitefinity instance from external threats. Learn to configure HTTPS, SSL, allow lists for trusted sites, and cookie security, among others.

Foundations of Sitefinity ASP.NET Core Development

The free on-demand video course teaches developers how to use Sitefinity .NET Core and leverage its decoupled architecture and new way of coding against the platform.

Was this article helpful?

Next article

Email mailing lists