Nested families parameters

I have an issue which can be done in Revit along but it would take me forever, I have a substructure family made up of a pile cap and the pile 2 elements within one, I created a script which I had to first create a project parameter within my Revit file, the run script to bring the information of the forward like the location of the structural foundations, however that only picks up the pile cap and not the piles is there anyways which I can do this through dynamo please and let it show within the properties like so grids