Default Template used in Family Node

@Japhy or @kike

I’m working with the RhinoInside.Revit API. I’m looking to create a Python equivalent to the New Component Family node. Or, in summary, trying to find a way to create new families in Revit via Python.

To do this, I understand you need:

  • a Template file
  • boolean option to overwrite family if existing
  • boolean option to overwirte parameters
  • string family name
  • Revit Category
  • Revit Geometry

When you opt to do this in Grasshopper you don’t need to provide a template file. Does the grasshopper node look at the Category you are using then go to the Revit version>Family Templates and grab the ‘best match’ default template? Or what is happening behind the scenes here that makes it so that you don’t need to supply a Template input? I’m suspicious of my assumption because I’m able to make Structural Connection families in Grasshopper, but I don’t see a corresponding Structural Connections.rft template in the Family Template folder.

Also, when it comes to passing Geometry to Revit should I be using this website/method as API reference? I see it’s for 2022, but still seems like the most comprehensive RiR API documentation I can find.
GeometryEncoder.ToSolid Method (Brep)

Thanks,

Dan

Hi @lignindes

When the template file is missing RiR uses a generic built-in work-plane based template and assigns the category to the resulting family on the fly.

About the API documentation, you are right the documentation for Revit 2022 is valid also for Revit 2026 and for any version of RiR after 1.0.