Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to auto generate pdf on HR case from HR document template.

Vicky Kumar Sh1
Tera Contributor

I want automatically generate and attach pdf to HR case from HR document template mentioned in pdf template field on HR case. I was thinking about BR but couldn't find any script or API that does it for HR documents. 

1 REPLY 1

Muskan Dixit
Tera Contributor

Use below script in your BR:-

new GeneralHRForm(current.sys_class_name, current.sys_id).generate();

Also make sure to set pdf template field on HR case via HR template or record producer script.