New Draft with Template

The script may not be that approachable if you are not familiar with coding, but it’s not terribly difficult to alter. The line in the example New Draft with Template action which sets the content of the new draft is:

d.content = d.processTemplate(template.content);

In this case the d variable is the new draft that has been created, and the template is the variable holding the template draft. The processTemplate part is what evaluated tags in that template, so timestamps and what not get expanded.

Perhaps the simplest way to get what you are describing is to keep putting the name of the template in the first line of the template, but remove that line when creating the new draft from the template. Changing the line above to the below would accomplish this…

let templateLines = template.lines; // get lines of template as array
templateLines.shift(); // remove first line
let templateContent = templateLines.join("\n"); // re-join lines without first one
d.content = d.processTemplate(templateContent);

Then you would still be selecting templates based on the name you put in the first line, but the first line would be omitted when creating the new draft with the action.