I have two functions one creates a custom object which once done is piped to the next function. The problem is that the second function is not receiving my object correctly. Ins
This is expected behavior. The begin {}
block runs before any pipeline objects are encountered, so you have no access to any parameters that come in through the pipeline in your begin block.
The process {}
block is run once for each item, so the code you have in the begin block really needs to be put there (because it's specific to a single VM).