Create a Brep from NurbsSurface and NurbsCurves

Hey folks,

I’m trying to use rhino3dm via Python to read in a 3dm model gather the nurbs data, edit it, and then create a new 3dm model.

I have the nurbs data extracted (looks to be a single Brep with multiple faces, edges, and vertices). I’ve got my new nurbs surfaces and curves reconstructed in rhino3dm. But now I’m not sure how to put it all together.

Maybe I’m confused on the data structures of a Brep, but I’m not sure how to create/edit the lists to add these surfaces, edges, and vertices. It’s trivial to add the surfaces directly to the model, and I can confirm I can create the surfaces, but then the edges from the curves are not there (square surfaces).

Any guidance would be appreciated! Thanks!

This is an explanation of the data structure of a brep