You could create a view that contains a single field/row that contains the KML content and use the table CSV export feature.
A more elegant solution is to create a custom pack that sends the content directly to the service that needs this data. Ideally, the service you POST it to could store into the system that needs this document. Or, it could be a service that allows the final system to retrieve it.
I generate a lot of GeoJSON data in Coda and use a custom pack to post it into a Firestore database and mapping apps then retrieve it from there.
Only slightly better is with a dataurl. But Coda blocks data url links, so you can also only work with copy/paste.
Here is an example.
Click the button to copy the data url, then open a new tab and paste it into your browsers address bar. Hit enter and it should start a file download. In most browsers you can not predefine a filename thatway. You have to enter it during the download manually.
Coyp to clipboard does not work in the embed directly in the community! You need to “open in coda” to test it.