[CONF] Apache Syncope Manage notification e-mail templates

2013-12-31 Thread Francesco Chicchiricco (Confluence)














  


Francesco Chicchiricco edited the page:
 


Manage notification e-mail templates   




 Comment: SYNCOPE-463 


 



 Table of Contents








style
decimal


 




Introduction
You can create new (and modify existing) template messages to customize the body of notification messages. This can be achieved by creating and / or modifying the notification e-mail template files.
...

 user  UserTO instance representing the subject of the current notification
 syncopeConf  MapString, String containing all defined configurations as key, value - see how to manage these items 
 recipients  list of UserTO instances for all the actual recipients of the current notification e-mail
 events  list of String containing all the events that could have triggered the current notification

 Apache Syncope = 1.1.5 
 New Syncope-specific variable were added: 

 type  type of event being notified 
 category  category (String) of event being notified 
 subcategory  subcategory (String) of event being notified 
 event  event (String) that actually triggered the current notification 
 condition  condition (success or failure) under which this notification was sent 

 Notifications can be related to RESTful method invocation that actually changed an entity (user, role, resource, ...). In this case, additional variables are available: 

 before  entity value (Object) before actual modification took place 
  

[CONF] Apache Syncope Manage notification e-mail templates

2013-01-09 Thread confluence







Manage notification e-mail templates
Page edited by Francesco Chicchiricco


 Changes (8)
 




...
 Besides standard expressions, you can use the following Syncope-specific variables: 
* {{user}} 
  [UserTO|http://syncope.apache.org/apidocs/org/apache/syncope/client/to/UserTO.html] instance representing the subject of the current notification 
* {{syncopeConf}} 
  {{MapString, String}} containing all defined configurations as {{key, value}} 
* {{recipients}} 
  list of [UserTO|http://syncope.apache.org/apidocs/org/apache/syncope/client/to/UserTO.html] instances for all the actual recipients of the current notification e-mail 
* {{events}} 
  list of {{String}} containing all the events that triggered the current notification 


Full Content



Introduction
Template files
Template location
Template format


Introduction

You can create new (and modify existing) template messages to customize the body of notification messages. This can be achieved by creating and / or modifying the notification e-mail template files.

Template files

Templates are defined by their name. 

Each template is made up of a couple of files:

	the rich-text HTML variant (with extension .html.vm)
	the plain text variant (with extension .txt.vm)



For example, the default optin template is defined by:

	optin.html.vm
	optin.txt.vm



Template location

Assuming you have generated and built your own project, existing templates (including the default optin template) are located under 

core/target/syncope/WEB-INF/classes/mailTemplates/


You need to create your own template files (or copy existing to modify) under 

core/src/main/resources/mailTemplates/


Template format

Template files are interpreted using the Velocity engine; check the language reference.

Besides standard expressions, you can use the following Syncope-specific variables:

	user
  UserTO instance representing the subject of the current notification
	syncopeConf
  MapString, String containing all defined configurations as key, value
	recipients
  list of UserTO instances for all the actual recipients of the current notification e-mail
	events
  list of String containing all the events that triggered the current notification





Change Notification Preferences

View Online
|
View Changes
|
Add Comment