Rotate 3D - Rotate along line/axis/vector

Hi! Does anybody know how to properly rotate these boxes so that they grow in direction of these lines? I have tried rotate and rotate 3d and many others, yet can’t seem to find the right axis or plane to rotate from and chaos happens. Thank you!
5.11 Protocolo (172.5 KB)

I cant really open your file beacause I dont have all of your plugins, but try Align plane .

Right now youre feeding points into your rectangle component, you should feed aligned planes.

Make a plane (XY plane for example) in each of your points and then allign it in the corresponding direcion, you need a vector or simply converting your lines to vectors for that matter.

Finally feed that into your rectangle or box component, otherwise you get a XY plane aligned to the world axis, which is what you see on your screen cap.