Reporting on host collections

I’m running Foreman+Katello EL latest version and I’m trying to clone and modify the reporting templates to serve my purpose. I must admit I’m really struggling at understanding what variables are available and how to call them. All I’m trying to do should be simple:

I want an example of how to ask the user for a host collection ID, and then based off that input iterate and print out all hostnames in that collection.

Any help for this specific goal, or general links for reporting would be super helpful thank you much.

To know what methods and variables are available, the best way is in the “Help” tab of the web UI when you’re editing the template. You should see everything there.

You can also view the documentation about it here: Managing hosts