public interface NotificationTemplate
com.veeva.vault.sdk.api.notification.| Modifier and Type | Method and Description |
|---|---|
NotificationTemplate |
setTemplateName(String templateName)
Sets the notification template name (using the name of the notification template).
|
default NotificationTemplate |
setTokenResolver(Consumer<TokenResolverInput> tokenResolverInputConsumer)
Sets a Consumer that can provide resolved values for the requested tokens
specified in a
TokenResolverInput. |
NotificationTemplate |
setTokenValue(String tokenName,
String tokenValue)
Sets a custom token value.
|
NotificationTemplate setTemplateName(String templateName)
If the templateName is not set or is invalid, an error will occur when
NotificationService.send() is called with this
NotificationTemplate.
templateName - public key of notification templateNotificationTemplateNotificationTemplate setTokenValue(String tokenName, String tokenValue)
${Custom.tokenName},
can be placed in a notification template subject, message or text.
Custom tokens in a notification template, such as Document Message or Object Message, can only contain characters [a-z,A-Z,0-9,_] and must be 40 characters maximum.
If a null tokenName or tokenValue is set, an error will occur when
NotificationService.send() is called with this NotificationTemplate.
tokenName - name of a custom token in the template. This name should not have the Custom prefix,
for example, use myTokenName rather than Custom.myTokenName.tokenValue - value to set for the custom tokenNotificationTemplatedefault NotificationTemplate setTokenResolver(Consumer<TokenResolverInput> tokenResolverInputConsumer)
TokenResolverInput.
The default implementation does not set a Consumer for resolving tokens.tokenResolverInputConsumer - a Consumer that can resolve token valuesNotificationTemplateCopyright © Veeva Systems 2017–2022. All rights reserved.