Normally you do not program MCUs through on-board circuitry at all; that's an evaluation board thing for rapid testing. Placing such circuits on the board itself will bloat the BoM, making it expensive. To cheap out on the actual USB debugger by adding more parts to the PCB instead is senseless.
For Cortex M, there are a few sensible options:
Standard SWD connectors, male 2x5 1.27mm (0.05''). Program through an in-circuit debugger.These have the advantages of being cheap and standard.
The down-side is that 1.27mm IDC connectors on ribbon cable are
trash. They are trash for debugging and they are extra trash for production purposes. The problem is that the IDC connection itself
tends to take a lot of strain when you disconnect it while pulling on
the ribbon cable (you shouldn't remove it like that, but everyone
does). When they fail, they fail in subtle ways.
Standard JTAG connectors, classic double-row header strips, male 2x10 2,54mm (0.1''). Program through an in-circuit debugger. Very cheap and standard.
These are more rugged than the 1.27mm ones. However, they take up ridiculous amounts of board space.
Custom connector. Use whatever suits the product best and adapt cable assemblies. "Card edge" for example, is one way to skip the need for soldered connectors on the PCBA, but they also take quite a bit of space.
Buy MCUs pre-programmed. This is the most cost-efficient option if you have high volumes and are comfortable with providing the executable to a contractor. You probably still want the option to attach a debugger though, so maybe still leave room for a SWD connector even if you don't have it mounted.
Please note that you shouldn't be using some programming IDE in production. The chances of messing up increase and you really don't want the production crew having full access to the source. Not necessarily a trust issue, but more like introducing a huge potential for goof-ups: suppose someone downloads the debug build instead of the release build by accident etc.
Instead, the executable should be provided in one of the standard formats: bin/hex/s19 etc. Just to be downloaded through whatever program your USB adapter fancies.
As for which in-circuit debugger to pick, there's lots (and product recommendations is off-topic). But consider if you wish to use it for debugging only, debugging + production or for production only. Someone mentioned ST-Link - also consider if a specific brand is good enough or if you wish to use the debugger in future projects also, where you do not necessarily intend to use an ST part. ST-Link probably won't let you do that.