I'm not sure if this is the answer to your question, but, because I don't know a lot about foreman. I do know quite a lot about Puppet and if this a Puppet related question, I guess you need to write a device type for the devices you want to manage.
Here is an example on how to do this.