Is it possible to have a Dynamo script that can Purge Unused for all families in a project?

is it possible to have a Dynamo script that can Purge Unused for all families in a project?

I would like Revit models with minimal file size, but do not have time to open each family in the model, do I Purge Unused, and then reload each one back? if the families also have several levels of nested components,
can dynamo help?

I found this

Yes.

Also
image

3 Likes