Export grasshopper curve/line to revit with assigning subcategory

Dear All,
I’m trying to export rhino/grasshopper curves to Revit using subcategories to control the visibility and colour of the curves/lines. Main issue is to export curves with its colour.

I’ve started creating loadable family from Rhino curves and I’ve used Component Family Curve connected to New Component Family.

I have faced the problem because grasshopper communicates 1. The input category id cannot be assigned as the new category for this family. Parameter name: categoryId

I’ve checked and I have the same subcategory name in the main Revit file (where I want to export rhino geometry) and in the template file but still I have the same error with categoryId .

I would like to use Lines model object but I have problem to find correct family template in Family Component to create the curve family. I’ve tried also use mass (only geometric form available) and generic models (all problem described in the attached file).

I will appreciate for any advice how to solve the problem with not correct categoryId.

Maybe there is simpler way to export rhino curves to Revit with its original colours. If not via Lines, perhaps exporting via Regions might be the solution? . What kind of family (templates) is the best way to choose for Lines or Region?

How to change material of DirectShape geometry - I always have models/rebar also when I was changing generic models to lines (see below print screen)

In the attachment I’ve sent Revit and Rhino/grasshopper files.
Exort to Revit_loadable families.gh (24.6 KB) Triangle to Revit export.3dm (46.2 KB) Triangle_Revit.rvt (3.4 MB) Bryła_katy.rfa (540 KB) Triangle Angle_my.rfa (352 KB)
Cheers,