How to create a static mesh in UE5 in C++?

I have tried to use code from UE4 for this but it no longer compiles.
Do we have any recommended approach to create a static mesh in C++ in UE5?

Any feedback is welcome.