I have found the Editor class to create an empty prefab at any location but how do I add .fbx, scripts etc. I am missing the necessary functions. Would it be possible to point me to the right direction? Thank you.
Most of the stuff you want is in the EditorUtility class… personally I have found the easiest way to build the prefabs was to make an Editor script that creates a Prefab in the Project View and then creates a GameObject in the Hierarchy (Scene) View and add all the stuff you want to the GameObject (Mesh, Materials etc), then calls EditorUtility.ReplacePrefab with the newly created GameObject and Prefab.
You can then delete GameObject from the scene and will have a working Prefab in the Project view…
I’m not sure if this is the best way, and would also like to hear other suggestions.