NativeSubscriptionManagerAddTestSubscriptionEventForDocument Method Content Studio 5.7 SDK
Content Studio Web Content Management System

[This is preliminary documentation and is subject to change.]

Adds a test subscription event for a specific document. The document must belong to a category enabled for subscription.

Namespace: ContentStudio.Document.Subscription
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax

public void AddTestSubscriptionEventForDocument(
	DocumentId documentId,
	string receiver,
	SubscriptionType subscriptionType
)

Parameters

documentId
Type: ContentStudio.DocumentDocumentId
The identifier of a document to send.
receiver
Type: SystemString
The receiver of the message. This parameter cannot be null or empty.
subscriptionType
Type: ContentStudio.Document.SubscriptionSubscriptionType
The type of subscription. Currently (CS 5.2) only the Newsletter type is supported
Exceptions

ExceptionCondition
ArgumentExceptionReceiver is either null or empty.
InvalidOperationException The document category is not enabled for subscription - or - The document is currently being processed.
NotSupportedExceptionThe supplied subscriptionType is not supported.
CSExceptionA business rule was violated in the underlying Content Studio database
CSPermissionDeniedExceptionThe caller has no permission to perform the requested action
CSInvalidSessionExceptionThe session is invalid
CSInvalidParameterExceptionA parameter has an invalid value
CSDocumentNotFoundExceptionThe document could not be found
SqlExceptionAn error occurred when executing the command against the Content Studio database
Content Studio permissions

This method can only successfully be executed by sessions that have the WriteContainer and Read permissions on the document's category and Read permission on the document.
Remarks

A new subscription event handler job is added to the event actions queue a result of this method. The event indicates that a specific address will receive the message rather than the users that have subscribed to the category.
Note Note
This method is new in Content Studio 5.2
See Also

Reference