You can reference environment variables (ones defined by you as well as standard system variables) in notification templates, so long as you use the ${VAR} syntax.
You can also include register variables for a project in notification templates. If you reference an empty register, the system returns an empty string.