Atlassian Support here! The idea with code insights reports is that automated systems such as the likes of SonarQube etc are able to create reports via following set of REST API endpoints after an analysis of a commit's code has been performed:
While many solutions have out-of-the-box integrations that allow them to pretty seamlessly create their reports, it's of course possible to develop a form of automation that creates your own custom reports. In case you don't already have it handy, here's a link to a tutorial on how you'd be able to do that: