Current template system works for simple cases. With anything more complex and involving data from not directly related entities I feel forced to create custom "bag of values" entities, just for the purpose of sending an email or generating a document. There's also no easy way to add arbitrary variables to templates. I mean variables that are not connected with any entities, something like for example current date. I think it would help a lot if you could set up multiple "macro sources" and add arbitrary parameters too (just like you can create parameters for a business process).
To get the IMacrosInvokable interface, you have to add it first, by adding source code to the schema of your development package. Please, refer to the paragraph 'Creating the class which implements the IMacrosInvokable interface' of the guide.
Apart from that you can use your own templates that are quite convenient as well. More details are in this article:
If you receive the error 'IMacrosInvokable' could not be found' that means that most likely you are not using the Service application. This guide and functionality are developed for Service applications only and the interface IMacrosInvokable' is developed in CaseService package of the IMacrosInvokable schema. It might me the reason for this error. Our R&D team is working on implementation of this functionality in different products, so you may expect it in the upcoming versions of the application.