Normal rotation to object rotation

Hey, is there a way to set the object rotation to the rotation of a face? I want to have the same rotation on the object like the normal rotation in edit mode.

Yes. Assign all vertices to a hook modifier, make a custom transform orientation from the face, align the object to transform orientation, and then apply the modifier.

Worked. Will take his time for 100 Objects but i guess a cup of tee and some music will do the job. Thank you.

Hey what is the actual Python API you are referring when you say “align the object to transform orientation” , the reason I am asking is that the orientations seem to affect the operations done in that context (once the orientation is created and applied). You seem to refer a way to arbitrarily align an object to them, which is something I am interested in figuring out.

thanks