logo

NJP

What are Email Templates in ServiceNow? | How Email templates are created in ServiceNow?

Import · Mar 07, 2021 · video

[Music] please subscribe to my channel and click on the bell icon to get the regular updates of my channel and do not forget to like comment and share hello everyone welcome to sas with servicenow this video is about email templates in servicenow platform in this video you will learn what are email templates in servicenow where they are used in servicenow and how to create new email templates for sending email notifications from servicenow platform what are email templates in servicenow email templates allow us to send emails with pre-defined templates which are reusable content for subject and body of the email notifications for example you are sending email notifications in one format for every type of task in that case rather than providing email content which is subject and body in each notification separately you can create one template and use it in all notifications wherever you want that format email templates provide consistent information and save time they can be created in rich html format servicenow has a module of email templates and that is templates which is under system notification application in which you can access all email templates created in the instance you can also create new templates as well via this module and this module can be accessed by users who have admin role in the instance this is the form of email template in which you can provide details to create new templates for email notifications first field of this form is name in which you can provide the name of the template you want to create second is table in which you can select the table of rackets of which email notifications will be sent next is subject in which you can provide the text for subject of email next is method html in which you can provide the text in html format basically this is the body of the email now if you want to send simple text message and not in html format then you provide text in next field that is message text and this whatever content whatever data whatever message you will put in this particular field that will not be in html format that will be just simple text the next is sms alternate if you want users to get sms notification for same notification then you can mention the text in this field as well and if you will leave this field as empty then whatever text you will provide in methods text that will be used for sms as well you must be thinking that if this is a template that how can i make some data dynamic in notification overall when you create a notification you can use some dynamic data as well with the help of variables similarly in email template as well you can access variables that means you can access the fields which you have on that particular table you have selected for that particular template now while providing these texts which you can see in these fields in these different fields so you have option to select variables and whatever data you want to populate via when you want to send that notification as part of the email template that you can select that particular field you can select in this template as well and the data will be automatically populated when email will be sent with the help of this email template now how can i use template in a notification this is the form of notification in which you can see a field called email template and this is under what it contains section now this field is a reference field which shows the rackets from templates table and you can select the template for the notification you want to create now let's see email templates in my personal developer instance and create new template and send notification using same template this is my personal developer instance now in order to access templates you can directly go to system notifications application now under system notification application you will see this templates module so click on this once you will click on this module you will see list of available email templates in your instance in order to create new one you can just click on this new button and this will open up a new form of email template so here you can see we have same fields now what we will do we will start with providing the name of the template so this is for demo so i'm just doing demo email comma dot template that's it now here we have incident and i'm going to provide let's say whenever i change the state it should send a notification but for that maybe i will just use uh this template uh so i will just mention um i will i will take the field from here so let's let's take number so we will have this number right here we have this number so what i will do i will just cut from here is updated this is my template i think it can it can send any update basically and here i will just put i can do like this and i can just do hello number was updated so here i'm putting number was updated and i can put title so if i want to show title that is short description so i will put short description i think i can keep like this and then i can do description or maybe i will not write it i don't have to write it overall because if i will click on that variable i can just show in this template automatically so that word will also be automatically added so you can see we have this description hello it says this number was updated short description this description this so this is how you can just put any content you want and what will happen when i will use this template it will only show this data in whatever email notification you will select so you don't have to mention these contained the subject separately and i will show you how exactly you can do that so i'm putting this message html so i think it should be good so i will just put maybe thanks that's it demo system and what i will do and i'm doing it for incident and i'm going to save this when i will save this this particular email template will be captured in the update set so that means now i can also move it to the next instance so i'm done i think i don't have to add anything so we will see how exactly it is populating this data with the template for for basically notifications so what i will do now i will go to notifications and here i will create a new notification so we will create new notification and here i can just mention demo dot email and i can select incident table because we selected incident for like then in the table in the template we also selected incident so here i can keep i'm not i'm not selecting these fields when to send i can record inserted okay i can put record updated not on inserted and i can maybe i will just mention short description not every time maybe it starts with email demo and who will receive maybe i can just put myself and we can also put maybe assignment group so here we have assignment group and we will also send it to assign to if it is available and that's it and here i will select what will now here in what will what it will contain this is really important so if you remember i mentioned that how exactly you can use the template so here is the field where we can select that template so i will remove this one so as of now it is already showing me another template what i will do what i will do i will just click here and here we have our new template demo email dot template so i will just select that and i don't have to put anything here so normally when you create notification you have to provide that data over here for that particular notification but in this case because i'm selecting this email template i don't need to put any subject any any text in these two fields because when this notification will be sent it will automatically take the template from from this particular template which we have selected so whatever subject whatever body we have mentioned in this template system will take the data from that template how we will see now so i will just click on save so we have selected the template once you are done with the selection of the template now you are ready to do test and for testing so we mentioned the condition it is record is updated and it should be email demo so basically short description should start with email demo so what i will do i will go to here and i will just maybe i think update maybe i will update existing incidents i'm opening this one because we have mentioned the condition for update not inserted so here i will just maybe select any user able tutor and here i will put email demo this is a demo for email template and here i can select the assignment group so that is application development here i can select the group the person assigned to person so i can select this one and here i can select short description sorry description as well so here and description just to show you the difference so i think that's it so what i will do i will just click on save and this should this particular this particular action should trigger that notification which we have just created with template we didn't mention any content in the subject and body of body of that particular email notification that message text because we just selected the template so it should send now i will go to email logs so let me go to emails so if i go to emails and you can see here it says is updated and i open this one and you can see it is our same email demo dot email that means our new email notification which is created it got triggered because it met it basically uh got the condition so condition was matched and that's the reason system triggered that notification and let's see the data so if i talk about the data so we will just preview it and you can see here hello number incident was updated short description here description here now you can see and it is you can see thanks demo system now you can understand that we did not mention any data directly in the notification however it pulled all those information from the template use use the template and send that notification that's how you can create templates you can make the data dynamic as well with the help of templates and send notifications that's how you create templates and servers now and use it for sending different types of notifications for for different requirements you get from your customers and clients if you really think then i'm able to enhance your learning experience in service now then please do not forget to like share and subscribe to my channel and share videos with your friends with your colleagues so that they can also get more information about servicenow and learn the platform thank you and have a great day

View original source

https://www.youtube.com/watch?v=G2ijyBi8onE