You can add email template objects to automatic email templates to return information about URIs, machines, blueprints, costs, and requests.

You can use the following email template objects to return information to automatic email templates.

  • WebsiteURIItems

  • WebsiteURIInbox

  • VirtualMachineEx

  • VirtualMachineTemplateEx

  • ReservationHelper

  • Request

  • RequestWithAudit

The WebsiteURIItems object returns the URL of the Items tab on the vRealize Automation console, for example https://vcac.mycompany.com/shell-ui-app/org/mytenant/#csp.catalog.item.list. To use this object to provide a link to the My Items page in the console, consider the following sample lines.

       Click
          <a>
            <xsl:attribute name="href">
              <xsl:value-of select="//WebsiteURIItems"/>
            </xsl:attribute><xsl:value-of select="//WebsiteURIItems"/>here</a>
          for your provisioned items.

The WebsiteURIInbox object returns the URL of the Inbox tab on the vRealize Automation console, for example https://vcac.mycompany.com/shell-ui-app/org/mytenant/#cafe.work.items.list. To use this object to provide a link to the My Inbox page in the console, consider the following sample lines.

       Click
          <a>
            <xsl:attribute name="href">
              <xsl:value-of select="//WebsiteURIInbox"/></xsl:attribute><xsl:value-of select="//WebsiteURIInbox"/>here</a>
           for your assigned tasks.

The VirtualMachineEx object returns a specific item of information about the machine associated with the event triggering the email. The information is determined by the attribute provided with the object; see the table Selected Attributes of the VirtualMachineEx Object for more information. For example, you could use the following line to include the expiration date of the machine in an email.

<xsl:value-of select="//VirtualMachineEx/Expires"/>

Table 1. Selected Attributes of the VirtualMachineEx Object

Attribute

Returns

Name

Name of machine as generated by vRealize Automation

Description

Machine’s description

DnsName

Machine’s DNS name

TemplateName

Name of blueprint from which machine was provisioned

StoragePath

If a virtual machine, name of storage path on which machine was provisioned

State/Name

Status of machine

Owner

Owner of machine

Expires

Date on which machine expires

ExpireDays

Number of days until machine expires

CreationTime

Date and time at which machine was provisioned

HostName

If a virtual machine, name of host where machine was provisioned

GroupName

Name of business group in which machine was provisioned

ReservationName

Name of reservation on which machine was provisioned

Group/AdministratorEmail

Names of users or groups who receive group manager emails for business group for which machine was provisioned

In addition, the special attribute Properties lets you search the custom properties associated with the machine for a specific property and return the value if found. For example, to include the value of Image.WIM.Name, which specifies the name of the WIM image from which a machine was provisioned, you could use the following lines.

<xsl:for-each select="//VirtualMachineEx/Properties/NameValue">
    <xsl:if test="starts-with(Name, 'Image.WIM.Name')">
        <xsl:value-of select="Value"/>

If the machine does not have the Image.WIM.Name property, nothing is returned.

The VirtualMachineTemplateEx object returns a specific item of information about the source blueprint of the machine associated with the even triggering the email. The information is determined by the attribute provided with the object; see the table Selected Attributes of the VirtualMachineTemplateEx Email Object for more information. For example, to include the daily cost specified in the source blueprint you could use the following line:

<xsl:value-of select="//VirtualMachineTemplateEx/Cost"/>

Table 2. Selected Attributes of the VirtualMachineTemplateEx Email Object

Attribute

Returns

Name

Name of blueprint

Description

Blueprint’s description

MachinePrefix

Machine prefix specified in blueprint

LeaseDays

Number of lease days specified in blueprint

ExpireDays

If a virtual blueprint, number of archive days specified

Cost

Daily cost specified in blueprint

VirtualMachineTemplateEx also takes the special attribute Properties to let you search the custom properties included in the blueprint for a specific property and return the value if found, as described for the VirtualMachineEx object.

The ReservationHelper object returns information about the daily cost of the machine, as specified by the attributes in the table Selected Attributes of the ReservationHelper Email Object, when a cost profile applies to the virtual or physical machine associated with the event triggering the email.

Table 3. Selected Attributes of the ReservationHelper Email Object

Attribute

Returns

DailyCostFormatted

Daily cost of machine

LeaseCostFormatted

Daily cost times the number of days in the machine’s lease.